@oomol-lab/open-flow 0.1.0-alpha.0 → 0.1.0-alpha.10

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (72) hide show
  1. package/dist/browser/addNodeOptions-BwrMvPQC.js +5230 -0
  2. package/dist/browser/assets/typeScriptWorker-CaA4llbX.js +59850 -0
  3. package/dist/browser/carbon-DMCVsjHo.js +53 -0
  4. package/dist/browser/{project-change.js → change-Cu6pQIit.js} +15 -45
  5. package/dist/browser/createLucideIcon-COMgwa_u.js +5317 -0
  6. package/dist/browser/createResourceDialog-YgMLylQz.js +467 -0
  7. package/dist/browser/{dist-o4dBuwiG.js → dist-3Mj8q8Pr.js} +28 -28
  8. package/dist/browser/{dist-CIq6ue3I.js → dist-BKuSVKCC.js} +1115 -1103
  9. package/dist/browser/{dist-DL0SDskM.js → dist-BMqL-qR5.js} +473 -906
  10. package/dist/browser/{dist-CLZJNoWB.js → dist-BN4ZCyOB.js} +10 -10
  11. package/dist/browser/{dist-zyY--HOV.js → dist-BpopSHwP.js} +3 -3
  12. package/dist/browser/dist-C46JByB-.js +252 -0
  13. package/dist/browser/{dist-BbyiRq3c.js → dist-CJpzJrLM.js} +294 -284
  14. package/dist/browser/{dist-Djd02JSy.js → dist-CPuF50D9.js} +198 -198
  15. package/dist/browser/{dist-CvcmLAMW.js → dist-CUSrALSX.js} +115 -115
  16. package/dist/browser/dist-CeSZ2xSM.js +444 -0
  17. package/dist/browser/{dist-7oZK9QXZ.js → dist-DMi8_lU3.js} +5 -5
  18. package/dist/browser/{dist-B9OV3YTx.js → dist-DUzA0Ukh.js} +22 -22
  19. package/dist/browser/{dist-aWSZx4q1.js → dist-DWADUsVB.js} +75 -75
  20. package/dist/browser/{dist-BLk5M0uK.js → dist-Mecbzdl2.js} +3 -3
  21. package/dist/browser/{esm-DXw7EADW.js → esm-CvAs_mAS.js} +14 -24
  22. package/dist/browser/field-BrEG-7ap.js +312 -0
  23. package/dist/browser/flow-authoring-edge.d.ts +3 -0
  24. package/dist/browser/flow-authoring-module.d.ts +4 -0
  25. package/dist/browser/flow-authoring-node.d.ts +84 -0
  26. package/dist/browser/flow-authoring.d.ts +4 -0
  27. package/dist/browser/flow-authoring.js +522 -0
  28. package/dist/browser/{project-change.d.ts → flow-change.d.ts} +27 -36
  29. package/dist/browser/flow-change.js +231 -0
  30. package/dist/browser/{project-notifications.d.ts → flow-notifications.d.ts} +6 -3
  31. package/dist/browser/flowRunInputEditorStore-DXOyyY7o.js +8219 -0
  32. package/dist/browser/flowWorkspace-X_T_DcQf.js +46003 -0
  33. package/dist/browser/{lib-S4ccuMeT.js → lib-GrGxYjsJ.js} +3 -5
  34. package/dist/browser/licenses.md +620 -12
  35. package/dist/browser/{markdownContent-ZZFfSRqO.js → markdownContent-BI-2PmDX.js} +4071 -4035
  36. package/dist/browser/typeScriptSession-Dagu_tRs.js +2549 -0
  37. package/dist/browser/workbench-contract.d.ts +4 -5
  38. package/dist/browser/workbench.css +1 -1
  39. package/dist/browser/workbench.d.ts +2 -1
  40. package/dist/browser/workbench.js +3920 -2138
  41. package/dist/common/connector-action.d.ts +6 -0
  42. package/dist/common/connector-action.js +38 -30
  43. package/dist/common/control-api-conformance.js +223 -359
  44. package/dist/common/control-api-errors.d.ts +20 -24
  45. package/dist/common/control-api.d.ts +44 -73
  46. package/dist/common/control-api.js +150 -203
  47. package/dist/common/cron-trigger.d.ts +1 -1
  48. package/dist/common/cron-trigger.js +1 -1
  49. package/dist/common/flow-encoding.d.ts +11 -0
  50. package/dist/common/{project-encoding.js → flow-encoding.js} +14 -13
  51. package/dist/common/{project-notifications.d.ts → flow-notifications.d.ts} +6 -3
  52. package/dist/common/{project-semantics.d.ts → flow-semantics.d.ts} +9 -12
  53. package/dist/common/{project-semantics.js → flow-semantics.js} +594 -597
  54. package/dist/common/integration-trigger.d.ts +2 -1
  55. package/dist/common/integration-trigger.js +1 -1
  56. package/dist/common/poll-trigger.d.ts +1 -1
  57. package/dist/common/provider-triggers.js +1057 -948
  58. package/dist/common/run-lifecycle.js +1 -1
  59. package/dist/common/runtime-contract.d.ts +1 -1
  60. package/dist/common/runtime-contract.js +1 -1
  61. package/dist/common/scheduler.d.ts +7 -7
  62. package/dist/common/scheduler.js +237 -232
  63. package/dist/common/webhook-trigger.d.ts +1 -1
  64. package/dist/common/webhook-trigger.js +35 -1
  65. package/package.json +20 -10
  66. package/dist/browser/addNodeOptions-DqoIueCR.js +0 -33746
  67. package/dist/browser/carbon-nMY84Amv.js +0 -53
  68. package/dist/browser/composite-7VwgfnXx.js +0 -6088
  69. package/dist/browser/createResourceDialog-ByuJWdSL.js +0 -439
  70. package/dist/browser/dist-n-z5HtaO.js +0 -4
  71. package/dist/browser/flowWorkspace-DwVMpcar.js +0 -22092
  72. package/dist/common/project-encoding.d.ts +0 -11
@@ -0,0 +1,467 @@
1
+ import { A as e, At as t, Bn as n, D as r, Gn as i, Jn as a, O as o, On as s, Ot as c, R as l, S as u, T as d, Wn as f, Y as p, _ as m, b as h, c as g, ct as _, dt as v, er as y, ht as b, it as x, j as S, jr as C, kn as w, lr as T, lt as E, nt as D, rr as O, st as k, t as A, v as j, y as M } from "./createLucideIcon-COMgwa_u.js";
2
+ import { a as N, c as P, d as ee, i as te, l as ne, n as F, o as I, r as L, s as re, t as ie, u as ae } from "./field-BrEG-7ap.js";
3
+ import * as R from "react";
4
+ import { useEffect as oe, useRef as z, useState as se } from "react";
5
+ import { Fragment as ce, jsx as B, jsxs as V } from "react/jsx-runtime";
6
+ //#region ../../node_modules/.bun/lucide-react@0.468.0+f4eacebf2041cd4f/node_modules/lucide-react/dist/esm/icons/x.js
7
+ var H = A("X", [["path", {
8
+ d: "M18 6 6 18",
9
+ key: "1bl5f8"
10
+ }], ["path", {
11
+ d: "m6 6 12 12",
12
+ key: "d8bk6v"
13
+ }]]), U = /*#__PURE__*/ R.createContext(void 0);
14
+ process.env.NODE_ENV !== "production" && (U.displayName = "DialogRootContext");
15
+ function W(e) {
16
+ let t = R.useContext(U);
17
+ if (e === !1 && t === void 0) throw Error(process.env.NODE_ENV === "production" ? O(27) : "Base UI: DialogRootContext is missing. Dialog parts must be placed within <Dialog.Root>.");
18
+ return t;
19
+ }
20
+ //#endregion
21
+ //#region ../../node_modules/.bun/@base-ui+react@1.4.1+b87d06724be9db7a/node_modules/@base-ui/react/esm/dialog/backdrop/DialogBackdrop.js
22
+ var le = {
23
+ ...u,
24
+ ...t
25
+ }, G = /*#__PURE__*/ R.forwardRef(function(e, t) {
26
+ let { render: n, className: r, style: i, forceRender: o = !1, ...s } = e, { store: c } = W(), l = c.useState("open"), u = c.useState("nested"), d = c.useState("mounted"), f = {
27
+ open: l,
28
+ transitionStatus: c.useState("transitionStatus")
29
+ };
30
+ return a("div", e, {
31
+ state: f,
32
+ ref: [c.context.backdropRef, t],
33
+ stateAttributesMapping: le,
34
+ props: [{
35
+ role: "presentation",
36
+ hidden: !d,
37
+ style: {
38
+ userSelect: "none",
39
+ WebkitUserSelect: "none"
40
+ }
41
+ }, s],
42
+ enabled: o || !u
43
+ });
44
+ });
45
+ process.env.NODE_ENV !== "production" && (G.displayName = "DialogBackdrop");
46
+ //#endregion
47
+ //#region ../../node_modules/.bun/@base-ui+react@1.4.1+b87d06724be9db7a/node_modules/@base-ui/react/esm/dialog/close/DialogClose.js
48
+ var K = /*#__PURE__*/ R.forwardRef(function(e, t) {
49
+ let { render: n, className: r, disabled: i = !1, nativeButton: o = !0, style: s, ...c } = e, { store: l } = W(), u = l.useState("open");
50
+ function d(e) {
51
+ u && l.setOpen(!1, E(v, e.nativeEvent));
52
+ }
53
+ let { getButtonProps: f, buttonRef: p } = y({
54
+ disabled: i,
55
+ native: o
56
+ });
57
+ return a("button", e, {
58
+ state: { disabled: i },
59
+ ref: [t, p],
60
+ props: [
61
+ { onClick: d },
62
+ c,
63
+ f
64
+ ]
65
+ });
66
+ });
67
+ process.env.NODE_ENV !== "production" && (K.displayName = "DialogClose");
68
+ //#endregion
69
+ //#region ../../node_modules/.bun/@base-ui+react@1.4.1+b87d06724be9db7a/node_modules/@base-ui/react/esm/dialog/popup/DialogPopupCssVars.js
70
+ var ue = /*#__PURE__*/ function(e) {
71
+ return e.nestedDialogs = "--nested-dialogs", e;
72
+ }({}), de = function(e) {
73
+ return e[e.open = h.open] = "open", e[e.closed = h.closed] = "closed", e[e.startingStyle = h.startingStyle] = "startingStyle", e[e.endingStyle = h.endingStyle] = "endingStyle", e.nested = "data-nested", e.nestedDialogOpen = "data-nested-dialog-open", e;
74
+ }({}), q = /*#__PURE__*/ R.createContext(void 0);
75
+ process.env.NODE_ENV !== "production" && (q.displayName = "DialogPortalContext");
76
+ function fe() {
77
+ let e = R.useContext(q);
78
+ if (e === void 0) throw Error(process.env.NODE_ENV === "production" ? O(26) : "Base UI: <Dialog.Portal> is missing.");
79
+ return e;
80
+ }
81
+ //#endregion
82
+ //#region ../../node_modules/.bun/@base-ui+react@1.4.1+b87d06724be9db7a/node_modules/@base-ui/react/esm/dialog/popup/DialogPopup.js
83
+ var pe = {
84
+ ...u,
85
+ ...t,
86
+ nestedDialogOpen(e) {
87
+ return e ? { [de.nestedDialogOpen]: "" } : null;
88
+ }
89
+ }, J = /*#__PURE__*/ R.forwardRef(function(e, t) {
90
+ let { className: n, finalFocus: r, initialFocus: i, render: o, style: s, ...l } = e, { store: u } = W(), d = u.useState("descriptionElementId"), f = u.useState("disablePointerDismissal"), p = u.useState("floatingRootContext"), m = u.useState("popupProps"), h = u.useState("modal"), _ = u.useState("mounted"), v = u.useState("nested"), y = u.useState("nestedOpenDialogCount"), b = u.useState("open"), x = u.useState("openMethod"), C = u.useState("titleElementId"), w = u.useState("transitionStatus"), T = u.useState("role");
91
+ fe(), c({
92
+ open: b,
93
+ ref: u.context.popupRef,
94
+ onComplete() {
95
+ b && u.context.onOpenChangeComplete?.(!0);
96
+ }
97
+ });
98
+ function E(e) {
99
+ return e !== "touch" || u.context.popupRef.current;
100
+ }
101
+ let D = i === void 0 ? E : i, O = a("div", e, {
102
+ state: {
103
+ open: b,
104
+ nested: v,
105
+ transitionStatus: w,
106
+ nestedDialogOpen: y > 0
107
+ },
108
+ props: [
109
+ m,
110
+ {
111
+ "aria-labelledby": C ?? void 0,
112
+ "aria-describedby": d ?? void 0,
113
+ role: T,
114
+ tabIndex: -1,
115
+ hidden: !_,
116
+ onKeyDown(e) {
117
+ g.has(e.key) && e.stopPropagation();
118
+ },
119
+ style: { [ue.nestedDialogs]: y }
120
+ },
121
+ l
122
+ ],
123
+ ref: [
124
+ t,
125
+ u.context.popupRef,
126
+ u.useStateSetter("popupElement")
127
+ ],
128
+ stateAttributesMapping: pe
129
+ });
130
+ return /*#__PURE__*/ B(S, {
131
+ context: p,
132
+ openInteractionType: x,
133
+ disabled: !_,
134
+ closeOnFocusOut: !f,
135
+ initialFocus: D,
136
+ returnFocus: r,
137
+ modal: h !== !1,
138
+ restoreFocus: "popup",
139
+ children: O
140
+ });
141
+ });
142
+ process.env.NODE_ENV !== "production" && (J.displayName = "DialogPopup");
143
+ //#endregion
144
+ //#region ../../node_modules/.bun/@base-ui+react@1.4.1+b87d06724be9db7a/node_modules/@base-ui/react/esm/dialog/portal/DialogPortal.js
145
+ var Y = /*#__PURE__*/ R.forwardRef(function(e, t) {
146
+ let { keepMounted: n = !1, ...r } = e, { store: i } = W(), a = i.useState("mounted"), o = i.useState("modal"), s = i.useState("open");
147
+ return a || n ? /*#__PURE__*/ B(q.Provider, {
148
+ value: n,
149
+ children: /*#__PURE__*/ V(l, {
150
+ ref: t,
151
+ ...r,
152
+ children: [a && o === !0 && /*#__PURE__*/ B(j, {
153
+ ref: i.context.internalBackdropRef,
154
+ inert: M(!s)
155
+ }), e.children]
156
+ })
157
+ }) : null;
158
+ });
159
+ process.env.NODE_ENV !== "production" && (Y.displayName = "DialogPortal");
160
+ //#endregion
161
+ //#region ../../node_modules/.bun/@base-ui+react@1.4.1+b87d06724be9db7a/node_modules/@base-ui/react/esm/dialog/root/useDialogRoot.js
162
+ function me(t) {
163
+ let { store: n, parentContext: i, actionsRef: a, isDrawer: o } = t, c = n.useState("open"), l = n.useState("disablePointerDismissal"), u = n.useState("modal"), f = n.useState("popupElement"), { openMethod: p, triggerProps: h } = d(c);
164
+ ae(n);
165
+ let { forceUnmount: g } = ee(c, n), _ = R.useCallback(() => {
166
+ n.setOpen(!1, E(b));
167
+ }, [n]);
168
+ R.useImperativeHandle(a, () => ({
169
+ unmount: g,
170
+ close: _
171
+ }), [g, _]);
172
+ let v = re({
173
+ popupStore: n,
174
+ onOpenChange: n.setOpen,
175
+ treatPopupAsFloatingElement: !0
176
+ }), [y, x] = R.useState(0), [S, C] = R.useState(0), T = y === 0, D = I(v), O = e(v, {
177
+ outsidePressEvent() {
178
+ return n.context.internalBackdropRef.current || n.context.backdropRef.current ? "intentional" : {
179
+ mouse: u === "trap-focus" ? "sloppy" : "intentional",
180
+ touch: "sloppy"
181
+ };
182
+ },
183
+ outsidePress(e) {
184
+ if (!n.context.outsidePressEnabledRef.current || "button" in e && e.button !== 0 || "touches" in e && e.touches.length !== 1) return !1;
185
+ let t = w(e);
186
+ if (T && !l) {
187
+ let e = t;
188
+ return u && (n.context.internalBackdropRef.current || n.context.backdropRef.current) ? n.context.internalBackdropRef.current === e || n.context.backdropRef.current === e || s(e, f) && !e?.hasAttribute("data-base-ui-portal") : !0;
189
+ }
190
+ return !1;
191
+ },
192
+ escapeKey: T
193
+ });
194
+ m(c && u === !0, f);
195
+ let { getReferenceProps: k, getFloatingProps: A, getTriggerProps: j } = r([D, O]);
196
+ n.useContextCallback("onNestedDialogOpen", (e, t) => {
197
+ x(e), C(t);
198
+ }), n.useContextCallback("onNestedDialogClose", () => {
199
+ x(0), C(0);
200
+ }), R.useEffect(() => (i?.onNestedDialogOpen && c && i.onNestedDialogOpen(y + 1, S + +!!o), i?.onNestedDialogClose && !c && i.onNestedDialogClose(), () => {
201
+ i?.onNestedDialogClose && c && i.onNestedDialogClose();
202
+ }), [
203
+ o,
204
+ c,
205
+ y,
206
+ S,
207
+ i
208
+ ]);
209
+ let M = R.useMemo(() => k(h), [k, h]), N = R.useMemo(() => j(h), [j, h]), P = R.useMemo(() => A(), [A]);
210
+ n.useSyncedValues({
211
+ openMethod: p,
212
+ activeTriggerProps: M,
213
+ inactiveTriggerProps: N,
214
+ popupProps: P,
215
+ floatingRootContext: v,
216
+ nestedOpenDialogCount: y,
217
+ nestedOpenDrawerCount: S
218
+ });
219
+ }
220
+ //#endregion
221
+ //#region ../../node_modules/.bun/@base-ui+react@1.4.1+b87d06724be9db7a/node_modules/@base-ui/react/esm/dialog/store/DialogStore.js
222
+ var he = {
223
+ ...ne,
224
+ modal: D((e) => e.modal),
225
+ nested: D((e) => e.nested),
226
+ nestedOpenDialogCount: D((e) => e.nestedOpenDialogCount),
227
+ nestedOpenDrawerCount: D((e) => e.nestedOpenDrawerCount),
228
+ disablePointerDismissal: D((e) => e.disablePointerDismissal),
229
+ openMethod: D((e) => e.openMethod),
230
+ descriptionElementId: D((e) => e.descriptionElementId),
231
+ titleElementId: D((e) => e.titleElementId),
232
+ viewportElement: D((e) => e.viewportElement),
233
+ role: D((e) => e.role)
234
+ }, ge = class e extends p {
235
+ constructor(e) {
236
+ super(_e(e), {
237
+ popupRef: /*#__PURE__*/ R.createRef(),
238
+ backdropRef: /*#__PURE__*/ R.createRef(),
239
+ internalBackdropRef: /*#__PURE__*/ R.createRef(),
240
+ outsidePressEnabledRef: { current: !0 },
241
+ triggerElements: new o(),
242
+ onOpenChange: void 0,
243
+ onOpenChangeComplete: void 0
244
+ }, he);
245
+ }
246
+ setOpen = (e, t) => {
247
+ if (t.preventUnmountOnClose = () => {
248
+ this.set("preventUnmountingOnClose", !0);
249
+ }, !e && t.trigger == null && this.state.activeTriggerId != null && (t.trigger = this.state.activeTriggerElement ?? void 0), this.context.onOpenChange?.(e, t), t.isCanceled) return;
250
+ this.state.floatingRootContext.dispatchOpenChange(e, t);
251
+ let n = { open: e }, r = t.trigger?.id ?? null;
252
+ (r || e) && (n.activeTriggerId = r, n.activeTriggerElement = t.trigger ?? null), this.update(n);
253
+ };
254
+ static useStore(t, n) {
255
+ let r = T(() => new e(n)).current;
256
+ return t ?? r;
257
+ }
258
+ };
259
+ function _e(e = {}) {
260
+ return {
261
+ ...P(),
262
+ modal: !0,
263
+ disablePointerDismissal: !1,
264
+ popupElement: null,
265
+ viewportElement: null,
266
+ descriptionElementId: void 0,
267
+ titleElementId: void 0,
268
+ openMethod: null,
269
+ nested: !1,
270
+ nestedOpenDialogCount: 0,
271
+ nestedOpenDrawerCount: 0,
272
+ role: "dialog",
273
+ ...e
274
+ };
275
+ }
276
+ //#endregion
277
+ //#region ../../node_modules/.bun/@base-ui+react@1.4.1+b87d06724be9db7a/node_modules/@base-ui/react/esm/dialog/root/DialogRoot.js
278
+ var X = /*#__PURE__*/ R.createContext(!1);
279
+ process.env.NODE_ENV !== "production" && (X.displayName = "IsDrawerContext");
280
+ function ve(e) {
281
+ let { children: t, open: n, defaultOpen: r = !1, onOpenChange: i, onOpenChangeComplete: a, disablePointerDismissal: o = !1, modal: s = !0, actionsRef: c, handle: l, triggerId: u, defaultTriggerId: d = null } = e, f = W(!0), p = R.useContext(X), m = !!f, h = ge.useStore(l?.store, {
282
+ open: r,
283
+ openProp: n,
284
+ activeTriggerId: d,
285
+ triggerIdProp: u,
286
+ modal: s,
287
+ disablePointerDismissal: o,
288
+ nested: m
289
+ });
290
+ x(() => {
291
+ n === void 0 && h.state.open === !1 && r === !0 && h.update({
292
+ open: !0,
293
+ activeTriggerId: d
294
+ });
295
+ }), h.useControlledProp("openProp", n), h.useControlledProp("triggerIdProp", u), h.useSyncedValues({
296
+ disablePointerDismissal: o,
297
+ nested: m,
298
+ modal: s
299
+ }), h.useContextCallback("onOpenChange", i), h.useContextCallback("onOpenChangeComplete", a);
300
+ let g = h.useState("payload");
301
+ me({
302
+ store: h,
303
+ actionsRef: c,
304
+ parentContext: f?.store.context,
305
+ isDrawer: p,
306
+ onOpenChange: i,
307
+ triggerIdProp: u
308
+ });
309
+ let _ = R.useMemo(() => ({ store: h }), [h]);
310
+ return /*#__PURE__*/ B(X.Provider, {
311
+ value: !1,
312
+ children: /*#__PURE__*/ B(U.Provider, {
313
+ value: _,
314
+ children: typeof t == "function" ? t({ payload: g }) : t
315
+ })
316
+ });
317
+ }
318
+ //#endregion
319
+ //#region ../../node_modules/.bun/@base-ui+react@1.4.1+b87d06724be9db7a/node_modules/@base-ui/react/esm/dialog/title/DialogTitle.js
320
+ var Z = /*#__PURE__*/ R.forwardRef(function(e, t) {
321
+ let { render: r, className: i, style: o, id: s, ...c } = e, { store: l } = W(), u = n(s);
322
+ return l.useSyncedValueWithCleanup("titleElementId", u), a("h2", e, {
323
+ ref: t,
324
+ props: [{ id: u }, c]
325
+ });
326
+ });
327
+ process.env.NODE_ENV !== "production" && (Z.displayName = "DialogTitle");
328
+ //#endregion
329
+ //#region src/ui/browser/dialog.tsx
330
+ function ye(e) {
331
+ return /* @__PURE__ */ B(ve, {
332
+ "data-slot": "dialog",
333
+ ...e
334
+ });
335
+ }
336
+ function be(e) {
337
+ return /* @__PURE__ */ B(Y, {
338
+ "data-slot": "dialog-portal",
339
+ ...e
340
+ });
341
+ }
342
+ function Q(e) {
343
+ return /* @__PURE__ */ B(K, {
344
+ "data-slot": "dialog-close",
345
+ ...e
346
+ });
347
+ }
348
+ function xe({ className: e, ...t }) {
349
+ return /* @__PURE__ */ B(G, {
350
+ "data-slot": "dialog-overlay",
351
+ className: i("fixed inset-0 isolate z-50 bg-black/10 duration-100 supports-backdrop-filter:backdrop-blur-xs data-open:animate-in data-open:fade-in-0 data-closed:animate-out data-closed:fade-out-0 motion-reduce:animate-none motion-reduce:transition-none", e),
352
+ ...t
353
+ });
354
+ }
355
+ function Se({ children: e, className: t, closeLabel: n = "Close", container: r, showCloseButton: a = !0, ...o }) {
356
+ return /* @__PURE__ */ V(be, {
357
+ container: r,
358
+ children: [/* @__PURE__ */ B(xe, {}), /* @__PURE__ */ V(J, {
359
+ "data-slot": "dialog-content",
360
+ className: i("fixed top-1/2 left-1/2 z-50 grid w-full max-w-[calc(100%-2rem)] -translate-x-1/2 -translate-y-1/2 gap-4 rounded-xl bg-popover p-4 text-sm text-popover-foreground shadow-lg ring-1 ring-foreground/10 duration-100 outline-none sm:max-w-sm data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95 motion-reduce:animate-none motion-reduce:transition-none", t),
361
+ ...o,
362
+ children: [e, a && /* @__PURE__ */ V(K, {
363
+ "data-slot": "dialog-close",
364
+ render: /* @__PURE__ */ B(f, {
365
+ className: "absolute top-2 right-2",
366
+ size: "icon-sm",
367
+ variant: "ghost"
368
+ }),
369
+ children: [/* @__PURE__ */ B(H, {}), /* @__PURE__ */ B("span", {
370
+ className: "sr-only",
371
+ children: n
372
+ })]
373
+ })]
374
+ })]
375
+ });
376
+ }
377
+ function Ce({ className: e, ...t }) {
378
+ return /* @__PURE__ */ B("div", {
379
+ "data-slot": "dialog-header",
380
+ className: i("flex flex-col gap-2", e),
381
+ ...t
382
+ });
383
+ }
384
+ function $({ className: e, ...t }) {
385
+ return /* @__PURE__ */ B("div", {
386
+ "data-slot": "dialog-footer",
387
+ className: i("-mx-4 -mb-4 flex flex-col-reverse gap-2 rounded-b-xl border-t bg-muted/50 p-4 sm:flex-row sm:justify-end", e),
388
+ ...t
389
+ });
390
+ }
391
+ function we({ className: e, ...t }) {
392
+ return /* @__PURE__ */ B(Z, {
393
+ "data-slot": "dialog-title",
394
+ className: i("text-base leading-none font-medium", e),
395
+ ...t
396
+ });
397
+ }
398
+ //#endregion
399
+ //#region src/workbench/browser/runtime/shell/createResourceDialog.tsx
400
+ function Te({ id: e, issue: t, label: n, name: r, onNameChange: i, onOpenChange: a, onSubmit: o, pending: s, title: c }) {
401
+ let l = C(), u = z(null), d = z(null), [p, m] = se(!1), h = r.length > 0 && t != null, g = l(h ? `resource.nameIssue.${t}` : "resource.nameHint", { max: 80 }), v = `${e}-message`;
402
+ return oe(() => m(!0), []), /* @__PURE__ */ V(ce, { children: [/* @__PURE__ */ B("div", { ref: d }), /* @__PURE__ */ B(ye, {
403
+ onOpenChange: m,
404
+ onOpenChangeComplete: (e) => {
405
+ e || a(!1);
406
+ },
407
+ open: p,
408
+ children: /* @__PURE__ */ B(Se, {
409
+ container: d.current,
410
+ initialFocus: () => u.current,
411
+ showCloseButton: !1,
412
+ children: /* @__PURE__ */ V("form", {
413
+ className: "flex flex-col gap-4",
414
+ onSubmit: o,
415
+ children: [
416
+ /* @__PURE__ */ V(Ce, {
417
+ className: "flex-row items-center justify-between",
418
+ children: [/* @__PURE__ */ B(we, { children: c }), /* @__PURE__ */ B(Q, {
419
+ "aria-label": l("common.cancel"),
420
+ render: /* @__PURE__ */ B(f, {
421
+ size: "icon-sm",
422
+ variant: "ghost"
423
+ }),
424
+ type: "button",
425
+ children: /* @__PURE__ */ B(k, { name: "close" })
426
+ })]
427
+ }),
428
+ /* @__PURE__ */ B(te, { children: /* @__PURE__ */ V(ie, {
429
+ "data-invalid": h,
430
+ children: [
431
+ /* @__PURE__ */ B(N, {
432
+ htmlFor: e,
433
+ children: n
434
+ }),
435
+ /* @__PURE__ */ B(_, {
436
+ autoComplete: "off",
437
+ "aria-describedby": v,
438
+ "aria-invalid": h,
439
+ id: e,
440
+ name: "resource-name",
441
+ onChange: (e) => i(e.target.value),
442
+ ref: u,
443
+ required: !0,
444
+ value: r
445
+ }),
446
+ B(h ? L : F, {
447
+ id: v,
448
+ children: g
449
+ })
450
+ ]
451
+ }) }),
452
+ /* @__PURE__ */ V($, { children: [/* @__PURE__ */ B(Q, {
453
+ render: /* @__PURE__ */ B(f, { variant: "outline" }),
454
+ type: "button",
455
+ children: l("common.cancel")
456
+ }), /* @__PURE__ */ B(f, {
457
+ disabled: s || t != null,
458
+ type: "submit",
459
+ children: l(s ? "common.creating" : "common.create")
460
+ })] })
461
+ ]
462
+ })
463
+ })
464
+ })] });
465
+ }
466
+ //#endregion
467
+ export { Te as default };
@@ -1,13 +1,13 @@
1
- import { g as e, i as t, o as n } from "./dist-zyY--HOV.js";
2
- import { n as r, r as i, t as a } from "./dist-aWSZx4q1.js";
3
- import { C as o, _ as s, o as c, p as l, r as u, y as d } from "./dist-CvcmLAMW.js";
4
- //#region ../../node_modules/@lezer/yaml/dist/index.js
5
- var f = 63, p = 64, m = 1, h = 2, g = 3, _ = 4, v = 5, ee = 6, y = 7, b = 65, te = 66, ne = 8, re = 9, ie = 10, x = 11, S = 12, C = 13, w = 19, ae = 20, T = 29, E = 33, D = 34, O = 47, k = 0, A = 1, j = 2, M = 3, N = 4, P = class {
1
+ import { _ as e, a as t, s as n } from "./dist-BpopSHwP.js";
2
+ import { n as r, r as i, t as a } from "./dist-DWADUsVB.js";
3
+ import { _ as o, o as s, p as c, r as l, w as u, y as d } from "./dist-CUSrALSX.js";
4
+ //#region ../../node_modules/.bun/@lezer+yaml@1.0.4/node_modules/@lezer/yaml/dist/index.js
5
+ var f = 63, p = 64, m = 1, h = 2, g = 3, _ = 4, v = 5, y = 6, b = 7, x = 65, S = 66, ee = 8, te = 9, ne = 10, C = 11, re = 12, w = 13, T = 19, E = 20, D = 29, O = 33, k = 34, ie = 47, ae = 0, A = 1, j = 2, M = 3, N = 4, P = class {
6
6
  constructor(e, t, n) {
7
7
  this.parent = e, this.depth = t, this.type = n, this.hash = (e ? e.hash + e.hash << 8 : 0) + t + (t << 4) + n;
8
8
  }
9
9
  };
10
- P.top = new P(null, -1, k);
10
+ P.top = new P(null, -1, ae);
11
11
  function F(e, t) {
12
12
  for (let n = 0, r = t - e.pos - 1;; r--, n++) {
13
13
  let t = e.peek(r);
@@ -29,15 +29,15 @@ function z(e) {
29
29
  var B = new a({
30
30
  start: P.top,
31
31
  reduce(e, t) {
32
- return e.type == M && (t == ae || t == D) ? e.parent : e;
32
+ return e.type == M && (t == E || t == k) ? e.parent : e;
33
33
  },
34
34
  shift(e, t, n, r) {
35
35
  if (t == g) return new P(e, F(r, r.pos), A);
36
- if (t == b || t == v) return new P(e, F(r, r.pos), j);
36
+ if (t == x || t == v) return new P(e, F(r, r.pos), j);
37
37
  if (t == f) return e.parent;
38
- if (t == w || t == E) return new P(e, 0, M);
39
- if (t == C && e.type == N) return e.parent;
40
- if (t == O) {
38
+ if (t == T || t == O) return new P(e, 0, M);
39
+ if (t == w && e.type == N) return e.parent;
40
+ if (t == ie) {
41
41
  let t = /[1-9]/.exec(r.read(r.pos, n.pos));
42
42
  if (t) return new P(e, e.depth + +t[0], N);
43
43
  }
@@ -68,11 +68,11 @@ var H = new r((e, t) => {
68
68
  }
69
69
  }, { contextual: !0 }), U = new r((e, t) => {
70
70
  if (t.context.type == M) {
71
- e.next == 63 && (e.advance(), z(e.next) && e.acceptToken(y));
71
+ e.next == 63 && (e.advance(), z(e.next) && e.acceptToken(b));
72
72
  return;
73
73
  }
74
74
  if (e.next == 45) e.advance(), z(e.next) && e.acceptToken(t.context.type == A && t.context.depth == F(e, e.pos - 1) ? _ : g);
75
- else if (e.next == 63) e.advance(), z(e.next) && e.acceptToken(t.context.type == j && t.context.depth == F(e, e.pos - 1) ? ee : v);
75
+ else if (e.next == 63) e.advance(), z(e.next) && e.acceptToken(t.context.type == j && t.context.depth == F(e, e.pos - 1) ? y : v);
76
76
  else {
77
77
  let n = e.pos;
78
78
  for (;;) if (I(e.next)) {
@@ -95,8 +95,8 @@ var H = new r((e, t) => {
95
95
  }
96
96
  for (; I(e.next);) e.advance();
97
97
  if (e.next == 58) {
98
- if (e.pos == n && t.canShift(T)) return;
99
- z(e.peek(1)) && e.acceptTokenTo(t.context.type == j && t.context.depth == F(e, n) ? te : b, n);
98
+ if (e.pos == n && t.canShift(D)) return;
99
+ z(e.peek(1)) && e.acceptTokenTo(t.context.type == j && t.context.depth == F(e, n) ? S : x, n);
100
100
  }
101
101
  }
102
102
  }, { contextual: !0 });
@@ -177,11 +177,11 @@ function Q(e, t, n, r) {
177
177
  return !0;
178
178
  }
179
179
  var ce = new r((e, t) => {
180
- if (e.next == 33) q(e), e.acceptToken(S);
180
+ if (e.next == 33) q(e), e.acceptToken(re);
181
181
  else if (e.next == 38 || e.next == 42) {
182
- let t = e.next == 38 ? ie : x;
182
+ let t = e.next == 38 ? ne : C;
183
183
  J(e), e.acceptToken(t);
184
- } else e.next == 39 || e.next == 34 ? (Y(e, !1), e.acceptToken(re)) : Q(e, !1, t.context.type == M, t.context.depth) && e.acceptToken(ne);
184
+ } else e.next == 39 || e.next == 34 ? (Y(e, !1), e.acceptToken(te)) : Q(e, !1, t.context.type == M, t.context.depth) && e.acceptToken(ee);
185
185
  }), le = new r((e, t) => {
186
186
  let n = t.context.type == N ? t.context.depth : -1, r = e.pos;
187
187
  scan: for (;;) {
@@ -195,7 +195,7 @@ var ce = new r((e, t) => {
195
195
  r = e.pos;
196
196
  }
197
197
  }
198
- e.acceptTokenTo(C, r);
198
+ e.acceptTokenTo(w, r);
199
199
  }), ue = t({
200
200
  DirectiveName: n.keyword,
201
201
  DirectiveContent: n.attributeValue,
@@ -271,9 +271,9 @@ var ce = new r((e, t) => {
271
271
  tokenizers: [0],
272
272
  topRules: { Document: [0, 1] },
273
273
  tokenPrec: 67
274
- }), $ = /*@__PURE__*/ u.define({
274
+ }), $ = /*@__PURE__*/ l.define({
275
275
  name: "yaml",
276
- parser: /*@__PURE__*/ de.configure({ props: [/*@__PURE__*/ o.add({
276
+ parser: /*@__PURE__*/ de.configure({ props: [/*@__PURE__*/ u.add({
277
277
  Stream: (e) => {
278
278
  for (let t = e.node.resolve(e.pos, -1); t && t.to >= e.pos; t = t.parent) {
279
279
  if (t.name == "BlockLiteralContent" && t.from < t.to) return e.baseIndentFor(t);
@@ -288,10 +288,10 @@ var ce = new r((e, t) => {
288
288
  }
289
289
  return null;
290
290
  },
291
- FlowMapping: /*@__PURE__*/ l({ closing: "}" }),
292
- FlowSequence: /*@__PURE__*/ l({ closing: "]" })
291
+ FlowMapping: /*@__PURE__*/ c({ closing: "}" }),
292
+ FlowSequence: /*@__PURE__*/ c({ closing: "]" })
293
293
  }), /*@__PURE__*/ d.add({
294
- "FlowMapping FlowSequence": s,
294
+ "FlowMapping FlowSequence": o,
295
295
  "Item Pair BlockLiteral": (e, t) => ({
296
296
  from: t.doc.lineAt(e.from).to,
297
297
  to: e.to
@@ -303,18 +303,18 @@ var ce = new r((e, t) => {
303
303
  }
304
304
  });
305
305
  function pe() {
306
- return new c($);
306
+ return new s($);
307
307
  }
308
- var me = /*@__PURE__*/ u.define({
308
+ var me = /*@__PURE__*/ l.define({
309
309
  name: "yaml-frontmatter",
310
310
  parser: /*@__PURE__*/ fe.configure({ props: [/*@__PURE__*/ t({ DashLine: n.meta })] })
311
311
  });
312
312
  function he(t) {
313
- let { language: n, support: r } = t.content instanceof c ? t.content : {
313
+ let { language: n, support: r } = t.content instanceof s ? t.content : {
314
314
  language: t.content,
315
315
  support: []
316
316
  };
317
- return new c(me.configure({ wrap: e((e) => e.name == "FrontmatterContent" ? { parser: $.parser } : e.name == "Body" ? { parser: n.parser } : null) }), r);
317
+ return new s(me.configure({ wrap: e((e) => e.name == "FrontmatterContent" ? { parser: $.parser } : e.name == "Body" ? { parser: n.parser } : null) }), r);
318
318
  }
319
319
  //#endregion
320
320
  export { pe as yaml, he as yamlFrontmatter, $ as yamlLanguage };