import { cx } from "@/utils/cx"; const styles = { sm: { root: "gap-4", label: "text-sm font-medium", spinner: "size-8", }, md: { root: "gap-4", label: "text-sm font-medium", spinner: "size-12", }, lg: { root: "gap-4", label: "text-lg font-medium", spinner: "size-14", }, xl: { root: "gap-5", label: "text-lg font-medium", spinner: "size-16", }, }; interface LoadingIndicatorProps { /** * The visual style of the loading indicator. * @default 'line-simple' */ type?: "line-simple" | "line-spinner" | "dot-circle"; /** * The size of the loading indicator. * @default 'sm' */ size?: "sm" | "md" | "lg" | "xl"; /** * Optional text label displayed below the indicator. */ label?: string; } export const LoadingIndicator = ({ type = "line-simple", size = "sm", label }: LoadingIndicatorProps) => { const renderSpinner = () => { if (type === "line-spinner") { return ( ); } if (type === "dot-circle") { return ( ); } // Default case: type === "line-simple" return ( ); }; return (