Skip to content

feat(models): support drag reordering selected models - #634

Merged
vastsa merged 4 commits into
mainfrom
feat/model-drag-reorder
Sep 19, 2026
Merged

vastsa merged 4 commits into
mainfrom
feat/model-drag-reorder

Conversation

@vastsa

@vastsa vastsa commented Sep 19, 2026

Copy link
Copy Markdown
Owner

Lands #396 onto current main.

功能

在「编辑 AI 服务 → 模型设置」中,通过每个模型左侧的拖动手柄上下重新排序。保存后顺序保留,模型选择器按该顺序显示。

  • 拖动手柄 / 聚焦后 ↑↓ 调整顺序;搜索过滤时保留隐藏模型及其覆盖配置。
  • 沿用现有「首项 = 服务默认模型」行为;已绑定模型的会话不变。无 schema / IPC 变更。
  • 相对原 PR:变基到当前 main,去掉无关的 CI 修复提交,抽出拖放/键盘纯函数并补测试。

验证

  • apps/desktop 相关单测 70 项通过(含 model-reorder、composer-models、provider-model-config、provider-form-layout)。
  • desktop typecheck、style tokens、biome lint、architecture check、pnpm docs:check、i18n catalogs 通过。

Closes #396

inorilzy and others added 4 commits September 19, 2026 14:51
Extract drop placement and visible-neighbor math from the hook so the
filtered-list and arrow-key cases run as tests. Skip redundant dragover
updates and recover the drag source from the MIME payload if React state
lags behind the drop.
Copilot AI lite review requested due to automatic review settings September 19, 2026 06:51

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@vastsa
vastsa merged commit f0c8051 into main Sep 19, 2026
4 checks passed
@vastsa
vastsa deleted the feat/model-drag-reorder branch September 21, 2026 11:16

This branch was successfully deployed

1 active deployment
Preview — 733042e6 Deployed Sep 19, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants