feat(providers): 请求头导入改为独立视图 - #319
Merged
Merged
Conversation
导入按钮补上 ClipboardPaste 图标并在展开时进入选中态;点击后请求头 列表整块换成导入输入框(带入场动画与自动聚焦),解析成功后增量合并 并自动切回列表,失败则留在导入视图显示错误。 列表被顶掉期间:"添加"按钮禁用(新增行不可见,避免静默无响应),列表 级校验文案隐藏,保存命中非法请求头时先切回列表再聚焦。 "添加请求头"按钮文案缩短为"添加"/"Add",与相邻的"导入"对齐。 GUI 与 WebUI 两端同步。
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
改动
供应商配置里「自定义请求头」的导入交互美化,GUI 与 WebUI 两端同步(这段代码本来就是逐字一致的镜像)。
ClipboardPaste(两端 icons 桶里已有,未新增图标依赖),补gap-1.5与相邻「添加」按钮对齐;展开时按钮进入选中态,配合原有aria-expanded。provider-panel-enter入场动画、textarea 自动聚焦可直接粘贴;点「解析并导入」成功后按原有mergeImportedCustomHeaders增量合并(同名覆盖、新名追加)并自动切回列表,每行的入场动画让导入结果有反馈;解析失败仍留在导入视图内显示错误。顺带处理的一致性问题
「隐藏列表」带出来的两处,否则会出现静默无响应:
handleSave先关掉导入视图再聚焦——否则目标输入框尚未挂载,聚焦是空操作。验证
biome check告警数与基线完全一致(GUI 5 warnings / 3 infos、WebUI 3 / 3,全部落在未触碰的区域)tsc --noEmit干净test/settings+test/providers428 项通过、test/i18n4 项通过;WebUInpm test487 项通过工作区里
Cargo.lock的依赖解析改动(rustix 版本拆分)在本次改动之前就已存在,与本 PR 无关,未纳入提交。