Skip to content
SprecherEast
Issue 769

Align tone names and values across Alert, Badge and Card

Back to our plan
Open
frontendtech-debtpriority: low

Problem

The shared Alert, Badge and Card each define the success and error tones on their own. Alert calls the destructive tone error and Card calls it danger. Alert's success border is 30% opacity and Card's is 40%. A toned box can look slightly different depending on which component draws it.

Proposed fix

Pick one tone vocabulary and one set of border and background values, and define them once as shared theme tokens or one shared definition that Alert, Badge and Card all use. Follow "use, configure or split" (docs/guidelines/components-and-content.md).

Acceptance criteria

  • The three components use the same tone names and the same token values for success, danger and neutral.
  • Existing looks stay the same except for the deliberate alignment, checked in light and dark at six widths.
  • Tests and the gallery are updated.

Area

frontend, shared component

Priority

priority: low

Found in the review of PR #765 (#517).


Generated by Claude Code, opens in a new tab

See it on GitHub, opens in a new tab