linecraft 0.2.3 → 0.2.5
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 +84 -7
- package/lib/components/code-debug.d.ts +7 -1
- package/lib/components/code-debug.d.ts.map +1 -1
- package/lib/components/code-debug.js +261 -232
- package/lib/components/code-debug.js.map +1 -1
- package/lib/components/code-debug.test.d.ts +2 -0
- package/lib/components/code-debug.test.d.ts.map +1 -0
- package/lib/components/code-debug.test.js +253 -0
- package/lib/components/code-debug.test.js.map +1 -0
- package/lib/components/progress-bar-grid.d.ts.map +1 -1
- package/lib/components/progress-bar-grid.js +2 -1
- package/lib/components/progress-bar-grid.js.map +1 -1
- package/lib/components/progress-bar-grid.test.js +8 -7
- package/lib/components/progress-bar-grid.test.js.map +1 -1
- package/lib/components/prompt.d.ts.map +1 -1
- package/lib/components/prompt.js +2 -1
- package/lib/components/prompt.js.map +1 -1
- package/lib/components/segments.d.ts.map +1 -1
- package/lib/components/segments.js +0 -7
- package/lib/components/segments.js.map +1 -1
- package/lib/components/style.test.js +12 -11
- package/lib/components/style.test.js.map +1 -1
- package/lib/components/styled.d.ts +1 -0
- package/lib/components/styled.d.ts.map +1 -1
- package/lib/components/styled.js +38 -8
- package/lib/components/styled.js.map +1 -1
- package/lib/components/styled.test.js +12 -11
- package/lib/components/styled.test.js.map +1 -1
- package/lib/layout/grid.d.ts +3 -2
- package/lib/layout/grid.d.ts.map +1 -1
- package/lib/layout/grid.js +166 -81
- package/lib/layout/grid.js.map +1 -1
- package/lib/layout/grid.test.js +70 -3
- package/lib/layout/grid.test.js.map +1 -1
- package/lib/native/diff.d.ts.map +1 -1
- package/lib/native/diff.js +2 -1
- package/lib/native/diff.js.map +1 -1
- package/lib/native/diff.test.js.map +1 -1
- package/lib/native/region-old.js +4 -4
- package/lib/native/region-old.js.map +1 -1
- package/lib/native/region-renderer.d.ts +3 -2
- package/lib/native/region-renderer.d.ts.map +1 -1
- package/lib/native/region-renderer.js +39 -9
- package/lib/native/region-renderer.js.map +1 -1
- package/lib/native/region-simple.d.ts.map +1 -1
- package/lib/native/region-simple.js +1 -1
- package/lib/native/region-simple.js.map +1 -1
- package/lib/region.d.ts +3 -3
- package/lib/region.d.ts.map +1 -1
- package/lib/region.js +15 -66
- package/lib/region.js.map +1 -1
- package/lib/types.d.ts +1 -0
- package/lib/types.d.ts.map +1 -1
- package/lib/utils/colors.d.ts.map +1 -1
- package/lib/utils/colors.js +3 -0
- package/lib/utils/colors.js.map +1 -1
- package/lib/utils/cursor-position.d.ts.map +1 -1
- package/lib/utils/cursor-position.js +4 -15
- package/lib/utils/cursor-position.js.map +1 -1
- package/lib/utils/prompt.js +3 -3
- package/lib/utils/prompt.js.map +1 -1
- package/lib/utils/terminal-theme.d.ts +5 -4
- package/lib/utils/terminal-theme.d.ts.map +1 -1
- package/lib/utils/terminal-theme.js +7 -6
- package/lib/utils/terminal-theme.js.map +1 -1
- package/lib/utils/text.d.ts +91 -2
- package/lib/utils/text.d.ts.map +1 -1
- package/lib/utils/text.js +765 -72
- package/lib/utils/text.js.map +1 -1
- package/lib/utils/text.test.d.ts +2 -0
- package/lib/utils/text.test.d.ts.map +1 -0
- package/lib/utils/text.test.js +237 -0
- package/lib/utils/text.test.js.map +1 -0
- package/lib/utils/wait-for-spacebar.d.ts.map +1 -1
- package/lib/utils/wait-for-spacebar.js +2 -9
- package/lib/utils/wait-for-spacebar.js.map +1 -1
- package/package.json +7 -3
|
@@ -0,0 +1,253 @@
|
|
|
1
|
+
// Unit tests for code-debug component
|
|
2
|
+
import { describe, it, expect, beforeEach } from 'vitest';
|
|
3
|
+
import { CodeDebug } from './code-debug.js';
|
|
4
|
+
import { TerminalRegion } from '../region.js';
|
|
5
|
+
import { callComponent } from '../component.js';
|
|
6
|
+
import { stripAnsi } from '../utils/text.js';
|
|
7
|
+
describe('code-debug component', () => {
|
|
8
|
+
let region;
|
|
9
|
+
beforeEach(() => {
|
|
10
|
+
region = new TerminalRegion({ disableRendering: true, width: 100 });
|
|
11
|
+
});
|
|
12
|
+
function render(component, width = 100) {
|
|
13
|
+
const ctx = {
|
|
14
|
+
availableWidth: width,
|
|
15
|
+
region: region,
|
|
16
|
+
columnIndex: 0,
|
|
17
|
+
rowIndex: 0,
|
|
18
|
+
};
|
|
19
|
+
const result = callComponent(component, ctx);
|
|
20
|
+
if (Array.isArray(result)) {
|
|
21
|
+
return result;
|
|
22
|
+
}
|
|
23
|
+
else if (result) {
|
|
24
|
+
return [result];
|
|
25
|
+
}
|
|
26
|
+
return [];
|
|
27
|
+
}
|
|
28
|
+
describe('truncated code with ellipsis', () => {
|
|
29
|
+
it('should correctly point to .v at columns 77-78 when code is truncated with start ellipsis', () => {
|
|
30
|
+
// This is the extend-chaining example that's failing
|
|
31
|
+
const errorLine = ' .ma:extend(.a,.b,.c,.d,.e,.f,.g,.h,.i,.j,.k,.l,.m,.n,.o,.p,.q,.r,.s,.t,.u,.v) {};';
|
|
32
|
+
const startColumn = 77; // Should point to '.'
|
|
33
|
+
const endColumn = 78; // Should point to 'v'
|
|
34
|
+
// Verify original columns
|
|
35
|
+
expect(errorLine[startColumn - 1]).toBe('.');
|
|
36
|
+
expect(errorLine[endColumn - 1]).toBe('v');
|
|
37
|
+
// Test with width that causes truncation (80 chars should truncate this 83-char line)
|
|
38
|
+
const width = 80;
|
|
39
|
+
const component = CodeDebug({
|
|
40
|
+
startLine: 77,
|
|
41
|
+
startColumn,
|
|
42
|
+
endColumn,
|
|
43
|
+
errorLine,
|
|
44
|
+
message: 'Extend target ".v" not accessible',
|
|
45
|
+
shortMessage: 'extend target not accessible',
|
|
46
|
+
filePath: 'test.less',
|
|
47
|
+
fullPath: '/test/test.less',
|
|
48
|
+
baseDir: '/test',
|
|
49
|
+
type: 'warning',
|
|
50
|
+
});
|
|
51
|
+
const output = render(component, width);
|
|
52
|
+
const outputText = output.join('\n');
|
|
53
|
+
const outputTextPlain = stripAnsi(outputText);
|
|
54
|
+
// Find the error line (line with │ and the code) - format: "77 │ ..."
|
|
55
|
+
const errorLineRegex = /^\s*\d+\s*│\s*(.+)$/m;
|
|
56
|
+
const errorLineMatch = outputTextPlain.match(errorLineRegex);
|
|
57
|
+
expect(errorLineMatch, `Error line should be found in:\n${outputTextPlain}`).toBeTruthy();
|
|
58
|
+
const renderedErrorLinePlain = errorLineMatch[1];
|
|
59
|
+
// Find the indicator line (line with │ and the underline) - format: " │ ..."
|
|
60
|
+
// Look for lines with indicator characters (┖, ┬, ┚, ╿)
|
|
61
|
+
const lines = outputTextPlain.split('\n');
|
|
62
|
+
let indicatorLinePlain = null;
|
|
63
|
+
let fullIndicatorLine = null;
|
|
64
|
+
for (const line of lines) {
|
|
65
|
+
if (line.includes('│') && (line.includes('┖') || line.includes('┬') || line.includes('┚') || line.includes('╿'))) {
|
|
66
|
+
fullIndicatorLine = line;
|
|
67
|
+
const match = line.match(/│ (.*)$/);
|
|
68
|
+
if (match) {
|
|
69
|
+
indicatorLinePlain = match[1];
|
|
70
|
+
break;
|
|
71
|
+
}
|
|
72
|
+
}
|
|
73
|
+
}
|
|
74
|
+
expect(indicatorLinePlain, `Indicator line should be found in:\n${outputTextPlain}`).toBeTruthy();
|
|
75
|
+
// The indicator should point to .v in the rendered error line
|
|
76
|
+
// Find where .v appears in the rendered error line
|
|
77
|
+
const dotVIndex = renderedErrorLinePlain.indexOf('.v');
|
|
78
|
+
expect(dotVIndex, `.v should be visible in rendered line: "${renderedErrorLinePlain}"`).toBeGreaterThanOrEqual(0);
|
|
79
|
+
// The indicator (┖, ┬, ┚, or ╿) should be positioned at or near .v
|
|
80
|
+
// Find the position of the T-bar (┬) or bracket (┖/┚) in the indicator line
|
|
81
|
+
const tBarIndex = indicatorLinePlain.indexOf('┬');
|
|
82
|
+
const bracketStart = indicatorLinePlain.indexOf('┖');
|
|
83
|
+
const bracketEnd = indicatorLinePlain.indexOf('┚');
|
|
84
|
+
const indicatorPos = tBarIndex >= 0 ? tBarIndex : (bracketStart >= 0 ? bracketStart : bracketEnd);
|
|
85
|
+
expect(indicatorPos, `Indicator should be found in: "${indicatorLinePlain}"`).toBeGreaterThanOrEqual(0);
|
|
86
|
+
// Account for ellipsis at start if present
|
|
87
|
+
// renderedErrorLinePlain includes ellipsis if present
|
|
88
|
+
const expectedIndicatorPos = dotVIndex;
|
|
89
|
+
// The indicator should be at or near where .v is (within 2 characters)
|
|
90
|
+
expect(Math.abs(indicatorPos - expectedIndicatorPos), `Indicator at ${indicatorPos} should be near .v at ${expectedIndicatorPos} in error line "${renderedErrorLinePlain}" and indicator "${indicatorLinePlain}"`).toBeLessThanOrEqual(2);
|
|
91
|
+
});
|
|
92
|
+
});
|
|
93
|
+
describe('short message alignment', () => {
|
|
94
|
+
it('should correctly align left-placed short message (message on right side)', () => {
|
|
95
|
+
// Left placement means message appears to the right of the code
|
|
96
|
+
const component = CodeDebug({
|
|
97
|
+
startLine: 50,
|
|
98
|
+
startColumn: 16,
|
|
99
|
+
endColumn: 35,
|
|
100
|
+
errorLine: 'const result = veryLongFunctionName(withManyParameters, andMoreParameters)',
|
|
101
|
+
message: 'Line too long',
|
|
102
|
+
shortMessage: 'line too long',
|
|
103
|
+
shortMessagePlacement: 'left',
|
|
104
|
+
filePath: 'test.ts',
|
|
105
|
+
fullPath: '/test/test.ts',
|
|
106
|
+
baseDir: '/test',
|
|
107
|
+
type: 'error',
|
|
108
|
+
});
|
|
109
|
+
const output = render(component, 100);
|
|
110
|
+
// Find the short message line (should have connector ──╯ pointing left)
|
|
111
|
+
const shortMessageLineRegex = /^\s*│\s*(.+)$/m;
|
|
112
|
+
const lines = output.join('\n').split('\n');
|
|
113
|
+
let shortMessageLine = null;
|
|
114
|
+
for (const line of lines) {
|
|
115
|
+
if (line.includes('──╯') || line.includes('line too long')) {
|
|
116
|
+
shortMessageLine = line;
|
|
117
|
+
break;
|
|
118
|
+
}
|
|
119
|
+
}
|
|
120
|
+
expect(shortMessageLine).toBeTruthy();
|
|
121
|
+
const shortMessageLinePlain = stripAnsi(shortMessageLine);
|
|
122
|
+
// Find the indicator line to get the T-bar position
|
|
123
|
+
const indicatorLineRegex = /^\s*│\s*(.+)$/m;
|
|
124
|
+
let indicatorLine = null;
|
|
125
|
+
for (const line of lines) {
|
|
126
|
+
if (line.includes('┬') || line.includes('┖')) {
|
|
127
|
+
indicatorLine = line;
|
|
128
|
+
break;
|
|
129
|
+
}
|
|
130
|
+
}
|
|
131
|
+
expect(indicatorLine).toBeTruthy();
|
|
132
|
+
const indicatorLinePlain = stripAnsi(indicatorLine);
|
|
133
|
+
// Find T-bar position in indicator line
|
|
134
|
+
const tBarPos = indicatorLinePlain.indexOf('┬');
|
|
135
|
+
expect(tBarPos).toBeGreaterThanOrEqual(0);
|
|
136
|
+
// Find connector end (╯) position in short message line
|
|
137
|
+
const connectorEndPos = shortMessageLinePlain.indexOf('╯');
|
|
138
|
+
expect(connectorEndPos).toBeGreaterThanOrEqual(0);
|
|
139
|
+
// The connector end (╯) should be at the T-bar position (exactly)
|
|
140
|
+
// Account for the │ prefix (lineNumWidth + 3)
|
|
141
|
+
const lineNumWidth = 2; // "50" is 2 chars
|
|
142
|
+
const prefixWidth = lineNumWidth + 3; // lineNumWidth + space + │ + space
|
|
143
|
+
const tBarPosInLine = tBarPos + prefixWidth;
|
|
144
|
+
const connectorEndPosInLine = connectorEndPos + prefixWidth;
|
|
145
|
+
// Should be exactly aligned (within 1 char tolerance)
|
|
146
|
+
expect(Math.abs(connectorEndPosInLine - tBarPosInLine), `Left-placed message: T-bar at ${tBarPosInLine}, connector end at ${connectorEndPosInLine}, difference: ${Math.abs(connectorEndPosInLine - tBarPosInLine)}`).toBeLessThanOrEqual(1);
|
|
147
|
+
});
|
|
148
|
+
it('should correctly align right-placed short message (message on left side)', () => {
|
|
149
|
+
// Right placement means message appears to the left of the code
|
|
150
|
+
const component = CodeDebug({
|
|
151
|
+
startLine: 12,
|
|
152
|
+
startColumn: 12,
|
|
153
|
+
endColumn: 16,
|
|
154
|
+
errorLine: ' return x + y + z;',
|
|
155
|
+
message: 'Type error: cannot add string and number',
|
|
156
|
+
shortMessage: 'string + number',
|
|
157
|
+
shortMessagePlacement: 'right',
|
|
158
|
+
filePath: 'test.ts',
|
|
159
|
+
fullPath: '/test/test.ts',
|
|
160
|
+
baseDir: '/test',
|
|
161
|
+
type: 'error',
|
|
162
|
+
});
|
|
163
|
+
const output = render(component, 100);
|
|
164
|
+
// Find the short message line (should have connector ╰── pointing right)
|
|
165
|
+
const lines = output.join('\n').split('\n');
|
|
166
|
+
let shortMessageLine = null;
|
|
167
|
+
for (const line of lines) {
|
|
168
|
+
if (line.includes('╰──') || line.includes('string + number')) {
|
|
169
|
+
shortMessageLine = line;
|
|
170
|
+
break;
|
|
171
|
+
}
|
|
172
|
+
}
|
|
173
|
+
expect(shortMessageLine).toBeTruthy();
|
|
174
|
+
const shortMessageLinePlain = stripAnsi(shortMessageLine);
|
|
175
|
+
// Find the indicator line to get the T-bar position
|
|
176
|
+
let indicatorLine = null;
|
|
177
|
+
for (const line of lines) {
|
|
178
|
+
if (line.includes('┬') || line.includes('┖')) {
|
|
179
|
+
indicatorLine = line;
|
|
180
|
+
break;
|
|
181
|
+
}
|
|
182
|
+
}
|
|
183
|
+
expect(indicatorLine).toBeTruthy();
|
|
184
|
+
const indicatorLinePlain = stripAnsi(indicatorLine);
|
|
185
|
+
// Find T-bar position in indicator line
|
|
186
|
+
const tBarPos = indicatorLinePlain.indexOf('┬');
|
|
187
|
+
expect(tBarPos).toBeGreaterThanOrEqual(0);
|
|
188
|
+
// Find connector start (╰) position in short message line
|
|
189
|
+
const connectorStartPos = shortMessageLinePlain.indexOf('╰');
|
|
190
|
+
expect(connectorStartPos).toBeGreaterThanOrEqual(0);
|
|
191
|
+
// The connector "╰── " has the last dash at position 3 from start
|
|
192
|
+
// So connectorStartPos + 3 should be at T-bar position
|
|
193
|
+
const lineNumWidth = 2; // "12" is 2 chars
|
|
194
|
+
const prefixWidth = lineNumWidth + 3; // lineNumWidth + space + │ + space
|
|
195
|
+
const tBarPosInLine = tBarPos + prefixWidth;
|
|
196
|
+
const connectorLastDashPosInLine = connectorStartPos + prefixWidth + 3;
|
|
197
|
+
// Should be exactly aligned (within 1 char tolerance)
|
|
198
|
+
expect(Math.abs(connectorLastDashPosInLine - tBarPosInLine), `Right-placed message: T-bar at ${tBarPosInLine}, connector last dash at ${connectorLastDashPosInLine}, difference: ${Math.abs(connectorLastDashPosInLine - tBarPosInLine)}`).toBeLessThanOrEqual(1);
|
|
199
|
+
});
|
|
200
|
+
});
|
|
201
|
+
describe('hyperlink preservation', () => {
|
|
202
|
+
it('should preserve OSC 8 hyperlink on truncated file path', () => {
|
|
203
|
+
// When a file path with a hyperlink is truncated, the entire visible portion should remain clickable
|
|
204
|
+
const component = CodeDebug({
|
|
205
|
+
startLine: 77,
|
|
206
|
+
startColumn: 77,
|
|
207
|
+
endColumn: 78,
|
|
208
|
+
errorLine: ' .ma:extend(.a,.b,.c,.d,.e,.f,.g,.h,.i,.j,.k,.l,.m,.n,.o,.p,.q,.r,.s,.t,.u,.v) {};',
|
|
209
|
+
message: 'Extend target ".v" not accessible',
|
|
210
|
+
shortMessage: 'extend target not accessible',
|
|
211
|
+
filePath: '../less.js/packages/test-data/tests-unit/extend-chaining/extend-chaining.less',
|
|
212
|
+
fullPath: '/project/../less.js/packages/test-data/tests-unit/extend-chaining/extend-chaining.less',
|
|
213
|
+
baseDir: '/project',
|
|
214
|
+
type: 'warning',
|
|
215
|
+
});
|
|
216
|
+
const output = render(component, 80); // Narrow width to force truncation
|
|
217
|
+
const outputText = output.join('\n');
|
|
218
|
+
const outputTextPlain = stripAnsi(outputText);
|
|
219
|
+
// Find the location line (has the file path with hyperlink)
|
|
220
|
+
// Format: " ╭─[path:line:column]"
|
|
221
|
+
const locationLineMatch = outputTextPlain.match(/╭─\[(.+?)\]/);
|
|
222
|
+
expect(locationLineMatch, `Location line should be found in:\n${outputTextPlain.substring(0, 200)}`).toBeTruthy();
|
|
223
|
+
// Get the actual line with ANSI codes for hyperlink checking
|
|
224
|
+
const locationLineWithAnsi = output.join('\n').split('\n').find(line => stripAnsi(line).includes('╭─['));
|
|
225
|
+
expect(locationLineWithAnsi, 'Location line with ANSI should be found').toBeTruthy();
|
|
226
|
+
const locationLine = locationLineWithAnsi;
|
|
227
|
+
// Check that the entire visible path (not just ellipsis) has the OSC 8 hyperlink
|
|
228
|
+
// OSC 8 format: \x1b]8;;<url>\x1b\\<text>\x1b]8;;\x1b\\
|
|
229
|
+
// The hyperlink should wrap the entire visible text, not just the ellipsis
|
|
230
|
+
const hasOsc8Start = locationLine.includes('\x1b]8;;');
|
|
231
|
+
expect(hasOsc8Start, 'Location line should contain OSC 8 hyperlink start').toBe(true);
|
|
232
|
+
// Extract the visible path portion (after ellipsis if present)
|
|
233
|
+
const pathMatch = locationLine.match(/\[(.+?)\]/);
|
|
234
|
+
expect(pathMatch, 'Path should be found in location line').toBeTruthy();
|
|
235
|
+
const visiblePath = pathMatch[1];
|
|
236
|
+
const visiblePathPlain = stripAnsi(visiblePath);
|
|
237
|
+
// If truncated with ellipsis, check that text after ellipsis is still in the link
|
|
238
|
+
if (visiblePathPlain.startsWith('...')) {
|
|
239
|
+
// Find where the ellipsis ends and the actual path text begins
|
|
240
|
+
const pathAfterEllipsis = visiblePathPlain.substring(3);
|
|
241
|
+
// The path after ellipsis should still be part of the hyperlink
|
|
242
|
+
// We can't easily test this without parsing OSC 8, but we can check that
|
|
243
|
+
// the hyperlink sequence appears before the ellipsis and continues after
|
|
244
|
+
const ellipsisIndex = locationLine.indexOf('...');
|
|
245
|
+
const pathAfterEllipsisIndex = locationLine.indexOf(pathAfterEllipsis.substring(0, Math.min(10, pathAfterEllipsis.length)));
|
|
246
|
+
// There should be an OSC 8 start before the ellipsis
|
|
247
|
+
const osc8BeforeEllipsis = locationLine.substring(0, ellipsisIndex).includes('\x1b]8;;');
|
|
248
|
+
expect(osc8BeforeEllipsis || pathAfterEllipsisIndex > ellipsisIndex, 'Hyperlink should start before ellipsis and continue on the visible path text').toBe(true);
|
|
249
|
+
}
|
|
250
|
+
});
|
|
251
|
+
});
|
|
252
|
+
});
|
|
253
|
+
//# sourceMappingURL=code-debug.test.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"code-debug.test.js","sourceRoot":"","sources":["../../src/components/code-debug.test.ts"],"names":[],"mappings":"AAAA,sCAAsC;AAEtC,OAAO,EAAE,QAAQ,EAAE,EAAE,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,QAAQ,CAAC;AAC1D,OAAO,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAC5C,OAAO,EAAE,cAAc,EAAE,MAAM,cAAc,CAAC;AAC9C,OAAO,EAAE,aAAa,EAAE,MAAM,iBAAiB,CAAC;AAChD,OAAO,EAAE,SAAS,EAAqB,MAAM,kBAAkB,CAAC;AAEhE,QAAQ,CAAC,sBAAsB,EAAE,GAAG,EAAE;IACpC,IAAI,MAAsB,CAAC;IAE3B,UAAU,CAAC,GAAG,EAAE;QACd,MAAM,GAAG,IAAI,cAAc,CAAC,EAAE,gBAAgB,EAAE,IAAI,EAAE,KAAK,EAAE,GAAG,EAAE,CAAC,CAAC;IACtE,CAAC,CAAC,CAAC;IAEH,SAAS,MAAM,CAAC,SAAuC,EAAE,QAAgB,GAAG;QAC1E,MAAM,GAAG,GAAG;YACV,cAAc,EAAE,KAAK;YACrB,MAAM,EAAE,MAAM;YACd,WAAW,EAAE,CAAC;YACd,QAAQ,EAAE,CAAC;SACZ,CAAC;QACF,MAAM,MAAM,GAAG,aAAa,CAAC,SAAS,EAAE,GAAG,CAAC,CAAC;QAC7C,IAAI,KAAK,CAAC,OAAO,CAAC,MAAM,CAAC,EAAE,CAAC;YAC1B,OAAO,MAAM,CAAC;QAChB,CAAC;aAAM,IAAI,MAAM,EAAE,CAAC;YAClB,OAAO,CAAC,MAAM,CAAC,CAAC;QAClB,CAAC;QACD,OAAO,EAAE,CAAC;IACZ,CAAC;IAED,QA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,CAAC,CAAC,CAAC;IACL,CAAC,CAAC,CAAC;AACL,CAAC,CAAC,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"progress-bar-grid.d.ts","sourceRoot":"","sources":["../../src/components/progress-bar-grid.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,SAAS,EAAiB,MAAM,iBAAiB,CAAC;
|
|
1
|
+
{"version":3,"file":"progress-bar-grid.d.ts","sourceRoot":"","sources":["../../src/components/progress-bar-grid.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,SAAS,EAAiB,MAAM,iBAAiB,CAAC;AAEhE,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,aAAa,CAAC;AAKzC,MAAM,WAAW,kBAAkB;IACjC,OAAO,EAAE,MAAM,CAAC;IAChB,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,UAAU,CAAC,EAAE,KAAK,CAAC;IACnB,QAAQ,CAAC,EAAE,KAAK,CAAC;IACjB,YAAY,CAAC,EAAE,KAAK,CAAC;IACrB,YAAY,CAAC,EAAE,KAAK,CAAC;IACrB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,QAAQ,CAAC,EAAE,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;CAC7B;AAED;;;GAGG;AACH,wBAAgB,WAAW,CAAC,OAAO,EAAE,kBAAkB,GAAG,SAAS,CA0ClE"}
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
// Progress bar component using grid system
|
|
2
|
+
import { callComponent } from '../component.js';
|
|
2
3
|
import { Styled } from './styled.js';
|
|
3
4
|
import { grid as Grid } from '../layout/grid.js';
|
|
4
5
|
import { applyStyle } from '../utils/colors.js';
|
|
@@ -38,7 +39,7 @@ export function progressBar(options) {
|
|
|
38
39
|
];
|
|
39
40
|
// Use grid to layout: [1] [flex] [1] [7]
|
|
40
41
|
const gridComp = Grid({ template: [1, '1*', 1, 7], columnGap: 0 }, ...children);
|
|
41
|
-
return gridComp
|
|
42
|
+
return callComponent(gridComp, ctx);
|
|
42
43
|
};
|
|
43
44
|
}
|
|
44
45
|
//# sourceMappingURL=progress-bar-grid.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"progress-bar-grid.js","sourceRoot":"","sources":["../../src/components/progress-bar-grid.ts"],"names":[],"mappings":"AAAA,2CAA2C;
|
|
1
|
+
{"version":3,"file":"progress-bar-grid.js","sourceRoot":"","sources":["../../src/components/progress-bar-grid.ts"],"names":[],"mappings":"AAAA,2CAA2C;AAG3C,OAAO,EAAE,aAAa,EAAE,MAAM,iBAAiB,CAAC;AAEhD,OAAO,EAAE,MAAM,EAAE,MAAM,aAAa,CAAC;AACrC,OAAO,EAAE,IAAI,IAAI,IAAI,EAAE,MAAM,mBAAmB,CAAC;AACjD,OAAO,EAAE,UAAU,EAAE,MAAM,oBAAoB,CAAC;AAehD;;;GAGG;AACH,MAAM,UAAU,WAAW,CAAC,OAA2B;IACrD,OAAO,CAAC,GAAkB,EAAE,EAAE;QAC5B,MAAM,OAAO,GAAG,IAAI,CAAC,GAAG,CAAC,GAAG,EAAE,IAAI,CAAC,GAAG,CAAC,CAAC,EAAE,CAAC,OAAO,CAAC,OAAO,GAAG,OAAO,CAAC,KAAK,CAAC,GAAG,GAAG,CAAC,CAAC,CAAC;QAEpF,MAAM,YAAY,GAAG,OAAO,CAAC,YAAY,IAAI,GAAG,CAAC;QACjD,MAAM,cAAc,GAAG,OAAO,CAAC,cAAc,IAAI,GAAG,CAAC;QACrD,MAAM,WAAW,GAAG,OAAO,CAAC,QAAQ,EAAE,CAAC,CAAC,CAAC,IAAI,QAAQ,CAAC,CAAC,IAAI;QAC3D,MAAM,YAAY,GAAG,OAAO,CAAC,QAAQ,EAAE,CAAC,CAAC,CAAC,IAAI,QAAQ,CAAC,CAAC,IAAI;QAE5D,MAAM,YAAY,GAAG,OAAO,CA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AQ,GAAG,IAAI,CAAC,EAAE,QAAQ,EAAE,CAAC,CAAC,EAAE,IAAI,EAAE,CAAC,EAAE,CAAC,CAAC,EAAE,SAAS,EAAE,CAAC,EAAE,EAAE,GAAG,QAAQ,CAAC,CAAC;QAChF,OAAO,aAAa,CAAC,QAAQ,EAAE,GAAG,CAAC,CAAC;IACtC,CAAC,CAAC;AACJ,CAAC"}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { describe, it, expect, beforeEach } from 'vitest';
|
|
2
2
|
import { progressBar } from './progress-bar-grid.js';
|
|
3
3
|
import { TerminalRegion } from '../region.js';
|
|
4
|
+
import { callComponent } from '../component.js';
|
|
4
5
|
describe('ProgressBar (Grid)', () => {
|
|
5
6
|
let region;
|
|
6
7
|
beforeEach(() => {
|
|
@@ -11,8 +12,8 @@ describe('ProgressBar (Grid)', () => {
|
|
|
11
12
|
current: 50,
|
|
12
13
|
total: 100,
|
|
13
14
|
});
|
|
14
|
-
expect(typeof component).toBe(
|
|
15
|
-
const result = component
|
|
15
|
+
expect(typeof component === 'function' || (typeof component === 'object' && component !== null && 'render' in component)).toBe(true);
|
|
16
|
+
const result = callComponent(component, {
|
|
16
17
|
availableWidth: 80,
|
|
17
18
|
region: region,
|
|
18
19
|
columnIndex: 0,
|
|
@@ -26,7 +27,7 @@ describe('ProgressBar (Grid)', () => {
|
|
|
26
27
|
current: 50,
|
|
27
28
|
total: 100,
|
|
28
29
|
});
|
|
29
|
-
const result = component
|
|
30
|
+
const result = callComponent(component, {
|
|
30
31
|
availableWidth: 80,
|
|
31
32
|
region: region,
|
|
32
33
|
columnIndex: 0,
|
|
@@ -42,7 +43,7 @@ describe('ProgressBar (Grid)', () => {
|
|
|
42
43
|
current: 25,
|
|
43
44
|
total: 100,
|
|
44
45
|
});
|
|
45
|
-
const result = component
|
|
46
|
+
const result = callComponent(component, {
|
|
46
47
|
availableWidth: 80,
|
|
47
48
|
region: region,
|
|
48
49
|
columnIndex: 0,
|
|
@@ -59,7 +60,7 @@ describe('ProgressBar (Grid)', () => {
|
|
|
59
60
|
bracketColor: 'brightBlack',
|
|
60
61
|
percentColor: 'yellow',
|
|
61
62
|
});
|
|
62
|
-
const result = component
|
|
63
|
+
const result = callComponent(component, {
|
|
63
64
|
availableWidth: 80,
|
|
64
65
|
region: region,
|
|
65
66
|
columnIndex: 0,
|
|
@@ -73,7 +74,7 @@ describe('ProgressBar (Grid)', () => {
|
|
|
73
74
|
current: 0,
|
|
74
75
|
total: 100,
|
|
75
76
|
});
|
|
76
|
-
const result = component
|
|
77
|
+
const result = callComponent(component, {
|
|
77
78
|
availableWidth: 80,
|
|
78
79
|
region: region,
|
|
79
80
|
columnIndex: 0,
|
|
@@ -87,7 +88,7 @@ describe('ProgressBar (Grid)', () => {
|
|
|
87
88
|
current: 100,
|
|
88
89
|
total: 100,
|
|
89
90
|
});
|
|
90
|
-
const result = component
|
|
91
|
+
const result = callComponent(component, {
|
|
91
92
|
availableWidth: 80,
|
|
92
93
|
region: region,
|
|
93
94
|
columnIndex: 0,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"progress-bar-grid.test.js","sourceRoot":"","sources":["../../src/components/progress-bar-grid.test.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,EAAE,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,QAAQ,CAAC;AAC1D,OAAO,EAAE,WAAW,EAAE,MAAM,wBAAwB,CAAC;AACrD,OAAO,EAAE,cAAc,EAAE,MAAM,cAAc,CAAC;
|
|
1
|
+
{"version":3,"file":"progress-bar-grid.test.js","sourceRoot":"","sources":["../../src/components/progress-bar-grid.test.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,EAAE,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,QAAQ,CAAC;AAC1D,OAAO,EAAE,WAAW,EAAE,MAAM,wBAAwB,CAAC;AACrD,OAAO,EAAE,cAAc,EAAE,MAAM,cAAc,CAAC;AA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
1
|
+
{"version":3,"file":"prompt.d.ts","sourceRoot":"","sources":["../../src/components/prompt.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,aAAa,CAAC;AACzC,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAIjD,MAAM,WAAW,aAAa;IAC5B,OAAO,EAAE,MAAM,CAAC;IAChB,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,KAAK,CAAC,EAAE,KAAK,CAAC;CACf;AAED;;;GAGG;AACH,wBAAgB,MAAM,CAAC,OAAO,EAAE,aAAa,GAAG,SAAS,CAqBxD"}
|
package/lib/components/prompt.js
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
// Prompt component - improved API for prompts like "Press SPACEBAR"
|
|
2
|
+
import { callComponent } from '../component.js';
|
|
2
3
|
import { Styled } from './styled.js';
|
|
3
4
|
/**
|
|
4
5
|
* Create a Prompt component that can be added to a region
|
|
@@ -9,7 +10,7 @@ export function Prompt(options) {
|
|
|
9
10
|
return (ctx) => {
|
|
10
11
|
const promptText = `Press ${key} to ${message}...`;
|
|
11
12
|
const styledComponent = Styled({ color: promptColor }, promptText);
|
|
12
|
-
const styledResult = styledComponent
|
|
13
|
+
const styledResult = callComponent(styledComponent, ctx);
|
|
13
14
|
// Return blank line + prompt
|
|
14
15
|
if (typeof styledResult === 'string') {
|
|
15
16
|
return ['', styledResult];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"prompt.js","sourceRoot":"","sources":["../../src/components/prompt.ts"],"names":[],"mappings":"AAAA,oEAAoE;
|
|
1
|
+
{"version":3,"file":"prompt.js","sourceRoot":"","sources":["../../src/components/prompt.ts"],"names":[],"mappings":"AAAA,oEAAoE;AAIpE,OAAO,EAAE,aAAa,EAAE,MAAM,iBAAiB,CAAC;AAChD,OAAO,EAAE,MAAM,EAAE,MAAM,aAAa,CAAC;AAQrC;;;GAGG;AACH,MAAM,UAAU,MAAM,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ACrB;AAiCD;;;;;;;;;;;;GAYG;AACH,wBAAgB,QAAQ,CAAC,OAAO,EAAE,eAAe,GAAG,SAAS,
|
|
1
|
+
{"version":3,"file":"segments.d.ts","sourceRoot":"","sources":["../../src/components/segments.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAiB,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAChE,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,aAAa,CAAC;AAKzC,MAAM,MAAM,WAAW,GAAG,KAAK,GAAG,SAAS,GAAG,OAAO,GAAG,KAAK,GAAG,UAAU,CAAC;AAE3E,MAAM,WAAW,OAAO;IACtB,OAAO,EAAE,MAAM,CAAC;IAChB,KAAK,CAAC,EAAE,KAAK,CAAC;IACd,WAAW,CAAC,EAAE,WAAW,CAAC;CAC3B;AAED,MAAM,WAAW,eAAe;IAC9B,QAAQ,EAAE,OAAO,EAAE,CAAC;CACrB;AAiCD;;;;;;;;;;;;GAYG;AACH,wBAAgB,QAAQ,CAAC,OAAO,EAAE,eAAe,GAAG,SAAS,CA2D5D"}
|
|
@@ -51,17 +51,14 @@ export function Segments(options) {
|
|
|
51
51
|
}
|
|
52
52
|
const availableWidth = ctx.availableWidth;
|
|
53
53
|
let result = '';
|
|
54
|
-
let usedWidth = 0;
|
|
55
54
|
for (let i = 0; i < segments.length; i++) {
|
|
56
55
|
const segment = segments[i];
|
|
57
|
-
const nextSegment = i < segments.length - 1 ? segments[i + 1] : null;
|
|
58
56
|
// Left divider (automatic - dash for middle segments)
|
|
59
57
|
if (i > 0) {
|
|
60
58
|
// Always use dash (─) for dividers - it works well with all border styles
|
|
61
59
|
const dividerColor = 'brightBlack';
|
|
62
60
|
const styledDivider = applyStyle('─', { color: dividerColor });
|
|
63
61
|
result += styledDivider;
|
|
64
|
-
usedWidth += 1;
|
|
65
62
|
}
|
|
66
63
|
// Left border decoration
|
|
67
64
|
const borderStyle = segment.borderStyle ?? 'cap';
|
|
@@ -70,7 +67,6 @@ export function Segments(options) {
|
|
|
70
67
|
// Auto-theme: borders use text color
|
|
71
68
|
const borderColor = segment.color ?? 'brightCyan';
|
|
72
69
|
result += applyStyle(borderChars.left, { color: borderColor });
|
|
73
|
-
usedWidth += 1;
|
|
74
70
|
}
|
|
75
71
|
// Segment content with automatic padding (no background, just text color)
|
|
76
72
|
// Trim content and add padding automatically
|
|
@@ -81,13 +77,11 @@ export function Segments(options) {
|
|
|
81
77
|
// No backgroundColor - uses default terminal background
|
|
82
78
|
});
|
|
83
79
|
result += styledContent;
|
|
84
|
-
usedWidth += paddedContent.length;
|
|
85
80
|
// Right border decoration
|
|
86
81
|
if (borderChars.right) {
|
|
87
82
|
// Auto-theme: borders use text color
|
|
88
83
|
const borderColor = segment.color ?? 'brightCyan';
|
|
89
84
|
result += applyStyle(borderChars.right, { color: borderColor });
|
|
90
|
-
usedWidth += 1;
|
|
91
85
|
}
|
|
92
86
|
// Right divider (automatic - dash for middle segments)
|
|
93
87
|
if (i < segments.length - 1) {
|
|
@@ -95,7 +89,6 @@ export function Segments(options) {
|
|
|
95
89
|
const dividerColor = 'brightBlack';
|
|
96
90
|
const styledDivider = applyStyle('─', { color: dividerColor });
|
|
97
91
|
result += styledDivider;
|
|
98
|
-
usedWidth += 1;
|
|
99
92
|
}
|
|
100
93
|
}
|
|
101
94
|
// Truncate if needed (preserving ANSI codes)
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"segments.js","sourceRoot":"","sources":["../../src/components/segments.ts"],"names":[],"mappings":"AAAA,qFAAqF;AAIrF,OAAO,EAAE,UAAU,EAAE,MAAM,oBAAoB,CAAC;AAChD,OAAO,EAAE,eAAe,EAAE,MAAM,kBAAkB,CAAC;AAgBnD;;;GAGG;AACH,SAAS,cAAc,CAAC,KAAkB;IACxC,QAAQ,KAAK,EAAE,CAAC;QACd,KAAK,KAAK;YACR,sCAAsC;YACtC,2CAA2C;YAC3C,4CAA4C;YAC5C,OAAO,EAAE,IAAI,EAAE,GAAG,EAAE,K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O,eAAe,CAAC,MAAM,EAAE,cAAc,CAAC,CAAC;IACjD,CAAC,CAAC;AACJ,CAAC"}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { describe, it, expect, beforeEach } from 'vitest';
|
|
2
2
|
import { Styled } from './styled.js';
|
|
3
3
|
import { TerminalRegion } from '../region.js';
|
|
4
|
+
import { callComponent } from '../component.js';
|
|
4
5
|
describe('Style Component', () => {
|
|
5
6
|
let region;
|
|
6
7
|
beforeEach(() => {
|
|
@@ -9,7 +10,7 @@ describe('Style Component', () => {
|
|
|
9
10
|
describe('basic styling', () => {
|
|
10
11
|
it('should apply color', () => {
|
|
11
12
|
const component = Styled({ color: 'red' }, 'Hello');
|
|
12
|
-
const result = component
|
|
13
|
+
const result = callComponent(component, {
|
|
13
14
|
availableWidth: 80,
|
|
14
15
|
region: region,
|
|
15
16
|
columnIndex: 0,
|
|
@@ -20,7 +21,7 @@ describe('Style Component', () => {
|
|
|
20
21
|
});
|
|
21
22
|
it('should apply backgroundColor', () => {
|
|
22
23
|
const component = Styled({ backgroundColor: 'blue' }, 'Hello');
|
|
23
|
-
const result = component
|
|
24
|
+
const result = callComponent(component, {
|
|
24
25
|
availableWidth: 80,
|
|
25
26
|
region: region,
|
|
26
27
|
columnIndex: 0,
|
|
@@ -31,7 +32,7 @@ describe('Style Component', () => {
|
|
|
31
32
|
});
|
|
32
33
|
it('should apply bold', () => {
|
|
33
34
|
const component = Styled({ bold: true }, 'Hello');
|
|
34
|
-
const result = component
|
|
35
|
+
const result = callComponent(component, {
|
|
35
36
|
availableWidth: 80,
|
|
36
37
|
region: region,
|
|
37
38
|
columnIndex: 0,
|
|
@@ -43,7 +44,7 @@ describe('Style Component', () => {
|
|
|
43
44
|
describe('overflow handling', () => {
|
|
44
45
|
it('should truncate with ellipsis-end', () => {
|
|
45
46
|
const component = Styled({ overflow: 'ellipsis-end' }, 'This is a very long text');
|
|
46
|
-
const result = component
|
|
47
|
+
const result = callComponent(component, {
|
|
47
48
|
availableWidth: 10,
|
|
48
49
|
region: region,
|
|
49
50
|
columnIndex: 0,
|
|
@@ -55,7 +56,7 @@ describe('Style Component', () => {
|
|
|
55
56
|
});
|
|
56
57
|
it('should truncate with ellipsis-start', () => {
|
|
57
58
|
const component = Styled({ overflow: 'ellipsis-start' }, 'This is a very long text');
|
|
58
|
-
const result = component
|
|
59
|
+
const result = callComponent(component, {
|
|
59
60
|
availableWidth: 10,
|
|
60
61
|
region: region,
|
|
61
62
|
columnIndex: 0,
|
|
@@ -67,7 +68,7 @@ describe('Style Component', () => {
|
|
|
67
68
|
});
|
|
68
69
|
it('should wrap text', () => {
|
|
69
70
|
const component = Styled({ overflow: 'wrap' }, 'This is a very long text that should wrap');
|
|
70
|
-
const result = component
|
|
71
|
+
const result = callComponent(component, {
|
|
71
72
|
availableWidth: 10,
|
|
72
73
|
region: region,
|
|
73
74
|
columnIndex: 0,
|
|
@@ -80,7 +81,7 @@ describe('Style Component', () => {
|
|
|
80
81
|
describe('when condition', () => {
|
|
81
82
|
it('should return null when condition is false', () => {
|
|
82
83
|
const component = Styled({ when: () => false }, 'Hello');
|
|
83
|
-
const result = component
|
|
84
|
+
const result = callComponent(component, {
|
|
84
85
|
availableWidth: 80,
|
|
85
86
|
region: region,
|
|
86
87
|
columnIndex: 0,
|
|
@@ -90,7 +91,7 @@ describe('Style Component', () => {
|
|
|
90
91
|
});
|
|
91
92
|
it('should return content when condition is true', () => {
|
|
92
93
|
const component = Styled({ when: (ctx) => ctx.availableWidth > 50 }, 'Hello');
|
|
93
|
-
const result = component
|
|
94
|
+
const result = callComponent(component, {
|
|
94
95
|
availableWidth: 80,
|
|
95
96
|
region: region,
|
|
96
97
|
columnIndex: 0,
|
|
@@ -100,14 +101,14 @@ describe('Style Component', () => {
|
|
|
100
101
|
});
|
|
101
102
|
it('should check availableWidth in condition', () => {
|
|
102
103
|
const component = Styled({ when: (ctx) => ctx.availableWidth > 50 }, 'Hello');
|
|
103
|
-
const result1 = component
|
|
104
|
+
const result1 = callComponent(component, {
|
|
104
105
|
availableWidth: 40,
|
|
105
106
|
region: region,
|
|
106
107
|
columnIndex: 0,
|
|
107
108
|
rowIndex: 0,
|
|
108
109
|
});
|
|
109
110
|
expect(result1).toBeNull();
|
|
110
|
-
const result2 = component
|
|
111
|
+
const result2 = callComponent(component, {
|
|
111
112
|
availableWidth: 60,
|
|
112
113
|
region: region,
|
|
113
114
|
columnIndex: 0,
|
|
@@ -119,7 +120,7 @@ describe('Style Component', () => {
|
|
|
119
120
|
describe('multi-line content', () => {
|
|
120
121
|
it('should apply styling to each line', () => {
|
|
121
122
|
const component = Styled({ color: 'red' }, ['Line 1', 'Line 2']);
|
|
122
|
-
const result = component
|
|
123
|
+
const result = callComponent(component, {
|
|
123
124
|
availableWidth: 80,
|
|
124
125
|
region: region,
|
|
125
126
|
columnIndex: 0,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"style.test.js","sourceRoot":"","sources":["../../src/components/style.test.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,EAAE,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,QAAQ,CAAC;AAC1D,OAAO,EAAE,MAAM,EAAE,MAAM,aAAa,CAAC;AACrC,OAAO,EAAE,cAAc,EAAE,MAAM,cAAc,CAAC;
|
|
1
|
+
{"version":3,"file":"style.test.js","sourceRoot":"","sources":["../../src/components/style.test.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,EAAE,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,QAAQ,CAAC;AAC1D,OAAO,EAAE,MAAM,EAAE,MAAM,aAAa,CAAC;AACrC,OAAO,EAAE,cAAc,EAAE,MAAM,cAAc,CAAC;AAC9C,OAAO,EAAE,aAAa,EAAE,MAAM,iBAAiB,CAAC;AAEhD,QAAQ,CAAC,iBAAiB,EAAE,GAAG,EAAE;IAC/B,IAAI,MAAsB,CAAC;IAE3B,UAAU,CAAC,GAAG,EAAE;QACd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