图片显示优化

This commit is contained in:
kerwincui
2022-06-15 20:30:17 +08:00
parent 82d3f73eeb
commit f7b6883dff
4 changed files with 35 additions and 6 deletions

View File

@@ -196,6 +196,10 @@
color: #FFF; color: #FFF;
opacity: 0.5; opacity: 0.5;
} }
img {
max-width: 100%;
}
</style> </style>
</head> </head>
<body> <body>

View File

@@ -333,7 +333,7 @@
<el-tag size="mini" effect="dark" v-else>信息</el-tag> <el-tag size="mini" effect="dark" v-else>信息</el-tag>
<span style="margin-left:20px;">{{notice.createTime}}</span> <span style="margin-left:20px;">{{notice.createTime}}</span>
</div> </div>
<div v-loading="loading" style="line-height:24px;padding:10px;border:1px solid #eee;border-radius:10px;"> <div v-loading="loading" class="content">
<div v-html="notice.noticeContent"></div> <div v-html="notice.noticeContent"></div>
</div> </div>
<div slot="footer" class="dialog-footer"> <div slot="footer" class="dialog-footer">
@@ -965,6 +965,13 @@ export default {
</script> </script>
<style lang="scss" scoped> <style lang="scss" scoped>
.content {
line-height: 24px;
padding: 10px;
border: 1px solid #eee;
border-radius: 10px;
}
.description { .description {
font-size: 14px; font-size: 14px;

View File

@@ -49,7 +49,7 @@
<el-table-column type="selection" width="55" align="center" /> <el-table-column type="selection" width="55" align="center" />
<el-table-column label="图片" align="center" prop="imgUrl" width="140px;"> <el-table-column label="图片" align="center" prop="imgUrl" width="140px;">
<template slot-scope="scope"> <template slot-scope="scope">
<el-image style="border-radius:5px;height:60px;width:120px;margin-bottom:-5px;" lazy :preview-src-list="[baseUrl+scope.row.imgUrl]" :src="baseUrl+scope.row.imgUrl" fit="cover"></el-image> <el-image style="border-radius:5px;height:80px;width:120px;margin-bottom:-5px;" lazy :preview-src-list="[baseUrl+scope.row.imgUrl]" :src="baseUrl+scope.row.imgUrl" fit="cover"></el-image>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="标题" align="center" prop="title" /> <el-table-column label="标题" align="center" prop="title" />
@@ -152,7 +152,7 @@
<el-tag size="mini" effect="dark" type="success">{{form.categoryName}}</el-tag> <el-tag size="mini" effect="dark" type="success">{{form.categoryName}}</el-tag>
<span style="margin-left:20px;">{{form.createTime}}</span> <span style="margin-left:20px;">{{form.createTime}}</span>
</div> </div>
<div v-loading="loadingDetail" style="line-height:24px;padding:10px;border:1px solid #eee;border-radius:10px;"> <div v-loading="loadingDetail" class="content">
<div v-html="form.content"></div> <div v-html="form.content"></div>
</div> </div>
<div slot="footer" class="dialog-footer"> <div slot="footer" class="dialog-footer">
@@ -403,3 +403,12 @@ export default {
} }
}; };
</script> </script>
<style lang="scss" scoped>
.content {
line-height: 24px;
padding: 10px;
border: 1px solid #eee;
border-radius: 10px;
}
</style>

View File

@@ -105,7 +105,7 @@
<el-tag size="mini" effect="dark" v-else>信息</el-tag> <el-tag size="mini" effect="dark" v-else>信息</el-tag>
<span style="margin-left:20px;">{{form.createTime}}</span> <span style="margin-left:20px;">{{form.createTime}}</span>
</div> </div>
<div v-loading="loadingDetail" style="line-height:24px;padding:10px;border:1px solid #eee;border-radius:10px;"> <div v-loading="loadingDetail" class="content">
<div v-html="form.noticeContent"></div> <div v-html="form.noticeContent"></div>
</div> </div>
<div slot="footer" class="dialog-footer"> <div slot="footer" class="dialog-footer">
@@ -294,3 +294,12 @@ export default {
} }
}; };
</script> </script>
<style lang="scss" scoped>
.content {
line-height: 24px;
padding: 10px;
border: 1px solid #eee;
border-radius: 10px;
}
</style>