UNPKG

651 BTypeScriptView Raw
1import * as React from "react";
2import { BoxProps } from "../Box";
3import { IRadio } from "../Radio";
4import { Omit } from "../common-types";
5
6export interface IRadioGroup {
7 id?: string;
8 name?: string;
9 children?: React.ReactNode;
10 defaultValue?: IRadio["value"];
11 value?: IRadio["value"];
12 variantColor?: IRadio["variantColor"];
13 onChange?: (
14 event: React.ChangeEvent<HTMLInputElement>,
15 value: IRadio["value"],
16 ) => void;
17 spacing?: BoxProps["margin"];
18 isInline?: boolean;
19}
20
21export type RadioGroupProps = IRadioGroup & Omit<BoxProps, "onChange">;
22declare const RadioGroup: React.FC<RadioGroupProps>;
23export default RadioGroup;