chore:后台数字跳动可以自定义文字大小颜色

This commit is contained in:
2026-09-01 15:56:30 +08:00
parent a026adaec7
commit 33f54eb63c
2 changed files with 24 additions and 17 deletions

View File

@@ -202,7 +202,7 @@ const localDevConfig = ({
// })['2724']; // 生物菌肥 // })['2724']; // 生物菌肥
// })['2811']; // 选择要使用的环境配置 // })['2811']; // 选择要使用的环境配置
// })['local-11']; // 选择要使用的环境配置 // })['local-11']; // 选择要使用的环境配置
})['2811']; // 本地 })['5g-97']; // 本地
// })['local-2']; // 本地 // })['local-2']; // 本地
// })['local-11']; // 本地 // })['local-11']; // 本地
// })['1-test']; // test // })['1-test']; // test

View File

@@ -8,13 +8,15 @@
:style="{ width: (100 / value.rowCount + '%') + ';' }"> :style="{ width: (100 / value.rowCount + '%') + ';' }">
<view style="display:flex;"> <view style="display:flex;">
<view :style="{ <view :style="{
'line-height': '1.2;', 'display': 'flex;',
'font-size': (value.font.titlesize * 2 + 'rpx') + ';', 'align-items': 'baseline;',
'font-weight': '600;', 'line-height': '1.2;'
'color': value.font.titlecolor + ';'
}"> }">
<uv-count-to :ref="`countTo-${index}`" :autoplay="true" :startVal="30" :endVal="item.title" <uv-count-to :ref="`countTo-${index}`" :autoplay="true" :startVal="30" :endVal="item.title"
:decimals="getvalue(item.title)" decimal="."></uv-count-to> :decimals="getvalue(item.title)" decimal="."
:color="value.font.titlecolor"
:fontSize="value.font.titlesize || 22"
:bold="isBold(value.font.weight)"></uv-count-to>
<text :style="{ <text :style="{
'margin-left': '4rpx;', 'margin-left': '4rpx;',
'font-size': (value.font.unitsize * 2 + 'rpx') + ';', 'font-size': (value.font.unitsize * 2 + 'rpx') + ';',
@@ -88,6 +90,11 @@ export default {
return value % 1 !== 0 ? 2 : 0; return value % 1 !== 0 ? 2 : 0;
}, },
// 是否加粗
isBold(weight) {
return weight === 'bold' || (weight && Number(weight) >= 600);
},
// 页面跳转 // 页面跳转
redirectTo(item) { redirectTo(item) {
if (!item.wap_url || this.$util.getCurrRoute() != this.$util.MEMBER_PAGE_URL || this.storeToken) { if (!item.wap_url || this.$util.getCurrRoute() != this.$util.MEMBER_PAGE_URL || this.storeToken) {