import { SvelteComponentTyped } from "svelte"; import type { SvelteHTMLElements } from "svelte/elements"; type $RestProps = SvelteHTMLElements["div"]; type $Props = { /** * Specify the current value. */ value?: number | undefined; /** * Specify the maximum value * @default 100 */ max?: number; /** * Specify the kind of progress bar. * @default "default" */ kind?: "default" | "inline" | "indented"; /** * Specify the status. * @default "active" */ status?: "active" | "finished" | "error"; /** * Specify the size. * Also accepts Carbon v11's `"small"` (`"sm"`) and `"big"` (`"md"`). * @default "md" */ size?: "sm" | "md" | "small" | "big"; /** * Specify the label text * @default "" */ labelText?: string; /** * Set to `true` to visually hide the label text * @default false */ hideLabel?: boolean; /** * Specify the helper text * @default "" */ helperText?: string; /** * Specify the value text, at the end of the label row and used for `aria-valuetext`. * Format it yourself, e.g. "40 MB of 100 MB". * @default "" */ valueText?: string; /** * Specify the text announced and described when the status is `"error"`. * @default "Error" */ errorText?: string; /** * Specify the text announced and described when the status is `"finished"`. * @default "Complete" */ finishedText?: string; /** * Set an id for the progress bar element. * The helper text and status ids derive from it as `{id}-helper` and * `{id}-status`. * @default uniqueId() */ id?: string; labelChildren?: (this: void) => void; valueChildren?: (this: void) => void; [key: `data-${string}`]: unknown; }; export type ProgressBarProps = Omit<$RestProps, keyof $Props> & $Props; export default class ProgressBar extends SvelteComponentTyped< ProgressBarProps, Record, { labelChildren: Record; valueChildren: Record; } > {}