Commit Graph

25 Commits

Author SHA1 Message Date
Mihail Klimin 8fa7c14f18 feat(tauri): Migrate from Tauri v1 to v2
# Summary
This commit completes the migration from Tauri v1 to v2, resolves configuration issues, upgrades Next.js, and adds test coverage for critical components to ensure stability during the transition.

# Details
## Tauri v2 Migration
- Updated Tauri dependencies to v2.3.0 series in package.json
- Restructured build configuration in `/app/config/build.ts` to align with Tauri v2 requirements
- Fixed imports and API usage patterns across the codebase
- Added compatibility layer for window.__TAURI__ references to maintain backward compatibility

## Next.js Issues
- Upgraded Next.js from 14.1.1 to 14.2.24
- Resolved caching problems with Server Actions
- Updated eslint-config-next to match the new version
- Cleared Next.js cache and temporary files to address build issues

## Testing & Stability
- Added comprehensive tests for `stream.ts` to verify streaming functionality
- Created mocks for Tauri API to support test environment
- Verified that critical functionality continues to work correctly
- Translated all comments to English for consistency

## Infrastructure
- Fixed peer dependency warnings during installation
- Ensured proper integration with Tauri v2 plugins (clipboard-manager, dialog, fs, http, notification, shell, updater, window-state)

# Approach
Prioritized stability by:
1. Making minimal necessary changes to configuration files
2. Preserving most `window.__TAURI__` calls as they still function in v2
3. Planning gradual migration to new APIs with test coverage for critical components
4. Documenting areas that will require future attention

# Testing
- Created unit tests for critical streaming functionality
- Performed manual testing of key application features
- Verified successful build and launch with Tauri v2

# Future Work
- Future PRs will gradually replace deprecated Tauri v1 API calls with v2 equivalents
- Additional test coverage will be added for other critical components
2025-03-16 02:14:47 +03:00
lloydzhou 2eebfcf6fe client app tauri updater #2966 2024-10-11 11:29:22 +08:00
DDDDD12138 63ffd473d5 chore: remove unused imports 2024-09-15 20:17:02 +08:00
Fred Liang 45798f993d
fix: fix type errors 2023-12-24 02:39:13 +08:00
Fred Liang 778e88cb56
chore: resolve conflict 2023-12-24 02:15:30 +08:00
Fred Liang 3ef0621eb0
refactor: update product name 2023-12-23 16:48:16 +08:00
H0llyW00dzZ b558d1afc6
Feat & Fix "Client App [Notification]"
[+] feat(update.ts): add support for localization in update notifications
[+] fix(update.ts): add missing semicolon in useUpdateStore function
2023-10-04 02:10:26 +07:00
H0llyW00dzZ ddfd05b008
Fix & Feat Client App [Notification]
[+] fix(update.ts): remove unnecessary notification sending when permission is not granted
[+] feat(update.ts): add notification for already up to date version
2023-10-03 09:12:41 +07:00
H0llyW00dzZ 64a17abfe2
Client App [Notification]
[+] feat(global.d.ts): add support for window.__TAURI__.notification methods
[+] feat(update.ts): add notification for new version availability
[+] fix(Cargo.toml): add tauri feature "notification-all" to enable notifications
[+] fix(tauri.conf.json): enable all notification features in tauri configuration
2023-10-03 08:08:11 +07:00
Yidadaa 38f6956e71 feat: close #2754 add import/export to file 2023-09-11 00:20:23 +08:00
Yidadaa ee55f8790e fix: #2208 use global settings button dose not work 2023-07-01 18:16:06 +08:00
Yidadaa be4834688d feat: close #2190 improve app auto updater 2023-06-30 00:39:54 +08:00
Yidadaa 50cd33dbb2 feat: #1000 ready to support client-side only 2023-06-14 00:37:42 +08:00
Yidadaa 37da759fd5 fix: #1815 refuse to serve when disable gpt4 2023-06-07 01:02:01 +08:00
Yidadaa a3de277c43 refactor: #1000 #1179 api layer for client-side only mode and local models 2023-05-15 01:33:46 +08:00
Yidadaa fce3b3ce7b feat: use commit time as version id 2023-05-04 00:12:00 +08:00
Yidadaa 30040a0366 feat: migrate state from v1 to v2 2023-04-27 02:00:22 +08:00
Yidadaa 789a779775 feat: user prompts 2023-04-18 01:34:12 +08:00
Yidadaa fdc8278b90 feat: check usage throttle 2023-04-17 23:12:27 +08:00
Yidadaa d6e6dd09f0 feat: dynamic config 2023-04-11 02:54:31 +08:00
Yidadaa 9b61cb1335 refactor: build/runtime/client configs 2023-04-11 01:21:34 +08:00
Yifei Zhang 2f2e0b6762 fix: commit id as version id 2023-03-30 18:15:49 +00:00
Yifei Zhang 802ea20ec4 fix: auto scroll on enter 2023-03-30 17:04:32 +00:00
Yifei Zhang 7783545bff feat: use tag as version number 2023-03-30 16:46:17 +00:00
Yifei Zhang 99b88f36fd refactor: #6 check update over one hour and debound scroll 2023-03-23 17:00:33 +00:00