UNPKG

@stratakit/react

Version:

A React component library for StrataKit

33 lines (32 loc) 930 B
import { jsx } from "react/jsx-runtime"; import * as React from "react"; import { Spinner as SkSpinner } from "@stratakit/bricks"; import { useCompatProps } from "./~utils.js"; const ProgressRadial = React.forwardRef((props, forwardedRef) => { const { // biome-ignore-start lint/correctness/noUnusedVariables: NOT IMPLEMENTED value, indeterminate, status, children, // biome-ignore-end lint/correctness/noUnusedVariables: NOT IMPLEMENTED size: sizeProp, ...rest } = useCompatProps(props); const size = React.useMemo(() => { switch (sizeProp) { case "x-small": return "small"; case "small": return "medium"; case "large": return "xlarge"; } return "large"; }, [sizeProp]); return /* @__PURE__ */ jsx(SkSpinner, { ...rest, ref: forwardedRef, size }); }); DEV: ProgressRadial.displayName = "ProgressRadial"; export { ProgressRadial };