-
Notifications
You must be signed in to change notification settings - Fork 21
Open
Labels
questionFurther information is requestedFurther information is requested
Description
issue trying to render a table in logs
issues when trying to log a table formatted with cli-table3 library. seems no not being taking advantage of full terminal width and its proportional of terminal width.
Code
import CliTable3 from "cli-table3"
import { ConsoleManager } from "console-gui-tools"
const GUI = new ConsoleManager({
title: '🎢 Adventure World Management System ',
logPageSize: 10,
enableMouse: true,
overrideConsole: true,
showLogKey: "ctrl+l",
layoutOptions: {
showTitle: true,
changeFocusKey: 'tab',
type: 'double',
boxed: true,
fitHeight: true,
pageRatio: [10,16]
}
});
const table = new CliTable3({
head: ['ID','Name','Type','Capacity','Current','Price','Revenue' ],
colWidths: [ 8, 20, 15, 8, 8, 10, 12 ]
});
table.push([ 1, "prueba", "roller coaster", "50", "0", `$15`, `$10000` ]);
const tableString = table.toString();
const tableLines = tableString.split('\n');
tableLines.forEach((line, index) => {
GUI.info(line)
});Library Version
3.7.0
Node Version
22
What operating system are you using?
Windows
Terminal
powershell
Metadata
Metadata
Assignees
Labels
questionFurther information is requestedFurther information is requested
