Repository navigation
fix(dashboard): keep delegation paging visible and keyboard-accessible - #7623
Conversation
Signed-off-by: LoopX Agent <337587101+loopx-agent@users.noreply.github.com>
Signed-off-by: LoopX Agent <337587101+loopx-agent@users.noreply.github.com>
loopx-agent
left a comment
There was a problem hiding this comment.
Reviewer: model_agent; model=gpt-6.1-sol; provider=OpenAI; declaration_source=runtime_reported; reasoning_effort=max.
Approval conclusion (author-owned PR; GitHub blocks formal self-approval)
结论:APPROVE,未发现阻塞问题。 已独立检查完整head 8c5771fe01f2ab8efd3833c2817acb25c0399ff9,以 652f503842609e948e8ff832ae3977f23f79f28d 为变更前基线。GitHub同账号限制下使用COMMENTED;这不是正式自批准或合并授权。
动机 / Motivation
查看委派清单的用户需要知道当前已加载多少记录,并能继续读取后面的请求。
同一批43条委派中,旧版把更多记录放在长列表末尾,窄屏首屏看不到分页操作;新版让计数和分页留在页脚,展开长正文时仍可继续读取。
实测新head可按键盘加载12→24→36→43条,最终焦点转到43/43计数,搜索仍使用匹配记录数作为分母。
本PR只交付清单布局、分页焦点和可读计数,不改变委派来源、筛选、状态判断、权限或回传执行,也不宣称完成安装采用、库存延迟优化或长程模型收益。
不修复会让用户反复滚动长列表寻找下一页,而且键盘分页后的焦点回到页面;只增加计数无法修复操作不可见和焦点丢失。此次没有增加用户确认轮次,既有打开清单、搜索和阅读动作继续原位完成。
改动思路 / Approach
保留现有组件、请求读取owner和ContextHelp,只调整局部flex布局与临时焦点意图;没有新增分页协议、共享状态或第二份决策owner。
当前PR边界是完整可用的委派分页展示修复;底层来源恢复、回执冲突和整体库存性能仍沿原owner处理。
入口仍是管家页的ConversationRequests,数据由fetchConversationRequests读取真实Chat/SQLite/Inbox。原load继续负责scope、generation、abort、snapshot digest和失败重试;页脚只消费既有matched及coverage,搜索分母没有换成全量pending_count。
弹窗改为纵向flex,标题、筛选和页脚不收缩,列表以min-height:0独立滚动。相比给旧max-height再减一个固定数字,这能直接适应标题、搜索换行和长正文。分页按钮保留键盘焦点,用aria-disabled及busy拒绝重复动作;末页按钮消失后才把焦点交给可读计数。若用户已移走焦点,既有activeElement检查阻止抢焦点。
具体改动 / Changes
完整diff为3个文本文件+41/-9及5张合成图片;其中生产TSX/CSS为+31/-8,smoke为+10/-1。五张图片均检查了像素及PNG元数据,内容为公开合成委派,没有私有消息、凭据或本机路径。实际PR正文已直接嵌入前后桌面、窄屏和展开截图,标明源码与packaged边界。
关键代码讲解
- ConversationRequests::load仍使用原scope和snapshot fence;实际43条清单的四页、搜索及错误恢复均经真实HTTP读取,没有用新的前端列表替代后端结果。
- 分页焦点effect消费restorePagingFocus临时ref。12→24和24→36后继续停在按钮,36→43后停在结果span;各页在读取期间再按一次Enter,仍只有一次inventory请求。
- 页脚渲染显示rows.length/matched,部分读取追加+并使用原ContextHelp。真实503会清空旧行、隐藏页脚并保留重试;恢复后重新读取当前搜索scope。
- 弹窗flex规则替换重叠的viewport减法。1440×1000、390×844和展开长详情都实测;窄屏更多按钮底边823,处于844高的viewport内。
规范依据:spec_ref docs/development/design.md,spec_revision 652f503842609e948e8ff832ae3977f23f79f28d;实施前也读取同版本docs/development/frontend-delivery.md的Task-first delivery。原规范章节逐项映射:Earn The User's Attention → implemented,下一页和真实加载数默认可见;Explanations On Demand → implemented,部分读取以+和可访问帮助保留,不再重复解释段落;Accessibility → implemented,键盘分页、末页焦点和Escape返回入口实测;Populated Page Review → implemented,默认/展开、长内容、空搜索及失败恢复均观察;Task-first delivery → implemented,使用构建后的实际Chat页面和隔离SQLite后端,而非组件截图代替流程。
对主干的风险 / Risks
最强反例是固定页脚挤掉正文、末页删除按钮又丢焦点,或搜索后误显示43这个总数。相同43条负载在旧版390×844中,更多按钮底边约2006,三次键盘分页都落到BODY;新head底边823,最终焦点为“已显示43/43”。reviewer搜索为12/14→14/14,无匹配为0/0;单项搜索、原对话、清空和关闭后返回原入口也实际执行。
14个原生inventory测试、Chat构建及TypeScript检查PASS,改变的smoke通过node语法检查。原完整Playwright脚本未启动;本次通过Ego执行受影响的实际packaged分页、搜索、长内容、中英文和失败恢复路径。真实后端四页保留43个唯一请求,除夹具生成的身份和创建时间外,完整brief、状态、decision、returns、warning、linked work、数量及coverage逐项一致;每臂内部来源身份另行检查,没有把scope差异归一化为产品资格。
标准premerge的4个direct、4个catalog和1个public-boundary检查PASS;整体exit1来自5张二进制图片的visual_evidence人工hold,未改写成门禁通过。已逐张核验其像素、尺寸及PNG仅IHDR/IDAT/IEND/iCCP块,提供本次人工检查证据;原canary回执和维护者合并决定仍分别保留。两臂fixture最终均source_unchanged=true,所有POST均由只读fixture拒绝;各有3个启动相关POST尝试,不能报告零HTTP写请求,也没有执行外部消息或模型。
语义与CI对齐
新变量仅是React局部焦点ref,复用原API、状态和locale词汇,没有新增共享Enum或权限语义。默认变化仅为页脚、搜索匹配计数及焦点行为,PR正文和smoke已明确披露;不存在opt-in/default-off声明。底层来源及snapshot拒绝未改,不把数量、已加载页或帮助提示当作验收或执行权。wait_for_ci=false,未查询、轮询或等待CI。
我的整体评价 / Verdict
这是goal_achieved,仅针对本次分页展示切片。long_horizon判为preserved:完整请求和后页仍可达,重读或关闭不新增委派effect,未以本地通过推断长期任务收益。user_experience判为improved:下一页可见且键盘可连续完成,搜索、错误与恢复保持真实,额外强制确认轮次为零。
已观察43条、两位接收方、长中英文标题与长brief的整页:计数和更多记录清楚留在页脚,正文独立滚动,完整约束、验收和原对话可读;桌面及390px展开仍使用14px正文,没有靠缩字藏内容。
未验证正式安装的native WebView、真实模型及持续库存延迟;File provider未单独运行,底层存储和API代码在本PR无变更。部分读取提示单独使用显式注入响应,只证明该展示分支。
scope、data owner和callback没有迁移,局部改动规模相称;以flex直接替代多处高度算术,比保留另一套兼容布局更小。未发现需要本PR扩大为配置、backend迁移或新组件框架的理由。正式GitHub审批、分支保护及受保护合并继续独立办理。
English verdict: APPROVE — 8c5771f keeps paging visible, preserves matched counts, and retains keyboard focus through the final page; packaged positive and recovery checks passed.
Goal And Delivered Outcome
The delegation dialog showed a pending total while loading only twelve rows, with More records below the scrollable list. On a 390px viewport the baseline button started at y=1393, outside the 844px screen. The dialog now keeps paging and the loaded/matched count in a persistent footer. Search uses its own matched denominator; incomplete coverage retains an accessible alert disclosure and
+.Author Declaration
docs/development/design.mdanddocs/development/frontend-delivery.mdat652f503842609e948e8ff832ae3977f23f79f28d; reproduced pagination defect described above.Self-check: reviewed the complete TSX/CSS diff, source/snapshot error paths, and synthetic screenshots. No new state vocabulary, provider, authority or query semantics. The flex layout replaces overlapping viewport-height calculations within the same component.
Scope And Continuation
Complete UI paging slice. Existing work still owns historical conflicting-receipt recovery and end-to-end inventory latency investigation. This PR does not claim those problems fixed, installation adoption, or backend performance gains. They remain independent from the reversible presentation change.
Validation
8c5771fe01f2ab8efd3833c2817acb25c0399ff9(identical to parentbd8cf18c59c50ae6ae21516f905fd98d1b5edcee); baseline652f503842609e948e8ff832ae3977f23f79f28d.git diff --check; existing bundle-size warning retaineduv run --extra test python -m pytest tests/control_plane/test_chat_request_inventory.py -q: 14 passed; source/authority/snapshot boundary coveragenode --checkfor the extended existing browser smokeNo installed App claim. File-provider behavior is unchanged and was not separately exercised here. Unknown/receipt-conflict repair and latency qualification remain open.
Frontend / Visual Evidence
Before desktop:

After desktop:

Type of Change
LoopX Area
Shared-authority RFC fixture impact
N/A: no authority or control-plane migration behavior changes.
Boundary Checklist