Commit ba73f1b
[terminal] Add TerminalTable class; [rush-lib] remove cli-table dependency (#5785)
* [terminal] Add TerminalTable; [rush-lib] replace cli-table dependency
Add TerminalTable to @rushstack/terminal as a drop-in replacement for
the cli-table and cli-table3 npm packages. Handles ANSI escape sequences
when calculating column widths, and matches the chars/head/colWidths
constructor API used by both packages.
Replace cli-table usage in rush-lib (ListAction, InteractiveUpgradeUI)
with TerminalTable, and remove the cli-table dependency.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
* Add changefiles for terminal-table PR
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
* fixup! Add changefiles for terminal-table PR
* Rush update.
* fixup! [terminal] Add TerminalTable; [rush-lib] replace cli-table dependency
* Add a borderless option.
* [terminal] Redesign TerminalTable API: camelCase border names, borderless option, getLines()
- Rename all ITerminalTableChars members from kebab-case to camelCase
- Rename `chars` option to `borderCharacters`
- Add `borderless: true` shorthand (replaces verbose empty-string chars override)
- Add `getLines(): string[]` method
- Add JSDoc to ITerminalTableChars members with visual reference diagram
- Update tests and snapshots
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
* fixup! [terminal] Redesign TerminalTable API: camelCase border names, borderless option, getLines()
* fixup! Add changefiles for terminal-table PR
---------
Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>1 parent ea11482 commit ba73f1b
File tree
15 files changed
+503
-79
lines changed- common
- changes
- @microsoft/rush
- @rushstack/terminal
- config
- rush
- subspaces
- build-tests-subspace
- default
- reviews/api
- libraries
- rush-lib
- src
- cli/actions
- utilities
- terminal/src
- test
- __snapshots__
15 files changed
+503
-79
lines changedLines changed: 10 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
Lines changed: 10 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
614 | 614 | | |
615 | 615 | | |
616 | 616 | | |
617 | | - | |
618 | | - | |
619 | | - | |
620 | | - | |
621 | 617 | | |
622 | 618 | | |
623 | 619 | | |
| |||
Lines changed: 5 additions & 20 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Lines changed: 2 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | | - | |
| 3 | + | |
4 | 4 | | |
5 | | - | |
| 5 | + | |
6 | 6 | | |
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | | - | |
| 3 | + | |
4 | 4 | | |
5 | 5 | | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
246 | 246 | | |
247 | 247 | | |
248 | 248 | | |
| 249 | + | |
| 250 | + | |
| 251 | + | |
| 252 | + | |
| 253 | + | |
| 254 | + | |
| 255 | + | |
| 256 | + | |
| 257 | + | |
| 258 | + | |
| 259 | + | |
| 260 | + | |
| 261 | + | |
| 262 | + | |
| 263 | + | |
| 264 | + | |
| 265 | + | |
| 266 | + | |
| 267 | + | |
| 268 | + | |
| 269 | + | |
| 270 | + | |
| 271 | + | |
| 272 | + | |
| 273 | + | |
| 274 | + | |
| 275 | + | |
249 | 276 | | |
250 | 277 | | |
251 | 278 | | |
| |||
459 | 486 | | |
460 | 487 | | |
461 | 488 | | |
| 489 | + | |
| 490 | + | |
| 491 | + | |
| 492 | + | |
| 493 | + | |
| 494 | + | |
| 495 | + | |
| 496 | + | |
| 497 | + | |
462 | 498 | | |
463 | 499 | | |
464 | 500 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
58 | 58 | | |
59 | 59 | | |
60 | 60 | | |
61 | | - | |
62 | 61 | | |
63 | 62 | | |
64 | 63 | | |
| |||
91 | 90 | | |
92 | 91 | | |
93 | 92 | | |
94 | | - | |
95 | 93 | | |
96 | 94 | | |
97 | 95 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2 | 2 | | |
3 | 3 | | |
4 | 4 | | |
5 | | - | |
| 5 | + | |
6 | 6 | | |
7 | 7 | | |
8 | 8 | | |
| |||
220 | 220 | | |
221 | 221 | | |
222 | 222 | | |
223 | | - | |
224 | | - | |
| 223 | + | |
225 | 224 | | |
226 | 225 | | |
227 | 226 | | |
| |||
0 commit comments