@beisen-phoenix/checkbox-group

checkbox-group

Usage no npm install needed!

<script type="module">
  import beisenPhoenixCheckboxGroup from 'https://cdn.skypack.dev/@beisen-phoenix/checkbox-group';
</script>

README

复选框组

@beisen-phoenix/checkbox-group

概述

多选框主要用于一组可选项多项选择,或者单独用于标记切换某种状态。分为三类:单独使用、CheckboxGroup、全选。

API

参数 说明 类型 默认值 必须
options checkbox的label、value、disabled Array
checkedList 已选中的checkbox的label和value Array
defaultCheckedList 默认已选中的checkbox的label和value Array
arrangement 排列方向 row:横排 col:竖排 String row
disabled 禁用全部checkbox boolean false
colSpace 纵向排列时的间距 marge-bottom number 10
onChange 发生状态变化后的回调,返回checkedlist, Array类型。点击全选时,返回两个参数,第一个返回checkedlist,第二个参数为全选按钮数据 (checkedList:Array,item) => void
extraCls 自定义class string ''
tipsType 提示UI类型default【显示为html标签自带title】、animate【显示为标准tooltip】 使用'default'有利于性能提升 string 'animate'
checkboxWidth checkbox宽度:文字加图标宽度 number 0(auto)
showCheckAll 是否显示全选 boolean false

多语言

参数 说明 类型 默认值
translation 语言包 用于翻译组件内置常量 {checkAll: string} {checkAll: '全选'}