This commit is contained in:
姚宇浩 2023-12-07 15:27:00 +08:00
parent 3c0c429006
commit 589d54851c
3 changed files with 10 additions and 19 deletions

View File

@ -1,14 +1,9 @@
<template> <template>
<div class="list-1"> <div class="list-1">
<div class="top"> <div class="top">
<strong :class="[newData.title.length < 40 ? 'yesDevelop' : 'noDevelop']" <strong class="yesDevelop"
>{{ newData.title >{{ newData.title
}}<a }}</strong
href="javascript:;"
v-if="newData.title.length > 40"
@click="quanwen"
>全文</a
></strong
> >
</div> </div>
<div class="bottom-1"> <div class="bottom-1">
@ -39,7 +34,8 @@ const quanwen = () => {
.noDevelop { .noDevelop {
display: inline-block; display: inline-block;
width: 343px; // width: 343px;
width: 90vw;
height: 44px; height: 44px;
overflow: hidden; overflow: hidden;
text-overflow: ellipsis; text-overflow: ellipsis;
@ -74,7 +70,8 @@ const quanwen = () => {
.yesDevelop { .yesDevelop {
display: inline-block; display: inline-block;
width: 343px; // width: 343px;
width: 90vw;
overflow: hidden; overflow: hidden;
text-overflow: ellipsis; text-overflow: ellipsis;
display: -webkit-box; display: -webkit-box;

View File

@ -1,15 +1,9 @@
<template> <template>
<div class="list-1"> <div class="list-1">
<div class="left"> <div class="left">
<strong :class="[newData.title.length < 26 ? 'yesDevelop' : 'noDevelop']" <strong class="yesDevelop"
>{{ newData.title >{{ newData.title
}}<a }}</strong
href="javascript:;"
v-if="newData.title.length > 26"
@click="quanwen"
>
全文</a
></strong
> >
<div class="bottom-1"> <div class="bottom-1">
<div class="left">{{ newData.createdAt }}</div> <div class="left">{{ newData.createdAt }}</div>

View File

@ -114,14 +114,14 @@ const records = reactive({
{ {
id: 1, id: 1,
display: 0, display: 0,
title: "2023年养老金政策震撼发布你的养老金将发生这样的变化", title: "2023年养老金政策震撼发布你的养老金将发生这样的变化红红火火恍恍惚惚或或或或或或或或或或或或或或或或或或或或或或或或或",
createdAt: "11月27日", createdAt: "11月27日",
eye: "8888", eye: "8888",
}, },
{ {
id: 1, id: 1,
display: 1, display: 1,
title: "“三问”个人养老金:是什么、怎么缴、如何领?", title: "“三问”个人养老金:是什么、怎么缴、如何领?红红火火恍恍惚惚或或或或或或或或或或或或或或或或或或或或或或或或或",
createdAt: "11月27日", createdAt: "11月27日",
eye: "8888", eye: "8888",
}, },