@dxos/app-framework 0.8.2-main.fbd8ed0 → 0.8.2-staging.7ac8446

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 (326) hide show
  1. package/dist/lib/browser/{app-graph-builder-6E7NCZ77.mjs → app-graph-builder-576BHZC7.mjs} +23 -23
  2. package/dist/lib/browser/app-graph-builder-576BHZC7.mjs.map +7 -0
  3. package/dist/lib/browser/{chunk-2KSDY3EZ.mjs → chunk-6AVTZPMT.mjs} +267 -325
  4. package/dist/lib/browser/chunk-6AVTZPMT.mjs.map +7 -0
  5. package/dist/lib/browser/{chunk-K3HOLGVH.mjs → chunk-PPIBZ5N4.mjs} +28 -40
  6. package/dist/lib/browser/chunk-PPIBZ5N4.mjs.map +7 -0
  7. package/dist/lib/browser/{chunk-KPRHX73H.mjs → chunk-SFPT4Z2C.mjs} +9 -9
  8. package/dist/lib/browser/chunk-SFPT4Z2C.mjs.map +7 -0
  9. package/dist/lib/browser/index.mjs +8 -10
  10. package/dist/lib/browser/index.mjs.map +1 -1
  11. package/dist/lib/browser/{intent-dispatcher-VGUJBPPN.mjs → intent-dispatcher-3Q67MHZZ.mjs} +2 -2
  12. package/dist/lib/browser/{intent-resolver-QLFZY5R5.mjs → intent-resolver-O763LCLG.mjs} +3 -3
  13. package/dist/lib/browser/meta.json +1 -1
  14. package/dist/lib/browser/{store-QGVXOY4T.mjs → store-URSN7DZI.mjs} +6 -7
  15. package/dist/lib/browser/store-URSN7DZI.mjs.map +7 -0
  16. package/dist/lib/browser/testing/index.mjs +3 -7
  17. package/dist/lib/browser/testing/index.mjs.map +3 -3
  18. package/dist/lib/browser/worker.mjs +3 -5
  19. package/dist/lib/node/app-graph-builder-JZCSKYPY.cjs +146 -0
  20. package/dist/lib/node/app-graph-builder-JZCSKYPY.cjs.map +7 -0
  21. package/dist/lib/node/{chunk-JQMNABMK.cjs → chunk-JUSEAFDU.cjs} +4 -4
  22. package/dist/lib/node/chunk-JUSEAFDU.cjs.map +7 -0
  23. package/dist/lib/node/{chunk-2EBZ2ICH.cjs → chunk-YIFTVCOR.cjs} +247 -304
  24. package/dist/lib/node/chunk-YIFTVCOR.cjs.map +7 -0
  25. package/dist/lib/node/{chunk-7J66KH2T.cjs → chunk-YNTKVTVX.cjs} +67 -79
  26. package/dist/lib/node/chunk-YNTKVTVX.cjs.map +7 -0
  27. package/dist/lib/node/index.cjs +79 -81
  28. package/dist/lib/node/index.cjs.map +1 -1
  29. package/dist/lib/node/{intent-dispatcher-TASJBG5M.cjs → intent-dispatcher-H334XLFD.cjs} +8 -8
  30. package/dist/lib/node/{intent-dispatcher-TASJBG5M.cjs.map → intent-dispatcher-H334XLFD.cjs.map} +2 -2
  31. package/dist/lib/node/{intent-resolver-5CG5NIJY.cjs → intent-resolver-3F4POWAM.cjs} +12 -12
  32. package/dist/lib/node/meta.json +1 -1
  33. package/dist/lib/node/{store-IF3UR2KA.cjs → store-OFDHTDCB.cjs} +9 -10
  34. package/dist/lib/node/store-OFDHTDCB.cjs.map +7 -0
  35. package/dist/lib/node/testing/index.cjs +9 -14
  36. package/dist/lib/node/testing/index.cjs.map +3 -3
  37. package/dist/lib/node/worker.cjs +38 -40
  38. package/dist/lib/node/worker.cjs.map +2 -2
  39. package/dist/lib/node-esm/{app-graph-builder-LYCG5CO3.mjs → app-graph-builder-VYKLSMSZ.mjs} +23 -23
  40. package/dist/lib/node-esm/app-graph-builder-VYKLSMSZ.mjs.map +7 -0
  41. package/dist/lib/node-esm/{chunk-BOEJMAVK.mjs → chunk-AHKIPS2L.mjs} +267 -325
  42. package/dist/lib/node-esm/chunk-AHKIPS2L.mjs.map +7 -0
  43. package/dist/lib/node-esm/{chunk-JUJF5L4G.mjs → chunk-PHOUQACM.mjs} +9 -9
  44. package/dist/lib/node-esm/chunk-PHOUQACM.mjs.map +7 -0
  45. package/dist/lib/node-esm/{chunk-ISNBS46Y.mjs → chunk-R6A7Z4LU.mjs} +28 -40
  46. package/dist/lib/node-esm/chunk-R6A7Z4LU.mjs.map +7 -0
  47. package/dist/lib/node-esm/index.mjs +8 -10
  48. package/dist/lib/node-esm/index.mjs.map +1 -1
  49. package/dist/lib/node-esm/{intent-dispatcher-ZUSNX2OY.mjs → intent-dispatcher-YDE2ONZA.mjs} +2 -2
  50. package/dist/lib/node-esm/{intent-resolver-NGDHUKDD.mjs → intent-resolver-LAGJ7LXM.mjs} +3 -3
  51. package/dist/lib/node-esm/meta.json +1 -1
  52. package/dist/lib/node-esm/{store-NCRSE25X.mjs → store-EYSUVNCS.mjs} +6 -7
  53. package/dist/lib/node-esm/store-EYSUVNCS.mjs.map +7 -0
  54. package/dist/lib/node-esm/testing/index.mjs +3 -7
  55. package/dist/lib/node-esm/testing/index.mjs.map +3 -3
  56. package/dist/lib/node-esm/worker.mjs +3 -5
  57. package/dist/types/src/App.d.ts +1 -3
  58. package/dist/types/src/App.d.ts.map +1 -1
  59. package/dist/types/src/common/capabilities.d.ts +196 -6
  60. package/dist/types/src/common/capabilities.d.ts.map +1 -1
  61. package/dist/types/src/common/events.d.ts.map +1 -1
  62. package/dist/types/src/common/file.d.ts +7 -7
  63. package/dist/types/src/common/file.d.ts.map +1 -1
  64. package/dist/types/src/common/index.d.ts +0 -1
  65. package/dist/types/src/common/index.d.ts.map +1 -1
  66. package/dist/types/src/common/layout.d.ts +158 -164
  67. package/dist/types/src/common/layout.d.ts.map +1 -1
  68. package/dist/types/src/common/surface.d.ts.map +1 -1
  69. package/dist/types/src/common/translations.d.ts +7 -7
  70. package/dist/types/src/common/translations.d.ts.map +1 -1
  71. package/dist/types/src/core/capabilities.d.ts +15 -33
  72. package/dist/types/src/core/capabilities.d.ts.map +1 -1
  73. package/dist/types/src/core/events.d.ts +1 -4
  74. package/dist/types/src/core/events.d.ts.map +1 -1
  75. package/dist/types/src/core/manager.d.ts +11 -14
  76. package/dist/types/src/core/manager.d.ts.map +1 -1
  77. package/dist/types/src/core/plugin.d.ts +3 -4
  78. package/dist/types/src/core/plugin.d.ts.map +1 -1
  79. package/dist/types/src/helpers.d.ts.map +1 -1
  80. package/dist/types/src/playground/generator/generator.d.ts.map +1 -1
  81. package/dist/types/src/playground/logger/schema.d.ts +6 -6
  82. package/dist/types/src/playground/logger/schema.d.ts.map +1 -1
  83. package/dist/types/src/plugin-intent/actions.d.ts +14 -14
  84. package/dist/types/src/plugin-intent/actions.d.ts.map +1 -1
  85. package/dist/types/src/plugin-intent/intent-dispatcher.d.ts +3 -29
  86. package/dist/types/src/plugin-intent/intent-dispatcher.d.ts.map +1 -1
  87. package/dist/types/src/plugin-intent/intent.d.ts +20 -14
  88. package/dist/types/src/plugin-intent/intent.d.ts.map +1 -1
  89. package/dist/types/src/plugin-settings/actions.d.ts +10 -10
  90. package/dist/types/src/plugin-settings/actions.d.ts.map +1 -1
  91. package/dist/types/src/plugin-settings/app-graph-builder.d.ts +195 -2
  92. package/dist/types/src/plugin-settings/app-graph-builder.d.ts.map +1 -1
  93. package/dist/types/src/plugin-settings/store.d.ts +2 -2
  94. package/dist/types/src/plugin-settings/store.d.ts.map +1 -1
  95. package/dist/types/src/react/IntentContext.d.ts.map +1 -1
  96. package/dist/types/src/react/Surface.d.ts +2 -2
  97. package/dist/types/src/react/Surface.d.ts.map +1 -1
  98. package/dist/types/src/react/useCapabilities.d.ts +2 -2
  99. package/dist/types/src/react/useCapabilities.d.ts.map +1 -1
  100. package/dist/types/src/react/useIntentResolver.d.ts.map +1 -1
  101. package/dist/types/src/testing/withPluginManager.d.ts +2 -5
  102. package/dist/types/src/testing/withPluginManager.d.ts.map +1 -1
  103. package/dist/types/src/testing/withPluginManager.stories.d.ts.map +1 -1
  104. package/dist/types/tsconfig.tsbuildinfo +1 -1
  105. package/package.json +20 -29
  106. package/project.json +1 -2
  107. package/src/App.tsx +4 -16
  108. package/src/common/capabilities.ts +4 -7
  109. package/src/common/file.ts +7 -7
  110. package/src/common/index.ts +0 -1
  111. package/src/common/layout.ts +128 -159
  112. package/src/common/translations.ts +7 -7
  113. package/src/core/capabilities.test.ts +36 -55
  114. package/src/core/capabilities.ts +58 -82
  115. package/src/core/events.ts +1 -4
  116. package/src/core/manager.test.ts +22 -22
  117. package/src/core/manager.ts +16 -24
  118. package/src/core/plugin.ts +3 -4
  119. package/src/playground/generator/generator.ts +4 -4
  120. package/src/playground/logger/schema.ts +5 -5
  121. package/src/playground/playground.stories.tsx +1 -1
  122. package/src/plugin-intent/actions.ts +9 -9
  123. package/src/plugin-intent/intent-dispatcher.test.ts +42 -23
  124. package/src/plugin-intent/intent-dispatcher.ts +13 -25
  125. package/src/plugin-intent/intent.ts +20 -22
  126. package/src/plugin-settings/actions.ts +8 -8
  127. package/src/plugin-settings/app-graph-builder.ts +94 -129
  128. package/src/plugin-settings/store.ts +17 -20
  129. package/src/react/Surface.stories.tsx +1 -1
  130. package/src/react/Surface.tsx +3 -3
  131. package/src/react/useCapabilities.ts +19 -9
  132. package/src/testing/withPluginManager.stories.tsx +1 -0
  133. package/src/testing/withPluginManager.tsx +3 -11
  134. package/tsconfig.json +0 -3
  135. package/dist/lib/browser/app-graph-builder-6E7NCZ77.mjs.map +0 -7
  136. package/dist/lib/browser/chunk-2KSDY3EZ.mjs.map +0 -7
  137. package/dist/lib/browser/chunk-K3HOLGVH.mjs.map +0 -7
  138. package/dist/lib/browser/chunk-KPRHX73H.mjs.map +0 -7
  139. package/dist/lib/browser/store-QGVXOY4T.mjs.map +0 -7
  140. package/dist/lib/node/app-graph-builder-4IWMG67O.cjs +0 -146
  141. package/dist/lib/node/app-graph-builder-4IWMG67O.cjs.map +0 -7
  142. package/dist/lib/node/chunk-2EBZ2ICH.cjs.map +0 -7
  143. package/dist/lib/node/chunk-7J66KH2T.cjs.map +0 -7
  144. package/dist/lib/node/chunk-JQMNABMK.cjs.map +0 -7
  145. package/dist/lib/node/store-IF3UR2KA.cjs.map +0 -7
  146. package/dist/lib/node-esm/app-graph-builder-LYCG5CO3.mjs.map +0 -7
  147. package/dist/lib/node-esm/chunk-BOEJMAVK.mjs.map +0 -7
  148. package/dist/lib/node-esm/chunk-ISNBS46Y.mjs.map +0 -7
  149. package/dist/lib/node-esm/chunk-JUJF5L4G.mjs.map +0 -7
  150. package/dist/lib/node-esm/store-NCRSE25X.mjs.map +0 -7
  151. package/dist/types/src/common/collaboration.d.ts +0 -26
  152. package/dist/types/src/common/collaboration.d.ts.map +0 -1
  153. package/src/common/collaboration.ts +0 -24
  154. package/typedoc/.nojekyll +0 -1
  155. package/typedoc/assets/hierarchy.js +0 -1
  156. package/typedoc/assets/highlight.css +0 -106
  157. package/typedoc/assets/icons.js +0 -18
  158. package/typedoc/assets/icons.svg +0 -1
  159. package/typedoc/assets/main.js +0 -60
  160. package/typedoc/assets/navigation.js +0 -1
  161. package/typedoc/assets/search.js +0 -1
  162. package/typedoc/assets/style.css +0 -1640
  163. package/typedoc/classes/CollaborationActions.InsertContent.html +0 -460
  164. package/typedoc/classes/ErrorBoundary.html +0 -125
  165. package/typedoc/classes/IntentAction.ShowUndo.html +0 -227
  166. package/typedoc/classes/IntentAction.Track.html +0 -266
  167. package/typedoc/classes/LayoutAction.AddToast.html +0 -265
  168. package/typedoc/classes/LayoutAction.Close.html +0 -382
  169. package/typedoc/classes/LayoutAction.Expose.html +0 -265
  170. package/typedoc/classes/LayoutAction.Open.html +0 -1123
  171. package/typedoc/classes/LayoutAction.RevertWorkspace.html +0 -343
  172. package/typedoc/classes/LayoutAction.ScrollIntoView.html +0 -460
  173. package/typedoc/classes/LayoutAction.Set.html +0 -460
  174. package/typedoc/classes/LayoutAction.SetLayoutMode.html +0 -499
  175. package/typedoc/classes/LayoutAction.SwitchWorkspace.html +0 -265
  176. package/typedoc/classes/LayoutAction.UpdateComplementary.html +0 -616
  177. package/typedoc/classes/LayoutAction.UpdateDialog.html +0 -811
  178. package/typedoc/classes/LayoutAction.UpdateLayout.html +0 -461
  179. package/typedoc/classes/LayoutAction.UpdatePopover.html +0 -1435
  180. package/typedoc/classes/LayoutAction.UpdateSidebar.html +0 -616
  181. package/typedoc/classes/Plugin.html +0 -6
  182. package/typedoc/classes/PluginContext.html +0 -38
  183. package/typedoc/classes/PluginManager.html +0 -43
  184. package/typedoc/classes/PluginModule.html +0 -18
  185. package/typedoc/classes/SettingsAction.Open.html +0 -226
  186. package/typedoc/classes/SettingsAction.OpenPluginRegistry.html +0 -265
  187. package/typedoc/functions/Events.createStateEvent.html +0 -2
  188. package/typedoc/functions/IntentPlugin.html +0 -1
  189. package/typedoc/functions/SettingsPlugin.html +0 -1
  190. package/typedoc/functions/allOf.html +0 -2
  191. package/typedoc/functions/chain.html +0 -3
  192. package/typedoc/functions/contributes.html +0 -2
  193. package/typedoc/functions/createApp.html +0 -6
  194. package/typedoc/functions/createDispatcher.html +0 -3
  195. package/typedoc/functions/createIntent.html +0 -6
  196. package/typedoc/functions/createResolver.html +0 -2
  197. package/typedoc/functions/createSurface.html +0 -2
  198. package/typedoc/functions/defineCapability.html +0 -2
  199. package/typedoc/functions/defineEvent.html +0 -2
  200. package/typedoc/functions/defineModule.html +0 -2
  201. package/typedoc/functions/definePlugin.html +0 -2
  202. package/typedoc/functions/eventKey.html +0 -2
  203. package/typedoc/functions/getEvents.html +0 -2
  204. package/typedoc/functions/isAllOf.html +0 -2
  205. package/typedoc/functions/isOneOf.html +0 -2
  206. package/typedoc/functions/isSurfaceAvailable.html +0 -2
  207. package/typedoc/functions/lazy.html +0 -2
  208. package/typedoc/functions/oneOf.html +0 -2
  209. package/typedoc/functions/useAppGraph.html +0 -1
  210. package/typedoc/functions/useCapabilities.html +0 -3
  211. package/typedoc/functions/useCapability.html +0 -4
  212. package/typedoc/functions/useIntentDispatcher.html +0 -1
  213. package/typedoc/functions/useIntentResolver.html +0 -1
  214. package/typedoc/functions/useLayout.html +0 -1
  215. package/typedoc/functions/usePluginManager.html +0 -2
  216. package/typedoc/hierarchy.html +0 -1
  217. package/typedoc/index.html +0 -16
  218. package/typedoc/interfaces/LayoutAction.Toast.html +0 -10
  219. package/typedoc/media/LICENSE +0 -8
  220. package/typedoc/modules/Capabilities.html +0 -1
  221. package/typedoc/modules/CollaborationActions.html +0 -1
  222. package/typedoc/modules/Events.html +0 -1
  223. package/typedoc/modules/IntentAction.html +0 -1
  224. package/typedoc/modules/LayoutAction.html +0 -2
  225. package/typedoc/modules/SettingsAction.html +0 -1
  226. package/typedoc/modules.html +0 -1
  227. package/typedoc/types/ActivationEvent.html +0 -8
  228. package/typedoc/types/ActivationEvents.html +0 -2
  229. package/typedoc/types/AnyCapability.html +0 -1
  230. package/typedoc/types/AnyIntent.html +0 -1
  231. package/typedoc/types/AnyIntentChain.html +0 -1
  232. package/typedoc/types/AnyIntentEffectResult.html +0 -1
  233. package/typedoc/types/AnyIntentResolver.html +0 -1
  234. package/typedoc/types/AnyIntentResult.html +0 -1
  235. package/typedoc/types/Capabilities.FileUploader.html +0 -1
  236. package/typedoc/types/Capabilities.IntentResolver.html +0 -1
  237. package/typedoc/types/Capabilities.Layout.html +0 -1
  238. package/typedoc/types/Capabilities.Metadata.html +0 -1
  239. package/typedoc/types/Capabilities.ReactContext.html +0 -1
  240. package/typedoc/types/Capabilities.ReactRoot.html +0 -1
  241. package/typedoc/types/Capabilities.ReactSurface.html +0 -1
  242. package/typedoc/types/Capabilities.Settings.html +0 -4
  243. package/typedoc/types/Capability.html +0 -9
  244. package/typedoc/types/CreateAppOptions.html +0 -10
  245. package/typedoc/types/FileInfo.html +0 -1
  246. package/typedoc/types/Intent.html +0 -10
  247. package/typedoc/types/IntentChain.html +0 -6
  248. package/typedoc/types/IntentContext.html +0 -5
  249. package/typedoc/types/IntentData.html +0 -1
  250. package/typedoc/types/IntentDispatcher.html +0 -2
  251. package/typedoc/types/IntentDispatcherResult.html +0 -2
  252. package/typedoc/types/IntentEffectDefinition.html +0 -2
  253. package/typedoc/types/IntentEffectResult.html +0 -15
  254. package/typedoc/types/IntentParams.html +0 -3
  255. package/typedoc/types/IntentResolver.html +0 -2
  256. package/typedoc/types/IntentResultData.html +0 -1
  257. package/typedoc/types/IntentSchema.html +0 -1
  258. package/typedoc/types/IntentUndo.html +0 -2
  259. package/typedoc/types/InterfaceDef.html +0 -4
  260. package/typedoc/types/Label.html +0 -1
  261. package/typedoc/types/NodeSerializer.html +0 -8
  262. package/typedoc/types/PluginManagerOptions.html +0 -6
  263. package/typedoc/types/PluginMeta.html +0 -21
  264. package/typedoc/types/PromiseIntentDispatcher.html +0 -2
  265. package/typedoc/types/PromiseIntentUndo.html +0 -2
  266. package/typedoc/types/Resource.html +0 -1
  267. package/typedoc/types/ResourceKey.html +0 -1
  268. package/typedoc/types/ResourceLanguage.html +0 -1
  269. package/typedoc/types/SerializedNode.html +0 -4
  270. package/typedoc/types/SurfaceComponent.html +0 -2
  271. package/typedoc/types/SurfaceDefinition.html +0 -2
  272. package/typedoc/types/SurfaceProps.html +0 -4
  273. package/typedoc/variables/Capabilities.AppGraph.html +0 -1
  274. package/typedoc/variables/Capabilities.AppGraphBuilder.html +0 -1
  275. package/typedoc/variables/Capabilities.AppGraphSerializer.html +0 -1
  276. package/typedoc/variables/Capabilities.ArtifactDefinition.html +0 -1
  277. package/typedoc/variables/Capabilities.FileUploader.html +0 -1
  278. package/typedoc/variables/Capabilities.IntentDispatcher.html +0 -1
  279. package/typedoc/variables/Capabilities.IntentResolver.html +0 -1
  280. package/typedoc/variables/Capabilities.Layout.html +0 -1
  281. package/typedoc/variables/Capabilities.Metadata.html +0 -1
  282. package/typedoc/variables/Capabilities.Null.html +0 -1
  283. package/typedoc/variables/Capabilities.PluginManager.html +0 -1
  284. package/typedoc/variables/Capabilities.ReactContext.html +0 -1
  285. package/typedoc/variables/Capabilities.ReactRoot.html +0 -1
  286. package/typedoc/variables/Capabilities.ReactSurface.html +0 -1
  287. package/typedoc/variables/Capabilities.RxRegistry.html +0 -1
  288. package/typedoc/variables/Capabilities.Settings.html +0 -1
  289. package/typedoc/variables/Capabilities.SettingsStore.html +0 -1
  290. package/typedoc/variables/Capabilities.Tools.html +0 -1
  291. package/typedoc/variables/Capabilities.Translations.html +0 -1
  292. package/typedoc/variables/Events.AppGraphReady.html +0 -2
  293. package/typedoc/variables/Events.DispatcherReady.html +0 -2
  294. package/typedoc/variables/Events.LayoutReady.html +0 -1
  295. package/typedoc/variables/Events.SettingsReady.html +0 -2
  296. package/typedoc/variables/Events.SetupAppGraph.html +0 -2
  297. package/typedoc/variables/Events.SetupArtifactDefinition.html +0 -2
  298. package/typedoc/variables/Events.SetupIntentResolver.html +0 -2
  299. package/typedoc/variables/Events.SetupMetadata.html +0 -2
  300. package/typedoc/variables/Events.SetupReactSurface.html +0 -2
  301. package/typedoc/variables/Events.SetupSettings.html +0 -2
  302. package/typedoc/variables/Events.SetupTranslations.html +0 -2
  303. package/typedoc/variables/Events.Startup.html +0 -2
  304. package/typedoc/variables/FileInfoSchema.html +0 -1
  305. package/typedoc/variables/INTENT_ACTION.html +0 -1
  306. package/typedoc/variables/INTENT_PLUGIN.html +0 -1
  307. package/typedoc/variables/LAYOUT_ACTION.html +0 -1
  308. package/typedoc/variables/LAYOUT_PLUGIN.html +0 -1
  309. package/typedoc/variables/Label.html +0 -1
  310. package/typedoc/variables/LayoutAction.Toast.html +0 -1
  311. package/typedoc/variables/LayoutAction.UPDATE_LAYOUT.html +0 -1
  312. package/typedoc/variables/PluginManagerProvider.html +0 -2
  313. package/typedoc/variables/Resource.html +0 -2
  314. package/typedoc/variables/ResourceKey.html +0 -1
  315. package/typedoc/variables/ResourceLanguage.html +0 -1
  316. package/typedoc/variables/SETTINGS_ACTION.html +0 -1
  317. package/typedoc/variables/SETTINGS_ID.html +0 -1
  318. package/typedoc/variables/SETTINGS_KEY.html +0 -1
  319. package/typedoc/variables/SETTINGS_PLUGIN.html +0 -1
  320. package/typedoc/variables/Surface.html +0 -2
  321. package/typedoc/variables/defaultFileTypes.html +0 -1
  322. /package/dist/lib/browser/{intent-dispatcher-VGUJBPPN.mjs.map → intent-dispatcher-3Q67MHZZ.mjs.map} +0 -0
  323. /package/dist/lib/browser/{intent-resolver-QLFZY5R5.mjs.map → intent-resolver-O763LCLG.mjs.map} +0 -0
  324. /package/dist/lib/node/{intent-resolver-5CG5NIJY.cjs.map → intent-resolver-3F4POWAM.cjs.map} +0 -0
  325. /package/dist/lib/node-esm/{intent-dispatcher-ZUSNX2OY.mjs.map → intent-dispatcher-YDE2ONZA.mjs.map} +0 -0
  326. /package/dist/lib/node-esm/{intent-resolver-NGDHUKDD.mjs.map → intent-resolver-LAGJ7LXM.mjs.map} +0 -0
@@ -1,18 +1,18 @@
1
1
  import { createRequire } from 'node:module';const require = createRequire(import.meta.url);
2
2
 
3
3
  // packages/sdk/app-framework/src/plugin-intent/intent-dispatcher.ts
4
- import { Effect as Effect3, Option, pipe as pipe2, Ref as Ref2 } from "effect";
5
- import { live as live2 } from "@dxos/live-object";
4
+ import { Effect as Effect3, Option, pipe as pipe2, Ref } from "effect";
5
+ import { create as create3 } from "@dxos/live-object";
6
6
  import { log as log3 } from "@dxos/log";
7
7
  import { byPosition } from "@dxos/util";
8
8
 
9
9
  // packages/sdk/app-framework/src/plugin-intent/actions.ts
10
- import { Schema as Schema2 } from "effect";
10
+ import { Schema as S2 } from "effect";
11
11
 
12
12
  // packages/sdk/app-framework/src/plugin-intent/intent.ts
13
- import { Schema } from "effect";
13
+ import { Schema as S } from "effect";
14
14
  var createIntent = (schema, data = {}, params = {}) => {
15
- const _ = Schema.validateSync(schema.fields.input)(data);
15
+ const _ = S.validateSync(schema.fields.input)(data);
16
16
  const intent = {
17
17
  ...params,
18
18
  _schema: schema,
@@ -47,9 +47,9 @@ var chain = (schema, data = {}, params = {}) => (intent) => {
47
47
  ]
48
48
  };
49
49
  };
50
- var Label = Schema.Union(Schema.String, Schema.mutable(Schema.Tuple(Schema.String, Schema.mutable(Schema.Struct({
51
- ns: Schema.String,
52
- count: Schema.optional(Schema.Number)
50
+ var Label = S.Union(S.String, S.mutable(S.Tuple(S.String, S.mutable(S.Struct({
51
+ ns: S.String,
52
+ count: S.optional(S.Number)
53
53
  })))));
54
54
 
55
55
  // packages/sdk/app-framework/src/plugin-intent/actions.ts
@@ -57,20 +57,20 @@ var INTENT_PLUGIN = "dxos.org/plugin/intent";
57
57
  var INTENT_ACTION = `${INTENT_PLUGIN}/action`;
58
58
  var IntentAction;
59
59
  (function(IntentAction2) {
60
- class Track extends Schema2.TaggedClass()(`${INTENT_ACTION}/track`, {
61
- input: Schema2.Struct({
62
- intents: Schema2.Array(Schema2.String),
63
- error: Schema2.optional(Schema2.String)
60
+ class Track extends S2.TaggedClass()(`${INTENT_ACTION}/track`, {
61
+ input: S2.Struct({
62
+ intents: S2.Array(S2.String),
63
+ error: S2.optional(S2.String)
64
64
  }),
65
- output: Schema2.Void
65
+ output: S2.Void
66
66
  }) {
67
67
  }
68
68
  IntentAction2.Track = Track;
69
- class ShowUndo extends Schema2.TaggedClass()(`${INTENT_ACTION}/show-undo`, {
70
- input: Schema2.Struct({
69
+ class ShowUndo extends S2.TaggedClass()(`${INTENT_ACTION}/show-undo`, {
70
+ input: S2.Struct({
71
71
  message: Label
72
72
  }),
73
- output: Schema2.Void
73
+ output: S2.Void
74
74
  }) {
75
75
  }
76
76
  IntentAction2.ShowUndo = ShowUndo;
@@ -102,10 +102,11 @@ var CycleDetectedError = class extends BaseError {
102
102
  };
103
103
 
104
104
  // packages/sdk/app-framework/src/core/capabilities.ts
105
- import { Rx } from "@effect-rx/rx-react";
105
+ import { effect, untracked } from "@preact/signals-core";
106
106
  import { Effect } from "effect";
107
107
  import { Trigger } from "@dxos/async";
108
108
  import { invariant } from "@dxos/invariant";
109
+ import { create } from "@dxos/live-object";
109
110
  import { log } from "@dxos/log";
110
111
  var __dxlog_file = "/home/runner/work/dxos/dxos/packages/sdk/app-framework/src/core/capabilities.ts";
111
112
  var InterfaceDefTypeId = Symbol.for("InterfaceDefTypeId");
@@ -131,33 +132,9 @@ var lazy = (c) => async (props) => {
131
132
  const { default: getCapability } = await c();
132
133
  return async () => getCapability(props);
133
134
  };
134
- var PluginContext = class {
135
- constructor({ registry, activate, reset }) {
136
- this._capabilityImpls = Rx.family(() => {
137
- return Rx.make([]).pipe(Rx.keepAlive);
138
- });
139
- this._capabilities = Rx.family((id) => {
140
- return Rx.make((get) => {
141
- const current = get(this._capabilityImpls(id));
142
- return current.map((c) => c.implementation);
143
- });
144
- });
145
- this._capability = Rx.family((id) => {
146
- return Rx.make((get) => {
147
- const current = get(this._capabilities(id));
148
- invariant(current.length > 0, `No capability found for ${id}`, {
149
- F: __dxlog_file,
150
- L: 117,
151
- S: this,
152
- A: [
153
- "current.length > 0",
154
- "`No capability found for ${id}`"
155
- ]
156
- });
157
- return current[0];
158
- });
159
- });
160
- this._registry = registry;
135
+ var PluginsContext = class {
136
+ constructor({ activate, reset }) {
137
+ this._definedCapabilities = /* @__PURE__ */ new Map();
161
138
  this.activate = activate;
162
139
  this.reset = reset;
163
140
  }
@@ -165,22 +142,22 @@ var PluginContext = class {
165
142
  * @internal
166
143
  */
167
144
  contributeCapability({ module: moduleId, interface: interfaceDef, implementation }) {
168
- const current = this._registry.get(this._capabilityImpls(interfaceDef.identifier));
169
- const capability = new CapabilityImpl(moduleId, implementation);
170
- if (current.includes(capability)) {
171
- return;
145
+ let current = this._definedCapabilities.get(interfaceDef.identifier);
146
+ if (!current) {
147
+ const object = create({
148
+ value: []
149
+ });
150
+ current = untracked(() => object.value);
151
+ this._definedCapabilities.set(interfaceDef.identifier, current);
172
152
  }
173
- this._registry.set(this._capabilityImpls(interfaceDef.identifier), [
174
- ...current,
175
- capability
176
- ]);
153
+ current.push(new CapabilityImpl(moduleId, implementation));
177
154
  log("capability contributed", {
178
155
  id: interfaceDef.identifier,
179
156
  moduleId,
180
- count: current.length
157
+ count: untracked(() => current.length)
181
158
  }, {
182
159
  F: __dxlog_file,
183
- L: 161,
160
+ L: 142,
184
161
  S: this,
185
162
  C: (f, a) => f(...a)
186
163
  });
@@ -189,19 +166,19 @@ var PluginContext = class {
189
166
  * @internal
190
167
  */
191
168
  removeCapability(interfaceDef, implementation) {
192
- const current = this._registry.get(this._capabilityImpls(interfaceDef.identifier));
193
- if (current.length === 0) {
169
+ const current = this._definedCapabilities.get(interfaceDef.identifier);
170
+ if (!current) {
194
171
  return;
195
172
  }
196
- const next = current.filter((c) => c.implementation !== implementation);
197
- if (next.length !== current.length) {
198
- this._registry.set(this._capabilityImpls(interfaceDef.identifier), next);
173
+ const index = current.findIndex((i) => i.implementation === implementation);
174
+ if (index !== -1) {
175
+ current.splice(index, 1);
199
176
  log("capability removed", {
200
177
  id: interfaceDef.identifier,
201
- count: current.length
178
+ count: untracked(() => current.length)
202
179
  }, {
203
180
  F: __dxlog_file,
204
- L: 180,
181
+ L: 161,
205
182
  S: this,
206
183
  C: (f, a) => f(...a)
207
184
  });
@@ -210,64 +187,63 @@ var PluginContext = class {
210
187
  id: interfaceDef.identifier
211
188
  }, {
212
189
  F: __dxlog_file,
213
- L: 182,
190
+ L: 163,
214
191
  S: this,
215
192
  C: (f, a) => f(...a)
216
193
  });
217
194
  }
218
195
  }
219
196
  /**
220
- * Get the Rx reference to the available capabilities for a given interface.
221
- * Primarily useful for deriving other Rx values based on the capabilities or
222
- * for subscribing to changes in the capabilities.
223
- * @returns An Rx reference to the available capabilities.
224
- */
225
- capabilities(interfaceDef) {
226
- return this._capabilities(interfaceDef.identifier);
227
- }
228
- /**
229
- * Get the Rx reference to the available capabilities for a given interface.
230
- * Primarily useful for deriving other Rx values based on the capability or
231
- * for subscribing to changes in the capability.
232
- * @returns An Rx reference to the available capability.
233
- * @throws If no capability is found.
234
- */
235
- capability(interfaceDef) {
236
- return this._capability(interfaceDef.identifier);
237
- }
238
- /**
239
- * Get capabilities from the plugin context.
197
+ * Requests capabilities from the plugin context.
240
198
  * @returns An array of capabilities.
199
+ * @reactive
241
200
  */
242
- getCapabilities(interfaceDef) {
243
- return this._registry.get(this.capabilities(interfaceDef));
201
+ requestCapabilities(interfaceDef, filter) {
202
+ let current = this._definedCapabilities.get(interfaceDef.identifier);
203
+ if (!current) {
204
+ const object = create({
205
+ value: []
206
+ });
207
+ current = untracked(() => object.value);
208
+ this._definedCapabilities.set(interfaceDef.identifier, current);
209
+ }
210
+ const capabilities = filter ? current.filter((c) => filter(c.implementation, c.moduleId)) : current;
211
+ return capabilities.map((c) => c.implementation);
244
212
  }
245
213
  /**
246
214
  * Requests a single capability from the plugin context.
247
215
  * @returns The capability.
248
216
  * @throws If no capability is found.
217
+ * @reactive
249
218
  */
250
- getCapability(interfaceDef) {
251
- return this._registry.get(this.capability(interfaceDef));
219
+ requestCapability(interfaceDef, filter) {
220
+ const capability = this.requestCapabilities(interfaceDef, filter)[0];
221
+ invariant(capability, `No capability found for ${interfaceDef.identifier}`, {
222
+ F: __dxlog_file,
223
+ L: 199,
224
+ S: this,
225
+ A: [
226
+ "capability",
227
+ "`No capability found for ${interfaceDef.identifier}`"
228
+ ]
229
+ });
230
+ return capability;
252
231
  }
253
232
  /**
254
- * Waits for a capability to be available.
233
+ * Waits for a capability to be contributed.
255
234
  * @returns The capability.
256
235
  */
257
- async waitForCapability(interfaceDef) {
258
- const [capability] = this.getCapabilities(interfaceDef);
259
- if (capability) {
260
- return capability;
261
- }
236
+ async waitForCapability(interfaceDef, filter) {
262
237
  const trigger = new Trigger();
263
- const cancel = this._registry.subscribe(this.capabilities(interfaceDef), (capabilities) => {
264
- if (capabilities.length > 0) {
238
+ const unsubscribe = effect(() => {
239
+ const capabilities = this.requestCapabilities(interfaceDef, filter);
240
+ if (capabilities[0]) {
265
241
  trigger.wake(capabilities[0]);
266
242
  }
267
243
  });
268
- const result = await trigger.wait();
269
- cancel();
270
- return result;
244
+ const capability = await trigger.wait();
245
+ unsubscribe();
246
+ return capability;
271
247
  }
272
248
  async activatePromise(event) {
273
249
  return this.activate(event).pipe(Effect.runPromise);
@@ -300,28 +276,25 @@ var getEvents = (events) => "type" in events ? events.events : [
300
276
  ];
301
277
 
302
278
  // packages/sdk/app-framework/src/core/manager.ts
303
- import { Registry } from "@effect-rx/rx-react";
304
- import { untracked } from "@preact/signals-core";
279
+ import { untracked as untracked2 } from "@preact/signals-core";
305
280
  import { Array as A, Effect as Effect2, Either, Match, pipe } from "effect";
306
281
  import { Event } from "@dxos/async";
307
- import { live } from "@dxos/live-object";
282
+ import { create as create2 } from "@dxos/live-object";
308
283
  import { log as log2 } from "@dxos/log";
309
284
  var __dxlog_file2 = "/home/runner/work/dxos/dxos/packages/sdk/app-framework/src/core/manager.ts";
310
285
  var isPromise = (value) => {
311
286
  return value !== null && typeof value === "object" && "then" in value;
312
287
  };
313
288
  var PluginManager = class {
314
- constructor({ pluginLoader, plugins = [], core = plugins.map(({ meta }) => meta.id), enabled = [], registry }) {
289
+ constructor({ pluginLoader, plugins = [], core = plugins.map(({ meta }) => meta.id), enabled = [] }) {
315
290
  this.activation = new Event();
316
- this._capabilities = /* @__PURE__ */ new Map();
317
- this.registry = registry ?? Registry.make();
318
- this.context = new PluginContext({
319
- registry: this.registry,
291
+ this.context = new PluginsContext({
320
292
  activate: (event) => this._activate(event),
321
293
  reset: (id) => this._reset(id)
322
294
  });
295
+ this._capabilities = /* @__PURE__ */ new Map();
323
296
  this._pluginLoader = pluginLoader;
324
- this._state = live({
297
+ this._state = create2({
325
298
  plugins,
326
299
  core,
327
300
  enabled,
@@ -395,12 +368,12 @@ var PluginManager = class {
395
368
  * @param id The id of the plugin.
396
369
  */
397
370
  async add(id) {
398
- return untracked(async () => {
371
+ return untracked2(async () => {
399
372
  log2("add plugin", {
400
373
  id
401
374
  }, {
402
375
  F: __dxlog_file2,
403
- L: 154,
376
+ L: 146,
404
377
  S: this,
405
378
  C: (f, a) => f(...a)
406
379
  });
@@ -414,12 +387,12 @@ var PluginManager = class {
414
387
  * @param id The id of the plugin.
415
388
  */
416
389
  enable(id) {
417
- return untracked(async () => {
390
+ return untracked2(async () => {
418
391
  log2("enable plugin", {
419
392
  id
420
393
  }, {
421
394
  F: __dxlog_file2,
422
- L: 167,
395
+ L: 159,
423
396
  S: this,
424
397
  C: (f, a) => f(...a)
425
398
  });
@@ -440,7 +413,7 @@ var PluginManager = class {
440
413
  ]
441
414
  }, {
442
415
  F: __dxlog_file2,
443
- L: 182,
416
+ L: 174,
444
417
  S: this,
445
418
  C: (f, a) => f(...a)
446
419
  });
@@ -455,12 +428,12 @@ var PluginManager = class {
455
428
  * @param id The id of the plugin.
456
429
  */
457
430
  remove(id) {
458
- return untracked(() => {
431
+ return untracked2(() => {
459
432
  log2("remove plugin", {
460
433
  id
461
434
  }, {
462
435
  F: __dxlog_file2,
463
- L: 200,
436
+ L: 192,
464
437
  S: this,
465
438
  C: (f, a) => f(...a)
466
439
  });
@@ -477,12 +450,12 @@ var PluginManager = class {
477
450
  * @param id The id of the plugin.
478
451
  */
479
452
  disable(id) {
480
- return untracked(async () => {
453
+ return untracked2(async () => {
481
454
  log2("disable plugin", {
482
455
  id
483
456
  }, {
484
457
  F: __dxlog_file2,
485
- L: 217,
458
+ L: 209,
486
459
  S: this,
487
460
  C: (f, a) => f(...a)
488
461
  });
@@ -510,7 +483,7 @@ var PluginManager = class {
510
483
  * @returns Whether the activation was successful.
511
484
  */
512
485
  activate(event) {
513
- return untracked(() => Effect2.runPromise(this._activate(event)));
486
+ return untracked2(() => Effect2.runPromise(this._activate(event)));
514
487
  }
515
488
  /**
516
489
  * Deactivates all of the modules for a plugin.
@@ -518,7 +491,7 @@ var PluginManager = class {
518
491
  * @returns Whether the deactivation was successful.
519
492
  */
520
493
  deactivate(id) {
521
- return untracked(() => Effect2.runPromise(this._deactivate(id)));
494
+ return untracked2(() => Effect2.runPromise(this._deactivate(id)));
522
495
  }
523
496
  /**
524
497
  * Re-activates the modules that were activated by the event.
@@ -526,15 +499,15 @@ var PluginManager = class {
526
499
  * @returns Whether the reset was successful.
527
500
  */
528
501
  reset(event) {
529
- return untracked(() => Effect2.runPromise(this._reset(event)));
502
+ return untracked2(() => Effect2.runPromise(this._reset(event)));
530
503
  }
531
504
  _addPlugin(plugin) {
532
- untracked(() => {
505
+ untracked2(() => {
533
506
  log2("add plugin", {
534
507
  id: plugin.meta.id
535
508
  }, {
536
509
  F: __dxlog_file2,
537
- L: 270,
510
+ L: 262,
538
511
  S: this,
539
512
  C: (f, a) => f(...a)
540
513
  });
@@ -544,12 +517,12 @@ var PluginManager = class {
544
517
  });
545
518
  }
546
519
  _removePlugin(id) {
547
- untracked(() => {
520
+ untracked2(() => {
548
521
  log2("remove plugin", {
549
522
  id
550
523
  }, {
551
524
  F: __dxlog_file2,
552
- L: 279,
525
+ L: 271,
553
526
  S: this,
554
527
  C: (f, a) => f(...a)
555
528
  });
@@ -560,12 +533,12 @@ var PluginManager = class {
560
533
  });
561
534
  }
562
535
  _addModule(module) {
563
- untracked(() => {
536
+ untracked2(() => {
564
537
  log2("add module", {
565
538
  id: module.id
566
539
  }, {
567
540
  F: __dxlog_file2,
568
- L: 289,
541
+ L: 281,
569
542
  S: this,
570
543
  C: (f, a) => f(...a)
571
544
  });
@@ -575,12 +548,12 @@ var PluginManager = class {
575
548
  });
576
549
  }
577
550
  _removeModule(id) {
578
- untracked(() => {
551
+ untracked2(() => {
579
552
  log2("remove module", {
580
553
  id
581
554
  }, {
582
555
  F: __dxlog_file2,
583
- L: 298,
556
+ L: 290,
584
557
  S: this,
585
558
  C: (f, a) => f(...a)
586
559
  });
@@ -606,7 +579,7 @@ var PluginManager = class {
606
579
  return this._getInactiveModules().filter((module) => getEvents(module.activatesOn).map(eventKey).includes(key));
607
580
  }
608
581
  _setPendingResetByModule(module) {
609
- return untracked(() => {
582
+ return untracked2(() => {
610
583
  const activationEvents = getEvents(module.activatesOn).map(eventKey).filter((key) => this._state.eventsFired.includes(key));
611
584
  const pendingReset = Array.from(new Set(activationEvents)).filter((event) => !this._state.pendingReset.includes(event));
612
585
  if (pendingReset.length > 0) {
@@ -614,7 +587,7 @@ var PluginManager = class {
614
587
  events: pendingReset
615
588
  }, {
616
589
  F: __dxlog_file2,
617
- L: 336,
590
+ L: 328,
618
591
  S: this,
619
592
  C: (f, a) => f(...a)
620
593
  });
@@ -633,7 +606,7 @@ var PluginManager = class {
633
606
  key
634
607
  }, {
635
608
  F: __dxlog_file2,
636
- L: 349,
609
+ L: 341,
637
610
  S: this,
638
611
  C: (f, a) => f(...a)
639
612
  });
@@ -654,7 +627,7 @@ var PluginManager = class {
654
627
  key
655
628
  }, {
656
629
  F: __dxlog_file2,
657
- L: 365,
630
+ L: 357,
658
631
  S: this,
659
632
  C: (f, a) => f(...a)
660
633
  });
@@ -668,7 +641,7 @@ var PluginManager = class {
668
641
  modules: modules.map((module) => module.id)
669
642
  }, {
670
643
  F: __dxlog_file2,
671
- L: 372,
644
+ L: 364,
672
645
  S: this,
673
646
  C: (f, a) => f(...a)
674
647
  });
@@ -710,7 +683,7 @@ var PluginManager = class {
710
683
  key
711
684
  }, {
712
685
  F: __dxlog_file2,
713
- L: 406,
686
+ L: 398,
714
687
  S: this,
715
688
  C: (f, a) => f(...a)
716
689
  });
@@ -726,7 +699,7 @@ var PluginManager = class {
726
699
  module: module.id
727
700
  }, {
728
701
  F: __dxlog_file2,
729
- L: 421,
702
+ L: 413,
730
703
  S: this,
731
704
  C: (f, a) => f(...a)
732
705
  });
@@ -755,7 +728,7 @@ var PluginManager = class {
755
728
  module: module.id
756
729
  }, {
757
730
  F: __dxlog_file2,
758
- L: 444,
731
+ L: 436,
759
732
  S: this,
760
733
  C: (f, a) => f(...a)
761
734
  });
@@ -784,7 +757,7 @@ var PluginManager = class {
784
757
  id
785
758
  }, {
786
759
  F: __dxlog_file2,
787
- L: 471,
760
+ L: 463,
788
761
  S: this,
789
762
  C: (f, a) => f(...a)
790
763
  });
@@ -793,7 +766,7 @@ var PluginManager = class {
793
766
  for (const capability of capabilities) {
794
767
  this.context.removeCapability(capability.interface, capability.implementation);
795
768
  const program = capability.deactivate?.();
796
- yield* Match.value(program).pipe(Match.when(Effect2.isEffect, (effect) => effect), Match.when(isPromise, (promise) => Effect2.tryPromise({
769
+ yield* Match.value(program).pipe(Match.when(Effect2.isEffect, (effect2) => effect2), Match.when(isPromise, (promise) => Effect2.tryPromise({
797
770
  try: () => promise,
798
771
  catch: (error) => error
799
772
  })), Match.orElse((program2) => Effect2.succeed(program2)));
@@ -808,7 +781,7 @@ var PluginManager = class {
808
781
  id
809
782
  }, {
810
783
  F: __dxlog_file2,
811
- L: 497,
784
+ L: 489,
812
785
  S: this,
813
786
  C: (f, a) => f(...a)
814
787
  });
@@ -822,7 +795,7 @@ var PluginManager = class {
822
795
  key
823
796
  }, {
824
797
  F: __dxlog_file2,
825
- L: 505,
798
+ L: 497,
826
799
  S: this,
827
800
  C: (f, a) => f(...a)
828
801
  });
@@ -865,7 +838,6 @@ var Capabilities;
865
838
  (function(Capabilities2) {
866
839
  Capabilities2.PluginManager = defineCapability("dxos.org/app-framework/capability/plugin-manager");
867
840
  Capabilities2.Null = defineCapability("dxos.org/app-framework/capability/null");
868
- Capabilities2.RxRegistry = defineCapability("dxos.org/app-framework/capability/rx-registry");
869
841
  Capabilities2.ReactContext = defineCapability("dxos.org/app-framework/capability/react-context");
870
842
  Capabilities2.ReactRoot = defineCapability("dxos.org/app-framework/capability/react-root");
871
843
  Capabilities2.ReactSurface = defineCapability("dxos.org/app-framework/common/react-surface");
@@ -884,27 +856,6 @@ var Capabilities;
884
856
  Capabilities2.FileUploader = defineCapability("dxos.org/app-framework/capability/file-uploader");
885
857
  })(Capabilities || (Capabilities = {}));
886
858
 
887
- // packages/sdk/app-framework/src/common/collaboration.ts
888
- import { Schema as Schema3, SchemaAST } from "effect";
889
- import { Expando, Ref } from "@dxos/echo-schema";
890
- import { SpaceId } from "@dxos/keys";
891
- var CollaborationActions;
892
- (function(CollaborationActions2) {
893
- class InsertContent extends Schema3.TaggedClass()("assistant/intent-content", {
894
- input: Schema3.Struct({
895
- spaceId: SpaceId,
896
- target: Ref(Expando),
897
- object: Ref(Expando),
898
- label: Schema3.String.pipe(Schema3.optional)
899
- }).annotations({
900
- [SchemaAST.DescriptionAnnotationId]: "Enables plugins to inject content blocks or references into a related entity."
901
- }),
902
- output: Schema3.Void
903
- }) {
904
- }
905
- CollaborationActions2.InsertContent = InsertContent;
906
- })(CollaborationActions || (CollaborationActions = {}));
907
-
908
859
  // packages/sdk/app-framework/src/common/events.ts
909
860
  var Events;
910
861
  (function(Events2) {
@@ -924,7 +875,7 @@ var Events;
924
875
  })(Events || (Events = {}));
925
876
 
926
877
  // packages/sdk/app-framework/src/common/file.ts
927
- import { Schema as Schema4 } from "effect";
878
+ import { Schema as S3 } from "effect";
928
879
  var defaultFileTypes = {
929
880
  images: [
930
881
  "png",
@@ -944,15 +895,15 @@ var defaultFileTypes = {
944
895
  "md"
945
896
  ]
946
897
  };
947
- var FileInfoSchema = Schema4.Struct({
948
- name: Schema4.String,
949
- type: Schema4.String,
950
- url: Schema4.optional(Schema4.String),
951
- cid: Schema4.optional(Schema4.String)
898
+ var FileInfoSchema = S3.Struct({
899
+ name: S3.String,
900
+ type: S3.String,
901
+ url: S3.optional(S3.String),
902
+ cid: S3.optional(S3.String)
952
903
  });
953
904
 
954
905
  // packages/sdk/app-framework/src/common/layout.ts
955
- import { Schema as Schema5 } from "effect";
906
+ import { Schema as S4 } from "effect";
956
907
 
957
908
  // packages/sdk/app-framework/src/plugin-intent/IntentPlugin.tsx
958
909
  var IntentPlugin = () => definePlugin({
@@ -968,7 +919,7 @@ var IntentPlugin = () => definePlugin({
968
919
  activatesAfter: [
969
920
  Events.DispatcherReady
970
921
  ],
971
- activate: lazy(() => import("./intent-dispatcher-ZUSNX2OY.mjs"))
922
+ activate: lazy(() => import("./intent-dispatcher-YDE2ONZA.mjs"))
972
923
  })
973
924
  ]);
974
925
 
@@ -978,323 +929,313 @@ var LAYOUT_ACTION = `${LAYOUT_PLUGIN}/action`;
978
929
  var LayoutAction;
979
930
  (function(LayoutAction2) {
980
931
  LayoutAction2.UPDATE_LAYOUT = `${LAYOUT_ACTION}/update-layout`;
981
- class UpdateLayout extends Schema5.TaggedClass()(LayoutAction2.UPDATE_LAYOUT, {
982
- input: Schema5.Struct({
983
- part: Schema5.String.annotations({
932
+ class UpdateLayout extends S4.TaggedClass()(LayoutAction2.UPDATE_LAYOUT, {
933
+ input: S4.Struct({
934
+ part: S4.String.annotations({
984
935
  description: "The part of the layout to mutate."
985
936
  }),
986
- subject: Schema5.optional(Schema5.Any.annotations({
937
+ subject: S4.optional(S4.Any.annotations({
987
938
  description: "The subject of the layout update."
988
939
  })),
989
- options: Schema5.optional(Schema5.Record({
990
- key: Schema5.String,
991
- value: Schema5.Any
940
+ options: S4.optional(S4.Record({
941
+ key: S4.String,
942
+ value: S4.Any
992
943
  }).annotations({
993
944
  description: "Additional options for the layout action."
994
945
  }))
995
946
  }),
996
- output: Schema5.Void
947
+ output: S4.Void
997
948
  }) {
998
949
  }
999
950
  LayoutAction2.UpdateLayout = UpdateLayout;
1000
- class SetLayoutMode extends Schema5.TaggedClass()(LayoutAction2.UPDATE_LAYOUT, {
1001
- input: Schema5.Struct({
1002
- part: Schema5.Literal("mode").annotations({
951
+ class SetLayoutMode extends S4.TaggedClass()(LayoutAction2.UPDATE_LAYOUT, {
952
+ input: S4.Struct({
953
+ part: S4.Literal("mode").annotations({
1003
954
  description: "Setting the layout mode."
1004
955
  }),
1005
- subject: Schema5.optional(Schema5.String.annotations({
956
+ subject: S4.optional(S4.String.annotations({
1006
957
  description: "Item which is the subject of the new layout mode."
1007
958
  })),
1008
- options: Schema5.Union(Schema5.Struct({
1009
- mode: Schema5.String.annotations({
959
+ options: S4.Union(S4.Struct({
960
+ mode: S4.String.annotations({
1010
961
  description: "The new layout mode."
1011
962
  })
1012
- }), Schema5.Struct({
1013
- revert: Schema5.Boolean.annotations({
963
+ }), S4.Struct({
964
+ revert: S4.Boolean.annotations({
1014
965
  description: "Revert to the previous layout mode."
1015
966
  })
1016
967
  }))
1017
968
  }),
1018
- output: Schema5.Void
969
+ output: S4.Void
1019
970
  }) {
1020
971
  }
1021
972
  LayoutAction2.SetLayoutMode = SetLayoutMode;
1022
- class UpdateSidebar extends Schema5.TaggedClass()(LayoutAction2.UPDATE_LAYOUT, {
1023
- input: Schema5.Struct({
1024
- part: Schema5.Literal("sidebar").annotations({
973
+ class UpdateSidebar extends S4.TaggedClass()(LayoutAction2.UPDATE_LAYOUT, {
974
+ input: S4.Struct({
975
+ part: S4.Literal("sidebar").annotations({
1025
976
  description: "Updating the sidebar."
1026
977
  }),
1027
- subject: Schema5.optional(Schema5.String.annotations({
978
+ subject: S4.optional(S4.String.annotations({
1028
979
  description: "URI of the component to display in the sidebar."
1029
980
  })),
1030
- options: Schema5.optional(Schema5.Struct({
1031
- state: Schema5.Literal("closed", "collapsed", "expanded").annotations({
981
+ options: S4.optional(S4.Struct({
982
+ state: S4.Literal("closed", "collapsed", "expanded").annotations({
1032
983
  description: "Whether the sidebar is closed, collapsed, or expanded."
1033
984
  })
1034
985
  }))
1035
986
  }),
1036
- output: Schema5.Void
987
+ output: S4.Void
1037
988
  }) {
1038
989
  }
1039
990
  LayoutAction2.UpdateSidebar = UpdateSidebar;
1040
- class UpdateComplementary extends Schema5.TaggedClass()(LayoutAction2.UPDATE_LAYOUT, {
1041
- input: Schema5.Struct({
1042
- part: Schema5.Literal("complementary").annotations({
991
+ class UpdateComplementary extends S4.TaggedClass()(LayoutAction2.UPDATE_LAYOUT, {
992
+ input: S4.Struct({
993
+ part: S4.Literal("complementary").annotations({
1043
994
  description: "Updating the complementary sidebar."
1044
995
  }),
1045
- subject: Schema5.optional(Schema5.String.annotations({
996
+ subject: S4.optional(S4.String.annotations({
1046
997
  description: "URI of the component to display in the complementary area."
1047
998
  })),
1048
- options: Schema5.optional(Schema5.Struct({
1049
- state: Schema5.Literal("closed", "collapsed", "expanded").annotations({
999
+ options: S4.optional(S4.Struct({
1000
+ state: S4.Literal("closed", "collapsed", "expanded").annotations({
1050
1001
  description: "Whether the complementary sidebar is closed, collapsed, or expanded."
1051
1002
  })
1052
1003
  }))
1053
1004
  }),
1054
- output: Schema5.Void
1005
+ output: S4.Void
1055
1006
  }) {
1056
1007
  }
1057
1008
  LayoutAction2.UpdateComplementary = UpdateComplementary;
1058
- class UpdateDialog extends Schema5.TaggedClass()(LayoutAction2.UPDATE_LAYOUT, {
1059
- input: Schema5.Struct({
1060
- part: Schema5.Literal("dialog").annotations({
1009
+ class UpdateDialog extends S4.TaggedClass()(LayoutAction2.UPDATE_LAYOUT, {
1010
+ input: S4.Struct({
1011
+ part: S4.Literal("dialog").annotations({
1061
1012
  description: "Updating the dialog."
1062
1013
  }),
1063
- subject: Schema5.optional(Schema5.String.annotations({
1014
+ subject: S4.optional(S4.String.annotations({
1064
1015
  description: "URI of the component to display in the dialog."
1065
1016
  })),
1066
- options: Schema5.Struct({
1067
- state: Schema5.optional(Schema5.Boolean.annotations({
1017
+ options: S4.Struct({
1018
+ state: S4.optional(S4.Boolean.annotations({
1068
1019
  description: "Whether the dialog is open or closed."
1069
1020
  })),
1070
- blockAlign: Schema5.optional(Schema5.Literal("start", "center", "end").annotations({
1021
+ blockAlign: S4.optional(S4.Literal("start", "center", "end").annotations({
1071
1022
  description: "The alignment of the dialog."
1072
1023
  })),
1073
- type: Schema5.optional(Schema5.Literal("default", "alert").annotations({
1024
+ type: S4.optional(S4.Literal("default", "alert").annotations({
1074
1025
  description: "The type of dialog."
1075
1026
  })),
1076
- props: Schema5.optional(Schema5.Record({
1077
- key: Schema5.String,
1078
- value: Schema5.Any
1027
+ props: S4.optional(S4.Record({
1028
+ key: S4.String,
1029
+ value: S4.Any
1079
1030
  }).annotations({
1080
1031
  description: "Additional props for the dialog."
1081
1032
  }))
1082
1033
  })
1083
1034
  }),
1084
- output: Schema5.Void
1035
+ output: S4.Void
1085
1036
  }) {
1086
1037
  }
1087
1038
  LayoutAction2.UpdateDialog = UpdateDialog;
1088
- class UpdatePopover extends Schema5.TaggedClass()(LayoutAction2.UPDATE_LAYOUT, {
1089
- input: Schema5.Struct({
1090
- part: Schema5.Literal("popover").annotations({
1039
+ class UpdatePopover extends S4.TaggedClass()(LayoutAction2.UPDATE_LAYOUT, {
1040
+ input: S4.Struct({
1041
+ part: S4.Literal("popover").annotations({
1091
1042
  description: "Updating the popover."
1092
1043
  }),
1093
- subject: Schema5.optional(Schema5.Any.annotations({
1094
- description: "URI of the component to display in the popover or data to pass to the popover."
1044
+ subject: S4.optional(S4.String.annotations({
1045
+ description: "URI of the component to display in the popover."
1095
1046
  })),
1096
- options: Schema5.Struct({
1097
- side: Schema5.optional(Schema5.Literal("top", "right", "bottom", "left").annotations({
1047
+ options: S4.Struct({
1048
+ anchorId: S4.String.annotations({
1049
+ description: "The id of the element to anchor the popover to."
1050
+ }),
1051
+ side: S4.optional(S4.Literal("top", "right", "bottom", "left").annotations({
1098
1052
  description: "The side of the anchor."
1099
1053
  })),
1100
- state: Schema5.optional(Schema5.Boolean.annotations({
1054
+ state: S4.optional(S4.Boolean.annotations({
1101
1055
  description: "Whether the popover is open or closed."
1102
1056
  })),
1103
- props: Schema5.optional(Schema5.Record({
1104
- key: Schema5.String,
1105
- value: Schema5.Any
1057
+ props: S4.optional(S4.Record({
1058
+ key: S4.String,
1059
+ value: S4.Any
1106
1060
  }).annotations({
1107
1061
  description: "Additional props for the popover."
1108
1062
  }))
1109
- }).pipe(Schema5.extend(Schema5.Union(Schema5.Struct({
1110
- variant: Schema5.Literal("virtual"),
1111
- anchor: Schema5.Any.annotations({
1112
- description: "The DOM element to anchor the popover to."
1113
- })
1114
- }), Schema5.Struct({
1115
- variant: Schema5.optional(Schema5.Literal("react")),
1116
- anchorId: Schema5.String.annotations({
1117
- description: "An id that can be used to determine whether to render the anchor subcomponent."
1118
- })
1119
- }))))
1063
+ })
1120
1064
  }),
1121
- output: Schema5.Void
1065
+ output: S4.Void
1122
1066
  }) {
1123
1067
  }
1124
1068
  LayoutAction2.UpdatePopover = UpdatePopover;
1125
- LayoutAction2.Toast = Schema5.Struct({
1126
- id: Schema5.String.annotations({
1069
+ LayoutAction2.Toast = S4.Struct({
1070
+ id: S4.String.annotations({
1127
1071
  description: "The id of the toast."
1128
1072
  }),
1129
- title: Schema5.optional(Label.annotations({
1073
+ title: S4.optional(Label.annotations({
1130
1074
  description: "The title of the toast."
1131
1075
  })),
1132
- description: Schema5.optional(Label.annotations({
1076
+ description: S4.optional(Label.annotations({
1133
1077
  description: "The description of the toast."
1134
1078
  })),
1135
- icon: Schema5.optional(Schema5.String.annotations({
1079
+ icon: S4.optional(S4.String.annotations({
1136
1080
  description: "The icon of the toast."
1137
1081
  })),
1138
- duration: Schema5.optional(Schema5.Number.annotations({
1082
+ duration: S4.optional(S4.Number.annotations({
1139
1083
  description: "The duration of the toast."
1140
1084
  })),
1141
- closeLabel: Schema5.optional(Label.annotations({
1085
+ closeLabel: S4.optional(Label.annotations({
1142
1086
  description: "The label of the close button."
1143
1087
  })),
1144
- actionLabel: Schema5.optional(Label.annotations({
1088
+ actionLabel: S4.optional(Label.annotations({
1145
1089
  description: "The label of the action button."
1146
1090
  })),
1147
- actionAlt: Schema5.optional(Label.annotations({
1091
+ actionAlt: S4.optional(Label.annotations({
1148
1092
  description: "The alt text of the action button."
1149
1093
  })),
1150
- onAction: Schema5.optional(Schema5.Any.annotations({
1094
+ onAction: S4.optional(S4.Any.annotations({
1151
1095
  description: "The action to perform when the action button is clicked."
1152
1096
  }))
1153
1097
  });
1154
- class AddToast extends Schema5.TaggedClass()(LayoutAction2.UPDATE_LAYOUT, {
1155
- input: Schema5.Struct({
1156
- part: Schema5.Literal("toast").annotations({
1098
+ class AddToast extends S4.TaggedClass()(LayoutAction2.UPDATE_LAYOUT, {
1099
+ input: S4.Struct({
1100
+ part: S4.Literal("toast").annotations({
1157
1101
  description: "Adding a toast."
1158
1102
  }),
1159
1103
  subject: LayoutAction2.Toast.annotations({
1160
1104
  description: "The toast to add."
1161
1105
  })
1162
1106
  }),
1163
- output: Schema5.Void
1107
+ output: S4.Void
1164
1108
  }) {
1165
1109
  }
1166
1110
  LayoutAction2.AddToast = AddToast;
1167
- class SwitchWorkspace extends Schema5.TaggedClass()(LayoutAction2.UPDATE_LAYOUT, {
1168
- input: Schema5.Struct({
1169
- part: Schema5.Literal("workspace").annotations({
1111
+ class SwitchWorkspace extends S4.TaggedClass()(LayoutAction2.UPDATE_LAYOUT, {
1112
+ input: S4.Struct({
1113
+ part: S4.Literal("workspace").annotations({
1170
1114
  description: "Switching the workspace."
1171
1115
  }),
1172
- subject: Schema5.String.annotations({
1116
+ subject: S4.String.annotations({
1173
1117
  description: "The id of the workspace to switch to."
1174
1118
  })
1175
1119
  }),
1176
- output: Schema5.Void
1120
+ output: S4.Void
1177
1121
  }) {
1178
1122
  }
1179
1123
  LayoutAction2.SwitchWorkspace = SwitchWorkspace;
1180
- class RevertWorkspace extends Schema5.TaggedClass()(LayoutAction2.UPDATE_LAYOUT, {
1181
- input: Schema5.Struct({
1182
- part: Schema5.Literal("workspace").annotations({
1124
+ class RevertWorkspace extends S4.TaggedClass()(LayoutAction2.UPDATE_LAYOUT, {
1125
+ input: S4.Struct({
1126
+ part: S4.Literal("workspace").annotations({
1183
1127
  description: "Switching the workspace."
1184
1128
  }),
1185
- options: Schema5.Struct({
1186
- revert: Schema5.Literal(true).annotations({
1129
+ options: S4.Struct({
1130
+ revert: S4.Literal(true).annotations({
1187
1131
  description: "Revert to the previous workspace."
1188
1132
  })
1189
1133
  })
1190
1134
  }),
1191
- output: Schema5.Void
1135
+ output: S4.Void
1192
1136
  }) {
1193
1137
  }
1194
1138
  LayoutAction2.RevertWorkspace = RevertWorkspace;
1195
- class Open extends Schema5.TaggedClass()(LayoutAction2.UPDATE_LAYOUT, {
1196
- input: Schema5.Struct({
1197
- part: Schema5.Literal("main").annotations({
1139
+ class Open extends S4.TaggedClass()(LayoutAction2.UPDATE_LAYOUT, {
1140
+ input: S4.Struct({
1141
+ part: S4.Literal("main").annotations({
1198
1142
  description: "Opening an item in the main content area."
1199
1143
  }),
1200
- subject: Schema5.Array(Schema5.String.annotations({
1144
+ subject: S4.Array(S4.String.annotations({
1201
1145
  description: "Ids of the items to open."
1202
1146
  })),
1203
- options: Schema5.optional(Schema5.Struct({
1204
- state: Schema5.optional(Schema5.Literal(true).annotations({
1147
+ options: S4.optional(S4.Struct({
1148
+ state: S4.optional(S4.Literal(true).annotations({
1205
1149
  description: "The items are being added."
1206
1150
  })),
1207
- variant: Schema5.optional(Schema5.String.annotations({
1151
+ variant: S4.optional(S4.String.annotations({
1208
1152
  description: "The variant of the item to open."
1209
1153
  })),
1210
- key: Schema5.optional(Schema5.String.annotations({
1154
+ key: S4.optional(S4.String.annotations({
1211
1155
  description: "If provided, will replace item with a matching key (id prefix)."
1212
1156
  })),
1213
- workspace: Schema5.optional(Schema5.String.annotations({
1214
- description: "The workspace to open the items in."
1215
- })),
1216
- scrollIntoView: Schema5.optional(Schema5.Boolean.annotations({
1157
+ scrollIntoView: S4.optional(S4.Boolean.annotations({
1217
1158
  description: "Scroll the items into view."
1218
1159
  })),
1219
- pivotId: Schema5.optional(Schema5.String.annotations({
1160
+ pivotId: S4.optional(S4.String.annotations({
1220
1161
  description: "The id of the item to place new items next to."
1221
1162
  })),
1222
- positioning: Schema5.optional(Schema5.Union(Schema5.Literal("start").annotations({
1163
+ positioning: S4.optional(S4.Union(S4.Literal("start").annotations({
1223
1164
  description: "The items are being added before the pivot item."
1224
- }), Schema5.Literal("end").annotations({
1165
+ }), S4.Literal("end").annotations({
1225
1166
  description: "The items are being added after the pivot item."
1226
1167
  })))
1227
1168
  }))
1228
1169
  }),
1229
- output: Schema5.Void
1170
+ output: S4.Void
1230
1171
  }) {
1231
1172
  }
1232
1173
  LayoutAction2.Open = Open;
1233
- class Set2 extends Schema5.TaggedClass()(LayoutAction2.UPDATE_LAYOUT, {
1234
- input: Schema5.Struct({
1235
- part: Schema5.Literal("main").annotations({
1174
+ class Set2 extends S4.TaggedClass()(LayoutAction2.UPDATE_LAYOUT, {
1175
+ input: S4.Struct({
1176
+ part: S4.Literal("main").annotations({
1236
1177
  description: "Setting items in the main content area."
1237
1178
  }),
1238
- subject: Schema5.Array(Schema5.String.annotations({
1179
+ subject: S4.Array(S4.String.annotations({
1239
1180
  description: "Ids of the items to set."
1240
1181
  })),
1241
- options: Schema5.Struct({
1242
- override: Schema5.Literal(true).annotations({
1182
+ options: S4.Struct({
1183
+ override: S4.Literal(true).annotations({
1243
1184
  description: "Override the current items in the main content area."
1244
1185
  })
1245
1186
  })
1246
1187
  }),
1247
- output: Schema5.Void
1188
+ output: S4.Void
1248
1189
  }) {
1249
1190
  }
1250
1191
  LayoutAction2.Set = Set2;
1251
- class Close extends Schema5.TaggedClass()(LayoutAction2.UPDATE_LAYOUT, {
1252
- input: Schema5.Struct({
1253
- part: Schema5.Literal("main").annotations({
1192
+ class Close extends S4.TaggedClass()(LayoutAction2.UPDATE_LAYOUT, {
1193
+ input: S4.Struct({
1194
+ part: S4.Literal("main").annotations({
1254
1195
  description: "Closing items in the main content area."
1255
1196
  }),
1256
- subject: Schema5.Array(Schema5.String.annotations({
1197
+ subject: S4.Array(S4.String.annotations({
1257
1198
  description: "Ids of the items to close."
1258
1199
  })),
1259
- options: Schema5.Struct({
1260
- state: Schema5.Literal(false).annotations({
1200
+ options: S4.Struct({
1201
+ state: S4.Literal(false).annotations({
1261
1202
  description: "The items are being removed."
1262
1203
  })
1263
1204
  })
1264
1205
  }),
1265
- output: Schema5.Void
1206
+ output: S4.Void
1266
1207
  }) {
1267
1208
  }
1268
1209
  LayoutAction2.Close = Close;
1269
- class ScrollIntoView extends Schema5.TaggedClass()(LayoutAction2.UPDATE_LAYOUT, {
1270
- input: Schema5.Struct({
1271
- part: Schema5.Literal("current").annotations({
1210
+ class ScrollIntoView extends S4.TaggedClass()(LayoutAction2.UPDATE_LAYOUT, {
1211
+ input: S4.Struct({
1212
+ part: S4.Literal("current").annotations({
1272
1213
  description: "Setting the current item"
1273
1214
  }),
1274
- subject: Schema5.optional(Schema5.String.annotations({
1215
+ subject: S4.optional(S4.String.annotations({
1275
1216
  description: "The id of the item to set as current."
1276
1217
  })),
1277
- options: Schema5.optional(Schema5.Record({
1278
- key: Schema5.String,
1279
- value: Schema5.Any
1218
+ options: S4.optional(S4.Record({
1219
+ key: S4.String,
1220
+ value: S4.Any
1280
1221
  }).annotations({
1281
1222
  description: "Additional options for the scroll into view."
1282
1223
  }))
1283
1224
  }),
1284
- output: Schema5.Void
1225
+ output: S4.Void
1285
1226
  }) {
1286
1227
  }
1287
1228
  LayoutAction2.ScrollIntoView = ScrollIntoView;
1288
- class Expose extends Schema5.TaggedClass()(LayoutAction2.UPDATE_LAYOUT, {
1289
- input: Schema5.Struct({
1290
- part: Schema5.Literal("navigation").annotations({
1229
+ class Expose extends S4.TaggedClass()(LayoutAction2.UPDATE_LAYOUT, {
1230
+ input: S4.Struct({
1231
+ part: S4.Literal("navigation").annotations({
1291
1232
  description: "Exposing an item in the navigation area."
1292
1233
  }),
1293
- subject: Schema5.String.annotations({
1234
+ subject: S4.String.annotations({
1294
1235
  description: "The id of the item to expose."
1295
1236
  })
1296
1237
  }),
1297
- output: Schema5.Void
1238
+ output: S4.Void
1298
1239
  }) {
1299
1240
  }
1300
1241
  LayoutAction2.Expose = Expose;
@@ -1304,17 +1245,17 @@ var LayoutAction;
1304
1245
  var createSurface = (definition) => definition;
1305
1246
 
1306
1247
  // packages/sdk/app-framework/src/common/translations.ts
1307
- import { Schema as Schema6 } from "effect";
1308
- var ResourceKey = Schema6.Union(Schema6.String, Schema6.Record({
1309
- key: Schema6.String,
1310
- value: Schema6.Any
1248
+ import { Schema as S5 } from "effect";
1249
+ var ResourceKey = S5.Union(S5.String, S5.Record({
1250
+ key: S5.String,
1251
+ value: S5.Any
1311
1252
  }));
1312
- var ResourceLanguage = Schema6.Record({
1313
- key: Schema6.String,
1253
+ var ResourceLanguage = S5.Record({
1254
+ key: S5.String,
1314
1255
  value: ResourceKey
1315
1256
  });
1316
- var Resource = Schema6.Record({
1317
- key: Schema6.String,
1257
+ var Resource = S5.Record({
1258
+ key: S5.String,
1318
1259
  value: ResourceLanguage
1319
1260
  });
1320
1261
 
@@ -1325,14 +1266,14 @@ var HISTORY_LIMIT = 100;
1325
1266
  var createResolver = (resolver) => resolver;
1326
1267
  var isUndoable = (historyEntry) => historyEntry.length > 0 && historyEntry.every(({ undoable }) => !!undoable);
1327
1268
  var createDispatcher = (getResolvers, { executionLimit = EXECUTION_LIMIT, historyLimit = HISTORY_LIMIT } = {}) => {
1328
- const historyRef = Effect3.runSync(Ref2.make([]));
1269
+ const historyRef = Effect3.runSync(Ref.make([]));
1329
1270
  const handleIntent = (intent) => Effect3.gen(function* () {
1330
- const candidates = getResolvers().filter((resolver) => resolver.intent._tag === intent.id).filter((resolver) => !resolver.filter || resolver.filter(intent.data)).toSorted(byPosition);
1271
+ const candidates = getResolvers(intent.module).filter((resolver) => resolver.intent._tag === intent.id).filter((resolver) => !resolver.filter || resolver.filter(intent.data)).toSorted(byPosition);
1331
1272
  if (candidates.length === 0) {
1332
1273
  yield* Effect3.fail(new NoResolversError(intent.id));
1333
1274
  }
1334
- const effect = candidates[0].resolve(intent.data, intent.undo ?? false);
1335
- const result = Effect3.isEffect(effect) ? yield* effect : yield* Effect3.promise(async () => effect);
1275
+ const effect2 = candidates[0].resolve(intent.data, intent.undo ?? false);
1276
+ const result = Effect3.isEffect(effect2) ? yield* effect2 : yield* Effect3.promise(async () => effect2);
1336
1277
  return {
1337
1278
  _intent: intent,
1338
1279
  ...result
@@ -1343,7 +1284,7 @@ var createDispatcher = (getResolvers, { executionLimit = EXECUTION_LIMIT, histor
1343
1284
  if (depth > executionLimit) {
1344
1285
  yield* Effect3.fail(new CycleDetectedError());
1345
1286
  }
1346
- const resultsRef = yield* Ref2.make([]);
1287
+ const resultsRef = yield* Ref.make([]);
1347
1288
  for (const intent of intentChain.all) {
1348
1289
  const { data: prev } = (yield* resultsRef.get)[0] ?? {};
1349
1290
  const result2 = yield* handleIntent({
@@ -1353,7 +1294,7 @@ var createDispatcher = (getResolvers, { executionLimit = EXECUTION_LIMIT, histor
1353
1294
  ...prev
1354
1295
  }
1355
1296
  });
1356
- yield* Ref2.update(resultsRef, (results2) => [
1297
+ yield* Ref.update(resultsRef, (results2) => [
1357
1298
  result2,
1358
1299
  ...results2
1359
1300
  ]);
@@ -1368,7 +1309,7 @@ var createDispatcher = (getResolvers, { executionLimit = EXECUTION_LIMIT, histor
1368
1309
  }
1369
1310
  const results = yield* resultsRef.get;
1370
1311
  const result = results[0];
1371
- yield* Ref2.update(historyRef, (history) => {
1312
+ yield* Ref.update(historyRef, (history) => {
1372
1313
  const next = [
1373
1314
  ...history,
1374
1315
  results
@@ -1392,7 +1333,7 @@ var createDispatcher = (getResolvers, { executionLimit = EXECUTION_LIMIT, histor
1392
1333
  })).catch((error) => {
1393
1334
  log3.catch(error, void 0, {
1394
1335
  F: __dxlog_file3,
1395
- L: 270,
1336
+ L: 254,
1396
1337
  S: void 0,
1397
1338
  C: (f, a) => f(...a)
1398
1339
  });
@@ -1424,7 +1365,7 @@ var createDispatcher = (getResolvers, { executionLimit = EXECUTION_LIMIT, histor
1424
1365
  last: all.at(-1),
1425
1366
  all
1426
1367
  };
1427
- yield* Ref2.update(historyRef, (h) => h.filter((_, index) => index !== last));
1368
+ yield* Ref.update(historyRef, (h) => h.filter((_, index) => index !== last));
1428
1369
  return yield* dispatch(intent);
1429
1370
  }
1430
1371
  });
@@ -1446,14 +1387,16 @@ var createDispatcher = (getResolvers, { executionLimit = EXECUTION_LIMIT, histor
1446
1387
  var defaultEffect = () => Effect3.fail(new Error("Intent runtime not ready"));
1447
1388
  var defaultPromise = () => Effect3.runPromise(defaultEffect());
1448
1389
  var intent_dispatcher_default = (context) => {
1449
- const state = live2({
1390
+ const state = create3({
1450
1391
  dispatch: defaultEffect,
1451
1392
  dispatchPromise: defaultPromise,
1452
1393
  undo: defaultEffect,
1453
1394
  undoPromise: defaultPromise
1454
1395
  });
1455
- const { dispatch, dispatchPromise, undo, undoPromise } = createDispatcher(() => context.getCapabilities(Capabilities.IntentResolver).flat());
1456
- const manager = context.getCapability(Capabilities.PluginManager);
1396
+ const { dispatch, dispatchPromise, undo, undoPromise } = createDispatcher((module) => context.requestCapabilities(Capabilities.IntentResolver, (c, moduleId) => {
1397
+ return module ? moduleId === module : true;
1398
+ }).flat());
1399
+ const manager = context.requestCapability(Capabilities.PluginManager);
1457
1400
  state.dispatch = (intentChain, depth) => {
1458
1401
  return Effect3.gen(function* () {
1459
1402
  yield* manager._activate(Events.SetupIntentResolver);
@@ -1473,7 +1416,7 @@ export {
1473
1416
  defineCapability,
1474
1417
  contributes,
1475
1418
  lazy,
1476
- PluginContext,
1419
+ PluginsContext,
1477
1420
  defineEvent,
1478
1421
  eventKey,
1479
1422
  oneOf,
@@ -1487,7 +1430,6 @@ export {
1487
1430
  Plugin,
1488
1431
  definePlugin,
1489
1432
  Capabilities,
1490
- CollaborationActions,
1491
1433
  Events,
1492
1434
  defaultFileTypes,
1493
1435
  FileInfoSchema,
@@ -1509,4 +1451,4 @@ export {
1509
1451
  ResourceLanguage,
1510
1452
  Resource
1511
1453
  };
1512
- //# sourceMappingURL=chunk-BOEJMAVK.mjs.map
1454
+ //# sourceMappingURL=chunk-AHKIPS2L.mjs.map