UNPKG

formsy-semantic-ui-react

Version:

Formsy-React wrappers for Semantic-Ui-React's form Components

18 lines (17 loc) 1.55 kB
import { FormsyInjectedProps } from 'formsy-react'; import React from 'react'; import { Checkbox, Form, Radio, StrictFormFieldProps, StrictRadioProps } from 'semantic-ui-react'; declare type CheckboxRadioValueType = boolean | number | string; export interface IFormsyCheckboxProps extends FormsyInjectedProps<CheckboxRadioValueType>, Pick<StrictFormFieldProps, 'as' | 'className' | 'error' | 'width' | 'inline' | 'disabled'>, Omit<StrictRadioProps, 'value' | 'name' | 'onChange'> { inputClassName?: string; passRequiredToField?: boolean; inputAs?: typeof Form.Checkbox | typeof Form.Radio | typeof Checkbox | typeof Radio; defaultChecked?: boolean; errorLabel?: React.ReactElement; label?: string | React.ReactNode; onChange?(event: React.FormEvent<HTMLInputElement>, data: Omit<StrictRadioProps, 'value'> & { value: CheckboxRadioValueType; }): void; } declare const _default: React.ComponentType<Pick<IFormsyCheckboxProps & import("formsy-react/dist/withFormsy").WrapperProps<CheckboxRadioValueType>, "as" | "className" | "error" | "width" | "inline" | "disabled" | "value" | "name" | "onChange" | "slider" | "toggle" | "type" | "checked" | "defaultChecked" | "defaultIndeterminate" | "fitted" | "id" | "indeterminate" | "label" | "onClick" | "onMouseDown" | "onMouseUp" | "radio" | "readOnly" | "tabIndex" | "required" | "inputClassName" | "passRequiredToField" | "inputAs" | "errorLabel" | "innerRef" | "validationError" | "validationErrors" | "validations">>; export default _default;