zard-cli 1.1.0-alpha.0 → 1.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +122 -60
- package/commands/add/component-installer.d.ts +2 -1
- package/commands/add/component-installer.d.ts.map +1 -1
- package/commands/add/component-installer.js +25 -7
- package/commands/add/component-installer.js.map +1 -1
- package/commands/add/component-selector.d.ts +3 -3
- package/commands/add/component-selector.js +4 -4
- package/commands/add/dark-mode-setup.d.ts +2 -0
- package/commands/add/dark-mode-setup.d.ts.map +1 -1
- package/commands/add/dark-mode-setup.js +15 -1
- package/commands/add/dark-mode-setup.js.map +1 -1
- package/commands/add/dependency-resolver.d.ts +8 -1
- package/commands/add/dependency-resolver.d.ts.map +1 -1
- package/commands/add/dependency-resolver.js +87 -16
- package/commands/add/dependency-resolver.js.map +1 -1
- package/commands/add/index.d.ts.map +1 -1
- package/commands/add/index.js +55 -29
- package/commands/add/index.js.map +1 -1
- package/commands/add/stylesheet-setup.d.ts +3 -0
- package/commands/add/stylesheet-setup.d.ts.map +1 -0
- package/commands/add/stylesheet-setup.js +92 -0
- package/commands/add/stylesheet-setup.js.map +1 -0
- package/commands/add/wizard.d.ts +12 -8
- package/commands/add/wizard.d.ts.map +1 -1
- package/commands/add/wizard.js +12 -2
- package/commands/add/wizard.js.map +1 -1
- package/commands/init/config-prompter.d.ts +36 -16
- package/commands/init/config-prompter.d.ts.map +1 -1
- package/commands/init/config-prompter.js +37 -17
- package/commands/init/config-prompter.js.map +1 -1
- package/commands/init/dependencies.d.ts.map +1 -1
- package/commands/init/dependencies.js +35 -23
- package/commands/init/dependencies.js.map +1 -1
- package/commands/init/index.d.ts.map +1 -1
- package/commands/init/index.js +74 -23
- package/commands/init/index.js.map +1 -1
- package/commands/init/library-peers.d.ts +28 -0
- package/commands/init/library-peers.d.ts.map +1 -0
- package/commands/init/library-peers.js +61 -0
- package/commands/init/library-peers.js.map +1 -0
- package/commands/init/project-kind.d.ts +39 -39
- package/commands/init/project-kind.d.ts.map +1 -1
- package/commands/init/project-kind.js +45 -45
- package/commands/init/project-kind.js.map +1 -1
- package/commands/init/rtl-setup.d.ts +12 -0
- package/commands/init/rtl-setup.d.ts.map +1 -0
- package/commands/init/rtl-setup.js +42 -0
- package/commands/init/rtl-setup.js.map +1 -0
- package/commands/init/steps.d.ts +3 -4
- package/commands/init/steps.d.ts.map +1 -1
- package/commands/init/steps.js +100 -39
- package/commands/init/steps.js.map +1 -1
- package/commands/init/tailwind-setup.d.ts +5 -5
- package/commands/init/tailwind-setup.d.ts.map +1 -1
- package/commands/init/tailwind-setup.js +29 -15
- package/commands/init/tailwind-setup.js.map +1 -1
- package/commands/init/tsconfig-updater.d.ts +4 -4
- package/commands/init/tsconfig-updater.js +12 -12
- package/commands/init/tsconfig-updater.js.map +1 -1
- package/commands/init/update-angular-config.js +4 -4
- package/commands/init/vite-setup.d.ts +5 -4
- package/commands/init/vite-setup.d.ts.map +1 -1
- package/commands/init/vite-setup.js +11 -10
- package/commands/init/vite-setup.js.map +1 -1
- package/commands/init/wizard.d.ts +10 -7
- package/commands/init/wizard.d.ts.map +1 -1
- package/commands/init/wizard.js +73 -46
- package/commands/init/wizard.js.map +1 -1
- package/constants/app.constants.d.ts +17 -0
- package/constants/app.constants.d.ts.map +1 -1
- package/constants/app.constants.js +39 -16
- package/constants/app.constants.js.map +1 -1
- package/core/icons/families.d.ts +38 -0
- package/core/icons/families.d.ts.map +1 -0
- package/core/icons/families.js +26 -0
- package/core/icons/families.js.map +1 -0
- package/core/icons/icon-map.d.ts +24 -0
- package/core/icons/icon-map.d.ts.map +1 -0
- package/core/icons/icon-map.js +150 -0
- package/core/icons/icon-map.js.map +1 -0
- package/core/icons/index.d.ts +107 -0
- package/core/icons/index.d.ts.map +1 -0
- package/core/icons/index.js +183 -0
- package/core/icons/index.js.map +1 -0
- package/core/registry/registry-data.d.ts.map +1 -1
- package/core/registry/registry-data.js +545 -63
- package/core/registry/registry-data.js.map +1 -1
- package/core/themes/index.d.ts +1 -1
- package/core/themes/index.js +1 -1
- package/core/themes/theme-definitions.d.ts.map +1 -1
- package/core/themes/theme-definitions.js +61 -72
- package/core/themes/theme-definitions.js.map +1 -1
- package/index.js +3 -2
- package/index.js.map +1 -1
- package/package.json +56 -58
- package/ui/blocks.d.ts +29 -28
- package/ui/blocks.d.ts.map +1 -1
- package/ui/blocks.js +27 -27
- package/ui/blocks.js.map +1 -1
- package/ui/brand.d.ts +5 -5
- package/ui/brand.d.ts.map +1 -1
- package/ui/brand.js +6 -6
- package/ui/brand.js.map +1 -1
- package/ui/engine/animation/index.d.ts +2 -3
- package/ui/engine/animation/index.d.ts.map +1 -1
- package/ui/engine/animation/index.js +2 -3
- package/ui/engine/animation/index.js.map +1 -1
- package/ui/engine/ansi/index.d.ts +10 -11
- package/ui/engine/ansi/index.d.ts.map +1 -1
- package/ui/engine/ansi/index.js +6 -7
- package/ui/engine/ansi/index.js.map +1 -1
- package/ui/engine/components/index.d.ts +3 -3
- package/ui/engine/components/index.js +4 -4
- package/ui/engine/cursor/index.d.ts +3 -4
- package/ui/engine/cursor/index.d.ts.map +1 -1
- package/ui/engine/cursor/index.js +2 -3
- package/ui/engine/cursor/index.js.map +1 -1
- package/ui/engine/diff/index.d.ts +2 -3
- package/ui/engine/diff/index.d.ts.map +1 -1
- package/ui/engine/diff/index.js +5 -6
- package/ui/engine/diff/index.js.map +1 -1
- package/ui/engine/events/index.d.ts +2 -2
- package/ui/engine/events/index.js +3 -3
- package/ui/engine/events/index.js.map +1 -1
- package/ui/engine/focus/index.d.ts +2 -2
- package/ui/engine/focus/index.js +2 -2
- package/ui/engine/frame/index.d.ts +4 -4
- package/ui/engine/frame/index.js +0 -0
- package/ui/engine/index.d.ts +7 -7
- package/ui/engine/index.js +7 -7
- package/ui/engine/input/index.d.ts +2 -2
- package/ui/engine/input/index.js +11 -11
- package/ui/engine/input/index.js.map +1 -1
- package/ui/engine/layout/index.d.ts +3 -3
- package/ui/engine/layout/index.js +7 -7
- package/ui/engine/layout/index.js.map +1 -1
- package/ui/engine/renderer/index.d.ts +4 -4
- package/ui/engine/renderer/index.d.ts.map +1 -1
- package/ui/engine/renderer/index.js +3 -3
- package/ui/engine/scheduler/index.d.ts +3 -3
- package/ui/engine/scheduler/index.js +5 -5
- package/ui/engine/scheduler/index.js.map +1 -1
- package/ui/engine/screen/index.d.ts +5 -5
- package/ui/engine/screen/index.d.ts.map +1 -1
- package/ui/engine/screen/index.js +7 -7
- package/ui/engine/screen/index.js.map +1 -1
- package/ui/engine/terminal/index.d.ts +49 -3
- package/ui/engine/terminal/index.d.ts.map +1 -1
- package/ui/engine/terminal/index.js +149 -18
- package/ui/engine/terminal/index.js.map +1 -1
- package/ui/engine/testing/index.d.ts +4 -4
- package/ui/engine/testing/index.d.ts.map +1 -1
- package/ui/engine/testing/index.js +2 -2
- package/ui/engine/theme/index.d.ts +2 -3
- package/ui/engine/theme/index.d.ts.map +1 -1
- package/ui/engine/theme/index.js +3 -4
- package/ui/engine/theme/index.js.map +1 -1
- package/ui/engine/utils/index.d.ts +2 -2
- package/ui/engine/utils/index.js +4 -4
- package/ui/engine/utils/index.js.map +1 -1
- package/ui/gate.d.ts +7 -7
- package/ui/gate.d.ts.map +1 -1
- package/ui/gate.js +5 -5
- package/ui/index.d.ts +3 -3
- package/ui/index.js +3 -3
- package/ui/log-sink.d.ts +9 -9
- package/ui/log-sink.d.ts.map +1 -1
- package/ui/log-sink.js +9 -9
- package/ui/log-sink.js.map +1 -1
- package/ui/output.d.ts +6 -6
- package/ui/output.d.ts.map +1 -1
- package/ui/output.js +6 -6
- package/ui/output.js.map +1 -1
- package/ui/report.d.ts +8 -8
- package/ui/report.d.ts.map +1 -1
- package/ui/report.js +7 -7
- package/ui/report.js.map +1 -1
- package/ui/runner.d.ts +31 -22
- package/ui/runner.d.ts.map +1 -1
- package/ui/runner.js +41 -25
- package/ui/runner.js.map +1 -1
- package/ui/style.d.ts +7 -7
- package/ui/style.d.ts.map +1 -1
- package/ui/style.js +8 -8
- package/ui/style.js.map +1 -1
- package/ui/testing/fake-tty.d.ts +4 -4
- package/ui/testing/fake-tty.js +4 -4
- package/ui/text-input.d.ts +15 -14
- package/ui/text-input.d.ts.map +1 -1
- package/ui/text-input.js +15 -13
- package/ui/text-input.js.map +1 -1
- package/ui/theme.d.ts +4 -4
- package/ui/theme.js +4 -4
- package/utils/angular-compat.d.ts +21 -0
- package/utils/angular-compat.d.ts.map +1 -0
- package/utils/angular-compat.js +52 -0
- package/utils/angular-compat.js.map +1 -0
- package/utils/config.d.ts +16 -9
- package/utils/config.d.ts.map +1 -1
- package/utils/config.js +35 -13
- package/utils/config.js.map +1 -1
- package/utils/errors.d.ts +11 -0
- package/utils/errors.d.ts.map +1 -1
- package/utils/errors.js +14 -0
- package/utils/errors.js.map +1 -1
- package/utils/get-project-info.d.ts +6 -6
- package/utils/get-project-info.d.ts.map +1 -1
- package/utils/get-project-info.js +106 -36
- package/utils/get-project-info.js.map +1 -1
- package/utils/http-client.d.ts.map +1 -1
- package/utils/http-client.js +20 -5
- package/utils/http-client.js.map +1 -1
- package/utils/icon-catalog.d.ts +34 -0
- package/utils/icon-catalog.d.ts.map +1 -0
- package/utils/icon-catalog.js +63 -0
- package/utils/icon-catalog.js.map +1 -0
- package/utils/logger.d.ts +3 -3
- package/utils/logger.js +9 -9
- package/utils/logger.js.map +1 -1
- package/utils/package-manager.d.ts +25 -25
- package/utils/package-manager.js +50 -50
- package/utils/package-manager.js.map +1 -1
- package/utils/registry.d.ts +100 -6
- package/utils/registry.d.ts.map +1 -1
- package/utils/registry.js +141 -22
- package/utils/registry.js.map +1 -1
- package/utils/schema-version.d.ts +21 -0
- package/utils/schema-version.d.ts.map +1 -0
- package/utils/schema-version.js +28 -0
- package/utils/schema-version.js.map +1 -0
- package/utils/source-file.d.ts +21 -21
- package/utils/source-file.d.ts.map +1 -1
- package/utils/source-file.js +24 -24
- package/utils/source-file.js.map +1 -1
package/ui/index.d.ts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
/**
|
|
2
|
-
*
|
|
2
|
+
* The public surface of the CLI's UI.
|
|
3
3
|
*
|
|
4
|
-
*
|
|
5
|
-
*
|
|
4
|
+
* Commands import from here — never from `./engine` directly — so that replacing
|
|
5
|
+
* or upgrading the engine stays contained in this layer.
|
|
6
6
|
*/
|
|
7
7
|
export * from './engine/index.js';
|
|
8
8
|
export * from './blocks.js';
|
package/ui/index.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
/**
|
|
2
|
-
*
|
|
2
|
+
* The public surface of the CLI's UI.
|
|
3
3
|
*
|
|
4
|
-
*
|
|
5
|
-
*
|
|
4
|
+
* Commands import from here — never from `./engine` directly — so that replacing
|
|
5
|
+
* or upgrading the engine stays contained in this layer.
|
|
6
6
|
*/
|
|
7
7
|
export * from './engine/index.js';
|
|
8
8
|
export * from './blocks.js';
|
package/ui/log-sink.d.ts
CHANGED
|
@@ -1,24 +1,24 @@
|
|
|
1
1
|
/**
|
|
2
|
-
*
|
|
3
|
-
*
|
|
2
|
+
* Message sink — diverts the logger's output while the interactive screen is
|
|
3
|
+
* mounted.
|
|
4
4
|
*
|
|
5
|
-
*
|
|
6
|
-
* (tsconfig-updater, theme-loader, package manager…)
|
|
7
|
-
* engine
|
|
8
|
-
*
|
|
5
|
+
* In the alt-screen, any `console.log` fired by an internal module
|
|
6
|
+
* (tsconfig-updater, theme-loader, package manager…) would tear the frame the
|
|
7
|
+
* engine just painted. While capturing, messages are held here and re-emitted
|
|
8
|
+
* into the terminal's history after unmount, alongside the summary.
|
|
9
9
|
*/
|
|
10
10
|
export type LogLevel = 'info' | 'warn' | 'error' | 'success' | 'debug';
|
|
11
11
|
export interface LogRecord {
|
|
12
12
|
readonly level: LogLevel;
|
|
13
13
|
readonly message: string;
|
|
14
14
|
}
|
|
15
|
-
/**
|
|
15
|
+
/** Starts holding the logger's messages instead of writing them to the terminal. */
|
|
16
16
|
export declare function beginCapture(): void;
|
|
17
17
|
/** Encerra a captura e devolve o que foi retido, na ordem em que chegou. */
|
|
18
18
|
export declare function endCapture(): LogRecord[];
|
|
19
19
|
export declare function isCapturing(): boolean;
|
|
20
|
-
/**
|
|
20
|
+
/** Holds one message. Returns false when no capture is active. */
|
|
21
21
|
export declare function capture(level: LogLevel, message: string): boolean;
|
|
22
|
-
/**
|
|
22
|
+
/** The messages held so far, without ending the capture (for display in the UI). */
|
|
23
23
|
export declare function captured(): readonly LogRecord[];
|
|
24
24
|
//# sourceMappingURL=log-sink.d.ts.map
|
package/ui/log-sink.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"log-sink.d.ts","sourceRoot":"","sources":["../../src/ui/log-sink.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAEH,MAAM,MAAM,QAAQ,GAAG,MAAM,GAAG,MAAM,GAAG,OAAO,GAAG,SAAS,GAAG,OAAO,CAAC;AAEvE,MAAM,WAAW,SAAS;IACxB,QAAQ,CAAC,KAAK,EAAE,QAAQ,CAAC;IACzB,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;CAC1B;AAID,
|
|
1
|
+
{"version":3,"file":"log-sink.d.ts","sourceRoot":"","sources":["../../src/ui/log-sink.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAEH,MAAM,MAAM,QAAQ,GAAG,MAAM,GAAG,MAAM,GAAG,OAAO,GAAG,SAAS,GAAG,OAAO,CAAC;AAEvE,MAAM,WAAW,SAAS;IACxB,QAAQ,CAAC,KAAK,EAAE,QAAQ,CAAC;IACzB,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;CAC1B;AAID,oFAAoF;AACpF,wBAAgB,YAAY,IAAI,IAAI,CAEnC;AAED,4EAA4E;AAC5E,wBAAgB,UAAU,IAAI,SAAS,EAAE,CAIxC;AAED,wBAAgB,WAAW,IAAI,OAAO,CAErC;AAED,kEAAkE;AAClE,wBAAgB,OAAO,CAAC,KAAK,EAAE,QAAQ,EAAE,OAAO,EAAE,MAAM,GAAG,OAAO,CAIjE;AAED,oFAAoF;AACpF,wBAAgB,QAAQ,IAAI,SAAS,SAAS,EAAE,CAE/C"}
|
package/ui/log-sink.js
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
/**
|
|
2
|
-
*
|
|
3
|
-
*
|
|
2
|
+
* Message sink — diverts the logger's output while the interactive screen is
|
|
3
|
+
* mounted.
|
|
4
4
|
*
|
|
5
|
-
*
|
|
6
|
-
* (tsconfig-updater, theme-loader, package manager…)
|
|
7
|
-
* engine
|
|
8
|
-
*
|
|
5
|
+
* In the alt-screen, any `console.log` fired by an internal module
|
|
6
|
+
* (tsconfig-updater, theme-loader, package manager…) would tear the frame the
|
|
7
|
+
* engine just painted. While capturing, messages are held here and re-emitted
|
|
8
|
+
* into the terminal's history after unmount, alongside the summary.
|
|
9
9
|
*/
|
|
10
10
|
let buffer = null;
|
|
11
|
-
/**
|
|
11
|
+
/** Starts holding the logger's messages instead of writing them to the terminal. */
|
|
12
12
|
export function beginCapture() {
|
|
13
13
|
buffer = [];
|
|
14
14
|
}
|
|
@@ -21,14 +21,14 @@ export function endCapture() {
|
|
|
21
21
|
export function isCapturing() {
|
|
22
22
|
return buffer !== null;
|
|
23
23
|
}
|
|
24
|
-
/**
|
|
24
|
+
/** Holds one message. Returns false when no capture is active. */
|
|
25
25
|
export function capture(level, message) {
|
|
26
26
|
if (buffer === null)
|
|
27
27
|
return false;
|
|
28
28
|
buffer.push({ level, message });
|
|
29
29
|
return true;
|
|
30
30
|
}
|
|
31
|
-
/**
|
|
31
|
+
/** The messages held so far, without ending the capture (for display in the UI). */
|
|
32
32
|
export function captured() {
|
|
33
33
|
return buffer ?? [];
|
|
34
34
|
}
|
package/ui/log-sink.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"log-sink.js","sourceRoot":"","sources":["../../src/ui/log-sink.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AASH,IAAI,MAAM,GAAuB,IAAI,CAAC;AAEtC,
|
|
1
|
+
{"version":3,"file":"log-sink.js","sourceRoot":"","sources":["../../src/ui/log-sink.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AASH,IAAI,MAAM,GAAuB,IAAI,CAAC;AAEtC,oFAAoF;AACpF,MAAM,UAAU,YAAY;IAC1B,MAAM,GAAG,EAAE,CAAC;AACd,CAAC;AAED,4EAA4E;AAC5E,MAAM,UAAU,UAAU;IACxB,MAAM,QAAQ,GAAG,MAAM,IAAI,EAAE,CAAC;IAC9B,MAAM,GAAG,IAAI,CAAC;IACd,OAAO,QAAQ,CAAC;AAClB,CAAC;AAED,MAAM,UAAU,WAAW;IACzB,OAAO,MAAM,KAAK,IAAI,CAAC;AACzB,CAAC;AAED,kEAAkE;AAClE,MAAM,UAAU,OAAO,CAAC,KAAe,EAAE,OAAe;IACtD,IAAI,MAAM,KAAK,IAAI;QAAE,OAAO,KAAK,CAAC;IAClC,MAAM,CAAC,IAAI,CAAC,EAAE,KAAK,EAAE,OAAO,EAAE,CAAC,CAAC;IAChC,OAAO,IAAI,CAAC;AACd,CAAC;AAED,oFAAoF;AACpF,MAAM,UAAU,QAAQ;IACtB,OAAO,MAAM,IAAI,EAAE,CAAC;AACtB,CAAC"}
|
package/ui/output.d.ts
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
/**
|
|
2
|
-
*
|
|
3
|
-
* terminal,
|
|
2
|
+
* Line output — the only door through which the CLI writes loose text to the
|
|
3
|
+
* terminal, outside the interactive screen.
|
|
4
4
|
*
|
|
5
|
-
*
|
|
6
|
-
*
|
|
7
|
-
*
|
|
5
|
+
* Concentrating writes here guarantees the logger, the final summary and the
|
|
6
|
+
* messages re-emitted from the sink all use exactly the same level markers and
|
|
7
|
+
* the same palette.
|
|
8
8
|
*/
|
|
9
9
|
import { type LogRecord } from './log-sink.js';
|
|
10
10
|
export declare function writeLine(text?: string): void;
|
|
11
11
|
export declare function formatRecord(record: LogRecord): string;
|
|
12
|
-
/**
|
|
12
|
+
/** Re-emits into the terminal's history the messages held while the screen was up. */
|
|
13
13
|
export declare function flushRecords(records: readonly LogRecord[]): void;
|
|
14
14
|
//# sourceMappingURL=output.d.ts.map
|
package/ui/output.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"output.d.ts","sourceRoot":"","sources":["../../src/ui/output.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAEH,OAAO,EAAE,KAAK,SAAS,EAAiB,MAAM,eAAe,CAAC;AAW9D,wBAAgB,SAAS,CAAC,IAAI,SAAK,GAAG,IAAI,CAEzC;AAED,wBAAgB,YAAY,CAAC,MAAM,EAAE,SAAS,GAAG,MAAM,CAEtD;AAED,
|
|
1
|
+
{"version":3,"file":"output.d.ts","sourceRoot":"","sources":["../../src/ui/output.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAEH,OAAO,EAAE,KAAK,SAAS,EAAiB,MAAM,eAAe,CAAC;AAW9D,wBAAgB,SAAS,CAAC,IAAI,SAAK,GAAG,IAAI,CAEzC;AAED,wBAAgB,YAAY,CAAC,MAAM,EAAE,SAAS,GAAG,MAAM,CAEtD;AAED,sFAAsF;AACtF,wBAAgB,YAAY,CAAC,OAAO,EAAE,SAAS,SAAS,EAAE,GAAG,IAAI,CAEhE"}
|
package/ui/output.js
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
/**
|
|
2
|
-
*
|
|
3
|
-
* terminal,
|
|
2
|
+
* Line output — the only door through which the CLI writes loose text to the
|
|
3
|
+
* terminal, outside the interactive screen.
|
|
4
4
|
*
|
|
5
|
-
*
|
|
6
|
-
*
|
|
7
|
-
*
|
|
5
|
+
* Concentrating writes here guarantees the logger, the final summary and the
|
|
6
|
+
* messages re-emitted from the sink all use exactly the same level markers and
|
|
7
|
+
* the same palette.
|
|
8
8
|
*/
|
|
9
9
|
import { style } from './style.js';
|
|
10
10
|
const MARKS = {
|
|
@@ -20,7 +20,7 @@ export function writeLine(text = '') {
|
|
|
20
20
|
export function formatRecord(record) {
|
|
21
21
|
return MARKS[record.level](record.message);
|
|
22
22
|
}
|
|
23
|
-
/**
|
|
23
|
+
/** Re-emits into the terminal's history the messages held while the screen was up. */
|
|
24
24
|
export function flushRecords(records) {
|
|
25
25
|
for (const record of records)
|
|
26
26
|
writeLine(formatRecord(record));
|
package/ui/output.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"output.js","sourceRoot":"","sources":["../../src/ui/output.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAGH,OAAO,EAAE,KAAK,EAAE,MAAM,YAAY,CAAC;AAEnC,MAAM,KAAK,GAA+C;IACxD,IAAI,EAAE,IAAI,CAAC,EAAE,CAAC,GAAG,KAAK,CAAC,OAAO,CAAC,GAAG,CAAC,IAAI,IAAI,EAAE;IAC7C,OAAO,EAAE,IAAI,CAAC,EAAE,CAAC,GAAG,KAAK,CAAC,OAAO,CAAC,GAAG,CAAC,IAAI,IAAI,EAAE;IAChD,IAAI,EAAE,IAAI,CAAC,EAAE,CAAC,GAAG,KAAK,CAAC,OAAO,CAAC,GAAG,CAAC,IAAI,IAAI,EAAE;IAC7C,KAAK,EAAE,IAAI,CAAC,EAAE,CAAC,GAAG,KAAK,CAAC,MAAM,CAAC,GAAG,CAAC,IAAI,IAAI,EAAE;IAC7C,KAAK,EAAE,IAAI,CAAC,EAAE,CAAC,KAAK,CAAC,GAAG,CAAC,WAAW,IAAI,EAAE,CAAC;CAC5C,CAAC;AAEF,MAAM,UAAU,SAAS,CAAC,IAAI,GAAG,EAAE;IACjC,OAAO,CAAC,MAAM,CAAC,KAAK,CAAC,GAAG,IAAI,IAAI,CAAC,CAAC;AACpC,CAAC;AAED,MAAM,UAAU,YAAY,CAAC,MAAiB;IAC5C,OAAO,KAAK,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC;AAC7C,CAAC;AAED,
|
|
1
|
+
{"version":3,"file":"output.js","sourceRoot":"","sources":["../../src/ui/output.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAGH,OAAO,EAAE,KAAK,EAAE,MAAM,YAAY,CAAC;AAEnC,MAAM,KAAK,GAA+C;IACxD,IAAI,EAAE,IAAI,CAAC,EAAE,CAAC,GAAG,KAAK,CAAC,OAAO,CAAC,GAAG,CAAC,IAAI,IAAI,EAAE;IAC7C,OAAO,EAAE,IAAI,CAAC,EAAE,CAAC,GAAG,KAAK,CAAC,OAAO,CAAC,GAAG,CAAC,IAAI,IAAI,EAAE;IAChD,IAAI,EAAE,IAAI,CAAC,EAAE,CAAC,GAAG,KAAK,CAAC,OAAO,CAAC,GAAG,CAAC,IAAI,IAAI,EAAE;IAC7C,KAAK,EAAE,IAAI,CAAC,EAAE,CAAC,GAAG,KAAK,CAAC,MAAM,CAAC,GAAG,CAAC,IAAI,IAAI,EAAE;IAC7C,KAAK,EAAE,IAAI,CAAC,EAAE,CAAC,KAAK,CAAC,GAAG,CAAC,WAAW,IAAI,EAAE,CAAC;CAC5C,CAAC;AAEF,MAAM,UAAU,SAAS,CAAC,IAAI,GAAG,EAAE;IACjC,OAAO,CAAC,MAAM,CAAC,KAAK,CAAC,GAAG,IAAI,IAAI,CAAC,CAAC;AACpC,CAAC;AAED,MAAM,UAAU,YAAY,CAAC,MAAiB;IAC5C,OAAO,KAAK,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC;AAC7C,CAAC;AAED,sFAAsF;AACtF,MAAM,UAAU,YAAY,CAAC,OAA6B;IACxD,KAAK,MAAM,MAAM,IAAI,OAAO;QAAE,SAAS,CAAC,YAAY,CAAC,MAAM,CAAC,CAAC,CAAC;AAChE,CAAC"}
|
package/ui/report.d.ts
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
/**
|
|
2
|
-
*
|
|
2
|
+
* The post-run summary — what stays in the history after the alt-screen.
|
|
3
3
|
*
|
|
4
|
-
*
|
|
5
|
-
*
|
|
6
|
-
*
|
|
7
|
-
*
|
|
4
|
+
* On leaving the full screen, everything the wizard drew disappears. What the
|
|
5
|
+
* user needs to keep (what was written, what to run next, what went wrong) is
|
|
6
|
+
* reprinted here, in the terminal's normal flow, where it stays scrollable and
|
|
7
|
+
* copyable after the command ends.
|
|
8
8
|
*/
|
|
9
9
|
import { type LogRecord } from './log-sink.js';
|
|
10
10
|
export type ReportStatus = 'success' | 'cancelled' | 'error';
|
|
@@ -17,11 +17,11 @@ export interface Report {
|
|
|
17
17
|
readonly status: ReportStatus;
|
|
18
18
|
/** Uma frase: o desfecho do comando. */
|
|
19
19
|
readonly headline: string;
|
|
20
|
-
/**
|
|
20
|
+
/** What was actually done. */
|
|
21
21
|
readonly items?: readonly string[];
|
|
22
|
-
/**
|
|
22
|
+
/** Supporting text, shown in a secondary tone. */
|
|
23
23
|
readonly notes?: readonly string[];
|
|
24
|
-
/**
|
|
24
|
+
/** Suggested next steps. */
|
|
25
25
|
readonly commands?: readonly ReportCommand[];
|
|
26
26
|
/** Mensagens retidas enquanto a tela estava montada. */
|
|
27
27
|
readonly logs?: readonly LogRecord[];
|
package/ui/report.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"report.d.ts","sourceRoot":"","sources":["../../src/ui/report.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAEH,OAAO,EAAE,KAAK,SAAS,EAAE,MAAM,eAAe,CAAC;AAI/C,MAAM,MAAM,YAAY,GAAG,SAAS,GAAG,WAAW,GAAG,OAAO,CAAC;AAE7D,MAAM,WAAW,aAAa;IAC5B,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;IACzB,sEAAsE;IACtE,QAAQ,CAAC,QAAQ,CAAC,EAAE,MAAM,CAAC;CAC5B;AAED,MAAM,WAAW,MAAM;IACrB,QAAQ,CAAC,MAAM,EAAE,YAAY,CAAC;IAC9B,wCAAwC;IACxC,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAC;IAC1B,
|
|
1
|
+
{"version":3,"file":"report.d.ts","sourceRoot":"","sources":["../../src/ui/report.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAEH,OAAO,EAAE,KAAK,SAAS,EAAE,MAAM,eAAe,CAAC;AAI/C,MAAM,MAAM,YAAY,GAAG,SAAS,GAAG,WAAW,GAAG,OAAO,CAAC;AAE7D,MAAM,WAAW,aAAa;IAC5B,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;IACzB,sEAAsE;IACtE,QAAQ,CAAC,QAAQ,CAAC,EAAE,MAAM,CAAC;CAC5B;AAED,MAAM,WAAW,MAAM;IACrB,QAAQ,CAAC,MAAM,EAAE,YAAY,CAAC;IAC9B,wCAAwC;IACxC,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAC;IAC1B,8BAA8B;IAC9B,QAAQ,CAAC,KAAK,CAAC,EAAE,SAAS,MAAM,EAAE,CAAC;IACnC,kDAAkD;IAClD,QAAQ,CAAC,KAAK,CAAC,EAAE,SAAS,MAAM,EAAE,CAAC;IACnC,4BAA4B;IAC5B,QAAQ,CAAC,QAAQ,CAAC,EAAE,SAAS,aAAa,EAAE,CAAC;IAC7C,wDAAwD;IACxD,QAAQ,CAAC,IAAI,CAAC,EAAE,SAAS,SAAS,EAAE,CAAC;CACtC;AAQD,wBAAgB,WAAW,CAAC,MAAM,EAAE,MAAM,GAAG,IAAI,CA+BhD"}
|
package/ui/report.js
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
/**
|
|
2
|
-
*
|
|
2
|
+
* The post-run summary — what stays in the history after the alt-screen.
|
|
3
3
|
*
|
|
4
|
-
*
|
|
5
|
-
*
|
|
6
|
-
*
|
|
7
|
-
*
|
|
4
|
+
* On leaving the full screen, everything the wizard drew disappears. What the
|
|
5
|
+
* user needs to keep (what was written, what to run next, what went wrong) is
|
|
6
|
+
* reprinted here, in the terminal's normal flow, where it stays scrollable and
|
|
7
|
+
* copyable after the command ends.
|
|
8
8
|
*/
|
|
9
9
|
import { flushRecords, writeLine } from './output.js';
|
|
10
10
|
import { style } from './style.js';
|
|
@@ -37,8 +37,8 @@ export function printReport(report) {
|
|
|
37
37
|
writeLine(` ${style.foreground(command)}${suffix}`);
|
|
38
38
|
}
|
|
39
39
|
}
|
|
40
|
-
//
|
|
41
|
-
//
|
|
40
|
+
// Two lines, not one: the shell prompt comes back right below and, pressed up
|
|
41
|
+
// against it, the last suggested command looks like part of it.
|
|
42
42
|
writeLine();
|
|
43
43
|
writeLine();
|
|
44
44
|
}
|
package/ui/report.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"report.js","sourceRoot":"","sources":["../../src/ui/report.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAGH,OAAO,EAAE,YAAY,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AACtD,OAAO,EAAE,KAAK,EAAE,MAAM,YAAY,CAAC;AAwBnC,MAAM,QAAQ,GAAmD;IAC/D,OAAO,EAAE,IAAI,CAAC,EAAE,CAAC,GAAG,KAAK,CAAC,OAAO,CAAC,GAAG,CAAC,IAAI,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,EAAE;IAC5D,SAAS,EAAE,IAAI,CAAC,EAAE,CAAC,GAAG,KAAK,CAAC,OAAO,CAAC,GAAG,CAAC,IAAI,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,EAAE;IAC9D,KAAK,EAAE,IAAI,CAAC,EAAE,CAAC,GAAG,KAAK,CAAC,MAAM,CAAC,GAAG,CAAC,IAAI,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,EAAE;CAC1D,CAAC;AAEF,MAAM,UAAU,WAAW,CAAC,MAAc;IACxC,SAAS,EAAE,CAAC;IACZ,SAAS,CAAC,QAAQ,CAAC,MAAM,CAAC,MAAM,CAAC,CAAC,MAAM,CAAC,QAAQ,CAAC,CAAC,CAAC;IAEpD,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AAK,MAAM,EAAE,OAAO,EAAE,QAAQ,EAAE,IAAI,MAAM,CAAC,QAAQ,EAAE,CAAC;YACpD,MAAM,MAAM,GAAG,QAAQ,CAAC,CAAC,CAAC,IAAI,KAAK,CAAC,OAAO,CAAC,QAAQ,CAAC,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC;YAC7D,SAAS,CAAC,KAAK,KAAK,CAAC,UAAU,CAAC,OAAO,CAAC,GAAG,MAAM,EAAE,CAAC,CAAC;QACvD,CAAC;IACH,CAAC;IAED,8EAA8E;IAC9E,gEAAgE;IAChE,SAAS,EAAE,CAAC;IACZ,SAAS,EAAE,CAAC;AACd,CAAC"}
|
package/ui/runner.d.ts
CHANGED
|
@@ -1,26 +1,26 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Runner —
|
|
2
|
+
* Runner — the bridge between the engine's frame loop and the CLI's async flow.
|
|
3
3
|
*
|
|
4
|
-
*
|
|
5
|
-
*
|
|
6
|
-
*
|
|
7
|
-
*
|
|
4
|
+
* Commands are sequential (`const config = await promptForConfig(...)`), while
|
|
5
|
+
* the engine is an event-driven render loop. The runner reconciles the two: it
|
|
6
|
+
* mounts the screen, hands control to `onKey`/`run`, and resolves a Promise when
|
|
7
|
+
* the flow calls `done()`.
|
|
8
8
|
*
|
|
9
|
-
*
|
|
10
|
-
* 1.
|
|
11
|
-
*
|
|
12
|
-
* 2.
|
|
13
|
-
*
|
|
14
|
-
* 3.
|
|
15
|
-
*
|
|
9
|
+
* Three invariants hold for every wizard:
|
|
10
|
+
* 1. the terminal is restored on every exit path — errors, SIGINT and a
|
|
11
|
+
* process crash included;
|
|
12
|
+
* 2. with no TTY the screen is never mounted: the caller gets a
|
|
13
|
+
* NonInteractiveError and follows the headless path;
|
|
14
|
+
* 3. whatever the logger would write during the mount is held in the sink and
|
|
15
|
+
* re-emitted afterwards, so the frame is not torn.
|
|
16
16
|
*/
|
|
17
|
-
import { type KeyEvent, type Node, type Screen } from './engine/index.js';
|
|
17
|
+
import { type KeyEvent, type Node, type Screen, type TerminalStreams } from './engine/index.js';
|
|
18
18
|
import { type LogRecord } from './log-sink.js';
|
|
19
|
-
/**
|
|
19
|
+
/** Signals that the command has to carry on without an interactive UI (CI, pipe, --yes). */
|
|
20
20
|
export declare class NonInteractiveError extends Error {
|
|
21
21
|
constructor(message?: string);
|
|
22
22
|
}
|
|
23
|
-
/**
|
|
23
|
+
/** The user abandoned the wizard (Ctrl+C, or a step that cancels the flow). */
|
|
24
24
|
export declare class WizardCancelledError extends Error {
|
|
25
25
|
constructor(message?: string);
|
|
26
26
|
}
|
|
@@ -31,27 +31,36 @@ export interface WizardContext<T> {
|
|
|
31
31
|
cancel(message?: string): void;
|
|
32
32
|
/** Agenda um novo frame depois de alterar o estado. */
|
|
33
33
|
refresh(): void;
|
|
34
|
-
/**
|
|
34
|
+
/** Access to the screen, for cases that need the scheduler or the capabilities. */
|
|
35
35
|
readonly screen: Screen;
|
|
36
36
|
}
|
|
37
37
|
export interface WizardOptions<T> {
|
|
38
|
-
/**
|
|
38
|
+
/** Pure view, rebuilt every frame. */
|
|
39
39
|
view: () => Node;
|
|
40
|
-
/**
|
|
40
|
+
/** Keys the view handles on its own. */
|
|
41
41
|
onKey?: (event: KeyEvent, ctx: WizardContext<T>) => void;
|
|
42
42
|
/**
|
|
43
|
-
*
|
|
44
|
-
*
|
|
43
|
+
* Async work run with the screen alive — installing packages, writing files.
|
|
44
|
+
* The UI keeps animating until the promise resolves.
|
|
45
45
|
*/
|
|
46
46
|
run?: (ctx: WizardContext<T>) => Promise<void> | void;
|
|
47
47
|
fps?: number;
|
|
48
|
+
/** How to find the terminal. Injectable for tests; the default resolves it itself. */
|
|
49
|
+
resolveStreams?: () => TerminalStreams | null;
|
|
48
50
|
}
|
|
49
51
|
export interface WizardResult<T> {
|
|
50
52
|
readonly value: T;
|
|
51
53
|
/** Mensagens que o logger reteve enquanto a tela estava montada. */
|
|
52
54
|
readonly logs: readonly LogRecord[];
|
|
53
55
|
}
|
|
54
|
-
/**
|
|
55
|
-
|
|
56
|
+
/**
|
|
57
|
+
* True when there is a terminal to mount the screen on.
|
|
58
|
+
*
|
|
59
|
+
* Looking at `process.stdout.isTTY && process.stdin.isTTY` is not enough: that
|
|
60
|
+
* is what made `npx zard-cli init` fall back to text mode on macOS and Linux,
|
|
61
|
+
* where npm runs the binary through a shell and hands over stdin as a pipe. The
|
|
62
|
+
* controlling terminal is still reachable, and it is what decides.
|
|
63
|
+
*/
|
|
64
|
+
export declare function isInteractive(resolve?: () => TerminalStreams | null): boolean;
|
|
56
65
|
export declare function runWizard<T>(options: WizardOptions<T>): Promise<WizardResult<T>>;
|
|
57
66
|
//# sourceMappingURL=runner.d.ts.map
|
package/ui/runner.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"runner.d.ts","sourceRoot":"","sources":["../../src/ui/runner.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;GAeG;AAEH,OAAO,
|
|
1
|
+
{"version":3,"file":"runner.d.ts","sourceRoot":"","sources":["../../src/ui/runner.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;GAeG;AAEH,OAAO,EAIL,KAAK,QAAQ,EACb,KAAK,IAAI,EACT,KAAK,MAAM,EACX,KAAK,eAAe,EACrB,MAAM,mBAAmB,CAAC;AAC3B,OAAO,EAA4B,KAAK,SAAS,EAAE,MAAM,eAAe,CAAC;AAIzE,4FAA4F;AAC5F,qBAAa,mBAAoB,SAAQ,KAAK;gBAChC,OAAO,SAAsC;CAI1D;AAED,+EAA+E;AAC/E,qBAAa,oBAAqB,SAAQ,KAAK;gBACjC,OAAO,SAAyB;CAI7C;AAED,MAAM,WAAW,aAAa,CAAC,CAAC;IAC9B,wDAAwD;IACxD,IAAI,CAAC,KAAK,EAAE,CAAC,GAAG,IAAI,CAAC;IACrB,yDAAyD;IACzD,MAAM,CAAC,OAAO,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAC/B,uDAAuD;IACvD,OAAO,IAAI,IAAI,CAAC;IAChB,mFAAmF;IACnF,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAC;CACzB;AAED,MAAM,WAAW,aAAa,CAAC,CAAC;IAC9B,sCAAsC;IACtC,IAAI,EAAE,MAAM,IAAI,CAAC;IACjB,wCAAwC;IACxC,KAAK,CAAC,EAAE,CAAC,KAAK,EAAE,QAAQ,EAAE,GAAG,EAAE,aAAa,CAAC,CAAC,CAAC,KAAK,IAAI,CAAC;IACzD;;;OAGG;IACH,GAAG,CAAC,EAAE,CAAC,GAAG,EAAE,aAAa,CAAC,CAAC,CAAC,KAAK,OAAO,CAAC,IAAI,CAAC,GAAG,IAAI,CAAC;IACtD,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,sFAAsF;IACtF,cAAc,CAAC,EAAE,MAAM,eAAe,GAAG,IAAI,CAAC;CAC/C;AAED,MAAM,WAAW,YAAY,CAAC,CAAC;IAC7B,QAAQ,CAAC,KAAK,EAAE,CAAC,CAAC;IAClB,oEAAoE;IACpE,QAAQ,CAAC,IAAI,EAAE,SAAS,SAAS,EAAE,CAAC;CACrC;AAED;;;;;;;GAOG;AACH,wBAAgB,aAAa,CAAC,OAAO,GAAE,MAAM,eAAe,GAAG,IAA6B,GAAG,OAAO,CAMrG;AAED,wBAAsB,SAAS,CAAC,CAAC,EAAE,OAAO,EAAE,aAAa,CAAC,CAAC,CAAC,GAAG,OAAO,CAAC,YAAY,CAAC,CAAC,CAAC,CAAC,CAwFtF"}
|
package/ui/runner.js
CHANGED
|
@@ -1,49 +1,62 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Runner —
|
|
2
|
+
* Runner — the bridge between the engine's frame loop and the CLI's async flow.
|
|
3
3
|
*
|
|
4
|
-
*
|
|
5
|
-
*
|
|
6
|
-
*
|
|
7
|
-
*
|
|
4
|
+
* Commands are sequential (`const config = await promptForConfig(...)`), while
|
|
5
|
+
* the engine is an event-driven render loop. The runner reconciles the two: it
|
|
6
|
+
* mounts the screen, hands control to `onKey`/`run`, and resolves a Promise when
|
|
7
|
+
* the flow calls `done()`.
|
|
8
8
|
*
|
|
9
|
-
*
|
|
10
|
-
* 1.
|
|
11
|
-
*
|
|
12
|
-
* 2.
|
|
13
|
-
*
|
|
14
|
-
* 3.
|
|
15
|
-
*
|
|
9
|
+
* Three invariants hold for every wizard:
|
|
10
|
+
* 1. the terminal is restored on every exit path — errors, SIGINT and a
|
|
11
|
+
* process crash included;
|
|
12
|
+
* 2. with no TTY the screen is never mounted: the caller gets a
|
|
13
|
+
* NonInteractiveError and follows the headless path;
|
|
14
|
+
* 3. whatever the logger would write during the mount is held in the sink and
|
|
15
|
+
* re-emitted afterwards, so the frame is not torn.
|
|
16
16
|
*/
|
|
17
|
-
import { createScreen } from './engine/index.js';
|
|
17
|
+
import { createScreen, createTerminal, resolveTerminalStreams, } from './engine/index.js';
|
|
18
18
|
import { beginCapture, endCapture } from './log-sink.js';
|
|
19
19
|
import { flushRecords } from './output.js';
|
|
20
20
|
import { zardTheme } from './theme.js';
|
|
21
|
-
/**
|
|
21
|
+
/** Signals that the command has to carry on without an interactive UI (CI, pipe, --yes). */
|
|
22
22
|
export class NonInteractiveError extends Error {
|
|
23
23
|
constructor(message = 'This terminal is not interactive.') {
|
|
24
24
|
super(message);
|
|
25
25
|
this.name = 'NonInteractiveError';
|
|
26
26
|
}
|
|
27
27
|
}
|
|
28
|
-
/**
|
|
28
|
+
/** The user abandoned the wizard (Ctrl+C, or a step that cancels the flow). */
|
|
29
29
|
export class WizardCancelledError extends Error {
|
|
30
30
|
constructor(message = 'Operation cancelled.') {
|
|
31
31
|
super(message);
|
|
32
32
|
this.name = 'WizardCancelledError';
|
|
33
33
|
}
|
|
34
34
|
}
|
|
35
|
-
/**
|
|
36
|
-
|
|
37
|
-
|
|
35
|
+
/**
|
|
36
|
+
* True when there is a terminal to mount the screen on.
|
|
37
|
+
*
|
|
38
|
+
* Looking at `process.stdout.isTTY && process.stdin.isTTY` is not enough: that
|
|
39
|
+
* is what made `npx zard-cli init` fall back to text mode on macOS and Linux,
|
|
40
|
+
* where npm runs the binary through a shell and hands over stdin as a pipe. The
|
|
41
|
+
* controlling terminal is still reachable, and it is what decides.
|
|
42
|
+
*/
|
|
43
|
+
export function isInteractive(resolve = resolveTerminalStreams) {
|
|
44
|
+
const streams = resolve();
|
|
45
|
+
if (!streams)
|
|
46
|
+
return false;
|
|
47
|
+
streams.close();
|
|
48
|
+
return true;
|
|
38
49
|
}
|
|
39
50
|
export async function runWizard(options) {
|
|
40
|
-
|
|
51
|
+
const streams = (options.resolveStreams ?? resolveTerminalStreams)();
|
|
52
|
+
if (!streams)
|
|
41
53
|
throw new NonInteractiveError();
|
|
42
54
|
const screen = createScreen({
|
|
43
55
|
theme: zardTheme,
|
|
44
56
|
fps: options.fps ?? 30,
|
|
45
|
-
|
|
46
|
-
//
|
|
57
|
+
terminal: createTerminal({ stdin: streams.input, stdout: streams.output }),
|
|
58
|
+
// Teardown is ours: we intercept Ctrl+C to end the wizard with a message,
|
|
59
|
+
// instead of killing the process from inside the engine.
|
|
47
60
|
handleExitSignals: false,
|
|
48
61
|
});
|
|
49
62
|
let settled = false;
|
|
@@ -53,12 +66,15 @@ export async function runWizard(options) {
|
|
|
53
66
|
return;
|
|
54
67
|
teardownDone = true;
|
|
55
68
|
screen.unmount();
|
|
69
|
+
// After the unmount: that is what returns the terminal to its normal state,
|
|
70
|
+
// and closing the streams first would leave the alt-screen and raw mode on.
|
|
71
|
+
streams.close();
|
|
56
72
|
process.off('exit', teardown);
|
|
57
73
|
process.off('SIGINT', onSignal);
|
|
58
74
|
process.off('SIGTERM', onSignal);
|
|
59
75
|
};
|
|
60
|
-
//
|
|
61
|
-
//
|
|
76
|
+
// Safety net: if the process dies with the screen mounted, the terminal still
|
|
77
|
+
// returns to normal (cursor visible, no raw mode, out of the alt-screen).
|
|
62
78
|
function onSignal() {
|
|
63
79
|
teardown();
|
|
64
80
|
process.exit(130);
|
|
@@ -107,8 +123,8 @@ export async function runWizard(options) {
|
|
|
107
123
|
return { value, logs: endCapture() };
|
|
108
124
|
}
|
|
109
125
|
catch (error) {
|
|
110
|
-
//
|
|
111
|
-
//
|
|
126
|
+
// Last chance to show what was held: the screen is already down and whoever
|
|
127
|
+
// handles the error above will only see the exception's message.
|
|
112
128
|
flushRecords(endCapture());
|
|
113
129
|
throw error;
|
|
114
130
|
}
|
package/ui/runner.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"runner.js","sourceRoot":"","sources":["../../src/ui/runner.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;GAeG;AAEH,OAAO,
|
|
1
|
+
{"version":3,"file":"runner.js","sourceRoot":"","sources":["../../src/ui/runner.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;GAeG;AAEH,OAAO,EACL,YAAY,EACZ,cAAc,EACd,sBAAsB,GAKvB,MAAM,mBAAmB,CAAC;AAC3B,OAAO,EAAE,YAAY,EAAE,UAAU,EAAkB,MAAM,eAAe,CAAC;AACzE,OAAO,EAAE,YAAY,EAAE,MAAM,aAAa,CAAC;AAC3C,OAAO,EAAE,SAAS,EAAE,MAAM,YAAY,CAAC;AAEvC,4FAA4F;AAC5F,MAAM,OAAO,mBAAoB,SAAQ,KAAK;IAC5C,YAAY,OAAO,GAAG,mCAAmC;QACvD,KAAK,CAAC,OAAO,CAAC,CAAC;QACf,IAAI,CAAC,IAAI,GAAG,qBAAqB,CAAC;IACpC,CAAC;CACF;AAED,+EAA+E;AAC/E,MAAM,OAAO,oBAAqB,SAAQ,KAAK;IAC7C,YAAY,OAAO,GAAG,sBAAsB;QAC1C,KAAK,CAAC,OAAO,CAAC,CAAC;QACf,IAAI,CAAC,IAAI,GAAG,sBAAsB,CAAC;IACrC,CAAC;CACF;AAkCD;;;;;;;GAOG;AACH,MAAM,UAAU,aAAa,CAAC,UAAwC,sBAAsB;IAC1F,MAAM,OAAO,GAAG,OAAO,EAAE,CAAC;IAC1B,IAAI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AC;YAC9B,CAAC,CAAC,CAAC;YAEH,MAAM,CAAC,KAAK,EAAE,CAAC;YAEf,IAAI,OAAO,CAAC,GAAG,EAAE,CAAC;gBAChB,KAAK,CAAC,KAAK,IAAI,EAAE;oBACf,IAAI,CAAC;wBACH,MAAM,OAAO,CAAC,GAAG,EAAE,CAAC,GAAG,CAAC,CAAC;oBAC3B,CAAC;oBAAC,OAAO,KAAK,EAAE,CAAC;wBACf,MAAM,CAAC,GAAG,EAAE,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC,CAAC;oBAC9B,CAAC;gBACH,CAAC,CAAC,EAAE,CAAC;YACP,CAAC;QACH,CAAC,CAAC,CAAC;QAEH,OAAO,EAAE,KAAK,EAAE,IAAI,EAAE,UAAU,EAAE,EAAE,CAAC;IACvC,CAAC;IAAC,OAAO,KAAK,EAAE,CAAC;QACf,4EAA4E;QAC5E,iEAAiE;QACjE,YAAY,CAAC,UAAU,EAAE,CAAC,CAAC;QAC3B,MAAM,KAAK,CAAC;IACd,CAAC;YAAS,CAAC;QACT,QAAQ,EAAE,CAAC;IACb,CAAC;AACH,CAAC"}
|
package/ui/style.d.ts
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
/**
|
|
2
|
-
*
|
|
2
|
+
* Styling for line output — what the CLI writes outside the interactive screen.
|
|
3
3
|
*
|
|
4
|
-
*
|
|
5
|
-
*
|
|
6
|
-
*
|
|
4
|
+
* Replaces chalk using the engine's own ANSI vocabulary, which keeps a single
|
|
5
|
+
* source of truth for colour: the same theme tokens apply to the wizard in the
|
|
6
|
+
* alt-screen and to the text left behind in the terminal's history.
|
|
7
7
|
*/
|
|
8
|
-
/**
|
|
8
|
+
/** Re-evaluates the colour capability — used in tests, when stdout is swapped. */
|
|
9
9
|
export declare function resetColorLevel(): void;
|
|
10
10
|
export declare const style: {
|
|
11
11
|
primary: (text: string) => string;
|
|
@@ -16,9 +16,9 @@ export declare const style: {
|
|
|
16
16
|
foreground: (text: string) => string;
|
|
17
17
|
bold: (text: string) => string;
|
|
18
18
|
dim: (text: string) => string;
|
|
19
|
-
/**
|
|
19
|
+
/** Highlights a file name, command or path inside a sentence. */
|
|
20
20
|
code: (text: string) => string;
|
|
21
21
|
};
|
|
22
|
-
/**
|
|
22
|
+
/** True when the terminal accepts the UI's Unicode boxes and glyphs. */
|
|
23
23
|
export declare function supportsUnicode(): boolean;
|
|
24
24
|
//# sourceMappingURL=style.d.ts.map
|
package/ui/style.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"style.d.ts","sourceRoot":"","sources":["../../src/ui/style.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAaH,
|
|
1
|
+
{"version":3,"file":"style.d.ts","sourceRoot":"","sources":["../../src/ui/style.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAaH,kFAAkF;AAClF,wBAAgB,eAAe,IAAI,IAAI,CAEtC;AAWD,eAAO,MAAM,KAAK;oBACA,MAAM;oBACN,MAAM;oBACN,MAAM;mBACP,MAAM;kBACP,MAAM;uBACD,MAAM;iBACZ,MAAM;gBACP,MAAM;IAClB,iEAAiE;iBACpD,MAAM;CACpB,CAAC;AAEF,wEAAwE;AACxE,wBAAgB,eAAe,IAAI,OAAO,CAEzC"}
|
package/ui/style.js
CHANGED
|
@@ -1,19 +1,19 @@
|
|
|
1
1
|
/**
|
|
2
|
-
*
|
|
2
|
+
* Styling for line output — what the CLI writes outside the interactive screen.
|
|
3
3
|
*
|
|
4
|
-
*
|
|
5
|
-
*
|
|
6
|
-
*
|
|
4
|
+
* Replaces chalk using the engine's own ANSI vocabulary, which keeps a single
|
|
5
|
+
* source of truth for colour: the same theme tokens apply to the wizard in the
|
|
6
|
+
* alt-screen and to the text left behind in the terminal's history.
|
|
7
7
|
*/
|
|
8
8
|
import { Attr, createSgrBuilder, createTerminal } from './engine/index.js';
|
|
9
9
|
import { zardTheme } from './theme.js';
|
|
10
10
|
let cachedLevel = null;
|
|
11
|
-
/**
|
|
11
|
+
/** The current terminal's colour depth, resolved once per process. */
|
|
12
12
|
function colorLevel() {
|
|
13
13
|
cachedLevel ??= createTerminal().caps.colors;
|
|
14
14
|
return cachedLevel;
|
|
15
15
|
}
|
|
16
|
-
/**
|
|
16
|
+
/** Re-evaluates the colour capability — used in tests, when stdout is swapped. */
|
|
17
17
|
export function resetColorLevel() {
|
|
18
18
|
cachedLevel = null;
|
|
19
19
|
}
|
|
@@ -34,10 +34,10 @@ export const style = {
|
|
|
34
34
|
foreground: (text) => paint(text, 'foreground'),
|
|
35
35
|
bold: (text) => paint(text, undefined, Attr.Bold),
|
|
36
36
|
dim: (text) => paint(text, undefined, Attr.Dim),
|
|
37
|
-
/**
|
|
37
|
+
/** Highlights a file name, command or path inside a sentence. */
|
|
38
38
|
code: (text) => paint(text, 'primary', Attr.Bold),
|
|
39
39
|
};
|
|
40
|
-
/**
|
|
40
|
+
/** True when the terminal accepts the UI's Unicode boxes and glyphs. */
|
|
41
41
|
export function supportsUnicode() {
|
|
42
42
|
return createTerminal().caps.unicode;
|
|
43
43
|
}
|
package/ui/style.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"style.js","sourceRoot":"","sources":["../../src/ui/style.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,EAAE,IAAI,EAAE,gBAAgB,EAAE,cAAc,EAAmB,MAAM,mBAAmB,CAAC;AAC5F,OAAO,EAAE,SAAS,EAAE,MAAM,YAAY,CAAC;AAEvC,IAAI,WAAW,GAAsB,IAAI,CAAC;AAE1C,
|
|
1
|
+
{"version":3,"file":"style.js","sourceRoot":"","sources":["../../src/ui/style.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,EAAE,IAAI,EAAE,gBAAgB,EAAE,cAAc,EAAmB,MAAM,mBAAmB,CAAC;AAC5F,OAAO,EAAE,SAAS,EAAE,MAAM,YAAY,CAAC;AAEvC,IAAI,WAAW,GAAsB,IAAI,CAA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