uni-Identify-quality/components/title-block/title-block.vue

45 lines
755 B
Vue
Raw Normal View History

2023-09-20 06:13:13 +00:00
<template>
<div class="content1" :style="{marginTop:`${statusBarHeight}px`}">
2023-09-22 07:00:26 +00:00
<div class="wrap1">
<slot name="left"></slot>
</div>
2023-09-20 06:13:13 +00:00
<div class="wrap2">{{title}}</div>
<div class="wrap3"></div>
</div>
</template>
<script>
export default {
name: "title-block",
2023-09-22 07:00:26 +00:00
data() {
return {
statusBarHeight: uni.getSystemInfoSync().statusBarHeight + 4
};
2023-09-20 06:13:13 +00:00
},
2023-09-22 07:00:26 +00:00
props: {
title: String
2023-09-20 06:13:13 +00:00
}
2023-09-22 07:00:26 +00:00
};
2023-09-20 06:13:13 +00:00
</script>
<style scoped lang="scss">
2023-09-22 07:00:26 +00:00
.content1 {
2023-09-20 06:13:13 +00:00
display: flex;
2023-09-22 06:30:37 +00:00
2023-09-22 07:00:26 +00:00
.wrap1 {
2023-09-22 06:24:51 +00:00
flex-grow: 1;
flex-basis: 0;
2023-09-20 06:13:13 +00:00
}
2023-09-22 07:00:26 +00:00
.wrap3 {
2023-09-22 06:24:51 +00:00
flex-grow: 1;
flex-basis: 0;
2023-09-20 06:13:13 +00:00
}
2023-09-22 07:00:26 +00:00
.wrap2 {
2023-09-22 06:24:51 +00:00
display: flex;
justify-content: center;
align-items: center;
flex-grow: 1;
2023-09-22 07:00:26 +00:00
color: #4e964d;
2023-09-20 06:13:13 +00:00
font-size: 32rpx;
}
}
</style>