Files
sist_web/src/views/content/components/Introduction.vue
2022-10-04 17:17:55 +08:00

88 lines
1.6 KiB
Vue

<template>
<div class="Introduction" style="background-color:#fff; margin-top: 3rem;">
<el-row>
<el-col>
<div class="context">
<div v-if="value" class="title">{{ value.title }}</div>
<div v-if="value" class="text" v-html="value.content"></div>
</div>
</el-col>
</el-row>
</div>
</template>
<script>
export default {
name: "Introduction",
props: {
introduction: {
type: Object,
default() {
return {
}
},
},
},
data() {
return {
introductionData : this.value
}
},
watch:{
value(val){
this.introductionData = val
}
},
created() {
this.value = {
title: "12",
content: "12"
}
},
}
</script>
<style scoped lang="scss">
.Introduction {
width: 100%;
}
.tab {
margin-left: 1.9rem;
margin-top: 1.5rem;
font-weight: 400;
font-size: 1.4rem !important;
}
.context {
margin: 3rem 4rem;
.title {
font-size: 2.4rem;
font-weight: 500;
color: #1956BC;
text-align: center;
}
.text {
width: 100%;
margin-top: 2rem;
font-size: 1.2rem;
font-weight: 400;
color: #3C3C3C;
word-break: break-word; /* 文本行的任意字内断开 */
word-wrap: break-word; /* IE */
white-space: -moz-pre-wrap; /* Mozilla */
white-space: -hp-pre-wrap; /* HP printers */
white-space: -o-pre-wrap; /* Opera 7 */
white-space: -pre-wrap; /* Opera 4-6 */
white-space: pre; /* CSS2 */
white-space: pre-wrap; /* CSS 2.1 */
white-space: pre-line; /* CSS 3 (and 2.1 as well, actually) */
pre {
width: 100%;
}
}
}
</style>