markdown.css 4.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269
  1. /*---------------------------------------------------------------------------------------------
  2. * Copyright (c) Microsoft Corporation. All rights reserved.
  3. * Licensed under the MIT License. See License.txt in the project root for license information.
  4. *--------------------------------------------------------------------------------------------*/
  5. html, body {
  6. font-family: var(--markdown-font-family, -apple-system, BlinkMacSystemFont, "Segoe WPC", "Segoe UI", system-ui, "Ubuntu", "Droid Sans", sans-serif);
  7. font-size: var(--markdown-font-size, 14px);
  8. padding: 0 26px;
  9. line-height: var(--markdown-line-height, 22px);
  10. word-wrap: break-word;
  11. }
  12. body {
  13. padding-top: 1em;
  14. }
  15. /* Reset margin top for elements */
  16. h1, h2, h3, h4, h5, h6,
  17. p, ol, ul, pre {
  18. margin-top: 0;
  19. }
  20. h1, h2, h3, h4, h5, h6 {
  21. font-weight: 600;
  22. margin-top: 24px;
  23. margin-bottom: 16px;
  24. line-height: 1.25;
  25. }
  26. #code-csp-warning {
  27. position: fixed;
  28. top: 0;
  29. right: 0;
  30. color: white;
  31. margin: 16px;
  32. text-align: center;
  33. font-size: 12px;
  34. font-family: sans-serif;
  35. background-color:#444444;
  36. cursor: pointer;
  37. padding: 6px;
  38. box-shadow: 1px 1px 1px rgba(0,0,0,.25);
  39. }
  40. #code-csp-warning:hover {
  41. text-decoration: none;
  42. background-color:#007acc;
  43. box-shadow: 2px 2px 2px rgba(0,0,0,.25);
  44. }
  45. body.scrollBeyondLastLine {
  46. margin-bottom: calc(100vh - 22px);
  47. }
  48. body.showEditorSelection .code-line {
  49. position: relative;
  50. }
  51. body.showEditorSelection :not(tr,ul,ol).code-active-line:before,
  52. body.showEditorSelection :not(tr,ul,ol).code-line:hover:before {
  53. content: "";
  54. display: block;
  55. position: absolute;
  56. top: 0;
  57. left: -12px;
  58. height: 100%;
  59. }
  60. .vscode-high-contrast.showEditorSelection :not(tr,ul,ol).code-line .code-line:hover:before {
  61. border-left: none;
  62. }
  63. body.showEditorSelection li.code-active-line:before,
  64. body.showEditorSelection li.code-line:hover:before {
  65. left: -30px;
  66. }
  67. .vscode-light.showEditorSelection .code-active-line:before {
  68. border-left: 3px solid rgba(0, 0, 0, 0.15);
  69. }
  70. .vscode-light.showEditorSelection .code-line:hover:before {
  71. border-left: 3px solid rgba(0, 0, 0, 0.40);
  72. }
  73. .vscode-dark.showEditorSelection .code-active-line:before {
  74. border-left: 3px solid rgba(255, 255, 255, 0.4);
  75. }
  76. .vscode-dark.showEditorSelection .code-line:hover:before {
  77. border-left: 3px solid rgba(255, 255, 255, 0.60);
  78. }
  79. .vscode-high-contrast.showEditorSelection .code-active-line:before {
  80. border-left: 3px solid rgba(255, 160, 0, 0.7);
  81. }
  82. .vscode-high-contrast.showEditorSelection .code-line:hover:before {
  83. border-left: 3px solid rgba(255, 160, 0, 1);
  84. }
  85. /* Prevent `sub` and `sup` elements from affecting line height */
  86. sub,
  87. sup {
  88. line-height: 0;
  89. }
  90. ul ul:first-child,
  91. ul ol:first-child,
  92. ol ul:first-child,
  93. ol ol:first-child {
  94. margin-bottom: 0;
  95. }
  96. img, video {
  97. max-width: 100%;
  98. max-height: 100%;
  99. }
  100. a {
  101. text-decoration: none;
  102. }
  103. a:hover {
  104. text-decoration: underline;
  105. }
  106. a:focus,
  107. input:focus,
  108. select:focus,
  109. textarea:focus {
  110. outline: 1px solid -webkit-focus-ring-color;
  111. outline-offset: -1px;
  112. }
  113. p {
  114. margin-bottom: 16px;
  115. }
  116. li p {
  117. margin-bottom: 0.7em;
  118. }
  119. ul,
  120. ol {
  121. margin-bottom: 0.7em;
  122. }
  123. hr {
  124. border: 0;
  125. height: 1px;
  126. border-bottom: 1px solid;
  127. }
  128. h1 {
  129. font-size: 2em;
  130. margin-top: 0;
  131. padding-bottom: 0.3em;
  132. border-bottom-width: 1px;
  133. border-bottom-style: solid;
  134. }
  135. h2 {
  136. font-size: 1.5em;
  137. padding-bottom: 0.3em;
  138. border-bottom-width: 1px;
  139. border-bottom-style: solid;
  140. }
  141. h3 {
  142. font-size: 1.25em;
  143. }
  144. h4 {
  145. font-size: 1em;
  146. }
  147. h5 {
  148. font-size: 0.875em;
  149. }
  150. h6 {
  151. font-size: 0.85em;
  152. }
  153. table {
  154. border-collapse: collapse;
  155. margin-bottom: 0.7em;
  156. }
  157. th {
  158. text-align: left;
  159. border-bottom: 1px solid;
  160. }
  161. th,
  162. td {
  163. padding: 5px 10px;
  164. }
  165. table > tbody > tr + tr > td {
  166. border-top: 1px solid;
  167. }
  168. blockquote {
  169. margin: 0;
  170. padding: 0px 16px 0 10px;
  171. border-left-width: 5px;
  172. border-left-style: solid;
  173. border-radius: 2px;
  174. }
  175. code {
  176. font-family: var(--vscode-editor-font-family, "SF Mono", Monaco, Menlo, Consolas, "Ubuntu Mono", "Liberation Mono", "DejaVu Sans Mono", "Courier New", monospace);
  177. font-size: 1em;
  178. line-height: 1.357em;
  179. }
  180. body.wordWrap pre {
  181. white-space: pre-wrap;
  182. }
  183. pre:not(.hljs),
  184. pre.hljs code > div {
  185. padding: 16px;
  186. border-radius: 3px;
  187. overflow: auto;
  188. }
  189. pre code {
  190. display: inline-block;
  191. color: var(--vscode-editor-foreground);
  192. tab-size: 4;
  193. background: none;
  194. }
  195. /** Theming */
  196. pre {
  197. background-color: var(--vscode-textCodeBlock-background);
  198. border: 1px solid var(--vscode-widget-border);
  199. }
  200. .vscode-high-contrast h1 {
  201. border-color: rgb(0, 0, 0);
  202. }
  203. .vscode-light th {
  204. border-color: rgba(0, 0, 0, 0.69);
  205. }
  206. .vscode-dark th {
  207. border-color: rgba(255, 255, 255, 0.69);
  208. }
  209. .vscode-light h1,
  210. .vscode-light h2,
  211. .vscode-light hr,
  212. .vscode-light td {
  213. border-color: rgba(0, 0, 0, 0.18);
  214. }
  215. .vscode-dark h1,
  216. .vscode-dark h2,
  217. .vscode-dark hr,
  218. .vscode-dark td {
  219. border-color: rgba(255, 255, 255, 0.18);
  220. }