fix(a11y): improve inline code contrast in light theme (#9058)
This commit is contained in:
@@ -183,6 +183,8 @@
|
|||||||
--text-inverse: var(--color-white);
|
--text-inverse: var(--color-white);
|
||||||
--text-danger: var(--color-red-200);
|
--text-danger: var(--color-red-200);
|
||||||
|
|
||||||
|
--color-inline-code: #c2410c;
|
||||||
|
|
||||||
/* Search highlighting */
|
/* Search highlighting */
|
||||||
--highlight-color: rgba(255, 213, 0, 0.5);
|
--highlight-color: rgba(255, 213, 0, 0.5);
|
||||||
--highlight-current: rgba(252, 213, 3, 0.6);
|
--highlight-current: rgba(252, 213, 3, 0.6);
|
||||||
@@ -208,6 +210,8 @@
|
|||||||
--text-inverse: var(--color-black);
|
--text-inverse: var(--color-black);
|
||||||
--text-danger: var(--color-red-100);
|
--text-danger: var(--color-red-100);
|
||||||
|
|
||||||
|
--color-inline-code: #ff7235;
|
||||||
|
|
||||||
/* Search highlighting */
|
/* Search highlighting */
|
||||||
--highlight-color: rgba(255, 213, 0, 0.5);
|
--highlight-color: rgba(255, 213, 0, 0.5);
|
||||||
--highlight-current: rgba(252, 213, 3, 0.6);
|
--highlight-current: rgba(252, 213, 3, 0.6);
|
||||||
@@ -551,12 +555,18 @@ body {
|
|||||||
|
|
||||||
.bg-inline-code {
|
.bg-inline-code {
|
||||||
border-radius: 4px;
|
border-radius: 4px;
|
||||||
color: var(--color-neutral-200);
|
color: var(--color-inline-code);
|
||||||
|
background-color: var(--color-neutral-50);
|
||||||
font-family: monospace;
|
font-family: monospace;
|
||||||
font-size: 12px;
|
font-size: 12px;
|
||||||
font-style: normal;
|
font-style: normal;
|
||||||
font-weight: 400;
|
font-weight: 400;
|
||||||
line-height: normal;
|
line-height: normal;
|
||||||
|
padding: 2px 4px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.dark .bg-inline-code {
|
||||||
|
background-color: var(--color-neutral-900);
|
||||||
}
|
}
|
||||||
|
|
||||||
.bg-inline-code:before {
|
.bg-inline-code:before {
|
||||||
@@ -567,12 +577,6 @@ pre:has(> code.bg-inline-code) {
|
|||||||
padding: 1em;
|
padding: 1em;
|
||||||
}
|
}
|
||||||
|
|
||||||
li > code.bg-inline-code,
|
|
||||||
p > code.bg-inline-code {
|
|
||||||
color: var(--color-block-orange);
|
|
||||||
padding: 2px 4px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.bg-inline-code:after {
|
.bg-inline-code:after {
|
||||||
content: '';
|
content: '';
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user