
Switch 切換開關,通常用在開啟或關閉的功能上。
基本使用
<bpa-switch labelText="text" v-model="isOpen"/>
客製化文字
<bpa-switch labelText="text" v-model="isOpen">
<template v-slot:close-text><img src="favicon.ico" alt=""/>Off</template>
<template v-slot:open-text>On👍🏽</template>
</bpa-switch>
屬性
名稱 | Value | Type | Default Value | Required | 描述 |
---|---|---|---|---|---|
id | String | 隨機 | |||
labelText | String | ||||
v-slot:close-text | String | 關閉 | |||
v-slot:open-text | String | 開啟 |
事件
名稱 | Value | Type | Default Value | Required | 描述 |
---|---|---|---|---|---|
change | String | 隨機 |