diff --git a/types/blessed/blessed-tests.ts b/types/blessed/blessed-tests.ts index aa38af8985..00df6dbc7a 100644 --- a/types/blessed/blessed-tests.ts +++ b/types/blessed/blessed-tests.ts @@ -6,6 +6,24 @@ let screen: blessed.Widgets.Screen = null; // https://github.com/chjj/blessed/blob/master/test/widget-autopad.js +screen = blessed.screen({ + log: __dirname + "/logs/just-logs.log" +}); + +screen = blessed.screen({ + log: __dirname + "/logs/just-logs.log", + dump: false +}); + +screen = blessed.screen({ + dump: __dirname + "/logs/logs-and-all-in-and-output.log" +}); + +screen = blessed.screen({ + log: __dirname + "/logs/logs-and-all-in-and-output.log", + dump: true +}); + screen = blessed.screen({ dump: __dirname + "/logs/autopad.log", smartCSR: true, diff --git a/types/blessed/index.d.ts b/types/blessed/index.d.ts index 7dae1709d2..53dbf48706 100644 --- a/types/blessed/index.d.ts +++ b/types/blessed/index.d.ts @@ -1,6 +1,8 @@ // Type definitions for blessed 0.1 // Project: https://github.com/chjj/blessed -// Definitions by: Bryn Austin Bellomy , Steve Kellock +// Definitions by: Bryn Austin Bellomy +// Steve Kellock +// Max Brauer // Definitions: https://github.com/borisyankov/DefinitelyTyped // TypeScript Version: 2.1 @@ -925,12 +927,12 @@ export namespace Widgets { /** * Create a log file. See log method. */ - log?(...msg: any[]): void; + log?: string; /** * Dump all output and input to desired file. Can be used together with log option if set as a boolean. */ - dump?: string; + dump?: string | boolean; /** * Debug mode. Enables usage of the debug method. Also creates a debug console which will display when