跳到主要内容

radio

Radio item

Example

bxml

<view class="page-body">
<view class="page-section">
<view class="page-section-title">default style</view>
<label class="radio">
<radio value="r1" checked="true"/> checked
</label>
<label class="radio">
<radio value="r2" /> unchecked
</label>
<label class="radio">
<radio value="r3" disabled /> disabled
<radio value="r4" color="#333" /> custom color
</label>
</view>

Props

NameTypeDescriptionDefault
checkedbooleanWhen the radio is selected, the change event of the radio-group will carry the value of the radio.false
valuestringCurrently selected or not.
disabledbooleanDisabled or not.false
colorstringThe color of the radio, just like css color.\var(--bnui-primay)``

Events

NameDescription
bindtap
bindtapcapture