epiq 0.0.0

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.
Files changed (108) hide show
  1. package/dist/app.d.ts +5 -0
  2. package/dist/app.js +12 -0
  3. package/dist/board/actions/board-action-map.d.ts +11 -0
  4. package/dist/board/actions/board-action-map.js +11 -0
  5. package/dist/board/actions/move-actions-routes.d.ts +4 -0
  6. package/dist/board/actions/move-actions-routes.js +31 -0
  7. package/dist/board/actions/move-actions.d.ts +5 -0
  8. package/dist/board/actions/move-actions.js +49 -0
  9. package/dist/board/board-action-map.d.ts +9 -0
  10. package/dist/board/board-action-map.js +7 -0
  11. package/dist/board/components/Board.d.ts +6 -0
  12. package/dist/board/components/Board.js +19 -0
  13. package/dist/board/components/Help.d.ts +4 -0
  14. package/dist/board/components/Help.js +21 -0
  15. package/dist/board/components/Logo.d.ts +2 -0
  16. package/dist/board/components/Logo.js +21 -0
  17. package/dist/board/components/ScrollBox.d.ts +9 -0
  18. package/dist/board/components/ScrollBox.js +22 -0
  19. package/dist/board/components/Swimlane.d.ts +8 -0
  20. package/dist/board/components/Swimlane.js +10 -0
  21. package/dist/board/components/Swimlanes.d.ts +8 -0
  22. package/dist/board/components/Swimlanes.js +20 -0
  23. package/dist/board/components/TicketListItem.d.ts +6 -0
  24. package/dist/board/components/TicketListItem.js +12 -0
  25. package/dist/board/components/TicketUI.d.ts +8 -0
  26. package/dist/board/components/TicketUI.js +9 -0
  27. package/dist/board/mock/board.d.ts +2 -0
  28. package/dist/board/mock/board.js +474 -0
  29. package/dist/board/model/board.model.d.ts +26 -0
  30. package/dist/board/model/board.model.js +6 -0
  31. package/dist/board/move-actions-routes.d.ts +4 -0
  32. package/dist/board/move-actions-routes.js +31 -0
  33. package/dist/board/move-actions.d.ts +5 -0
  34. package/dist/board/move-actions.js +49 -0
  35. package/dist/board/render/color.d.ts +7 -0
  36. package/dist/board/render/color.js +21 -0
  37. package/dist/cli.d.ts +2 -0
  38. package/dist/cli.js +57 -0
  39. package/dist/components/Board.d.ts +6 -0
  40. package/dist/components/Board.js +15 -0
  41. package/dist/components/Help.d.ts +4 -0
  42. package/dist/components/Help.js +21 -0
  43. package/dist/components/Swimlane.d.ts +8 -0
  44. package/dist/components/Swimlane.js +10 -0
  45. package/dist/components/TicketListItem.d.ts +6 -0
  46. package/dist/components/TicketListItem.js +12 -0
  47. package/dist/lib/actions/board-action-map.d.ts +9 -0
  48. package/dist/lib/actions/board-action-map.js +7 -0
  49. package/dist/lib/actions/move-actions-utils.d.ts +5 -0
  50. package/dist/lib/actions/move-actions-utils.js +43 -0
  51. package/dist/lib/actions/move-actions.d.ts +4 -0
  52. package/dist/lib/actions/move-actions.js +31 -0
  53. package/dist/lib/board/board-action-map.d.ts +9 -0
  54. package/dist/lib/board/board-action-map.js +7 -0
  55. package/dist/lib/board/move-actions-routes.d.ts +4 -0
  56. package/dist/lib/board/move-actions-routes.js +31 -0
  57. package/dist/lib/board/move-actions.d.ts +5 -0
  58. package/dist/lib/board/move-actions.js +43 -0
  59. package/dist/lib/board-utils.d.ts +7 -0
  60. package/dist/lib/board-utils.js +33 -0
  61. package/dist/lib/default-actions-routes.d.ts +4 -0
  62. package/dist/lib/default-actions-routes.js +47 -0
  63. package/dist/lib/default-actions.d.ts +4 -0
  64. package/dist/lib/default-actions.js +47 -0
  65. package/dist/lib/navigation-context.d.ts +16 -0
  66. package/dist/lib/navigation-context.js +1 -0
  67. package/dist/lib/navigation.d.ts +10 -0
  68. package/dist/lib/navigation.js +74 -0
  69. package/dist/lib/render-utils.d.ts +10 -0
  70. package/dist/lib/render-utils.js +12 -0
  71. package/dist/lib/state.d.ts +8 -0
  72. package/dist/lib/state.js +8 -0
  73. package/dist/lib/types/action-map.model.d.ts +14 -0
  74. package/dist/lib/types/action-map.model.js +4 -0
  75. package/dist/lib/types/board.model.d.ts +21 -0
  76. package/dist/lib/types/board.model.js +5 -0
  77. package/dist/lib/types/navigation.model.d.ts +9 -0
  78. package/dist/lib/types/navigation.model.js +1 -0
  79. package/dist/lib/utils/array-utils.d.ts +5 -0
  80. package/dist/lib/utils/array-utils.js +7 -0
  81. package/dist/lib/utils/default-action-utils.d.ts +7 -0
  82. package/dist/lib/utils/default-action-utils.js +50 -0
  83. package/dist/lib/utils/default-actions.d.ts +7 -0
  84. package/dist/lib/utils/default-actions.js +50 -0
  85. package/dist/lib/utils/key-intent.d.ts +16 -0
  86. package/dist/lib/utils/key-intent.js +65 -0
  87. package/dist/lib/utils.d.ts +10 -0
  88. package/dist/lib/utils.js +12 -0
  89. package/dist/mock/board.d.ts +2 -0
  90. package/dist/mock/board.js +139 -0
  91. package/dist/navigation/actions/default-actions-routes.d.ts +4 -0
  92. package/dist/navigation/actions/default-actions-routes.js +47 -0
  93. package/dist/navigation/actions/default-actions.d.ts +7 -0
  94. package/dist/navigation/actions/default-actions.js +48 -0
  95. package/dist/navigation/model/action-map.model.d.ts +14 -0
  96. package/dist/navigation/model/action-map.model.js +4 -0
  97. package/dist/navigation/model/navigation-ctx.model.d.ts +16 -0
  98. package/dist/navigation/model/navigation-ctx.model.js +2 -0
  99. package/dist/navigation/model/navigation-tree.model.d.ts +9 -0
  100. package/dist/navigation/model/navigation-tree.model.js +1 -0
  101. package/dist/navigation/navigation.d.ts +10 -0
  102. package/dist/navigation/navigation.js +74 -0
  103. package/dist/navigation/state/state.d.ts +11 -0
  104. package/dist/navigation/state/state.js +10 -0
  105. package/dist/navigation/utils/key-intent.d.ts +16 -0
  106. package/dist/navigation/utils/key-intent.js +65 -0
  107. package/package.json +57 -0
  108. package/readme.md +37 -0
@@ -0,0 +1,474 @@
1
+ import { BoardItemTypes } from '../model/board.model.js';
2
+ export const board = {
3
+ id: 'b1',
4
+ isSelected: false,
5
+ name: 'Product Development Board',
6
+ actionContext: 'BOARD',
7
+ childrenRenderAxis: 'horizontal',
8
+ children: [
9
+ {
10
+ isSelected: false,
11
+ id: 's1',
12
+ name: 'To Do',
13
+ childrenRenderAxis: 'vertical',
14
+ actionContext: BoardItemTypes.SWIMLANE,
15
+ enableChildNavigationAcrossContainers: true,
16
+ children: [
17
+ {
18
+ isSelected: false,
19
+ id: 't1',
20
+ name: 'Setup CI/CD pipeline',
21
+ actionContext: BoardItemTypes.TICKET_LIST_ITEM,
22
+ childrenRenderAxis: 'vertical',
23
+ children: [
24
+ {
25
+ isSelected: false,
26
+ id: 't1-desc',
27
+ name: 'Configure GitHub Actions for test, build, and deploy stages.',
28
+ actionContext: BoardItemTypes.TICKET,
29
+ childrenRenderAxis: 'vertical',
30
+ children: [],
31
+ },
32
+ ],
33
+ },
34
+ {
35
+ isSelected: false,
36
+ id: 't2',
37
+ name: 'Create API contract for auth service',
38
+ actionContext: BoardItemTypes.TICKET_LIST_ITEM,
39
+ childrenRenderAxis: 'vertical',
40
+ children: [
41
+ {
42
+ isSelected: false,
43
+ id: 't2-desc',
44
+ name: 'Define request/response formats, error handling, and versioning.',
45
+ actionContext: BoardItemTypes.TICKET,
46
+ childrenRenderAxis: 'vertical',
47
+ children: [],
48
+ },
49
+ ],
50
+ },
51
+ {
52
+ isSelected: false,
53
+ id: 't3',
54
+ name: 'Draft OKRs for Q4',
55
+ actionContext: BoardItemTypes.TICKET_LIST_ITEM,
56
+ childrenRenderAxis: 'vertical',
57
+ children: [
58
+ {
59
+ isSelected: false,
60
+ id: 't3-desc',
61
+ name: 'Collaborate with leads to define team goals and key results.',
62
+ actionContext: BoardItemTypes.TICKET,
63
+ childrenRenderAxis: 'vertical',
64
+ children: [],
65
+ },
66
+ ],
67
+ },
68
+ {
69
+ isSelected: false,
70
+ id: 't11',
71
+ name: 'Define system architecture diagram',
72
+ actionContext: BoardItemTypes.TICKET_LIST_ITEM,
73
+ childrenRenderAxis: 'vertical',
74
+ children: [
75
+ {
76
+ isSelected: false,
77
+ id: 't11-desc',
78
+ name: 'Create high-level overview of services, databases, and communication flows.',
79
+ actionContext: BoardItemTypes.TICKET,
80
+ childrenRenderAxis: 'vertical',
81
+ children: [],
82
+ },
83
+ ],
84
+ },
85
+ {
86
+ isSelected: false,
87
+ id: 't12',
88
+ name: 'Setup monitoring and alerting',
89
+ actionContext: BoardItemTypes.TICKET_LIST_ITEM,
90
+ childrenRenderAxis: 'vertical',
91
+ children: [
92
+ {
93
+ isSelected: false,
94
+ id: 't12-desc',
95
+ name: 'Integrate tools like Prometheus and Grafana; define alert thresholds.',
96
+ actionContext: BoardItemTypes.TICKET,
97
+ childrenRenderAxis: 'vertical',
98
+ children: [],
99
+ },
100
+ ],
101
+ },
102
+ {
103
+ isSelected: false,
104
+ id: 't13',
105
+ name: 'Research data privacy regulations',
106
+ actionContext: BoardItemTypes.TICKET_LIST_ITEM,
107
+ childrenRenderAxis: 'vertical',
108
+ children: [
109
+ {
110
+ isSelected: false,
111
+ id: 't13-desc',
112
+ name: 'Identify GDPR and CCPA implications for data handling and user consent.',
113
+ actionContext: BoardItemTypes.TICKET,
114
+ childrenRenderAxis: 'vertical',
115
+ children: [],
116
+ },
117
+ ],
118
+ },
119
+ {
120
+ isSelected: false,
121
+ id: 't14',
122
+ name: 'Draft project onboarding guide',
123
+ actionContext: BoardItemTypes.TICKET_LIST_ITEM,
124
+ childrenRenderAxis: 'vertical',
125
+ children: [
126
+ {
127
+ isSelected: false,
128
+ id: 't14-desc',
129
+ name: 'Write setup instructions, repo structure, and coding standards.',
130
+ actionContext: BoardItemTypes.TICKET,
131
+ childrenRenderAxis: 'vertical',
132
+ children: [],
133
+ },
134
+ ],
135
+ },
136
+ {
137
+ isSelected: false,
138
+ id: 't15',
139
+ name: 'Evaluate state management solutions',
140
+ actionContext: BoardItemTypes.TICKET_LIST_ITEM,
141
+ childrenRenderAxis: 'vertical',
142
+ children: [
143
+ {
144
+ isSelected: false,
145
+ id: 't15-desc',
146
+ name: 'Compare Redux Toolkit, Zustand, and Jotai for frontend scalability.',
147
+ actionContext: BoardItemTypes.TICKET,
148
+ childrenRenderAxis: 'vertical',
149
+ children: [],
150
+ },
151
+ ],
152
+ },
153
+ {
154
+ isSelected: false,
155
+ id: 't16',
156
+ name: 'Write integration test plan',
157
+ actionContext: BoardItemTypes.TICKET_LIST_ITEM,
158
+ childrenRenderAxis: 'vertical',
159
+ children: [
160
+ {
161
+ isSelected: false,
162
+ id: 't16-desc',
163
+ name: 'Define test scenarios covering API and UI flows.',
164
+ actionContext: BoardItemTypes.TICKET,
165
+ childrenRenderAxis: 'vertical',
166
+ children: [],
167
+ },
168
+ ],
169
+ },
170
+ {
171
+ isSelected: false,
172
+ id: 't17',
173
+ name: 'Create performance benchmarks',
174
+ actionContext: BoardItemTypes.TICKET_LIST_ITEM,
175
+ childrenRenderAxis: 'vertical',
176
+ children: [
177
+ {
178
+ isSelected: false,
179
+ id: 't17-desc',
180
+ name: 'Set baseline response times for key endpoints and UI interactions.',
181
+ actionContext: BoardItemTypes.TICKET,
182
+ childrenRenderAxis: 'vertical',
183
+ children: [],
184
+ },
185
+ ],
186
+ },
187
+ {
188
+ isSelected: false,
189
+ id: 't18',
190
+ name: 'Design error handling strategy',
191
+ actionContext: BoardItemTypes.TICKET_LIST_ITEM,
192
+ childrenRenderAxis: 'vertical',
193
+ children: [
194
+ {
195
+ isSelected: false,
196
+ id: 't18-desc',
197
+ name: 'Standardize client and server error formats and fallback UIs.',
198
+ actionContext: BoardItemTypes.TICKET,
199
+ childrenRenderAxis: 'vertical',
200
+ children: [],
201
+ },
202
+ ],
203
+ },
204
+ {
205
+ isSelected: false,
206
+ id: 't19',
207
+ name: 'Define logging strategy',
208
+ actionContext: BoardItemTypes.TICKET_LIST_ITEM,
209
+ childrenRenderAxis: 'vertical',
210
+ children: [
211
+ {
212
+ isSelected: false,
213
+ id: 't19-desc',
214
+ name: 'Choose log levels, format, and storage mechanisms for observability.',
215
+ actionContext: BoardItemTypes.TICKET,
216
+ childrenRenderAxis: 'vertical',
217
+ children: [],
218
+ },
219
+ ],
220
+ },
221
+ {
222
+ isSelected: false,
223
+ id: 't20',
224
+ name: 'Setup feature flag framework',
225
+ actionContext: BoardItemTypes.TICKET_LIST_ITEM,
226
+ childrenRenderAxis: 'vertical',
227
+ children: [
228
+ {
229
+ isSelected: false,
230
+ id: 't20-desc',
231
+ name: 'Enable gradual rollouts using LaunchDarkly or Unleash.',
232
+ actionContext: BoardItemTypes.TICKET,
233
+ childrenRenderAxis: 'vertical',
234
+ children: [],
235
+ },
236
+ ],
237
+ },
238
+ {
239
+ isSelected: false,
240
+ id: 't21',
241
+ name: 'Conduct competitor analysis',
242
+ actionContext: BoardItemTypes.TICKET_LIST_ITEM,
243
+ childrenRenderAxis: 'vertical',
244
+ children: [
245
+ {
246
+ isSelected: false,
247
+ id: 't21-desc',
248
+ name: 'List comparable products and key differentiators for positioning.',
249
+ actionContext: BoardItemTypes.TICKET,
250
+ childrenRenderAxis: 'vertical',
251
+ children: [],
252
+ },
253
+ ],
254
+ },
255
+ {
256
+ isSelected: false,
257
+ id: 't22',
258
+ name: 'Organize kick-off meeting',
259
+ actionContext: BoardItemTypes.TICKET_LIST_ITEM,
260
+ childrenRenderAxis: 'vertical',
261
+ children: [
262
+ {
263
+ isSelected: false,
264
+ id: 't22-desc',
265
+ name: 'Schedule initial sync with stakeholders and present roadmap.',
266
+ actionContext: BoardItemTypes.TICKET,
267
+ childrenRenderAxis: 'vertical',
268
+ children: [],
269
+ },
270
+ ],
271
+ },
272
+ {
273
+ isSelected: false,
274
+ id: 't23',
275
+ name: 'Provision cloud infrastructure',
276
+ actionContext: BoardItemTypes.TICKET_LIST_ITEM,
277
+ childrenRenderAxis: 'vertical',
278
+ children: [
279
+ {
280
+ isSelected: false,
281
+ id: 't23-desc',
282
+ name: 'Set up base AWS resources using Terraform templates.',
283
+ actionContext: BoardItemTypes.TICKET,
284
+ childrenRenderAxis: 'vertical',
285
+ children: [],
286
+ },
287
+ ],
288
+ },
289
+ {
290
+ isSelected: false,
291
+ id: 't24',
292
+ name: 'Define user personas',
293
+ actionContext: BoardItemTypes.TICKET_LIST_ITEM,
294
+ childrenRenderAxis: 'vertical',
295
+ children: [
296
+ {
297
+ isSelected: false,
298
+ id: 't24-desc',
299
+ name: 'Collaborate with design to outline primary users and their needs.',
300
+ actionContext: BoardItemTypes.TICKET,
301
+ childrenRenderAxis: 'vertical',
302
+ children: [],
303
+ },
304
+ ],
305
+ },
306
+ {
307
+ isSelected: false,
308
+ id: 't25',
309
+ name: 'Plan retro cadence and format',
310
+ actionContext: BoardItemTypes.TICKET_LIST_ITEM,
311
+ childrenRenderAxis: 'vertical',
312
+ children: [
313
+ {
314
+ isSelected: false,
315
+ id: 't25-desc',
316
+ name: 'Decide on tools, frequency, and feedback channels for retrospectives.',
317
+ actionContext: BoardItemTypes.TICKET,
318
+ childrenRenderAxis: 'vertical',
319
+ children: [],
320
+ },
321
+ ],
322
+ },
323
+ ],
324
+ },
325
+ {
326
+ isSelected: false,
327
+ id: 's2',
328
+ name: 'In Progress',
329
+ childrenRenderAxis: 'vertical',
330
+ actionContext: 'SWIMLANE',
331
+ enableChildNavigationAcrossContainers: true,
332
+ children: [],
333
+ },
334
+ {
335
+ isSelected: false,
336
+ id: 's3',
337
+ name: 'Review',
338
+ childrenRenderAxis: 'vertical',
339
+ actionContext: 'SWIMLANE',
340
+ enableChildNavigationAcrossContainers: true,
341
+ children: [
342
+ {
343
+ isSelected: false,
344
+ id: 't4',
345
+ name: 'Implement user login flow',
346
+ actionContext: BoardItemTypes.TICKET_LIST_ITEM,
347
+ childrenRenderAxis: 'vertical',
348
+ children: [
349
+ {
350
+ isSelected: false,
351
+ id: 't4-desc',
352
+ name: 'Integrate frontend with backend auth API and handle edge cases.',
353
+ actionContext: BoardItemTypes.TICKET,
354
+ childrenRenderAxis: 'vertical',
355
+ children: [],
356
+ },
357
+ ],
358
+ },
359
+ {
360
+ isSelected: false,
361
+ id: 't5',
362
+ name: 'Design new dashboard layout',
363
+ actionContext: BoardItemTypes.TICKET_LIST_ITEM,
364
+ childrenRenderAxis: 'vertical',
365
+ children: [
366
+ {
367
+ isSelected: false,
368
+ id: 't5-desc',
369
+ name: 'Collaborate with UX to create a grid-based responsive dashboard.',
370
+ actionContext: BoardItemTypes.TICKET,
371
+ childrenRenderAxis: 'vertical',
372
+ children: [],
373
+ },
374
+ ],
375
+ },
376
+ {
377
+ isSelected: false,
378
+ id: 't6',
379
+ name: 'Accessibility audit',
380
+ actionContext: BoardItemTypes.TICKET_LIST_ITEM,
381
+ childrenRenderAxis: 'vertical',
382
+ children: [
383
+ {
384
+ isSelected: false,
385
+ id: 't6-desc',
386
+ name: 'Evaluate color contrast, ARIA usage, and keyboard nav.',
387
+ actionContext: BoardItemTypes.TICKET,
388
+ childrenRenderAxis: 'vertical',
389
+ children: [],
390
+ },
391
+ ],
392
+ },
393
+ {
394
+ isSelected: false,
395
+ id: 't7',
396
+ name: 'Code review for analytics module',
397
+ actionContext: BoardItemTypes.TICKET_LIST_ITEM,
398
+ childrenRenderAxis: 'vertical',
399
+ children: [
400
+ {
401
+ isSelected: false,
402
+ id: 't7-desc',
403
+ name: 'Ensure test coverage, types, and data validation are in place.',
404
+ actionContext: BoardItemTypes.TICKET,
405
+ childrenRenderAxis: 'vertical',
406
+ children: [],
407
+ },
408
+ ],
409
+ },
410
+ {
411
+ isSelected: false,
412
+ id: 't8',
413
+ name: 'Review UI polish for mobile view',
414
+ actionContext: BoardItemTypes.TICKET_LIST_ITEM,
415
+ childrenRenderAxis: 'vertical',
416
+ children: [
417
+ {
418
+ isSelected: false,
419
+ id: 't8-desc',
420
+ name: 'Verify spacing, responsiveness, and visual hierarchy.',
421
+ actionContext: BoardItemTypes.TICKET,
422
+ childrenRenderAxis: 'vertical',
423
+ children: [],
424
+ },
425
+ ],
426
+ },
427
+ ],
428
+ },
429
+ {
430
+ isSelected: false,
431
+ id: 's4',
432
+ name: 'Done',
433
+ childrenRenderAxis: 'vertical',
434
+ actionContext: 'SWIMLANE',
435
+ enableChildNavigationAcrossContainers: true,
436
+ children: [
437
+ {
438
+ isSelected: false,
439
+ id: 't9',
440
+ name: 'Setup Storybook',
441
+ actionContext: BoardItemTypes.TICKET_LIST_ITEM,
442
+ childrenRenderAxis: 'vertical',
443
+ children: [
444
+ {
445
+ isSelected: false,
446
+ id: 't9-desc',
447
+ name: 'Document reusable components and tokens in Storybook.',
448
+ actionContext: BoardItemTypes.TICKET,
449
+ childrenRenderAxis: 'vertical',
450
+ children: [],
451
+ },
452
+ ],
453
+ },
454
+ {
455
+ isSelected: false,
456
+ id: 't10',
457
+ name: 'Deploy v1.2 to staging',
458
+ actionContext: BoardItemTypes.TICKET_LIST_ITEM,
459
+ childrenRenderAxis: 'vertical',
460
+ children: [
461
+ {
462
+ isSelected: false,
463
+ id: 't10-desc',
464
+ name: 'All pipelines green. Ready for product team QA.',
465
+ actionContext: BoardItemTypes.TICKET,
466
+ childrenRenderAxis: 'vertical',
467
+ children: [],
468
+ },
469
+ ],
470
+ },
471
+ ],
472
+ },
473
+ ],
474
+ };
@@ -0,0 +1,26 @@
1
+ import type { NavigationTree } from '../../navigation/model/navigation-tree.model.js';
2
+ export declare const BoardItemTypes: {
3
+ readonly TICKET: "TICKET";
4
+ readonly TICKET_LIST_ITEM: "TICKET_LIST_ITEM";
5
+ readonly SWIMLANE: "SWIMLANE";
6
+ readonly BOARD: "BOARD";
7
+ };
8
+ export type Board = NavigationTree<{
9
+ actionContext: (typeof BoardItemTypes)['BOARD'];
10
+ }> & {
11
+ children: Swimlane[];
12
+ };
13
+ export type Swimlane = NavigationTree<{
14
+ actionContext: (typeof BoardItemTypes)['SWIMLANE'];
15
+ enableChildNavigationAcrossContainers: true;
16
+ }> & {
17
+ children: TicketListItem[];
18
+ };
19
+ export type TicketListItem = NavigationTree<{
20
+ actionContext: (typeof BoardItemTypes)['TICKET_LIST_ITEM'];
21
+ }> & {
22
+ children: Ticket[];
23
+ };
24
+ export type Ticket = NavigationTree<{
25
+ actionContext: (typeof BoardItemTypes)['TICKET'];
26
+ }>;
@@ -0,0 +1,6 @@
1
+ export const BoardItemTypes = {
2
+ TICKET: 'TICKET',
3
+ TICKET_LIST_ITEM: 'TICKET_LIST_ITEM',
4
+ SWIMLANE: 'SWIMLANE',
5
+ BOARD: 'BOARD',
6
+ };
@@ -0,0 +1,4 @@
1
+ import { ActionEntry } from '../navigation/model/action-map.model.js';
2
+ import { NavigateCtx } from '../navigation/model/navigation-ctx.model.js';
3
+ export declare const moveWithinParent: ActionEntry<[NavigateCtx]>[];
4
+ export declare const moveAcrossParents: ActionEntry<[NavigateCtx]>[];
@@ -0,0 +1,31 @@
1
+ import { Mode } from '../navigation/model/action-map.model.js';
2
+ import { KeyIntent } from '../navigation/utils/key-intent.js';
3
+ import { moveChildNextWithinParent, moveChildPreviousWithinParent, moveChildToNextParent, moveChildToPreviousParent, } from './move-actions.js';
4
+ export const moveWithinParent = [
5
+ {
6
+ mode: Mode.DEFAULT,
7
+ description: '[SHIFT + ARROW KEYS] Move item',
8
+ },
9
+ {
10
+ intent: KeyIntent.MovePreviousItem,
11
+ mode: Mode.DEFAULT,
12
+ action: moveChildPreviousWithinParent,
13
+ },
14
+ {
15
+ intent: KeyIntent.MoveNextItem,
16
+ mode: Mode.DEFAULT,
17
+ action: moveChildNextWithinParent,
18
+ },
19
+ ];
20
+ export const moveAcrossParents = [
21
+ {
22
+ intent: KeyIntent.MoveToNextContainer,
23
+ mode: Mode.DEFAULT,
24
+ action: moveChildToNextParent,
25
+ },
26
+ {
27
+ intent: KeyIntent.MoveToPreviousContainer,
28
+ mode: Mode.DEFAULT,
29
+ action: moveChildToPreviousParent,
30
+ },
31
+ ];
@@ -0,0 +1,5 @@
1
+ import { NavigateCtx } from '../navigation/model/navigation-ctx.model.js';
2
+ export declare const moveChildToNextParent: (ctx: NavigateCtx) => void;
3
+ export declare const moveChildToPreviousParent: (ctx: NavigateCtx) => void;
4
+ export declare const moveChildPreviousWithinParent: (ctx: NavigateCtx) => void;
5
+ export declare const moveChildNextWithinParent: (ctx: NavigateCtx) => void;
@@ -0,0 +1,49 @@
1
+ function moveItemInArray({ array, from, to, }) {
2
+ if (from < 0 || from >= array.length || to < 0 || to >= array.length)
3
+ return;
4
+ const [item] = array.splice(from, 1);
5
+ if (item)
6
+ array.splice(to, 0, item);
7
+ }
8
+ function moveNodeToSiblingContainer(ctx, direction) {
9
+ const ancestors = ctx.breadCrumb;
10
+ const parent = ancestors.at(-1);
11
+ const grandParent = ancestors.at(-2);
12
+ if (!parent || !grandParent)
13
+ return;
14
+ const parentIndex = grandParent.children.findIndex(x => x.id === parent.id);
15
+ const targetIndex = parentIndex + direction;
16
+ if (parentIndex < 0 ||
17
+ targetIndex < 0 ||
18
+ targetIndex >= grandParent.children.length)
19
+ return;
20
+ const sibling = grandParent.children[targetIndex];
21
+ if (!sibling)
22
+ return;
23
+ if (!sibling?.children?.length && !Array.isArray(sibling.children))
24
+ return;
25
+ const currentIndex = ctx._selectedIndex;
26
+ if (currentIndex < 0 || currentIndex >= parent.children.length)
27
+ return;
28
+ const [node] = parent.children.splice(currentIndex, 1);
29
+ sibling.children.push(node);
30
+ const newBreadCrumb = [...ctx.breadCrumb.slice(0, -1), sibling];
31
+ const newIndex = sibling.children.length - 1;
32
+ ctx.reInvokeNavigate(newIndex, newBreadCrumb);
33
+ }
34
+ export const moveChildToNextParent = (ctx) => moveNodeToSiblingContainer(ctx, 1);
35
+ export const moveChildToPreviousParent = (ctx) => moveNodeToSiblingContainer(ctx, -1);
36
+ function moveChildWithinParent(ctx, direction) {
37
+ const from = ctx._selectedIndex;
38
+ const to = from + direction;
39
+ if (to < 0 || to >= ctx.navigationNode.children.length)
40
+ return;
41
+ moveItemInArray({
42
+ array: ctx.navigationNode.children,
43
+ from,
44
+ to,
45
+ });
46
+ ctx.select(to);
47
+ }
48
+ export const moveChildPreviousWithinParent = (ctx) => moveChildWithinParent(ctx, -1);
49
+ export const moveChildNextWithinParent = (ctx) => moveChildWithinParent(ctx, 1);
@@ -0,0 +1,7 @@
1
+ /**
2
+ * Applies ANSI color codes to a string for terminal output.
3
+ * @param text The text to colorize
4
+ * @param color One of: black, red, green, yellow, blue, magenta, cyan, white
5
+ * @returns A colorized string using ANSI escape codes
6
+ */
7
+ export declare function highlight(text: string, color: string): string;
@@ -0,0 +1,21 @@
1
+ /**
2
+ * Applies ANSI color codes to a string for terminal output.
3
+ * @param text The text to colorize
4
+ * @param color One of: black, red, green, yellow, blue, magenta, cyan, white
5
+ * @returns A colorized string using ANSI escape codes
6
+ */
7
+ export function highlight(text, color) {
8
+ const colors = {
9
+ black: '\x1b[30m',
10
+ red: '\x1b[31m',
11
+ green: '\x1b[32m',
12
+ yellow: '\x1b[33m',
13
+ blue: '\x1b[34m',
14
+ magenta: '\x1b[35m',
15
+ cyan: '\x1b[36m',
16
+ white: '\x1b[37m',
17
+ reset: '\x1b[0m',
18
+ };
19
+ const code = colors[color.toLowerCase()] ?? '';
20
+ return `${code}${text}${colors['reset']}`;
21
+ }
package/dist/cli.d.ts ADDED
@@ -0,0 +1,2 @@
1
+ #!/usr/bin/env node
2
+ export declare const main: () => void;