@marimo-team/islands 0.24.1-dev41 → 0.24.1-dev43

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 (33) hide show
  1. package/dist/{ConnectedDataExplorerComponent-4UvlnITc.js → ConnectedDataExplorerComponent-CxLgYj_n.js} +1038 -1038
  2. package/dist/{any-language-editor-ClDhQoll.js → any-language-editor-BrPYtXHK.js} +1 -1
  3. package/dist/{chat-ui-BzZL5_XE.js → chat-ui-Mjq3lBLn.js} +1335 -1335
  4. package/dist/{common-DVtMyyCC.js → common-IoLWZR0C.js} +20955 -20975
  5. package/dist/{input-CIaA2N0m.js → dropdown-menu-DEu759Oe.js} +930 -927
  6. package/dist/{error-banner-BbxpEiD5.js → error-banner-BT4uIIQ2.js} +190 -192
  7. package/dist/{glide-data-editor-CgO5z9xu.js → glide-data-editor-C2RTkAgQ.js} +51 -51
  8. package/dist/{html-to-image-DPAZGZSi.js → html-to-image-hKcfSWj_.js} +5795 -5590
  9. package/dist/main.js +8696 -8703
  10. package/dist/{mermaid-BBTUHwCi.js → mermaid-OsTxhZOI.js} +12 -12
  11. package/dist/{process-output-oZcxC_tq.js → process-output-BkHK-KDc.js} +6 -6
  12. package/dist/{reveal-component-BHpu6-qW.js → reveal-component-DUBiSLUI.js} +11 -11
  13. package/dist/{strings-CoQ5sA4r.js → select-Bakm9EUs.js} +50 -53
  14. package/dist/{spec-6c0_fLYz.js → spec-DqUrBQpS.js} +2 -2
  15. package/dist/style.css +1 -1
  16. package/dist/{useDateFormatter-6ImHK1ln.js → useDateFormatter-DjRKOAkR.js} +1 -1
  17. package/dist/{vega-component-DlnGFDeY.js → vega-component-A2xO4BUa.js} +17 -17
  18. package/package.json +1 -1
  19. package/src/components/chat/acp/agent-panel.tsx +4 -6
  20. package/src/components/data-table/columns.tsx +130 -132
  21. package/src/components/datasources/datasources.tsx +16 -17
  22. package/src/components/editor/actions/useNotebookActions.tsx +50 -0
  23. package/src/components/editor/chrome/panels/components.tsx +1 -1
  24. package/src/components/editor/connections/__tests__/add-connection-button.test.tsx +129 -0
  25. package/src/components/editor/connections/add-connection-button.tsx +132 -0
  26. package/src/components/editor/connections/components.tsx +11 -0
  27. package/src/components/editor/connections/quick-add-data-sources.tsx +11 -11
  28. package/src/components/editor/controls/__tests__/notebook-menu-dropdown.test.tsx +109 -1
  29. package/src/components/storage/storage-inspector.tsx +15 -17
  30. package/src/core/codemirror/language/panel/sql.test.tsx +69 -0
  31. package/src/core/codemirror/language/panel/sql.tsx +81 -4
  32. package/src/core/codemirror/markdown/commands.ts +1 -1
  33. package/src/core/codemirror/markdown/completions.ts +15 -17
@@ -5,14 +5,14 @@ import { t as l } from "./compiler-runtime-CAH9RLw2.js";
5
5
  import { t as u } from "./jsx-runtime-CpoKNRgu.js";
6
6
  import { Ac as d, Bc as f, Cn as p, Ec as m, Fc as h, Gc as g, Hc as _, In as v, Kc as y, Lc as ee, Nc as te, Pc as ne, Vc as b, Wc as x, jc as re, kc as ie, qc as S } from "./schemas-DeBAkn_c.js";
7
7
  //#region ../node_modules/.pnpm/@radix-ui+react-dialog@1.1.15_@types+react-dom@19.2.3_@types+react@19.2.10__@types+reac_243e5081bca3fbc73564cdfd99ffccf4/node_modules/@radix-ui/react-dialog/dist/index.mjs
8
- var C = /* @__PURE__ */ e(c(), 1), w = u(), T = "Dialog", [E, D] = y(T), [ae, O] = E(T), oe = (e) => {
8
+ var C = /* @__PURE__ */ e(c(), 1), w = u(), T = "Dialog", [E, ae] = y(T), [oe, D] = E(T), se = (e) => {
9
9
  let { __scopeDialog: t, children: n, open: r, defaultOpen: i, onOpenChange: a, modal: o = !0 } = e, s = C.useRef(null), c = C.useRef(null), [l, u] = _({
10
10
  prop: r,
11
11
  defaultProp: i ?? !1,
12
12
  onChange: a,
13
13
  caller: T
14
14
  });
15
- return /* @__PURE__ */ (0, w.jsx)(ae, {
15
+ return /* @__PURE__ */ (0, w.jsx)(oe, {
16
16
  scope: t,
17
17
  triggerRef: s,
18
18
  contentRef: c,
@@ -26,24 +26,24 @@ var C = /* @__PURE__ */ e(c(), 1), w = u(), T = "Dialog", [E, D] = y(T), [ae, O]
26
26
  children: n
27
27
  });
28
28
  };
29
- oe.displayName = T;
30
- var se = "DialogTrigger", ce = C.forwardRef((e, t) => {
31
- let { __scopeDialog: n, ...r } = e, i = O(se, n), o = a(t, i.triggerRef);
29
+ se.displayName = T;
30
+ var ce = "DialogTrigger", le = C.forwardRef((e, t) => {
31
+ let { __scopeDialog: n, ...r } = e, i = D(ce, n), o = a(t, i.triggerRef);
32
32
  return /* @__PURE__ */ (0, w.jsx)(S.button, {
33
33
  type: "button",
34
34
  "aria-haspopup": "dialog",
35
35
  "aria-expanded": i.open,
36
36
  "aria-controls": i.contentId,
37
- "data-state": U(i.open),
37
+ "data-state": H(i.open),
38
38
  ...r,
39
39
  ref: o,
40
40
  onClick: x(e.onClick, i.onOpenToggle)
41
41
  });
42
42
  });
43
- ce.displayName = se;
44
- var k = "DialogPortal", [le, A] = E(k, { forceMount: void 0 }), j = (e) => {
45
- let { __scopeDialog: t, forceMount: n, children: r, container: i } = e, a = O(k, t);
46
- return /* @__PURE__ */ (0, w.jsx)(le, {
43
+ le.displayName = ce;
44
+ var O = "DialogPortal", [ue, k] = E(O, { forceMount: void 0 }), A = (e) => {
45
+ let { __scopeDialog: t, forceMount: n, children: r, container: i } = e, a = D(O, t);
46
+ return /* @__PURE__ */ (0, w.jsx)(ue, {
47
47
  scope: t,
48
48
  forceMount: n,
49
49
  children: C.Children.map(r, (e) => /* @__PURE__ */ (0, w.jsx)(b, {
@@ -56,26 +56,26 @@ var k = "DialogPortal", [le, A] = E(k, { forceMount: void 0 }), j = (e) => {
56
56
  }))
57
57
  });
58
58
  };
59
- j.displayName = k;
60
- var M = "DialogOverlay", N = C.forwardRef((e, t) => {
61
- let n = A(M, e.__scopeDialog), { forceMount: r = n.forceMount, ...i } = e, a = O(M, e.__scopeDialog);
59
+ A.displayName = O;
60
+ var j = "DialogOverlay", M = C.forwardRef((e, t) => {
61
+ let n = k(j, e.__scopeDialog), { forceMount: r = n.forceMount, ...i } = e, a = D(j, e.__scopeDialog);
62
62
  return a.modal ? /* @__PURE__ */ (0, w.jsx)(b, {
63
63
  present: r || a.open,
64
- children: /* @__PURE__ */ (0, w.jsx)(de, {
64
+ children: /* @__PURE__ */ (0, w.jsx)(fe, {
65
65
  ...i,
66
66
  ref: t
67
67
  })
68
68
  }) : null;
69
69
  });
70
- N.displayName = M;
71
- var ue = s("DialogOverlay.RemoveScroll"), de = C.forwardRef((e, t) => {
72
- let { __scopeDialog: n, ...r } = e, i = O(M, n);
70
+ M.displayName = j;
71
+ var de = s("DialogOverlay.RemoveScroll"), fe = C.forwardRef((e, t) => {
72
+ let { __scopeDialog: n, ...r } = e, i = D(j, n);
73
73
  return /* @__PURE__ */ (0, w.jsx)(re, {
74
- as: ue,
74
+ as: de,
75
75
  allowPinchZoom: !0,
76
76
  shards: [i.contentRef],
77
77
  children: /* @__PURE__ */ (0, w.jsx)(S.div, {
78
- "data-state": U(i.open),
78
+ "data-state": H(i.open),
79
79
  ...r,
80
80
  ref: t,
81
81
  style: {
@@ -84,26 +84,26 @@ var ue = s("DialogOverlay.RemoveScroll"), de = C.forwardRef((e, t) => {
84
84
  }
85
85
  })
86
86
  });
87
- }), P = "DialogContent", F = C.forwardRef((e, t) => {
88
- let n = A(P, e.__scopeDialog), { forceMount: r = n.forceMount, ...i } = e, a = O(P, e.__scopeDialog);
87
+ }), N = "DialogContent", P = C.forwardRef((e, t) => {
88
+ let n = k(N, e.__scopeDialog), { forceMount: r = n.forceMount, ...i } = e, a = D(N, e.__scopeDialog);
89
89
  return /* @__PURE__ */ (0, w.jsx)(b, {
90
90
  present: r || a.open,
91
- children: a.modal ? /* @__PURE__ */ (0, w.jsx)(fe, {
91
+ children: a.modal ? /* @__PURE__ */ (0, w.jsx)(pe, {
92
92
  ...i,
93
93
  ref: t
94
- }) : /* @__PURE__ */ (0, w.jsx)(pe, {
94
+ }) : /* @__PURE__ */ (0, w.jsx)(me, {
95
95
  ...i,
96
96
  ref: t
97
97
  })
98
98
  });
99
99
  });
100
- F.displayName = P;
101
- var fe = C.forwardRef((e, t) => {
102
- let n = O(P, e.__scopeDialog), r = C.useRef(null), i = a(t, n.contentRef, r);
100
+ P.displayName = N;
101
+ var pe = C.forwardRef((e, t) => {
102
+ let n = D(N, e.__scopeDialog), r = C.useRef(null), i = a(t, n.contentRef, r);
103
103
  return C.useEffect(() => {
104
104
  let e = r.current;
105
105
  if (e) return d(e);
106
- }, []), /* @__PURE__ */ (0, w.jsx)(I, {
106
+ }, []), /* @__PURE__ */ (0, w.jsx)(F, {
107
107
  ...e,
108
108
  ref: i,
109
109
  trapFocus: n.open,
@@ -117,9 +117,9 @@ var fe = C.forwardRef((e, t) => {
117
117
  }),
118
118
  onFocusOutside: x(e.onFocusOutside, (e) => e.preventDefault())
119
119
  });
120
- }), pe = C.forwardRef((e, t) => {
121
- let n = O(P, e.__scopeDialog), r = C.useRef(!1), i = C.useRef(!1);
122
- return /* @__PURE__ */ (0, w.jsx)(I, {
120
+ }), me = C.forwardRef((e, t) => {
121
+ let n = D(N, e.__scopeDialog), r = C.useRef(!1), i = C.useRef(!1);
122
+ return /* @__PURE__ */ (0, w.jsx)(F, {
123
123
  ...e,
124
124
  ref: t,
125
125
  trapFocus: !1,
@@ -133,8 +133,8 @@ var fe = C.forwardRef((e, t) => {
133
133
  n.triggerRef.current?.contains(a) && t.preventDefault(), t.detail.originalEvent.type === "focusin" && i.current && t.preventDefault();
134
134
  }
135
135
  });
136
- }), I = C.forwardRef((e, t) => {
137
- let { __scopeDialog: n, trapFocus: r, onOpenAutoFocus: i, onCloseAutoFocus: o, ...s } = e, c = O(P, n), l = C.useRef(null), u = a(t, l);
136
+ }), F = C.forwardRef((e, t) => {
137
+ let { __scopeDialog: n, trapFocus: r, onOpenAutoFocus: i, onCloseAutoFocus: o, ...s } = e, c = D(N, n), l = C.useRef(null), u = a(t, l);
138
138
  return te(), /* @__PURE__ */ (0, w.jsxs)(w.Fragment, { children: [/* @__PURE__ */ (0, w.jsx)(h, {
139
139
  asChild: !0,
140
140
  loop: !0,
@@ -146,35 +146,35 @@ var fe = C.forwardRef((e, t) => {
146
146
  id: c.contentId,
147
147
  "aria-describedby": c.descriptionId,
148
148
  "aria-labelledby": c.titleId,
149
- "data-state": U(c.open),
149
+ "data-state": H(c.open),
150
150
  ...s,
151
151
  ref: u,
152
152
  onDismiss: () => c.onOpenChange(!1)
153
153
  })
154
- }), /* @__PURE__ */ (0, w.jsxs)(w.Fragment, { children: [/* @__PURE__ */ (0, w.jsx)(he, { titleId: c.titleId }), /* @__PURE__ */ (0, w.jsx)(_e, {
154
+ }), /* @__PURE__ */ (0, w.jsxs)(w.Fragment, { children: [/* @__PURE__ */ (0, w.jsx)(ge, { titleId: c.titleId }), /* @__PURE__ */ (0, w.jsx)(ve, {
155
155
  contentRef: l,
156
156
  descriptionId: c.descriptionId
157
157
  })] })] });
158
- }), L = "DialogTitle", R = C.forwardRef((e, t) => {
159
- let { __scopeDialog: n, ...r } = e, i = O(L, n);
158
+ }), I = "DialogTitle", L = C.forwardRef((e, t) => {
159
+ let { __scopeDialog: n, ...r } = e, i = D(I, n);
160
160
  return /* @__PURE__ */ (0, w.jsx)(S.h2, {
161
161
  id: i.titleId,
162
162
  ...r,
163
163
  ref: t
164
164
  });
165
165
  });
166
- R.displayName = L;
167
- var z = "DialogDescription", B = C.forwardRef((e, t) => {
168
- let { __scopeDialog: n, ...r } = e, i = O(z, n);
166
+ L.displayName = I;
167
+ var R = "DialogDescription", z = C.forwardRef((e, t) => {
168
+ let { __scopeDialog: n, ...r } = e, i = D(R, n);
169
169
  return /* @__PURE__ */ (0, w.jsx)(S.p, {
170
170
  id: i.descriptionId,
171
171
  ...r,
172
172
  ref: t
173
173
  });
174
174
  });
175
- B.displayName = z;
176
- var V = "DialogClose", H = C.forwardRef((e, t) => {
177
- let { __scopeDialog: n, ...r } = e, i = O(V, n);
175
+ z.displayName = R;
176
+ var B = "DialogClose", V = C.forwardRef((e, t) => {
177
+ let { __scopeDialog: n, ...r } = e, i = D(B, n);
178
178
  return /* @__PURE__ */ (0, w.jsx)(S.button, {
179
179
  type: "button",
180
180
  ...r,
@@ -182,16 +182,16 @@ var V = "DialogClose", H = C.forwardRef((e, t) => {
182
182
  onClick: x(e.onClick, () => i.onOpenChange(!1))
183
183
  });
184
184
  });
185
- H.displayName = V;
186
- function U(e) {
185
+ V.displayName = B;
186
+ function H(e) {
187
187
  return e ? "open" : "closed";
188
188
  }
189
- var W = "DialogTitleWarning", [me, G] = g(W, {
190
- contentName: P,
191
- titleName: L,
189
+ var U = "DialogTitleWarning", [he, W] = g(U, {
190
+ contentName: N,
191
+ titleName: I,
192
192
  docsSlug: "dialog"
193
- }), he = ({ titleId: e }) => {
194
- let t = G(W), n = `\`${t.contentName}\` requires a \`${t.titleName}\` for the component to be accessible for screen reader users.
193
+ }), ge = ({ titleId: e }) => {
194
+ let t = W(U), n = `\`${t.contentName}\` requires a \`${t.titleName}\` for the component to be accessible for screen reader users.
195
195
 
196
196
  If you want to hide the \`${t.titleName}\`, you can wrap it with our VisuallyHidden component.
197
197
 
@@ -199,8 +199,8 @@ For more information, see https://radix-ui.com/primitives/docs/components/${t.do
199
199
  return C.useEffect(() => {
200
200
  e && (document.getElementById(e) || console.error(n));
201
201
  }, [n, e]), null;
202
- }, ge = "DialogDescriptionWarning", _e = ({ contentRef: e, descriptionId: t }) => {
203
- let n = `Warning: Missing \`Description\` or \`aria-describedby={undefined}\` for {${G(ge).contentName}}.`;
202
+ }, _e = "DialogDescriptionWarning", ve = ({ contentRef: e, descriptionId: t }) => {
203
+ let n = `Warning: Missing \`Description\` or \`aria-describedby={undefined}\` for {${W(_e).contentName}}.`;
204
204
  return C.useEffect(() => {
205
205
  let r = e.current?.getAttribute("aria-describedby");
206
206
  t && r && (document.getElementById(t) || console.warn(n));
@@ -209,51 +209,51 @@ For more information, see https://radix-ui.com/primitives/docs/components/${t.do
209
209
  e,
210
210
  t
211
211
  ]), null;
212
- }, K = oe, ve = ce, q = j, ye = N, be = F, xe = R, Se = B, Ce = H, we = "AlertDialog", [Te, Ee] = y(we, [D]), J = D(), De = (e) => {
213
- let { __scopeAlertDialog: t, ...n } = e, r = J(t);
214
- return /* @__PURE__ */ (0, w.jsx)(K, {
212
+ }, G = se, ye = le, K = A, be = M, xe = P, Se = L, Ce = z, we = V, Te = "AlertDialog", [Ee, De] = y(Te, [ae]), q = ae(), Oe = (e) => {
213
+ let { __scopeAlertDialog: t, ...n } = e, r = q(t);
214
+ return /* @__PURE__ */ (0, w.jsx)(G, {
215
215
  ...r,
216
216
  ...n,
217
217
  modal: !0
218
218
  });
219
219
  };
220
- De.displayName = we;
221
- var Oe = "AlertDialogTrigger", ke = C.forwardRef((e, t) => {
222
- let { __scopeAlertDialog: n, ...r } = e, i = J(n);
223
- return /* @__PURE__ */ (0, w.jsx)(ve, {
220
+ Oe.displayName = Te;
221
+ var ke = "AlertDialogTrigger", Ae = C.forwardRef((e, t) => {
222
+ let { __scopeAlertDialog: n, ...r } = e, i = q(n);
223
+ return /* @__PURE__ */ (0, w.jsx)(ye, {
224
224
  ...i,
225
225
  ...r,
226
226
  ref: t
227
227
  });
228
228
  });
229
- ke.displayName = Oe;
230
- var Ae = "AlertDialogPortal", je = (e) => {
231
- let { __scopeAlertDialog: t, ...n } = e, r = J(t);
232
- return /* @__PURE__ */ (0, w.jsx)(q, {
229
+ Ae.displayName = ke;
230
+ var je = "AlertDialogPortal", Me = (e) => {
231
+ let { __scopeAlertDialog: t, ...n } = e, r = q(t);
232
+ return /* @__PURE__ */ (0, w.jsx)(K, {
233
233
  ...r,
234
234
  ...n
235
235
  });
236
236
  };
237
- je.displayName = Ae;
238
- var Me = "AlertDialogOverlay", Ne = C.forwardRef((e, t) => {
239
- let { __scopeAlertDialog: n, ...r } = e, i = J(n);
240
- return /* @__PURE__ */ (0, w.jsx)(ye, {
237
+ Me.displayName = je;
238
+ var Ne = "AlertDialogOverlay", Pe = C.forwardRef((e, t) => {
239
+ let { __scopeAlertDialog: n, ...r } = e, i = q(n);
240
+ return /* @__PURE__ */ (0, w.jsx)(be, {
241
241
  ...i,
242
242
  ...r,
243
243
  ref: t
244
244
  });
245
245
  });
246
- Ne.displayName = Me;
247
- var Y = "AlertDialogContent", [Pe, Fe] = Te(Y), Ie = t("AlertDialogContent"), Le = C.forwardRef((e, t) => {
248
- let { __scopeAlertDialog: n, children: r, ...i } = e, o = J(n), s = C.useRef(null), c = a(t, s), l = C.useRef(null);
249
- return /* @__PURE__ */ (0, w.jsx)(me, {
250
- contentName: Y,
251
- titleName: Re,
246
+ Pe.displayName = Ne;
247
+ var J = "AlertDialogContent", [Fe, Ie] = Ee(J), Le = t("AlertDialogContent"), Re = C.forwardRef((e, t) => {
248
+ let { __scopeAlertDialog: n, children: r, ...i } = e, o = q(n), s = C.useRef(null), c = a(t, s), l = C.useRef(null);
249
+ return /* @__PURE__ */ (0, w.jsx)(he, {
250
+ contentName: J,
251
+ titleName: ze,
252
252
  docsSlug: "alert-dialog",
253
- children: /* @__PURE__ */ (0, w.jsx)(Pe, {
253
+ children: /* @__PURE__ */ (0, w.jsx)(Fe, {
254
254
  scope: n,
255
255
  cancelRef: l,
256
- children: /* @__PURE__ */ (0, w.jsxs)(be, {
256
+ children: /* @__PURE__ */ (0, w.jsxs)(xe, {
257
257
  role: "alertdialog",
258
258
  ...o,
259
259
  ...i,
@@ -263,106 +263,62 @@ var Y = "AlertDialogContent", [Pe, Fe] = Te(Y), Ie = t("AlertDialogContent"), Le
263
263
  }),
264
264
  onPointerDownOutside: (e) => e.preventDefault(),
265
265
  onInteractOutside: (e) => e.preventDefault(),
266
- children: [/* @__PURE__ */ (0, w.jsx)(Ie, { children: r }), /* @__PURE__ */ (0, w.jsx)(Ke, { contentRef: s })]
266
+ children: [/* @__PURE__ */ (0, w.jsx)(Le, { children: r }), /* @__PURE__ */ (0, w.jsx)(qe, { contentRef: s })]
267
267
  })
268
268
  })
269
269
  });
270
270
  });
271
- Le.displayName = Y;
272
- var Re = "AlertDialogTitle", ze = C.forwardRef((e, t) => {
273
- let { __scopeAlertDialog: n, ...r } = e, i = J(n);
274
- return /* @__PURE__ */ (0, w.jsx)(xe, {
271
+ Re.displayName = J;
272
+ var ze = "AlertDialogTitle", Be = C.forwardRef((e, t) => {
273
+ let { __scopeAlertDialog: n, ...r } = e, i = q(n);
274
+ return /* @__PURE__ */ (0, w.jsx)(Se, {
275
275
  ...i,
276
276
  ...r,
277
277
  ref: t
278
278
  });
279
279
  });
280
- ze.displayName = Re;
281
- var Be = "AlertDialogDescription", Ve = C.forwardRef((e, t) => {
282
- let { __scopeAlertDialog: n, ...r } = e, i = J(n);
283
- return /* @__PURE__ */ (0, w.jsx)(Se, {
280
+ Be.displayName = ze;
281
+ var Ve = "AlertDialogDescription", He = C.forwardRef((e, t) => {
282
+ let { __scopeAlertDialog: n, ...r } = e, i = q(n);
283
+ return /* @__PURE__ */ (0, w.jsx)(Ce, {
284
284
  ...i,
285
285
  ...r,
286
286
  ref: t
287
287
  });
288
288
  });
289
- Ve.displayName = Be;
290
- var He = "AlertDialogAction", Ue = C.forwardRef((e, t) => {
291
- let { __scopeAlertDialog: n, ...r } = e, i = J(n);
292
- return /* @__PURE__ */ (0, w.jsx)(Ce, {
289
+ He.displayName = Ve;
290
+ var Ue = "AlertDialogAction", We = C.forwardRef((e, t) => {
291
+ let { __scopeAlertDialog: n, ...r } = e, i = q(n);
292
+ return /* @__PURE__ */ (0, w.jsx)(we, {
293
293
  ...i,
294
294
  ...r,
295
295
  ref: t
296
296
  });
297
297
  });
298
- Ue.displayName = He;
299
- var We = "AlertDialogCancel", Ge = C.forwardRef((e, t) => {
300
- let { __scopeAlertDialog: n, ...r } = e, { cancelRef: i } = Fe(We, n), o = J(n), s = a(t, i);
301
- return /* @__PURE__ */ (0, w.jsx)(Ce, {
298
+ We.displayName = Ue;
299
+ var Ge = "AlertDialogCancel", Ke = C.forwardRef((e, t) => {
300
+ let { __scopeAlertDialog: n, ...r } = e, { cancelRef: i } = Ie(Ge, n), o = q(n), s = a(t, i);
301
+ return /* @__PURE__ */ (0, w.jsx)(we, {
302
302
  ...o,
303
303
  ...r,
304
304
  ref: s
305
305
  });
306
306
  });
307
- Ge.displayName = We;
308
- var Ke = ({ contentRef: e }) => {
309
- let t = `\`${Y}\` requires a description for the component to be accessible for screen reader users.
307
+ Ke.displayName = Ge;
308
+ var qe = ({ contentRef: e }) => {
309
+ let t = `\`${J}\` requires a description for the component to be accessible for screen reader users.
310
310
 
311
- You can add a description to the \`${Y}\` by passing a \`${Be}\` component as a child, which also benefits sighted users by adding visible context to the dialog.
311
+ You can add a description to the \`${J}\` by passing a \`${Ve}\` component as a child, which also benefits sighted users by adding visible context to the dialog.
312
312
 
313
- Alternatively, you can use your own component as a description by assigning it an \`id\` and passing the same value to the \`aria-describedby\` prop in \`${Y}\`. If the description is confusing or duplicative for sighted users, you can use the \`@radix-ui/react-visually-hidden\` primitive as a wrapper around your description component.
313
+ Alternatively, you can use your own component as a description by assigning it an \`id\` and passing the same value to the \`aria-describedby\` prop in \`${J}\`. If the description is confusing or duplicative for sighted users, you can use the \`@radix-ui/react-visually-hidden\` primitive as a wrapper around your description component.
314
314
 
315
315
  For more information, see https://radix-ui.com/primitives/docs/components/alert-dialog`;
316
316
  return C.useEffect(() => {
317
317
  document.getElementById(e.current?.getAttribute("aria-describedby")) || console.warn(t);
318
318
  }, [t, e]), null;
319
- }, qe = De, Je = je, Ye = Ne, Xe = Le, X = Ue, Ze = Ge, Qe = ze, $e = Ve, Z = l(), Q = p({ detail: v() }), et = p({ error: v() });
320
- function tt(e) {
321
- if (!e) return "Unknown error";
322
- if (e instanceof Error) {
323
- let t = Q.safeParse(e.cause);
324
- return t.success ? t.data.detail : nt(e.message);
325
- }
326
- if (typeof e == "object") {
327
- let t = Q.safeParse(e);
328
- if (t.success) return t.data.detail;
329
- let n = et.safeParse(e);
330
- if (n.success) return n.data.error;
331
- }
332
- try {
333
- return JSON.stringify(e);
334
- } catch {
335
- return String(e);
336
- }
337
- }
338
- function nt(e) {
339
- let t = rt(e);
340
- if (!t) return e;
341
- let n = Q.safeParse(t);
342
- if (n.success) return n.data.detail;
343
- let r = et.safeParse(t);
344
- return r.success ? r.data.error : e;
345
- }
346
- function rt(e) {
347
- try {
348
- return JSON.parse(e);
349
- } catch {
350
- return e;
351
- }
352
- }
353
- var it = class extends Error {
354
- constructor(e = "The cell containing this UI element has not been run yet. Please run the cell first.") {
355
- super(e), this.name = "CellNotInitializedError";
356
- }
357
- }, at = class extends Error {
358
- constructor(e = "This UI element could not reach its function on the kernel. Try re-running the cell.") {
359
- super(e), this.name = "FunctionNotFoundError";
360
- }
361
- };
362
- //#endregion
363
- //#region src/components/ui/use-restore-focus.ts
364
- function ot() {
365
- let e = (0, Z.c)(3), [t, n] = (0, C.useState)(null), r;
319
+ }, Je = Oe, Ye = Me, Xe = Pe, Ze = Re, Y = We, Qe = Ke, $e = Be, et = He, X = l();
320
+ function tt() {
321
+ let e = (0, X.c)(3), [t, n] = (0, C.useState)(null), r;
366
322
  e[0] === Symbol.for("react.memo_cache_sentinel") ? (r = () => {
367
323
  n(document.activeElement);
368
324
  }, e[0] = r) : r = e[0];
@@ -376,16 +332,16 @@ function ot() {
376
332
  }
377
333
  //#endregion
378
334
  //#region src/components/ui/alert-dialog.tsx
379
- var st = qe, ct = m(({ children: e, ...t }) => /* @__PURE__ */ (0, w.jsx)(Je, {
335
+ var nt = Je, rt = m(({ children: e, ...t }) => /* @__PURE__ */ (0, w.jsx)(Ye, {
380
336
  ...t,
381
337
  children: /* @__PURE__ */ (0, w.jsx)(ie, { children: /* @__PURE__ */ (0, w.jsx)("div", {
382
338
  className: "fixed inset-0 z-50 flex items-end justify-center sm:items-start sm:top-[15%]",
383
339
  children: e
384
340
  }) })
385
341
  }));
386
- ct.displayName = Je.displayName;
387
- var lt = C.forwardRef((e, t) => {
388
- let n = (0, Z.c)(9), i, a;
342
+ rt.displayName = Ye.displayName;
343
+ var it = C.forwardRef((e, t) => {
344
+ let n = (0, X.c)(9), i, a;
389
345
  if (n[0] !== e) {
390
346
  let { className: t, children: r, ...o } = e;
391
347
  i = t, a = o, n[0] = e, n[1] = i, n[2] = a;
@@ -393,31 +349,31 @@ var lt = C.forwardRef((e, t) => {
393
349
  let o;
394
350
  n[3] === i ? o = n[4] : (o = r("fixed inset-0 z-50 bg-background/80 backdrop-blur-xs transition-opacity animate-in fade-in", i), n[3] = i, n[4] = o);
395
351
  let s;
396
- return n[5] !== a || n[6] !== t || n[7] !== o ? (s = /* @__PURE__ */ (0, w.jsx)(Ye, {
352
+ return n[5] !== a || n[6] !== t || n[7] !== o ? (s = /* @__PURE__ */ (0, w.jsx)(Xe, {
397
353
  className: o,
398
354
  ...a,
399
355
  ref: t
400
356
  }), n[5] = a, n[6] = t, n[7] = o, n[8] = s) : s = n[8], s;
401
357
  });
402
- lt.displayName = Ye.displayName;
403
- var ut = C.forwardRef((e, t) => {
404
- let n = (0, Z.c)(11), i, a;
358
+ it.displayName = Xe.displayName;
359
+ var at = C.forwardRef((e, t) => {
360
+ let n = (0, X.c)(11), i, a;
405
361
  n[0] === e ? (i = n[1], a = n[2]) : ({className: i, ...a} = e, n[0] = e, n[1] = i, n[2] = a);
406
- let o = ot(), s;
407
- n[3] === Symbol.for("react.memo_cache_sentinel") ? (s = /* @__PURE__ */ (0, w.jsx)(lt, {}), n[3] = s) : s = n[3];
362
+ let o = tt(), s;
363
+ n[3] === Symbol.for("react.memo_cache_sentinel") ? (s = /* @__PURE__ */ (0, w.jsx)(it, {}), n[3] = s) : s = n[3];
408
364
  let c;
409
365
  n[4] === i ? c = n[5] : (c = r("fixed z-50 grid w-full max-w-2xl scale-100 gap-4 border bg-background p-6 opacity-100 shadow-sm animate-in fade-in-90 slide-in-from-bottom-10 sm:rounded-lg sm:zoom-in-90 sm:slide-in-from-bottom-0 md:w-full", i), n[4] = i, n[5] = c);
410
366
  let l;
411
- return n[6] !== a || n[7] !== t || n[8] !== o || n[9] !== c ? (l = /* @__PURE__ */ (0, w.jsxs)(ct, { children: [s, /* @__PURE__ */ (0, w.jsx)(Xe, {
367
+ return n[6] !== a || n[7] !== t || n[8] !== o || n[9] !== c ? (l = /* @__PURE__ */ (0, w.jsxs)(rt, { children: [s, /* @__PURE__ */ (0, w.jsx)(Ze, {
412
368
  ref: t,
413
369
  className: c,
414
370
  ...o,
415
371
  ...a
416
372
  })] }), n[6] = a, n[7] = t, n[8] = o, n[9] = c, n[10] = l) : l = n[10], l;
417
373
  });
418
- ut.displayName = Xe.displayName;
419
- var dt = (e) => {
420
- let t = (0, Z.c)(8), n, i;
374
+ at.displayName = Ze.displayName;
375
+ var ot = (e) => {
376
+ let t = (0, X.c)(8), n, i;
421
377
  t[0] === e ? (n = t[1], i = t[2]) : ({className: n, ...i} = e, t[0] = e, t[1] = n, t[2] = i);
422
378
  let a;
423
379
  t[3] === n ? a = t[4] : (a = r("flex flex-col space-y-2 text-center sm:text-left", n), t[3] = n, t[4] = a);
@@ -427,9 +383,9 @@ var dt = (e) => {
427
383
  ...i
428
384
  }), t[5] = i, t[6] = a, t[7] = o) : o = t[7], o;
429
385
  };
430
- dt.displayName = "AlertDialogHeader";
431
- var ft = (e) => {
432
- let t = (0, Z.c)(8), n, i;
386
+ ot.displayName = "AlertDialogHeader";
387
+ var Z = (e) => {
388
+ let t = (0, X.c)(8), n, i;
433
389
  t[0] === e ? (n = t[1], i = t[2]) : ({className: n, ...i} = e, t[0] = e, t[1] = n, t[2] = i);
434
390
  let a;
435
391
  t[3] === n ? a = t[4] : (a = r("flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-2", n), t[3] = n, t[4] = a);
@@ -439,80 +395,122 @@ var ft = (e) => {
439
395
  ...i
440
396
  }), t[5] = i, t[6] = a, t[7] = o) : o = t[7], o;
441
397
  };
442
- ft.displayName = "AlertDialogFooter";
443
- var pt = C.forwardRef((e, t) => {
444
- let n = (0, Z.c)(9), i, a;
398
+ Z.displayName = "AlertDialogFooter";
399
+ var st = C.forwardRef((e, t) => {
400
+ let n = (0, X.c)(9), i, a;
445
401
  n[0] === e ? (i = n[1], a = n[2]) : ({className: i, ...a} = e, n[0] = e, n[1] = i, n[2] = a);
446
402
  let o;
447
403
  n[3] === i ? o = n[4] : (o = r("text-lg font-semibold", i), n[3] = i, n[4] = o);
448
404
  let s;
449
- return n[5] !== a || n[6] !== t || n[7] !== o ? (s = /* @__PURE__ */ (0, w.jsx)(Qe, {
405
+ return n[5] !== a || n[6] !== t || n[7] !== o ? (s = /* @__PURE__ */ (0, w.jsx)($e, {
450
406
  ref: t,
451
407
  className: o,
452
408
  ...a
453
409
  }), n[5] = a, n[6] = t, n[7] = o, n[8] = s) : s = n[8], s;
454
410
  });
455
- pt.displayName = Qe.displayName;
456
- var mt = C.forwardRef((e, t) => {
457
- let n = (0, Z.c)(9), i, a;
411
+ st.displayName = $e.displayName;
412
+ var ct = C.forwardRef((e, t) => {
413
+ let n = (0, X.c)(9), i, a;
458
414
  n[0] === e ? (i = n[1], a = n[2]) : ({className: i, ...a} = e, n[0] = e, n[1] = i, n[2] = a);
459
415
  let o;
460
416
  n[3] === i ? o = n[4] : (o = r("text-muted-foreground", i), n[3] = i, n[4] = o);
461
417
  let s;
462
- return n[5] !== a || n[6] !== t || n[7] !== o ? (s = /* @__PURE__ */ (0, w.jsx)($e, {
418
+ return n[5] !== a || n[6] !== t || n[7] !== o ? (s = /* @__PURE__ */ (0, w.jsx)(et, {
463
419
  ref: t,
464
420
  className: o,
465
421
  ...a
466
422
  }), n[5] = a, n[6] = t, n[7] = o, n[8] = s) : s = n[8], s;
467
423
  });
468
- mt.displayName = $e.displayName;
469
- var ht = C.forwardRef((e, t) => {
470
- let n = (0, Z.c)(9), a, o;
424
+ ct.displayName = et.displayName;
425
+ var lt = C.forwardRef((e, t) => {
426
+ let n = (0, X.c)(9), a, o;
471
427
  n[0] === e ? (a = n[1], o = n[2]) : ({className: a, ...o} = e, n[0] = e, n[1] = a, n[2] = o);
472
428
  let s;
473
429
  n[3] === a ? s = n[4] : (s = r(i(), a), n[3] = a, n[4] = s);
474
430
  let c;
475
- return n[5] !== o || n[6] !== t || n[7] !== s ? (c = /* @__PURE__ */ (0, w.jsx)(X, {
431
+ return n[5] !== o || n[6] !== t || n[7] !== s ? (c = /* @__PURE__ */ (0, w.jsx)(Y, {
476
432
  ref: t,
477
433
  className: s,
478
434
  ...o
479
435
  }), n[5] = o, n[6] = t, n[7] = s, n[8] = c) : c = n[8], c;
480
436
  });
481
- ht.displayName = X.displayName;
482
- var gt = C.forwardRef((e, t) => {
483
- let n = (0, Z.c)(9), a, o;
437
+ lt.displayName = Y.displayName;
438
+ var ut = C.forwardRef((e, t) => {
439
+ let n = (0, X.c)(9), a, o;
484
440
  n[0] === e ? (a = n[1], o = n[2]) : ({className: a, ...o} = e, n[0] = e, n[1] = a, n[2] = o);
485
441
  let s;
486
442
  n[3] === a ? s = n[4] : (s = r(i({ variant: "destructive" }), a), n[3] = a, n[4] = s);
487
443
  let c;
488
- return n[5] !== o || n[6] !== t || n[7] !== s ? (c = /* @__PURE__ */ (0, w.jsx)(X, {
444
+ return n[5] !== o || n[6] !== t || n[7] !== s ? (c = /* @__PURE__ */ (0, w.jsx)(Y, {
489
445
  ref: t,
490
446
  className: s,
491
447
  ...o
492
448
  }), n[5] = o, n[6] = t, n[7] = s, n[8] = c) : c = n[8], c;
493
449
  });
494
- gt.displayName = "AlertDialogDestructiveAction";
495
- var _t = C.forwardRef((e, t) => {
496
- let n = (0, Z.c)(9), a, o;
450
+ ut.displayName = "AlertDialogDestructiveAction";
451
+ var dt = C.forwardRef((e, t) => {
452
+ let n = (0, X.c)(9), a, o;
497
453
  n[0] === e ? (a = n[1], o = n[2]) : ({className: a, ...o} = e, n[0] = e, n[1] = a, n[2] = o);
498
454
  let s;
499
455
  n[3] === a ? s = n[4] : (s = r(i({ variant: "secondary" }), "mt-2 sm:mt-0", a), n[3] = a, n[4] = s);
500
456
  let c;
501
- return n[5] !== o || n[6] !== t || n[7] !== s ? (c = /* @__PURE__ */ (0, w.jsx)(Ze, {
457
+ return n[5] !== o || n[6] !== t || n[7] !== s ? (c = /* @__PURE__ */ (0, w.jsx)(Qe, {
502
458
  ref: t,
503
459
  className: s,
504
460
  ...o
505
461
  }), n[5] = o, n[6] = t, n[7] = s, n[8] = c) : c = n[8], c;
506
462
  });
507
- _t.displayName = Ze.displayName;
463
+ dt.displayName = Qe.displayName;
508
464
  //#endregion
509
- //#region src/plugins/impl/common/error-banner.tsx
510
- var vt = (e) => {
511
- let t = (0, Z.c)(23), { error: r, className: i, action: a } = e, [o, s] = (0, C.useState)(!1);
465
+ //#region src/utils/errors.ts
466
+ var Q = p({ detail: v() }), ft = p({ error: v() });
467
+ function pt(e) {
468
+ if (!e) return "Unknown error";
469
+ if (e instanceof Error) {
470
+ let t = Q.safeParse(e.cause);
471
+ return t.success ? t.data.detail : mt(e.message);
472
+ }
473
+ if (typeof e == "object") {
474
+ let t = Q.safeParse(e);
475
+ if (t.success) return t.data.detail;
476
+ let n = ft.safeParse(e);
477
+ if (n.success) return n.data.error;
478
+ }
479
+ try {
480
+ return JSON.stringify(e);
481
+ } catch {
482
+ return String(e);
483
+ }
484
+ }
485
+ function mt(e) {
486
+ let t = ht(e);
487
+ if (!t) return e;
488
+ let n = Q.safeParse(t);
489
+ if (n.success) return n.data.detail;
490
+ let r = ft.safeParse(t);
491
+ return r.success ? r.data.error : e;
492
+ }
493
+ function ht(e) {
494
+ try {
495
+ return JSON.parse(e);
496
+ } catch {
497
+ return e;
498
+ }
499
+ }
500
+ var gt = class extends Error {
501
+ constructor(e = "The cell containing this UI element has not been run yet. Please run the cell first.") {
502
+ super(e), this.name = "CellNotInitializedError";
503
+ }
504
+ }, _t = class extends Error {
505
+ constructor(e = "This UI element could not reach its function on the kernel. Try re-running the cell.") {
506
+ super(e), this.name = "FunctionNotFoundError";
507
+ }
508
+ }, vt = (e) => {
509
+ let t = (0, X.c)(23), { error: r, className: i, action: a } = e, [o, s] = (0, C.useState)(!1);
512
510
  if (!r) return null;
513
511
  n.error(r);
514
512
  let c;
515
- t[0] === r ? c = t[1] : (c = tt(r), t[0] = r, t[1] = c);
513
+ t[0] === r ? c = t[1] : (c = pt(r), t[0] = r, t[1] = c);
516
514
  let l = c, u;
517
515
  t[2] === Symbol.for("react.memo_cache_sentinel") ? (u = () => s(!0), t[2] = u) : u = t[2];
518
516
  let d;
@@ -534,24 +532,24 @@ var vt = (e) => {
534
532
  children: [d, f]
535
533
  }), t[7] = i, t[8] = d, t[9] = f, t[10] = p) : p = t[10];
536
534
  let m;
537
- t[11] === Symbol.for("react.memo_cache_sentinel") ? (m = /* @__PURE__ */ (0, w.jsx)(dt, { children: /* @__PURE__ */ (0, w.jsx)(pt, {
535
+ t[11] === Symbol.for("react.memo_cache_sentinel") ? (m = /* @__PURE__ */ (0, w.jsx)(ot, { children: /* @__PURE__ */ (0, w.jsx)(st, {
538
536
  className: "text-error",
539
537
  children: "Error"
540
538
  }) }), t[11] = m) : m = t[11];
541
539
  let h;
542
- t[12] === l ? h = t[13] : (h = /* @__PURE__ */ (0, w.jsx)(mt, {
540
+ t[12] === l ? h = t[13] : (h = /* @__PURE__ */ (0, w.jsx)(ct, {
543
541
  asChild: !0,
544
542
  className: "text-error text-sm p-2 font-mono overflow-auto whitespace-pre-wrap",
545
543
  children: /* @__PURE__ */ (0, w.jsx)("pre", { children: l })
546
544
  }), t[12] = l, t[13] = h);
547
545
  let g;
548
- t[14] === Symbol.for("react.memo_cache_sentinel") ? (g = /* @__PURE__ */ (0, w.jsx)(ft, { children: /* @__PURE__ */ (0, w.jsx)(ht, {
546
+ t[14] === Symbol.for("react.memo_cache_sentinel") ? (g = /* @__PURE__ */ (0, w.jsx)(Z, { children: /* @__PURE__ */ (0, w.jsx)(lt, {
549
547
  autoFocus: !0,
550
548
  onClick: () => s(!1),
551
549
  children: "Ok"
552
550
  }) }), t[14] = g) : g = t[14];
553
551
  let _;
554
- t[15] === h ? _ = t[16] : (_ = /* @__PURE__ */ (0, w.jsxs)(ut, {
552
+ t[15] === h ? _ = t[16] : (_ = /* @__PURE__ */ (0, w.jsxs)(at, {
555
553
  className: "max-w-[80%] max-h-[80%] overflow-hidden flex flex-col",
556
554
  children: [
557
555
  m,
@@ -560,7 +558,7 @@ var vt = (e) => {
560
558
  ]
561
559
  }), t[15] = h, t[16] = _);
562
560
  let v;
563
- t[17] !== o || t[18] !== _ ? (v = /* @__PURE__ */ (0, w.jsx)(st, {
561
+ t[17] !== o || t[18] !== _ ? (v = /* @__PURE__ */ (0, w.jsx)(nt, {
564
562
  open: o,
565
563
  onOpenChange: s,
566
564
  children: _
@@ -595,7 +593,7 @@ var vt = (e) => {
595
593
  ],
596
594
  defaultVariants: { kind: "info" }
597
595
  }), $ = (e) => {
598
- let t = (0, Z.c)(14), n, i, a, o, s;
596
+ let t = (0, X.c)(14), n, i, a, o, s;
599
597
  t[0] === e ? (n = t[1], i = t[2], a = t[3], o = t[4], s = t[5]) : ({kind: o, clickable: a, className: i, children: n, ...s} = e, t[0] = e, t[1] = n, t[2] = i, t[3] = a, t[4] = o, t[5] = s);
600
598
  let c;
601
599
  t[6] !== i || t[7] !== a || t[8] !== o ? (c = r(yt({
@@ -610,4 +608,4 @@ var vt = (e) => {
610
608
  }), t[10] = n, t[11] = s, t[12] = c, t[13] = l) : l = t[13], l;
611
609
  };
612
610
  //#endregion
613
- export { tt as a, q as c, at as i, K as l, vt as n, be as o, it as r, ye as s, $ as t };
611
+ export { pt as a, K as c, _t as i, G as l, vt as n, xe as o, gt as r, be as s, $ as t };