@powerhousedao/workflow 6.2.3-dev.53 → 6.2.3-dev.55
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.
- package/dist/browser/{BlockSelector-CzJnQWsh.js → BlockSelector-DnBab95a.js} +3 -3
- package/dist/browser/{BlockSelector-CzJnQWsh.js.map → BlockSelector-DnBab95a.js.map} +1 -1
- package/dist/browser/block-type-kX-27vVt.js +44 -0
- package/dist/browser/block-type-kX-27vVt.js.map +1 -0
- package/dist/browser/{connection-BP17lpt3.js → connection-BXV8I017.js} +2 -2
- package/dist/browser/{connection-BP17lpt3.js.map → connection-BXV8I017.js.map} +1 -1
- package/dist/browser/{connection-form-cCgfAa1A.js → connection-form-Cy2fyFUR.js} +24 -28
- package/dist/browser/connection-form-Cy2fyFUR.js.map +1 -0
- package/dist/browser/{data-tree-S_SwaRve.js → data-tree-BvFLAMyE.js} +2 -2
- package/dist/browser/{data-tree-S_SwaRve.js.map → data-tree-BvFLAMyE.js.map} +1 -1
- package/dist/browser/document-models/connection/index.js +3 -3
- package/dist/browser/document-models/index.js +3 -3
- package/dist/browser/document-models/workflow/index.js +3 -3
- package/dist/browser/{document-models-B08jDa_s.js → document-models-CncHyXAk.js} +3 -3
- package/dist/browser/{document-models-B08jDa_s.js.map → document-models-CncHyXAk.js.map} +1 -1
- package/dist/browser/{editor-CQyfDOIN.js → editor-CEJO-2Ue.js} +138 -127
- package/dist/browser/editor-CEJO-2Ue.js.map +1 -0
- package/dist/{node/editor-EeTeVS3A.mjs → browser/editor-DVBnS8YM.js} +360 -319
- package/dist/browser/editor-DVBnS8YM.js.map +1 -0
- package/dist/browser/{editor-CVXRNht0.js → editor-Dc9Q55q1.js} +7 -7
- package/dist/browser/{editor-CVXRNht0.js.map → editor-Dc9Q55q1.js.map} +1 -1
- package/dist/browser/editors/connection-editor/module.js +1 -1
- package/dist/browser/editors/runtime/index.js +2 -0
- package/dist/browser/editors/workflow-editor/module.js +1 -1
- package/dist/browser/editors/workflow-studio/module.js +1 -1
- package/dist/browser/index.js +4 -4
- package/dist/browser/{module-B2BMwu5E.js → module-DIQ3tQ2M.js} +97 -2
- package/dist/browser/module-DIQ3tQ2M.js.map +1 -0
- package/dist/browser/{module-ozS5EVRx.js → module-DxQBeqBh.js} +211 -83
- package/dist/browser/module-DxQBeqBh.js.map +1 -0
- package/dist/browser/reactor/index.js +2 -2
- package/dist/browser/{runtime-queries-2hn7fcKn.js → runtime-queries-DehIdatq.js} +3 -3
- package/dist/browser/{runtime-queries-2hn7fcKn.js.map → runtime-queries-DehIdatq.js.map} +1 -1
- package/dist/browser/{trigger-text-Cfyx8tMq.js → trigger-text-CfRbN-DV.js} +5 -5
- package/dist/browser/trigger-text-CfRbN-DV.js.map +1 -0
- package/dist/browser/upgrade-manifests-CAE3ivDp.js +8 -0
- package/dist/browser/{upgrade-manifests-DHGmgHKW.js.map → upgrade-manifests-CAE3ivDp.js.map} +1 -1
- package/dist/browser/{workflow-DoewHe4K.js → workflow-C003Wutu.js} +2 -2
- package/dist/browser/{workflow-DoewHe4K.js.map → workflow-C003Wutu.js.map} +1 -1
- package/dist/node/{BlockSelector-g9m3yaJj.mjs → BlockSelector-B77i85CO.mjs} +3 -3
- package/dist/node/{BlockSelector-g9m3yaJj.mjs.map → BlockSelector-B77i85CO.mjs.map} +1 -1
- package/dist/node/block-type-kX-27vVt.mjs +44 -0
- package/dist/node/block-type-kX-27vVt.mjs.map +1 -0
- package/dist/node/{connection-BxJoL8js.mjs → connection-BzW9OpKx.mjs} +2 -2
- package/dist/node/{connection-BxJoL8js.mjs.map → connection-BzW9OpKx.mjs.map} +1 -1
- package/dist/node/{connection-form-h0PidbTI.mjs → connection-form-BCwEO3ll.mjs} +24 -28
- package/dist/node/connection-form-BCwEO3ll.mjs.map +1 -0
- package/dist/node/{data-tree-CKKeR7qj.mjs → data-tree-CH8KnNSz.mjs} +2 -2
- package/dist/node/{data-tree-CKKeR7qj.mjs.map → data-tree-CH8KnNSz.mjs.map} +1 -1
- package/dist/node/document-models/connection/index.mjs +3 -3
- package/dist/node/document-models/index.mjs +3 -3
- package/dist/node/document-models/workflow/index.mjs +3 -3
- package/dist/node/{editor-BAbYXi7T.mjs → editor-BYzFMCB8.mjs} +7 -7
- package/dist/node/{editor-BAbYXi7T.mjs.map → editor-BYzFMCB8.mjs.map} +1 -1
- package/dist/{browser/editor-CbpyTAEC.js → node/editor-CsMRho-A.mjs} +360 -319
- package/dist/node/editor-CsMRho-A.mjs.map +1 -0
- package/dist/node/{editor-DCsT8WsQ.mjs → editor-DtLyolUn.mjs} +138 -127
- package/dist/node/editor-DtLyolUn.mjs.map +1 -0
- package/dist/node/editors/connection-editor/module.mjs +1 -1
- package/dist/node/editors/runtime/index.mjs +2 -0
- package/dist/node/editors/workflow-editor/module.mjs +1 -1
- package/dist/node/editors/workflow-studio/module.mjs +1 -1
- package/dist/node/index.mjs +4 -4
- package/dist/node/{module-BlT-atBQ.mjs → module-Bl_4mnxR.mjs} +97 -2
- package/dist/node/module-Bl_4mnxR.mjs.map +1 -0
- package/dist/node/{module-uKdoLIga.mjs → module-DPg8IYIn.mjs} +211 -83
- package/dist/node/module-DPg8IYIn.mjs.map +1 -0
- package/dist/node/pieces/reactor/descriptor.json +1 -1
- package/dist/node/pieces/reactor/package.json +1 -1
- package/dist/node/{runtime-queries-BtTx8FU3.mjs → runtime-queries-CJSpbsBq.mjs} +3 -3
- package/dist/node/{runtime-queries-BtTx8FU3.mjs.map → runtime-queries-CJSpbsBq.mjs.map} +1 -1
- package/dist/node/{trigger-text-CtSXg0KB.mjs → trigger-text-C6BlOwck.mjs} +5 -5
- package/dist/node/trigger-text-C6BlOwck.mjs.map +1 -0
- package/dist/node/upgrade-manifests-7SFwDrhd.mjs +8 -0
- package/dist/node/{upgrade-manifests-D-pLniUG.mjs.map → upgrade-manifests-7SFwDrhd.mjs.map} +1 -1
- package/dist/node/{workflow-Dy-309pE.mjs → workflow-7pmOvHmg.mjs} +2 -2
- package/dist/node/{workflow-Dy-309pE.mjs.map → workflow-7pmOvHmg.mjs.map} +1 -1
- package/dist/powerhouse.manifest.json +1 -1
- package/dist/style.css +29 -14
- package/dist/types/document-models/connection/v1/actions.d.ts +2 -0
- package/dist/types/document-models/connection/v1/actions.d.ts.map +1 -1
- package/dist/types/document-models/connection/v1/gen/config/actions.d.ts +10 -2
- package/dist/types/document-models/connection/v1/gen/config/actions.d.ts.map +1 -1
- package/dist/types/document-models/connection/v1/gen/config/creators.d.ts +4 -2
- package/dist/types/document-models/connection/v1/gen/config/creators.d.ts.map +1 -1
- package/dist/types/document-models/connection/v1/gen/config/error.d.ts +15 -1
- package/dist/types/document-models/connection/v1/gen/config/error.d.ts.map +1 -1
- package/dist/types/document-models/connection/v1/gen/config/operations.d.ts +3 -1
- package/dist/types/document-models/connection/v1/gen/config/operations.d.ts.map +1 -1
- package/dist/types/document-models/connection/v1/gen/document-model.d.ts.map +1 -1
- package/dist/types/document-models/connection/v1/gen/reducer.d.ts.map +1 -1
- package/dist/types/document-models/connection/v1/gen/schema/types.d.ts +7 -0
- package/dist/types/document-models/connection/v1/gen/schema/types.d.ts.map +1 -1
- package/dist/types/document-models/connection/v1/gen/schema/zod.d.ts +3 -1
- package/dist/types/document-models/connection/v1/gen/schema/zod.d.ts.map +1 -1
- package/dist/types/document-models/connection/v1/module.d.ts +2 -0
- package/dist/types/document-models/connection/v1/module.d.ts.map +1 -1
- package/dist/types/document-models/connection/v1/src/reducers/config.d.ts.map +1 -1
- package/dist/types/document-models/connection/v1/tests/config-values.test.d.ts +2 -0
- package/dist/types/document-models/connection/v1/tests/config-values.test.d.ts.map +1 -0
- package/dist/types/document-models/document-models.d.ts +5 -0
- package/dist/types/document-models/document-models.d.ts.map +1 -1
- package/dist/types/document-models/workflow/v1/actions.d.ts +3 -0
- package/dist/types/document-models/workflow/v1/actions.d.ts.map +1 -1
- package/dist/types/document-models/workflow/v1/gen/document-model.d.ts.map +1 -1
- package/dist/types/document-models/workflow/v1/gen/reducer.d.ts.map +1 -1
- package/dist/types/document-models/workflow/v1/gen/schema/types.d.ts +16 -0
- package/dist/types/document-models/workflow/v1/gen/schema/types.d.ts.map +1 -1
- package/dist/types/document-models/workflow/v1/gen/schema/zod.d.ts +5 -1
- package/dist/types/document-models/workflow/v1/gen/schema/zod.d.ts.map +1 -1
- package/dist/types/document-models/workflow/v1/gen/trigger/actions.d.ts +14 -2
- package/dist/types/document-models/workflow/v1/gen/trigger/actions.d.ts.map +1 -1
- package/dist/types/document-models/workflow/v1/gen/trigger/creators.d.ts +5 -2
- package/dist/types/document-models/workflow/v1/gen/trigger/creators.d.ts.map +1 -1
- package/dist/types/document-models/workflow/v1/gen/trigger/error.d.ts +32 -1
- package/dist/types/document-models/workflow/v1/gen/trigger/error.d.ts.map +1 -1
- package/dist/types/document-models/workflow/v1/gen/trigger/operations.d.ts +4 -1
- package/dist/types/document-models/workflow/v1/gen/trigger/operations.d.ts.map +1 -1
- package/dist/types/document-models/workflow/v1/module.d.ts +3 -0
- package/dist/types/document-models/workflow/v1/module.d.ts.map +1 -1
- package/dist/types/document-models/workflow/v1/src/reducers/trigger.d.ts.map +1 -1
- package/dist/types/document-models/workflow/v1/tests/trigger-fields.test.d.ts +2 -0
- package/dist/types/document-models/workflow/v1/tests/trigger-fields.test.d.ts.map +1 -0
- package/dist/types/editors/connection-editor/ReactorConnectionSettings.d.ts.map +1 -1
- package/dist/types/editors/connection-editor/connection-callbacks.d.ts.map +1 -1
- package/dist/types/editors/connection-editor/connection-form.d.ts +2 -2
- package/dist/types/editors/connection-editor/connection-form.d.ts.map +1 -1
- package/dist/types/editors/runtime/index.d.ts +21 -0
- package/dist/types/editors/runtime/index.d.ts.map +1 -0
- package/dist/types/editors/runtime/runtime-export.test.d.ts +2 -0
- package/dist/types/editors/runtime/runtime-export.test.d.ts.map +1 -0
- package/dist/types/editors/shared/pending-echo.d.ts +9 -0
- package/dist/types/editors/shared/pending-echo.d.ts.map +1 -0
- package/dist/types/editors/workflow-editor/document/useWorkflowModel.d.ts.map +1 -1
- package/dist/types/editors/workflow-editor/ui/PropertyForm.d.ts.map +1 -1
- package/dist/types/editors/workflow-editor/ui/ScheduleBuilder.d.ts.map +1 -1
- package/dist/types/editors/workflow-editor/ui/StepPanel.d.ts.map +1 -1
- package/dist/types/editors/workflow-editor/ui/model.d.ts +6 -0
- package/dist/types/editors/workflow-editor/ui/model.d.ts.map +1 -1
- package/dist/types/editors/workflow-studio/components/WorkflowBoard.d.ts.map +1 -1
- package/dist/types/editors/workflow-studio/components/WorkflowGraph.d.ts.map +1 -1
- package/dist/types/editors/workflow-studio/components/chain.d.ts +3 -1
- package/dist/types/editors/workflow-studio/components/chain.d.ts.map +1 -1
- package/dist/types/editors/workflow-studio/components/tips.d.ts +23 -0
- package/dist/types/editors/workflow-studio/components/tips.d.ts.map +1 -0
- package/dist/types/scripts/ui-stack.d.ts.map +1 -1
- package/dist/types/test/ui/harness/property-form-echo.d.ts +12 -0
- package/dist/types/test/ui/harness/property-form-echo.d.ts.map +1 -0
- package/dist/types/test/ui/harness/schedule-builder.d.ts +8 -0
- package/dist/types/test/ui/harness/schedule-builder.d.ts.map +1 -0
- package/dist/types/test/ui/property-form-echo.spec.d.ts +2 -0
- package/dist/types/test/ui/property-form-echo.spec.d.ts.map +1 -0
- package/dist/types/test/ui/schedule-builder.spec.d.ts +2 -0
- package/dist/types/test/ui/schedule-builder.spec.d.ts.map +1 -0
- package/package.json +14 -8
- package/dist/browser/connection-form-cCgfAa1A.js.map +0 -1
- package/dist/browser/editor-CQyfDOIN.js.map +0 -1
- package/dist/browser/editor-CbpyTAEC.js.map +0 -1
- package/dist/browser/module-B2BMwu5E.js.map +0 -1
- package/dist/browser/module-ozS5EVRx.js.map +0 -1
- package/dist/browser/trigger-text-Cfyx8tMq.js.map +0 -1
- package/dist/browser/upgrade-manifests-DHGmgHKW.js +0 -8
- package/dist/node/connection-form-h0PidbTI.mjs.map +0 -1
- package/dist/node/editor-DCsT8WsQ.mjs.map +0 -1
- package/dist/node/editor-EeTeVS3A.mjs.map +0 -1
- package/dist/node/module-BlT-atBQ.mjs.map +0 -1
- package/dist/node/module-uKdoLIga.mjs.map +0 -1
- package/dist/node/trigger-text-CtSXg0KB.mjs.map +0 -1
- package/dist/node/upgrade-manifests-D-pLniUG.mjs +0 -8
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { A as
|
|
2
|
-
import { a as createConnectionDocument, c as defaultLocalState, i as useSelectedConnectionDocument, l as defaultPHState, n as useConnectionDocumentsInSelectedDrive, o as createState, r as useConnectionDocumentsInSelectedFolder, s as defaultGlobalState, t as useConnectionDocumentById, u as ConnectionController } from "../../connection-
|
|
3
|
-
export { Connection, ConnectionAuthTypeSchema, ConnectionController, ConnectionDocumentHeaderSchema, ConnectionDocumentSchema, ConnectionPHStateSchema, ConnectionStateSchema, ConnectionStatusSchema, REACTOR_CONNECTOR_ID, REACTOR_LOCAL_ENDPOINT, ReactorConnectionConfigSchema, RecordCheckResultInputSchema, RemoveSecretRefInputSchema, SecretRefSchema, SetAccountLabelInputSchema, SetConfigInputSchema, SetConnectionNameInputSchema, SetConnectorInputSchema, SetSecretRefInputSchema, actions, assertIsConnectionDocument, assertIsConnectionState, creators_exports as connectionConfigActions, creators_exports$1 as connectionConnectionActions, connectionDocumentType, creators_exports$2 as connectionHealthActions, connectionUpgradeManifest, createConnectionDocument, createState, defaultGlobalState, defaultLocalState, defaultPHState, defaultReactorConnectionConfig, definedNonNullAnySchema, documentModel, initialGlobalState, initialLocalState, isConnectionDocument, isConnectionState, isDefinedNonNullAny, isReactorConnectorId, latestVersion, parseReactorConnectionConfig, recordCheckResult, reducer, removeSecretRef, setAccountLabel, setConfig, setConnectionName, setConnector, setSecretRef, supportedVersions, useConnectionDocumentById, useConnectionDocumentsInSelectedDrive, useConnectionDocumentsInSelectedFolder, useSelectedConnectionDocument, utils };
|
|
1
|
+
import { A as setConfigValue, B as ReactorConnectionConfigSchema, C as setAccountLabel, D as removeConfigValue, E as creators_exports, F as isReactorConnectorId, G as SetAccountLabelInputSchema, H as RemoveConfigValueInputSchema, I as parseReactorConnectionConfig, J as SetConnectionNameInputSchema, K as SetConfigInputSchema, L as ConnectionAuthTypeSchema, M as REACTOR_CONNECTOR_ID, N as REACTOR_LOCAL_ENDPOINT, O as removeSecretRef, P as defaultReactorConnectionConfig, Q as isDefinedNonNullAny, R as ConnectionStateSchema, S as creators_exports$1, T as setConnector, U as RemoveSecretRefInputSchema, V as RecordCheckResultInputSchema, W as SecretRefSchema, X as SetSecretRefInputSchema, Y as SetConnectorInputSchema, Z as definedNonNullAnySchema, _ as reducer, b as creators_exports$2, c as ConnectionPHStateSchema, d as isConnectionDocument, f as isConnectionState, g as supportedVersions, h as latestVersion, i as initialLocalState, j as setSecretRef, k as setConfig, l as assertIsConnectionDocument, m as connectionUpgradeManifest, n as utils, o as ConnectionDocumentHeaderSchema, p as connectionDocumentType, q as SetConfigValueInputSchema, r as initialGlobalState, s as ConnectionDocumentSchema, t as Connection, u as assertIsConnectionState, v as documentModel, w as setConnectionName, x as recordCheckResult, y as actions, z as ConnectionStatusSchema } from "../../module-DIQ3tQ2M.js";
|
|
2
|
+
import { a as createConnectionDocument, c as defaultLocalState, i as useSelectedConnectionDocument, l as defaultPHState, n as useConnectionDocumentsInSelectedDrive, o as createState, r as useConnectionDocumentsInSelectedFolder, s as defaultGlobalState, t as useConnectionDocumentById, u as ConnectionController } from "../../connection-BXV8I017.js";
|
|
3
|
+
export { Connection, ConnectionAuthTypeSchema, ConnectionController, ConnectionDocumentHeaderSchema, ConnectionDocumentSchema, ConnectionPHStateSchema, ConnectionStateSchema, ConnectionStatusSchema, REACTOR_CONNECTOR_ID, REACTOR_LOCAL_ENDPOINT, ReactorConnectionConfigSchema, RecordCheckResultInputSchema, RemoveConfigValueInputSchema, RemoveSecretRefInputSchema, SecretRefSchema, SetAccountLabelInputSchema, SetConfigInputSchema, SetConfigValueInputSchema, SetConnectionNameInputSchema, SetConnectorInputSchema, SetSecretRefInputSchema, actions, assertIsConnectionDocument, assertIsConnectionState, creators_exports as connectionConfigActions, creators_exports$1 as connectionConnectionActions, connectionDocumentType, creators_exports$2 as connectionHealthActions, connectionUpgradeManifest, createConnectionDocument, createState, defaultGlobalState, defaultLocalState, defaultPHState, defaultReactorConnectionConfig, definedNonNullAnySchema, documentModel, initialGlobalState, initialLocalState, isConnectionDocument, isConnectionState, isDefinedNonNullAny, isReactorConnectorId, latestVersion, parseReactorConnectionConfig, recordCheckResult, reducer, removeConfigValue, removeSecretRef, setAccountLabel, setConfig, setConfigValue, setConnectionName, setConnector, setSecretRef, supportedVersions, useConnectionDocumentById, useConnectionDocumentsInSelectedDrive, useConnectionDocumentsInSelectedFolder, useSelectedConnectionDocument, utils };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { t as
|
|
2
|
-
import { t as
|
|
3
|
-
import { t as upgradeManifests } from "../upgrade-manifests-
|
|
1
|
+
import { t as Connection } from "../module-DIQ3tQ2M.js";
|
|
2
|
+
import { t as Workflow } from "../module-DxQBeqBh.js";
|
|
3
|
+
import { t as upgradeManifests } from "../upgrade-manifests-CAE3ivDp.js";
|
|
4
4
|
export { Connection as ConnectionV1, Workflow as WorkflowV1, upgradeManifests };
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { $ as
|
|
2
|
-
import { a as createState, c as defaultLocalState, i as useWorkflowDocumentsInSelectedFolder, l as defaultPHState, n as useWorkflowDocumentById, o as createWorkflowDocument, r as useWorkflowDocumentsInSelectedDrive, s as defaultGlobalState, t as useSelectedWorkflowDocument, u as WorkflowController } from "../../workflow-
|
|
3
|
-
export { AddEdgeInputSchema, AddStepInputSchema, AddStepPositionInputSchema, AddStepPropertySettingInputSchema, AddStepRetryPolicyInputSchema, BackoffKindSchema, ClearTriggerInputSchema, ConcurrencyModeSchema, FailureModeSchema, PointSchema, PropertyModeSchema, PropertySettingSchema, PublishWorkflowInputSchema, PublishedWorkflowSchema, RemoveEdgeInputSchema, RemoveStepInputSchema, RemoveVariableInputSchema, RetryPolicySchema, RevertToPublishedInputSchema, RunStatusSchema, SetLastRunInputSchema, SetLastTestInputSchema, SetPolicyInputSchema, SetPolicyRetryPolicyInputSchema, SetStepConfigInputSchema, SetStepConfigPropertySettingInputSchema, SetTriggerInputSchema, SetTriggerPropertySettingInputSchema, SetVariableInputSchema, SetWorkflowDescriptionInputSchema, SetWorkflowNameInputSchema, SetWorkflowStatusInputSchema, StepTestRecordSchema, TriggerBindingSchema, UpdateStepInputSchema, UpdateStepPositionInputSchema, UpdateStepRetryPolicyInputSchema, VariableTypeSchema, Workflow, WorkflowController, WorkflowDocumentHeaderSchema, WorkflowDocumentSchema, WorkflowEdgeSchema, WorkflowPHStateSchema, WorkflowPolicySchema, WorkflowStateSchema, WorkflowStatusSchema, WorkflowStepSchema, WorkflowVariableSchema, actions, addEdge, addStep, assertIsWorkflowDocument, assertIsWorkflowState, clearTrigger, createState, createWorkflowDocument, defaultGlobalState, defaultLocalState, defaultPHState, definedNonNullAnySchema, documentModel, initialGlobalState, initialLocalState, isDefinedNonNullAny, isWorkflowDocument, isWorkflowState, latestVersion, publishWorkflow, reducer, removeEdge, removeStep, removeVariable, revertToPublished, setLastRun, setLastTest, setPolicy, setStepConfig, setTrigger, setVariable, setWorkflowDescription, setWorkflowName, setWorkflowStatus, supportedVersions, updateStep, useSelectedWorkflowDocument, useWorkflowDocumentById, useWorkflowDocumentsInSelectedDrive, useWorkflowDocumentsInSelectedFolder, utils, workflowDocumentType, creators_exports as workflowEdgesActions, creators_exports$1 as workflowPolicyActions, creators_exports$2 as workflowPublishingActions, creators_exports$3 as workflowRuntimeActions, creators_exports$4 as workflowStepsActions, creators_exports$5 as workflowTriggerActions, workflowUpgradeManifest, creators_exports$6 as workflowVariablesActions, creators_exports$7 as workflowWorkflowActions };
|
|
1
|
+
import { $ as AddStepRetryPolicyInputSchema, A as setTriggerConfig, At as SetWorkflowStatusInputSchema, B as setLastTest, Bt as WorkflowStatusSchema, C as setWorkflowStatus, Ct as SetTriggerConnectionInputSchema, D as clearTrigger, Dt as SetVariableInputSchema, E as setVariable, Et as SetTriggerPropertySettingInputSchema, F as removeStep, Ft as UpdateStepRetryPolicyInputSchema, G as setPolicy, H as publishWorkflow, Ht as WorkflowVariableSchema, I as setStepConfig, It as VariableTypeSchema, J as removeEdge, K as addEdge, L as updateStep, Lt as WorkflowEdgeSchema, M as setTriggerPieceVersion, Mt as TriggerBindingSchema, N as addStep, Nt as UpdateStepInputSchema, O as creators_exports$5, Ot as SetWorkflowDescriptionInputSchema, P as creators_exports$4, Pt as UpdateStepPositionInputSchema, Q as AddStepPropertySettingInputSchema, R as creators_exports$3, Rt as WorkflowPolicySchema, S as setWorkflowName, St as SetTriggerConfigPropertySettingInputSchema, T as removeVariable, Tt as SetTriggerPieceVersionInputSchema, U as revertToPublished, Ut as definedNonNullAnySchema, V as creators_exports$2, Vt as WorkflowStepSchema, W as creators_exports$1, Wt as isDefinedNonNullAny, X as AddStepInputSchema, Y as AddEdgeInputSchema, Z as AddStepPositionInputSchema, _ as reducer, _t as SetPolicyInputSchema, at as PropertyModeSchema, b as creators_exports$7, bt as SetStepConfigPropertySettingInputSchema, c as WorkflowPHStateSchema, ct as PublishedWorkflowSchema, d as isWorkflowDocument, dt as RemoveVariableInputSchema, et as BackoffKindSchema, f as isWorkflowState, ft as RetryPolicySchema, g as supportedVersions, gt as SetLastTestInputSchema, h as latestVersion, ht as SetLastRunInputSchema, i as initialLocalState, it as PointSchema, j as setTriggerConnection, jt as StepTestRecordSchema, k as setTrigger, kt as SetWorkflowNameInputSchema, l as assertIsWorkflowDocument, lt as RemoveEdgeInputSchema, m as workflowUpgradeManifest, mt as RunStatusSchema, n as utils, nt as ConcurrencyModeSchema, o as WorkflowDocumentHeaderSchema, ot as PropertySettingSchema, p as workflowDocumentType, pt as RevertToPublishedInputSchema, q as creators_exports, r as initialGlobalState, rt as FailureModeSchema, s as WorkflowDocumentSchema, st as PublishWorkflowInputSchema, t as Workflow, tt as ClearTriggerInputSchema, u as assertIsWorkflowState, ut as RemoveStepInputSchema, v as documentModel, vt as SetPolicyRetryPolicyInputSchema, w as creators_exports$6, wt as SetTriggerInputSchema, x as setWorkflowDescription, xt as SetTriggerConfigInputSchema, y as actions, yt as SetStepConfigInputSchema, z as setLastRun, zt as WorkflowStateSchema } from "../../module-DxQBeqBh.js";
|
|
2
|
+
import { a as createState, c as defaultLocalState, i as useWorkflowDocumentsInSelectedFolder, l as defaultPHState, n as useWorkflowDocumentById, o as createWorkflowDocument, r as useWorkflowDocumentsInSelectedDrive, s as defaultGlobalState, t as useSelectedWorkflowDocument, u as WorkflowController } from "../../workflow-C003Wutu.js";
|
|
3
|
+
export { AddEdgeInputSchema, AddStepInputSchema, AddStepPositionInputSchema, AddStepPropertySettingInputSchema, AddStepRetryPolicyInputSchema, BackoffKindSchema, ClearTriggerInputSchema, ConcurrencyModeSchema, FailureModeSchema, PointSchema, PropertyModeSchema, PropertySettingSchema, PublishWorkflowInputSchema, PublishedWorkflowSchema, RemoveEdgeInputSchema, RemoveStepInputSchema, RemoveVariableInputSchema, RetryPolicySchema, RevertToPublishedInputSchema, RunStatusSchema, SetLastRunInputSchema, SetLastTestInputSchema, SetPolicyInputSchema, SetPolicyRetryPolicyInputSchema, SetStepConfigInputSchema, SetStepConfigPropertySettingInputSchema, SetTriggerConfigInputSchema, SetTriggerConfigPropertySettingInputSchema, SetTriggerConnectionInputSchema, SetTriggerInputSchema, SetTriggerPieceVersionInputSchema, SetTriggerPropertySettingInputSchema, SetVariableInputSchema, SetWorkflowDescriptionInputSchema, SetWorkflowNameInputSchema, SetWorkflowStatusInputSchema, StepTestRecordSchema, TriggerBindingSchema, UpdateStepInputSchema, UpdateStepPositionInputSchema, UpdateStepRetryPolicyInputSchema, VariableTypeSchema, Workflow, WorkflowController, WorkflowDocumentHeaderSchema, WorkflowDocumentSchema, WorkflowEdgeSchema, WorkflowPHStateSchema, WorkflowPolicySchema, WorkflowStateSchema, WorkflowStatusSchema, WorkflowStepSchema, WorkflowVariableSchema, actions, addEdge, addStep, assertIsWorkflowDocument, assertIsWorkflowState, clearTrigger, createState, createWorkflowDocument, defaultGlobalState, defaultLocalState, defaultPHState, definedNonNullAnySchema, documentModel, initialGlobalState, initialLocalState, isDefinedNonNullAny, isWorkflowDocument, isWorkflowState, latestVersion, publishWorkflow, reducer, removeEdge, removeStep, removeVariable, revertToPublished, setLastRun, setLastTest, setPolicy, setStepConfig, setTrigger, setTriggerConfig, setTriggerConnection, setTriggerPieceVersion, setVariable, setWorkflowDescription, setWorkflowName, setWorkflowStatus, supportedVersions, updateStep, useSelectedWorkflowDocument, useWorkflowDocumentById, useWorkflowDocumentsInSelectedDrive, useWorkflowDocumentsInSelectedFolder, utils, workflowDocumentType, creators_exports as workflowEdgesActions, creators_exports$1 as workflowPolicyActions, creators_exports$2 as workflowPublishingActions, creators_exports$3 as workflowRuntimeActions, creators_exports$4 as workflowStepsActions, creators_exports$5 as workflowTriggerActions, workflowUpgradeManifest, creators_exports$6 as workflowVariablesActions, creators_exports$7 as workflowWorkflowActions };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { t as
|
|
2
|
-
import { t as
|
|
1
|
+
import { t as Connection } from "./module-DIQ3tQ2M.js";
|
|
2
|
+
import { t as Workflow } from "./module-DxQBeqBh.js";
|
|
3
3
|
//#region powerhouse.manifest.json
|
|
4
4
|
var powerhouse_manifest_default = {
|
|
5
5
|
name: "@powerhousedao/workflow",
|
|
@@ -124,4 +124,4 @@ const documentModels = [Connection, Workflow];
|
|
|
124
124
|
//#endregion
|
|
125
125
|
export { powerhouse_manifest_default as n, documentModels as t };
|
|
126
126
|
|
|
127
|
-
//# sourceMappingURL=document-models-
|
|
127
|
+
//# sourceMappingURL=document-models-CncHyXAk.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"document-models-
|
|
1
|
+
{"version":3,"file":"document-models-CncHyXAk.js","names":["ConnectionV1","WorkflowV1"],"sources":["../../powerhouse.manifest.json","../../document-models/document-models.ts"],"sourcesContent":["","import { Connection as ConnectionV1 } from \"document-models/connection/v1\";\nimport { Workflow as WorkflowV1 } from \"document-models/workflow/v1\";\n\n/**\n * WARNING: DO NOT EDIT\n * This file is auto-generated and updated by codegen\n */\n\nexport const documentModels = [ConnectionV1, WorkflowV1] as const;\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;ACQA,MAAa,iBAAiB,CAACA,YAAcC,QAAU"}
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import { r as __toESM, t as __commonJSMin } from "./rolldown-runtime-DC62tzP2.js";
|
|
2
2
|
import { c as planFromAuth, o as packageFromConnectorId, r as connectorIdForPiece } from "./piece-auth-BS5CtQOG.js";
|
|
3
|
-
import {
|
|
4
|
-
import { y as
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import { t as useSelectedWorkflowDocument } from "./workflow-
|
|
9
|
-
import { a as useSignInGate, f as connectionCallbacks, g as newUndoGroup, h as groupedAction, i as useReactorAccessDenial, l as reactorConnections, m as UndoRedo, n as SignInPrompt, o as missingInPublished, p as BackButton, r as usePublisher, s as runsAsText, t as ConnectionForm } from "./connection-form-
|
|
10
|
-
import { a as StepError, c as PublishButton, d as ReactorDenialNote, f as StatusToggle, g as uniqueStepKey, h as hasDraftChanges, i as DataViewer, l as PublishState, m as VARIABLES_VIEW, n as describeSchedule, o as Modal, p as usePublish, r as describeTrigger, s as DraftBanner, t as describeCron, u as PublishedMissingNote } from "./trigger-text-
|
|
3
|
+
import { at as sameBlock, bt as scheduleConfigIssue, ct as triggerBlock, et as STEP_PRESETS, f as stepOutputTreeQuery, gt as flowPorts, h as blockRefKey, ht as expandDocumentRefs, i as outputTreeQuery, lt as triggerFields, mt as documentRefsIn, n as catalogQuery, ot as stepBlock, rt as isCoreBlock, st as stepFields, tt as TRIGGER_PRESETS, u as runsQuery, v as TEST_TRIGGER_KIND, vt as knownPorts, y as realRuns, yt as parseScheduleConfig } from "./runtime-queries-DehIdatq.js";
|
|
4
|
+
import { $ as useTestStepRunner, At as Switch, B as useBlockForms, Ct as Button, Dt as IconButton, E as formatDuration, Et as Hint, F as toneOf, Ft as textAreaClass, G as useDesignTime, H as useBlockResolutions, It as textInputClass, J as useDynamicPrefetch, K as useDynamicCache, L as DesignTimeProvider, Lt as Icon, Ot as Segmented, Pt as invalidClass, Q as useRunById, R as useBlockForm, Rt as isIconName, S as TONE_TEXT, T as formatAbsolute, Tt as FieldLabel, U as useCachedBlockForm, V as useBlockPorts, W as useConnectionList, X as useOptionSearch, Y as useLatestRun, Z as useResolvedProp, a as BlockResolutionsProvider, at as parsePropList, bt as useRuntime, c as runsDifferentVersion, ct as storedSchema, d as versionBadge, dt as withSetting, et as useTestTrigger, f as blockMeta, ft as workflowReadiness, g as usePieceLogos, h as useBlockMeta, i as PickerPopover, it as isPropVisible, jt as Tabs, k as formatWhen, kt as Select, l as updateVersion, lt as stripOptions, m as pieceLogo, n as BlockSelector, nt as blockMissing, o as VersionSummary, ot as resolverInputFor, p as pieceDisplayName, pt as WorkflowRuntimeProvider, q as useDynamicLookup, r as PICKER_SIZE, rt as isEmptyValue, s as resolutionText, st as settingFor, t as BlockLogo, tt as useWebhookEndpoint, u as useResolution, ut as undeclaredPortIssues, wt as FieldError, x as TONE_DOT, xt as useRuntimeActions, y as RUN_TONE, yt as useRunsQuery, z as useBlockFormLoader, zt as DocumentErrorBoundary } from "./BlockSelector-DnBab95a.js";
|
|
5
|
+
import { M as REACTOR_CONNECTOR_ID, y as actions } from "./module-DIQ3tQ2M.js";
|
|
6
|
+
import { t as useConnectionDocumentById } from "./connection-BXV8I017.js";
|
|
7
|
+
import { y as actions$1 } from "./module-DxQBeqBh.js";
|
|
8
|
+
import { t as useSelectedWorkflowDocument } from "./workflow-C003Wutu.js";
|
|
9
|
+
import { a as useSignInGate, f as connectionCallbacks, g as newUndoGroup, h as groupedAction, i as useReactorAccessDenial, l as reactorConnections, m as UndoRedo, n as SignInPrompt, o as missingInPublished, p as BackButton, r as usePublisher, s as runsAsText, t as ConnectionForm } from "./connection-form-Cy2fyFUR.js";
|
|
10
|
+
import { a as StepError, c as PublishButton, d as ReactorDenialNote, f as StatusToggle, g as uniqueStepKey, h as hasDraftChanges, i as DataViewer, l as PublishState, m as VARIABLES_VIEW, n as describeSchedule, o as Modal, p as usePublish, r as describeTrigger, s as DraftBanner, t as describeCron, u as PublishedMissingNote } from "./trigger-text-CfRbN-DV.js";
|
|
11
11
|
import * as m from "react";
|
|
12
12
|
import React, { Fragment, Suspense, createContext, forwardRef, lazy, memo, useCallback, useContext, useEffect, useId, useLayoutEffect, useMemo, useRef, useState, useSyncExternalStore } from "react";
|
|
13
13
|
import { Fragment as Fragment$1, jsx, jsxs } from "react/jsx-runtime";
|
|
@@ -24,9 +24,9 @@ const WORKFLOW_UNDO = {
|
|
|
24
24
|
replay: (action, undone) => {
|
|
25
25
|
if (action.type === "SET_LAST_TEST") {
|
|
26
26
|
const input = action.input;
|
|
27
|
-
return undone.some((edit) => placesBlock(edit, input.id)) ? void 0 : actions.setLastTest(input);
|
|
27
|
+
return undone.some((edit) => placesBlock(edit, input.id)) ? void 0 : actions$1.setLastTest(input);
|
|
28
28
|
}
|
|
29
|
-
if (action.type === "SET_LAST_RUN") return actions.setLastRun(action.input);
|
|
29
|
+
if (action.type === "SET_LAST_RUN") return actions$1.setLastRun(action.input);
|
|
30
30
|
}
|
|
31
31
|
};
|
|
32
32
|
//#endregion
|
|
@@ -180,15 +180,15 @@ function useWorkflowModel() {
|
|
|
180
180
|
model: useMemo(() => toModel(state), [state]),
|
|
181
181
|
callbacks: useMemo(() => ({
|
|
182
182
|
setName: (name) => {
|
|
183
|
-
dispatch(actions.setWorkflowName({ name }));
|
|
184
|
-
dispatch(actions.setName(name));
|
|
183
|
+
dispatch(actions$1.setWorkflowName({ name }));
|
|
184
|
+
dispatch(actions$1.setName(name));
|
|
185
185
|
},
|
|
186
|
-
setDescription: (description) => dispatch(actions.setWorkflowDescription({ description })),
|
|
187
|
-
setStatus: (status) => dispatch(actions.setWorkflowStatus({ status })),
|
|
186
|
+
setDescription: (description) => dispatch(actions$1.setWorkflowDescription({ description })),
|
|
187
|
+
setStatus: (status) => dispatch(actions$1.setWorkflowStatus({ status })),
|
|
188
188
|
setTrigger: (input) => {
|
|
189
189
|
const id = state.trigger?.id ?? generateId();
|
|
190
190
|
const group = newUndoGroup();
|
|
191
|
-
dispatch(groupedAction(actions.setTrigger({
|
|
191
|
+
dispatch(groupedAction(actions$1.setTrigger({
|
|
192
192
|
id,
|
|
193
193
|
pieceName: input.pieceName,
|
|
194
194
|
pieceVersion: input.pieceVersion,
|
|
@@ -204,11 +204,17 @@ function useWorkflowModel() {
|
|
|
204
204
|
block: triggerBlock(input)
|
|
205
205
|
};
|
|
206
206
|
},
|
|
207
|
-
|
|
207
|
+
setTriggerConfig: (config, extras) => dispatch(actions$1.setTriggerConfig({
|
|
208
|
+
config,
|
|
209
|
+
...extras?.propertySettings ? { propertySettings: settingsInput(extras.propertySettings) } : {}
|
|
210
|
+
})),
|
|
211
|
+
setTriggerConnection: (input) => dispatch(actions$1.setTriggerConnection(input)),
|
|
212
|
+
setTriggerPieceVersion: (pieceVersion) => dispatch(actions$1.setTriggerPieceVersion({ pieceVersion })),
|
|
213
|
+
clearTrigger: () => dispatch(actions$1.clearTrigger({})),
|
|
208
214
|
addStep: (input) => {
|
|
209
215
|
const id = generateId();
|
|
210
216
|
const group = newUndoGroup();
|
|
211
|
-
dispatch(groupedAction(actions.addStep({
|
|
217
|
+
dispatch(groupedAction(actions$1.addStep({
|
|
212
218
|
id,
|
|
213
219
|
key: input.key,
|
|
214
220
|
name: input.name,
|
|
@@ -224,44 +230,44 @@ function useWorkflowModel() {
|
|
|
224
230
|
block: stepBlock(input)
|
|
225
231
|
};
|
|
226
232
|
},
|
|
227
|
-
updateStep: (input) => dispatch(actions.updateStep(input)),
|
|
228
|
-
setStepConfig: (id, config, extras) => dispatch(actions.setStepConfig({
|
|
233
|
+
updateStep: (input) => dispatch(actions$1.updateStep(input)),
|
|
234
|
+
setStepConfig: (id, config, extras) => dispatch(actions$1.setStepConfig({
|
|
229
235
|
id,
|
|
230
236
|
config,
|
|
231
237
|
...extras?.propertySettings ? { propertySettings: settingsInput(extras.propertySettings) } : {}
|
|
232
238
|
})),
|
|
233
239
|
publish: () => new Promise((resolve, reject) => {
|
|
234
|
-
const publish = actions.publishWorkflow({ publishedAt: (/* @__PURE__ */ new Date()).toISOString() });
|
|
235
|
-
const batch = state.status === "ENABLED" ? [publish] : [publish, actions.setWorkflowStatus({ status: "ENABLED" })];
|
|
240
|
+
const publish = actions$1.publishWorkflow({ publishedAt: (/* @__PURE__ */ new Date()).toISOString() });
|
|
241
|
+
const batch = state.status === "ENABLED" ? [publish] : [publish, actions$1.setWorkflowStatus({ status: "ENABLED" })];
|
|
236
242
|
dispatch(batch, (errors) => reject(errors[0]), () => resolve());
|
|
237
243
|
}),
|
|
238
|
-
discardChanges: () => dispatch(actions.revertToPublished({})),
|
|
239
|
-
removeStep: (id) => dispatch(actions.removeStep({ id })),
|
|
240
|
-
addEdge: (input) => dispatch(actions.addEdge({
|
|
244
|
+
discardChanges: () => dispatch(actions$1.revertToPublished({})),
|
|
245
|
+
removeStep: (id) => dispatch(actions$1.removeStep({ id })),
|
|
246
|
+
addEdge: (input) => dispatch(actions$1.addEdge({
|
|
241
247
|
id: generateId(),
|
|
242
248
|
from: input.from,
|
|
243
249
|
to: input.to,
|
|
244
250
|
port: input.port,
|
|
245
251
|
condition: input.condition
|
|
246
252
|
})),
|
|
247
|
-
removeEdge: (id) => dispatch(actions.removeEdge({ id })),
|
|
253
|
+
removeEdge: (id) => dispatch(actions$1.removeEdge({ id })),
|
|
248
254
|
moveStep: (move) => {
|
|
249
|
-
for (const edge of state.edges.filter((entry) => entry.to === move.stepId)) dispatch(actions.removeEdge({ id: edge.id }));
|
|
250
|
-
dispatch(actions.addEdge({
|
|
255
|
+
for (const edge of state.edges.filter((entry) => entry.to === move.stepId)) dispatch(actions$1.removeEdge({ id: edge.id }));
|
|
256
|
+
dispatch(actions$1.addEdge({
|
|
251
257
|
id: generateId(),
|
|
252
258
|
from: move.toParentId,
|
|
253
259
|
to: move.stepId,
|
|
254
260
|
port: move.port
|
|
255
261
|
}));
|
|
256
262
|
},
|
|
257
|
-
setVariable: (input) => dispatch(actions.setVariable({
|
|
263
|
+
setVariable: (input) => dispatch(actions$1.setVariable({
|
|
258
264
|
id: input.id ?? generateId(),
|
|
259
265
|
key: input.key,
|
|
260
266
|
value: input.value,
|
|
261
267
|
description: input.description,
|
|
262
268
|
...input.type !== void 0 ? { type: input.type } : {}
|
|
263
269
|
})),
|
|
264
|
-
removeVariable: (id) => dispatch(actions.removeVariable({ id })),
|
|
270
|
+
removeVariable: (id) => dispatch(actions$1.removeVariable({ id })),
|
|
265
271
|
insertStepOnEdge: (edgeId, input, port) => {
|
|
266
272
|
const edge = state.edges.find((entry) => entry.id === edgeId);
|
|
267
273
|
if (!edge) return void 0;
|
|
@@ -269,7 +275,7 @@ function useWorkflowModel() {
|
|
|
269
275
|
const continuing = generateId();
|
|
270
276
|
const group = newUndoGroup();
|
|
271
277
|
dispatch([
|
|
272
|
-
actions.addStep({
|
|
278
|
+
actions$1.addStep({
|
|
273
279
|
id: stepId,
|
|
274
280
|
key: input.key,
|
|
275
281
|
name: input.name,
|
|
@@ -278,15 +284,15 @@ function useWorkflowModel() {
|
|
|
278
284
|
actionName: input.actionName,
|
|
279
285
|
config: input.config
|
|
280
286
|
}),
|
|
281
|
-
actions.removeEdge({ id: edgeId }),
|
|
282
|
-
actions.addEdge({
|
|
287
|
+
actions$1.removeEdge({ id: edgeId }),
|
|
288
|
+
actions$1.addEdge({
|
|
283
289
|
id: generateId(),
|
|
284
290
|
from: edge.from,
|
|
285
291
|
to: stepId,
|
|
286
292
|
port: edge.port,
|
|
287
293
|
condition: edge.condition
|
|
288
294
|
}),
|
|
289
|
-
actions.addEdge({
|
|
295
|
+
actions$1.addEdge({
|
|
290
296
|
id: continuing,
|
|
291
297
|
from: stepId,
|
|
292
298
|
to: edge.to,
|
|
@@ -306,7 +312,7 @@ function useWorkflowModel() {
|
|
|
306
312
|
duplicateStep: (id) => {
|
|
307
313
|
const step = state.steps.find((entry) => entry.id === id);
|
|
308
314
|
if (!step) return;
|
|
309
|
-
dispatch(actions.addStep({
|
|
315
|
+
dispatch(actions$1.addStep({
|
|
310
316
|
id: generateId(),
|
|
311
317
|
key: uniqueStepKey(state.steps.map((entry) => entry.key), step.key),
|
|
312
318
|
name: step.name,
|
|
@@ -326,7 +332,7 @@ function useWorkflowModel() {
|
|
|
326
332
|
appendStep: (fromId, port, input) => {
|
|
327
333
|
const stepId = generateId();
|
|
328
334
|
const group = newUndoGroup();
|
|
329
|
-
dispatch([actions.addStep({
|
|
335
|
+
dispatch([actions$1.addStep({
|
|
330
336
|
id: stepId,
|
|
331
337
|
key: input.key,
|
|
332
338
|
name: input.name,
|
|
@@ -334,7 +340,7 @@ function useWorkflowModel() {
|
|
|
334
340
|
pieceVersion: input.pieceVersion,
|
|
335
341
|
actionName: input.actionName,
|
|
336
342
|
config: input.config
|
|
337
|
-
}), actions.addEdge({
|
|
343
|
+
}), actions$1.addEdge({
|
|
338
344
|
id: generateId(),
|
|
339
345
|
from: fromId,
|
|
340
346
|
to: stepId,
|
|
@@ -358,18 +364,10 @@ function useWorkflowModel() {
|
|
|
358
364
|
const plan = planFollowUp(added, found, current.edges, form);
|
|
359
365
|
if (!plan) return;
|
|
360
366
|
const trigger = current.trigger;
|
|
361
|
-
const followUps = [...plan.config && trigger?.id === added.id ? [actions.
|
|
362
|
-
id: trigger.id,
|
|
363
|
-
pieceName: trigger.pieceName,
|
|
364
|
-
pieceVersion: trigger.pieceVersion,
|
|
365
|
-
triggerName: trigger.triggerName,
|
|
366
|
-
config: plan.config,
|
|
367
|
-
connectionId: trigger.connectionId,
|
|
368
|
-
reactorConnectionId: trigger.reactorConnectionId
|
|
369
|
-
})] : plan.config ? [actions.setStepConfig({
|
|
367
|
+
const followUps = [...plan.config && trigger?.id === added.id ? [actions$1.setTriggerConfig({ config: plan.config })] : plan.config ? [actions$1.setStepConfig({
|
|
370
368
|
id: added.id,
|
|
371
369
|
config: plan.config
|
|
372
|
-
})] : [], ...plan.repoint ? [actions.removeEdge({ id: plan.repoint.edge.id }), actions.addEdge({
|
|
370
|
+
})] : [], ...plan.repoint ? [actions$1.removeEdge({ id: plan.repoint.edge.id }), actions$1.addEdge({
|
|
373
371
|
id: generateId(),
|
|
374
372
|
from: plan.repoint.edge.from,
|
|
375
373
|
to: plan.repoint.edge.to,
|
|
@@ -1468,12 +1466,12 @@ function CreateConnectionModal(props) {
|
|
|
1468
1466
|
if (!dispatch || prefilled || state === void 0) return;
|
|
1469
1467
|
if (state.connectorId) return;
|
|
1470
1468
|
setPrefilled(true);
|
|
1471
|
-
dispatch(actions
|
|
1472
|
-
dispatch(actions
|
|
1469
|
+
dispatch(actions.setConnectionName({ name: props.draft.name }));
|
|
1470
|
+
dispatch(actions.setName(props.draft.name));
|
|
1473
1471
|
const setConnector = (auth) => {
|
|
1474
1472
|
const { authType } = planFromAuth(auth);
|
|
1475
1473
|
if (authType === "UNKNOWN") return;
|
|
1476
|
-
dispatch(actions
|
|
1474
|
+
dispatch(actions.setConnector({
|
|
1477
1475
|
connectorId: props.draft.connectorId,
|
|
1478
1476
|
authType
|
|
1479
1477
|
}));
|
|
@@ -1483,8 +1481,8 @@ function CreateConnectionModal(props) {
|
|
|
1483
1481
|
setConnector(piece?.auth);
|
|
1484
1482
|
const name = connectionNameFor(props.draft.piecePackage, piece?.displayName);
|
|
1485
1483
|
if (name !== props.draft.name) {
|
|
1486
|
-
dispatch(actions
|
|
1487
|
-
dispatch(actions
|
|
1484
|
+
dispatch(actions.setConnectionName({ name }));
|
|
1485
|
+
dispatch(actions.setName(name));
|
|
1488
1486
|
}
|
|
1489
1487
|
}, () => setConnector(null));
|
|
1490
1488
|
}, [
|
|
@@ -1798,17 +1796,17 @@ function ConnectionField(props) {
|
|
|
1798
1796
|
//#region editors/workflow-editor/ui/reactor-connection-create.ts
|
|
1799
1797
|
function newReactorConnectionActions(name, requireReactor) {
|
|
1800
1798
|
return [
|
|
1801
|
-
actions
|
|
1802
|
-
actions
|
|
1803
|
-
actions
|
|
1799
|
+
actions.setConnectionName({ name }),
|
|
1800
|
+
actions.setName(name),
|
|
1801
|
+
actions.setConnector({
|
|
1804
1802
|
connectorId: REACTOR_CONNECTOR_ID,
|
|
1805
1803
|
authType: "REACTOR"
|
|
1806
1804
|
}),
|
|
1807
|
-
actions
|
|
1805
|
+
actions.setConfig({ config: requireReactor === "read" ? {
|
|
1808
1806
|
endpoint: "local",
|
|
1809
1807
|
access: "read"
|
|
1810
1808
|
} : { endpoint: "local" } }),
|
|
1811
|
-
actions
|
|
1809
|
+
actions.recordCheckResult({
|
|
1812
1810
|
status: "OK",
|
|
1813
1811
|
checkedAt: (/* @__PURE__ */ new Date()).toISOString()
|
|
1814
1812
|
})
|
|
@@ -1931,6 +1929,36 @@ function ReactorConnectionField(props) {
|
|
|
1931
1929
|
});
|
|
1932
1930
|
}
|
|
1933
1931
|
//#endregion
|
|
1932
|
+
//#region editors/shared/pending-echo.ts
|
|
1933
|
+
function keyOf(value) {
|
|
1934
|
+
return JSON.stringify(value, (_, entry) => entry && typeof entry === "object" && !Array.isArray(entry) ? Object.fromEntries(Object.entries(entry).sort(([a], [b]) => a.localeCompare(b))) : entry);
|
|
1935
|
+
}
|
|
1936
|
+
function usePendingEcho(saved, onChange) {
|
|
1937
|
+
const savedKey = keyOf(saved);
|
|
1938
|
+
const [sent, setSent] = useState([]);
|
|
1939
|
+
const [seen, setSeen] = useState(savedKey);
|
|
1940
|
+
let pending = sent;
|
|
1941
|
+
if (seen !== savedKey) {
|
|
1942
|
+
const echo = sent.findIndex((value) => keyOf(value) === savedKey);
|
|
1943
|
+
pending = echo === -1 ? [] : sent.slice(echo + 1);
|
|
1944
|
+
setSeen(savedKey);
|
|
1945
|
+
setSent(pending);
|
|
1946
|
+
}
|
|
1947
|
+
const value = pending.length > 0 ? pending[pending.length - 1] : saved;
|
|
1948
|
+
return {
|
|
1949
|
+
value,
|
|
1950
|
+
commit: (next) => {
|
|
1951
|
+
if (keyOf(next) === keyOf(value)) return;
|
|
1952
|
+
setSent([...pending, next]);
|
|
1953
|
+
onChange(next, value);
|
|
1954
|
+
},
|
|
1955
|
+
onBlur: (event) => {
|
|
1956
|
+
const inside = event.currentTarget.contains(event.relatedTarget);
|
|
1957
|
+
if (pending.length > 0 && !inside && keyOf(value) === savedKey) setSent([]);
|
|
1958
|
+
}
|
|
1959
|
+
};
|
|
1960
|
+
}
|
|
1961
|
+
//#endregion
|
|
1934
1962
|
//#region editors/workflow-editor/ui/secret-ref.ts
|
|
1935
1963
|
const SECRET_REF_PREFIX = "secret://v1:";
|
|
1936
1964
|
function useSecretRef(options) {
|
|
@@ -2650,23 +2678,28 @@ function ArrayRows(props) {
|
|
|
2650
2678
|
})]
|
|
2651
2679
|
});
|
|
2652
2680
|
}
|
|
2653
|
-
function
|
|
2654
|
-
|
|
2681
|
+
function rowsOf(value) {
|
|
2682
|
+
return Object.entries(value).map(([key, entry]) => ({
|
|
2655
2683
|
key,
|
|
2656
|
-
value: stringifyValue$1(
|
|
2657
|
-
}))
|
|
2658
|
-
|
|
2659
|
-
|
|
2660
|
-
|
|
2661
|
-
|
|
2662
|
-
|
|
2663
|
-
|
|
2664
|
-
|
|
2684
|
+
value: stringifyValue$1(entry)
|
|
2685
|
+
}));
|
|
2686
|
+
}
|
|
2687
|
+
function recordOf(rows) {
|
|
2688
|
+
const record = {};
|
|
2689
|
+
for (const row of rows) if (row.key.trim() !== "") record[row.key.trim()] = row.value;
|
|
2690
|
+
return record;
|
|
2691
|
+
}
|
|
2692
|
+
function ObjectRows(props) {
|
|
2693
|
+
const [rows, setRows] = useState(() => rowsOf(props.value));
|
|
2694
|
+
const valueKey = keyOf(props.value);
|
|
2695
|
+
const [seen, setSeen] = useState(valueKey);
|
|
2696
|
+
if (seen !== valueKey) {
|
|
2697
|
+
setSeen(valueKey);
|
|
2698
|
+
if (keyOf(recordOf(rows)) !== valueKey) setRows(rowsOf(props.value));
|
|
2665
2699
|
}
|
|
2666
2700
|
const commit = (next) => {
|
|
2667
2701
|
setRows(next);
|
|
2668
|
-
const record =
|
|
2669
|
-
for (const row of next) if (row.key.trim() !== "") record[row.key.trim()] = row.value;
|
|
2702
|
+
const record = recordOf(next);
|
|
2670
2703
|
props.onCommit(Object.keys(record).length > 0 ? record : void 0);
|
|
2671
2704
|
};
|
|
2672
2705
|
return /* @__PURE__ */ jsxs("div", {
|
|
@@ -3457,18 +3490,14 @@ const NO_BLOCK = {
|
|
|
3457
3490
|
name: ""
|
|
3458
3491
|
};
|
|
3459
3492
|
function PropertyForm(props) {
|
|
3460
|
-
const
|
|
3461
|
-
|
|
3462
|
-
|
|
3463
|
-
|
|
3464
|
-
|
|
3465
|
-
|
|
3466
|
-
|
|
3467
|
-
const
|
|
3468
|
-
if (props.settings !== prevSettings) {
|
|
3469
|
-
setPrevSettings(props.settings);
|
|
3470
|
-
setSettings(props.settings ?? null);
|
|
3471
|
-
}
|
|
3493
|
+
const echo = usePendingEcho({
|
|
3494
|
+
value: props.value,
|
|
3495
|
+
settings: props.settings ?? null
|
|
3496
|
+
}, (next, shown) => {
|
|
3497
|
+
if (next.settings !== shown.settings) props.onChange(next.value, next.settings ?? []);
|
|
3498
|
+
else props.onChange(next.value);
|
|
3499
|
+
});
|
|
3500
|
+
const { value: current, settings } = echo.value;
|
|
3472
3501
|
const tracksSettings = props.writesSettings === true;
|
|
3473
3502
|
const readDynamic = useDynamicCache();
|
|
3474
3503
|
const withResolvedSchemas = (list, config) => {
|
|
@@ -3498,17 +3527,17 @@ function PropertyForm(props) {
|
|
|
3498
3527
|
if (tracksSettings && dependent.type === "DYNAMIC" && settingFor(nextSettings, dependent.name)?.schema != null) nextSettings = withSetting(nextSettings, dependent.name, { schema: null });
|
|
3499
3528
|
}
|
|
3500
3529
|
if (tracksSettings) nextSettings = withResolvedSchemas(nextSettings, next);
|
|
3501
|
-
|
|
3502
|
-
|
|
3503
|
-
|
|
3504
|
-
|
|
3505
|
-
} else props.onChange(next);
|
|
3530
|
+
echo.commit({
|
|
3531
|
+
value: next,
|
|
3532
|
+
settings: nextSettings
|
|
3533
|
+
});
|
|
3506
3534
|
};
|
|
3507
3535
|
const setMode = (name, mode) => {
|
|
3508
3536
|
if (!tracksSettings || settingFor(settings, name)?.mode === mode) return;
|
|
3509
|
-
|
|
3510
|
-
|
|
3511
|
-
|
|
3537
|
+
echo.commit({
|
|
3538
|
+
value: current,
|
|
3539
|
+
settings: withResolvedSchemas(withSetting(settings, name, { mode }), current)
|
|
3540
|
+
});
|
|
3512
3541
|
};
|
|
3513
3542
|
const visible = props.props.filter((prop) => isPropVisible(prop, current));
|
|
3514
3543
|
const essential = visible.filter((prop) => !prop.advanced);
|
|
@@ -3534,6 +3563,7 @@ function PropertyForm(props) {
|
|
|
3534
3563
|
}, prop.name);
|
|
3535
3564
|
return /* @__PURE__ */ jsxs("div", {
|
|
3536
3565
|
className: `flex flex-col ${props.nested ? "gap-4" : "gap-5"}`,
|
|
3566
|
+
onBlur: echo.onBlur,
|
|
3537
3567
|
children: [/* @__PURE__ */ jsx(PropLayout, {
|
|
3538
3568
|
props: essential,
|
|
3539
3569
|
groups: props.groups,
|
|
@@ -3804,10 +3834,9 @@ function isEvery(text) {
|
|
|
3804
3834
|
function EveryInput(props) {
|
|
3805
3835
|
const [text, setText] = useState(String(props.every));
|
|
3806
3836
|
const [seen, setSeen] = useState(props.every);
|
|
3807
|
-
const [typing, setTyping] = useState(false);
|
|
3808
3837
|
if (seen !== props.every) {
|
|
3809
3838
|
setSeen(props.every);
|
|
3810
|
-
if (
|
|
3839
|
+
if (Number(text) !== props.every) setText(String(props.every));
|
|
3811
3840
|
}
|
|
3812
3841
|
return /* @__PURE__ */ jsx("input", {
|
|
3813
3842
|
id: props.id,
|
|
@@ -3817,12 +3846,12 @@ function EveryInput(props) {
|
|
|
3817
3846
|
className: `${textInputClass} w-24 tabular-nums`,
|
|
3818
3847
|
value: text,
|
|
3819
3848
|
onChange: (event) => {
|
|
3820
|
-
setTyping(true);
|
|
3821
3849
|
setText(event.target.value);
|
|
3822
|
-
if (isEvery(event.target.value))
|
|
3850
|
+
if (!isEvery(event.target.value)) return;
|
|
3851
|
+
const every = Number(event.target.value);
|
|
3852
|
+
if (every !== props.every) props.onCommit(every);
|
|
3823
3853
|
},
|
|
3824
3854
|
onBlur: () => {
|
|
3825
|
-
setTyping(false);
|
|
3826
3855
|
if (!isEvery(text)) setText(String(props.every));
|
|
3827
3856
|
}
|
|
3828
3857
|
});
|
|
@@ -3830,14 +3859,17 @@ function EveryInput(props) {
|
|
|
3830
3859
|
function ScheduleBuilder(props) {
|
|
3831
3860
|
const everyId = useId();
|
|
3832
3861
|
const cronId = useId();
|
|
3833
|
-
const
|
|
3834
|
-
const
|
|
3862
|
+
const echo = usePendingEcho(props.config, props.onChange);
|
|
3863
|
+
const config = echo.value;
|
|
3864
|
+
const parsed = draftFromConfig(config);
|
|
3865
|
+
const timezone = timezoneOf(config);
|
|
3835
3866
|
const [customPinned, setCustomPinned] = useState(parsed.kind === "custom");
|
|
3836
3867
|
const draft = customPinned && parsed.kind !== "custom" ? switchKind(parsed, "custom") : parsed;
|
|
3837
|
-
const commit = (next, zone = timezone) =>
|
|
3838
|
-
const issue = scheduleConfigIssue(
|
|
3868
|
+
const commit = (next, zone = timezone) => echo.commit(configFromDraft(next, zone));
|
|
3869
|
+
const issue = scheduleConfigIssue(config);
|
|
3839
3870
|
return /* @__PURE__ */ jsxs("div", {
|
|
3840
3871
|
className: "flex flex-col gap-5",
|
|
3872
|
+
onBlur: echo.onBlur,
|
|
3841
3873
|
children: [
|
|
3842
3874
|
/* @__PURE__ */ jsxs("div", { children: [/* @__PURE__ */ jsx(FieldLabel, { label: "Repeats" }), /* @__PURE__ */ jsx(Segmented, {
|
|
3843
3875
|
value: draft.kind,
|
|
@@ -3952,7 +3984,7 @@ function ScheduleBuilder(props) {
|
|
|
3952
3984
|
" ",
|
|
3953
3985
|
/* @__PURE__ */ jsx("span", {
|
|
3954
3986
|
className: "font-medium text-foreground",
|
|
3955
|
-
children: describeSchedule(
|
|
3987
|
+
children: describeSchedule(config).replace(/^\w/, (c) => c.toLowerCase())
|
|
3956
3988
|
})
|
|
3957
3989
|
]
|
|
3958
3990
|
})
|
|
@@ -5351,18 +5383,7 @@ function TriggerPanel(props) {
|
|
|
5351
5383
|
const writes = !props.readOnly;
|
|
5352
5384
|
const isWebhookTrigger = form !== "loading" && form?.triggerDelivery === "webhook";
|
|
5353
5385
|
const endpoint = useWebhookEndpoint(isWebhookTrigger);
|
|
5354
|
-
const
|
|
5355
|
-
const config = patch.config === void 0 ? trigger.config : patch.config;
|
|
5356
|
-
const connectionId = patch.connectionId === void 0 ? trigger.connectionId : patch.connectionId;
|
|
5357
|
-
const reactorConnectionId = patch.reactorConnectionId === void 0 ? trigger.reactorConnectionId : patch.reactorConnectionId;
|
|
5358
|
-
callbacks.setTrigger({
|
|
5359
|
-
...triggerFields(block),
|
|
5360
|
-
config,
|
|
5361
|
-
connectionId,
|
|
5362
|
-
reactorConnectionId,
|
|
5363
|
-
...writes ? { propertySettings: patch.settings } : {}
|
|
5364
|
-
});
|
|
5365
|
-
};
|
|
5386
|
+
const setTriggerConfig = (config, settings) => callbacks.setTriggerConfig(config, writes ? { propertySettings: settings } : void 0);
|
|
5366
5387
|
return /* @__PURE__ */ jsxs("div", {
|
|
5367
5388
|
className: "flex min-h-full flex-col",
|
|
5368
5389
|
children: [/* @__PURE__ */ jsx(PanelHeader, {
|
|
@@ -5379,28 +5400,25 @@ function TriggerPanel(props) {
|
|
|
5379
5400
|
isPieceTrigger ? /* @__PURE__ */ jsx(ConnectionField, {
|
|
5380
5401
|
block,
|
|
5381
5402
|
value: trigger.connectionId ?? "",
|
|
5382
|
-
onChange: (connectionId) =>
|
|
5403
|
+
onChange: (connectionId) => callbacks.setTriggerConnection({ connectionId })
|
|
5383
5404
|
}, `${trigger.id}-conn`) : null,
|
|
5384
5405
|
isPieceTrigger ? /* @__PURE__ */ jsx(ReactorConnectionField, {
|
|
5385
5406
|
block,
|
|
5386
5407
|
value: trigger.reactorConnectionId ?? "",
|
|
5387
5408
|
workflowId: designTime?.workflowId,
|
|
5388
5409
|
publishedVersion: props.publishedVersion,
|
|
5389
|
-
onChange: (reactorConnectionId) =>
|
|
5410
|
+
onChange: (reactorConnectionId) => callbacks.setTriggerConnection({ reactorConnectionId })
|
|
5390
5411
|
}, `${trigger.id}-reactor`) : null,
|
|
5391
5412
|
form !== "loading" && form?.display === "schedule" ? /* @__PURE__ */ jsx(ScheduleBuilder, {
|
|
5392
5413
|
config: trigger.config,
|
|
5393
|
-
onChange: (config) =>
|
|
5414
|
+
onChange: (config) => setTriggerConfig(config)
|
|
5394
5415
|
}, trigger.id) : /* @__PURE__ */ jsx(ConfigSection, {
|
|
5395
5416
|
block,
|
|
5396
5417
|
form,
|
|
5397
5418
|
formError,
|
|
5398
5419
|
config: trigger.config,
|
|
5399
5420
|
settings: trigger.propertySettings,
|
|
5400
|
-
onChange: (config, settings) =>
|
|
5401
|
-
config,
|
|
5402
|
-
settings
|
|
5403
|
-
}),
|
|
5421
|
+
onChange: (config, settings) => setTriggerConfig(config, settings),
|
|
5404
5422
|
writesSettings: writes,
|
|
5405
5423
|
connectionId: trigger.connectionId ?? void 0,
|
|
5406
5424
|
reactorConnectionId: trigger.reactorConnectionId ?? void 0,
|
|
@@ -5411,14 +5429,7 @@ function TriggerPanel(props) {
|
|
|
5411
5429
|
id: trigger.id,
|
|
5412
5430
|
block,
|
|
5413
5431
|
kind: "trigger",
|
|
5414
|
-
onUpdate: writes ? (pieceVersion) => callbacks.
|
|
5415
|
-
...triggerFields(block),
|
|
5416
|
-
pieceVersion,
|
|
5417
|
-
config: trigger.config,
|
|
5418
|
-
connectionId: trigger.connectionId,
|
|
5419
|
-
reactorConnectionId: trigger.reactorConnectionId,
|
|
5420
|
-
propertySettings: trigger.propertySettings ?? void 0
|
|
5421
|
-
}) : void 0
|
|
5432
|
+
onUpdate: writes ? (pieceVersion) => callbacks.setTriggerPieceVersion(pieceVersion) : void 0
|
|
5422
5433
|
}),
|
|
5423
5434
|
isPieceTrigger && testTrigger ? /* @__PURE__ */ jsx(Section, {
|
|
5424
5435
|
title: "Try it",
|
|
@@ -17595,4 +17606,4 @@ function Editor() {
|
|
|
17595
17606
|
//#endregion
|
|
17596
17607
|
export { Editor as default };
|
|
17597
17608
|
|
|
17598
|
-
//# sourceMappingURL=editor-
|
|
17609
|
+
//# sourceMappingURL=editor-CEJO-2Ue.js.map
|