Skip to content

fix(tui): give every table one shared column scale - #2217

Draft
notgitika wants to merge 1 commit into
aws:refactorfrom
notgitika:chore/tui-table-column-scale
Draft

fix(tui): give every table one shared column scale#2217
notgitika wants to merge 1 commit into
aws:refactorfrom
notgitika:chore/tui-table-column-scale

Conversation

@notgitika

@notgitika notgitika commented Sep 4, 2026

Copy link
Copy Markdown
Contributor

Gives every TUI table one shared column scale.

  • cap the flexible column at 40 cells so leftover width becomes right margin instead of a gap between an identifier and its metadata
  • one width per kind of value (timestamp 16, status 20, version 7, count 8) in columnPresets.ts
  • right-align numerics, center the narrow live/target flags
  • drop the Runtime id suffix column; the ID already contains the name

Tables sized their own columns, so `status` was anywhere between 12 and
22 cells wide depending on the screen, and the flexible column absorbed
all leftover terminal width — on a wide terminal that left a canyon of
blank space between an identifier and its own metadata.

- cap the flexible column at 40 cells; the leftover is right margin
- share one width per kind of value (timestamp, status, version, count)
- right-align numerics, center the narrow live/target flags, leave text
  and timestamps on the left edge
- drop the Runtime `ID suffix` column: the control plane derives a
  Runtime's ID from its name, so the ID column already carries both

# Conflicts:
#	src/components/MemoryPicker.tsx
#	src/components/PaginatedTablePicker.test.tsx
#	src/components/RuntimePicker.tsx
#	src/handlers/runtime/runtime.screen.test.tsx
@github-actions github-actions Bot added the size/m PR size: M label Sep 4, 2026
@agentcore-devx-automation agentcore-devx-automation Bot added agentcore-harness-reviewing AgentCore Harness review in progress claude-security-reviewing Claude Code /security-review in progress labels Sep 4, 2026
@notgitika
notgitika marked this pull request as draft September 4, 2026 05:20
@agentcore-devx-automation

Copy link
Copy Markdown
Contributor

Claude Security Review: no high-confidence findings. (run)

@agentcore-devx-automation agentcore-devx-automation Bot removed the claude-security-reviewing Claude Code /security-review in progress label Sep 4, 2026
@github-actions github-actions Bot added size/m PR size: M and removed size/m PR size: M labels Sep 4, 2026
@agentcore-devx-automation agentcore-devx-automation Bot removed the agentcore-harness-reviewing AgentCore Harness review in progress label Sep 4, 2026

@agentcore-devx-automation agentcore-devx-automation Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

AgentCore Harness Review

Verdict: Looks good

This is a nicely scoped UI refactor:

  • The new columnPresets.ts (STATUS_WIDTH, TIMESTAMP_WIDTH, VERSION_WIDTH, COUNT_WIDTH, NUMERIC_ALIGN, FLAG_ALIGN) is applied consistently across every picker, and the previously drifting status widths (12–22) are unified.
  • FLEX_MAX_WIDTH = 40 and the per-column maxWidth override are threaded correctly through computeColumnWidths, and DataTable truncates via cli-truncate, so the cap won't cause overflow. The updated columnWidths.test.ts covers the new ceiling and the leftover-as-right-margin behavior, and the PaginatedTablePicker.test.tsx change to allow totalWidth <= terminalWidth correctly reflects the new invariant.
  • Collapsing runtime name + id suffix into a single id column is reasonable given that agentRuntimeId embeds the name (orders-Ab12Cd34Ef); the /-filter still matches by name substring, and screen tests were updated in lockstep. Test fixtures now use realistic ID shapes.
  • No new user-facing features/telemetry surface here, and tests continue to render real components with a TestCoreClient rather than adding mocks.

Nothing blocking — LGTM.

@codecov-commenter

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 97.05%. Comparing base (da28031) to head (152e3e9).

Additional details and impacted files
@@            Coverage Diff            @@
##           refactor    #2217   +/-   ##
=========================================
  Coverage     97.04%   97.05%           
=========================================
  Files           544      545    +1     
  Lines         37536    37562   +26     
=========================================
+ Hits          36428    36454   +26     
  Misses         1108     1108           

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size/m PR size: M

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants