@oomol-lab/open-flow 0.1.0-beta.69 → 0.1.0-beta.70
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/{ContentIcon-CsECY5id.js → ContentIcon-CUQHjQIw.js} +16 -8
- package/dist/browser/{FlowCanvas-C5X22xQ7.js → FlowCanvas-CqtUDPGj.js} +11 -26
- package/dist/browser/{createResourceDialog-Di5BBrQv.js → createResourceDialog-BAHYW9yu.js} +3 -3
- package/dist/browser/{dialog-Bjo-r9B0.js → dialog-DcGOzUP2.js} +162 -12
- package/dist/browser/{exportSvg-Cj6Spxx-.js → exportSvg-Dv5Qgrq7.js} +2 -2
- package/dist/browser/flow-authoring.js +95 -12
- package/dist/browser/flow-change-schema.d.ts +24 -1
- package/dist/browser/flow-change.d.ts +33 -4
- package/dist/browser/flow-change.js +96 -13
- package/dist/browser/{flowChanges-Dp-rcEJ6.js → flowChanges-CYyehKer.js} +2593 -2254
- package/dist/browser/{flowWorkspace-CB1QACku.js → flowWorkspace-qYUZPJHR.js} +1114 -392
- package/dist/browser/preview.css +225 -221
- package/dist/browser/preview.js +3781 -2655
- package/dist/browser/{tooltip-CJjYs_2I.js → tooltip-wZJRB9oP.js} +28 -1
- package/dist/browser/ui.css +8 -20
- package/dist/browser/workbench.css +225 -221
- package/dist/browser/workbench.js +31 -10
- package/dist/browser/{workbenchSelect-C3hxUcYm.js → workbenchSelect-D8_vP2p5.js} +2 -2
- package/dist/command/index.js +45 -45
- package/dist/common/authoring.d.ts +3 -3
- package/dist/common/authoringExamples.d.ts +3 -2
- package/dist/common/authoringSchema.d.ts +37 -374
- package/dist/common/control-api-conformance.js +151 -55
- package/dist/common/control-api.d.ts +12 -78
- package/dist/common/control-api.js +162 -39
- package/dist/common/control-requests.d.ts +3 -3
- package/dist/common/control-requests.js +221 -35
- package/dist/common/decision.js +85 -7
- package/dist/common/engine-contract.d.ts +4 -2
- package/dist/common/flow-encoding.js +110 -14
- package/dist/common/flow-graph.d.ts +3 -0
- package/dist/common/flow-semantics.js +273 -14
- package/dist/common/integration-trigger.js +85 -7
- package/dist/common/liveDetails.d.ts +15 -0
- package/dist/common/mcp.d.ts +3 -3
- package/dist/common/mcp.js +134 -38
- package/dist/common/openapi.js +85 -7
- package/dist/common/poll-trigger.js +85 -7
- package/dist/common/run-events.d.ts +2 -0
- package/dist/common/run-events.js +59 -2
- package/dist/common/runtime-contract.js +14 -4
- package/dist/common/scheduler.d.ts +6 -2
- package/dist/common/scheduler.js +178 -11
- package/dist/common/webhook-response.d.ts +43 -0
- package/dist/common/webhook-trigger.d.ts +12 -0
- package/dist/common/webhook-trigger.js +236 -9
- package/dist/common/workflow.js +85 -7
- package/package.json +1 -1
- package/skills/open-flow/references/flow-authoring.md +15 -10
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { a as derive, l as val, r as combine } from "./dist-bO8nvHFH.js";
|
|
2
|
-
import { $ as
|
|
2
|
+
import { $ as useAnchoredPopupScrollLock, An as ownerDocument, At as useTriggerDataForwarding, Bn as useValueChanged, Bt as useFloatingTree, Cr as useRenderElement, Ct as useSyncedFloatingRootContext, Dr as warn, Dt as PopupTriggerMap, Er as NOOP, Et as popupStoreSelectors, Fn as useAnimationsFinished, Fr as SafeReact, Ft as FloatingFocusManager, Gn as closePress, Gt as POPUP_COLLISION_AVOIDANCE, Hr as isLastTraversableNode, Ht as FloatingPortal, I as useCompositeListItem, Ir as useStableCallback, It as FloatingNode, Jn as imperativeAction, Jt as ReactStore, Kt as FocusGuard, Ln as transitionStatusMapping, Lr as useRefWithInit, Lt as FloatingTree, Mn as createLucideIcon, Mr as formatErrorMessage, Nn as useTransitionStatus, Nr as mergeProps, Nt as useDismiss, On as isMac, Or as useMergedRefs, Ot as useImplicitActiveTrigger, P as Separator, Pn as useOpenChangeComplete, Pr as useIsoLayoutEffect, Pt as useClick, Q as useToolbarRootContext, Qn as itemPress, Qt as fastComponentRef, Rr as getParentNode, Rt as useFloatingNodeId, Sr as clsx, St as useFocus, Tr as EMPTY_OBJECT, Tt as createInitialPopupStoreState, U as COMPOSITE_KEYS, Un as cancelOpen, Ut as CLICK_TRIGGER_IDENTIFIER, Vn as createChangeEventDetails, Vr as isHTMLElement$1, Vt as FloatingTreeStore, Wt as DROPDOWN_COLLISION_AVOIDANCE, Zt as fastComponent, _r as useControlled, _t as useRole, an as useTimeout, at as adaptiveOrigin, br as cn, bt as useHoverReferenceInteraction, cn as getTabbableBeforeElement, cr as useFormContext, ct as inertValue, dr as useBaseUiId, dt as popupStateMapping, er as none, fr as useId$1, ft as pressableTriggerOpenStateMapping, gr as visuallyHiddenInput, gt as useTypeahead, hr as visuallyHidden, ht as safePolygon, in as Timeout, ir as triggerHover, it as useAnchorPositioning, jn as Check, jr as useCompositeRootContext, jt as useTriggerRegistration, kr as useButton, kt as useOpenStateTransitions, ln as isOutsideEvent, lr as useRegisterFieldControl, lt as getPseudoElementBounds, mr as fieldValidityMapping, mt as useOpenInteractionType, nr as siblingOpen, nt as getDisabledMountTransitionStyles, on as getNextTabbable, ot as useDirection, pt as triggerOpenStateMapping, qn as focusOut, rn as useOnFirstRender, rt as InternalBackdrop, sn as getTabbableAfterElement, sr as useLabelableContext, st as CompositeList, tn as createSelector, tt as usePositioner, ur as useFieldRootContext, vr as Button, vt as useListNavigation, wn as contains, wr as EMPTY_ARRAY, xt as useHoverFloatingInteraction, yt as useInteractions, zn as useOnMount, zt as useFloatingParentNodeId } from "./tooltip-wZJRB9oP.js";
|
|
3
3
|
import * as React from "react";
|
|
4
4
|
import reactExports, { createContext, forwardRef, memo, useCallback, useContext, useEffect, useImperativeHandle, useLayoutEffect, useMemo, useReducer, useRef, useState, useSyncExternalStore } from "react";
|
|
5
5
|
import { Fragment as Fragment$1, jsx, jsxs } from "react/jsx-runtime";
|
|
@@ -1174,7 +1174,8 @@ var en_default$1 = {
|
|
|
1174
1174
|
"value": "Fixed Values",
|
|
1175
1175
|
"input": "Flow input",
|
|
1176
1176
|
"output": "Flow output",
|
|
1177
|
-
"outputs": "Workflow Outputs"
|
|
1177
|
+
"outputs": "Workflow Outputs",
|
|
1178
|
+
"webhook-response": "Webhook Response"
|
|
1178
1179
|
},
|
|
1179
1180
|
"units": {
|
|
1180
1181
|
"minute": "minutes",
|
|
@@ -1816,7 +1817,8 @@ var fr_default$1 = {
|
|
|
1816
1817
|
"value": "Valeurs fixes",
|
|
1817
1818
|
"input": "Entrée",
|
|
1818
1819
|
"output": "Sortie",
|
|
1819
|
-
"outputs": "Sorties du workflow"
|
|
1820
|
+
"outputs": "Sorties du workflow",
|
|
1821
|
+
"webhook-response": "Réponse Webhook"
|
|
1820
1822
|
},
|
|
1821
1823
|
"units": {
|
|
1822
1824
|
"minute": "minutes",
|
|
@@ -2458,7 +2460,8 @@ var ja_default$1 = {
|
|
|
2458
2460
|
"value": "固定値",
|
|
2459
2461
|
"input": "入力",
|
|
2460
2462
|
"output": "出力",
|
|
2461
|
-
"outputs": "ワークフロー出力"
|
|
2463
|
+
"outputs": "ワークフロー出力",
|
|
2464
|
+
"webhook-response": "Webhook レスポンス"
|
|
2462
2465
|
},
|
|
2463
2466
|
"units": {
|
|
2464
2467
|
"minute": "分",
|
|
@@ -3100,7 +3103,8 @@ var ko_default$1 = {
|
|
|
3100
3103
|
"value": "고정 값",
|
|
3101
3104
|
"input": "입력",
|
|
3102
3105
|
"output": "출력",
|
|
3103
|
-
"outputs": "워크플로 출력"
|
|
3106
|
+
"outputs": "워크플로 출력",
|
|
3107
|
+
"webhook-response": "Webhook 응답"
|
|
3104
3108
|
},
|
|
3105
3109
|
"units": {
|
|
3106
3110
|
"minute": "분",
|
|
@@ -3742,7 +3746,8 @@ var ru_default$1 = {
|
|
|
3742
3746
|
"value": "Фиксированные значения",
|
|
3743
3747
|
"input": "Вход",
|
|
3744
3748
|
"output": "Выход",
|
|
3745
|
-
"outputs": "Выходы рабочего процесса"
|
|
3749
|
+
"outputs": "Выходы рабочего процесса",
|
|
3750
|
+
"webhook-response": "Ответ Webhook"
|
|
3746
3751
|
},
|
|
3747
3752
|
"units": {
|
|
3748
3753
|
"minute": "мин.",
|
|
@@ -4384,7 +4389,8 @@ var zh_CN_default$1 = {
|
|
|
4384
4389
|
"value": "固定值",
|
|
4385
4390
|
"input": "流程输入",
|
|
4386
4391
|
"output": "流程输出",
|
|
4387
|
-
"outputs": "工作流输出"
|
|
4392
|
+
"outputs": "工作流输出",
|
|
4393
|
+
"webhook-response": "Webhook 响应"
|
|
4388
4394
|
},
|
|
4389
4395
|
"units": {
|
|
4390
4396
|
"minute": "分钟",
|
|
@@ -5026,7 +5032,8 @@ var zh_TW_default$1 = {
|
|
|
5026
5032
|
"value": "固定值",
|
|
5027
5033
|
"input": "流程輸入",
|
|
5028
5034
|
"output": "流程輸出",
|
|
5029
|
-
"outputs": "工作流程輸出"
|
|
5035
|
+
"outputs": "工作流程輸出",
|
|
5036
|
+
"webhook-response": "Webhook 回應"
|
|
5030
5037
|
},
|
|
5031
5038
|
"units": {
|
|
5032
5039
|
"minute": "分鐘",
|
|
@@ -11469,6 +11476,7 @@ var extra_icon_default = {
|
|
|
11469
11476
|
"icons": {
|
|
11470
11477
|
"siren": { "body": "<path fill=\"none\" stroke=\"currentColor\" stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"1.5\" d=\"M7 18v-6a5 5 0 1 1 10 0v6M5 21a1 1 0 0 0 1 1h12a1 1 0 0 0 1-1v-1a2 2 0 0 0-2-2H7a2 2 0 0 0-2 2zm16-9h1m-3.5-7.5L18 5M2 12h1m9-10v1M4.929 4.929l.707.707M12 12v6\"/>" },
|
|
11471
11478
|
"log-out": { "body": "<path fill=\"none\" stroke=\"currentColor\" stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"1.5\" d=\"m16 17l5-5l-5-5m5 5H9m0 9H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h4\"/>" },
|
|
11479
|
+
"reply": { "body": "<g fill=\"none\" stroke=\"currentColor\" stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"1.5\"><path d=\"M20 18v-2a4 4 0 0 0-4-4H4\"/><path d=\"m9 17l-5-5l5-5\"/></g>" },
|
|
11472
11480
|
"workflow": {
|
|
11473
11481
|
"body": "<g fill=\"none\" stroke=\"currentColor\" stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"1.5\"><rect width=\"8\" height=\"8\" x=\"3\" y=\"3\" rx=\"2\"/><path d=\"M7 11v4a2 2 0 0 0 2 2h4\"/><rect width=\"8\" height=\"8\" x=\"13\" y=\"13\" rx=\"2\"/></g>",
|
|
11474
11482
|
"width": 24,
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { o as __toESM, t as __commonJSMin } from "./rolldown-runtime-CEgmsyvS.js";
|
|
2
|
-
import { $ as ko_default, B as MenuPopup, C as DropdownMenuContent, D as DropdownMenuRadioGroup, E as DropdownMenuLabel, F as findRootOwnerId, G as MenuRootContext, H as MenuGroup, J as waitBranchDescription, K as useMenuRootContext, L as MenuRoot, N as DropdownMenuTrigger, O as DropdownMenuRadioItem, Q as ru_default, R as MenuPositioner, S as DropdownMenuCheckboxItem, T as DropdownMenuItem, U as ContextMenuRootContext, V as MenuItem, W as useContextMenuRootContext, X as zh_TW_default, Z as zh_CN_default, _ as NativeScrollArea, at as Checkbox, d as PopoverContent, et as ja_default, g as PopoverTrigger, h as PopoverTitle, k as DropdownMenuSeparator, l as wrapLayout, nt as en_default, q as uiLocales, rt as I18n, st as IconThemeContext, t as ContentIcon, tt as fr_default, u as Popover, v as ScrollArea, w as DropdownMenuGroup, x as DropdownMenu, z as MenuPortal } from "./ContentIcon-
|
|
2
|
+
import { $ as ko_default, B as MenuPopup, C as DropdownMenuContent, D as DropdownMenuRadioGroup, E as DropdownMenuLabel, F as findRootOwnerId, G as MenuRootContext, H as MenuGroup, J as waitBranchDescription, K as useMenuRootContext, L as MenuRoot, N as DropdownMenuTrigger, O as DropdownMenuRadioItem, Q as ru_default, R as MenuPositioner, S as DropdownMenuCheckboxItem, T as DropdownMenuItem, U as ContextMenuRootContext, V as MenuItem, W as useContextMenuRootContext, X as zh_TW_default, Z as zh_CN_default, _ as NativeScrollArea, at as Checkbox, d as PopoverContent, et as ja_default, g as PopoverTrigger, h as PopoverTitle, k as DropdownMenuSeparator, l as wrapLayout, nt as en_default, q as uiLocales, rt as I18n, st as IconThemeContext, t as ContentIcon, tt as fr_default, u as Popover, v as ScrollArea, w as DropdownMenuGroup, x as DropdownMenu, z as MenuPortal } from "./ContentIcon-CUQHjQIw.js";
|
|
3
3
|
import { a as derive, c as strictEqual, i as compute, l as val, n as attachSetter, r as combine, s as readonlyVal } from "./dist-bO8nvHFH.js";
|
|
4
4
|
import { c as useLang, i as isString, l as useTranslate, n as isBoolean, o as I18nProvider, r as isPlainObject, t as isArray$1, u as useVal } from "./dist-BFmpkX4P.js";
|
|
5
|
-
import {
|
|
5
|
+
import { $t as require_with_selector, A as string, An as ownerDocument, C as literal, Cr as useRenderElement, Mn as createLucideIcon, Sr as clsx, T as number, Tn as getTarget, Un as cancelOpen, Vn as createChangeEventDetails, an as useTimeout, ar as triggerPress, bn as stopEvent$1, br as cn$1, fr as useId$1, ft as pressableTriggerOpenStateMapping, i as TooltipTrigger, k as strictObject, n as TooltipContent, p as timeZoneOffsetMinutes, qt as addEventListener, r as TooltipProvider, t as Tooltip, vr as Button, wn as contains, y as discriminatedUnion } from "./tooltip-wZJRB9oP.js";
|
|
6
6
|
import { r as resolveUiLanguage } from "./languages-gYzoQqCi.js";
|
|
7
7
|
import * as React from "react";
|
|
8
8
|
import reactExports, { Children, Suspense, createContext, forwardRef, isValidElement, lazy, memo, useCallback, useContext, useEffect, useId, useLayoutEffect, useMemo, useRef, useState } from "react";
|
|
@@ -2846,13 +2846,14 @@ function createNodeEntry(node, contentKey, canvasStore) {
|
|
|
2846
2846
|
const content$ = val(nodeContent(node));
|
|
2847
2847
|
const duplicateNode = (offset) => canvasStore.onDuplicate?.([node.id], offset);
|
|
2848
2848
|
const types = {
|
|
2849
|
-
approval: NODE_TYPE.TaskNode,
|
|
2850
|
-
outputs: NODE_TYPE.TaskNode,
|
|
2851
|
-
|
|
2852
|
-
|
|
2853
|
-
|
|
2854
|
-
|
|
2855
|
-
|
|
2849
|
+
"approval": NODE_TYPE.TaskNode,
|
|
2850
|
+
"outputs": NODE_TYPE.TaskNode,
|
|
2851
|
+
"webhook-response": NODE_TYPE.TaskNode,
|
|
2852
|
+
"condition": NODE_TYPE.ConditionNode,
|
|
2853
|
+
"task": NODE_TYPE.TaskNode,
|
|
2854
|
+
"trigger": NODE_TYPE.TriggerNode,
|
|
2855
|
+
"value": NODE_TYPE.ValueNode,
|
|
2856
|
+
"wait": NODE_TYPE.TaskNode
|
|
2856
2857
|
};
|
|
2857
2858
|
const store = new NodeStore(node.id, types[node.kind], {
|
|
2858
2859
|
ignoredNodeIds: canvasStore.ignoredNodeIds,
|
|
@@ -18586,22 +18587,6 @@ function timeZoneOffset(timezone, at = /* @__PURE__ */ new Date()) {
|
|
|
18586
18587
|
const absolute = Math.abs(minutes);
|
|
18587
18588
|
return `UTC${sign}${String(Math.floor(absolute / 60)).padStart(2, "0")}:${String(absolute % 60).padStart(2, "0")}`;
|
|
18588
18589
|
}
|
|
18589
|
-
function timeZoneOffsetMinutes(timezone, at = /* @__PURE__ */ new Date()) {
|
|
18590
|
-
try {
|
|
18591
|
-
const offset = new Intl.DateTimeFormat("en-US", {
|
|
18592
|
-
timeZone: timezone,
|
|
18593
|
-
timeZoneName: "longOffset"
|
|
18594
|
-
}).formatToParts(at).find((part) => part.type === "timeZoneName")?.value;
|
|
18595
|
-
if (offset == null) return;
|
|
18596
|
-
if (offset === "GMT") return 0;
|
|
18597
|
-
const match = /^GMT([+-])(\d{2}):(\d{2})$/.exec(offset);
|
|
18598
|
-
if (match == null) return;
|
|
18599
|
-
const minutes = Number(match[2]) * 60 + Number(match[3]);
|
|
18600
|
-
return match[1] === "-" ? -minutes : minutes;
|
|
18601
|
-
} catch {
|
|
18602
|
-
return;
|
|
18603
|
-
}
|
|
18604
|
-
}
|
|
18605
18590
|
function timeZoneLabel(timezone, t, language) {
|
|
18606
18591
|
let canonical;
|
|
18607
18592
|
try {
|
|
@@ -22718,4 +22703,4 @@ var FlowCanvas = ({ flowCanvasStore, annotationContext, onActivateSelection, onS
|
|
|
22718
22703
|
});
|
|
22719
22704
|
};
|
|
22720
22705
|
//#endregion
|
|
22721
|
-
export {
|
|
22706
|
+
export { isSameViewport as C, isMac as S, CanvasTooltip as _, collapseAllNested as a, toManifestHandleName as b, defaultTriggerIcon as c, selectableTimeZones as d, timeZoneLabel as f, E as g, cronDescription as h, JSONViewer as i, useDebouncedValue as l, timeZoneOffset as m, setAddItemId as n, formatDuration as o, timeZoneLongLabel as p, Textarea as r, CanvasNodeIcon as s, FlowCanvas as t, IconStack as u, CanvasStore as v, toManifestNodeId as x, toViewEdge as y };
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { l as useTranslate } from "./dist-BFmpkX4P.js";
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import { t as WorkbenchSelect } from "./workbenchSelect-
|
|
2
|
+
import { vr as Button } from "./tooltip-wZJRB9oP.js";
|
|
3
|
+
import { It as Input, a as DialogFooter, d as Field, f as FieldDescription, h as FieldLabel, i as DialogDescription, l as Icon, m as FieldGroup, n as DialogClose, o as DialogHeader, p as FieldError, r as DialogContent, s as DialogTitle, t as Dialog, u as Spinner } from "./dialog-DcGOzUP2.js";
|
|
4
|
+
import { t as WorkbenchSelect } from "./workbenchSelect-D8_vP2p5.js";
|
|
5
5
|
import { useEffect, useRef, useState } from "react";
|
|
6
6
|
import { Fragment as Fragment$1, jsx, jsxs } from "react/jsx-runtime";
|
|
7
7
|
//#region src/workbench/browser/runtime/shell/createResourceDialog.tsx
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { a as toPlainObject, i as isString } from "./dist-BFmpkX4P.js";
|
|
2
|
-
import { $ as
|
|
2
|
+
import { $ as useAnchoredPopupScrollLock, A as string, An as ownerDocument, At as useTriggerDataForwarding, Bn as useValueChanged, Br as isElement, C as literal, Cn as activeElement, Cr as useRenderElement, Ct as useSyncedFloatingRootContext, D as preprocess, Dt as PopupTriggerMap, E as object, Er as NOOP, Et as popupStoreSelectors, F as IndexGuessBehavior, Ft as FloatingFocusManager, Gn as closePress, Ht as FloatingPortal, I as useCompositeListItem, Ir as useStableCallback, Jn as imperativeAction, Jt as ReactStore, Ln as transitionStatusMapping, Lr as useRefWithInit, M as unknown, Mn as createLucideIcon, Mr as formatErrorMessage, Mt as platform, N as _isoDateTime, Nn as useTransitionStatus, Nr as mergeProps, Nt as useDismiss, O as record$1, Or as useMergedRefs, Ot as useImplicitActiveTrigger, P as Separator, Pn as useOpenChangeComplete, Pr as useIsoLayoutEffect, Pt as useClick, Q as useToolbarRootContext, Qn as itemPress, Rn as useAnimationFrame, T as number, Tn as getTarget, Tr as EMPTY_OBJECT, Tt as createInitialPopupStoreState, U as COMPOSITE_KEYS, Un as cancelOpen, Ut as CLICK_TRIGGER_IDENTIFIER, Vn as createChangeEventDetails, Wt as DROPDOWN_COLLISION_AVOIDANCE, Xt as useStore, Yt as Store, _ as array, _r as useControlled, _t as useRole, an as useTimeout, br as cn, cr as useFormContext, ct as inertValue, dr as useBaseUiId, dt as popupStateMapping, er as none, et as useScrollLock, f as isTimeZone, ft as pressableTriggerOpenStateMapping, g as _enum, gr as visuallyHiddenInput, gt as useTypeahead, h as ZodType, hr as visuallyHidden, i as TooltipTrigger, it as useAnchorPositioning, j as union, jn as Check, k as strictObject, kn as isWebKit, kr as useButton, kt as useOpenStateTransitions, lr as useRegisterFieldControl, lt as getPseudoElementBounds, m as ZodISODateTime, mr as fieldValidityMapping, mt as useOpenInteractionType, n as TooltipContent, nn as useValueAsRef, nt as getDisabledMountTransitionStyles, or as windowResize, ot as useDirection, pt as triggerOpenStateMapping, qt as addEventListener, rn as useOnFirstRender, rt as InternalBackdrop, sr as useLabelableContext, st as CompositeList, t as Tooltip, tn as createSelector, tt as usePositioner, ur as useFieldRootContext, ut as CommonPopupDataAttributes, v as boolean, vr as Button, vt as useListNavigation, w as never, wn as contains, wr as EMPTY_ARRAY, wt as useFloatingRootContext, x as json$1, xn as getFloatingFocusElement, xr as cva, y as discriminatedUnion, yn as rectToClientRect, yr as buttonVariants, yt as useInteractions, zr as getWindow } from "./tooltip-wZJRB9oP.js";
|
|
3
3
|
import * as React from "react";
|
|
4
4
|
import { useMemo } from "react";
|
|
5
5
|
import { Fragment as Fragment$1, jsx, jsxs } from "react/jsx-runtime";
|
|
@@ -176,6 +176,21 @@ var Network = createLucideIcon("Network", [
|
|
|
176
176
|
}]
|
|
177
177
|
]);
|
|
178
178
|
//#endregion
|
|
179
|
+
//#region ../../node_modules/.bun/lucide-react@0.468.0+f4eacebf2041cd4f/node_modules/lucide-react/dist/esm/icons/reply.js
|
|
180
|
+
/**
|
|
181
|
+
* @license lucide-react v0.468.0 - ISC
|
|
182
|
+
*
|
|
183
|
+
* This source code is licensed under the ISC license.
|
|
184
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
185
|
+
*/
|
|
186
|
+
var Reply = createLucideIcon("Reply", [["polyline", {
|
|
187
|
+
points: "9 17 4 12 9 7",
|
|
188
|
+
key: "hvgpf2"
|
|
189
|
+
}], ["path", {
|
|
190
|
+
d: "M20 18v-2a4 4 0 0 0-4-4H4",
|
|
191
|
+
key: "5vmcpk"
|
|
192
|
+
}]]);
|
|
193
|
+
//#endregion
|
|
179
194
|
//#region ../../node_modules/.bun/lucide-react@0.468.0+f4eacebf2041cd4f/node_modules/lucide-react/dist/esm/icons/sticky-note.js
|
|
180
195
|
/**
|
|
181
196
|
* @license lucide-react v0.468.0 - ISC
|
|
@@ -2319,6 +2334,11 @@ function dequal(foo, bar) {
|
|
|
2319
2334
|
return foo !== foo && bar !== bar;
|
|
2320
2335
|
}
|
|
2321
2336
|
//#endregion
|
|
2337
|
+
//#region ../../node_modules/.bun/zod@4.6.5/node_modules/zod/v4/classic/iso.js
|
|
2338
|
+
function datetime(params) {
|
|
2339
|
+
return _isoDateTime(ZodISODateTime, params);
|
|
2340
|
+
}
|
|
2341
|
+
//#endregion
|
|
2322
2342
|
//#region ../../node_modules/.bun/@cfworker+json-schema@4.1.1/node_modules/@cfworker/json-schema/dist/esm/deep-compare-strict.js
|
|
2323
2343
|
function deepCompareStrict(a, b) {
|
|
2324
2344
|
const typeofa = typeof a;
|
|
@@ -3403,6 +3423,22 @@ var triggerScheduleSchema = array(union([object({
|
|
|
3403
3423
|
value: number()
|
|
3404
3424
|
})]));
|
|
3405
3425
|
//#endregion
|
|
3426
|
+
//#region src/flow/common/wait.ts
|
|
3427
|
+
/** Drafts retain incomplete values; semantic validation gates publication and execution. */
|
|
3428
|
+
var waitAutoContinueDraftSchema = discriminatedUnion("kind", [strictObject({
|
|
3429
|
+
kind: literal("after"),
|
|
3430
|
+
durationMs: number().nullable()
|
|
3431
|
+
}), strictObject({
|
|
3432
|
+
kind: literal("at"),
|
|
3433
|
+
at: string(),
|
|
3434
|
+
timezone: string().optional()
|
|
3435
|
+
})]);
|
|
3436
|
+
/** Static business configuration; the deployment owns the allowed wait lifetime. */
|
|
3437
|
+
var waitAutoContinueSchema = discriminatedUnion("kind", [waitAutoContinueDraftSchema.options[0].extend({ durationMs: number().int().positive().max(Number.MAX_SAFE_INTEGER) }), waitAutoContinueDraftSchema.options[1].extend({
|
|
3438
|
+
at: datetime({ offset: true }),
|
|
3439
|
+
timezone: string().refine(isTimeZone, "Select a valid IANA timezone.").optional()
|
|
3440
|
+
})]);
|
|
3441
|
+
//#endregion
|
|
3406
3442
|
//#region src/flow/common/webhookMethod.ts
|
|
3407
3443
|
var webhookMethods = [
|
|
3408
3444
|
"GET",
|
|
@@ -3414,6 +3450,76 @@ var webhookMethods = [
|
|
|
3414
3450
|
function webhookSupportsBody(method) {
|
|
3415
3451
|
return method !== "GET";
|
|
3416
3452
|
}
|
|
3453
|
+
//#endregion
|
|
3454
|
+
//#region src/flow/common/webhookResponse.ts
|
|
3455
|
+
var webhookResponseTimeout = {
|
|
3456
|
+
defaultMs: 3e4,
|
|
3457
|
+
minMs: 1e3,
|
|
3458
|
+
maxMs: 6e4
|
|
3459
|
+
};
|
|
3460
|
+
var webhookStatusCodePort = {
|
|
3461
|
+
jsonSchema: { type: "number" },
|
|
3462
|
+
nullable: true
|
|
3463
|
+
};
|
|
3464
|
+
function webhookResponseAllowsBody(status) {
|
|
3465
|
+
return status !== 204 && status !== 205 && status !== 304;
|
|
3466
|
+
}
|
|
3467
|
+
var webhookHeaderValuePort = {
|
|
3468
|
+
jsonSchema: { type: [
|
|
3469
|
+
"string",
|
|
3470
|
+
"number",
|
|
3471
|
+
"boolean"
|
|
3472
|
+
] },
|
|
3473
|
+
nullable: true
|
|
3474
|
+
};
|
|
3475
|
+
var webhookHeadersPort = {
|
|
3476
|
+
jsonSchema: {
|
|
3477
|
+
type: "object",
|
|
3478
|
+
additionalProperties: { type: [
|
|
3479
|
+
"string",
|
|
3480
|
+
"number",
|
|
3481
|
+
"boolean"
|
|
3482
|
+
] }
|
|
3483
|
+
},
|
|
3484
|
+
nullable: true
|
|
3485
|
+
};
|
|
3486
|
+
function workflowOutputsPort(outputs) {
|
|
3487
|
+
return {
|
|
3488
|
+
jsonSchema: {
|
|
3489
|
+
type: "object",
|
|
3490
|
+
properties: Object.fromEntries(outputs.map((port) => [port.handle, port.jsonSchema])),
|
|
3491
|
+
additionalProperties: false,
|
|
3492
|
+
required: outputs.map((port) => port.handle)
|
|
3493
|
+
},
|
|
3494
|
+
nullable: false
|
|
3495
|
+
};
|
|
3496
|
+
}
|
|
3497
|
+
/** Header names are case-insensitive; never silently combine duplicate business fields. */
|
|
3498
|
+
function webhookHeaderNameIssue(name, names) {
|
|
3499
|
+
if (!/^[!#$%&'*+.^_`|~0-9A-Za-z-]+$/.test(name)) return "invalid";
|
|
3500
|
+
if (names.some((candidate) => candidate.toLowerCase() === name.toLowerCase())) return "duplicate";
|
|
3501
|
+
}
|
|
3502
|
+
/** Fixed inputs belong to the node, not author-supplied definitions. */
|
|
3503
|
+
var webhookResponseInputs = [
|
|
3504
|
+
{
|
|
3505
|
+
handle: "body",
|
|
3506
|
+
jsonSchema: {},
|
|
3507
|
+
nullable: true,
|
|
3508
|
+
value: ""
|
|
3509
|
+
},
|
|
3510
|
+
{
|
|
3511
|
+
handle: "statusCode",
|
|
3512
|
+
jsonSchema: { type: "number" },
|
|
3513
|
+
nullable: false,
|
|
3514
|
+
value: 200
|
|
3515
|
+
},
|
|
3516
|
+
{
|
|
3517
|
+
handle: "headers",
|
|
3518
|
+
jsonSchema: webhookHeadersPort.jsonSchema,
|
|
3519
|
+
nullable: false,
|
|
3520
|
+
value: {}
|
|
3521
|
+
}
|
|
3522
|
+
];
|
|
3417
3523
|
var text = string();
|
|
3418
3524
|
var actionConnection = text.describe("Account selection: omit while unconfigured; use an account ID to select it; use \"\" to explicitly defer configuration. Deferred Actions fail if called; deferred Agent tools are excluded from the callable tool set. Not supported by Triggers.");
|
|
3419
3525
|
var json = json$1();
|
|
@@ -3643,9 +3749,24 @@ var webhookOptions = object({
|
|
|
3643
3749
|
allowedMethods: never().optional(),
|
|
3644
3750
|
allowedOrigins: strings.optional(),
|
|
3645
3751
|
noResponseBody: never().optional(),
|
|
3752
|
+
responseBody: discriminatedUnion("kind", [strictObject({
|
|
3753
|
+
kind: literal("workflow-outputs"),
|
|
3754
|
+
output: text.optional(),
|
|
3755
|
+
timeoutMs: number().int().min(webhookResponseTimeout.minMs).max(webhookResponseTimeout.maxMs).optional()
|
|
3756
|
+
}), strictObject({
|
|
3757
|
+
kind: literal("webhook-response"),
|
|
3758
|
+
nodeId: text.optional(),
|
|
3759
|
+
timeoutMs: number().int().min(webhookResponseTimeout.minMs).max(webhookResponseTimeout.maxMs).optional()
|
|
3760
|
+
})]).optional(),
|
|
3646
3761
|
responseData: text.optional(),
|
|
3647
3762
|
responseHeaders: record$1(text, text).optional(),
|
|
3648
|
-
|
|
3763
|
+
responseHeadersSource: strictObject({
|
|
3764
|
+
kind: literal("workflow-outputs"),
|
|
3765
|
+
output: text.optional()
|
|
3766
|
+
}).optional(),
|
|
3767
|
+
responseHeaderOutputs: record$1(text, text).optional(),
|
|
3768
|
+
responseStatusCode: number().int().min(200).max(599).optional(),
|
|
3769
|
+
responseStatusCodeOutput: text.optional()
|
|
3649
3770
|
});
|
|
3650
3771
|
var webhook = {
|
|
3651
3772
|
bodyFields: array(input),
|
|
@@ -3700,6 +3821,12 @@ var base = {
|
|
|
3700
3821
|
onError: _enum(["stop", "error"]).optional()
|
|
3701
3822
|
};
|
|
3702
3823
|
var node = union([
|
|
3824
|
+
strictObject({
|
|
3825
|
+
...base,
|
|
3826
|
+
kind: literal("webhook-response"),
|
|
3827
|
+
retry: never().optional(),
|
|
3828
|
+
onError: never().optional()
|
|
3829
|
+
}),
|
|
3703
3830
|
strictObject({
|
|
3704
3831
|
...base,
|
|
3705
3832
|
kind: literal("outputs"),
|
|
@@ -3732,7 +3859,8 @@ var node = union([
|
|
|
3732
3859
|
strictObject({
|
|
3733
3860
|
...base,
|
|
3734
3861
|
kind: literal("wait"),
|
|
3735
|
-
...wait
|
|
3862
|
+
...wait,
|
|
3863
|
+
autoContinue: waitAutoContinueDraftSchema.optional()
|
|
3736
3864
|
}).omit({ timeoutMs: true }),
|
|
3737
3865
|
object({
|
|
3738
3866
|
...trigger,
|
|
@@ -3788,6 +3916,7 @@ var authoringDefinitionSchemas = {
|
|
|
3788
3916
|
ports,
|
|
3789
3917
|
condition: strictObject(condition),
|
|
3790
3918
|
wait: strictObject(wait),
|
|
3919
|
+
waitAutoContinue: waitAutoContinueSchema,
|
|
3791
3920
|
webhook: strictObject(webhook),
|
|
3792
3921
|
schedule: triggerScheduleSchema,
|
|
3793
3922
|
capabilities: array(capability),
|
|
@@ -3834,7 +3963,8 @@ var revision = object({
|
|
|
3834
3963
|
literal(6),
|
|
3835
3964
|
literal(7),
|
|
3836
3965
|
literal(8),
|
|
3837
|
-
literal(9)
|
|
3966
|
+
literal(9),
|
|
3967
|
+
literal(10)
|
|
3838
3968
|
]),
|
|
3839
3969
|
document,
|
|
3840
3970
|
modules: record$1(text, module)
|
|
@@ -3967,8 +4097,14 @@ var shapes = {
|
|
|
3967
4097
|
},
|
|
3968
4098
|
"graph.node.resolution.set": {
|
|
3969
4099
|
...at,
|
|
3970
|
-
before:
|
|
3971
|
-
|
|
4100
|
+
before: strictObject({
|
|
4101
|
+
...wait,
|
|
4102
|
+
autoContinue: waitAutoContinueDraftSchema.optional()
|
|
4103
|
+
}),
|
|
4104
|
+
value: strictObject({
|
|
4105
|
+
...wait,
|
|
4106
|
+
autoContinue: waitAutoContinueDraftSchema.optional()
|
|
4107
|
+
})
|
|
3972
4108
|
},
|
|
3973
4109
|
"graph.node.webhook.set": {
|
|
3974
4110
|
...at,
|
|
@@ -4030,12 +4166,14 @@ var variants = new Map(Object.entries(shapes).map(([kind, shape]) => [kind, shap
|
|
|
4030
4166
|
})]));
|
|
4031
4167
|
array(union([...variants.values()])).min(1);
|
|
4032
4168
|
function checkModelVersion(content) {
|
|
4169
|
+
if (content.modelVersion < 10 && Object.values(content.document.graph.nodes).some((candidateNode) => candidateNode.kind == "webhook" && (candidateNode.options?.responseBody != null || candidateNode.options?.responseStatusCodeOutput != null || candidateNode.options?.responseHeadersSource != null || candidateNode.options?.responseHeaderOutputs != null))) throw new TypeError("Dynamic Webhook responses require Flow model version 10.");
|
|
4033
4170
|
if (content.modelVersion < 9 && Object.values(content.document.graph.nodes).some((candidateNode) => "retry" in candidateNode && candidateNode.retry != null)) throw new TypeError("Node retries require Flow model version 9.");
|
|
4034
4171
|
if (content.modelVersion < 9 && Object.values(content.document.graph.nodes).some((candidateNode) => {
|
|
4035
4172
|
if (candidateNode.onError != null) return true;
|
|
4036
4173
|
if ([...Object.values("inputs" in candidateNode ? candidateNode.inputs : {}), ...Object.values(candidateNode.kind == "outputs" ? candidateNode.outputMappings : {})].some((candidateMapping) => candidateMapping.kind == "sources" && candidateMapping.sources.some((candidateSource) => candidateSource.kind == "node" && candidateSource.system))) return true;
|
|
4037
4174
|
return candidateNode.kind == "condition" && candidateNode.cases.some((item) => item.groups.some((candidateGroup) => candidateGroup.expressions.some((expression) => [expression.left, expression.right].some((candidateOperand) => candidateOperand?.kind == "source" && candidateOperand.source.kind == "node" && candidateOperand.source.system))));
|
|
4038
4175
|
})) throw new TypeError("Node error handling requires Flow model version 9.");
|
|
4176
|
+
if (content.modelVersion < 10 && Object.values(content.document.graph.nodes).some((candidate) => candidate.kind === "webhook-response")) throw new TypeError("Webhook response nodes require Flow model version 10.");
|
|
4039
4177
|
if (content.modelVersion < 8 && Object.values(content.document.graph.nodes).some((candidateNode) => candidateNode.kind == "outputs")) throw new TypeError("Workflow outputs require Flow model version 8.");
|
|
4040
4178
|
if (content.modelVersion < 7 && Object.values(content.document.graph.nodes).some((candidateNode) => candidateNode.kind == "start")) throw new TypeError("Start Triggers require Flow model version 7.");
|
|
4041
4179
|
if (content.modelVersion < 6 && Object.values(content.document.graph.nodes).some((candidateNode) => candidateNode.kind == "task" && "executor" in candidateNode.task)) throw new TypeError("Node-owned managed Tasks require Flow model version 6.");
|
|
@@ -4437,10 +4575,10 @@ function upgradeRevisionContent(content) {
|
|
|
4437
4575
|
function upgradeDecodedRevisionContent(content) {
|
|
4438
4576
|
const graph = content.document.graph;
|
|
4439
4577
|
const hasManual = Object.values(graph.nodes).some((node) => node.kind == "manual");
|
|
4440
|
-
if (!hasManual && content.modelVersion ==
|
|
4578
|
+
if (!hasManual && content.modelVersion == 10) return content;
|
|
4441
4579
|
return {
|
|
4442
4580
|
...content,
|
|
4443
|
-
modelVersion:
|
|
4581
|
+
modelVersion: 10,
|
|
4444
4582
|
document: {
|
|
4445
4583
|
...content.document,
|
|
4446
4584
|
graph: hasManual ? {
|
|
@@ -4487,7 +4625,7 @@ function invalid(message) {
|
|
|
4487
4625
|
throw new FlowChangeError(message);
|
|
4488
4626
|
}
|
|
4489
4627
|
function applyFlowChanges(content, operations) {
|
|
4490
|
-
const source = content.modelVersion !=
|
|
4628
|
+
const source = content.modelVersion != 10 || Object.values(content.document.graph.nodes).some((node) => node.kind == "manual") ? decodeRevisionContent(content) : content;
|
|
4491
4629
|
const document = { ...source.document };
|
|
4492
4630
|
const modules = { ...source.modules };
|
|
4493
4631
|
for (const operation of operations) switch (operation.kind) {
|
|
@@ -4803,12 +4941,15 @@ function applyFlowChanges(content, operations) {
|
|
|
4803
4941
|
const node = graph.nodes[operation.nodeId];
|
|
4804
4942
|
if (node?.kind != "wait" && node?.kind != "approval" || !dequal({
|
|
4805
4943
|
inputDefinitions: node.inputDefinitions,
|
|
4806
|
-
prompt: node.prompt
|
|
4944
|
+
prompt: node.prompt,
|
|
4945
|
+
...node.kind == "wait" && node.autoContinue != null ? { autoContinue: node.autoContinue } : {}
|
|
4807
4946
|
}, operation.before)) invalid("The resolution node changed before this operation was applied.");
|
|
4947
|
+
if (node.kind == "approval" && operation.value.autoContinue != null) invalid("Approval does not support automatic continuation.");
|
|
4808
4948
|
const updated = {
|
|
4809
4949
|
...node,
|
|
4810
4950
|
...operation.value
|
|
4811
4951
|
};
|
|
4952
|
+
if (updated.kind == "wait" && operation.value.autoContinue == null) Reflect.deleteProperty(updated, "autoContinue");
|
|
4812
4953
|
document.graph = {
|
|
4813
4954
|
...graph,
|
|
4814
4955
|
nodes: {
|
|
@@ -4932,7 +5073,7 @@ function applyFlowChanges(content, operations) {
|
|
|
4932
5073
|
assertOpenApiAuthBindings(document);
|
|
4933
5074
|
return upgradeDecodedRevisionContent({
|
|
4934
5075
|
document,
|
|
4935
|
-
modelVersion:
|
|
5076
|
+
modelVersion: 10,
|
|
4936
5077
|
modules
|
|
4937
5078
|
});
|
|
4938
5079
|
}
|
|
@@ -7959,6 +8100,9 @@ function comparePorts(source, target) {
|
|
|
7959
8100
|
mismatch: schemaMismatch(source, target, result)
|
|
7960
8101
|
} : result;
|
|
7961
8102
|
}
|
|
8103
|
+
function portsAssignable(source, target) {
|
|
8104
|
+
return comparePorts(source, target).kind == "compatible";
|
|
8105
|
+
}
|
|
7962
8106
|
function variableInputCompatible(jsonSchema) {
|
|
7963
8107
|
const schema = schemaObject(jsonSchema);
|
|
7964
8108
|
const types = schemaList(schema?.type);
|
|
@@ -8191,6 +8335,12 @@ function glyph(name) {
|
|
|
8191
8335
|
}
|
|
8192
8336
|
}
|
|
8193
8337
|
function Icon({ name, size = 18, ...props }) {
|
|
8338
|
+
if (name === "response") return /* @__PURE__ */ jsx(Reply, {
|
|
8339
|
+
"aria-hidden": "true",
|
|
8340
|
+
size,
|
|
8341
|
+
strokeWidth: 1.5,
|
|
8342
|
+
...props
|
|
8343
|
+
});
|
|
8194
8344
|
if (name === "outputs") return /* @__PURE__ */ jsx(LogOut, {
|
|
8195
8345
|
"aria-hidden": "true",
|
|
8196
8346
|
size,
|
|
@@ -8859,4 +9009,4 @@ function DialogDescription({ className, ...props }) {
|
|
|
8859
9009
|
});
|
|
8860
9010
|
}
|
|
8861
9011
|
//#endregion
|
|
8862
|
-
export {
|
|
9012
|
+
export { webhookStatusCodePort as $, upgradeManualTrigger as A, compareItemEquality as At, operandHandle as B, isSchemaKeyword as C, SelectTrigger as Ct, normalizeNodeName as D, isGroupedItems as Dt, nodeNameIssue as E, hasNullItemLabel as Et, clearConditionBindings as F, Label as Ft, authoringDefinitionSchemas as G, otherwiseOutput as H, comparisonIssue as I, Input as It, webhookHeaderValuePort as J, decodeRevisionContent as K, conditionInputPorts as L, useLabelableId as Lt, nodeErrorSchema as M, findItemIndex as Mt, nodeSystemOutputPorts as N, removeItem as Nt, portsByHandle as O, stringifyAsLabel as Ot, supportsNodeErrorHandling as P, selectedValueIncludes as Pt, webhookResponseTimeout as Q, mapConditionSources as R, ChevronDown as Rt, applyFlowChanges as S, SelectSeparator as St, nextNodeName as T, resolveAriaLabelledBy as Tt, unaryOperator as U, operatorsForType as V, valueType as W, webhookResponseAllowsBody as X, webhookHeadersPort as Y, webhookResponseInputs as Z, matchesSchema as _, Select as _t, DialogFooter as a, nodeRetryLimits as at, variableInputCompatible as b, SelectGroup as bt, DialogTrigger as c, checkJsonDepth as ct, Field as d, decisionQuestionIssues as dt, workflowOutputsPort as et, FieldDescription as f, decisionTask as ft, comparePorts as g, dequal as gt, FieldLabel as h, format as ht, DialogDescription as i, defaultNodeRetry as it, upgradeRevisionContent as j, defaultItemEquality as jt, resourceNameIssue as k, stringifyAsValue as kt, Icon as l, decisionLimits as lt, FieldGroup as m, limitDecisionQuestions as mt, DialogClose as n, webhookSupportsBody as nt, DialogHeader as o, retryConfigurationSchema as ot, FieldError as p, defaultDecisionQuestion as pt, webhookHeaderNameIssue as q, DialogContent as r, waitAutoContinueSchema as rt, DialogTitle as s, supportsNodeRetry as st, Dialog as t, webhookMethods as tt, Spinner as u, decisionModel as ut, portsAssignable as v, SelectChevron as vt, isTriggerNode as w, SelectValue as wt, FlowChangeError as x, SelectItem as xt, schemaObject as y, SelectContent as yt, nodeInputMappings as z };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { n as IconImageCrossOriginContext, o as IconifyProvider } from "./ContentIcon-
|
|
2
|
-
import { t as FlowCanvas,
|
|
1
|
+
import { n as IconImageCrossOriginContext, o as IconifyProvider } from "./ContentIcon-CUQHjQIw.js";
|
|
2
|
+
import { t as FlowCanvas, v as CanvasStore } from "./FlowCanvas-CqtUDPGj.js";
|
|
3
3
|
import { createElement } from "react";
|
|
4
4
|
import { createRoot } from "react-dom/client";
|
|
5
5
|
//#region ../../node_modules/.bun/html-to-image@1.11.11/node_modules/html-to-image/es/util.js
|