UNPKG

infinity-ui-elements

Version:

A React TypeScript component library with Tailwind CSS design system

40 lines 1.5 kB
import * as React from "react"; import { type VariantProps } from "class-variance-authority"; declare const counterVariants: (props?: ({ size?: "medium" | "large" | "small" | null | undefined; color?: "primary" | "positive" | "negative" | "notice" | "neutral" | "information" | null | undefined; emphasis?: "subtle" | "intense" | null | undefined; } & import("class-variance-authority/dist/types").ClassProp) | undefined) => string; type CounterVariantProps = VariantProps<typeof counterVariants>; export type CounterSize = NonNullable<CounterVariantProps["size"]>; export type CounterColor = NonNullable<CounterVariantProps["color"]>; export type CounterEmphasis = NonNullable<CounterVariantProps["emphasis"]>; export interface CounterProps extends Omit<React.HTMLAttributes<HTMLSpanElement>, "color"> { /** * The numerical value to display */ value: number | string; /** * Maximum value to display before showing overflow indicator (e.g., "99+") */ max?: number; /** * Custom class name for the counter */ className?: string; /** * Size of the counter */ size?: CounterSize; /** * Color variant of the counter */ color?: CounterColor; /** * Visual emphasis level */ emphasis?: CounterEmphasis; } declare const Counter: React.ForwardRefExoticComponent<CounterProps & React.RefAttributes<HTMLSpanElement>>; export { Counter, counterVariants }; //# sourceMappingURL=Counter.d.ts.map