25 lines
485 B
Vue
25 lines
485 B
Vue
<!-- 自定义状态栏 -->
|
|
<template>
|
|
<view class="status" :style="{ height: statusBarHeight, background: props.color }"></view>
|
|
</template>
|
|
|
|
<script setup>
|
|
import sheep from '@/sheep';
|
|
|
|
const statusBarHeight = sheep.$platform.device.statusBarHeight + 'px';
|
|
const props = defineProps({
|
|
color: {
|
|
type: String,
|
|
default: '#ffffff',
|
|
},
|
|
});
|
|
</script>
|
|
<style lang="scss">
|
|
.status {
|
|
width: 100%;
|
|
}
|
|
.uni-status-bar {
|
|
// width: 750rpx;
|
|
}
|
|
</style>
|