Files

21 lines
805 B
TypeScript

"use client";
import React from "react";
import { Progress as ProgressComponent, type ProgressRootProps } from "./Progress";
/**
* Add wrapper components and business logic here.
* If you modify this file, disable Subframe sync for it to prevent overwrites.
* Learn more: https://docs.subframe.com/concepts/syncing-components#wrapping-components
*/
const ProgressRoot = React.forwardRef<HTMLDivElement, ProgressRootProps>(function ProgressRoot(props, ref) {
const accessibleLabel =
props["aria-label"] ?? (props["aria-labelledby"] ? undefined : typeof props.label === "string" ? props.label : undefined);
return <ProgressComponent {...props} aria-label={accessibleLabel} ref={ref} />;
});
export const Progress = Object.assign(ProgressRoot, {
Indicator: ProgressComponent.Indicator,
});