Zum Inhalt springen

UI: ProgressBar

Als Markdown ansehen

Ein beschrifteter Fortschrittsbalken mit seinem Wert als Text. Importiere die Token-Datei einmal (@pithyx/ui/tokens.css) und umschließe die App mit UiProvider; siehe @pithyx/ui.

Beim Build aus den TSDoc-Kommentaren von @pithyx/ui 1.0.0-rc.9 erzeugt; der Text unter den Überschriften ist der Kommentar im Quelltext und bleibt Englisch.

The props of ProgressBar: React Aria’s progress bar props plus the label.

  • Omit<AriaProgressBarProps, "className" | "children">
label: ReactNode;

The label above the bar, also the accessible name.

optional showValue?: boolean;

Whether the value is shown as text next to the label; true when left out.

optional className?: string;

Extra class names, added after the bar’s own.

function ProgressBar(props): Element;

A labelled progress bar that shows its value as text unless showValue is false. Without value it is indeterminate only when isIndeterminate is set.

Parameter Typ Beschreibung
props ProgressBarProps React Aria’s progress bar props (value, minValue, maxValue, formatOptions) plus the label.

Element

The progress bar with its label.