Files
2026-03-31 10:59:25 +08:00

23 lines
491 B
TypeScript

Component({
options: {
styleIsolation: 'apply-shared',
},
properties: {
tabs: {
type: Array,
value: [],
},
activeTab: {
type: String,
value: '',
},
},
methods: {
onTabTap(e: WechatMiniprogram.TouchEvent) {
const id = (e.currentTarget.dataset.id as string) || '';
if (!id) return;
this.triggerEvent('change', { id });
},
},
});