Files
mixvideo-v2/apps/desktop/src-tauri/Cargo.toml
imeepos 44f3f40705 fix: 修复缩略图显示权限问题,使用base64数据URL
解决asset.localhost访问权限问题:
- 添加read_thumbnail_as_data_url命令读取文件并转换为base64数据URL
- 避免使用convertFileSrc的asset.localhost协议访问问题
- 添加base64依赖支持文件编码

 优化缩略图加载:
- 使用数据URL直接在img标签中显示缩略图
- 正确处理Windows长路径前缀 \\\\?\\
- 统一错误处理和降级机制

 技术改进:
- 移除不再使用的convertFileSrc导入
- 添加详细的控制台日志便于调试
- 确保跨平台文件路径兼容性

现在缩略图可以正确显示,不会因为权限问题导致加载失败。
2025-07-15 22:38:22 +08:00

46 lines
1.4 KiB
TOML

[package]
name = "mixvideo-desktop"
version = "0.1.9"
description = "MixVideo Desktop Application"
authors = ["imeepos <imeepos@outlook.com>"]
edition = "2021"
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
[lib]
# The `_lib` suffix may seem redundant but it is necessary
# to make the lib name unique and wouldn't conflict with the bin name.
# This seems to be only an issue on Windows, see https://github.com/rust-lang/cargo/issues/8519
name = "mixvideo_desktop_lib"
crate-type = ["staticlib", "cdylib", "rlib"]
[build-dependencies]
tauri-build = { version = "2", features = [] }
[dependencies]
tauri = { version = "2", features = ["protocol-asset"] }
tauri-plugin-opener = "2"
tauri-plugin-fs = "2"
tauri-plugin-dialog = "2"
serde = { version = "1", features = ["derive"] }
serde_json = "1"
rusqlite = { version = "0.31", features = ["bundled", "chrono"] }
chrono = { version = "0.4", features = ["serde"] }
uuid = { version = "1.0", features = ["v4", "serde"] }
tokio = { version = "1.0", features = ["full", "sync"] }
anyhow = "1.0"
thiserror = "1.0"
dirs = "5.0"
md5 = "0.7"
lazy_static = "1.4"
base64 = "0.22"
tracing = "0.1"
tracing-subscriber = { version = "0.3", features = ["env-filter", "chrono"] }
tracing-appender = "0.2"
reqwest = { version = "0.11", features = ["json", "multipart"] }
[dev-dependencies]
tempfile = "3.8"
tokio-test = "0.4"