bootstrap-source/bootstrap-3.0.3/less/code.less
author stetrabby <info@trabucchi.de>
Fri, 20 Dec 2013 22:49:16 +0100
changeset 54 0ded9d7748b7
permissions -rwxr-xr-x
initial less based on the pymove3d.css
info@54
     1
//
info@54
     2
// Code (inline and block)
info@54
     3
// --------------------------------------------------
info@54
     4
info@54
     5
info@54
     6
// Inline and block code styles
info@54
     7
code,
info@54
     8
kbd,
info@54
     9
pre,
info@54
    10
samp {
info@54
    11
  font-family: @font-family-monospace;
info@54
    12
}
info@54
    13
info@54
    14
// Inline code
info@54
    15
code {
info@54
    16
  padding: 2px 4px;
info@54
    17
  font-size: 90%;
info@54
    18
  color: @code-color;
info@54
    19
  background-color: @code-bg;
info@54
    20
  white-space: nowrap;
info@54
    21
  border-radius: @border-radius-base;
info@54
    22
}
info@54
    23
info@54
    24
// Blocks of code
info@54
    25
pre {
info@54
    26
  display: block;
info@54
    27
  padding: ((@line-height-computed - 1) / 2);
info@54
    28
  margin: 0 0 (@line-height-computed / 2);
info@54
    29
  font-size: (@font-size-base - 1); // 14px to 13px
info@54
    30
  line-height: @line-height-base;
info@54
    31
  word-break: break-all;
info@54
    32
  word-wrap: break-word;
info@54
    33
  color: @pre-color;
info@54
    34
  background-color: @pre-bg;
info@54
    35
  border: 1px solid @pre-border-color;
info@54
    36
  border-radius: @border-radius-base;
info@54
    37
info@54
    38
  // Account for some code outputs that place code tags in pre tags
info@54
    39
  code {
info@54
    40
    padding: 0;
info@54
    41
    font-size: inherit;
info@54
    42
    color: inherit;
info@54
    43
    white-space: pre-wrap;
info@54
    44
    background-color: transparent;
info@54
    45
    border-radius: 0;
info@54
    46
  }
info@54
    47
}
info@54
    48
info@54
    49
// Enable scrollable blocks of code
info@54
    50
.pre-scrollable {
info@54
    51
  max-height: @pre-scrollable-max-height;
info@54
    52
  overflow-y: scroll;
info@54
    53
}
Impressum Datenschutzerklärung