66 lines
1.2 KiB
Vue
66 lines
1.2 KiB
Vue
<template>
|
|
<view class="tabbar">
|
|
<view
|
|
class="tabbar-item"
|
|
:class="{ active: activeTab === 'home' }"
|
|
@tap="goHome"
|
|
>
|
|
<image src="/static/icons/home.png" class="tabbar-icon" />
|
|
<text>首页</text>
|
|
</view>
|
|
<view
|
|
class="tabbar-item"
|
|
:class="{ active: activeTab === 'mine' }"
|
|
@tap="goMine"
|
|
>
|
|
<image src="/static/icons/mine.png" class="tabbar-icon" />
|
|
<text>我的</text>
|
|
</view>
|
|
</view>
|
|
</template>
|
|
|
|
<script setup lang="ts">
|
|
const props = defineProps<{ activeTab: 'home' | 'mine' }>()
|
|
function goHome() {
|
|
uni.reLaunch({
|
|
url: '/pages/integrated/meeting/index'
|
|
})
|
|
}
|
|
function goMine() {
|
|
uni.reLaunch({
|
|
url: '/pages/integrated/meeting/my-reservations'
|
|
})
|
|
}
|
|
</script>
|
|
|
|
<style scoped>
|
|
.tabbar {
|
|
position: fixed;
|
|
left: 0;
|
|
right: 0;
|
|
bottom: 0;
|
|
height: 100rpx;
|
|
background: #fff;
|
|
display: flex;
|
|
border-top: 1px solid #eee;
|
|
z-index: 999;
|
|
}
|
|
.tabbar-item {
|
|
flex: 1;
|
|
display: flex;
|
|
flex-direction: column;
|
|
align-items: center;
|
|
justify-content: center;
|
|
color: #888;
|
|
font-size: 24rpx;
|
|
}
|
|
.tabbar-icon {
|
|
width: 48rpx;
|
|
height: 48rpx;
|
|
margin-bottom: 4rpx;
|
|
}
|
|
.tabbar-item.active {
|
|
color: #1777FF;
|
|
}
|
|
</style>
|