@almadar/std 3.1.0 → 3.1.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (176) hide show
  1. package/dist/behaviors/exports/atoms/std-async.orb +420 -0
  2. package/dist/behaviors/exports/atoms/std-browse.orb +173 -0
  3. package/dist/behaviors/exports/atoms/std-cache-aside.orb +881 -0
  4. package/dist/behaviors/exports/atoms/std-circuit-breaker.orb +501 -0
  5. package/dist/behaviors/exports/atoms/std-collision.orb +616 -0
  6. package/dist/behaviors/exports/atoms/std-combat-log.orb +145 -0
  7. package/dist/behaviors/exports/atoms/std-combat.orb +410 -0
  8. package/dist/behaviors/exports/atoms/std-confirmation.orb +282 -0
  9. package/dist/behaviors/exports/atoms/std-dialogue-box.orb +238 -0
  10. package/dist/behaviors/exports/atoms/std-display.orb +842 -0
  11. package/dist/behaviors/exports/atoms/std-drawer.orb +316 -0
  12. package/dist/behaviors/exports/atoms/std-filter.orb +442 -0
  13. package/dist/behaviors/exports/atoms/std-game-audio.orb +113 -0
  14. package/dist/behaviors/exports/atoms/std-game-canvas-2d.orb +135 -0
  15. package/dist/behaviors/exports/atoms/std-game-canvas-3d.orb +224 -0
  16. package/dist/behaviors/exports/atoms/std-game-hud.orb +151 -0
  17. package/dist/behaviors/exports/atoms/std-game-menu.orb +211 -0
  18. package/dist/behaviors/exports/atoms/std-game-over-screen.orb +195 -0
  19. package/dist/behaviors/exports/atoms/std-gameflow.orb +318 -0
  20. package/dist/behaviors/exports/atoms/std-input.orb +629 -0
  21. package/dist/behaviors/exports/atoms/std-inventory-panel.orb +255 -0
  22. package/dist/behaviors/exports/atoms/std-isometric-canvas.orb +631 -0
  23. package/dist/behaviors/exports/atoms/std-loading.orb +511 -0
  24. package/dist/behaviors/exports/atoms/std-modal.orb +270 -0
  25. package/dist/behaviors/exports/atoms/std-movement.orb +1037 -0
  26. package/dist/behaviors/exports/atoms/std-notification.orb +418 -0
  27. package/dist/behaviors/exports/atoms/std-overworld.orb +483 -0
  28. package/dist/behaviors/exports/atoms/std-pagination.orb +331 -0
  29. package/dist/behaviors/exports/atoms/std-physics2d.orb +419 -0
  30. package/dist/behaviors/exports/atoms/std-platformer-canvas.orb +257 -0
  31. package/dist/behaviors/exports/atoms/std-quest.orb +980 -0
  32. package/dist/behaviors/exports/atoms/std-rate-limiter.orb +638 -0
  33. package/dist/behaviors/exports/atoms/std-score-board.orb +238 -0
  34. package/dist/behaviors/exports/atoms/std-score.orb +466 -0
  35. package/dist/behaviors/exports/atoms/std-search.orb +373 -0
  36. package/dist/behaviors/exports/atoms/std-selection.orb +759 -0
  37. package/dist/behaviors/exports/atoms/std-simulation-canvas.orb +183 -0
  38. package/dist/behaviors/exports/atoms/std-sort.orb +578 -0
  39. package/dist/behaviors/exports/atoms/std-sprite.orb +156 -0
  40. package/dist/behaviors/exports/atoms/std-tabs.orb +274 -0
  41. package/dist/behaviors/exports/atoms/std-timer.orb +1030 -0
  42. package/dist/behaviors/exports/atoms/std-undo.orb +694 -0
  43. package/dist/behaviors/exports/atoms/std-wizard.orb +666 -0
  44. package/dist/behaviors/exports/molecules/std-builder-game.orb +183 -0
  45. package/dist/behaviors/exports/molecules/std-cart.orb +591 -0
  46. package/dist/behaviors/exports/molecules/std-classifier-game.orb +183 -0
  47. package/dist/behaviors/exports/molecules/std-debugger-game.orb +183 -0
  48. package/dist/behaviors/exports/molecules/std-detail.orb +589 -0
  49. package/dist/behaviors/exports/molecules/std-event-handler-game.orb +183 -0
  50. package/dist/behaviors/exports/molecules/std-geospatial.orb +649 -0
  51. package/dist/behaviors/exports/molecules/std-inventory.orb +853 -0
  52. package/dist/behaviors/exports/molecules/std-list.orb +954 -0
  53. package/dist/behaviors/exports/molecules/std-messaging.orb +585 -0
  54. package/dist/behaviors/exports/molecules/std-negotiator-game.orb +183 -0
  55. package/dist/behaviors/exports/molecules/std-platformer-game.orb +496 -0
  56. package/dist/behaviors/exports/molecules/std-puzzle-game.orb +527 -0
  57. package/dist/behaviors/exports/molecules/std-sequencer-game.orb +183 -0
  58. package/dist/behaviors/exports/molecules/std-simulator-game.orb +183 -0
  59. package/dist/behaviors/exports/molecules/std-turn-based-battle.orb +443 -0
  60. package/dist/behaviors/exports/organisms/std-api-gateway.orb +2296 -0
  61. package/dist/behaviors/exports/organisms/std-arcade-game.orb +833 -0
  62. package/dist/behaviors/exports/organisms/std-booking-system.orb +3977 -0
  63. package/dist/behaviors/exports/organisms/std-cicd-pipeline.orb +2214 -0
  64. package/dist/behaviors/exports/organisms/std-cms.orb +2644 -0
  65. package/dist/behaviors/exports/organisms/std-coding-academy.orb +1394 -0
  66. package/dist/behaviors/exports/organisms/std-crm.orb +3541 -0
  67. package/dist/behaviors/exports/organisms/std-devops-dashboard.orb +3134 -0
  68. package/dist/behaviors/exports/organisms/std-ecommerce.orb +3743 -0
  69. package/dist/behaviors/exports/organisms/std-finance-tracker.orb +2385 -0
  70. package/dist/behaviors/exports/organisms/std-healthcare.orb +4679 -0
  71. package/dist/behaviors/exports/organisms/std-helpdesk.orb +2564 -0
  72. package/dist/behaviors/exports/organisms/std-hr-portal.orb +4029 -0
  73. package/dist/behaviors/exports/organisms/std-iot-dashboard.orb +2297 -0
  74. package/dist/behaviors/exports/organisms/std-lms.orb +2854 -0
  75. package/dist/behaviors/exports/organisms/std-logic-training.orb +598 -0
  76. package/dist/behaviors/exports/organisms/std-platformer-app.orb +1569 -0
  77. package/dist/behaviors/exports/organisms/std-project-manager.orb +3021 -0
  78. package/dist/behaviors/exports/organisms/std-puzzle-app.orb +743 -0
  79. package/dist/behaviors/exports/organisms/std-realtime-chat.orb +2380 -0
  80. package/dist/behaviors/exports/organisms/std-rpg-game.orb +2804 -0
  81. package/dist/behaviors/exports/organisms/std-social-feed.orb +1221 -0
  82. package/dist/behaviors/exports/organisms/std-stem-lab.orb +1210 -0
  83. package/dist/behaviors/exports/organisms/std-strategy-game.orb +1761 -0
  84. package/dist/behaviors/exports/organisms/std-trading-dashboard.orb +2217 -0
  85. package/dist/behaviors/exports-reader.d.ts +2 -0
  86. package/dist/behaviors/exports-reader.js +5 -3
  87. package/dist/behaviors/exports-reader.js.map +1 -1
  88. package/dist/behaviors/index.js +5 -3
  89. package/dist/behaviors/index.js.map +1 -1
  90. package/dist/exports/atoms/std-async.orb +420 -0
  91. package/dist/exports/atoms/std-browse.orb +173 -0
  92. package/dist/exports/atoms/std-cache-aside.orb +881 -0
  93. package/dist/exports/atoms/std-circuit-breaker.orb +501 -0
  94. package/dist/exports/atoms/std-collision.orb +616 -0
  95. package/dist/exports/atoms/std-combat-log.orb +145 -0
  96. package/dist/exports/atoms/std-combat.orb +410 -0
  97. package/dist/exports/atoms/std-confirmation.orb +282 -0
  98. package/dist/exports/atoms/std-dialogue-box.orb +238 -0
  99. package/dist/exports/atoms/std-display.orb +842 -0
  100. package/dist/exports/atoms/std-drawer.orb +316 -0
  101. package/dist/exports/atoms/std-filter.orb +442 -0
  102. package/dist/exports/atoms/std-game-audio.orb +113 -0
  103. package/dist/exports/atoms/std-game-canvas-2d.orb +135 -0
  104. package/dist/exports/atoms/std-game-canvas-3d.orb +224 -0
  105. package/dist/exports/atoms/std-game-hud.orb +151 -0
  106. package/dist/exports/atoms/std-game-menu.orb +211 -0
  107. package/dist/exports/atoms/std-game-over-screen.orb +195 -0
  108. package/dist/exports/atoms/std-gameflow.orb +318 -0
  109. package/dist/exports/atoms/std-input.orb +629 -0
  110. package/dist/exports/atoms/std-inventory-panel.orb +255 -0
  111. package/dist/exports/atoms/std-isometric-canvas.orb +631 -0
  112. package/dist/exports/atoms/std-loading.orb +511 -0
  113. package/dist/exports/atoms/std-modal.orb +270 -0
  114. package/dist/exports/atoms/std-movement.orb +1037 -0
  115. package/dist/exports/atoms/std-notification.orb +418 -0
  116. package/dist/exports/atoms/std-overworld.orb +483 -0
  117. package/dist/exports/atoms/std-pagination.orb +331 -0
  118. package/dist/exports/atoms/std-physics2d.orb +419 -0
  119. package/dist/exports/atoms/std-platformer-canvas.orb +257 -0
  120. package/dist/exports/atoms/std-quest.orb +980 -0
  121. package/dist/exports/atoms/std-rate-limiter.orb +638 -0
  122. package/dist/exports/atoms/std-score-board.orb +238 -0
  123. package/dist/exports/atoms/std-score.orb +466 -0
  124. package/dist/exports/atoms/std-search.orb +373 -0
  125. package/dist/exports/atoms/std-selection.orb +759 -0
  126. package/dist/exports/atoms/std-simulation-canvas.orb +183 -0
  127. package/dist/exports/atoms/std-sort.orb +578 -0
  128. package/dist/exports/atoms/std-sprite.orb +156 -0
  129. package/dist/exports/atoms/std-tabs.orb +274 -0
  130. package/dist/exports/atoms/std-timer.orb +1030 -0
  131. package/dist/exports/atoms/std-undo.orb +694 -0
  132. package/dist/exports/atoms/std-wizard.orb +666 -0
  133. package/dist/exports/molecules/std-builder-game.orb +183 -0
  134. package/dist/exports/molecules/std-cart.orb +591 -0
  135. package/dist/exports/molecules/std-classifier-game.orb +183 -0
  136. package/dist/exports/molecules/std-debugger-game.orb +183 -0
  137. package/dist/exports/molecules/std-detail.orb +589 -0
  138. package/dist/exports/molecules/std-event-handler-game.orb +183 -0
  139. package/dist/exports/molecules/std-geospatial.orb +649 -0
  140. package/dist/exports/molecules/std-inventory.orb +853 -0
  141. package/dist/exports/molecules/std-list.orb +954 -0
  142. package/dist/exports/molecules/std-messaging.orb +585 -0
  143. package/dist/exports/molecules/std-negotiator-game.orb +183 -0
  144. package/dist/exports/molecules/std-platformer-game.orb +496 -0
  145. package/dist/exports/molecules/std-puzzle-game.orb +527 -0
  146. package/dist/exports/molecules/std-sequencer-game.orb +183 -0
  147. package/dist/exports/molecules/std-simulator-game.orb +183 -0
  148. package/dist/exports/molecules/std-turn-based-battle.orb +443 -0
  149. package/dist/exports/organisms/std-api-gateway.orb +2296 -0
  150. package/dist/exports/organisms/std-arcade-game.orb +833 -0
  151. package/dist/exports/organisms/std-booking-system.orb +3977 -0
  152. package/dist/exports/organisms/std-cicd-pipeline.orb +2214 -0
  153. package/dist/exports/organisms/std-cms.orb +2644 -0
  154. package/dist/exports/organisms/std-coding-academy.orb +1394 -0
  155. package/dist/exports/organisms/std-crm.orb +3541 -0
  156. package/dist/exports/organisms/std-devops-dashboard.orb +3134 -0
  157. package/dist/exports/organisms/std-ecommerce.orb +3743 -0
  158. package/dist/exports/organisms/std-finance-tracker.orb +2385 -0
  159. package/dist/exports/organisms/std-healthcare.orb +4679 -0
  160. package/dist/exports/organisms/std-helpdesk.orb +2564 -0
  161. package/dist/exports/organisms/std-hr-portal.orb +4029 -0
  162. package/dist/exports/organisms/std-iot-dashboard.orb +2297 -0
  163. package/dist/exports/organisms/std-lms.orb +2854 -0
  164. package/dist/exports/organisms/std-logic-training.orb +598 -0
  165. package/dist/exports/organisms/std-platformer-app.orb +1569 -0
  166. package/dist/exports/organisms/std-project-manager.orb +3021 -0
  167. package/dist/exports/organisms/std-puzzle-app.orb +743 -0
  168. package/dist/exports/organisms/std-realtime-chat.orb +2380 -0
  169. package/dist/exports/organisms/std-rpg-game.orb +2804 -0
  170. package/dist/exports/organisms/std-social-feed.orb +1221 -0
  171. package/dist/exports/organisms/std-stem-lab.orb +1210 -0
  172. package/dist/exports/organisms/std-strategy-game.orb +1761 -0
  173. package/dist/exports/organisms/std-trading-dashboard.orb +2217 -0
  174. package/dist/index.js +5 -3
  175. package/dist/index.js.map +1 -1
  176. package/package.json +1 -1
@@ -0,0 +1,2380 @@
1
+ {
2
+ "name": "Realtime Chat",
3
+ "version": "1.0.0",
4
+ "orbitals": [
5
+ {
6
+ "name": "ChatMessageOrbital",
7
+ "entity": {
8
+ "name": "ChatMessage",
9
+ "persistence": "runtime",
10
+ "fields": [
11
+ {
12
+ "name": "id",
13
+ "type": "string",
14
+ "required": true
15
+ },
16
+ {
17
+ "name": "sender",
18
+ "type": "string",
19
+ "required": true
20
+ },
21
+ {
22
+ "name": "content",
23
+ "type": "string",
24
+ "required": true
25
+ },
26
+ {
27
+ "name": "channel",
28
+ "type": "string"
29
+ },
30
+ {
31
+ "name": "timestamp",
32
+ "type": "string"
33
+ }
34
+ ]
35
+ },
36
+ "traits": [
37
+ {
38
+ "name": "ChatMessageBrowse",
39
+ "linkedEntity": "ChatMessage",
40
+ "category": "interaction",
41
+ "listens": [
42
+ {
43
+ "event": "SEND",
44
+ "triggers": "SEND"
45
+ }
46
+ ],
47
+ "stateMachine": {
48
+ "states": [
49
+ {
50
+ "name": "browsing",
51
+ "isInitial": true
52
+ }
53
+ ],
54
+ "events": [
55
+ {
56
+ "key": "INIT",
57
+ "name": "Initialize"
58
+ },
59
+ {
60
+ "key": "COMPOSE",
61
+ "name": "COMPOSE"
62
+ },
63
+ {
64
+ "key": "VIEW",
65
+ "name": "VIEW",
66
+ "payload": [
67
+ {
68
+ "name": "id",
69
+ "type": "string",
70
+ "required": true
71
+ }
72
+ ]
73
+ },
74
+ {
75
+ "key": "SEND",
76
+ "name": "SEND",
77
+ "payload": [
78
+ {
79
+ "name": "data",
80
+ "type": "object",
81
+ "required": true
82
+ }
83
+ ]
84
+ }
85
+ ],
86
+ "transitions": [
87
+ {
88
+ "from": "browsing",
89
+ "to": "browsing",
90
+ "event": "INIT",
91
+ "effects": [
92
+ [
93
+ "fetch",
94
+ "ChatMessage"
95
+ ],
96
+ [
97
+ "render-ui",
98
+ "main",
99
+ {
100
+ "type": "stack",
101
+ "direction": "vertical",
102
+ "gap": "lg",
103
+ "children": [
104
+ {
105
+ "type": "stack",
106
+ "direction": "horizontal",
107
+ "gap": "md",
108
+ "justify": "space-between",
109
+ "children": [
110
+ {
111
+ "type": "stack",
112
+ "direction": "horizontal",
113
+ "gap": "sm",
114
+ "align": "center",
115
+ "children": [
116
+ {
117
+ "type": "icon",
118
+ "name": "message-circle",
119
+ "size": "lg"
120
+ },
121
+ {
122
+ "type": "typography",
123
+ "content": "Chat",
124
+ "variant": "h2"
125
+ }
126
+ ]
127
+ },
128
+ {
129
+ "type": "stack",
130
+ "direction": "horizontal",
131
+ "gap": "sm",
132
+ "children": [
133
+ {
134
+ "type": "button",
135
+ "label": "Compose",
136
+ "event": "COMPOSE",
137
+ "variant": "primary",
138
+ "icon": "edit"
139
+ }
140
+ ]
141
+ }
142
+ ]
143
+ },
144
+ {
145
+ "type": "divider"
146
+ },
147
+ {
148
+ "type": "data-grid",
149
+ "entity": "ChatMessage",
150
+ "emptyIcon": "inbox",
151
+ "emptyTitle": "No messages yet",
152
+ "emptyDescription": "Start a new conversation.",
153
+ "itemActions": [
154
+ {
155
+ "label": "View",
156
+ "event": "VIEW"
157
+ }
158
+ ],
159
+ "className": "transition-shadow hover:shadow-md cursor-pointer",
160
+ "children": [
161
+ {
162
+ "type": "stack",
163
+ "direction": "vertical",
164
+ "gap": "sm",
165
+ "children": [
166
+ {
167
+ "type": "stack",
168
+ "direction": "horizontal",
169
+ "justify": "space-between",
170
+ "align": "center",
171
+ "children": [
172
+ {
173
+ "type": "stack",
174
+ "direction": "horizontal",
175
+ "gap": "sm",
176
+ "align": "center",
177
+ "children": [
178
+ {
179
+ "type": "icon",
180
+ "name": "message-circle",
181
+ "size": "sm"
182
+ },
183
+ {
184
+ "type": "typography",
185
+ "variant": "h4",
186
+ "content": "@entity.sender"
187
+ }
188
+ ]
189
+ },
190
+ {
191
+ "type": "badge",
192
+ "label": "@entity.content"
193
+ }
194
+ ]
195
+ },
196
+ {
197
+ "type": "typography",
198
+ "variant": "caption",
199
+ "color": "muted",
200
+ "content": "@entity.channel"
201
+ }
202
+ ]
203
+ }
204
+ ]
205
+ }
206
+ ]
207
+ }
208
+ ]
209
+ ]
210
+ },
211
+ {
212
+ "from": "browsing",
213
+ "to": "browsing",
214
+ "event": "SEND",
215
+ "effects": [
216
+ [
217
+ "fetch",
218
+ "ChatMessage"
219
+ ]
220
+ ]
221
+ }
222
+ ]
223
+ }
224
+ },
225
+ {
226
+ "name": "ChatMessageCompose",
227
+ "linkedEntity": "ChatMessage",
228
+ "category": "interaction",
229
+ "emits": [
230
+ {
231
+ "event": "SEND"
232
+ }
233
+ ],
234
+ "stateMachine": {
235
+ "states": [
236
+ {
237
+ "name": "closed",
238
+ "isInitial": true
239
+ },
240
+ {
241
+ "name": "open"
242
+ }
243
+ ],
244
+ "events": [
245
+ {
246
+ "key": "INIT",
247
+ "name": "Initialize"
248
+ },
249
+ {
250
+ "key": "COMPOSE",
251
+ "name": "Open"
252
+ },
253
+ {
254
+ "key": "CLOSE",
255
+ "name": "Close"
256
+ },
257
+ {
258
+ "key": "SEND",
259
+ "name": "Save",
260
+ "payload": [
261
+ {
262
+ "name": "data",
263
+ "type": "object",
264
+ "required": true
265
+ }
266
+ ]
267
+ }
268
+ ],
269
+ "transitions": [
270
+ {
271
+ "from": "closed",
272
+ "to": "closed",
273
+ "event": "INIT",
274
+ "effects": [
275
+ [
276
+ "fetch",
277
+ "ChatMessage"
278
+ ]
279
+ ]
280
+ },
281
+ {
282
+ "from": "closed",
283
+ "to": "open",
284
+ "event": "COMPOSE",
285
+ "effects": [
286
+ [
287
+ "render-ui",
288
+ "modal",
289
+ {
290
+ "type": "stack",
291
+ "direction": "vertical",
292
+ "gap": "md",
293
+ "children": [
294
+ {
295
+ "type": "stack",
296
+ "direction": "horizontal",
297
+ "gap": "sm",
298
+ "children": [
299
+ {
300
+ "type": "icon",
301
+ "name": "edit",
302
+ "size": "md"
303
+ },
304
+ {
305
+ "type": "typography",
306
+ "content": "New ChatMessage",
307
+ "variant": "h3"
308
+ }
309
+ ]
310
+ },
311
+ {
312
+ "type": "divider"
313
+ },
314
+ {
315
+ "type": "form-section",
316
+ "entity": "ChatMessage",
317
+ "mode": "create",
318
+ "submitEvent": "SEND",
319
+ "cancelEvent": "CLOSE",
320
+ "fields": [
321
+ "sender",
322
+ "content",
323
+ "channel",
324
+ "timestamp"
325
+ ]
326
+ }
327
+ ]
328
+ }
329
+ ]
330
+ ]
331
+ },
332
+ {
333
+ "from": "open",
334
+ "to": "closed",
335
+ "event": "CLOSE",
336
+ "effects": [
337
+ [
338
+ "render-ui",
339
+ "modal",
340
+ null
341
+ ]
342
+ ]
343
+ },
344
+ {
345
+ "from": "open",
346
+ "to": "closed",
347
+ "event": "SEND",
348
+ "effects": [
349
+ [
350
+ "persist",
351
+ "create",
352
+ "ChatMessage",
353
+ "@payload.data"
354
+ ],
355
+ [
356
+ "fetch",
357
+ "ChatMessage"
358
+ ],
359
+ [
360
+ "render-ui",
361
+ "modal",
362
+ null
363
+ ],
364
+ [
365
+ "emit",
366
+ "SEND"
367
+ ],
368
+ [
369
+ "notify",
370
+ "ChatMessage created successfully"
371
+ ]
372
+ ]
373
+ }
374
+ ]
375
+ }
376
+ },
377
+ {
378
+ "name": "ChatMessageView",
379
+ "linkedEntity": "ChatMessage",
380
+ "category": "interaction",
381
+ "stateMachine": {
382
+ "states": [
383
+ {
384
+ "name": "closed",
385
+ "isInitial": true
386
+ },
387
+ {
388
+ "name": "open"
389
+ }
390
+ ],
391
+ "events": [
392
+ {
393
+ "key": "INIT",
394
+ "name": "Initialize"
395
+ },
396
+ {
397
+ "key": "VIEW",
398
+ "name": "Open",
399
+ "payload": [
400
+ {
401
+ "name": "id",
402
+ "type": "string",
403
+ "required": true
404
+ }
405
+ ]
406
+ },
407
+ {
408
+ "key": "CLOSE",
409
+ "name": "Close"
410
+ }
411
+ ],
412
+ "transitions": [
413
+ {
414
+ "from": "closed",
415
+ "to": "closed",
416
+ "event": "INIT",
417
+ "effects": [
418
+ [
419
+ "fetch",
420
+ "ChatMessage"
421
+ ]
422
+ ]
423
+ },
424
+ {
425
+ "from": "closed",
426
+ "to": "open",
427
+ "event": "VIEW",
428
+ "effects": [
429
+ [
430
+ "fetch",
431
+ "ChatMessage",
432
+ "@payload.id"
433
+ ],
434
+ [
435
+ "render-ui",
436
+ "modal",
437
+ {
438
+ "type": "stack",
439
+ "direction": "vertical",
440
+ "gap": "md",
441
+ "children": [
442
+ {
443
+ "type": "stack",
444
+ "direction": "horizontal",
445
+ "gap": "sm",
446
+ "align": "center",
447
+ "children": [
448
+ {
449
+ "type": "icon",
450
+ "name": "eye",
451
+ "size": "md"
452
+ },
453
+ {
454
+ "type": "typography",
455
+ "variant": "h3",
456
+ "content": "@entity.sender"
457
+ }
458
+ ]
459
+ },
460
+ {
461
+ "type": "divider"
462
+ },
463
+ {
464
+ "type": "stack",
465
+ "direction": "horizontal",
466
+ "gap": "md",
467
+ "children": [
468
+ {
469
+ "type": "typography",
470
+ "variant": "caption",
471
+ "content": "Sender"
472
+ },
473
+ {
474
+ "type": "typography",
475
+ "variant": "body",
476
+ "content": "@entity.sender"
477
+ }
478
+ ]
479
+ },
480
+ {
481
+ "type": "stack",
482
+ "direction": "horizontal",
483
+ "gap": "md",
484
+ "children": [
485
+ {
486
+ "type": "typography",
487
+ "variant": "caption",
488
+ "content": "Content"
489
+ },
490
+ {
491
+ "type": "typography",
492
+ "variant": "body",
493
+ "content": "@entity.content"
494
+ }
495
+ ]
496
+ },
497
+ {
498
+ "type": "stack",
499
+ "direction": "horizontal",
500
+ "gap": "md",
501
+ "children": [
502
+ {
503
+ "type": "typography",
504
+ "variant": "caption",
505
+ "content": "Channel"
506
+ },
507
+ {
508
+ "type": "typography",
509
+ "variant": "body",
510
+ "content": "@entity.channel"
511
+ }
512
+ ]
513
+ },
514
+ {
515
+ "type": "stack",
516
+ "direction": "horizontal",
517
+ "gap": "md",
518
+ "children": [
519
+ {
520
+ "type": "typography",
521
+ "variant": "caption",
522
+ "content": "Timestamp"
523
+ },
524
+ {
525
+ "type": "typography",
526
+ "variant": "body",
527
+ "content": "@entity.timestamp"
528
+ }
529
+ ]
530
+ },
531
+ {
532
+ "type": "divider"
533
+ },
534
+ {
535
+ "type": "stack",
536
+ "direction": "horizontal",
537
+ "gap": "sm",
538
+ "justify": "end",
539
+ "children": [
540
+ {
541
+ "type": "button",
542
+ "label": "Close",
543
+ "event": "CLOSE",
544
+ "variant": "ghost"
545
+ }
546
+ ]
547
+ }
548
+ ]
549
+ }
550
+ ]
551
+ ]
552
+ },
553
+ {
554
+ "from": "open",
555
+ "to": "closed",
556
+ "event": "CLOSE",
557
+ "effects": [
558
+ [
559
+ "render-ui",
560
+ "modal",
561
+ null
562
+ ]
563
+ ]
564
+ }
565
+ ]
566
+ }
567
+ }
568
+ ],
569
+ "pages": [
570
+ {
571
+ "name": "ChatPage",
572
+ "path": "/chat",
573
+ "isInitial": true,
574
+ "traits": [
575
+ {
576
+ "ref": "ChatMessageBrowse"
577
+ },
578
+ {
579
+ "ref": "ChatMessageCompose"
580
+ },
581
+ {
582
+ "ref": "ChatMessageView"
583
+ }
584
+ ]
585
+ }
586
+ ]
587
+ },
588
+ {
589
+ "name": "ChannelOrbital",
590
+ "entity": {
591
+ "name": "Channel",
592
+ "persistence": "runtime",
593
+ "fields": [
594
+ {
595
+ "name": "id",
596
+ "type": "string",
597
+ "required": true
598
+ },
599
+ {
600
+ "name": "name",
601
+ "type": "string",
602
+ "required": true
603
+ },
604
+ {
605
+ "name": "description",
606
+ "type": "string"
607
+ },
608
+ {
609
+ "name": "memberCount",
610
+ "type": "number",
611
+ "default": 0
612
+ },
613
+ {
614
+ "name": "isPrivate",
615
+ "type": "boolean",
616
+ "default": false
617
+ }
618
+ ]
619
+ },
620
+ "traits": [
621
+ {
622
+ "name": "ChannelBrowse",
623
+ "linkedEntity": "Channel",
624
+ "category": "interaction",
625
+ "listens": [
626
+ {
627
+ "event": "CHANNEL_CREATED",
628
+ "triggers": "CHANNEL_CREATED"
629
+ },
630
+ {
631
+ "event": "CHANNEL_UPDATED",
632
+ "triggers": "CHANNEL_UPDATED"
633
+ }
634
+ ],
635
+ "stateMachine": {
636
+ "states": [
637
+ {
638
+ "name": "browsing",
639
+ "isInitial": true
640
+ },
641
+ {
642
+ "name": "deleting"
643
+ }
644
+ ],
645
+ "events": [
646
+ {
647
+ "key": "INIT",
648
+ "name": "Initialize"
649
+ },
650
+ {
651
+ "key": "CREATE",
652
+ "name": "CREATE"
653
+ },
654
+ {
655
+ "key": "VIEW",
656
+ "name": "VIEW",
657
+ "payload": [
658
+ {
659
+ "name": "id",
660
+ "type": "string",
661
+ "required": true
662
+ }
663
+ ]
664
+ },
665
+ {
666
+ "key": "EDIT",
667
+ "name": "EDIT",
668
+ "payload": [
669
+ {
670
+ "name": "id",
671
+ "type": "string",
672
+ "required": true
673
+ }
674
+ ]
675
+ },
676
+ {
677
+ "key": "DELETE",
678
+ "name": "DELETE",
679
+ "payload": [
680
+ {
681
+ "name": "id",
682
+ "type": "string",
683
+ "required": true
684
+ }
685
+ ]
686
+ },
687
+ {
688
+ "key": "CHANNEL_CREATED",
689
+ "name": "CHANNEL_CREATED",
690
+ "payload": [
691
+ {
692
+ "name": "data",
693
+ "type": "object",
694
+ "required": true
695
+ }
696
+ ]
697
+ },
698
+ {
699
+ "key": "CHANNEL_UPDATED",
700
+ "name": "CHANNEL_UPDATED",
701
+ "payload": [
702
+ {
703
+ "name": "data",
704
+ "type": "object",
705
+ "required": true
706
+ }
707
+ ]
708
+ },
709
+ {
710
+ "key": "CONFIRM_DELETE",
711
+ "name": "Confirm Delete"
712
+ },
713
+ {
714
+ "key": "CANCEL",
715
+ "name": "Cancel"
716
+ },
717
+ {
718
+ "key": "CLOSE",
719
+ "name": "Close"
720
+ }
721
+ ],
722
+ "transitions": [
723
+ {
724
+ "from": "browsing",
725
+ "to": "browsing",
726
+ "event": "INIT",
727
+ "effects": [
728
+ [
729
+ "fetch",
730
+ "Channel"
731
+ ],
732
+ [
733
+ "render-ui",
734
+ "main",
735
+ {
736
+ "type": "stack",
737
+ "direction": "vertical",
738
+ "gap": "lg",
739
+ "children": [
740
+ {
741
+ "type": "stack",
742
+ "direction": "horizontal",
743
+ "gap": "md",
744
+ "justify": "space-between",
745
+ "children": [
746
+ {
747
+ "type": "stack",
748
+ "direction": "horizontal",
749
+ "gap": "sm",
750
+ "align": "center",
751
+ "children": [
752
+ {
753
+ "type": "icon",
754
+ "name": "hash",
755
+ "size": "lg"
756
+ },
757
+ {
758
+ "type": "typography",
759
+ "content": "Channels",
760
+ "variant": "h2"
761
+ }
762
+ ]
763
+ },
764
+ {
765
+ "type": "stack",
766
+ "direction": "horizontal",
767
+ "gap": "sm",
768
+ "children": [
769
+ {
770
+ "type": "button",
771
+ "label": "Create Channel",
772
+ "event": "CREATE",
773
+ "variant": "primary",
774
+ "icon": "plus"
775
+ }
776
+ ]
777
+ }
778
+ ]
779
+ },
780
+ {
781
+ "type": "divider"
782
+ },
783
+ {
784
+ "type": "data-grid",
785
+ "entity": "Channel",
786
+ "emptyIcon": "inbox",
787
+ "emptyTitle": "No channels yet",
788
+ "emptyDescription": "Create your first channel to get started.",
789
+ "itemActions": [
790
+ {
791
+ "label": "View",
792
+ "event": "VIEW"
793
+ },
794
+ {
795
+ "label": "Edit",
796
+ "event": "EDIT"
797
+ },
798
+ {
799
+ "label": "Delete",
800
+ "event": "DELETE",
801
+ "variant": "danger"
802
+ }
803
+ ],
804
+ "className": "transition-shadow hover:shadow-md cursor-pointer",
805
+ "children": [
806
+ {
807
+ "type": "stack",
808
+ "direction": "vertical",
809
+ "gap": "sm",
810
+ "children": [
811
+ {
812
+ "type": "stack",
813
+ "direction": "horizontal",
814
+ "justify": "space-between",
815
+ "align": "center",
816
+ "children": [
817
+ {
818
+ "type": "stack",
819
+ "direction": "horizontal",
820
+ "gap": "sm",
821
+ "align": "center",
822
+ "children": [
823
+ {
824
+ "type": "icon",
825
+ "name": "hash",
826
+ "size": "sm"
827
+ },
828
+ {
829
+ "type": "typography",
830
+ "variant": "h4",
831
+ "content": "@entity.name"
832
+ }
833
+ ]
834
+ },
835
+ {
836
+ "type": "badge",
837
+ "label": "@entity.description"
838
+ }
839
+ ]
840
+ },
841
+ {
842
+ "type": "typography",
843
+ "variant": "caption",
844
+ "color": "muted",
845
+ "content": "@entity.memberCount"
846
+ }
847
+ ]
848
+ }
849
+ ]
850
+ }
851
+ ]
852
+ }
853
+ ]
854
+ ]
855
+ },
856
+ {
857
+ "from": "browsing",
858
+ "to": "browsing",
859
+ "event": "CHANNEL_CREATED",
860
+ "effects": [
861
+ [
862
+ "fetch",
863
+ "Channel"
864
+ ]
865
+ ]
866
+ },
867
+ {
868
+ "from": "browsing",
869
+ "to": "browsing",
870
+ "event": "CHANNEL_UPDATED",
871
+ "effects": [
872
+ [
873
+ "fetch",
874
+ "Channel"
875
+ ]
876
+ ]
877
+ },
878
+ {
879
+ "from": "browsing",
880
+ "to": "deleting",
881
+ "event": "DELETE",
882
+ "effects": [
883
+ [
884
+ "fetch",
885
+ "Channel",
886
+ "@payload.id"
887
+ ],
888
+ [
889
+ "render-ui",
890
+ "modal",
891
+ {
892
+ "type": "stack",
893
+ "direction": "vertical",
894
+ "gap": "md",
895
+ "children": [
896
+ {
897
+ "type": "stack",
898
+ "direction": "horizontal",
899
+ "gap": "sm",
900
+ "children": [
901
+ {
902
+ "type": "icon",
903
+ "name": "trash-2",
904
+ "size": "md"
905
+ },
906
+ {
907
+ "type": "typography",
908
+ "content": "Delete Channel",
909
+ "variant": "h3"
910
+ }
911
+ ]
912
+ },
913
+ {
914
+ "type": "divider"
915
+ },
916
+ {
917
+ "type": "typography",
918
+ "content": "Are you sure you want to delete this channel?",
919
+ "variant": "body"
920
+ },
921
+ {
922
+ "type": "stack",
923
+ "direction": "horizontal",
924
+ "gap": "sm",
925
+ "justify": "end",
926
+ "children": [
927
+ {
928
+ "type": "button",
929
+ "label": "Cancel",
930
+ "event": "CANCEL",
931
+ "variant": "ghost"
932
+ },
933
+ {
934
+ "type": "button",
935
+ "label": "Delete",
936
+ "event": "CONFIRM_DELETE",
937
+ "variant": "danger",
938
+ "icon": "trash"
939
+ }
940
+ ]
941
+ }
942
+ ]
943
+ }
944
+ ]
945
+ ]
946
+ },
947
+ {
948
+ "from": "deleting",
949
+ "to": "browsing",
950
+ "event": "CONFIRM_DELETE",
951
+ "effects": [
952
+ [
953
+ "persist",
954
+ "delete",
955
+ "Channel",
956
+ "@entity.id"
957
+ ],
958
+ [
959
+ "render-ui",
960
+ "modal",
961
+ null
962
+ ],
963
+ [
964
+ "fetch",
965
+ "Channel"
966
+ ],
967
+ [
968
+ "notify",
969
+ "Channel deleted successfully"
970
+ ]
971
+ ]
972
+ },
973
+ {
974
+ "from": "deleting",
975
+ "to": "browsing",
976
+ "event": "CANCEL",
977
+ "effects": [
978
+ [
979
+ "render-ui",
980
+ "modal",
981
+ null
982
+ ]
983
+ ]
984
+ },
985
+ {
986
+ "from": "deleting",
987
+ "to": "browsing",
988
+ "event": "CLOSE",
989
+ "effects": [
990
+ [
991
+ "render-ui",
992
+ "modal",
993
+ null
994
+ ]
995
+ ]
996
+ }
997
+ ]
998
+ }
999
+ },
1000
+ {
1001
+ "name": "ChannelCreate",
1002
+ "linkedEntity": "Channel",
1003
+ "category": "interaction",
1004
+ "emits": [
1005
+ {
1006
+ "event": "CHANNEL_CREATED"
1007
+ }
1008
+ ],
1009
+ "stateMachine": {
1010
+ "states": [
1011
+ {
1012
+ "name": "closed",
1013
+ "isInitial": true
1014
+ },
1015
+ {
1016
+ "name": "open"
1017
+ }
1018
+ ],
1019
+ "events": [
1020
+ {
1021
+ "key": "INIT",
1022
+ "name": "Initialize"
1023
+ },
1024
+ {
1025
+ "key": "CREATE",
1026
+ "name": "Open"
1027
+ },
1028
+ {
1029
+ "key": "CLOSE",
1030
+ "name": "Close"
1031
+ },
1032
+ {
1033
+ "key": "SAVE",
1034
+ "name": "Save",
1035
+ "payload": [
1036
+ {
1037
+ "name": "data",
1038
+ "type": "object",
1039
+ "required": true
1040
+ }
1041
+ ]
1042
+ }
1043
+ ],
1044
+ "transitions": [
1045
+ {
1046
+ "from": "closed",
1047
+ "to": "closed",
1048
+ "event": "INIT",
1049
+ "effects": [
1050
+ [
1051
+ "fetch",
1052
+ "Channel"
1053
+ ]
1054
+ ]
1055
+ },
1056
+ {
1057
+ "from": "closed",
1058
+ "to": "open",
1059
+ "event": "CREATE",
1060
+ "effects": [
1061
+ [
1062
+ "fetch",
1063
+ "Channel"
1064
+ ],
1065
+ [
1066
+ "render-ui",
1067
+ "modal",
1068
+ {
1069
+ "type": "stack",
1070
+ "direction": "vertical",
1071
+ "gap": "md",
1072
+ "children": [
1073
+ {
1074
+ "type": "stack",
1075
+ "direction": "horizontal",
1076
+ "gap": "sm",
1077
+ "children": [
1078
+ {
1079
+ "type": "icon",
1080
+ "name": "plus-circle",
1081
+ "size": "md"
1082
+ },
1083
+ {
1084
+ "type": "typography",
1085
+ "content": "Create Channel",
1086
+ "variant": "h3"
1087
+ }
1088
+ ]
1089
+ },
1090
+ {
1091
+ "type": "divider"
1092
+ },
1093
+ {
1094
+ "type": "form-section",
1095
+ "entity": "Channel",
1096
+ "mode": "create",
1097
+ "submitEvent": "SAVE",
1098
+ "cancelEvent": "CLOSE",
1099
+ "fields": [
1100
+ "name",
1101
+ "description",
1102
+ "memberCount",
1103
+ "isPrivate"
1104
+ ]
1105
+ }
1106
+ ]
1107
+ }
1108
+ ]
1109
+ ]
1110
+ },
1111
+ {
1112
+ "from": "open",
1113
+ "to": "closed",
1114
+ "event": "CLOSE",
1115
+ "effects": [
1116
+ [
1117
+ "render-ui",
1118
+ "modal",
1119
+ null
1120
+ ]
1121
+ ]
1122
+ },
1123
+ {
1124
+ "from": "open",
1125
+ "to": "closed",
1126
+ "event": "SAVE",
1127
+ "effects": [
1128
+ [
1129
+ "persist",
1130
+ "create",
1131
+ "Channel",
1132
+ "@payload.data"
1133
+ ],
1134
+ [
1135
+ "fetch",
1136
+ "Channel"
1137
+ ],
1138
+ [
1139
+ "render-ui",
1140
+ "modal",
1141
+ null
1142
+ ],
1143
+ [
1144
+ "emit",
1145
+ "CHANNEL_CREATED"
1146
+ ],
1147
+ [
1148
+ "notify",
1149
+ "Channel created successfully"
1150
+ ]
1151
+ ]
1152
+ }
1153
+ ]
1154
+ }
1155
+ },
1156
+ {
1157
+ "name": "ChannelEdit",
1158
+ "linkedEntity": "Channel",
1159
+ "category": "interaction",
1160
+ "emits": [
1161
+ {
1162
+ "event": "CHANNEL_UPDATED"
1163
+ }
1164
+ ],
1165
+ "stateMachine": {
1166
+ "states": [
1167
+ {
1168
+ "name": "closed",
1169
+ "isInitial": true
1170
+ },
1171
+ {
1172
+ "name": "open"
1173
+ }
1174
+ ],
1175
+ "events": [
1176
+ {
1177
+ "key": "INIT",
1178
+ "name": "Initialize"
1179
+ },
1180
+ {
1181
+ "key": "EDIT",
1182
+ "name": "Open",
1183
+ "payload": [
1184
+ {
1185
+ "name": "id",
1186
+ "type": "string",
1187
+ "required": true
1188
+ }
1189
+ ]
1190
+ },
1191
+ {
1192
+ "key": "CLOSE",
1193
+ "name": "Close"
1194
+ },
1195
+ {
1196
+ "key": "SAVE",
1197
+ "name": "Save",
1198
+ "payload": [
1199
+ {
1200
+ "name": "data",
1201
+ "type": "object",
1202
+ "required": true
1203
+ }
1204
+ ]
1205
+ }
1206
+ ],
1207
+ "transitions": [
1208
+ {
1209
+ "from": "closed",
1210
+ "to": "closed",
1211
+ "event": "INIT",
1212
+ "effects": [
1213
+ [
1214
+ "fetch",
1215
+ "Channel"
1216
+ ]
1217
+ ]
1218
+ },
1219
+ {
1220
+ "from": "closed",
1221
+ "to": "open",
1222
+ "event": "EDIT",
1223
+ "effects": [
1224
+ [
1225
+ "fetch",
1226
+ "Channel",
1227
+ "@payload.id"
1228
+ ],
1229
+ [
1230
+ "render-ui",
1231
+ "modal",
1232
+ {
1233
+ "type": "stack",
1234
+ "direction": "vertical",
1235
+ "gap": "md",
1236
+ "children": [
1237
+ {
1238
+ "type": "stack",
1239
+ "direction": "horizontal",
1240
+ "gap": "sm",
1241
+ "children": [
1242
+ {
1243
+ "type": "icon",
1244
+ "name": "edit",
1245
+ "size": "md"
1246
+ },
1247
+ {
1248
+ "type": "typography",
1249
+ "content": "Edit Channel",
1250
+ "variant": "h3"
1251
+ }
1252
+ ]
1253
+ },
1254
+ {
1255
+ "type": "divider"
1256
+ },
1257
+ {
1258
+ "type": "form-section",
1259
+ "entity": "Channel",
1260
+ "mode": "edit",
1261
+ "submitEvent": "SAVE",
1262
+ "cancelEvent": "CLOSE",
1263
+ "fields": [
1264
+ "name",
1265
+ "description",
1266
+ "memberCount",
1267
+ "isPrivate"
1268
+ ]
1269
+ }
1270
+ ]
1271
+ }
1272
+ ]
1273
+ ]
1274
+ },
1275
+ {
1276
+ "from": "open",
1277
+ "to": "closed",
1278
+ "event": "CLOSE",
1279
+ "effects": [
1280
+ [
1281
+ "render-ui",
1282
+ "modal",
1283
+ null
1284
+ ]
1285
+ ]
1286
+ },
1287
+ {
1288
+ "from": "open",
1289
+ "to": "closed",
1290
+ "event": "SAVE",
1291
+ "effects": [
1292
+ [
1293
+ "persist",
1294
+ "update",
1295
+ "Channel",
1296
+ "@payload.data"
1297
+ ],
1298
+ [
1299
+ "fetch",
1300
+ "Channel"
1301
+ ],
1302
+ [
1303
+ "render-ui",
1304
+ "modal",
1305
+ null
1306
+ ],
1307
+ [
1308
+ "emit",
1309
+ "CHANNEL_UPDATED"
1310
+ ],
1311
+ [
1312
+ "notify",
1313
+ "Channel updated successfully"
1314
+ ]
1315
+ ]
1316
+ }
1317
+ ]
1318
+ }
1319
+ },
1320
+ {
1321
+ "name": "ChannelView",
1322
+ "linkedEntity": "Channel",
1323
+ "category": "interaction",
1324
+ "stateMachine": {
1325
+ "states": [
1326
+ {
1327
+ "name": "closed",
1328
+ "isInitial": true
1329
+ },
1330
+ {
1331
+ "name": "open"
1332
+ }
1333
+ ],
1334
+ "events": [
1335
+ {
1336
+ "key": "INIT",
1337
+ "name": "Initialize"
1338
+ },
1339
+ {
1340
+ "key": "VIEW",
1341
+ "name": "Open",
1342
+ "payload": [
1343
+ {
1344
+ "name": "id",
1345
+ "type": "string",
1346
+ "required": true
1347
+ }
1348
+ ]
1349
+ },
1350
+ {
1351
+ "key": "CLOSE",
1352
+ "name": "Close"
1353
+ }
1354
+ ],
1355
+ "transitions": [
1356
+ {
1357
+ "from": "closed",
1358
+ "to": "closed",
1359
+ "event": "INIT",
1360
+ "effects": [
1361
+ [
1362
+ "fetch",
1363
+ "Channel"
1364
+ ]
1365
+ ]
1366
+ },
1367
+ {
1368
+ "from": "closed",
1369
+ "to": "open",
1370
+ "event": "VIEW",
1371
+ "effects": [
1372
+ [
1373
+ "fetch",
1374
+ "Channel",
1375
+ "@payload.id"
1376
+ ],
1377
+ [
1378
+ "render-ui",
1379
+ "modal",
1380
+ {
1381
+ "type": "stack",
1382
+ "direction": "vertical",
1383
+ "gap": "md",
1384
+ "children": [
1385
+ {
1386
+ "type": "stack",
1387
+ "direction": "horizontal",
1388
+ "gap": "sm",
1389
+ "align": "center",
1390
+ "children": [
1391
+ {
1392
+ "type": "icon",
1393
+ "name": "eye",
1394
+ "size": "md"
1395
+ },
1396
+ {
1397
+ "type": "typography",
1398
+ "variant": "h3",
1399
+ "content": "@entity.name"
1400
+ }
1401
+ ]
1402
+ },
1403
+ {
1404
+ "type": "divider"
1405
+ },
1406
+ {
1407
+ "type": "stack",
1408
+ "direction": "horizontal",
1409
+ "gap": "md",
1410
+ "children": [
1411
+ {
1412
+ "type": "typography",
1413
+ "variant": "caption",
1414
+ "content": "Name"
1415
+ },
1416
+ {
1417
+ "type": "typography",
1418
+ "variant": "body",
1419
+ "content": "@entity.name"
1420
+ }
1421
+ ]
1422
+ },
1423
+ {
1424
+ "type": "stack",
1425
+ "direction": "horizontal",
1426
+ "gap": "md",
1427
+ "children": [
1428
+ {
1429
+ "type": "typography",
1430
+ "variant": "caption",
1431
+ "content": "Description"
1432
+ },
1433
+ {
1434
+ "type": "typography",
1435
+ "variant": "body",
1436
+ "content": "@entity.description"
1437
+ }
1438
+ ]
1439
+ },
1440
+ {
1441
+ "type": "stack",
1442
+ "direction": "horizontal",
1443
+ "gap": "md",
1444
+ "children": [
1445
+ {
1446
+ "type": "typography",
1447
+ "variant": "caption",
1448
+ "content": "MemberCount"
1449
+ },
1450
+ {
1451
+ "type": "typography",
1452
+ "variant": "body",
1453
+ "content": "@entity.memberCount"
1454
+ }
1455
+ ]
1456
+ },
1457
+ {
1458
+ "type": "stack",
1459
+ "direction": "horizontal",
1460
+ "gap": "md",
1461
+ "children": [
1462
+ {
1463
+ "type": "typography",
1464
+ "variant": "caption",
1465
+ "content": "IsPrivate"
1466
+ },
1467
+ {
1468
+ "type": "typography",
1469
+ "variant": "body",
1470
+ "content": "@entity.isPrivate"
1471
+ }
1472
+ ]
1473
+ },
1474
+ {
1475
+ "type": "divider"
1476
+ },
1477
+ {
1478
+ "type": "stack",
1479
+ "direction": "horizontal",
1480
+ "gap": "sm",
1481
+ "justify": "end",
1482
+ "children": [
1483
+ {
1484
+ "type": "button",
1485
+ "label": "Edit",
1486
+ "event": "EDIT",
1487
+ "variant": "primary",
1488
+ "icon": "edit"
1489
+ },
1490
+ {
1491
+ "type": "button",
1492
+ "label": "Close",
1493
+ "event": "CLOSE",
1494
+ "variant": "ghost"
1495
+ }
1496
+ ]
1497
+ }
1498
+ ]
1499
+ }
1500
+ ]
1501
+ ]
1502
+ },
1503
+ {
1504
+ "from": "open",
1505
+ "to": "closed",
1506
+ "event": "CLOSE",
1507
+ "effects": [
1508
+ [
1509
+ "render-ui",
1510
+ "modal",
1511
+ null
1512
+ ]
1513
+ ]
1514
+ }
1515
+ ]
1516
+ }
1517
+ }
1518
+ ],
1519
+ "pages": [
1520
+ {
1521
+ "name": "ChannelsPage",
1522
+ "path": "/channels",
1523
+ "traits": [
1524
+ {
1525
+ "ref": "ChannelBrowse"
1526
+ },
1527
+ {
1528
+ "ref": "ChannelCreate"
1529
+ },
1530
+ {
1531
+ "ref": "ChannelEdit"
1532
+ },
1533
+ {
1534
+ "ref": "ChannelView"
1535
+ }
1536
+ ]
1537
+ }
1538
+ ]
1539
+ },
1540
+ {
1541
+ "name": "OnlineUserOrbital",
1542
+ "entity": {
1543
+ "name": "OnlineUser",
1544
+ "persistence": "runtime",
1545
+ "fields": [
1546
+ {
1547
+ "name": "id",
1548
+ "type": "string",
1549
+ "required": true
1550
+ },
1551
+ {
1552
+ "name": "username",
1553
+ "type": "string",
1554
+ "required": true
1555
+ },
1556
+ {
1557
+ "name": "status",
1558
+ "type": "string",
1559
+ "default": "online"
1560
+ },
1561
+ {
1562
+ "name": "lastActive",
1563
+ "type": "string"
1564
+ },
1565
+ {
1566
+ "name": "avatar",
1567
+ "type": "string"
1568
+ }
1569
+ ]
1570
+ },
1571
+ "traits": [
1572
+ {
1573
+ "name": "OnlineUserDisplay",
1574
+ "linkedEntity": "OnlineUser",
1575
+ "category": "interaction",
1576
+ "stateMachine": {
1577
+ "states": [
1578
+ {
1579
+ "name": "loading",
1580
+ "isInitial": true
1581
+ },
1582
+ {
1583
+ "name": "displaying"
1584
+ },
1585
+ {
1586
+ "name": "refreshing"
1587
+ }
1588
+ ],
1589
+ "events": [
1590
+ {
1591
+ "key": "INIT",
1592
+ "name": "Initialize"
1593
+ },
1594
+ {
1595
+ "key": "LOADED",
1596
+ "name": "Loaded"
1597
+ },
1598
+ {
1599
+ "key": "REFRESH",
1600
+ "name": "Refresh"
1601
+ },
1602
+ {
1603
+ "key": "REFRESHED",
1604
+ "name": "Refreshed"
1605
+ }
1606
+ ],
1607
+ "transitions": [
1608
+ {
1609
+ "from": "loading",
1610
+ "to": "displaying",
1611
+ "event": "INIT",
1612
+ "effects": [
1613
+ [
1614
+ "fetch",
1615
+ "OnlineUser"
1616
+ ],
1617
+ [
1618
+ "render-ui",
1619
+ "main",
1620
+ {
1621
+ "type": "stack",
1622
+ "direction": "vertical",
1623
+ "gap": "lg",
1624
+ "children": [
1625
+ {
1626
+ "type": "stack",
1627
+ "direction": "horizontal",
1628
+ "gap": "md",
1629
+ "justify": "space-between",
1630
+ "children": [
1631
+ {
1632
+ "type": "stack",
1633
+ "direction": "horizontal",
1634
+ "gap": "md",
1635
+ "children": [
1636
+ {
1637
+ "type": "icon",
1638
+ "name": "users",
1639
+ "size": "lg"
1640
+ },
1641
+ {
1642
+ "type": "typography",
1643
+ "content": "Online Users",
1644
+ "variant": "h2"
1645
+ }
1646
+ ]
1647
+ },
1648
+ {
1649
+ "type": "button",
1650
+ "label": "Refresh",
1651
+ "event": "REFRESH",
1652
+ "variant": "secondary",
1653
+ "icon": "refresh-cw"
1654
+ }
1655
+ ]
1656
+ },
1657
+ {
1658
+ "type": "divider"
1659
+ },
1660
+ {
1661
+ "type": "simple-grid",
1662
+ "columns": 3,
1663
+ "children": [
1664
+ {
1665
+ "type": "card",
1666
+ "children": [
1667
+ {
1668
+ "type": "stack",
1669
+ "direction": "vertical",
1670
+ "gap": "sm",
1671
+ "children": [
1672
+ {
1673
+ "type": "typography",
1674
+ "variant": "caption",
1675
+ "content": "Username"
1676
+ },
1677
+ {
1678
+ "type": "typography",
1679
+ "variant": "h3",
1680
+ "content": "@entity.username"
1681
+ }
1682
+ ]
1683
+ }
1684
+ ]
1685
+ },
1686
+ {
1687
+ "type": "card",
1688
+ "children": [
1689
+ {
1690
+ "type": "stack",
1691
+ "direction": "vertical",
1692
+ "gap": "sm",
1693
+ "children": [
1694
+ {
1695
+ "type": "typography",
1696
+ "variant": "caption",
1697
+ "content": "Status"
1698
+ },
1699
+ {
1700
+ "type": "typography",
1701
+ "variant": "h3",
1702
+ "content": "@entity.status"
1703
+ }
1704
+ ]
1705
+ }
1706
+ ]
1707
+ },
1708
+ {
1709
+ "type": "card",
1710
+ "children": [
1711
+ {
1712
+ "type": "stack",
1713
+ "direction": "vertical",
1714
+ "gap": "sm",
1715
+ "children": [
1716
+ {
1717
+ "type": "typography",
1718
+ "variant": "caption",
1719
+ "content": "LastActive"
1720
+ },
1721
+ {
1722
+ "type": "typography",
1723
+ "variant": "h3",
1724
+ "content": "@entity.lastActive"
1725
+ }
1726
+ ]
1727
+ }
1728
+ ]
1729
+ },
1730
+ {
1731
+ "type": "card",
1732
+ "children": [
1733
+ {
1734
+ "type": "stack",
1735
+ "direction": "vertical",
1736
+ "gap": "sm",
1737
+ "children": [
1738
+ {
1739
+ "type": "typography",
1740
+ "variant": "caption",
1741
+ "content": "Avatar"
1742
+ },
1743
+ {
1744
+ "type": "typography",
1745
+ "variant": "h3",
1746
+ "content": "@entity.avatar"
1747
+ }
1748
+ ]
1749
+ }
1750
+ ]
1751
+ }
1752
+ ]
1753
+ }
1754
+ ]
1755
+ }
1756
+ ]
1757
+ ]
1758
+ },
1759
+ {
1760
+ "from": "loading",
1761
+ "to": "displaying",
1762
+ "event": "LOADED",
1763
+ "effects": [
1764
+ [
1765
+ "fetch",
1766
+ "OnlineUser"
1767
+ ],
1768
+ [
1769
+ "render-ui",
1770
+ "main",
1771
+ {
1772
+ "type": "stack",
1773
+ "direction": "vertical",
1774
+ "gap": "lg",
1775
+ "children": [
1776
+ {
1777
+ "type": "stack",
1778
+ "direction": "horizontal",
1779
+ "gap": "md",
1780
+ "justify": "space-between",
1781
+ "children": [
1782
+ {
1783
+ "type": "stack",
1784
+ "direction": "horizontal",
1785
+ "gap": "md",
1786
+ "children": [
1787
+ {
1788
+ "type": "icon",
1789
+ "name": "users",
1790
+ "size": "lg"
1791
+ },
1792
+ {
1793
+ "type": "typography",
1794
+ "content": "Online Users",
1795
+ "variant": "h2"
1796
+ }
1797
+ ]
1798
+ },
1799
+ {
1800
+ "type": "button",
1801
+ "label": "Refresh",
1802
+ "event": "REFRESH",
1803
+ "variant": "secondary",
1804
+ "icon": "refresh-cw"
1805
+ }
1806
+ ]
1807
+ },
1808
+ {
1809
+ "type": "divider"
1810
+ },
1811
+ {
1812
+ "type": "simple-grid",
1813
+ "columns": 3,
1814
+ "children": [
1815
+ {
1816
+ "type": "card",
1817
+ "children": [
1818
+ {
1819
+ "type": "stack",
1820
+ "direction": "vertical",
1821
+ "gap": "sm",
1822
+ "children": [
1823
+ {
1824
+ "type": "typography",
1825
+ "variant": "caption",
1826
+ "content": "Username"
1827
+ },
1828
+ {
1829
+ "type": "typography",
1830
+ "variant": "h3",
1831
+ "content": "@entity.username"
1832
+ }
1833
+ ]
1834
+ }
1835
+ ]
1836
+ },
1837
+ {
1838
+ "type": "card",
1839
+ "children": [
1840
+ {
1841
+ "type": "stack",
1842
+ "direction": "vertical",
1843
+ "gap": "sm",
1844
+ "children": [
1845
+ {
1846
+ "type": "typography",
1847
+ "variant": "caption",
1848
+ "content": "Status"
1849
+ },
1850
+ {
1851
+ "type": "typography",
1852
+ "variant": "h3",
1853
+ "content": "@entity.status"
1854
+ }
1855
+ ]
1856
+ }
1857
+ ]
1858
+ },
1859
+ {
1860
+ "type": "card",
1861
+ "children": [
1862
+ {
1863
+ "type": "stack",
1864
+ "direction": "vertical",
1865
+ "gap": "sm",
1866
+ "children": [
1867
+ {
1868
+ "type": "typography",
1869
+ "variant": "caption",
1870
+ "content": "LastActive"
1871
+ },
1872
+ {
1873
+ "type": "typography",
1874
+ "variant": "h3",
1875
+ "content": "@entity.lastActive"
1876
+ }
1877
+ ]
1878
+ }
1879
+ ]
1880
+ },
1881
+ {
1882
+ "type": "card",
1883
+ "children": [
1884
+ {
1885
+ "type": "stack",
1886
+ "direction": "vertical",
1887
+ "gap": "sm",
1888
+ "children": [
1889
+ {
1890
+ "type": "typography",
1891
+ "variant": "caption",
1892
+ "content": "Avatar"
1893
+ },
1894
+ {
1895
+ "type": "typography",
1896
+ "variant": "h3",
1897
+ "content": "@entity.avatar"
1898
+ }
1899
+ ]
1900
+ }
1901
+ ]
1902
+ }
1903
+ ]
1904
+ }
1905
+ ]
1906
+ }
1907
+ ]
1908
+ ]
1909
+ },
1910
+ {
1911
+ "from": "displaying",
1912
+ "to": "displaying",
1913
+ "event": "INIT",
1914
+ "effects": [
1915
+ [
1916
+ "fetch",
1917
+ "OnlineUser"
1918
+ ],
1919
+ [
1920
+ "render-ui",
1921
+ "main",
1922
+ {
1923
+ "type": "stack",
1924
+ "direction": "vertical",
1925
+ "gap": "lg",
1926
+ "children": [
1927
+ {
1928
+ "type": "stack",
1929
+ "direction": "horizontal",
1930
+ "gap": "md",
1931
+ "justify": "space-between",
1932
+ "children": [
1933
+ {
1934
+ "type": "stack",
1935
+ "direction": "horizontal",
1936
+ "gap": "md",
1937
+ "children": [
1938
+ {
1939
+ "type": "icon",
1940
+ "name": "users",
1941
+ "size": "lg"
1942
+ },
1943
+ {
1944
+ "type": "typography",
1945
+ "content": "Online Users",
1946
+ "variant": "h2"
1947
+ }
1948
+ ]
1949
+ },
1950
+ {
1951
+ "type": "button",
1952
+ "label": "Refresh",
1953
+ "event": "REFRESH",
1954
+ "variant": "secondary",
1955
+ "icon": "refresh-cw"
1956
+ }
1957
+ ]
1958
+ },
1959
+ {
1960
+ "type": "divider"
1961
+ },
1962
+ {
1963
+ "type": "simple-grid",
1964
+ "columns": 3,
1965
+ "children": [
1966
+ {
1967
+ "type": "card",
1968
+ "children": [
1969
+ {
1970
+ "type": "stack",
1971
+ "direction": "vertical",
1972
+ "gap": "sm",
1973
+ "children": [
1974
+ {
1975
+ "type": "typography",
1976
+ "variant": "caption",
1977
+ "content": "Username"
1978
+ },
1979
+ {
1980
+ "type": "typography",
1981
+ "variant": "h3",
1982
+ "content": "@entity.username"
1983
+ }
1984
+ ]
1985
+ }
1986
+ ]
1987
+ },
1988
+ {
1989
+ "type": "card",
1990
+ "children": [
1991
+ {
1992
+ "type": "stack",
1993
+ "direction": "vertical",
1994
+ "gap": "sm",
1995
+ "children": [
1996
+ {
1997
+ "type": "typography",
1998
+ "variant": "caption",
1999
+ "content": "Status"
2000
+ },
2001
+ {
2002
+ "type": "typography",
2003
+ "variant": "h3",
2004
+ "content": "@entity.status"
2005
+ }
2006
+ ]
2007
+ }
2008
+ ]
2009
+ },
2010
+ {
2011
+ "type": "card",
2012
+ "children": [
2013
+ {
2014
+ "type": "stack",
2015
+ "direction": "vertical",
2016
+ "gap": "sm",
2017
+ "children": [
2018
+ {
2019
+ "type": "typography",
2020
+ "variant": "caption",
2021
+ "content": "LastActive"
2022
+ },
2023
+ {
2024
+ "type": "typography",
2025
+ "variant": "h3",
2026
+ "content": "@entity.lastActive"
2027
+ }
2028
+ ]
2029
+ }
2030
+ ]
2031
+ },
2032
+ {
2033
+ "type": "card",
2034
+ "children": [
2035
+ {
2036
+ "type": "stack",
2037
+ "direction": "vertical",
2038
+ "gap": "sm",
2039
+ "children": [
2040
+ {
2041
+ "type": "typography",
2042
+ "variant": "caption",
2043
+ "content": "Avatar"
2044
+ },
2045
+ {
2046
+ "type": "typography",
2047
+ "variant": "h3",
2048
+ "content": "@entity.avatar"
2049
+ }
2050
+ ]
2051
+ }
2052
+ ]
2053
+ }
2054
+ ]
2055
+ }
2056
+ ]
2057
+ }
2058
+ ]
2059
+ ]
2060
+ },
2061
+ {
2062
+ "from": "displaying",
2063
+ "to": "refreshing",
2064
+ "event": "REFRESH",
2065
+ "effects": [
2066
+ [
2067
+ "fetch",
2068
+ "OnlineUser"
2069
+ ],
2070
+ [
2071
+ "render-ui",
2072
+ "main",
2073
+ {
2074
+ "type": "stack",
2075
+ "direction": "vertical",
2076
+ "gap": "lg",
2077
+ "children": [
2078
+ {
2079
+ "type": "stack",
2080
+ "direction": "horizontal",
2081
+ "gap": "md",
2082
+ "justify": "space-between",
2083
+ "children": [
2084
+ {
2085
+ "type": "stack",
2086
+ "direction": "horizontal",
2087
+ "gap": "md",
2088
+ "children": [
2089
+ {
2090
+ "type": "icon",
2091
+ "name": "users",
2092
+ "size": "lg"
2093
+ },
2094
+ {
2095
+ "type": "typography",
2096
+ "content": "Online Users",
2097
+ "variant": "h2"
2098
+ }
2099
+ ]
2100
+ },
2101
+ {
2102
+ "type": "button",
2103
+ "label": "Refresh",
2104
+ "event": "REFRESH",
2105
+ "variant": "secondary",
2106
+ "icon": "refresh-cw"
2107
+ }
2108
+ ]
2109
+ },
2110
+ {
2111
+ "type": "divider"
2112
+ },
2113
+ {
2114
+ "type": "simple-grid",
2115
+ "columns": 3,
2116
+ "children": [
2117
+ {
2118
+ "type": "card",
2119
+ "children": [
2120
+ {
2121
+ "type": "stack",
2122
+ "direction": "vertical",
2123
+ "gap": "sm",
2124
+ "children": [
2125
+ {
2126
+ "type": "typography",
2127
+ "variant": "caption",
2128
+ "content": "Username"
2129
+ },
2130
+ {
2131
+ "type": "typography",
2132
+ "variant": "h3",
2133
+ "content": "@entity.username"
2134
+ }
2135
+ ]
2136
+ }
2137
+ ]
2138
+ },
2139
+ {
2140
+ "type": "card",
2141
+ "children": [
2142
+ {
2143
+ "type": "stack",
2144
+ "direction": "vertical",
2145
+ "gap": "sm",
2146
+ "children": [
2147
+ {
2148
+ "type": "typography",
2149
+ "variant": "caption",
2150
+ "content": "Status"
2151
+ },
2152
+ {
2153
+ "type": "typography",
2154
+ "variant": "h3",
2155
+ "content": "@entity.status"
2156
+ }
2157
+ ]
2158
+ }
2159
+ ]
2160
+ },
2161
+ {
2162
+ "type": "card",
2163
+ "children": [
2164
+ {
2165
+ "type": "stack",
2166
+ "direction": "vertical",
2167
+ "gap": "sm",
2168
+ "children": [
2169
+ {
2170
+ "type": "typography",
2171
+ "variant": "caption",
2172
+ "content": "LastActive"
2173
+ },
2174
+ {
2175
+ "type": "typography",
2176
+ "variant": "h3",
2177
+ "content": "@entity.lastActive"
2178
+ }
2179
+ ]
2180
+ }
2181
+ ]
2182
+ },
2183
+ {
2184
+ "type": "card",
2185
+ "children": [
2186
+ {
2187
+ "type": "stack",
2188
+ "direction": "vertical",
2189
+ "gap": "sm",
2190
+ "children": [
2191
+ {
2192
+ "type": "typography",
2193
+ "variant": "caption",
2194
+ "content": "Avatar"
2195
+ },
2196
+ {
2197
+ "type": "typography",
2198
+ "variant": "h3",
2199
+ "content": "@entity.avatar"
2200
+ }
2201
+ ]
2202
+ }
2203
+ ]
2204
+ }
2205
+ ]
2206
+ }
2207
+ ]
2208
+ }
2209
+ ]
2210
+ ]
2211
+ },
2212
+ {
2213
+ "from": "refreshing",
2214
+ "to": "displaying",
2215
+ "event": "REFRESHED",
2216
+ "effects": [
2217
+ [
2218
+ "fetch",
2219
+ "OnlineUser"
2220
+ ],
2221
+ [
2222
+ "render-ui",
2223
+ "main",
2224
+ {
2225
+ "type": "stack",
2226
+ "direction": "vertical",
2227
+ "gap": "lg",
2228
+ "children": [
2229
+ {
2230
+ "type": "stack",
2231
+ "direction": "horizontal",
2232
+ "gap": "md",
2233
+ "justify": "space-between",
2234
+ "children": [
2235
+ {
2236
+ "type": "stack",
2237
+ "direction": "horizontal",
2238
+ "gap": "md",
2239
+ "children": [
2240
+ {
2241
+ "type": "icon",
2242
+ "name": "users",
2243
+ "size": "lg"
2244
+ },
2245
+ {
2246
+ "type": "typography",
2247
+ "content": "Online Users",
2248
+ "variant": "h2"
2249
+ }
2250
+ ]
2251
+ },
2252
+ {
2253
+ "type": "button",
2254
+ "label": "Refresh",
2255
+ "event": "REFRESH",
2256
+ "variant": "secondary",
2257
+ "icon": "refresh-cw"
2258
+ }
2259
+ ]
2260
+ },
2261
+ {
2262
+ "type": "divider"
2263
+ },
2264
+ {
2265
+ "type": "simple-grid",
2266
+ "columns": 3,
2267
+ "children": [
2268
+ {
2269
+ "type": "card",
2270
+ "children": [
2271
+ {
2272
+ "type": "stack",
2273
+ "direction": "vertical",
2274
+ "gap": "sm",
2275
+ "children": [
2276
+ {
2277
+ "type": "typography",
2278
+ "variant": "caption",
2279
+ "content": "Username"
2280
+ },
2281
+ {
2282
+ "type": "typography",
2283
+ "variant": "h3",
2284
+ "content": "@entity.username"
2285
+ }
2286
+ ]
2287
+ }
2288
+ ]
2289
+ },
2290
+ {
2291
+ "type": "card",
2292
+ "children": [
2293
+ {
2294
+ "type": "stack",
2295
+ "direction": "vertical",
2296
+ "gap": "sm",
2297
+ "children": [
2298
+ {
2299
+ "type": "typography",
2300
+ "variant": "caption",
2301
+ "content": "Status"
2302
+ },
2303
+ {
2304
+ "type": "typography",
2305
+ "variant": "h3",
2306
+ "content": "@entity.status"
2307
+ }
2308
+ ]
2309
+ }
2310
+ ]
2311
+ },
2312
+ {
2313
+ "type": "card",
2314
+ "children": [
2315
+ {
2316
+ "type": "stack",
2317
+ "direction": "vertical",
2318
+ "gap": "sm",
2319
+ "children": [
2320
+ {
2321
+ "type": "typography",
2322
+ "variant": "caption",
2323
+ "content": "LastActive"
2324
+ },
2325
+ {
2326
+ "type": "typography",
2327
+ "variant": "h3",
2328
+ "content": "@entity.lastActive"
2329
+ }
2330
+ ]
2331
+ }
2332
+ ]
2333
+ },
2334
+ {
2335
+ "type": "card",
2336
+ "children": [
2337
+ {
2338
+ "type": "stack",
2339
+ "direction": "vertical",
2340
+ "gap": "sm",
2341
+ "children": [
2342
+ {
2343
+ "type": "typography",
2344
+ "variant": "caption",
2345
+ "content": "Avatar"
2346
+ },
2347
+ {
2348
+ "type": "typography",
2349
+ "variant": "h3",
2350
+ "content": "@entity.avatar"
2351
+ }
2352
+ ]
2353
+ }
2354
+ ]
2355
+ }
2356
+ ]
2357
+ }
2358
+ ]
2359
+ }
2360
+ ]
2361
+ ]
2362
+ }
2363
+ ]
2364
+ }
2365
+ }
2366
+ ],
2367
+ "pages": [
2368
+ {
2369
+ "name": "OnlinePage",
2370
+ "path": "/online",
2371
+ "traits": [
2372
+ {
2373
+ "ref": "OnlineUserDisplay"
2374
+ }
2375
+ ]
2376
+ }
2377
+ ]
2378
+ }
2379
+ ]
2380
+ }