添加登录逻辑
This commit is contained in:
44
components/nav-bar/nav-bar.vue
Normal file
44
components/nav-bar/nav-bar.vue
Normal file
@@ -0,0 +1,44 @@
|
||||
<script setup>
|
||||
import { navigateBack } from '@/utils/router'
|
||||
|
||||
const props = defineProps({
|
||||
})
|
||||
|
||||
const onBack = () => {
|
||||
navigateBack()
|
||||
}
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<view class="nav-bar">
|
||||
<view class="status_bar">
|
||||
<!-- 这里是状态栏 -->
|
||||
</view>
|
||||
<view class="nav-bar-box">
|
||||
<view @click="onBack">
|
||||
<!-- 返回图标插槽 -->
|
||||
<slot name="back"></slot>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.nav-bar {
|
||||
position: fixed;
|
||||
top: 0;
|
||||
width: 100%;
|
||||
}
|
||||
.status_bar {
|
||||
height: var(--status-bar-height);
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.nav-bar-box {
|
||||
padding: 0 36rpx;
|
||||
height: 58rpx;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
}
|
||||
</style>
|
||||
Reference in New Issue
Block a user