zhnghongrui 136a2870ad 历史 1 year ago
..
components 136a2870ad 历史 1 year ago
changelog.md 136a2870ad 历史 1 year ago
package.json 136a2870ad 历史 1 year ago
readme.md 136a2870ad 历史 1 year ago

readme.md

1.1.0版本起变更了传值方式与方法名,如从旧版本更新需更新写法

基础用法

template

<lgd-tab v-model="tabIndex" :tabValue="tabValue" />

script

export default {
    data() {
        return {
            tabValue: ['示例1',  '示例2'],
            tabIndex: 0
        }
    }
}

参数说明

参数名 说明 默认 是否必填 参数类型
tabValue tab列表 - Array
tabIndex tab选中下标 0 NumBer
textColor 文字颜色 #333 String
underlineColor 滑块颜色 #34b2fa String
fontSize 字体大小 16 NumBer
background 组件背景颜色 #fff String

事件

事件名 说明 回调参数
change 监听TAB切换 index

样式

App.vue中引入css

<style>
    @import url("./components/lgd-tab/lgd-tab.css");
</style>