From a8bf8e00aba0ea0df35cc165ae0fc71aa333e511 Mon Sep 17 00:00:00 2001 From: Dawn <2439646234@qq.com> Date: Sun, 18 May 2025 05:10:00 +0800 Subject: [PATCH] =?UTF-8?q?perf(component):=20:zap:=20=E4=BC=98=E5=8C=96?= =?UTF-8?q?=E7=BE=A4=E8=81=8A=E6=88=90=E5=91=98=E5=92=8C=E5=85=AC=E5=91=8A?= =?UTF-8?q?=E5=B1=95=E7=A4=BA=E3=80=81=E4=BB=A5=E5=8F=8A=E5=AE=8C=E6=88=90?= =?UTF-8?q?=E6=90=9C=E7=B4=A2=E4=BC=9A=E8=AF=9D=E5=8A=9F=E8=83=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src-tauri/Cargo.lock | 160 ++++++----- src/components/common/InfoPopover.vue | 12 +- .../rightBox/chatBox/ChatSidebar.vue | 86 +++++- src/layout/center/index.vue | 21 +- src/typings/components.d.ts | 1 + src/views/homeWindow/SearchDetails.vue | 270 +++++++++++++++--- 6 files changed, 428 insertions(+), 122 deletions(-) diff --git a/src-tauri/Cargo.lock b/src-tauri/Cargo.lock index 3a9646d1..57214f6f 100644 --- a/src-tauri/Cargo.lock +++ b/src-tauri/Cargo.lock @@ -54,7 +54,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ed7572b7ba83a31e20d1b48970ee402d2e3e0537dcfe0a3ff4d6eb7508617d43" dependencies = [ "alsa-sys", - "bitflags 2.9.0", + "bitflags 2.9.1", "cfg-if", "libc", ] @@ -371,7 +371,7 @@ version = "0.70.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f49d8fed880d473ea71efb9bf597651e77201bdd4893efe54c9e5d65ae04ce6f" dependencies = [ - "bitflags 2.9.0", + "bitflags 2.9.1", "cexpr", "clang-sys", "itertools", @@ -391,9 +391,9 @@ checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a" [[package]] name = "bitflags" -version = "2.9.0" +version = "2.9.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5c8214115b7bf84099f1309324e63141d4c5d7cc26862f97a0a857dbefe165bd" +checksum = "1b8e56985ec62d17e9c1001dc89c88ecd7dc08e47eba5ec7c29c7b5eeecde967" dependencies = [ "serde", ] @@ -504,7 +504,7 @@ version = "0.18.5" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8ca26ef0159422fb77631dc9d17b102f253b876fe1586b03b803e63a309b4ee2" dependencies = [ - "bitflags 2.9.0", + "bitflags 2.9.1", "cairo-sys-rs", "glib", "libc", @@ -567,9 +567,9 @@ dependencies = [ [[package]] name = "cc" -version = "1.2.22" +version = "1.2.23" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "32db95edf998450acc7881c932f94cd9b05c87b4b2599e8bab064753da4acfd1" +checksum = "5f4ac86a9e5bc1e2b3449ab9d7d3a6a405e3d1bb28d7b9be8614f55846ae3766" dependencies = [ "jobserver", "libc", @@ -669,7 +669,7 @@ version = "0.26.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f79398230a6e2c08f5c9760610eb6924b52aa9e7950a619602baba59dcbbdbb2" dependencies = [ - "bitflags 2.9.0", + "bitflags 2.9.1", "block", "cocoa-foundation", "core-foundation 0.10.0", @@ -685,7 +685,7 @@ version = "0.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e14045fb83be07b5acf1c0884b2180461635b433455fa35d1cd6f17f1450679d" dependencies = [ - "bitflags 2.9.0", + "bitflags 2.9.1", "block", "core-foundation 0.10.0", "core-graphics-types 0.2.0", @@ -811,7 +811,7 @@ version = "0.24.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "fa95a34622365fa5bbf40b20b75dba8dfa8c94c734aea8ac9a5ca38af14316f1" dependencies = [ - "bitflags 2.9.0", + "bitflags 2.9.1", "core-foundation 0.10.0", "core-graphics-types 0.2.0", "foreign-types 0.5.0", @@ -835,7 +835,7 @@ version = "0.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3d44a101f213f6c4cdc1853d4b78aef6db6bdfa3468798cc1d9912f4735013eb" dependencies = [ - "bitflags 2.9.0", + "bitflags 2.9.1", "core-foundation 0.10.0", "libc", ] @@ -1161,7 +1161,7 @@ version = "0.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1a0d569e003ff27784e0e14e4a594048698e0c0f0b66cabcb51511be55a7caa0" dependencies = [ - "bitflags 2.9.0", + "bitflags 2.9.1", "block2 0.6.1", "libc", "objc2 0.6.1", @@ -1173,7 +1173,7 @@ version = "0.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "89a09f22a6c6069a18470eb92d2298acf25463f14256d24778e1230d789a2aec" dependencies = [ - "bitflags 2.9.0", + "bitflags 2.9.1", "objc2 0.6.1", ] @@ -1365,9 +1365,9 @@ dependencies = [ [[package]] name = "errno" -version = "0.3.11" +version = "0.3.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "976dd42dc7e85965fe702eb8164f21f450704bdde31faefd6471dba214cb594e" +checksum = "cea14ef9355e3beab063703aa9dab15afd25f0667c341310c1e5274bb1d0da18" dependencies = [ "libc", "windows-sys 0.59.0", @@ -1881,7 +1881,7 @@ version = "0.18.5" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "233daaf6e83ae6a12a52055f568f9d7cf4671dabb78ff9560ab6da230ce00ee5" dependencies = [ - "bitflags 2.9.0", + "bitflags 2.9.1", "futures-channel", "futures-core", "futures-executor", @@ -2364,7 +2364,7 @@ dependencies = [ "js-sys", "log", "wasm-bindgen", - "windows-core 0.61.0", + "windows-core 0.61.1", ] [[package]] @@ -2688,7 +2688,7 @@ version = "0.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b750dcadc39a09dbadd74e118f6dd6598df77fa01df0cfcdc52c28dece74528a" dependencies = [ - "bitflags 2.9.0", + "bitflags 2.9.1", "serde", "unicode-segmentation", ] @@ -2798,7 +2798,7 @@ version = "0.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c0ff37bd590ca25063e35af745c343cb7a0271906fb7b37e4813e8f79f00268d" dependencies = [ - "bitflags 2.9.0", + "bitflags 2.9.1", "libc", "redox_syscall", ] @@ -3024,7 +3024,7 @@ version = "0.8.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "2076a31b7010b17a38c01907c45b945e8f11495ee4dd588309718901b1f7a5b7" dependencies = [ - "bitflags 2.9.0", + "bitflags 2.9.1", "jni-sys", "log", "ndk-sys 0.5.0+25.2.9519653", @@ -3038,7 +3038,7 @@ version = "0.9.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c3f42e7bbe13d351b6bead8286a43aac9534b82bd3cc43e47037f012ebfd62d4" dependencies = [ - "bitflags 2.9.0", + "bitflags 2.9.1", "jni-sys", "log", "ndk-sys 0.6.0+11769913", @@ -3083,7 +3083,7 @@ version = "0.30.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "74523f3a35e05aba87a1d978330aef40f67b0304ac79c1c00b294c9830543db6" dependencies = [ - "bitflags 2.9.0", + "bitflags 2.9.1", "cfg-if", "cfg_aliases", "libc", @@ -3246,7 +3246,7 @@ version = "0.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e6f29f568bec459b0ddff777cec4fe3fd8666d82d5a40ebd0ff7e66134f89bcc" dependencies = [ - "bitflags 2.9.0", + "bitflags 2.9.1", "block2 0.6.1", "libc", "objc2 0.6.1", @@ -3265,7 +3265,7 @@ version = "0.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "17614fdcd9b411e6ff1117dfb1d0150f908ba83a7df81b1f118005fe0a8ea15d" dependencies = [ - "bitflags 2.9.0", + "bitflags 2.9.1", "objc2 0.6.1", "objc2-foundation 0.3.1", ] @@ -3276,7 +3276,7 @@ version = "0.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "291fbbf7d29287518e8686417cf7239c74700fd4b607623140a7d4a3c834329d" dependencies = [ - "bitflags 2.9.0", + "bitflags 2.9.1", "objc2 0.6.1", "objc2-foundation 0.3.1", ] @@ -3287,7 +3287,7 @@ version = "0.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1c10c2894a6fed806ade6027bcd50662746363a9589d3ec9d9bef30a4e4bc166" dependencies = [ - "bitflags 2.9.0", + "bitflags 2.9.1", "dispatch2 0.3.0", "objc2 0.6.1", ] @@ -3298,7 +3298,7 @@ version = "0.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "989c6c68c13021b5c2d6b71456ebb0f9dc78d752e86a98da7c716f4f9470f5a4" dependencies = [ - "bitflags 2.9.0", + "bitflags 2.9.1", "dispatch2 0.3.0", "objc2 0.6.1", "objc2-core-foundation", @@ -3336,7 +3336,7 @@ version = "0.2.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0ee638a5da3799329310ad4cfa62fbf045d5f56e3ef5ba4149e7452dcf89d5a8" dependencies = [ - "bitflags 2.9.0", + "bitflags 2.9.1", "block2 0.5.1", "libc", "objc2 0.5.2", @@ -3348,7 +3348,7 @@ version = "0.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "900831247d2fe1a09a683278e5384cfb8c80c79fe6b166f9d14bfdde0ea1b03c" dependencies = [ - "bitflags 2.9.0", + "bitflags 2.9.1", "block2 0.6.1", "libc", "objc2 0.6.1", @@ -3361,7 +3361,7 @@ version = "0.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7282e9ac92529fa3457ce90ebb15f4ecbc383e8338060960760fa2cf75420c3c" dependencies = [ - "bitflags 2.9.0", + "bitflags 2.9.1", "objc2 0.6.1", "objc2-core-foundation", ] @@ -3372,7 +3372,7 @@ version = "0.2.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "dd0cba1276f6023976a406a14ffa85e1fdd19df6b0f737b063b95f6c8c7aadd6" dependencies = [ - "bitflags 2.9.0", + "bitflags 2.9.1", "block2 0.5.1", "objc2 0.5.2", "objc2-foundation 0.2.2", @@ -3384,7 +3384,7 @@ version = "0.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "26bb88504b5a050dbba515d2414607bf5e57dd56b107bc5f0351197a3e7bdc5d" dependencies = [ - "bitflags 2.9.0", + "bitflags 2.9.1", "objc2 0.6.1", "objc2-app-kit", "objc2-foundation 0.3.1", @@ -3396,7 +3396,7 @@ version = "0.2.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e42bee7bff906b14b167da2bac5efe6b6a07e6f7c0a21a7308d40c960242dc7a" dependencies = [ - "bitflags 2.9.0", + "bitflags 2.9.1", "block2 0.5.1", "objc2 0.5.2", "objc2-foundation 0.2.2", @@ -3409,7 +3409,7 @@ version = "0.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "90ffb6a0cd5f182dc964334388560b12a57f7b74b3e2dec5e2722aa2dfb2ccd5" dependencies = [ - "bitflags 2.9.0", + "bitflags 2.9.1", "objc2 0.6.1", "objc2-foundation 0.3.1", ] @@ -3420,7 +3420,7 @@ version = "0.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "25b1312ad7bc8a0e92adae17aa10f90aae1fb618832f9b993b022b591027daed" dependencies = [ - "bitflags 2.9.0", + "bitflags 2.9.1", "objc2 0.6.1", "objc2-core-foundation", "objc2-foundation 0.3.1", @@ -3432,7 +3432,7 @@ version = "0.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "91672909de8b1ce1c2252e95bbee8c1649c9ad9d14b9248b3d7b4c47903c47ad" dependencies = [ - "bitflags 2.9.0", + "bitflags 2.9.1", "block2 0.6.1", "objc2 0.6.1", "objc2-app-kit", @@ -3505,7 +3505,7 @@ version = "0.10.72" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "fedfea7d58a1f73118430a55da6a286e7b044961736ce96a16a17068ea25e5da" dependencies = [ - "bitflags 2.9.0", + "bitflags 2.9.1", "cfg-if", "foreign-types 0.3.2", "libc", @@ -4247,7 +4247,7 @@ version = "0.5.12" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "928fca9cf2aa042393a8325b9ead81d2f0df4cb12e1e24cef072922ccd99c5af" dependencies = [ - "bitflags 2.9.0", + "bitflags 2.9.1", ] [[package]] @@ -4501,7 +4501,7 @@ version = "0.38.44" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "fdb5bc1ae2baa591800df16c9ca78619bf65c0488b41b96ccec5d11220d8c154" dependencies = [ - "bitflags 2.9.0", + "bitflags 2.9.1", "errno", "libc", "linux-raw-sys 0.4.15", @@ -4514,7 +4514,7 @@ version = "1.0.7" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c71e83d6afe7ff64890ec6b71d6a69bb8a610ab78ce364b3352876bb4c801266" dependencies = [ - "bitflags 2.9.0", + "bitflags 2.9.1", "errno", "libc", "linux-raw-sys 0.9.4", @@ -4692,7 +4692,7 @@ version = "2.11.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "897b2245f0b511c87893af39b033e5ca9cce68824c4d7e7630b5a1d339658d02" dependencies = [ - "bitflags 2.9.0", + "bitflags 2.9.1", "core-foundation 0.9.4", "core-foundation-sys", "libc", @@ -5151,7 +5151,7 @@ checksum = "0afdd3aa7a629683c2d750c2df343025545087081ab5942593a5288855b1b7a7" dependencies = [ "atoi", "base64 0.22.1", - "bitflags 2.9.0", + "bitflags 2.9.1", "byteorder", "bytes", "crc", @@ -5194,7 +5194,7 @@ checksum = "a0bedbe1bbb5e2615ef347a5e9d8cd7680fb63e77d9dafc0f29be15e53f1ebe6" dependencies = [ "atoi", "base64 0.22.1", - "bitflags 2.9.0", + "bitflags 2.9.1", "byteorder", "crc", "dotenvy", @@ -5443,7 +5443,7 @@ version = "0.6.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3c879d448e9d986b661742763247d3693ed13609438cf3d006f51f5368a5ba6b" dependencies = [ - "bitflags 2.9.0", + "bitflags 2.9.1", "core-foundation 0.9.4", "system-configuration-sys 0.6.0", ] @@ -5487,7 +5487,7 @@ version = "0.33.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1e59c1f38e657351a2e822eadf40d6a2ad4627b9c25557bc1180ec1b3295ef82" dependencies = [ - "bitflags 2.9.0", + "bitflags 2.9.1", "core-foundation 0.10.0", "core-graphics 0.24.0", "crossbeam-channel", @@ -5515,7 +5515,7 @@ dependencies = [ "unicode-segmentation", "url", "windows 0.61.1", - "windows-core 0.61.0", + "windows-core 0.61.1", "windows-version", "x11-dl", ] @@ -6803,7 +6803,7 @@ version = "0.31.10" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "978fa7c67b0847dbd6a9f350ca2569174974cd4082737054dbb7fbb79d7d9a61" dependencies = [ - "bitflags 2.9.0", + "bitflags 2.9.1", "rustix 0.38.44", "wayland-backend", "wayland-scanner", @@ -6815,7 +6815,7 @@ version = "0.32.8" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "779075454e1e9a521794fed15886323ea0feda3f8b0fc1390f5398141310422a" dependencies = [ - "bitflags 2.9.0", + "bitflags 2.9.1", "wayland-backend", "wayland-client", "wayland-scanner", @@ -6827,7 +6827,7 @@ version = "0.3.8" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1cb6cdc73399c0e06504c437fe3cf886f25568dd5454473d565085b36d6a8bbf" dependencies = [ - "bitflags 2.9.0", + "bitflags 2.9.1", "wayland-backend", "wayland-client", "wayland-protocols", @@ -6951,7 +6951,7 @@ dependencies = [ "webview2-com-macros", "webview2-com-sys", "windows 0.61.1", - "windows-core 0.61.0", + "windows-core 0.61.1", "windows-implement", "windows-interface", ] @@ -6975,7 +6975,7 @@ checksum = "8ae2d11c4a686e4409659d7891791254cf9286d3cfe0eef54df1523533d22295" dependencies = [ "thiserror 2.0.12", "windows 0.61.1", - "windows-core 0.61.0", + "windows-core 0.61.1", ] [[package]] @@ -7082,7 +7082,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c5ee8f3d025738cb02bad7868bbb5f8a6327501e870bf51f1b455b0a2454a419" dependencies = [ "windows-collections", - "windows-core 0.61.0", + "windows-core 0.61.1", "windows-future", "windows-link", "windows-numerics", @@ -7094,7 +7094,7 @@ version = "0.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3beeceb5e5cfd9eb1d76b381630e82c4241ccd0d27f1a39ed41b2760b255c5e8" dependencies = [ - "windows-core 0.61.0", + "windows-core 0.61.1", ] [[package]] @@ -7118,25 +7118,26 @@ dependencies = [ [[package]] name = "windows-core" -version = "0.61.0" +version = "0.61.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4763c1de310c86d75a878046489e2e5ba02c649d185f21c67d4cf8a56d098980" +checksum = "46ec44dc15085cea82cf9c78f85a9114c463a369786585ad2882d1ff0b0acf40" dependencies = [ "windows-implement", "windows-interface", "windows-link", - "windows-result 0.3.2", - "windows-strings 0.4.0", + "windows-result 0.3.3", + "windows-strings 0.4.1", ] [[package]] name = "windows-future" -version = "0.2.0" +version = "0.2.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7a1d6bbefcb7b60acd19828e1bc965da6fcf18a7e39490c5f8be71e54a19ba32" +checksum = "fc6a41e98427b19fe4b73c550f060b59fa592d7d686537eebf9385621bfbad8e" dependencies = [ - "windows-core 0.61.0", + "windows-core 0.61.1", "windows-link", + "windows-threading", ] [[package]] @@ -7173,7 +7174,7 @@ version = "0.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "9150af68066c4c5c07ddc0ce30421554771e528bde427614c61038bc2c92c2b1" dependencies = [ - "windows-core 0.61.0", + "windows-core 0.61.1", "windows-link", ] @@ -7183,7 +7184,7 @@ version = "0.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "4286ad90ddb45071efd1a66dfa43eb02dd0dfbae1545ad6cc3c51cf34d7e8ba3" dependencies = [ - "windows-result 0.3.2", + "windows-result 0.3.3", "windows-strings 0.3.1", "windows-targets 0.53.0", ] @@ -7199,9 +7200,9 @@ dependencies = [ [[package]] name = "windows-result" -version = "0.3.2" +version = "0.3.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c64fd11a4fd95df68efcfee5f44a294fe71b8bc6a91993e2791938abcc712252" +checksum = "4b895b5356fc36103d0f64dd1e94dfa7ac5633f1c9dd6e80fe9ec4adef69e09d" dependencies = [ "windows-link", ] @@ -7217,9 +7218,9 @@ dependencies = [ [[package]] name = "windows-strings" -version = "0.4.0" +version = "0.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7a2ba9642430ee452d5a7aa78d72907ebe8cfda358e8cb7918a2050581322f97" +checksum = "2a7ab927b2637c19b3dbe0965e75d8f2d30bdd697a1516191cad2ec4df8fb28a" dependencies = [ "windows-link", ] @@ -7322,6 +7323,15 @@ dependencies = [ "windows_x86_64_msvc 0.53.0", ] +[[package]] +name = "windows-threading" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b66463ad2e0ea3bbf808b7f1d371311c80e115c0b71d60efc142cafbcfb057a6" +dependencies = [ + "windows-link", +] + [[package]] name = "windows-version" version = "0.1.4" @@ -7564,7 +7574,7 @@ version = "0.39.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6f42320e61fe2cfd34354ecb597f86f413484a798ba44a8ca1165c58d42da6c1" dependencies = [ - "bitflags 2.9.0", + "bitflags 2.9.1", ] [[package]] @@ -7631,7 +7641,7 @@ dependencies = [ "webkit2gtk-sys", "webview2-com", "windows 0.61.1", - "windows-core 0.61.0", + "windows-core 0.61.1", "windows-version", "x11-dl", ] @@ -7862,22 +7872,24 @@ dependencies = [ [[package]] name = "zip" -version = "2.6.1" +version = "2.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1dcb24d0152526ae49b9b96c1dcf71850ca1e0b882e4e28ed898a93c41334744" +checksum = "fabe6324e908f85a1c52063ce7aa26b68dcb7eb6dbc83a2d148403c9bc3eba50" dependencies = [ "arbitrary", "crc32fast", "crossbeam-utils", + "displaydoc", "indexmap 2.9.0", "memchr", + "thiserror 2.0.12", ] [[package]] name = "zvariant" -version = "5.5.2" +version = "5.5.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e34d60a2cff1bfddd0d4a73791fd0a4255a59e349aa0cec437cb0df7776f2450" +checksum = "9d30786f75e393ee63a21de4f9074d4c038d52c5b1bb4471f955db249f9dffb1" dependencies = [ "endi", "enumflags2", @@ -7890,9 +7902,9 @@ dependencies = [ [[package]] name = "zvariant_derive" -version = "5.5.2" +version = "5.5.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0604376d86f838e0c3f4fe6d6ee1f861a04dac9015cbbb25c25d336996c91423" +checksum = "75fda702cd42d735ccd48117b1630432219c0e9616bf6cb0f8350844ee4d9580" dependencies = [ "proc-macro-crate 3.3.0", "proc-macro2", diff --git a/src/components/common/InfoPopover.vue b/src/components/common/InfoPopover.vue index fa3f170c..49b1d832 100644 --- a/src/components/common/InfoPopover.vue +++ b/src/components/common/InfoPopover.vue @@ -105,7 +105,15 @@ 获得的徽章 @@ -159,6 +167,8 @@ const contactStore = useContactStore() const userStatusStore = useUserStatusStore() const { stateList } = storeToRefs(userStatusStore) const isCurrentUser = computed(() => useUserInfo(uid).value) +/** 头像加载状态 */ +const badgeLoadedMap = ref>({}) const avatarSrc = computed(() => AvatarUtils.getAvatarUrl(useUserInfo(uid).value.avatar as string)) /** 是否是当前登录的用户 */ const isCurrentUserUid = computed(() => userUid.value === uid) diff --git a/src/components/rightBox/chatBox/ChatSidebar.vue b/src/components/rightBox/chatBox/ChatSidebar.vue index df2262da..1405ef82 100644 --- a/src/components/rightBox/chatBox/ChatSidebar.vue +++ b/src/components/rightBox/chatBox/ChatSidebar.vue @@ -27,12 +27,20 @@ @click="handleOpenAnnoun(announNum === 0 && isAddAnnoun)">

群公告须知

- + - + + + + + + + + +

请不要把重要信息发到该群,网络不是法外之地,请遵守网络规范,否则直接删除。

@@ -43,16 +51,16 @@ - - 在线群聊成员  - @@ -77,7 +85,22 @@ + +
+ + + + + + + + + +
+ + groupStore.userList) const userList = computed(() => { // 先获取所有需要的用户ID @@ -294,6 +322,11 @@ watch( } else { filteredUserList.value = userList.value } + + // 判断成员列表是否已加载完成 + if (userList.value.length > 0 && currentLoadingRoomId.value === globalStore.currentSession?.roomId) { + isLoadingMembers.value = false + } }, { immediate: true } ) @@ -361,6 +394,9 @@ const handleOpenAnnoun = (isAdd: boolean) => { * 加载群公告 */ const handleLoadGroupAnnoun = async (roomId: string) => { + // 设置公告加载状态为加载中 + isLoadingAnnouncement.value = true + // 设置是否可以添加公告 isAddAnnoun.value = isLord.value || isAdmin.value || hasBadge6.value! // 获取群公告列表 @@ -376,6 +412,9 @@ const handleLoadGroupAnnoun = async (roomId: string) => { } announNum.value = parseInt(data.total) } + + // 加载完成后,关闭骨架屏 + isLoadingAnnouncement.value = false } /** @@ -424,6 +463,29 @@ onMounted(async () => { }) ) + // 监听会话变化 + watch( + () => globalStore.currentSession, + async (newSession, oldSession) => { + if (newSession?.type === RoomTypeEnum.GROUP) { + // 如果切换到不同的群聊会话,重置加载状态 + if (newSession?.roomId !== oldSession?.roomId) { + isLoadingMembers.value = true + isLoadingAnnouncement.value = true + currentLoadingRoomId.value = newSession.roomId + + // 重置群组数据后再加载新的群成员数据 + groupStore.resetGroupData() + await groupStore.getGroupUserList(true, newSession.roomId) + + // 初始化群公告 + await handleInitAnnoun() + } + } + }, + { immediate: true } + ) + // 初始化时获取当前群组用户的信息 if (groupUserList.value.length > 0) { await cachedStore.getBatchUserInfo(groupUserList.value.map((item) => item.uid)) diff --git a/src/layout/center/index.vue b/src/layout/center/index.vue index 22aa8c91..b0690707 100644 --- a/src/layout/center/index.vue +++ b/src/layout/center/index.vue @@ -29,14 +29,16 @@
+ :placeholder="isSearchMode ? '' : '搜索'"> @@ -150,6 +152,8 @@ const isDrag = ref(true) const currentMsg = ref() /** 搜索框文字 */ const searchText = ref('搜索') +/** 是否处于搜索模式 */ +const isSearchMode = ref(false) /** 添加面板是否显示 */ const addPanels = ref({ show: false, @@ -210,6 +214,20 @@ const handleCreateGroup = async () => { const handleSearchFocus = () => { router.push('/searchDetails') searchText.value = '' + isSearchMode.value = true + + // 延迟发送当前搜索框的值到SearchDetails组件 + setTimeout(() => { + useMitt.emit('search_input_change', searchText.value) + }, 100) +} + +// 处理搜索输入变化 +const handleSearchInputChange = (value: string) => { + // 如果处于搜索详情页面,将输入值发送到SearchDetails组件 + if (isSearchMode.value) { + useMitt.emit('search_input_change', value) + } } const closeMenu = (event: Event) => { @@ -218,6 +236,7 @@ const closeMenu = (event: Event) => { /** 判断如果点击的搜索框,就关闭消息列表 */ if (!e.matches('#search, #search *, #centerList *, #centerList') && route === '/searchDetails') { router.go(-1) + isSearchMode.value = false } } diff --git a/src/typings/components.d.ts b/src/typings/components.d.ts index 7603b57b..44b2d0f3 100644 --- a/src/typings/components.d.ts +++ b/src/typings/components.d.ts @@ -63,6 +63,7 @@ declare module 'vue' { NQrCode: typeof import('naive-ui')['NQrCode'] NRadio: typeof import('naive-ui')['NRadio'] NResult: typeof import('naive-ui')['NResult'] + NS: typeof import('naive-ui')['NS'] NScrollbar: typeof import('naive-ui')['NScrollbar'] NSelect: typeof import('naive-ui')['NSelect'] NSkeleton: typeof import('naive-ui')['NSkeleton'] diff --git a/src/views/homeWindow/SearchDetails.vue b/src/views/homeWindow/SearchDetails.vue index 1ab67378..3cfa5072 100644 --- a/src/views/homeWindow/SearchDetails.vue +++ b/src/views/homeWindow/SearchDetails.vue @@ -1,43 +1,245 @@