15 Commits
Author SHA1 Message Date
Suzu008 2aa1aee12a fix: trigger widget callback on upload to enable Vue Nodes 2.0 preview 2026-05-31 01:32:18 +08:00
Suzu008 a58a5b8917 refactor(sw): bidirectional SW status sync with IndexedDB persistence
Replace fire-and-forget key delivery with a sync-status protocol that
verifies key consistency between main thread and Service Worker using
SHA-256 fingerprints via MessageChannel request-response.

- SW (ts/sw.ts): persist keys in IndexedDB, auto-restore on activate;
  respond to sync-status queries with loaded keys + fingerprints;
  support cryptio-clear-keys to wipe memory + DB.
- New ts/utils/swSync.ts: single entry point for SW registration,
  key sync, and status verification. Controller change listener
  re-syncs on SW restart. Deduplicates concurrent sync calls.
- Deleted ts/utils/swKeySender.ts (replaced by swSync.ts).
- Remove SW registration (~55 lines) from cryptioSaveImage.ts;
  setup() now calls syncSWStatus().
- uploadUtils.ts: drop 5-retry preview loop (~6.4s worst case);
  single attempt with syncSWStatus fallback on failure.
- cryptioSettings.ts: sync after key changes; clearSWKeys() on
  Clear All.
- cryptioUploadImage/Video.ts: syncSWStatus in setup + preview
  fallback.
- types.ts: add SWStatus interface.
2026-05-30 22:29:45 +08:00
Suzu008 8a335dbaee refactor: improve type safety with custom interfaces (Fix 11) 2026-03-24 20:59:40 +08:00
Suzu008 4e0bfdd82e refactor: extract duplicated code into shared modules (videoWidgetUtils, uploadUtils, fileUtils) 2026-03-24 08:53:08 +08:00
Suzu008 ab1746b5e8 fix: prevent blob URL memory leaks by tracking and revoking URLs on re-execution and node removal 2026-03-24 08:43:17 +08:00
Suzu008 f905c7bc47 fix: use chunked base64 conversion to prevent stack overflow on large files 2026-03-24 08:37:42 +08:00
Suzu008 2a8c29d5c0 perf: deduplicate concurrent exchangeKeys() calls with in-flight promise guard 2026-03-24 08:34:57 +08:00
Suzu008 0a29b74d66 refactor: replace new Uint8Array() re-wrap with 'as BlobPart' type assertion 2026-03-24 08:33:08 +08:00
Suzu008 3e662b248a refactor: remove unused createVideoPreviewElement from videoLoader.ts 2026-03-24 08:29:20 +08:00
Suzu008 958f78164f feat: 为图片节点添加图片格式和保存质量组件 2025-12-10 04:05:46 +08:00
Suzu008 b5a62ef000 feat(视频处理): 添加视频加密上传、保存和预览功能
- 实现视频文件的上传、加密保存和解密预览功能
- 新增视频加载器模块处理视频解密和预览
- 扩展文件工具类支持更多视频格式
- 添加前端组件处理视频上传和预览交互
2025-10-13 04:46:45 +08:00
Suzu008 2ebf987648 refactor(cryptio): 重构密钥管理模块并优化加密功能
将密钥管理逻辑从 keys.py 迁移到 utils 模块,实现 KeyManager 单例类
新增 crypto_utils 模块集中管理加密/解密功能
优化混合加密方案实现,提高代码复用性和可维护性
2025-10-12 13:30:29 +08:00
Suzu008 b809568a75 refactor(crypto): 优化加密功能并添加base64工具
- 重命名加密函数以更准确反映用途
- 提取base64转换逻辑到独立工具文件
- 简化文本加密流程,移除冗余代码
2025-10-12 12:26:43 +08:00
Suzu008 6ed9ea5b1f refactor(crypto): 重构加密模块以支持不同密钥场景
- 将通用加密解密逻辑提取为内部函数
- 添加针对不同场景的加密解密方法(服务端/客户端密钥)
- 更新相关调用代码以使用新的加密方法
- 改进注释和类型定义
2025-10-12 07:04:20 +08:00
Suzu008 05ac7e0542 refactor(utils): 重构加密文件处理工具模块
将加密文件处理相关功能拆分为独立工具模块,包括文件工具、上传工具、图片加载工具和加密工具

重构 cryptioSaveImage.ts 和 cryptioUploadImage.ts,使用新的工具模块替换原有代码
2025-10-12 06:34:57 +08:00