Repository navigation
test(web): 多页签浮层补整页滚动 / 刷新恢复 / 菜单贴底的回归测试(#421) - #436
Merged
Merged
Conversation
yile2020
force-pushed
the
test/issue-421
branch
from
November 21, 2026 22:50
a42126d to
630a2e6
Compare
yile2020
enabled auto-merge
November 21, 2026 22:50
- 新增 tab-overlay-boundary.spec.ts,滚动方式 page / content 各跑三条: 后台页签里开着的 URL 抽屉不锁滚动、不挡前台、切回来同一个输入节点和值都在; 刷新后从 sessionStorage 恢复的后台页签不挡前台,点回去再切走仍隐藏; 贴底的行操作菜单挂 <body>、完整可见、逐项在最上层、焦点进出正确、不改滚动位置 - 滚动锁两条实现都认(属性 / 覆盖式滚动条下只写内联 overflow) - shell 分册:补 portal 容器策略表;推翻「菜单挂进内容区会被裁」的推断; 记下后台恢复的抽屉根本不挂、滚动锁只在整页模式伤人 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…al 连坐 · 注释与分册证据对齐实测(#421) - afterAll 先 DELETE 本用例自动存下的 admin 发起草稿:草稿列表不看定义停没停用,原来每跑一次往共享库多留一份(实测私有库里留了 2 条) - beforeAll 断言 publish 返回 published=true,校验不过时不再六条全晚到 wf-start-sheet 才红 - 「↓ 能走」改为断言焦点落在 role=menuitem 上:原断言打开时焦点就在弹层里,去掉 ↓ 照样绿(变异实测:新断言红) - 焦点进菜单 / inert / 铃铛不在 [data-tab] 的一次性读改成 expect.poll - describe.configure 由 serial 改 default:同一 worker 顺序跑、beforeAll 只建一份,但 page 模式红不再把 content 三条连带跳过 - 文件头 / 刷新用例注释改成实测行为(恢复到后台时抽屉没挂,portal 容器靠后半段守);滚动锁描述指向 pageLocked - shell 分册策略表:只实测了审批「发起」,其余 URL 抽屉标为推断 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
yile2020
force-pushed
the
test/issue-421
branch
from
November 22, 2026 00:01
630a2e6 to
55f1d6f
Compare
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.
Closes #421
守的是什么
TabOutlet把 URL 驱动的抽屉 portal 挂进本页签根节点(useTabPortalContainer),后台时抽屉跟着页签隐藏、状态保留。已有的workflow.spec.ts「填到一半切走再切回来」只在默认的内容区滚动下验了应用内切换。这次补 issue 列的几种边界。新增
apps/web/e2e/tests/tab-overlay-boundary.spec.ts(6 条 = 3 个场景 ×page/content两种滚动方式)?start=)page看window.scrollY,content看视口不动、内容层动)、铃铛面板挂<body>能开能关、焦点回到铃铛;切回来后抽屉可见,是同一个输入节点(打了记号,避免被草稿恢复蒙过去)、值还在、滚动锁重新拿上[data-tab]里、完整落在视口内、每个可点项中心的elementFromPoint都是它自己、焦点进菜单 / ↓ 可走 / Esc 回到触发器、打开关上前后滚动位置不变每条都先红后绿(变异实测)
私有环境:api :8421 →
fba_i421_test(PostgreSQL)+ 一次性 Redis :6421,web :1421,临时 playwright 配置(已删)。每个变异改完后按单条用例逐个跑,改回再跑全绿。start-sheet.tsx的container={container}→undefined(撤掉修复,portal 回<body>)expect(sheet).toBeHidden()(Received: visible);「刷新恢复」两种模式都红在再切走那一步的toBeHidden()TabOutlet用display:none的 div 代替<Activity>(隐藏页签保留 effect)page模式红在「前台应该能滚」,content模式通过,说明用例能区分两种模式;而且前台照样点得动,只断言「能点」抓不到这个问题[data-tab]里」那句collisionAvoidance={{ side: 'none' }}(不翻转)改回之后:新文件 6 条
--repeat-each 212/12 绿;连同tabs/tab-isolation/session-tabs/overlay-leave/page-overflow/workflow/notice-reach一起跑 43/43 绿。pnpm typecheck --force·pnpm lint·pnpm arch:check·pnpm ctx:check都过。实测出来的新结论(已写进
packages/platform/src/shell/AGENTS.md)data-base-ui-scroll-locked:覆盖式滚动条、页面没溢出时,只在<html>/<body>上写内联overflow: hidden。用例第一版只认这个属性,在打开抽屉时就红了?start=在,wf-start-sheet节点 0 个,去掉container也一样):Base UI 靠 effect 建 portal 节点,hidden 的<Activity>不跑 effect。原始 bug 的现场是「刷新后那页正开着、再切走」,所以用例两段都测<body>的理由改写成「浮层不该跟着页签一起隐藏、一起滚动」<body>,页面下拉菜单挂<body>没覆盖的
useTabPortalContainer,没逐个写用例mouse.wheel🤖 Generated with Claude Code