UNPKG

@jdcfe/yep-react

Version:

一套移动端的React组件库

52 lines (51 loc) 1.11 kB
import * as React from 'react'; export declare type Option = { label: string; value: string; disabled?: boolean; defaultChecked?: boolean; }; export interface RadioProps { prefixCls?: string; className?: string; style?: React.CSSProperties; onChange?: (value: any) => void; name?: string; /** * ['option1','option2'] * * or * * [{ * label:'label1', * value: 'value1' * },{ * label: 'Option2', value: '2', disabled: true, * },{ * label: 'Option3', value: '3', disabled: true, defaultChecked:true, * }] * * */ options: Option[]; checked?: string | number; /** * 是否水平排列 */ horizontal?: boolean; } export default class Radio extends React.PureComponent<RadioProps, any> { static defaultProps: { prefixCls: string; options: never[]; horizontal: boolean; }; constructor(props: RadioProps); handleChange(value: any): void; render(): JSX.Element; }