| 1 |
/* |
| 2 |
* Wrap inline code samples otherwise they shoot of the side and |
| 3 |
* can't be read at all. |
| 4 |
* |
| 5 |
* https://github.com/mkdocs/mkdocs/issues/313 |
| 6 |
* https://github.com/mkdocs/mkdocs/issues/233 |
| 7 |
* https://github.com/mkdocs/mkdocs/issues/834 |
| 8 |
*/ |
| 9 |
.rst-content code { |
| 10 |
white-space: pre-wrap; |
| 11 |
word-wrap: break-word; |
| 12 |
padding: 2px 5px; |
| 13 |
} |
| 14 |
|
| 15 |
/** |
| 16 |
* Make code blocks display as blocks and give them the appropriate |
| 17 |
* font size and padding. |
| 18 |
* |
| 19 |
* https://github.com/mkdocs/mkdocs/issues/855 |
| 20 |
* https://github.com/mkdocs/mkdocs/issues/834 |
| 21 |
* https://github.com/mkdocs/mkdocs/issues/233 |
| 22 |
*/ |
| 23 |
.rst-content pre code { |
| 24 |
white-space: pre; |
| 25 |
word-wrap: normal; |
| 26 |
display: block; |
| 27 |
padding: 12px; |
| 28 |
font-size: 12px; |
| 29 |
} |
| 30 |
|
| 31 |
/** |
| 32 |
* Fix code colors |
| 33 |
* |
| 34 |
* https://github.com/mkdocs/mkdocs/issues/2027 |
| 35 |
*/ |
| 36 |
.rst-content code { |
| 37 |
color: #E74C3C; |
| 38 |
} |
| 39 |
|
| 40 |
.rst-content pre code { |
| 41 |
color: #000; |
| 42 |
background: #f8f8f8; |
| 43 |
} |
| 44 |
|
| 45 |
/* |
| 46 |
* Fix link colors when the link text is inline code. |
| 47 |
* |
| 48 |
* https://github.com/mkdocs/mkdocs/issues/718 |
| 49 |
*/ |
| 50 |
a code { |
| 51 |
color: #2980B9; |
| 52 |
} |
| 53 |
a:hover code { |
| 54 |
color: #3091d1; |
| 55 |
} |
| 56 |
a:visited code { |
| 57 |
color: #9B59B6; |
| 58 |
} |
| 59 |
|
| 60 |
/* |
| 61 |
* The CSS classes from highlight.js seem to clash with the |
| 62 |
* ReadTheDocs theme causing some code to be incorrectly made |
| 63 |
* bold and italic. |
| 64 |
* |
| 65 |
* https://github.com/mkdocs/mkdocs/issues/411 |
| 66 |
*/ |
| 67 |
pre .cs, pre .c { |
| 68 |
font-weight: inherit; |
| 69 |
font-style: inherit; |
| 70 |
} |
| 71 |
|
| 72 |
/* |
| 73 |
* Fix some issues with the theme and non-highlighted code |
| 74 |
* samples. Without and highlighting styles attached the |
| 75 |
* formatting is broken. |
| 76 |
* |
| 77 |
* https://github.com/mkdocs/mkdocs/issues/319 |
| 78 |
*/ |
| 79 |
.rst-content .no-highlight { |
| 80 |
display: block; |
| 81 |
padding: 0.5em; |
| 82 |
color: #333; |
| 83 |
} |
| 84 |
|
| 85 |
|
| 86 |
/* |
| 87 |
* Additions specific to the search functionality provided by MkDocs |
| 88 |
*/ |
| 89 |
|
| 90 |
.search-results { |
| 91 |
margin-top: 23px; |
| 92 |
} |
| 93 |
|
| 94 |
.search-results article { |
| 95 |
border-top: 1px solid #E1E4E5; |
| 96 |
padding-top: 24px; |
| 97 |
} |
| 98 |
|
| 99 |
.search-results article:first-child { |
| 100 |
border-top: none; |
| 101 |
} |
| 102 |
|
| 103 |
form .search-query { |
| 104 |
width: 100%; |
| 105 |
border-radius: 50px; |
| 106 |
padding: 6px 12px; |
| 107 |
border-color: #D1D4D5; |
| 108 |
} |
| 109 |
|
| 110 |
/* |
| 111 |
* Improve inline code blocks within admonitions. |
| 112 |
* |
| 113 |
* https://github.com/mkdocs/mkdocs/issues/656 |
| 114 |
*/ |
| 115 |
.rst-content .admonition code { |
| 116 |
color: #404040; |
| 117 |
border: 1px solid #c7c9cb; |
| 118 |
border: 1px solid rgba(0, 0, 0, 0.2); |
| 119 |
background: #f8fbfd; |
| 120 |
background: rgba(255, 255, 255, 0.7); |
| 121 |
} |
| 122 |
|
| 123 |
/* |
| 124 |
* Account for wide tables which go off the side. |
| 125 |
* Override borders to avoid weirdness on narrow tables. |
| 126 |
* |
| 127 |
* https://github.com/mkdocs/mkdocs/issues/834 |
| 128 |
* https://github.com/mkdocs/mkdocs/pull/1034 |
| 129 |
*/ |
| 130 |
.rst-content .section .docutils { |
| 131 |
width: 100%; |
| 132 |
overflow: auto; |
| 133 |
display: block; |
| 134 |
border: none; |
| 135 |
} |
| 136 |
|
| 137 |
td, th { |
| 138 |
border: 1px solid #e1e4e5 !important; |
| 139 |
border-collapse: collapse; |
| 140 |
} |
| 141 |
|
| 142 |
/* |
| 143 |
* Without the following amendments, the navigation in the theme will be |
| 144 |
* slightly cut off. This is due to the fact that the .wy-nav-side has a |
| 145 |
* padding-bottom of 2em, which must not necessarily align with the font-size of |
| 146 |
* 90 % on the .rst-current-version container, combined with the padding of 12px |
| 147 |
* above and below. These amendments fix this in two steps: First, make sure the |
| 148 |
* .rst-current-version container has a fixed height of 40px, achieved using |
| 149 |
* line-height, and then applying a padding-bottom of 40px to this container. In |
| 150 |
* a second step, the items within that container are re-aligned using flexbox. |
| 151 |
* |
| 152 |
* https://github.com/mkdocs/mkdocs/issues/2012 |
| 153 |
*/ |
| 154 |
.wy-nav-side { |
| 155 |
padding-bottom: 40px; |
| 156 |
} |
| 157 |
|
| 158 |
/* For section-index only */ |
| 159 |
.wy-menu-vertical .current-section p { |
| 160 |
background-color: #e3e3e3; |
| 161 |
color: #404040; |
| 162 |
} |
| 163 |
|
| 164 |
/* |
| 165 |
* The second step of above amendment: Here we make sure the items are aligned |
| 166 |
* correctly within the .rst-current-version container. Using flexbox, we |
| 167 |
* achieve it in such a way that it will look like the following: |
| 168 |
* |
| 169 |
* [No repo_name] |
| 170 |
* Next >> // On the first page |
| 171 |
* << Previous Next >> // On all subsequent pages |
| 172 |
* |
| 173 |
* [With repo_name] |
| 174 |
* <repo_name> Next >> // On the first page |
| 175 |
* <repo_name> << Previous Next >> // On all subsequent pages |
| 176 |
* |
| 177 |
* https://github.com/mkdocs/mkdocs/issues/2012 |
| 178 |
*/ |
| 179 |
.rst-versions .rst-current-version { |
| 180 |
padding: 0 12px; |
| 181 |
display: flex; |
| 182 |
font-size: initial; |
| 183 |
justify-content: space-between; |
| 184 |
align-items: center; |
| 185 |
line-height: 40px; |
| 186 |
} |
| 187 |
|
| 188 |
/* |
| 189 |
* Please note that this amendment also involves removing certain inline-styles |
| 190 |
* from the file ./mkdocs/themes/readthedocs/versions.html. |
| 191 |
* |
| 192 |
* https://github.com/mkdocs/mkdocs/issues/2012 |
| 193 |
*/ |
| 194 |
.rst-current-version span { |
| 195 |
flex: 1; |
| 196 |
text-align: center; |
| 197 |
} |