4 Commits

Author SHA1 Message Date
MikiVL
d632e9f6f7 feat(M3): AI 续写/润色/摘要/问答、Hono 代理、模型管理窗口
- 新增 Hono 代理服务(server/index.ts,端口 3001),SSE 流式转发 Claude API
- 新增 src/lib/ai.ts:streamAI() 封装 fetch + ReadableStream + AbortController
- 新增 AI 面板(AiPanel.tsx):流式聊天问答、全文摘要、停止按钮
- 新增模型管理弹窗(ModelSettingsModal.tsx):增删模型、切换激活模型
- 编辑器新增 AI 续写()和面板切换()按钮
- 浮动工具栏新增润色(Wand2)和摘要(FileText)按钮,结果预览 Modal 支持一键替换
- appStore 新增 aiPanelOpen + toggleAiPanel
- vite.config.ts 添加 /api 代理到 localhost:3001
- index.css 添加 .ai-cursor 光标动画

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-03 00:03:50 +08:00
MikiVL
54366cb60c feat(M1): complete remaining editor features
- Replace StarterKit codeBlock with CodeBlockLowlight (lowlight/common) for syntax highlighting
- Add Image extension with URL slash command, drag-and-drop and paste support
- Show reading time estimate in editor footer (wordCount / 250 min)
- Implement focus mode: sidebar collapses with CSS transition, toggle button in title bar, Esc to exit
- Add focusMode state + toggleFocusMode action to Zustand store
- Add highlight.js CSS theme (light/dark) and image/sidebar-transition styles

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-02 19:24:34 +08:00
MikiVL
bf2b16c78c feat: add welcome view, fix duplicate seeding, add star/delete UI
- Replace editable intro note with a static read-only WelcomeView component
- Add "使用指南" sidebar nav item always pointing to WelcomeView
- Fix React StrictMode double-seed race condition via module-level Promise singleton
- Add deduplicateDB() to clean up already-inserted duplicates on startup
- Add star button in editor title bar and sidebar note hover row
- Add visible delete button on note item hover in sidebar
- Default activeNoteId to '__welcome__' sentinel; deleted notes return to WelcomeView

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-02 19:16:50 +08:00
MikiVL
45871ac481 Initial commit
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-02 14:36:32 +08:00