Refactor(云灵AI):换一换动态效果实现

This commit is contained in:
lifizer
2026-04-28 09:53:04 +08:00
parent 8a1a58d14a
commit 898c3b74bc
3 changed files with 17 additions and 7 deletions
+3 -1
View File
@@ -416,10 +416,10 @@ export const chatMixinsV2 = {
} }
}) })
if (idx > -1) { if (idx > -1) {
this.$set(this.chatMessageList[idx], 'changeIsRotate', true)
if (this.chatMessageList[idx].changeIsRotate) { if (this.chatMessageList[idx].changeIsRotate) {
return return
} }
this.$set(this.chatMessageList[idx], 'changeIsRotate', true)
} }
let listKey = '' let listKey = ''
// 抽奖和订单查询没有换一换 // 抽奖和订单查询没有换一换
@@ -457,6 +457,8 @@ export const chatMixinsV2 = {
this.$set(this.chatMessageList[idx], 'changeIsRotate', false) this.$set(this.chatMessageList[idx], 'changeIsRotate', false)
}, 1000) }, 1000)
} }
}).catch(error => {
this.$set(this.chatMessageList[idx], 'changeIsRotate', false)
}) })
}, },
productItemClickHandle(item) { productItemClickHandle(item) {
+5 -2
View File
@@ -1,6 +1,9 @@
<template> <template>
<view <view
:class="scrollTop > 0 ? 'page-scroll' : ''" :class="{
'page-scroll': scrollTop > 0,
'new-chat': chatMessageListLength === 0
}"
class="fix-tabbar-page" class="fix-tabbar-page"
> >
<hx-navbar <hx-navbar
@@ -771,7 +774,7 @@ export default {
} }
.icon { .icon {
display: flex; display: flex;
width: 40rpx; width: 32rpx;
height: 32rpx; height: 32rpx;
margin: 0 8rpx 0 0; margin: 0 8rpx 0 0;
&.rotate { &.rotate {
+9 -4
View File
@@ -12,10 +12,14 @@ page {
min-height: 100vh; min-height: 100vh;
background: linear-gradient(155deg, rgba(61, 76, 241, 0.15) 0%, rgba(255,255,255,1) 25%, rgba(255,255,255,1) 75%, rgba(61, 76, 241, 0.15) 100%); background: linear-gradient(155deg, rgba(61, 76, 241, 0.15) 0%, rgba(255,255,255,1) 25%, rgba(255,255,255,1) 75%, rgba(61, 76, 241, 0.15) 100%);
// background-color: #fff; // background-color: #fff;
background-size: 100% calc(100vh - 160rpx); // background-size: 100% calc(100vh - 160rpx);
// background-image: url(https://wxapp.xdd618.com/api/file/pic/aiChat/bg.png); // background-image: url(https://wxapp.xdd618.com/api/file/pic/aiChat/bg.png);
background-repeat: no-repeat; // background-repeat: no-repeat;
// background-attachment: fixed; // background-attachment: fixed;
&.new-chat {
background-size: 100% calc(100vh - 160rpx);
background-repeat: no-repeat;
}
.fix-tabbar-header { .fix-tabbar-header {
position: fixed; position: fixed;
top: 0; top: 0;
@@ -1086,9 +1090,10 @@ page {
align-items: center; align-items: center;
justify-content: center; justify-content: center;
color: #3D4CF0; color: #3D4CF0;
font-size: 28rpx;
.icon { .icon {
display: block; display: block;
width: 40rpx; width: 32rpx;
height: 32rpx; height: 32rpx;
margin: 0 8rpx 0 0; margin: 0 8rpx 0 0;
&.rotate { &.rotate {
@@ -1351,6 +1356,6 @@ page {
transform: rotate(0deg); transform: rotate(0deg);
} }
100% { 100% {
transform: rotate(360deg); transform: rotate(720deg);
} }
} }