@dxos/app-framework 0.7.4 → 0.7.5-feature-compute.4d9d99a

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 (327) hide show
  1. package/dist/lib/browser/chunk-EGGZVV7Q.mjs +1595 -0
  2. package/dist/lib/browser/chunk-EGGZVV7Q.mjs.map +7 -0
  3. package/dist/lib/browser/index.mjs +136 -527
  4. package/dist/lib/browser/index.mjs.map +4 -4
  5. package/dist/lib/browser/meta.json +1 -1
  6. package/dist/lib/browser/testing/index.mjs +67 -0
  7. package/dist/lib/browser/testing/index.mjs.map +7 -0
  8. package/dist/lib/node/chunk-UBX6GP2N.cjs +1639 -0
  9. package/dist/lib/node/chunk-UBX6GP2N.cjs.map +7 -0
  10. package/dist/lib/node/index.cjs +141 -551
  11. package/dist/lib/node/index.cjs.map +4 -4
  12. package/dist/lib/node/meta.json +1 -1
  13. package/dist/lib/node/testing/index.cjs +91 -0
  14. package/dist/lib/node/testing/index.cjs.map +7 -0
  15. package/dist/lib/node-esm/chunk-HG5P55WF.mjs +1597 -0
  16. package/dist/lib/node-esm/chunk-HG5P55WF.mjs.map +7 -0
  17. package/dist/lib/node-esm/index.mjs +136 -527
  18. package/dist/lib/node-esm/index.mjs.map +4 -4
  19. package/dist/lib/node-esm/meta.json +1 -1
  20. package/dist/lib/node-esm/testing/index.mjs +68 -0
  21. package/dist/lib/node-esm/testing/index.mjs.map +7 -0
  22. package/dist/types/src/App.d.ts +22 -13
  23. package/dist/types/src/App.d.ts.map +1 -1
  24. package/dist/types/src/common/capabilities.d.ts +340 -0
  25. package/dist/types/src/common/capabilities.d.ts.map +1 -0
  26. package/dist/types/src/common/events.d.ts +41 -0
  27. package/dist/types/src/common/events.d.ts.map +1 -0
  28. package/dist/types/src/common/file.d.ts +14 -0
  29. package/dist/types/src/common/file.d.ts.map +1 -0
  30. package/dist/types/src/common/graph.d.ts +21 -0
  31. package/dist/types/src/common/graph.d.ts.map +1 -0
  32. package/dist/types/src/{plugins/common → common}/index.d.ts +3 -1
  33. package/dist/types/src/common/index.d.ts.map +1 -0
  34. package/dist/types/src/common/layout.d.ts +165 -0
  35. package/dist/types/src/common/layout.d.ts.map +1 -0
  36. package/dist/types/src/{plugins/common → common}/navigation.d.ts +77 -32
  37. package/dist/types/src/common/navigation.d.ts.map +1 -0
  38. package/dist/types/src/common/surface.d.ts +68 -0
  39. package/dist/types/src/common/surface.d.ts.map +1 -0
  40. package/dist/types/src/{plugins/common → common}/translations.d.ts +0 -11
  41. package/dist/types/src/common/translations.d.ts.map +1 -0
  42. package/dist/types/src/core/capabilities.d.ts +90 -0
  43. package/dist/types/src/core/capabilities.d.ts.map +1 -0
  44. package/dist/types/src/core/capabilities.test.d.ts +2 -0
  45. package/dist/types/src/core/capabilities.test.d.ts.map +1 -0
  46. package/dist/types/src/core/events.d.ts +58 -0
  47. package/dist/types/src/core/events.d.ts.map +1 -0
  48. package/dist/types/src/core/index.d.ts +5 -0
  49. package/dist/types/src/core/index.d.ts.map +1 -0
  50. package/dist/types/src/core/manager.d.ts +126 -0
  51. package/dist/types/src/core/manager.d.ts.map +1 -0
  52. package/dist/types/src/core/manager.test.d.ts +2 -0
  53. package/dist/types/src/core/manager.test.d.ts.map +1 -0
  54. package/dist/types/src/core/plugin.d.ts +94 -0
  55. package/dist/types/src/core/plugin.d.ts.map +1 -0
  56. package/dist/types/src/helpers.d.ts +10 -0
  57. package/dist/types/src/helpers.d.ts.map +1 -0
  58. package/dist/types/src/helpers.test.d.ts +2 -0
  59. package/dist/types/src/helpers.test.d.ts.map +1 -0
  60. package/dist/types/src/index.d.ts +5 -1
  61. package/dist/types/src/index.d.ts.map +1 -1
  62. package/dist/types/src/playground/debug/Debug.d.ts +6 -0
  63. package/dist/types/src/playground/debug/Debug.d.ts.map +1 -0
  64. package/dist/types/src/playground/debug/index.d.ts +2 -0
  65. package/dist/types/src/playground/debug/index.d.ts.map +1 -0
  66. package/dist/types/src/playground/debug/plugin.d.ts +2 -0
  67. package/dist/types/src/playground/debug/plugin.d.ts.map +1 -0
  68. package/dist/types/src/playground/generator/Main.d.ts +6 -0
  69. package/dist/types/src/playground/generator/Main.d.ts.map +1 -0
  70. package/dist/types/src/playground/generator/Toolbar.d.ts +6 -0
  71. package/dist/types/src/playground/generator/Toolbar.d.ts.map +1 -0
  72. package/dist/types/src/playground/generator/generator.d.ts +5 -0
  73. package/dist/types/src/playground/generator/generator.d.ts.map +1 -0
  74. package/dist/types/src/playground/generator/index.d.ts +3 -0
  75. package/dist/types/src/playground/generator/index.d.ts.map +1 -0
  76. package/dist/types/src/playground/generator/plugin.d.ts +2 -0
  77. package/dist/types/src/playground/generator/plugin.d.ts.map +1 -0
  78. package/dist/types/src/playground/layout/Layout.d.ts +8 -0
  79. package/dist/types/src/playground/layout/Layout.d.ts.map +1 -0
  80. package/dist/types/src/playground/layout/index.d.ts +2 -0
  81. package/dist/types/src/playground/layout/index.d.ts.map +1 -0
  82. package/dist/types/src/playground/layout/plugin.d.ts +2 -0
  83. package/dist/types/src/playground/layout/plugin.d.ts.map +1 -0
  84. package/dist/types/src/playground/logger/Toolbar.d.ts +6 -0
  85. package/dist/types/src/playground/logger/Toolbar.d.ts.map +1 -0
  86. package/dist/types/src/playground/logger/index.d.ts +2 -0
  87. package/dist/types/src/playground/logger/index.d.ts.map +1 -0
  88. package/dist/types/src/playground/logger/plugin.d.ts +2 -0
  89. package/dist/types/src/playground/logger/plugin.d.ts.map +1 -0
  90. package/dist/types/src/playground/logger/schema.d.ts +13 -0
  91. package/dist/types/src/playground/logger/schema.d.ts.map +1 -0
  92. package/dist/types/src/playground/playground.stories.d.ts +10 -0
  93. package/dist/types/src/playground/playground.stories.d.ts.map +1 -0
  94. package/dist/types/src/plugin-intent/IntentContext.d.ts +8 -0
  95. package/dist/types/src/plugin-intent/IntentContext.d.ts.map +1 -0
  96. package/dist/types/src/plugin-intent/IntentPlugin.d.ts +2 -0
  97. package/dist/types/src/plugin-intent/IntentPlugin.d.ts.map +1 -0
  98. package/dist/types/src/plugin-intent/actions.d.ts +23 -0
  99. package/dist/types/src/plugin-intent/actions.d.ts.map +1 -0
  100. package/dist/types/src/plugin-intent/errors.d.ts +16 -0
  101. package/dist/types/src/plugin-intent/errors.d.ts.map +1 -0
  102. package/dist/types/src/plugin-intent/index.d.ts +6 -0
  103. package/dist/types/src/plugin-intent/index.d.ts.map +1 -0
  104. package/dist/types/src/plugin-intent/intent-dispatcher.d.ts +106 -0
  105. package/dist/types/src/plugin-intent/intent-dispatcher.d.ts.map +1 -0
  106. package/dist/types/src/plugin-intent/intent-dispatcher.test.d.ts +2 -0
  107. package/dist/types/src/plugin-intent/intent-dispatcher.test.d.ts.map +1 -0
  108. package/dist/types/src/plugin-intent/intent.d.ts +68 -0
  109. package/dist/types/src/plugin-intent/intent.d.ts.map +1 -0
  110. package/dist/types/src/plugin-settings/SettingsPlugin.d.ts +2 -0
  111. package/dist/types/src/plugin-settings/SettingsPlugin.d.ts.map +1 -0
  112. package/dist/types/src/plugin-settings/actions.d.ts +17 -0
  113. package/dist/types/src/plugin-settings/actions.d.ts.map +1 -0
  114. package/dist/types/src/plugin-settings/index.d.ts +3 -0
  115. package/dist/types/src/plugin-settings/index.d.ts.map +1 -0
  116. package/dist/types/src/react/ErrorBoundary.d.ts.map +1 -0
  117. package/dist/types/src/react/PluginManagerProvider.d.ts +10 -0
  118. package/dist/types/src/react/PluginManagerProvider.d.ts.map +1 -0
  119. package/dist/types/src/react/Surface.d.ts +12 -0
  120. package/dist/types/src/react/Surface.d.ts.map +1 -0
  121. package/dist/types/src/react/index.d.ts +5 -0
  122. package/dist/types/src/react/index.d.ts.map +1 -0
  123. package/dist/types/src/react/useCapabilities.d.ts +13 -0
  124. package/dist/types/src/react/useCapabilities.d.ts.map +1 -0
  125. package/dist/types/src/testing/index.d.ts +2 -0
  126. package/dist/types/src/testing/index.d.ts.map +1 -0
  127. package/dist/types/src/testing/withPluginManager.d.ts +10 -0
  128. package/dist/types/src/testing/withPluginManager.d.ts.map +1 -0
  129. package/dist/types/src/testing/withPluginManager.stories.d.ts +5 -0
  130. package/dist/types/src/testing/withPluginManager.stories.d.ts.map +1 -0
  131. package/dist/types/tsconfig.tsbuildinfo +1 -0
  132. package/package.json +30 -14
  133. package/project.json +2 -1
  134. package/src/App.tsx +138 -34
  135. package/src/common/capabilities.ts +82 -0
  136. package/src/common/events.ts +63 -0
  137. package/src/common/file.ts +22 -0
  138. package/src/common/graph.ts +30 -0
  139. package/src/{plugins/common → common}/index.ts +3 -1
  140. package/src/common/layout.ts +157 -0
  141. package/src/{plugins/common → common}/navigation.ts +59 -45
  142. package/src/common/surface.ts +81 -0
  143. package/src/common/translations.ts +18 -0
  144. package/src/core/capabilities.test.ts +116 -0
  145. package/src/core/capabilities.ts +213 -0
  146. package/src/core/events.ts +58 -0
  147. package/src/core/index.ts +8 -0
  148. package/src/core/manager.test.ts +567 -0
  149. package/src/core/manager.ts +497 -0
  150. package/src/core/plugin.ts +128 -0
  151. package/src/helpers.test.ts +97 -0
  152. package/src/helpers.ts +45 -0
  153. package/src/index.ts +6 -3
  154. package/src/playground/debug/Debug.tsx +39 -0
  155. package/src/playground/debug/index.ts +5 -0
  156. package/src/playground/debug/plugin.ts +17 -0
  157. package/src/playground/generator/Main.tsx +71 -0
  158. package/src/playground/generator/Toolbar.tsx +46 -0
  159. package/src/playground/generator/generator.ts +23 -0
  160. package/src/playground/generator/index.ts +6 -0
  161. package/src/playground/generator/plugin.ts +18 -0
  162. package/src/playground/layout/Layout.tsx +33 -0
  163. package/src/playground/layout/index.ts +5 -0
  164. package/src/playground/layout/plugin.ts +17 -0
  165. package/src/playground/logger/Toolbar.tsx +28 -0
  166. package/src/playground/logger/index.ts +5 -0
  167. package/src/playground/logger/plugin.ts +33 -0
  168. package/src/playground/logger/schema.ts +12 -0
  169. package/src/playground/playground.stories.tsx +34 -0
  170. package/src/plugin-intent/IntentContext.tsx +34 -0
  171. package/src/plugin-intent/IntentPlugin.tsx +60 -0
  172. package/src/plugin-intent/actions.ts +22 -0
  173. package/src/plugin-intent/errors.ts +39 -0
  174. package/src/plugin-intent/index.ts +9 -0
  175. package/src/plugin-intent/intent-dispatcher.test.ts +280 -0
  176. package/src/plugin-intent/intent-dispatcher.ts +269 -0
  177. package/src/plugin-intent/intent.ts +146 -0
  178. package/src/plugin-settings/SettingsPlugin.ts +29 -0
  179. package/src/plugin-settings/actions.ts +17 -0
  180. package/src/plugin-settings/index.ts +6 -0
  181. package/src/react/PluginManagerProvider.ts +22 -0
  182. package/src/react/Surface.tsx +72 -0
  183. package/src/react/index.ts +8 -0
  184. package/src/react/useCapabilities.ts +40 -0
  185. package/src/testing/index.ts +5 -0
  186. package/src/testing/withPluginManager.stories.tsx +47 -0
  187. package/src/testing/withPluginManager.tsx +67 -0
  188. package/tsconfig.json +51 -2
  189. package/dist/lib/browser/chunk-3E7RY3CE.mjs +0 -72
  190. package/dist/lib/browser/chunk-3E7RY3CE.mjs.map +0 -7
  191. package/dist/lib/browser/chunk-653Y45CL.mjs +0 -41
  192. package/dist/lib/browser/chunk-653Y45CL.mjs.map +0 -7
  193. package/dist/lib/browser/chunk-FRXJ25VI.mjs +0 -214
  194. package/dist/lib/browser/chunk-FRXJ25VI.mjs.map +0 -7
  195. package/dist/lib/browser/chunk-YXM35XRE.mjs +0 -213
  196. package/dist/lib/browser/chunk-YXM35XRE.mjs.map +0 -7
  197. package/dist/lib/browser/plugin-intent-LU4KL2RO.mjs +0 -22
  198. package/dist/lib/browser/plugin-intent-LU4KL2RO.mjs.map +0 -7
  199. package/dist/lib/browser/plugin-settings-OM3G2QFY.mjs +0 -11
  200. package/dist/lib/browser/plugin-settings-OM3G2QFY.mjs.map +0 -7
  201. package/dist/lib/browser/plugin-surface-LECZMKSQ.mjs +0 -24
  202. package/dist/lib/browser/plugin-surface-LECZMKSQ.mjs.map +0 -7
  203. package/dist/lib/node/chunk-JZ2JVKRY.cjs +0 -58
  204. package/dist/lib/node/chunk-JZ2JVKRY.cjs.map +0 -7
  205. package/dist/lib/node/chunk-QBM42OQ6.cjs +0 -97
  206. package/dist/lib/node/chunk-QBM42OQ6.cjs.map +0 -7
  207. package/dist/lib/node/chunk-QSVP5HOW.cjs +0 -238
  208. package/dist/lib/node/chunk-QSVP5HOW.cjs.map +0 -7
  209. package/dist/lib/node/chunk-SOVLKUWI.cjs +0 -236
  210. package/dist/lib/node/chunk-SOVLKUWI.cjs.map +0 -7
  211. package/dist/lib/node/plugin-intent-FVFR2LKB.cjs +0 -43
  212. package/dist/lib/node/plugin-intent-FVFR2LKB.cjs.map +0 -7
  213. package/dist/lib/node/plugin-settings-OZ6IKAE5.cjs +0 -32
  214. package/dist/lib/node/plugin-settings-OZ6IKAE5.cjs.map +0 -7
  215. package/dist/lib/node/plugin-surface-YWDRXQTD.cjs +0 -45
  216. package/dist/lib/node/plugin-surface-YWDRXQTD.cjs.map +0 -7
  217. package/dist/lib/node-esm/chunk-2R4GVK7O.mjs +0 -215
  218. package/dist/lib/node-esm/chunk-2R4GVK7O.mjs.map +0 -7
  219. package/dist/lib/node-esm/chunk-EYCTSFEJ.mjs +0 -74
  220. package/dist/lib/node-esm/chunk-EYCTSFEJ.mjs.map +0 -7
  221. package/dist/lib/node-esm/chunk-YFMFQBB4.mjs +0 -214
  222. package/dist/lib/node-esm/chunk-YFMFQBB4.mjs.map +0 -7
  223. package/dist/lib/node-esm/chunk-YNU7FTGJ.mjs +0 -43
  224. package/dist/lib/node-esm/chunk-YNU7FTGJ.mjs.map +0 -7
  225. package/dist/lib/node-esm/plugin-intent-V7ER24Y6.mjs +0 -23
  226. package/dist/lib/node-esm/plugin-intent-V7ER24Y6.mjs.map +0 -7
  227. package/dist/lib/node-esm/plugin-settings-37UVWF2V.mjs +0 -12
  228. package/dist/lib/node-esm/plugin-settings-37UVWF2V.mjs.map +0 -7
  229. package/dist/lib/node-esm/plugin-surface-TEU42XQN.mjs +0 -25
  230. package/dist/lib/node-esm/plugin-surface-TEU42XQN.mjs.map +0 -7
  231. package/dist/types/src/plugins/common/file.d.ts +0 -22
  232. package/dist/types/src/plugins/common/file.d.ts.map +0 -1
  233. package/dist/types/src/plugins/common/graph.d.ts +0 -51
  234. package/dist/types/src/plugins/common/graph.d.ts.map +0 -1
  235. package/dist/types/src/plugins/common/index.d.ts.map +0 -1
  236. package/dist/types/src/plugins/common/layout.d.ts +0 -202
  237. package/dist/types/src/plugins/common/layout.d.ts.map +0 -1
  238. package/dist/types/src/plugins/common/metadata.d.ts +0 -16
  239. package/dist/types/src/plugins/common/metadata.d.ts.map +0 -1
  240. package/dist/types/src/plugins/common/navigation.d.ts.map +0 -1
  241. package/dist/types/src/plugins/common/translations.d.ts.map +0 -1
  242. package/dist/types/src/plugins/helpers.d.ts +0 -41
  243. package/dist/types/src/plugins/helpers.d.ts.map +0 -1
  244. package/dist/types/src/plugins/index.d.ts +0 -7
  245. package/dist/types/src/plugins/index.d.ts.map +0 -1
  246. package/dist/types/src/plugins/plugin-host/HostPlugin.d.ts +0 -21
  247. package/dist/types/src/plugins/plugin-host/HostPlugin.d.ts.map +0 -1
  248. package/dist/types/src/plugins/plugin-host/PluginContainer.d.ts +0 -14
  249. package/dist/types/src/plugins/plugin-host/PluginContainer.d.ts.map +0 -1
  250. package/dist/types/src/plugins/plugin-host/PluginContext.d.ts +0 -47
  251. package/dist/types/src/plugins/plugin-host/PluginContext.d.ts.map +0 -1
  252. package/dist/types/src/plugins/plugin-host/index.d.ts +0 -4
  253. package/dist/types/src/plugins/plugin-host/index.d.ts.map +0 -1
  254. package/dist/types/src/plugins/plugin-host/plugin.d.ts +0 -98
  255. package/dist/types/src/plugins/plugin-host/plugin.d.ts.map +0 -1
  256. package/dist/types/src/plugins/plugin-host/plugin.test.d.ts +0 -35
  257. package/dist/types/src/plugins/plugin-host/plugin.test.d.ts.map +0 -1
  258. package/dist/types/src/plugins/plugin-intent/IntentContext.d.ts +0 -21
  259. package/dist/types/src/plugins/plugin-intent/IntentContext.d.ts.map +0 -1
  260. package/dist/types/src/plugins/plugin-intent/IntentPlugin.d.ts +0 -8
  261. package/dist/types/src/plugins/plugin-intent/IntentPlugin.d.ts.map +0 -1
  262. package/dist/types/src/plugins/plugin-intent/helpers.d.ts +0 -6
  263. package/dist/types/src/plugins/plugin-intent/helpers.d.ts.map +0 -1
  264. package/dist/types/src/plugins/plugin-intent/index.d.ts +0 -6
  265. package/dist/types/src/plugins/plugin-intent/index.d.ts.map +0 -1
  266. package/dist/types/src/plugins/plugin-intent/intent.d.ts +0 -81
  267. package/dist/types/src/plugins/plugin-intent/intent.d.ts.map +0 -1
  268. package/dist/types/src/plugins/plugin-intent/meta.d.ts +0 -5
  269. package/dist/types/src/plugins/plugin-intent/meta.d.ts.map +0 -1
  270. package/dist/types/src/plugins/plugin-intent/provides.d.ts +0 -20
  271. package/dist/types/src/plugins/plugin-intent/provides.d.ts.map +0 -1
  272. package/dist/types/src/plugins/plugin-settings/SettingsPlugin.d.ts +0 -4
  273. package/dist/types/src/plugins/plugin-settings/SettingsPlugin.d.ts.map +0 -1
  274. package/dist/types/src/plugins/plugin-settings/index.d.ts +0 -4
  275. package/dist/types/src/plugins/plugin-settings/index.d.ts.map +0 -1
  276. package/dist/types/src/plugins/plugin-settings/meta.d.ts +0 -5
  277. package/dist/types/src/plugins/plugin-settings/meta.d.ts.map +0 -1
  278. package/dist/types/src/plugins/plugin-settings/provides.d.ts +0 -13
  279. package/dist/types/src/plugins/plugin-settings/provides.d.ts.map +0 -1
  280. package/dist/types/src/plugins/plugin-surface/ErrorBoundary.d.ts.map +0 -1
  281. package/dist/types/src/plugins/plugin-surface/Surface.d.ts +0 -62
  282. package/dist/types/src/plugins/plugin-surface/Surface.d.ts.map +0 -1
  283. package/dist/types/src/plugins/plugin-surface/SurfacePlugin.d.ts +0 -7
  284. package/dist/types/src/plugins/plugin-surface/SurfacePlugin.d.ts.map +0 -1
  285. package/dist/types/src/plugins/plugin-surface/SurfaceRootContext.d.ts +0 -39
  286. package/dist/types/src/plugins/plugin-surface/SurfaceRootContext.d.ts.map +0 -1
  287. package/dist/types/src/plugins/plugin-surface/helpers.d.ts +0 -21
  288. package/dist/types/src/plugins/plugin-surface/helpers.d.ts.map +0 -1
  289. package/dist/types/src/plugins/plugin-surface/index.d.ts +0 -8
  290. package/dist/types/src/plugins/plugin-surface/index.d.ts.map +0 -1
  291. package/dist/types/src/plugins/plugin-surface/meta.d.ts +0 -5
  292. package/dist/types/src/plugins/plugin-surface/meta.d.ts.map +0 -1
  293. package/dist/types/src/plugins/plugin-surface/provides.d.ts +0 -16
  294. package/dist/types/src/plugins/plugin-surface/provides.d.ts.map +0 -1
  295. package/src/plugins/common/file.ts +0 -36
  296. package/src/plugins/common/graph.ts +0 -70
  297. package/src/plugins/common/layout.ts +0 -155
  298. package/src/plugins/common/metadata.ts +0 -29
  299. package/src/plugins/common/translations.ts +0 -36
  300. package/src/plugins/helpers.ts +0 -92
  301. package/src/plugins/index.ts +0 -11
  302. package/src/plugins/plugin-host/HostPlugin.tsx +0 -96
  303. package/src/plugins/plugin-host/PluginContainer.tsx +0 -120
  304. package/src/plugins/plugin-host/PluginContext.tsx +0 -79
  305. package/src/plugins/plugin-host/index.ts +0 -8
  306. package/src/plugins/plugin-host/plugin.test.ts +0 -158
  307. package/src/plugins/plugin-host/plugin.ts +0 -126
  308. package/src/plugins/plugin-intent/IntentContext.tsx +0 -49
  309. package/src/plugins/plugin-intent/IntentPlugin.tsx +0 -151
  310. package/src/plugins/plugin-intent/helpers.ts +0 -11
  311. package/src/plugins/plugin-intent/index.ts +0 -12
  312. package/src/plugins/plugin-intent/intent.ts +0 -101
  313. package/src/plugins/plugin-intent/meta.ts +0 -9
  314. package/src/plugins/plugin-intent/provides.ts +0 -38
  315. package/src/plugins/plugin-settings/SettingsPlugin.tsx +0 -22
  316. package/src/plugins/plugin-settings/index.ts +0 -9
  317. package/src/plugins/plugin-settings/meta.ts +0 -9
  318. package/src/plugins/plugin-settings/provides.ts +0 -29
  319. package/src/plugins/plugin-surface/Surface.tsx +0 -195
  320. package/src/plugins/plugin-surface/SurfacePlugin.tsx +0 -33
  321. package/src/plugins/plugin-surface/SurfaceRootContext.tsx +0 -60
  322. package/src/plugins/plugin-surface/helpers.ts +0 -22
  323. package/src/plugins/plugin-surface/index.ts +0 -14
  324. package/src/plugins/plugin-surface/meta.ts +0 -9
  325. package/src/plugins/plugin-surface/provides.ts +0 -26
  326. /package/dist/types/src/{plugins/plugin-surface → react}/ErrorBoundary.d.ts +0 -0
  327. /package/src/{plugins/plugin-surface → react}/ErrorBoundary.tsx +0 -0
@@ -0,0 +1,94 @@
1
+ import { type Effect } from 'effect';
2
+ import { type MaybePromise } from '@dxos/util';
3
+ import { type AnyCapability, type PluginsContext } from './capabilities';
4
+ import { type ActivationEvent, type ActivationEvents } from './events';
5
+ interface PluginModuleInterface {
6
+ /**
7
+ * Unique id of the module.
8
+ */
9
+ id: string;
10
+ /**
11
+ * Events for which the module will be activated.
12
+ */
13
+ activatesOn: ActivationEvents;
14
+ /**
15
+ * Events which the plugin depends on being activated.
16
+ * Plugin is marked as needing reset a plugin activated by a dependent event is removed.
17
+ * Events are automatically activated before activation of the plugin.
18
+ */
19
+ activatesBefore?: ActivationEvent[];
20
+ /**
21
+ * Events which this plugin triggers upon activation.
22
+ */
23
+ activatesAfter?: ActivationEvent[];
24
+ /**
25
+ * Called when the module is activated.
26
+ * @param context The plugin context.
27
+ * @returns The capabilities of the module.
28
+ */
29
+ activate: (context: PluginsContext) => MaybePromise<AnyCapability | AnyCapability[]> | Effect.Effect<AnyCapability | AnyCapability[], Error>;
30
+ }
31
+ /**
32
+ * A unit of containment of modular functionality that can be provided to an application.
33
+ * Plugins provide things like components, state, actions, etc. to the application.
34
+ */
35
+ export declare class PluginModule implements PluginModuleInterface {
36
+ readonly id: PluginModuleInterface['id'];
37
+ readonly activatesOn: PluginModuleInterface['activatesOn'];
38
+ readonly activatesBefore?: PluginModuleInterface['activatesBefore'];
39
+ readonly activatesAfter?: PluginModuleInterface['activatesAfter'];
40
+ readonly activate: PluginModuleInterface['activate'];
41
+ constructor(options: PluginModuleInterface);
42
+ }
43
+ /**
44
+ * Helper to define a module.
45
+ */
46
+ export declare const defineModule: (options: PluginModuleInterface) => PluginModule;
47
+ export type PluginMeta = {
48
+ /**
49
+ * Globally unique ID.
50
+ *
51
+ * Expected to be in the form of a valid URL.
52
+ *
53
+ * @example dxos.org/plugin/example
54
+ */
55
+ id: string;
56
+ /**
57
+ * Human-readable name.
58
+ */
59
+ name?: string;
60
+ /**
61
+ * Short description of plugin functionality.
62
+ */
63
+ description?: string;
64
+ /**
65
+ * URL of home page.
66
+ */
67
+ homePage?: string;
68
+ /**
69
+ * URL of source code.
70
+ */
71
+ source?: string;
72
+ /**
73
+ * Tags to help categorize the plugin.
74
+ */
75
+ tags?: string[];
76
+ /**
77
+ * A grep-able symbol string which can be resolved to an icon asset by @ch-ui/icons, via @ch-ui/vite-plugin-icons.
78
+ */
79
+ icon?: string;
80
+ };
81
+ /**
82
+ * A collection of modules that are be enabled/disabled as a unit.
83
+ */
84
+ export declare class Plugin {
85
+ readonly meta: PluginMeta;
86
+ readonly modules: PluginModule[];
87
+ constructor(meta: PluginMeta, modules: PluginModule[]);
88
+ }
89
+ /**
90
+ * Helper to define a plugin.
91
+ */
92
+ export declare const definePlugin: (meta: PluginMeta, modules: PluginModule[]) => Plugin;
93
+ export {};
94
+ //# sourceMappingURL=plugin.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"plugin.d.ts","sourceRoot":"","sources":["../../../../src/core/plugin.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,KAAK,MAAM,EAAE,MAAM,QAAQ,CAAC;AAErC,OAAO,EAAE,KAAK,YAAY,EAAE,MAAM,YAAY,CAAC;AAE/C,OAAO,EAAE,KAAK,aAAa,EAAE,KAAK,cAAc,EAAE,MAAM,gBAAgB,CAAC;AACzE,OAAO,EAAE,KAAK,eAAe,EAAE,KAAK,gBAAgB,EAAE,MAAM,UAAU,CAAC;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;;OAEG;IACH,IAAI,CAAC,EAAE,MAAM,CAAC;CACf,CAAC;AAEF;;GAEG;AAEH,qBAAa,MAAM;IAEf,QAAQ,CAAC,IAAI,EAAE,UAAU;IACzB,QAAQ,CAAC,OAAO,EAAE,YAAY,EAAE;gBADvB,IAAI,EAAE,UAAU,EAChB,OAAO,EAAE,YAAY,EAAE;CAEnC;AAED;;GAEG;AACH,eAAO,MAAM,YAAY,SAAU,UAAU,WAAW,YAAY,EAAE,WAErE,CAAC"}
@@ -0,0 +1,10 @@
1
+ type DependencyNode = {
2
+ id: string;
3
+ dependsOn?: string[];
4
+ };
5
+ /**
6
+ * Topologically sorts a list of nodes based on their dependencies.
7
+ */
8
+ export declare const topologicalSort: <T extends DependencyNode>(nodes: T[]) => T[];
9
+ export {};
10
+ //# sourceMappingURL=helpers.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"helpers.d.ts","sourceRoot":"","sources":["../../../src/helpers.ts"],"names":[],"mappings":"AAIA,KAAK,cAAc,GAAG;IACpB,EAAE,EAAE,MAAM,CAAC;IACX,SAAS,CAAC,EAAE,MAAM,EAAE,CAAC;CACtB,CAAC;AAEF;;GAEG;AAEH,eAAO,MAAM,eAAe,GAAI,CAAC,SAAS,cAAc,SAAS,CAAC,EAAE,KAAG,CAAC,EA+BvE,CAAC"}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=helpers.test.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"helpers.test.d.ts","sourceRoot":"","sources":["../../../src/helpers.test.ts"],"names":[],"mappings":""}
@@ -1,3 +1,7 @@
1
- export * from './plugins';
2
1
  export * from './App';
2
+ export * from './common';
3
+ export * from './core';
4
+ export * from './plugin-intent';
5
+ export * from './plugin-settings';
6
+ export * from './react';
3
7
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/index.ts"],"names":[],"mappings":"AAIA,cAAc,WAAW,CAAC;AAE1B,cAAc,OAAO,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/index.ts"],"names":[],"mappings":"AAIA,cAAc,OAAO,CAAC;AACtB,cAAc,UAAU,CAAC;AACzB,cAAc,QAAQ,CAAC;AACvB,cAAc,iBAAiB,CAAC;AAChC,cAAc,mBAAmB,CAAC;AAClC,cAAc,SAAS,CAAC"}
@@ -0,0 +1,6 @@
1
+ import React from 'react';
2
+ import { Capabilities } from '../../common';
3
+ export declare const Debug: () => React.JSX.Element;
4
+ declare const _default: () => import("../../core").Capability<Capabilities.ReactSurface>;
5
+ export default _default;
6
+ //# sourceMappingURL=Debug.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Debug.d.ts","sourceRoot":"","sources":["../../../../../src/playground/debug/Debug.tsx"],"names":[],"mappings":"AAIA,OAAO,KAAK,MAAM,OAAO,CAAC;AAI1B,OAAO,EAAE,YAAY,EAAiB,MAAM,cAAc,CAAC;AAI3D,eAAO,MAAM,KAAK,yBAgBjB,CAAC;;AAEF,wBAQI"}
@@ -0,0 +1,2 @@
1
+ export * from './plugin';
2
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/playground/debug/index.ts"],"names":[],"mappings":"AAIA,cAAc,UAAU,CAAC"}
@@ -0,0 +1,2 @@
1
+ export declare const DebugPlugin: () => import("../../core").Plugin;
2
+ //# sourceMappingURL=plugin.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"plugin.d.ts","sourceRoot":"","sources":["../../../../../src/playground/debug/plugin.ts"],"names":[],"mappings":"AASA,eAAO,MAAM,WAAW,mCAOpB,CAAC"}
@@ -0,0 +1,6 @@
1
+ import React from 'react';
2
+ import { Capabilities } from '../../common';
3
+ export declare const Main: () => React.JSX.Element;
4
+ declare const _default: () => import("../../core").Capability<Capabilities.ReactSurface>;
5
+ export default _default;
6
+ //# sourceMappingURL=Main.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Main.d.ts","sourceRoot":"","sources":["../../../../../src/playground/generator/Main.tsx"],"names":[],"mappings":"AAIA,OAAO,KAAsB,MAAM,OAAO,CAAC;AAI3C,OAAO,EAAE,YAAY,EAAE,MAAM,cAAc,CAAC;AAiC5C,eAAO,MAAM,IAAI,yBAsBhB,CAAC;;AAEF,wBAKK"}
@@ -0,0 +1,6 @@
1
+ import React from 'react';
2
+ import { Capabilities } from '../../common';
3
+ export declare const Toolbar: () => React.JSX.Element;
4
+ declare const _default: () => import("../../core").Capability<Capabilities.ReactSurface>;
5
+ export default _default;
6
+ //# sourceMappingURL=Toolbar.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Toolbar.d.ts","sourceRoot":"","sources":["../../../../../src/playground/generator/Toolbar.tsx"],"names":[],"mappings":"AAIA,OAAO,KAAsB,MAAM,OAAO,CAAC;AAK3C,OAAO,EAAE,YAAY,EAAE,MAAM,cAAc,CAAC;AAI5C,eAAO,MAAM,OAAO,yBAyBnB,CAAC;;AAEF,wBAKK"}
@@ -0,0 +1,5 @@
1
+ export declare const Number: import("../../core").InterfaceDef<number>;
2
+ export declare const CountEvent: import("../../core").ActivationEvent;
3
+ export declare const createPluginId: (id: string) => string;
4
+ export declare const createNumberPlugin: (id: string) => import("../../core").Plugin;
5
+ //# sourceMappingURL=generator.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"generator.d.ts","sourceRoot":"","sources":["../../../../../src/playground/generator/generator.ts"],"names":[],"mappings":"AAMA,eAAO,MAAM,MAAM,2CAA6D,CAAC;AAEjF,eAAO,MAAM,UAAU,sCAA+C,CAAC;AAEvE,eAAO,MAAM,cAAc,OAAQ,MAAM,WAAoC,CAAC;AAE9E,eAAO,MAAM,kBAAkB,OAAQ,MAAM,gCAU5C,CAAC"}
@@ -0,0 +1,3 @@
1
+ export * from './plugin';
2
+ export * from './generator';
3
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/playground/generator/index.ts"],"names":[],"mappings":"AAIA,cAAc,UAAU,CAAC;AACzB,cAAc,aAAa,CAAC"}
@@ -0,0 +1,2 @@
1
+ export declare const GeneratorPlugin: () => import("../../core").Plugin;
2
+ //# sourceMappingURL=plugin.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"plugin.d.ts","sourceRoot":"","sources":["../../../../../src/playground/generator/plugin.ts"],"names":[],"mappings":"AAUA,eAAO,MAAM,eAAe,mCAOxB,CAAC"}
@@ -0,0 +1,8 @@
1
+ import React from 'react';
2
+ export declare const Layout: () => React.JSX.Element;
3
+ declare const _default: () => import("../../core").Capability<Readonly<{
4
+ id: string;
5
+ root: React.FC<React.PropsWithChildren>;
6
+ }>>;
7
+ export default _default;
8
+ //# sourceMappingURL=Layout.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Layout.d.ts","sourceRoot":"","sources":["../../../../../src/playground/layout/Layout.tsx"],"names":[],"mappings":"AAIA,OAAO,KAAK,MAAM,OAAO,CAAC;AAM1B,eAAO,MAAM,MAAM,yBAgBlB,CAAC;;;;;AAEF,wBAIK"}
@@ -0,0 +1,2 @@
1
+ export * from './plugin';
2
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/playground/layout/index.ts"],"names":[],"mappings":"AAIA,cAAc,UAAU,CAAC"}
@@ -0,0 +1,2 @@
1
+ export declare const LayoutPlugin: () => import("../../core").Plugin;
2
+ //# sourceMappingURL=plugin.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"plugin.d.ts","sourceRoot":"","sources":["../../../../../src/playground/layout/plugin.ts"],"names":[],"mappings":"AASA,eAAO,MAAM,YAAY,mCAOrB,CAAC"}
@@ -0,0 +1,6 @@
1
+ import React from 'react';
2
+ import { Capabilities } from '../../common';
3
+ export declare const Logger: () => React.JSX.Element;
4
+ declare const _default: () => import("../../core").Capability<Capabilities.ReactSurface>;
5
+ export default _default;
6
+ //# sourceMappingURL=Toolbar.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Toolbar.d.ts","sourceRoot":"","sources":["../../../../../src/playground/logger/Toolbar.tsx"],"names":[],"mappings":"AAIA,OAAO,KAAsB,MAAM,OAAO,CAAC;AAK3C,OAAO,EAAE,YAAY,EAAiB,MAAM,cAAc,CAAC;AAI3D,eAAO,MAAM,MAAM,yBAIlB,CAAC;;AAEF,wBAQI"}
@@ -0,0 +1,2 @@
1
+ export * from './plugin';
2
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/playground/logger/index.ts"],"names":[],"mappings":"AAIA,cAAc,UAAU,CAAC"}
@@ -0,0 +1,2 @@
1
+ export declare const LoggerPlugin: () => import("../../core").Plugin;
2
+ //# sourceMappingURL=plugin.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"plugin.d.ts","sourceRoot":"","sources":["../../../../../src/playground/logger/plugin.ts"],"names":[],"mappings":"AAaA,eAAO,MAAM,YAAY,mCAmBrB,CAAC"}
@@ -0,0 +1,13 @@
1
+ import { S } from '@dxos/echo-schema';
2
+ declare const Log_base: S.TaggedClass<Log, "dxos.org/test/logger/log", {
3
+ readonly _tag: S.tag<"dxos.org/test/logger/log">;
4
+ } & {
5
+ input: S.Struct<{
6
+ message: typeof S.String;
7
+ }>;
8
+ output: typeof S.Void;
9
+ }>;
10
+ export declare class Log extends Log_base {
11
+ }
12
+ export {};
13
+ //# sourceMappingURL=schema.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"schema.d.ts","sourceRoot":"","sources":["../../../../../src/playground/logger/schema.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,CAAC,EAAE,MAAM,mBAAmB,CAAC;;;;;;;;;AAEtC,qBAAa,GAAI,SAAQ,QAKvB;CAAG"}
@@ -0,0 +1,10 @@
1
+ import '@dxos-theme';
2
+ import React from 'react';
3
+ export declare const Playground: {};
4
+ declare const _default: {
5
+ title: string;
6
+ render: () => React.JSX.Element;
7
+ decorators: import("@storybook/react/*").Decorator[];
8
+ };
9
+ export default _default;
10
+ //# sourceMappingURL=playground.stories.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"playground.stories.d.ts","sourceRoot":"","sources":["../../../../src/playground/playground.stories.tsx"],"names":[],"mappings":"AAIA,OAAO,aAAa,CAAC;AAErB,OAAO,KAAK,MAAM,OAAO,CAAC;AAqB1B,eAAO,MAAM,UAAU,IAAK,CAAC;;;;;;AAE7B,wBAIE"}
@@ -0,0 +1,8 @@
1
+ import { type Context, type Provider } from 'react';
2
+ import { type AnyIntentResolver, type IntentContext } from './intent-dispatcher';
3
+ declare const IntentContext: Context<IntentContext | undefined>;
4
+ export declare const useIntentDispatcher: () => Pick<IntentContext, "dispatch" | "dispatchPromise">;
5
+ export declare const useIntentResolver: (module: string, resolver: AnyIntentResolver) => void;
6
+ export declare const IntentProvider: Provider<IntentContext | undefined>;
7
+ export {};
8
+ //# sourceMappingURL=IntentContext.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"IntentContext.d.ts","sourceRoot":"","sources":["../../../../src/plugin-intent/IntentContext.tsx"],"names":[],"mappings":"AAIA,OAAO,EAAE,KAAK,OAAO,EAA6B,KAAK,QAAQ,EAAa,MAAM,OAAO,CAAC;AAK1F,OAAO,EAAE,KAAK,iBAAiB,EAAE,KAAK,aAAa,EAAE,MAAM,qBAAqB,CAAC;AAIjF,QAAA,MAAM,aAAa,EAAE,OAAO,CAAC,aAAa,GAAG,SAAS,CAAuD,CAAC;AAE9G,eAAO,MAAM,mBAAmB,QAAO,IAAI,CAAC,aAAa,EAAE,UAAU,GAAG,iBAAiB,CAGxF,CAAC;AAEF,eAAO,MAAM,iBAAiB,WAAY,MAAM,YAAY,iBAAiB,SAW5E,CAAC;AAEF,eAAO,MAAM,cAAc,EAAE,QAAQ,CAAC,aAAa,GAAG,SAAS,CAA0B,CAAC"}
@@ -0,0 +1,2 @@
1
+ export declare const IntentPlugin: () => import("../core").Plugin;
2
+ //# sourceMappingURL=IntentPlugin.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"IntentPlugin.d.ts","sourceRoot":"","sources":["../../../../src/plugin-intent/IntentPlugin.tsx"],"names":[],"mappings":"AAkBA,eAAO,MAAM,YAAY,gCAyCrB,CAAC"}
@@ -0,0 +1,23 @@
1
+ import { S } from '@dxos/echo-schema';
2
+ export declare const INTENT_PLUGIN = "dxos.org/plugin/intent";
3
+ export declare const INTENT_ACTION = "dxos.org/plugin/intent/action";
4
+ export declare namespace IntentAction {
5
+ const ShowUndo_base: S.TaggedClass<ShowUndo, "dxos.org/plugin/intent/action/show-undo", {
6
+ readonly _tag: S.tag<"dxos.org/plugin/intent/action/show-undo">;
7
+ } & {
8
+ input: S.Struct<{
9
+ message: S.Union<[typeof S.String, S.mutable<S.Tuple<[typeof S.String, S.mutable<S.Struct<{
10
+ ns: typeof S.String;
11
+ count: S.optional<typeof S.Number>;
12
+ }>>]>>]>;
13
+ }>;
14
+ output: typeof S.Void;
15
+ }>;
16
+ /**
17
+ * Fired after an intent is dispatched if the intent is undoable.
18
+ */
19
+ export class ShowUndo extends ShowUndo_base {
20
+ }
21
+ export {};
22
+ }
23
+ //# sourceMappingURL=actions.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"actions.d.ts","sourceRoot":"","sources":["../../../../src/plugin-intent/actions.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,CAAC,EAAE,MAAM,mBAAmB,CAAC;AAItC,eAAO,MAAM,aAAa,2BAA2B,CAAC;AACtD,eAAO,MAAM,aAAa,kCAA4B,CAAC;AAEvD,yBAAiB,YAAY,CAAC;;;;;;;;;;;;IAC5B;;OAEG;IACH,MAAM,OAAO,QAAS,SAAQ,aAK5B;KAAG;;CACN"}
@@ -0,0 +1,16 @@
1
+ /**
2
+ * NOTE: Messages should be sentences (Start with a capital letter and end with a period).
3
+ * Errors can optionally include a JSON context object.
4
+ */
5
+ export declare class BaseError extends Error {
6
+ readonly code: string;
7
+ readonly context?: Record<string, any> | undefined;
8
+ constructor(code: string, message?: string, context?: Record<string, any> | undefined);
9
+ }
10
+ export declare class NoResolversError extends BaseError {
11
+ constructor(action: string);
12
+ }
13
+ export declare class CycleDetectedError extends BaseError {
14
+ constructor(context?: Record<string, any>);
15
+ }
16
+ //# sourceMappingURL=errors.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"errors.d.ts","sourceRoot":"","sources":["../../../../src/plugin-intent/errors.ts"],"names":[],"mappings":"AAMA;;;GAGG;AACH,qBAAa,SAAU,SAAQ,KAAK;IAEhC,QAAQ,CAAC,IAAI,EAAE,MAAM;IAErB,QAAQ,CAAC,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC;gBAF7B,IAAI,EAAE,MAAM,EACrB,OAAO,CAAC,EAAE,MAAM,EACP,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,YAAA;CAQzC;AAED,qBAAa,gBAAiB,SAAQ,SAAS;gBACjC,MAAM,EAAE,MAAM;CAG3B;AAED,qBAAa,kBAAmB,SAAQ,SAAS;gBACnC,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC;CAO1C"}
@@ -0,0 +1,6 @@
1
+ export * from './actions';
2
+ export * from './intent';
3
+ export * from './intent-dispatcher';
4
+ export * from './IntentContext';
5
+ export * from './IntentPlugin';
6
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/plugin-intent/index.ts"],"names":[],"mappings":"AAIA,cAAc,WAAW,CAAC;AAC1B,cAAc,UAAU,CAAC;AACzB,cAAc,qBAAqB,CAAC;AACpC,cAAc,iBAAiB,CAAC;AAChC,cAAc,gBAAgB,CAAC"}
@@ -0,0 +1,106 @@
1
+ import { Effect } from 'effect';
2
+ import { type Simplify } from 'effect/Types';
3
+ import { type MaybePromise, type Disposition } from '@dxos/util';
4
+ import { type AnyIntentChain, type Intent, type IntentChain, type IntentData, type IntentParams, type IntentResultData, type IntentSchema, type Label } from './intent';
5
+ /**
6
+ * The return value of an intent effect.
7
+ */
8
+ export type IntentEffectResult<Fields extends IntentParams> = {
9
+ /**
10
+ * The output of the action that was performed.
11
+ *
12
+ * If the intent is apart of a chain of intents, the data will be passed to the next intent.
13
+ */
14
+ data?: IntentResultData<Fields>;
15
+ /**
16
+ * If provided, the action will be undoable.
17
+ */
18
+ undoable?: {
19
+ /**
20
+ * Message to display to the user when indicating that the action can be undone.
21
+ */
22
+ message: Label;
23
+ /**
24
+ * Will be merged with the original intent data when firing the undo intent.
25
+ */
26
+ data?: Partial<IntentData<Fields>>;
27
+ };
28
+ /**
29
+ * An error that occurred while performing the action.
30
+ *
31
+ * If the intent is apart of a chain of intents and an error occurs, the chain will be aborted.
32
+ *
33
+ * Return caught error instead of throwing to trigger other intent to be triggered prior to returning the error.
34
+ */
35
+ error?: Error;
36
+ /**
37
+ * Other intent chains to be triggered.
38
+ */
39
+ intents?: AnyIntentChain[];
40
+ };
41
+ export type AnyIntentEffectResult = IntentEffectResult<any>;
42
+ /**
43
+ * The result of an intent dispatcher.
44
+ */
45
+ export type IntentDispatcherResult<Fields extends IntentParams> = Pick<IntentEffectResult<Fields>, 'data' | 'error'>;
46
+ /**
47
+ * The implementation of an intent effect.
48
+ */
49
+ export type IntentEffectDefinition<Fields extends IntentParams> = (data: IntentData<Fields>, undo: boolean) => MaybePromise<IntentEffectResult<Fields> | void> | Effect.Effect<IntentEffectResult<Fields> | void>;
50
+ /**
51
+ * Intent resolver to match intents to their effects.
52
+ */
53
+ export type IntentResolver<Tag extends string, Fields extends IntentParams> = Readonly<{
54
+ action: Tag;
55
+ disposition?: Disposition;
56
+ filter?: (data: IntentData<Fields>) => boolean;
57
+ effect: IntentEffectDefinition<Fields>;
58
+ }>;
59
+ export type AnyIntentResolver = IntentResolver<any, any>;
60
+ /**
61
+ * Creates an intent resolver to match intents to their effects.
62
+ * @param schema Schema of the intent. Must be a tagged class with input and output schemas.
63
+ * @param effect Effect to be performed when the intent is resolved.
64
+ * @param params.disposition Determines the priority of the resolver when multiple are resolved.
65
+ * @param params.filter Optional filter to determine if the resolver should be used.
66
+ */
67
+ export declare const createResolver: <Tag extends string, Fields extends IntentParams>(schema: IntentSchema<Tag, Fields>, effect: IntentEffectDefinition<Fields>, params?: Pick<IntentResolver<Tag, Fields>, "disposition" | "filter">) => IntentResolver<Tag, Fields>;
68
+ /**
69
+ * Invokes intents and returns the result.
70
+ */
71
+ export type PromiseIntentDispatcher = <Fields extends IntentParams>(intent: IntentChain<any, any, any, Fields>) => Promise<Simplify<IntentDispatcherResult<Fields>>>;
72
+ /**
73
+ * Creates an effect for intents.
74
+ */
75
+ export type IntentDispatcher = <Fields extends IntentParams>(intent: IntentChain<any, any, any, Fields>, depth?: number) => Effect.Effect<Simplify<Required<IntentDispatcherResult<Fields>>['data']>, Error>;
76
+ type IntentResult<Tag extends string, Fields extends IntentParams> = IntentEffectResult<Fields> & {
77
+ _intent: Intent<Tag, Fields>;
78
+ };
79
+ export type AnyIntentResult = IntentResult<any, any>;
80
+ /**
81
+ * Invokes the most recent undoable intent with undo flags.
82
+ */
83
+ export type PromiseIntentUndo = () => Promise<IntentDispatcherResult<any>>;
84
+ /**
85
+ * Creates an effect which undoes the last intent.
86
+ */
87
+ export type IntentUndo = () => Effect.Effect<any, Error>;
88
+ export type IntentContext = {
89
+ dispatch: IntentDispatcher;
90
+ dispatchPromise: PromiseIntentDispatcher;
91
+ undo: IntentUndo;
92
+ undoPromise: PromiseIntentUndo;
93
+ };
94
+ /**
95
+ * Sets of an intent dispatcher.
96
+ *
97
+ * @param resolvers An array of available intent resolvers.
98
+ * @param params.historyLimit The maximum number of intent results to keep in history.
99
+ * @param params.executionLimit The maximum recursion depth of intent chains.
100
+ */
101
+ export declare const createDispatcher: (getResolvers: (module?: string) => AnyIntentResolver[], { executionLimit, historyLimit }?: {
102
+ executionLimit?: number | undefined;
103
+ historyLimit?: number | undefined;
104
+ }) => IntentContext;
105
+ export {};
106
+ //# sourceMappingURL=intent-dispatcher.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"intent-dispatcher.d.ts","sourceRoot":"","sources":["../../../../src/plugin-intent/intent-dispatcher.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,MAAM,EAAqB,MAAM,QAAQ,CAAC;AACnD,OAAO,EAAE,KAAK,QAAQ,EAAE,MAAM,cAAc,CAAC;AAE7C,OAAO,EAAE,KAAK,YAAY,EAAiB,KAAK,WAAW,EAAE,MAAM,YAAY,CAAC;AAIhF,OAAO,EAGL,KAAK,cAAc,EACnB,KAAK,MAAM,EACX,KAAK,WAAW,EAChB,KAAK,UAAU,EACf,KAAK,YAAY,EACjB,KAAK,gBAAgB,EACrB,KAAK,YAAY,EACjB,KAAK,KAAK,EACX,MAAM,UAAU,CAAC;AAKlB;;GAEG;AACH,MAAM,MAAM,kBAAkB,CAAC,MAAM,SAAS,YAAY,IAAI;IAC5D;;;;OAIG;IACH,IAAI,CAAC,EAAE,gBAAgB,CAAC,MAAM,CAAC,CAAC;IAEhC;;OAEG;IACH,QAAQ,CAAC,EAAE;QACT;;WAEG;QACH,OAAO,EAAE,KAAK,CAAC;QAEf;;WAEG;QACH,IAAI,CAAC,EAAE,OAAO,CAAC,UAAU,CAAC,MAAM,CAAC,CAAC,CAAC;KACpC,CAAC;IAEF;;;;;;OAMG;IACH,KAAK,CAAC,EAAE,KAAK,CAAC;IAEd;;OAEG;IACH,OAAO,CAAC,EAAE,cAAc,EAAE,CAAC;CAC5B,CAAC;AAEF,MAAM,MAAM,qBAAqB,GAAG,kBAAkB,CAAC,GAAG,CAAC,CAAC;AAE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cher.test.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"intent-dispatcher.test.d.ts","sourceRoot":"","sources":["../../../../src/plugin-intent/intent-dispatcher.test.ts"],"names":[],"mappings":""}
@@ -0,0 +1,68 @@
1
+ import { S } from '@dxos/echo-schema';
2
+ export type IntentParams = {
3
+ readonly input: S.Schema.All;
4
+ readonly output: S.Schema.All;
5
+ };
6
+ export type IntentData<Fields extends IntentParams> = S.Schema.Type<S.Struct<Fields>> extends {
7
+ readonly input: any;
8
+ } ? S.Schema.Type<S.Struct<Fields>>['input'] : any;
9
+ export type IntentResultData<Fields extends IntentParams> = S.Schema.Type<S.Struct<Fields>> extends {
10
+ readonly output: any;
11
+ } ? S.Schema.Type<S.Struct<Fields>>['output'] : any;
12
+ export type IntentSchema<Tag extends string, Fields extends IntentParams> = S.TaggedClass<any, Tag, Fields>;
13
+ /**
14
+ * An intent is an abstract description of an operation to be performed.
15
+ * Intents allow actions to be performed across plugins.
16
+ */
17
+ export type Intent<Tag extends string, Fields extends IntentParams> = {
18
+ _schema: IntentSchema<Tag, Fields>;
19
+ /**
20
+ * The action to perform.
21
+ */
22
+ action: Tag;
23
+ /**
24
+ * Any data needed to perform the desired action.
25
+ */
26
+ data: IntentData<Fields>;
27
+ /**
28
+ * Module ID.
29
+ * If specified, the intent will be sent explicitly to the plugin module.
30
+ * Otherwise, the intent will be sent to all plugins, in order and the first to resolve a non-null value will be used.
31
+ */
32
+ module?: string;
33
+ /**
34
+ * Whether or not the intent is being undone.
35
+ */
36
+ undo?: boolean;
37
+ };
38
+ export type AnyIntent = Intent<any, any>;
39
+ /**
40
+ * Chain of intents to be executed together.
41
+ * The result of each intent is merged into the next intent's input data.
42
+ */
43
+ export type IntentChain<FirstTag extends string, LastTag extends string, FirstFields extends IntentParams, LastFields extends IntentParams> = {
44
+ first: Intent<FirstTag, FirstFields>;
45
+ last: Intent<LastTag, LastFields>;
46
+ all: AnyIntent[];
47
+ };
48
+ export type AnyIntentChain = IntentChain<any, any, any, any>;
49
+ /**
50
+ * Creates a typed intent.
51
+ * @param schema Schema of the intent. Must be a tagged class with input and output schemas.
52
+ * @param data Data fulfilling the input schema of the intent.
53
+ * @param params.plugin Optional plugin ID to send the intent to.
54
+ * @param params.undo Optional flag to indicate that the intent is being undone. Generally not set manually.
55
+ */
56
+ export declare const createIntent: <Tag extends string, Fields extends IntentParams>(schema: IntentSchema<Tag, Fields>, data?: IntentData<Fields>, params?: Pick<AnyIntent, "module" | "undo">) => IntentChain<Tag, Tag, Fields, Fields>;
57
+ /**
58
+ * Chain two intents together.
59
+ *
60
+ * NOTE: Chaining of intents depends on the data inputs and outputs being structs.
61
+ */
62
+ export declare const chain: <FirstTag extends string, NextTag extends string, FirstFields extends IntentParams, LastFields extends IntentParams, NextFields extends IntentParams>(schema: IntentSchema<NextTag, NextFields>, data?: Omit<IntentData<NextFields>, keyof IntentResultData<LastFields>>, params?: Pick<AnyIntent, "module" | "undo">) => (intent: IntentChain<FirstTag, any, FirstFields, LastFields>) => IntentChain<FirstTag, NextTag, FirstFields, NextFields>;
63
+ export declare const Label: S.Union<[typeof S.String, S.mutable<S.Tuple<[typeof S.String, S.mutable<S.Struct<{
64
+ ns: typeof S.String;
65
+ count: S.optional<typeof S.Number>;
66
+ }>>]>>]>;
67
+ export type Label = S.Schema.Type<typeof Label>;
68
+ //# sourceMappingURL=intent.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"intent.d.ts","sourceRoot":"","sources":["../../../../src/plugin-intent/intent.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,CAAC,EAAE,MAAM,mBAAmB,CAAC;AAEtC,MAAM,MAAM,YAAY,GAAG;IACzB,QAAQ,CAAC,KAAK,EAAE,CAAC,CAAC,MAAM,CAAC,GAAG,CAAC;IAC7B,QAAQ,CAAC,MAAM,EAAE,CAAC,CAAC,MAAM,CAAC,GAAG,CAAC;CAC/B,CAAC;AAEF,MAAM,MAAM,UAAU,CAAC,MAAM,SAAS,YAAY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,KAAK,CAAC,CAAC"}
@@ -0,0 +1,2 @@
1
+ export declare const SettingsPlugin: () => import("../core").Plugin;
2
+ //# sourceMappingURL=SettingsPlugin.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"SettingsPlugin.d.ts","sourceRoot":"","sources":["../../../../src/plugin-settings/SettingsPlugin.ts"],"names":[],"mappings":"AAUA,eAAO,MAAM,cAAc,gCAkBvB,CAAC"}
@@ -0,0 +1,17 @@
1
+ import { S } from '@dxos/echo-schema';
2
+ export declare const SETTINGS_PLUGIN = "dxos.org/plugin/settings";
3
+ export declare const SETTINGS_ACTION = "dxos.org/plugin/settings/action";
4
+ export declare namespace SettingsAction {
5
+ const Open_base: S.TaggedClass<Open, "dxos.org/plugin/settings/action/open", {
6
+ readonly _tag: S.tag<"dxos.org/plugin/settings/action/open">;
7
+ } & {
8
+ input: S.Struct<{
9
+ plugin: S.optional<typeof S.String>;
10
+ }>;
11
+ output: typeof S.Void;
12
+ }>;
13
+ export class Open extends Open_base {
14
+ }
15
+ export {};
16
+ }
17
+ //# sourceMappingURL=actions.d.ts.map