Status Icon
A work item status as one glyph: backlog, todo, in progress, in review, done and canceled, readable without color.
Rendering Status Icon…
Installation
Copy the source into your project with the CLI. It lands under @/components/ui and is yours to edit.
npx mlola-ui add status-iconUsage
import { StatusIcon } from "@/components/ui/status-icon";
export default function Example() {
return (
<div className="ml-cluster">
<StatusIcon status="todo" />
<StatusIcon status="in-progress" progress={0.5} />
<StatusIcon status="done" />
</div>
);
}Styling comes from the engine stylesheet and the nearest theme. Set it once at the root:
<html data-theme="graphite" data-mode="light">HTML
The markup the example above renders, exactly. It needs no script: write it from any language or template.
<div class="ml-cluster">
<svg class="ml-status-icon" viewBox="0 0 14 14" width="1em" height="1em" data-status="todo" role="img" aria-label="Todo"><circle cx="7" cy="7" r="5.75" fill="none" stroke="currentColor" stroke-width="1.5"></circle></svg>
<svg class="ml-status-icon" viewBox="0 0 14 14" width="1em" height="1em" data-status="in-progress" role="img" aria-label="In progress"><circle cx="7" cy="7" r="5.75" fill="none" stroke="currentColor" stroke-width="1.5"></circle><circle cx="7" cy="7" r="2.4" fill="none" stroke="currentColor" stroke-width="4.8" stroke-dasharray="7.5398223686155035 15.079644737231007" transform="rotate(-90 7 7)"></circle></svg>
<svg class="ml-status-icon" viewBox="0 0 14 14" width="1em" height="1em" data-status="done" role="img" aria-label="Done"><circle cx="7" cy="7" r="6" fill="currentColor"></circle><path d="M4.4 7.2 6.2 9 9.7 5.2" fill="none" stroke="var(--ml-status-mark)" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path></svg>
</div>Options
| Prop | Values | Default |
|---|---|---|
status | backlogtodoin-progressin-reviewdonecanceled | — |
Every prop with a fixed set of values, read from the exported TypeScript types with its doc comment. Open the Code tab above for the rest of the API.
Classes and attributes
A class names each element; data-* and aria-* attributes carry its variant and state. The values listed are the ones the stylesheet draws; the default needs no attribute.
| Class | Attributes |
|---|---|
ml-status-icon | data-status="backlog | canceled | done | in-progress | in-review" |
Accessibility and theming
- Semantic elements, accessible names and state relationships are part of the contract.
- Keyboard, pointer and touch paths are operable; focus stays visible in every theme.
- Light and dark modes pass WCAG AA contrast in all 5 canonical themes.
- Reduced motion and forced colors keep meaning and operation.