style(cli): apply prettier formatting

Pre-commit hook ran prettier on the prior commit but left the reformats
unstaged. Folding them in here so the branch is clean.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
gavrielc
2026-04-29 18:03:47 +03:00
parent 3a3d2ee644
commit 594d1b4055
5 changed files with 8 additions and 30 deletions

View File

@@ -41,11 +41,8 @@ function isFlatRecord(x: unknown): x is Record<string, unknown> {
function renderTable(rows: Record<string, unknown>[]): string {
if (rows.length === 0) return '(no rows)';
const cols = Object.keys(rows[0]);
const widths = cols.map((c) =>
Math.max(c.length, ...rows.map((r) => String(r[c] ?? '').length)),
);
const fmtRow = (vals: string[]): string =>
vals.map((v, i) => v.padEnd(widths[i])).join(' ');
const widths = cols.map((c) => Math.max(c.length, ...rows.map((r) => String(r[c] ?? '').length)));
const fmtRow = (vals: string[]): string => vals.map((v, i) => v.padEnd(widths[i])).join(' ');
const lines = [
fmtRow(cols),
fmtRow(widths.map((w) => '─'.repeat(w))),