4.2.0 (#530)
* revamp code highlighting * replace standard Fira Code with a variable version * change buttons arrows * redesign code blocks * make terminal logo more prominent * separate terminal theme styles from terminal.css Terminal.css styles only can change the color scheme. * update docs and version * remove USERS.md * fix header pattern * remove old prismjs shortcode * remove old rss template * remove old figure shortcode * [chore] update yarn LOL, I'm still using 1.22.x * [chore] update package-lock.json * fix pagination & boost meta visibility * fix code blocks on mobile & move some parts from CSS to JS
This commit is contained in:
parent
c7770bc85e
commit
3f87c12098
34 changed files with 4747 additions and 6686 deletions
|
@ -1,115 +1,97 @@
|
|||
code.language-css,
|
||||
code.language-scss,
|
||||
.token.boolean,
|
||||
.token.string,
|
||||
.token.entity,
|
||||
.token.url,
|
||||
.language-css .token.string,
|
||||
.language-scss .token.string,
|
||||
.style .token.string,
|
||||
.token.attr-value,
|
||||
.token.keyword,
|
||||
.token.control,
|
||||
.token.directive,
|
||||
.token.statement,
|
||||
.token.regex,
|
||||
.token.atrule,
|
||||
.token.number,
|
||||
.token.inserted,
|
||||
.token.important {
|
||||
color: var(--accent) !important;
|
||||
:root {
|
||||
--first-tone: var(--accent);
|
||||
--second-tone: color-mix(in srgb, var(--accent) 70%, transparent);
|
||||
--comment: color-mix(in srgb, var(--foreground) 50%, transparent);
|
||||
}
|
||||
|
||||
.token.tag-id,
|
||||
.token.atrule-id,
|
||||
.token.operator,
|
||||
.token.unit,
|
||||
.token.placeholder,
|
||||
.token.variable,
|
||||
.token.attr-name,
|
||||
.token.namespace,
|
||||
.token.deleted,
|
||||
.token.property,
|
||||
.token.class-name,
|
||||
.token.constant,
|
||||
.token.symbol {
|
||||
color: color-mix(in srgb, var(--accent) 70%, transparent) !important;
|
||||
}
|
||||
/* Background */ .bg { }
|
||||
/* PreWrapper */ .chroma { overflow:auto; }
|
||||
/* Other */ .chroma .x { }
|
||||
/* Error */ .chroma .err { }
|
||||
/* CodeLine */ .chroma .cl { }
|
||||
/* LineLink */ .chroma .lnlinks { outline:none;text-decoration:none;color:inherit }
|
||||
/* LineTableTD */ .chroma .lntd { width:100%;vertical-align:top;padding:0;margin:0;border:0; }
|
||||
/* LineTableTDNumbers */ .chroma .lntd:first-child { width: auto; }
|
||||
/* Custom */ .chroma .lntd code { display:grid; }
|
||||
/* LineTable */ .chroma .lntable { width:100%;border-spacing:0;padding:0;margin:0;border:0; }
|
||||
/* LineHighlight */ .chroma .hl { background-color:color-mix(in srgb, var(--foreground) 5%, transparent) !important}
|
||||
/* LineNumbersTable */ .chroma .lnt { color:var(--comment);white-space:pre;-webkit-user-select:none;user-select:none;padding:0 10px; }
|
||||
/* LineNumbers */ .chroma .ln { color:var(--comment);white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.8em;padding:0 0.4em 0 0; }
|
||||
/* Line */ .chroma .line { display:flex;padding:0 10px; }
|
||||
/* Keyword */ .chroma .k { color:var(--second-tone) }
|
||||
/* KeywordConstant */ .chroma .kc { color:var(--second-tone) }
|
||||
/* KeywordDeclaration */ .chroma .kd { color:var(--second-tone) }
|
||||
/* KeywordNamespace */ .chroma .kn { color:var(--second-tone) }
|
||||
/* KeywordPseudo */ .chroma .kp { color:var(--second-tone) }
|
||||
/* KeywordReserved */ .chroma .kr { color:var(--second-tone) }
|
||||
/* KeywordType */ .chroma .kt { color:var(--second-tone) }
|
||||
/* Name */ .chroma .n { color:var(--first-tone) }
|
||||
/* NameAttribute */ .chroma .na { color:var(--second-tone) }
|
||||
/* NameBuiltin */ .chroma .nb { color:var(--first-tone) }
|
||||
/* NameBuiltinPseudo */ .chroma .bp { color:var(--first-tone) }
|
||||
/* NameClass */ .chroma .nc { color:var(--foreground) }
|
||||
/* NameConstant */ .chroma .no { color:var(--first-tone) }
|
||||
/* NameDecorator */ .chroma .nd { color:var(--first-tone) }
|
||||
/* NameEntity */ .chroma .ni { color:var(--first-tone) }
|
||||
/* NameException */ .chroma .ne { color:var(--first-tone) }
|
||||
/* NameFunction */ .chroma .nf { color:var(--first-tone); }
|
||||
/* NameFunctionMagic */ .chroma .fm { color:var(--first-tone); }
|
||||
/* NameLabel */ .chroma .nl { color:var(--first-tone) }
|
||||
/* NameNamespace */ .chroma .nn { color:var(--first-tone) }
|
||||
/* NameOther */ .chroma .nx { color:var(--first-tone) }
|
||||
/* NameProperty */ .chroma .py { color:var(--first-tone) }
|
||||
/* NameTag */ .chroma .nt { color:var(--first-tone) }
|
||||
/* NameVariable */ .chroma .nv { color:var(--first-tone) }
|
||||
/* NameVariableClass */ .chroma .vc { color:var(--first-tone) }
|
||||
/* NameVariableGlobal */ .chroma .vg { color:var(--first-tone) }
|
||||
/* NameVariableInstance */ .chroma .vi { color:var(--first-tone) }
|
||||
/* NameVariableMagic */ .chroma .vm { color:var(--first-tone) }
|
||||
/* Literal */ .chroma .l { }
|
||||
/* LiteralDate */ .chroma .ld { }
|
||||
/* LiteralString */ .chroma .s { color:var(--foreground) }
|
||||
/* LiteralStringAffix */ .chroma .sa { color:var(--foreground) }
|
||||
/* LiteralStringBacktick */ .chroma .sb { color:var(--foreground) }
|
||||
/* LiteralStringChar */ .chroma .sc { color:var(--foreground) }
|
||||
/* LiteralStringDelimiter */ .chroma .dl { color:var(--foreground) }
|
||||
/* LiteralStringDoc */ .chroma .sd { color:var(--foreground) }
|
||||
/* LiteralStringDouble */ .chroma .s2 { color:var(--foreground) }
|
||||
/* LiteralStringEscape */ .chroma .se { color:var(--foreground) }
|
||||
/* LiteralStringHeredoc */ .chroma .sh { color:var(--foreground) }
|
||||
/* LiteralStringInterpol */ .chroma .si { color:var(--foreground) }
|
||||
/* LiteralStringOther */ .chroma .sx { color:var(--foreground) }
|
||||
/* LiteralStringRegex */ .chroma .sr { color:var(--foreground) }
|
||||
/* LiteralStringSingle */ .chroma .s1 { color:var(--foreground) }
|
||||
/* LiteralStringSymbol */ .chroma .ss { color:var(--foreground) }
|
||||
/* LiteralNumber */ .chroma .m { color:var(--first-tone) }
|
||||
/* LiteralNumberBin */ .chroma .mb { color:var(--first-tone) }
|
||||
/* LiteralNumberFloat */ .chroma .mf { color:var(--first-tone) }
|
||||
/* LiteralNumberHex */ .chroma .mh { color:var(--first-tone) }
|
||||
/* LiteralNumberInteger */ .chroma .mi { color:var(--first-tone) }
|
||||
/* LiteralNumberIntegerLong */ .chroma .il { color:var(--first-tone) }
|
||||
/* LiteralNumberOct */ .chroma .mo { color:var(--first-tone) }
|
||||
/* Operator */ .chroma .o { color:var(--foreground) }
|
||||
/* OperatorWord */ .chroma .ow { color:var(--foreground) }
|
||||
/* Punctuation */ .chroma .p { color:var(--foreground) }
|
||||
/* Comment */ .chroma .c { color:var(--comment) }
|
||||
/* CommentHashbang */ .chroma .ch { color:var(--comment) }
|
||||
/* CommentMultiline */ .chroma .cm { color:var(--comment) }
|
||||
/* CommentSingle */ .chroma .c1 { color:var(--comment) }
|
||||
/* CommentSpecial */ .chroma .cs { color:var(--comment) }
|
||||
/* CommentPreproc */ .chroma .cp { color:var(--comment) }
|
||||
/* CommentPreprocFile */ .chroma .cpf { color:var(--comment) }
|
||||
/* Generic */ .chroma .g { }
|
||||
/* GenericDeleted */ .chroma .gd { color:var(--first-tone) }
|
||||
/* GenericEmph */ .chroma .ge { }
|
||||
/* GenericError */ .chroma .gr { }
|
||||
/* GenericHeading */ .chroma .gh { }
|
||||
/* GenericInserted */ .chroma .gi { color:var(--second-tone); }
|
||||
/* GenericOutput */ .chroma .go { }
|
||||
/* GenericPrompt */ .chroma .gp { }
|
||||
/* GenericStrong */ .chroma .gs { }
|
||||
/* GenericSubheading */ .chroma .gu { }
|
||||
/* GenericTraceback */ .chroma .gt { }
|
||||
/* GenericUnderline */ .chroma .gl { }
|
||||
/* TextWhitespace */ .chroma .w { }
|
||||
|
||||
.token.property,
|
||||
.token.function,
|
||||
.token.function-name,
|
||||
.token.deleted,
|
||||
code.language-javascript,
|
||||
code.language-html,
|
||||
.command-line-prompt > span::before {
|
||||
color: var(--accent) !important;
|
||||
}
|
||||
|
||||
.token.selector,
|
||||
.token.tag,
|
||||
.token.punctuation {
|
||||
color: color-mix(in srgb, var(--accent) 50%, var(--foreground)) !important;
|
||||
}
|
||||
|
||||
.token.comment,
|
||||
.token.prolog,
|
||||
.token.doctype,
|
||||
.token.cdata {
|
||||
color: color-mix(in srgb, var(--foreground) 30%, transparent) !important;
|
||||
}
|
||||
|
||||
.token.namespace {
|
||||
opacity: 0.7 !important;
|
||||
}
|
||||
|
||||
pre[data-line] {
|
||||
position: relative;
|
||||
}
|
||||
|
||||
pre[class*=language-] {
|
||||
margin: 0;
|
||||
overflow: auto;
|
||||
}
|
||||
|
||||
.line-highlight {
|
||||
position: absolute;
|
||||
left: 0;
|
||||
right: 0;
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
background: color-mix(in srgb, var(--foreground) 7%, transparent);
|
||||
pointer-events: none;
|
||||
line-height: inherit;
|
||||
white-space: pre;
|
||||
}
|
||||
|
||||
.line-highlight::before,
|
||||
.line-highlight[data-end]::after {
|
||||
content: attr(data-start);
|
||||
position: absolute;
|
||||
|
||||
/* top: .4em; */
|
||||
left: 0.6em;
|
||||
min-width: 1em;
|
||||
padding: 0 0.5em;
|
||||
background-color: color-mix(in srgb, var(--foreground) 40%, transparent);
|
||||
color: var(--foreground);
|
||||
font: bold 65%/1.5 sans-serif;
|
||||
text-align: center;
|
||||
vertical-align: 0.3em;
|
||||
border-radius: 999px;
|
||||
text-shadow: none;
|
||||
box-shadow: 0 1px var(--foreground);
|
||||
}
|
||||
|
||||
.line-highlight[data-end]::after {
|
||||
content: attr(data-end);
|
||||
top: auto;
|
||||
bottom: 0.4em;
|
||||
}
|
||||
|
||||
.line-numbers .line-highlight::before,
|
||||
.line-numbers .line-highlight::after {
|
||||
content: none;
|
||||
}
|
||||
/* LANGUAGE FIXES */
|
||||
/* PHP CommentPreproc */ .chroma .language-php .cp { color:var(--foreground) }
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue