@nexusui/components
Version:
These are custom components specially-developed for NexusUI applications. They will make your life easier by giving you out-of-the-box implementations for various high-level UI elements that you can drop directly into your application.
21 lines (20 loc) • 918 B
TypeScript
import React from 'react';
import { FormControlLabelProps } from '@mui/material/FormControlLabel';
import { RadioProps } from '@mui/material/Radio';
import { RadioGroupProps } from '@mui/material/RadioGroup';
import { ControllerProps } from 'react-hook-form';
export type OptionProps = Omit<FormControlLabelProps, 'control'>;
export type RadioOptionsProps = ReadonlyArray<OptionProps>;
export type FormControllerProps = Omit<ControllerProps, 'control' | 'name' | 'rules' | 'render'>;
export interface FormRadioProps extends RadioGroupProps {
name: string;
options: RadioOptionsProps;
rules?: ControllerProps['rules'];
controllerProps?: FormControllerProps;
radioProps?: RadioProps;
}
/**
* @param {FormRadioProps} props - provides the properties fo React component
* @return {ReactNode} - provides the react component to be ingested
**/
export declare const FormRadio: React.FC<FormRadioProps>;