File tree Expand file tree Collapse file tree 1 file changed +15
-7
lines changed Expand file tree Collapse file tree 1 file changed +15
-7
lines changed Original file line number Diff line number Diff line change @@ -115,16 +115,24 @@ export const darkTheme = {
115
115
116
116
/* In dark theme, we need to override the scrollbars or they stick out like a sore thumb */
117
117
globalCss : styledComponents . css `
118
- ::-webkit-scrollbar {
119
- background-color: ${ p => polished . darken ( 0.2 , p . theme . containerBackground ) } ;
118
+ @supports (color-scheme: dark) {
119
+ :root {
120
+ color-scheme: dark;
121
+ }
120
122
}
121
123
122
- ::-webkit-scrollbar-thumb {
123
- background-color: ${ p => polished . lighten ( 0.2 , p . theme . containerBackground ) } ;
124
- }
124
+ @supports not (color-scheme: dark) {
125
+ ::-webkit-scrollbar {
126
+ background-color: ${ p => polished . darken ( 0.2 , p . theme . containerBackground ) } ;
127
+ }
125
128
126
- /* Standard, but poorly supported: */
127
- scrollbar-color: dark;
129
+ ::-webkit-scrollbar-thumb {
130
+ background-color: ${ p => polished . lighten ( 0.2 , p . theme . containerBackground ) } ;
131
+ }
132
+
133
+ /* Standard, but poorly supported: */
134
+ scrollbar-color: dark;
135
+ }
128
136
`
129
137
} ;
130
138
You can’t perform that action at this time.
0 commit comments