feat: 全局更改tabbar、首页、分享页UI重构
This commit is contained in:
@@ -6,6 +6,7 @@
|
||||
:bgStyle="{ color: props.color }"
|
||||
:showLeftButton="props.showLeftButton"
|
||||
:goLeft="props.goLeft"
|
||||
:tabbar="props.tabbar"
|
||||
@onClickLeft="onClickLeft"
|
||||
>
|
||||
<!-- <Agreement /> -->
|
||||
@@ -24,7 +25,7 @@
|
||||
</view>
|
||||
</s-layout>
|
||||
</template>
|
||||
<script setup lang="ts">
|
||||
<script setup>
|
||||
// import Agreement from '@/components/agreement.vue';
|
||||
import {
|
||||
ref,
|
||||
@@ -71,16 +72,22 @@
|
||||
type: String,
|
||||
default: 'inner',
|
||||
},
|
||||
tabbar: {
|
||||
type: [String, Boolean],
|
||||
default: '',
|
||||
},
|
||||
});
|
||||
let height = ref(0);
|
||||
let sysInfo = uni.getSystemInfoSync();
|
||||
const windowHeight = sysInfo.windowHeight;
|
||||
const safeBottom = sysInfo.safeAreaInsets?.bottom || 0;
|
||||
watch(
|
||||
() => [props.height, props.heightShow],
|
||||
(val) => {
|
||||
if (!props.height) {
|
||||
if (!props.heightShow) {
|
||||
height.value = windowHeight - sysInfo.statusBarHeight - uni.upx2px(88);
|
||||
const tabbarHeight = props.tabbar ? uni.upx2px(100) + safeBottom : 0;
|
||||
height.value = windowHeight - sysInfo.statusBarHeight - uni.upx2px(88) - tabbarHeight;
|
||||
}
|
||||
} else {
|
||||
height.value = props.height;
|
||||
|
||||
Reference in New Issue
Block a user