index.css 9.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461
  1. /*-----------------------------------------------------------------------------
  2. | Copyright (c) Jupyter Development Team.
  3. | Distributed under the terms of the Modified BSD License.
  4. |----------------------------------------------------------------------------*/
  5. /*-----------------------------------------------------------------------------
  6. | Table of Contents
  7. |----------------------------------------------------------------------------*/
  8. .jp-TableOfContents-content {
  9. flex: 1 1 auto;
  10. margin: 0;
  11. padding: 0;
  12. list-style-type: none;
  13. overflow: auto;
  14. background-color: var(--jp-layout-color1);
  15. }
  16. .jp-TableOfContents-content li {
  17. display: flex;
  18. flex-direction: row;
  19. padding: 4px 12px;
  20. -webkit-user-select: none;
  21. -moz-user-select: none;
  22. -ms-user-select: none;
  23. user-select: none;
  24. cursor: pointer;
  25. padding-top: 8px;
  26. padding-bottom: 8px;
  27. }
  28. .jp-TableOfContents-content li:hover {
  29. background: var(--jp-layout-color2);
  30. }
  31. .jp-TableOfContents {
  32. display: flex;
  33. flex-direction: column;
  34. background: var(--jp-layout-color1);
  35. color: var(--jp-ui-font-color1);
  36. font-size: var(--jp-ui-font-size0);
  37. height: 100%;
  38. }
  39. .jp-TableOfContents header {
  40. border-bottom: var(--jp-border-width) solid var(--jp-border-color2);
  41. flex: 0 0 auto;
  42. font-size: var(--jp-ui-font-size0);
  43. font-weight: 600;
  44. letter-spacing: 1px;
  45. margin: 0px;
  46. padding: 12px 0 4px 12px;
  47. text-transform: uppercase;
  48. }
  49. [data-jp-theme-light='true'] .jp-TableOfContents-icon {
  50. background-image: url(list-light.svg);
  51. }
  52. [data-jp-theme-light='false'] .jp-TableOfContents-icon {
  53. background-image: url(list-dark.svg);
  54. }
  55. .jp-TableOfContents-codeContainer {
  56. overflow: hidden;
  57. }
  58. .jp-TableOfContents-code {
  59. font-size: 9px;
  60. max-height: 70px;
  61. }
  62. .cm-toc .CodeMirror {
  63. font-size: 9px;
  64. z-index: 0;
  65. border: var(--jp-border-width) solid var(--jp-cell-editor-border-color);
  66. border-radius: 0px;
  67. background: var(--jp-cell-editor-background);
  68. max-width: 100%;
  69. max-height: 36px;
  70. }
  71. .toc-code-span {
  72. width: 100%;
  73. max-width: 100%;
  74. overflow: hidden;
  75. }
  76. .cm-toc .CodeMirror-scroll {
  77. overflow: hidden !important;
  78. }
  79. .CodeMirror-scroll::-webkit-scrollbar-track {
  80. background-color: transparent;
  81. }
  82. .toc-toolbar-icon,
  83. .toc-toolbar-icon-selected {
  84. float: left;
  85. padding: 0px;
  86. margin: 4px;
  87. background-repeat: no-repeat;
  88. background-color: none;
  89. background-size: 100%;
  90. background-position: center;
  91. height: 24px;
  92. width: 24px;
  93. margin: 4px;
  94. border-radius: 2px;
  95. }
  96. [data-jp-theme-light='true'] .toc-toolbar-code-icon {
  97. background-image: url('img/code.svg');
  98. }
  99. [data-jp-theme-light='false'] .toc-toolbar-code-icon {
  100. background-image: url('img/code_darktheme.svg');
  101. }
  102. [data-jp-theme-light='true'] .toc-toolbar-markdown-icon {
  103. background-image: url('img/markdown.svg');
  104. }
  105. [data-jp-theme-light='false'] .toc-toolbar-markdown-icon {
  106. background-image: url('img/markdown_darktheme.svg');
  107. }
  108. [data-jp-theme-light='true'] .toc-toolbar-auto-numbering-icon {
  109. background-image: url('img/autonumbering.svg');
  110. }
  111. [data-jp-theme-light='false'] .toc-toolbar-auto-numbering-icon {
  112. background-image: url('img/autonumbering_darktheme.svg');
  113. }
  114. .toc-toolbar-tag-icon {
  115. width: 30px;
  116. height: 22px;
  117. margin: 4px 9px 4px 4px;
  118. }
  119. [data-jp-theme-light='true'] .toc-toolbar-tag-icon {
  120. background-image: url('img/tag.svg');
  121. }
  122. [data-jp-theme-light='false'] .toc-toolbar-tag-icon {
  123. background-image: url('img/tag_darktheme.svg');
  124. }
  125. [data-jp-theme-light='true'] .toc-toolbar-icon:hover {
  126. background-color: var(--jp-input-background);
  127. }
  128. [data-jp-theme-light='false'] .toc-toolbar-icon:hover {
  129. background-color: #3a3a3a;
  130. }
  131. [data-jp-theme-light='true'] .toc-toolbar-icon-selected {
  132. background-color: var(--jp-layout-color2);
  133. }
  134. [data-jp-theme-light='false'] .toc-toolbar-icon-selected {
  135. background-color: #565656;
  136. }
  137. .toc-code-cell-prompt {
  138. flex: 0 0 27px;
  139. color: var(--jp-cell-prompt-not-active-font-color);
  140. opacity: var(--jp-cell-prompt-not-active-opacity);
  141. font-family: var(--jp-cell-prompt-font-family);
  142. padding: var(--jp-code-padding);
  143. padding-right: 0px;
  144. padding-left: 0px;
  145. letter-spacing: var(--jp-cell-prompt-letter-spacing);
  146. line-height: var(--jp-code-line-height);
  147. font-size: 8px;
  148. border: var(--jp-border-width) solid transparent;
  149. text-align: left;
  150. white-space: nowrap;
  151. overflow: hidden;
  152. text-overflow: ellipsis;
  153. -webkit-user-select: none;
  154. -moz-user-select: none;
  155. -ms-user-select: none;
  156. user-select: none;
  157. }
  158. .toc-toolbar {
  159. position: relative;
  160. width: 100%;
  161. margin: 0px;
  162. user-select: none;
  163. border-bottom: var(--jp-border-width) solid var(--jp-border-color2);
  164. height: 36px;
  165. display: flex;
  166. align-items: center;
  167. }
  168. .toc-code-cell-div {
  169. display: inline-flex;
  170. width: 100%;
  171. }
  172. .toc-entry-holder {
  173. display: inline-flex;
  174. position: relative;
  175. align-items: center;
  176. width: 100%;
  177. }
  178. .toc-collapse-button {
  179. padding-left: 3px;
  180. cursor: default;
  181. min-width: 11px;
  182. position: absolute;
  183. }
  184. .toc-arrow-img {
  185. top: 0;
  186. bottom: 0;
  187. margin: auto;
  188. position: absolute;
  189. background-repeat: no-repeat;
  190. }
  191. .toc-downarrow-img {
  192. width: 12px;
  193. height: 6px;
  194. }
  195. [data-jp-theme-light='true'] .toc-downarrow-img {
  196. background-image: url('img/toggle_down.svg');
  197. }
  198. [data-jp-theme-light='false'] .toc-downarrow-img {
  199. background-image: url('img/toggle_down_darktheme.svg');
  200. }
  201. .toc-rightarrow-img {
  202. width: 7px;
  203. height: 12px;
  204. }
  205. [data-jp-theme-light='true'] .toc-rightarrow-img {
  206. background-image: url('img/toggle_right.svg');
  207. }
  208. [data-jp-theme-light='false'] .toc-rightarrow-img {
  209. background-image: url('img/toggle_right_darktheme.svg');
  210. }
  211. .toc-twist-placeholder {
  212. max-width: 10px;
  213. opacity: 0;
  214. overflow: hidden;
  215. }
  216. .cm-toc-plain-span {
  217. width: 100%;
  218. white-space: pre-wrap;
  219. display: block;
  220. }
  221. .cm-toc-plain-textarea {
  222. font-size: 9px;
  223. z-index: 0;
  224. border: var(--jp-border-width) solid var(--jp-cell-editor-border-color2);
  225. border-radius: 0px;
  226. background: var(--jp-cell-editor-background);
  227. width: calc(100% - 9px);
  228. overflow: hidden;
  229. max-height: 74px;
  230. resize: none;
  231. font-family: var(--jp-code-font-family);
  232. outline: none;
  233. user-select: none;
  234. white-space: pre;
  235. padding: var(--jp-code-padding);
  236. }
  237. .cm-toc .CodeMirror-sizer {
  238. min-width: 0px !important;
  239. min-height: 0px !important;
  240. margin-bottom: 0px !important;
  241. }
  242. .cm-toc .CodeMirror-line {
  243. white-space: pre-wrap;
  244. cursor: pointer;
  245. }
  246. .cm-toc .CodeMirror-lines {
  247. cursor: pointer;
  248. }
  249. .toc-tag-dropdown {
  250. display: flex;
  251. width: 100%;
  252. }
  253. .toc-tag-dropdown-button {
  254. margin-left: auto;
  255. }
  256. .toc-tags-container {
  257. padding: 4px;
  258. border-bottom: var(--jp-border-width) solid var(--jp-border-color2);
  259. }
  260. .toc-clear-button {
  261. font-size: 12px;
  262. color: var(--jp-ui-font-color1);
  263. padding-left: 15px;
  264. /* padding-top: 7px; */
  265. user-select: none;
  266. float: right;
  267. }
  268. .toc-clear-button:hover {
  269. font-size: 12px;
  270. color: var(--jp-ui-font-color2);
  271. padding-left: 15px;
  272. /* padding-top: 7px; */
  273. user-select: none;
  274. }
  275. .toc-filter-button {
  276. background-color: var(--jp-layout-color1);
  277. border: solid 1px var(--jp-layout-color4);
  278. border-radius: 3px;
  279. width: fit-content;
  280. padding: 5px;
  281. padding-left: 6px;
  282. padding-right: 6px;
  283. margin-right: 17px;
  284. color: var(--jp-layout-color5);
  285. float: right;
  286. font-size: 12px;
  287. user-select: none;
  288. margin-bottom: 13px;
  289. }
  290. .toc-filter-button:hover {
  291. background-color: var(--jp-layout-color4);
  292. border: solid 1px var(--jp-layout-color4);
  293. color: var(--jp-layout-color1);
  294. }
  295. .toc-filter-button-na {
  296. background-color: var(--jp-layout-color1);
  297. border: solid 1px var(--jp-ui-font-color3);
  298. border-radius: 3px;
  299. width: fit-content;
  300. padding: 5px;
  301. padding-left: 6px;
  302. padding-right: 6px;
  303. margin-right: 17px;
  304. color: var(--jp-ui-font-color3);
  305. float: right;
  306. font-size: 12px;
  307. user-select: none;
  308. margin-bottom: 13px;
  309. }
  310. .toc-no-tags-div {
  311. font-size: 12px;
  312. padding: 3px;
  313. padding-bottom: 6px;
  314. margin: auto;
  315. color: var(--jp-layout-color4);
  316. }
  317. .toc-tags-container {
  318. width: 100%;
  319. }
  320. .jp-TableOfContents-content code {
  321. font-size: inherit;
  322. }
  323. .toc-cell-item {
  324. padding-left: 24px;
  325. }
  326. /* styles for tags */
  327. .toc-tag-label {
  328. font-size: 11px;
  329. max-width: 100%;
  330. text-overflow: ellipsis;
  331. display: inline-block;
  332. overflow: hidden;
  333. box-sizing: border-box;
  334. padding-top: 0px;
  335. margin-top: -1px;
  336. margin-bottom: 0px;
  337. user-select: none;
  338. }
  339. .toc-tag {
  340. box-sizing: border-box;
  341. height: 24px;
  342. border-radius: 20px;
  343. padding: 10px;
  344. padding-bottom: 4px;
  345. padding-top: 5px;
  346. margin: 3px;
  347. width: fit-content;
  348. max-width: calc(100% - 25px);
  349. }
  350. .toc-selected-tag {
  351. color: white;
  352. background-color: #2196f3;
  353. outline: none;
  354. }
  355. .toc-unselected-tag {
  356. background-color: var(--jp-layout-color2);
  357. outline: none;
  358. }
  359. .toc-tag-holder {
  360. display: flex;
  361. flex-wrap: wrap;
  362. height: fit-content;
  363. padding-bottom: 6px;
  364. padding-right: 20px;
  365. padding-left: 9px;
  366. padding-top: 6px;
  367. }
  368. /* Font level sizes */
  369. .toc-level-size-1 {
  370. font-size: 16.89px;
  371. }
  372. .toc-level-size-2 {
  373. font-size: 14.82px;
  374. }
  375. .toc-level-size-3 {
  376. font-size: 13px;
  377. }
  378. .toc-level-size-4 {
  379. font-size: 11.4px;
  380. }
  381. .toc-level-size-5 {
  382. font-size: 10px;
  383. }
  384. .toc-level-size-6 {
  385. font-size: 9px;
  386. }
  387. .toc-level-size-default {
  388. font-size: 9px;
  389. }