细节完善

This commit is contained in:
kron
2026-01-07 10:07:25 +08:00
parent 199bf3160e
commit 494f83392e
4 changed files with 20 additions and 15 deletions

View File

@@ -524,7 +524,15 @@ export const sharePractiseData = async (canvasId, data) => {
renderText(ctx, data.weekArrow, 36, "#FA2A2A", 84, 152, "center");
ctx.drawImage(bubble2Img, 65, 220, 143, 87);
renderText(ctx, "本周消耗", 14, "#FDA103", 139, 248, "center");
renderText(ctx, data.weekArrow * 1.6, 36, "#FA2A2A", 139, 284, "center");
renderText(
ctx,
Math.round(data.weekArrow * 1.6),
36,
"#FA2A2A",
139,
284,
"center"
);
ctx.drawImage(bubble3Img, 255, 52, 114, 92);
renderText(ctx, "我的名次", 14, "#FDA103", 312, 80, "center");
renderText(ctx, data.rank, 36, "#FA2A2A", 312, 116, "center");

View File

@@ -147,8 +147,8 @@ const onClick = async () => {
align-items: center;
font-size: 22rpx;
color: #777777;
margin-left: 20rpx;
margin-right: 10rpx;
padding-left: 20rpx;
padding-right: 10rpx;
}
.rank-item > button:nth-child(5) > image {
width: 24rpx;

View File

@@ -71,11 +71,7 @@ const shareImage = async () => {
</view>
<block v-if="list[0]">
<text>{{ list[0].name }}占领了封面</text>
<text
>整整消耗了{{
Number((list[0].weekArrow * 1.6).toFixed(0))
}}大卡!</text
>
<text>整整消耗了{{ Math.round(list[0].weekArrow * 1.6) }}大卡!</text>
</block>
</view>
<view class="rank-title-bar">
@@ -173,12 +169,12 @@ const shareImage = async () => {
display: flex;
align-items: center;
text-align: center;
width: 100%;
width: calc(100% - 80rpx);
line-height: 80rpx;
padding: 0 40rpx;
}
.rank-title-bar > text:nth-child(1) {
width: calc(15% - 30rpx);
padding-left: 30rpx;
width: 60rpx;
}
.rank-title-bar > text:nth-child(2) {
flex: 1;
@@ -187,7 +183,7 @@ const shareImage = async () => {
width: 18%;
}
.rank-title-bar > text:nth-child(4) {
width: 27%;
width: 24%;
}
.data-list {
background: $uni-white;

View File

@@ -648,11 +648,12 @@ onShareTimeline(() => {
display: flex;
align-items: center;
text-align: center;
width: 100%;
width: calc(100% - 40rpx);
line-height: 80rpx;
padding: 0 20rpx;
}
.rank-title-bar > text:nth-child(1) {
width: 15%;
width: 55rpx;
}
.rank-title-bar > text:nth-child(2) {
flex: 1;
@@ -661,7 +662,7 @@ onShareTimeline(() => {
width: 16%;
}
.rank-title-bar > text:nth-child(4) {
width: 27%;
width: 25%;
}
.strength {
font-size: 22rpx;