Skip to content

fix(table): 操作列文字左对齐(整体方案) + 排序/筛选图标间距收紧#2167

Draft
Fiona2016 wants to merge 7 commits into
mainfrom
feat-table-fix-0708
Draft

fix(table): 操作列文字左对齐(整体方案) + 排序/筛选图标间距收紧#2167
Fiona2016 wants to merge 7 commits into
mainfrom
feat-table-fix-0708

Conversation

@Fiona2016

@Fiona2016 Fiona2016 commented Jul 8, 2026

Copy link
Copy Markdown
Collaborator

Unified branch feat-table-fix-0708 (shared across the three repos). Two common
styling issues surfaced during the srm-fe table review; since the integration build takes
EnhancedTable/theme from this repo, they are fixed here.

  • Left-align action-column inline button text (overall solution): EnhancedTable detects
    the action column and injects .fc-table-op-column + align: 'left'; style.less removes
    the left padding of the first inline link/text button (class-led selector).
  • Tighten spacing when sort + filter icons share a column: theme/table.less
    .ant-table-filter-trigger margin-left 6px -> 2px.

Additional changes (global — please note)

  • usePagination: enable showQuickJumper globally (affects all ~61 tables using this hook).
  • datasource TableSource: the delete action is now always shown but disabled with a tooltip
    when the datasource is enabled (previously hidden), for UX consistency.

Known follow-up

  • Op-column detection currently also matches the literal title '操作', so the alignment
    applies reliably only in the zh locale; a locale-independent signal is preferable.

Verification: 9111 build SUCCESS; filter-trigger margin = 2px; .fc-table-op-column present.

🤖 Generated with Claude Code

srm-fe 走查共性问题移植到 n9e/fe(集成构建的 EnhancedTable/theme 以 fe 为准):
- EnhancedTable 检测操作列(dataIndex='operate' 或标题「操作」)→注入 .fc-table-op-column+align:left;
  style.less .fc-table-op-column 去掉首个内联 link/text 按钮左内边距(class-led)。
- theme/table.less 排序+筛选同列漏斗 margin-left 6px→2px,图标不再离太远/窄列放不下。
对应 srm-fe PR #1033 的同类改动(srm-fe 侧因 integrate.js 不覆盖 fe 的共享组件/主题而不生效)。
@coderabbitai

coderabbitai Bot commented Jul 8, 2026

Copy link
Copy Markdown

Important

Review skipped

Draft detected.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: f7b9a864-f98f-44b4-a953-f282779bd375

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feat-table-fix-0708

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

Fiona2016 and others added 6 commits July 8, 2026 04:48
Add showQuickJumper:true to the shared usePagination hook so every table
that spreads its return value gets the 跳转至第 X 页 input, consistently.
Server-side paginated tables reuse the same onChange callback (verified
all hook-consuming server-side tables pass total), so no behavior change
beyond the added jump input.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
…zh title

EnhancedTable tagged hand-written action columns via col.title === '操作',
matching only the Chinese literal — under any other locale the op-column
left-align silently stopped working. Detect via col.key === 'operate' (or
dataIndex) instead. This is the fe copy that ships in the integration build;
all fe op columns already use rowActions or dataIndex='operate', so nothing
regresses. Mirrors the srm-fe change.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Cap the EllipsisText tooltip at maxHeight 400 with overflow auto so very long
cell text scrolls inside the tooltip instead of overflowing the viewport. This
is the fe copy that ships in the integration build; mirrors the srm-fe change.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant