Skip to content

Commit

Permalink
feat: updated tab scrolling styles (#436)
Browse files Browse the repository at this point in the history
  • Loading branch information
Fran McDade authored and Fran McDade committed Nov 10, 2023
1 parent 1646d5f commit 9381be5
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ export const TabScrollFuzz = styled.span<Props>`
opacity: 1;
position: absolute;
top: 0;
transition: opacity 300ms ease-in;
width: 56px;
z-index: 1;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ export const Tabs = ({
}: TabsProps): JSX.Element => {
return (
<MTabs
allowScrollButtonsMobile
className={className}
onChange={(_, tabValue): void => onTabChange(tabValue)}
ScrollButtonComponent={TabScrollFuzz} // Utilizing MuiTabScrollButton to show/hide scroll fuzz.
Expand Down
5 changes: 3 additions & 2 deletions packages/data-explorer-ui/src/theme/common/components.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1414,10 +1414,11 @@ export const MuiTabs = (theme: Theme): Components["MuiTabs"] => {
position: "relative", // Positions scroll fuzz.
},
scroller: {
margin: "0 16px",
margin: 0,
padding: "0 8px",
// eslint-disable-next-line sort-keys -- disabling key order for readability
[tabletUp]: {
margin: 0,
padding: 0,
},
},
},
Expand Down

0 comments on commit 9381be5

Please sign in to comment.