Components / visual
StatusColorLegend
Explains the colors assigned to lifecycle states.
Generated from @oods/foundry 0.10.1
- Categories
- visual
- Contexts
- detail
- Readiness
react-and-vue
Playground
This component's contract doesn't list typed props, so the playground shows its documented example.
Documented example StatusColorLegend : mount and declared input triggers, A named section pairs semantic color swatches with visible state names, the current state and optional token references. Meaning is never color alone..
The render follows the page's theme switch: light, dark or high contrast. Both frameworks render the same example.
Status colors
- neutral
- --sys-status-neutral-surface
- success (current)
- --sys-status-success-surface
Status colors
- neutral
- --sys-status-neutral-surface
- success (current)
- --sys-status-success-surface
Code
The documented example. HTML is the markup the React component renders for it, which @oods/component-styles styles.
import { StatusColorLegend } from '@oods/components-react';
import '@oods/component-styles/css';
const colorStates = [
"neutral",
"success"
];
export function Example() {
return (
<StatusColorLegend
colorStates={colorStates}
value="success"
showTokenReferences={true}
/>
);
}Props, slots and events
Contract version 1.1.0. Types are from the React declarations in @oods/components-react.
| Prop | Type | Required | Documented example |
|---|---|---|---|
title | string | undefined | no | |
color | readonly string[] | undefined | no | ["neutral","success"] |
value | string | undefined | no | success |
show | boolean | undefined | no | true |
Slots
none
Events
none
States
empty, populated
Accessibility
- Role
region- How it gets its name
aria-labelon[data-oods-component="StatusColorLegend"]
Keyboard
The contract lists no keyboard behaviour.
Obligations in the contract
- Visible text exposes values without relying on color
- Named semantic container or noninteractive span
A named section pairs semantic color swatches with visible state names, the current state and optional token references. Meaning is never color alone.
Tokens
The token roles this component reads.
surface.paneltext.body
Readiness
The evidence recorded for this component, with its label.
react-and-vue: catalog_list gives this label when the React and Vue components have complete readiness evidence, but the sweep's generated apps don't use the component in both.
| Evidence | React | Vue |
|---|---|---|
| state | implemented-evidence-complete | implemented-evidence-complete |
| versioned contract | passed | passed |
| target implementation | passed | passed |
| package export | passed | passed |
| public declaration | passed | passed |
| dependency closure | passed | passed |
| framework scenario | passed | passed |
| accessibility | verified | verified |
| interaction | not-applicable | not-applicable |
| visual themes | verified | verified |
StatusColorLegend presents declared trait values and owns no focusable control or consumer action.
Use your own
You can replace this component with your own React or Vue component. Map it, and generated code imports yours at the exact version you name. A contract report, run in a real browser, lists what your component met, what it didn't, and what wasn't checked.
The component_map call, with the parts in angle brackets yours to fill:
{
"action": "create",
"apply": true,
"externalSystem": "<your design system>",
"externalComponent": "<YourStatusColorLegend>",
"oodsTraits": [
"Colorized"
],
"substitution": {
"component": "StatusColorLegend",
"react": {
"package": "<your-package>/react",
"version": "<exact version>",
"export": "<YourStatusColorLegend>"
},
"vue": {
"package": "<your-package>/vue",
"version": "<exact version>",
"export": "<YourStatusColorLegend>"
}
}
} How this page was made
Generated at build from the published data, each source with the hash of what was read. The page's manifest.
- Contract:
@oods/component-contracts@0.10.1 componentContracts.StatusColorLegendsha256:82cc2c5404ab… - Documented example:
@oods/component-contracts@0.10.1 sharedScenarios StatusColorLegendsha256:18f1bbe7b398… - Catalog entry (catalog_list):
generated/0.10.1/system/catalog.json StatusColorLegendsha256:f8a0fb919a1c… - React readiness:
@oods/components-react@0.10.1 readiness StatusColorLegendsha256:9985547e5768… - Vue readiness:
@oods/components-vue@0.10.1 readiness StatusColorLegendsha256:98cc5ca576fb… - Prop types:
generated/0.10.1/components/prop-types.json StatusColorLegendsha256:1b74aeb23d8b…