@almadar/std 5.0.0 → 5.2.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 (421) hide show
  1. package/behaviors/exports/atoms/std-agent-activity-log.orb +5 -45
  2. package/behaviors/exports/atoms/std-agent-chat-thread.orb +5 -55
  3. package/behaviors/exports/atoms/std-agent-classifier.orb +8 -8
  4. package/behaviors/exports/atoms/std-agent-completion.orb +8 -8
  5. package/behaviors/exports/atoms/std-agent-context-window.orb +5 -4
  6. package/behaviors/exports/atoms/std-agent-conversation.orb +5 -71
  7. package/behaviors/exports/atoms/std-agent-memory.orb +13 -127
  8. package/behaviors/exports/atoms/std-agent-provider.orb +8 -8
  9. package/behaviors/exports/atoms/std-agent-search.orb +6 -27
  10. package/behaviors/exports/atoms/std-agent-session.orb +11 -85
  11. package/behaviors/exports/atoms/std-agent-step-progress.orb +5 -4
  12. package/behaviors/exports/atoms/std-agent-token-gauge.orb +5 -4
  13. package/behaviors/exports/atoms/std-agent-tool-call.orb +8 -8
  14. package/behaviors/exports/atoms/std-async.orb +5 -8
  15. package/behaviors/exports/atoms/std-autoregressive.orb +4 -2
  16. package/behaviors/exports/atoms/std-browse.orb +5 -4
  17. package/behaviors/exports/atoms/std-cache-aside.orb +5 -8
  18. package/behaviors/exports/atoms/std-calendar.orb +5 -4
  19. package/behaviors/exports/atoms/std-circuit-breaker.orb +5 -4
  20. package/behaviors/exports/atoms/std-collision.orb +5 -4
  21. package/behaviors/exports/atoms/std-combat-log.orb +5 -4
  22. package/behaviors/exports/atoms/std-combat.orb +5 -4
  23. package/behaviors/exports/atoms/std-confirmation.orb +10 -4
  24. package/behaviors/exports/atoms/std-dialogue-box.orb +5 -4
  25. package/behaviors/exports/atoms/std-display.orb +5 -4
  26. package/behaviors/exports/atoms/std-drawer.orb +5 -4
  27. package/behaviors/exports/atoms/std-filter.orb +5 -4
  28. package/behaviors/exports/atoms/std-flip-card.orb +5 -4
  29. package/behaviors/exports/atoms/std-gallery.orb +5 -4
  30. package/behaviors/exports/atoms/std-game-audio.orb +5 -4
  31. package/behaviors/exports/atoms/std-game-canvas2d.orb +4 -2
  32. package/behaviors/exports/atoms/std-game-canvas3d.orb +4 -2
  33. package/behaviors/exports/atoms/std-game-hud.orb +5 -4
  34. package/behaviors/exports/atoms/std-game-menu.orb +5 -4
  35. package/behaviors/exports/atoms/std-game-over-screen.orb +5 -4
  36. package/behaviors/exports/atoms/std-gameflow.orb +5 -4
  37. package/behaviors/exports/atoms/std-input.orb +5 -4
  38. package/behaviors/exports/atoms/std-inventory-panel.orb +5 -8
  39. package/behaviors/exports/atoms/std-isometric-canvas.orb +5 -4
  40. package/behaviors/exports/atoms/std-loading.orb +5 -4
  41. package/behaviors/exports/atoms/std-modal.orb +89 -4
  42. package/behaviors/exports/atoms/std-movement.orb +5 -4
  43. package/behaviors/exports/atoms/std-notification.orb +5 -4
  44. package/behaviors/exports/atoms/std-overworld.orb +5 -4
  45. package/behaviors/exports/atoms/std-pagination.orb +5 -4
  46. package/behaviors/exports/atoms/std-physics2d.orb +5 -4
  47. package/behaviors/exports/atoms/std-platformer-canvas.orb +5 -4
  48. package/behaviors/exports/atoms/std-quest.orb +5 -8
  49. package/behaviors/exports/atoms/std-rate-limiter.orb +5 -4
  50. package/behaviors/exports/atoms/std-rating.orb +5 -4
  51. package/behaviors/exports/atoms/std-score-board.orb +5 -4
  52. package/behaviors/exports/atoms/std-score.orb +5 -4
  53. package/behaviors/exports/atoms/std-search.orb +5 -4
  54. package/behaviors/exports/atoms/std-selection.orb +5 -4
  55. package/behaviors/exports/atoms/std-service-custom-bearer.orb +5 -15
  56. package/behaviors/exports/atoms/std-service-custom-header.orb +5 -17
  57. package/behaviors/exports/atoms/std-service-custom-noauth.orb +5 -11
  58. package/behaviors/exports/atoms/std-service-custom-query.orb +5 -17
  59. package/behaviors/exports/atoms/std-service-email.orb +5 -4
  60. package/behaviors/exports/atoms/std-service-github.orb +5 -4
  61. package/behaviors/exports/atoms/std-service-llm.orb +5 -4
  62. package/behaviors/exports/atoms/std-service-oauth.orb +5 -4
  63. package/behaviors/exports/atoms/std-service-redis.orb +5 -4
  64. package/behaviors/exports/atoms/std-service-storage.orb +5 -4
  65. package/behaviors/exports/atoms/std-service-stripe.orb +5 -4
  66. package/behaviors/exports/atoms/std-service-twilio.orb +5 -4
  67. package/behaviors/exports/atoms/std-service-youtube.orb +5 -4
  68. package/behaviors/exports/atoms/std-simulation-canvas.orb +5 -4
  69. package/behaviors/exports/atoms/std-sort.orb +5 -4
  70. package/behaviors/exports/atoms/std-sprite.orb +5 -4
  71. package/behaviors/exports/atoms/std-tabs.orb +5 -4
  72. package/behaviors/exports/atoms/std-text-effects.orb +5 -4
  73. package/behaviors/exports/atoms/std-theme.orb +5 -4
  74. package/behaviors/exports/atoms/std-timer.orb +5 -4
  75. package/behaviors/exports/atoms/std-undo.orb +5 -4
  76. package/behaviors/exports/atoms/std-upload.orb +5 -4
  77. package/behaviors/exports/atoms/std-validate-on-save.orb +5 -32
  78. package/behaviors/exports/atoms/std-wizard.orb +5 -4
  79. package/behaviors/exports/molecules/std-agent-fix-loop.orb +1141 -1709
  80. package/behaviors/exports/molecules/std-agent-learner.orb +608 -938
  81. package/behaviors/exports/molecules/std-agent-planner.orb +613 -961
  82. package/behaviors/exports/molecules/std-agent-rag.orb +586 -915
  83. package/behaviors/exports/molecules/std-agent-tool-loop.orb +915 -2846
  84. package/behaviors/exports/molecules/std-builder-game.orb +5 -4
  85. package/behaviors/exports/molecules/std-cart.orb +196 -307
  86. package/behaviors/exports/molecules/std-classifier-game.orb +5 -4
  87. package/behaviors/exports/molecules/std-debugger-game.orb +5 -4
  88. package/behaviors/exports/molecules/std-detail.orb +309 -467
  89. package/behaviors/exports/molecules/std-event-handler-game.orb +5 -4
  90. package/behaviors/exports/molecules/std-form-advanced.orb +5 -8
  91. package/behaviors/exports/molecules/std-geospatial.orb +363 -539
  92. package/behaviors/exports/molecules/std-inventory.orb +390 -720
  93. package/behaviors/exports/molecules/std-list.orb +526 -1156
  94. package/behaviors/exports/molecules/std-messaging.orb +295 -452
  95. package/behaviors/exports/molecules/std-negotiator-game.orb +5 -4
  96. package/behaviors/exports/molecules/std-platformer-game.orb +5 -4
  97. package/behaviors/exports/molecules/std-puzzle-game.orb +5 -4
  98. package/behaviors/exports/molecules/std-quiz.orb +5 -4
  99. package/behaviors/exports/molecules/std-sequencer-game.orb +5 -4
  100. package/behaviors/exports/molecules/std-service-content-pipeline.orb +5 -4
  101. package/behaviors/exports/molecules/std-service-custom-api-tester.orb +5 -42
  102. package/behaviors/exports/molecules/std-service-devops-toolkit.orb +5 -4
  103. package/behaviors/exports/molecules/std-service-notification-hub.orb +5 -4
  104. package/behaviors/exports/molecules/std-service-payment-flow.orb +5 -4
  105. package/behaviors/exports/molecules/std-simulator-game.orb +5 -4
  106. package/behaviors/exports/molecules/std-turn-based-battle.orb +5 -4
  107. package/behaviors/exports/organisms/std-agent-assistant.orb +15 -143
  108. package/behaviors/exports/organisms/std-agent-builder.orb +814 -1476
  109. package/behaviors/exports/organisms/std-agent-pipeline.orb +785 -1567
  110. package/behaviors/exports/organisms/std-agent-reviewer.orb +299 -502
  111. package/behaviors/exports/organisms/std-agent-tutor.orb +306 -493
  112. package/behaviors/exports/organisms/std-api-gateway.orb +284 -626
  113. package/behaviors/exports/organisms/std-arcade-game.orb +4 -4
  114. package/behaviors/exports/organisms/std-booking-system.orb +1422 -2160
  115. package/behaviors/exports/organisms/std-cicd-pipeline.orb +274 -617
  116. package/behaviors/exports/organisms/std-cms.orb +1274 -1972
  117. package/behaviors/exports/organisms/std-coding-academy.orb +4 -4
  118. package/behaviors/exports/organisms/std-crm.orb +999 -1775
  119. package/behaviors/exports/organisms/std-devops-dashboard.orb +284 -638
  120. package/behaviors/exports/organisms/std-ecommerce.orb +1653 -2398
  121. package/behaviors/exports/organisms/std-finance-tracker.orb +340 -684
  122. package/behaviors/exports/organisms/std-healthcare.orb +984 -1838
  123. package/behaviors/exports/organisms/std-helpdesk.orb +340 -744
  124. package/behaviors/exports/organisms/std-hr-portal.orb +1401 -2151
  125. package/behaviors/exports/organisms/std-iot-dashboard.orb +284 -626
  126. package/behaviors/exports/organisms/std-lms.orb +284 -632
  127. package/behaviors/exports/organisms/std-logic-training.orb +4 -4
  128. package/behaviors/exports/organisms/std-platformer-app.orb +15 -98
  129. package/behaviors/exports/organisms/std-project-manager.orb +970 -1774
  130. package/behaviors/exports/organisms/std-puzzle-app.orb +4 -4
  131. package/behaviors/exports/organisms/std-realtime-chat.orb +364 -714
  132. package/behaviors/exports/organisms/std-rpg-game.orb +15 -102
  133. package/behaviors/exports/organisms/std-service-marketplace.orb +1589 -2361
  134. package/behaviors/exports/organisms/std-service-research-assistant.orb +4 -15
  135. package/behaviors/exports/organisms/std-social-feed.orb +62 -66
  136. package/behaviors/exports/organisms/std-stem-lab.orb +4 -4
  137. package/behaviors/exports/organisms/std-strategy-game.orb +4 -4
  138. package/behaviors/exports/organisms/std-trading-dashboard.orb +274 -620
  139. package/dist/behaviors/exports/atoms/std-agent-activity-log.orb +5 -45
  140. package/dist/behaviors/exports/atoms/std-agent-chat-thread.orb +5 -55
  141. package/dist/behaviors/exports/atoms/std-agent-classifier.orb +8 -8
  142. package/dist/behaviors/exports/atoms/std-agent-completion.orb +8 -8
  143. package/dist/behaviors/exports/atoms/std-agent-context-window.orb +5 -4
  144. package/dist/behaviors/exports/atoms/std-agent-conversation.orb +5 -71
  145. package/dist/behaviors/exports/atoms/std-agent-memory.orb +13 -127
  146. package/dist/behaviors/exports/atoms/std-agent-provider.orb +8 -8
  147. package/dist/behaviors/exports/atoms/std-agent-search.orb +6 -27
  148. package/dist/behaviors/exports/atoms/std-agent-session.orb +11 -85
  149. package/dist/behaviors/exports/atoms/std-agent-step-progress.orb +5 -4
  150. package/dist/behaviors/exports/atoms/std-agent-token-gauge.orb +5 -4
  151. package/dist/behaviors/exports/atoms/std-agent-tool-call.orb +8 -8
  152. package/dist/behaviors/exports/atoms/std-async.orb +5 -8
  153. package/dist/behaviors/exports/atoms/std-autoregressive.orb +4 -2
  154. package/dist/behaviors/exports/atoms/std-browse.orb +5 -4
  155. package/dist/behaviors/exports/atoms/std-cache-aside.orb +5 -8
  156. package/dist/behaviors/exports/atoms/std-calendar.orb +5 -4
  157. package/dist/behaviors/exports/atoms/std-circuit-breaker.orb +5 -4
  158. package/dist/behaviors/exports/atoms/std-collision.orb +5 -4
  159. package/dist/behaviors/exports/atoms/std-combat-log.orb +5 -4
  160. package/dist/behaviors/exports/atoms/std-combat.orb +5 -4
  161. package/dist/behaviors/exports/atoms/std-confirmation.orb +10 -4
  162. package/dist/behaviors/exports/atoms/std-dialogue-box.orb +5 -4
  163. package/dist/behaviors/exports/atoms/std-display.orb +5 -4
  164. package/dist/behaviors/exports/atoms/std-drawer.orb +5 -4
  165. package/dist/behaviors/exports/atoms/std-filter.orb +5 -4
  166. package/dist/behaviors/exports/atoms/std-flip-card.orb +5 -4
  167. package/dist/behaviors/exports/atoms/std-gallery.orb +5 -4
  168. package/dist/behaviors/exports/atoms/std-game-audio.orb +5 -4
  169. package/dist/behaviors/exports/atoms/std-game-canvas2d.orb +4 -2
  170. package/dist/behaviors/exports/atoms/std-game-canvas3d.orb +4 -2
  171. package/dist/behaviors/exports/atoms/std-game-hud.orb +5 -4
  172. package/dist/behaviors/exports/atoms/std-game-menu.orb +5 -4
  173. package/dist/behaviors/exports/atoms/std-game-over-screen.orb +5 -4
  174. package/dist/behaviors/exports/atoms/std-gameflow.orb +5 -4
  175. package/dist/behaviors/exports/atoms/std-input.orb +5 -4
  176. package/dist/behaviors/exports/atoms/std-inventory-panel.orb +5 -8
  177. package/dist/behaviors/exports/atoms/std-isometric-canvas.orb +5 -4
  178. package/dist/behaviors/exports/atoms/std-loading.orb +5 -4
  179. package/dist/behaviors/exports/atoms/std-modal.orb +89 -4
  180. package/dist/behaviors/exports/atoms/std-movement.orb +5 -4
  181. package/dist/behaviors/exports/atoms/std-notification.orb +5 -4
  182. package/dist/behaviors/exports/atoms/std-overworld.orb +5 -4
  183. package/dist/behaviors/exports/atoms/std-pagination.orb +5 -4
  184. package/dist/behaviors/exports/atoms/std-physics2d.orb +5 -4
  185. package/dist/behaviors/exports/atoms/std-platformer-canvas.orb +5 -4
  186. package/dist/behaviors/exports/atoms/std-quest.orb +5 -8
  187. package/dist/behaviors/exports/atoms/std-rate-limiter.orb +5 -4
  188. package/dist/behaviors/exports/atoms/std-rating.orb +5 -4
  189. package/dist/behaviors/exports/atoms/std-score-board.orb +5 -4
  190. package/dist/behaviors/exports/atoms/std-score.orb +5 -4
  191. package/dist/behaviors/exports/atoms/std-search.orb +5 -4
  192. package/dist/behaviors/exports/atoms/std-selection.orb +5 -4
  193. package/dist/behaviors/exports/atoms/std-service-custom-bearer.orb +5 -15
  194. package/dist/behaviors/exports/atoms/std-service-custom-header.orb +5 -17
  195. package/dist/behaviors/exports/atoms/std-service-custom-noauth.orb +5 -11
  196. package/dist/behaviors/exports/atoms/std-service-custom-query.orb +5 -17
  197. package/dist/behaviors/exports/atoms/std-service-email.orb +5 -4
  198. package/dist/behaviors/exports/atoms/std-service-github.orb +5 -4
  199. package/dist/behaviors/exports/atoms/std-service-llm.orb +5 -4
  200. package/dist/behaviors/exports/atoms/std-service-oauth.orb +5 -4
  201. package/dist/behaviors/exports/atoms/std-service-redis.orb +5 -4
  202. package/dist/behaviors/exports/atoms/std-service-storage.orb +5 -4
  203. package/dist/behaviors/exports/atoms/std-service-stripe.orb +5 -4
  204. package/dist/behaviors/exports/atoms/std-service-twilio.orb +5 -4
  205. package/dist/behaviors/exports/atoms/std-service-youtube.orb +5 -4
  206. package/dist/behaviors/exports/atoms/std-simulation-canvas.orb +5 -4
  207. package/dist/behaviors/exports/atoms/std-sort.orb +5 -4
  208. package/dist/behaviors/exports/atoms/std-sprite.orb +5 -4
  209. package/dist/behaviors/exports/atoms/std-tabs.orb +5 -4
  210. package/dist/behaviors/exports/atoms/std-text-effects.orb +5 -4
  211. package/dist/behaviors/exports/atoms/std-theme.orb +5 -4
  212. package/dist/behaviors/exports/atoms/std-timer.orb +5 -4
  213. package/dist/behaviors/exports/atoms/std-undo.orb +5 -4
  214. package/dist/behaviors/exports/atoms/std-upload.orb +5 -4
  215. package/dist/behaviors/exports/atoms/std-validate-on-save.orb +5 -32
  216. package/dist/behaviors/exports/atoms/std-wizard.orb +5 -4
  217. package/dist/behaviors/exports/molecules/std-agent-fix-loop.orb +1141 -1709
  218. package/dist/behaviors/exports/molecules/std-agent-learner.orb +608 -938
  219. package/dist/behaviors/exports/molecules/std-agent-planner.orb +613 -961
  220. package/dist/behaviors/exports/molecules/std-agent-rag.orb +586 -915
  221. package/dist/behaviors/exports/molecules/std-agent-tool-loop.orb +915 -2846
  222. package/dist/behaviors/exports/molecules/std-builder-game.orb +5 -4
  223. package/dist/behaviors/exports/molecules/std-cart.orb +196 -307
  224. package/dist/behaviors/exports/molecules/std-classifier-game.orb +5 -4
  225. package/dist/behaviors/exports/molecules/std-debugger-game.orb +5 -4
  226. package/dist/behaviors/exports/molecules/std-detail.orb +309 -467
  227. package/dist/behaviors/exports/molecules/std-event-handler-game.orb +5 -4
  228. package/dist/behaviors/exports/molecules/std-form-advanced.orb +5 -8
  229. package/dist/behaviors/exports/molecules/std-geospatial.orb +363 -539
  230. package/dist/behaviors/exports/molecules/std-inventory.orb +390 -720
  231. package/dist/behaviors/exports/molecules/std-list.orb +526 -1156
  232. package/dist/behaviors/exports/molecules/std-messaging.orb +295 -452
  233. package/dist/behaviors/exports/molecules/std-negotiator-game.orb +5 -4
  234. package/dist/behaviors/exports/molecules/std-platformer-game.orb +5 -4
  235. package/dist/behaviors/exports/molecules/std-puzzle-game.orb +5 -4
  236. package/dist/behaviors/exports/molecules/std-quiz.orb +5 -4
  237. package/dist/behaviors/exports/molecules/std-sequencer-game.orb +5 -4
  238. package/dist/behaviors/exports/molecules/std-service-content-pipeline.orb +5 -4
  239. package/dist/behaviors/exports/molecules/std-service-custom-api-tester.orb +5 -42
  240. package/dist/behaviors/exports/molecules/std-service-devops-toolkit.orb +5 -4
  241. package/dist/behaviors/exports/molecules/std-service-notification-hub.orb +5 -4
  242. package/dist/behaviors/exports/molecules/std-service-payment-flow.orb +5 -4
  243. package/dist/behaviors/exports/molecules/std-simulator-game.orb +5 -4
  244. package/dist/behaviors/exports/molecules/std-turn-based-battle.orb +5 -4
  245. package/dist/behaviors/exports/organisms/std-agent-assistant.orb +15 -143
  246. package/dist/behaviors/exports/organisms/std-agent-builder.orb +814 -1476
  247. package/dist/behaviors/exports/organisms/std-agent-pipeline.orb +785 -1567
  248. package/dist/behaviors/exports/organisms/std-agent-reviewer.orb +299 -502
  249. package/dist/behaviors/exports/organisms/std-agent-tutor.orb +306 -493
  250. package/dist/behaviors/exports/organisms/std-api-gateway.orb +284 -626
  251. package/dist/behaviors/exports/organisms/std-arcade-game.orb +4 -4
  252. package/dist/behaviors/exports/organisms/std-booking-system.orb +1422 -2160
  253. package/dist/behaviors/exports/organisms/std-cicd-pipeline.orb +274 -617
  254. package/dist/behaviors/exports/organisms/std-cms.orb +1274 -1972
  255. package/dist/behaviors/exports/organisms/std-coding-academy.orb +4 -4
  256. package/dist/behaviors/exports/organisms/std-crm.orb +999 -1775
  257. package/dist/behaviors/exports/organisms/std-devops-dashboard.orb +284 -638
  258. package/dist/behaviors/exports/organisms/std-ecommerce.orb +1653 -2398
  259. package/dist/behaviors/exports/organisms/std-finance-tracker.orb +340 -684
  260. package/dist/behaviors/exports/organisms/std-healthcare.orb +984 -1838
  261. package/dist/behaviors/exports/organisms/std-helpdesk.orb +340 -744
  262. package/dist/behaviors/exports/organisms/std-hr-portal.orb +1401 -2151
  263. package/dist/behaviors/exports/organisms/std-iot-dashboard.orb +284 -626
  264. package/dist/behaviors/exports/organisms/std-lms.orb +284 -632
  265. package/dist/behaviors/exports/organisms/std-logic-training.orb +4 -4
  266. package/dist/behaviors/exports/organisms/std-platformer-app.orb +15 -98
  267. package/dist/behaviors/exports/organisms/std-project-manager.orb +970 -1774
  268. package/dist/behaviors/exports/organisms/std-puzzle-app.orb +4 -4
  269. package/dist/behaviors/exports/organisms/std-realtime-chat.orb +364 -714
  270. package/dist/behaviors/exports/organisms/std-rpg-game.orb +15 -102
  271. package/dist/behaviors/exports/organisms/std-service-marketplace.orb +1589 -2361
  272. package/dist/behaviors/exports/organisms/std-service-research-assistant.orb +4 -15
  273. package/dist/behaviors/exports/organisms/std-social-feed.orb +62 -66
  274. package/dist/behaviors/exports/organisms/std-stem-lab.orb +4 -4
  275. package/dist/behaviors/exports/organisms/std-strategy-game.orb +4 -4
  276. package/dist/behaviors/exports/organisms/std-trading-dashboard.orb +274 -620
  277. package/dist/behaviors/exports-reader.js.map +1 -1
  278. package/dist/behaviors/functions/index.d.ts +2192 -0
  279. package/dist/behaviors/functions/index.js.map +1 -1
  280. package/dist/behaviors/index.js.map +1 -1
  281. package/dist/behaviors/query.js.map +1 -1
  282. package/dist/exports/atoms/std-agent-activity-log.orb +5 -45
  283. package/dist/exports/atoms/std-agent-chat-thread.orb +5 -55
  284. package/dist/exports/atoms/std-agent-classifier.orb +8 -8
  285. package/dist/exports/atoms/std-agent-completion.orb +8 -8
  286. package/dist/exports/atoms/std-agent-context-window.orb +5 -4
  287. package/dist/exports/atoms/std-agent-conversation.orb +5 -71
  288. package/dist/exports/atoms/std-agent-memory.orb +13 -127
  289. package/dist/exports/atoms/std-agent-provider.orb +8 -8
  290. package/dist/exports/atoms/std-agent-search.orb +6 -27
  291. package/dist/exports/atoms/std-agent-session.orb +11 -85
  292. package/dist/exports/atoms/std-agent-step-progress.orb +5 -4
  293. package/dist/exports/atoms/std-agent-token-gauge.orb +5 -4
  294. package/dist/exports/atoms/std-agent-tool-call.orb +8 -8
  295. package/dist/exports/atoms/std-async.orb +5 -8
  296. package/dist/exports/atoms/std-autoregressive.orb +4 -2
  297. package/dist/exports/atoms/std-browse.orb +5 -4
  298. package/dist/exports/atoms/std-cache-aside.orb +5 -8
  299. package/dist/exports/atoms/std-calendar.orb +5 -4
  300. package/dist/exports/atoms/std-circuit-breaker.orb +5 -4
  301. package/dist/exports/atoms/std-collision.orb +5 -4
  302. package/dist/exports/atoms/std-combat-log.orb +5 -4
  303. package/dist/exports/atoms/std-combat.orb +5 -4
  304. package/dist/exports/atoms/std-confirmation.orb +10 -4
  305. package/dist/exports/atoms/std-dialogue-box.orb +5 -4
  306. package/dist/exports/atoms/std-display.orb +5 -4
  307. package/dist/exports/atoms/std-drawer.orb +5 -4
  308. package/dist/exports/atoms/std-filter.orb +5 -4
  309. package/dist/exports/atoms/std-flip-card.orb +5 -4
  310. package/dist/exports/atoms/std-gallery.orb +5 -4
  311. package/dist/exports/atoms/std-game-audio.orb +5 -4
  312. package/dist/exports/atoms/std-game-canvas2d.orb +4 -2
  313. package/dist/exports/atoms/std-game-canvas3d.orb +4 -2
  314. package/dist/exports/atoms/std-game-hud.orb +5 -4
  315. package/dist/exports/atoms/std-game-menu.orb +5 -4
  316. package/dist/exports/atoms/std-game-over-screen.orb +5 -4
  317. package/dist/exports/atoms/std-gameflow.orb +5 -4
  318. package/dist/exports/atoms/std-input.orb +5 -4
  319. package/dist/exports/atoms/std-inventory-panel.orb +5 -8
  320. package/dist/exports/atoms/std-isometric-canvas.orb +5 -4
  321. package/dist/exports/atoms/std-loading.orb +5 -4
  322. package/dist/exports/atoms/std-modal.orb +89 -4
  323. package/dist/exports/atoms/std-movement.orb +5 -4
  324. package/dist/exports/atoms/std-notification.orb +5 -4
  325. package/dist/exports/atoms/std-overworld.orb +5 -4
  326. package/dist/exports/atoms/std-pagination.orb +5 -4
  327. package/dist/exports/atoms/std-physics2d.orb +5 -4
  328. package/dist/exports/atoms/std-platformer-canvas.orb +5 -4
  329. package/dist/exports/atoms/std-quest.orb +5 -8
  330. package/dist/exports/atoms/std-rate-limiter.orb +5 -4
  331. package/dist/exports/atoms/std-rating.orb +5 -4
  332. package/dist/exports/atoms/std-score-board.orb +5 -4
  333. package/dist/exports/atoms/std-score.orb +5 -4
  334. package/dist/exports/atoms/std-search.orb +5 -4
  335. package/dist/exports/atoms/std-selection.orb +5 -4
  336. package/dist/exports/atoms/std-service-custom-bearer.orb +5 -15
  337. package/dist/exports/atoms/std-service-custom-header.orb +5 -17
  338. package/dist/exports/atoms/std-service-custom-noauth.orb +5 -11
  339. package/dist/exports/atoms/std-service-custom-query.orb +5 -17
  340. package/dist/exports/atoms/std-service-email.orb +5 -4
  341. package/dist/exports/atoms/std-service-github.orb +5 -4
  342. package/dist/exports/atoms/std-service-llm.orb +5 -4
  343. package/dist/exports/atoms/std-service-oauth.orb +5 -4
  344. package/dist/exports/atoms/std-service-redis.orb +5 -4
  345. package/dist/exports/atoms/std-service-storage.orb +5 -4
  346. package/dist/exports/atoms/std-service-stripe.orb +5 -4
  347. package/dist/exports/atoms/std-service-twilio.orb +5 -4
  348. package/dist/exports/atoms/std-service-youtube.orb +5 -4
  349. package/dist/exports/atoms/std-simulation-canvas.orb +5 -4
  350. package/dist/exports/atoms/std-sort.orb +5 -4
  351. package/dist/exports/atoms/std-sprite.orb +5 -4
  352. package/dist/exports/atoms/std-tabs.orb +5 -4
  353. package/dist/exports/atoms/std-text-effects.orb +5 -4
  354. package/dist/exports/atoms/std-theme.orb +5 -4
  355. package/dist/exports/atoms/std-timer.orb +5 -4
  356. package/dist/exports/atoms/std-undo.orb +5 -4
  357. package/dist/exports/atoms/std-upload.orb +5 -4
  358. package/dist/exports/atoms/std-validate-on-save.orb +5 -32
  359. package/dist/exports/atoms/std-wizard.orb +5 -4
  360. package/dist/exports/molecules/std-agent-fix-loop.orb +1141 -1709
  361. package/dist/exports/molecules/std-agent-learner.orb +608 -938
  362. package/dist/exports/molecules/std-agent-planner.orb +613 -961
  363. package/dist/exports/molecules/std-agent-rag.orb +586 -915
  364. package/dist/exports/molecules/std-agent-tool-loop.orb +915 -2846
  365. package/dist/exports/molecules/std-builder-game.orb +5 -4
  366. package/dist/exports/molecules/std-cart.orb +196 -307
  367. package/dist/exports/molecules/std-classifier-game.orb +5 -4
  368. package/dist/exports/molecules/std-debugger-game.orb +5 -4
  369. package/dist/exports/molecules/std-detail.orb +309 -467
  370. package/dist/exports/molecules/std-event-handler-game.orb +5 -4
  371. package/dist/exports/molecules/std-form-advanced.orb +5 -8
  372. package/dist/exports/molecules/std-geospatial.orb +363 -539
  373. package/dist/exports/molecules/std-inventory.orb +390 -720
  374. package/dist/exports/molecules/std-list.orb +526 -1156
  375. package/dist/exports/molecules/std-messaging.orb +295 -452
  376. package/dist/exports/molecules/std-negotiator-game.orb +5 -4
  377. package/dist/exports/molecules/std-platformer-game.orb +5 -4
  378. package/dist/exports/molecules/std-puzzle-game.orb +5 -4
  379. package/dist/exports/molecules/std-quiz.orb +5 -4
  380. package/dist/exports/molecules/std-sequencer-game.orb +5 -4
  381. package/dist/exports/molecules/std-service-content-pipeline.orb +5 -4
  382. package/dist/exports/molecules/std-service-custom-api-tester.orb +5 -42
  383. package/dist/exports/molecules/std-service-devops-toolkit.orb +5 -4
  384. package/dist/exports/molecules/std-service-notification-hub.orb +5 -4
  385. package/dist/exports/molecules/std-service-payment-flow.orb +5 -4
  386. package/dist/exports/molecules/std-simulator-game.orb +5 -4
  387. package/dist/exports/molecules/std-turn-based-battle.orb +5 -4
  388. package/dist/exports/organisms/std-agent-assistant.orb +15 -143
  389. package/dist/exports/organisms/std-agent-builder.orb +814 -1476
  390. package/dist/exports/organisms/std-agent-pipeline.orb +785 -1567
  391. package/dist/exports/organisms/std-agent-reviewer.orb +299 -502
  392. package/dist/exports/organisms/std-agent-tutor.orb +306 -493
  393. package/dist/exports/organisms/std-api-gateway.orb +284 -626
  394. package/dist/exports/organisms/std-arcade-game.orb +4 -4
  395. package/dist/exports/organisms/std-booking-system.orb +1422 -2160
  396. package/dist/exports/organisms/std-cicd-pipeline.orb +274 -617
  397. package/dist/exports/organisms/std-cms.orb +1274 -1972
  398. package/dist/exports/organisms/std-coding-academy.orb +4 -4
  399. package/dist/exports/organisms/std-crm.orb +999 -1775
  400. package/dist/exports/organisms/std-devops-dashboard.orb +284 -638
  401. package/dist/exports/organisms/std-ecommerce.orb +1653 -2398
  402. package/dist/exports/organisms/std-finance-tracker.orb +340 -684
  403. package/dist/exports/organisms/std-healthcare.orb +984 -1838
  404. package/dist/exports/organisms/std-helpdesk.orb +340 -744
  405. package/dist/exports/organisms/std-hr-portal.orb +1401 -2151
  406. package/dist/exports/organisms/std-iot-dashboard.orb +284 -626
  407. package/dist/exports/organisms/std-lms.orb +284 -632
  408. package/dist/exports/organisms/std-logic-training.orb +4 -4
  409. package/dist/exports/organisms/std-platformer-app.orb +15 -98
  410. package/dist/exports/organisms/std-project-manager.orb +970 -1774
  411. package/dist/exports/organisms/std-puzzle-app.orb +4 -4
  412. package/dist/exports/organisms/std-realtime-chat.orb +364 -714
  413. package/dist/exports/organisms/std-rpg-game.orb +15 -102
  414. package/dist/exports/organisms/std-service-marketplace.orb +1589 -2361
  415. package/dist/exports/organisms/std-service-research-assistant.orb +4 -15
  416. package/dist/exports/organisms/std-social-feed.orb +62 -66
  417. package/dist/exports/organisms/std-stem-lab.orb +4 -4
  418. package/dist/exports/organisms/std-strategy-game.orb +4 -4
  419. package/dist/exports/organisms/std-trading-dashboard.orb +274 -620
  420. package/dist/index.js.map +1 -1
  421. package/package.json +2 -2
@@ -1,6 +1,7 @@
1
1
  {
2
- "name": "CmsApp",
2
+ "name": "std-cms",
3
3
  "version": "1.0.0",
4
+ "description": "Content management organism. Composes molecules via compose: - stdList(Article): article management with CRUD - stdDetail(MediaAsset): media library browse + view - stdList(Category): category management",
4
5
  "orbitals": [
5
6
  {
6
7
  "name": "ArticleOrbital",
@@ -57,11 +58,15 @@
57
58
  "listens": [
58
59
  {
59
60
  "event": "ARTICLE_CREATED",
60
- "triggers": "ARTICLE_CREATED"
61
+ "triggers": "INIT"
61
62
  },
62
63
  {
63
64
  "event": "ARTICLE_UPDATED",
64
- "triggers": "ARTICLE_UPDATED"
65
+ "triggers": "INIT"
66
+ },
67
+ {
68
+ "event": "ARTICLE_DELETED",
69
+ "triggers": "INIT"
65
70
  }
66
71
  ],
67
72
  "stateMachine": {
@@ -69,9 +74,6 @@
69
74
  {
70
75
  "name": "browsing",
71
76
  "isInitial": true
72
- },
73
- {
74
- "name": "deleting"
75
77
  }
76
78
  ],
77
79
  "events": [
@@ -127,40 +129,6 @@
127
129
  "type": "object"
128
130
  }
129
131
  ]
130
- },
131
- {
132
- "key": "ARTICLE_CREATED",
133
- "name": "ARTICLE_CREATED",
134
- "payload": [
135
- {
136
- "name": "data",
137
- "type": "object",
138
- "required": true
139
- }
140
- ]
141
- },
142
- {
143
- "key": "ARTICLE_UPDATED",
144
- "name": "ARTICLE_UPDATED",
145
- "payload": [
146
- {
147
- "name": "data",
148
- "type": "object",
149
- "required": true
150
- }
151
- ]
152
- },
153
- {
154
- "key": "CONFIRM_DELETE",
155
- "name": "Confirm Delete"
156
- },
157
- {
158
- "key": "CANCEL",
159
- "name": "Cancel"
160
- },
161
- {
162
- "key": "CLOSE",
163
- "name": "Close"
164
132
  }
165
133
  ],
166
134
  "transitions": [
@@ -307,22 +275,86 @@
307
275
  }
308
276
  ]
309
277
  ]
278
+ }
279
+ ]
280
+ },
281
+ "emits": [
282
+ {
283
+ "event": "PUBLISH",
284
+ "payload": [
285
+ {
286
+ "name": "id",
287
+ "type": "string",
288
+ "required": true
289
+ }
290
+ ],
291
+ "scope": "external"
292
+ },
293
+ {
294
+ "event": "CATEGORIZE",
295
+ "payload": [
296
+ {
297
+ "name": "id",
298
+ "type": "string",
299
+ "required": true
300
+ }
301
+ ],
302
+ "scope": "external"
303
+ }
304
+ ]
305
+ },
306
+ {
307
+ "name": "ArticleCreate",
308
+ "linkedEntity": "Article",
309
+ "category": "interaction",
310
+ "emits": [
311
+ {
312
+ "event": "SAVE"
313
+ },
314
+ {
315
+ "event": "ARTICLE_CREATED"
316
+ }
317
+ ],
318
+ "stateMachine": {
319
+ "states": [
320
+ {
321
+ "name": "closed",
322
+ "isInitial": true
310
323
  },
311
324
  {
312
- "from": "browsing",
313
- "to": "browsing",
314
- "event": "ARTICLE_CREATED",
315
- "effects": [
316
- [
317
- "ref",
318
- "Article"
319
- ]
320
- ]
325
+ "name": "open"
326
+ }
327
+ ],
328
+ "events": [
329
+ {
330
+ "key": "INIT",
331
+ "name": "Initialize"
321
332
  },
322
333
  {
323
- "from": "browsing",
324
- "to": "browsing",
325
- "event": "ARTICLE_UPDATED",
334
+ "key": "CREATE",
335
+ "name": "Open"
336
+ },
337
+ {
338
+ "key": "CLOSE",
339
+ "name": "Close"
340
+ },
341
+ {
342
+ "key": "SAVE",
343
+ "name": "Save",
344
+ "payload": [
345
+ {
346
+ "name": "data",
347
+ "type": "object",
348
+ "required": true
349
+ }
350
+ ]
351
+ }
352
+ ],
353
+ "transitions": [
354
+ {
355
+ "from": "closed",
356
+ "to": "closed",
357
+ "event": "INIT",
326
358
  "effects": [
327
359
  [
328
360
  "ref",
@@ -331,16 +363,13 @@
331
363
  ]
332
364
  },
333
365
  {
334
- "from": "browsing",
335
- "to": "deleting",
336
- "event": "DELETE",
366
+ "from": "closed",
367
+ "to": "open",
368
+ "event": "CREATE",
337
369
  "effects": [
338
370
  [
339
371
  "fetch",
340
- "Article",
341
- {
342
- "id": "@payload.id"
343
- }
372
+ "Article"
344
373
  ],
345
374
  [
346
375
  "render-ui",
@@ -357,12 +386,12 @@
357
386
  "children": [
358
387
  {
359
388
  "type": "icon",
360
- "name": "trash-2",
389
+ "name": "plus-circle",
361
390
  "size": "md"
362
391
  },
363
392
  {
364
393
  "type": "typography",
365
- "content": "Delete Article",
394
+ "content": "Create Article",
366
395
  "variant": "h3"
367
396
  }
368
397
  ]
@@ -371,34 +400,18 @@
371
400
  "type": "divider"
372
401
  },
373
402
  {
374
- "type": "typography",
375
- "content": "@entity.title",
376
- "variant": "h4"
377
- },
378
- {
379
- "type": "typography",
380
- "content": "This action cannot be undone.",
381
- "variant": "body"
382
- },
383
- {
384
- "type": "stack",
385
- "direction": "horizontal",
386
- "gap": "sm",
387
- "justify": "end",
388
- "children": [
389
- {
390
- "type": "button",
391
- "label": "Cancel",
392
- "event": "CANCEL",
393
- "variant": "ghost"
394
- },
395
- {
396
- "type": "button",
397
- "label": "Delete",
398
- "event": "CONFIRM_DELETE",
399
- "variant": "danger",
400
- "icon": "trash"
401
- }
403
+ "type": "form-section",
404
+ "entity": "Article",
405
+ "mode": "create",
406
+ "submitEvent": "SAVE",
407
+ "cancelEvent": "CLOSE",
408
+ "fields": [
409
+ "title",
410
+ "slug",
411
+ "content",
412
+ "author",
413
+ "status",
414
+ "publishedAt"
402
415
  ]
403
416
  }
404
417
  ]
@@ -407,15 +420,32 @@
407
420
  ]
408
421
  },
409
422
  {
410
- "from": "deleting",
411
- "to": "browsing",
412
- "event": "CONFIRM_DELETE",
423
+ "from": "open",
424
+ "to": "closed",
425
+ "event": "CLOSE",
426
+ "effects": [
427
+ [
428
+ "render-ui",
429
+ "modal",
430
+ null
431
+ ],
432
+ [
433
+ "notify",
434
+ "Cancelled",
435
+ "info"
436
+ ]
437
+ ]
438
+ },
439
+ {
440
+ "from": "open",
441
+ "to": "closed",
442
+ "event": "SAVE",
413
443
  "effects": [
414
444
  [
415
445
  "persist",
416
- "delete",
446
+ "create",
417
447
  "Article",
418
- "@entity.id"
448
+ "@payload.data"
419
449
  ],
420
450
  [
421
451
  "render-ui",
@@ -423,148 +453,145 @@
423
453
  null
424
454
  ],
425
455
  [
426
- "render-ui",
427
- "main",
428
- {
429
- "type": "dashboard-layout",
430
- "appName": "CmsApp",
431
- "navItems": [
432
- {
433
- "label": "Articles",
434
- "href": "/articles",
435
- "icon": "file-text"
436
- },
437
- {
438
- "label": "Media",
439
- "href": "/media",
440
- "icon": "image"
441
- },
442
- {
443
- "label": "Categories",
444
- "href": "/categories",
445
- "icon": "folder"
446
- }
447
- ],
448
- "children": [
449
- {
450
- "type": "stack",
451
- "direction": "vertical",
452
- "gap": "lg",
453
- "className": "max-w-5xl mx-auto w-full",
454
- "children": [
455
- {
456
- "type": "stack",
457
- "direction": "horizontal",
458
- "gap": "md",
459
- "justify": "space-between",
460
- "align": "center",
461
- "children": [
462
- {
463
- "type": "stack",
464
- "direction": "horizontal",
465
- "gap": "sm",
466
- "align": "center",
467
- "children": [
468
- {
469
- "type": "icon",
470
- "name": "file-text",
471
- "size": "lg"
472
- },
473
- {
474
- "type": "typography",
475
- "content": "Articles",
476
- "variant": "h2"
477
- }
478
- ]
479
- },
480
- {
481
- "type": "stack",
482
- "direction": "horizontal",
483
- "gap": "sm",
484
- "children": [
485
- {
486
- "type": "button",
487
- "label": "Create Article",
488
- "event": "CREATE",
489
- "variant": "primary",
490
- "icon": "plus"
491
- }
492
- ]
493
- }
494
- ]
495
- },
456
+ "emit",
457
+ "ARTICLE_CREATED"
458
+ ]
459
+ ]
460
+ }
461
+ ]
462
+ }
463
+ },
464
+ {
465
+ "name": "ArticleEdit",
466
+ "linkedEntity": "Article",
467
+ "category": "interaction",
468
+ "emits": [
469
+ {
470
+ "event": "SAVE"
471
+ },
472
+ {
473
+ "event": "ARTICLE_UPDATED"
474
+ }
475
+ ],
476
+ "stateMachine": {
477
+ "states": [
478
+ {
479
+ "name": "closed",
480
+ "isInitial": true
481
+ },
482
+ {
483
+ "name": "open"
484
+ }
485
+ ],
486
+ "events": [
487
+ {
488
+ "key": "INIT",
489
+ "name": "Initialize"
490
+ },
491
+ {
492
+ "key": "EDIT",
493
+ "name": "Open",
494
+ "payload": [
495
+ {
496
+ "name": "id",
497
+ "type": "string",
498
+ "required": true
499
+ }
500
+ ]
501
+ },
502
+ {
503
+ "key": "CLOSE",
504
+ "name": "Close"
505
+ },
506
+ {
507
+ "key": "SAVE",
508
+ "name": "Save",
509
+ "payload": [
510
+ {
511
+ "name": "data",
512
+ "type": "object",
513
+ "required": true
514
+ }
515
+ ]
516
+ }
517
+ ],
518
+ "transitions": [
519
+ {
520
+ "from": "closed",
521
+ "to": "closed",
522
+ "event": "INIT",
523
+ "effects": [
524
+ [
525
+ "ref",
526
+ "Article"
527
+ ]
528
+ ]
529
+ },
530
+ {
531
+ "from": "closed",
532
+ "to": "open",
533
+ "event": "EDIT",
534
+ "effects": [
535
+ [
536
+ "fetch",
537
+ "Article",
538
+ {
539
+ "id": "@payload.id"
540
+ }
541
+ ],
542
+ [
543
+ "render-ui",
544
+ "modal",
545
+ {
546
+ "type": "stack",
547
+ "direction": "vertical",
548
+ "gap": "md",
549
+ "children": [
550
+ {
551
+ "type": "stack",
552
+ "direction": "horizontal",
553
+ "gap": "sm",
554
+ "children": [
496
555
  {
497
- "type": "divider"
556
+ "type": "icon",
557
+ "name": "edit",
558
+ "size": "md"
498
559
  },
499
560
  {
500
- "type": "data-list",
501
- "entity": "Article",
502
- "emptyIcon": "inbox",
503
- "emptyTitle": "No articles yet",
504
- "emptyDescription": "Write your first article.",
505
- "itemActions": [
506
- {
507
- "label": "View",
508
- "event": "VIEW",
509
- "variant": "ghost",
510
- "size": "sm"
511
- },
512
- {
513
- "label": "Edit",
514
- "event": "EDIT",
515
- "variant": "ghost",
516
- "size": "sm"
517
- },
518
- {
519
- "label": "Delete",
520
- "event": "DELETE",
521
- "variant": "danger",
522
- "size": "sm"
523
- }
524
- ],
525
- "columns": [
526
- {
527
- "name": "title",
528
- "variant": "h3",
529
- "icon": "file-text"
530
- },
531
- {
532
- "name": "status",
533
- "variant": "badge"
534
- },
535
- {
536
- "name": "author",
537
- "variant": "body"
538
- },
539
- {
540
- "name": "slug",
541
- "variant": "caption"
542
- },
543
- {
544
- "name": "publishedAt",
545
- "label": "Published",
546
- "variant": "caption",
547
- "format": "date"
548
- }
549
- ],
550
- "variant": "card",
551
- "gap": "sm"
561
+ "type": "typography",
562
+ "content": "Edit Article",
563
+ "variant": "h3"
552
564
  }
553
565
  ]
566
+ },
567
+ {
568
+ "type": "divider"
569
+ },
570
+ {
571
+ "type": "form-section",
572
+ "entity": "Article",
573
+ "mode": "edit",
574
+ "submitEvent": "SAVE",
575
+ "cancelEvent": "CLOSE",
576
+ "fields": [
577
+ "title",
578
+ "slug",
579
+ "content",
580
+ "author",
581
+ "status",
582
+ "publishedAt"
583
+ ],
584
+ "entityId": "@entity.id"
554
585
  }
555
586
  ]
556
587
  }
557
- ],
558
- [
559
- "notify",
560
- "Article deleted successfully"
561
588
  ]
562
589
  ]
563
590
  },
564
591
  {
565
- "from": "deleting",
566
- "to": "browsing",
567
- "event": "CANCEL",
592
+ "from": "open",
593
+ "to": "closed",
594
+ "event": "CLOSE",
568
595
  "effects": [
569
596
  [
570
597
  "render-ui",
@@ -572,285 +599,264 @@
572
599
  null
573
600
  ],
574
601
  [
575
- "fetch",
576
- "Article"
602
+ "notify",
603
+ "Cancelled",
604
+ "info"
605
+ ]
606
+ ]
607
+ },
608
+ {
609
+ "from": "open",
610
+ "to": "closed",
611
+ "event": "SAVE",
612
+ "effects": [
613
+ [
614
+ "persist",
615
+ "update",
616
+ "Article",
617
+ "@payload.data"
577
618
  ],
578
619
  [
579
620
  "render-ui",
580
- "main",
581
- {
582
- "type": "dashboard-layout",
583
- "appName": "CmsApp",
584
- "navItems": [
585
- {
586
- "label": "Articles",
587
- "href": "/articles",
588
- "icon": "file-text"
589
- },
590
- {
591
- "label": "Media",
592
- "href": "/media",
593
- "icon": "image"
594
- },
595
- {
596
- "label": "Categories",
597
- "href": "/categories",
598
- "icon": "folder"
599
- }
600
- ],
601
- "children": [
602
- {
603
- "type": "stack",
604
- "direction": "vertical",
605
- "gap": "lg",
606
- "className": "max-w-5xl mx-auto w-full",
607
- "children": [
608
- {
609
- "type": "stack",
610
- "direction": "horizontal",
611
- "gap": "md",
612
- "justify": "space-between",
613
- "align": "center",
614
- "children": [
615
- {
616
- "type": "stack",
617
- "direction": "horizontal",
618
- "gap": "sm",
619
- "align": "center",
620
- "children": [
621
- {
622
- "type": "icon",
623
- "name": "file-text",
624
- "size": "lg"
625
- },
626
- {
627
- "type": "typography",
628
- "content": "Articles",
629
- "variant": "h2"
630
- }
631
- ]
632
- },
633
- {
634
- "type": "stack",
635
- "direction": "horizontal",
636
- "gap": "sm",
637
- "children": [
638
- {
639
- "type": "button",
640
- "label": "Create Article",
641
- "event": "CREATE",
642
- "variant": "primary",
643
- "icon": "plus"
644
- }
645
- ]
646
- }
647
- ]
648
- },
649
- {
650
- "type": "divider"
651
- },
652
- {
653
- "type": "data-list",
654
- "entity": "Article",
655
- "emptyIcon": "inbox",
656
- "emptyTitle": "No articles yet",
657
- "emptyDescription": "Write your first article.",
658
- "itemActions": [
659
- {
660
- "label": "View",
661
- "event": "VIEW",
662
- "variant": "ghost",
663
- "size": "sm"
664
- },
665
- {
666
- "label": "Edit",
667
- "event": "EDIT",
668
- "variant": "ghost",
669
- "size": "sm"
670
- },
671
- {
672
- "label": "Delete",
673
- "event": "DELETE",
674
- "variant": "danger",
675
- "size": "sm"
676
- }
677
- ],
678
- "columns": [
679
- {
680
- "name": "title",
681
- "variant": "h3",
682
- "icon": "file-text"
683
- },
684
- {
685
- "name": "status",
686
- "variant": "badge"
687
- },
688
- {
689
- "name": "author",
690
- "variant": "body"
691
- },
692
- {
693
- "name": "slug",
694
- "variant": "caption"
695
- },
696
- {
697
- "name": "publishedAt",
698
- "label": "Published",
699
- "variant": "caption",
700
- "format": "date"
701
- }
702
- ],
703
- "variant": "card",
704
- "gap": "sm"
705
- }
706
- ]
707
- }
708
- ]
709
- }
621
+ "modal",
622
+ null
623
+ ],
624
+ [
625
+ "emit",
626
+ "ARTICLE_UPDATED"
710
627
  ]
711
628
  ]
629
+ }
630
+ ]
631
+ }
632
+ },
633
+ {
634
+ "name": "ArticleView",
635
+ "linkedEntity": "Article",
636
+ "category": "interaction",
637
+ "emits": [
638
+ {
639
+ "event": "SAVE"
640
+ }
641
+ ],
642
+ "stateMachine": {
643
+ "states": [
644
+ {
645
+ "name": "closed",
646
+ "isInitial": true
647
+ },
648
+ {
649
+ "name": "open"
650
+ }
651
+ ],
652
+ "events": [
653
+ {
654
+ "key": "INIT",
655
+ "name": "Initialize"
656
+ },
657
+ {
658
+ "key": "VIEW",
659
+ "name": "Open",
660
+ "payload": [
661
+ {
662
+ "name": "id",
663
+ "type": "string",
664
+ "required": true
665
+ }
666
+ ]
712
667
  },
713
668
  {
714
- "from": "deleting",
715
- "to": "browsing",
716
- "event": "CLOSE",
669
+ "key": "CLOSE",
670
+ "name": "Close"
671
+ },
672
+ {
673
+ "key": "SAVE",
674
+ "name": "Save",
675
+ "payload": [
676
+ {
677
+ "name": "data",
678
+ "type": "object",
679
+ "required": true
680
+ }
681
+ ]
682
+ }
683
+ ],
684
+ "transitions": [
685
+ {
686
+ "from": "closed",
687
+ "to": "closed",
688
+ "event": "INIT",
717
689
  "effects": [
718
690
  [
719
- "render-ui",
720
- "modal",
721
- null
722
- ],
691
+ "ref",
692
+ "Article"
693
+ ]
694
+ ]
695
+ },
696
+ {
697
+ "from": "closed",
698
+ "to": "open",
699
+ "event": "VIEW",
700
+ "effects": [
723
701
  [
724
702
  "fetch",
725
- "Article"
703
+ "Article",
704
+ {
705
+ "id": "@payload.id"
706
+ }
726
707
  ],
727
708
  [
728
709
  "render-ui",
729
- "main",
710
+ "modal",
730
711
  {
731
- "type": "dashboard-layout",
732
- "appName": "CmsApp",
733
- "navItems": [
712
+ "type": "stack",
713
+ "direction": "vertical",
714
+ "gap": "md",
715
+ "children": [
734
716
  {
735
- "label": "Articles",
736
- "href": "/articles",
737
- "icon": "file-text"
717
+ "type": "stack",
718
+ "direction": "horizontal",
719
+ "gap": "sm",
720
+ "align": "center",
721
+ "children": [
722
+ {
723
+ "type": "icon",
724
+ "name": "eye",
725
+ "size": "md"
726
+ },
727
+ {
728
+ "type": "typography",
729
+ "variant": "h3",
730
+ "content": "@entity.title"
731
+ }
732
+ ]
738
733
  },
739
734
  {
740
- "label": "Media",
741
- "href": "/media",
742
- "icon": "image"
735
+ "type": "divider"
743
736
  },
744
- {
745
- "label": "Categories",
746
- "href": "/categories",
747
- "icon": "folder"
748
- }
749
- ],
750
- "children": [
751
737
  {
752
738
  "type": "stack",
753
- "direction": "vertical",
754
- "gap": "lg",
755
- "className": "max-w-5xl mx-auto w-full",
739
+ "direction": "horizontal",
740
+ "gap": "md",
756
741
  "children": [
757
742
  {
758
- "type": "stack",
759
- "direction": "horizontal",
760
- "gap": "md",
761
- "justify": "space-between",
762
- "align": "center",
763
- "children": [
764
- {
765
- "type": "stack",
766
- "direction": "horizontal",
767
- "gap": "sm",
768
- "align": "center",
769
- "children": [
770
- {
771
- "type": "icon",
772
- "name": "file-text",
773
- "size": "lg"
774
- },
775
- {
776
- "type": "typography",
777
- "content": "Articles",
778
- "variant": "h2"
779
- }
780
- ]
781
- },
782
- {
783
- "type": "stack",
784
- "direction": "horizontal",
785
- "gap": "sm",
786
- "children": [
787
- {
788
- "type": "button",
789
- "label": "Create Article",
790
- "event": "CREATE",
791
- "variant": "primary",
792
- "icon": "plus"
793
- }
794
- ]
795
- }
796
- ]
797
- },
798
- {
799
- "type": "divider"
743
+ "type": "typography",
744
+ "variant": "caption",
745
+ "content": "Title"
800
746
  },
801
747
  {
802
- "type": "data-list",
803
- "entity": "Article",
804
- "emptyIcon": "inbox",
805
- "emptyTitle": "No articles yet",
806
- "emptyDescription": "Write your first article.",
807
- "itemActions": [
808
- {
809
- "label": "View",
810
- "event": "VIEW",
811
- "variant": "ghost",
812
- "size": "sm"
813
- },
814
- {
815
- "label": "Edit",
816
- "event": "EDIT",
817
- "variant": "ghost",
818
- "size": "sm"
819
- },
820
- {
821
- "label": "Delete",
822
- "event": "DELETE",
823
- "variant": "danger",
824
- "size": "sm"
825
- }
826
- ],
827
- "columns": [
828
- {
829
- "name": "title",
830
- "variant": "h3",
831
- "icon": "file-text"
832
- },
833
- {
834
- "name": "status",
835
- "variant": "badge"
836
- },
837
- {
838
- "name": "author",
839
- "variant": "body"
840
- },
841
- {
842
- "name": "slug",
843
- "variant": "caption"
844
- },
845
- {
846
- "name": "publishedAt",
847
- "label": "Published",
848
- "variant": "caption",
849
- "format": "date"
850
- }
851
- ],
852
- "variant": "card",
853
- "gap": "sm"
748
+ "type": "typography",
749
+ "variant": "body",
750
+ "content": "@entity.title"
751
+ }
752
+ ]
753
+ },
754
+ {
755
+ "type": "stack",
756
+ "direction": "horizontal",
757
+ "gap": "md",
758
+ "children": [
759
+ {
760
+ "type": "typography",
761
+ "variant": "caption",
762
+ "content": "Slug"
763
+ },
764
+ {
765
+ "type": "typography",
766
+ "variant": "body",
767
+ "content": "@entity.slug"
768
+ }
769
+ ]
770
+ },
771
+ {
772
+ "type": "stack",
773
+ "direction": "horizontal",
774
+ "gap": "md",
775
+ "children": [
776
+ {
777
+ "type": "typography",
778
+ "variant": "caption",
779
+ "content": "Content"
780
+ },
781
+ {
782
+ "type": "typography",
783
+ "variant": "body",
784
+ "content": "@entity.content"
785
+ }
786
+ ]
787
+ },
788
+ {
789
+ "type": "stack",
790
+ "direction": "horizontal",
791
+ "gap": "md",
792
+ "children": [
793
+ {
794
+ "type": "typography",
795
+ "variant": "caption",
796
+ "content": "Author"
797
+ },
798
+ {
799
+ "type": "typography",
800
+ "variant": "body",
801
+ "content": "@entity.author"
802
+ }
803
+ ]
804
+ },
805
+ {
806
+ "type": "stack",
807
+ "direction": "horizontal",
808
+ "gap": "md",
809
+ "children": [
810
+ {
811
+ "type": "typography",
812
+ "variant": "caption",
813
+ "content": "Status"
814
+ },
815
+ {
816
+ "type": "typography",
817
+ "variant": "body",
818
+ "content": "@entity.status"
819
+ }
820
+ ]
821
+ },
822
+ {
823
+ "type": "stack",
824
+ "direction": "horizontal",
825
+ "gap": "md",
826
+ "children": [
827
+ {
828
+ "type": "typography",
829
+ "variant": "caption",
830
+ "content": "Published At"
831
+ },
832
+ {
833
+ "type": "typography",
834
+ "variant": "body",
835
+ "content": "@entity.publishedAt"
836
+ }
837
+ ]
838
+ },
839
+ {
840
+ "type": "divider"
841
+ },
842
+ {
843
+ "type": "stack",
844
+ "direction": "horizontal",
845
+ "gap": "sm",
846
+ "justify": "end",
847
+ "children": [
848
+ {
849
+ "type": "button",
850
+ "label": "Edit",
851
+ "event": "EDIT",
852
+ "variant": "primary",
853
+ "icon": "edit"
854
+ },
855
+ {
856
+ "type": "button",
857
+ "label": "Close",
858
+ "event": "CLOSE",
859
+ "variant": "ghost"
854
860
  }
855
861
  ]
856
862
  }
@@ -858,51 +864,59 @@
858
864
  }
859
865
  ]
860
866
  ]
867
+ },
868
+ {
869
+ "from": "open",
870
+ "to": "closed",
871
+ "event": "CLOSE",
872
+ "effects": [
873
+ [
874
+ "render-ui",
875
+ "modal",
876
+ null
877
+ ],
878
+ [
879
+ "notify",
880
+ "Cancelled",
881
+ "info"
882
+ ]
883
+ ]
884
+ },
885
+ {
886
+ "from": "open",
887
+ "to": "closed",
888
+ "event": "SAVE",
889
+ "effects": [
890
+ [
891
+ "render-ui",
892
+ "modal",
893
+ null
894
+ ]
895
+ ]
861
896
  }
862
897
  ]
863
- },
864
- "emits": [
865
- {
866
- "event": "PUBLISH",
867
- "payload": [
868
- {
869
- "name": "id",
870
- "type": "string",
871
- "required": true
872
- }
873
- ],
874
- "scope": "external"
875
- },
876
- {
877
- "event": "CATEGORIZE",
878
- "payload": [
879
- {
880
- "name": "id",
881
- "type": "string",
882
- "required": true
883
- }
884
- ],
885
- "scope": "external"
886
- }
887
- ]
898
+ }
888
899
  },
889
900
  {
890
- "name": "ArticleCreate",
901
+ "name": "ArticleDelete",
891
902
  "linkedEntity": "Article",
892
903
  "category": "interaction",
893
904
  "emits": [
894
905
  {
895
- "event": "ARTICLE_CREATED"
906
+ "event": "CONFIRM_DELETE"
907
+ },
908
+ {
909
+ "event": "ARTICLE_DELETED"
896
910
  }
897
911
  ],
898
912
  "stateMachine": {
899
913
  "states": [
900
914
  {
901
- "name": "closed",
915
+ "name": "idle",
902
916
  "isInitial": true
903
917
  },
904
918
  {
905
- "name": "open"
919
+ "name": "confirming"
906
920
  }
907
921
  ],
908
922
  "events": [
@@ -911,29 +925,33 @@
911
925
  "name": "Initialize"
912
926
  },
913
927
  {
914
- "key": "CREATE",
915
- "name": "Open"
916
- },
917
- {
918
- "key": "CLOSE",
919
- "name": "Close"
920
- },
921
- {
922
- "key": "SAVE",
923
- "name": "Save",
928
+ "key": "DELETE",
929
+ "name": "Request Confirmation",
924
930
  "payload": [
925
931
  {
926
- "name": "data",
927
- "type": "object",
932
+ "name": "id",
933
+ "type": "string",
928
934
  "required": true
929
935
  }
930
936
  ]
937
+ },
938
+ {
939
+ "key": "CONFIRM_DELETE",
940
+ "name": "Confirm"
941
+ },
942
+ {
943
+ "key": "CANCEL",
944
+ "name": "Cancel"
945
+ },
946
+ {
947
+ "key": "CLOSE",
948
+ "name": "Close"
931
949
  }
932
950
  ],
933
951
  "transitions": [
934
952
  {
935
- "from": "closed",
936
- "to": "closed",
953
+ "from": "idle",
954
+ "to": "idle",
937
955
  "event": "INIT",
938
956
  "effects": [
939
957
  [
@@ -943,13 +961,21 @@
943
961
  ]
944
962
  },
945
963
  {
946
- "from": "closed",
947
- "to": "open",
948
- "event": "CREATE",
964
+ "from": "idle",
965
+ "to": "confirming",
966
+ "event": "DELETE",
949
967
  "effects": [
968
+ [
969
+ "set",
970
+ "@entity.pendingId",
971
+ "@payload.id"
972
+ ],
950
973
  [
951
974
  "fetch",
952
- "Article"
975
+ "Article",
976
+ {
977
+ "id": "@payload.id"
978
+ }
953
979
  ],
954
980
  [
955
981
  "render-ui",
@@ -963,15 +989,16 @@
963
989
  "type": "stack",
964
990
  "direction": "horizontal",
965
991
  "gap": "sm",
992
+ "align": "center",
966
993
  "children": [
967
994
  {
968
995
  "type": "icon",
969
- "name": "plus-circle",
996
+ "name": "alert-triangle",
970
997
  "size": "md"
971
998
  },
972
999
  {
973
1000
  "type": "typography",
974
- "content": "Create Article",
1001
+ "content": "Delete Article",
975
1002
  "variant": "h3"
976
1003
  }
977
1004
  ]
@@ -980,18 +1007,29 @@
980
1007
  "type": "divider"
981
1008
  },
982
1009
  {
983
- "type": "form-section",
984
- "entity": "Article",
985
- "mode": "create",
986
- "submitEvent": "SAVE",
987
- "cancelEvent": "CLOSE",
988
- "fields": [
989
- "title",
990
- "slug",
991
- "content",
992
- "author",
993
- "status",
994
- "publishedAt"
1010
+ "type": "alert",
1011
+ "variant": "danger",
1012
+ "message": "This action cannot be undone."
1013
+ },
1014
+ {
1015
+ "type": "stack",
1016
+ "direction": "horizontal",
1017
+ "gap": "sm",
1018
+ "justify": "end",
1019
+ "children": [
1020
+ {
1021
+ "type": "button",
1022
+ "label": "Cancel",
1023
+ "event": "CANCEL",
1024
+ "variant": "ghost"
1025
+ },
1026
+ {
1027
+ "type": "button",
1028
+ "label": "Delete",
1029
+ "event": "CONFIRM_DELETE",
1030
+ "variant": "danger",
1031
+ "icon": "check"
1032
+ }
995
1033
  ]
996
1034
  }
997
1035
  ]
@@ -1000,68 +1038,153 @@
1000
1038
  ]
1001
1039
  },
1002
1040
  {
1003
- "from": "open",
1004
- "to": "closed",
1005
- "event": "CLOSE",
1041
+ "from": "confirming",
1042
+ "to": "idle",
1043
+ "event": "CONFIRM_DELETE",
1006
1044
  "effects": [
1045
+ [
1046
+ "persist",
1047
+ "delete",
1048
+ "Article",
1049
+ "@entity.pendingId"
1050
+ ],
1007
1051
  [
1008
1052
  "render-ui",
1009
1053
  "modal",
1010
1054
  null
1011
1055
  ],
1012
1056
  [
1013
- "notify",
1014
- "Cancelled",
1015
- "info"
1057
+ "ref",
1058
+ "Article"
1059
+ ],
1060
+ [
1061
+ "emit",
1062
+ "ARTICLE_DELETED"
1016
1063
  ]
1017
1064
  ]
1018
1065
  },
1019
1066
  {
1020
- "from": "open",
1021
- "to": "closed",
1022
- "event": "SAVE",
1067
+ "from": "confirming",
1068
+ "to": "idle",
1069
+ "event": "CANCEL",
1023
1070
  "effects": [
1024
- [
1025
- "persist",
1026
- "create",
1027
- "Article",
1028
- "@payload.data"
1029
- ],
1030
1071
  [
1031
1072
  "render-ui",
1032
1073
  "modal",
1033
1074
  null
1034
1075
  ],
1035
1076
  [
1036
- "emit",
1037
- "ARTICLE_CREATED"
1077
+ "ref",
1078
+ "Article"
1079
+ ]
1080
+ ]
1081
+ },
1082
+ {
1083
+ "from": "confirming",
1084
+ "to": "idle",
1085
+ "event": "CLOSE",
1086
+ "effects": [
1087
+ [
1088
+ "render-ui",
1089
+ "modal",
1090
+ null
1038
1091
  ],
1039
1092
  [
1040
- "notify",
1041
- "Article created successfully"
1093
+ "ref",
1094
+ "Article"
1042
1095
  ]
1043
1096
  ]
1044
1097
  }
1045
1098
  ]
1046
1099
  }
1047
- },
1100
+ }
1101
+ ],
1102
+ "pages": [
1048
1103
  {
1049
- "name": "ArticleEdit",
1050
- "linkedEntity": "Article",
1104
+ "name": "ArticlesPage",
1105
+ "path": "/articles",
1106
+ "isInitial": true,
1107
+ "traits": [
1108
+ {
1109
+ "ref": "ArticleBrowse"
1110
+ },
1111
+ {
1112
+ "ref": "ArticleCreate"
1113
+ },
1114
+ {
1115
+ "ref": "ArticleEdit"
1116
+ },
1117
+ {
1118
+ "ref": "ArticleView"
1119
+ },
1120
+ {
1121
+ "ref": "ArticleDelete"
1122
+ }
1123
+ ]
1124
+ }
1125
+ ]
1126
+ },
1127
+ {
1128
+ "name": "MediaAssetOrbital",
1129
+ "entity": {
1130
+ "name": "MediaAsset",
1131
+ "persistence": "persistent",
1132
+ "collection": "mediaassets",
1133
+ "fields": [
1134
+ {
1135
+ "name": "id",
1136
+ "type": "string",
1137
+ "required": true
1138
+ },
1139
+ {
1140
+ "name": "fileName",
1141
+ "type": "string",
1142
+ "required": true
1143
+ },
1144
+ {
1145
+ "name": "fileType",
1146
+ "type": "string",
1147
+ "required": true
1148
+ },
1149
+ {
1150
+ "name": "fileSize",
1151
+ "type": "number"
1152
+ },
1153
+ {
1154
+ "name": "url",
1155
+ "type": "string"
1156
+ },
1157
+ {
1158
+ "name": "altText",
1159
+ "type": "string"
1160
+ },
1161
+ {
1162
+ "name": "uploadedAt",
1163
+ "type": "date"
1164
+ }
1165
+ ]
1166
+ },
1167
+ "traits": [
1168
+ {
1169
+ "name": "MediaAssetBrowse",
1170
+ "linkedEntity": "MediaAsset",
1051
1171
  "category": "interaction",
1052
- "emits": [
1172
+ "listens": [
1053
1173
  {
1054
- "event": "ARTICLE_UPDATED"
1174
+ "event": "SAVE",
1175
+ "triggers": "INIT"
1176
+ },
1177
+ {
1178
+ "event": "PUBLISH",
1179
+ "triggers": "INIT",
1180
+ "scope": "external"
1055
1181
  }
1056
1182
  ],
1057
1183
  "stateMachine": {
1058
1184
  "states": [
1059
1185
  {
1060
- "name": "closed",
1186
+ "name": "browsing",
1061
1187
  "isInitial": true
1062
- },
1063
- {
1064
- "name": "open"
1065
1188
  }
1066
1189
  ],
1067
1190
  "events": [
@@ -1070,99 +1193,267 @@
1070
1193
  "name": "Initialize"
1071
1194
  },
1072
1195
  {
1073
- "key": "EDIT",
1074
- "name": "Open",
1196
+ "key": "CREATE",
1197
+ "name": "CREATE"
1198
+ },
1199
+ {
1200
+ "key": "VIEW",
1201
+ "name": "VIEW",
1075
1202
  "payload": [
1076
1203
  {
1077
1204
  "name": "id",
1078
1205
  "type": "string",
1079
1206
  "required": true
1080
- }
1081
- ]
1082
- },
1083
- {
1084
- "key": "CLOSE",
1085
- "name": "Close"
1086
- },
1087
- {
1088
- "key": "SAVE",
1089
- "name": "Save",
1090
- "payload": [
1207
+ },
1091
1208
  {
1092
- "name": "data",
1093
- "type": "object",
1094
- "required": true
1209
+ "name": "row",
1210
+ "type": "object"
1095
1211
  }
1096
1212
  ]
1097
1213
  }
1098
1214
  ],
1099
1215
  "transitions": [
1100
1216
  {
1101
- "from": "closed",
1102
- "to": "closed",
1217
+ "from": "browsing",
1218
+ "to": "browsing",
1103
1219
  "event": "INIT",
1104
1220
  "effects": [
1105
1221
  [
1106
1222
  "ref",
1107
- "Article"
1108
- ]
1109
- ]
1110
- },
1111
- {
1112
- "from": "closed",
1113
- "to": "open",
1114
- "event": "EDIT",
1115
- "effects": [
1116
- [
1117
- "fetch",
1118
- "Article",
1119
- {
1120
- "id": "@payload.id"
1121
- }
1223
+ "MediaAsset"
1122
1224
  ],
1123
1225
  [
1124
1226
  "render-ui",
1125
- "modal",
1227
+ "main",
1126
1228
  {
1127
- "type": "stack",
1128
- "direction": "vertical",
1129
- "gap": "md",
1130
- "children": [
1229
+ "type": "dashboard-layout",
1230
+ "appName": "CmsApp",
1231
+ "navItems": [
1131
1232
  {
1132
- "type": "stack",
1133
- "direction": "horizontal",
1134
- "gap": "sm",
1135
- "children": [
1136
- {
1137
- "type": "icon",
1138
- "name": "edit",
1139
- "size": "md"
1140
- },
1141
- {
1142
- "type": "typography",
1143
- "content": "Edit Article",
1144
- "variant": "h3"
1145
- }
1146
- ]
1233
+ "label": "Articles",
1234
+ "href": "/articles",
1235
+ "icon": "file-text"
1147
1236
  },
1148
1237
  {
1149
- "type": "divider"
1238
+ "label": "Media",
1239
+ "href": "/media",
1240
+ "icon": "image"
1150
1241
  },
1151
1242
  {
1152
- "type": "form-section",
1153
- "entity": "Article",
1154
- "mode": "edit",
1155
- "submitEvent": "SAVE",
1156
- "cancelEvent": "CLOSE",
1157
- "fields": [
1158
- "title",
1159
- "slug",
1160
- "content",
1161
- "author",
1162
- "status",
1163
- "publishedAt"
1164
- ],
1165
- "entityId": "@entity.id"
1243
+ "label": "Categories",
1244
+ "href": "/categories",
1245
+ "icon": "folder"
1246
+ }
1247
+ ],
1248
+ "children": [
1249
+ {
1250
+ "type": "stack",
1251
+ "direction": "vertical",
1252
+ "gap": "lg",
1253
+ "className": "max-w-5xl mx-auto w-full",
1254
+ "children": [
1255
+ {
1256
+ "type": "stack",
1257
+ "direction": "horizontal",
1258
+ "gap": "md",
1259
+ "justify": "space-between",
1260
+ "align": "center",
1261
+ "children": [
1262
+ {
1263
+ "type": "stack",
1264
+ "direction": "horizontal",
1265
+ "gap": "sm",
1266
+ "align": "center",
1267
+ "children": [
1268
+ {
1269
+ "type": "icon",
1270
+ "name": "image",
1271
+ "size": "lg"
1272
+ },
1273
+ {
1274
+ "type": "typography",
1275
+ "content": "Media Library",
1276
+ "variant": "h2"
1277
+ }
1278
+ ]
1279
+ },
1280
+ {
1281
+ "type": "stack",
1282
+ "direction": "horizontal",
1283
+ "gap": "sm",
1284
+ "children": [
1285
+ {
1286
+ "type": "button",
1287
+ "label": "Create MediaAsset",
1288
+ "event": "CREATE",
1289
+ "variant": "primary",
1290
+ "icon": "plus"
1291
+ }
1292
+ ]
1293
+ }
1294
+ ]
1295
+ },
1296
+ {
1297
+ "type": "divider"
1298
+ },
1299
+ {
1300
+ "type": "data-grid",
1301
+ "entity": "MediaAsset",
1302
+ "emptyIcon": "inbox",
1303
+ "emptyTitle": "No media assets",
1304
+ "emptyDescription": "Upload media to build your library.",
1305
+ "itemActions": [
1306
+ {
1307
+ "label": "View",
1308
+ "event": "VIEW",
1309
+ "variant": "ghost",
1310
+ "size": "sm"
1311
+ }
1312
+ ],
1313
+ "columns": [
1314
+ {
1315
+ "name": "fileName",
1316
+ "label": "File",
1317
+ "variant": "h3",
1318
+ "icon": "image"
1319
+ },
1320
+ {
1321
+ "name": "fileType",
1322
+ "label": "Type",
1323
+ "variant": "badge"
1324
+ },
1325
+ {
1326
+ "name": "fileSize",
1327
+ "label": "Size",
1328
+ "variant": "body",
1329
+ "format": "number"
1330
+ },
1331
+ {
1332
+ "name": "altText",
1333
+ "label": "Alt Text",
1334
+ "variant": "caption"
1335
+ }
1336
+ ],
1337
+ "cols": 3,
1338
+ "gap": "md"
1339
+ }
1340
+ ]
1341
+ }
1342
+ ]
1343
+ }
1344
+ ]
1345
+ ]
1346
+ }
1347
+ ]
1348
+ }
1349
+ },
1350
+ {
1351
+ "name": "MediaAssetCreate",
1352
+ "linkedEntity": "MediaAsset",
1353
+ "category": "interaction",
1354
+ "emits": [
1355
+ {
1356
+ "event": "SAVE"
1357
+ }
1358
+ ],
1359
+ "stateMachine": {
1360
+ "states": [
1361
+ {
1362
+ "name": "closed",
1363
+ "isInitial": true
1364
+ },
1365
+ {
1366
+ "name": "open"
1367
+ }
1368
+ ],
1369
+ "events": [
1370
+ {
1371
+ "key": "INIT",
1372
+ "name": "Initialize"
1373
+ },
1374
+ {
1375
+ "key": "CREATE",
1376
+ "name": "Open"
1377
+ },
1378
+ {
1379
+ "key": "CLOSE",
1380
+ "name": "Close"
1381
+ },
1382
+ {
1383
+ "key": "SAVE",
1384
+ "name": "Save",
1385
+ "payload": [
1386
+ {
1387
+ "name": "data",
1388
+ "type": "object",
1389
+ "required": true
1390
+ }
1391
+ ]
1392
+ }
1393
+ ],
1394
+ "transitions": [
1395
+ {
1396
+ "from": "closed",
1397
+ "to": "closed",
1398
+ "event": "INIT",
1399
+ "effects": [
1400
+ [
1401
+ "ref",
1402
+ "MediaAsset"
1403
+ ]
1404
+ ]
1405
+ },
1406
+ {
1407
+ "from": "closed",
1408
+ "to": "open",
1409
+ "event": "CREATE",
1410
+ "effects": [
1411
+ [
1412
+ "fetch",
1413
+ "MediaAsset"
1414
+ ],
1415
+ [
1416
+ "render-ui",
1417
+ "modal",
1418
+ {
1419
+ "type": "stack",
1420
+ "direction": "vertical",
1421
+ "gap": "md",
1422
+ "children": [
1423
+ {
1424
+ "type": "stack",
1425
+ "direction": "horizontal",
1426
+ "gap": "sm",
1427
+ "children": [
1428
+ {
1429
+ "type": "icon",
1430
+ "name": "plus-circle",
1431
+ "size": "md"
1432
+ },
1433
+ {
1434
+ "type": "typography",
1435
+ "content": "New MediaAsset",
1436
+ "variant": "h3"
1437
+ }
1438
+ ]
1439
+ },
1440
+ {
1441
+ "type": "divider"
1442
+ },
1443
+ {
1444
+ "type": "form-section",
1445
+ "entity": "MediaAsset",
1446
+ "mode": "create",
1447
+ "submitEvent": "SAVE",
1448
+ "cancelEvent": "CLOSE",
1449
+ "fields": [
1450
+ "fileName",
1451
+ "fileType",
1452
+ "fileSize",
1453
+ "url",
1454
+ "altText",
1455
+ "uploadedAt"
1456
+ ]
1166
1457
  }
1167
1458
  ]
1168
1459
  }
@@ -1193,22 +1484,14 @@
1193
1484
  "effects": [
1194
1485
  [
1195
1486
  "persist",
1196
- "update",
1197
- "Article",
1487
+ "create",
1488
+ "MediaAsset",
1198
1489
  "@payload.data"
1199
1490
  ],
1200
1491
  [
1201
1492
  "render-ui",
1202
1493
  "modal",
1203
1494
  null
1204
- ],
1205
- [
1206
- "emit",
1207
- "ARTICLE_UPDATED"
1208
- ],
1209
- [
1210
- "notify",
1211
- "Article updated successfully"
1212
1495
  ]
1213
1496
  ]
1214
1497
  }
@@ -1216,9 +1499,14 @@
1216
1499
  }
1217
1500
  },
1218
1501
  {
1219
- "name": "ArticleView",
1220
- "linkedEntity": "Article",
1502
+ "name": "MediaAssetView",
1503
+ "linkedEntity": "MediaAsset",
1221
1504
  "category": "interaction",
1505
+ "emits": [
1506
+ {
1507
+ "event": "SAVE"
1508
+ }
1509
+ ],
1222
1510
  "stateMachine": {
1223
1511
  "states": [
1224
1512
  {
@@ -1248,6 +1536,17 @@
1248
1536
  {
1249
1537
  "key": "CLOSE",
1250
1538
  "name": "Close"
1539
+ },
1540
+ {
1541
+ "key": "SAVE",
1542
+ "name": "Save",
1543
+ "payload": [
1544
+ {
1545
+ "name": "data",
1546
+ "type": "object",
1547
+ "required": true
1548
+ }
1549
+ ]
1251
1550
  }
1252
1551
  ],
1253
1552
  "transitions": [
@@ -1258,7 +1557,7 @@
1258
1557
  "effects": [
1259
1558
  [
1260
1559
  "ref",
1261
- "Article"
1560
+ "MediaAsset"
1262
1561
  ]
1263
1562
  ]
1264
1563
  },
@@ -1269,7 +1568,7 @@
1269
1568
  "effects": [
1270
1569
  [
1271
1570
  "fetch",
1272
- "Article",
1571
+ "MediaAsset",
1273
1572
  {
1274
1573
  "id": "@payload.id"
1275
1574
  }
@@ -1296,7 +1595,7 @@
1296
1595
  {
1297
1596
  "type": "typography",
1298
1597
  "variant": "h3",
1299
- "content": "@entity.title"
1598
+ "content": "@entity.fileName"
1300
1599
  }
1301
1600
  ]
1302
1601
  },
@@ -1311,12 +1610,12 @@
1311
1610
  {
1312
1611
  "type": "typography",
1313
1612
  "variant": "caption",
1314
- "content": "Title"
1613
+ "content": "File Name"
1315
1614
  },
1316
1615
  {
1317
1616
  "type": "typography",
1318
1617
  "variant": "body",
1319
- "content": "@entity.title"
1618
+ "content": "@entity.fileName"
1320
1619
  }
1321
1620
  ]
1322
1621
  },
@@ -1328,12 +1627,12 @@
1328
1627
  {
1329
1628
  "type": "typography",
1330
1629
  "variant": "caption",
1331
- "content": "Slug"
1630
+ "content": "File Type"
1332
1631
  },
1333
1632
  {
1334
1633
  "type": "typography",
1335
1634
  "variant": "body",
1336
- "content": "@entity.slug"
1635
+ "content": "@entity.fileType"
1337
1636
  }
1338
1637
  ]
1339
1638
  },
@@ -1345,12 +1644,12 @@
1345
1644
  {
1346
1645
  "type": "typography",
1347
1646
  "variant": "caption",
1348
- "content": "Content"
1647
+ "content": "File Size"
1349
1648
  },
1350
1649
  {
1351
1650
  "type": "typography",
1352
1651
  "variant": "body",
1353
- "content": "@entity.content"
1652
+ "content": "@entity.fileSize"
1354
1653
  }
1355
1654
  ]
1356
1655
  },
@@ -1362,12 +1661,12 @@
1362
1661
  {
1363
1662
  "type": "typography",
1364
1663
  "variant": "caption",
1365
- "content": "Author"
1664
+ "content": "Url"
1366
1665
  },
1367
1666
  {
1368
1667
  "type": "typography",
1369
1668
  "variant": "body",
1370
- "content": "@entity.author"
1669
+ "content": "@entity.url"
1371
1670
  }
1372
1671
  ]
1373
1672
  },
@@ -1379,12 +1678,12 @@
1379
1678
  {
1380
1679
  "type": "typography",
1381
1680
  "variant": "caption",
1382
- "content": "Status"
1681
+ "content": "Alt Text"
1383
1682
  },
1384
1683
  {
1385
1684
  "type": "typography",
1386
1685
  "variant": "body",
1387
- "content": "@entity.status"
1686
+ "content": "@entity.altText"
1388
1687
  }
1389
1688
  ]
1390
1689
  },
@@ -1396,12 +1695,12 @@
1396
1695
  {
1397
1696
  "type": "typography",
1398
1697
  "variant": "caption",
1399
- "content": "Published At"
1698
+ "content": "Uploaded At"
1400
1699
  },
1401
1700
  {
1402
1701
  "type": "typography",
1403
1702
  "variant": "body",
1404
- "content": "@entity.publishedAt"
1703
+ "content": "@entity.uploadedAt"
1405
1704
  }
1406
1705
  ]
1407
1706
  },
@@ -1414,13 +1713,6 @@
1414
1713
  "gap": "sm",
1415
1714
  "justify": "end",
1416
1715
  "children": [
1417
- {
1418
- "type": "button",
1419
- "label": "Edit",
1420
- "event": "EDIT",
1421
- "variant": "primary",
1422
- "icon": "edit"
1423
- },
1424
1716
  {
1425
1717
  "type": "button",
1426
1718
  "label": "Close",
@@ -1450,6 +1742,18 @@
1450
1742
  "info"
1451
1743
  ]
1452
1744
  ]
1745
+ },
1746
+ {
1747
+ "from": "open",
1748
+ "to": "closed",
1749
+ "event": "SAVE",
1750
+ "effects": [
1751
+ [
1752
+ "render-ui",
1753
+ "modal",
1754
+ null
1755
+ ]
1756
+ ]
1453
1757
  }
1454
1758
  ]
1455
1759
  }
@@ -1457,32 +1761,28 @@
1457
1761
  ],
1458
1762
  "pages": [
1459
1763
  {
1460
- "name": "ArticlesPage",
1461
- "path": "/articles",
1462
- "isInitial": true,
1764
+ "name": "MediaPage",
1765
+ "path": "/media",
1463
1766
  "traits": [
1464
1767
  {
1465
- "ref": "ArticleBrowse"
1466
- },
1467
- {
1468
- "ref": "ArticleCreate"
1768
+ "ref": "MediaAssetBrowse"
1469
1769
  },
1470
1770
  {
1471
- "ref": "ArticleEdit"
1771
+ "ref": "MediaAssetCreate"
1472
1772
  },
1473
1773
  {
1474
- "ref": "ArticleView"
1774
+ "ref": "MediaAssetView"
1475
1775
  }
1476
1776
  ]
1477
1777
  }
1478
1778
  ]
1479
1779
  },
1480
1780
  {
1481
- "name": "MediaAssetOrbital",
1781
+ "name": "CategoryOrbital",
1482
1782
  "entity": {
1483
- "name": "MediaAsset",
1783
+ "name": "Category",
1484
1784
  "persistence": "persistent",
1485
- "collection": "mediaassets",
1785
+ "collection": "categorys",
1486
1786
  "fields": [
1487
1787
  {
1488
1788
  "name": "id",
@@ -1490,45 +1790,50 @@
1490
1790
  "required": true
1491
1791
  },
1492
1792
  {
1493
- "name": "fileName",
1793
+ "name": "name",
1494
1794
  "type": "string",
1495
1795
  "required": true
1496
1796
  },
1497
1797
  {
1498
- "name": "fileType",
1798
+ "name": "slug",
1499
1799
  "type": "string",
1500
1800
  "required": true
1501
1801
  },
1502
1802
  {
1503
- "name": "fileSize",
1504
- "type": "number"
1505
- },
1506
- {
1507
- "name": "url",
1803
+ "name": "description",
1508
1804
  "type": "string"
1509
1805
  },
1510
1806
  {
1511
- "name": "altText",
1807
+ "name": "parentCategory",
1512
1808
  "type": "string"
1513
1809
  },
1514
1810
  {
1515
- "name": "uploadedAt",
1516
- "type": "date"
1811
+ "name": "articleCount",
1812
+ "type": "number",
1813
+ "default": 0
1517
1814
  }
1518
1815
  ]
1519
1816
  },
1520
1817
  "traits": [
1521
1818
  {
1522
- "name": "MediaAssetBrowse",
1523
- "linkedEntity": "MediaAsset",
1819
+ "name": "CategoryBrowse",
1820
+ "linkedEntity": "Category",
1524
1821
  "category": "interaction",
1525
1822
  "listens": [
1526
1823
  {
1527
- "event": "SAVE",
1528
- "triggers": "SAVE"
1824
+ "event": "CATEGORY_CREATED",
1825
+ "triggers": "INIT"
1529
1826
  },
1530
1827
  {
1531
- "event": "PUBLISH",
1828
+ "event": "CATEGORY_UPDATED",
1829
+ "triggers": "INIT"
1830
+ },
1831
+ {
1832
+ "event": "CATEGORY_DELETED",
1833
+ "triggers": "INIT"
1834
+ },
1835
+ {
1836
+ "event": "CATEGORIZE",
1532
1837
  "triggers": "INIT",
1533
1838
  "scope": "external"
1534
1839
  }
@@ -1564,1277 +1869,45 @@
1564
1869
  }
1565
1870
  ]
1566
1871
  },
1567
- {
1568
- "key": "SAVE",
1569
- "name": "SAVE",
1570
- "payload": [
1571
- {
1572
- "name": "data",
1573
- "type": "object",
1574
- "required": true
1575
- }
1576
- ]
1577
- }
1578
- ],
1579
- "transitions": [
1580
- {
1581
- "from": "browsing",
1582
- "to": "browsing",
1583
- "event": "INIT",
1584
- "effects": [
1585
- [
1586
- "ref",
1587
- "MediaAsset"
1588
- ],
1589
- [
1590
- "render-ui",
1591
- "main",
1592
- {
1593
- "type": "dashboard-layout",
1594
- "appName": "CmsApp",
1595
- "navItems": [
1596
- {
1597
- "label": "Articles",
1598
- "href": "/articles",
1599
- "icon": "file-text"
1600
- },
1601
- {
1602
- "label": "Media",
1603
- "href": "/media",
1604
- "icon": "image"
1605
- },
1606
- {
1607
- "label": "Categories",
1608
- "href": "/categories",
1609
- "icon": "folder"
1610
- }
1611
- ],
1612
- "children": [
1613
- {
1614
- "type": "stack",
1615
- "direction": "vertical",
1616
- "gap": "lg",
1617
- "className": "max-w-5xl mx-auto w-full",
1618
- "children": [
1619
- {
1620
- "type": "stack",
1621
- "direction": "horizontal",
1622
- "gap": "md",
1623
- "justify": "space-between",
1624
- "align": "center",
1625
- "children": [
1626
- {
1627
- "type": "stack",
1628
- "direction": "horizontal",
1629
- "gap": "sm",
1630
- "align": "center",
1631
- "children": [
1632
- {
1633
- "type": "icon",
1634
- "name": "image",
1635
- "size": "lg"
1636
- },
1637
- {
1638
- "type": "typography",
1639
- "content": "Media Library",
1640
- "variant": "h2"
1641
- }
1642
- ]
1643
- },
1644
- {
1645
- "type": "stack",
1646
- "direction": "horizontal",
1647
- "gap": "sm",
1648
- "children": [
1649
- {
1650
- "type": "button",
1651
- "label": "Create MediaAsset",
1652
- "event": "CREATE",
1653
- "variant": "primary",
1654
- "icon": "plus"
1655
- }
1656
- ]
1657
- }
1658
- ]
1659
- },
1660
- {
1661
- "type": "divider"
1662
- },
1663
- {
1664
- "type": "data-grid",
1665
- "entity": "MediaAsset",
1666
- "emptyIcon": "inbox",
1667
- "emptyTitle": "No media assets",
1668
- "emptyDescription": "Upload media to build your library.",
1669
- "itemActions": [
1670
- {
1671
- "label": "View",
1672
- "event": "VIEW",
1673
- "variant": "ghost",
1674
- "size": "sm"
1675
- }
1676
- ],
1677
- "columns": [
1678
- {
1679
- "name": "fileName",
1680
- "label": "File",
1681
- "variant": "h3",
1682
- "icon": "image"
1683
- },
1684
- {
1685
- "name": "fileType",
1686
- "label": "Type",
1687
- "variant": "badge"
1688
- },
1689
- {
1690
- "name": "fileSize",
1691
- "label": "Size",
1692
- "variant": "body",
1693
- "format": "number"
1694
- },
1695
- {
1696
- "name": "altText",
1697
- "label": "Alt Text",
1698
- "variant": "caption"
1699
- }
1700
- ],
1701
- "cols": 3,
1702
- "gap": "md"
1703
- }
1704
- ]
1705
- }
1706
- ]
1707
- }
1708
- ]
1709
- ]
1710
- },
1711
- {
1712
- "from": "browsing",
1713
- "to": "browsing",
1714
- "event": "SAVE",
1715
- "effects": [
1716
- [
1717
- "ref",
1718
- "MediaAsset"
1719
- ]
1720
- ]
1721
- }
1722
- ]
1723
- }
1724
- },
1725
- {
1726
- "name": "MediaAssetCreate",
1727
- "linkedEntity": "MediaAsset",
1728
- "category": "interaction",
1729
- "emits": [
1730
- {
1731
- "event": "SAVE"
1732
- }
1733
- ],
1734
- "stateMachine": {
1735
- "states": [
1736
- {
1737
- "name": "closed",
1738
- "isInitial": true
1739
- },
1740
- {
1741
- "name": "open"
1742
- }
1743
- ],
1744
- "events": [
1745
- {
1746
- "key": "INIT",
1747
- "name": "Initialize"
1748
- },
1749
- {
1750
- "key": "CREATE",
1751
- "name": "Open"
1752
- },
1753
- {
1754
- "key": "CLOSE",
1755
- "name": "Close"
1756
- },
1757
- {
1758
- "key": "SAVE",
1759
- "name": "Save",
1760
- "payload": [
1761
- {
1762
- "name": "data",
1763
- "type": "object",
1764
- "required": true
1765
- }
1766
- ]
1767
- }
1768
- ],
1769
- "transitions": [
1770
- {
1771
- "from": "closed",
1772
- "to": "closed",
1773
- "event": "INIT",
1774
- "effects": [
1775
- [
1776
- "ref",
1777
- "MediaAsset"
1778
- ]
1779
- ]
1780
- },
1781
- {
1782
- "from": "closed",
1783
- "to": "open",
1784
- "event": "CREATE",
1785
- "effects": [
1786
- [
1787
- "fetch",
1788
- "MediaAsset"
1789
- ],
1790
- [
1791
- "render-ui",
1792
- "modal",
1793
- {
1794
- "type": "stack",
1795
- "direction": "vertical",
1796
- "gap": "md",
1797
- "children": [
1798
- {
1799
- "type": "stack",
1800
- "direction": "horizontal",
1801
- "gap": "sm",
1802
- "children": [
1803
- {
1804
- "type": "icon",
1805
- "name": "plus-circle",
1806
- "size": "md"
1807
- },
1808
- {
1809
- "type": "typography",
1810
- "content": "New MediaAsset",
1811
- "variant": "h3"
1812
- }
1813
- ]
1814
- },
1815
- {
1816
- "type": "divider"
1817
- },
1818
- {
1819
- "type": "form-section",
1820
- "entity": "MediaAsset",
1821
- "mode": "create",
1822
- "submitEvent": "SAVE",
1823
- "cancelEvent": "CLOSE",
1824
- "fields": [
1825
- "fileName",
1826
- "fileType",
1827
- "fileSize",
1828
- "url",
1829
- "altText",
1830
- "uploadedAt"
1831
- ]
1832
- }
1833
- ]
1834
- }
1835
- ]
1836
- ]
1837
- },
1838
- {
1839
- "from": "open",
1840
- "to": "closed",
1841
- "event": "CLOSE",
1842
- "effects": [
1843
- [
1844
- "render-ui",
1845
- "modal",
1846
- null
1847
- ],
1848
- [
1849
- "notify",
1850
- "Cancelled",
1851
- "info"
1852
- ]
1853
- ]
1854
- },
1855
- {
1856
- "from": "open",
1857
- "to": "closed",
1858
- "event": "SAVE",
1859
- "effects": [
1860
- [
1861
- "persist",
1862
- "create",
1863
- "MediaAsset",
1864
- "@payload.data"
1865
- ],
1866
- [
1867
- "render-ui",
1868
- "modal",
1869
- null
1870
- ],
1871
- [
1872
- "emit",
1873
- "SAVE"
1874
- ],
1875
- [
1876
- "notify",
1877
- "MediaAsset created successfully"
1878
- ]
1879
- ]
1880
- }
1881
- ]
1882
- }
1883
- },
1884
- {
1885
- "name": "MediaAssetView",
1886
- "linkedEntity": "MediaAsset",
1887
- "category": "interaction",
1888
- "stateMachine": {
1889
- "states": [
1890
- {
1891
- "name": "closed",
1892
- "isInitial": true
1893
- },
1894
- {
1895
- "name": "open"
1896
- }
1897
- ],
1898
- "events": [
1899
- {
1900
- "key": "INIT",
1901
- "name": "Initialize"
1902
- },
1903
- {
1904
- "key": "VIEW",
1905
- "name": "Open",
1906
- "payload": [
1907
- {
1908
- "name": "id",
1909
- "type": "string",
1910
- "required": true
1911
- }
1912
- ]
1913
- },
1914
- {
1915
- "key": "CLOSE",
1916
- "name": "Close"
1917
- }
1918
- ],
1919
- "transitions": [
1920
- {
1921
- "from": "closed",
1922
- "to": "closed",
1923
- "event": "INIT",
1924
- "effects": [
1925
- [
1926
- "ref",
1927
- "MediaAsset"
1928
- ]
1929
- ]
1930
- },
1931
- {
1932
- "from": "closed",
1933
- "to": "open",
1934
- "event": "VIEW",
1935
- "effects": [
1936
- [
1937
- "fetch",
1938
- "MediaAsset",
1939
- {
1940
- "id": "@payload.id"
1941
- }
1942
- ],
1943
- [
1944
- "render-ui",
1945
- "modal",
1946
- {
1947
- "type": "stack",
1948
- "direction": "vertical",
1949
- "gap": "md",
1950
- "children": [
1951
- {
1952
- "type": "stack",
1953
- "direction": "horizontal",
1954
- "gap": "sm",
1955
- "align": "center",
1956
- "children": [
1957
- {
1958
- "type": "icon",
1959
- "name": "eye",
1960
- "size": "md"
1961
- },
1962
- {
1963
- "type": "typography",
1964
- "variant": "h3",
1965
- "content": "@entity.fileName"
1966
- }
1967
- ]
1968
- },
1969
- {
1970
- "type": "divider"
1971
- },
1972
- {
1973
- "type": "stack",
1974
- "direction": "horizontal",
1975
- "gap": "md",
1976
- "children": [
1977
- {
1978
- "type": "typography",
1979
- "variant": "caption",
1980
- "content": "File Name"
1981
- },
1982
- {
1983
- "type": "typography",
1984
- "variant": "body",
1985
- "content": "@entity.fileName"
1986
- }
1987
- ]
1988
- },
1989
- {
1990
- "type": "stack",
1991
- "direction": "horizontal",
1992
- "gap": "md",
1993
- "children": [
1994
- {
1995
- "type": "typography",
1996
- "variant": "caption",
1997
- "content": "File Type"
1998
- },
1999
- {
2000
- "type": "typography",
2001
- "variant": "body",
2002
- "content": "@entity.fileType"
2003
- }
2004
- ]
2005
- },
2006
- {
2007
- "type": "stack",
2008
- "direction": "horizontal",
2009
- "gap": "md",
2010
- "children": [
2011
- {
2012
- "type": "typography",
2013
- "variant": "caption",
2014
- "content": "File Size"
2015
- },
2016
- {
2017
- "type": "typography",
2018
- "variant": "body",
2019
- "content": "@entity.fileSize"
2020
- }
2021
- ]
2022
- },
2023
- {
2024
- "type": "stack",
2025
- "direction": "horizontal",
2026
- "gap": "md",
2027
- "children": [
2028
- {
2029
- "type": "typography",
2030
- "variant": "caption",
2031
- "content": "Url"
2032
- },
2033
- {
2034
- "type": "typography",
2035
- "variant": "body",
2036
- "content": "@entity.url"
2037
- }
2038
- ]
2039
- },
2040
- {
2041
- "type": "stack",
2042
- "direction": "horizontal",
2043
- "gap": "md",
2044
- "children": [
2045
- {
2046
- "type": "typography",
2047
- "variant": "caption",
2048
- "content": "Alt Text"
2049
- },
2050
- {
2051
- "type": "typography",
2052
- "variant": "body",
2053
- "content": "@entity.altText"
2054
- }
2055
- ]
2056
- },
2057
- {
2058
- "type": "stack",
2059
- "direction": "horizontal",
2060
- "gap": "md",
2061
- "children": [
2062
- {
2063
- "type": "typography",
2064
- "variant": "caption",
2065
- "content": "Uploaded At"
2066
- },
2067
- {
2068
- "type": "typography",
2069
- "variant": "body",
2070
- "content": "@entity.uploadedAt"
2071
- }
2072
- ]
2073
- },
2074
- {
2075
- "type": "divider"
2076
- },
2077
- {
2078
- "type": "stack",
2079
- "direction": "horizontal",
2080
- "gap": "sm",
2081
- "justify": "end",
2082
- "children": [
2083
- {
2084
- "type": "button",
2085
- "label": "Close",
2086
- "event": "CLOSE",
2087
- "variant": "ghost"
2088
- }
2089
- ]
2090
- }
2091
- ]
2092
- }
2093
- ]
2094
- ]
2095
- },
2096
- {
2097
- "from": "open",
2098
- "to": "closed",
2099
- "event": "CLOSE",
2100
- "effects": [
2101
- [
2102
- "render-ui",
2103
- "modal",
2104
- null
2105
- ],
2106
- [
2107
- "notify",
2108
- "Cancelled",
2109
- "info"
2110
- ]
2111
- ]
2112
- }
2113
- ]
2114
- }
2115
- }
2116
- ],
2117
- "pages": [
2118
- {
2119
- "name": "MediaPage",
2120
- "path": "/media",
2121
- "traits": [
2122
- {
2123
- "ref": "MediaAssetBrowse"
2124
- },
2125
- {
2126
- "ref": "MediaAssetCreate"
2127
- },
2128
- {
2129
- "ref": "MediaAssetView"
2130
- }
2131
- ]
2132
- }
2133
- ]
2134
- },
2135
- {
2136
- "name": "CategoryOrbital",
2137
- "entity": {
2138
- "name": "Category",
2139
- "persistence": "persistent",
2140
- "collection": "categorys",
2141
- "fields": [
2142
- {
2143
- "name": "id",
2144
- "type": "string",
2145
- "required": true
2146
- },
2147
- {
2148
- "name": "name",
2149
- "type": "string",
2150
- "required": true
2151
- },
2152
- {
2153
- "name": "slug",
2154
- "type": "string",
2155
- "required": true
2156
- },
2157
- {
2158
- "name": "description",
2159
- "type": "string"
2160
- },
2161
- {
2162
- "name": "parentCategory",
2163
- "type": "string"
2164
- },
2165
- {
2166
- "name": "articleCount",
2167
- "type": "number",
2168
- "default": 0
2169
- }
2170
- ]
2171
- },
2172
- "traits": [
2173
- {
2174
- "name": "CategoryBrowse",
2175
- "linkedEntity": "Category",
2176
- "category": "interaction",
2177
- "listens": [
2178
- {
2179
- "event": "CATEGORY_CREATED",
2180
- "triggers": "CATEGORY_CREATED"
2181
- },
2182
- {
2183
- "event": "CATEGORY_UPDATED",
2184
- "triggers": "CATEGORY_UPDATED"
2185
- },
2186
- {
2187
- "event": "CATEGORIZE",
2188
- "triggers": "INIT",
2189
- "scope": "external"
2190
- }
2191
- ],
2192
- "stateMachine": {
2193
- "states": [
2194
- {
2195
- "name": "browsing",
2196
- "isInitial": true
2197
- },
2198
- {
2199
- "name": "deleting"
2200
- }
2201
- ],
2202
- "events": [
2203
- {
2204
- "key": "INIT",
2205
- "name": "Initialize"
2206
- },
2207
- {
2208
- "key": "CREATE",
2209
- "name": "CREATE"
2210
- },
2211
- {
2212
- "key": "VIEW",
2213
- "name": "VIEW",
2214
- "payload": [
2215
- {
2216
- "name": "id",
2217
- "type": "string",
2218
- "required": true
2219
- },
2220
- {
2221
- "name": "row",
2222
- "type": "object"
2223
- }
2224
- ]
2225
- },
2226
- {
2227
- "key": "EDIT",
2228
- "name": "EDIT",
2229
- "payload": [
2230
- {
2231
- "name": "id",
2232
- "type": "string",
2233
- "required": true
2234
- },
2235
- {
2236
- "name": "row",
2237
- "type": "object"
2238
- }
2239
- ]
2240
- },
2241
- {
2242
- "key": "DELETE",
2243
- "name": "DELETE",
2244
- "payload": [
2245
- {
2246
- "name": "id",
2247
- "type": "string",
2248
- "required": true
2249
- },
2250
- {
2251
- "name": "row",
2252
- "type": "object"
2253
- }
2254
- ]
2255
- },
2256
- {
2257
- "key": "CATEGORY_CREATED",
2258
- "name": "CATEGORY_CREATED",
2259
- "payload": [
2260
- {
2261
- "name": "data",
2262
- "type": "object",
2263
- "required": true
2264
- }
2265
- ]
2266
- },
2267
- {
2268
- "key": "CATEGORY_UPDATED",
2269
- "name": "CATEGORY_UPDATED",
2270
- "payload": [
2271
- {
2272
- "name": "data",
2273
- "type": "object",
2274
- "required": true
2275
- }
2276
- ]
2277
- },
2278
- {
2279
- "key": "CONFIRM_DELETE",
2280
- "name": "Confirm Delete"
2281
- },
2282
- {
2283
- "key": "CANCEL",
2284
- "name": "Cancel"
2285
- },
2286
- {
2287
- "key": "CLOSE",
2288
- "name": "Close"
2289
- }
2290
- ],
2291
- "transitions": [
2292
- {
2293
- "from": "browsing",
2294
- "to": "browsing",
2295
- "event": "INIT",
2296
- "effects": [
2297
- [
2298
- "ref",
2299
- "Category"
2300
- ],
2301
- [
2302
- "render-ui",
2303
- "main",
2304
- {
2305
- "type": "dashboard-layout",
2306
- "appName": "CmsApp",
2307
- "navItems": [
2308
- {
2309
- "label": "Articles",
2310
- "href": "/articles",
2311
- "icon": "file-text"
2312
- },
2313
- {
2314
- "label": "Media",
2315
- "href": "/media",
2316
- "icon": "image"
2317
- },
2318
- {
2319
- "label": "Categories",
2320
- "href": "/categories",
2321
- "icon": "folder"
2322
- }
2323
- ],
2324
- "children": [
2325
- {
2326
- "type": "stack",
2327
- "direction": "vertical",
2328
- "gap": "lg",
2329
- "className": "max-w-5xl mx-auto w-full",
2330
- "children": [
2331
- {
2332
- "type": "stack",
2333
- "direction": "horizontal",
2334
- "gap": "md",
2335
- "justify": "space-between",
2336
- "align": "center",
2337
- "children": [
2338
- {
2339
- "type": "stack",
2340
- "direction": "horizontal",
2341
- "gap": "sm",
2342
- "align": "center",
2343
- "children": [
2344
- {
2345
- "type": "icon",
2346
- "name": "folder",
2347
- "size": "lg"
2348
- },
2349
- {
2350
- "type": "typography",
2351
- "content": "Categories",
2352
- "variant": "h2"
2353
- }
2354
- ]
2355
- },
2356
- {
2357
- "type": "stack",
2358
- "direction": "horizontal",
2359
- "gap": "sm",
2360
- "children": [
2361
- {
2362
- "type": "button",
2363
- "label": "Create Category",
2364
- "event": "CREATE",
2365
- "variant": "primary",
2366
- "icon": "plus"
2367
- }
2368
- ]
2369
- }
2370
- ]
2371
- },
2372
- {
2373
- "type": "divider"
2374
- },
2375
- {
2376
- "type": "data-list",
2377
- "entity": "Category",
2378
- "emptyIcon": "inbox",
2379
- "emptyTitle": "No categories yet",
2380
- "emptyDescription": "Create categories to organize your content.",
2381
- "itemActions": [
2382
- {
2383
- "label": "View",
2384
- "event": "VIEW",
2385
- "variant": "ghost",
2386
- "size": "sm"
2387
- },
2388
- {
2389
- "label": "Edit",
2390
- "event": "EDIT",
2391
- "variant": "ghost",
2392
- "size": "sm"
2393
- },
2394
- {
2395
- "label": "Delete",
2396
- "event": "DELETE",
2397
- "variant": "danger",
2398
- "size": "sm"
2399
- }
2400
- ],
2401
- "columns": [
2402
- {
2403
- "name": "name",
2404
- "variant": "h3",
2405
- "icon": "folder"
2406
- },
2407
- {
2408
- "name": "articleCount",
2409
- "label": "Articles",
2410
- "variant": "badge",
2411
- "format": "number"
2412
- },
2413
- {
2414
- "name": "description",
2415
- "variant": "body"
2416
- },
2417
- {
2418
- "name": "slug",
2419
- "variant": "caption"
2420
- }
2421
- ],
2422
- "variant": "card",
2423
- "gap": "sm"
2424
- }
2425
- ]
2426
- }
2427
- ]
2428
- }
2429
- ]
2430
- ]
2431
- },
2432
- {
2433
- "from": "browsing",
2434
- "to": "browsing",
2435
- "event": "CATEGORY_CREATED",
2436
- "effects": [
2437
- [
2438
- "ref",
2439
- "Category"
2440
- ]
2441
- ]
2442
- },
2443
- {
2444
- "from": "browsing",
2445
- "to": "browsing",
2446
- "event": "CATEGORY_UPDATED",
2447
- "effects": [
2448
- [
2449
- "ref",
2450
- "Category"
2451
- ]
2452
- ]
2453
- },
2454
- {
2455
- "from": "browsing",
2456
- "to": "deleting",
2457
- "event": "DELETE",
2458
- "effects": [
2459
- [
2460
- "fetch",
2461
- "Category",
2462
- {
2463
- "id": "@payload.id"
2464
- }
2465
- ],
2466
- [
2467
- "render-ui",
2468
- "modal",
2469
- {
2470
- "type": "stack",
2471
- "direction": "vertical",
2472
- "gap": "md",
2473
- "children": [
2474
- {
2475
- "type": "stack",
2476
- "direction": "horizontal",
2477
- "gap": "sm",
2478
- "children": [
2479
- {
2480
- "type": "icon",
2481
- "name": "trash-2",
2482
- "size": "md"
2483
- },
2484
- {
2485
- "type": "typography",
2486
- "content": "Delete Category",
2487
- "variant": "h3"
2488
- }
2489
- ]
2490
- },
2491
- {
2492
- "type": "divider"
2493
- },
2494
- {
2495
- "type": "typography",
2496
- "content": "@entity.name",
2497
- "variant": "h4"
2498
- },
2499
- {
2500
- "type": "typography",
2501
- "content": "This action cannot be undone.",
2502
- "variant": "body"
2503
- },
2504
- {
2505
- "type": "stack",
2506
- "direction": "horizontal",
2507
- "gap": "sm",
2508
- "justify": "end",
2509
- "children": [
2510
- {
2511
- "type": "button",
2512
- "label": "Cancel",
2513
- "event": "CANCEL",
2514
- "variant": "ghost"
2515
- },
2516
- {
2517
- "type": "button",
2518
- "label": "Delete",
2519
- "event": "CONFIRM_DELETE",
2520
- "variant": "danger",
2521
- "icon": "trash"
2522
- }
2523
- ]
2524
- }
2525
- ]
2526
- }
2527
- ]
2528
- ]
2529
- },
2530
- {
2531
- "from": "deleting",
2532
- "to": "browsing",
2533
- "event": "CONFIRM_DELETE",
2534
- "effects": [
2535
- [
2536
- "persist",
2537
- "delete",
2538
- "Category",
2539
- "@entity.id"
2540
- ],
2541
- [
2542
- "render-ui",
2543
- "modal",
2544
- null
2545
- ],
2546
- [
2547
- "render-ui",
2548
- "main",
2549
- {
2550
- "type": "dashboard-layout",
2551
- "appName": "CmsApp",
2552
- "navItems": [
2553
- {
2554
- "label": "Articles",
2555
- "href": "/articles",
2556
- "icon": "file-text"
2557
- },
2558
- {
2559
- "label": "Media",
2560
- "href": "/media",
2561
- "icon": "image"
2562
- },
2563
- {
2564
- "label": "Categories",
2565
- "href": "/categories",
2566
- "icon": "folder"
2567
- }
2568
- ],
2569
- "children": [
2570
- {
2571
- "type": "stack",
2572
- "direction": "vertical",
2573
- "gap": "lg",
2574
- "className": "max-w-5xl mx-auto w-full",
2575
- "children": [
2576
- {
2577
- "type": "stack",
2578
- "direction": "horizontal",
2579
- "gap": "md",
2580
- "justify": "space-between",
2581
- "align": "center",
2582
- "children": [
2583
- {
2584
- "type": "stack",
2585
- "direction": "horizontal",
2586
- "gap": "sm",
2587
- "align": "center",
2588
- "children": [
2589
- {
2590
- "type": "icon",
2591
- "name": "folder",
2592
- "size": "lg"
2593
- },
2594
- {
2595
- "type": "typography",
2596
- "content": "Categories",
2597
- "variant": "h2"
2598
- }
2599
- ]
2600
- },
2601
- {
2602
- "type": "stack",
2603
- "direction": "horizontal",
2604
- "gap": "sm",
2605
- "children": [
2606
- {
2607
- "type": "button",
2608
- "label": "Create Category",
2609
- "event": "CREATE",
2610
- "variant": "primary",
2611
- "icon": "plus"
2612
- }
2613
- ]
2614
- }
2615
- ]
2616
- },
2617
- {
2618
- "type": "divider"
2619
- },
2620
- {
2621
- "type": "data-list",
2622
- "entity": "Category",
2623
- "emptyIcon": "inbox",
2624
- "emptyTitle": "No categories yet",
2625
- "emptyDescription": "Create categories to organize your content.",
2626
- "itemActions": [
2627
- {
2628
- "label": "View",
2629
- "event": "VIEW",
2630
- "variant": "ghost",
2631
- "size": "sm"
2632
- },
2633
- {
2634
- "label": "Edit",
2635
- "event": "EDIT",
2636
- "variant": "ghost",
2637
- "size": "sm"
2638
- },
2639
- {
2640
- "label": "Delete",
2641
- "event": "DELETE",
2642
- "variant": "danger",
2643
- "size": "sm"
2644
- }
2645
- ],
2646
- "columns": [
2647
- {
2648
- "name": "name",
2649
- "variant": "h3",
2650
- "icon": "folder"
2651
- },
2652
- {
2653
- "name": "articleCount",
2654
- "label": "Articles",
2655
- "variant": "badge",
2656
- "format": "number"
2657
- },
2658
- {
2659
- "name": "description",
2660
- "variant": "body"
2661
- },
2662
- {
2663
- "name": "slug",
2664
- "variant": "caption"
2665
- }
2666
- ],
2667
- "variant": "card",
2668
- "gap": "sm"
2669
- }
2670
- ]
2671
- }
2672
- ]
2673
- }
2674
- ],
2675
- [
2676
- "notify",
2677
- "Category deleted successfully"
2678
- ]
2679
- ]
2680
- },
2681
- {
2682
- "from": "deleting",
2683
- "to": "browsing",
2684
- "event": "CANCEL",
2685
- "effects": [
2686
- [
2687
- "render-ui",
2688
- "modal",
2689
- null
2690
- ],
2691
- [
2692
- "fetch",
2693
- "Category"
2694
- ],
2695
- [
2696
- "render-ui",
2697
- "main",
2698
- {
2699
- "type": "dashboard-layout",
2700
- "appName": "CmsApp",
2701
- "navItems": [
2702
- {
2703
- "label": "Articles",
2704
- "href": "/articles",
2705
- "icon": "file-text"
2706
- },
2707
- {
2708
- "label": "Media",
2709
- "href": "/media",
2710
- "icon": "image"
2711
- },
2712
- {
2713
- "label": "Categories",
2714
- "href": "/categories",
2715
- "icon": "folder"
2716
- }
2717
- ],
2718
- "children": [
2719
- {
2720
- "type": "stack",
2721
- "direction": "vertical",
2722
- "gap": "lg",
2723
- "className": "max-w-5xl mx-auto w-full",
2724
- "children": [
2725
- {
2726
- "type": "stack",
2727
- "direction": "horizontal",
2728
- "gap": "md",
2729
- "justify": "space-between",
2730
- "align": "center",
2731
- "children": [
2732
- {
2733
- "type": "stack",
2734
- "direction": "horizontal",
2735
- "gap": "sm",
2736
- "align": "center",
2737
- "children": [
2738
- {
2739
- "type": "icon",
2740
- "name": "folder",
2741
- "size": "lg"
2742
- },
2743
- {
2744
- "type": "typography",
2745
- "content": "Categories",
2746
- "variant": "h2"
2747
- }
2748
- ]
2749
- },
2750
- {
2751
- "type": "stack",
2752
- "direction": "horizontal",
2753
- "gap": "sm",
2754
- "children": [
2755
- {
2756
- "type": "button",
2757
- "label": "Create Category",
2758
- "event": "CREATE",
2759
- "variant": "primary",
2760
- "icon": "plus"
2761
- }
2762
- ]
2763
- }
2764
- ]
2765
- },
2766
- {
2767
- "type": "divider"
2768
- },
2769
- {
2770
- "type": "data-list",
2771
- "entity": "Category",
2772
- "emptyIcon": "inbox",
2773
- "emptyTitle": "No categories yet",
2774
- "emptyDescription": "Create categories to organize your content.",
2775
- "itemActions": [
2776
- {
2777
- "label": "View",
2778
- "event": "VIEW",
2779
- "variant": "ghost",
2780
- "size": "sm"
2781
- },
2782
- {
2783
- "label": "Edit",
2784
- "event": "EDIT",
2785
- "variant": "ghost",
2786
- "size": "sm"
2787
- },
2788
- {
2789
- "label": "Delete",
2790
- "event": "DELETE",
2791
- "variant": "danger",
2792
- "size": "sm"
2793
- }
2794
- ],
2795
- "columns": [
2796
- {
2797
- "name": "name",
2798
- "variant": "h3",
2799
- "icon": "folder"
2800
- },
2801
- {
2802
- "name": "articleCount",
2803
- "label": "Articles",
2804
- "variant": "badge",
2805
- "format": "number"
2806
- },
2807
- {
2808
- "name": "description",
2809
- "variant": "body"
2810
- },
2811
- {
2812
- "name": "slug",
2813
- "variant": "caption"
2814
- }
2815
- ],
2816
- "variant": "card",
2817
- "gap": "sm"
2818
- }
2819
- ]
2820
- }
2821
- ]
2822
- }
2823
- ]
1872
+ {
1873
+ "key": "EDIT",
1874
+ "name": "EDIT",
1875
+ "payload": [
1876
+ {
1877
+ "name": "id",
1878
+ "type": "string",
1879
+ "required": true
1880
+ },
1881
+ {
1882
+ "name": "row",
1883
+ "type": "object"
1884
+ }
2824
1885
  ]
2825
1886
  },
2826
1887
  {
2827
- "from": "deleting",
1888
+ "key": "DELETE",
1889
+ "name": "DELETE",
1890
+ "payload": [
1891
+ {
1892
+ "name": "id",
1893
+ "type": "string",
1894
+ "required": true
1895
+ },
1896
+ {
1897
+ "name": "row",
1898
+ "type": "object"
1899
+ }
1900
+ ]
1901
+ }
1902
+ ],
1903
+ "transitions": [
1904
+ {
1905
+ "from": "browsing",
2828
1906
  "to": "browsing",
2829
- "event": "CLOSE",
1907
+ "event": "INIT",
2830
1908
  "effects": [
2831
1909
  [
2832
- "render-ui",
2833
- "modal",
2834
- null
2835
- ],
2836
- [
2837
- "fetch",
1910
+ "ref",
2838
1911
  "Category"
2839
1912
  ],
2840
1913
  [
@@ -2976,6 +2049,9 @@
2976
2049
  "linkedEntity": "Category",
2977
2050
  "category": "interaction",
2978
2051
  "emits": [
2052
+ {
2053
+ "event": "SAVE"
2054
+ },
2979
2055
  {
2980
2056
  "event": "CATEGORY_CREATED"
2981
2057
  }
@@ -3119,10 +2195,6 @@
3119
2195
  [
3120
2196
  "emit",
3121
2197
  "CATEGORY_CREATED"
3122
- ],
3123
- [
3124
- "notify",
3125
- "Category created successfully"
3126
2198
  ]
3127
2199
  ]
3128
2200
  }
@@ -3134,6 +2206,9 @@
3134
2206
  "linkedEntity": "Category",
3135
2207
  "category": "interaction",
3136
2208
  "emits": [
2209
+ {
2210
+ "event": "SAVE"
2211
+ },
3137
2212
  {
3138
2213
  "event": "CATEGORY_UPDATED"
3139
2214
  }
@@ -3288,10 +2363,6 @@
3288
2363
  [
3289
2364
  "emit",
3290
2365
  "CATEGORY_UPDATED"
3291
- ],
3292
- [
3293
- "notify",
3294
- "Category updated successfully"
3295
2366
  ]
3296
2367
  ]
3297
2368
  }
@@ -3302,6 +2373,11 @@
3302
2373
  "name": "CategoryView",
3303
2374
  "linkedEntity": "Category",
3304
2375
  "category": "interaction",
2376
+ "emits": [
2377
+ {
2378
+ "event": "SAVE"
2379
+ }
2380
+ ],
3305
2381
  "stateMachine": {
3306
2382
  "states": [
3307
2383
  {
@@ -3331,6 +2407,17 @@
3331
2407
  {
3332
2408
  "key": "CLOSE",
3333
2409
  "name": "Close"
2410
+ },
2411
+ {
2412
+ "key": "SAVE",
2413
+ "name": "Save",
2414
+ "payload": [
2415
+ {
2416
+ "name": "data",
2417
+ "type": "object",
2418
+ "required": true
2419
+ }
2420
+ ]
3334
2421
  }
3335
2422
  ],
3336
2423
  "transitions": [
@@ -3516,6 +2603,219 @@
3516
2603
  "info"
3517
2604
  ]
3518
2605
  ]
2606
+ },
2607
+ {
2608
+ "from": "open",
2609
+ "to": "closed",
2610
+ "event": "SAVE",
2611
+ "effects": [
2612
+ [
2613
+ "render-ui",
2614
+ "modal",
2615
+ null
2616
+ ]
2617
+ ]
2618
+ }
2619
+ ]
2620
+ }
2621
+ },
2622
+ {
2623
+ "name": "CategoryDelete",
2624
+ "linkedEntity": "Category",
2625
+ "category": "interaction",
2626
+ "emits": [
2627
+ {
2628
+ "event": "CONFIRM_DELETE"
2629
+ },
2630
+ {
2631
+ "event": "CATEGORY_DELETED"
2632
+ }
2633
+ ],
2634
+ "stateMachine": {
2635
+ "states": [
2636
+ {
2637
+ "name": "idle",
2638
+ "isInitial": true
2639
+ },
2640
+ {
2641
+ "name": "confirming"
2642
+ }
2643
+ ],
2644
+ "events": [
2645
+ {
2646
+ "key": "INIT",
2647
+ "name": "Initialize"
2648
+ },
2649
+ {
2650
+ "key": "DELETE",
2651
+ "name": "Request Confirmation",
2652
+ "payload": [
2653
+ {
2654
+ "name": "id",
2655
+ "type": "string",
2656
+ "required": true
2657
+ }
2658
+ ]
2659
+ },
2660
+ {
2661
+ "key": "CONFIRM_DELETE",
2662
+ "name": "Confirm"
2663
+ },
2664
+ {
2665
+ "key": "CANCEL",
2666
+ "name": "Cancel"
2667
+ },
2668
+ {
2669
+ "key": "CLOSE",
2670
+ "name": "Close"
2671
+ }
2672
+ ],
2673
+ "transitions": [
2674
+ {
2675
+ "from": "idle",
2676
+ "to": "idle",
2677
+ "event": "INIT",
2678
+ "effects": [
2679
+ [
2680
+ "ref",
2681
+ "Category"
2682
+ ]
2683
+ ]
2684
+ },
2685
+ {
2686
+ "from": "idle",
2687
+ "to": "confirming",
2688
+ "event": "DELETE",
2689
+ "effects": [
2690
+ [
2691
+ "set",
2692
+ "@entity.pendingId",
2693
+ "@payload.id"
2694
+ ],
2695
+ [
2696
+ "fetch",
2697
+ "Category",
2698
+ {
2699
+ "id": "@payload.id"
2700
+ }
2701
+ ],
2702
+ [
2703
+ "render-ui",
2704
+ "modal",
2705
+ {
2706
+ "type": "stack",
2707
+ "direction": "vertical",
2708
+ "gap": "md",
2709
+ "children": [
2710
+ {
2711
+ "type": "stack",
2712
+ "direction": "horizontal",
2713
+ "gap": "sm",
2714
+ "align": "center",
2715
+ "children": [
2716
+ {
2717
+ "type": "icon",
2718
+ "name": "alert-triangle",
2719
+ "size": "md"
2720
+ },
2721
+ {
2722
+ "type": "typography",
2723
+ "content": "Delete Category",
2724
+ "variant": "h3"
2725
+ }
2726
+ ]
2727
+ },
2728
+ {
2729
+ "type": "divider"
2730
+ },
2731
+ {
2732
+ "type": "alert",
2733
+ "variant": "danger",
2734
+ "message": "This action cannot be undone."
2735
+ },
2736
+ {
2737
+ "type": "stack",
2738
+ "direction": "horizontal",
2739
+ "gap": "sm",
2740
+ "justify": "end",
2741
+ "children": [
2742
+ {
2743
+ "type": "button",
2744
+ "label": "Cancel",
2745
+ "event": "CANCEL",
2746
+ "variant": "ghost"
2747
+ },
2748
+ {
2749
+ "type": "button",
2750
+ "label": "Delete",
2751
+ "event": "CONFIRM_DELETE",
2752
+ "variant": "danger",
2753
+ "icon": "check"
2754
+ }
2755
+ ]
2756
+ }
2757
+ ]
2758
+ }
2759
+ ]
2760
+ ]
2761
+ },
2762
+ {
2763
+ "from": "confirming",
2764
+ "to": "idle",
2765
+ "event": "CONFIRM_DELETE",
2766
+ "effects": [
2767
+ [
2768
+ "persist",
2769
+ "delete",
2770
+ "Category",
2771
+ "@entity.pendingId"
2772
+ ],
2773
+ [
2774
+ "render-ui",
2775
+ "modal",
2776
+ null
2777
+ ],
2778
+ [
2779
+ "ref",
2780
+ "Category"
2781
+ ],
2782
+ [
2783
+ "emit",
2784
+ "CATEGORY_DELETED"
2785
+ ]
2786
+ ]
2787
+ },
2788
+ {
2789
+ "from": "confirming",
2790
+ "to": "idle",
2791
+ "event": "CANCEL",
2792
+ "effects": [
2793
+ [
2794
+ "render-ui",
2795
+ "modal",
2796
+ null
2797
+ ],
2798
+ [
2799
+ "ref",
2800
+ "Category"
2801
+ ]
2802
+ ]
2803
+ },
2804
+ {
2805
+ "from": "confirming",
2806
+ "to": "idle",
2807
+ "event": "CLOSE",
2808
+ "effects": [
2809
+ [
2810
+ "render-ui",
2811
+ "modal",
2812
+ null
2813
+ ],
2814
+ [
2815
+ "ref",
2816
+ "Category"
2817
+ ]
2818
+ ]
3519
2819
  }
3520
2820
  ]
3521
2821
  }
@@ -3537,11 +2837,13 @@
3537
2837
  },
3538
2838
  {
3539
2839
  "ref": "CategoryView"
2840
+ },
2841
+ {
2842
+ "ref": "CategoryDelete"
3540
2843
  }
3541
2844
  ]
3542
2845
  }
3543
2846
  ]
3544
2847
  }
3545
- ],
3546
- "description": "Content management organism. Composes molecules via compose: - stdList(Article): article management with CRUD - stdDetail(MediaAsset): media library browse + view - stdList(Category): category management Cross-orbital connections: - PUBLISH: ArticleBrowse -> MediaAssetBrowse - CATEGORIZE: ArticleBrowse -> CategoryBrowse"
3547
- }
2848
+ ]
2849
+ }