UNPKG

react-hook-form-mantine

Version:
19 lines (18 loc) 1.14 kB
import { UseControllerProps, FieldValues } from 'react-hook-form'; import { ChipProps as $ChipProps } from '@mantine/core'; export type ChipProps<T extends FieldValues> = UseControllerProps<T> & Omit<$ChipProps, "value" | "defaultValue">; /** Standalone chip input with react-hook-form controller. For use inside `ChipGroup`, use `Chip.Item` to avoid double controller registration. */ export declare const Chip: { <T extends FieldValues>({ name, control, defaultValue, rules, shouldUnregister, onChange, ...props }: ChipProps<T>): import("react").JSX.Element; Group: <T extends FieldValues>({ name, control, defaultValue, rules, shouldUnregister, onChange, ...props }: import('..').ChipGroupProps<T>) => import("react").JSX.Element; Item: import('@mantine/core').MantineComponent<{ props: $ChipProps; ref: HTMLInputElement; stylesNames: import('@mantine/core').ChipStylesNames; vars: import('@mantine/core').ChipCssVariables; variant: import('@mantine/core').ChipVariant; staticComponents: { Group: typeof import('@mantine/core').ChipGroup; }; }>; };