mirror of
https://github.com/ant-design/ant-design.git
synced 2025-01-18 14:13:37 +08:00
Merge branch 'master' of github.com:ant-design/ant-design
This commit is contained in:
commit
34b00a4ad7
@ -20,4 +20,22 @@
|
||||
|-----------|------------------------------------------|------------|-------|--------|
|
||||
| checked | 指定当前是否选中 | boolean | | false |
|
||||
| defaultChecked | 初始是否选中 | boolean | | false |
|
||||
| onChange | 组合时必须 | Function(e:Event) | | | |
|
||||
| onChange | 变化时回调函数,组合时必须 | Function(e:Event) | | |
|
||||
| value | value参数,组合时根据此项判定checked | -- | | | |
|
||||
|
||||
####组合使用:
|
||||
以value值来决定自身的checked,
|
||||
|
||||
gruop里需一个做全局checked的参数
|
||||
`getInitialState() {
|
||||
return {
|
||||
r: 'a'
|
||||
}
|
||||
}`
|
||||
|
||||
在自身checked上判断`this.state.r === 'a'`;
|
||||
|
||||
回调接口里
|
||||
`this.setState({
|
||||
r: e.target.value
|
||||
})`
|
||||
|
Loading…
Reference in New Issue
Block a user