Skip to content

Commit

Permalink
šŸ›Autocomplete: Firefox scrollbar clipping issue (#3179)
Browse files Browse the repository at this point in the history
  • Loading branch information
oddvernes authored Dec 11, 2023
1 parent f786992 commit c08fefe
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,10 @@ const StyledList = styled(List)(
overflow-x: hidden;
padding: 0;
display: grid;
/* hack to fix clipping issue in firefox (#3170) */
@supports (-moz-appearance: none) {
scrollbar-width: thin;
}
`,
)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,10 @@ const Label = styled.span<{ $multiline: boolean }>(({ theme, $multiline }) => {
white-space: ${$multiline ? 'normal' : 'nowrap'};
overflow: ${$multiline ? 'initial' : 'hidden'};
overflow-wrap: anywhere;
/* hack to fix clipping issue in firefox (#3170) */
@supports (-moz-appearance: none) {
overflow: ${$multiline ? 'initial' : 'clip'};
}
`
})

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,18 @@ exports[`Autocomplete Matches snapshot 1`] = `
}
@supports (-moz-appearance:none) {
.c3 {
overflow: clip;
}
}
@supports (-moz-appearance:none) {
.c1 {
scrollbar-width: thin;
}
}
<ul
aria-labelledby="downshift-:r0:-label"
class="c0 c1"
Expand Down

0 comments on commit c08fefe

Please sign in to comment.