Metric
A labeled value with optional contextual trend and supporting text.
Preview
- Monthly revenue
- $24,580
- 12.8% higher
- Compared with the previous month.
Use Metric
Metric is a named export of @flood-md/react. Connect the package once, then import what you use.
Design notes
- Native definition-list semantics associate the label with its value, trend and hint. Values may be rich content; the host owns currency, number and locale formatting.
- Trend direction and semantic tone are independent: a decreasing failure rate can be good. Its label must communicate the change without relying on the decorative arrow or color. No automatic percentage calculation is performed.
- Compatible addition in 0.2.5. Uses existing Flood semantic tokens and relative geometry.
API reference
View TypeScript source