UNPKG

@snowball-tech/fractal

Version:

Fractal's (Snowball's design system) React component library based on RadixUI and PandaCSS

37 lines (34 loc) 1.3 kB
import { AllHTMLAttributes, ReactNode, MouseEvent, ChangeEvent } from 'react'; import { ButtonProps } from '../Button/Button.types.js'; import '@snowball-tech/design-tokens/dist/web/typescript/constants'; import '../constants-QFINMz1u.js'; import '../Button/Button.constants.js'; interface InputTextProps extends Omit<AllHTMLAttributes<HTMLInputElement>, 'onChange' | 'prefix'> { autoFocus?: boolean; button?: { position?: 'left' | 'right'; } & Omit<ButtonProps, 'onClick' | 'variant'>; defaultValue?: number | string; description?: string; disabled?: boolean; error?: boolean | string; extraSmall?: boolean; fullWidth?: boolean; id?: string; label?: string; name?: string; placeholder?: string; prefix?: ReactNode; readOnly?: boolean; required?: boolean; selectOnFocus?: boolean; success?: boolean | string; suffix?: ReactNode; type?: 'date' | 'datetime-local' | 'email' | 'number' | 'password' | 'search' | 'tel' | 'text' | 'time' | 'time' | 'url'; value?: number | string; withButton?: boolean; withSpinButton?: boolean; onButtonClick?: (event: MouseEvent<HTMLElement>) => void; onChange?: (event: ChangeEvent<HTMLInputElement>, newValue: string) => void; } export type { InputTextProps };