Skip to content

feat(table): add web-style full cell grid for prettified tables - #259

Open
jinwei233 wants to merge 2 commits into
dnouri:masterfrom
jinwei233:feat/table-full-grid
Open

feat(table): add web-style full cell grid for prettified tables#259
jinwei233 wants to merge 2 commits into
dnouri:masterfrom
jinwei233:feat/table-full-grid

Conversation

@jinwei233

@jinwei233 jinwei233 commented Aug 8, 2026

Copy link
Copy Markdown

What

Adds pi-coding-agent-table-full-grid (default on) so prettified tables render a top border, an inter-row rule, and a bottom border using Unicode box-drawing characters — every cell is fully enclosed like an HTML table.

Before:

 Name  │ Value
───────┼───────
 Alpha │ Beta
 Gamma │ Delta
image

After:

┌───────┬───────┐
│ Name  │ Value │
├───────┼───────┤
│ Alpha │ Beta  │
├───────┼───────┤
│ Gamma │ Delta │
└───────┴───────┘
Snipaste_2026-08-08_22-36-28

How

Border rules are woven into the existing per-raw-line display groups, so the group↔raw-line 1:1 invariant that pi-coding-agent--decorate-table relies on is preserved and overlay orchestration is untouched. Column widths are reused, so junctions align with the cell verticals, including zero-width columns. The option has no effect when pi-coding-agent-prettify-tables is disabled.

Testing

  • New regression tests for grid-rule widths, full-grid enclosure, and the grid-off path.
  • Full table suite (73 tests) passes.
  • Byte-compiles clean with byte-compile-error-on-warn.

jinwei added 2 commits August 8, 2026 17:19
Introduce `pi-coding-agent-table-full-grid' (default on) so prettified
tables render a top border, an inter-row rule, and a bottom border with
Unicode box-drawing characters, enclosing every cell like an HTML table.

Border rules are woven into the existing per-raw-line display groups, so
the group<->raw-line 1:1 invariant that `pi-coding-agent--decorate-table'
relies on is preserved and overlay orchestration is untouched. Column
widths are reused, so junctions align with the cell verticals, including
zero-width columns. The option has no effect when prettify is disabled.
@jinwei233
jinwei233 force-pushed the feat/table-full-grid branch from 093907b to 0e3944c Compare August 9, 2026 02:21
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