Browse Source

style: add dark style for `pre` and `code` (#6382)

pull/6414/head
Konv Suu 2 years ago committed by GitHub
parent
commit
9dbe035efe
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 16
      site/src/theme/static/highlight.dark.less
  2. 1
      site/src/theme/static/index.less

16
site/src/theme/static/highlight.dark.less

@ -0,0 +1,16 @@
html[data-doc-theme='dark'] {
pre code {
background: #262626;
border-color: #262626;
}
code[class*='language-'],
pre[class*='language-'] {
color: black;
}
:not(pre) > code[class*='language-'],
pre[class*='language-'] {
background: #262626;
}
}

1
site/src/theme/static/index.less

@ -9,6 +9,7 @@
@import './toc';
@import './not-found';
@import './highlight';
@import './highlight.dark';
@import './demo';
@import './icons';
@import './mock-browser';

Loading…
Cancel
Save