diff --git a/package-lock.json b/package-lock.json index 1403dbe..8f2b7f9 100644 --- a/package-lock.json +++ b/package-lock.json @@ -8,7 +8,7 @@ "name": "quicktranslate", "version": "0.7.0", "dependencies": { - "@tauri-apps/api": "^2", + "@tauri-apps/api": "^2.12.4", "@tauri-apps/plugin-autostart": "^2", "@tauri-apps/plugin-global-shortcut": "^2", "@tauri-apps/plugin-updater": "^2", @@ -19,7 +19,7 @@ "zustand": "^5.0.0" }, "devDependencies": { - "@tauri-apps/cli": "^2", + "@tauri-apps/cli": "^2.12.4", "@types/canvas-confetti": "^1.9.0", "@types/react": "^19.0.0", "@types/react-dom": "^19.0.0", @@ -1476,9 +1476,9 @@ "license": "MIT" }, "node_modules/@tauri-apps/api": { - "version": "2.10.1", - "resolved": "https://registry.npmmirror.com/@tauri-apps/api/-/api-2.10.1.tgz", - "integrity": "sha512-hKL/jWf293UDSUN09rR69hrToyIXBb8CjGaWC7gfinvnQrBVvnLr08FeFi38gxtugAVyVcTa5/FD/Xnkb1siBw==", + "version": "2.12.4", + "resolved": "https://registry.npmjs.org/@tauri-apps/api/-/api-2.12.4.tgz", + "integrity": "sha512-pVmfis+4zT8H0Qhp3xPZx9Ju7kpzvA6rr/PSJPyuwfvucTQ8sVt61NYU9KMkK703UFlYadFmjKA4HhybOtN0gg==", "license": "Apache-2.0 OR MIT", "funding": { "type": "opencollective", @@ -1486,9 +1486,9 @@ } }, "node_modules/@tauri-apps/cli": { - "version": "2.10.1", - "resolved": "https://registry.npmmirror.com/@tauri-apps/cli/-/cli-2.10.1.tgz", - "integrity": "sha512-jQNGF/5quwORdZSSLtTluyKQ+o6SMa/AUICfhf4egCGFdMHqWssApVgYSbg+jmrZoc8e1DscNvjTnXtlHLS11g==", + "version": "2.12.4", + "resolved": "https://registry.npmjs.org/@tauri-apps/cli/-/cli-2.12.4.tgz", + "integrity": "sha512-JI9bHfudSRJikGOrjbXEm6RjzzvmKuLc+JixB1NE8hNzQkNlCCIC3pTES3uypkR9lxHrsbxzcnSwhI2IxBQphw==", "dev": true, "license": "Apache-2.0 OR MIT", "bin": { @@ -1502,23 +1502,23 @@ "url": "https://opencollective.com/tauri" }, "optionalDependencies": { - "@tauri-apps/cli-darwin-arm64": "2.10.1", - "@tauri-apps/cli-darwin-x64": "2.10.1", - "@tauri-apps/cli-linux-arm-gnueabihf": "2.10.1", - "@tauri-apps/cli-linux-arm64-gnu": "2.10.1", - "@tauri-apps/cli-linux-arm64-musl": "2.10.1", - "@tauri-apps/cli-linux-riscv64-gnu": "2.10.1", - "@tauri-apps/cli-linux-x64-gnu": "2.10.1", - "@tauri-apps/cli-linux-x64-musl": "2.10.1", - "@tauri-apps/cli-win32-arm64-msvc": "2.10.1", - "@tauri-apps/cli-win32-ia32-msvc": "2.10.1", - "@tauri-apps/cli-win32-x64-msvc": "2.10.1" + "@tauri-apps/cli-darwin-arm64": "2.12.4", + "@tauri-apps/cli-darwin-x64": "2.12.4", + "@tauri-apps/cli-linux-arm-gnueabihf": "2.12.4", + "@tauri-apps/cli-linux-arm64-gnu": "2.12.4", + "@tauri-apps/cli-linux-arm64-musl": "2.12.4", + "@tauri-apps/cli-linux-riscv64-gnu": "2.12.4", + "@tauri-apps/cli-linux-x64-gnu": "2.12.4", + "@tauri-apps/cli-linux-x64-musl": "2.12.4", + "@tauri-apps/cli-win32-arm64-msvc": "2.12.4", + "@tauri-apps/cli-win32-ia32-msvc": "2.12.4", + "@tauri-apps/cli-win32-x64-msvc": "2.12.4" } }, "node_modules/@tauri-apps/cli-darwin-arm64": { - "version": "2.10.1", - "resolved": "https://registry.npmmirror.com/@tauri-apps/cli-darwin-arm64/-/cli-darwin-arm64-2.10.1.tgz", - "integrity": "sha512-Z2OjCXiZ+fbYZy7PmP3WRnOpM9+Fy+oonKDEmUE6MwN4IGaYqgceTjwHucc/kEEYZos5GICve35f7ZiizgqEnQ==", + "version": "2.12.4", + "resolved": "https://registry.npmjs.org/@tauri-apps/cli-darwin-arm64/-/cli-darwin-arm64-2.12.4.tgz", + "integrity": "sha512-OxqKSckIkoJ6vX2AjifIJpTasFC0Hbdoo7gEiCmAjauABO3U8m2MRsLWe+QTiBwDx1mIrvgA+rvI7tvDnbnHVg==", "cpu": [ "arm64" ], @@ -1533,9 +1533,9 @@ } }, "node_modules/@tauri-apps/cli-darwin-x64": { - "version": "2.10.1", - "resolved": "https://registry.npmmirror.com/@tauri-apps/cli-darwin-x64/-/cli-darwin-x64-2.10.1.tgz", - "integrity": "sha512-V/irQVvjPMGOTQqNj55PnQPVuH4VJP8vZCN7ajnj+ZS8Kom1tEM2hR3qbbIRoS3dBKs5mbG8yg1WC+97dq17Pw==", + "version": "2.12.4", + "resolved": "https://registry.npmjs.org/@tauri-apps/cli-darwin-x64/-/cli-darwin-x64-2.12.4.tgz", + "integrity": "sha512-fz76/77wMMJOaaUN6n3CybRG0P/MTEjjqYk81mGPyhi9m6Ue5T+LWBnJP/AkPooNatBPI2vtulGqomyMJ44lCQ==", "cpu": [ "x64" ], @@ -1550,9 +1550,9 @@ } }, "node_modules/@tauri-apps/cli-linux-arm-gnueabihf": { - "version": "2.10.1", - "resolved": "https://registry.npmmirror.com/@tauri-apps/cli-linux-arm-gnueabihf/-/cli-linux-arm-gnueabihf-2.10.1.tgz", - "integrity": "sha512-Hyzwsb4VnCWKGfTw+wSt15Z2pLw2f0JdFBfq2vHBOBhvg7oi6uhKiF87hmbXOBXUZaGkyRDkCHsdzJcIfoJC2w==", + "version": "2.12.4", + "resolved": "https://registry.npmjs.org/@tauri-apps/cli-linux-arm-gnueabihf/-/cli-linux-arm-gnueabihf-2.12.4.tgz", + "integrity": "sha512-K0w8Bof6Lt8QKLAYhRy0yy36ZH5iA/35VuSOvnxyjvCUZ+A3JKsUTlALviH/sVgAlisaPzzmeJSH8XOn4Q2HBA==", "cpu": [ "arm" ], @@ -1567,13 +1567,16 @@ } }, "node_modules/@tauri-apps/cli-linux-arm64-gnu": { - "version": "2.10.1", - "resolved": "https://registry.npmmirror.com/@tauri-apps/cli-linux-arm64-gnu/-/cli-linux-arm64-gnu-2.10.1.tgz", - "integrity": "sha512-OyOYs2t5GkBIvyWjA1+h4CZxTcdz1OZPCWAPz5DYEfB0cnWHERTnQ/SLayQzncrT0kwRoSfSz9KxenkyJoTelA==", + "version": "2.12.4", + "resolved": "https://registry.npmjs.org/@tauri-apps/cli-linux-arm64-gnu/-/cli-linux-arm64-gnu-2.12.4.tgz", + "integrity": "sha512-j5rOnjmRUwWrm1oosf0zBYl4D+fqydgUROFCk0hvKZxvbTT8SOERes0QB7rBV/XWNy+kM6pCKzb3oSm2sRglzg==", "cpu": [ "arm64" ], "dev": true, + "libc": [ + "glibc" + ], "license": "Apache-2.0 OR MIT", "optional": true, "os": [ @@ -1584,13 +1587,16 @@ } }, "node_modules/@tauri-apps/cli-linux-arm64-musl": { - "version": "2.10.1", - "resolved": "https://registry.npmmirror.com/@tauri-apps/cli-linux-arm64-musl/-/cli-linux-arm64-musl-2.10.1.tgz", - "integrity": "sha512-MIj78PDDGjkg3NqGptDOGgfXks7SYJwhiMh8SBoZS+vfdz7yP5jN18bNaLnDhsVIPARcAhE1TlsZe/8Yxo2zqg==", + "version": "2.12.4", + "resolved": "https://registry.npmjs.org/@tauri-apps/cli-linux-arm64-musl/-/cli-linux-arm64-musl-2.12.4.tgz", + "integrity": "sha512-aOue3Fy6Jb7+oWcfAVUsVHfeTybSCt2CZoU06aO4jv4d2Ks/KnaTPwMAK3CLEduGOvBLY1lbBBrIyomqLLH5Sg==", "cpu": [ "arm64" ], "dev": true, + "libc": [ + "musl" + ], "license": "Apache-2.0 OR MIT", "optional": true, "os": [ @@ -1601,13 +1607,16 @@ } }, "node_modules/@tauri-apps/cli-linux-riscv64-gnu": { - "version": "2.10.1", - "resolved": "https://registry.npmmirror.com/@tauri-apps/cli-linux-riscv64-gnu/-/cli-linux-riscv64-gnu-2.10.1.tgz", - "integrity": "sha512-X0lvOVUg8PCVaoEtEAnpxmnkwlE1gcMDTqfhbefICKDnOTJ5Est3qL0SrWxizDackIOKBcvtpejrSiVpuJI1kw==", + "version": "2.12.4", + "resolved": "https://registry.npmjs.org/@tauri-apps/cli-linux-riscv64-gnu/-/cli-linux-riscv64-gnu-2.12.4.tgz", + "integrity": "sha512-Fx6GShY/RvST+t6LMlTHAwd66+1tEaAAGrnU7cysVfaiRP1BKng5Vl6rVmO6rSLOA1Sp1dRzNYM4f0OWQGb7qA==", "cpu": [ "riscv64" ], "dev": true, + "libc": [ + "glibc" + ], "license": "Apache-2.0 OR MIT", "optional": true, "os": [ @@ -1618,13 +1627,16 @@ } }, "node_modules/@tauri-apps/cli-linux-x64-gnu": { - "version": "2.10.1", - "resolved": "https://registry.npmmirror.com/@tauri-apps/cli-linux-x64-gnu/-/cli-linux-x64-gnu-2.10.1.tgz", - "integrity": "sha512-2/12bEzsJS9fAKybxgicCDFxYD1WEI9kO+tlDwX5znWG2GwMBaiWcmhGlZ8fi+DMe9CXlcVarMTYc0L3REIRxw==", + "version": "2.12.4", + "resolved": "https://registry.npmjs.org/@tauri-apps/cli-linux-x64-gnu/-/cli-linux-x64-gnu-2.12.4.tgz", + "integrity": "sha512-tNzZSa79Z1nRpHxEpQ38lsAFpKlFlYvoXzjTV+lRRn/zSf3wrdUC3wnLcq2XEadchPu4ttK0zivhYzr+XGD19Q==", "cpu": [ "x64" ], "dev": true, + "libc": [ + "glibc" + ], "license": "Apache-2.0 OR MIT", "optional": true, "os": [ @@ -1635,13 +1647,16 @@ } }, "node_modules/@tauri-apps/cli-linux-x64-musl": { - "version": "2.10.1", - "resolved": "https://registry.npmmirror.com/@tauri-apps/cli-linux-x64-musl/-/cli-linux-x64-musl-2.10.1.tgz", - "integrity": "sha512-Y8J0ZzswPz50UcGOFuXGEMrxbjwKSPgXftx5qnkuMs2rmwQB5ssvLb6tn54wDSYxe7S6vlLob9vt0VKuNOaCIQ==", + "version": "2.12.4", + "resolved": "https://registry.npmjs.org/@tauri-apps/cli-linux-x64-musl/-/cli-linux-x64-musl-2.12.4.tgz", + "integrity": "sha512-jmZ1pr0xEqUhuEusWtt9Yt+GF6lCnGHUmIL+KIknpbjK/XQ2qkhDBhaxK/JMHM2A8dAacVXCxXJk2EXpwhQUfA==", "cpu": [ "x64" ], "dev": true, + "libc": [ + "musl" + ], "license": "Apache-2.0 OR MIT", "optional": true, "os": [ @@ -1652,9 +1667,9 @@ } }, "node_modules/@tauri-apps/cli-win32-arm64-msvc": { - "version": "2.10.1", - "resolved": "https://registry.npmmirror.com/@tauri-apps/cli-win32-arm64-msvc/-/cli-win32-arm64-msvc-2.10.1.tgz", - "integrity": "sha512-iSt5B86jHYAPJa/IlYw++SXtFPGnWtFJriHn7X0NFBVunF6zu9+/zOn8OgqIWSl8RgzhLGXQEEtGBdR4wzpVgg==", + "version": "2.12.4", + "resolved": "https://registry.npmjs.org/@tauri-apps/cli-win32-arm64-msvc/-/cli-win32-arm64-msvc-2.12.4.tgz", + "integrity": "sha512-fGo8pgEHZxdSYgZ/J98m1usJ7NHKmKbq7k6uT0x1rpOq6Bg2YVzzpaAblWk710f5LHYBJIL5QIFS5IrD+4gmTg==", "cpu": [ "arm64" ], @@ -1669,9 +1684,9 @@ } }, "node_modules/@tauri-apps/cli-win32-ia32-msvc": { - "version": "2.10.1", - "resolved": "https://registry.npmmirror.com/@tauri-apps/cli-win32-ia32-msvc/-/cli-win32-ia32-msvc-2.10.1.tgz", - "integrity": "sha512-gXyxgEzsFegmnWywYU5pEBURkcFN/Oo45EAwvZrHMh+zUSEAvO5E8TXsgPADYm31d1u7OQU3O3HsYfVBf2moHw==", + "version": "2.12.4", + "resolved": "https://registry.npmjs.org/@tauri-apps/cli-win32-ia32-msvc/-/cli-win32-ia32-msvc-2.12.4.tgz", + "integrity": "sha512-ezl8sQIcjYsye3TUnTH5VcWmWzccZASlQm7hlZt0dYyj1XD0qpVW47u2xYVrIKui0F8uQv/7QGZixdWiClBsbg==", "cpu": [ "ia32" ], @@ -1686,9 +1701,9 @@ } }, "node_modules/@tauri-apps/cli-win32-x64-msvc": { - "version": "2.10.1", - "resolved": "https://registry.npmmirror.com/@tauri-apps/cli-win32-x64-msvc/-/cli-win32-x64-msvc-2.10.1.tgz", - "integrity": "sha512-6Cn7YpPFwzChy0ERz6djKEmUehWrYlM+xTaNzGPgZocw3BD7OfwfWHKVWxXzdjEW2KfKkHddfdxK1XXTYqBRLg==", + "version": "2.12.4", + "resolved": "https://registry.npmjs.org/@tauri-apps/cli-win32-x64-msvc/-/cli-win32-x64-msvc-2.12.4.tgz", + "integrity": "sha512-DJhDeCqjLDNMWYFy7ZS8cfeAHX2RK0RbQMLiA3bMVVkXRDJ4NBYiHriGqsUhsr9iG41aTb+dJGkFPmPw1gWwVw==", "cpu": [ "x64" ], diff --git a/package.json b/package.json index d9ced47..2106376 100644 --- a/package.json +++ b/package.json @@ -11,7 +11,7 @@ "test": "vitest run" }, "dependencies": { - "@tauri-apps/api": "^2", + "@tauri-apps/api": "^2.12.4", "@tauri-apps/plugin-autostart": "^2", "@tauri-apps/plugin-global-shortcut": "^2", "@tauri-apps/plugin-updater": "^2", @@ -22,7 +22,7 @@ "zustand": "^5.0.0" }, "devDependencies": { - "@tauri-apps/cli": "^2", + "@tauri-apps/cli": "^2.12.4", "@types/canvas-confetti": "^1.9.0", "@types/react": "^19.0.0", "@types/react-dom": "^19.0.0", diff --git a/src-tauri/Cargo.lock b/src-tauri/Cargo.lock index 6570304..68aa1aa 100644 --- a/src-tauri/Cargo.lock +++ b/src-tauri/Cargo.lock @@ -66,15 +66,15 @@ dependencies = [ [[package]] name = "alloc-no-stdlib" -version = "2.0.4" +version = "3.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cc7bb162ec39d46ab1ca8c77bf72e890535becd1751bb45f64c597edb4c8c6b3" +checksum = "c2fb6cfd47bf496ff64095c20eaba0c201404ee38714d4142fcfa1dc334fcc7a" [[package]] name = "alloc-stdlib" -version = "0.2.2" +version = "0.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "94fb8275041c72129eb51b7d0322c29b8387a0386127718b096429201a5d6ece" +checksum = "0b5c1865780388bfa186411ab5f247819487fc4864c6e9c3106611fa347586e1" dependencies = [ "alloc-no-stdlib", ] @@ -312,6 +312,12 @@ version = "0.22.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "72b3254f16251a8381aa12e40e3c4d2f0199f8c6508fbecb9d91f575e0fbb8c6" +[[package]] +name = "base64" +version = "0.23.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ac07cdecf99051d9a5238b80f35af32cdeba5b336e55d957b318b50137e18da5" + [[package]] name = "bit-set" version = "0.8.0" @@ -375,9 +381,9 @@ dependencies = [ [[package]] name = "brotli" -version = "8.0.2" +version = "9.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4bd8b9603c7aa97359dbd97ecf258968c95f3adddd6db2f7e7a5bef101c84560" +checksum = "f8b851b75c23ca7873623d612fe49bd1989aeb03d08fb9432187eb253d3d4c6b" dependencies = [ "alloc-no-stdlib", "alloc-stdlib", @@ -386,9 +392,9 @@ dependencies = [ [[package]] name = "brotli-decompressor" -version = "5.0.0" +version = "6.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "874bb8112abecc98cbd6d81ea4fa7e94fb9449648c93cc89aa40c81c24d7de03" +checksum = "941cd9bd4ddab83cb46fa5a2d428f1c857b24ac78cb876cf7beb710840934bd7" dependencies = [ "alloc-no-stdlib", "alloc-stdlib", @@ -486,12 +492,13 @@ dependencies = [ [[package]] name = "cargo_toml" -version = "0.22.3" +version = "1.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "374b7c592d9c00c1f4972ea58390ac6b18cbb6ab79011f3bdc90a0b82ca06b77" +checksum = "82f4b26e751e711a5302649417f2da046dce6391b2ea30a4820f37462314f0b9" dependencies = [ + "semver", "serde", - "toml 0.9.12+spec-1.1.0", + "toml 1.1.8+spec-1.1.0", ] [[package]] @@ -521,6 +528,17 @@ dependencies = [ "uuid", ] +[[package]] +name = "cfb" +version = "0.14.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a347dcabdae9c31b0825fd6a8bed285ec9c2acb89c47827126d52fa4f59cece3" +dependencies = [ + "fnv", + "uuid", + "web-time", +] + [[package]] name = "cfg-expr" version = "0.15.8" @@ -552,7 +570,7 @@ dependencies = [ "iana-time-zone", "num-traits", "serde", - "windows-link 0.2.1", + "windows-link", ] [[package]] @@ -705,7 +723,7 @@ version = "0.29.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f93d03419cb5950ccfd3daf3ff1c7a36ace64609a1a8746d493df1ca0afde0fa" dependencies = [ - "cssparser-macros", + "cssparser-macros 0.6.1", "dtoa-short", "itoa", "matches", @@ -718,11 +736,11 @@ dependencies = [ [[package]] name = "cssparser" -version = "0.36.0" +version = "0.37.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dae61cf9c0abb83bd659dab65b7e4e38d8236824c85f0f804f173567bda257d2" +checksum = "8c9cdaae01d5ed7882b04d795e7f752f46ff52d2fa3b50a20d28c464510bba98" dependencies = [ - "cssparser-macros", + "cssparser-macros 0.7.1", "dtoa-short", "itoa", "phf 0.13.1", @@ -740,15 +758,21 @@ dependencies = [ ] [[package]] -name = "ctor" -version = "0.2.9" +name = "cssparser-macros" +version = "0.7.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "32a2785755761f3ddc1492979ce1e48d2c00d09311c39e4466429188f3dd6501" +checksum = "d045de693cb712d0b22c6a64be5b953f67b3ce00ab5ad3dd5d8b441886ab8e1a" dependencies = [ "quote", - "syn 2.0.117", + "syn 3.0.6", ] +[[package]] +name = "ctor" +version = "1.0.13" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "914a755b7c2d4af2bdcff7ce1739e2db9a1b81a9b07123d8015786ae03c0980d" + [[package]] name = "ctr" version = "0.9.2" @@ -792,6 +816,17 @@ dependencies = [ "syn 2.0.117", ] +[[package]] +name = "dbus" +version = "0.9.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3ab69f03cc8c4340c9c8e315114e1658e6775a9b16a04357973aa21cec22b32e" +dependencies = [ + "libc", + "libdbus-sys", + "windows-sys 0.61.2", +] + [[package]] name = "deranged" version = "0.5.8" @@ -876,6 +911,15 @@ dependencies = [ "dirs-sys 0.5.0", ] +[[package]] +name = "dirs" +version = "7.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8d57d423b3c82e89b9a24ca3091fee61f456a26edbd28d26c65906f4bc1dcd8f" +dependencies = [ + "dirs-sys 0.5.0", +] + [[package]] name = "dirs-sys" version = "0.3.7" @@ -947,16 +991,16 @@ dependencies = [ [[package]] name = "dom_query" -version = "0.27.0" +version = "0.28.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "521e380c0c8afb8d9a1e83a1822ee03556fc3e3e7dbc1fd30be14e37f9cb3f89" +checksum = "fac5fca71e65e94cc718a6e2af65d6e0f9c6027751c2aa562fbb5087fda639bc" dependencies = [ "bit-set", - "cssparser 0.36.0", + "cssparser 0.37.0", "foldhash 0.2.0", - "html5ever 0.38.0", + "html5ever 0.39.0", "precomputed-hash", - "selectors 0.36.1", + "selectors 0.38.0", "tendril 0.5.0", ] @@ -1453,7 +1497,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1bd49230192a3797a9a4d6abe9b3eed6f7fa4c8a8a4947977c6f80025f92cbd8" dependencies = [ "rustix", - "windows-link 0.2.1", + "windows-link", ] [[package]] @@ -1762,12 +1806,12 @@ dependencies = [ [[package]] name = "html5ever" -version = "0.38.0" +version = "0.39.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1054432bae2f14e0061e33d23402fbaa67a921d319d56adc6bcf887ddad1cbc2" +checksum = "46a1761807faccc9a19e86944bbf40610014066306f96edcdedc2fb714bcb7b8" dependencies = [ "log", - "markup5ever 0.38.0", + "markup5ever 0.39.0", ] [[package]] @@ -1881,7 +1925,7 @@ dependencies = [ "js-sys", "log", "wasm-bindgen", - "windows-core 0.62.2", + "windows-core", ] [[package]] @@ -1895,12 +1939,12 @@ dependencies = [ [[package]] name = "ico" -version = "0.5.0" +version = "0.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3e795dff5605e0f04bff85ca41b51a96b83e80b281e96231bcaaf1ac35103371" +checksum = "d75e94d66081e4d8dcd098bd8dc5254800fea14a26389b298410158d834de167" dependencies = [ "byteorder", - "png 0.17.16", + "png", ] [[package]] @@ -2028,7 +2072,7 @@ dependencies = [ "byteorder-lite", "moxcms", "num-traits", - "png 0.18.1", + "png", "tiff", ] @@ -2061,7 +2105,16 @@ version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a588916bfdfd92e71cacef98a63d9b1f0d74d6599980d11894290e7ddefffcf7" dependencies = [ - "cfb", + "cfb 0.7.3", +] + +[[package]] +name = "infer" +version = "0.22.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f4200d433cbd5178df7797c9c2e75b348b728e39631cf14520d1e2fc424201f4" +dependencies = [ + "cfb 0.14.0", ] [[package]] @@ -2176,21 +2229,21 @@ dependencies = [ [[package]] name = "json-patch" -version = "3.0.1" +version = "4.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "863726d7afb6bc2590eeff7135d923545e5e964f004c2ccf8716c25e70a86f08" +checksum = "7421438de105a0827e44fadd05377727847d717c80ce29a229f85fd04c427b72" dependencies = [ "jsonptr", "serde", "serde_json", - "thiserror 1.0.69", + "thiserror 2.0.18", ] [[package]] name = "jsonptr" -version = "0.6.3" +version = "0.7.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5dea2b27dd239b2556ed7a25ba842fe47fd602e7fc7433c2a8d6106d4d9edd70" +checksum = "a5a3cc660ba5d72bce0b3bb295bf20847ccbb40fd423f3f05b61273672e561fe" dependencies = [ "serde", "serde_json", @@ -2198,13 +2251,12 @@ dependencies = [ [[package]] name = "keyboard-types" -version = "0.7.0" +version = "0.8.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b750dcadc39a09dbadd74e118f6dd6598df77fa01df0cfcdc52c28dece74528a" +checksum = "0fbe853b403ae61a04233030ae8a79d94975281ed9770a1f9e246732b534b28d" dependencies = [ "bitflags 2.11.0", "serde", - "unicode-segmentation", ] [[package]] @@ -2261,6 +2313,15 @@ version = "0.2.184" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "48f5d2a454e16a5ea0f4ced81bd44e4cfc7bd3a507b61887c99fd3538b28e4af" +[[package]] +name = "libdbus-sys" +version = "0.2.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "328c4789d42200f1eeec05bd86c9c13c7f091d2ba9a6ea35acdf51f31bc0f043" +dependencies = [ + "pkg-config", +] + [[package]] name = "libloading" version = "0.7.4" @@ -2349,9 +2410,9 @@ dependencies = [ [[package]] name = "markup5ever" -version = "0.38.0" +version = "0.39.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8983d30f2915feeaaab2d6babdd6bc7e9ed1a00b66b5e6d74df19aa9c0e91862" +checksum = "7122d987ec5f704ee56f6e5b41a7d93722e9aae27ae07cafa4036c4d3f9757de" dependencies = [ "log", "tendril 0.5.0", @@ -2454,9 +2515,9 @@ dependencies = [ [[package]] name = "muda" -version = "0.17.2" +version = "0.20.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7c9fec5a4e89860383d778d10563a605838f8f0b2f9303868937e5ff32e86177" +checksum = "cca139e57da4383727f189e43e66e84fa372347027fc996f9f1a007ec0a37996" dependencies = [ "crossbeam-channel", "dpi", @@ -2467,10 +2528,10 @@ dependencies = [ "objc2-core-foundation", "objc2-foundation", "once_cell", - "png 0.17.16", + "png", "serde", "thiserror 2.0.18", - "windows-sys 0.60.2", + "windows-sys 0.61.2", ] [[package]] @@ -2657,6 +2718,16 @@ dependencies = [ "objc2-foundation", ] +[[package]] +name = "objc2-core-location" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ca347214e24bc973fc025fd0d36ebb179ff30536ed1f80252706db19ee452009" +dependencies = [ + "objc2", + "objc2-foundation", +] + [[package]] name = "objc2-core-text" version = "0.3.2" @@ -2752,8 +2823,27 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d87d638e33c06f577498cbcc50491496a3ed4246998a7fbba7ccb98b1e7eab22" dependencies = [ "bitflags 2.11.0", + "block2", "objc2", + "objc2-cloud-kit", + "objc2-core-data", "objc2-core-foundation", + "objc2-core-graphics", + "objc2-core-image", + "objc2-core-location", + "objc2-core-text", + "objc2-foundation", + "objc2-quartz-core", + "objc2-user-notifications", +] + +[[package]] +name = "objc2-user-notifications" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9df9128cbbfef73cda168416ccf7f837b62737d748333bfe9ab71c245d76613e" +dependencies = [ + "objc2", "objc2-foundation", ] @@ -2870,7 +2960,7 @@ dependencies = [ "libc", "redox_syscall 0.5.18", "smallvec", - "windows-link 0.2.1", + "windows-link", ] [[package]] @@ -2905,7 +2995,6 @@ version = "0.11.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1fd6780a80ae0c52cc120a26a1a42c1ae51b247a253e4e06113d23d2c2edd078" dependencies = [ - "phf_macros 0.11.3", "phf_shared 0.11.3", ] @@ -3004,19 +3093,6 @@ dependencies = [ "syn 1.0.109", ] -[[package]] -name = "phf_macros" -version = "0.11.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f84ac04429c13a7ff43785d75ad27569f2951ce0ffd30a3321230db2fc727216" -dependencies = [ - "phf_generator 0.11.3", - "phf_shared 0.11.3", - "proc-macro2", - "quote", - "syn 2.0.117", -] - [[package]] name = "phf_macros" version = "0.13.1" @@ -3108,19 +3184,6 @@ dependencies = [ "time", ] -[[package]] -name = "png" -version = "0.17.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "82151a2fc869e011c153adc57cf2789ccb8d9906ce52c0b39a6b5697749d7526" -dependencies = [ - "bitflags 1.3.2", - "crc32fast", - "fdeflate", - "flate2", - "miniz_oxide", -] - [[package]] name = "png" version = "0.18.1" @@ -3941,12 +4004,12 @@ dependencies = [ [[package]] name = "selectors" -version = "0.36.1" +version = "0.38.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c5d9c0c92a92d33f08817311cf3f2c29a3538a8240e94a6a3c622ce652d7e00c" +checksum = "8adfa1c298912827b8a28b223b3b874357397ae706e6190acd9bf28cee99114d" dependencies = [ "bitflags 2.11.0", - "cssparser 0.36.0", + "cssparser 0.37.0", "derive_more 2.1.1", "log", "new_debug_unreachable", @@ -4056,9 +4119,9 @@ dependencies = [ [[package]] name = "serde_spanned" -version = "1.1.1" +version = "1.1.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6662b5879511e06e8999a8a235d848113e942c9124f211511b16466ee2995f26" +checksum = "4e7523beb55eece201a2356bee0bbca0d1ab466c14c07703b2e0ee6d42cb0c2c" dependencies = [ "serde_core", ] @@ -4277,6 +4340,12 @@ version = "1.2.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6ce2be8dc25455e1f91df71bfa12ad37d7af1092ae736f3a6cd0e37bc7810596" +[[package]] +name = "static_vcruntime" +version = "3.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ff7589a1859b09232522bb9edf076ca7fcf14ded96685d3fa629db73023ffbb7" + [[package]] name = "string_cache" version = "0.8.9" @@ -4340,9 +4409,9 @@ checksum = "13c2bddecc57b384dee18652358fb23172facb8a2c51ccc10d74c157bdea3292" [[package]] name = "swift-rs" -version = "1.0.7" +version = "1.0.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4057c98e2e852d51fdcfca832aac7b571f6b351ad159f9eda5db1655f8d0c4d7" +checksum = "cefd87076fd385308ee4aff597256c902f1fbb4d031de1558efc12f8ffefadd9" dependencies = [ "base64 0.21.7", "serde", @@ -4417,15 +4486,16 @@ dependencies = [ [[package]] name = "tao" -version = "0.34.8" +version = "0.37.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9103edf55f2da3c82aea4c7fab7c4241032bfeea0e71fa557d98e00e7ce7cc20" +checksum = "f37f381f4e048e6cdf038b5705f8cf14ad108279d46eb968140a7b291aba9400" dependencies = [ "bitflags 2.11.0", "block2", "core-foundation", "core-graphics", "crossbeam-channel", + "dbus", "dispatch2", "dlopen2", "dpi", @@ -4441,23 +4511,24 @@ dependencies = [ "objc2", "objc2-app-kit", "objc2-foundation", - "once_cell", + "objc2-ui-kit", "parking_lot", + "percent-encoding", "raw-window-handle", "tao-macros", "unicode-segmentation", "url", "windows", - "windows-core 0.61.2", + "windows-core", "windows-version", "x11-dl", ] [[package]] name = "tao-macros" -version = "0.1.3" +version = "0.1.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f4e16beb8b2ac17db28eab8bca40e62dbfbb34c0fcdc6d9826b11b7b5d047dfd" +checksum = "5f7eeb6d99155545da6150a1795945f16ac9c178deb2a5f2e74d776107bd5849" dependencies = [ "proc-macro2", "quote", @@ -4483,14 +4554,14 @@ checksum = "61c41af27dd6d1e27b1b16b489db798443478cef1f06a660c96db617ba5de3b1" [[package]] name = "tauri" -version = "2.10.3" +version = "2.12.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "da77cc00fb9028caf5b5d4650f75e31f1ef3693459dfca7f7e506d1ecef0ba2d" +checksum = "5fb0244332cfb9cee7e2a568bf5da29a36ed8fdbd717f6f47a66b6b7b358c072" dependencies = [ "anyhow", "bytes", "cookie", - "dirs 6.0.0", + "dirs 7.0.0", "dunce", "embed_plist", "getrandom 0.3.4", @@ -4534,13 +4605,13 @@ dependencies = [ [[package]] name = "tauri-build" -version = "2.5.6" +version = "2.7.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4bbc990d1dbf57a8e1c7fa2327f2a614d8b757805603c1b9ba5c81bade09fd4d" +checksum = "adddb0e648752aaac5da9c3c3c6a68e1e87cab55e3b757b18a9441ef8c3ac614" dependencies = [ "anyhow", "cargo_toml", - "dirs 6.0.0", + "dirs 7.0.0", "glob", "heck 0.5.0", "json-patch", @@ -4548,24 +4619,25 @@ dependencies = [ "semver", "serde", "serde_json", + "static_vcruntime", + "strsim", "tauri-utils", "tauri-winres", - "toml 0.9.12+spec-1.1.0", "walkdir", ] [[package]] name = "tauri-codegen" -version = "2.5.5" +version = "2.7.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d4a24476afd977c5d5d169f72425868613d82747916dd29e0a357c84c4bd6d29" +checksum = "fb37631cf71dab5e8ab55e1bdd701e18a52653d90b78e71d0e5598b1e0a61316" dependencies = [ - "base64 0.22.1", + "base64 0.23.1", "brotli", "ico", "json-patch", "plist", - "png 0.17.16", + "png", "proc-macro2", "quote", "semver", @@ -4583,9 +4655,9 @@ dependencies = [ [[package]] name = "tauri-macros" -version = "2.5.5" +version = "2.7.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d39b349a98dadaffebb73f0a40dcd1f23c999211e5a2e744403db384d0c33de7" +checksum = "0cc38db58854c10fb5f91a887ed8bf82d3239bb92b5d8db86eda09e96d9963d1" dependencies = [ "heck 0.5.0", "proc-macro2", @@ -4653,7 +4725,7 @@ dependencies = [ "flate2", "futures-util", "http", - "infer", + "infer 0.19.0", "log", "minisign-verify", "osakit", @@ -4677,9 +4749,9 @@ dependencies = [ [[package]] name = "tauri-runtime" -version = "2.10.1" +version = "2.12.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2826d79a3297ed08cd6ea7f412644ef58e32969504bc4fbd8d7dbeabc4445ea2" +checksum = "7c55766d99cea69055904d1735b93c2049302b2e09effd462120deb5581d78e9" dependencies = [ "cookie", "dpi", @@ -4702,9 +4774,9 @@ dependencies = [ [[package]] name = "tauri-runtime-wry" -version = "2.10.1" +version = "2.12.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e11ea2e6f801d275fdd890d6c9603736012742a1c33b96d0db788c9cdebf7f9e" +checksum = "e1aa9d8b7a120f879f44fdc1053f7b7dbf416bf0bbc6a72b714dec46b782b52f" dependencies = [ "gtk", "http", @@ -4712,7 +4784,6 @@ dependencies = [ "log", "objc2", "objc2-app-kit", - "once_cell", "percent-encoding", "raw-window-handle", "softbuffer", @@ -4728,24 +4799,26 @@ dependencies = [ [[package]] name = "tauri-utils" -version = "2.8.3" +version = "2.10.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "219a1f983a2af3653f75b5747f76733b0da7ff03069c7a41901a5eb3ace4557d" +checksum = "362ab21cd4cc713f2a02b1a9b5688198b1541cfb6907c4281e9190e0f0ef4aa3" dependencies = [ "anyhow", "brotli", "cargo_metadata", "ctor", + "dom_query", "dunce", "glob", "html5ever 0.29.1", "http", - "infer", + "infer 0.22.0", "json-patch", "kuchikiki", "log", "memchr", - "phf 0.11.3", + "phf 0.13.1", + "plist", "proc-macro2", "quote", "regex", @@ -5001,13 +5074,28 @@ checksum = "cf92845e79fc2e2def6a5d828f0801e29a2f8acc037becc5ab08595c7d5e9863" dependencies = [ "indexmap 2.13.1", "serde_core", - "serde_spanned 1.1.1", + "serde_spanned 1.1.2", "toml_datetime 0.7.5+spec-1.1.0", "toml_parser", "toml_writer", "winnow 0.7.15", ] +[[package]] +name = "toml" +version = "1.1.8+spec-1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "20489e00e4d8741d6be680764cc12e270655e375a20d1011e844a9c3379e678d" +dependencies = [ + "indexmap 2.13.1", + "serde_core", + "serde_spanned 1.1.2", + "toml_datetime 1.1.2+spec-1.1.0", + "toml_parser", + "toml_writer", + "winnow 1.0.1", +] + [[package]] name = "toml_datetime" version = "0.6.3" @@ -5028,9 +5116,9 @@ dependencies = [ [[package]] name = "toml_datetime" -version = "1.1.1+spec-1.1.0" +version = "1.1.2+spec-1.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3165f65f62e28e0115a00b2ebdd37eb6f3b641855f9d636d3cd4103767159ad7" +checksum = "2b86d767906c6c42421dcba507eb9d203e779497710a47782a224bb871653053" dependencies = [ "serde_core", ] @@ -5066,25 +5154,25 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a82418ca169e235e6c399a84e395ab6debeb3bc90edc959bf0f48647c6a32d1b" dependencies = [ "indexmap 2.13.1", - "toml_datetime 1.1.1+spec-1.1.0", + "toml_datetime 1.1.2+spec-1.1.0", "toml_parser", "winnow 1.0.1", ] [[package]] name = "toml_parser" -version = "1.1.2+spec-1.1.0" +version = "1.1.5+spec-1.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a2abe9b86193656635d2411dc43050282ca48aa31c2451210f4202550afb7526" +checksum = "baa693a8032d7e1cada7d0041e96126df243179ff061456783ac7f12bda4744c" dependencies = [ "winnow 1.0.1", ] [[package]] name = "toml_writer" -version = "1.1.1+spec-1.1.0" +version = "1.1.3+spec-1.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "756daf9b1013ebe47a8776667b466417e2d4c5679d441c26230efd9ef78692db" +checksum = "06bdbd8cfc056b8d2e2e85f29b56a3bdbecb527cef81eb39e3e7b98af4652770" [[package]] name = "tower" @@ -5206,12 +5294,12 @@ dependencies = [ [[package]] name = "tray-icon" -version = "0.21.3" +version = "0.25.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a5e85aa143ceb072062fc4d6356c1b520a51d636e7bc8e77ec94be3608e5e80c" +checksum = "b2b9c52859a94554803ccd4a24b98f74148ebc73b90676d783f3490b1bff9d72" dependencies = [ "crossbeam-channel", - "dirs 6.0.0", + "dirs 7.0.0", "libappindicator", "muda", "objc2", @@ -5220,10 +5308,10 @@ dependencies = [ "objc2-core-graphics", "objc2-foundation", "once_cell", - "png 0.17.16", + "png", "serde", "thiserror 2.0.18", - "windows-sys 0.60.2", + "windows-sys 0.61.2", ] [[package]] @@ -5255,47 +5343,6 @@ dependencies = [ "windows-sys 0.61.2", ] -[[package]] -name = "unic-char-property" -version = "0.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a8c57a407d9b6fa02b4795eb81c5b6652060a15a7903ea981f3d723e6c0be221" -dependencies = [ - "unic-char-range", -] - -[[package]] -name = "unic-char-range" -version = "0.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0398022d5f700414f6b899e10b8348231abf9173fa93144cbc1a43b9793c1fbc" - -[[package]] -name = "unic-common" -version = "0.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "80d7ff825a6a654ee85a63e80f92f054f904f21e7d12da4e22f9834a4aaa35bc" - -[[package]] -name = "unic-ucd-ident" -version = "0.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e230a37c0381caa9219d67cf063aa3a375ffed5bf541a452db16e744bdab6987" -dependencies = [ - "unic-char-property", - "unic-char-range", - "unic-ucd-version", -] - -[[package]] -name = "unic-ucd-version" -version = "0.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "96bd2f2237fe450fcd0a1d2f5f4e91711124f7857ba2e964247776ebeeb7b0c4" -dependencies = [ - "unic-common", -] - [[package]] name = "unicode-ident" version = "1.0.24" @@ -5345,13 +5392,13 @@ dependencies = [ [[package]] name = "urlpattern" -version = "0.3.0" +version = "0.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "70acd30e3aa1450bc2eece896ce2ad0d178e9c079493819301573dae3c37ba6d" +checksum = "df16f50ef4cc145211879a3867ba757076b25dfee812040dcb0658bd9ae7904b" dependencies = [ + "icu_properties", "regex", "serde", - "unic-ucd-ident", "url", ] @@ -5670,16 +5717,14 @@ dependencies = [ [[package]] name = "webview2-com" -version = "0.38.2" +version = "0.39.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7130243a7a5b33c54a444e54842e6a9e133de08b5ad7b5861cd8ed9a6a5bc96a" +checksum = "3f89fca7a704cee10dcb3654c1dbb8941d1783132f1917358af75bec37a7d7e6" dependencies = [ "webview2-com-macros", "webview2-com-sys", "windows", - "windows-core 0.61.2", - "windows-implement", - "windows-interface", + "windows-core", ] [[package]] @@ -5695,13 +5740,13 @@ dependencies = [ [[package]] name = "webview2-com-sys" -version = "0.38.2" +version = "0.39.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "381336cfffd772377d291702245447a5251a2ffa5bad679c99e61bc48bacbf9c" +checksum = "b3a07132775117d6065853d9d1178157b8c90e228de47129d6bce2c7edebedfb" dependencies = [ "thiserror 2.0.18", "windows", - "windows-core 0.61.2", + "windows-core", ] [[package]] @@ -5743,52 +5788,39 @@ checksum = "712e227841d057c1ee1cd2fb22fa7e5a5461ae8e48fa2ca79ec42cfc1931183f" [[package]] name = "window-vibrancy" -version = "0.6.0" +version = "0.8.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d9bec5a31f3f9362f2258fd0e9c9dd61a9ca432e7306cc78c444258f0dce9a9c" +checksum = "111e51caca442cafd9bab396628ac4d814880eaea4e63dfd76a12e9f342b5580" dependencies = [ "objc2", "objc2-app-kit", "objc2-core-foundation", "objc2-foundation", + "objc2-quartz-core", "raw-window-handle", - "windows-sys 0.59.0", + "windows-sys 0.61.2", "windows-version", ] [[package]] name = "windows" -version = "0.61.3" +version = "0.62.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9babd3a767a4c1aef6900409f85f5d53ce2544ccdfaa86dad48c91782c6d6893" +checksum = "527fadee13e0c05939a6a05d5bd6eec6cd2e3dbd648b9f8e447c6518133d8580" dependencies = [ "windows-collections", - "windows-core 0.61.2", + "windows-core", "windows-future", - "windows-link 0.1.3", "windows-numerics", ] [[package]] name = "windows-collections" -version = "0.2.0" +version = "0.3.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3beeceb5e5cfd9eb1d76b381630e82c4241ccd0d27f1a39ed41b2760b255c5e8" +checksum = "23b2d95af1a8a14a3c7367e1ed4fc9c20e0a26e79551b1454d72583c97cc6610" dependencies = [ - "windows-core 0.61.2", -] - -[[package]] -name = "windows-core" -version = "0.61.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c0fdd3ddb90610c7638aa2b3a3ab2904fb9e5cdbecc643ddb3647212781c4ae3" -dependencies = [ - "windows-implement", - "windows-interface", - "windows-link 0.1.3", - "windows-result 0.3.4", - "windows-strings 0.4.2", + "windows-core", ] [[package]] @@ -5799,19 +5831,19 @@ checksum = "b8e83a14d34d0623b51dce9581199302a221863196a1dde71a7663a4c2be9deb" dependencies = [ "windows-implement", "windows-interface", - "windows-link 0.2.1", - "windows-result 0.4.1", - "windows-strings 0.5.1", + "windows-link", + "windows-result", + "windows-strings", ] [[package]] name = "windows-future" -version = "0.2.1" +version = "0.3.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fc6a41e98427b19fe4b73c550f060b59fa592d7d686537eebf9385621bfbad8e" +checksum = "e1d6f90251fe18a279739e78025bd6ddc52a7e22f921070ccdc67dde84c605cb" dependencies = [ - "windows-core 0.61.2", - "windows-link 0.1.3", + "windows-core", + "windows-link", "windows-threading", ] @@ -5837,12 +5869,6 @@ dependencies = [ "syn 2.0.117", ] -[[package]] -name = "windows-link" -version = "0.1.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5e6ad25900d524eaabdbbb96d20b4311e1e7ae1699af4fb28c17ae66c80d798a" - [[package]] name = "windows-link" version = "0.2.1" @@ -5851,21 +5877,12 @@ checksum = "f0805222e57f7521d6a62e36fa9163bc891acd422f971defe97d64e70d0a4fe5" [[package]] name = "windows-numerics" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9150af68066c4c5c07ddc0ce30421554771e528bde427614c61038bc2c92c2b1" -dependencies = [ - "windows-core 0.61.2", - "windows-link 0.1.3", -] - -[[package]] -name = "windows-result" -version = "0.3.4" +version = "0.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "56f42bd332cc6c8eac5af113fc0c1fd6a8fd2aa08a0119358686e5160d0586c6" +checksum = "6e2e40844ac143cdb44aead537bbf727de9b044e107a0f1220392177d15b0f26" dependencies = [ - "windows-link 0.1.3", + "windows-core", + "windows-link", ] [[package]] @@ -5874,16 +5891,7 @@ version = "0.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7781fa89eaf60850ac3d2da7af8e5242a5ea78d1a11c49bf2910bb5a73853eb5" dependencies = [ - "windows-link 0.2.1", -] - -[[package]] -name = "windows-strings" -version = "0.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "56e6c93f3a0c3b36176cb1327a4958a0353d5d166c2a35cb268ace15e91d3b57" -dependencies = [ - "windows-link 0.1.3", + "windows-link", ] [[package]] @@ -5892,7 +5900,7 @@ version = "0.5.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7837d08f69c77cf6b07689544538e017c1bfcf57e34b4c0ff58e6c2cd3b37091" dependencies = [ - "windows-link 0.2.1", + "windows-link", ] [[package]] @@ -5937,7 +5945,7 @@ version = "0.61.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ae137229bcbd6cdf0f7b80a31df61766145077ddf49416a728b02cb3921ff3fc" dependencies = [ - "windows-link 0.2.1", + "windows-link", ] [[package]] @@ -5977,7 +5985,7 @@ version = "0.53.5" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "4945f9f551b88e0d65f3db0bc25c33b8acea4d9e41163edf90dcd0b19f9069f3" dependencies = [ - "windows-link 0.2.1", + "windows-link", "windows_aarch64_gnullvm 0.53.1", "windows_aarch64_msvc 0.53.1", "windows_i686_gnu 0.53.1", @@ -5990,11 +5998,11 @@ dependencies = [ [[package]] name = "windows-threading" -version = "0.1.0" +version = "0.2.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b66463ad2e0ea3bbf808b7f1d371311c80e115c0b71d60efc142cafbcfb057a6" +checksum = "3949bd5b99cafdf1c7ca86b43ca564028dfe27d66958f2470940f73d86d75b37" dependencies = [ - "windows-link 0.1.3", + "windows-link", ] [[package]] @@ -6003,7 +6011,7 @@ version = "0.1.7" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e4060a1da109b9d0326b7262c8e12c84df67cc0dbc9e33cf49e01ccc2eb63631" dependencies = [ - "windows-link 0.2.1", + "windows-link", ] [[package]] @@ -6283,15 +6291,15 @@ checksum = "1ffae5123b2d3fc086436f8834ae3ab053a283cfac8fe0a0b8eaae044768a4c4" [[package]] name = "wry" -version = "0.54.4" +version = "0.57.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e5a8135d8676225e5744de000d4dff5a082501bf7db6a1c1495034f8c314edbc" +checksum = "a819957a01b3119af85e638a38d242af76dbc87d130dca67bfd0441072e21ff0" dependencies = [ "base64 0.22.1", "block2", "cookie", "crossbeam-channel", - "dirs 6.0.0", + "dirs 7.0.0", "dom_query", "dpi", "dunce", @@ -6320,7 +6328,7 @@ dependencies = [ "webkit2gtk-sys", "webview2-com", "windows", - "windows-core 0.61.2", + "windows-core", "windows-version", "x11-dl", ] diff --git a/src-tauri/Cargo.toml b/src-tauri/Cargo.toml index 375ce6e..7fd69fe 100644 --- a/src-tauri/Cargo.toml +++ b/src-tauri/Cargo.toml @@ -11,7 +11,9 @@ crate-type = ["staticlib", "cdylib", "rlib"] tauri-build = { version = "2", features = [] } [dependencies] -tauri = { version = "2", features = ["tray-icon", "macos-private-api"] } +# 2.12 起 tauri-utils 才有 LiquidGlass 材质变体(macOS 26+)。 +# 下限锁到 2.12:2.10/2.11 的 Effect 枚举里没有这两个变体,编译不过。 +tauri = { version = "2.12", features = ["tray-icon", "macos-private-api"] } tauri-plugin-autostart = "2" tauri-plugin-single-instance = "2" tauri-plugin-updater = "2" diff --git a/src-tauri/src/system/translation_flow.rs b/src-tauri/src/system/translation_flow.rs index 213669a..d452990 100644 --- a/src-tauri/src/system/translation_flow.rs +++ b/src-tauri/src/system/translation_flow.rs @@ -8,8 +8,16 @@ // // 依赖方向单向:coordinator → translation_flow,反向没有任何引用。 +use tauri::utils::config::WindowEffectsConfig; +use tauri::window::{Effect, EffectsBuilder}; use tauri::{AppHandle, Emitter, Manager, WebviewUrl, WebviewWindow, WebviewWindowBuilder}; +// 平台专有的材质参数,按 cfg 引入以免在另一平台产生未使用告警 +#[cfg(target_os = "windows")] +use tauri::window::Color; +#[cfg(target_os = "macos")] +use tauri::window::EffectState; + use crate::system::popup_geometry; use crate::types::{ PopupPosition, TranslationErrorPayload, TranslationLoadingPayload, TranslationResult, @@ -22,7 +30,7 @@ pub(crate) const POPUP_LABEL: &str = "popup"; const POPUP_LOGICAL_W: f64 = popup_geometry::WIDTH_NORMAL; const POPUP_LOGICAL_H: f64 = popup_geometry::HEIGHT_INITIAL; -/// 给浮窗套上系统级材质(PRD 5.4:Windows Acrylic / macOS NSVisualEffectView)。 +/// 浮窗的系统级材质声明。 /// /// 为什么必须有这一步:CSS 的 `backdrop-filter` 只能模糊「同一 webview 内 /// 已经绘制的内容」。窗口本身不透明时,窗口背后是桌面/其他应用,webview @@ -32,58 +40,101 @@ const POPUP_LOGICAL_H: f64 = popup_geometry::HEIGHT_INITIAL; /// 只有先让窗口透明(`transparent(true)`)再让 OS 画材质,背后的桌面才会 /// 真正透过来。两者缺一不可: /// - Windows:Acrylic 由 DWM 合成,需要 `transparent` + 非装饰窗口 -/// - macOS:NSVisualEffectView 需要 `macOSPrivateApi` 才允许透明背景 +/// - macOS:NSVisualEffectView / NSGlassEffectView 需要 `macOSPrivateApi` /// -/// 失败不致命:材质不可用时退回 CSS 的半透明背景(观感退化为磨砂纯色, -/// 功能不受影响),因此只记 warn。 -fn apply_popup_material(window: &WebviewWindow) { - use tauri::window::{Effect, EffectsBuilder}; - +/// 声明 ≠ 生效:这里只构造配置。真正的施加由 builder 投递到主线程队列, +/// 而 tauri 内层用 `let _ =` 丢弃了施加结果(`vibrancy::set_window_effects` +/// 恒返回 `Ok`),所以**任何返回值都不能证明材质画出来了**。能确认的只有 +/// `log_material_decision` 记下的「本机打算用哪一档」。 +fn popup_effects() -> WindowEffectsConfig { #[cfg(target_os = "windows")] - let effects = EffectsBuilder::new() - // Acrylic:Windows 10 1803+ 的实时模糊 + 噪点,最接近「液态玻璃」 - .effect(Effect::Acrylic) - // 极淡的白色着色:让深色桌面背景下文字仍可读 - .color(tauri::utils::config::Color(255, 255, 255, 18)) - .build(); + { + EffectsBuilder::new() + // Acrylic:Windows 10 1803+ 的实时模糊 + 噪点,最接近「液态玻璃」 + .effect(Effect::Acrylic) + // 极淡的白色着色。注意 Win11 22H2+ 走 DWMWA_SYSTEMBACKDROP_TYPE, + // 这个颜色会被系统静默忽略 —— 明暗改由 set_popup_theme 的 + // DWMWA_USE_IMMERSIVE_DARK_MODE 控制 + .color(Color(255, 255, 255, 18)) + .build() + } #[cfg(target_os = "macos")] - let effects = { - use tauri::window::EffectState; + { EffectsBuilder::new() - // Popover:macOS 原生弹出层材质,带正确的明暗自适应 + // macOS 26+ 的原生 Liquid Glass + .effect(Effect::LiquidGlassRegular) + // 回退档:tauri 在 Liquid Glass 返回 UnsupportedPlatformVersion + // (macOS 15 及以下)时会自动改用这一项。两项必须同时声明, + // 否则旧系统上窗口完全没有材质 .effect(Effect::Popover) + // 浮窗是 focusable(false),永远不会成为 key window。保持 + // FollowsWindowActiveState 会稳定渲染 inactive(更淡)外观, + // 与当前「玻璃偏淡」的取向一致。要改浓才换成 Active .state(EffectState::FollowsWindowActiveState) .radius(popup_geometry::RADIUS_LG) .build() - }; + } #[cfg(not(any(target_os = "windows", target_os = "macos")))] - let effects = { - let _ = Effect::Acrylic; + { EffectsBuilder::new().build() - }; - - if let Err(e) = window.set_effects(effects) { - tracing::warn!( - event = "popup_material_unavailable", - "系统级浮窗材质应用失败,退回 CSS 半透明背景: {}", - e - ); } } +/// 记录本机打算用哪一档材质。 +/// +/// 存在的理由:`set_effects` 的失败日志在 tauri 里是死代码(内层 `let _ =`), +/// 材质没画出来时日志一片空白。这条决策日志至少能区分「声明了 Liquid Glass」 +/// 与「声明了 Popover 回退」,排查时不必靠猜。 +fn log_material_decision() { + #[cfg(target_os = "windows")] + tracing::info!( + event = "popup_material_decision", + platform = "windows", + effect = "acrylic", + "浮窗材质:Windows Acrylic(Win11 22H2+ 由 DWM 系统背板承担,着色参数被忽略)" + ); + + #[cfg(target_os = "macos")] + tracing::info!( + event = "popup_material_decision", + platform = "macos", + effect = "liquid_glass_regular|popover", + "浮窗材质:macOS 26+ 用 Liquid Glass Regular,15 及以下回退 Popover" + ); + + #[cfg(not(any(target_os = "windows", target_os = "macos")))] + tracing::info!( + event = "popup_material_decision", + platform = "other", + effect = "none", + "浮窗材质:当前平台无原生材质,退回 CSS 半透明背景" + ); +} + /// 浮窗窗口的唯一构建入口。 /// /// 三条创建路径(ensure_popup_window / show_popup_loading / 未来新增) /// 共用同一份属性集:透明、无装饰、置顶、免激活。属性分散复制是这份 /// 代码里已经发生过两次漂移的地方(材质只在一条路径上缺失就会表现为 /// 「有时是玻璃有时不是」)。 +/// +/// `visible` 参数保留原语义,但**建窗一律先隐藏**,材质声明走 builder 的 +/// `effects()`,最后才按需 `show()`。 +/// +/// 为什么要这样绕一圈:`WindowEffectsConfig` 在 builder 内部是投递到主线程 +/// 队列执行的(`build_internal` 里的 `run_on_main_thread`),而 `.visible(true)` +/// 会让窗口在 `build()` 返回前就可见。两者叠加的结果是「窗口先亮出来、材质 +/// 后画上去」,首帧是一块没有玻璃的透明板。先隐藏再按序 show,队列顺序保证 +/// 材质先于可见。 fn build_popup_window( app: &AppHandle, position: (f64, f64), visible: bool, ) -> tauri::Result { + log_material_decision(); + let window = WebviewWindowBuilder::new(app, POPUP_LABEL, WebviewUrl::App("index.html#popup".into())) .title("QuickTranslate") @@ -94,16 +145,23 @@ fn build_popup_window( // 非激活窗口(Windows 上即 WS_EX_NOACTIVATE):显示时不抢焦点, // 不把用户从正在编辑的地方带走(Phase 8b / 计划第 19 节) .focusable(false) - .visible(visible) + // 始终隐藏建窗:见上方注释,可见性由末尾的 show() 决定 + .visible(false) .resizable(false) // 透明背景:CSS 的圆角与阴影需要它才能真正透出桌面, - // 也是系统级材质生效的前提(见 apply_popup_material) + // 也是系统级材质生效的前提(见 popup_effects) .transparent(true) + // 材质声明进 builder,由 build_internal 投递到主线程队列, + // 排在下面那次 show() 之前 + .effects(popup_effects()) .inner_size(POPUP_LOGICAL_W, POPUP_LOGICAL_H) .position(position.0, position.1) .build()?; - apply_popup_material(&window); + if visible { + let _ = window.show(); + } + Ok(window) } @@ -350,3 +408,45 @@ pub(crate) fn reposition_popup(app: &AppHandle, width: f64, height: f64) -> bool ); true } + +#[cfg(test)] +mod tests { + use super::*; + + /// Windows 只声明 Acrylic 一项,并带着极淡的白色着色。 + #[cfg(target_os = "windows")] + #[test] + fn windows_declares_acrylic_with_faint_white_tint() { + let config = popup_effects(); + assert_eq!(config.effects, vec![Effect::Acrylic]); + assert_eq!(config.color, Some(Color(255, 255, 255, 18))); + } + + /// macOS 必须同时声明 Liquid Glass 与回退材质。 + /// + /// 这是本模块最容易静默回归的契约:只留 LiquidGlassRegular 时, + /// macOS 26 上一切正常,macOS 15 及以下则完全没有材质 —— 而回退 + /// 逻辑在 tauri 内部,Windows 上的任何测试都看不见这个缺陷。 + #[cfg(target_os = "macos")] + #[test] + fn macos_declares_liquid_glass_with_popover_fallback() { + let config = popup_effects(); + assert_eq!( + config.effects, + vec![Effect::LiquidGlassRegular, Effect::Popover] + ); + assert_eq!( + config.state, + Some(EffectState::FollowsWindowActiveState), + "浮窗不可聚焦,保持跟随活跃态才会渲染偏淡的 inactive 外观" + ); + assert_eq!(config.radius, Some(popup_geometry::RADIUS_LG)); + } + + /// 材质声明为空时不应该被当成「有材质」传给系统。 + #[cfg(not(any(target_os = "windows", target_os = "macos")))] + #[test] + fn other_platforms_declare_no_effects() { + assert!(popup_effects().effects.is_empty()); + } +} diff --git a/src/styles/globals.css b/src/styles/globals.css index cc45c6a..b663cc2 100644 --- a/src/styles/globals.css +++ b/src/styles/globals.css @@ -59,16 +59,32 @@ --focus-ring: rgba(0, 122, 255, 0.35); /* ── Popup / Card ── */ - /* 着色层刻意极薄(0.10):实机对照(黑底白字探头,2026-10-20)证明 - Windows DWM Acrylic(DWMSBT_TRANSIENTWINDOW)本身在工作 —— 背后的 - 文字被模糊成晕影 —— 但 0.22 的白 tint + 高光渐变把材质洗成了雾白 - 平板,玻璃感全靠 0.22 那点可怜的透度硬撑。0.10 让系统材质成为绝对 - 主角;文字衬底改由 ::before 的受光渐变承担(深色背景半区更暗、 - 浅色背景半区更亮的真实玻璃行为)。0.55 的教训(闷成色块)与 0.22 - 的教训(雾白板)都写在这里供后人参考。 */ - --popup-bg: rgba(255, 255, 255, 0.10); - --popup-border: rgba(255, 255, 255, 0.50); - --popup-shadow: 0 12px 40px rgba(0, 0, 0, 0.22), 0 2px 10px rgba(0, 0, 0, 0.12), 0 0 0 0.5px rgba(0, 0, 0, 0.06); + /* 玻璃层与阅读层是两套独立的配方,不要合并: + · 玻璃层(--popup-glass-*)负责「这是一块玻璃」——极薄的着色、 + 边缘高光、外阴影。它要尽量透,让 OS 原生材质当主角。 + · 阅读层(--popup-reading-*)负责「字看得清」——只铺在正文区域, + 不铺满整个面板。 + 把可读性压进玻璃层(提高 --popup-glass-tint)是这条链路历史上反复 + 踩的坑:0.55 闷成色块,0.22 洗成雾白板。文字对比度应当由阅读层 + 和文字色解决,而不是让整块玻璃变厚。 */ + /* 实机对照(黑底白字探头,2026-10-20)证明 Windows DWM Acrylic + (DWMSBT_TRANSIENTWINDOW)本身在工作 —— 背后的文字被模糊成晕影 —— + 0.10 让系统材质成为绝对主角。 */ + --popup-glass-tint: rgba(255, 255, 255, 0.10); + --popup-glass-edge: rgba(255, 255, 255, 0.50); + --popup-glass-shadow: 0 12px 40px rgba(0, 0, 0, 0.22), 0 2px 10px rgba(0, 0, 0, 0.12), 0 0 0 0.5px rgba(0, 0, 0, 0.06); + + /* 阅读衬底:浅色主题用低纹理的白,正文用深色高对比文字。 + 0.52 是起始值,最终以真实合成截图为准(见 DECISIONS D7: + 上限 0.65,再不够就回头调文字色,不继续加厚)。 */ + --popup-reading-bg: rgba(255, 255, 255, 0.52); + --popup-reading-border: rgba(0, 0, 0, 0.06); + --popup-divider: rgba(0, 0, 0, 0.06); + + /* 浅色主题下正文用与 --text-primary 相同的深色即可:深色文字压 + 浅色衬底的对比度余量充足(实测最坏 6.66:1),不需要单独提纯。 */ + --popup-text-primary: #1D1D1F; + --card-bg: rgba(255, 255, 255, 0.60); --card-border: rgba(0, 0, 0, 0.06); --card-shadow: 0 2px 8px rgba(0, 0, 0, 0.06); @@ -121,9 +137,25 @@ --active-bg: rgba(255, 255, 255, 0.10); --focus-ring: rgba(0, 122, 255, 0.45); - --popup-bg: rgba(28, 28, 30, 0.16); - --popup-border: rgba(255, 255, 255, 0.14); - --popup-shadow: 0 14px 44px rgba(0, 0, 0, 0.55), 0 2px 12px rgba(0, 0, 0, 0.38), 0 0 0 0.5px rgba(255, 255, 255, 0.10); + --popup-glass-tint: rgba(28, 28, 30, 0.16); + --popup-glass-edge: rgba(255, 255, 255, 0.14); + --popup-glass-shadow: 0 14px 44px rgba(0, 0, 0, 0.55), 0 2px 12px rgba(0, 0, 0, 0.38), 0 0 0 0.5px rgba(255, 255, 255, 0.10); + + /* 深色阅读衬底:比浅色更需要实体感 —— 浅色文字压在深色桌面上的 + 可读性比反向更差,因此起始不透明度略高于浅色主题。 + 0.58 来自实测:最坏背景(纯白桌面 + 系统材质提亮)下, + #FFFFFF 正文的合成对比度为 5.25:1,高于 4.5 门槛。 + 配 0.56 时只有 4.95:1,余量太薄,不足以覆盖不同 DPI 与系统缩放 + 带来的合成偏差。 */ + --popup-reading-bg: rgba(28, 28, 30, 0.58); + --popup-reading-border: rgba(255, 255, 255, 0.07); + --popup-divider: rgba(255, 255, 255, 0.08); + + /* 浮窗正文专用文字色:纯白而非 --text-primary 的 #F5F5F7。 + 深色玻璃上浅灰与纯白的观感差异几乎不可见,但对比度差 0.4 个点。 + 只影响阅读衬底内的正文,设置页等其他深色界面仍用 #F5F5F7。 */ + --popup-text-primary: #FFFFFF; + --card-bg: rgba(44, 44, 46, 0.60); --card-border: rgba(255, 255, 255, 0.08); --card-shadow: 0 2px 8px rgba(0, 0, 0, 0.25); @@ -174,15 +206,15 @@ html, body, #root { 窗口本身已 transparent(true),三层才能叠出玻璃观感。 */ .popup-container { position: relative; - background: var(--popup-bg); + background: var(--popup-glass-tint); /* backdrop-filter 保留为「材质不可用平台」的兜底:Windows/macOS 上 系统材质已提供真实桌面模糊,30px 的 CSS 模糊在透明窗口上没有可采 样的内容(背后是 DWM 合成的材质,webview 采不到),等于纯空转。 */ backdrop-filter: blur(30px) saturate(185%) brightness(1.03); -webkit-backdrop-filter: blur(30px) saturate(185%) brightness(1.03); - border: 1px solid var(--popup-border); + border: 1px solid var(--popup-glass-edge); border-radius: var(--radius-lg); - box-shadow: var(--popup-shadow); + box-shadow: var(--popup-glass-shadow); overflow: hidden; /* 注:不要给 width 加 transition —— 容器是 w-full(百分比),窗口级 resize 只改 used value 不触发 transition(死代码);若真触发反而 @@ -250,6 +282,29 @@ html, body, #root { z-index: 2; } +/* ============================================================ + Popup Reading Surface — 正文阅读衬底 + ============================================================ */ + +/* 玻璃层与阅读层分离:外层(.popup-container)只管「这是一块玻璃」, + 阅读层只管「字看得清」。可读性不再由提高全窗不透明度换取。 + + 为什么只铺正文区域而不是整个面板:整块加厚会把 OS 原生材质闷掉, + 退化成色板 —— 这正是 --popup-glass-tint 反复调参想避开的结局。 + 局部衬底让标题栏、底部操作栏保持通透,只有真正要读的那几行有底。 + + 实现约束: + · 不给伪元素 —— 伪元素会挡文本选择与点击;直接用背景色 + · 不设 z-index —— 它与兄弟节点同层,自然压在光学层之上 + · 不设 pointer-events —— 衬底必须让子元素的事件正常冒泡, + 拖拽禁区判定(isDragBlockingTarget)依赖 .selectable 祖先链 */ +.popup-reading-surface { + background: var(--popup-reading-bg); + border-radius: var(--radius-md); + /* 极细内描边:让衬底与玻璃层之间有分界,而不是糊在一起 */ + box-shadow: inset 0 0 0 1px var(--popup-reading-border); +} + /* ============================================================ Popup Titlebar + Traffic Lights ============================================================ */ diff --git a/src/windows/popup/ErrorView.tsx b/src/windows/popup/ErrorView.tsx index 95b09ae..6a95ff8 100644 --- a/src/windows/popup/ErrorView.tsx +++ b/src/windows/popup/ErrorView.tsx @@ -43,8 +43,10 @@ export function ErrorView({ code, message }: ErrorViewProps) { - {/* 错误信息 */} -

+ {/* 错误信息 — 套阅读衬底:错误文本是用户此刻唯一要读的内容, + 压在裸露的玻璃上最容易在杂乱背景里读丢。只包文字,不包 + 图标和操作行,避免衬底变成一块覆盖全屏的暗板。 */} +

{displayMessage}

diff --git a/src/windows/popup/LoadingView.tsx b/src/windows/popup/LoadingView.tsx index 0778bd0..a3601f0 100644 --- a/src/windows/popup/LoadingView.tsx +++ b/src/windows/popup/LoadingView.tsx @@ -7,21 +7,22 @@ export function LoadingView() { {/* 语言标签骨架 */}
- {/* 分隔线 */} -
- - {/* 翻译结果骨架 — 多行展示结构化文本预留空间 */} -
-
-
-
-
-
-
+ {/* 翻译结果骨架 — 多行展示结构化文本预留空间。 + 套用与 ResultView 相同的阅读衬底:加载态与结果态之间若衬底 + 有无不一致,切换时会看到一块区域突然变暗,像是闪了一下。 */} +
+
+
+
+
+
+
+
+
{/* 底部操作栏骨架 */} -
+
diff --git a/src/windows/popup/ResultView.tsx b/src/windows/popup/ResultView.tsx index 2c5ac42..68245ab 100644 --- a/src/windows/popup/ResultView.tsx +++ b/src/windows/popup/ResultView.tsx @@ -49,21 +49,35 @@ export function ResultView({ result, showKeyboardHint = false }: ResultViewProps )}
- {/* ── macOS 分隔线 ── */} -
- {/* ── 翻译结果文本 ── 译文是浮窗的主角:14.5px / 500 字重(实机验证反馈 13.5px/400 - 在玻璃材质上存在感不足),行高放宽到 1.8 保证中文可读性 */} -
- {result.translated_text} + 在玻璃材质上存在感不足),行高放宽到 1.8 保证中文可读性。 + + 阅读衬底(.popup-reading-surface)只铺在这一块:标题栏和底部 + 操作栏保持通透,让 OS 原生材质仍然可见。整块面板加厚会把玻璃 + 闷成色板,那是这条链路历史上反复踩过的坑。 + + 上方不再放分隔线 —— 衬底自带内描边,再叠一条会形成双重 border。 + + maxHeight 从 360 降到 300:阅读衬底自身带来 padding(24) + 内描边(2), + 叠加标题栏、语言标签、分隔线与操作栏后,360 会让容器总高达到约 + 497px,超过后端 MAX_HEIGHT=480 的硬上限。被 clamp 的后果是译文 + 滚动区被压扁,而用户看不到「还有内容」的提示。300 留出约 43px + 余量,滚动区仍能显示约 11 行中文。 */} +
+
+ {result.translated_text} +
- {/* ── macOS 分隔线 ── */} -
+ {/* ── macOS 分隔线 ── + 上方那条已移除:阅读衬底自带内描边,再叠一条会形成双重 border。 + 这一条保留 —— 它分界的是「正文区」与「操作栏」,两者都在衬底 + 之外,需要一条线把操作栏和玻璃层分开。 */} +
{/* ── 底部操作栏 ── */}