样式优化

master
wujingling0908 5 days ago
parent 0cec477441
commit de0ea807f3
  1. 4
      src/assets/style/chat.css
  2. 117
      src/components/hot-question.vue
  3. 4
      src/components/human-appraise-popup.vue
  4. 2
      src/components/insurance-reservation.vue
  5. 4
      src/components/network-address.vue
  6. 2
      src/components/notice-bar.vue
  7. 4
      src/components/product-card-list.vue

@ -452,6 +452,7 @@ img.avatarUrl-img[lazy="loading"] {
box-sizing: border-box;
position: relative;
background: linear-gradient(90deg, #025cea 0%, #0595f6 100%);
margin: 12rem 0;
/* box-shadow:
1rem 2rem 5rem 0 rgba(10, 75, 173, 0.42),
inset 0 -4rem 15rem 0 rgba(164, 203, 255, 0.25); */
@ -769,7 +770,7 @@ img.avatarUrl-img[lazy="loading"] {
}
.chat-txt-content {
background: #5a9cff;
background: linear-gradient(103deg, #055cea 0%, #137dff 99%);
color: #ffffff;
text-align: left;
-webkit-user-select: text;
@ -800,6 +801,7 @@ img.avatarUrl-img[lazy="loading"] {
user-select: text;
min-height: 5rem;
text-align: justify;
margin: 0;
}
.chat-txt-content p a {

@ -327,14 +327,12 @@ function initHotQuestionYTH(callback) {
function initViewState() {
footerMore.value = false
// 当isQA=true时,需要检查第一页是否需要显示展开收起
if (props.isQA && active.value === 0 && hotList.value.length > 4) {
footerMore.value = true
if (props.isQA && active.value === 0) {
footerMore.value = hotList.value.length > 4
}
}
function activeChange(e) {
console.log(e)
footerMore.value = true
isExchange.value = false
footerOpen.value = false
numNone.value = 3
@ -354,16 +352,16 @@ function activeChange(e) {
console.log(`activeChange: active=${active.value}, len=${len}, isQA=${props.isQA}`)
// 当isQA=true时,第一页也需要显示展开收起功能
if ((active.value === 0 && !props.isQA) || len <= 4) {
footerMore.value = false
if ((active.value === 0 && !props.isQA)) {
footerMore.value = len > 4
}
// 当isQA=true且在第一页时,如果数据超过4条也要显示展开收起
if (props.isQA && active.value === 0 && len > 4) {
footerMore.value = true
if (props.isQA && active.value === 0) {
footerMore.value = len > 4
}
// 其他页签如果数据超过4条也要显示展开收起
if (active.value > 0 && len > 4) {
footerMore.value = true
if (active.value > 0) {
footerMore.value = len > 4
}
updateTabHeight()
}
@ -452,14 +450,14 @@ function updateTabHeight() {
hiddenContent.style.visibility = originalVisibility
}
// 展开状态且有更多内容时添加25px
// 展开状态且有更多内容时添加25rem
const expandedPadding = footerOpen.value && hasMoreContent ? 25 : 0
// 折叠状态且有更多内容时添加25px
// 折叠状态且有更多内容时添加25rem
const collapsedPadding = hasMoreContent ? 25 : 0
const baseHeight = Math.max(totalHeight, 160) // visible content 最小高度
tabHeights[tabIndex] = `${baseHeight + hiddenHeight + expandedPadding}px`
collapsedHeights[tabIndex] = `${baseHeight + collapsedPadding}px`
tabHeights[tabIndex] = `${baseHeight + hiddenHeight + expandedPadding}rem`
collapsedHeights[tabIndex] = `${baseHeight + collapsedPadding}rem`
})
console.log(
@ -603,7 +601,7 @@ onMounted(() => {
padding: 0 !important;
&::before {
right: -5px !important;
right: -5rem !important;
}
}
@ -615,9 +613,9 @@ onMounted(() => {
}
.van-tabs__wrap {
padding: 0px 6px;
padding: 0rem 6rem;
position: relative;
height: 39px !important;
height: 39rem !important;
&::before {
content: '';
@ -625,9 +623,9 @@ onMounted(() => {
z-index: 3;
right: 0;
top: 0;
width: 1px;
height: 40px;
box-shadow: -8px 0px 10px 10px #fff;
width: 1rem;
height: 40rem;
box-shadow: -8rem 0rem 10rem 10rem #fff;
}
&::after {
@ -645,13 +643,15 @@ onMounted(() => {
.van-tabs__nav {
.van-tab {
padding: 0px 10px;
padding: 0rem 10rem;
color: #7e849f;
font-size: 13px;
font-size: 13rem;
}
}
.van-cell__value {
text-align: left;
color: #025cea;
span {
word-break: break-all;
word-wrap: break-word;
@ -659,18 +659,18 @@ onMounted(() => {
}
.van-tab--active {
margin: 0px -2px;
margin: 0rem -2rem;
span {
font-weight: 700;
font-size: 14px;
font-size: 14rem;
color: #025cea;
}
}
</style>
<style scoped lang="scss">
.hot-question {
padding-top: 10px;
padding-top: 0;
}
.hot-question-main {
@ -679,18 +679,18 @@ onMounted(() => {
flex-direction: column;
position: relative;
background: #fff;
border-radius: 8px;
border-radius: 8rem;
overflow: hidden;
.content_body {
width: 100%;
min-height: 180px;
min-height: 180rem;
.van-tabs__nav1 {
font-weight: bold;
& :deep(.van-tabs__line) {
width: 24px !important;
width: 24rem !important;
background: #025cea;
}
@ -703,7 +703,7 @@ onMounted(() => {
.van_cell {
position: relative;
width: 100%;
padding: 4px 16px 4px 35px;
padding: 4rem 16rem 4rem 35rem;
.van-icon {
color: #7e849f;
@ -711,36 +711,39 @@ onMounted(() => {
.van_cell span {
color: #17204d;
font-size: 13px;
font-size: 13rem;
font-weight: 400;
}
&:nth-child(odd)::before {
position: absolute;
left: 15px;
left: 15rem;
top: 50%;
transform: translateY(-50%);
content: '';
width: 11px;
height: 9px;
width: 11rem;
height: 9rem;
background: url('@/assets/images/qustion_icon.png');
background-size: cover;
}
&:nth-child(even)::before {
position: absolute;
left: 15px;
left: 15rem;
top: 50%;
transform: translateY(-50%);
content: '';
width: 11px;
height: 9px;
width: 11rem;
height: 9rem;
background: url('@/assets/images/qustion_icon2.png');
background-size: cover;
}
& :deep(.van-cell__right-icon) {
font-size: 13px;
line-height: 28rem;
height: 28rem;
font-size: 12rem;
color: #025cea;
}
}
@ -750,7 +753,7 @@ onMounted(() => {
}
.change_body {
padding: 0px 16px;
padding: 0rem 16rem;
.border_div {
display: flex;
@ -762,26 +765,26 @@ onMounted(() => {
content: '';
position: absolute;
width: 100%;
height: 0.5px;
height: 0.5rem;
background: #e4eaf2;
left: 0;
top: 0;
}
.refresh-btn-img {
line-height: 17px;
line-height: 17rem;
display: flex;
align-items: center;
padding: 10px 0px;
padding: 10rem 0rem;
img {
width: 13px;
height: 13px;
margin-right: 4px;
width: 13rem;
height: 13rem;
margin-right: 4rem;
}
span {
font-size: 14px;
font-size: 14rem;
color: #17204d;
font-weight: 700;
}
@ -800,15 +803,15 @@ onMounted(() => {
position: absolute;
bottom: 0;
width: 100%;
height: 30px;
height: 30rem;
color: #025cea;
line-height: 30px;
line-height: 30rem;
background: linear-gradient(rgba(255, 255, 255, 0), #fff 70%);
border-radius: 8px;
border-radius: 8rem;
display: flex;
align-items: center;
justify-content: center;
font-size: 14px;
font-size: 14rem;
transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1);
cursor: pointer;
z-index: 1;
@ -819,7 +822,7 @@ onMounted(() => {
&.expanded,
.footerOpen & {
padding-top: 5px;
padding-top: 5rem;
background: #fff;
}
@ -830,10 +833,10 @@ onMounted(() => {
}
span {
font-size: 15px;
font-size: 15rem;
font-weight: 700;
margin-right: 4px;
line-height: 15px;
margin-right: 4rem;
line-height: 15rem;
}
.van-icon {
@ -870,8 +873,8 @@ onMounted(() => {
.van_cell {
position: relative;
width: 100%;
padding: 4px 16px 4px 35px;
min-height: 35px;
padding: 4rem 16rem 4rem 35rem;
min-height: 35rem;
box-sizing: border-box;
.van-cell__value {
@ -884,7 +887,7 @@ onMounted(() => {
/* 所有页签(不只第一个)给最小高度兜底:tab-inner 是绝对定位,
惰性渲染 + 高度未测量时 tab-content 高度为 0,内容会被 overflow:hidden 藏住 */
.van-tabs__content .tab-content {
min-height: 140px !important;
min-height: 140rem !important;
}
/* 确保热点页cell内容完全显示 */
@ -895,7 +898,7 @@ onMounted(() => {
/* 确保"换一换"按钮触发后内容更新正常显示 */
.van-tabs__content > :first-child .visible-content {
min-height: 140px;
min-height: 140rem;
display: flex;
flex-direction: column;
}

@ -253,7 +253,7 @@ function submitAppraise() {
}
.sub-title {
font-size: 14px;
font-size: 14rem;
font-weight: normal;
color: #7e849f;
text-align: center;
@ -371,7 +371,7 @@ function submitAppraise() {
border-radius: 8px;
border: none;
padding: 12px;
font-size: 14px;
font-size: 14rem;
color: #333;
box-sizing: border-box;
resize: none;

@ -391,7 +391,7 @@ function validatorPhone(val) {
}
.insResbox-title {
font-size: 14px;
font-size: 14rem;
color: #333;
font-weight: bold;
margin-bottom: 10px;

@ -84,7 +84,7 @@
</div>
</template>
<template v-else-if="networkInfo == 'noOne'">
<div style="text-align: left; font-size: 14px; color: #666">
<div style="text-align: left; font-size: 14rem; color: #666">
您好,您所选的区域未设立我司网点,请您选择其他区域
</div>
</template>
@ -296,7 +296,7 @@ function RequestInfo(info) {
.edit-address-title-hd {
font-family: NotoSansHans-Regular;
font-size: 14px;
font-size: 14rem;
line-height: 21px;
font-weight: 700;
color: #333333;

@ -303,7 +303,7 @@ onMounted(() => {
.notice-content {
padding: 15px 15px 30px 15px;
font-size: 14px;
font-size: 14rem;
flex: 1 1 auto;
overflow-y: scroll;
-webkit-overflow-scrolling: touch;

@ -103,7 +103,7 @@ function sendQuestion(text) {
padding: 24px 16px;
text-align: center;
color: #999;
font-size: 14px;
font-size: 14rem;
background: #f9f9f9;
border-radius: 8px;
}
@ -193,7 +193,7 @@ function sendQuestion(text) {
text-align: center;
padding: 12px;
color: #4f95fd;
font-size: 14px;
font-size: 14rem;
background: #f0f7ff;
border-radius: 8px;
cursor: pointer;

Loading…
Cancel
Save