Skip to content

Checkbox 多选框

规则

js
{
    type:"checkbox",
    title:"标签",
    field:"label",
    value:["1","2","3"],
    options:[
        {value:"1",label:"好用",disabled:true},
        {value:"2",label:"方便",disabled:false},
        {value:"3",label:"实用",disabled:false},
        {value:"4",label:"有效",disabled:false},
    ]
}

参考:arco-design_Checkbox

value :Array

Options

字段名说明字段类型是否必填默认值
value参数值String,Numbertrue-
label字段别名Stringtrue-
disabled设置为禁用状态Booleanfalsefalse

Props

参数名描述类型默认值
default-value默认值(非受控状态)Array<string | number | boolean>[]
direction复选框的排列方向Direction'horizontal'
disabled是否禁用booleanfalse

Events

事件名描述参数
change值改变时触发value: Array<string | number | boolean>