32 Commits

Author SHA1 Message Date
Estrella Pan
6e8f2f0f35 refactor(webui): 图标换成 @lucide/vue,headlessui 换成 naive-ui,并改用 Vue 3.5 写法
- 30 个文件的 @icon-park/vue-next 图标换成 @lucide/vue;侧栏与移动导航的 RSS 图标
  改用 Lucide Rss,删除 vue-inline-svg 与 public/images/RSS.svg
- ab-modal 用 NModal、ab-bottom-sheet 用 NDrawer、ab-menu 与 ab-status-bar 系统菜单
  用 NDropdown、通知中心用 NPopover、ab-fold-panel 用 NCollapse;公开 props/emits/slots
  不变,dialog 语义、aria-expanded、menuitem 角色与 Esc 关闭由组件补齐;删除 @headlessui/vue
- naive-ui 主题覆盖移到 src/style/naive-theme.ts(abNaiveTheme),新增 Dropdown/Collapse/
  Popover 的 ab-* token;遮罩颜色统一为 --color-overlay
- withDefaults 改为响应式 props 解构;模板引用改用 useTemplateRef;ab-bottom-sheet、
  llm-auth-dialog、ab-list 的 v-model 改用 defineModel;visualViewport 监听用
  onWatcherCleanup 撤销;复制提示改用 useClipboard({ copiedDuring })
2026-10-20 11:45:48 +02:00
Estrella Pan
5d8a02787a chore(webui): ESLint 10 + antfu flat 配置取代 Prettier,husky 升级到 9 2026-10-20 11:12:07 +02:00
Estrella Pan
13dc621ff7 chore(deps): 前端运行时升级到 vue-router 5 / pinia 4 / vueuse 15 / vue-i18n 11 / axios 1.20 2026-10-20 11:06:50 +02:00
Estrella Pan
2f1fa317d1 chore(deps): 前端构建与测试工具链升级到 Vite 8 / Vitest 5 / TS 6 / Storybook 10
- vite 8、@vitejs/plugin-vue 6、vitest 5、happy-dom 21、@vue/test-utils 2.5、
  typescript ~6.0.3、vue-tsc 3.3、unocss 66.11、unplugin-auto-import 21、
  unplugin-vue-components 32、sass-embedded 1.105、playwright 1.64.1、storybook 10.6
- vite.config:去掉 defineModel 开关;Sass 改用 @use;esbuild.drop 换成
  rolldown 的 dropConsole;__dirname 换成 import.meta.dirname;两处 alias
  改为 resolve.tsconfigPaths
- 删除 plugin-vue-jsx:三个 SFC 的 JSX 改写为 h()
- 删除 preset-attributify:模板里的属性式工具类全部改回 class
  (含 space-y-*、text-*、line、i-carbon-* 等,不止 5 处 flex="~")
- 删除 vite-plugin-pwa:改为静态 manifest.webmanifest + 自毁 sw.js(4.1 删除)
- tsconfig:moduleResolution Bundler、去掉 baseUrl 与 JSX 配置,
  app 的 types 只留 vitest/globals
- Storybook 10:addon-links + addon-docs,stories 改从 @storybook/vue3-vite 导入类型
- @intlify/unplugin-vue-i18n 0.11 -> 11.2.7(Vite 8 下旧版产物被 vite-json 再次解析而失败);
  新版只产出 AST 文案,故打开 __INTLIFY_JIT_COMPILATION__,hasKey 识别 AST 叶子
2026-10-20 11:00:31 +02:00
Estrella Pan
02e0c3ea63 chore(deps): CI 运行时升级到 Node 24 / pnpm 12,并移除未用依赖
- Node 24、pnpm 12.14.0、pnpm/action-setup@v6,@types/node ^24
- .npmrc 的 public-hoist-pattern 迁入 pnpm-workspace.yaml,新增 allowBuilds
- docs 同步迁移 pnpm 12
- 删除 @vueuse/components、radash、generate-pwa-assets 脚本、失效的 coverage 配置、app AutoImport 的 vitest 预设与 Components dirs
2026-10-20 10:41:07 +02:00
Estrella Pan
bf1c8db08c feat(4.0-P6): 前端插件后端与 plugin-ui 工作区包
- 清单 [[plugin.ui]]:五个挂载点、ab-plugin- 元素名与 web/ 入口校验
- GET /plugins/ui 列出已启用插件的挂载点;GET /plugins/{id}/web/{path} 提供静态资源(防路径穿越、JS MIME、需登录)
- SPA 文档加 CSP script-src 'self',内联深色模式脚本移到 theme-init.js
- webui/packages/plugin-ui:AbHost 类型、--ab-* 主题变量、Vite 库模式模板
- 设计文档第 0 节记录第一部分的调整
2026-10-08 13:31:03 +02:00
Estrella Pan
8df50b65eb test: add browser auth e2e coverage 2026-07-10 13:50:15 +02:00
Estrella Pan
d80bf89cfa fix(webui): restore config page — naive-ui theme crash and missing controls
Two regressions from the component-system unification left the Config
page blank or control-less:

- App.vue passed var(--color-danger) as common.errorColor*; naive-ui
  runs JS color math (seemly rgba) on these tokens and threw
  "Invalid color value var(...)" while rendering NSelect, killing the
  whole page subtree. Error colors are now per-theme literals.
- ab-setting.vue still referenced the deleted AbSwitch/AbSelect
  primitives, which auto-resolution silently rendered as nothing —
  every switch/select in settings vanished. Replaced with themed
  NSwitch/NSelect plus an items→options adapter for the old API.
- Bumped naive-ui 2.39→2.44: 2.39 predates Vue 3.5 and crashed NTag
  rendering inside NDynamicTags ("theme.self undefined").

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01GTnuEgR78cBk32bLNKar3z
2026-07-02 21:33:02 +02:00
Estrella Pan
7733bd18f7 fix(webui): setup loop, reactive selects, escape handler, axios/i18n and dep bumps
- Clear needSetup after completion so the wizard stops bouncing back to itself
- ab-select watches modelValue (config selects showed stale defaults); notification-type dropdown renders options
- Search modal Escape handler no longer opens the modal from anywhere; ab-button defaults type=button (no double login)
- axios surfaces 400/404/422; background polls suppress the network-error toast storm; calendar re-reads locally on activate
- Search subscribe uses the active provider + i18n; provider settings go through axios; dead search-store code removed
- Bump axios ^1.7 (CVE-2023-45857) and vue-i18n ^9.14.2 (XSS); add missing i18n keys

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_014w1Z6Nxy6XTRgkFXqPr9Zh
2026-07-02 17:05:50 +02:00
Estrella Pan
a0bf878b7e feat(calendar): add drag-and-drop to assign unknown bangumi to weekdays
Allow users to drag bangumi cards from the "Unknown" section into weekday
columns in the calendar view. Manual assignments are locked so calendar
refresh from Bangumi.tv doesn't overwrite them. A reset button lets users
unlock and send cards back to Unknown.

Backend:
- Add weekday_locked field to Bangumi model (migration v9)
- Add PATCH /api/v1/bangumi/{id}/weekday endpoint
- Skip locked items in refresh_calendar()

Frontend:
- Add vuedraggable for smooth drag-and-drop
- Pin indicator and unpin button on manually-assigned cards
- Drop zone highlighting during drag
- i18n strings for drag/pin/unpin

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-23 14:21:00 +01:00
EstrellaXD
a137b54b85 test: add comprehensive API tests for backend and frontend
Backend:
- Add API test files for auth, program, downloader, config, log, bangumi extended, search, and passkey endpoints
- Update conftest.py with new fixtures (app, authed_client, unauthed_client, mock_program, mock_webauthn, mock_download_client)
- Update factories.py with make_config and make_passkey functions

Frontend:
- Setup vitest testing infrastructure with happy-dom environment
- Add test setup file with mocks for axios, router, i18n, localStorage
- Add mock API data for testing
- Add tests for API logic, store logic, hooks, and basic components
- Add @vue/test-utils and happy-dom dev dependencies

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-26 16:20:39 +01:00
Rewrite0
8972373cb7 fix: vue-tsc error 2024-09-23 16:53:02 +08:00
Rewrite0
cee640d9af fix: type error 2024-09-23 16:38:02 +08:00
Rewrite0
ec2856bf5a refactor: refactor search logic & remove rxjs 2024-09-23 16:07:48 +08:00
Rewrite0
fcdcde07ed feat: update deps 2024-09-23 15:49:52 +08:00
Rewrite0
7913061f45 ci: modify process 2024-05-31 16:37:22 +08:00
Rewrite0
b0eef9e8d2 fix: ci pnpm version 2024-05-31 16:05:52 +08:00
Rewrite0
ae43989bc8 feat: 移动端响应式布局 2024-05-29 15:25:10 +08:00
Rewrite0
31631214bd feat: lodash 更换为 radash 2024-04-23 10:46:44 +08:00
Rewrite0
c95fe89d5d refactor: 整理unocss,重构useApi,完善通知i18n,调整了一些代码写法,调整了一些样式,清理了一些无用依赖和代码 2024-03-07 15:58:33 +08:00
Rewrite0
c20369fb95 feat: Enable Vue JSX support 2024-03-05 10:38:22 +08:00
EstrellaXD
ef19f4ed07 feat: add vue/component 2023-09-08 10:50:06 +08:00
zthxxx
7d50e360ed fix: 修复 bangumi search API 中的流式接口,webui 对应接口定义方法改造
- StreamingResponse 换成 EventSourceResponse,即 Server Send Event Source 方式发送数据
- webui 中 search 接口改成 rxjs Observable 方式,
  这次来不及改到 vue 里,但是写了接口 usage example;
- 顺手补了一些 vscode 通用的开发配置,
  补了之前配置文件解析漏了一个可用环境变量的 host 字段
2023-08-31 23:48:07 +08:00
Rewrite0
3425e38bb1 feat: create RSS page 2023-08-13 19:49:43 +08:00
Rewrite0
86fdb7a56a feat: webui pwa support 2023-08-12 23:15:26 +08:00
Rewrite0
cd0ff943f2 feat: Optimization 2023-06-14 22:08:07 +08:00
umbor
a9c037e69c Remove unplugin-vue-i18n and change language file format
去除unplugin-vue-i18n,语言文件改为json格式,把i18n-ally的localespaths设置为"src/locales/lang"就可以用。缺少downloader及calendar及format问题也一并修改。
2023-06-12 13:08:36 +08:00
umbor
5dd0d84a79 Merge branch 'EstrellaXD:3.1-dev' into 3.1-dev 2023-06-12 12:36:42 +08:00
100gle
b5b632ef29 feat: use husky to add git hooks before commiting code 2023-06-11 20:27:49 +08:00
umbor
4ae0bcec65 Fix some bugs
Fix some bugs
2023-06-11 14:24:17 +08:00
umbor
c53f5f9c49 Add i18n basic components
Add i18n basic components
2023-06-10 23:16:51 +08:00
zthxxx
684e124480 chore: move Auto_Bangumi_WebUI -> Auto_Bangumi_WebUI/webui/, prepare for merge into AutoBangumi repo 2023-06-05 23:47:00 +08:00