diff --git a/package.json b/package.json
index e069ec04d..6830a509e 100644
--- a/package.json
+++ b/package.json
@@ -30,7 +30,7 @@
"libarchive-wasm": "^1.1.0",
"mockjs": "^1.1.0",
"pinia": "^2.1.7",
- "vue": "3.4.21",
+ "vue": "^3.5.13",
"vue-router": "4.3.0"
},
"devDependencies": {
diff --git a/src/components/Comment.vue b/src/components/Comment.vue
index 3e3adf838..b80c542e8 100644
--- a/src/components/Comment.vue
+++ b/src/components/Comment.vue
@@ -255,6 +255,12 @@ export default {
_time,
_formatNumber,
_checkImgUrl,
+ // 评论发送成功后调用此方法
+ resetSelectStatus() {
+ this.friends.all.forEach((item) => {
+ item.select = false // 重置选中状态
+ })
+ },
async handShowChildren(item) {
this.loadChildrenItemCId = item.comment_id
this.loadChildren = true
@@ -268,18 +274,29 @@ export default {
}
},
send() {
- this.comments.push({
- id: '2',
- avatar: new URL('../assets/img/icon/avatar/4.png', import.meta.url).href,
- name: '成都旅行',
- text: this.comment,
- loveNum: 27,
- isLoved: false,
- time: '2021-08-24 20:33',
- children: []
- })
+ if (!this.comment.trim()) {
+ return // 如果评论内容为空,直接返回
+ }
+ const baseStore = useBaseStore()
+ const commentData = {
+ ip_location: baseStore.userinfo.ip_location,
+ aweme_id: this.videoId,
+ content: this.comment,
+ create_time: Date.now(),
+ uid: String(baseStore.userinfo.uid),
+ short_id: String(baseStore.userinfo.short_id),
+ unique_id: baseStore.userinfo.unique_id,
+ signature: baseStore.userinfo.signature,
+ nickname: baseStore.userinfo.nickname,
+ avatar: baseStore.userinfo.avatar_168x168['url_list'][0]
+ // 其他必要的字段可以根据你的需求添加
+ }
+ // this.$props.item.statistics.comment_count++
+ // _updateItem(this.$props, 'isLoved', !props.item.isLoved)
+ this.comments.unshift(commentData)
this.comment = ''
this.isCall = false
+ this.resetSelectStatus()
},
async getData() {
let res: any = await videoComments({ id: this.videoId })
diff --git a/src/components/Share.vue b/src/components/Share.vue
index b75af0beb..ad5d56183 100644
--- a/src/components/Share.vue
+++ b/src/components/Share.vue
@@ -45,14 +45,14 @@
建群并发送
- {{ store.selectFriends.length > 1 ? '分别发送' : '发送' }}
@@ -226,6 +226,11 @@ function closeShare() {
})
emit('update:modelValue', false)
}
+function shared() {
+ _notice('分享成功!')
+ store.message = ''
+ closeShare()
+}
diff --git a/src/pages/login/RetrievePassword.vue b/src/pages/login/RetrievePassword.vue
index af9eb5ba2..cafb99f41 100644
--- a/src/pages/login/RetrievePassword.vue
+++ b/src/pages/login/RetrievePassword.vue
@@ -156,5 +156,55 @@ export default {
color: black;
font-size: 14rem;
background: white;
+ .content {
+ padding: 60rem 30rem;
+
+ .desc {
+ margin-bottom: 60rem;
+ margin-top: 120rem;
+ display: flex;
+ align-items: center;
+ flex-direction: column;
+
+ .title {
+ margin-bottom: 20rem;
+ font-size: 20rem;
+ }
+
+ .phone-number {
+ letter-spacing: 3rem;
+ font-size: 30rem;
+ margin-bottom: 10rem;
+ }
+
+ .sub-title {
+ font-size: 12rem;
+ color: var(--second-text-color);
+ }
+ }
+
+ .button {
+ width: 100%;
+ margin-bottom: 5rem;
+ }
+
+ .protocol {
+ position: relative;
+ color: gray;
+ margin-top: 20rem;
+ font-size: 12rem;
+ display: flex;
+
+ .left {
+ padding-top: 1rem;
+ margin-right: 5rem;
+ }
+ }
+ .options {
+ position: relative;
+ font-size: 14rem;
+ display: flex;
+ }
+ }
}
diff --git a/src/pages/login/VerificationCode.vue b/src/pages/login/VerificationCode.vue
index d9aed12a6..18cc62d5b 100644
--- a/src/pages/login/VerificationCode.vue
+++ b/src/pages/login/VerificationCode.vue
@@ -119,6 +119,57 @@ function login() {
font-size: 14rem;
background: white;
+ .content {
+ padding: 60rem 30rem;
+
+ .desc {
+ margin-bottom: 60rem;
+ margin-top: 120rem;
+ display: flex;
+ align-items: center;
+ flex-direction: column;
+
+ .title {
+ margin-bottom: 20rem;
+ font-size: 20rem;
+ }
+
+ .phone-number {
+ letter-spacing: 3rem;
+ font-size: 30rem;
+ margin-bottom: 10rem;
+ }
+
+ .sub-title {
+ font-size: 12rem;
+ color: var(--second-text-color);
+ }
+ }
+
+ .button {
+ width: 100%;
+ margin-bottom: 5rem;
+ }
+
+ .protocol {
+ position: relative;
+ color: gray;
+ margin-top: 20rem;
+ font-size: 12rem;
+ display: flex;
+
+ .left {
+ padding-top: 1rem;
+ margin-right: 5rem;
+ }
+ }
+ .options {
+ position: relative;
+ font-size: 14rem;
+ display: flex;
+ }
+ }
+
.options {
margin-top: 10rem;
}
diff --git a/src/store/pinia.ts b/src/store/pinia.ts
index 93fab95ab..0258d4c53 100644
--- a/src/store/pinia.ts
+++ b/src/store/pinia.ts
@@ -50,7 +50,8 @@ export const useBaseStore = defineStore('base', {
}
]
},
- friends: resource.users
+ friends: resource.users,
+ message: ''
}
},
getters: {