vue3 数据大屏中经常做一些小标题样式,今天整理一些在数据可视化大屏小标题样式效果。如果将来数据大屏中合适的样式的可以直接拿来用。
vue3 小标题样式效果
组件代码
<template>
<div class="titleBg">
<span>{{ title }}</span>
</div>
</template>
<script>
export default {
name: "title",
data() {
return {}
},
props: {
title: {
type: String,
default() {
return '';
}
},
},
mounted() {
},
}
</script>
<style lang="scss" scoped>
.titleBg {
width: 100%;
height: 34px;
background: url("./assets/titlebg.png") left bottom no-repeat;
background-size: 100% 100%;
display: flex;
justify-content: flex-start;
align-items: center;
flex-wrap: nowrap;
flex-direction: row;
align-content: flex-start;
flex-shrink: 0;
span {
font-size: 22px;
font-family: YouSheBiaoTiHei;
font-weight: 400;
color: #00FCFF;
margin-left: 18px;
}
}
</style>