Skip to content

Commit 406c89f

Browse files
committed
docs: knock back body color
1 parent 9ad26a9 commit 406c89f

1 file changed

Lines changed: 66 additions & 0 deletions

File tree

docs/reference.css

Lines changed: 66 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,8 @@
55
--dark-color-background: lab(2.75381% 0 0);
66
--dark-color-background-secondary: lab(2.75381% 0 0);
77
--dark-color-accent: lab(100% 0 0/.1);
8+
--reference-dark-body-text: lab(86% 0 0);
9+
--reference-light-body-text: lab(40% 0 0);
810
--dim-footer-height: 0px;
911
--dim-toolbar-contents-height: 3.5rem;
1012
--dim-container-main-margin-y: 0px;
@@ -64,6 +66,70 @@ footer, .tsd-filter-visibility {
6466
margin-bottom: var(--reference-nav-item-padding-y);
6567
}
6668

69+
@media (prefers-color-scheme: dark) {
70+
:root:not([data-theme="light"]) .col-content,
71+
:root:not([data-theme="light"]) .site-menu,
72+
:root:not([data-theme="light"]) .page-menu,
73+
:root:not([data-theme="light"]) #tsd-sidebar-links {
74+
--color-text: var(--reference-dark-body-text);
75+
}
76+
77+
:root:not([data-theme="light"]) .col-content {
78+
color: var(--reference-dark-body-text);
79+
}
80+
81+
:root:not([data-theme="light"]) .col-content :is(h1, h2, h3, h4, h5, h6) {
82+
color: var(--dark-color-text);
83+
}
84+
}
85+
86+
:root[data-theme="dark"] .col-content,
87+
:root[data-theme="dark"] .site-menu,
88+
:root[data-theme="dark"] .page-menu,
89+
:root[data-theme="dark"] #tsd-sidebar-links {
90+
--color-text: var(--reference-dark-body-text);
91+
}
92+
93+
:root[data-theme="dark"] .col-content {
94+
color: var(--reference-dark-body-text);
95+
}
96+
97+
:root[data-theme="dark"] .col-content :is(h1, h2, h3, h4, h5, h6) {
98+
color: var(--dark-color-text);
99+
}
100+
101+
@media (prefers-color-scheme: light) {
102+
:root:not([data-theme="dark"]) .col-content,
103+
:root:not([data-theme="dark"]) .site-menu,
104+
:root:not([data-theme="dark"]) .page-menu,
105+
:root:not([data-theme="dark"]) #tsd-sidebar-links {
106+
--color-text: var(--reference-light-body-text);
107+
}
108+
109+
:root:not([data-theme="dark"]) .col-content {
110+
color: var(--reference-light-body-text);
111+
}
112+
113+
:root:not([data-theme="dark"]) .col-content :is(h1, h2, h3, h4, h5, h6) {
114+
color: var(--light-color-text);
115+
}
116+
}
117+
118+
:root[data-theme="light"] .col-content,
119+
:root[data-theme="light"] .site-menu,
120+
:root[data-theme="light"] .page-menu,
121+
:root[data-theme="light"] #tsd-sidebar-links {
122+
--color-text: var(--reference-light-body-text);
123+
}
124+
125+
:root[data-theme="light"] .col-content {
126+
color: var(--reference-light-body-text);
127+
}
128+
129+
:root[data-theme="light"] .col-content :is(h1, h2, h3, h4, h5, h6) {
130+
color: var(--light-color-text);
131+
}
132+
67133
@media (min-width: 770px) {
68134
/* TypeDoc re-applies this at desktop breakpoints — override in the same query */
69135
.container-main {

0 commit comments

Comments
 (0)