Skip to content

Commit

Permalink
center icon only badge
Browse files Browse the repository at this point in the history
  • Loading branch information
yihuiliao committed Jan 30, 2025
1 parent afc5d76 commit 55a44c9
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion packages/@react-spectrum/s2/src/Badge.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,10 @@ const badge = style<BadgeStyleProps>({
display: 'flex',
font: 'control',
justifyContent: 'center',
alignItems: 'baseline',
alignItems: {
default: 'baseline',
':has([slot=icon]:only-child)': 'center'
},
borderRadius: 'control',
minHeight: 'control',
paddingX: {
Expand Down

0 comments on commit 55a44c9

Please sign in to comment.