Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 17 additions & 3 deletions src/components/scroll/Scroll.css.ts
Original file line number Diff line number Diff line change
Expand Up @@ -87,15 +87,25 @@ export const Scroll = recipe({
},
size: {
"0": {
scrollbarWidth: "none",
"@supports": {
"(scrollbar-color: transparent transparent)": {
scrollbarWidth: "none",
},
},
selectors: {
"&::-webkit-scrollbar": {
display: "none",
},
},
},
"300": {
scrollbarWidth: "thin",
"@supports": {
"(scrollbar-color: transparent transparent)": {
// only apply scrollbarWidth if scrollbar-color is supported,
// otherwise it breaks the colors in some browser like safari.
scrollbarWidth: "thin",
},
},
selectors: {
"&::-webkit-scrollbar": {
width: toRem(8),
Expand All @@ -108,7 +118,11 @@ export const Scroll = recipe({
},
},
"400": {
scrollbarWidth: "auto",
"@supports": {
"(scrollbar-color: transparent transparent)": {
scrollbarWidth: "auto",
},
},
selectors: {
"&::-webkit-scrollbar": {
width: toRem(16),
Expand Down
Loading