From 2b7ed69c213585e586f013b03c4396f0d8cfc704 Mon Sep 17 00:00:00 2001 From: kuaifan Date: Wed, 22 Feb 2023 12:17:35 +0800 Subject: [PATCH] =?UTF-8?q?perf:=20=E4=BC=98=E5=8C=96=E7=A7=BB=E5=8A=A8?= =?UTF-8?q?=E7=AB=AF=E8=AE=BE=E7=BD=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../assets/js/pages/manage/messenger.vue | 10 ++++---- .../assets/js/pages/manage/setting/index.vue | 8 +++--- resources/assets/sass/pages/page-setting.scss | 25 ++++++++++++++++--- 3 files changed, 30 insertions(+), 13 deletions(-) diff --git a/resources/assets/js/pages/manage/messenger.vue b/resources/assets/js/pages/manage/messenger.vue index a393d0d0e..b117dc0c0 100644 --- a/resources/assets/js/pages/manage/messenger.vue +++ b/resources/assets/js/pages/manage/messenger.vue @@ -508,11 +508,11 @@ export default { index = this.dialogList.findIndex(dialog => $A.getDialogUnread(dialog, true) > 0) } if (index > -1) { - const el = this.$refs[`dialog_${this.dialogList[index]?.id}`][0] - if (el) { - $A.scrollIntoViewIfNeeded(el) - el.classList.remove("common-shake") - requestAnimationFrame(_ => el.classList.add("common-shake")) + const el = this.$refs[`dialog_${this.dialogList[index]?.id}`] + if (el && el[0]) { + $A.scrollIntoViewIfNeeded(el[0]) + el[0].classList.remove("common-shake") + requestAnimationFrame(_ => el[0].classList.add("common-shake")) } } }, diff --git a/resources/assets/js/pages/manage/setting/index.vue b/resources/assets/js/pages/manage/setting/index.vue index 2c5bfe02d..f3330e051 100644 --- a/resources/assets/js/pages/manage/setting/index.vue +++ b/resources/assets/js/pages/manage/setting/index.vue @@ -5,14 +5,14 @@

{{$L(settingTitleName)}}

-
+
-
-
+
+
  • ul { padding: 12px 32px; > li { @@ -404,6 +418,9 @@ } } .setting-content { + transform: translateX(0); + opacity: 1; + padding-bottom: 16px; .setting-content-title { display: none; }