@dxos/app-framework 0.8.4-main.69d29f4 → 0.8.4-main.6fa680abb7

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 (363) hide show
  1. package/.storybook/main.mts +1 -3
  2. package/dist/lib/browser/{capability-7PCNSWBT.mjs → capability-6YMUBS54.mjs} +15 -11
  3. package/dist/lib/browser/capability-6YMUBS54.mjs.map +7 -0
  4. package/dist/lib/browser/capability-LF3OXSCV.mjs +34 -0
  5. package/dist/lib/browser/capability-LF3OXSCV.mjs.map +7 -0
  6. package/dist/lib/browser/{chunk-PKQT6C53.mjs → chunk-272IPLHQ.mjs} +1 -1
  7. package/dist/lib/browser/{chunk-PKQT6C53.mjs.map → chunk-272IPLHQ.mjs.map} +1 -1
  8. package/dist/lib/browser/{chunk-FMZN33N4.mjs → chunk-2UI6ACB5.mjs} +48 -31
  9. package/dist/lib/browser/chunk-2UI6ACB5.mjs.map +7 -0
  10. package/dist/lib/browser/{chunk-TCLLRCS3.mjs → chunk-7M4467QR.mjs} +6 -6
  11. package/dist/lib/browser/chunk-7M4467QR.mjs.map +7 -0
  12. package/dist/lib/browser/{chunk-7IQHKD4U.mjs → chunk-JGWCBVKJ.mjs} +2 -2
  13. package/dist/lib/browser/chunk-JGWCBVKJ.mjs.map +7 -0
  14. package/dist/lib/browser/chunk-M5IC326L.mjs +34 -0
  15. package/dist/lib/browser/chunk-M5IC326L.mjs.map +7 -0
  16. package/dist/lib/browser/{chunk-XYNO72GQ.mjs → chunk-NQPYE365.mjs} +435 -478
  17. package/dist/lib/browser/chunk-NQPYE365.mjs.map +7 -0
  18. package/dist/lib/browser/chunk-TGX63LTL.mjs +8 -0
  19. package/dist/lib/browser/{chunk-FHQTHCX7.mjs.map → chunk-TGX63LTL.mjs.map} +1 -1
  20. package/dist/lib/browser/chunk-TIEBZMTF.mjs +44 -0
  21. package/dist/lib/browser/chunk-TIEBZMTF.mjs.map +7 -0
  22. package/dist/lib/browser/chunk-WEBSGU5L.mjs +80 -0
  23. package/dist/lib/browser/chunk-WEBSGU5L.mjs.map +7 -0
  24. package/dist/lib/browser/chunk-YAFEA4GV.mjs +1 -0
  25. package/dist/lib/browser/{chunk-6Y7PZV72.mjs → chunk-YNFPIQGB.mjs} +2 -3
  26. package/dist/lib/browser/{chunk-6Y7PZV72.mjs.map → chunk-YNFPIQGB.mjs.map} +3 -3
  27. package/dist/lib/browser/cli/index.mjs +89 -0
  28. package/dist/lib/browser/cli/index.mjs.map +7 -0
  29. package/dist/lib/browser/common/activation-events.mjs +23 -0
  30. package/dist/lib/browser/common/capabilities.mjs +45 -0
  31. package/dist/lib/browser/core/activation-event.mjs +1 -1
  32. package/dist/lib/browser/core/capability.mjs +1 -1
  33. package/dist/lib/browser/core/plugin-manager.mjs +4 -4
  34. package/dist/lib/browser/core/plugin.mjs +2 -2
  35. package/dist/lib/browser/index.mjs +37 -132
  36. package/dist/lib/browser/index.mjs.map +4 -4
  37. package/dist/lib/browser/{invoker-capability-SZRSTHEH.mjs → invoker-capability-4AUGUMM5.mjs} +16 -12
  38. package/dist/lib/browser/invoker-capability-4AUGUMM5.mjs.map +7 -0
  39. package/dist/lib/browser/meta.json +1 -1
  40. package/dist/lib/browser/testing/index.mjs +28 -20
  41. package/dist/lib/browser/testing/index.mjs.map +3 -3
  42. package/dist/lib/browser/{react → ui}/index.mjs +18 -19
  43. package/dist/lib/node-esm/{capability-CFLQ2QQU.mjs → capability-R5O2OYX4.mjs} +15 -11
  44. package/dist/lib/node-esm/capability-R5O2OYX4.mjs.map +7 -0
  45. package/dist/lib/node-esm/capability-SA6LPYGL.mjs +35 -0
  46. package/dist/lib/node-esm/capability-SA6LPYGL.mjs.map +7 -0
  47. package/dist/lib/node-esm/{chunk-663A54LQ.mjs → chunk-3D66SZHP.mjs} +2 -2
  48. package/dist/lib/node-esm/chunk-3D66SZHP.mjs.map +7 -0
  49. package/dist/lib/node-esm/{chunk-7OWSHPYK.mjs → chunk-6REV5DE7.mjs} +1 -1
  50. package/dist/lib/node-esm/{chunk-7OWSHPYK.mjs.map → chunk-6REV5DE7.mjs.map} +1 -1
  51. package/dist/lib/node-esm/{chunk-6WXBT3EC.mjs → chunk-FHWPWQRJ.mjs} +435 -478
  52. package/dist/lib/node-esm/chunk-FHWPWQRJ.mjs.map +7 -0
  53. package/dist/lib/node-esm/{chunk-UEWJDI2L.mjs → chunk-FKE4Z3D6.mjs} +2 -2
  54. package/dist/lib/node-esm/{chunk-UEWJDI2L.mjs.map → chunk-FKE4Z3D6.mjs.map} +1 -1
  55. package/dist/lib/node-esm/{chunk-GT6OKM5I.mjs → chunk-JHFY3HTS.mjs} +6 -6
  56. package/dist/lib/node-esm/chunk-JHFY3HTS.mjs.map +7 -0
  57. package/dist/lib/node-esm/{chunk-XYQTBFPA.mjs → chunk-JIVXIJ2T.mjs} +48 -31
  58. package/dist/lib/node-esm/chunk-JIVXIJ2T.mjs.map +7 -0
  59. package/dist/lib/node-esm/chunk-NHXBSAQR.mjs +35 -0
  60. package/dist/lib/node-esm/chunk-NHXBSAQR.mjs.map +7 -0
  61. package/dist/lib/node-esm/{chunk-STMXUEPO.mjs → chunk-SB5ODNPX.mjs} +2 -3
  62. package/dist/lib/node-esm/{chunk-STMXUEPO.mjs.map → chunk-SB5ODNPX.mjs.map} +3 -3
  63. package/dist/lib/node-esm/chunk-SCDGIGGU.mjs +45 -0
  64. package/dist/lib/node-esm/chunk-SCDGIGGU.mjs.map +7 -0
  65. package/dist/lib/node-esm/chunk-SQICGJBW.mjs +81 -0
  66. package/dist/lib/node-esm/chunk-SQICGJBW.mjs.map +7 -0
  67. package/dist/lib/node-esm/chunk-Z4TJPSMP.mjs +2 -0
  68. package/dist/lib/node-esm/chunk-Z4TJPSMP.mjs.map +7 -0
  69. package/dist/lib/node-esm/cli/index.mjs +90 -0
  70. package/dist/lib/node-esm/cli/index.mjs.map +7 -0
  71. package/dist/lib/node-esm/common/activation-events.mjs +24 -0
  72. package/dist/lib/node-esm/common/activation-events.mjs.map +7 -0
  73. package/dist/lib/node-esm/common/capabilities.mjs +46 -0
  74. package/dist/lib/node-esm/common/capabilities.mjs.map +7 -0
  75. package/dist/lib/node-esm/core/activation-event.mjs +1 -1
  76. package/dist/lib/node-esm/core/capability.mjs +1 -1
  77. package/dist/lib/node-esm/core/plugin-manager.mjs +4 -4
  78. package/dist/lib/node-esm/core/plugin.mjs +2 -2
  79. package/dist/lib/node-esm/index.mjs +37 -132
  80. package/dist/lib/node-esm/index.mjs.map +4 -4
  81. package/dist/lib/node-esm/{invoker-capability-PNMA5JOS.mjs → invoker-capability-3YDIVDWV.mjs} +16 -12
  82. package/dist/lib/node-esm/invoker-capability-3YDIVDWV.mjs.map +7 -0
  83. package/dist/lib/node-esm/meta.json +1 -1
  84. package/dist/lib/node-esm/testing/index.mjs +28 -20
  85. package/dist/lib/node-esm/testing/index.mjs.map +3 -3
  86. package/dist/lib/node-esm/{react → ui}/index.mjs +18 -19
  87. package/dist/lib/node-esm/ui/index.mjs.map +7 -0
  88. package/dist/types/src/{cli.d.ts → cli/cli.d.ts} +2 -2
  89. package/dist/types/src/cli/cli.d.ts.map +1 -0
  90. package/dist/types/src/cli/index.d.ts +2 -0
  91. package/dist/types/src/cli/index.d.ts.map +1 -0
  92. package/dist/types/src/common/activation-events.d.ts +27 -0
  93. package/dist/types/src/common/activation-events.d.ts.map +1 -0
  94. package/dist/types/src/common/capabilities.d.ts +115 -0
  95. package/dist/types/src/common/capabilities.d.ts.map +1 -0
  96. package/dist/types/src/common/index.d.ts +4 -9
  97. package/dist/types/src/common/index.d.ts.map +1 -1
  98. package/dist/types/src/common/operations.d.ts +1 -348
  99. package/dist/types/src/common/operations.d.ts.map +1 -1
  100. package/dist/types/src/common/translations.d.ts +0 -9
  101. package/dist/types/src/common/translations.d.ts.map +1 -1
  102. package/dist/types/src/core/activation-event.d.ts +1 -1
  103. package/dist/types/src/core/capability.d.ts +7 -7
  104. package/dist/types/src/core/capability.d.ts.map +1 -1
  105. package/dist/types/src/core/plugin-manager.d.ts.map +1 -1
  106. package/dist/types/src/core/plugin.d.ts +1 -1
  107. package/dist/types/src/core/plugin.d.ts.map +1 -1
  108. package/dist/types/src/index.d.ts +1 -3
  109. package/dist/types/src/index.d.ts.map +1 -1
  110. package/dist/types/src/plugin-operation/history/capability.d.ts +1 -1
  111. package/dist/types/src/plugin-operation/history/undo-mapping.d.ts +11 -3
  112. package/dist/types/src/plugin-operation/history/undo-mapping.d.ts.map +1 -1
  113. package/dist/types/src/plugin-operation/invoker-capability.d.ts +1 -1
  114. package/dist/types/src/plugin-runtime/capability.d.ts +2 -2
  115. package/dist/types/src/plugin-runtime/capability.d.ts.map +1 -1
  116. package/dist/types/src/testing/withPluginManager.d.ts +1 -1
  117. package/dist/types/src/testing/withPluginManager.d.ts.map +1 -1
  118. package/dist/types/src/{react → ui/components/App}/App.d.ts +1 -1
  119. package/dist/types/src/ui/components/App/App.d.ts.map +1 -0
  120. package/dist/types/src/{react/Surface.stories.d.ts → ui/components/App/App.stories.d.ts} +7 -2
  121. package/dist/types/src/ui/components/App/App.stories.d.ts.map +1 -0
  122. package/dist/types/src/ui/components/App/index.d.ts +2 -0
  123. package/dist/types/src/ui/components/App/index.d.ts.map +1 -0
  124. package/dist/types/src/ui/components/PluginManager/PluginManagerContext.stories.d.ts.map +1 -0
  125. package/dist/types/src/{react → ui/components/PluginManager}/PluginManagerProvider.d.ts +1 -1
  126. package/dist/types/src/ui/components/PluginManager/PluginManagerProvider.d.ts.map +1 -0
  127. package/dist/types/src/ui/components/PluginManager/index.d.ts +2 -0
  128. package/dist/types/src/ui/components/PluginManager/index.d.ts.map +1 -0
  129. package/dist/types/src/ui/components/Surface/SurfaceComponent.d.ts +12 -0
  130. package/dist/types/src/ui/components/Surface/SurfaceComponent.d.ts.map +1 -0
  131. package/dist/types/src/{react/App.stories.d.ts → ui/components/Surface/SurfaceComponent.stories.d.ts} +1 -1
  132. package/dist/types/src/ui/components/Surface/SurfaceComponent.stories.d.ts.map +1 -0
  133. package/dist/types/src/ui/components/Surface/SurfaceInfo.d.ts.map +1 -0
  134. package/dist/types/src/ui/components/Surface/context.d.ts +5 -0
  135. package/dist/types/src/ui/components/Surface/context.d.ts.map +1 -0
  136. package/dist/types/src/ui/components/Surface/index.d.ts +20 -0
  137. package/dist/types/src/ui/components/Surface/index.d.ts.map +1 -0
  138. package/dist/types/src/{common/surface.d.ts → ui/components/Surface/types.d.ts} +20 -18
  139. package/dist/types/src/ui/components/Surface/types.d.ts.map +1 -0
  140. package/dist/types/src/ui/components/index.d.ts +4 -0
  141. package/dist/types/src/ui/components/index.d.ts.map +1 -0
  142. package/dist/types/src/ui/hooks/index.d.ts +7 -0
  143. package/dist/types/src/ui/hooks/index.d.ts.map +1 -0
  144. package/dist/types/src/{react → ui/hooks}/useApp.d.ts +14 -9
  145. package/dist/types/src/ui/hooks/useApp.d.ts.map +1 -0
  146. package/dist/types/src/{react → ui/hooks}/useCapabilities.d.ts +6 -1
  147. package/dist/types/src/ui/hooks/useCapabilities.d.ts.map +1 -0
  148. package/dist/types/src/ui/hooks/useLoading.d.ts.map +1 -0
  149. package/dist/types/src/{react → ui/hooks}/useOperationResolver.d.ts +2 -2
  150. package/dist/types/src/ui/hooks/useOperationResolver.d.ts.map +1 -0
  151. package/dist/types/src/{react/common.d.ts → ui/hooks/useSettingsState.d.ts} +1 -5
  152. package/dist/types/src/ui/hooks/useSettingsState.d.ts.map +1 -0
  153. package/dist/types/src/ui/hooks/useSurface.d.ts +3 -0
  154. package/dist/types/src/ui/hooks/useSurface.d.ts.map +1 -0
  155. package/dist/types/src/ui/index.d.ts +3 -0
  156. package/dist/types/src/ui/index.d.ts.map +1 -0
  157. package/dist/types/tsconfig.tsbuildinfo +1 -1
  158. package/moon.yml +6 -6
  159. package/package.json +72 -64
  160. package/src/{cli.ts → cli/cli.ts} +10 -10
  161. package/src/{playground/debug → cli}/index.ts +1 -1
  162. package/src/common/activation-events.ts +44 -0
  163. package/src/common/capabilities.ts +178 -0
  164. package/src/common/index.ts +4 -9
  165. package/src/common/operations.ts +2 -376
  166. package/src/common/translations.ts +0 -12
  167. package/src/context.ts +1 -1
  168. package/src/core/activation-event.ts +1 -1
  169. package/src/core/capability.ts +9 -9
  170. package/src/core/plugin-manager.test.ts +44 -44
  171. package/src/core/plugin-manager.ts +19 -0
  172. package/src/core/plugin.ts +3 -2
  173. package/src/index.ts +1 -3
  174. package/src/plugin-operation/OperationPlugin.ts +5 -5
  175. package/src/plugin-operation/history/capability.ts +5 -5
  176. package/src/plugin-operation/history/undo-mapping.ts +6 -3
  177. package/src/plugin-operation/invoker-capability.ts +5 -5
  178. package/src/plugin-operation/meta.ts +1 -1
  179. package/src/plugin-runtime/RuntimePlugin.ts +4 -4
  180. package/src/plugin-runtime/capability.ts +5 -5
  181. package/src/plugin-runtime/meta.ts +1 -1
  182. package/src/testing/service.ts +6 -6
  183. package/src/testing/withPluginManager.stories.tsx +6 -6
  184. package/src/testing/withPluginManager.tsx +11 -8
  185. package/src/ui/components/App/App.stories.tsx +92 -0
  186. package/src/{react → ui/components/App}/App.tsx +6 -9
  187. package/src/{playground/layout → ui/components/App}/index.ts +1 -1
  188. package/src/{react → ui/components/PluginManager}/PluginManagerContext.stories.tsx +13 -14
  189. package/src/{react → ui/components/PluginManager}/PluginManagerProvider.ts +1 -1
  190. package/src/ui/components/PluginManager/index.ts +5 -0
  191. package/src/{react/Surface.stories.tsx → ui/components/Surface/SurfaceComponent.stories.tsx} +18 -16
  192. package/src/{react/Surface.tsx → ui/components/Surface/SurfaceComponent.tsx} +36 -56
  193. package/src/{react → ui/components/Surface}/SurfaceInfo.tsx +2 -2
  194. package/src/ui/components/Surface/context.ts +12 -0
  195. package/src/ui/components/Surface/index.ts +20 -0
  196. package/src/{common/surface.ts → ui/components/Surface/types.ts} +22 -25
  197. package/src/ui/components/index.ts +7 -0
  198. package/src/ui/hooks/index.ts +10 -0
  199. package/src/{react → ui/hooks}/useApp.tsx +29 -25
  200. package/src/{react → ui/hooks}/useCapabilities.ts +9 -5
  201. package/src/{react → ui/hooks}/useOperationResolver.ts +5 -5
  202. package/src/{react/common.ts → ui/hooks/useSettingsState.ts} +0 -11
  203. package/src/ui/hooks/useSurface.ts +13 -0
  204. package/src/ui/index.ts +6 -0
  205. package/tsconfig.json +2 -29
  206. package/tsconfig.node.json +1 -3
  207. package/typedoc.json +2 -4
  208. package/dist/lib/browser/app-graph-builder-M2VPYQC6.mjs +0 -149
  209. package/dist/lib/browser/app-graph-builder-M2VPYQC6.mjs.map +0 -7
  210. package/dist/lib/browser/capability-7PCNSWBT.mjs.map +0 -7
  211. package/dist/lib/browser/capability-KP3PFEXD.mjs +0 -31
  212. package/dist/lib/browser/capability-KP3PFEXD.mjs.map +0 -7
  213. package/dist/lib/browser/chunk-7IQHKD4U.mjs.map +0 -7
  214. package/dist/lib/browser/chunk-BLQJSGL3.mjs +0 -732
  215. package/dist/lib/browser/chunk-BLQJSGL3.mjs.map +0 -7
  216. package/dist/lib/browser/chunk-FHQTHCX7.mjs +0 -8
  217. package/dist/lib/browser/chunk-FMZN33N4.mjs.map +0 -7
  218. package/dist/lib/browser/chunk-H4WPA7U7.mjs +0 -77
  219. package/dist/lib/browser/chunk-H4WPA7U7.mjs.map +0 -7
  220. package/dist/lib/browser/chunk-TCLLRCS3.mjs.map +0 -7
  221. package/dist/lib/browser/chunk-XYNO72GQ.mjs.map +0 -7
  222. package/dist/lib/browser/common/index.mjs +0 -38
  223. package/dist/lib/browser/invoker-capability-SZRSTHEH.mjs.map +0 -7
  224. package/dist/lib/browser/operation-resolver-6MP2MYOY.mjs +0 -64
  225. package/dist/lib/browser/operation-resolver-6MP2MYOY.mjs.map +0 -7
  226. package/dist/lib/node-esm/app-graph-builder-LROHGJEM.mjs +0 -150
  227. package/dist/lib/node-esm/app-graph-builder-LROHGJEM.mjs.map +0 -7
  228. package/dist/lib/node-esm/capability-CFLQ2QQU.mjs.map +0 -7
  229. package/dist/lib/node-esm/capability-RCUNM2M7.mjs +0 -32
  230. package/dist/lib/node-esm/capability-RCUNM2M7.mjs.map +0 -7
  231. package/dist/lib/node-esm/chunk-663A54LQ.mjs.map +0 -7
  232. package/dist/lib/node-esm/chunk-6WXBT3EC.mjs.map +0 -7
  233. package/dist/lib/node-esm/chunk-GQEBIGKD.mjs +0 -733
  234. package/dist/lib/node-esm/chunk-GQEBIGKD.mjs.map +0 -7
  235. package/dist/lib/node-esm/chunk-GT6OKM5I.mjs.map +0 -7
  236. package/dist/lib/node-esm/chunk-XR6NMKEP.mjs +0 -78
  237. package/dist/lib/node-esm/chunk-XR6NMKEP.mjs.map +0 -7
  238. package/dist/lib/node-esm/chunk-XYQTBFPA.mjs.map +0 -7
  239. package/dist/lib/node-esm/common/index.mjs +0 -39
  240. package/dist/lib/node-esm/invoker-capability-PNMA5JOS.mjs.map +0 -7
  241. package/dist/lib/node-esm/operation-resolver-7YWDMTNU.mjs +0 -65
  242. package/dist/lib/node-esm/operation-resolver-7YWDMTNU.mjs.map +0 -7
  243. package/dist/types/src/cli.d.ts.map +0 -1
  244. package/dist/types/src/common/activation-event.d.ts +0 -66
  245. package/dist/types/src/common/activation-event.d.ts.map +0 -1
  246. package/dist/types/src/common/capability.d.ts +0 -265
  247. package/dist/types/src/common/capability.d.ts.map +0 -1
  248. package/dist/types/src/common/collaboration.d.ts +0 -26
  249. package/dist/types/src/common/collaboration.d.ts.map +0 -1
  250. package/dist/types/src/common/file.d.ts +0 -14
  251. package/dist/types/src/common/file.d.ts.map +0 -1
  252. package/dist/types/src/common/graph.d.ts +0 -21
  253. package/dist/types/src/common/graph.d.ts.map +0 -1
  254. package/dist/types/src/common/plugin.d.ts +0 -201
  255. package/dist/types/src/common/plugin.d.ts.map +0 -1
  256. package/dist/types/src/common/surface.d.ts.map +0 -1
  257. package/dist/types/src/playground/debug/Debug.d.ts +0 -8
  258. package/dist/types/src/playground/debug/Debug.d.ts.map +0 -1
  259. package/dist/types/src/playground/debug/index.d.ts +0 -2
  260. package/dist/types/src/playground/debug/index.d.ts.map +0 -1
  261. package/dist/types/src/playground/debug/plugin.d.ts +0 -3
  262. package/dist/types/src/playground/debug/plugin.d.ts.map +0 -1
  263. package/dist/types/src/playground/generator/Main.d.ts +0 -8
  264. package/dist/types/src/playground/generator/Main.d.ts.map +0 -1
  265. package/dist/types/src/playground/generator/Toolbar.d.ts +0 -8
  266. package/dist/types/src/playground/generator/Toolbar.d.ts.map +0 -1
  267. package/dist/types/src/playground/generator/generator.d.ts +0 -19
  268. package/dist/types/src/playground/generator/generator.d.ts.map +0 -1
  269. package/dist/types/src/playground/generator/index.d.ts +0 -3
  270. package/dist/types/src/playground/generator/index.d.ts.map +0 -1
  271. package/dist/types/src/playground/generator/plugin.d.ts +0 -3
  272. package/dist/types/src/playground/generator/plugin.d.ts.map +0 -1
  273. package/dist/types/src/playground/layout/Layout.d.ts +0 -10
  274. package/dist/types/src/playground/layout/Layout.d.ts.map +0 -1
  275. package/dist/types/src/playground/layout/index.d.ts +0 -2
  276. package/dist/types/src/playground/layout/index.d.ts.map +0 -1
  277. package/dist/types/src/playground/layout/plugin.d.ts +0 -3
  278. package/dist/types/src/playground/layout/plugin.d.ts.map +0 -1
  279. package/dist/types/src/playground/logger/Toolbar.d.ts +0 -8
  280. package/dist/types/src/playground/logger/Toolbar.d.ts.map +0 -1
  281. package/dist/types/src/playground/logger/index.d.ts +0 -2
  282. package/dist/types/src/playground/logger/index.d.ts.map +0 -1
  283. package/dist/types/src/playground/logger/plugin.d.ts +0 -3
  284. package/dist/types/src/playground/logger/plugin.d.ts.map +0 -1
  285. package/dist/types/src/playground/logger/schema.d.ts +0 -27
  286. package/dist/types/src/playground/logger/schema.d.ts.map +0 -1
  287. package/dist/types/src/playground/playground.stories.d.ts +0 -11
  288. package/dist/types/src/playground/playground.stories.d.ts.map +0 -1
  289. package/dist/types/src/plugin-settings/SettingsPlugin.d.ts +0 -3
  290. package/dist/types/src/plugin-settings/SettingsPlugin.d.ts.map +0 -1
  291. package/dist/types/src/plugin-settings/actions.d.ts +0 -61
  292. package/dist/types/src/plugin-settings/actions.d.ts.map +0 -1
  293. package/dist/types/src/plugin-settings/app-graph-builder.d.ts +0 -6
  294. package/dist/types/src/plugin-settings/app-graph-builder.d.ts.map +0 -1
  295. package/dist/types/src/plugin-settings/index.d.ts +0 -3
  296. package/dist/types/src/plugin-settings/index.d.ts.map +0 -1
  297. package/dist/types/src/plugin-settings/meta.d.ts +0 -3
  298. package/dist/types/src/plugin-settings/meta.d.ts.map +0 -1
  299. package/dist/types/src/plugin-settings/operation-resolver.d.ts +0 -6
  300. package/dist/types/src/plugin-settings/operation-resolver.d.ts.map +0 -1
  301. package/dist/types/src/plugin-settings/translations.d.ts +0 -11
  302. package/dist/types/src/plugin-settings/translations.d.ts.map +0 -1
  303. package/dist/types/src/react/App.d.ts.map +0 -1
  304. package/dist/types/src/react/App.stories.d.ts.map +0 -1
  305. package/dist/types/src/react/DefaultFallback.d.ts +0 -8
  306. package/dist/types/src/react/DefaultFallback.d.ts.map +0 -1
  307. package/dist/types/src/react/ErrorBoundary.d.ts +0 -30
  308. package/dist/types/src/react/ErrorBoundary.d.ts.map +0 -1
  309. package/dist/types/src/react/PluginManagerContext.stories.d.ts.map +0 -1
  310. package/dist/types/src/react/PluginManagerProvider.d.ts.map +0 -1
  311. package/dist/types/src/react/Surface.d.ts +0 -14
  312. package/dist/types/src/react/Surface.d.ts.map +0 -1
  313. package/dist/types/src/react/Surface.stories.d.ts.map +0 -1
  314. package/dist/types/src/react/SurfaceInfo.d.ts.map +0 -1
  315. package/dist/types/src/react/common.d.ts.map +0 -1
  316. package/dist/types/src/react/index.d.ts +0 -9
  317. package/dist/types/src/react/index.d.ts.map +0 -1
  318. package/dist/types/src/react/types.d.ts +0 -12
  319. package/dist/types/src/react/types.d.ts.map +0 -1
  320. package/dist/types/src/react/useApp.d.ts.map +0 -1
  321. package/dist/types/src/react/useCapabilities.d.ts.map +0 -1
  322. package/dist/types/src/react/useLoading.d.ts.map +0 -1
  323. package/dist/types/src/react/useOperationResolver.d.ts.map +0 -1
  324. package/src/common/activation-event.ts +0 -99
  325. package/src/common/capability.ts +0 -343
  326. package/src/common/collaboration.ts +0 -31
  327. package/src/common/file.ts +0 -22
  328. package/src/common/graph.ts +0 -30
  329. package/src/common/plugin.ts +0 -364
  330. package/src/playground/debug/Debug.tsx +0 -49
  331. package/src/playground/debug/plugin.ts +0 -16
  332. package/src/playground/generator/Main.tsx +0 -80
  333. package/src/playground/generator/Toolbar.tsx +0 -57
  334. package/src/playground/generator/generator.ts +0 -48
  335. package/src/playground/generator/index.ts +0 -6
  336. package/src/playground/generator/plugin.ts +0 -21
  337. package/src/playground/layout/Layout.tsx +0 -37
  338. package/src/playground/layout/plugin.ts +0 -18
  339. package/src/playground/logger/Toolbar.tsx +0 -33
  340. package/src/playground/logger/index.ts +0 -5
  341. package/src/playground/logger/plugin.ts +0 -42
  342. package/src/playground/logger/schema.ts +0 -22
  343. package/src/playground/playground.stories.tsx +0 -54
  344. package/src/plugin-settings/SettingsPlugin.ts +0 -19
  345. package/src/plugin-settings/actions.ts +0 -64
  346. package/src/plugin-settings/app-graph-builder.ts +0 -140
  347. package/src/plugin-settings/index.ts +0 -6
  348. package/src/plugin-settings/meta.ts +0 -10
  349. package/src/plugin-settings/operation-resolver.ts +0 -55
  350. package/src/plugin-settings/translations.ts +0 -19
  351. package/src/react/App.stories.tsx +0 -63
  352. package/src/react/DefaultFallback.tsx +0 -26
  353. package/src/react/ErrorBoundary.tsx +0 -56
  354. package/src/react/index.ts +0 -14
  355. package/src/react/types.ts +0 -27
  356. /package/dist/lib/{node-esm/react/index.mjs.map → browser/chunk-YAFEA4GV.mjs.map} +0 -0
  357. /package/dist/lib/{node-esm/common/index.mjs.map → browser/common/activation-events.mjs.map} +0 -0
  358. /package/dist/lib/browser/{react/index.mjs.map → common/capabilities.mjs.map} +0 -0
  359. /package/dist/lib/browser/{common → ui}/index.mjs.map +0 -0
  360. /package/dist/types/src/{react → ui/components/PluginManager}/PluginManagerContext.stories.d.ts +0 -0
  361. /package/dist/types/src/{react → ui/components/Surface}/SurfaceInfo.d.ts +0 -0
  362. /package/dist/types/src/{react → ui/hooks}/useLoading.d.ts +0 -0
  363. /package/src/{react → ui/hooks}/useLoading.tsx +0 -0
@@ -15,7 +15,7 @@ import * as TestClock from 'effect/TestClock';
15
15
  import { invariant } from '@dxos/invariant';
16
16
  import { type LogConfig, type LogEntry, LogLevel, log } from '@dxos/log';
17
17
 
18
- import * as Common from '../common';
18
+ import { ActivationEvents } from '../common';
19
19
 
20
20
  import * as ActivationEvent from './activation-event';
21
21
  import * as Capability from './capability';
@@ -23,14 +23,14 @@ import type * as CapabilityManager from './capability-manager';
23
23
  import * as Plugin from './plugin';
24
24
  import * as PluginManager from './plugin-manager';
25
25
 
26
- const String = Capability.make<{ string: string }>('dxos.org/test/string');
27
- const Number = Capability.make<{ number: number }>('dxos.org/test/number');
28
- const Total = Capability.make<{ total: number }>('dxos.org/test/total');
26
+ const String = Capability.make<{ string: string }>('org.dxos.test.string');
27
+ const Number = Capability.make<{ number: number }>('org.dxos.test.number');
28
+ const Total = Capability.make<{ total: number }>('org.dxos.test.total');
29
29
 
30
- const CountEvent = ActivationEvent.make('dxos.org/test/count');
31
- const FailEvent = ActivationEvent.make('dxos.org/test/fail');
30
+ const CountEvent = ActivationEvent.make('org.dxos.test.count');
31
+ const FailEvent = ActivationEvent.make('org.dxos.test.fail');
32
32
 
33
- const testMeta = { id: 'dxos.org/plugin/test', name: 'Test' };
33
+ const testMeta = { id: 'org.dxos.plugin.test', name: 'Test' };
34
34
 
35
35
  // TODO(wittjosiah): Factor out?
36
36
  const atomCounter = (registry: Registry.Registry, atom: Atom.Atom<any>) => {
@@ -89,12 +89,12 @@ describe('PluginManager', () => {
89
89
  const TestPluginFactory = Plugin.define<TestPluginOptions>(testMeta).pipe(
90
90
  Plugin.addModule((options: TestPluginOptions) => ({
91
91
  id: 'Hello',
92
- activatesOn: Common.ActivationEvent.Startup,
92
+ activatesOn: ActivationEvents.Startup,
93
93
  activate: () => Effect.succeed(Capability.contributes(String, { string: `hello-${options.count}` })),
94
94
  })),
95
95
  Plugin.addModule({
96
96
  id: 'World',
97
- activatesOn: Common.ActivationEvent.Startup,
97
+ activatesOn: ActivationEvents.Startup,
98
98
  activate: () => Effect.succeed(Capability.contributes(String, { string: 'world' })),
99
99
  }),
100
100
  Plugin.make,
@@ -105,7 +105,7 @@ describe('PluginManager', () => {
105
105
 
106
106
  const manager = PluginManager.make({ plugins: [plugin], core: [], pluginLoader });
107
107
  yield* manager.enable(testMeta.id);
108
- yield* manager.activate(Common.ActivationEvent.Startup);
108
+ yield* manager.activate(ActivationEvents.Startup);
109
109
  const strings = manager.capabilities.getAll(String);
110
110
  assert.strictEqual(strings.length, 2);
111
111
  assert.strictEqual(strings[0].string, 'hello-5');
@@ -118,7 +118,7 @@ describe('PluginManager', () => {
118
118
  const Test = Plugin.define(testMeta).pipe(
119
119
  Plugin.addModule({
120
120
  id: 'Hello',
121
- activatesOn: Common.ActivationEvent.Startup,
121
+ activatesOn: ActivationEvents.Startup,
122
122
  activate: () => Effect.succeed(Capability.contributes(String, { string: 'hello' })),
123
123
  }),
124
124
  Plugin.make,
@@ -140,7 +140,7 @@ describe('PluginManager', () => {
140
140
  const Test = Plugin.define(testMeta).pipe(
141
141
  Plugin.addModule({
142
142
  id: 'Hello',
143
- activatesOn: Common.ActivationEvent.Startup,
143
+ activatesOn: ActivationEvents.Startup,
144
144
  activate: () => Effect.succeed(Capability.contributes(String, { string: 'hello' })),
145
145
  }),
146
146
  Plugin.make,
@@ -154,9 +154,9 @@ describe('PluginManager', () => {
154
154
  assert.deepStrictEqual(manager.getModules(), [testPlugin.modules[0]]);
155
155
  assert.deepStrictEqual(manager.getActive(), []);
156
156
  assert.deepStrictEqual(manager.getEventsFired(), []);
157
- yield* manager.activate(Common.ActivationEvent.Startup);
157
+ yield* manager.activate(ActivationEvents.Startup);
158
158
  assert.deepStrictEqual(manager.getActive(), [testPlugin.modules[0].id]);
159
- assert.deepStrictEqual(manager.getEventsFired(), [Common.ActivationEvent.Startup.id]);
159
+ assert.deepStrictEqual(manager.getEventsFired(), [ActivationEvents.Startup.id]);
160
160
  }),
161
161
  );
162
162
 
@@ -165,7 +165,7 @@ describe('PluginManager', () => {
165
165
  const Test = Plugin.define(testMeta).pipe(
166
166
  Plugin.addModule({
167
167
  id: 'NoCapabilities',
168
- activatesOn: Common.ActivationEvent.Startup,
168
+ activatesOn: ActivationEvents.Startup,
169
169
  activate: Effect.fnUntraced(function* () {}),
170
170
  }),
171
171
  Plugin.make,
@@ -175,7 +175,7 @@ describe('PluginManager', () => {
175
175
  const manager = PluginManager.make({ plugins: [testPlugin], pluginLoader });
176
176
  yield* manager.enable(Test.meta.id);
177
177
 
178
- const result = yield* manager.activate(Common.ActivationEvent.Startup);
178
+ const result = yield* manager.activate(ActivationEvents.Startup);
179
179
  assert.isTrue(result);
180
180
  assert.deepStrictEqual(manager.getActive(), [testPlugin.modules[0].id]);
181
181
  assert.strictEqual(manager.capabilities.getAll(String).length, 0);
@@ -204,7 +204,7 @@ describe('PluginManager', () => {
204
204
 
205
205
  it.effect('should catch and log defects (synchronous throws) in module activation', () =>
206
206
  Effect.gen(function* () {
207
- const DefectEvent = ActivationEvent.make('dxos.org/test/defect');
207
+ const DefectEvent = ActivationEvent.make('org.dxos.test.defect');
208
208
  const capturedErrors: LogEntry[] = [];
209
209
  const removeProcessor = log.addProcessor((_config: LogConfig, entry: LogEntry) => {
210
210
  if (entry.level === LogLevel.ERROR) {
@@ -238,7 +238,7 @@ describe('PluginManager', () => {
238
238
  const defectLog = capturedErrors.find(
239
239
  (entry) =>
240
240
  entry.message?.includes('module failed to activate') &&
241
- entry.context?.module === 'dxos.org/plugin/test/module/DefectInEffectSync',
241
+ entry.context?.module === 'org.dxos.plugin.test.module.DefectInEffectSync',
242
242
  );
243
243
  assert.isNotNull(defectLog, 'Expected error log for defect');
244
244
  assert.strictEqual(defectLog?.context?.isDefect, true, 'Expected isDefect to be true for synchronous throw');
@@ -249,7 +249,7 @@ describe('PluginManager', () => {
249
249
 
250
250
  it.effect('should catch and log defects when activate throws before returning Effect', () =>
251
251
  Effect.gen(function* () {
252
- const DefectEvent = ActivationEvent.make('dxos.org/test/defect-immediate');
252
+ const DefectEvent = ActivationEvent.make('org.dxos.test.defect-immediate');
253
253
  const capturedErrors: LogEntry[] = [];
254
254
  const removeProcessor = log.addProcessor((_config: LogConfig, entry: LogEntry) => {
255
255
  if (entry.level === LogLevel.ERROR) {
@@ -284,7 +284,7 @@ describe('PluginManager', () => {
284
284
  const defectLog = capturedErrors.find(
285
285
  (entry) =>
286
286
  entry.message?.includes('module failed to activate') &&
287
- entry.context?.module === 'dxos.org/plugin/test/module/DefectImmediate',
287
+ entry.context?.module === 'org.dxos.plugin.test.module.DefectImmediate',
288
288
  );
289
289
  assert.isNotNull(defectLog, 'Expected error log for immediate defect');
290
290
  assert.strictEqual(
@@ -303,7 +303,7 @@ describe('PluginManager', () => {
303
303
  Plugin.define(testMeta).pipe(
304
304
  Plugin.addModule({
305
305
  id: 'Hello',
306
- activatesOn: Common.ActivationEvent.Startup,
306
+ activatesOn: ActivationEvents.Startup,
307
307
  activate: () => Effect.succeed(Capability.contributes(String, { string: 'hello' })),
308
308
  }),
309
309
  Plugin.addModule({
@@ -339,7 +339,7 @@ describe('PluginManager', () => {
339
339
  );
340
340
 
341
341
  yield* manager.add(testMeta.id);
342
- yield* manager.activate(Common.ActivationEvent.Startup);
342
+ yield* manager.activate(ActivationEvents.Startup);
343
343
  yield* activating.await;
344
344
  yield* activated.await;
345
345
 
@@ -374,7 +374,7 @@ describe('PluginManager', () => {
374
374
  const Test = Plugin.define(testMeta).pipe(
375
375
  Plugin.addModule({
376
376
  id: 'Hello',
377
- activatesOn: Common.ActivationEvent.Startup,
377
+ activatesOn: ActivationEvents.Startup,
378
378
  activate: () => {
379
379
  count++;
380
380
  return Effect.succeed(Capability.contributes(String, { string: 'hello' }));
@@ -389,19 +389,19 @@ describe('PluginManager', () => {
389
389
 
390
390
  {
391
391
  yield* manager.add(testMeta.id);
392
- const result = yield* manager.activate(Common.ActivationEvent.Startup);
392
+ const result = yield* manager.activate(ActivationEvents.Startup);
393
393
  assert.isTrue(result);
394
394
  assert.deepStrictEqual(manager.getActive(), [testPlugin.modules[0].id]);
395
395
  assert.strictEqual(count, 1);
396
396
  }
397
397
 
398
398
  {
399
- const result = yield* manager.activate(Common.ActivationEvent.Startup);
399
+ const result = yield* manager.activate(ActivationEvents.Startup);
400
400
  assert.isFalse(result);
401
401
  }
402
402
 
403
403
  {
404
- const result = yield* manager.reset(Common.ActivationEvent.Startup);
404
+ const result = yield* manager.reset(ActivationEvents.Startup);
405
405
  assert.isTrue(result);
406
406
  assert.strictEqual(count, 2);
407
407
  }
@@ -419,7 +419,7 @@ describe('PluginManager', () => {
419
419
 
420
420
  it.effect('should be able to fire custom activation events', () =>
421
421
  Effect.gen(function* () {
422
- const Plugin1 = Plugin.define({ id: 'dxos.org/test/plugin-1', name: 'Plugin 1' }).pipe(
422
+ const Plugin1 = Plugin.define({ id: 'org.dxos.test.plugin-1', name: 'Plugin 1' }).pipe(
423
423
  Plugin.addModule({
424
424
  activatesOn: CountEvent,
425
425
  id: 'Plugin1',
@@ -427,7 +427,7 @@ describe('PluginManager', () => {
427
427
  }),
428
428
  Plugin.make,
429
429
  );
430
- const Plugin2 = Plugin.define({ id: 'dxos.org/test/plugin-2', name: 'Plugin 2' }).pipe(
430
+ const Plugin2 = Plugin.define({ id: 'org.dxos.test.plugin-2', name: 'Plugin 2' }).pipe(
431
431
  Plugin.addModule({
432
432
  activatesOn: CountEvent,
433
433
  id: 'Plugin2',
@@ -435,7 +435,7 @@ describe('PluginManager', () => {
435
435
  }),
436
436
  Plugin.make,
437
437
  );
438
- const Plugin3 = Plugin.define({ id: 'dxos.org/test/plugin-3', name: 'Plugin 3' }).pipe(
438
+ const Plugin3 = Plugin.define({ id: 'org.dxos.test.plugin-3', name: 'Plugin 3' }).pipe(
439
439
  Plugin.addModule({
440
440
  activatesOn: CountEvent,
441
441
  id: 'Plugin3',
@@ -477,7 +477,7 @@ describe('PluginManager', () => {
477
477
  Effect.gen(function* () {
478
478
  const Test = Plugin.define(testMeta).pipe(
479
479
  Plugin.addModule({
480
- activatesOn: ActivationEvent.allOf(Common.ActivationEvent.Startup, CountEvent),
480
+ activatesOn: ActivationEvent.allOf(ActivationEvents.Startup, CountEvent),
481
481
  id: 'Hello',
482
482
  activate: () => {
483
483
  return Effect.succeed(Capability.contributes(String, { string: 'hello' }));
@@ -493,7 +493,7 @@ describe('PluginManager', () => {
493
493
  assert.strictEqual(manager.capabilities.getAll(String).length, 0);
494
494
 
495
495
  yield* manager.add(testMeta.id);
496
- yield* manager.activate(Common.ActivationEvent.Startup);
496
+ yield* manager.activate(ActivationEvents.Startup);
497
497
  assert.deepStrictEqual(manager.getActive(), []);
498
498
  assert.strictEqual(manager.capabilities.getAll(String).length, 0);
499
499
 
@@ -509,7 +509,7 @@ describe('PluginManager', () => {
509
509
  const Test = Plugin.define(testMeta).pipe(
510
510
  Plugin.addModule({
511
511
  id: 'Hello',
512
- activatesOn: ActivationEvent.oneOf(Common.ActivationEvent.Startup, CountEvent),
512
+ activatesOn: ActivationEvent.oneOf(ActivationEvents.Startup, CountEvent),
513
513
  activate: () => {
514
514
  count++;
515
515
  return Effect.succeed(Capability.contributes(String, { string: 'hello' }));
@@ -531,7 +531,7 @@ describe('PluginManager', () => {
531
531
  assert.strictEqual(manager.capabilities.getAll(String).length, 1);
532
532
  assert.strictEqual(count, 1);
533
533
 
534
- yield* manager.activate(Common.ActivationEvent.Startup);
534
+ yield* manager.activate(ActivationEvents.Startup);
535
535
  assert.deepStrictEqual(manager.getActive(), [testPlugin.modules[0].id]);
536
536
  assert.strictEqual(manager.capabilities.getAll(String).length, 1);
537
537
  assert.strictEqual(count, 1);
@@ -546,10 +546,10 @@ describe('PluginManager', () => {
546
546
  state.total = numbers.reduce((acc: number, n: { number: number }) => acc + n.number, 0);
547
547
  };
548
548
 
549
- const Count = Plugin.define({ id: 'dxos.org/test/count', name: 'Count' }).pipe(
549
+ const Count = Plugin.define({ id: 'org.dxos.test.count', name: 'Count' }).pipe(
550
550
  Plugin.addModule({
551
551
  id: 'Count',
552
- activatesOn: Common.ActivationEvent.Startup,
552
+ activatesOn: ActivationEvents.Startup,
553
553
  activatesBefore: [CountEvent],
554
554
  activate: Effect.fnUntraced(function* () {
555
555
  const capabilityManager = yield* Capability.Service;
@@ -586,7 +586,7 @@ describe('PluginManager', () => {
586
586
  {
587
587
  yield* manager.add(Test.meta.id);
588
588
  yield* manager.add(Count.meta.id);
589
- yield* manager.activate(Common.ActivationEvent.Startup);
589
+ yield* manager.activate(ActivationEvents.Startup);
590
590
  assert.deepStrictEqual(manager.getActive(), [
591
591
  ...testPlugin.modules.map((m) => m.id),
592
592
  countPlugin.modules[0].id,
@@ -626,7 +626,7 @@ describe('PluginManager', () => {
626
626
 
627
627
  it.effect('should be reactive', () =>
628
628
  Effect.gen(function* () {
629
- const Plugin1 = Plugin.define({ id: 'dxos.org/test/plugin-1', name: 'Plugin 1' }).pipe(
629
+ const Plugin1 = Plugin.define({ id: 'org.dxos.test.plugin-1', name: 'Plugin 1' }).pipe(
630
630
  Plugin.addModule({
631
631
  activatesOn: CountEvent,
632
632
  id: 'Plugin1',
@@ -634,7 +634,7 @@ describe('PluginManager', () => {
634
634
  }),
635
635
  Plugin.make,
636
636
  );
637
- const Plugin2 = Plugin.define({ id: 'dxos.org/test/plugin-2', name: 'Plugin 2' }).pipe(
637
+ const Plugin2 = Plugin.define({ id: 'org.dxos.test.plugin-2', name: 'Plugin 2' }).pipe(
638
638
  Plugin.addModule({
639
639
  activatesOn: CountEvent,
640
640
  id: 'Plugin2',
@@ -642,7 +642,7 @@ describe('PluginManager', () => {
642
642
  }),
643
643
  Plugin.make,
644
644
  );
645
- const Plugin3 = Plugin.define({ id: 'dxos.org/test/plugin-3', name: 'Plugin 3' }).pipe(
645
+ const Plugin3 = Plugin.define({ id: 'org.dxos.test.plugin-3', name: 'Plugin 3' }).pipe(
646
646
  Plugin.addModule({
647
647
  activatesOn: CountEvent,
648
648
  id: 'Plugin3',
@@ -752,8 +752,8 @@ describe('PluginManager', () => {
752
752
  }
753
753
  });
754
754
 
755
- const SlowEvent = ActivationEvent.make('dxos.org/test/slow');
756
- const SlowPlugin = Plugin.define({ id: 'dxos.org/test/slow-plugin', name: 'Slow Plugin' }).pipe(
755
+ const SlowEvent = ActivationEvent.make('org.dxos.test.slow');
756
+ const SlowPlugin = Plugin.define({ id: 'org.dxos.test.slow-plugin', name: 'Slow Plugin' }).pipe(
757
757
  Plugin.addModule({
758
758
  id: 'SlowModule',
759
759
  activatesOn: SlowEvent,
@@ -795,11 +795,11 @@ describe('PluginManager', () => {
795
795
  it.effect('should prevent concurrent loads of the same module via semaphore', () =>
796
796
  Effect.gen(function* () {
797
797
  // Two different events that both can trigger the same module.
798
- const EventA = ActivationEvent.make('dxos.org/test/event-a');
799
- const EventB = ActivationEvent.make('dxos.org/test/event-b');
798
+ const EventA = ActivationEvent.make('org.dxos.test.event-a');
799
+ const EventB = ActivationEvent.make('org.dxos.test.event-b');
800
800
 
801
801
  let activateCallCount = 0;
802
- const ConcurrentPlugin = Plugin.define({ id: 'dxos.org/test/concurrent-plugin', name: 'Concurrent Plugin' }).pipe(
802
+ const ConcurrentPlugin = Plugin.define({ id: 'org.dxos.test.concurrent-plugin', name: 'Concurrent Plugin' }).pipe(
803
803
  Plugin.addModule({
804
804
  id: 'ConcurrentModule',
805
805
  // Module activates on either event - this allows two different events to race.
@@ -15,6 +15,7 @@ import * as PubSub from 'effect/PubSub';
15
15
  import * as Ref from 'effect/Ref';
16
16
 
17
17
  import { runAndForwardErrors } from '@dxos/effect';
18
+ import { Performance } from '@dxos/effect';
18
19
  import { log } from '@dxos/log';
19
20
 
20
21
  import * as ActivationEvent from './activation-event';
@@ -438,6 +439,15 @@ class ManagerImpl implements PluginManager {
438
439
  Effect.andThen(Effect.sync(() => log.warn('event activation is taking a long time', { event: key }))),
439
440
  ),
440
441
  ),
442
+ Performance.addTrackEntry({
443
+ name: typeof event === 'string' ? event : ActivationEvent.eventKey(event),
444
+ devtools: {
445
+ dataType: 'track-entry',
446
+ track: 'Event Activation',
447
+ trackGroup: 'Composer',
448
+ color: 'primary',
449
+ },
450
+ }),
441
451
  );
442
452
  }
443
453
 
@@ -609,6 +619,15 @@ class ManagerImpl implements PluginManager {
609
619
  ),
610
620
  ),
611
621
  ),
622
+ Performance.addTrackEntry({
623
+ name: module.id,
624
+ devtools: {
625
+ dataType: 'track-entry',
626
+ track: 'Module Activation',
627
+ trackGroup: 'Composer',
628
+ color: 'primary',
629
+ },
630
+ }),
612
631
  );
613
632
 
614
633
  // Fork the load to run in background, completing the deferred when done.
@@ -49,7 +49,7 @@ export const reset = (event: ActivationEvent.ActivationEvent): Effect.Effect<boo
49
49
  * Computes a module ID from plugin ID and export name.
50
50
  */
51
51
  const computeModuleId = (pluginId: string, moduleName: string): string => {
52
- return `${pluginId}/module/${moduleName}`;
52
+ return `${pluginId}.module.${moduleName}`;
53
53
  };
54
54
 
55
55
  /**
@@ -128,7 +128,7 @@ export type Meta = {
128
128
  *
129
129
  * Expected to be in the form of a valid URL.
130
130
  *
131
- * @example dxos.org/plugin/example
131
+ * @example org.dxos.plugin.example
132
132
  */
133
133
  id: string;
134
134
 
@@ -190,6 +190,7 @@ export const isPlugin = (value: unknown): value is Plugin => {
190
190
  * A collection of modules that are be enabled/disabled as a unit.
191
191
  * Plugins provide things such as components, state, actions, etc. to the application.
192
192
  */
193
+ // TODO(burdon): Convert to ECHO schema.
193
194
  export interface Plugin {
194
195
  readonly [PluginTypeId]: PluginTypeId;
195
196
  readonly meta: Readonly<Meta>;
package/src/index.ts CHANGED
@@ -2,10 +2,8 @@
2
2
  // Copyright 2025 DXOS.org
3
3
  //
4
4
 
5
- export * from './cli';
6
- export * as Common from './common';
5
+ export * from './common';
7
6
  export * from './context';
8
7
  export * from './core';
9
8
  export * from './plugin-operation';
10
9
  export * from './plugin-runtime';
11
- export * from './plugin-settings';
@@ -2,7 +2,7 @@
2
2
  // Copyright 2025 DXOS.org
3
3
  //
4
4
 
5
- import * as Common from '../common';
5
+ import { ActivationEvents } from '../common';
6
6
  import { Capability, Plugin } from '../core';
7
7
 
8
8
  import { meta } from './meta';
@@ -12,13 +12,13 @@ const HistoryCapabilities = Capability.lazy('HistoryCapabilities', () => import(
12
12
 
13
13
  export const OperationPlugin = Plugin.define(meta).pipe(
14
14
  Plugin.addModule({
15
- activatesOn: Common.ActivationEvent.ManagedRuntimeReady,
16
- activatesBefore: [Common.ActivationEvent.SetupOperationResolver],
17
- activatesAfter: [Common.ActivationEvent.OperationInvokerReady],
15
+ activatesOn: ActivationEvents.ManagedRuntimeReady,
16
+ activatesBefore: [ActivationEvents.SetupOperationResolver],
17
+ activatesAfter: [ActivationEvents.OperationInvokerReady],
18
18
  activate: OperationInvoker,
19
19
  }),
20
20
  Plugin.addModule({
21
- activatesOn: Common.ActivationEvent.OperationInvokerReady,
21
+ activatesOn: ActivationEvents.OperationInvokerReady,
22
22
  activate: HistoryCapabilities,
23
23
  }),
24
24
  Plugin.make,
@@ -6,7 +6,7 @@ import * as Effect from 'effect/Effect';
6
6
 
7
7
  import { type OperationInvoker } from '@dxos/operation';
8
8
 
9
- import * as Common from '../../common';
9
+ import { Capabilities } from '../../common';
10
10
  import { Capability } from '../../core';
11
11
 
12
12
  import * as HistoryTracker from './history-tracker';
@@ -22,16 +22,16 @@ export default Capability.makeModule(
22
22
  const capabilities = yield* Capability.Service;
23
23
 
24
24
  // Create UndoRegistry.
25
- const undoRegistry = UndoRegistry.make(() => capabilities.getAll(Common.Capability.UndoMapping).flat());
25
+ const undoRegistry = UndoRegistry.make(() => capabilities.getAll(Capabilities.UndoMapping).flat());
26
26
 
27
27
  // Create HistoryTracker (depends on UndoRegistry and OperationInvoker).
28
- const invoker = yield* Capability.get(Common.Capability.OperationInvoker);
28
+ const invoker = yield* Capability.get(Capabilities.OperationInvoker);
29
29
  // Cast to internal type - the factory always returns OperationInvokerInternal.
30
30
  const historyTracker = HistoryTracker.make(invoker as OperationInvoker.OperationInvokerInternal, undoRegistry);
31
31
 
32
32
  return [
33
- Capability.contributes(Common.Capability.UndoRegistry, undoRegistry),
34
- Capability.contributes(Common.Capability.HistoryTracker, historyTracker),
33
+ Capability.contributes(Capabilities.UndoRegistry, undoRegistry),
34
+ Capability.contributes(Capabilities.HistoryTracker, historyTracker),
35
35
  ];
36
36
  }),
37
37
  );
@@ -4,7 +4,10 @@
4
4
 
5
5
  import type { Operation } from '@dxos/operation';
6
6
 
7
- import type { Label } from '../../common/translations';
7
+ /**
8
+ * Label type for translatable text (canonical definition in @dxos/app-toolkit).
9
+ */
10
+ type Label = string | [string, { ns: string; count?: number; defaultValue?: string }];
8
11
 
9
12
  /**
10
13
  * Extract the input type from an OperationDefinition.
@@ -95,7 +98,7 @@ export interface UndoMappingProps<
95
98
  * thread: output.thread,
96
99
  * anchor: output.anchor,
97
100
  * }),
98
- * message: ['thread deleted label', { ns: 'plugin-thread' }],
101
+ * message: ['thread deleted label', { ns: '@dxos/plugin-thread' }],
99
102
  * });
100
103
  *
101
104
  * // Dynamic message based on input/output
@@ -106,7 +109,7 @@ export interface UndoMappingProps<
106
109
  * message: (input, _output) =>
107
110
  * input.objects.length === 1
108
111
  * ? ['object deleted label', { ns: getTypename(input.objects[0]) }]
109
- * : ['objects deleted label', { ns: 'plugin-space' }],
112
+ * : ['objects deleted label', { ns: '@dxos/plugin-space' }],
110
113
  * });
111
114
  * ```
112
115
  */
@@ -6,7 +6,7 @@ import * as Effect from 'effect/Effect';
6
6
 
7
7
  import { OperationInvoker } from '@dxos/operation';
8
8
 
9
- import * as Common from '../common';
9
+ import { ActivationEvents, Capabilities } from '../common';
10
10
  import { Capability, Plugin } from '../core';
11
11
 
12
12
  //
@@ -20,14 +20,14 @@ export default Capability.makeModule(
20
20
  const pluginManager = yield* Plugin.Service;
21
21
 
22
22
  // Get the ManagedRuntime capability (should be available since we activate after ManagedRuntimeReady).
23
- const managedRuntimes = yield* Capability.getAll(Common.Capability.ManagedRuntime);
23
+ const managedRuntimes = yield* Capability.getAll(Capabilities.ManagedRuntime);
24
24
  const managedRuntime = managedRuntimes.length > 0 ? managedRuntimes[0] : undefined;
25
25
 
26
26
  const invoker = OperationInvoker.make(
27
27
  () =>
28
28
  Effect.gen(function* () {
29
- yield* Plugin.activate(Common.ActivationEvent.SetupOperationResolver);
30
- return (yield* Capability.getAll(Common.Capability.OperationResolver)).flat();
29
+ yield* Plugin.activate(ActivationEvents.SetupOperationResolver);
30
+ return (yield* Capability.getAll(Capabilities.OperationResolver)).flat();
31
31
  }).pipe(
32
32
  Effect.provideService(Capability.Service, capabilityManager),
33
33
  Effect.provideService(Plugin.Service, pluginManager),
@@ -35,6 +35,6 @@ export default Capability.makeModule(
35
35
  managedRuntime,
36
36
  );
37
37
 
38
- return Capability.contributes(Common.Capability.OperationInvoker, invoker);
38
+ return Capability.contributes(Capabilities.OperationInvoker, invoker);
39
39
  }),
40
40
  );
@@ -5,7 +5,7 @@
5
5
  import { type Plugin } from '../core';
6
6
 
7
7
  export const meta: Plugin.Meta = {
8
- id: 'dxos.org/plugin/operation',
8
+ id: 'org.dxos.plugin.operation',
9
9
  name: 'Operation Plugin',
10
10
  description: 'Provides operation invocation, undo registry, and history tracking.',
11
11
  };
@@ -2,7 +2,7 @@
2
2
  // Copyright 2025 DXOS.org
3
3
  //
4
4
 
5
- import * as Common from '../common';
5
+ import { ActivationEvents } from '../common';
6
6
  import { Capability, Plugin } from '../core';
7
7
 
8
8
  import { meta } from './meta';
@@ -11,9 +11,9 @@ const ManagedRuntimeCapability = Capability.lazy('ManagedRuntime', () => import(
11
11
 
12
12
  export const RuntimePlugin = Plugin.define(meta).pipe(
13
13
  Plugin.addModule({
14
- activatesOn: Common.ActivationEvent.Startup,
15
- activatesBefore: [Common.ActivationEvent.SetupLayer],
16
- activatesAfter: [Common.ActivationEvent.ManagedRuntimeReady],
14
+ activatesOn: ActivationEvents.Startup,
15
+ activatesBefore: [ActivationEvents.SetupLayer],
16
+ activatesAfter: [ActivationEvents.ManagedRuntimeReady],
17
17
  activate: ManagedRuntimeCapability,
18
18
  }),
19
19
  Plugin.make,
@@ -6,7 +6,7 @@ import * as Effect from 'effect/Effect';
6
6
  import * as Layer from 'effect/Layer';
7
7
  import * as ManagedRuntime from 'effect/ManagedRuntime';
8
8
 
9
- import * as Common from '../common';
9
+ import { ActivationEvents, Capabilities } from '../common';
10
10
  import { Capability, Plugin } from '../core';
11
11
 
12
12
  //
@@ -22,10 +22,10 @@ export default Capability.makeModule(
22
22
  const pluginManager = yield* Plugin.Service;
23
23
 
24
24
  // Trigger setup event so plugins can contribute their layers.
25
- yield* Plugin.activate(Common.ActivationEvent.SetupLayer);
25
+ yield* Plugin.activate(ActivationEvents.SetupLayer);
26
26
 
27
27
  // Gather all contributed layers.
28
- const layers = yield* Capability.getAll(Common.Capability.Layer);
28
+ const layers = yield* Capability.getAll(Capabilities.Layer);
29
29
 
30
30
  // Create layers that provide Capability.Service and Plugin.Service.
31
31
  const capabilityServiceLayer = Layer.succeed(Capability.Service, capabilityManager);
@@ -46,8 +46,8 @@ export default Capability.makeModule(
46
46
  );
47
47
 
48
48
  // Create the managed runtime from the composed layer.
49
- const runtime = ManagedRuntime.make(composedLayer) as Common.Capability.ManagedRuntime;
49
+ const runtime = ManagedRuntime.make(composedLayer) as Capabilities.ManagedRuntime;
50
50
 
51
- return Capability.contributes(Common.Capability.ManagedRuntime, runtime);
51
+ return Capability.contributes(Capabilities.ManagedRuntime, runtime);
52
52
  }),
53
53
  );
@@ -5,7 +5,7 @@
5
5
  import { type Plugin } from '../core';
6
6
 
7
7
  export const meta: Plugin.Meta = {
8
- id: 'dxos.org/plugin/runtime',
8
+ id: 'org.dxos.plugin.runtime',
9
9
  name: 'Runtime Plugin',
10
10
  description: 'Provides a managed Effect runtime by composing contributed layers.',
11
11
  };
@@ -7,7 +7,7 @@ import * as Layer from 'effect/Layer';
7
7
 
8
8
  import { invariant } from '@dxos/invariant';
9
9
 
10
- import * as Common from '../common';
10
+ import { ActivationEvents, Capabilities } from '../common';
11
11
  import { Plugin, PluginManager } from '../core';
12
12
 
13
13
  /**
@@ -34,18 +34,18 @@ export const fromPlugins = (plugins: Plugin.Plugin[]) =>
34
34
  });
35
35
 
36
36
  manager.capabilities.contribute({
37
- interface: Common.Capability.PluginManager,
37
+ interface: Capabilities.PluginManager,
38
38
  implementation: manager,
39
- module: 'dxos.org/app-framework/plugin-manager',
39
+ module: 'org.dxos.app-framework.plugin-manager',
40
40
  });
41
41
 
42
42
  manager.capabilities.contribute({
43
- interface: Common.Capability.AtomRegistry,
43
+ interface: Capabilities.AtomRegistry,
44
44
  implementation: manager.registry,
45
- module: 'dxos.org/app-framework/atom-registry',
45
+ module: 'org.dxos.app-framework.atom-registry',
46
46
  });
47
47
 
48
- yield* manager.activate(Common.ActivationEvent.Startup);
48
+ yield* manager.activate(ActivationEvents.Startup);
49
49
 
50
50
  return manager;
51
51
  }),