What problem does this feature solve?
根据其它表单选项来决定整个组件的状态,省去重复代码<RadioGroup v-model="form.meta.showAlways">
<Radio :label="1" :disabled="form.type === 3 || form.type === 2">展开</Radio>
<Radio :label="0" :disabled="form.type === 3 || form.type === 2">折叠</Radio>
</RadioGroup>
What does the proposed API look like?
希望Group与子选项能同时支持disabled属性<RadioGroup v-model="form.meta.showAlways" :disabled="form.type === 3 || form.type === 2">
<Radio :label="1">展开</Radio>
<Radio :label="0">折叠</Radio>
</RadioGroup>
1条答案
按热度按时间mrwjdhj31#
Translation of this issue:
What problem does this feature solve?
Determine the state of the entire component based on other form options, eliminating duplicate code
RadioGroup v-model='form.meta.show Always'> <Radio:label="1": disabled="form.type===3 | form.type===2"> expand </Radio> <Radio:label="0": disabled="form.type====3 | form.type====2"> fold </Radio> </RadioGroup>
What does the proposed API look like?
Hopefully Group and sub-options will support disabled attributes at the same time
RadioGroup V-model =
form.meta.showAlways': disabled =form.type=== 3 | | form.type=== 2'> <Radio:label="1">Expansion </Radio> <Radio:label="0">Fold</Radio> </RadioGroup>