@dxos/plugin-automation 0.8.4-main.bc674ce → 0.8.4-main.c351d160a8

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 (219) hide show
  1. package/dist/lib/browser/AutomationPanel-IGLIQY2N.mjs +11 -0
  2. package/dist/lib/browser/AutomationSettings-XGJGVBDD.mjs +37 -0
  3. package/dist/lib/browser/AutomationSettings-XGJGVBDD.mjs.map +7 -0
  4. package/dist/lib/browser/FunctionsContainer-R4ZMYSFJ.mjs +43 -0
  5. package/dist/lib/browser/FunctionsContainer-R4ZMYSFJ.mjs.map +7 -0
  6. package/dist/lib/browser/{FunctionsPanel-ZX4J75UM.mjs → FunctionsPanel-NMA4RYJL.mjs} +3 -3
  7. package/dist/lib/browser/FunctionsRegistry-TMKAEG5E.mjs +10 -0
  8. package/dist/lib/browser/TriggerSettings-GW5OEM2G.mjs +11 -0
  9. package/dist/lib/browser/{app-graph-builder-LAQMEBMH.mjs → app-graph-builder-74ILZP25.mjs} +19 -20
  10. package/dist/lib/browser/app-graph-builder-74ILZP25.mjs.map +7 -0
  11. package/dist/lib/browser/{chunk-JOXPQ27I.mjs → chunk-5WMYSXEH.mjs} +7 -7
  12. package/dist/lib/browser/chunk-5WMYSXEH.mjs.map +7 -0
  13. package/dist/lib/browser/{chunk-BFUIVUQH.mjs → chunk-75XLBFAG.mjs} +11 -16
  14. package/dist/lib/browser/chunk-75XLBFAG.mjs.map +7 -0
  15. package/dist/lib/browser/{chunk-QW3EM35H.mjs → chunk-BWEKRPFJ.mjs} +62 -16
  16. package/dist/lib/browser/chunk-BWEKRPFJ.mjs.map +7 -0
  17. package/dist/lib/browser/{chunk-PZNBEKO5.mjs → chunk-EL64ZPPN.mjs} +2 -2
  18. package/dist/lib/browser/{chunk-PZNBEKO5.mjs.map → chunk-EL64ZPPN.mjs.map} +1 -1
  19. package/dist/lib/browser/{FunctionsContainer-6QLC7JP4.mjs → chunk-FUVAC5EC.mjs} +15 -48
  20. package/dist/lib/browser/chunk-FUVAC5EC.mjs.map +7 -0
  21. package/dist/lib/browser/{chunk-BKFQBKYO.mjs → chunk-LHJEQVX5.mjs} +2 -2
  22. package/dist/lib/browser/{chunk-YWLEY2FD.mjs → chunk-O23LHDEX.mjs} +119 -50
  23. package/dist/lib/browser/chunk-O23LHDEX.mjs.map +7 -0
  24. package/dist/lib/browser/chunk-PUYY7B5F.mjs +31 -0
  25. package/dist/lib/browser/chunk-PUYY7B5F.mjs.map +7 -0
  26. package/dist/lib/browser/{chunk-RAF2FJST.mjs → chunk-ZBEMNWNY.mjs} +19 -12
  27. package/dist/lib/browser/chunk-ZBEMNWNY.mjs.map +7 -0
  28. package/dist/lib/browser/cli/index.mjs +62 -54
  29. package/dist/lib/browser/cli/index.mjs.map +3 -3
  30. package/dist/lib/browser/{compute-runtime-WTWLQ67J.mjs → compute-runtime-I3I2BIRE.mjs} +36 -20
  31. package/dist/lib/browser/compute-runtime-I3I2BIRE.mjs.map +7 -0
  32. package/dist/lib/browser/hooks/index.mjs +3 -3
  33. package/dist/lib/browser/index.mjs +26 -25
  34. package/dist/lib/browser/index.mjs.map +4 -4
  35. package/dist/lib/browser/meta.json +1 -1
  36. package/dist/lib/browser/{operation-resolver-Q3MWOR7K.mjs → operation-resolver-NGN4BEWN.mjs} +11 -9
  37. package/dist/lib/browser/operation-resolver-NGN4BEWN.mjs.map +7 -0
  38. package/dist/lib/browser/react-surface-SXDIM3RM.mjs +65 -0
  39. package/dist/lib/browser/react-surface-SXDIM3RM.mjs.map +7 -0
  40. package/dist/lib/browser/types/index.mjs +2 -2
  41. package/dist/lib/node-esm/{AutomationPanel-B7NAGDFA.mjs → AutomationPanel-O2BCQA7P.mjs} +4 -4
  42. package/dist/lib/node-esm/AutomationPanel-O2BCQA7P.mjs.map +7 -0
  43. package/dist/lib/node-esm/AutomationSettings-W52ZO2XI.mjs +38 -0
  44. package/dist/lib/node-esm/AutomationSettings-W52ZO2XI.mjs.map +7 -0
  45. package/dist/lib/node-esm/FunctionsContainer-GYRPQZM7.mjs +44 -0
  46. package/dist/lib/node-esm/FunctionsContainer-GYRPQZM7.mjs.map +7 -0
  47. package/dist/lib/node-esm/{FunctionsPanel-SS6GIVNU.mjs → FunctionsPanel-DCXXLSVP.mjs} +3 -3
  48. package/dist/lib/node-esm/FunctionsPanel-DCXXLSVP.mjs.map +7 -0
  49. package/dist/lib/node-esm/FunctionsRegistry-7WCHC64E.mjs +11 -0
  50. package/dist/lib/node-esm/FunctionsRegistry-7WCHC64E.mjs.map +7 -0
  51. package/dist/lib/node-esm/TriggerSettings-2GKFPECW.mjs +12 -0
  52. package/dist/lib/node-esm/TriggerSettings-2GKFPECW.mjs.map +7 -0
  53. package/dist/lib/node-esm/{app-graph-builder-4UCMXHYY.mjs → app-graph-builder-VDXPOWCH.mjs} +19 -20
  54. package/dist/lib/node-esm/app-graph-builder-VDXPOWCH.mjs.map +7 -0
  55. package/dist/lib/node-esm/{FunctionsContainer-J4O2ULWR.mjs → chunk-6JVB3IHW.mjs} +15 -48
  56. package/dist/lib/node-esm/chunk-6JVB3IHW.mjs.map +7 -0
  57. package/dist/lib/node-esm/chunk-BNWZ2NNI.mjs +32 -0
  58. package/dist/lib/node-esm/chunk-BNWZ2NNI.mjs.map +7 -0
  59. package/dist/lib/node-esm/{chunk-2CKVH7JC.mjs → chunk-FPXVLTEY.mjs} +119 -50
  60. package/dist/lib/node-esm/chunk-FPXVLTEY.mjs.map +7 -0
  61. package/dist/lib/node-esm/{chunk-KWKWOGS5.mjs → chunk-K7T2MVB7.mjs} +11 -16
  62. package/dist/lib/node-esm/chunk-K7T2MVB7.mjs.map +7 -0
  63. package/dist/lib/node-esm/{chunk-LJAXQ6CX.mjs → chunk-Q5JSKD6Z.mjs} +62 -16
  64. package/dist/lib/node-esm/chunk-Q5JSKD6Z.mjs.map +7 -0
  65. package/dist/lib/node-esm/{chunk-K7GCM342.mjs → chunk-V3VUE2NR.mjs} +2 -2
  66. package/dist/lib/node-esm/{chunk-5FXNN3MV.mjs → chunk-WC5AT7B3.mjs} +2 -2
  67. package/dist/lib/node-esm/{chunk-5FXNN3MV.mjs.map → chunk-WC5AT7B3.mjs.map} +1 -1
  68. package/dist/lib/node-esm/{chunk-RX52VKI2.mjs → chunk-XCFO2IXT.mjs} +7 -7
  69. package/dist/lib/node-esm/chunk-XCFO2IXT.mjs.map +7 -0
  70. package/dist/lib/node-esm/{chunk-HQLVREIX.mjs → chunk-XQO3HK62.mjs} +19 -12
  71. package/dist/lib/node-esm/chunk-XQO3HK62.mjs.map +7 -0
  72. package/dist/lib/node-esm/cli/index.mjs +62 -54
  73. package/dist/lib/node-esm/cli/index.mjs.map +3 -3
  74. package/dist/lib/node-esm/{compute-runtime-ZHROOBLY.mjs → compute-runtime-7HCSIYFG.mjs} +36 -20
  75. package/dist/lib/node-esm/compute-runtime-7HCSIYFG.mjs.map +7 -0
  76. package/dist/lib/node-esm/hooks/index.mjs +3 -3
  77. package/dist/lib/node-esm/index.mjs +26 -25
  78. package/dist/lib/node-esm/index.mjs.map +4 -4
  79. package/dist/lib/node-esm/meta.json +1 -1
  80. package/dist/lib/node-esm/{operation-resolver-R5GA4YNO.mjs → operation-resolver-ANGACQZG.mjs} +11 -9
  81. package/dist/lib/node-esm/operation-resolver-ANGACQZG.mjs.map +7 -0
  82. package/dist/lib/node-esm/{react-surface-S6VZJCEZ.mjs → react-surface-QVLVDEVW.mjs} +25 -25
  83. package/dist/lib/node-esm/react-surface-QVLVDEVW.mjs.map +7 -0
  84. package/dist/lib/node-esm/types/index.mjs +2 -2
  85. package/dist/types/src/AutomationPlugin.d.ts.map +1 -1
  86. package/dist/types/src/capabilities/app-graph-builder/app-graph-builder.d.ts +1 -1
  87. package/dist/types/src/capabilities/app-graph-builder/app-graph-builder.d.ts.map +1 -1
  88. package/dist/types/src/capabilities/compute-runtime/compute-runtime.d.ts +1 -1
  89. package/dist/types/src/capabilities/compute-runtime/compute-runtime.d.ts.map +1 -1
  90. package/dist/types/src/capabilities/operation-resolver/index.d.ts +1 -1
  91. package/dist/types/src/capabilities/operation-resolver/index.d.ts.map +1 -1
  92. package/dist/types/src/capabilities/operation-resolver/operation-resolver.d.ts +2 -2
  93. package/dist/types/src/capabilities/operation-resolver/operation-resolver.d.ts.map +1 -1
  94. package/dist/types/src/capabilities/react-surface/index.d.ts +1 -1
  95. package/dist/types/src/capabilities/react-surface/index.d.ts.map +1 -1
  96. package/dist/types/src/capabilities/react-surface/react-surface.d.ts +2 -2
  97. package/dist/types/src/capabilities/react-surface/react-surface.d.ts.map +1 -1
  98. package/dist/types/src/cli/commands/trigger/update/queue.d.ts.map +1 -1
  99. package/dist/types/src/cli/commands/trigger/util.d.ts +2 -2
  100. package/dist/types/src/cli/commands/trigger/util.d.ts.map +1 -1
  101. package/dist/types/src/cli/plugin.d.ts.map +1 -1
  102. package/dist/types/src/components/AutomationPanel/AutomationPanel.d.ts +3 -4
  103. package/dist/types/src/components/AutomationPanel/AutomationPanel.d.ts.map +1 -1
  104. package/dist/types/src/components/AutomationPanel/AutomationPanel.stories.d.ts +1 -0
  105. package/dist/types/src/components/AutomationPanel/AutomationPanel.stories.d.ts.map +1 -1
  106. package/dist/types/src/components/FunctionsPanel/FunctionsPanel.d.ts.map +1 -1
  107. package/dist/types/src/components/FunctionsRegistry/FunctionsRegistry.d.ts.map +1 -1
  108. package/dist/types/src/components/FunctionsRegistry/index.d.ts +3 -1
  109. package/dist/types/src/components/FunctionsRegistry/index.d.ts.map +1 -1
  110. package/dist/types/src/components/TriggerEditor/FunctionInputEditor.d.ts.map +1 -1
  111. package/dist/types/src/components/TriggerEditor/TriggerEditor.d.ts.map +1 -1
  112. package/dist/types/src/components/TriggerEditor/TriggerEditor.stories.d.ts +2 -0
  113. package/dist/types/src/components/TriggerEditor/TriggerEditor.stories.d.ts.map +1 -1
  114. package/dist/types/src/components/index.d.ts +3 -4
  115. package/dist/types/src/components/index.d.ts.map +1 -1
  116. package/dist/types/src/containers/AutomationSettings/AutomationSettings.d.ts +4 -0
  117. package/dist/types/src/containers/AutomationSettings/AutomationSettings.d.ts.map +1 -0
  118. package/dist/types/src/containers/AutomationSettings/index.d.ts +3 -0
  119. package/dist/types/src/containers/AutomationSettings/index.d.ts.map +1 -0
  120. package/dist/types/src/{components → containers/FunctionsContainer}/FunctionsContainer.d.ts +0 -1
  121. package/dist/types/src/containers/FunctionsContainer/FunctionsContainer.d.ts.map +1 -0
  122. package/dist/types/src/containers/FunctionsContainer/index.d.ts +3 -0
  123. package/dist/types/src/containers/FunctionsContainer/index.d.ts.map +1 -0
  124. package/dist/types/src/containers/TriggerSettings/TriggerSettings.d.ts.map +1 -0
  125. package/dist/types/src/containers/TriggerSettings/index.d.ts +3 -0
  126. package/dist/types/src/containers/TriggerSettings/index.d.ts.map +1 -0
  127. package/dist/types/src/containers/index.d.ts +5 -0
  128. package/dist/types/src/containers/index.d.ts.map +1 -0
  129. package/dist/types/src/hooks/useTriggerRuntimeControls.d.ts +2 -1
  130. package/dist/types/src/hooks/useTriggerRuntimeControls.d.ts.map +1 -1
  131. package/dist/types/src/translations.d.ts +1 -0
  132. package/dist/types/src/translations.d.ts.map +1 -1
  133. package/dist/types/src/types/capabilities.d.ts +3 -2
  134. package/dist/types/src/types/capabilities.d.ts.map +1 -1
  135. package/dist/types/src/types/schema.d.ts +3 -3
  136. package/dist/types/tsconfig.tsbuildinfo +1 -1
  137. package/package.json +51 -46
  138. package/src/AutomationPlugin.tsx +7 -6
  139. package/src/capabilities/app-graph-builder/app-graph-builder.ts +17 -15
  140. package/src/capabilities/compute-runtime/compute-runtime.ts +36 -14
  141. package/src/capabilities/operation-resolver/operation-resolver.ts +7 -6
  142. package/src/capabilities/react-surface/react-surface.tsx +16 -19
  143. package/src/cli/commands/trigger/create/queue.ts +4 -4
  144. package/src/cli/commands/trigger/create/subscription.ts +4 -4
  145. package/src/cli/commands/trigger/create/timer.ts +4 -4
  146. package/src/cli/commands/trigger/list.ts +2 -2
  147. package/src/cli/commands/trigger/remove.ts +2 -2
  148. package/src/cli/commands/trigger/update/queue.ts +5 -5
  149. package/src/cli/commands/trigger/update/subscription.ts +5 -5
  150. package/src/cli/commands/trigger/update/timer.ts +5 -5
  151. package/src/cli/commands/trigger/util.ts +34 -25
  152. package/src/cli/plugin.ts +3 -2
  153. package/src/components/AutomationPanel/AutomationPanel.stories.tsx +3 -3
  154. package/src/components/AutomationPanel/AutomationPanel.tsx +137 -69
  155. package/src/components/FunctionsPanel/FunctionsPanel.tsx +9 -11
  156. package/src/components/FunctionsRegistry/FunctionsRegistry.tsx +9 -10
  157. package/src/components/FunctionsRegistry/index.ts +4 -1
  158. package/src/components/TriggerEditor/FunctionInputEditor.tsx +13 -4
  159. package/src/components/TriggerEditor/SpecSelector.tsx +1 -1
  160. package/src/components/TriggerEditor/TriggerEditor.stories.tsx +46 -4
  161. package/src/components/TriggerEditor/TriggerEditor.tsx +39 -7
  162. package/src/components/index.ts +1 -2
  163. package/src/{components → containers/AutomationSettings}/AutomationSettings.tsx +8 -11
  164. package/src/containers/AutomationSettings/index.ts +7 -0
  165. package/src/{components → containers/FunctionsContainer}/FunctionsContainer.tsx +10 -13
  166. package/src/containers/FunctionsContainer/index.ts +7 -0
  167. package/src/containers/TriggerSettings/TriggerSettings.tsx +26 -0
  168. package/src/containers/TriggerSettings/index.ts +6 -0
  169. package/src/containers/index.ts +9 -0
  170. package/src/hooks/useComputeRuntimeCallback.ts +1 -1
  171. package/src/hooks/useTriggerRuntimeControls.ts +22 -8
  172. package/src/meta.ts +1 -1
  173. package/src/testing/test-functions.ts +5 -5
  174. package/src/translations.ts +2 -0
  175. package/src/types/capabilities.ts +5 -2
  176. package/src/types/events.ts +1 -1
  177. package/src/types/schema.ts +3 -3
  178. package/dist/lib/browser/AutomationPanel-FAS6ADCW.mjs +0 -11
  179. package/dist/lib/browser/AutomationSettings-XN2OIYWL.mjs +0 -56
  180. package/dist/lib/browser/AutomationSettings-XN2OIYWL.mjs.map +0 -7
  181. package/dist/lib/browser/FunctionsContainer-6QLC7JP4.mjs.map +0 -7
  182. package/dist/lib/browser/app-graph-builder-LAQMEBMH.mjs.map +0 -7
  183. package/dist/lib/browser/chunk-54PANILA.mjs +0 -14
  184. package/dist/lib/browser/chunk-54PANILA.mjs.map +0 -7
  185. package/dist/lib/browser/chunk-BFUIVUQH.mjs.map +0 -7
  186. package/dist/lib/browser/chunk-JOXPQ27I.mjs.map +0 -7
  187. package/dist/lib/browser/chunk-QW3EM35H.mjs.map +0 -7
  188. package/dist/lib/browser/chunk-RAF2FJST.mjs.map +0 -7
  189. package/dist/lib/browser/chunk-YWLEY2FD.mjs.map +0 -7
  190. package/dist/lib/browser/compute-runtime-WTWLQ67J.mjs.map +0 -7
  191. package/dist/lib/browser/operation-resolver-Q3MWOR7K.mjs.map +0 -7
  192. package/dist/lib/browser/react-surface-EV3AC62F.mjs +0 -65
  193. package/dist/lib/browser/react-surface-EV3AC62F.mjs.map +0 -7
  194. package/dist/lib/node-esm/AutomationSettings-M5PMZJ6P.mjs +0 -57
  195. package/dist/lib/node-esm/AutomationSettings-M5PMZJ6P.mjs.map +0 -7
  196. package/dist/lib/node-esm/FunctionsContainer-J4O2ULWR.mjs.map +0 -7
  197. package/dist/lib/node-esm/app-graph-builder-4UCMXHYY.mjs.map +0 -7
  198. package/dist/lib/node-esm/chunk-2CKVH7JC.mjs.map +0 -7
  199. package/dist/lib/node-esm/chunk-7QRUPEHH.mjs +0 -16
  200. package/dist/lib/node-esm/chunk-7QRUPEHH.mjs.map +0 -7
  201. package/dist/lib/node-esm/chunk-HQLVREIX.mjs.map +0 -7
  202. package/dist/lib/node-esm/chunk-KWKWOGS5.mjs.map +0 -7
  203. package/dist/lib/node-esm/chunk-LJAXQ6CX.mjs.map +0 -7
  204. package/dist/lib/node-esm/chunk-RX52VKI2.mjs.map +0 -7
  205. package/dist/lib/node-esm/compute-runtime-ZHROOBLY.mjs.map +0 -7
  206. package/dist/lib/node-esm/operation-resolver-R5GA4YNO.mjs.map +0 -7
  207. package/dist/lib/node-esm/react-surface-S6VZJCEZ.mjs.map +0 -7
  208. package/dist/types/src/components/AutomationSettings.d.ts +0 -5
  209. package/dist/types/src/components/AutomationSettings.d.ts.map +0 -1
  210. package/dist/types/src/components/FunctionsContainer.d.ts.map +0 -1
  211. package/dist/types/src/components/TriggerSettings.d.ts.map +0 -1
  212. package/src/components/TriggerSettings.tsx +0 -25
  213. /package/dist/lib/browser/{AutomationPanel-FAS6ADCW.mjs.map → AutomationPanel-IGLIQY2N.mjs.map} +0 -0
  214. /package/dist/lib/browser/{FunctionsPanel-ZX4J75UM.mjs.map → FunctionsPanel-NMA4RYJL.mjs.map} +0 -0
  215. /package/dist/lib/{node-esm/AutomationPanel-B7NAGDFA.mjs.map → browser/FunctionsRegistry-TMKAEG5E.mjs.map} +0 -0
  216. /package/dist/lib/{node-esm/FunctionsPanel-SS6GIVNU.mjs.map → browser/TriggerSettings-GW5OEM2G.mjs.map} +0 -0
  217. /package/dist/lib/browser/{chunk-BKFQBKYO.mjs.map → chunk-LHJEQVX5.mjs.map} +0 -0
  218. /package/dist/lib/node-esm/{chunk-K7GCM342.mjs.map → chunk-V3VUE2NR.mjs.map} +0 -0
  219. /package/dist/types/src/{components → containers/TriggerSettings}/TriggerSettings.d.ts +0 -0
@@ -0,0 +1,65 @@
1
+ import {
2
+ meta
3
+ } from "./chunk-EL64ZPPN.mjs";
4
+
5
+ // src/capabilities/react-surface/react-surface.tsx
6
+ import * as Effect from "effect/Effect";
7
+ import React from "react";
8
+ import { Capabilities, Capability } from "@dxos/app-framework";
9
+ import { Surface } from "@dxos/app-framework/ui";
10
+ import { Obj } from "@dxos/echo";
11
+ import { useActiveSpace } from "@dxos/plugin-space";
12
+ import { getSpace } from "@dxos/react-client/echo";
13
+
14
+ // src/containers/index.ts
15
+ import { lazy } from "react";
16
+ var AutomationSettings = lazy(() => import("./AutomationSettings-XGJGVBDD.mjs"));
17
+ var FunctionsContainer = lazy(() => import("./FunctionsContainer-R4ZMYSFJ.mjs"));
18
+ var TriggerSettings = lazy(() => import("./TriggerSettings-GW5OEM2G.mjs"));
19
+
20
+ // src/capabilities/react-surface/react-surface.tsx
21
+ var react_surface_default = Capability.makeModule(() => Effect.succeed(Capability.contributes(Capabilities.ReactSurface, [
22
+ Surface.create({
23
+ id: `${meta.id}.space-settings-functions`,
24
+ role: "article",
25
+ filter: (data) => data.subject === `${meta.id}.space-settings-functions`,
26
+ component: () => {
27
+ const space = useActiveSpace();
28
+ if (!space) {
29
+ return null;
30
+ }
31
+ return /* @__PURE__ */ React.createElement(FunctionsContainer, {
32
+ space
33
+ });
34
+ }
35
+ }),
36
+ Surface.create({
37
+ id: `${meta.id}.space-settings-automation`,
38
+ role: "article",
39
+ filter: (data) => data.subject === `${meta.id}.space-settings-automation`,
40
+ component: () => {
41
+ const space = useActiveSpace();
42
+ if (!space) {
43
+ return null;
44
+ }
45
+ return /* @__PURE__ */ React.createElement(AutomationSettings, {
46
+ space
47
+ });
48
+ }
49
+ }),
50
+ Surface.create({
51
+ id: `${meta.id}.companion.automation`,
52
+ role: "article",
53
+ filter: (data) => Obj.isObject(data.companionTo) && data.subject === "automation",
54
+ component: ({ data }) => {
55
+ return /* @__PURE__ */ React.createElement(AutomationSettings, {
56
+ space: getSpace(data.companionTo),
57
+ object: data.companionTo
58
+ });
59
+ }
60
+ })
61
+ ])));
62
+ export {
63
+ react_surface_default as default
64
+ };
65
+ //# sourceMappingURL=react-surface-SXDIM3RM.mjs.map
@@ -0,0 +1,7 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../../src/capabilities/react-surface/react-surface.tsx", "../../../src/containers/index.ts"],
4
+ "sourcesContent": ["//\n// Copyright 2025 DXOS.org\n//\n\nimport * as Effect from 'effect/Effect';\nimport React from 'react';\n\nimport { Capabilities, Capability } from '@dxos/app-framework';\nimport { Surface } from '@dxos/app-framework/ui';\nimport { Obj } from '@dxos/echo';\nimport { useActiveSpace } from '@dxos/plugin-space';\nimport { getSpace } from '@dxos/react-client/echo';\n\nimport { AutomationSettings, FunctionsContainer } from '../../containers';\nimport { meta } from '../../meta';\n\nexport default Capability.makeModule(() =>\n Effect.succeed(\n Capability.contributes(Capabilities.ReactSurface, [\n Surface.create({\n id: `${meta.id}.space-settings-functions`,\n role: 'article',\n filter: (data): data is { subject: string } => data.subject === `${meta.id}.space-settings-functions`,\n component: () => {\n const space = useActiveSpace();\n if (!space) {\n return null;\n }\n\n return <FunctionsContainer space={space} />;\n },\n }),\n Surface.create({\n id: `${meta.id}.space-settings-automation`,\n role: 'article',\n filter: (data): data is { subject: string } => data.subject === `${meta.id}.space-settings-automation`,\n component: () => {\n const space = useActiveSpace();\n if (!space) {\n return null;\n }\n\n return <AutomationSettings space={space} />;\n },\n }),\n Surface.create({\n id: `${meta.id}.companion.automation`,\n role: 'article',\n filter: (data): data is { companionTo: Obj.Unknown; subject: 'automation' } =>\n Obj.isObject(data.companionTo) && data.subject === 'automation',\n component: ({ data }) => {\n return <AutomationSettings space={getSpace(data.companionTo)!} object={data.companionTo} />;\n },\n }),\n ]),\n ),\n);\n", "//\n// Copyright 2025 DXOS.org\n//\n\nimport { type ComponentType, lazy } from 'react';\n\nexport const AutomationSettings: ComponentType<any> = lazy(() => import('./AutomationSettings'));\nexport const FunctionsContainer: ComponentType<any> = lazy(() => import('./FunctionsContainer'));\nexport const TriggerSettings: ComponentType<any> = lazy(() => import('./TriggerSettings'));\n"],
5
+ "mappings": ";;;;;AAIA,YAAYA,YAAY;AACxB,OAAOC,WAAW;AAElB,SAASC,cAAcC,kBAAkB;AACzC,SAASC,eAAe;AACxB,SAASC,WAAW;AACpB,SAASC,sBAAsB;AAC/B,SAASC,gBAAgB;;;ACPzB,SAA6BC,YAAY;AAElC,IAAMC,qBAAyCC,KAAK,MAAM,OAAO,mCAAA,CAAA;AACjE,IAAMC,qBAAyCD,KAAK,MAAM,OAAO,mCAAA,CAAA;AACjE,IAAME,kBAAsCF,KAAK,MAAM,OAAO,gCAAA,CAAA;;;ADQrE,IAAA,wBAAeG,WAAWC,WAAW,MAC5BC,eACLF,WAAWG,YAAYC,aAAaC,cAAc;EAChDC,QAAQC,OAAO;IACbC,IAAI,GAAGC,KAAKD,EAAE;IACdE,MAAM;IACNC,QAAQ,CAACC,SAAsCA,KAAKC,YAAY,GAAGJ,KAAKD,EAAE;IAC1EM,WAAW,MAAA;AACT,YAAMC,QAAQC,eAAAA;AACd,UAAI,CAACD,OAAO;AACV,eAAO;MACT;AAEA,aAAO,sBAAA,cAACE,oBAAAA;QAAmBF;;IAC7B;EACF,CAAA;EACAT,QAAQC,OAAO;IACbC,IAAI,GAAGC,KAAKD,EAAE;IACdE,MAAM;IACNC,QAAQ,CAACC,SAAsCA,KAAKC,YAAY,GAAGJ,KAAKD,EAAE;IAC1EM,WAAW,MAAA;AACT,YAAMC,QAAQC,eAAAA;AACd,UAAI,CAACD,OAAO;AACV,eAAO;MACT;AAEA,aAAO,sBAAA,cAACG,oBAAAA;QAAmBH;;IAC7B;EACF,CAAA;EACAT,QAAQC,OAAO;IACbC,IAAI,GAAGC,KAAKD,EAAE;IACdE,MAAM;IACNC,QAAQ,CAACC,SACPO,IAAIC,SAASR,KAAKS,WAAW,KAAKT,KAAKC,YAAY;IACrDC,WAAW,CAAC,EAAEF,KAAI,MAAE;AAClB,aAAO,sBAAA,cAACM,oBAAAA;QAAmBH,OAAOO,SAASV,KAAKS,WAAW;QAAIE,QAAQX,KAAKS;;IAC9E;EACF,CAAA;CACD,CAAA,CAAA;",
6
+ "names": ["Effect", "React", "Capabilities", "Capability", "Surface", "Obj", "useActiveSpace", "getSpace", "lazy", "AutomationSettings", "lazy", "FunctionsContainer", "TriggerSettings", "Capability", "makeModule", "succeed", "contributes", "Capabilities", "ReactSurface", "Surface", "create", "id", "meta", "role", "filter", "data", "subject", "component", "space", "useActiveSpace", "FunctionsContainer", "AutomationSettings", "Obj", "isObject", "companionTo", "getSpace", "object"]
7
+ }
@@ -3,8 +3,8 @@ import {
3
3
  AutomationCapabilities,
4
4
  AutomationEvents,
5
5
  AutomationOperation
6
- } from "../chunk-JOXPQ27I.mjs";
7
- import "../chunk-PZNBEKO5.mjs";
6
+ } from "../chunk-5WMYSXEH.mjs";
7
+ import "../chunk-EL64ZPPN.mjs";
8
8
  export {
9
9
  AutomationAction,
10
10
  AutomationCapabilities,
@@ -2,11 +2,11 @@ import { createRequire } from 'node:module';const require = createRequire(import
2
2
  import {
3
3
  AutomationPanel,
4
4
  AutomationPanel_default
5
- } from "./chunk-2CKVH7JC.mjs";
6
- import "./chunk-LJAXQ6CX.mjs";
7
- import "./chunk-5FXNN3MV.mjs";
5
+ } from "./chunk-FPXVLTEY.mjs";
6
+ import "./chunk-Q5JSKD6Z.mjs";
7
+ import "./chunk-WC5AT7B3.mjs";
8
8
  export {
9
9
  AutomationPanel,
10
10
  AutomationPanel_default as default
11
11
  };
12
- //# sourceMappingURL=AutomationPanel-B7NAGDFA.mjs.map
12
+ //# sourceMappingURL=AutomationPanel-O2BCQA7P.mjs.map
@@ -0,0 +1,7 @@
1
+ {
2
+ "version": 3,
3
+ "sources": [],
4
+ "sourcesContent": [],
5
+ "mappings": "",
6
+ "names": []
7
+ }
@@ -0,0 +1,38 @@
1
+ import { createRequire } from 'node:module';const require = createRequire(import.meta.url);
2
+ import {
3
+ TriggersSettings
4
+ } from "./chunk-BNWZ2NNI.mjs";
5
+ import "./chunk-XQO3HK62.mjs";
6
+ import "./chunk-XCFO2IXT.mjs";
7
+ import {
8
+ AutomationPanel
9
+ } from "./chunk-FPXVLTEY.mjs";
10
+ import "./chunk-Q5JSKD6Z.mjs";
11
+ import {
12
+ meta
13
+ } from "./chunk-WC5AT7B3.mjs";
14
+
15
+ // src/containers/AutomationSettings/AutomationSettings.tsx
16
+ import React from "react";
17
+ import { useTranslation } from "@dxos/react-ui";
18
+ import { Settings } from "@dxos/react-ui-form";
19
+ var AutomationSettings = (props) => {
20
+ const { t } = useTranslation(meta.id);
21
+ return /* @__PURE__ */ React.createElement(Settings.Root, null, /* @__PURE__ */ React.createElement(Settings.Section, {
22
+ title: t("automation verbose label", {
23
+ ns: meta.id
24
+ }),
25
+ description: t("automation description", {
26
+ ns: meta.id
27
+ })
28
+ }, /* @__PURE__ */ React.createElement(AutomationPanel, props), /* @__PURE__ */ React.createElement(TriggersSettings, {
29
+ db: props.space.db
30
+ })));
31
+ };
32
+
33
+ // src/containers/AutomationSettings/index.ts
34
+ var AutomationSettings_default = AutomationSettings;
35
+ export {
36
+ AutomationSettings_default as default
37
+ };
38
+ //# sourceMappingURL=AutomationSettings-W52ZO2XI.mjs.map
@@ -0,0 +1,7 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../../src/containers/AutomationSettings/AutomationSettings.tsx", "../../../src/containers/AutomationSettings/index.ts"],
4
+ "sourcesContent": ["//\n// Copyright 2025 DXOS.org\n//\n\nimport React from 'react';\n\nimport { useTranslation } from '@dxos/react-ui';\nimport { Settings } from '@dxos/react-ui-form';\n\nimport { AutomationPanel, type AutomationPanelProps } from '../../components/AutomationPanel';\nimport { meta } from '../../meta';\nimport { TriggersSettings } from '../TriggerSettings';\n\nexport const AutomationSettings = (props: AutomationPanelProps) => {\n const { t } = useTranslation(meta.id);\n return (\n <Settings.Root>\n <Settings.Section\n title={t('automation verbose label', { ns: meta.id })}\n description={t('automation description', { ns: meta.id })}\n >\n <AutomationPanel {...props} />\n <TriggersSettings db={props.space.db} />\n </Settings.Section>\n </Settings.Root>\n );\n};\n", "//\n// Copyright 2025 DXOS.org\n//\n\nimport { AutomationSettings } from './AutomationSettings';\n\nexport default AutomationSettings;\n"],
5
+ "mappings": ";;;;;;;;;;;;;;;AAIA,OAAOA,WAAW;AAElB,SAASC,sBAAsB;AAC/B,SAASC,gBAAgB;AAMlB,IAAMC,qBAAqB,CAACC,UAAAA;AACjC,QAAM,EAAEC,EAAC,IAAKC,eAAeC,KAAKC,EAAE;AACpC,SACE,sBAAA,cAACC,SAASC,MAAI,MACZ,sBAAA,cAACD,SAASE,SAAO;IACfC,OAAOP,EAAE,4BAA4B;MAAEQ,IAAIN,KAAKC;IAAG,CAAA;IACnDM,aAAaT,EAAE,0BAA0B;MAAEQ,IAAIN,KAAKC;IAAG,CAAA;KAEvD,sBAAA,cAACO,iBAAoBX,KAAAA,GACrB,sBAAA,cAACY,kBAAAA;IAAiBC,IAAIb,MAAMc,MAAMD;;AAI1C;;;ACpBA,IAAA,6BAAeE;",
6
+ "names": ["React", "useTranslation", "Settings", "AutomationSettings", "props", "t", "useTranslation", "meta", "id", "Settings", "Root", "Section", "title", "ns", "description", "AutomationPanel", "TriggersSettings", "db", "space", "AutomationSettings"]
7
+ }
@@ -0,0 +1,44 @@
1
+ import { createRequire } from 'node:module';const require = createRequire(import.meta.url);
2
+ import {
3
+ FunctionsPanel
4
+ } from "./chunk-K7T2MVB7.mjs";
5
+ import {
6
+ FunctionsRegistry
7
+ } from "./chunk-6JVB3IHW.mjs";
8
+ import {
9
+ meta
10
+ } from "./chunk-WC5AT7B3.mjs";
11
+
12
+ // src/containers/FunctionsContainer/FunctionsContainer.tsx
13
+ import React from "react";
14
+ import { useTranslation } from "@dxos/react-ui";
15
+ import { Settings } from "@dxos/react-ui-form";
16
+ var FunctionsContainer = ({ space }) => {
17
+ const { t } = useTranslation(meta.id);
18
+ return /* @__PURE__ */ React.createElement(Settings.Root, null, /* @__PURE__ */ React.createElement(Settings.Section, {
19
+ title: t("functions verbose label", {
20
+ ns: meta.id
21
+ }),
22
+ description: t("functions description", {
23
+ ns: meta.id
24
+ })
25
+ }, /* @__PURE__ */ React.createElement(FunctionsPanel, {
26
+ space
27
+ })), /* @__PURE__ */ React.createElement(Settings.Section, {
28
+ title: t("functions registry verbose label", {
29
+ ns: meta.id
30
+ }),
31
+ description: t("functions registry description", {
32
+ ns: meta.id
33
+ })
34
+ }, /* @__PURE__ */ React.createElement(FunctionsRegistry, {
35
+ space
36
+ })));
37
+ };
38
+
39
+ // src/containers/FunctionsContainer/index.ts
40
+ var FunctionsContainer_default = FunctionsContainer;
41
+ export {
42
+ FunctionsContainer_default as default
43
+ };
44
+ //# sourceMappingURL=FunctionsContainer-GYRPQZM7.mjs.map
@@ -0,0 +1,7 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../../src/containers/FunctionsContainer/FunctionsContainer.tsx", "../../../src/containers/FunctionsContainer/index.ts"],
4
+ "sourcesContent": ["//\n// Copyright 2025 DXOS.org\n//\n\nimport React from 'react';\n\nimport { type Space } from '@dxos/react-client/echo';\nimport { useTranslation } from '@dxos/react-ui';\nimport { Settings } from '@dxos/react-ui-form';\n\nimport { FunctionsPanel } from '../../components/FunctionsPanel';\nimport { FunctionsRegistry } from '../../components/FunctionsRegistry';\nimport { meta } from '../../meta';\n\nexport const FunctionsContainer = ({ space }: { space: Space }) => {\n const { t } = useTranslation(meta.id);\n return (\n <Settings.Root>\n <Settings.Section\n title={t('functions verbose label', { ns: meta.id })}\n description={t('functions description', { ns: meta.id })}\n >\n <FunctionsPanel space={space} />\n </Settings.Section>\n <Settings.Section\n title={t('functions registry verbose label', { ns: meta.id })}\n description={t('functions registry description', { ns: meta.id })}\n >\n <FunctionsRegistry space={space} />\n </Settings.Section>\n </Settings.Root>\n );\n};\n", "//\n// Copyright 2025 DXOS.org\n//\n\nimport { FunctionsContainer } from './FunctionsContainer';\n\nexport default FunctionsContainer;\n"],
5
+ "mappings": ";;;;;;;;;;;;AAIA,OAAOA,WAAW;AAGlB,SAASC,sBAAsB;AAC/B,SAASC,gBAAgB;AAMlB,IAAMC,qBAAqB,CAAC,EAAEC,MAAK,MAAoB;AAC5D,QAAM,EAAEC,EAAC,IAAKC,eAAeC,KAAKC,EAAE;AACpC,SACE,sBAAA,cAACC,SAASC,MAAI,MACZ,sBAAA,cAACD,SAASE,SAAO;IACfC,OAAOP,EAAE,2BAA2B;MAAEQ,IAAIN,KAAKC;IAAG,CAAA;IAClDM,aAAaT,EAAE,yBAAyB;MAAEQ,IAAIN,KAAKC;IAAG,CAAA;KAEtD,sBAAA,cAACO,gBAAAA;IAAeX;OAElB,sBAAA,cAACK,SAASE,SAAO;IACfC,OAAOP,EAAE,oCAAoC;MAAEQ,IAAIN,KAAKC;IAAG,CAAA;IAC3DM,aAAaT,EAAE,kCAAkC;MAAEQ,IAAIN,KAAKC;IAAG,CAAA;KAE/D,sBAAA,cAACQ,mBAAAA;IAAkBZ;;AAI3B;;;AC1BA,IAAA,6BAAea;",
6
+ "names": ["React", "useTranslation", "Settings", "FunctionsContainer", "space", "t", "useTranslation", "meta", "id", "Settings", "Root", "Section", "title", "ns", "description", "FunctionsPanel", "FunctionsRegistry", "FunctionsContainer"]
7
+ }
@@ -2,10 +2,10 @@ import { createRequire } from 'node:module';const require = createRequire(import
2
2
  import {
3
3
  FunctionsPanel,
4
4
  FunctionsPanel_default
5
- } from "./chunk-KWKWOGS5.mjs";
6
- import "./chunk-5FXNN3MV.mjs";
5
+ } from "./chunk-K7T2MVB7.mjs";
6
+ import "./chunk-WC5AT7B3.mjs";
7
7
  export {
8
8
  FunctionsPanel,
9
9
  FunctionsPanel_default as default
10
10
  };
11
- //# sourceMappingURL=FunctionsPanel-SS6GIVNU.mjs.map
11
+ //# sourceMappingURL=FunctionsPanel-DCXXLSVP.mjs.map
@@ -0,0 +1,7 @@
1
+ {
2
+ "version": 3,
3
+ "sources": [],
4
+ "sourcesContent": [],
5
+ "mappings": "",
6
+ "names": []
7
+ }
@@ -0,0 +1,11 @@
1
+ import { createRequire } from 'node:module';const require = createRequire(import.meta.url);
2
+ import {
3
+ FunctionsRegistry,
4
+ FunctionsRegistry_default
5
+ } from "./chunk-6JVB3IHW.mjs";
6
+ import "./chunk-WC5AT7B3.mjs";
7
+ export {
8
+ FunctionsRegistry,
9
+ FunctionsRegistry_default as default
10
+ };
11
+ //# sourceMappingURL=FunctionsRegistry-7WCHC64E.mjs.map
@@ -0,0 +1,7 @@
1
+ {
2
+ "version": 3,
3
+ "sources": [],
4
+ "sourcesContent": [],
5
+ "mappings": "",
6
+ "names": []
7
+ }
@@ -0,0 +1,12 @@
1
+ import { createRequire } from 'node:module';const require = createRequire(import.meta.url);
2
+ import {
3
+ TriggersSettings
4
+ } from "./chunk-BNWZ2NNI.mjs";
5
+ import "./chunk-XQO3HK62.mjs";
6
+ import "./chunk-XCFO2IXT.mjs";
7
+ import "./chunk-WC5AT7B3.mjs";
8
+ export {
9
+ TriggersSettings,
10
+ TriggersSettings as default
11
+ };
12
+ //# sourceMappingURL=TriggerSettings-2GKFPECW.mjs.map
@@ -0,0 +1,7 @@
1
+ {
2
+ "version": 3,
3
+ "sources": [],
4
+ "sourcesContent": [],
5
+ "mappings": "",
6
+ "names": []
7
+ }
@@ -1,25 +1,27 @@
1
1
  import { createRequire } from 'node:module';const require = createRequire(import.meta.url);
2
2
  import {
3
3
  meta
4
- } from "./chunk-5FXNN3MV.mjs";
4
+ } from "./chunk-WC5AT7B3.mjs";
5
5
 
6
6
  // src/capabilities/app-graph-builder/app-graph-builder.ts
7
7
  import * as Effect from "effect/Effect";
8
- import { Capability, Common } from "@dxos/app-framework";
8
+ import { Capability } from "@dxos/app-framework";
9
+ import { AppCapabilities } from "@dxos/app-toolkit";
9
10
  import { Script } from "@dxos/functions";
10
- import { ATTENDABLE_PATH_SEPARATOR, PLANK_COMPANION_TYPE } from "@dxos/plugin-deck/types";
11
+ import { COMPANION_PREFIX } from "@dxos/app-toolkit";
12
+ import { PLANK_COMPANION_TYPE } from "@dxos/plugin-deck/types";
11
13
  import { GraphBuilder, NodeMatcher } from "@dxos/plugin-graph";
12
14
  import { meta as spaceMeta } from "@dxos/plugin-space";
13
15
  var app_graph_builder_default = Capability.makeModule(Effect.fnUntraced(function* () {
14
16
  const extensions = yield* Effect.all([
15
17
  GraphBuilder.createExtension({
16
- id: `${meta.id}/space-settings-automation`,
17
- match: NodeMatcher.whenNodeType(`${spaceMeta.id}/settings`),
18
+ id: `${meta.id}.space-settings-automation`,
19
+ match: NodeMatcher.whenNodeType(`${spaceMeta.id}.settings`),
18
20
  connector: (node) => Effect.succeed([
19
21
  {
20
- id: `automation-${node.id}`,
21
- type: `${meta.id}/space-settings-automation`,
22
- data: `${meta.id}/space-settings-automation`,
22
+ id: `${meta.id}.automations`,
23
+ type: `${meta.id}.space-settings-automation`,
24
+ data: `${meta.id}.space-settings-automation`,
23
25
  properties: {
24
26
  label: [
25
27
  "automation panel label",
@@ -33,13 +35,13 @@ var app_graph_builder_default = Capability.makeModule(Effect.fnUntraced(function
33
35
  ])
34
36
  }),
35
37
  GraphBuilder.createExtension({
36
- id: `${meta.id}/space-settings-functions`,
37
- match: NodeMatcher.whenNodeType(`${spaceMeta.id}/settings`),
38
+ id: `${meta.id}.space-settings-functions`,
39
+ match: NodeMatcher.whenNodeType(`${spaceMeta.id}.settings`),
38
40
  connector: (node) => Effect.succeed([
39
41
  {
40
- id: `functions-${node.id}`,
41
- type: `${meta.id}/space-settings-functions`,
42
- data: `${meta.id}/space-settings-functions`,
42
+ id: `${meta.id}.functions`,
43
+ type: `${meta.id}.space-settings-functions`,
44
+ data: `${meta.id}.space-settings-functions`,
43
45
  properties: {
44
46
  label: [
45
47
  "functions panel label",
@@ -53,14 +55,11 @@ var app_graph_builder_default = Capability.makeModule(Effect.fnUntraced(function
53
55
  ])
54
56
  }),
55
57
  GraphBuilder.createTypeExtension({
56
- id: `${meta.id}/script-companion`,
58
+ id: `${meta.id}.script-companion`,
57
59
  type: Script.Script,
58
60
  connector: (script) => Effect.succeed([
59
61
  {
60
- id: [
61
- script.id,
62
- "automation"
63
- ].join(ATTENDABLE_PATH_SEPARATOR),
62
+ id: `${COMPANION_PREFIX}automation`,
64
63
  type: PLANK_COMPANION_TYPE,
65
64
  data: "automation",
66
65
  properties: {
@@ -77,9 +76,9 @@ var app_graph_builder_default = Capability.makeModule(Effect.fnUntraced(function
77
76
  ])
78
77
  })
79
78
  ]);
80
- return Capability.contributes(Common.Capability.AppGraphBuilder, extensions);
79
+ return Capability.contributes(AppCapabilities.AppGraphBuilder, extensions);
81
80
  }));
82
81
  export {
83
82
  app_graph_builder_default as default
84
83
  };
85
- //# sourceMappingURL=app-graph-builder-4UCMXHYY.mjs.map
84
+ //# sourceMappingURL=app-graph-builder-VDXPOWCH.mjs.map
@@ -0,0 +1,7 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../../src/capabilities/app-graph-builder/app-graph-builder.ts"],
4
+ "sourcesContent": ["//\n// Copyright 2025 DXOS.org\n//\n\nimport * as Effect from 'effect/Effect';\n\nimport { Capability } from '@dxos/app-framework';\nimport { AppCapabilities } from '@dxos/app-toolkit';\nimport { Script } from '@dxos/functions';\nimport { COMPANION_PREFIX } from '@dxos/app-toolkit';\nimport { PLANK_COMPANION_TYPE } from '@dxos/plugin-deck/types';\nimport { GraphBuilder, NodeMatcher } from '@dxos/plugin-graph';\nimport { meta as spaceMeta } from '@dxos/plugin-space';\n\nimport { meta } from '../../meta';\n\nexport default Capability.makeModule(\n Effect.fnUntraced(function* () {\n const extensions = yield* Effect.all([\n GraphBuilder.createExtension({\n id: `${meta.id}.space-settings-automation`,\n match: NodeMatcher.whenNodeType(`${spaceMeta.id}.settings`),\n connector: (node) =>\n Effect.succeed([\n {\n id: `${meta.id}.automations`,\n type: `${meta.id}.space-settings-automation`,\n data: `${meta.id}.space-settings-automation`,\n properties: {\n label: ['automation panel label', { ns: meta.id }],\n icon: 'ph--lightning--regular',\n },\n },\n ]),\n }),\n GraphBuilder.createExtension({\n id: `${meta.id}.space-settings-functions`,\n match: NodeMatcher.whenNodeType(`${spaceMeta.id}.settings`),\n connector: (node) =>\n Effect.succeed([\n {\n id: `${meta.id}.functions`,\n type: `${meta.id}.space-settings-functions`,\n data: `${meta.id}.space-settings-functions`,\n properties: {\n label: ['functions panel label', { ns: meta.id }],\n icon: 'ph--function--regular',\n },\n },\n ]),\n }),\n GraphBuilder.createTypeExtension({\n id: `${meta.id}.script-companion`,\n type: Script.Script,\n connector: (script) =>\n Effect.succeed([\n {\n id: `${COMPANION_PREFIX}automation`,\n type: PLANK_COMPANION_TYPE,\n data: 'automation',\n properties: {\n label: ['script automation label', { ns: meta.id }],\n icon: 'ph--lightning--regular',\n disposition: 'hidden',\n },\n },\n ]),\n }),\n ]);\n\n return Capability.contributes(AppCapabilities.AppGraphBuilder, extensions);\n }),\n);\n"],
5
+ "mappings": ";;;;;;AAIA,YAAYA,YAAY;AAExB,SAASC,kBAAkB;AAC3B,SAASC,uBAAuB;AAChC,SAASC,cAAc;AACvB,SAASC,wBAAwB;AACjC,SAASC,4BAA4B;AACrC,SAASC,cAAcC,mBAAmB;AAC1C,SAASC,QAAQC,iBAAiB;AAIlC,IAAA,4BAAeC,WAAWC,WACjBC,kBAAW,aAAA;AAChB,QAAMC,aAAa,OAAcC,WAAI;IACnCC,aAAaC,gBAAgB;MAC3BC,IAAI,GAAGC,KAAKD,EAAE;MACdE,OAAOC,YAAYC,aAAa,GAAGC,UAAUL,EAAE,WAAW;MAC1DM,WAAW,CAACC,SACHC,eAAQ;QACb;UACER,IAAI,GAAGC,KAAKD,EAAE;UACdS,MAAM,GAAGR,KAAKD,EAAE;UAChBU,MAAM,GAAGT,KAAKD,EAAE;UAChBW,YAAY;YACVC,OAAO;cAAC;cAA0B;gBAAEC,IAAIZ,KAAKD;cAAG;;YAChDc,MAAM;UACR;QACF;OACD;IACL,CAAA;IACAhB,aAAaC,gBAAgB;MAC3BC,IAAI,GAAGC,KAAKD,EAAE;MACdE,OAAOC,YAAYC,aAAa,GAAGC,UAAUL,EAAE,WAAW;MAC1DM,WAAW,CAACC,SACHC,eAAQ;QACb;UACER,IAAI,GAAGC,KAAKD,EAAE;UACdS,MAAM,GAAGR,KAAKD,EAAE;UAChBU,MAAM,GAAGT,KAAKD,EAAE;UAChBW,YAAY;YACVC,OAAO;cAAC;cAAyB;gBAAEC,IAAIZ,KAAKD;cAAG;;YAC/Cc,MAAM;UACR;QACF;OACD;IACL,CAAA;IACAhB,aAAaiB,oBAAoB;MAC/Bf,IAAI,GAAGC,KAAKD,EAAE;MACdS,MAAMO,OAAOA;MACbV,WAAW,CAACW,WACHT,eAAQ;QACb;UACER,IAAI,GAAGkB,gBAAAA;UACPT,MAAMU;UACNT,MAAM;UACNC,YAAY;YACVC,OAAO;cAAC;cAA2B;gBAAEC,IAAIZ,KAAKD;cAAG;;YACjDc,MAAM;YACNM,aAAa;UACf;QACF;OACD;IACL,CAAA;GACD;AAED,SAAO3B,WAAW4B,YAAYC,gBAAgBC,iBAAiB3B,UAAAA;AACjE,CAAA,CAAA;",
6
+ "names": ["Effect", "Capability", "AppCapabilities", "Script", "COMPANION_PREFIX", "PLANK_COMPANION_TYPE", "GraphBuilder", "NodeMatcher", "meta", "spaceMeta", "Capability", "makeModule", "fnUntraced", "extensions", "all", "GraphBuilder", "createExtension", "id", "meta", "match", "NodeMatcher", "whenNodeType", "spaceMeta", "connector", "node", "succeed", "type", "data", "properties", "label", "ns", "icon", "createTypeExtension", "Script", "script", "COMPANION_PREFIX", "PLANK_COMPANION_TYPE", "disposition", "contributes", "AppCapabilities", "AppGraphBuilder"]
7
+ }
@@ -1,15 +1,7 @@
1
1
  import { createRequire } from 'node:module';const require = createRequire(import.meta.url);
2
- import {
3
- FunctionsPanel
4
- } from "./chunk-KWKWOGS5.mjs";
5
2
  import {
6
3
  meta
7
- } from "./chunk-5FXNN3MV.mjs";
8
-
9
- // src/components/FunctionsContainer.tsx
10
- import React2 from "react";
11
- import { useTranslation as useTranslation2 } from "@dxos/react-ui";
12
- import { ControlPage, ControlSection } from "@dxos/react-ui-form";
4
+ } from "./chunk-WC5AT7B3.mjs";
13
5
 
14
6
  // src/components/FunctionsRegistry/FunctionsRegistry.tsx
15
7
  import * as Schema from "effect/Schema";
@@ -19,12 +11,11 @@ import { Function } from "@dxos/functions";
19
11
  import { getDeployedFunctions } from "@dxos/functions-runtime/edge";
20
12
  import { useClient } from "@dxos/react-client";
21
13
  import { Filter, Query, useQuery } from "@dxos/react-client/echo";
22
- import { useAsyncEffect } from "@dxos/react-ui";
23
- import { IconButton, useTranslation } from "@dxos/react-ui";
24
- import { controlItemClasses } from "@dxos/react-ui-form";
14
+ import { IconButton, useAsyncEffect, useTranslation } from "@dxos/react-ui";
15
+ import { Settings } from "@dxos/react-ui-form";
25
16
  import { List } from "@dxos/react-ui-list";
26
17
  import { ghostHover, mx } from "@dxos/ui-theme";
27
- var grid = "grid grid-cols-[1fr_1fr_auto] min-bs-[2.5rem]";
18
+ var grid = "grid grid-cols-[1fr_1fr_auto] min-h-[2.5rem]";
28
19
  var FunctionsRegistry = ({ space }) => {
29
20
  const client = useClient();
30
21
  const [loading, setLoading] = useState(true);
@@ -60,20 +51,17 @@ var FunctionsRegistry = ({ space }) => {
60
51
  }, [
61
52
  space
62
53
  ]);
63
- return /* @__PURE__ */ React.createElement("div", {
64
- role: "none",
65
- className: mx(controlItemClasses)
66
- }, functions.length > 0 && /* @__PURE__ */ React.createElement(List.Root, {
54
+ return /* @__PURE__ */ React.createElement(Settings.Container, null, functions.length > 0 && /* @__PURE__ */ React.createElement(List.Root, {
67
55
  items: functions,
68
56
  isItem: Schema.is(Function.Function),
69
57
  getId: (func) => func.id
70
58
  }, ({ items }) => /* @__PURE__ */ React.createElement("div", {
71
59
  role: "list",
72
- className: "flex flex-col is-full"
60
+ className: "flex flex-col w-full"
73
61
  }, items?.map((func) => /* @__PURE__ */ React.createElement(List.Item, {
74
62
  key: func.id,
75
63
  item: func,
76
- classNames: mx(grid, ghostHover, "items-center", "pli-2", "min-bs-[3rem]")
64
+ classNames: mx(grid, ghostHover, "items-center", "px-2", "min-h-[3rem]")
77
65
  }, /* @__PURE__ */ React.createElement("div", {
78
66
  className: "flex flex-col truncate"
79
67
  }, /* @__PURE__ */ React.createElement(List.ItemTitle, {
@@ -93,38 +81,17 @@ var FunctionsRegistry = ({ space }) => {
93
81
  disabled: state(func) === "none",
94
82
  onClick: () => hanleImportOrUpdate(func)
95
83
  }))))), functions.length === 0 && !loading && /* @__PURE__ */ React.createElement("div", {
96
- className: "text-center plb-4 text-gray-500"
84
+ className: "text-center py-4 text-gray-500"
97
85
  }, t("no functions found")), loading && /* @__PURE__ */ React.createElement("div", {
98
- className: "text-center plb-4 text-gray-500"
86
+ className: "text-center py-4 text-gray-500"
99
87
  }, t("loading functions")));
100
88
  };
101
89
 
102
- // src/components/FunctionsContainer.tsx
103
- var FunctionsContainer = ({ space }) => {
104
- const { t } = useTranslation2(meta.id);
105
- return /* @__PURE__ */ React2.createElement(ControlPage, null, /* @__PURE__ */ React2.createElement(ControlSection, {
106
- title: t("functions verbose label", {
107
- ns: meta.id
108
- }),
109
- description: t("functions description", {
110
- ns: meta.id
111
- })
112
- }, /* @__PURE__ */ React2.createElement(FunctionsPanel, {
113
- space
114
- })), /* @__PURE__ */ React2.createElement(ControlSection, {
115
- title: t("functions registry verbose label", {
116
- ns: meta.id
117
- }),
118
- description: t("functions registry description", {
119
- ns: meta.id
120
- })
121
- }, /* @__PURE__ */ React2.createElement(FunctionsRegistry, {
122
- space
123
- })));
124
- };
125
- var FunctionsContainer_default = FunctionsContainer;
90
+ // src/components/FunctionsRegistry/index.ts
91
+ var FunctionsRegistry_default = FunctionsRegistry;
92
+
126
93
  export {
127
- FunctionsContainer,
128
- FunctionsContainer_default as default
94
+ FunctionsRegistry,
95
+ FunctionsRegistry_default
129
96
  };
130
- //# sourceMappingURL=FunctionsContainer-J4O2ULWR.mjs.map
97
+ //# sourceMappingURL=chunk-6JVB3IHW.mjs.map
@@ -0,0 +1,7 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../../src/components/FunctionsRegistry/FunctionsRegistry.tsx", "../../../src/components/FunctionsRegistry/index.ts"],
4
+ "sourcesContent": ["//\n// Copyright 2025 DXOS.org\n//\n\nimport * as Schema from 'effect/Schema';\nimport { useState } from 'react';\nimport React, { useCallback } from 'react';\n\nimport { Function } from '@dxos/functions';\nimport { getDeployedFunctions } from '@dxos/functions-runtime/edge';\nimport { useClient } from '@dxos/react-client';\nimport { Filter, Query, type Space, useQuery } from '@dxos/react-client/echo';\nimport { IconButton, useAsyncEffect, useTranslation } from '@dxos/react-ui';\nimport { Settings } from '@dxos/react-ui-form';\nimport { List } from '@dxos/react-ui-list';\nimport { ghostHover, mx } from '@dxos/ui-theme';\n\nimport { meta } from '../../meta';\n\nconst grid = 'grid grid-cols-[1fr_1fr_auto] min-h-[2.5rem]';\n\ntype FunctionsRegistryProps = {\n space: Space;\n};\n\nexport const FunctionsRegistry = ({ space }: FunctionsRegistryProps) => {\n const client = useClient();\n const [loading, setLoading] = useState(true);\n const [functions, setFunctions] = useState<Function.Function[]>([]);\n const { t } = useTranslation(meta.id);\n\n const dbFunctions = useQuery(space.db, Filter.type(Function.Function));\n\n const state = (func: Function.Function) => {\n const dbFunction = dbFunctions.find((f) => f.key === func.key);\n if (!dbFunction) {\n return 'import';\n }\n if (dbFunction.version === func.version && dbFunction.updated === func.updated) {\n return 'none';\n }\n return 'update';\n };\n\n useAsyncEffect(async () => {\n setLoading(true);\n const functions = await getDeployedFunctions(client, true);\n setFunctions(functions);\n setLoading(false);\n }, []);\n\n const hanleImportOrUpdate = useCallback(\n async (func: Function.Function) => {\n const functions = await space.db.query(Query.type(Function.Function, { key: func.key })).run();\n const [existingFunc] = functions;\n if (!existingFunc) {\n space.db.add(func);\n return;\n }\n Function.setFrom(existingFunc, func);\n },\n [space],\n );\n\n return (\n <Settings.Container>\n {functions.length > 0 && (\n <List.Root<Function.Function> items={functions} isItem={Schema.is(Function.Function)} getId={(func) => func.id}>\n {({ items }) => (\n <div role='list' className='flex flex-col w-full'>\n {items?.map((func) => (\n <List.Item<Function.Function>\n key={func.id}\n item={func}\n classNames={mx(grid, ghostHover, 'items-center', 'px-2', 'min-h-[3rem]')}\n >\n <div className='flex flex-col truncate'>\n <List.ItemTitle classNames='truncate'>{func.name}</List.ItemTitle>\n <div className='text-xs text-description truncate'>{func.key}</div>\n </div>\n <div className='flex flex-col truncate'>\n <div className='text-xs text-description truncate'>{func.version}</div>\n <div className='text-xs text-description truncate'>\n {func.updated ? `Uploaded ${new Date(func.updated).toLocaleString()}` : ''}\n </div>\n </div>\n\n <IconButton\n iconOnly\n icon={state(func) === 'update' ? 'ph--arrows-clockwise--regular' : 'ph--download--regular'}\n label={\n state(func) === 'update' ? t('update function button label') : t('import function button label')\n }\n disabled={state(func) === 'none'}\n onClick={() => hanleImportOrUpdate(func)}\n />\n </List.Item>\n ))}\n </div>\n )}\n </List.Root>\n )}\n\n {functions.length === 0 && !loading && (\n <div className='text-center py-4 text-gray-500'>{t('no functions found')}</div>\n )}\n {loading && <div className='text-center py-4 text-gray-500'>{t('loading functions')}</div>}\n </Settings.Container>\n );\n};\n", "//\n// Copyright 2025 DXOS.org\n//\n\nimport { FunctionsRegistry } from './FunctionsRegistry';\n\nexport { FunctionsRegistry };\nexport default FunctionsRegistry;\n"],
5
+ "mappings": "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",
6
+ "names": ["Schema", "useState", "React", "useCallback", "Function", "getDeployedFunctions", "useClient", "Filter", "Query", "useQuery", "IconButton", "useAsyncEffect", "useTranslation", "Settings", "List", "ghostHover", "mx", "grid", "FunctionsRegistry", "space", "client", "useClient", "loading", "setLoading", "useState", "functions", "setFunctions", "t", "useTranslation", "meta", "id", "dbFunctions", "useQuery", "db", "Filter", "type", "Function", "state", "func", "dbFunction", "find", "f", "key", "version", "updated", "useAsyncEffect", "getDeployedFunctions", "hanleImportOrUpdate", "useCallback", "query", "Query", "run", "existingFunc", "add", "setFrom", "Settings", "Container", "length", "List", "Root", "items", "isItem", "is", "getId", "div", "role", "className", "map", "Item", "item", "classNames", "mx", "ghostHover", "ItemTitle", "name", "Date", "toLocaleString", "IconButton", "iconOnly", "icon", "label", "disabled", "onClick", "FunctionsRegistry"]
7
+ }
@@ -0,0 +1,32 @@
1
+ import { createRequire } from 'node:module';const require = createRequire(import.meta.url);
2
+ import {
3
+ useTriggerRuntimeControls
4
+ } from "./chunk-XQO3HK62.mjs";
5
+ import {
6
+ meta
7
+ } from "./chunk-WC5AT7B3.mjs";
8
+
9
+ // src/containers/TriggerSettings/TriggerSettings.tsx
10
+ import React from "react";
11
+ import { Input, useTranslation } from "@dxos/react-ui";
12
+ import { Settings } from "@dxos/react-ui-form";
13
+ var TriggersSettings = ({ db }) => {
14
+ const { state, start, stop } = useTriggerRuntimeControls(db);
15
+ const isRunning = state?.enabled ?? false;
16
+ const { t } = useTranslation(meta.id);
17
+ return /* @__PURE__ */ React.createElement("div", {
18
+ className: "grid grid-cols-1 md:grid-cols-[1fr_min-content]"
19
+ }, /* @__PURE__ */ React.createElement(Settings.ItemInput, {
20
+ title: t("runtime label"),
21
+ description: t("runtime description")
22
+ }, /* @__PURE__ */ React.createElement(Input.Switch, {
23
+ classNames: "justify-self-end",
24
+ checked: isRunning,
25
+ onCheckedChange: isRunning ? stop : start
26
+ })));
27
+ };
28
+
29
+ export {
30
+ TriggersSettings
31
+ };
32
+ //# sourceMappingURL=chunk-BNWZ2NNI.mjs.map
@@ -0,0 +1,7 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../../src/containers/TriggerSettings/TriggerSettings.tsx"],
4
+ "sourcesContent": ["//\n// Copyright 2025 DXOS.org\n//\n\nimport React from 'react';\n\nimport { type Database } from '@dxos/echo';\nimport { Input, useTranslation } from '@dxos/react-ui';\nimport { Settings } from '@dxos/react-ui-form';\n\nimport { useTriggerRuntimeControls } from '../../hooks';\nimport { meta } from '../../meta';\n\nexport const TriggersSettings = ({ db }: { db: Database.Database }) => {\n const { state, start, stop } = useTriggerRuntimeControls(db);\n const isRunning = state?.enabled ?? false;\n const { t } = useTranslation(meta.id);\n\n return (\n <div className='grid grid-cols-1 md:grid-cols-[1fr_min-content]'>\n <Settings.ItemInput title={t('runtime label')} description={t('runtime description')}>\n <Input.Switch classNames='justify-self-end' checked={isRunning} onCheckedChange={isRunning ? stop : start} />\n </Settings.ItemInput>\n </div>\n );\n};\n"],
5
+ "mappings": ";;;;;;;;;AAIA,OAAOA,WAAW;AAGlB,SAASC,OAAOC,sBAAsB;AACtC,SAASC,gBAAgB;AAKlB,IAAMC,mBAAmB,CAAC,EAAEC,GAAE,MAA6B;AAChE,QAAM,EAAEC,OAAOC,OAAOC,KAAI,IAAKC,0BAA0BJ,EAAAA;AACzD,QAAMK,YAAYJ,OAAOK,WAAW;AACpC,QAAM,EAAEC,EAAC,IAAKC,eAAeC,KAAKC,EAAE;AAEpC,SACE,sBAAA,cAACC,OAAAA;IAAIC,WAAU;KACb,sBAAA,cAACC,SAASC,WAAS;IAACC,OAAOR,EAAE,eAAA;IAAkBS,aAAaT,EAAE,qBAAA;KAC5D,sBAAA,cAACU,MAAMC,QAAM;IAACC,YAAW;IAAmBC,SAASf;IAAWgB,iBAAiBhB,YAAYF,OAAOD;;AAI5G;",
6
+ "names": ["React", "Input", "useTranslation", "Settings", "TriggersSettings", "db", "state", "start", "stop", "useTriggerRuntimeControls", "isRunning", "enabled", "t", "useTranslation", "meta", "id", "div", "className", "Settings", "ItemInput", "title", "description", "Input", "Switch", "classNames", "checked", "onCheckedChange"]
7
+ }