v12-ui
Version:
A React component library with a focus on utility-first design and accessibility.
19 lines (18 loc) • 1.72 kB
TypeScript
import { ComponentPropsWithRef, ReactNode } from 'react';
import { WithoutSharedProperties } from '../utils/polymorphicTypes';
import { VariantProps } from 'class-variance-authority';
declare const text: (props?: ({
variant?: "error" | "default" | "primary" | "secondary" | "muted" | "accent" | "success" | "warning" | "info" | null | undefined;
hover?: boolean | null | undefined;
textShadow?: "none" | "black_p" | "black_title" | "success_p" | "success_title" | "warning_p" | "warning_title" | "error_p" | "error_title" | "info_p" | "info_title" | null | undefined;
fontSize?: "small_responsive" | "paragraph_responsive" | "subtitle_responsive" | "title_responsive" | null | undefined;
fontWeight?: "small" | "title" | "auto" | "paragraph" | "subtitle" | null | undefined;
} & import('class-variance-authority/types').ClassProp) | undefined) => string;
type ElementAllowedTags = ('h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6' | 'p' | 'span' | 'strong' | 'small' | 'em' | 'b' | 'i' | 'u' | 'mark' | 'del' | 'ins' | 'code' | 'kbd' | 'samp' | 'var' | 'cite' | 'q' | 'pre' | 'blockquote' | 'address') & keyof React.JSX.IntrinsicElements;
type PolymorphicProps<T extends ElementAllowedTags = 'p'> = {
as?: T;
children?: ReactNode;
className?: string;
} & WithoutSharedProperties<ComponentPropsWithRef<T>> & VariantProps<typeof text>;
export declare const Text: import('react').ForwardRefExoticComponent<Omit<PolymorphicProps<"small" | "address" | "b" | "blockquote" | "cite" | "code" | "del" | "em" | "h1" | "h2" | "h3" | "h4" | "h5" | "h6" | "i" | "ins" | "kbd" | "mark" | "p" | "pre" | "q" | "samp" | "span" | "strong" | "u" | "var">, "ref"> & import('react').RefAttributes<any>>;
export {};