Skip to content

fix(components): data-table row actions trigger visible at rest in a muted tone - #29030

Merged
objectstack-fleet[bot] merged 1 commit into
mainfrom
claude/project-thread-n792y2
Nov 2, 2026
Merged

objectstack-fleet[bot] merged 1 commit into
mainfrom
claude/project-thread-n792y2

Conversation

@objectstack-fleet

Copy link
Copy Markdown
Contributor

Requested by Steedos · project thread

Fixes #28923

Clause-②: no
Metadata-protocol: none

维护者速读

  • 改了什么:通用 data-table 渲染器里每行的 ⋯ 操作按钮,静止时也画出来(灰色弱化色),鼠标移到该行、行内获得焦点、行被选中、按钮自己获得键盘焦点、菜单打开时,或在触屏上,变为正常前景色。与列表表格(List grid Actions column: a visible low-emphasis ⋯ on every row at rest, instead of a header over a column that looks empty until the pointer hovers a row #28871)的做法一致。菜单里有哪些项、各项的显示条件和顺序都不变。Console 列表名称旁的「整页打开」↗ 仍保持悬停才出现,只把它说「与行菜单一致」的注释改正。
  • 为什么改:表头「操作」一直在,但桌面端按钮在鼠标移上行之前是透明的,整列看起来是空的,读者会以为「没有可用操作」。
  • 风险与回滚:只改 ui/packages/components 一个按钮的样式类,另有一处 app-shell 注释;不动 spec、服务端、元数据和菜单逻辑。弱化色用文字色(text-muted-foreground),不是透明度。回滚 = revert 本 PR。
  • 先看:ui/packages/components/src/renderers/complex/data-table.tsx 里 data-testid="data-table-row-actions" 那个按钮的 className;再看新测试 data-table-row-actions-atRest-28923.test.tsx。
  • 两分钟验证:cd ui && pnpm exec vitest run packages/components/src/renderers/complex/__tests__/data-table-row-actions-atRest-28923.test.tsx,应 1 个文件 4 个用例全部通过;或打开任一相关列表(1440 px),不移动鼠标就能看到每行的 ⋯。
  • 需要你做的:无,席位落地。

What changes

data-table's row ⋯ trigger (data-testid="data-table-row-actions", drawn per row when the schema's rowActions leave at least one item):

objectViewOpenAsPage.tsx (the Console list's per-row ↗ "open as page"): triage's call, kept hover-revealed. It is an extra link beside the name with no header of its own, so the empty-column defect does not apply, and drawing it on every row would crowd the name column. Only its docblock changes: it no longer claims to match the row menu, and says why the two differ. OPEN_AS_PAGE_CLASS is unchanged.

Unchanged: the menu's items, gates and order (useDataTableRowMenuPlan, #28434), the empty-menu guard, the header, the accessible name. No key, option or prop is added. Changeset: @object-ui/components patch (app-shell's change is a comment only, not published).

Tests

  • data-table-row-actions-atRest-28923.test.tsx (new, 4 cases): at rest no opacity-0 under any variant, invisible, hidden or sr-only, name kept; rests in text-muted-foreground with the five full-strength variants; the only pointer-coarse: class is pointer-coarse:text-foreground; control: opening the menu flips data-state to open and shows Edit.
  • data-table-leadingCell-12423.test.tsx: its row-actions-trigger case pinned the old opacity-0 set and is repointed to the new one. Its checkbox cases are untouched.
Ablation (scripts/ablation-replace.mjs, at 920a4d8, source-resolved, no dist)
  • opacity-0 put back at rest (text-muted-foreground transition-colors to text-muted-foreground opacity-0 transition-colors): 1 failed ("is drawn at rest on every row"), 3 passed. Restored, blob 1d306e61 equal to HEAD, git diff HEAD empty.
  • Coarse-pointer leg put back to an opacity reveal (pointer-coarse:text-foreground to pointer-coarse:opacity-100): 1 failed (the every-pointer-type case), 3 passed. Restored, blob 1d306e61 equal to HEAD, git diff HEAD empty.

Acceptance notes

  • None beyond the open-as-page choice above.

Verification

All on the final head 920a4d85 (base origin/main 62b3ec36), after pnpm install --frozen-lockfile and turbo run build --filter='@object-ui/components^...' plus formula, sdui-parser, lint and client (43 tasks, exit 0), under scripts/pm/os-verify-lock.sh.

  • The whole packages/components/ vitest suite (--maxWorkers=2): 470 files passed, 1 skipped; 4481 tests passed, 24 skipped. The three data-table row-menu files plus ObjectView.recordOpenDisplay-26681.test.tsx (app-shell, the open-as-page link): 22 passed.
  • pnpm --filter @object-ui/components run type-check (both tsc programs, the test one included): exit 0.
  • ESLint on the four changed tsx files: exit 0, 0 errors. 53 warnings: 51 on untouched lines of data-table.tsx, one on the 12423 file's existing ComponentRegistry.get(...) as any, and one on the same cast in the new test, copied from it.
  • Derived gates (node scripts/pm/dispatch-gates.mjs --commands): 34 of 34 run, each exit 0 (check:type-check-debt and pnpm --dir ui exec vitest run scripts/ under the lock), including node scripts/check-sdui-manifest.mjs and the PR-body gates with this body as GITHUB_EVENT_PATH. --ran reconciles 34 derived, 34 run, 0 NOT-MEASURED. check-partof-closing-keyword with PR_BODY: exit 0.
  • Not run locally: app-shell type-check (the app-shell change is a docblock only) and the rest of app-shell's suite; CI's Type Check UI and Test UI run them.

🤖 Generated with Claude Code

https://claude.ai/code/session_01QsR2jSXEKkhP494Y6s2au2

…muted tone

The data-table's row ⋯ trigger rests in text-muted-foreground instead of
opacity-0, and lifts to full strength on row hover, focus-within, a selected
row, an open menu, its own focus and a coarse pointer, as the list grid's
RowActionMenu does. The open-as-page link keeps its hover reveal; its
docblock no longer claims it matches the row menu.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01QsR2jSXEKkhP494Y6s2au2
@github-actions github-actions Bot added size/m 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 2, 2026
@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

domain:ui#1 · zhuangjianguo · session_01QsR2jUJ19MstFvFhjgiYTu

席位核对 · ACCEPT · 2026-11-02T06:35Z

Head-sha: 920a4d85665ac28aa6415aff52368ad76b67aa5f

  • Shape:
    • The PR is a draft against main. The first card line is Fixes #28923, and no other card sits beside a closing keyword.
    • 5 files, +147 / −16, inside the claimed surface (6569701064). No governed path: check-governed-merges --pr 29030 reports NOT governed.
    • Clause-②: no and Metadata-protocol: none start their lines in the body and the changeset, as claimed. The changeset is patch for @object-ui/components.
  • Read in the diff:
  • Gates (check-runs on this head): 44 success, 11 skipped, 0 failed or pending. mergeable_state is clean.
  • Tests (dev): new atRest-28923 (4 tests); components in full, 470 files and 4481 tests. Ablation: both legs 1 red, 3 green, restored blob equal to HEAD. Derived gates 34 of 34.
  • NOT MEASURED: the seat ran no live session.
  • Landing: ordinary queue landing, pr_ready then automerge_enable. Fixes #28923 closes the card on merge.

@objectstack-fleet
objectstack-fleet Bot marked this pull request as ready for review November 2, 2026 06:36
@objectstack-fleet
objectstack-fleet Bot enabled auto-merge November 2, 2026 06:36
@objectstack-fleet
objectstack-fleet Bot added this pull request to the merge queue Nov 2, 2026
Merged via the queue into main with commit 636432c Nov 2, 2026
56 checks passed
@objectstack-fleet
objectstack-fleet Bot deleted the claude/project-thread-n792y2 branch November 2, 2026 07:19
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.

components data-table: the row ⋯ actions trigger is still hidden at rest on a fine pointer, as the list grid's was before #28871

1 participant