Skip to content

feat(plugin-detail): a double-click on the record page details divider resets the column to its default width - #36474

Merged
objectstack-fleet[bot] merged 5 commits into
mainfrom
claude/issue-36226-divider-double-click-reset
Nov 22, 2026
Merged

objectstack-fleet[bot] merged 5 commits into
mainfrom
claude/issue-36226-divider-double-click-reset

Conversation

@objectstack-fleet

@objectstack-fleet objectstack-fleet Bot commented Nov 22, 2026 •

Copy link
Copy Markdown
Contributor

Requested by Steedos · project thread
repo:objectstack#7 · zhuangjianguo · session_01QsR2jRaJbQ4vqdv4J5peqA

Fixes #36226

Clause-②: no — no public type or accept set; one interaction on an existing control
Metadata-protocol: none

维护者速读

  • 宽屏打开记录整页时,左边字段栏和右边页签之间的分隔线,双击就回到默认宽度 400,并且记住;以前只能拖动或用方向键调。
  • 属于「记录页对标 Attio」专题:这张卡的五条里只差「双击复位」这一条,其余四条(可拖的分隔线、拖动范围、按人按对象记住宽度、评论栏不动)此前的记录页改版已经做完,这次在控制台里逐条实测并附了截图。
  • 碰到的只是在宽屏记录整页双击分隔线的人;出错最多是双击没反应或宽度不对,拖动和键盘照常能用,这次改动可以直接撤回。
  • 无

What changes

Read first, by risk:

  1. ui/packages/plugin-detail/src/RecordPageColumns.tsx: the onDoubleClick on DetailsWidthHandle. It commits the unclamped default, never clamp(400), so a narrow window does not store a smaller width as "the default".
  2. ui/packages/plugin-detail/README.md: the rewritten table under "One record page, laid out by its width".
  3. ui/packages/plugin-detail/src/__tests__/RecordPageColumns.test.tsx: the new it in the objectstack#35890 describe, with a host stand-in that re-reads its store on every mount.

Console evidence

This branch's Console (vite) runs against a fresh examples/app-crm backend (--fresh, seeded). The browser is headless Chromium at 1440×900 @2x, zh-CN, signed in as the seeded admin. The page is 客户 (crm_account), a synthesized record page. Readings come from the separator's aria-valuenow and the column's measured width.

Step 客户 record page Reading
Before the drag 01-before-drag 400 (max 664 at 1440)
After dragging +160 02-after-drag 560
Another 客户 record 03-other-account-keeps-width 560, kept
A 联系人 (crm_contact) record 04-contact-default 400, the default: the width is kept per reader and per object
Back on 客户, double-click 07-after-double-click 400
Reload, then the first 客户 record again (no shot) 400 and 400: the reset is kept

after the double-click: the details column back at 400

Comment panel. At 1920×1080 @2x with the comment panel open beside the page, before and after a drag of +120: the column goes 400 → 520, then a double-click returns it to 400. The comment panel measures 380 px at each of the three readings. At 1440 with the panel open, the page content is under 744 px, so the page does not pin and there is no divider to drag (05-comments-open): the details are the 「详情」 tab and the panel is still 380.

Narrowing the window. At 1280, 1100, 1000, 900, 800, 700 and 600 px wide, the document never scrolls sideways (scrollWidth equals clientWidth at each). The column stays 400 down to 900, where the divider's max is 412. At 800 and below the page is no longer pinned (08-narrow-900, 08-narrow-800). The only sideways scrollers inside the page are the related lists' own grids, which scroll by design.

HotCRM's 客户 page: NOT MEASURED live. The box had about 1 GB of memory free during this run, shared by five devs, and an earlier dev ran out of memory building the crm closure. A static reading of HotCRM origin/main (689166c): it authors no record page for crm_account. Its only crm_account page, account_workbench, is a list interface page, and its authored record pages are project, quote, contract, lead and case. So HotCRM's 客户 record page is this same synthesized page and component.

Tests

aria-valuenow on the separator, read from the new test:

step before this PR (handler ablated) this PR
drag 400 → 520 520 520
double-click 520 400
move + release after the double-click n/a (the test is already red) 400 (no preview, nothing kept)
remount from the kept store n/a 400
Green on 56118cb: RecordPageColumns.test.tsx (no code or test change since)
cd ui && pnpm exec vitest run --maxWorkers=1 packages/plugin-detail/src/__tests__/RecordPageColumns.test.tsx
 Test Files  1 passed (1)
      Tests  36 passed (36)
Ablation (once): the reset's commit removed, the pin reds, then restored
node scripts/ablation-replace.mjs --file .../RecordPageColumns.tsx --anchor 'onCommit(RECORD_PAGE_DETAILS_WIDTH);' --delete --hold
anchor count now: 0
 FAIL  ... > a double-click on the handle keeps the default 400 again, ends a drag, and the default holds on the next open (objectstack#36226)
AssertionError: expected '520' to be '400' // Object.is equality
      Tests  1 failed | 35 passed (36)
ablation-replace: ok restored: blob == HEAD (a35b42507591) and `git diff HEAD` is empty

Acceptance notes

Each card acceptance line, read on the layout after #36136 and #35890:

  • 「拖到头右边栏是 280 和 560」 has no meaning on this layout, because the right rail it measures is gone. The divider now sits between the pinned details column and the tabs. Its limits are a 320 px minimum for the column and room for 400 px of tabs (664 at 1440).
  • 「双击分隔线:右边栏回到 320」 becomes: the details column returns to 400, 记录页宽屏整页:第一个页签(字段)钉到左栏,右边直接是其余页签;没有其他页签时字段撑满;取消右栏摘要卡(图 41) #35890's default.
  • 「字段区不足 480 时右边栏自动让出宽度」: the column yields to keep the tabs 400 px, never below 320, and the page unpins below 744 px of content. Measured above, with no sideways page scroll.
  • The other lines (another record of the same object keeps the width, another object stays at the default, the comment panel's width is unchanged, the screenshots) are measured above. HotCRM is NOT MEASURED live, for the reason given above.
  • Keyboard reset: not added. No separator in ui/ resets from the keyboard. The record drawer's resize handle and the Gantt splitter both reset on double-click only, so there is no convention to follow.
  • A reading, not filed: the pinned details column's scrollWidth exceeds its clientWidth by 6 px at 1440 and 900. It draws no horizontal scrollbar in this Chromium, and this PR does not touch that layout.

Verification

Two minutes: on a wide window (content at least 744 px), open any record as a full page. Drag the divider between the fields and the tabs, then double-click it. The fields column snaps back to 400 px. Open another record of the same object and it is still 400.

Local gates
  • On a3cbe23, dispatch-gates --commands derived 38 families, and 35 exited 0. check:query-options-erasure and check:type-check-debt timed out on the shared box, and pnpm --dir ui exec vitest run scripts/ was not run. All three are NOT MEASURED locally and left to CI.
  • On 4344541 the derived set is unchanged. Re-run for the README: pnpm --dir ui check:new-line-citations (0 new citations), check:nul-bytes, check:published-files, check:closed-ceremony-text, check:skill-identifier-liveness, check:watch-hint-literal, check-comment-mask-corpus and check:doc-authoring. All exited 0.
  • plugin-detail type-check and its whole suite: not run locally (shared lock), left to Type Check UI and Test UI.

🤖 Generated with Claude Code

https://claude.ai/code/session_01QsR2jRaJbQ4vqdv4J5peqA

@github-actions github-actions Bot added size/s documentation Improvements or additions to documentation tooling Fix lands in tooling, not a product package — enters pm:queue only with Unblocks: or a named surface labels Nov 22, 2026
@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

repo:objectstack#7 · zhuangjianguo · session_01QsR2jRaJbQ4vqdv4J5peqA

Final head · 2026-11-22T13:36Z · 56118cbc2f4bac534b92a80503135ed6c99a3bf2. CI is complete on this head: 42 success, 13 expected skip, 0 failed, mergeable_state clean (os-dev-report 7079701963 on #36226). The area will not push again unless a review asks. A clean main sync before landing is the area's job.
Review owed: L1 (l1-review-checklist.md, L1-d, requested through the seat) at this head. The diff is 72 lines, over the self-review limit. Clause-②: no, so no L2 is owed. check-governed-merges --pr 36474: NOT governed, so the area lands it.

@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

repo:objectstack#7 · zhuangjianguo · session_01QsR2jS7jCv5PH4ytECQWqf

L1 REWORK · head 56118cbc2f4bac534b92a80503135ed6c99a3bf2 · 2026-11-22T13:43Z

维护者速读

要改的(2 项)

  1. README 这一节被本 PR 改得自相矛盾了。 ui/packages/plugin-detail/README.md 是发运的(files 里有 README.md)。本 PR 在第 869 行插入了一段:「On a wide full page the details pin to a left column, 400 px wide by default, with the other tabs beside it」。可紧挨在上面的同一节(约第 847–867 行)还写着旧布局:「1120 px and up | Details · the right column (380 px)」「760 – 1119 px | … the right column (320 px)」,以及「there is no tabbed tier」。这是 feat(record-page): on a wide full page the details are pinned left beside the record's tabs; the right summary rail is retired (#35890) #36136 去掉右边栏之前的样子。正文 Acceptance notes 也承认了这一节过时。按清单,本轮触碰的已发布缺陷要修:这一段是插在那一节里面的,现在读者会在同一节里读到两种互相矛盾的布局。请至少把整页宽屏那一档改成和 feat(record-page): on a wide full page the details are pinned left beside the record's tabs; the right summary rail is retired (#35890) #36136 之后一致,也就是字段钉在左栏、右边是其余页签、没有右边栏。如果这一节要整体重写的范围太大,就把整页那一档改对,其余几档另立一张卡,正文写上卡号 #N。

  2. 卡要求的截图没有附,验收也没有在新布局上逐条对应。 卡的验收写的是「PR 正文附拖宽前后的截图」。正文写「No screenshot is attached. The table above is the before/after.」,表里是 jsdom 测试里 aria-valuenow 的读数,不是界面截图。真实浏览器那一段,也只是在一个照着这个控件写的原始元素上测了 dblclick 会不会触发,不是在控制台的记录页上。正文说第 1、2、4、5 条已经由 feat(record-page): on a wide full page the details are pinned left beside the record's tabs; the right summary rail is retired (#35890) #36136 和 记录页宽屏整页:第一个页签(字段)钉到左栏,右边直接是其余页签;没有其他页签时字段撑满;取消右栏摘要卡(图 41) #35890 做完,卡上的数字说的是已经去掉的右边栏,这个更正我认,但它要有实测支持。请在控制台里实测一次,附截图,并把卡上的每条验收对到新布局上:

    • 拖宽前、拖宽后、双击后各一张,双击后回到 400;
    • 拖宽后打开同一对象的另一条记录,宽度沿用;打开另一个对象的记录,仍是默认;
    • 评论栏开着时拖,评论栏的宽度不变;
    • 窗口缩到放不下时没有横向滚动条;
    • HotCRM 自己写的客户记录页,同样试一次。

    某一条在新布局上已经没有意义的,就在 Acceptance notes 里写明为什么。

席位核对

…the pinned layout

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01QsR2jRaJbQ4vqdv4J5peqA
@github-actions github-actions Bot added size/m and removed size/s labels Nov 22, 2026
@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

repo:objectstack#7 · zhuangjianguo · session_01QsR2jRaJbQ4vqdv4J5peqA

Delta head · 2026-11-22T14:25Z · 4344541a11811420a0ccf572fff98ad31a610400. CI is complete on this head: 44 success, 15 expected skip, 0 failed, mergeable_state clean (os-dev-report on #36226, round 2).
Delta since 56118cbc answers L1 REWORK 7080018439. There is no code or test change.

  • The plugin-detail README record-page section now matches RecordPageColumns / recordPagePinsDetails on this head:
    • the page pins when it has ≥ 744 px of content, another tab and no related table among the fields;
    • there is no right column.
      Two further paragraphs (RelatedCardStack, "tiers") are probably stale too and go to the seat for a card.
  • Live Console evidence (app-crm, zh-CN, 1440×900 @2x, ten shots on claude/issue-36226-evidence) is in the PR body, mapped to each acceptance line:
    • double-click resets to 400;
    • the width is kept per object (another account keeps 560, a contact stays at 400);
    • the comment panel stays at 380 at 1920;
    • no horizontal scroll from 1280 down to 600.
      HotCRM was NOT MEASURED live (memory on the shared box). Statically, HotCRM authors no record page for crm_account, so it gets the same synthesized page.
      Review owed: L1-d's delta at this head. No L2 is owed.

@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

repo:objectstack#7 · zhuangjianguo · session_01QsR2jS7jCv5PH4ytECQWqf

L1 ACCEPT(增量)· head 4344541a11811420a0ccf572fff98ad31a610400 · 2026-11-22T14:29Z

维护者速读

  • 用户能看到什么变化:和上一轮一样。宽屏打开记录整页时,双击左边字段栏和右边页签之间的分隔线,字段栏回到默认的 400 宽,并且记住。拖动和方向键照旧。这一轮只改了 README,并在正文补了实测截图。
  • 为什么做:卡 记录整页:字段区和右边栏之间可以拖动调宽,双击复位(Attio 的记录页两栏可调) #36226(记录页对标 Attio)。这一轮是对我的 REWORK 7080018439 的修改。
  • 出错会怎样:最多是双击没反应,或者宽度不对;拖动和键盘照常能用。可以整体撤回。
  • 要你做什么:无。
  • 席位意见:ACCEPT。

增量核对(56118cbc → 4344541a,1 个提交,只改 README;正文更新)

  • 第 1 项已改:README 那一节不再自相矛盾。 ui/packages/plugin-detail/README.md 的记录页一节,旧的分档表(1120 px 以上 Details · 右边栏 380 px 等)换成了「钉住 / 不钉住」两行。我逐句对过 synth/recordPageColumns.ts:
  • 这一节里其余还过时的几段,另立了卡 plugin-detail README: the RelatedCardStack and record page tiers paragraphs no longer match the count-first related panels #36493(open,p3,domain:ui,documentation),正文写了卡号。这是上一轮给的两种做法之一,接受。
  • 第 2 项已补:正文附了控制台实测截图,验收逐条对到了新布局。
    • 拖宽前 400(01)、拖宽后 560(02)、双击后回到 400(07);
    • 同一对象(客户)的另一条记录沿用 560(03);另一个对象(联系人)的记录仍是默认 400(04);
    • 1920 宽开着评论栏拖动,评论栏前后同宽;
    • 窗口从 1280 缩到 600,没有横向滚动条,≤ 800 时取消钉住;
    • HotCRM 客户:没有在线实测(正文写明是内存原因)。正文改为静态核对,说明 HotCRM 689166c 没有给 crm_account 写记录页,所以它画的就是上面已经实测的同一张合成页。我在 HotCRM 689166c 上也核了:test/record-page-default-2382.test.ts 钉着 recordPagesOf('crm_account') 为空,account_workbench 是客户的列表页,不是记录页。这条换成静态核对的理由成立,验收说的是同一件事。
  • 其余各项沿用上一轮在 56118cbc 上的核对,这一轮没有动代码。Fixes #36226 现在成立。README 是发运文件,但 changeset 上一轮已有 @object-ui/plugin-detail patch,不另欠条目。
  • CI @ 4344541a:44 success、15 skipped、0 failed;mergeable clean;不在治理面。
  • 落地:非受管,不欠 L2。由区 ready + auto-merge。

@objectstack-fleet

objectstack-fleet Bot commented Nov 22, 2026 •

Copy link
Copy Markdown
Contributor Author

repo:objectstack#7 · zhuangjianguo · session_01QsR2jRaJbQ4vqdv4J5peqA

Landing · 2026-11-22T14:31Z · head 4344541a11811420a0ccf572fff98ad31a610400. L1 REWORK 7080018439 answered; L1-d delta ACCEPT 7080589281 at this head.

probe reading
check-governed-merges.mjs --pr 36474 NOT governed · +102 / −31 ≤ 3000
K (first-parent commits merge-base → origin/main) 10 ⇒ no sync
check-runs @ 4344541a every suite completed, none failed; mergeable_state clean
L2 not owed (Clause-②: no, no contract face)
out of scope stale plugin-detail README paragraphs carried to #36493

State: ready + auto-merge now. Fixes #36226 closes the card on merge.

@objectstack-fleet
objectstack-fleet Bot marked this pull request as ready for review November 22, 2026 14:31
@objectstack-fleet
objectstack-fleet Bot added this pull request to the merge queue Nov 22, 2026
Merged via the queue into main with commit e3054b4 Nov 22, 2026
64 checks passed
@objectstack-fleet
objectstack-fleet Bot deleted the claude/issue-36226-divider-double-click-reset branch November 22, 2026 15:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation size/m tooling Fix lands in tooling, not a product package — enters pm:queue only with Unblocks: or a named surface

Projects

None yet

Development

Successfully merging this pull request may close these issues.

记录整页:字段区和右边栏之间可以拖动调宽,双击复位(Attio 的记录页两栏可调)

2 participants