@chengchenccc/tui 0.1.1-rc.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/dist/autocomplete.d.ts +56 -0
- package/dist/autocomplete.d.ts.map +1 -0
- package/dist/autocomplete.js +647 -0
- package/dist/components/box.d.ts +22 -0
- package/dist/components/box.d.ts.map +1 -0
- package/dist/components/box.js +103 -0
- package/dist/components/card.d.ts +33 -0
- package/dist/components/card.d.ts.map +1 -0
- package/dist/components/card.js +49 -0
- package/dist/components/editor.d.ts +257 -0
- package/dist/components/editor.d.ts.map +1 -0
- package/dist/components/editor.js +1980 -0
- package/dist/components/input.d.ts +37 -0
- package/dist/components/input.d.ts.map +1 -0
- package/dist/components/input.js +389 -0
- package/dist/components/loader.d.ts +33 -0
- package/dist/components/loader.d.ts.map +1 -0
- package/dist/components/loader.js +100 -0
- package/dist/components/markdown.d.ts +108 -0
- package/dist/components/markdown.d.ts.map +1 -0
- package/dist/components/markdown.js +847 -0
- package/dist/components/markdown.test.d.ts +2 -0
- package/dist/components/markdown.test.d.ts.map +1 -0
- package/dist/components/markdown.test.js +81 -0
- package/dist/components/output-block.d.ts +44 -0
- package/dist/components/output-block.d.ts.map +1 -0
- package/dist/components/output-block.js +131 -0
- package/dist/components/select-list.d.ts +50 -0
- package/dist/components/select-list.d.ts.map +1 -0
- package/dist/components/select-list.js +166 -0
- package/dist/components/spacer.d.ts +12 -0
- package/dist/components/spacer.d.ts.map +1 -0
- package/dist/components/spacer.js +22 -0
- package/dist/components/statusline.d.ts +30 -0
- package/dist/components/statusline.d.ts.map +1 -0
- package/dist/components/statusline.js +46 -0
- package/dist/components/text.d.ts +19 -0
- package/dist/components/text.d.ts.map +1 -0
- package/dist/components/text.js +90 -0
- package/dist/components/truncated-text.d.ts +13 -0
- package/dist/components/truncated-text.d.ts.map +1 -0
- package/dist/components/truncated-text.js +50 -0
- package/dist/editor-component.d.ts +39 -0
- package/dist/editor-component.d.ts.map +1 -0
- package/dist/editor-component.js +1 -0
- package/dist/fuzzy.d.ts +16 -0
- package/dist/fuzzy.d.ts.map +1 -0
- package/dist/fuzzy.js +109 -0
- package/dist/index.d.ts +25 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +36 -0
- package/dist/keybindings.d.ts +193 -0
- package/dist/keybindings.d.ts.map +1 -0
- package/dist/keybindings.js +191 -0
- package/dist/keys.d.ts +184 -0
- package/dist/keys.d.ts.map +1 -0
- package/dist/keys.js +1191 -0
- package/dist/kill-ring.d.ts +28 -0
- package/dist/kill-ring.d.ts.map +1 -0
- package/dist/kill-ring.js +43 -0
- package/dist/mermaid.d.ts +23 -0
- package/dist/mermaid.d.ts.map +1 -0
- package/dist/mermaid.js +77 -0
- package/dist/mouse.d.ts +40 -0
- package/dist/mouse.d.ts.map +1 -0
- package/dist/mouse.js +39 -0
- package/dist/mouse.test.d.ts +2 -0
- package/dist/mouse.test.d.ts.map +1 -0
- package/dist/mouse.test.js +36 -0
- package/dist/native-modifiers.d.ts +3 -0
- package/dist/native-modifiers.d.ts.map +1 -0
- package/dist/native-modifiers.js +52 -0
- package/dist/stdin-buffer.d.ts +50 -0
- package/dist/stdin-buffer.d.ts.map +1 -0
- package/dist/stdin-buffer.js +360 -0
- package/dist/terminal-colors.d.ts +10 -0
- package/dist/terminal-colors.d.ts.map +1 -0
- package/dist/terminal-colors.js +58 -0
- package/dist/terminal-image.d.ts +90 -0
- package/dist/terminal-image.d.ts.map +1 -0
- package/dist/terminal-image.js +375 -0
- package/dist/terminal.d.ts +110 -0
- package/dist/terminal.d.ts.map +1 -0
- package/dist/terminal.js +432 -0
- package/dist/tui-scrollback.test.d.ts +2 -0
- package/dist/tui-scrollback.test.d.ts.map +1 -0
- package/dist/tui-scrollback.test.js +51 -0
- package/dist/tui.d.ts +330 -0
- package/dist/tui.d.ts.map +1 -0
- package/dist/tui.js +1568 -0
- package/dist/undo-stack.d.ts +17 -0
- package/dist/undo-stack.d.ts.map +1 -0
- package/dist/undo-stack.js +24 -0
- package/dist/utils.d.ts +85 -0
- package/dist/utils.d.ts.map +1 -0
- package/dist/utils.js +1066 -0
- package/dist/vendor/mermaid-ascii/ascii/ansi.d.ts +42 -0
- package/dist/vendor/mermaid-ascii/ascii/ansi.d.ts.map +1 -0
- package/dist/vendor/mermaid-ascii/ascii/ansi.js +361 -0
- package/dist/vendor/mermaid-ascii/ascii/canvas.d.ts +90 -0
- package/dist/vendor/mermaid-ascii/ascii/canvas.d.ts.map +1 -0
- package/dist/vendor/mermaid-ascii/ascii/canvas.js +414 -0
- package/dist/vendor/mermaid-ascii/ascii/class-diagram.d.ts +8 -0
- package/dist/vendor/mermaid-ascii/ascii/class-diagram.d.ts.map +1 -0
- package/dist/vendor/mermaid-ascii/ascii/class-diagram.js +623 -0
- package/dist/vendor/mermaid-ascii/ascii/converter.d.ts +13 -0
- package/dist/vendor/mermaid-ascii/ascii/converter.d.ts.map +1 -0
- package/dist/vendor/mermaid-ascii/ascii/converter.js +233 -0
- package/dist/vendor/mermaid-ascii/ascii/draw.d.ts +67 -0
- package/dist/vendor/mermaid-ascii/ascii/draw.d.ts.map +1 -0
- package/dist/vendor/mermaid-ascii/ascii/draw.js +1313 -0
- package/dist/vendor/mermaid-ascii/ascii/edge-bundling.d.ts +49 -0
- package/dist/vendor/mermaid-ascii/ascii/edge-bundling.d.ts.map +1 -0
- package/dist/vendor/mermaid-ascii/ascii/edge-bundling.js +289 -0
- package/dist/vendor/mermaid-ascii/ascii/edge-routing.d.ts +44 -0
- package/dist/vendor/mermaid-ascii/ascii/edge-routing.d.ts.map +1 -0
- package/dist/vendor/mermaid-ascii/ascii/edge-routing.js +302 -0
- package/dist/vendor/mermaid-ascii/ascii/er-diagram.d.ts +8 -0
- package/dist/vendor/mermaid-ascii/ascii/er-diagram.d.ts.map +1 -0
- package/dist/vendor/mermaid-ascii/ascii/er-diagram.js +380 -0
- package/dist/vendor/mermaid-ascii/ascii/grid.d.ts +57 -0
- package/dist/vendor/mermaid-ascii/ascii/grid.d.ts.map +1 -0
- package/dist/vendor/mermaid-ascii/ascii/grid.js +516 -0
- package/dist/vendor/mermaid-ascii/ascii/index.d.ts +66 -0
- package/dist/vendor/mermaid-ascii/ascii/index.d.ts.map +1 -0
- package/dist/vendor/mermaid-ascii/ascii/index.js +133 -0
- package/dist/vendor/mermaid-ascii/ascii/multiline-utils.d.ts +28 -0
- package/dist/vendor/mermaid-ascii/ascii/multiline-utils.d.ts.map +1 -0
- package/dist/vendor/mermaid-ascii/ascii/multiline-utils.js +60 -0
- package/dist/vendor/mermaid-ascii/ascii/pathfinder.d.ts +18 -0
- package/dist/vendor/mermaid-ascii/ascii/pathfinder.d.ts.map +1 -0
- package/dist/vendor/mermaid-ascii/ascii/pathfinder.js +224 -0
- package/dist/vendor/mermaid-ascii/ascii/sequence.d.ts +8 -0
- package/dist/vendor/mermaid-ascii/ascii/sequence.d.ts.map +1 -0
- package/dist/vendor/mermaid-ascii/ascii/sequence.js +416 -0
- package/dist/vendor/mermaid-ascii/ascii/shapes/circle.d.ts +12 -0
- package/dist/vendor/mermaid-ascii/ascii/shapes/circle.d.ts.map +1 -0
- package/dist/vendor/mermaid-ascii/ascii/shapes/circle.js +22 -0
- package/dist/vendor/mermaid-ascii/ascii/shapes/corners.d.ts +35 -0
- package/dist/vendor/mermaid-ascii/ascii/shapes/corners.d.ts.map +1 -0
- package/dist/vendor/mermaid-ascii/ascii/shapes/corners.js +91 -0
- package/dist/vendor/mermaid-ascii/ascii/shapes/diamond.d.ts +12 -0
- package/dist/vendor/mermaid-ascii/ascii/shapes/diamond.d.ts.map +1 -0
- package/dist/vendor/mermaid-ascii/ascii/shapes/diamond.js +22 -0
- package/dist/vendor/mermaid-ascii/ascii/shapes/hexagon.d.ts +12 -0
- package/dist/vendor/mermaid-ascii/ascii/shapes/hexagon.d.ts.map +1 -0
- package/dist/vendor/mermaid-ascii/ascii/shapes/hexagon.js +22 -0
- package/dist/vendor/mermaid-ascii/ascii/shapes/index.d.ts +27 -0
- package/dist/vendor/mermaid-ascii/ascii/shapes/index.d.ts.map +1 -0
- package/dist/vendor/mermaid-ascii/ascii/shapes/index.js +66 -0
- package/dist/vendor/mermaid-ascii/ascii/shapes/rectangle.d.ts +32 -0
- package/dist/vendor/mermaid-ascii/ascii/shapes/rectangle.d.ts.map +1 -0
- package/dist/vendor/mermaid-ascii/ascii/shapes/rectangle.js +149 -0
- package/dist/vendor/mermaid-ascii/ascii/shapes/rounded.d.ts +12 -0
- package/dist/vendor/mermaid-ascii/ascii/shapes/rounded.d.ts.map +1 -0
- package/dist/vendor/mermaid-ascii/ascii/shapes/rounded.js +22 -0
- package/dist/vendor/mermaid-ascii/ascii/shapes/special.d.ts +60 -0
- package/dist/vendor/mermaid-ascii/ascii/shapes/special.d.ts.map +1 -0
- package/dist/vendor/mermaid-ascii/ascii/shapes/special.js +253 -0
- package/dist/vendor/mermaid-ascii/ascii/shapes/stadium.d.ts +18 -0
- package/dist/vendor/mermaid-ascii/ascii/shapes/stadium.d.ts.map +1 -0
- package/dist/vendor/mermaid-ascii/ascii/shapes/stadium.js +103 -0
- package/dist/vendor/mermaid-ascii/ascii/shapes/state.d.ts +31 -0
- package/dist/vendor/mermaid-ascii/ascii/shapes/state.d.ts.map +1 -0
- package/dist/vendor/mermaid-ascii/ascii/shapes/state.js +167 -0
- package/dist/vendor/mermaid-ascii/ascii/shapes/types.d.ts +56 -0
- package/dist/vendor/mermaid-ascii/ascii/shapes/types.d.ts.map +1 -0
- package/dist/vendor/mermaid-ascii/ascii/shapes/types.js +4 -0
- package/dist/vendor/mermaid-ascii/ascii/types.d.ts +207 -0
- package/dist/vendor/mermaid-ascii/ascii/types.d.ts.map +1 -0
- package/dist/vendor/mermaid-ascii/ascii/types.js +39 -0
- package/dist/vendor/mermaid-ascii/ascii/validate.d.ts +52 -0
- package/dist/vendor/mermaid-ascii/ascii/validate.d.ts.map +1 -0
- package/dist/vendor/mermaid-ascii/ascii/validate.js +97 -0
- package/dist/vendor/mermaid-ascii/ascii/xychart.d.ts +3 -0
- package/dist/vendor/mermaid-ascii/ascii/xychart.d.ts.map +1 -0
- package/dist/vendor/mermaid-ascii/ascii/xychart.js +719 -0
- package/dist/vendor/mermaid-ascii/class/parser.d.ts +7 -0
- package/dist/vendor/mermaid-ascii/class/parser.d.ts.map +1 -0
- package/dist/vendor/mermaid-ascii/class/parser.js +265 -0
- package/dist/vendor/mermaid-ascii/class/types.d.ts +103 -0
- package/dist/vendor/mermaid-ascii/class/types.d.ts.map +1 -0
- package/dist/vendor/mermaid-ascii/class/types.js +7 -0
- package/dist/vendor/mermaid-ascii/er/parser.d.ts +7 -0
- package/dist/vendor/mermaid-ascii/er/parser.d.ts.map +1 -0
- package/dist/vendor/mermaid-ascii/er/parser.js +162 -0
- package/dist/vendor/mermaid-ascii/er/types.d.ts +77 -0
- package/dist/vendor/mermaid-ascii/er/types.d.ts.map +1 -0
- package/dist/vendor/mermaid-ascii/er/types.js +7 -0
- package/dist/vendor/mermaid-ascii/index.d.ts +2 -0
- package/dist/vendor/mermaid-ascii/index.d.ts.map +1 -0
- package/dist/vendor/mermaid-ascii/index.js +13 -0
- package/dist/vendor/mermaid-ascii/multiline-utils.d.ts +10 -0
- package/dist/vendor/mermaid-ascii/multiline-utils.d.ts.map +1 -0
- package/dist/vendor/mermaid-ascii/multiline-utils.js +29 -0
- package/dist/vendor/mermaid-ascii/parser.d.ts +8 -0
- package/dist/vendor/mermaid-ascii/parser.d.ts.map +1 -0
- package/dist/vendor/mermaid-ascii/parser.js +558 -0
- package/dist/vendor/mermaid-ascii/sequence/parser.d.ts +7 -0
- package/dist/vendor/mermaid-ascii/sequence/parser.d.ts.map +1 -0
- package/dist/vendor/mermaid-ascii/sequence/parser.js +182 -0
- package/dist/vendor/mermaid-ascii/sequence/types.d.ts +131 -0
- package/dist/vendor/mermaid-ascii/sequence/types.d.ts.map +1 -0
- package/dist/vendor/mermaid-ascii/sequence/types.js +7 -0
- package/dist/vendor/mermaid-ascii/text-metrics.d.ts +24 -0
- package/dist/vendor/mermaid-ascii/text-metrics.d.ts.map +1 -0
- package/dist/vendor/mermaid-ascii/text-metrics.js +69 -0
- package/dist/vendor/mermaid-ascii/types.d.ts +115 -0
- package/dist/vendor/mermaid-ascii/types.d.ts.map +1 -0
- package/dist/vendor/mermaid-ascii/types.js +4 -0
- package/dist/vendor/mermaid-ascii/xychart/colors.d.ts +26 -0
- package/dist/vendor/mermaid-ascii/xychart/colors.d.ts.map +1 -0
- package/dist/vendor/mermaid-ascii/xychart/colors.js +145 -0
- package/dist/vendor/mermaid-ascii/xychart/parser.d.ts +7 -0
- package/dist/vendor/mermaid-ascii/xychart/parser.d.ts.map +1 -0
- package/dist/vendor/mermaid-ascii/xychart/parser.js +105 -0
- package/dist/vendor/mermaid-ascii/xychart/types.d.ts +146 -0
- package/dist/vendor/mermaid-ascii/xychart/types.d.ts.map +1 -0
- package/dist/vendor/mermaid-ascii/xychart/types.js +8 -0
- package/dist/virtual-terminal.d.ts +80 -0
- package/dist/virtual-terminal.d.ts.map +1 -0
- package/dist/virtual-terminal.js +284 -0
- package/dist/word-navigation.d.ts +25 -0
- package/dist/word-navigation.d.ts.map +1 -0
- package/dist/word-navigation.js +97 -0
- package/package.json +38 -0
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
import type { CharRole, AsciiTheme, ColorMode } from './types.ts';
|
|
2
|
+
/**
|
|
3
|
+
* Default ASCII theme derived from the SVG renderer's color palette.
|
|
4
|
+
* Uses the same mixing ratios to maintain visual consistency.
|
|
5
|
+
*/
|
|
6
|
+
export declare const DEFAULT_ASCII_THEME: AsciiTheme;
|
|
7
|
+
/**
|
|
8
|
+
* Detect the best color mode for the current environment.
|
|
9
|
+
*
|
|
10
|
+
* Terminal detection order:
|
|
11
|
+
* 1. COLORTERM=truecolor or COLORTERM=24bit → truecolor
|
|
12
|
+
* 2. TERM contains "256color" → ansi256
|
|
13
|
+
* 3. TERM is set and not "dumb" → ansi16
|
|
14
|
+
*
|
|
15
|
+
* Browser: returns 'html' (uses <span> tags with inline styles).
|
|
16
|
+
* Unknown/piped: returns 'none'.
|
|
17
|
+
*/
|
|
18
|
+
export declare function detectColorMode(): ColorMode;
|
|
19
|
+
/**
|
|
20
|
+
* Generate the ANSI escape sequence for a role color.
|
|
21
|
+
*/
|
|
22
|
+
export declare function getAnsiColor(role: CharRole, theme: AsciiTheme, mode: ColorMode): string;
|
|
23
|
+
/**
|
|
24
|
+
* Get the ANSI reset sequence.
|
|
25
|
+
*/
|
|
26
|
+
export declare function getAnsiReset(mode: ColorMode): string;
|
|
27
|
+
/**
|
|
28
|
+
* Wrap a character with ANSI color codes based on its role.
|
|
29
|
+
*/
|
|
30
|
+
export declare function colorizeChar(char: string, role: CharRole | null, theme: AsciiTheme, mode: ColorMode): string;
|
|
31
|
+
/**
|
|
32
|
+
* Colorize an entire line efficiently by grouping consecutive same-role characters.
|
|
33
|
+
* This reduces the number of escape sequences (ANSI) or span tags (HTML) in the output.
|
|
34
|
+
*/
|
|
35
|
+
export declare function colorizeLine(chars: string[], roles: (CharRole | null)[], theme: AsciiTheme, mode: ColorMode): string;
|
|
36
|
+
/**
|
|
37
|
+
* Colorize a text string with a direct hex color.
|
|
38
|
+
* Used by renderers that need per-cell color control (e.g. multi-series xychart).
|
|
39
|
+
* Handles all output modes: ANSI (16/256/truecolor) and HTML.
|
|
40
|
+
*/
|
|
41
|
+
export declare function colorizeText(text: string, hex: string, mode: ColorMode): string;
|
|
42
|
+
//# sourceMappingURL=ansi.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ansi.d.ts","sourceRoot":"","sources":["../../../../src/vendor/mermaid-ascii/ascii/ansi.ts"],"names":[],"mappings":"AAQA,OAAO,KAAK,EAAE,QAAQ,EAAE,UAAU,EAAE,SAAS,EAAE,MAAM,YAAY,CAAA;AAQjE;;;GAGG;AACH,eAAO,MAAM,mBAAmB,EAAE,UAOjC,CAAA;AAMD;;;;;;;;;;GAUG;AACH,wBAAgB,eAAe,IAAI,SAAS,CAsC3C;AAuJD;;GAEG;AACH,wBAAgB,YAAY,CAAC,IAAI,EAAE,QAAQ,EAAE,KAAK,EAAE,UAAU,EAAE,IAAI,EAAE,SAAS,GAAG,MAAM,CAWvF;AAED;;GAEG;AACH,wBAAgB,YAAY,CAAC,IAAI,EAAE,SAAS,GAAG,MAAM,CAEpD;AAED;;GAEG;AACH,wBAAgB,YAAY,CAC1B,IAAI,EAAE,MAAM,EACZ,IAAI,EAAE,QAAQ,GAAG,IAAI,EACrB,KAAK,EAAE,UAAU,EACjB,IAAI,EAAE,SAAS,GACd,MAAM,CAOR;AAED;;;GAGG;AACH,wBAAgB,YAAY,CAC1B,KAAK,EAAE,MAAM,EAAE,EACf,KAAK,EAAE,CAAC,QAAQ,GAAG,IAAI,CAAC,EAAE,EAC1B,KAAK,EAAE,UAAU,EACjB,IAAI,EAAE,SAAS,GACd,MAAM,CA2DR;AAmDD;;;;GAIG;AACH,wBAAgB,YAAY,CAAC,IAAI,EAAE,MAAM,EAAE,GAAG,EAAE,MAAM,EAAE,IAAI,EAAE,SAAS,GAAG,MAAM,CAW/E"}
|
|
@@ -0,0 +1,361 @@
|
|
|
1
|
+
// ============================================================================
|
|
2
|
+
// ASCII renderer — color utilities
|
|
3
|
+
//
|
|
4
|
+
// Provides color output for themed ASCII diagrams.
|
|
5
|
+
// Supports ANSI terminal modes (16/256/truecolor) and HTML <span> tags
|
|
6
|
+
// for browser rendering.
|
|
7
|
+
// ============================================================================
|
|
8
|
+
// ============================================================================
|
|
9
|
+
// Default theme — matches SVG theme colors for consistency
|
|
10
|
+
// ============================================================================
|
|
11
|
+
/**
|
|
12
|
+
* Default ASCII theme derived from the SVG renderer's color palette.
|
|
13
|
+
* Uses the same mixing ratios to maintain visual consistency.
|
|
14
|
+
*/
|
|
15
|
+
export const DEFAULT_ASCII_THEME = {
|
|
16
|
+
fg: '#27272a', // zinc-800 — primary text
|
|
17
|
+
border: '#a1a1aa', // zinc-400 — node borders (12% mix)
|
|
18
|
+
line: '#71717a', // zinc-500 — edge lines (35% mix)
|
|
19
|
+
arrow: '#52525b', // zinc-600 — arrowheads (60% mix)
|
|
20
|
+
corner: '#71717a', // same as line
|
|
21
|
+
junction: '#a1a1aa', // same as border
|
|
22
|
+
};
|
|
23
|
+
// ============================================================================
|
|
24
|
+
// Color mode detection
|
|
25
|
+
// ============================================================================
|
|
26
|
+
/**
|
|
27
|
+
* Detect the best color mode for the current environment.
|
|
28
|
+
*
|
|
29
|
+
* Terminal detection order:
|
|
30
|
+
* 1. COLORTERM=truecolor or COLORTERM=24bit → truecolor
|
|
31
|
+
* 2. TERM contains "256color" → ansi256
|
|
32
|
+
* 3. TERM is set and not "dumb" → ansi16
|
|
33
|
+
*
|
|
34
|
+
* Browser: returns 'html' (uses <span> tags with inline styles).
|
|
35
|
+
* Unknown/piped: returns 'none'.
|
|
36
|
+
*/
|
|
37
|
+
export function detectColorMode() {
|
|
38
|
+
// Check if we're in a Node.js-like environment with process object
|
|
39
|
+
// Use globalThis to safely check for process without TypeScript errors
|
|
40
|
+
const proc = globalThis.process;
|
|
41
|
+
if (proc) {
|
|
42
|
+
// Check if stdout is a TTY (not piped/redirected)
|
|
43
|
+
if (!proc.stdout?.isTTY) {
|
|
44
|
+
return 'none';
|
|
45
|
+
}
|
|
46
|
+
const colorTerm = proc.env?.COLORTERM?.toLowerCase() ?? '';
|
|
47
|
+
const term = proc.env?.TERM?.toLowerCase() ?? '';
|
|
48
|
+
// True color support
|
|
49
|
+
if (colorTerm === 'truecolor' || colorTerm === '24bit') {
|
|
50
|
+
return 'truecolor';
|
|
51
|
+
}
|
|
52
|
+
// 256 color support
|
|
53
|
+
if (term.includes('256color') || term.includes('256')) {
|
|
54
|
+
return 'ansi256';
|
|
55
|
+
}
|
|
56
|
+
// Basic color support
|
|
57
|
+
if (term && term !== 'dumb') {
|
|
58
|
+
return 'ansi16';
|
|
59
|
+
}
|
|
60
|
+
return 'none';
|
|
61
|
+
}
|
|
62
|
+
// No process object → browser environment → use HTML color output
|
|
63
|
+
if (typeof document !== 'undefined') {
|
|
64
|
+
return 'html';
|
|
65
|
+
}
|
|
66
|
+
return 'none';
|
|
67
|
+
}
|
|
68
|
+
// ============================================================================
|
|
69
|
+
// Hex color parsing
|
|
70
|
+
// ============================================================================
|
|
71
|
+
/**
|
|
72
|
+
* Parse a hex color string to RGB values.
|
|
73
|
+
* Supports both 3-char (#RGB) and 6-char (#RRGGBB) formats.
|
|
74
|
+
*/
|
|
75
|
+
function parseHex(hex) {
|
|
76
|
+
const h = hex.replace('#', '');
|
|
77
|
+
if (h.length === 3) {
|
|
78
|
+
return {
|
|
79
|
+
r: parseInt(h[0] + h[0], 16),
|
|
80
|
+
g: parseInt(h[1] + h[1], 16),
|
|
81
|
+
b: parseInt(h[2] + h[2], 16),
|
|
82
|
+
};
|
|
83
|
+
}
|
|
84
|
+
return {
|
|
85
|
+
r: parseInt(h.substring(0, 2), 16),
|
|
86
|
+
g: parseInt(h.substring(2, 4), 16),
|
|
87
|
+
b: parseInt(h.substring(4, 6), 16),
|
|
88
|
+
};
|
|
89
|
+
}
|
|
90
|
+
// ============================================================================
|
|
91
|
+
// ANSI escape code generation
|
|
92
|
+
// ============================================================================
|
|
93
|
+
/** ANSI escape sequence prefix */
|
|
94
|
+
const ESC = '\x1b[';
|
|
95
|
+
/** Reset all attributes */
|
|
96
|
+
const RESET = `${ESC}0m`;
|
|
97
|
+
/**
|
|
98
|
+
* Generate ANSI foreground color escape sequence for 24-bit true color.
|
|
99
|
+
* Format: ESC[38;2;R;G;Bm
|
|
100
|
+
*/
|
|
101
|
+
function truecolorFg(hex) {
|
|
102
|
+
const { r, g, b } = parseHex(hex);
|
|
103
|
+
return `${ESC}38;2;${r};${g};${b}m`;
|
|
104
|
+
}
|
|
105
|
+
/**
|
|
106
|
+
* Find the closest 256-color palette index for an RGB color.
|
|
107
|
+
* The 256-color palette has:
|
|
108
|
+
* - 0-15: Standard colors (duplicates of 16-color)
|
|
109
|
+
* - 16-231: 6x6x6 color cube (216 colors)
|
|
110
|
+
* - 232-255: Grayscale ramp (24 shades)
|
|
111
|
+
*/
|
|
112
|
+
function rgbTo256(r, g, b) {
|
|
113
|
+
// Check if it's close to grayscale
|
|
114
|
+
const avg = (r + g + b) / 3;
|
|
115
|
+
const maxDiff = Math.max(Math.abs(r - avg), Math.abs(g - avg), Math.abs(b - avg));
|
|
116
|
+
if (maxDiff < 10) {
|
|
117
|
+
// Use grayscale ramp (232-255)
|
|
118
|
+
// Each step is ~10.625 (256/24)
|
|
119
|
+
const gray = Math.round((avg / 255) * 23);
|
|
120
|
+
return 232 + Math.min(23, Math.max(0, gray));
|
|
121
|
+
}
|
|
122
|
+
// Use 6x6x6 color cube (16-231)
|
|
123
|
+
// Each channel maps to 0-5: 0, 95, 135, 175, 215, 255
|
|
124
|
+
const toIndex = (v) => {
|
|
125
|
+
if (v < 48)
|
|
126
|
+
return 0;
|
|
127
|
+
if (v < 115)
|
|
128
|
+
return 1;
|
|
129
|
+
return Math.min(5, Math.floor((v - 35) / 40));
|
|
130
|
+
};
|
|
131
|
+
const ri = toIndex(r);
|
|
132
|
+
const gi = toIndex(g);
|
|
133
|
+
const bi = toIndex(b);
|
|
134
|
+
return 16 + (36 * ri) + (6 * gi) + bi;
|
|
135
|
+
}
|
|
136
|
+
/**
|
|
137
|
+
* Generate ANSI foreground color escape sequence for 256-color mode.
|
|
138
|
+
* Format: ESC[38;5;Nm
|
|
139
|
+
*/
|
|
140
|
+
function ansi256Fg(hex) {
|
|
141
|
+
const { r, g, b } = parseHex(hex);
|
|
142
|
+
const index = rgbTo256(r, g, b);
|
|
143
|
+
return `${ESC}38;5;${index}m`;
|
|
144
|
+
}
|
|
145
|
+
/**
|
|
146
|
+
* Map an RGB color to the closest 16-color ANSI code.
|
|
147
|
+
* Returns the foreground color escape sequence.
|
|
148
|
+
*
|
|
149
|
+
* Standard 16 colors:
|
|
150
|
+
* 0=black, 1=red, 2=green, 3=yellow, 4=blue, 5=magenta, 6=cyan, 7=white
|
|
151
|
+
* 8-15 = bright versions
|
|
152
|
+
*/
|
|
153
|
+
function ansi16Fg(hex) {
|
|
154
|
+
const { r, g, b } = parseHex(hex);
|
|
155
|
+
const luma = 0.299 * r + 0.587 * g + 0.114 * b;
|
|
156
|
+
// Determine brightness (use bright colors for better visibility)
|
|
157
|
+
const bright = luma > 100 ? 0 : 60; // 60 = bright variant offset
|
|
158
|
+
// Determine base color based on dominant channel
|
|
159
|
+
let code;
|
|
160
|
+
if (r > 180 && g < 100 && b < 100)
|
|
161
|
+
code = 31; // red
|
|
162
|
+
else if (g > 180 && r < 100 && b < 100)
|
|
163
|
+
code = 32; // green
|
|
164
|
+
else if (r > 150 && g > 150 && b < 100)
|
|
165
|
+
code = 33; // yellow
|
|
166
|
+
else if (b > 180 && r < 100 && g < 100)
|
|
167
|
+
code = 34; // blue
|
|
168
|
+
else if (r > 150 && b > 150 && g < 100)
|
|
169
|
+
code = 35; // magenta
|
|
170
|
+
else if (g > 150 && b > 150 && r < 100)
|
|
171
|
+
code = 36; // cyan
|
|
172
|
+
else if (luma > 200)
|
|
173
|
+
code = 37; // white
|
|
174
|
+
else if (luma < 50)
|
|
175
|
+
code = 30; // black
|
|
176
|
+
else
|
|
177
|
+
code = 37; // default to white for grays
|
|
178
|
+
return `${ESC}${code + bright}m`;
|
|
179
|
+
}
|
|
180
|
+
// ============================================================================
|
|
181
|
+
// HTML color output (for browser rendering)
|
|
182
|
+
// ============================================================================
|
|
183
|
+
/** Escape characters that would break HTML output. */
|
|
184
|
+
function escapeHtml(text) {
|
|
185
|
+
return text.replace(/&/g, '&').replace(/</g, '<').replace(/>/g, '>');
|
|
186
|
+
}
|
|
187
|
+
/** Wrap text in a <span> with an inline color style. */
|
|
188
|
+
function htmlSpan(hex, text) {
|
|
189
|
+
return `<span style="color:${hex}">${escapeHtml(text)}</span>`;
|
|
190
|
+
}
|
|
191
|
+
// ============================================================================
|
|
192
|
+
// Role → color mapping
|
|
193
|
+
// ============================================================================
|
|
194
|
+
/**
|
|
195
|
+
* Get the color for a character role from the theme.
|
|
196
|
+
*/
|
|
197
|
+
function getRoleColor(role, theme) {
|
|
198
|
+
switch (role) {
|
|
199
|
+
case 'text': return theme.fg;
|
|
200
|
+
case 'border': return theme.border;
|
|
201
|
+
case 'line': return theme.line;
|
|
202
|
+
case 'arrow': return theme.arrow;
|
|
203
|
+
case 'corner': return theme.corner ?? theme.line;
|
|
204
|
+
case 'junction': return theme.junction ?? theme.border;
|
|
205
|
+
default: return theme.fg;
|
|
206
|
+
}
|
|
207
|
+
}
|
|
208
|
+
/**
|
|
209
|
+
* Generate the ANSI escape sequence for a role color.
|
|
210
|
+
*/
|
|
211
|
+
export function getAnsiColor(role, theme, mode) {
|
|
212
|
+
if (mode === 'none')
|
|
213
|
+
return '';
|
|
214
|
+
const hex = getRoleColor(role, theme);
|
|
215
|
+
switch (mode) {
|
|
216
|
+
case 'truecolor': return truecolorFg(hex);
|
|
217
|
+
case 'ansi256': return ansi256Fg(hex);
|
|
218
|
+
case 'ansi16': return ansi16Fg(hex);
|
|
219
|
+
default: return '';
|
|
220
|
+
}
|
|
221
|
+
}
|
|
222
|
+
/**
|
|
223
|
+
* Get the ANSI reset sequence.
|
|
224
|
+
*/
|
|
225
|
+
export function getAnsiReset(mode) {
|
|
226
|
+
return mode === 'none' ? '' : RESET;
|
|
227
|
+
}
|
|
228
|
+
/**
|
|
229
|
+
* Wrap a character with ANSI color codes based on its role.
|
|
230
|
+
*/
|
|
231
|
+
export function colorizeChar(char, role, theme, mode) {
|
|
232
|
+
if (mode === 'none' || role === null || char === ' ') {
|
|
233
|
+
return char;
|
|
234
|
+
}
|
|
235
|
+
const colorCode = getAnsiColor(role, theme, mode);
|
|
236
|
+
return `${colorCode}${char}${RESET}`;
|
|
237
|
+
}
|
|
238
|
+
/**
|
|
239
|
+
* Colorize an entire line efficiently by grouping consecutive same-role characters.
|
|
240
|
+
* This reduces the number of escape sequences (ANSI) or span tags (HTML) in the output.
|
|
241
|
+
*/
|
|
242
|
+
export function colorizeLine(chars, roles, theme, mode) {
|
|
243
|
+
if (mode === 'none') {
|
|
244
|
+
return chars.join('');
|
|
245
|
+
}
|
|
246
|
+
if (mode === 'html') {
|
|
247
|
+
return colorizeLineHtml(chars, roles, theme);
|
|
248
|
+
}
|
|
249
|
+
let result = '';
|
|
250
|
+
let currentRole = null;
|
|
251
|
+
let buffer = '';
|
|
252
|
+
for (let i = 0; i < chars.length; i++) {
|
|
253
|
+
const char = chars[i];
|
|
254
|
+
const role = roles[i] ?? null;
|
|
255
|
+
// Whitespace doesn't need coloring
|
|
256
|
+
if (char === ' ') {
|
|
257
|
+
// Flush any buffered characters (with or without color)
|
|
258
|
+
if (buffer.length > 0) {
|
|
259
|
+
if (currentRole !== null) {
|
|
260
|
+
result += getAnsiColor(currentRole, theme, mode) + buffer + RESET;
|
|
261
|
+
}
|
|
262
|
+
else {
|
|
263
|
+
result += buffer;
|
|
264
|
+
}
|
|
265
|
+
buffer = '';
|
|
266
|
+
currentRole = null;
|
|
267
|
+
}
|
|
268
|
+
result += char;
|
|
269
|
+
continue;
|
|
270
|
+
}
|
|
271
|
+
// Same role as previous — accumulate
|
|
272
|
+
if (role === currentRole) {
|
|
273
|
+
buffer += char;
|
|
274
|
+
continue;
|
|
275
|
+
}
|
|
276
|
+
// Role changed — flush buffer (with or without color) and start new
|
|
277
|
+
if (buffer.length > 0) {
|
|
278
|
+
if (currentRole !== null) {
|
|
279
|
+
result += getAnsiColor(currentRole, theme, mode) + buffer + RESET;
|
|
280
|
+
}
|
|
281
|
+
else {
|
|
282
|
+
result += buffer;
|
|
283
|
+
}
|
|
284
|
+
}
|
|
285
|
+
buffer = char;
|
|
286
|
+
currentRole = role;
|
|
287
|
+
}
|
|
288
|
+
// Flush remaining buffer
|
|
289
|
+
if (buffer.length > 0 && currentRole !== null) {
|
|
290
|
+
result += getAnsiColor(currentRole, theme, mode) + buffer + RESET;
|
|
291
|
+
}
|
|
292
|
+
else if (buffer.length > 0) {
|
|
293
|
+
result += buffer;
|
|
294
|
+
}
|
|
295
|
+
return result;
|
|
296
|
+
}
|
|
297
|
+
/**
|
|
298
|
+
* HTML-specific line colorization.
|
|
299
|
+
* Groups consecutive same-role characters into <span> tags with inline color styles.
|
|
300
|
+
* Whitespace is emitted bare (no wrapping) to keep output compact.
|
|
301
|
+
*/
|
|
302
|
+
function colorizeLineHtml(chars, roles, theme) {
|
|
303
|
+
let result = '';
|
|
304
|
+
let currentRole = null;
|
|
305
|
+
let buffer = '';
|
|
306
|
+
const flush = () => {
|
|
307
|
+
if (buffer.length === 0)
|
|
308
|
+
return;
|
|
309
|
+
if (currentRole !== null) {
|
|
310
|
+
result += htmlSpan(getRoleColor(currentRole, theme), buffer);
|
|
311
|
+
}
|
|
312
|
+
else {
|
|
313
|
+
result += escapeHtml(buffer);
|
|
314
|
+
}
|
|
315
|
+
buffer = '';
|
|
316
|
+
currentRole = null;
|
|
317
|
+
};
|
|
318
|
+
for (let i = 0; i < chars.length; i++) {
|
|
319
|
+
const char = chars[i];
|
|
320
|
+
const role = roles[i] ?? null;
|
|
321
|
+
if (char === ' ') {
|
|
322
|
+
flush();
|
|
323
|
+
result += ' ';
|
|
324
|
+
continue;
|
|
325
|
+
}
|
|
326
|
+
if (role === currentRole) {
|
|
327
|
+
buffer += char;
|
|
328
|
+
continue;
|
|
329
|
+
}
|
|
330
|
+
flush();
|
|
331
|
+
buffer = char;
|
|
332
|
+
currentRole = role;
|
|
333
|
+
}
|
|
334
|
+
flush();
|
|
335
|
+
return result;
|
|
336
|
+
}
|
|
337
|
+
/**
|
|
338
|
+
* Colorize a text string with a direct hex color.
|
|
339
|
+
* Used by renderers that need per-cell color control (e.g. multi-series xychart).
|
|
340
|
+
* Handles all output modes: ANSI (16/256/truecolor) and HTML.
|
|
341
|
+
*/
|
|
342
|
+
export function colorizeText(text, hex, mode) {
|
|
343
|
+
if (mode === 'none' || text.length === 0)
|
|
344
|
+
return text;
|
|
345
|
+
if (mode === 'html')
|
|
346
|
+
return htmlSpan(hex, text);
|
|
347
|
+
let code;
|
|
348
|
+
switch (mode) {
|
|
349
|
+
case 'truecolor':
|
|
350
|
+
code = truecolorFg(hex);
|
|
351
|
+
break;
|
|
352
|
+
case 'ansi256':
|
|
353
|
+
code = ansi256Fg(hex);
|
|
354
|
+
break;
|
|
355
|
+
case 'ansi16':
|
|
356
|
+
code = ansi16Fg(hex);
|
|
357
|
+
break;
|
|
358
|
+
default: return text;
|
|
359
|
+
}
|
|
360
|
+
return `${code}${text}${RESET}`;
|
|
361
|
+
}
|
|
@@ -0,0 +1,90 @@
|
|
|
1
|
+
import type { Canvas, DrawingCoord, RoleCanvas, CharRole, AsciiTheme, ColorMode } from './types.ts';
|
|
2
|
+
/**
|
|
3
|
+
* Create a blank canvas filled with spaces.
|
|
4
|
+
* Dimensions are inclusive: mkCanvas(3, 2) creates a 4x3 grid (indices 0..3, 0..2).
|
|
5
|
+
*/
|
|
6
|
+
export declare function mkCanvas(x: number, y: number): Canvas;
|
|
7
|
+
/** Create a blank canvas with the same dimensions as the given canvas. */
|
|
8
|
+
export declare function copyCanvas(source: Canvas): Canvas;
|
|
9
|
+
/**
|
|
10
|
+
* Create a blank role canvas filled with nulls.
|
|
11
|
+
* Same dimensions as mkCanvas — column-major, roleCanvas[x][y].
|
|
12
|
+
*/
|
|
13
|
+
export declare function mkRoleCanvas(x: number, y: number): RoleCanvas;
|
|
14
|
+
/** Create a blank role canvas with the same dimensions as the given role canvas. */
|
|
15
|
+
export declare function copyRoleCanvas(source: RoleCanvas): RoleCanvas;
|
|
16
|
+
/**
|
|
17
|
+
* Grow the role canvas to fit at least (newX, newY), preserving existing roles.
|
|
18
|
+
* Mutates the role canvas in place and returns it.
|
|
19
|
+
*/
|
|
20
|
+
export declare function increaseRoleCanvasSize(roleCanvas: RoleCanvas, newX: number, newY: number): RoleCanvas;
|
|
21
|
+
/**
|
|
22
|
+
* Set a role at a specific coordinate.
|
|
23
|
+
* Expands the role canvas if necessary.
|
|
24
|
+
*/
|
|
25
|
+
export declare function setRole(roleCanvas: RoleCanvas, x: number, y: number, role: CharRole): void;
|
|
26
|
+
/**
|
|
27
|
+
* Merge role canvases — same logic as mergeCanvases but for roles.
|
|
28
|
+
* Non-null roles in overlays overwrite null roles in base.
|
|
29
|
+
*/
|
|
30
|
+
export declare function mergeRoleCanvases(base: RoleCanvas, offset: DrawingCoord, ...overlays: RoleCanvas[]): RoleCanvas;
|
|
31
|
+
/** Returns [maxX, maxY] — the highest valid indices in each dimension. */
|
|
32
|
+
export declare function getCanvasSize(canvas: Canvas): [number, number];
|
|
33
|
+
/**
|
|
34
|
+
* Grow the canvas to fit at least (newX, newY), preserving existing content.
|
|
35
|
+
* Mutates the canvas in place and returns it.
|
|
36
|
+
*/
|
|
37
|
+
export declare function increaseSize(canvas: Canvas, newX: number, newY: number): Canvas;
|
|
38
|
+
export declare function isJunctionChar(c: string): boolean;
|
|
39
|
+
export declare function mergeJunctions(c1: string, c2: string): string;
|
|
40
|
+
/**
|
|
41
|
+
* Merge overlay canvases onto a base canvas at the given offset.
|
|
42
|
+
* Non-space characters in overlays overwrite the base.
|
|
43
|
+
* When both characters are Unicode junction chars, they're merged intelligently.
|
|
44
|
+
*/
|
|
45
|
+
export declare function mergeCanvases(base: Canvas, offset: DrawingCoord, useAscii: boolean, ...overlays: Canvas[]): Canvas;
|
|
46
|
+
/** Options for converting canvas to string with optional coloring. */
|
|
47
|
+
export interface CanvasToStringOptions {
|
|
48
|
+
/** Role canvas for applying colors. If not provided, output is plain text. */
|
|
49
|
+
roleCanvas?: RoleCanvas;
|
|
50
|
+
/** Color mode for terminal output. Default: 'none' */
|
|
51
|
+
colorMode?: ColorMode;
|
|
52
|
+
/** Theme colors for ASCII output. Uses default theme if not provided. */
|
|
53
|
+
theme?: AsciiTheme;
|
|
54
|
+
}
|
|
55
|
+
/**
|
|
56
|
+
* Convert the canvas to a multi-line string (row by row, left to right).
|
|
57
|
+
* Optionally applies ANSI color codes based on character roles.
|
|
58
|
+
*/
|
|
59
|
+
export declare function canvasToString(canvas: Canvas, options?: CanvasToStringOptions): string;
|
|
60
|
+
/**
|
|
61
|
+
* Flip the canvas vertically (mirror across the horizontal center).
|
|
62
|
+
* Reverses row order within each column and remaps directional characters
|
|
63
|
+
* (arrows, corners, junctions) so they point the correct way after flip.
|
|
64
|
+
*
|
|
65
|
+
* Used to transform a TD-rendered canvas into BT output.
|
|
66
|
+
* Mutates the canvas in place and returns it.
|
|
67
|
+
*/
|
|
68
|
+
export declare function flipCanvasVertically(canvas: Canvas): Canvas;
|
|
69
|
+
/**
|
|
70
|
+
* Flip the role canvas vertically to match flipCanvasVertically.
|
|
71
|
+
* Mutates the role canvas in place and returns it.
|
|
72
|
+
*/
|
|
73
|
+
export declare function flipRoleCanvasVertically(roleCanvas: RoleCanvas): RoleCanvas;
|
|
74
|
+
/**
|
|
75
|
+
* Draw text string onto the canvas starting at the given coordinate.
|
|
76
|
+
* By default, preserves existing non-space characters (labels don't overwrite each other).
|
|
77
|
+
* Set forceOverwrite=true to always overwrite (for box content).
|
|
78
|
+
*/
|
|
79
|
+
export declare function drawText(canvas: Canvas, start: DrawingCoord, text: string, forceOverwrite?: boolean): void;
|
|
80
|
+
/**
|
|
81
|
+
* Set the canvas size to fit all grid columns and rows.
|
|
82
|
+
* Called after layout to ensure the canvas covers the full drawing area.
|
|
83
|
+
*/
|
|
84
|
+
export declare function setCanvasSizeToGrid(canvas: Canvas, columnWidth: Map<number, number>, rowHeight: Map<number, number>): void;
|
|
85
|
+
/**
|
|
86
|
+
* Set the role canvas size to match the grid dimensions.
|
|
87
|
+
* Should be called alongside setCanvasSizeToGrid.
|
|
88
|
+
*/
|
|
89
|
+
export declare function setRoleCanvasSizeToGrid(roleCanvas: RoleCanvas, columnWidth: Map<number, number>, rowHeight: Map<number, number>): void;
|
|
90
|
+
//# sourceMappingURL=canvas.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"canvas.d.ts","sourceRoot":"","sources":["../../../../src/vendor/mermaid-ascii/ascii/canvas.ts"],"names":[],"mappings":"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"}
|