mirror of
https://gitee.com/vant-contrib/vant-weapp.git
synced 2025-04-06 03:58:05 +08:00
fix #1625 pull request 改动点: - 重构组件,优化性能 - 新增 inactiveColor、name 属性 - 完善文档,增加小程序自定义tab-bar示例
23 lines
360 B
JavaScript
23 lines
360 B
JavaScript
import list from '../../config';
|
|
import Page from '../../common/page';
|
|
|
|
Page({
|
|
data: {
|
|
list,
|
|
activeName: []
|
|
},
|
|
|
|
onChangeCollapse(event) {
|
|
this.setData({
|
|
activeNames: event.detail
|
|
});
|
|
},
|
|
|
|
onClick(event) {
|
|
const { switchTab, url } = event.currentTarget.dataset;
|
|
if (switchTab) {
|
|
wx.switchTab({ url });
|
|
}
|
|
}
|
|
});
|