docs: add documentation of all typings (#9359)

This commit is contained in:
neverland
2021-08-31 15:51:38 +08:00
committed by GitHub
parent 43b78002d3
commit 317035e9f5
129 changed files with 661 additions and 79 deletions
+4 -2
View File
@@ -168,7 +168,7 @@ export default {
| label-disabled | Whether to disable label click | _boolean_ | `false` |
| label-position | Can be set to `left` | _string_ | `right` |
| icon-size | Icon size | _number \| string_ | `20px` |
| checked-color | Checked color | _string_ | `#1989fa` | - |
| checked-color | Checked color | _string_ | `#1989fa` |
### RadioGroup Props
@@ -178,7 +178,7 @@ export default {
| disabled | Disable all radios | _boolean_ | `false` |
| direction | Direction, can be set to `horizontal` | _string_ | `vertical` |
| icon-size | Icon size of all radios | _number \| string_ | `20px` |
| checked-color | Checked color of all radios | _string_ | `#1989fa` | - |
| checked-color | Checked color of all radios | _string_ | `#1989fa` |
### Radio Events
@@ -199,6 +199,8 @@ export default {
| default | Custom label | - |
| icon | Custom icon | _{ checked: boolean, disabled: boolean }_ |
## Theming
### CSS Variables
The component provides the following CSS variables, which can be used to customize styles. Please refer to [ConfigProvider component](#/en-US/config-provider).
+4 -2
View File
@@ -149,9 +149,9 @@ export default {
</van-radio-group>
```
### 与 Cell 组件一起使用
### 搭配单元格组件使用
此时你需要再引入 `Cell``CellGroup` 组件。
搭配单元格组件使用时,需要再引入 `Cell``CellGroup` 组件。
```html
<van-radio-group v-model="checked">
@@ -213,6 +213,8 @@ export default {
| default | 自定义文本 | - |
| icon | 自定义图标 | _{ checked: boolean, disabled: boolean }_ |
## 主题定制
### 样式变量
组件提供了下列 CSS 变量,可用于自定义样式,使用方法请参考 [ConfigProvider 组件](#/zh-CN/config-provider)。
+1 -1
View File
@@ -7,7 +7,7 @@ const t = useTranslate({
radio: '单选框',
text1: '未选中禁用',
text2: '选中且禁用',
withCell: '与 Cell 组件一起使用',
withCell: '搭配单元格组件使用',
horizontal: '水平排列',
customIcon: '自定义图标',
customColor: '自定义颜色',