@almadar/std 14.27.0 → 14.28.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 (25) hide show
  1. package/behaviors/registry/app/atoms/std-approval-chain.orb +106 -0
  2. package/behaviors/registry/app/atoms/std-multi-party-transaction.orb +130 -0
  3. package/behaviors/registry/app/atoms/std-pipeline.orb +139 -0
  4. package/behaviors/registry/app/atoms/std-recurring-schedule.orb +94 -0
  5. package/behaviors/registry/app/atoms/std-timeline.orb +108 -0
  6. package/behaviors/registry/app/atoms/std-wizard-branching.orb +129 -0
  7. package/behaviors/registry/core/atoms/std-board.orb +1367 -0
  8. package/behaviors/registry/core/atoms/std-event-log.orb +777 -0
  9. package/behaviors/registry/core/atoms/std-multi-party-flow.orb +1313 -0
  10. package/behaviors/registry/core/atoms/std-recurrence.orb +937 -0
  11. package/behaviors/registry/core/atoms/std-step-flow.orb +1155 -0
  12. package/behaviors/registry/core/atoms/std-wizard.orb +1085 -0
  13. package/dist/behaviors/registry/app/atoms/std-approval-chain.orb +106 -0
  14. package/dist/behaviors/registry/app/atoms/std-multi-party-transaction.orb +130 -0
  15. package/dist/behaviors/registry/app/atoms/std-pipeline.orb +139 -0
  16. package/dist/behaviors/registry/app/atoms/std-recurring-schedule.orb +94 -0
  17. package/dist/behaviors/registry/app/atoms/std-timeline.orb +108 -0
  18. package/dist/behaviors/registry/app/atoms/std-wizard-branching.orb +129 -0
  19. package/dist/behaviors/registry/core/atoms/std-board.orb +1367 -0
  20. package/dist/behaviors/registry/core/atoms/std-event-log.orb +777 -0
  21. package/dist/behaviors/registry/core/atoms/std-multi-party-flow.orb +1313 -0
  22. package/dist/behaviors/registry/core/atoms/std-recurrence.orb +937 -0
  23. package/dist/behaviors/registry/core/atoms/std-step-flow.orb +1155 -0
  24. package/dist/behaviors/registry/core/atoms/std-wizard.orb +1085 -0
  25. package/package.json +1 -1
@@ -0,0 +1,777 @@
1
+ {
2
+ "name": "std-event-log",
3
+ "version": "1.0.0",
4
+ "description": "std-event-log — generic chronological event feed. Topology = loading / viewing / filtering / backfilling / error — adds a backfilling state for retroactive entries that pure-CRUD atoms can't express. Renders a timeline of events with filter controls and a backfill form.",
5
+ "orbitals": [
6
+ {
7
+ "name": "EventLogOrbital",
8
+ "entity": {
9
+ "name": "EventLogView",
10
+ "persistence": "runtime",
11
+ "fields": [
12
+ {
13
+ "name": "id",
14
+ "type": "string",
15
+ "required": true
16
+ },
17
+ {
18
+ "name": "entries",
19
+ "type": "array",
20
+ "default": [],
21
+ "items": {
22
+ "type": "object",
23
+ "properties": {
24
+ "kind": {
25
+ "name": "kind",
26
+ "type": "string"
27
+ },
28
+ "status": {
29
+ "name": "status",
30
+ "type": "string",
31
+ "values": [
32
+ "info",
33
+ "success",
34
+ "warning",
35
+ "error"
36
+ ]
37
+ },
38
+ "id": {
39
+ "name": "id",
40
+ "type": "string"
41
+ },
42
+ "icon": {
43
+ "name": "icon",
44
+ "type": "string"
45
+ },
46
+ "date": {
47
+ "name": "date",
48
+ "type": "string"
49
+ },
50
+ "title": {
51
+ "name": "title",
52
+ "type": "string"
53
+ },
54
+ "description": {
55
+ "name": "description",
56
+ "type": "string"
57
+ }
58
+ }
59
+ }
60
+ },
61
+ {
62
+ "name": "filterKind",
63
+ "type": "string",
64
+ "default": ""
65
+ },
66
+ {
67
+ "name": "backfillTitle",
68
+ "type": "string",
69
+ "default": ""
70
+ },
71
+ {
72
+ "name": "backfillDescription",
73
+ "type": "string",
74
+ "default": ""
75
+ },
76
+ {
77
+ "name": "backfillDate",
78
+ "type": "string",
79
+ "default": ""
80
+ },
81
+ {
82
+ "name": "backfillKind",
83
+ "type": "string",
84
+ "default": ""
85
+ },
86
+ {
87
+ "name": "errorMessage",
88
+ "type": "string",
89
+ "default": ""
90
+ }
91
+ ]
92
+ },
93
+ "traits": [
94
+ {
95
+ "name": "EventLogTimeline",
96
+ "category": "interaction",
97
+ "linkedEntity": "EventLogView",
98
+ "emits": [
99
+ {
100
+ "event": "OPEN_FILTER"
101
+ },
102
+ {
103
+ "event": "OPEN_BACKFILL"
104
+ },
105
+ {
106
+ "event": "APPLY_FILTER",
107
+ "payloadSchema": [
108
+ {
109
+ "name": "filterKind",
110
+ "type": "string"
111
+ }
112
+ ]
113
+ },
114
+ {
115
+ "event": "CLOSE_FILTER"
116
+ },
117
+ {
118
+ "event": "SAVE_BACKFILL",
119
+ "payloadSchema": [
120
+ {
121
+ "name": "data",
122
+ "type": "object"
123
+ }
124
+ ]
125
+ },
126
+ {
127
+ "event": "CANCEL_BACKFILL"
128
+ },
129
+ {
130
+ "event": "EventLogLoaded",
131
+ "payloadSchema": [
132
+ {
133
+ "name": "data",
134
+ "type": "[object]"
135
+ }
136
+ ]
137
+ },
138
+ {
139
+ "event": "EventLogLoadFailed",
140
+ "payloadSchema": [
141
+ {
142
+ "name": "error",
143
+ "type": "string"
144
+ },
145
+ {
146
+ "name": "code",
147
+ "type": "string"
148
+ }
149
+ ]
150
+ }
151
+ ],
152
+ "stateMachine": {
153
+ "states": [
154
+ {
155
+ "name": "loading",
156
+ "isInitial": true
157
+ },
158
+ {
159
+ "name": "viewing"
160
+ },
161
+ {
162
+ "name": "filtering"
163
+ },
164
+ {
165
+ "name": "backfilling"
166
+ },
167
+ {
168
+ "name": "error"
169
+ }
170
+ ],
171
+ "events": [
172
+ {
173
+ "key": "INIT",
174
+ "name": "Initialize"
175
+ },
176
+ {
177
+ "key": "EventLogLoaded",
178
+ "name": "Event log loaded",
179
+ "payloadSchema": [
180
+ {
181
+ "name": "data",
182
+ "type": "[object]"
183
+ }
184
+ ]
185
+ },
186
+ {
187
+ "key": "EventLogLoadFailed",
188
+ "name": "Event log load failed",
189
+ "payloadSchema": [
190
+ {
191
+ "name": "error",
192
+ "type": "string"
193
+ },
194
+ {
195
+ "name": "code",
196
+ "type": "string"
197
+ }
198
+ ]
199
+ },
200
+ {
201
+ "key": "EventLogSaved",
202
+ "name": "Event log saved",
203
+ "payloadSchema": [
204
+ {
205
+ "name": "row",
206
+ "type": "object"
207
+ }
208
+ ]
209
+ },
210
+ {
211
+ "key": "EventLogSaveFailed",
212
+ "name": "Event log save failed",
213
+ "payloadSchema": [
214
+ {
215
+ "name": "error",
216
+ "type": "string"
217
+ },
218
+ {
219
+ "name": "code",
220
+ "type": "string"
221
+ }
222
+ ]
223
+ },
224
+ {
225
+ "key": "OPEN_FILTER",
226
+ "name": "Open Filter"
227
+ },
228
+ {
229
+ "key": "OPEN_BACKFILL",
230
+ "name": "Open Backfill"
231
+ },
232
+ {
233
+ "key": "APPLY_FILTER",
234
+ "name": "Apply Filter",
235
+ "payloadSchema": [
236
+ {
237
+ "name": "filterKind",
238
+ "type": "string"
239
+ }
240
+ ]
241
+ },
242
+ {
243
+ "key": "CLOSE_FILTER",
244
+ "name": "Close Filter"
245
+ },
246
+ {
247
+ "key": "SAVE_BACKFILL",
248
+ "name": "Save Backfill",
249
+ "payloadSchema": [
250
+ {
251
+ "name": "data",
252
+ "type": "object"
253
+ }
254
+ ]
255
+ },
256
+ {
257
+ "key": "CANCEL_BACKFILL",
258
+ "name": "Cancel Backfill"
259
+ }
260
+ ],
261
+ "transitions": [
262
+ {
263
+ "from": "loading",
264
+ "to": "loading",
265
+ "event": "INIT",
266
+ "effects": [
267
+ [
268
+ "fetch",
269
+ "EventLogView",
270
+ {
271
+ "emit": {
272
+ "success": "EventLogLoaded",
273
+ "failure": "EventLogLoadFailed"
274
+ }
275
+ }
276
+ ],
277
+ [
278
+ "render-ui",
279
+ "main",
280
+ {
281
+ "type": "loading-state",
282
+ "title": "Loading activity…"
283
+ }
284
+ ]
285
+ ]
286
+ },
287
+ {
288
+ "from": "loading",
289
+ "to": "viewing",
290
+ "event": "EventLogLoaded",
291
+ "effects": [
292
+ [
293
+ "set",
294
+ "@entity.entries",
295
+ [
296
+ "array/map",
297
+ "@payload.data",
298
+ [
299
+ "fn",
300
+ "row",
301
+ {
302
+ "status": "@config.itemStatus",
303
+ "icon": "@config.itemIcon",
304
+ "kind": [
305
+ "object/get",
306
+ "@row",
307
+ "kind",
308
+ ""
309
+ ],
310
+ "title": [
311
+ "object/get",
312
+ "@row",
313
+ "title",
314
+ ""
315
+ ],
316
+ "id": [
317
+ "object/get",
318
+ "@row",
319
+ "id",
320
+ ""
321
+ ],
322
+ "description": [
323
+ "object/get",
324
+ "@row",
325
+ "description",
326
+ ""
327
+ ],
328
+ "date": [
329
+ "object/get",
330
+ "@row",
331
+ "createdAt",
332
+ ""
333
+ ]
334
+ }
335
+ ]
336
+ ]
337
+ ],
338
+ [
339
+ "render-ui",
340
+ "main",
341
+ {
342
+ "type": "stack",
343
+ "children": [
344
+ {
345
+ "align": "center",
346
+ "children": [
347
+ {
348
+ "type": "icon",
349
+ "name": "history"
350
+ },
351
+ {
352
+ "variant": "h3",
353
+ "content": "@config.title",
354
+ "type": "typography"
355
+ }
356
+ ],
357
+ "gap": "sm",
358
+ "direction": "horizontal",
359
+ "type": "stack"
360
+ },
361
+ {
362
+ "type": "divider"
363
+ },
364
+ {
365
+ "entity": "@entity.entries",
366
+ "fields": [],
367
+ "renderItem": [
368
+ "fn",
369
+ "entry",
370
+ {
371
+ "type": "card",
372
+ "children": [
373
+ {
374
+ "children": [
375
+ {
376
+ "type": "icon",
377
+ "name": "@entry.icon"
378
+ },
379
+ {
380
+ "children": [
381
+ {
382
+ "content": "@entry.title",
383
+ "type": "typography",
384
+ "variant": "h4"
385
+ },
386
+ {
387
+ "content": "@entry.description",
388
+ "type": "typography",
389
+ "variant": "caption",
390
+ "color": "muted"
391
+ },
392
+ {
393
+ "variant": "caption",
394
+ "content": "@entry.date",
395
+ "color": "muted",
396
+ "type": "typography"
397
+ }
398
+ ],
399
+ "type": "stack",
400
+ "direction": "vertical",
401
+ "gap": "xs"
402
+ },
403
+ {
404
+ "label": "@entry.kind",
405
+ "type": "badge",
406
+ "variant": "primary"
407
+ }
408
+ ],
409
+ "align": "center",
410
+ "gap": "sm",
411
+ "type": "stack",
412
+ "direction": "horizontal"
413
+ }
414
+ ]
415
+ }
416
+ ],
417
+ "type": "data-list",
418
+ "gap": "md"
419
+ },
420
+ {
421
+ "type": "stack",
422
+ "align": "center",
423
+ "gap": "sm",
424
+ "direction": "horizontal",
425
+ "children": [
426
+ {
427
+ "label": "Filter",
428
+ "action": "OPEN_FILTER",
429
+ "variant": "secondary",
430
+ "icon": "filter",
431
+ "type": "button"
432
+ },
433
+ {
434
+ "icon": "plus",
435
+ "label": "Add Entry",
436
+ "type": "button",
437
+ "variant": "primary",
438
+ "action": "OPEN_BACKFILL"
439
+ }
440
+ ]
441
+ }
442
+ ],
443
+ "gap": "md",
444
+ "direction": "vertical"
445
+ }
446
+ ]
447
+ ]
448
+ },
449
+ {
450
+ "from": "loading",
451
+ "to": "error",
452
+ "event": "EventLogLoadFailed",
453
+ "effects": [
454
+ [
455
+ "set",
456
+ "@entity.errorMessage",
457
+ "@payload.error"
458
+ ],
459
+ [
460
+ "render-ui",
461
+ "main",
462
+ {
463
+ "message": "@entity.errorMessage",
464
+ "type": "error-state",
465
+ "title": "Failed to load"
466
+ }
467
+ ]
468
+ ]
469
+ },
470
+ {
471
+ "from": "loading",
472
+ "to": "viewing",
473
+ "event": "EventLogSaved",
474
+ "effects": [
475
+ [
476
+ "render-ui",
477
+ "main",
478
+ {
479
+ "title": "Refreshing…",
480
+ "type": "loading-state"
481
+ }
482
+ ]
483
+ ]
484
+ },
485
+ {
486
+ "from": "loading",
487
+ "to": "error",
488
+ "event": "EventLogSaveFailed",
489
+ "effects": [
490
+ [
491
+ "set",
492
+ "@entity.errorMessage",
493
+ "@payload.error"
494
+ ],
495
+ [
496
+ "render-ui",
497
+ "main",
498
+ {
499
+ "title": "Save failed",
500
+ "message": "@entity.errorMessage",
501
+ "type": "error-state"
502
+ }
503
+ ]
504
+ ]
505
+ },
506
+ {
507
+ "from": "viewing",
508
+ "to": "filtering",
509
+ "event": "OPEN_FILTER",
510
+ "effects": [
511
+ [
512
+ "render-ui",
513
+ "main",
514
+ {
515
+ "direction": "vertical",
516
+ "children": [
517
+ {
518
+ "direction": "horizontal",
519
+ "gap": "sm",
520
+ "type": "stack",
521
+ "align": "center",
522
+ "children": [
523
+ {
524
+ "variant": "ghost",
525
+ "action": "CLOSE_FILTER",
526
+ "label": "Back",
527
+ "type": "button",
528
+ "icon": "arrow-left"
529
+ },
530
+ {
531
+ "type": "icon",
532
+ "name": "filter"
533
+ },
534
+ {
535
+ "content": "Filter Activity",
536
+ "variant": "h3",
537
+ "type": "typography"
538
+ }
539
+ ]
540
+ },
541
+ {
542
+ "type": "divider"
543
+ },
544
+ {
545
+ "cancelEvent": "CLOSE_FILTER",
546
+ "fields": [
547
+ "filterKind"
548
+ ],
549
+ "mode": "edit",
550
+ "submitEvent": "APPLY_FILTER",
551
+ "type": "form-section",
552
+ "entity": "@entity"
553
+ }
554
+ ],
555
+ "gap": "md",
556
+ "type": "stack"
557
+ }
558
+ ]
559
+ ]
560
+ },
561
+ {
562
+ "from": "viewing",
563
+ "to": "backfilling",
564
+ "event": "OPEN_BACKFILL",
565
+ "effects": [
566
+ [
567
+ "set",
568
+ "@entity.backfillTitle",
569
+ ""
570
+ ],
571
+ [
572
+ "set",
573
+ "@entity.backfillDescription",
574
+ ""
575
+ ],
576
+ [
577
+ "set",
578
+ "@entity.backfillDate",
579
+ ""
580
+ ],
581
+ [
582
+ "set",
583
+ "@entity.backfillKind",
584
+ ""
585
+ ],
586
+ [
587
+ "render-ui",
588
+ "main",
589
+ {
590
+ "children": [
591
+ {
592
+ "gap": "sm",
593
+ "align": "center",
594
+ "direction": "horizontal",
595
+ "type": "stack",
596
+ "children": [
597
+ {
598
+ "action": "CANCEL_BACKFILL",
599
+ "variant": "ghost",
600
+ "icon": "x",
601
+ "type": "button",
602
+ "label": "Cancel"
603
+ },
604
+ {
605
+ "name": "plus",
606
+ "type": "icon"
607
+ },
608
+ {
609
+ "content": "Add Retroactive Entry",
610
+ "type": "typography",
611
+ "variant": "h3"
612
+ }
613
+ ]
614
+ },
615
+ {
616
+ "type": "divider"
617
+ },
618
+ {
619
+ "type": "form-section",
620
+ "submitEvent": "SAVE_BACKFILL",
621
+ "fields": "@config.formFields",
622
+ "mode": "create",
623
+ "entity": "@entity",
624
+ "cancelEvent": "CANCEL_BACKFILL"
625
+ }
626
+ ],
627
+ "direction": "vertical",
628
+ "gap": "md",
629
+ "type": "stack"
630
+ }
631
+ ]
632
+ ]
633
+ },
634
+ {
635
+ "from": "filtering",
636
+ "to": "loading",
637
+ "event": "APPLY_FILTER",
638
+ "effects": [
639
+ [
640
+ "set",
641
+ "@entity.filterKind",
642
+ "@payload.filterKind"
643
+ ],
644
+ [
645
+ "render-ui",
646
+ "main",
647
+ {
648
+ "title": "Filtering…",
649
+ "type": "loading-state"
650
+ }
651
+ ]
652
+ ]
653
+ },
654
+ {
655
+ "from": "filtering",
656
+ "to": "viewing",
657
+ "event": "CLOSE_FILTER",
658
+ "effects": [
659
+ [
660
+ "render-ui",
661
+ "main",
662
+ {
663
+ "type": "loading-state",
664
+ "title": "Closing filter…"
665
+ }
666
+ ]
667
+ ]
668
+ },
669
+ {
670
+ "from": "backfilling",
671
+ "to": "loading",
672
+ "event": "SAVE_BACKFILL",
673
+ "effects": [
674
+ [
675
+ "render-ui",
676
+ "main",
677
+ {
678
+ "type": "loading-state",
679
+ "title": "Saving entry…"
680
+ }
681
+ ]
682
+ ]
683
+ },
684
+ {
685
+ "from": "backfilling",
686
+ "to": "viewing",
687
+ "event": "CANCEL_BACKFILL",
688
+ "effects": [
689
+ [
690
+ "render-ui",
691
+ "main",
692
+ {
693
+ "type": "loading-state",
694
+ "title": "Cancelling…"
695
+ }
696
+ ]
697
+ ]
698
+ },
699
+ {
700
+ "from": "error",
701
+ "to": "loading",
702
+ "event": "INIT",
703
+ "effects": [
704
+ [
705
+ "render-ui",
706
+ "main",
707
+ {
708
+ "type": "loading-state",
709
+ "title": "Retrying…"
710
+ }
711
+ ]
712
+ ]
713
+ }
714
+ ]
715
+ },
716
+ "config": {
717
+ "title": {
718
+ "type": "string",
719
+ "default": "Activity"
720
+ },
721
+ "kindField": {
722
+ "type": "string",
723
+ "default": "kind"
724
+ },
725
+ "dateField": {
726
+ "type": "string",
727
+ "default": "createdAt"
728
+ },
729
+ "bodyField": {
730
+ "type": "string",
731
+ "default": "description"
732
+ },
733
+ "itemStatus": {
734
+ "type": "string",
735
+ "default": "info",
736
+ "values": [
737
+ "info",
738
+ "success",
739
+ "warning",
740
+ "error"
741
+ ]
742
+ },
743
+ "itemIcon": {
744
+ "type": "string",
745
+ "default": "activity"
746
+ },
747
+ "titleField": {
748
+ "type": "string",
749
+ "default": "title"
750
+ },
751
+ "formFields": {
752
+ "type": "[string]",
753
+ "default": [
754
+ "title",
755
+ "description",
756
+ "kind",
757
+ "date"
758
+ ]
759
+ }
760
+ },
761
+ "scope": "instance"
762
+ }
763
+ ],
764
+ "pages": [
765
+ {
766
+ "name": "EventLogPage",
767
+ "path": "/event-log",
768
+ "traits": [
769
+ {
770
+ "ref": "EventLogTimeline"
771
+ }
772
+ ]
773
+ }
774
+ ]
775
+ }
776
+ ]
777
+ }