Commit Graph
1067 Commits
Author SHA1 Message Date
liquidliang 22ef45ad02 chore: bump version to 0.5.76 2026-02-05 16:54:33 +08:00
liquidliang fba4fe7f57 feat: add base64 image preview functionality
- Updated the application version to 0.5.75 in index.html and version.json.
- Implemented global helper functions for toggling base64 image previews and extracting image information.
- Enhanced JSON formatting to support inline base64 image previews in logs.
- Improved the rendering of reference images in the LLM API log entries.
- Added CSS styles for base64 image preview components.
2026-02-05 15:54:45 +08:00
liquidliang 0002654a68 docs: 添加配置对象深拷贝规则
- CLAUDE.md 新增第 18 条规则:getSetting 等返回配置对象的方法需返回深拷贝
- CODING_RULES.md 添加详细规则和错误/正确示例
- 防止脱敏函数等外部操作意外修改全局设置状态
2026-02-05 15:53:10 +08:00
liquidliang 4a0e912830 chore: bump version to 0.5.75 2026-02-05 15:38:23 +08:00
liquidliang c7eb797933 chore: update version to 0.5.74 and adjust build time 2026-02-05 14:17:28 +08:00
liquidliang 1fc5967532 chore: bump version to 0.5.74 2026-02-05 14:11:57 +08:00
liquidliang 99b268e6bb chore: update version to 0.5.73 and improve task loading logic
- Bumped application version to 0.5.73 in index.html and version.json.
- Enhanced task loading in useTaskQueue and useFilteredTaskQueue hooks with retry logic for better reliability.
- Removed deprecated task migration service and adjusted related sync services to reflect the new paged format.
- Updated format detection to support only paged and none types, removing legacy support.
2026-02-05 14:11:49 +08:00
liquidliang cbe11e0865 perf: 优化同步上传性能,避免 UI 阻塞
问题:pushToRemote 在主线程连续执行大量 CPU 密集型操作(JSON.stringify、加密等),
导致事件处理器无法及时响应,页面卡顿。

解决方案:
- 在 @aitu/utils 中添加 yieldToMain() 和 processBatched() 工具函数
- 在同步相关的 CPU 密集型循环中添加 yield 点,每 3-5 次迭代让出主线程
- 更新 CLAUDE.md 和 CODING_RULES.md 记录此规则

优化的文件:
- sync-engine.ts: 画板增量比较/上传循环
- data-serializer.ts: collectSyncData、serializeToGistFiles* 方法
- task-sync-service.ts: syncTasks、uploadTaskData 方法
- workflow-sync-service.ts: syncWorkflows、uploadWorkflowData 方法
2026-02-05 14:10:43 +08:00
liquidliang 06a61e8133 chore: bump version to 0.5.73 2026-02-05 10:57:23 +08:00
liquidliang 25746d6b29 feat: implement image fitting utility and enhance video processing
- Replaced image cropping with a new function to fit images to target canvas sizes while maintaining aspect ratio and centering the image with a background filled with the dominant color.
- Added a utility function to extract the dominant color from images to improve visual consistency in the fitting process.
- Updated comments in the VideoHandler class to reflect the new image processing logic.
2026-02-05 10:55:53 +08:00
liquidliang 3cdc13eaf1 chore: update version to 0.5.72 and enhance LLM API logging
- Bumped application version to 0.5.72 in index.html and version.json.
- Updated build time in version.json.
- Added remoteId support in LLM API logging functions for better tracking of asynchronous tasks.
- Improved logging in image generation API for better debugging and monitoring.
2026-02-05 10:55:46 +08:00
liquidliang df013d286d chore: bump version to 0.5.72 2026-02-05 10:29:45 +08:00
liquidliang 708131f7c1 docs: 添加 LLM API 日志记录异步任务 remoteId 规则
在 CODING_RULES.md 中添加规则,说明 failLLMApiLog 和 completeLLMApiLog
函数参数需要支持 remoteId 字段,便于异步任务调试和恢复追踪。
2026-02-05 10:28:02 +08:00
liquid 504fee1c0c chore: update app version to 0.5.71 and adjust build time 2026-02-05 09:25:16 +08:00
liquid 65d6716cbb chore: bump version to 0.5.71 2026-02-05 09:21:18 +08:00
liquid 30a9bbfd13 feat: enhance analytics and reporting functionality
- Updated PostHog integration to conditionally load based on local development environment and URL parameters.
- Refactored Sentry initialization to enable reporting based on environment settings.
- Added new menu item for cleaning invalid media links, including URL validity checks and user feedback.
- Introduced new icons and translations for the clean invalid links feature.
- Improved task queue management by consolidating service worker checks and ensuring compatibility with existing services.
- Updated version and build time in version.json to reflect recent changes.
2026-02-05 09:14:48 +08:00
liquid f13f809a3f docs: 添加编码规则 - SW 初始化统一入口
- CLAUDE.md: 添加第 23 条规则 - 使用 swChannelClient.ensureReady() 作为统一入口
- CODING_RULES.md: 添加详细规则和示例代码
2026-02-05 09:08:53 +08:00
liquid e6a39db673 docs: 添加编码规则 - 模块循环依赖处理
新增规则说明如何避免和解决 ES 模块循环依赖导致的 TDZ 错误:
- 将共享函数提取到独立的隔离模块
- 使用服务注册表和 Proxy 延迟服务访问
- 单例构造函数中使用 queueMicrotask 延迟
2026-02-05 09:04:43 +08:00
liquid e0f459a63d docs: 添加降级模式任务执行规则
- 合并 CLAUDE.md 规则 13 和 20(主线程直接读取 IndexedDB)
- 新增规则 15:降级模式下 createTask 后必须自动触发 executeTask
- CODING_RULES.md 添加详细示例和说明
- task-queue-service.ts: 添加 executeTask 方法,创建/重试任务后自动执行
- task-storage-writer.ts: 添加 deleteTask 方法
2026-02-05 08:24:36 +08:00
liquid 4757a0d4bf feat: enhance video handling and task queue management
- Improved video blob retrieval by adding network fallback if not found in cache.
- Updated service worker to allow GitHub API requests to bypass caching for better performance.
- Enhanced task queue management by allowing tasks in the SUBMITTING phase to be retried without marking them as failed.
- Introduced a transparent placeholder response for missing video thumbnails to prevent playback issues.
- Added detailed logging for task retries and execution phases to aid in debugging.
2026-02-04 23:35:34 +08:00
liquidliang 1dc71a993f feat: add master badge and enhance Gist handling
- Introduced a new badge for identifying the master Gist in the SyncSettings component.
- Removed unused functions related to switching and creating Gists to streamline the code.
- Updated the GitHubSyncContext to include a flag for identifying master Gists.
- Enhanced the GitHub API service to prioritize master Gists during sync operations.
- Improved logging for better debugging and tracking of sync processes.
2026-02-04 14:53:55 +08:00
liquidliang 4376be0cac feat: implement failed URL caching for external image requests
- Added a caching mechanism to store failed external image URLs for 5 minutes to avoid repeated requests for known 404 errors.
- Introduced functions to check if a URL is likely expired and to mark URLs as failed based on their response status.
- Enhanced the fetch event listener to skip requests for recently failed URLs, improving performance and reducing unnecessary network traffic.
2026-02-04 14:30:10 +08:00
liquidliang 9847d773ca chore: bump version to 0.5.70 2026-02-04 14:27:36 +08:00
liquidliang 036cce5291 chore: update build time and refactor imports for consistency
- Updated build time in version.json to reflect recent changes.
- Refactored imports in various components to utilize @aitu/utils for consistency and improved maintainability.
- Removed unnecessary console logs and debug statements across multiple files to clean up the codebase.
2026-02-04 14:27:27 +08:00
liquidliang 066eb12d12 refactor: 清理调试日志和未使用代码
- 移除 workflow-engine、workflow-polling-service、workflow-submission-service 中的调试 console.log
- 移除 fallback-executor、sw-capabilities/handler、drawnix.tsx 中的调试 console.log
- 移除 workflow-storage-writer 中的调试日志
- 移除 engine.ts 中未使用的 getEvents 方法和 Observable 导入
- 移除未使用的 WorkflowStatus 导入
- engine.ts 行数从 502 降至 466
2026-02-04 11:30:25 +08:00
liquidliang dae0bb8ac3 feat: integrate fake-indexeddb and refactor media executor
- Added fake-indexeddb as a dev dependency for improved testing.
- Refactored media executor by extracting utility functions for building image request bodies, parsing image responses, and polling video status.
- Updated workflow engine to utilize new utility functions for better code clarity and maintainability.
- Adjusted version.json build time to reflect recent changes.
2026-02-04 11:19:47 +08:00
liquidliang 8dfcf4a351 docs: 更新工具函数规则 - 添加新模块和避免不必要包装
- 更新 @aitu/utils 可用函数列表(blob、device、format、indexeddb)
- 添加"避免不必要的函数包装/别名"规则
- 优化规则 15 描述:禁止二次导出或不必要的包装
2026-02-04 11:19:20 +08:00
liquidliang af1fb113ec chore: update app version to 0.5.69 and adjust build time in version.json 2026-02-04 10:31:27 +08:00
liquidliang 5c86d02b79 docs: 添加编码规则 - 降级路径功能一致性
降级到主线程直接调用 API 时,必须保持与 SW 模式相同的功能行为,
特别是 LLM API 日志记录,否则调试工具会漏掉这些调用。
2026-02-04 10:30:55 +08:00
liquidliang f51c14c05d chore: bump version to 0.5.69 2026-02-04 10:30:15 +08:00
liquid 3d844c4250 docs: 添加 LLM 响应格式兼容性和工作流状态同步规则
- LLM 响应格式兼容性:支持多种 AI 返回格式
- 工作流状态同步:使用轮询 IndexedDB 替代 SW 事件依赖
2026-02-04 09:18:09 +08:00
liquid 900db04dc5 feat(executor): implement unified media execution and workflow enhancements
- Added a new media executor to handle image, video, and AI analysis tasks, allowing for asynchronous execution and improved task management.
- Introduced new RPC methods for executor operations, including PING and EXECUTOR_EXECUTE.
- Updated workflow executor to support pending main thread steps, ensuring proper handling of canvas operations and media generation tools.
- Enhanced workflow status synchronization with a new hook for better UI updates and reliability.
- Removed deprecated tool response handling for improved code clarity and efficiency.
- Updated documentation to reflect changes in workflow and executor functionalities.
2026-02-04 09:16:36 +08:00
liquidliang 84e9436cc6 fix(workflow): enhance workflow submission with timeout and retry logic
- Implemented a timeout mechanism for workflow submissions, allowing for better handling of long-running operations.
- Added retry logic to ensure successful submission after initialization failures, improving robustness against transient errors.
- Updated the new workflow detection logic to consider a 60-second window for new workflows instead of 10 seconds.
- Removed unnecessary debugger statement from the AI analyze tool.
- Bumped build time in version.json to reflect recent changes.
2026-02-03 20:43:21 +08:00
liquidliang 10f953f73c docs: 添加编码规则 - IndexedDB 直接读取和 RPC 超时处理
- 主线程直接读取 IndexedDB 优于 RPC:避免 postMessage 限制
- RPC 超时与重连策略:合理超时 + 自动重连重试
2026-02-03 20:42:27 +08:00
liquidliang ebb412d1c3 docs: 添加同步数据格式一致性规则
- CLAUDE.md: 添加第19条 SW 规则摘要
- CODING_RULES.md: 添加详细示例和数据格式参考表

修复调试面板中多处使用错误数据格式的问题:
- tasks.json 结构是 { completedTasks: Task[] } 不是数组
- 画板文件是 board_{id}.json 不是 .drawnix
2026-02-03 17:21:27 +08:00
liquid 061423a931 feat(gist): add Gist management panel and enhance sync logging
- Introduced a new Gist management panel in the SW debug interface, allowing users to manage Gist configurations and view shard statistics.
- Updated sync services to utilize a unified logging system for better tracking of sync operations, including success and error logging.
- Enhanced error handling and logging in the MediaSyncService and ShardSyncService to provide clearer insights during synchronization processes.
- Bumped app version to 0.5.68 to reflect these changes.
2026-02-03 09:08:48 +08:00
liquid 97332dc7f1 docs: 添加同步模块日志规范
- 更新 CLAUDE.md 规则6,同步模块使用统一日志服务
- 在 CODING_RULES.md 添加详细的同步模块日志规范
- 包含正确/错误示例和 API 说明
2026-02-03 09:07:45 +08:00
liquid 49329c411d chore: bump version to 0.5.68 2026-02-02 22:25:22 +08:00
liquidliang 4e2741c955 docs(claude): 添加新规则 - GitHub Gist API 批量上传大小限制 2026-02-02 20:17:20 +08:00
liquid 163bcee133 fix(sync): enhance manifest decryption error handling
- Improved error handling during manifest decryption to check for local data before deciding to overwrite remote data.
- Added checks to prevent data loss by refusing to overwrite remote data if local data is empty, ensuring safer synchronization.
2026-02-02 09:53:15 +08:00
liquid fedfebd40c chore: update app version to 0.5.67 and adjust build time 2026-02-02 09:26:17 +08:00
liquid 70486b7755 chore: bump version to 0.5.67 2026-02-02 09:16:10 +08:00
liquid 3a93bf08d5 feat(sync): implement soft delete and data recovery features
- Updated SyncManifest to include records for deleted prompts and tasks, enhancing data recovery capabilities.
- Introduced PromptTombstone and TaskTombstone interfaces to track deleted items with metadata such as deletion time and device ID.
- Enhanced data-serializer and sync-engine to support detection and application of deletions, ensuring safe data synchronization.
- Added UI components in SyncSettings for managing deleted items, including a recycle bin for restoring and permanently deleting items.

This update significantly improves the synchronization process by allowing users to recover deleted items while maintaining data integrity.
2026-02-02 09:15:56 +08:00
liquid 27064a500e feat(sync): 任务队列同步下载远程数据时双向合并
- 修改 applySyncData 中的任务合并逻辑,基于 ID 去重
- 使用 updatedAt 时间戳判断保留更新的版本
- 合并完成后自动上传任务数据到远程,确保双向同步
- 添加编码规则:同步数据双向合并
2026-02-02 07:49:49 +08:00
liquid d0eafd68b9 chore: bump version to 0.5.66 2026-02-02 07:16:56 +08:00
liquidliang f33025443d Merge branch 'develop' 2026-02-01 22:22:35 +08:00
ljquan 4b143190a9 Merge pull request #95 from changesydneyai-max/develop
Develop
2026-02-01 22:22:14 +08:00
liquidliang 6c01e7e33b Merge branch '92-sw' into develop 2026-02-01 22:21:32 +08:00
liquidliang a95ddd20b0 docs: 添加异步操作和事件订阅相关规则
- 异步操作不阻塞 UI:远程同步等耗时操作应异步执行
- 关键操作直接调用:不依赖 RxJS 事件订阅触发业务逻辑
2026-02-01 22:19:21 +08:00
liquidliang 8ecc8e7571 docs: 添加 CSS 变量优先级和弹出菜单截断规则
- CLAUDE.md: 更新 createPortal 规则说明,新增组件内颜色使用规范
- CODING_RULES.md: 添加详细的 TDesign CSS 变量优先级问题说明
- CODING_RULES.md: 添加弹出菜单被 overflow 截断的解决方案
2026-02-01 22:19:02 +08:00