39 lines
640 B
Vue
39 lines
640 B
Vue
<template>
|
|
<div class="custom-title" :class="[ `type-${type}` ]">
|
|
<slot></slot>
|
|
</div>
|
|
</template>
|
|
|
|
<script>
|
|
export default {
|
|
name: "CustomTitle",
|
|
props: {
|
|
type: {
|
|
type: String,
|
|
default: '1'
|
|
}
|
|
}
|
|
}
|
|
</script>
|
|
|
|
<style scoped lang="less">
|
|
@import "../assets/styles/mixin";
|
|
.custom-title {
|
|
font-family: HYHeiFangJ;
|
|
font-size: 18px;
|
|
color: #FFFFFF;
|
|
letter-spacing: 1px;
|
|
line-height: 32px;
|
|
font-weight: 400;
|
|
padding-left: 36px;
|
|
height: 32px;
|
|
&.type-1 {
|
|
.bg("~/assets/images/title.png");
|
|
}
|
|
&.type-2 {
|
|
.bg("~/assets/images/title2.png");
|
|
}
|
|
|
|
}
|
|
</style>
|