|
| 1 | +/* PrismJS 1.30.0 |
| 2 | +https://prismjs.com/download#themes=prism-dark&languages=markup+css+clike+javascript+abap+abnf+actionscript+ada+agda+al+antlr4+apacheconf+apex+apl+applescript+aql+arduino+arff+armasm+arturo+asciidoc+aspnet+asm6502+asmatmel+autohotkey+autoit+avisynth+avro-idl+awk+bash+basic+batch+bbcode+bbj+bicep+birb+bison+bnf+bqn+brainfuck+brightscript+bro+bsl+c+csharp+cpp+cfscript+chaiscript+cil+cilkc+cilkcpp+clojure+cmake+cobol+coffeescript+concurnas+csp+cooklang+coq+crystal+css-extras+csv+cue+cypher+d+dart+dataweave+dax+dhall+diff+django+dns-zone-file+docker+dot+ebnf+editorconfig+eiffel+ejs+elixir+elm+etlua+erb+erlang+excel-formula+fsharp+factor+false+firestore-security-rules+flow+fortran+ftl+gml+gap+gcode+gdscript+gedcom+gettext+gherkin+git+glsl+gn+linker-script+go+go-module+gradle+graphql+groovy+haml+handlebars+haskell+haxe+hcl+hlsl+hoon+http+hpkp+hsts+ichigojam+icon+icu-message-format+idris+ignore+inform7+ini+io+j+java+javadoc+javadoclike+javastacktrace+jexl+jolie+jq+jsdoc+js-extras+json+json5+jsonp+jsstacktrace+js-templates+julia+keepalived+keyman+kotlin+kumir+kusto+latex+latte+less+lilypond+liquid+lisp+livescript+llvm+log+lolcode+lua+magma+makefile+markdown+markup-templating+mata+matlab+maxscript+mel+mermaid+metafont+mizar+mongodb+monkey+moonscript+n1ql+n4js+nand2tetris-hdl+naniscript+nasm+neon+nevod+nginx+nim+nix+nsis+objectivec+ocaml+odin+opencl+openqasm+oz+parigp+parser+pascal+pascaligo+psl+pcaxis+peoplecode+perl+php+phpdoc+php-extras+plant-uml+plsql+powerquery+powershell+processing+prolog+promql+properties+protobuf+pug+puppet+pure+purebasic+purescript+python+qsharp+q+qml+qore+r+racket+cshtml+jsx+tsx+reason+regex+rego+renpy+rescript+rest+rip+roboconf+robotframework+ruby+rust+sas+sass+scss+scala+scheme+shell-session+smali+smalltalk+smarty+sml+solidity+solution-file+soy+sparql+splunk-spl+sqf+sql+squirrel+stan+stata+iecst+stylus+supercollider+swift+systemd+t4-templating+t4-cs+t4-vb+tap+tcl+tt2+textile+toml+tremor+turtle+twig+typescript+typoscript+unrealscript+uorazor+uri+v+vala+vbnet+velocity+verilog+vhdl+vim+visual-basic+warpscript+wasm+web-idl+wgsl+wiki+wolfram+wren+xeora+xml-doc+xojo+xquery+yaml+yang+zig&plugins=line-numbers+show-language+inline-color+toolbar+copy-to-clipboard+download-button */ |
| 3 | +/** |
| 4 | + * prism.js Dark theme for JavaScript, CSS and HTML |
| 5 | + * Based on the slides of the talk “/Reg(exp){2}lained/” |
| 6 | + * @author Lea Verou |
| 7 | + */ |
| 8 | + |
| 9 | +@font-face { |
| 10 | + font-family: "JetBrains Mono"; |
| 11 | + src: url("JetBrainsMono.ttf") format("truetype"); |
| 12 | +} |
| 13 | + |
| 14 | +code[class*="language-"], |
| 15 | +pre[class*="language-"] { |
| 16 | + color: white; |
| 17 | + background: none; |
| 18 | + text-shadow: 0 -.1em .2em black; |
| 19 | + font-size: 1em; |
| 20 | + text-align: left; |
| 21 | + font-family: "JetBrains Mono"; |
| 22 | + white-space: pre; |
| 23 | + word-spacing: normal; |
| 24 | + word-break: normal; |
| 25 | + word-wrap: normal; |
| 26 | + line-height: 1.5; |
| 27 | + |
| 28 | + -moz-tab-size: 4; |
| 29 | + -o-tab-size: 4; |
| 30 | + tab-size: 4; |
| 31 | + |
| 32 | + -webkit-hyphens: none; |
| 33 | + -moz-hyphens: none; |
| 34 | + -ms-hyphens: none; |
| 35 | + hyphens: none; |
| 36 | +} |
| 37 | + |
| 38 | +@media print { |
| 39 | + code[class*="language-"], |
| 40 | + pre[class*="language-"] { |
| 41 | + text-shadow: none; |
| 42 | + } |
| 43 | +} |
| 44 | + |
| 45 | +pre[class*="language-"], |
| 46 | +:not(pre) > code[class*="language-"] { |
| 47 | + background: rgba(0,0,0,50%); |
| 48 | +} |
| 49 | + |
| 50 | +/* Code blocks */ |
| 51 | +pre[class*="language-"] { |
| 52 | + padding: 1em; |
| 53 | + margin: .5em 0; |
| 54 | + overflow: auto; |
| 55 | + /* border: .3em solid hsl(30, 20%, 40%); */ |
| 56 | + border-radius: .5em; |
| 57 | + /* box-shadow: 1px 1px .5em black inset; */ |
| 58 | +} |
| 59 | + |
| 60 | +/* Inline code */ |
| 61 | +:not(pre) > code[class*="language-"] { |
| 62 | + padding: .15em .2em .05em; |
| 63 | + border-radius: .3em; |
| 64 | + border: .13em solid hsl(30, 20%, 40%); |
| 65 | + box-shadow: 1px 1px .3em -.1em black inset; |
| 66 | + white-space: normal; |
| 67 | +} |
| 68 | + |
| 69 | +.token.comment, |
| 70 | +.token.prolog, |
| 71 | +.token.doctype, |
| 72 | +.token.cdata { |
| 73 | + color: hsl(30, 20%, 50%); |
| 74 | +} |
| 75 | + |
| 76 | +.token.punctuation { |
| 77 | + opacity: .7; |
| 78 | +} |
| 79 | + |
| 80 | +.token.namespace { |
| 81 | + opacity: .7; |
| 82 | +} |
| 83 | + |
| 84 | +.token.property, |
| 85 | +.token.tag, |
| 86 | +.token.boolean, |
| 87 | +.token.number, |
| 88 | +.token.constant, |
| 89 | +.token.symbol { |
| 90 | + color: hsl(350, 40%, 70%); |
| 91 | +} |
| 92 | + |
| 93 | +.token.selector, |
| 94 | +.token.attr-name, |
| 95 | +.token.string, |
| 96 | +.token.char, |
| 97 | +.token.builtin, |
| 98 | +.token.inserted { |
| 99 | + color: hsl(75, 70%, 60%); |
| 100 | +} |
| 101 | + |
| 102 | +.token.operator, |
| 103 | +.token.entity, |
| 104 | +.token.url, |
| 105 | +.language-css .token.string, |
| 106 | +.style .token.string, |
| 107 | +.token.variable { |
| 108 | + color: hsl(40, 90%, 60%); |
| 109 | +} |
| 110 | + |
| 111 | +.token.atrule, |
| 112 | +.token.attr-value, |
| 113 | +.token.keyword { |
| 114 | + color: hsl(350, 40%, 70%); |
| 115 | +} |
| 116 | + |
| 117 | +.token.regex, |
| 118 | +.token.important { |
| 119 | + color: #e90; |
| 120 | +} |
| 121 | + |
| 122 | +.token.important, |
| 123 | +.token.bold { |
| 124 | + font-weight: bold; |
| 125 | +} |
| 126 | +.token.italic { |
| 127 | + font-style: italic; |
| 128 | +} |
| 129 | + |
| 130 | +.token.entity { |
| 131 | + cursor: help; |
| 132 | +} |
| 133 | + |
| 134 | +.token.deleted { |
| 135 | + color: red; |
| 136 | +} |
| 137 | + |
| 138 | +pre[class*="language-"].line-numbers { |
| 139 | + position: relative; |
| 140 | + padding-left: 3.8em; |
| 141 | + counter-reset: linenumber; |
| 142 | +} |
| 143 | + |
| 144 | +pre[class*="language-"].line-numbers > code { |
| 145 | + position: relative; |
| 146 | + white-space: inherit; |
| 147 | +} |
| 148 | + |
| 149 | +.line-numbers .line-numbers-rows { |
| 150 | + position: absolute; |
| 151 | + pointer-events: none; |
| 152 | + top: 0; |
| 153 | + font-size: 100%; |
| 154 | + left: -3.8em; |
| 155 | + width: 3em; /* works for line-numbers below 1000 lines */ |
| 156 | + letter-spacing: -1px; |
| 157 | + border-right: 1px solid #999; |
| 158 | + |
| 159 | + -webkit-user-select: none; |
| 160 | + -moz-user-select: none; |
| 161 | + -ms-user-select: none; |
| 162 | + user-select: none; |
| 163 | + |
| 164 | +} |
| 165 | + |
| 166 | + .line-numbers-rows > span { |
| 167 | + display: block; |
| 168 | + counter-increment: linenumber; |
| 169 | + } |
| 170 | + |
| 171 | + .line-numbers-rows > span:before { |
| 172 | + content: counter(linenumber); |
| 173 | + color: #999; |
| 174 | + display: block; |
| 175 | + padding-right: 0.8em; |
| 176 | + text-align: right; |
| 177 | + } |
| 178 | + |
| 179 | +div.code-toolbar { |
| 180 | + position: relative; |
| 181 | +} |
| 182 | + |
| 183 | +div.code-toolbar > .toolbar { |
| 184 | + position: absolute; |
| 185 | + z-index: 10; |
| 186 | + top: .3em; |
| 187 | + right: .2em; |
| 188 | + transition: opacity 0.3s ease-in-out; |
| 189 | + opacity: 0; |
| 190 | +} |
| 191 | + |
| 192 | +div.code-toolbar:hover > .toolbar { |
| 193 | + opacity: 1; |
| 194 | +} |
| 195 | + |
| 196 | +/* Separate line b/c rules are thrown out if selector is invalid. |
| 197 | + IE11 and old Edge versions don't support :focus-within. */ |
| 198 | +div.code-toolbar:focus-within > .toolbar { |
| 199 | + opacity: 1; |
| 200 | +} |
| 201 | + |
| 202 | +div.code-toolbar > .toolbar > .toolbar-item { |
| 203 | + display: inline-block; |
| 204 | +} |
| 205 | + |
| 206 | +div.code-toolbar > .toolbar > .toolbar-item > a { |
| 207 | + cursor: pointer; |
| 208 | +} |
| 209 | + |
| 210 | +div.code-toolbar > .toolbar > .toolbar-item > button { |
| 211 | + background: none; |
| 212 | + border: 0; |
| 213 | + color: inherit; |
| 214 | + font: inherit; |
| 215 | + line-height: normal; |
| 216 | + overflow: visible; |
| 217 | + padding: 0; |
| 218 | + -webkit-user-select: none; /* for button */ |
| 219 | + -moz-user-select: none; |
| 220 | + -ms-user-select: none; |
| 221 | +} |
| 222 | + |
| 223 | +div.code-toolbar > .toolbar > .toolbar-item > a, |
| 224 | +div.code-toolbar > .toolbar > .toolbar-item > button, |
| 225 | +div.code-toolbar > .toolbar > .toolbar-item > span { |
| 226 | + color: #bbb; |
| 227 | + font-size: .8em; |
| 228 | + padding: 0 .5em; |
| 229 | + background: #f5f2f0; |
| 230 | + background: rgba(224, 224, 224, 0.2); |
| 231 | + box-shadow: 0 2px 0 0 rgba(0,0,0,0.2); |
| 232 | + border-radius: .5em; |
| 233 | +} |
| 234 | + |
| 235 | +div.code-toolbar > .toolbar > .toolbar-item > a:hover, |
| 236 | +div.code-toolbar > .toolbar > .toolbar-item > a:focus, |
| 237 | +div.code-toolbar > .toolbar > .toolbar-item > button:hover, |
| 238 | +div.code-toolbar > .toolbar > .toolbar-item > button:focus, |
| 239 | +div.code-toolbar > .toolbar > .toolbar-item > span:hover, |
| 240 | +div.code-toolbar > .toolbar > .toolbar-item > span:focus { |
| 241 | + color: inherit; |
| 242 | + text-decoration: none; |
| 243 | +} |
| 244 | + |
| 245 | +span.inline-color-wrapper { |
| 246 | + /* |
| 247 | + * The background image is the following SVG inline in base 64: |
| 248 | + * |
| 249 | + * <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 2 2"> |
| 250 | + * <path fill="gray" d="M0 0h2v2H0z"/> |
| 251 | + * <path fill="white" d="M0 0h1v1H0zM1 1h1v1H1z"/> |
| 252 | + * </svg> |
| 253 | + * |
| 254 | + * SVG-inlining explained: |
| 255 | + * https://stackoverflow.com/a/21626701/7595472 |
| 256 | + */ |
| 257 | + background: url("data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAyIDIiPjxwYXRoIGZpbGw9ImdyYXkiIGQ9Ik0wIDBoMnYySDB6Ii8+PHBhdGggZmlsbD0id2hpdGUiIGQ9Ik0wIDBoMXYxSDB6TTEgMWgxdjFIMXoiLz48L3N2Zz4="); |
| 258 | + /* This is to prevent visual glitches where one pixel from the repeating pattern could be seen. */ |
| 259 | + background-position: center; |
| 260 | + background-size: 110%; |
| 261 | + |
| 262 | + display: inline-block; |
| 263 | + height: 1.333ch; |
| 264 | + width: 1.333ch; |
| 265 | + margin: 0 .333ch; |
| 266 | + box-sizing: border-box; |
| 267 | + border: 1px solid white; |
| 268 | + /* outline: 1px solid rgba(0,0,0,.5); */ |
| 269 | + overflow: hidden; |
| 270 | +} |
| 271 | + |
| 272 | +span.inline-color { |
| 273 | + display: block; |
| 274 | + /* To prevent visual glitches again */ |
| 275 | + height: 120%; |
| 276 | + width: 120%; |
| 277 | +} |
| 278 | + |
0 commit comments