Compare commits

..

11 Commits

Author SHA1 Message Date
目棃
1f814bc8b5 🚀 v0.5.2 2024-08-11 15:46:05 +08:00
目棃
885fa3b19e JSBridge分辨率适配 2024-08-11 15:40:17 +08:00
目棃
82ba88a2c9 🍱 更新4.8下半数据 2024-08-09 09:30:23 +08:00
目棃
1a4d175e3d 👽️ 调整更新日志链接 2024-08-09 09:23:16 +08:00
目棃
6a39aa127b 🐛 修复窗口全屏失效 2024-08-03 21:37:55 +08:00
目棃
5c0d5f50fe ⬆️ migrate tauri-rc 2024-08-02 23:09:42 +08:00
目棃
27501acfd2 🔥 移除扫码登录模块 2024-08-02 13:16:35 +08:00
目棃
69157ea008 🐛 修复公告时间获取异常&内容渲染异常 2024-08-02 13:14:25 +08:00
目棃
db00765f7b ♻️ 重构窗体/缩放调整 2024-08-01 22:09:54 +08:00
目棃
49854367b1 🐛 修复日志目录异常 2024-07-31 19:13:16 +08:00
目棃
cab497f573 📝 更新文档 2024-07-31 18:21:56 +08:00
40 changed files with 9022 additions and 8742 deletions

View File

@@ -43,11 +43,11 @@ jobs:
- name: setup node
uses: actions/setup-node@v3
with:
node-version: 22.0.0
node-version: 22.3.0
- name: setup pnpm
uses: pnpm/action-setup@v2
with:
version: 9.5.0
version: 9.6.0
- name: remove lockfile
run: rm pnpm-lock.yaml
- name: Install frontend dependencies

View File

@@ -2,29 +2,21 @@
Author: 目棃
Description: CHANGELOG
Date: 2024-07-09
Update: 2024-07-30
Update: 2024-08-11
---
> 本文档 [`Frontmatter`](https://github.com/BTMuli/MuCli#Frontmatter) 由 [MuCli](https://github.com/BTMuli/Mucli) 自动生成于 `2024-07-09 14:16:16`
>
> 更新于 `2024-07-30 10:46:30`
> 更新于 `2024-08-11 15:43:34`
## [0.5.0](https://github.com/BTMuli/TeyvatGuide/releases/v0.5.0) (2024-07-17)
## [0.5.2](https://github.com/BTMuli/TeyvatGuide/releases/v0.5.2) (2024-08-11)
- ⬆️ 底层架构更新,升级至 `Tauri v2` [`#92`](https://github.com/BTMuli/TeyvatGuide/issues/92)
- 🐛 修复数据恢复异常
- ⬆️ 更新绝区零版块列表
- ⬆️ 适配米游社返回数据
- ⚡️ 链接解析调整
- ✨ 幻想真境剧诗适配 [`#113`](https://github.com/BTMuli/TeyvatGuide/issues/113)
- ♻️ 帖子顶部小工具添加到首页
- ⚡️ 公告链接样式调整
- ⚡️ 角色分享图添加水印
- ✨ 视频支持封面下载
- ⚡️ 咨讯页调整绝区零版块排序
- ✨ 祈愿添加 UIGF v4 支持
- 🍱 更新 4.8 版本资源 [`#115`](https://github.com/BTMuli/TeyvatGuide/issues/115)
- ✨ 材料 wiki 页面草创
- 🐛 修复日志目录异常
- ♻️ 重构窗体/缩放调整逻辑
- 🐛 修复公告时间获取异常&内容渲染异常
- 🔥 移除扫码登录模块
👽️ 调整更新日志链接
- 🍱 更新4.8下半数据
## [0.5.1](https://github.com/BTMuli/TeyvatGuide/releases/v0.5.1) (2024-07-30)
@@ -47,3 +39,20 @@ Update: 2024-07-30
- 🐛 修复公告页部分公告时间解析异常
- 🐛 调整祈愿页面抽数计算规则
- 💄 根据屏幕缩放调整应用缩放
## [0.5.0](https://github.com/BTMuli/TeyvatGuide/releases/v0.5.0) (2024-07-17)
- ⬆️ 底层架构更新,升级至 `Tauri v2` [`#92`](https://github.com/BTMuli/TeyvatGuide/issues/92)
- 🐛 修复数据恢复异常
- ⬆️ 更新绝区零版块列表
- ⬆️ 适配米游社返回数据
- ⚡️ 链接解析调整
- ✨ 幻想真境剧诗适配 [`#113`](https://github.com/BTMuli/TeyvatGuide/issues/113)
- ♻️ 帖子顶部小工具添加到首页
- ⚡️ 公告链接样式调整
- ⚡️ 角色分享图添加水印
- ✨ 视频支持封面下载
- ⚡️ 咨讯页调整绝区零版块排序
- ✨ 祈愿添加 UIGF v4 支持
- 🍱 更新 4.8 版本资源 [`#115`](https://github.com/BTMuli/TeyvatGuide/issues/115)
- ✨ 材料 wiki 页面草创

View File

@@ -2,12 +2,12 @@
Author: 目棃
Description: 说明文档
Date: 2023-03-05
Update: 2024-07-14
Update: 2024-07-31
---
> 本文档 [`Frontmatter`](https://github.com/BTMuli/MuCli#Frontmatter) 由 [MuCli](https://github.com/BTMuli/Mucli) 自动生成于 `2023-03-05 14:41:55`
>
> 更新于 `2024-07-14 08:50:43`
> 更新于 `2024-07-31 18:21:43`
![](https://img.shields.io/github/last-commit/BTMuli/TeyvatGuide?style=for-the-badge) ![](https://img.shields.io/github/commits-since/BTMuli/TeyvatGuide/latest?include_prereleases&style=for-the-badge)
@@ -33,7 +33,7 @@ Game Tool for Genshin Impact player, supports Windows and macOS.
> macOS 用户可以通过 Github Release 下载
[![GitHub release (latest by date including pre-releases)](https://img.shields.io/github/v/release/BTMuli/TeyvatGuide?include_prereleases&style=for-the-badge)](https://github.com/BTMuli/TeyvatGuide/releases/latest)
[![GitHub release (latest by date)](https://img.shields.io/github/v/release/BTMuli/TeyvatGuide?style=for-the-badge)](https://github.com/BTMuli/TeyvatGuide/releases/latest)
## 仓库概况 / Repo Stats
@@ -48,7 +48,7 @@ Game Tool for Genshin Impact player, supports Windows and macOS.
- [x] 米游社官方帖获取(支持通过 ID 获取)
- [x] 米游社各分区帖子获取(支持通过 ID 获取)
- [x] 成就管理UIAF v1.1),支持 [`YaeAchievement`](https://github.com/HolographicHat/YaeAchievement) 导入
- [x] 祈愿管理UIGF v3.00.5.0 起支持 UIGF v4.0
- [x] 祈愿管理UIGF v3.0UIGF v4.0
- [x] 留影叙佳期画片查看
- [x] 帖子收藏
@@ -66,6 +66,7 @@ Game Tool for Genshin Impact player, supports Windows and macOS.
- [x] 武器图鉴
- [x] 名片图鉴
- [x] 卡牌图鉴
- [x] 材料图鉴
- 应用功能:
- [x] 浅色/深色主题切换

View File

@@ -1,6 +1,6 @@
{
"name": "TeyvatGuide",
"version": "0.5.1",
"version": "0.5.2",
"description": "Game Tool for Genshin Impact player",
"private": true,
"type": "module",
@@ -66,15 +66,15 @@
},
"dependencies": {
"@mdi/font": "7.4.47",
"@tauri-apps/api": "2.0.0-beta.14",
"@tauri-apps/plugin-deep-link": "2.0.0-beta.9",
"@tauri-apps/plugin-dialog": "2.0.0-beta.7",
"@tauri-apps/plugin-fs": "2.0.0-beta.7",
"@tauri-apps/plugin-http": "2.0.0-beta.8",
"@tauri-apps/plugin-log": "2.0.0-beta.8",
"@tauri-apps/plugin-os": "2.0.0-beta.7",
"@tauri-apps/plugin-process": "2.0.0-beta.7",
"@tauri-apps/plugin-shell": "2.0.0-beta.8",
"@tauri-apps/api": "2.0.0-rc.0",
"@tauri-apps/plugin-deep-link": "2.0.0-beta.10",
"@tauri-apps/plugin-dialog": "2.0.0-beta.8",
"@tauri-apps/plugin-fs": "2.0.0-beta.8",
"@tauri-apps/plugin-http": "2.0.0-beta.9",
"@tauri-apps/plugin-log": "2.0.0-beta.9",
"@tauri-apps/plugin-os": "2.0.0-beta.8",
"@tauri-apps/plugin-process": "2.0.0-beta.8",
"@tauri-apps/plugin-shell": "2.0.0-beta.9",
"@tauri-apps/plugin-sql": "2.0.0-beta.7",
"ajv": "^8.17.1",
"artplayer": "^5.1.6",
@@ -84,57 +84,57 @@
"html2canvas": "^1.4.1",
"js-md5": "^0.8.3",
"jsencrypt": "^3.3.2",
"pinia": "^2.1.7",
"pinia": "^2.2.0",
"pinia-plugin-persistedstate": "^3.2.1",
"qrcode.vue": "^3.4.1",
"uuid": "^10.0.0",
"vue": "^3.4.32",
"vue": "^3.4.35",
"vue-echarts": "^6.7.3",
"vue-json-viewer": "^3.0.4",
"vue-router": "^4.4.0",
"vuetify": "^3.6.13",
"vue-router": "^4.4.2",
"vuetify": "^3.6.14",
"wcag-color": "^1.1.1",
"xml-js": "^1.6.11"
},
"devDependencies": {
"@eslint/eslintrc": "^3.1.0",
"@eslint/js": "^9.7.0",
"@eslint/js": "^9.8.0",
"@tauri-apps/cli": "2.0.0-beta.21",
"@types/color-convert": "^2.0.3",
"@types/js-md5": "^0.7.2",
"@types/node": "^20.14.11",
"@types/node": "^22.1.0",
"@types/uuid": "^10.0.0",
"@typescript-eslint/parser": "^7.16.1",
"@vitejs/plugin-vue": "^5.0.5",
"@typescript-eslint/parser": "^8.0.0",
"@vitejs/plugin-vue": "^5.1.2",
"concurrently": "^8.2.2",
"eslint": "^9.7.0",
"eslint-config-love": "^56.0.0",
"eslint": "^9.8.0",
"eslint-config-love": "^62.0.0",
"eslint-config-prettier": "^9.1.0",
"eslint-plugin-import": "^2.29.1",
"eslint-plugin-jsonc": "^2.16.0",
"eslint-plugin-n": "^17.9.0",
"eslint-plugin-n": "^17.10.1",
"eslint-plugin-prettier": "^5.2.1",
"eslint-plugin-promise": "^6.4.0",
"eslint-plugin-promise": "^7.0.0",
"eslint-plugin-vue": "^9.27.0",
"eslint-plugin-yml": "^1.14.0",
"globals": "^15.8.0",
"husky": "^9.1.0",
"globals": "^15.9.0",
"husky": "^9.1.4",
"jsonc-eslint-parser": "^2.4.0",
"lint-staged": "^15.2.7",
"oxlint": "^0.6.1",
"prettier": "3.3.3",
"stylelint": "^16.7.0",
"stylelint": "^16.8.1",
"stylelint-config-idiomatic-order": "^10.0.0",
"stylelint-config-standard-vue": "^1.0.0",
"stylelint-declaration-block-no-ignored-properties": "^2.8.0",
"stylelint-high-performance-animation": "^1.10.0",
"stylelint-order": "^6.0.4",
"stylelint-prettier": "^5.0.2",
"typescript": "^5.5.3",
"typescript-eslint": "^7.16.1",
"vite": "^5.3.4",
"typescript": "^5.5.4",
"typescript-eslint": "^8.0.0",
"vite": "^5.3.5",
"vite-plugin-node-polyfills": "^0.22.0",
"vite-plugin-vue-devtools": "^7.3.6",
"vite-plugin-vue-devtools": "^7.3.7",
"vite-plugin-vuetify": "^2.0.3",
"vue-eslint-parser": "^9.4.3",
"yaml-eslint-parser": "^1.2.3"

1172
pnpm-lock.yaml generated

File diff suppressed because it is too large Load Diff

301
src-tauri/Cargo.lock generated
View File

@@ -4,7 +4,7 @@ version = 3
[[package]]
name = "TeyvatGuide"
version = "0.5.1"
version = "0.5.2"
dependencies = [
"chrono",
"log",
@@ -60,7 +60,6 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "e89da841a80418a9b391ebaea17f5c112ffaaa96f621d2c285b5174da76b9011"
dependencies = [
"cfg-if",
"getrandom 0.2.15",
"once_cell",
"version_check",
"zerocopy",
@@ -163,7 +162,7 @@ version = "0.7.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "20cd0e2e25ea8e5f7e9df04578dc6cf5c83577fd09b1a46aaf5c85e1c33f2a7e"
dependencies = [
"event-listener 5.3.1",
"event-listener",
"event-listener-strategy",
"futures-core",
"pin-project-lite",
@@ -230,7 +229,7 @@ version = "3.4.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "ff6e472cdea888a4bd64f342f09b3f50e1886d32afe8df3d663c01140b811b18"
dependencies = [
"event-listener 5.3.1",
"event-listener",
"event-listener-strategy",
"pin-project-lite",
]
@@ -248,7 +247,7 @@ dependencies = [
"async-task",
"blocking",
"cfg-if",
"event-listener 5.3.1",
"event-listener",
"futures-lite",
"rustix",
"tracing",
@@ -263,7 +262,7 @@ checksum = "3b43422f69d8ff38f95f1b2bb76517c91589a924d1559a0e935d7c8ce0274c11"
dependencies = [
"proc-macro2",
"quote",
"syn 2.0.71",
"syn 2.0.72",
]
[[package]]
@@ -298,7 +297,7 @@ checksum = "6e0c28dcc82d7c8ead5cb13beb15405b57b8546e93215673ff8ca0349a028107"
dependencies = [
"proc-macro2",
"quote",
"syn 2.0.71",
"syn 2.0.72",
]
[[package]]
@@ -462,7 +461,7 @@ dependencies = [
"proc-macro-crate 2.0.2",
"proc-macro2",
"quote",
"syn 2.0.71",
"syn 2.0.72",
"syn_derive",
]
@@ -528,9 +527,9 @@ dependencies = [
[[package]]
name = "bytemuck"
version = "1.16.1"
version = "1.16.3"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "b236fc92302c97ed75b38da1f4917b5cdda4984745740f153a5d3059e48d725e"
checksum = "102087e286b4677862ea56cf8fc58bb2cdfa8725c40ffb80fe3a008eb7f2fc83"
[[package]]
name = "byteorder"
@@ -616,9 +615,9 @@ dependencies = [
[[package]]
name = "cc"
version = "1.1.5"
version = "1.1.7"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "324c74f2155653c90b04f25b2a47a8a631360cb908f92a772695f430c7e31052"
checksum = "26a5c3fd7bfa1ce3897a3a3501d362b2d87b7f2583ebcb4a949ec25911025cbc"
[[package]]
name = "cesu8"
@@ -926,7 +925,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "13b588ba4ac1a99f7f2964d24b3d896ddc6bf847ee3855dbd4366f058cfcd331"
dependencies = [
"quote",
"syn 2.0.71",
"syn 2.0.72",
]
[[package]]
@@ -936,7 +935,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "edb49164822f3ee45b17acd4a208cfc1251410cf0cad9a833234c9890774dd9f"
dependencies = [
"quote",
"syn 2.0.71",
"syn 2.0.72",
]
[[package]]
@@ -960,7 +959,7 @@ dependencies = [
"proc-macro2",
"quote",
"strsim",
"syn 2.0.71",
"syn 2.0.72",
]
[[package]]
@@ -971,7 +970,7 @@ checksum = "d336a2a514f6ccccaa3e09b02d41d35330c07ddf03a62165fcec10bb561c7806"
dependencies = [
"darling_core",
"quote",
"syn 2.0.71",
"syn 2.0.72",
]
[[package]]
@@ -1022,7 +1021,7 @@ dependencies = [
"proc-macro2",
"quote",
"rustc_version",
"syn 2.0.71",
"syn 2.0.72",
]
[[package]]
@@ -1084,7 +1083,7 @@ checksum = "f2b99bf03862d7f545ebc28ddd33a665b50865f4dfd84031a393823879bd4c54"
dependencies = [
"proc-macro2",
"quote",
"syn 2.0.71",
"syn 2.0.72",
]
[[package]]
@@ -1149,9 +1148,9 @@ dependencies = [
[[package]]
name = "embed-resource"
version = "2.4.2"
version = "2.4.3"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "c6985554d0688b687c5cb73898a34fbe3ad6c24c58c238a4d91d5e840670ee9d"
checksum = "4edcacde9351c33139a41e3c97eb2334351a81a2791bebb0b243df837128f602"
dependencies = [
"cc",
"memchr",
@@ -1200,14 +1199,14 @@ checksum = "de0d48a183585823424a4ce1aa132d174a6a81bd540895822eb4c8373a8e49e8"
dependencies = [
"proc-macro2",
"quote",
"syn 2.0.71",
"syn 2.0.72",
]
[[package]]
name = "env_filter"
version = "0.1.0"
version = "0.1.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "a009aa4810eb158359dda09d0c87378e4bbb89b5a801f016885a4707ba24f7ea"
checksum = "4f2c92ceda6ceec50f43169f9ee8424fe2db276791afde7b2cd8bc084cb376ab"
dependencies = [
"log",
"regex",
@@ -1250,12 +1249,6 @@ dependencies = [
"windows-sys 0.48.0",
]
[[package]]
name = "event-listener"
version = "2.5.3"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "0206175f82b8d6bf6652ff7d71a1e27fd2e4efde587fd368662814d6ec1d9ce0"
[[package]]
name = "event-listener"
version = "5.3.1"
@@ -1273,7 +1266,7 @@ version = "0.5.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "0f214dc438f977e6d4e3500aaa277f5ad94ca83fbbd9b1a15713ce2344ccc5a1"
dependencies = [
"event-listener 5.3.1",
"event-listener",
"pin-project-lite",
]
@@ -1356,7 +1349,7 @@ checksum = "1a5c6c585bc94aaf2c7b51dd4c2ba22680844aba4c687be581871a6f518c5742"
dependencies = [
"proc-macro2",
"quote",
"syn 2.0.71",
"syn 2.0.72",
]
[[package]]
@@ -1455,7 +1448,7 @@ checksum = "87750cf4b7a4c0625b1529e4c543c2182106e4dedc60a2a6455e00d212c489ac"
dependencies = [
"proc-macro2",
"quote",
"syn 2.0.71",
"syn 2.0.72",
]
[[package]]
@@ -1722,7 +1715,7 @@ dependencies = [
"proc-macro-error",
"proc-macro2",
"quote",
"syn 2.0.71",
"syn 2.0.72",
]
[[package]]
@@ -1801,7 +1794,7 @@ dependencies = [
"proc-macro-error",
"proc-macro2",
"quote",
"syn 2.0.71",
"syn 2.0.72",
]
[[package]]
@@ -1844,9 +1837,9 @@ dependencies = [
[[package]]
name = "hashlink"
version = "0.8.4"
version = "0.9.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "e8094feaf31ff591f651a2664fb9cfd92bba7a60ce3197265e9482ebe753c8f7"
checksum = "6ba4ff7128dee98c7dc9794b6a411377e1404dba1c97deb8d1a55297bd25d8af"
dependencies = [
"hashbrown 0.14.5",
]
@@ -1856,9 +1849,6 @@ name = "heck"
version = "0.4.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "95505c38b4572b2d910cecb0281560f54b440a19336cbbcb27bf6ce6adc6f5a8"
dependencies = [
"unicode-segmentation",
]
[[package]]
name = "heck"
@@ -2315,9 +2305,9 @@ dependencies = [
[[package]]
name = "libsqlite3-sys"
version = "0.27.0"
version = "0.28.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "cf4e226dcd58b4be396f7bd3c20da8fdee2911400705297ba7d2d7cc2c30f716"
checksum = "0c10584274047cb335c23d3e61bcef8e323adae7c5c8c760540f73610177fc3f"
dependencies = [
"cc",
"pkg-config",
@@ -2457,13 +2447,14 @@ dependencies = [
[[package]]
name = "mio"
version = "0.8.11"
version = "1.0.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "a4a650543ca06a924e8b371db273b2756685faae30f8487da1b56505a8f78b0c"
checksum = "4569e456d394deccd22ce1c1913e6ea0e54519f577285001215d33557431afe4"
dependencies = [
"hermit-abi 0.3.9",
"libc",
"wasi 0.11.0+wasi-snapshot-preview1",
"windows-sys 0.48.0",
"windows-sys 0.52.0",
]
[[package]]
@@ -2611,16 +2602,6 @@ dependencies = [
"libm",
]
[[package]]
name = "num_cpus"
version = "1.16.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "4161fcb6d602d4d2081af7c3a45852d875a03dd337a6bfdd6e06407b61342a43"
dependencies = [
"hermit-abi 0.3.9",
"libc",
]
[[package]]
name = "num_enum"
version = "0.5.11"
@@ -2792,9 +2773,9 @@ dependencies = [
[[package]]
name = "object"
version = "0.36.1"
version = "0.36.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "081b846d1d56ddfc18fdf1a922e4f6e07a11768ea1b92dec44e42b72712ccfce"
checksum = "3f203fa8daa7bb185f760ae12bd8e097f63d17041dcdcaf675ac54cdf863170e"
dependencies = [
"memchr",
]
@@ -3054,7 +3035,7 @@ dependencies = [
"phf_shared 0.11.2",
"proc-macro2",
"quote",
"syn 2.0.71",
"syn 2.0.72",
]
[[package]]
@@ -3101,7 +3082,7 @@ checksum = "2f38a4412a78282e09a2cf38d195ea5420d15ba0602cb375210efbc877243965"
dependencies = [
"proc-macro2",
"quote",
"syn 2.0.71",
"syn 2.0.72",
]
[[package]]
@@ -3203,9 +3184,13 @@ checksum = "439ee305def115ba05938db6eb1644ff94165c5ab5e9420d1c1bcedbba909391"
[[package]]
name = "ppv-lite86"
version = "0.2.17"
version = "0.2.19"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "5b40af805b3121feab8a3c29f04d8ad262fa8e0561883e7653e024ae4479e6de"
checksum = "2288c0e17cc8d342c712bb43a257a80ebffce59cdb33d5000d8348f3ec02528b"
dependencies = [
"zerocopy",
"zerocopy-derive",
]
[[package]]
name = "precomputed-hash"
@@ -3353,14 +3338,13 @@ dependencies = [
[[package]]
name = "quinn-udp"
version = "0.5.2"
version = "0.5.4"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "9096629c45860fc7fb143e125eb826b5e721e10be3263160c7d60ca832cf8c46"
checksum = "8bffec3605b73c6f1754535084a85229fa8a30f86014e6c81aeec4abb68b0285"
dependencies = [
"libc",
"once_cell",
"socket2",
"tracing",
"windows-sys 0.52.0",
]
@@ -3754,9 +3738,9 @@ dependencies = [
[[package]]
name = "rustls"
version = "0.23.11"
version = "0.23.12"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "4828ea528154ae444e5a642dbb7d5623354030dc9822b83fd9bb79683c7399d0"
checksum = "c58f8c84392efc0a126acce10fa59ff7b3d2ac06ab451a33f2741989b806b044"
dependencies = [
"once_cell",
"ring",
@@ -3784,9 +3768,9 @@ checksum = "976295e77ce332211c0d24d92c0e83e50f5c5f046d11082cea19f3df13a3562d"
[[package]]
name = "rustls-webpki"
version = "0.102.5"
version = "0.102.6"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "f9a6fccd794a42c2c105b513a2f62bc3fd8f3ba57a4593677ceb0bd035164d78"
checksum = "8e6b52d4fda176fd835fdc55a835d4a89b8499cad995885a21149d5ad62f852e"
dependencies = [
"ring",
"rustls-pki-types",
@@ -3837,7 +3821,7 @@ dependencies = [
"proc-macro2",
"quote",
"serde_derive_internals",
"syn 2.0.71",
"syn 2.0.72",
]
[[package]]
@@ -3915,7 +3899,7 @@ checksum = "e0cd7e117be63d3c3678776753929474f3b04a43a080c744d6b0ae2a8c28e222"
dependencies = [
"proc-macro2",
"quote",
"syn 2.0.71",
"syn 2.0.72",
]
[[package]]
@@ -3926,16 +3910,17 @@ checksum = "18d26a20a969b9e3fdf2fc2d9f21eda6c40e2de84c9408bb5d3b05d499aae711"
dependencies = [
"proc-macro2",
"quote",
"syn 2.0.71",
"syn 2.0.72",
]
[[package]]
name = "serde_json"
version = "1.0.120"
version = "1.0.122"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "4e0d21c9a8cae1235ad58a00c11cb40d4b1e5c784f1ef2c537876ed6ffd8b7c5"
checksum = "784b6203951c57ff748476b126ccb5e8e2959a5c19e5c617ab1956be3dbc68da"
dependencies = [
"itoa 1.0.11",
"memchr",
"ryu",
"serde",
]
@@ -3948,14 +3933,14 @@ checksum = "6c64451ba24fc7a6a2d60fc75dd9c83c90903b19028d4eff35e88fc1e86564e9"
dependencies = [
"proc-macro2",
"quote",
"syn 2.0.71",
"syn 2.0.72",
]
[[package]]
name = "serde_spanned"
version = "0.6.6"
version = "0.6.7"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "79e674e01f999af37c49f70a6ede167a8a60b2503e56c5599532a65baa5969a0"
checksum = "eb5b1b31579f3811bf615c144393417496f152e12ac8b7663bf664f4a815306d"
dependencies = [
"serde",
]
@@ -3999,7 +3984,7 @@ dependencies = [
"darling",
"proc-macro2",
"quote",
"syn 2.0.71",
"syn 2.0.72",
]
[[package]]
@@ -4126,6 +4111,9 @@ name = "smallvec"
version = "1.13.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67"
dependencies = [
"serde",
]
[[package]]
name = "socket2"
@@ -4217,9 +4205,9 @@ dependencies = [
[[package]]
name = "sqlx"
version = "0.7.4"
version = "0.8.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "c9a2ccff1a000a5a59cd33da541d9f2fdcd9e6e8229cc200565942bff36d0aaa"
checksum = "27144619c6e5802f1380337a209d2ac1c431002dd74c6e60aebff3c506dc4f0c"
dependencies = [
"sqlx-core",
"sqlx-macros",
@@ -4230,23 +4218,23 @@ dependencies = [
[[package]]
name = "sqlx-core"
version = "0.7.4"
version = "0.8.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "24ba59a9342a3d9bab6c56c118be528b27c9b60e490080e9711a04dccac83ef6"
checksum = "a999083c1af5b5d6c071d34a708a19ba3e02106ad82ef7bbd69f5e48266b613b"
dependencies = [
"ahash 0.8.11",
"atoi",
"byteorder",
"bytes",
"crc",
"crossbeam-queue",
"either",
"event-listener 2.5.3",
"event-listener",
"futures-channel",
"futures-core",
"futures-intrusive",
"futures-io",
"futures-util",
"hashbrown 0.14.5",
"hashlink",
"hex",
"indexmap 2.2.6",
@@ -4270,26 +4258,26 @@ dependencies = [
[[package]]
name = "sqlx-macros"
version = "0.7.4"
version = "0.8.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "4ea40e2345eb2faa9e1e5e326db8c34711317d2b5e08d0d5741619048a803127"
checksum = "a23217eb7d86c584b8cbe0337b9eacf12ab76fe7673c513141ec42565698bb88"
dependencies = [
"proc-macro2",
"quote",
"sqlx-core",
"sqlx-macros-core",
"syn 1.0.109",
"syn 2.0.72",
]
[[package]]
name = "sqlx-macros-core"
version = "0.7.4"
version = "0.8.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "5833ef53aaa16d860e92123292f1f6a3d53c34ba8b1969f152ef1a7bb803f3c8"
checksum = "1a099220ae541c5db479c6424bdf1b200987934033c2584f79a0e1693601e776"
dependencies = [
"dotenvy",
"either",
"heck 0.4.1",
"heck 0.5.0",
"hex",
"once_cell",
"proc-macro2",
@@ -4301,7 +4289,7 @@ dependencies = [
"sqlx-mysql",
"sqlx-postgres",
"sqlx-sqlite",
"syn 1.0.109",
"syn 2.0.72",
"tempfile",
"tokio",
"url",
@@ -4309,12 +4297,12 @@ dependencies = [
[[package]]
name = "sqlx-mysql"
version = "0.7.4"
version = "0.8.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "1ed31390216d20e538e447a7a9b959e06ed9fc51c37b514b46eb758016ecd418"
checksum = "5afe4c38a9b417b6a9a5eeffe7235d0a106716495536e7727d1c7f4b1ff3eba6"
dependencies = [
"atoi",
"base64 0.21.7",
"base64 0.22.1",
"bitflags 2.6.0",
"byteorder",
"bytes",
@@ -4352,12 +4340,12 @@ dependencies = [
[[package]]
name = "sqlx-postgres"
version = "0.7.4"
version = "0.8.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "7c824eb80b894f926f89a0b9da0c7f435d27cdd35b8c655b114e58223918577e"
checksum = "b1dbb157e65f10dbe01f729339c06d239120221c9ad9fa0ba8408c4cc18ecf21"
dependencies = [
"atoi",
"base64 0.21.7",
"base64 0.22.1",
"bitflags 2.6.0",
"byteorder",
"crc",
@@ -4391,9 +4379,9 @@ dependencies = [
[[package]]
name = "sqlx-sqlite"
version = "0.7.4"
version = "0.8.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "b244ef0a8414da0bed4bb1910426e890b19e5e9bccc27ada6b797d05c55ae0aa"
checksum = "9b2cdd83c008a622d94499c0006d8ee5f821f36c89b7d625c900e5dc30b5c5ee"
dependencies = [
"atoi",
"flume",
@@ -4406,11 +4394,11 @@ dependencies = [
"log",
"percent-encoding",
"serde",
"serde_urlencoded",
"sqlx-core",
"time",
"tracing",
"url",
"urlencoding",
]
[[package]]
@@ -4507,9 +4495,9 @@ dependencies = [
[[package]]
name = "syn"
version = "2.0.71"
version = "2.0.72"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "b146dcf730474b4bcd16c311627b31ede9ab149045db4d6088b3becaea046462"
checksum = "dc4b9b9bf2add8093d3f2c0204471e951b2285580335de42f9d2534f3ae7a8af"
dependencies = [
"proc-macro2",
"quote",
@@ -4525,7 +4513,7 @@ dependencies = [
"proc-macro-error",
"proc-macro2",
"quote",
"syn 2.0.71",
"syn 2.0.72",
]
[[package]]
@@ -4635,15 +4623,15 @@ checksum = "55937e1799185b12863d447f42597ed69d9928686b8d88a1df17376a097d8369"
[[package]]
name = "target-lexicon"
version = "0.12.15"
version = "0.12.16"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "4873307b7c257eddcb50c9bedf158eb669578359fb28428bef438fec8e6ba7c2"
checksum = "61c41af27dd6d1e27b1b16b489db798443478cef1f06a660c96db617ba5de3b1"
[[package]]
name = "tauri"
version = "2.0.0-beta.24"
version = "2.0.0-rc.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "3eab508aad4ae86e23865e294b20a7bb89bd7afea523897b7478329b841d4295"
checksum = "255e746089a370802ec4eb896dccc6f27c1dd2a203c1dc484fd996db954e2300"
dependencies = [
"anyhow",
"bytes",
@@ -4690,9 +4678,9 @@ dependencies = [
[[package]]
name = "tauri-build"
version = "2.0.0-beta.19"
version = "2.0.0-rc.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "498f587026501e4bbc5d6273b63f8956b03c37b3d3b2027f9c756fcd468e9c62"
checksum = "85ceb8d082c3b17b4b2eb134a39363a22c696ddba473d6e5c0ab1caadad4cfca"
dependencies = [
"anyhow",
"cargo_toml",
@@ -4712,9 +4700,9 @@ dependencies = [
[[package]]
name = "tauri-codegen"
version = "2.0.0-beta.19"
version = "2.0.0-rc.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "43bbc731067e319ef60601bf5716d1e706ee9ae28e38c0587f7165c7d6824cdf"
checksum = "2407c7d37a491b16e530445c9611d91091cae198eea2ed424913b740215605f2"
dependencies = [
"base64 0.22.1",
"brotli",
@@ -4728,7 +4716,7 @@ dependencies = [
"serde",
"serde_json",
"sha2",
"syn 2.0.71",
"syn 2.0.72",
"tauri-utils",
"thiserror",
"time",
@@ -4739,14 +4727,14 @@ dependencies = [
[[package]]
name = "tauri-macros"
version = "2.0.0-beta.19"
version = "2.0.0-rc.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "36b4a44346577ccde75a24c62405a4c3b4f7a3a76614ee6cf1ed14a0b756795c"
checksum = "d210893b693be00f569b4f54456803debe104b7675f368205f2b6e94bac09b34"
dependencies = [
"heck 0.5.0",
"proc-macro2",
"quote",
"syn 2.0.71",
"syn 2.0.72",
"tauri-codegen",
"tauri-utils",
]
@@ -4771,7 +4759,7 @@ dependencies = [
[[package]]
name = "tauri-plugin-deep-link"
version = "2.0.0-beta.9"
source = "git+https://github.com/tauri-apps/plugins-workspace?branch=v2#93bdb6d133b89d990ddd5470536edfe4cb617e89"
source = "git+https://github.com/tauri-apps/plugins-workspace?branch=v2#e847cedc1f46f3e7a2ad81ea579b620bc5b992d7"
dependencies = [
"dunce",
"log",
@@ -4790,7 +4778,7 @@ dependencies = [
[[package]]
name = "tauri-plugin-dialog"
version = "2.0.0-beta.11"
source = "git+https://github.com/tauri-apps/plugins-workspace?branch=v2#93bdb6d133b89d990ddd5470536edfe4cb617e89"
source = "git+https://github.com/tauri-apps/plugins-workspace?branch=v2#e847cedc1f46f3e7a2ad81ea579b620bc5b992d7"
dependencies = [
"dunce",
"log",
@@ -4807,7 +4795,7 @@ dependencies = [
[[package]]
name = "tauri-plugin-fs"
version = "2.0.0-beta.11"
source = "git+https://github.com/tauri-apps/plugins-workspace?branch=v2#93bdb6d133b89d990ddd5470536edfe4cb617e89"
source = "git+https://github.com/tauri-apps/plugins-workspace?branch=v2#e847cedc1f46f3e7a2ad81ea579b620bc5b992d7"
dependencies = [
"anyhow",
"glob",
@@ -4825,7 +4813,7 @@ dependencies = [
[[package]]
name = "tauri-plugin-http"
version = "2.0.0-beta.12"
source = "git+https://github.com/tauri-apps/plugins-workspace?branch=v2#93bdb6d133b89d990ddd5470536edfe4cb617e89"
source = "git+https://github.com/tauri-apps/plugins-workspace?branch=v2#e847cedc1f46f3e7a2ad81ea579b620bc5b992d7"
dependencies = [
"data-url",
"http",
@@ -4845,8 +4833,8 @@ dependencies = [
[[package]]
name = "tauri-plugin-log"
version = "2.0.0-beta.8"
source = "git+https://github.com/tauri-apps/plugins-workspace?branch=v2#93bdb6d133b89d990ddd5470536edfe4cb617e89"
version = "2.0.0-beta.9"
source = "git+https://github.com/tauri-apps/plugins-workspace?branch=v2#e847cedc1f46f3e7a2ad81ea579b620bc5b992d7"
dependencies = [
"android_logger",
"byte-unit",
@@ -4860,13 +4848,14 @@ dependencies = [
"swift-rs",
"tauri",
"tauri-plugin",
"thiserror",
"time",
]
[[package]]
name = "tauri-plugin-os"
version = "2.0.0-beta.8"
source = "git+https://github.com/tauri-apps/plugins-workspace?branch=v2#93bdb6d133b89d990ddd5470536edfe4cb617e89"
source = "git+https://github.com/tauri-apps/plugins-workspace?branch=v2#e847cedc1f46f3e7a2ad81ea579b620bc5b992d7"
dependencies = [
"gethostname",
"log",
@@ -4883,7 +4872,7 @@ dependencies = [
[[package]]
name = "tauri-plugin-process"
version = "2.0.0-beta.8"
source = "git+https://github.com/tauri-apps/plugins-workspace?branch=v2#93bdb6d133b89d990ddd5470536edfe4cb617e89"
source = "git+https://github.com/tauri-apps/plugins-workspace?branch=v2#e847cedc1f46f3e7a2ad81ea579b620bc5b992d7"
dependencies = [
"tauri",
"tauri-plugin",
@@ -4892,7 +4881,7 @@ dependencies = [
[[package]]
name = "tauri-plugin-shell"
version = "2.0.0-beta.9"
source = "git+https://github.com/tauri-apps/plugins-workspace?branch=v2#93bdb6d133b89d990ddd5470536edfe4cb617e89"
source = "git+https://github.com/tauri-apps/plugins-workspace?branch=v2#e847cedc1f46f3e7a2ad81ea579b620bc5b992d7"
dependencies = [
"encoding_rs",
"log",
@@ -4912,7 +4901,7 @@ dependencies = [
[[package]]
name = "tauri-plugin-single-instance"
version = "2.0.0-beta.11"
source = "git+https://github.com/tauri-apps/plugins-workspace?branch=v2#93bdb6d133b89d990ddd5470536edfe4cb617e89"
source = "git+https://github.com/tauri-apps/plugins-workspace?branch=v2#e847cedc1f46f3e7a2ad81ea579b620bc5b992d7"
dependencies = [
"log",
"serde",
@@ -4925,8 +4914,8 @@ dependencies = [
[[package]]
name = "tauri-plugin-sql"
version = "2.0.0-beta.9"
source = "git+https://github.com/tauri-apps/plugins-workspace?branch=v2#93bdb6d133b89d990ddd5470536edfe4cb617e89"
version = "2.0.0-beta.10"
source = "git+https://github.com/tauri-apps/plugins-workspace?branch=v2#e847cedc1f46f3e7a2ad81ea579b620bc5b992d7"
dependencies = [
"futures-core",
"indexmap 2.2.6",
@@ -4943,9 +4932,9 @@ dependencies = [
[[package]]
name = "tauri-runtime"
version = "2.0.0-beta.20"
version = "2.0.0-rc.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "fe978df03966febbebc608931dc2cf26ef94df70855a18b05f07134cf474de09"
checksum = "6624fdf383ccafc9e8ad9205fe6e5c976b318efcd6b3662dde658c74e4254792"
dependencies = [
"dpi",
"gtk",
@@ -4962,9 +4951,9 @@ dependencies = [
[[package]]
name = "tauri-runtime-wry"
version = "2.0.0-beta.20"
version = "2.0.0-rc.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "11e4d568f61095f507b3fc4254dfbfff3b20de2a1d66167ffca3f6d90b14db8f"
checksum = "9fd1a785c4281f8231b091593393b40cb3a800810c407b1ffed52de27ff1640a"
dependencies = [
"cocoa",
"gtk",
@@ -4986,9 +4975,9 @@ dependencies = [
[[package]]
name = "tauri-utils"
version = "2.0.0-beta.19"
version = "2.0.0-rc.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "e20e51856f343c503892749b27d34042e6ca83a0369a12de3c5552d9874d04e8"
checksum = "6f435eeaae1e69cf93cf19da0f727989eed2e5eb6fc63a8d21432f59dd3ac4ac"
dependencies = [
"brotli",
"cargo_metadata",
@@ -5060,22 +5049,22 @@ checksum = "8eaa81235c7058867fa8c0e7314f33dcce9c215f535d1913822a2b3f5e289f3c"
[[package]]
name = "thiserror"
version = "1.0.62"
version = "1.0.63"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "f2675633b1499176c2dff06b0856a27976a8f9d436737b4cf4f312d4d91d8bbb"
checksum = "c0342370b38b6a11b6cc11d6a805569958d54cfa061a29969c3b5ce2ea405724"
dependencies = [
"thiserror-impl",
]
[[package]]
name = "thiserror-impl"
version = "1.0.62"
version = "1.0.63"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "d20468752b09f49e909e55a5d338caa8bedf615594e9d80bc4c565d30faf798c"
checksum = "a4558b58466b9ad7ca0f102865eccc95938dca1a74a856f2b57b6629050da261"
dependencies = [
"proc-macro2",
"quote",
"syn 2.0.71",
"syn 2.0.72",
]
[[package]]
@@ -5147,32 +5136,31 @@ checksum = "1f3ccbac311fea05f86f61904b462b55fb3df8837a366dfc601a0161d0532f20"
[[package]]
name = "tokio"
version = "1.38.1"
version = "1.39.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "eb2caba9f80616f438e09748d5acda951967e1ea58508ef53d9c6402485a46df"
checksum = "daa4fb1bc778bd6f04cbfc4bb2d06a7396a8f299dc33ea1900cedaa316f467b1"
dependencies = [
"backtrace",
"bytes",
"libc",
"mio",
"num_cpus",
"pin-project-lite",
"signal-hook-registry",
"socket2",
"tokio-macros",
"tracing",
"windows-sys 0.48.0",
"windows-sys 0.52.0",
]
[[package]]
name = "tokio-macros"
version = "2.3.0"
version = "2.4.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "5f5ae998a069d4b5aba8ee9dad856af7d520c3699e6159b185c2acd48155d39a"
checksum = "693d596312e88961bc67d7f1f97af8a70227d9f90c31bba5806eec004978d752"
dependencies = [
"proc-macro2",
"quote",
"syn 2.0.71",
"syn 2.0.72",
]
[[package]]
@@ -5316,7 +5304,7 @@ checksum = "34704c8d6ebcbc939824180af020566b01a7c01f80641264eba0999f6c2b6be7"
dependencies = [
"proc-macro2",
"quote",
"syn 2.0.71",
"syn 2.0.72",
]
[[package]]
@@ -5511,12 +5499,6 @@ dependencies = [
"serde",
]
[[package]]
name = "urlencoding"
version = "2.1.3"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "daf8dba3b7eb870caf1ddeed7bc9d2a049f3cfdfae7cb521b087cc33ae4c49da"
[[package]]
name = "urlpattern"
version = "0.2.0"
@@ -5577,9 +5559,9 @@ checksum = "852e951cb7832cb45cb1169900d19760cfa39b82bc0ea9c0e5a14ae88411c98b"
[[package]]
name = "version_check"
version = "0.9.4"
version = "0.9.5"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "49874b5167b65d7193b8aba1567f5c7d93d001cafc34600cee003eda787e483f"
checksum = "0b928f33d975fc6ad9f86c8f283853ad26bdd5b10b7f1542aa2fa15e2289105a"
[[package]]
name = "vswhom"
@@ -5659,7 +5641,7 @@ dependencies = [
"once_cell",
"proc-macro2",
"quote",
"syn 2.0.71",
"syn 2.0.72",
"wasm-bindgen-shared",
]
@@ -5693,7 +5675,7 @@ checksum = "e94f17b526d0a461a191c78ea52bbce64071ed5c04c9ffe424dcb38f74171bb7"
dependencies = [
"proc-macro2",
"quote",
"syn 2.0.71",
"syn 2.0.72",
"wasm-bindgen-backend",
"wasm-bindgen-shared",
]
@@ -5802,7 +5784,7 @@ checksum = "ac1345798ecd8122468840bcdf1b95e5dc6d2206c5e4b0eafa078d061f59c9bc"
dependencies = [
"proc-macro2",
"quote",
"syn 2.0.71",
"syn 2.0.72",
]
[[package]]
@@ -5918,7 +5900,7 @@ checksum = "9107ddc059d5b6fbfbffdfa7a7fe3e22a226def0b2608f72e9d552763d3e1ad7"
dependencies = [
"proc-macro2",
"quote",
"syn 2.0.71",
"syn 2.0.72",
]
[[package]]
@@ -5929,7 +5911,7 @@ checksum = "29bee4b38ea3cde66011baa44dba677c432a78593e202392d1e9070cf2a7fca7"
dependencies = [
"proc-macro2",
"quote",
"syn 2.0.71",
"syn 2.0.72",
]
[[package]]
@@ -6304,7 +6286,7 @@ dependencies = [
"blocking",
"derivative",
"enumflags2",
"event-listener 5.3.1",
"event-listener",
"futures-core",
"futures-sink",
"futures-util",
@@ -6357,6 +6339,7 @@ version = "0.7.35"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "1b9b4fd18abc82b8136838da5d50bae7bdea537c574d8dc1a34ed098d6c166f0"
dependencies = [
"byteorder",
"zerocopy-derive",
]
@@ -6368,7 +6351,7 @@ checksum = "fa4f8080344d4671fb4e831a13ad1e68092748387dfc4f55e356242fae12ce3e"
dependencies = [
"proc-macro2",
"quote",
"syn 2.0.71",
"syn 2.0.72",
]
[[package]]

View File

@@ -1,6 +1,6 @@
[package]
name = "TeyvatGuide"
version = "0.5.1"
version = "0.5.2"
description = "Game Tool for Genshin Impact player"
authors = ["BTMuli <bt-muli@outlook.com>"]
license = "MIT"
@@ -16,9 +16,9 @@ tauri-build = { version = "2.0.0-beta.19", features = [] }
chrono = "0.4.38"
log = "0.4.22"
serde = { version = "1.0.204", features = ["derive"] }
serde_json = "1.0.120"
tauri = { version = "2.0.0-beta.24", features = [] }
tauri-utils = "2.0.0-beta.19"
serde_json = "1.0.122"
tauri = { version = "2.0.0-rc.0", features = [] }
tauri-utils = "2.0.0-rc.0"
url = "2.5.2"
walkdir = "2.5.0"

View File

@@ -4,28 +4,28 @@
"description": "Capability for the dev json window",
"windows": ["Dev_JSON"],
"permissions": [
"app:allow-version",
"app:default",
"event:allow-listen",
"event:default",
"core:app:allow-version",
"core:app:default",
"core:event:allow-listen",
"core:event:default",
"http:allow-fetch",
"log:allow-log",
"log:default",
"path:allow-resolve-directory",
"path:default",
"core:path:allow-resolve-directory",
"core:path:default",
"sql:allow-load",
"sql:allow-execute",
"sql:default",
"webview:allow-set-webview-zoom",
"webview:default",
"window:allow-center",
"window:allow-close",
"window:allow-destroy",
"window:allow-set-size",
"window:allow-set-title",
"window:allow-set-fullscreen",
"window:allow-show",
"window:default",
"core:webview:allow-set-webview-zoom",
"core:webview:default",
"core:window:allow-center",
"core:window:allow-close",
"core:window:allow-destroy",
"core:window:allow-set-size",
"core:window:allow-set-title",
"core:window:allow-set-fullscreen",
"core:window:allow-show",
"core:window:default",
{
"identifier": "http:default",
"allow": [

View File

@@ -6,14 +6,14 @@
"permissions": [
"dialog:allow-message",
"dialog:default",
"event:allow-emit",
"core:event:allow-emit",
"http:allow-fetch",
"webview:allow-set-webview-zoom",
"webview:default",
"window:allow-center",
"window:default",
"path:allow-resolve-directory",
"path:default",
"core:webview:allow-set-webview-zoom",
"core:webview:default",
"core:window:allow-center",
"core:window:default",
"core:path:allow-resolve-directory",
"core:path:default",
{
"identifier": "fs:allow-exists",
"allow": [

View File

@@ -4,33 +4,33 @@
"description": "Capability for the sub window",
"windows": ["Sub_window"],
"permissions": [
"app:allow-version",
"app:default",
"core:app:allow-version",
"core:app:default",
"dialog:allow-save",
"dialog:default",
"event:allow-listen",
"event:default",
"core:event:allow-listen",
"core:event:default",
"fs:default",
"http:allow-fetch",
"log:allow-log",
"log:default",
"path:allow-resolve-directory",
"path:default",
"core:path:allow-resolve-directory",
"core:path:default",
"shell:allow-open",
"shell:default",
"sql:allow-load",
"sql:allow-execute",
"sql:default",
"webview:allow-set-webview-zoom",
"webview:default",
"window:allow-center",
"window:allow-close",
"window:allow-destroy",
"window:allow-set-size",
"window:allow-set-title",
"window:allow-set-fullscreen",
"window:allow-show",
"window:default",
"core:webview:allow-set-webview-zoom",
"core:webview:default",
"core:window:allow-center",
"core:window:allow-close",
"core:window:allow-destroy",
"core:window:allow-set-size",
"core:window:allow-set-title",
"core:window:allow-set-fullscreen",
"core:window:allow-show",
"core:window:default",
{
"identifier": "fs:allow-exists",
"allow": [{ "path": "**" }]

View File

@@ -4,18 +4,18 @@
"description": "Capability for the main window",
"windows": ["TeyvatGuide"],
"permissions": [
"app:allow-version",
"app:default",
"core:app:allow-version",
"core:app:default",
"dialog:allow-save",
"dialog:default",
"event:allow-listen",
"event:default",
"core:event:allow-listen",
"core:event:default",
"fs:default",
"http:allow-fetch",
"log:allow-log",
"log:default",
"path:allow-resolve-directory",
"path:default",
"core:path:allow-resolve-directory",
"core:path:default",
"process:allow-exit",
"process:default",
"shell:allow-execute",
@@ -24,19 +24,19 @@
"sql:allow-load",
"sql:allow-execute",
"sql:default",
"webview:allow-create-webview-window",
"webview:allow-set-webview-zoom",
"webview:default",
"window:allow-center",
"window:allow-close",
"window:allow-destroy",
"window:allow-set-size",
"window:default",
"window:allow-is-minimized",
"window:allow-set-title",
"window:allow-set-focus",
"window:allow-show",
"window:allow-unminimize",
"core:webview:allow-create-webview-window",
"core:webview:allow-set-webview-zoom",
"core:webview:default",
"core:window:allow-center",
"core:window:allow-close",
"core:window:allow-destroy",
"core:window:allow-set-size",
"core:window:default",
"core:window:allow-is-minimized",
"core:window:allow-set-title",
"core:window:allow-set-focus",
"core:window:allow-show",
"core:window:allow-unminimize",
{
"identifier": "fs:allow-exists",
"allow": [{ "path": "**" }]

File diff suppressed because one or more lines are too long

View File

@@ -1 +1,179 @@
{"DevJson":{"identifier":"DevJson","description":"Capability for the dev json window","local":true,"windows":["Dev_JSON"],"permissions":["app:allow-version","app:default","event:allow-listen","event:default","http:allow-fetch","log:allow-log","log:default","path:allow-resolve-directory","path:default","sql:allow-load","sql:allow-execute","sql:default","webview:allow-set-webview-zoom","webview:default","window:allow-center","window:allow-close","window:allow-destroy","window:allow-set-size","window:allow-set-title","window:allow-set-fullscreen","window:allow-show","window:default",{"identifier":"http:default","allow":[{"url":"https://*.miyoushe.com/*"},{"url":"https://*.mihoyo.com/*"}]}],"platforms":["windows","macOS"]},"Mys":{"identifier":"Mys","description":"Capability for the mys client window","remote":{"urls":["https://*.mihoyo.com/*","https://*.miyoushe.com/*"]},"local":true,"windows":["mhy_client"],"permissions":["dialog:allow-message","dialog:default","event:allow-emit","http:allow-fetch","webview:allow-set-webview-zoom","webview:default","window:allow-center","window:default","path:allow-resolve-directory","path:default",{"identifier":"fs:allow-exists","allow":[{"path":"**"}]},{"identifier":"fs:allow-mkdir","allow":[{"path":"**"}]},{"identifier":"fs:allow-read-dir","allow":[{"path":"**"}]},{"identifier":"fs:allow-read-text-file","allow":[{"path":"**"}]},{"identifier":"fs:allow-remove","allow":[{"path":"**"}]},{"identifier":"fs:allow-write-file","allow":[{"path":"**"}]},{"identifier":"fs:allow-write-text-file","allow":[{"path":"**"}]},{"identifier":"http:default","allow":[{"url":"https://*.miyoushe.com/*"},{"url":"https://*.mihoyo.com/*"}]}],"platforms":["windows","macOS"]},"SubWindow":{"identifier":"SubWindow","description":"Capability for the sub window","local":true,"windows":["Sub_window"],"permissions":["app:allow-version","app:default","dialog:allow-save","dialog:default","event:allow-listen","event:default","fs:default","http:allow-fetch","log:allow-log","log:default","path:allow-resolve-directory","path:default","shell:allow-open","shell:default","sql:allow-load","sql:allow-execute","sql:default","webview:allow-set-webview-zoom","webview:default","window:allow-center","window:allow-close","window:allow-destroy","window:allow-set-size","window:allow-set-title","window:allow-set-fullscreen","window:allow-show","window:default",{"identifier":"fs:allow-exists","allow":[{"path":"**"}]},{"identifier":"fs:allow-mkdir","allow":[{"path":"**"}]},{"identifier":"fs:allow-read-dir","allow":[{"path":"**"}]},{"identifier":"fs:allow-read-text-file","allow":[{"path":"**"}]},{"identifier":"fs:allow-remove","allow":[{"path":"**"}]},{"identifier":"fs:allow-write-file","allow":[{"path":"**"}]},{"identifier":"fs:allow-write-text-file","allow":[{"path":"**"}]},{"identifier":"http:default","allow":[{"url":"https://*.miyoushe.com/*"},{"url":"https://*.mihoyo.com/*"}]}],"platforms":["windows","macOS"]},"TeyvatGuide":{"identifier":"TeyvatGuide","description":"Capability for the main window","local":true,"windows":["TeyvatGuide"],"permissions":["app:allow-version","app:default","dialog:allow-save","dialog:default","event:allow-listen","event:default","fs:default","http:allow-fetch","log:allow-log","log:default","path:allow-resolve-directory","path:default","process:allow-exit","process:default","shell:allow-execute","shell:allow-open","shell:default","sql:allow-load","sql:allow-execute","sql:default","webview:allow-create-webview-window","webview:allow-set-webview-zoom","webview:default","window:allow-center","window:allow-close","window:allow-destroy","window:allow-set-size","window:default","window:allow-is-minimized","window:allow-set-title","window:allow-set-focus","window:allow-show","window:allow-unminimize",{"identifier":"fs:allow-exists","allow":[{"path":"**"}]},{"identifier":"fs:allow-mkdir","allow":[{"path":"**"}]},{"identifier":"fs:allow-read-dir","allow":[{"path":"**"}]},{"identifier":"fs:allow-read-text-file","allow":[{"path":"**"}]},{"identifier":"fs:allow-remove","allow":[{"path":"**"}]},{"identifier":"fs:allow-write-file","allow":[{"path":"**"}]},{"identifier":"fs:allow-write-text-file","allow":[{"path":"**"}]},{"identifier":"http:default","allow":[{"url":"https://*.miyoushe.com/*"},{"url":"https://*.mihoyo.com/*"},{"url":"https://homa.snapgenshin.com/*"}]},{"identifier":"shell:allow-execute","allow":[{"args":true,"cmd":"explorer","name":"win_open"},{"args":true,"cmd":"open","name":"mac_open"}]}],"platforms":["windows","macOS"]}}
{
"DevJson": {
"identifier": "DevJson",
"description": "Capability for the dev json window",
"local": true,
"windows": ["Dev_JSON"],
"permissions": [
"core:app:allow-version",
"core:app:default",
"core:event:allow-listen",
"core:event:default",
"http:allow-fetch",
"log:allow-log",
"log:default",
"core:path:allow-resolve-directory",
"core:path:default",
"sql:allow-load",
"sql:allow-execute",
"sql:default",
"core:webview:allow-set-webview-zoom",
"core:webview:default",
"core:window:allow-center",
"core:window:allow-close",
"core:window:allow-destroy",
"core:window:allow-set-size",
"core:window:allow-set-title",
"core:window:allow-set-fullscreen",
"core:window:allow-show",
"core:window:default",
{
"identifier": "http:default",
"allow": [{ "url": "https://*.miyoushe.com/*" }, { "url": "https://*.mihoyo.com/*" }]
}
],
"platforms": ["windows", "macOS"]
},
"Mys": {
"identifier": "Mys",
"description": "Capability for the mys client window",
"remote": { "urls": ["https://*.mihoyo.com/*", "https://*.miyoushe.com/*"] },
"local": true,
"windows": ["mhy_client"],
"permissions": [
"dialog:allow-message",
"dialog:default",
"core:event:allow-emit",
"http:allow-fetch",
"core:webview:allow-set-webview-zoom",
"core:webview:default",
"core:window:allow-center",
"core:window:default",
"core:path:allow-resolve-directory",
"core:path:default",
{ "identifier": "fs:allow-exists", "allow": [{ "path": "**" }] },
{ "identifier": "fs:allow-mkdir", "allow": [{ "path": "**" }] },
{ "identifier": "fs:allow-read-dir", "allow": [{ "path": "**" }] },
{ "identifier": "fs:allow-read-text-file", "allow": [{ "path": "**" }] },
{ "identifier": "fs:allow-remove", "allow": [{ "path": "**" }] },
{ "identifier": "fs:allow-write-file", "allow": [{ "path": "**" }] },
{ "identifier": "fs:allow-write-text-file", "allow": [{ "path": "**" }] },
{
"identifier": "http:default",
"allow": [{ "url": "https://*.miyoushe.com/*" }, { "url": "https://*.mihoyo.com/*" }]
}
],
"platforms": ["windows", "macOS"]
},
"SubWindow": {
"identifier": "SubWindow",
"description": "Capability for the sub window",
"local": true,
"windows": ["Sub_window"],
"permissions": [
"core:app:allow-version",
"core:app:default",
"dialog:allow-save",
"dialog:default",
"core:event:allow-listen",
"core:event:default",
"fs:default",
"http:allow-fetch",
"log:allow-log",
"log:default",
"core:path:allow-resolve-directory",
"core:path:default",
"shell:allow-open",
"shell:default",
"sql:allow-load",
"sql:allow-execute",
"sql:default",
"core:webview:allow-set-webview-zoom",
"core:webview:default",
"core:window:allow-center",
"core:window:allow-close",
"core:window:allow-destroy",
"core:window:allow-set-size",
"core:window:allow-set-title",
"core:window:allow-set-fullscreen",
"core:window:allow-show",
"core:window:default",
{ "identifier": "fs:allow-exists", "allow": [{ "path": "**" }] },
{ "identifier": "fs:allow-mkdir", "allow": [{ "path": "**" }] },
{ "identifier": "fs:allow-read-dir", "allow": [{ "path": "**" }] },
{ "identifier": "fs:allow-read-text-file", "allow": [{ "path": "**" }] },
{ "identifier": "fs:allow-remove", "allow": [{ "path": "**" }] },
{ "identifier": "fs:allow-write-file", "allow": [{ "path": "**" }] },
{ "identifier": "fs:allow-write-text-file", "allow": [{ "path": "**" }] },
{
"identifier": "http:default",
"allow": [{ "url": "https://*.miyoushe.com/*" }, { "url": "https://*.mihoyo.com/*" }]
}
],
"platforms": ["windows", "macOS"]
},
"TeyvatGuide": {
"identifier": "TeyvatGuide",
"description": "Capability for the main window",
"local": true,
"windows": ["TeyvatGuide"],
"permissions": [
"core:app:allow-version",
"core:app:default",
"dialog:allow-save",
"dialog:default",
"core:event:allow-listen",
"core:event:default",
"fs:default",
"http:allow-fetch",
"log:allow-log",
"log:default",
"core:path:allow-resolve-directory",
"core:path:default",
"process:allow-exit",
"process:default",
"shell:allow-execute",
"shell:allow-open",
"shell:default",
"sql:allow-load",
"sql:allow-execute",
"sql:default",
"core:webview:allow-create-webview-window",
"core:webview:allow-set-webview-zoom",
"core:webview:default",
"core:window:allow-center",
"core:window:allow-close",
"core:window:allow-destroy",
"core:window:allow-set-size",
"core:window:default",
"core:window:allow-is-minimized",
"core:window:allow-set-title",
"core:window:allow-set-focus",
"core:window:allow-show",
"core:window:allow-unminimize",
{ "identifier": "fs:allow-exists", "allow": [{ "path": "**" }] },
{ "identifier": "fs:allow-mkdir", "allow": [{ "path": "**" }] },
{ "identifier": "fs:allow-read-dir", "allow": [{ "path": "**" }] },
{ "identifier": "fs:allow-read-text-file", "allow": [{ "path": "**" }] },
{ "identifier": "fs:allow-remove", "allow": [{ "path": "**" }] },
{ "identifier": "fs:allow-write-file", "allow": [{ "path": "**" }] },
{ "identifier": "fs:allow-write-text-file", "allow": [{ "path": "**" }] },
{
"identifier": "http:default",
"allow": [
{ "url": "https://*.miyoushe.com/*" },
{ "url": "https://*.mihoyo.com/*" },
{ "url": "https://homa.snapgenshin.com/*" }
]
},
{
"identifier": "shell:allow-execute",
"allow": [
{ "args": true, "cmd": "explorer", "name": "win_open" },
{ "args": true, "cmd": "open", "name": "mac_open" }
]
}
],
"platforms": ["windows", "macOS"]
}
}

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@@ -1,7 +1,8 @@
//! @file src/client/menu.rs
//! @desc 客户端菜单模块,负责操作米游社客户端菜单
//! @since Beta v0.5.0
//! @since Beta v0.5.2
use crate::client::utils;
use tauri::menu::{Menu, MenuBuilder, MenuEvent, MenuItemBuilder, Submenu, SubmenuBuilder};
use tauri::{AppHandle, LogicalSize, Manager, Size, Window, Wry};
use tauri_utils::config::WebviewUrl;
@@ -21,7 +22,7 @@ pub fn get_mhy_client_url(func: String) -> WebviewUrl {
.parse()
.unwrap();
}
return WebviewUrl::External(url_res);
WebviewUrl::External(url_res)
}
// 创建子菜单-工具
@@ -39,7 +40,7 @@ fn create_utils_menu(app: AppHandle) -> Submenu<Wry> {
.item(&rotate_window_submenu)
.build()
.expect("failed to create utils_menu");
return utils_menu;
utils_menu
}
// 创建米游社客户端菜单
@@ -48,13 +49,13 @@ pub fn create_mhy_menu(app: AppHandle) -> Menu<Wry> {
let cancel_top_menu = MenuItemBuilder::with_id("cancel_top", "取消置顶").build(&app).unwrap();
let open_post_menu = MenuItemBuilder::with_id("open_post", "打开帖子").build(&app).unwrap();
let utils_menu = create_utils_menu(app.clone());
return MenuBuilder::new(&app)
MenuBuilder::new(&app)
.item(&top_menu)
.item(&cancel_top_menu)
.item(&open_post_menu)
.item(&utils_menu)
.build()
.expect("failed to create mhy_menu");
.expect("failed to create mhy_menu")
}
// 菜单栏事件处理
@@ -181,10 +182,17 @@ fn handle_menu_rotate_window(app_handle: &Window) {
let window = window_get.unwrap();
// 获取窗口宽高比
let cur_size = window.inner_size().ok().unwrap();
let monitor = window.primary_monitor().ok().unwrap().unwrap();
if cur_size.width > cur_size.height {
window.set_size(Size::Logical(LogicalSize { width: 400.0, height: 800.0 })).unwrap();
let trans_size = utils::get_window_size2(monitor, 400.0, 800.0);
window
.set_size(Size::Logical(LogicalSize { width: trans_size.0, height: trans_size.1 }))
.unwrap();
} else {
window.set_size(Size::Logical(LogicalSize { width: 1280.0, height: 720.0 })).unwrap();
let trans_size = utils::get_window_size2(monitor, 1280.0, 720.0);
window
.set_size(Size::Logical(LogicalSize { width: trans_size.0, height: trans_size.1 }))
.unwrap();
}
window.center().unwrap();
window.set_focus().unwrap();

View File

@@ -1,8 +1,10 @@
//! @file src/client/mod.rs
//! @desc 客户端模块,负责操作米游社客户端
//! @since Beta v0.5.0
//! @since Beta v0.5.2
mod menu;
mod utils;
use tauri::{AppHandle, Manager, WebviewWindowBuilder};
use tauri_utils::config::WebviewUrl;
@@ -29,8 +31,9 @@ pub async fn create_mhy_client(handle: AppHandle, func: String, url: String) {
window_find.unwrap().destroy().unwrap();
return;
}
let trans_size = utils::get_window_size(handle.clone(), win_width, win_height);
WebviewWindowBuilder::new(&handle, "mhy_client", url_parse)
.inner_size(win_width, win_height)
.inner_size(trans_size.0, trans_size.1)
.title("米游社")
.center()
.user_agent(win_ua)

View File

@@ -0,0 +1,22 @@
//! @file src/client/utils.rs
//! @desc 结合屏幕分辨率获取窗口大小
//! @since Beta v0.5.2
use tauri::{AppHandle, Manager, Monitor};
pub fn get_window_size(app: AppHandle, width: f64, height: f64) -> (f64, f64) {
let mhy_window = app.get_webview_window("TeyvatGuide").unwrap();
let monitor = mhy_window.primary_monitor().unwrap().expect("failed to get primary monitor");
get_window_size2(monitor, width, height)
}
pub fn get_window_size2(monitor: Monitor, width: f64, height: f64) -> (f64, f64) {
let monitor_size = monitor.size();
let monitor_width = monitor_size.width as f64;
let monitor_height = monitor_size.height as f64;
let width_scale = monitor_width / 1920.0;
let height_scale = monitor_height / 1080.0;
let get_width = (width * width_scale).round();
let get_height = (height * height_scale).round();
(get_width, get_height)
}

View File

@@ -1,6 +1,6 @@
//! @file src/main.rs
//! @desc 主模块,用于启动应用
//! @since Beta v0.5.1
//! @since Beta v0.5.2
// Prevents additional console window on Windows in release, DO NOT REMOVE!!
#![cfg_attr(not(debug_assertions), windows_subsystem = "windows")]
@@ -45,7 +45,7 @@ fn main() {
.plugin(tauri_plugin_os::init())
.plugin(tauri_plugin_process::init())
.plugin(tauri_plugin_shell::init())
.plugin(plugins::build_sql_plugin())
.plugin(tauri_plugin_sql::Builder::default().build())
.plugin(plugins::build_log_plugin())
.setup(|_app| {
let _window = _app.get_webview_window("TeyvatGuide");

View File

@@ -1,18 +1,12 @@
//! @file src/plugins.rs
//! @desc 插件模块,用于注册插件
//! @since Beta v0.5.0
//! @since Beta v0.5.2
use super::utils;
use log::LevelFilter;
use tauri::plugin::TauriPlugin;
use tauri::Runtime;
use tauri_plugin_log::{Target, TargetKind, TimezoneStrategy};
use tauri_plugin_sql::PluginConfig;
// sqlite 插件
pub fn build_sql_plugin<R: Runtime>() -> TauriPlugin<R, Option<PluginConfig>> {
tauri_plugin_sql::Builder::default().build()
}
// 日志插件
pub fn build_log_plugin<R: Runtime>() -> TauriPlugin<R> {

View File

@@ -1,7 +1,7 @@
{
"productName": "TeyvatGuide",
"identifier": "TeyvatGuide",
"version": "0.5.1",
"version": "0.5.2",
"build": {
"beforeDevCommand": "pnpm vite:dev",
"beforeBuildCommand": "pnpm vite:build",

View File

@@ -11,7 +11,7 @@
</template>
<script lang="ts" setup>
import { app, event, core, webviewWindow } from "@tauri-apps/api";
import { app, event, core, webviewWindow, window as TauriWindow } from "@tauri-apps/api";
import { PhysicalSize } from "@tauri-apps/api/dpi";
import { UnlistenFn, Event } from "@tauri-apps/api/event";
import { mkdir } from "@tauri-apps/plugin-fs";
@@ -43,7 +43,7 @@ let themeListener: UnlistenFn;
let urlListener: UnlistenFn;
onBeforeMount(async () => {
const win = webviewWindow.getCurrent();
const win = webviewWindow.getCurrentWebviewWindow();
isMain.value = win.label === "TeyvatGuide";
if (isMain.value) {
const title = "Teyvat Guide v" + (await app.getVersion()) + " Beta";
@@ -52,24 +52,34 @@ onBeforeMount(async () => {
await core.invoke("init_app");
urlListener = await getDeepLink();
}
await win.show();
await checkResize();
await win.show();
});
async function checkResize(): Promise<void> {
const windowCur = await webviewWindow.getCurrent();
const winScale = await windowCur.scaleFactor();
if (winScale > 1) {
const newSize = getSize(windowCur.label);
await windowCur.setSize(newSize);
await windowCur.setZoom(1 / winScale);
await windowCur.center();
} else if (winScale === 1) {
const newSize = getSize(windowCur.label);
await windowCur.setSize(newSize);
await windowCur.setZoom(1);
await windowCur.center();
const screen = await TauriWindow.currentMonitor();
if (screen === null) {
showSnackbar({
text: "获取屏幕信息失败!",
color: "error",
timeout: 3000,
});
return;
}
const windowCur = await webviewWindow.getCurrentWebviewWindow();
if (await windowCur.isMaximized()) return;
const designSize = getSize(windowCur.label);
const widthScale = screen.size.width / 1920;
const heightScale = screen.size.height / 1080;
await windowCur.setSize(
new PhysicalSize(
Math.round(designSize.width * widthScale),
Math.round(designSize.height * heightScale),
),
);
await windowCur.setZoom((1 / screen.scaleFactor) * Math.min(widthScale, heightScale));
await windowCur.center();
return;
}
function getSize(label: string): PhysicalSize {

View File

@@ -301,7 +301,7 @@ onMounted(async () => {
const theme = e.payload;
themeGet.value = theme === "default" ? "default" : "dark";
});
if (webviewWindow.getCurrent().label === "TeyvatGuide") {
if (webviewWindow.getCurrentWebviewWindow().label === "TeyvatGuide") {
await mhyClient.run();
}
if (userStore.briefInfo.value && userStore.briefInfo.value.nickname) {

View File

@@ -52,7 +52,7 @@ function toStore() {
}
function toSite() {
window.open("https://app.btmuli.ink/docs/Changelogs.html");
window.open("https://app.btmuli.ink/docs/TeyvatGuide/changelogs.html");
}
</script>
<style lang="css" scoped>

View File

@@ -46,8 +46,8 @@
</template>
<template #append>
<v-icon @click="confirmCLD()" style="cursor: pointer" title="清理日志文件"
>mdi-delete</v-icon
>
>mdi-delete
</v-icon>
&emsp;
<v-icon @click="openPath('log')" style="cursor: pointer" title="打开日志目录"
>mdi-folder-open
@@ -64,6 +64,7 @@
import { path } from "@tauri-apps/api";
import { open } from "@tauri-apps/plugin-dialog";
import { readDir, remove } from "@tauri-apps/plugin-fs";
import { onMounted } from "vue";
import TGSqlite from "../../plugins/Sqlite/index.js";
import { useAppStore } from "../../store/modules/app.js";
@@ -74,6 +75,27 @@ import showSnackbar from "../func/snackbar.js";
const appStore = useAppStore();
onMounted(async () => {
const logDir = await path.appLogDir();
const dbPath = `${await path.appConfigDir()}${path.sep()}TeyvatGuide.db`;
let message = "";
if (appStore.dbPath !== dbPath) {
appStore.dbPath = dbPath;
await TGSqlite.saveAppData("dbPath", dbPath);
message += "数据库路径 ";
}
if (appStore.logDir !== logDir) {
appStore.logDir = logDir;
message += "日志路径 ";
}
if (message !== "") {
showSnackbar({
text: `${message}已更新!`,
color: "success",
});
}
});
async function confirmCUD(): Promise<void> {
const oriDir = appStore.userDir;
const check = await showConfirm({ title: "确认修改用户数据路径吗?" });

View File

@@ -1,5 +1,4 @@
<template>
<ToGameLogin v-model="scan" @success="refreshUser" />
<v-card class="tcu-box">
<template #prepend>
<v-avatar :image="userInfo.avatar" />
@@ -15,7 +14,6 @@
icon="mdi-cellphone"
title="验证码登录"
/>
<v-btn variant="outlined" @click="scan = true" icon="mdi-qrcode-scan" title="扫码登录" />
<v-btn
variant="outlined"
@click="confirmRefreshUser"
@@ -42,7 +40,6 @@ import TGRequest from "../../web/request/TGRequest.js";
import showConfirm from "../func/confirm.js";
import showGeetest from "../func/geetest.js";
import showSnackbar from "../func/snackbar.js";
import ToGameLogin from "../overlay/to-gameLogin.vue";
interface TcUserBadgeEmits {
(e: "loadOuter", v: TGApp.Component.Loading.EmitParams): void;
@@ -54,7 +51,6 @@ const appStore = useAppStore();
const userStore = storeToRefs(useUserStore());
const loading = ref<boolean>(false);
const scan = ref<boolean>(false);
const userInfo = ref<TGApp.App.Account.BriefInfo>({
nickname: "未登录",
uid: "-1",
@@ -141,7 +137,7 @@ async function refreshUser() {
await TGLogger.Error("[tc-userBadge][refreshUser] cookie 不存在");
showSnackbar({
color: "error",
text: "扫码登录后才能刷新用户信息!",
text: "登录后才能刷新用户信息!",
});
appStore.isLogin = false;
return;

View File

@@ -42,7 +42,6 @@ watch(show, () => {
async function displayBox(
props: TGApp.Plugins.Mys.Geetest.reqResp,
): Promise<TGApp.Plugins.Mys.Geetest.validateResp | false> {
show.value = true;
return await new Promise<TGApp.Plugins.Mys.Geetest.validateResp>((resolve) => {
// eslint-disable-next-line no-undef
initGeetest(
@@ -58,6 +57,9 @@ async function displayBox(
(captchaObj: TGApp.Plugins.Mys.Geetest.GeetestCaptcha) => {
geetestRef.value.innerHTML = "";
captchaObj.appendTo("#geetest");
captchaObj.onReady(() => {
show.value = true;
});
captchaObj.onSuccess(async () => {
const validate = captchaObj.getValidate();
resolve(validate);

View File

@@ -63,6 +63,7 @@ onMounted(async () => {
const width = highestResolution.width;
const height = highestResolution.height;
if (width && height) {
// eslint-disable-next-line @typescript-eslint/no-unused-expressions
width > height
? (vodAspectRatio.value = width / height)
: (vodAspectRatio.value = height / width);
@@ -118,7 +119,7 @@ onMounted(async () => {
};
container.value = new Artplayer(option);
container.value?.on("fullscreen", async (state) => {
await TauriWindow.getCurrent().setFullscreen(state);
await TauriWindow.getCurrentWindow().setFullscreen(state);
});
});

View File

@@ -416,7 +416,7 @@
},
{
"id": 1313,
"contentId": 0,
"contentId": 501569,
"name": "夏沃蕾",
"type": "角色牌",
"icon": "/WIKI/GCG/normal/夏沃蕾.webp",
@@ -754,7 +754,7 @@
},
{
"id": 1608,
"contentId": 0,
"contentId": 501547,
"name": "娜维娅",
"type": "角色牌",
"icon": "/WIKI/GCG/normal/娜维娅.webp",
@@ -899,7 +899,7 @@
},
{
"id": 2104,
"contentId": 0,
"contentId": 501558,
"name": "愚人众·霜役人",
"type": "角色牌",
"icon": "/WIKI/GCG/normal/愚人众·霜役人.webp",
@@ -1991,7 +1991,7 @@
},
{
"id": 213131,
"contentId": 0,
"contentId": 501564,
"name": "尖兵协同战法",
"type": "行动牌",
"icon": "/WIKI/GCG/normal/尖兵协同战法.webp",
@@ -2297,7 +2297,7 @@
},
{
"id": 216081,
"contentId": 0,
"contentId": 501548,
"name": "不明流通渠道",
"type": "行动牌",
"icon": "/WIKI/GCG/normal/不明流通渠道.webp",
@@ -2427,7 +2427,7 @@
},
{
"id": 221041,
"contentId": 0,
"contentId": 501559,
"name": "冰雅刺剑",
"type": "行动牌",
"icon": "/WIKI/GCG/normal/冰雅刺剑.webp",
@@ -2904,7 +2904,7 @@
},
{
"id": 311308,
"contentId": 0,
"contentId": 501561,
"name": "「究极霸王超级魔剑」",
"type": "行动牌",
"icon": "/WIKI/GCG/normal/「究极霸王超级魔剑」.webp",
@@ -3003,7 +3003,7 @@
},
{
"id": 311409,
"contentId": 0,
"contentId": 501562,
"name": "勘探钻机",
"type": "行动牌",
"icon": "/WIKI/GCG/normal/勘探钻机.webp",
@@ -3382,7 +3382,7 @@
},
{
"id": 312029,
"contentId": 0,
"contentId": 501566,
"name": "角斗士的凯旋",
"type": "行动牌",
"icon": "/WIKI/GCG/normal/角斗士的凯旋.webp",
@@ -4002,7 +4002,7 @@
},
{
"id": 322027,
"contentId": 0,
"contentId": 501567,
"name": "瑟琳",
"type": "行动牌",
"icon": "/WIKI/GCG/normal/瑟琳.webp",
@@ -4618,7 +4618,7 @@
},
{
"id": 332037,
"contentId": 0,
"contentId": 501563,
"name": "噔噔!",
"type": "行动牌",
"icon": "/WIKI/GCG/normal/噔噔!.webp",

View File

@@ -1409,7 +1409,7 @@
},
{
"id": 10000099,
"contentId": 0,
"contentId": 501441,
"dropDays": [3, 6, 7],
"name": "艾梅莉埃",
"itemType": "character",
@@ -6094,7 +6094,7 @@
},
{
"id": 13513,
"contentId": 0,
"contentId": 501725,
"dropDays": [3, 6, 7],
"name": "柔灯挽歌",
"itemType": "weapon",

View File

@@ -2141,5 +2141,41 @@
"postId": "55147896",
"up5List": [12512, 11511],
"up4List": [11418, 12402, 13401, 14409, 15405]
},
{
"name": "凝露轻芳",
"version": "4.8",
"order": 2,
"banner": "https://sdk.hoyoverse.com/upload/ann/2024/07/19/a613355dfdca28e391d39905d3d0879b_5070315245511088722.jpg",
"from": "2024-08-06T18:00:00+08:00",
"to": "2024-08-27T14:59:00+08:00",
"type": 301,
"postId": "56072207",
"up5List": [10000099],
"up4List": [10000048, 10000023, 10000020]
},
{
"name": "素霓伣天",
"version": "4.8",
"order": 2,
"banner": "https://sdk.hoyoverse.com/upload/ann/2024/07/19/4dff39a5df5b0978653f46b92fa512f8_7130552963756568493.jpg",
"from": "2024-08-06T18:00:00+08:00",
"to": "2024-08-27T14:59:00+08:00",
"type": 400,
"postId": "56072208",
"up5List": [10000060],
"up4List": [10000048, 10000023, 10000020]
},
{
"name": "神铸赋形",
"version": "4.8",
"order": 2,
"banner": "https://sdk.hoyoverse.com/upload/ann/2024/07/19/3cecd09457f7158fad2d9c140dc09fdb_8057167364819822333.jpg",
"from": "2024-08-06T18:00:00+08:00",
"to": "2024-08-27T14:59:00+08:00",
"type": 302,
"postId": "56072210",
"up5List": [13513, 15508],
"up4List": [12415, 14416, 11402, 13407, 15401]
}
]

View File

@@ -181,7 +181,7 @@
},
{
"id": 13513,
"contentId": 0,
"contentId": 501725,
"name": "柔灯挽歌",
"star": 5,
"bg": "/icon/bg/5-Star.webp",

View File

@@ -212,6 +212,15 @@ function getAnnoTime(content: string): string | false {
}
if (content.match(regexes[3])) {
const res = content.match(regexes[3]);
try {
const span1 = document.createElement("span");
span1.innerHTML = res?.[1] ?? "";
const span2 = document.createElement("span");
span2.innerHTML = res?.[2] ?? "";
return `${span1.innerText} ~ ${span2.innerText}`;
} catch (e) {
console.error(e);
}
return `${res?.[1]} ~ ${res?.[2]}`;
}
if (content.match(regexes[4])) {

View File

@@ -1,12 +1,12 @@
/**
* @file plugins/Mys/types/Geetest.d.ts
* @description Mys 插件 Geetest 类型定义文件
* @since Beta v0.5.1
* @since Beta v0.5.2
*/
/**
* @description Mys 插件 Geetest 类型
* @since Beta v0.5.1
* @since Beta v0.5.2
* @namespace TGApp.Plugins.Mys.Geetest
* @memberof TGApp.Plugins.Mys
*/
@@ -66,12 +66,13 @@ declare namespace TGApp.Plugins.Mys.Geetest {
/**
* @description Geetest 插件 captchaObj
* @since Beta v0.5.1
* @since Beta v0.5.2
* @interface GeetestCaptcha
* @property {Function} appendTo
* @property {Function} getValidate
* @property {Function} onSuccess
* @property {Function} onClose
* @property {Function} onReady
* @return GeetestCaptcha
*/
interface GeetestCaptcha {
@@ -79,6 +80,7 @@ declare namespace TGApp.Plugins.Mys.Geetest {
getValidate: () => validateResp;
onSuccess: (callback: () => void) => void;
onClose: (callback: () => void) => void;
onReady: (callback: () => void) => void;
}
/**

View File

@@ -1,7 +1,7 @@
/**
* @file store/modules/app.ts
* @description App store module
* @since Beta v0.5.0
* @since Beta v0.5.2
*/
import { path } from "@tauri-apps/api";
@@ -16,7 +16,7 @@ const userDataDir = `${await path.appLocalDataDir()}${path.sep()}userData`;
// 用于存放数据库的路径
const dbDataPath = `${await path.appConfigDir()}${path.sep()}TeyvatGuide.db`;
// 用于存放日志的路径
const logDataDir = `${await path.appConfigDir()}${path.sep()}logs`;
const logDataDir = await path.appLogDir();
export const useAppStore = defineStore(
"app",

View File

@@ -75,7 +75,9 @@ onMounted(async () => {
annoHtml.value = await TGUtils.Anno.parseContent(annoData.value.content);
if (annoData.value.banner !== "") annoBanner.value = await saveImgLocal(annoData.value.banner);
annoTitle.value = `Anno_${annoId}`;
await webviewWindow.getCurrent().setTitle(`Anno_${annoId} ${annoData.value.title}`);
await webviewWindow
.getCurrentWebviewWindow()
.setTitle(`Anno_${annoId} ${annoData.value.title}`);
annoRef.value = <HTMLElement>document.querySelector(".anno-body");
} catch (error) {
if (error instanceof Error)
@@ -83,7 +85,7 @@ onMounted(async () => {
else console.error(error);
loadingEmpty.value = true;
loadingTitle.value = "公告不存在或解析失败";
await webviewWindow.getCurrent().setTitle(`Anno_${annoId} Parsing Error`);
await webviewWindow.getCurrentWebviewWindow().setTitle(`Anno_${annoId} Parsing Error`);
return;
}
// 打开 json

View File

@@ -136,7 +136,7 @@ onMounted(async () => {
if (!postId) {
loadingEmpty.value = true;
loadingTitle.value = "未找到数据";
await webviewWindow.getCurrent().setTitle("未找到数据");
await webviewWindow.getCurrentWebviewWindow().setTitle("未找到数据");
await TGLogger.Error("[t-post][onMounted] PostID 不存在");
return;
}
@@ -147,7 +147,9 @@ onMounted(async () => {
loadingTitle.value = "正在渲染数据...";
renderPost.value = getRenderPost(postData.value);
shareTitle.value = `Post_${postId}`;
await webviewWindow.getCurrent().setTitle(`Post_${postId} ${postData.value.post.subject}`);
await webviewWindow
.getCurrentWebviewWindow()
.setTitle(`Post_${postId} ${postData.value.post.subject}`);
} catch (error) {
if (error instanceof Error) {
await TGLogger.Error(`[t-post][${postId}] ${error.name}: ${error.message}`);
@@ -159,7 +161,7 @@ onMounted(async () => {
loadingSub.value = "请检查帖子是否存在或者是否为合法的帖子";
}
loadingEmpty.value = true;
await webviewWindow.getCurrent().setTitle(`Post_${postId} Parsing Error`);
await webviewWindow.getCurrentWebviewWindow().setTitle(`Post_${postId} Parsing Error`);
return;
}
await TGLogger.Info(`[t-post][${postId}][onMounted] ${postData.value.post.subject}`);

View File

@@ -12,7 +12,7 @@ import TGConstant from "../constant/TGConstant.js";
* @description 获取设备指纹
* @since Beta v0.5.0
* @param {TGApp.App.Device.DeviceInfo} Info - 设备信息
* @returns {Promise<string>} 设备指纹
* @returns {Promise<TGApp.App.Device.DeviceInfo>} 设备指纹
*/
export async function getDeviceFp(
Info?: TGApp.App.Device.DeviceInfo,

View File

@@ -1,7 +1,7 @@
/**
* @file web/utils/parseAnno.ts
* @description 解析游戏内公告数据
* @since Beta v0.5.0
* @since Beta v0.5.2
*/
import { saveImgLocal } from "../../utils/TGShare.js";
@@ -30,7 +30,7 @@ function parseAnnoA(a: HTMLAnchorElement): HTMLAnchorElement {
/**
* @description 解析 p
* @since Beta v0.4.7
* @since Beta v0.5.2
* @param {HTMLParagraphElement} p p 元素
* @returns {HTMLParagraphElement} 解析后的 p 元素
*/
@@ -40,6 +40,7 @@ function parseAnnoP(p: HTMLParagraphElement): HTMLParagraphElement {
} else {
p.querySelectorAll("*").forEach((child) => {
child.innerHTML = decodeRegExp(child.innerHTML);
child.querySelectorAll("span").forEach((span) => parseAnnoSpan(span));
});
}
return p;

View File

@@ -4,7 +4,7 @@
* @since Beta v0.4.3
*/
import TGConstant from "../constant/TGConstant";
import TGConstant from "../constant/TGConstant.js";
/**
* @description 转义正则表达式