|
55 | 55 | padding: 0.5em;
|
56 | 56 | margin-bottom: 1em;
|
57 | 57 | }
|
| 58 | + |
| 59 | + |
| 60 | +/* ================================================================== |
| 61 | + HLJS CODE BLOCKS |
| 62 | +================================================================== */ |
| 63 | + |
| 64 | +.hljs { |
| 65 | + position: relative; |
| 66 | + font-size: var(--small); |
| 67 | + line-height: 1.35em; |
| 68 | + border-radius: 10px; |
| 69 | +} |
| 70 | + |
| 71 | +.hljs-meta { font-weight: bold;} |
| 72 | + |
| 73 | +/* Use colors from theme specified in style.html */ |
| 74 | +.hljs-meta.prompt_ {color: #7ee787;} |
| 75 | +.hljs-meta.help_ {color: #f2cc60;} |
| 76 | +.hljs-meta.shell_ {color: #ff7b72;} |
| 77 | +.hljs-meta.infiltrator_ {color: #ffa657;} |
| 78 | +.hljs-meta.debugger_ {color: #ffa657;} |
| 79 | +.hljs-meta.debuggereval_ {color: #ffa657;} |
| 80 | + |
| 81 | +/* Add language name to code blocks */ |
| 82 | +.hljs::before { |
| 83 | + content: ""; |
| 84 | + position: absolute; |
| 85 | + top: 0; |
| 86 | + left: 0; |
| 87 | + padding: 0.2rem 0.5rem 0.1rem; |
| 88 | + background-color: #27303c; /* brighter than #0d1117 */ |
| 89 | + border-bottom-right-radius:10px; |
| 90 | + font-size: 0.7rem; |
| 91 | + font-weight: 700; |
| 92 | + text-transform: uppercase; |
| 93 | +} |
| 94 | + |
| 95 | +/* Define language names shown in code blocks */ |
| 96 | +.language-bash::before {content: "Shell";} |
| 97 | +.language-toml::before {content: "TOML";} |
| 98 | +.language-julia::before {content: "Julia";} |
| 99 | +/* Special Franklin tags for Julia REPL modes */ |
| 100 | +.language-julia-repl::before {content: "Julia REPL";} |
| 101 | +.julia-repl::before {content: "Julia REPL";} |
| 102 | +.julia-repl-pkg::before {content: "Julia REPL: Pkg mode";} |
| 103 | +.julia-repl-help::before {content: "Julia REPL: Help mode";} |
| 104 | +.julia-repl-shell::before {content: "Julia REPL: Shell mode";} |
| 105 | +/* Julia code after REPL prompts doesn't need a language tag */ |
| 106 | +.language-julia-repl .language-julia::before {content: "";} |
| 107 | +.julia-repl .language-julia::before {content: "";} |
| 108 | +.julia-repl-pkg .language-julia::before {content: "";} |
| 109 | +.julia-repl-help .language-julia::before {content: "";} |
| 110 | +.julia-repl-shell .language-julia::before {content: "";} |
| 111 | +/* Julia code in doc strings printed via REPL Help mode is sometimes incorrectly |
| 112 | +recognized as Ruby code. Since we don't have any Ruby code in MJW, this is a quick fix. |
| 113 | +TODO: remove when not required in Xranklin. |
| 114 | +*/ |
| 115 | +.language-ruby::before {content: "Julia";} |
0 commit comments