termcast 1.3.46 → 1.3.48
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/apis/cache.d.ts.map +1 -1
- package/dist/apis/cache.js +1 -2
- package/dist/apis/cache.js.map +1 -1
- package/dist/apis/localstorage.d.ts.map +1 -1
- package/dist/apis/localstorage.js +1 -2
- package/dist/apis/localstorage.js.map +1 -1
- package/dist/apis/sqlite.d.ts +7 -0
- package/dist/apis/sqlite.d.ts.map +1 -0
- package/dist/apis/sqlite.js +13 -0
- package/dist/apis/sqlite.js.map +1 -0
- package/dist/build.d.ts.map +1 -1
- package/dist/build.js +7 -1
- package/dist/build.js.map +1 -1
- package/dist/compile.js +1 -1
- package/dist/compile.js.map +1 -1
- package/dist/components/actions.d.ts +18 -0
- package/dist/components/actions.d.ts.map +1 -1
- package/dist/components/actions.js +70 -5
- package/dist/components/actions.js.map +1 -1
- package/dist/components/detail.d.ts.map +1 -1
- package/dist/components/detail.js +3 -1
- package/dist/components/detail.js.map +1 -1
- package/dist/components/dropdown.d.ts.map +1 -1
- package/dist/components/dropdown.js +40 -11
- package/dist/components/dropdown.js.map +1 -1
- package/dist/components/form/dropdown.d.ts.map +1 -1
- package/dist/components/form/dropdown.js +26 -10
- package/dist/components/form/dropdown.js.map +1 -1
- package/dist/components/list.d.ts +7 -0
- package/dist/components/list.d.ts.map +1 -1
- package/dist/components/list.js +82 -15
- package/dist/components/list.js.map +1 -1
- package/dist/components/metadata.d.ts.map +1 -1
- package/dist/components/metadata.js +2 -1
- package/dist/components/metadata.js.map +1 -1
- package/dist/components/spinner.d.ts +6 -0
- package/dist/components/spinner.d.ts.map +1 -0
- package/dist/components/spinner.js +12 -0
- package/dist/components/spinner.js.map +1 -0
- package/dist/examples/action-shortcut.d.ts +2 -0
- package/dist/examples/action-shortcut.d.ts.map +1 -0
- package/dist/examples/action-shortcut.js +20 -0
- package/dist/examples/action-shortcut.js.map +1 -0
- package/dist/examples/internal/scrollbox-with-descendants.js +19 -8
- package/dist/examples/internal/scrollbox-with-descendants.js.map +1 -1
- package/dist/examples/list-spacing-default.d.ts +5 -0
- package/dist/examples/list-spacing-default.d.ts.map +1 -0
- package/dist/examples/list-spacing-default.js +10 -0
- package/dist/examples/list-spacing-default.js.map +1 -0
- package/dist/examples/list-spacing-mode.d.ts +10 -0
- package/dist/examples/list-spacing-mode.d.ts.map +1 -0
- package/dist/examples/list-spacing-mode.js +26 -0
- package/dist/examples/list-spacing-mode.js.map +1 -0
- package/dist/examples/list-spacing-relaxed.d.ts +5 -0
- package/dist/examples/list-spacing-relaxed.d.ts.map +1 -0
- package/dist/examples/list-spacing-relaxed.js +10 -0
- package/dist/examples/list-spacing-relaxed.js.map +1 -0
- package/dist/index.d.ts +2 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1 -0
- package/dist/index.js.map +1 -1
- package/dist/logger.d.ts.map +1 -1
- package/dist/logger.js +2 -1
- package/dist/logger.js.map +1 -1
- package/dist/state.d.ts +9 -0
- package/dist/state.d.ts.map +1 -1
- package/dist/state.js +2 -0
- package/dist/state.js.map +1 -1
- package/dist/swift-runtime.d.ts.map +1 -1
- package/dist/swift-runtime.js +20 -5
- package/dist/swift-runtime.js.map +1 -1
- package/dist/utils.js +1 -1
- package/dist/utils.js.map +1 -1
- package/package.json +5 -5
- package/src/apis/cache.test.ts +1 -1
- package/src/apis/cache.tsx +1 -2
- package/src/apis/localstorage.tsx +1 -2
- package/src/apis/sqlite.ts +14 -0
- package/src/build.tsx +7 -1
- package/src/compile.tsx +1 -1
- package/src/components/actions.tsx +77 -5
- package/src/components/detail.tsx +3 -1
- package/src/components/dropdown.tsx +49 -11
- package/src/components/form/dropdown.tsx +32 -10
- package/src/components/list.tsx +157 -18
- package/src/components/metadata.tsx +3 -2
- package/src/components/spinner.tsx +25 -0
- package/src/examples/action-shortcut.tsx +53 -0
- package/src/examples/action-shortcut.vitest.tsx +178 -0
- package/src/examples/actions-context.vitest.tsx +4 -4
- package/src/examples/detail-metadata-showcase.vitest.tsx +32 -18
- package/src/examples/form-dropdown.vitest.tsx +8 -8
- package/src/examples/form-tagpicker.vitest.tsx +4 -4
- package/src/examples/github.vitest.tsx +16 -9
- package/src/examples/internal/scrollbox-with-descendants.tsx +27 -8
- package/src/examples/list-detail-metadata.vitest.tsx +3 -1
- package/src/examples/list-loading-empty-view.vitest.tsx +5 -5
- package/src/examples/list-scrollbox.vitest.tsx +5 -5
- package/src/examples/list-spacing-default.tsx +38 -0
- package/src/examples/list-spacing-mode.tsx +137 -0
- package/src/examples/list-spacing-mode.vitest.tsx +158 -0
- package/src/examples/list-spacing-relaxed.tsx +38 -0
- package/src/examples/list-with-detail.vitest.tsx +63 -28
- package/src/examples/list-with-sections.vitest.tsx +14 -14
- package/src/examples/simple-detail-markdown.vitest.tsx +3 -4
- package/src/examples/simple-file-picker.vitest.tsx +1 -1
- package/src/examples/simple-grid.vitest.tsx +42 -35
- package/src/examples/simple-navigation.vitest.tsx +14 -14
- package/src/extensions/dev.vitest.tsx +9 -3
- package/src/index.tsx +2 -0
- package/src/logger.tsx +2 -1
- package/src/state.tsx +13 -0
- package/src/swift-runtime.tsx +19 -5
- package/src/utils.test.tsx +1 -1
- package/src/utils.tsx +1 -1
|
@@ -0,0 +1,158 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* E2E tests for List spacingMode prop.
|
|
3
|
+
*
|
|
4
|
+
* Tests both 'default' (single-line) and 'relaxed' (two-line) modes
|
|
5
|
+
* to verify layout differences and subtitle alignment.
|
|
6
|
+
*/
|
|
7
|
+
|
|
8
|
+
import { test, expect, afterEach, beforeEach, describe } from 'vitest'
|
|
9
|
+
import { launchTerminal, Session } from 'tuistory/src'
|
|
10
|
+
|
|
11
|
+
describe('spacingMode default', () => {
|
|
12
|
+
let session: Session
|
|
13
|
+
|
|
14
|
+
beforeEach(async () => {
|
|
15
|
+
session = await launchTerminal({
|
|
16
|
+
command: 'bun',
|
|
17
|
+
args: ['src/examples/list-spacing-default.tsx'],
|
|
18
|
+
cols: 70,
|
|
19
|
+
rows: 20,
|
|
20
|
+
})
|
|
21
|
+
})
|
|
22
|
+
|
|
23
|
+
afterEach(() => {
|
|
24
|
+
session?.close()
|
|
25
|
+
})
|
|
26
|
+
|
|
27
|
+
test('renders single-line items with title and subtitle on same row', async () => {
|
|
28
|
+
await session.text({
|
|
29
|
+
waitFor: (text) => /Default Mode/i.test(text),
|
|
30
|
+
})
|
|
31
|
+
|
|
32
|
+
const text = await session.text()
|
|
33
|
+
expect(text).toMatchInlineSnapshot(`
|
|
34
|
+
"
|
|
35
|
+
|
|
36
|
+
|
|
37
|
+
Default Mode ───────────────────────────────────────────────────
|
|
38
|
+
|
|
39
|
+
> Search...
|
|
40
|
+
|
|
41
|
+
With Icons
|
|
42
|
+
›▯ Report Q4 financial summary [Draft]
|
|
43
|
+
⟨⟩ API Docs REST endpoints guide v2.1
|
|
44
|
+
|
|
45
|
+
Without Icons
|
|
46
|
+
Meeting Notes Weekly standup points [Important]
|
|
47
|
+
|
|
48
|
+
No Subtitle
|
|
49
|
+
★ Favorites
|
|
50
|
+
|
|
51
|
+
|
|
52
|
+
↑↓ navigate ^k actions
|
|
53
|
+
|
|
54
|
+
"
|
|
55
|
+
`)
|
|
56
|
+
|
|
57
|
+
// Title and subtitle on same line
|
|
58
|
+
expect(text).toContain('Report')
|
|
59
|
+
expect(text).toContain('Q4 financial')
|
|
60
|
+
}, 10000)
|
|
61
|
+
})
|
|
62
|
+
|
|
63
|
+
describe('spacingMode relaxed', () => {
|
|
64
|
+
let session: Session
|
|
65
|
+
|
|
66
|
+
beforeEach(async () => {
|
|
67
|
+
session = await launchTerminal({
|
|
68
|
+
command: 'bun',
|
|
69
|
+
args: ['src/examples/list-spacing-relaxed.tsx'],
|
|
70
|
+
cols: 70,
|
|
71
|
+
rows: 25,
|
|
72
|
+
})
|
|
73
|
+
})
|
|
74
|
+
|
|
75
|
+
afterEach(() => {
|
|
76
|
+
session?.close()
|
|
77
|
+
})
|
|
78
|
+
|
|
79
|
+
test('renders two-line items with subtitle below title', async () => {
|
|
80
|
+
await session.text({
|
|
81
|
+
waitFor: (text) => /Relaxed Mode/i.test(text),
|
|
82
|
+
})
|
|
83
|
+
|
|
84
|
+
const text = await session.text()
|
|
85
|
+
expect(text).toMatchInlineSnapshot(`
|
|
86
|
+
"
|
|
87
|
+
|
|
88
|
+
|
|
89
|
+
Relaxed Mode ───────────────────────────────────────────────────
|
|
90
|
+
|
|
91
|
+
> Search...
|
|
92
|
+
|
|
93
|
+
With Icons
|
|
94
|
+
›▯ Report [Draft]
|
|
95
|
+
Q4 financial summary
|
|
96
|
+
|
|
97
|
+
⟨⟩ API Docs v2.1
|
|
98
|
+
REST endpoints guide
|
|
99
|
+
|
|
100
|
+
|
|
101
|
+
Without Icons
|
|
102
|
+
Meeting Notes [Important]
|
|
103
|
+
Weekly standup points
|
|
104
|
+
|
|
105
|
+
|
|
106
|
+
No Subtitle
|
|
107
|
+
|
|
108
|
+
|
|
109
|
+
↑↓ navigate ^k actions
|
|
110
|
+
|
|
111
|
+
"
|
|
112
|
+
`)
|
|
113
|
+
|
|
114
|
+
// Should have content
|
|
115
|
+
expect(text).toContain('Report')
|
|
116
|
+
expect(text).toContain('Q4 financial')
|
|
117
|
+
}, 10000)
|
|
118
|
+
|
|
119
|
+
test('navigates through relaxed items', async () => {
|
|
120
|
+
await session.text({
|
|
121
|
+
waitFor: (text) => /Relaxed Mode/i.test(text),
|
|
122
|
+
})
|
|
123
|
+
|
|
124
|
+
await session.press('down')
|
|
125
|
+
const afterDown = await session.text()
|
|
126
|
+
expect(afterDown).toMatchInlineSnapshot(`
|
|
127
|
+
"
|
|
128
|
+
|
|
129
|
+
|
|
130
|
+
Relaxed Mode ───────────────────────────────────────────────────
|
|
131
|
+
|
|
132
|
+
> Search...
|
|
133
|
+
|
|
134
|
+
With Icons
|
|
135
|
+
▯ Report [Draft]
|
|
136
|
+
Q4 financial summary
|
|
137
|
+
|
|
138
|
+
›⟨⟩ API Docs v2.1
|
|
139
|
+
REST endpoints guide
|
|
140
|
+
|
|
141
|
+
|
|
142
|
+
Without Icons
|
|
143
|
+
Meeting Notes [Important]
|
|
144
|
+
Weekly standup points
|
|
145
|
+
|
|
146
|
+
|
|
147
|
+
No Subtitle
|
|
148
|
+
|
|
149
|
+
|
|
150
|
+
↑↓ navigate ^k actions
|
|
151
|
+
|
|
152
|
+
"
|
|
153
|
+
`)
|
|
154
|
+
|
|
155
|
+
// Second item should be selected
|
|
156
|
+
expect(afterDown).toContain('API Docs')
|
|
157
|
+
}, 10000)
|
|
158
|
+
})
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Test file for List with spacingMode="relaxed" (two-line items)
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
import { List, Icon, Color, renderWithProviders } from 'termcast'
|
|
6
|
+
|
|
7
|
+
function ListSpacingRelaxed() {
|
|
8
|
+
return (
|
|
9
|
+
<List navigationTitle="Relaxed Mode" spacingMode="relaxed">
|
|
10
|
+
<List.Section title="With Icons">
|
|
11
|
+
<List.Item
|
|
12
|
+
icon={Icon.Document}
|
|
13
|
+
title="Report"
|
|
14
|
+
subtitle="Q4 financial summary"
|
|
15
|
+
accessories={[{ tag: { value: 'Draft', color: Color.Yellow } }]}
|
|
16
|
+
/>
|
|
17
|
+
<List.Item
|
|
18
|
+
icon={Icon.Code}
|
|
19
|
+
title="API Docs"
|
|
20
|
+
subtitle="REST endpoints guide"
|
|
21
|
+
accessories={[{ text: 'v2.1' }]}
|
|
22
|
+
/>
|
|
23
|
+
</List.Section>
|
|
24
|
+
<List.Section title="Without Icons">
|
|
25
|
+
<List.Item
|
|
26
|
+
title="Meeting Notes"
|
|
27
|
+
subtitle="Weekly standup points"
|
|
28
|
+
accessories={[{ tag: 'Important' }]}
|
|
29
|
+
/>
|
|
30
|
+
</List.Section>
|
|
31
|
+
<List.Section title="No Subtitle">
|
|
32
|
+
<List.Item icon={Icon.Star} title="Favorites" />
|
|
33
|
+
</List.Section>
|
|
34
|
+
</List>
|
|
35
|
+
)
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
await renderWithProviders(<ListSpacingRelaxed />)
|
|
@@ -8,7 +8,7 @@ beforeEach(async () => {
|
|
|
8
8
|
command: 'bun',
|
|
9
9
|
args: ['src/examples/list-with-detail.tsx'],
|
|
10
10
|
cols: 80,
|
|
11
|
-
rows:
|
|
11
|
+
rows: 33,
|
|
12
12
|
})
|
|
13
13
|
})
|
|
14
14
|
|
|
@@ -51,14 +51,17 @@ test('list with detail view display and navigation', async () => {
|
|
|
51
51
|
│ - Height: 0.7m
|
|
52
52
|
│ - Weight: 6.9kg
|
|
53
53
|
│
|
|
54
|
+
│
|
|
54
55
|
│ Abilities
|
|
55
56
|
│
|
|
56
57
|
│ - Chlorophyll
|
|
57
58
|
│ - Overgrow
|
|
58
59
|
│
|
|
59
60
|
│
|
|
61
|
+
│
|
|
60
62
|
│ Types
|
|
61
|
-
|
|
63
|
+
│
|
|
64
|
+
↵ toggle detail ↑↓ navigate ^k a │ Grass ▼
|
|
62
65
|
|
|
63
66
|
"
|
|
64
67
|
`)
|
|
@@ -90,14 +93,17 @@ test('list with detail view display and navigation', async () => {
|
|
|
90
93
|
│ - Height: 1m
|
|
91
94
|
│ - Weight: 13kg
|
|
92
95
|
│
|
|
96
|
+
│
|
|
93
97
|
│ Abilities
|
|
94
98
|
│
|
|
95
99
|
│ - Chlorophyll
|
|
96
100
|
│ - Overgrow
|
|
97
101
|
│
|
|
98
102
|
│
|
|
103
|
+
│
|
|
99
104
|
│ Types
|
|
100
|
-
|
|
105
|
+
│
|
|
106
|
+
↵ toggle detail ↑↓ navigate ^k a │ Grass ▼
|
|
101
107
|
|
|
102
108
|
"
|
|
103
109
|
`)
|
|
@@ -127,14 +133,17 @@ test('list with detail view display and navigation', async () => {
|
|
|
127
133
|
│ - Height: 0.6m
|
|
128
134
|
│ - Weight: 8.5kg
|
|
129
135
|
│
|
|
136
|
+
│
|
|
130
137
|
│ Abilities
|
|
131
138
|
│
|
|
132
139
|
│ - Blaze
|
|
133
140
|
│ - Solar Power
|
|
134
141
|
│
|
|
135
142
|
│
|
|
143
|
+
│
|
|
136
144
|
│ Types
|
|
137
|
-
|
|
145
|
+
│
|
|
146
|
+
↵ toggle detail ↑↓ navigate ^k a │ Fire ▼
|
|
138
147
|
|
|
139
148
|
"
|
|
140
149
|
`)
|
|
@@ -170,11 +179,14 @@ test('list with detail view display and navigation', async () => {
|
|
|
170
179
|
│ See Console Logs │
|
|
171
180
|
│ │
|
|
172
181
|
│ │
|
|
182
|
+
│ │
|
|
183
|
+
│ │
|
|
184
|
+
│ │
|
|
173
185
|
│ ↵ select ↑↓ navigate │
|
|
174
186
|
│ │
|
|
175
187
|
╰──────────────────────────────────────────────────────────────────────────╯
|
|
176
|
-
│
|
|
177
|
-
↵ toggle detail ↑↓ navigate ^k a │
|
|
188
|
+
│
|
|
189
|
+
↵ toggle detail ↑↓ navigate ^k a │ Fire ▼
|
|
178
190
|
|
|
179
191
|
"
|
|
180
192
|
`)
|
|
@@ -217,6 +229,9 @@ test('list with detail view display and navigation', async () => {
|
|
|
217
229
|
|
|
218
230
|
|
|
219
231
|
|
|
232
|
+
|
|
233
|
+
|
|
234
|
+
|
|
220
235
|
"
|
|
221
236
|
`)
|
|
222
237
|
|
|
@@ -250,14 +265,17 @@ test('list with detail view display and navigation', async () => {
|
|
|
250
265
|
│ - Height: 0.6m
|
|
251
266
|
│ - Weight: 8.5kg
|
|
252
267
|
│
|
|
268
|
+
│
|
|
253
269
|
│ Abilities
|
|
254
270
|
│
|
|
255
271
|
│ - Blaze
|
|
256
272
|
│ - Solar Power
|
|
257
273
|
│
|
|
258
274
|
│
|
|
275
|
+
│
|
|
259
276
|
│ Types
|
|
260
|
-
|
|
277
|
+
│
|
|
278
|
+
↵ toggle detail ↑↓ navigate ^k a │ Fire ▼
|
|
261
279
|
|
|
262
280
|
"
|
|
263
281
|
`)
|
|
@@ -299,14 +317,17 @@ test('list detail view search functionality', async () => {
|
|
|
299
317
|
│ - Height: 0.6m
|
|
300
318
|
│ - Weight: 8.5kg
|
|
301
319
|
│
|
|
320
|
+
│
|
|
302
321
|
│ Abilities
|
|
303
322
|
│
|
|
304
323
|
│ - Blaze
|
|
305
324
|
│ - Solar Power
|
|
306
325
|
│
|
|
307
326
|
│
|
|
327
|
+
│
|
|
308
328
|
│ Types
|
|
309
|
-
|
|
329
|
+
│
|
|
330
|
+
↵ toggle detail ↑↓ navigate ^k a │ Fire ▼
|
|
310
331
|
|
|
311
332
|
"
|
|
312
333
|
`)
|
|
@@ -332,27 +353,30 @@ test('list detail view search functionality', async () => {
|
|
|
332
353
|
> water
|
|
333
354
|
|
|
334
355
|
|
|
335
|
-
│
|
|
336
|
-
No items found │
|
|
356
|
+
│ wartortle ▲
|
|
357
|
+
No items found │ █
|
|
337
358
|
│ Illustration
|
|
338
359
|
│
|
|
339
360
|
│ Types
|
|
340
361
|
│
|
|
341
|
-
│
|
|
362
|
+
│ Water
|
|
342
363
|
│
|
|
343
364
|
│ Characteristics
|
|
344
365
|
│
|
|
345
|
-
│ - Height:
|
|
346
|
-
│ - Weight:
|
|
366
|
+
│ - Height: 1m
|
|
367
|
+
│ - Weight: 22.5kg
|
|
368
|
+
│
|
|
347
369
|
│
|
|
348
370
|
│ Abilities
|
|
349
371
|
│
|
|
350
|
-
│ -
|
|
351
|
-
│ -
|
|
372
|
+
│ - Torrent
|
|
373
|
+
│ - Rain Dish
|
|
374
|
+
│
|
|
352
375
|
│
|
|
353
376
|
│
|
|
354
377
|
│ Types
|
|
355
|
-
|
|
378
|
+
│
|
|
379
|
+
↵ toggle detail ↑↓ navigate ^k a │ Water ▼
|
|
356
380
|
|
|
357
381
|
"
|
|
358
382
|
`)
|
|
@@ -369,27 +393,30 @@ test('list detail view search functionality', async () => {
|
|
|
369
393
|
> water
|
|
370
394
|
|
|
371
395
|
|
|
372
|
-
│
|
|
373
|
-
No items found │
|
|
396
|
+
│ wartortle ▲
|
|
397
|
+
No items found │ █
|
|
374
398
|
│ Illustration
|
|
375
399
|
│
|
|
376
400
|
│ Types
|
|
377
401
|
│
|
|
378
|
-
│
|
|
402
|
+
│ Water
|
|
379
403
|
│
|
|
380
404
|
│ Characteristics
|
|
381
405
|
│
|
|
382
|
-
│ - Height:
|
|
383
|
-
│ - Weight:
|
|
406
|
+
│ - Height: 1m
|
|
407
|
+
│ - Weight: 22.5kg
|
|
408
|
+
│
|
|
384
409
|
│
|
|
385
410
|
│ Abilities
|
|
386
411
|
│
|
|
387
|
-
│ -
|
|
388
|
-
│ -
|
|
412
|
+
│ - Torrent
|
|
413
|
+
│ - Rain Dish
|
|
414
|
+
│
|
|
389
415
|
│
|
|
390
416
|
│
|
|
391
417
|
│ Types
|
|
392
|
-
|
|
418
|
+
│
|
|
419
|
+
↵ toggle detail ↑↓ navigate ^k a │ Water ▼
|
|
393
420
|
|
|
394
421
|
"
|
|
395
422
|
`)
|
|
@@ -431,14 +458,17 @@ test('list detail metadata rendering', async () => {
|
|
|
431
458
|
│ - Height: 0.7m
|
|
432
459
|
│ - Weight: 6.9kg
|
|
433
460
|
│
|
|
461
|
+
│
|
|
434
462
|
│ Abilities
|
|
435
463
|
│
|
|
436
464
|
│ - Chlorophyll
|
|
437
465
|
│ - Overgrow
|
|
438
466
|
│
|
|
439
467
|
│
|
|
468
|
+
│
|
|
440
469
|
│ Types
|
|
441
|
-
|
|
470
|
+
│
|
|
471
|
+
↵ toggle detail ↑↓ navigate ^k a │ Grass ▼
|
|
442
472
|
|
|
443
473
|
"
|
|
444
474
|
`)
|
|
@@ -475,14 +505,17 @@ test('list detail metadata rendering', async () => {
|
|
|
475
505
|
│ - Height: 0.5m
|
|
476
506
|
│ - Weight: 9kg
|
|
477
507
|
│
|
|
508
|
+
│
|
|
478
509
|
│ Abilities
|
|
479
510
|
│
|
|
480
511
|
│ - Torrent
|
|
481
512
|
│ - Rain Dish
|
|
482
513
|
│
|
|
483
514
|
│
|
|
515
|
+
│
|
|
484
516
|
│ Types
|
|
485
|
-
|
|
517
|
+
│
|
|
518
|
+
↵ toggle detail ↑↓ navigate ^k a │ Water ▼
|
|
486
519
|
|
|
487
520
|
"
|
|
488
521
|
`)
|
|
@@ -502,7 +535,8 @@ test('list with detail layout consistency - short vs long detail content', async
|
|
|
502
535
|
waitFor: (text) => {
|
|
503
536
|
return (
|
|
504
537
|
text.includes('›Short Detail') &&
|
|
505
|
-
text.includes('Brief content')
|
|
538
|
+
text.includes('Brief content') &&
|
|
539
|
+
text.includes('↑↓ navigate')
|
|
506
540
|
)
|
|
507
541
|
},
|
|
508
542
|
})
|
|
@@ -514,7 +548,8 @@ test('list with detail layout consistency - short vs long detail content', async
|
|
|
514
548
|
waitFor: (text) => {
|
|
515
549
|
return (
|
|
516
550
|
text.includes('›Long Detail') &&
|
|
517
|
-
text.includes('extensive')
|
|
551
|
+
text.includes('extensive') &&
|
|
552
|
+
text.includes('↑↓ navigate')
|
|
518
553
|
)
|
|
519
554
|
},
|
|
520
555
|
})
|
|
@@ -320,8 +320,8 @@ test('list with sections search functionality', async () => {
|
|
|
320
320
|
- Perfect for sandwiches or toast
|
|
321
321
|
|
|
322
322
|
|
|
323
|
-
esc go back
|
|
324
323
|
|
|
324
|
+
esc go back
|
|
325
325
|
|
|
326
326
|
"
|
|
327
327
|
`)
|
|
@@ -440,8 +440,6 @@ test('list actions panel with ctrl+k', async () => {
|
|
|
440
440
|
"
|
|
441
441
|
|
|
442
442
|
|
|
443
|
-
Simple List Example ────────────────────────────────────────────
|
|
444
|
-
|
|
445
443
|
╭────────────────────────────────────────────────────────────────╮
|
|
446
444
|
│ │
|
|
447
445
|
│ Actions esc │
|
|
@@ -456,8 +454,10 @@ test('list actions panel with ctrl+k', async () => {
|
|
|
456
454
|
│ See Console Logs │
|
|
457
455
|
│ │
|
|
458
456
|
│ │
|
|
459
|
-
│
|
|
460
|
-
│ │
|
|
457
|
+
│ │
|
|
458
|
+
│ │
|
|
459
|
+
│ │
|
|
460
|
+
│ ↵ select ↑↓ navigate │"
|
|
461
461
|
`)
|
|
462
462
|
|
|
463
463
|
// Navigate down to second action
|
|
@@ -468,8 +468,6 @@ test('list actions panel with ctrl+k', async () => {
|
|
|
468
468
|
"
|
|
469
469
|
|
|
470
470
|
|
|
471
|
-
Simple List Example ────────────────────────────────────────────
|
|
472
|
-
|
|
473
471
|
╭────────────────────────────────────────────────────────────────╮
|
|
474
472
|
│ │
|
|
475
473
|
│ Actions esc │
|
|
@@ -484,8 +482,10 @@ test('list actions panel with ctrl+k', async () => {
|
|
|
484
482
|
│ See Console Logs │
|
|
485
483
|
│ │
|
|
486
484
|
│ │
|
|
487
|
-
│
|
|
488
|
-
│ │
|
|
485
|
+
│ │
|
|
486
|
+
│ │
|
|
487
|
+
│ │
|
|
488
|
+
│ ↵ select ↑↓ navigate │"
|
|
489
489
|
`)
|
|
490
490
|
|
|
491
491
|
// Trigger the second action (Add to Cart)
|
|
@@ -706,15 +706,15 @@ test('list scrollbox scrolling with sections', async () => {
|
|
|
706
706
|
|
|
707
707
|
> Search items...
|
|
708
708
|
|
|
709
|
+
Fruits
|
|
710
|
+
Apple Red and sweet Fresh [Popular]
|
|
711
|
+
Banana Yellow and nutritious Ripe
|
|
709
712
|
Orange Citrus and juicy Fresh
|
|
710
713
|
Grape Sweet clusters [Seasonal]
|
|
711
714
|
Mango Tropical delight Imported
|
|
712
715
|
Pineapple Sweet and tangy
|
|
713
716
|
›Strawberry Red and sweet [Popular]
|
|
714
717
|
|
|
715
|
-
Vegetables
|
|
716
|
-
Carrot Orange and crunchy [Healthy]
|
|
717
|
-
Lettuce Green and fresh
|
|
718
718
|
|
|
719
719
|
|
|
720
720
|
↑↓ navigate ^k actions
|
|
@@ -736,8 +736,6 @@ test('list scrollbox scrolling with sections', async () => {
|
|
|
736
736
|
|
|
737
737
|
> Search items...
|
|
738
738
|
|
|
739
|
-
|
|
740
|
-
Vegetables
|
|
741
739
|
Carrot Orange and crunchy [Healthy]
|
|
742
740
|
Lettuce Green and fresh
|
|
743
741
|
›Broccoli Green florets [Healthy]
|
|
@@ -746,6 +744,8 @@ test('list scrollbox scrolling with sections', async () => {
|
|
|
746
744
|
Cucumber Cool and crisp
|
|
747
745
|
Bell Pepper Colorful and crunchy [Fresh]
|
|
748
746
|
|
|
747
|
+
Bread Freshly baked Today [New]
|
|
748
|
+
|
|
749
749
|
|
|
750
750
|
↑↓ navigate ^k actions
|
|
751
751
|
|
|
@@ -30,7 +30,7 @@ test('detail renders markdown with headings, lists, links, tables, code and diag
|
|
|
30
30
|
|
|
31
31
|
█
|
|
32
32
|
█
|
|
33
|
-
Architecture Overview
|
|
33
|
+
Architecture Overview
|
|
34
34
|
|
|
35
35
|
This document describes the system architecture.
|
|
36
36
|
|
|
@@ -42,6 +42,7 @@ test('detail renders markdown with headings, lists, links, tables, code and diag
|
|
|
42
42
|
- Server - processes requests
|
|
43
43
|
- Database - stores data
|
|
44
44
|
|
|
45
|
+
|
|
45
46
|
Links
|
|
46
47
|
|
|
47
48
|
Check out the GitHub repository for the source code.
|
|
@@ -90,7 +91,6 @@ test('detail renders markdown with headings, lists, links, tables, code and diag
|
|
|
90
91
|
|
|
91
92
|
Code Example
|
|
92
93
|
|
|
93
|
-
interface Config {
|
|
94
94
|
|
|
95
95
|
|
|
96
96
|
esc go back powered by termcast
|
|
@@ -117,9 +117,8 @@ test('detail renders markdown with headings, lists, links, tables, code and diag
|
|
|
117
117
|
expect(text).toContain('┌─')
|
|
118
118
|
expect(text).toContain('─┐')
|
|
119
119
|
expect(text).toContain('Process')
|
|
120
|
-
// Code block header visible (content may need scroll)
|
|
120
|
+
// Code block header visible (content may need scroll to see full block)
|
|
121
121
|
expect(text).toContain('Code Example')
|
|
122
|
-
expect(text).toContain('interface Config')
|
|
123
122
|
}, 30000)
|
|
124
123
|
|
|
125
124
|
test('links have distinct cyan color from bold/heading text', async () => {
|
|
@@ -51,6 +51,7 @@ test('file picker shows form fields', async () => {
|
|
|
51
51
|
└
|
|
52
52
|
|
|
53
53
|
|
|
54
|
+
ctrl ↵ submit tab navigate ^k actions
|
|
54
55
|
|
|
55
56
|
|
|
56
57
|
|
|
@@ -76,7 +77,6 @@ test('file picker shows form fields', async () => {
|
|
|
76
77
|
|
|
77
78
|
|
|
78
79
|
|
|
79
|
-
ctrl ↵ submit tab navigate ^k actions
|
|
80
80
|
|
|
81
81
|
"
|
|
82
82
|
`)
|