Skip to content

Commit

Permalink
fix(Tabs): update gap small size
Browse files Browse the repository at this point in the history
  • Loading branch information
baptistetruchet committed Oct 22, 2024
1 parent 3af9f68 commit 69cf0d6
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 13 deletions.
20 changes: 9 additions & 11 deletions packages/Core/src/theme/tabs.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,12 +16,12 @@ export type ThemeTabs = {
default: CSSObject
disabled: CSSObject
focus: CSSObject
size: Record<Size, CSSObject>
}
panel: {
horizontal: CSSObject
vertical: CSSObject
}
size: Record<Size, CSSObject>
tabsBorder: {
horizontal: CSSObject
vertical: CSSObject
Expand All @@ -44,7 +44,6 @@ export const getTabs = (theme: WuiTheme): ThemeTabs => {
default: {
color: colors['dark-700'],
fontWeight: fontWeights.medium,
fontSize: fontSizes.md,
textDecoration: 'none',
lineHeight: lineHeights.md,
},
Expand All @@ -57,6 +56,14 @@ export const getTabs = (theme: WuiTheme): ThemeTabs => {
disabled: {
color: colors['dark-400'],
},
size: {
sm: {
fontSize: fontSizes.sm,
},
md: {
fontSize: fontSizes.md,
},
},
},
panel: {
vertical: {
Expand All @@ -81,15 +88,6 @@ export const getTabs = (theme: WuiTheme): ThemeTabs => {
width: borderWidths.md,
},
},
size: {
sm: {
marginRight: space.md,
fontSize: fontSizes.sm,
},
md: {
marginRight: space.xl,
},
},
icon: {
maxWidth: space.lg,
maxHeight: space.lg,
Expand Down
5 changes: 3 additions & 2 deletions packages/Tabs/src/styles.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ export const TabList = styled(Ariakit.TabList)<{ size: SizeOptions }>(
overflow-x: auto;
display: flex;
border: 0;
gap: xl;
&[aria-orientation='vertical'] {
flex-direction: column;
Expand All @@ -21,8 +22,8 @@ export const TabList = styled(Ariakit.TabList)<{ size: SizeOptions }>(
${th('tabs.tabsBorder.horizontal')};
& > :not(:last-child) {
${th(`tabs.size.${size}`)}
${Tab} {
${th(`tabs.item.size.${size}`)}
}
${system};
`
Expand Down

0 comments on commit 69cf0d6

Please sign in to comment.