| 12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061 |
- //
- // Code (inline and blocK)
- // --------------------------------------------------
- // Inline and block code styles
- code,
- pre {
- @include font-family-monospace();
- font-size: $font-size-base - 2;
- background-color: $code-tag-bg;
- color: $text-color;
- border: 1px solid $code-tag-border;
- padding: 10px;
- border-radius: 4px;
- }
- // Inline code
- code {
- color: $text-color;
- background-color: $code-tag-bg;
- border: 1px solid darken($code-tag-bg, 15%);
- white-space: nowrap;
- }
- code.code--small {
- font-size: $font-size-xs;
- padding: 5px;
- margin: 0 2px;
- }
- p.code--line {
- line-height: 1.8;
- }
- // Blocks of code
- pre {
- display: block;
- margin: 0 0 $line-height-base;
- line-height: $line-height-base;
- word-break: break-all;
- word-wrap: break-word;
- white-space: pre;
- white-space: pre-wrap;
- background-color: $code-tag-bg;
- // Make prettyprint styles more spaced out for readability
- &.prettyprint {
- margin-bottom: $line-height-base;
- }
- // Account for some code outputs that place code tags in pre tags
- code {
- padding: 0;
- color: inherit;
- white-space: pre;
- white-space: pre-wrap;
- background-color: transparent;
- border: 0;
- }
- }
|