Repository navigation
v7.0.0
Major Changes
-
1a35841: Breaking:
Tag'svariant="default"is removed, and everyTagcolour now
resolves through the samedata-color+--tag-*system. Completes #320, which
6.2.0 shipped only halfway.variant="default"→variant="filled"6.2.0 renamed the value but kept
'default'as a deprecated alias. That left the
exact asymmetry the issue was filed about —variant="default"was valid on
Tagbut not onButton. The alias is now gone.- <Tag variant="default">…</Tag> + <Tag variant="filled">…</Tag>
filledis also the default, sovariant="default"can usually just be dropped.
This is the only source change consumers need to make.One colour path instead of two
Before, only the 13 preset colours emitted
data-colorand read--tag-*; the
semantic states (default/primary/success/warning/danger) carried fixed
Tailwind classes instead. So[data-color]selectors and--tag-*overrides
worked on some colours and silently did nothing on others.Now every colour goes through the same three custom properties:
Property Role --tag-bgthe hue; the border when variant="outlined"--tag-fgtext colour (defaults to --tag-bg)--tag-tintthe fill behind variant="filled"/* now works for every colour, not just the presets */ [data-slot='badge'][data-color='success'] { --tag-bg: oklch(70% 0.2 160); }
Tagalso emitsdata-variantso stylesheets can target a variant without
re-deriving it from class names.Rendered output is unchanged. All 36 colour × variant combinations were
screenshot-compared before and after in both light and dark mode; the images are
byte-identical (MD5 match). The semantic states keep the exact Tailwind ramp
values they had —successstill reads green-500/600 with green-400 in dark
mode,warningyellow-500/600 with yellow-400.What deliberately did not change
successandwarningstay onTageven thoughButton'scolorhas no such
values. ATagmarks state, and antd'sTagcarries status colours itsButton
does not — dropping them would have made the component worse, not more aligned.
variantlikewise staysfilled | outlinedrather than adoptingButton's full
solid/dashed/text/linkset, which #320 never asked for.
What's Changed
- 💥 feat(ui): finish Tag's vocabulary alignment — remove the default alias and unify its colour path (#320) by @pjb0811 in #328
- 🔖 chore: version packages by @github-actions[bot] in #329
Full Changelog: v6.2.0...v7.0.0