@marimo-team/islands 0.25.1-dev2 → 0.25.1-dev4
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/{ErrorBoundary-DO0ie20N.js → ErrorBoundary-pV36lYEK.js} +1 -1
- package/dist/{cells-DYIkSxs6.js → cells-B5-y5EY3.js} +4121 -4148
- package/dist/{chat-ui-BXj3uYjy.js → chat-ui-HJZsTl7o.js} +45 -45
- package/dist/{code-visibility-64_ACQvC.js → code-visibility-CgZS2a3W.js} +17 -17
- package/dist/{common-LlPE7GR6.js → common-DnMDPPaW.js} +611 -611
- package/dist/{data-grid-overlay-editor-BUvmnptP.js → data-grid-overlay-editor-hHYgD_Sm.js} +1 -1
- package/dist/{error-entries-C0NsUqXl.js → error-entries-Bkbpx0T0.js} +18 -18
- package/dist/{feedback-button-B98mEc3M.js → feedback-button-CvKssdG_.js} +19 -19
- package/dist/{formats-BR5iGb4s.js → formats-C8rLgZT9.js} +1 -1
- package/dist/{glide-data-editor-CBIPbkXG.js → glide-data-editor-Ohetlgag.js} +3 -3
- package/dist/{globals-VpAtGRbg.js → globals-CPNNcOJI.js} +1 -1
- package/dist/{html-to-image-CeYYvQNb.js → html-to-image-BAgJOlSW.js} +31 -30
- package/dist/main.js +581 -581
- package/dist/{number-overlay-editor-ClZmv3Qw.js → number-overlay-editor-CHWg5gGO.js} +1 -1
- package/dist/{process-output-BCTjlyuH.js → process-output-zDX4jbhd.js} +2 -2
- package/dist/{reveal-component-C1s_K6O8.js → reveal-component-BujcZI2B.js} +744 -743
- package/dist/{toDate-WXg1yLcI.js → toDate-C67bxMWn.js} +139 -111
- package/dist/{vega-component-D0QXopU8.js → vega-component-CNf5gcrm.js} +9 -9
- package/package.json +1 -1
- package/src/core/kernel/__tests__/session.test.ts +110 -1
- package/src/core/kernel/session.ts +46 -15
package/dist/main.js
CHANGED
|
@@ -3,20 +3,20 @@ import { _ as a, c as o, f as s, g as c, h as l, i as u, l as d, m as f, n as p,
|
|
|
3
3
|
import { t as y } from "./react-ofJbxM4x.js";
|
|
4
4
|
import { t as b } from "./compiler-runtime-Cj8ZWiNS.js";
|
|
5
5
|
import { i as x, n as S, r as C, t as w } from "./copy-icon-CLdENY__.js";
|
|
6
|
-
import { C as T, F as E, G as D, I as O, J as k, K as A, L as j, P as M, R as N, X as P, Z as F, _ as I, a as L, b as R, g as ee, i as z, j as te, k as B, n as ne, o as re, q as ie, v as ae, y as oe } from "./html-to-image-
|
|
6
|
+
import { C as T, F as E, G as D, I as O, J as k, K as A, L as j, P as M, R as N, X as P, Z as F, _ as I, a as L, b as R, g as ee, i as z, j as te, k as B, n as ne, o as re, q as ie, v as ae, y as oe } from "./html-to-image-BAgJOlSW.js";
|
|
7
7
|
import { a as se, f as ce, g as V, i as le, n as ue, o as de, p as fe, r as pe, t as me } from "./tooltip-qB8NlSqV.js";
|
|
8
|
-
import { $ as he, $t as ge,
|
|
9
|
-
import { D as
|
|
10
|
-
import { $t as
|
|
11
|
-
import { c as
|
|
12
|
-
import { t as
|
|
13
|
-
import { A as
|
|
14
|
-
import { B as
|
|
15
|
-
import { _ as
|
|
16
|
-
import { a as wa, c as Ta, d as Ea, f as Da, i as Oa, l as ka, n as Aa, o as ja, r as Ma, s as Na, t as Pa } from "./process-output-
|
|
8
|
+
import { $ as he, $t as ge, B as _e, Bt as ve, C as ye, Ct as be, D as xe, Dt as Se, Et as Ce, F as we, G as Te, Gt as Ee, Ht as De, I as Oe, J as ke, Jt as Ae, Kt as je, L as Me, O as Ne, Ot as Pe, P as Fe, Pt as Ie, Q as Le, Qt as Re, Rt as ze, S as Be, St as Ve, T as He, Tt as Ue, U as We, W as Ge, Wt as Ke, bt as qe, c as Je, cn as Ye, ct as Xe, d as Ze, dn as Qe, dt as $e, en as et, f as tt, fn as nt, ft as rt, g as it, gt as at, h as ot, hn as st, k as ct, l as lt, ln as ut, m as dt, mn as ft, n as pt, o as mt, on as ht, ot as gt, p as _t, q as vt, qt as yt, r as bt, rn as xt, rt as St, sn as Ct, st as wt, tn as Tt, u as Et, v as Dt, w as Ot, wt as kt, zt as At } from "./cells-B5-y5EY3.js";
|
|
9
|
+
import { D as jt, E as Mt, O as Nt, S as Pt, T as Ft, _ as It, a as Lt, c as Rt, d as zt, f as Bt, g as Vt, h as Ht, i as Ut, l as Wt, m as Gt, n as Kt, o as qt, p as Jt, r as Yt, s as Xt, t as Zt, u as Qt, v as $t, w as en, x as tn, y as nn } from "./spec-CAYwFeV6.js";
|
|
10
|
+
import { $t as rn, A as an, At as on, B as sn, Bt as cn, C as ln, Ct as un, D as dn, Dt as fn, E as pn, Et as mn, F as hn, Ft as gn, G as _n, Gt as vn, H as yn, Ht as bn, I as xn, It as Sn, J as Cn, Jt as wn, K as Tn, Kt as En, L as Dn, Lt as On, M as kn, Mt as An, N as jn, Nt as Mn, O as Nn, Ot as Pn, P as Fn, Pt as In, Qt as Ln, R as Rn, Rt as zn, S as Bn, St as Vn, T as Hn, Tt as Un, U as Wn, Ut as Gn, V as Kn, Vt as qn, W as Jn, Wt as Yn, X as Xn, Xt as Zn, Y as Qn, Yt as $n, Zt as er, _ as tr, _t as nr, an as rr, at as ir, b as ar, c as or, cn as sr, ct as cr, d as lr, dn as ur, dt as dr, en as fr, et as pr, f as mr, fn as hr, ft as gr, g as _r, gt as vr, h as yr, hn as br, ht as xr, in as Sr, it as Cr, j as wr, jt as Tr, k as Er, kt as Dr, ln as Or, lt as kr, m as Ar, mn as jr, mt as Mr, nn as Nr, nt as Pr, ot as Fr, p as Ir, pn as Lr, pt as Rr, q as zr, qt as Br, r as Vr, rn as Hr, rt as Ur, sn as Wr, st as Gr, t as Kr, tn as qr, tt as Jr, u as Yr, un as Xr, ut as Zr, v as Qr, vt as $r, w as ei, wt as ti, x as ni, y as ri, yt as ii, z as ai, zt as oi } from "./common-DnMDPPaW.js";
|
|
11
|
+
import { c as si, i as ci, n as li, o as ui, t as di } from "./useLifecycle-DPgiiwwU.js";
|
|
12
|
+
import { t as fi } from "./check-B7cIK6gb.js";
|
|
13
|
+
import { A as pi, C as mi, D as hi, E as gi, M as _i, O as vi, S as yi, T as bi, a as xi, b as Si, c as Ci, i as wi, k as Ti, l as Ei, n as Di, o as Oi, r as ki, s as Ai, t as ji, w as Mi, x as Ni } from "./select-C6plhmZr.js";
|
|
14
|
+
import { B as Pi, C as Fi, J as Ii, Mt as Li, Nt as Ri, S as zi, Vt as Bi, W as Vi, _ as Hi, a as Ui, at as Wi, c as Gi, dt as Ki, f as qi, fn as Ji, g as Yi, h as Xi, i as Zi, it as Qi, m as $i, n as ea, p as ta, pn as na, q as ra, r as ia, s as aa, t as oa, v as sa, vt as ca, x as la, z as ua } from "./dropdown-menu-CZgjYSAh.js";
|
|
15
|
+
import { C as da, S as fa, T as pa, _ as ma, c as ha, d as ga, f as _a, g as va, h as ya, m as ba, u as xa, x as Sa, y as Ca } from "./toDate-C67bxMWn.js";
|
|
16
|
+
import { a as wa, c as Ta, d as Ea, f as Da, i as Oa, l as ka, n as Aa, o as ja, r as Ma, s as Na, t as Pa } from "./process-output-zDX4jbhd.js";
|
|
17
17
|
import { a as Fa, c as Ia, d as La, i as Ra, l as za, r as Ba, u as Va } from "./glide-utils-B3rUT5PI.js";
|
|
18
|
-
import { n as Ha, t as Ua } from "./ErrorBoundary-
|
|
19
|
-
import { n as Wa, t as Ga } from "./globals-
|
|
18
|
+
import { n as Ha, t as Ua } from "./ErrorBoundary-pV36lYEK.js";
|
|
19
|
+
import { n as Wa, t as Ga } from "./globals-CPNNcOJI.js";
|
|
20
20
|
import { t as Ka } from "./react-dom-BUgJ-ab_.js";
|
|
21
21
|
import { t as qa } from "./jsx-runtime-DgDPJV9S.js";
|
|
22
22
|
import { B as Ja, C as H, Ct as Ya, D as Xa, E as Za, Et as Qa, F as U, G as $a, H as eo, I as to, L as no, M as W, N as ro, O as io, P as ao, Q as oo, R as so, S as G, St as co, Tt as lo, U as uo, W as fo, Y as po, Z as mo, _ as ho, a as go, b as _o, bt as vo, c as yo, d as bo, dt as xo, f as So, g as Co, gt as wo, h as To, i as Eo, j as K, k as Do, l as Oo, m as ko, n as Ao, o as jo, p as Mo, r as No, s as Po, u as Fo, v as Io, vt as Lo, w as Ro, wt as zo, x as Bo, xt as Vo, y as Ho, yt as Uo } from "./use-restore-focus-D5D9xEjZ.js";
|
|
@@ -37,10 +37,10 @@ import { n as ks } from "./dist-BRxfaJgs.js";
|
|
|
37
37
|
import { i as As } from "./dist-C2KzV-vf.js";
|
|
38
38
|
import { n as js, t as Ms } from "./esm-h8f7-1CJ.js";
|
|
39
39
|
import { t as Ns } from "./useAsyncData-BD6AStMt.js";
|
|
40
|
-
import { i as Ps, n as Fs, r as Is } from "./formats-
|
|
40
|
+
import { i as Ps, n as Fs, r as Is } from "./formats-C8rLgZT9.js";
|
|
41
41
|
import { M as Ls, N as Rs } from "./vega-loader.browser-D95WfUcj.js";
|
|
42
42
|
import { a as zs, n as Bs } from "./loader-D2W4oM-3.js";
|
|
43
|
-
import { c as Vs, d as Hs, i as Us, l as Ws, o as Gs, s as Ks, t as qs, u as Js } from "./code-visibility-
|
|
43
|
+
import { c as Vs, d as Hs, i as Us, l as Ws, o as Gs, s as Ks, t as qs, u as Js } from "./code-visibility-CgZS2a3W.js";
|
|
44
44
|
import { t as Ys } from "./useDeepCompareMemoize-D_HNdyvI.js";
|
|
45
45
|
import { t as Xs } from "./esm-BElI3qKH.js";
|
|
46
46
|
//#region ../node_modules/.pnpm/iconify-icon@2.3.0/node_modules/iconify-icon/dist/iconify-icon.mjs
|
|
@@ -1859,8 +1859,8 @@ var { enableCache: tu, disableCache: nu, iconLoaded: ru, iconExists: iu, getIcon
|
|
|
1859
1859
|
d: "M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4",
|
|
1860
1860
|
key: "ih7n3h"
|
|
1861
1861
|
}]
|
|
1862
|
-
]), J = /* @__PURE__ */ e(y(), 1), sd = /* @__PURE__ */ e(Ka(), 1), Y = qa(), cd = "NavigationMenu", [ld, ud, dd] =
|
|
1863
|
-
let { __scopeNavigationMenu: n, value: r, onValueChange: i, defaultValue: a, delayDuration: o = 200, skipDelayDuration: s = 300, orientation: c = "horizontal", dir: l, ...u } = e, [d, f] = J.useState(null), p = h(t, (e) => f(e)), m =
|
|
1862
|
+
]), J = /* @__PURE__ */ e(y(), 1), sd = /* @__PURE__ */ e(Ka(), 1), Y = qa(), cd = "NavigationMenu", [ld, ud, dd] = Ti(cd), [fd, pd, md] = Ti(cd), [hd, gd] = zo(cd, [dd, md]), [_d, vd] = hd(cd), [yd, bd] = hd(cd), xd = J.forwardRef((e, t) => {
|
|
1863
|
+
let { __scopeNavigationMenu: n, value: r, onValueChange: i, defaultValue: a, delayDuration: o = 200, skipDelayDuration: s = 300, orientation: c = "horizontal", dir: l, ...u } = e, [d, f] = J.useState(null), p = h(t, (e) => f(e)), m = vi(l), g = J.useRef(0), _ = J.useRef(0), v = J.useRef(0), [y, b] = J.useState(!0), [x, S] = Vo({
|
|
1864
1864
|
prop: r,
|
|
1865
1865
|
onChange: (e) => {
|
|
1866
1866
|
let t = e !== "", n = s > 0;
|
|
@@ -1944,7 +1944,7 @@ var wd = (e) => {
|
|
|
1944
1944
|
isRootMenu: n,
|
|
1945
1945
|
rootNavigationMenu: r,
|
|
1946
1946
|
value: s,
|
|
1947
|
-
previousValue:
|
|
1947
|
+
previousValue: hi(s),
|
|
1948
1948
|
baseId: Uo(),
|
|
1949
1949
|
dir: i,
|
|
1950
1950
|
orientation: a,
|
|
@@ -2425,7 +2425,7 @@ var sf = xd, cf = Ed, lf = Ad, uf = Md, df = Fd, ff = Ld, pf = Bd, mf = Gd, hf =
|
|
|
2425
2425
|
"ArrowUp",
|
|
2426
2426
|
"ArrowLeft"
|
|
2427
2427
|
]
|
|
2428
|
-
}, vf = "Slider", [yf, bf, xf] =
|
|
2428
|
+
}, vf = "Slider", [yf, bf, xf] = Ti(vf), [Sf, Cf] = zo(vf, [xf]), [wf, Tf] = Sf(vf), Ef = J.forwardRef((e, t) => {
|
|
2429
2429
|
let { name: n, min: r = 0, max: i = 100, step: a = 1, orientation: o = "horizontal", disabled: s = !1, minStepsBetweenThumbs: c = 0, defaultValue: l = [r], value: u, onValueChange: d = () => {}, onValueCommit: f = () => {}, inverted: p = !1, form: m, ...h } = e, g = J.useRef(/* @__PURE__ */ new Set()), _ = J.useRef(0), v = o === "horizontal" ? kf : Af, [y = [], b] = Vo({
|
|
2430
2430
|
prop: u,
|
|
2431
2431
|
defaultProp: l,
|
|
@@ -2444,7 +2444,7 @@ var sf = xd, cf = Ed, lf = Ad, uf = Md, df = Fd, ff = Ld, pf = Bd, mf = Gd, hf =
|
|
|
2444
2444
|
y[_.current] !== e && f(y);
|
|
2445
2445
|
}
|
|
2446
2446
|
function T(e, t, { commit: n } = { commit: !1 }) {
|
|
2447
|
-
let o = Yf(a), s = Xf(Math.round((e - r) / a) * a + r, o), l =
|
|
2447
|
+
let o = Yf(a), s = Xf(Math.round((e - r) / a) * a + r, o), l = gi(s, [r, i]);
|
|
2448
2448
|
b((e = []) => {
|
|
2449
2449
|
let r = Vf(e, l, t);
|
|
2450
2450
|
if (qf(r, c * a)) {
|
|
@@ -2504,7 +2504,7 @@ var [Df, Of] = Sf(vf, {
|
|
|
2504
2504
|
size: "width",
|
|
2505
2505
|
direction: 1
|
|
2506
2506
|
}), kf = J.forwardRef((e, t) => {
|
|
2507
|
-
let { min: n, max: r, dir: i, inverted: a, onSlideStart: o, onSlideMove: s, onSlideEnd: c, onStepKeyDown: l, ...u } = e, [d, f] = J.useState(null), p = h(t, (e) => f(e)), m = J.useRef(void 0), g =
|
|
2507
|
+
let { min: n, max: r, dir: i, inverted: a, onSlideStart: o, onSlideMove: s, onSlideEnd: c, onStepKeyDown: l, ...u } = e, [d, f] = J.useState(null), p = h(t, (e) => f(e)), m = J.useRef(void 0), g = vi(i), _ = g === "ltr", v = _ && !a || !_ && a;
|
|
2508
2508
|
function y(e) {
|
|
2509
2509
|
let t = m.current || d.getBoundingClientRect(), i = Jf([0, t.width], v ? [n, r] : [r, n]);
|
|
2510
2510
|
return m.current = t, i(e - t.left);
|
|
@@ -2676,7 +2676,7 @@ var If = "SliderThumb", Lf = J.forwardRef((e, t) => {
|
|
|
2676
2676
|
});
|
|
2677
2677
|
Lf.displayName = If;
|
|
2678
2678
|
var zf = "RadioBubbleInput", Bf = J.forwardRef(({ __scopeSlider: e, value: t, ...n }, r) => {
|
|
2679
|
-
let i = J.useRef(null), a = h(i, r), o =
|
|
2679
|
+
let i = J.useRef(null), a = h(i, r), o = hi(t);
|
|
2680
2680
|
return J.useEffect(() => {
|
|
2681
2681
|
let e = i.current;
|
|
2682
2682
|
if (!e) return;
|
|
@@ -2699,7 +2699,7 @@ function Vf(e = [], t, n) {
|
|
|
2699
2699
|
}
|
|
2700
2700
|
function Hf(e, t, n) {
|
|
2701
2701
|
let r = 100 / (n - t) * (e - t);
|
|
2702
|
-
return
|
|
2702
|
+
return gi(r, [0, 100]);
|
|
2703
2703
|
}
|
|
2704
2704
|
function Uf(e, t) {
|
|
2705
2705
|
if (t > 2) return `Value ${e + 1} of ${t}`;
|
|
@@ -2762,15 +2762,15 @@ var rp = np;
|
|
|
2762
2762
|
//#endregion
|
|
2763
2763
|
//#region ../node_modules/.pnpm/@react-aria+button@3.14.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@react-aria/button/dist/useToggleButton.mjs
|
|
2764
2764
|
function ip(e, t, n) {
|
|
2765
|
-
let { isSelected: r } = t, { isPressed: i, buttonProps: a } =
|
|
2765
|
+
let { isSelected: r } = t, { isPressed: i, buttonProps: a } = Wi({
|
|
2766
2766
|
...e,
|
|
2767
|
-
onPress:
|
|
2767
|
+
onPress: Bi(t.toggle, e.onPress)
|
|
2768
2768
|
}, n);
|
|
2769
2769
|
return {
|
|
2770
2770
|
isPressed: i,
|
|
2771
2771
|
isSelected: r,
|
|
2772
2772
|
isDisabled: e.isDisabled || !1,
|
|
2773
|
-
buttonProps:
|
|
2773
|
+
buttonProps: Ri(a, { "aria-pressed": r })
|
|
2774
2774
|
};
|
|
2775
2775
|
}
|
|
2776
2776
|
//#endregion
|
|
@@ -2800,7 +2800,7 @@ function ap(e, t, n) {
|
|
|
2800
2800
|
//#endregion
|
|
2801
2801
|
//#region ../node_modules/.pnpm/@react-stately+toggle@3.9.5_react@19.2.8/node_modules/@react-stately/toggle/dist/useToggleState.mjs
|
|
2802
2802
|
function op(e = {}) {
|
|
2803
|
-
let { isReadOnly: t } = e, [n, r] =
|
|
2803
|
+
let { isReadOnly: t } = e, [n, r] = ca(e.isSelected, e.defaultSelected || !1, e.onChange), [i] = (0, J.useState)(n);
|
|
2804
2804
|
function a(e) {
|
|
2805
2805
|
t || r(e);
|
|
2806
2806
|
}
|
|
@@ -2848,7 +2848,7 @@ function fp(e) {
|
|
|
2848
2848
|
}
|
|
2849
2849
|
//#endregion
|
|
2850
2850
|
//#region ../node_modules/.pnpm/react-hook-form@7.54.2_react@19.2.8/node_modules/react-hook-form/dist/index.esm.mjs
|
|
2851
|
-
var X = b(), pp = /* @__PURE__ */ e(
|
|
2851
|
+
var X = b(), pp = /* @__PURE__ */ e(at(), 1), mp = ya(), hp = (e) => e.type === "checkbox", gp = (e) => e instanceof Date, _p = (e) => e == null, vp = (e) => typeof e == "object", yp = (e) => !_p(e) && !Array.isArray(e) && vp(e) && !gp(e), bp = (e) => yp(e) && e.target ? hp(e.target) ? e.target.checked : e.target.value : e, xp = (e) => e.substring(0, e.search(/\.\d+(\.|$)/)) || e, Sp = (e, t) => e.has(xp(t)), Cp = (e) => {
|
|
2852
2852
|
let t = e.constructor && e.constructor.prototype;
|
|
2853
2853
|
return yp(t) && t.hasOwnProperty("isPrototypeOf");
|
|
2854
2854
|
}, wp = typeof window < "u" && window.HTMLElement !== void 0 && typeof document < "u";
|
|
@@ -4266,7 +4266,7 @@ var wh = (e) => {
|
|
|
4266
4266
|
let a;
|
|
4267
4267
|
t[0] === n ? a = t[1] : (a = l("stroke-[1.8px]", n), t[0] = n, t[1] = a);
|
|
4268
4268
|
let o;
|
|
4269
|
-
t[2] === a ? o = t[3] : (o = /* @__PURE__ */ (0, Y.jsx)(
|
|
4269
|
+
t[2] === a ? o = t[3] : (o = /* @__PURE__ */ (0, Y.jsx)(ft, { className: a }), t[2] = a, t[3] = o);
|
|
4270
4270
|
let s;
|
|
4271
4271
|
return t[4] !== i || t[5] !== o ? (s = /* @__PURE__ */ (0, Y.jsx)(me, {
|
|
4272
4272
|
content: i,
|
|
@@ -4277,7 +4277,7 @@ wh.displayName = "FormMessageTooltip";
|
|
|
4277
4277
|
//#endregion
|
|
4278
4278
|
//#region ../node_modules/.pnpm/react-aria-components@1.16.0_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/react-aria-components/dist/SelectionIndicator.mjs
|
|
4279
4279
|
var Th = /*#__PURE__*/ (0, J.createContext)({ isSelected: !1 }), Eh = /*#__PURE__*/ (0, J.createContext)(null), Dh = /*#__PURE__*/ (0, J.createContext)({}), Oh = /*#__PURE__*/ (0, J.forwardRef)(function(e, t) {
|
|
4280
|
-
[e, t] =
|
|
4280
|
+
[e, t] = ua(e, t, Dh);
|
|
4281
4281
|
let n = (0, J.useContext)(Eh), r = op(n && e.id != null ? {
|
|
4282
4282
|
isSelected: n.selectedKeys.has(e.id),
|
|
4283
4283
|
onChange(t) {
|
|
@@ -4289,10 +4289,10 @@ var Th = /*#__PURE__*/ (0, J.createContext)({ isSelected: !1 }), Eh = /*#__PURE_
|
|
|
4289
4289
|
}, n, t) : ip({
|
|
4290
4290
|
...e,
|
|
4291
4291
|
id: e.id == null ? void 0 : String(e.id)
|
|
4292
|
-
}, r, t), { focusProps: c, isFocused: l, isFocusVisible: u } =
|
|
4292
|
+
}, r, t), { focusProps: c, isFocused: l, isFocusVisible: u } = Qi(e), { hoverProps: d, isHovered: f } = Ki({
|
|
4293
4293
|
...e,
|
|
4294
4294
|
isDisabled: s
|
|
4295
|
-
}), p =
|
|
4295
|
+
}), p = Pi({
|
|
4296
4296
|
...e,
|
|
4297
4297
|
id: void 0,
|
|
4298
4298
|
values: {
|
|
@@ -4305,9 +4305,9 @@ var Th = /*#__PURE__*/ (0, J.createContext)({ isSelected: !1 }), Eh = /*#__PURE_
|
|
|
4305
4305
|
state: r
|
|
4306
4306
|
},
|
|
4307
4307
|
defaultClassName: "react-aria-ToggleButton"
|
|
4308
|
-
}), m =
|
|
4309
|
-
return delete m.id, delete m.onClick, /*#__PURE__*/ J.createElement(
|
|
4310
|
-
...
|
|
4308
|
+
}), m = Li(e, { global: !0 });
|
|
4309
|
+
return delete m.id, delete m.onClick, /*#__PURE__*/ J.createElement(Vi.button, {
|
|
4310
|
+
...Ri(m, p, i, c, d),
|
|
4311
4311
|
ref: t,
|
|
4312
4312
|
slot: e.slot || void 0,
|
|
4313
4313
|
"data-focused": l || void 0,
|
|
@@ -4352,7 +4352,7 @@ var Ah = J.forwardRef((e, t) => {
|
|
|
4352
4352
|
delay: a.delay,
|
|
4353
4353
|
onChange: i
|
|
4354
4354
|
}, n[4] = i, n[5] = a.delay, n[6] = a.value, n[7] = o) : o = n[7];
|
|
4355
|
-
let { value: s, onChange: c } =
|
|
4355
|
+
let { value: s, onChange: c } = ra(o), l;
|
|
4356
4356
|
n[8] === c ? l = n[9] : (l = (e) => c(e.target.value), n[8] = c, n[9] = l);
|
|
4357
4357
|
let u;
|
|
4358
4358
|
return n[10] !== r || n[11] !== a || n[12] !== t || n[13] !== l || n[14] !== s ? (u = /* @__PURE__ */ (0, Y.jsx)(kh, {
|
|
@@ -4476,7 +4476,7 @@ var Rh = "\n", zh = (e) => {
|
|
|
4476
4476
|
className: s,
|
|
4477
4477
|
onChange: i,
|
|
4478
4478
|
placeholder: o ? `${o}: one per line` : "One value per line"
|
|
4479
|
-
}) : /* @__PURE__ */ (0, Y.jsx)(
|
|
4479
|
+
}) : /* @__PURE__ */ (0, Y.jsx)(vn, {
|
|
4480
4480
|
placeholder: o,
|
|
4481
4481
|
displayValue: Hh,
|
|
4482
4482
|
className: l("w-full max-w-[400px]", c),
|
|
@@ -4541,7 +4541,7 @@ function Hh(e) {
|
|
|
4541
4541
|
return e;
|
|
4542
4542
|
}
|
|
4543
4543
|
function Uh(e) {
|
|
4544
|
-
return /* @__PURE__ */ (0, Y.jsx)(
|
|
4544
|
+
return /* @__PURE__ */ (0, Y.jsx)(En, {
|
|
4545
4545
|
value: e,
|
|
4546
4546
|
children: e
|
|
4547
4547
|
}, e);
|
|
@@ -4611,7 +4611,7 @@ function Kh({ schema: e, form: t, path: n, renderers: r }) {
|
|
|
4611
4611
|
render: ({ field: e }) => /* @__PURE__ */ (0, Y.jsxs)(yh, { children: [
|
|
4612
4612
|
/* @__PURE__ */ (0, Y.jsx)(bh, { children: i }),
|
|
4613
4613
|
/* @__PURE__ */ (0, Y.jsx)(Sh, { children: a }),
|
|
4614
|
-
/* @__PURE__ */ (0, Y.jsx)(xh, { children: /* @__PURE__ */ (0, Y.jsx)(
|
|
4614
|
+
/* @__PURE__ */ (0, Y.jsx)(xh, { children: /* @__PURE__ */ (0, Y.jsx)(ta, {
|
|
4615
4615
|
...e,
|
|
4616
4616
|
onValueChange: e.onChange,
|
|
4617
4617
|
type: "time",
|
|
@@ -4629,7 +4629,7 @@ function Kh({ schema: e, form: t, path: n, renderers: r }) {
|
|
|
4629
4629
|
name: n,
|
|
4630
4630
|
render: ({ field: e }) => /* @__PURE__ */ (0, Y.jsxs)(yh, { children: [/* @__PURE__ */ (0, Y.jsxs)("div", {
|
|
4631
4631
|
className: l("flex flex-row gap-2", a ? "items-start" : "items-center"),
|
|
4632
|
-
children: [/* @__PURE__ */ (0, Y.jsx)(xh, { children: /* @__PURE__ */ (0, Y.jsx)(
|
|
4632
|
+
children: [/* @__PURE__ */ (0, Y.jsx)(xh, { children: /* @__PURE__ */ (0, Y.jsx)(Me, {
|
|
4633
4633
|
"data-testid": "marimo-plugin-data-frames-boolean-checkbox",
|
|
4634
4634
|
checked: e.value,
|
|
4635
4635
|
onCheckedChange: e.onChange,
|
|
@@ -4658,7 +4658,7 @@ function Kh({ schema: e, form: t, path: n, renderers: r }) {
|
|
|
4658
4658
|
render: ({ field: e }) => /* @__PURE__ */ (0, Y.jsxs)(yh, { children: [
|
|
4659
4659
|
/* @__PURE__ */ (0, Y.jsx)(bh, { children: i }),
|
|
4660
4660
|
/* @__PURE__ */ (0, Y.jsx)(Sh, { children: a }),
|
|
4661
|
-
/* @__PURE__ */ (0, Y.jsx)(xh, { children: /* @__PURE__ */ (0, Y.jsx)(
|
|
4661
|
+
/* @__PURE__ */ (0, Y.jsx)(xh, { children: /* @__PURE__ */ (0, Y.jsx)($i, {
|
|
4662
4662
|
...e,
|
|
4663
4663
|
className: "my-0",
|
|
4664
4664
|
onValueChange: e.onChange
|
|
@@ -4674,7 +4674,7 @@ function Kh({ schema: e, form: t, path: n, renderers: r }) {
|
|
|
4674
4674
|
render: ({ field: t }) => /* @__PURE__ */ (0, Y.jsxs)(yh, { children: [
|
|
4675
4675
|
/* @__PURE__ */ (0, Y.jsx)(bh, { children: i }),
|
|
4676
4676
|
/* @__PURE__ */ (0, Y.jsx)(Sh, { children: a }),
|
|
4677
|
-
/* @__PURE__ */ (0, Y.jsx)(xh, { children: /* @__PURE__ */ (0, Y.jsx)(
|
|
4677
|
+
/* @__PURE__ */ (0, Y.jsx)(xh, { children: /* @__PURE__ */ (0, Y.jsx)(ta, {
|
|
4678
4678
|
...t,
|
|
4679
4679
|
onValueChange: t.onChange,
|
|
4680
4680
|
type: e,
|
|
@@ -4777,7 +4777,7 @@ function Kh({ schema: e, form: t, path: n, renderers: r }) {
|
|
|
4777
4777
|
className: "flex flex-col mb-4 gap-1",
|
|
4778
4778
|
children: [
|
|
4779
4779
|
/* @__PURE__ */ (0, Y.jsx)(bh, { children: i }),
|
|
4780
|
-
/* @__PURE__ */ (0, Y.jsx)(
|
|
4780
|
+
/* @__PURE__ */ (0, Y.jsx)(Ei, {
|
|
4781
4781
|
"data-testid": "marimo-plugin-data-frames-union-select",
|
|
4782
4782
|
...a,
|
|
4783
4783
|
children: c.map((e) => /* @__PURE__ */ (0, Y.jsx)("option", {
|
|
@@ -4919,7 +4919,7 @@ var qh = (e) => {
|
|
|
4919
4919
|
return /* @__PURE__ */ (0, Y.jsxs)(yh, { children: [
|
|
4920
4920
|
/* @__PURE__ */ (0, Y.jsx)(bh, { children: o }),
|
|
4921
4921
|
/* @__PURE__ */ (0, Y.jsx)(Sh, { children: s }),
|
|
4922
|
-
/* @__PURE__ */ (0, Y.jsx)(xh, { children: /* @__PURE__ */ (0, Y.jsx)(
|
|
4922
|
+
/* @__PURE__ */ (0, Y.jsx)(xh, { children: /* @__PURE__ */ (0, Y.jsx)(ta, {
|
|
4923
4923
|
...t,
|
|
4924
4924
|
type: u,
|
|
4925
4925
|
value: t.value,
|
|
@@ -4970,19 +4970,19 @@ var qh = (e) => {
|
|
|
4970
4970
|
return /* @__PURE__ */ (0, Y.jsxs)(yh, { children: [
|
|
4971
4971
|
/* @__PURE__ */ (0, Y.jsx)(bh, { children: c }),
|
|
4972
4972
|
/* @__PURE__ */ (0, Y.jsx)(Sh, { children: l }),
|
|
4973
|
-
/* @__PURE__ */ (0, Y.jsx)(xh, { children: /* @__PURE__ */ (0, Y.jsx)(
|
|
4973
|
+
/* @__PURE__ */ (0, Y.jsx)(xh, { children: /* @__PURE__ */ (0, Y.jsx)(Gn, {
|
|
4974
4974
|
className: "flex flex-row gap-2 pt-1 items-center",
|
|
4975
4975
|
value: t.value,
|
|
4976
4976
|
onValueChange: t.onChange,
|
|
4977
4977
|
children: a.map((e) => /* @__PURE__ */ (0, Y.jsxs)("div", {
|
|
4978
4978
|
className: "flex items-center gap-1",
|
|
4979
|
-
children: [/* @__PURE__ */ (0, Y.jsx)(
|
|
4979
|
+
children: [/* @__PURE__ */ (0, Y.jsx)(Yn, {
|
|
4980
4980
|
value: e,
|
|
4981
4981
|
id: `${i}-${e}`
|
|
4982
4982
|
}, e), /* @__PURE__ */ (0, Y.jsx)(bh, {
|
|
4983
4983
|
className: "whitespace-pre",
|
|
4984
4984
|
htmlFor: `${i}-${e}`,
|
|
4985
|
-
children:
|
|
4985
|
+
children: Si.startCase(e)
|
|
4986
4986
|
})]
|
|
4987
4987
|
}, e))
|
|
4988
4988
|
}) }),
|
|
@@ -5006,17 +5006,17 @@ var qh = (e) => {
|
|
|
5006
5006
|
children: c
|
|
5007
5007
|
}),
|
|
5008
5008
|
/* @__PURE__ */ (0, Y.jsx)(Sh, { children: l }),
|
|
5009
|
-
/* @__PURE__ */ (0, Y.jsx)(xh, { children: /* @__PURE__ */ (0, Y.jsxs)(
|
|
5009
|
+
/* @__PURE__ */ (0, Y.jsx)(xh, { children: /* @__PURE__ */ (0, Y.jsxs)(ji, {
|
|
5010
5010
|
"data-testid": "marimo-plugin-data-frames-select",
|
|
5011
5011
|
value: t.value,
|
|
5012
5012
|
onValueChange: t.onChange,
|
|
5013
|
-
children: [/* @__PURE__ */ (0, Y.jsx)(
|
|
5013
|
+
children: [/* @__PURE__ */ (0, Y.jsx)(Ai, {
|
|
5014
5014
|
className: "min-w-[180px]",
|
|
5015
|
-
children: /* @__PURE__ */ (0, Y.jsx)(
|
|
5016
|
-
}), /* @__PURE__ */ (0, Y.jsx)(
|
|
5015
|
+
children: /* @__PURE__ */ (0, Y.jsx)(Ci, { placeholder: "--" })
|
|
5016
|
+
}), /* @__PURE__ */ (0, Y.jsx)(Di, { children: /* @__PURE__ */ (0, Y.jsxs)(ki, { children: [a.map((e) => /* @__PURE__ */ (0, Y.jsx)(wi, {
|
|
5017
5017
|
value: e,
|
|
5018
5018
|
children: o?.(e) ?? e
|
|
5019
|
-
}, e)), a.length === 0 && /* @__PURE__ */ (0, Y.jsx)(
|
|
5019
|
+
}, e)), a.length === 0 && /* @__PURE__ */ (0, Y.jsx)(wi, {
|
|
5020
5020
|
disabled: !0,
|
|
5021
5021
|
value: "--",
|
|
5022
5022
|
children: "No options"
|
|
@@ -5051,7 +5051,7 @@ var qh = (e) => {
|
|
|
5051
5051
|
value: n,
|
|
5052
5052
|
options: a,
|
|
5053
5053
|
placeholder: p
|
|
5054
|
-
}) : /* @__PURE__ */ (0, Y.jsx)(
|
|
5054
|
+
}) : /* @__PURE__ */ (0, Y.jsx)(vn, {
|
|
5055
5055
|
className: "min-w-[180px]",
|
|
5056
5056
|
placeholder: p,
|
|
5057
5057
|
displayValue: eg,
|
|
@@ -5079,10 +5079,10 @@ function $h(e) {
|
|
|
5079
5079
|
return e.preventDefault();
|
|
5080
5080
|
}
|
|
5081
5081
|
function eg(e) {
|
|
5082
|
-
return
|
|
5082
|
+
return Si.startCase(e);
|
|
5083
5083
|
}
|
|
5084
5084
|
function tg(e) {
|
|
5085
|
-
return /* @__PURE__ */ (0, Y.jsx)(
|
|
5085
|
+
return /* @__PURE__ */ (0, Y.jsx)(En, {
|
|
5086
5086
|
value: e,
|
|
5087
5087
|
children: e
|
|
5088
5088
|
}, e);
|
|
@@ -5249,18 +5249,18 @@ function ug(e) {
|
|
|
5249
5249
|
return typeof e == "function";
|
|
5250
5250
|
}
|
|
5251
5251
|
function dg(e) {
|
|
5252
|
-
return
|
|
5252
|
+
return Ge(e) && (lg(e.render) || ug(e.initialize));
|
|
5253
5253
|
}
|
|
5254
5254
|
function fg(e) {
|
|
5255
5255
|
return typeof e == "function" || dg(e);
|
|
5256
5256
|
}
|
|
5257
5257
|
function pg(e) {
|
|
5258
|
-
return
|
|
5258
|
+
return Ge(e) && fg(e.default);
|
|
5259
5259
|
}
|
|
5260
5260
|
var mg = /* @__PURE__ */ new Set(), hg = /* @__PURE__ */ new WeakMap();
|
|
5261
5261
|
function gg(e, t) {
|
|
5262
5262
|
if (pg(e)) return e.default;
|
|
5263
|
-
if (!
|
|
5263
|
+
if (!Ge(e) || e.default !== void 0) return null;
|
|
5264
5264
|
let n = lg(e.render) ? e.render : void 0, r = ug(e.initialize) ? e.initialize : void 0;
|
|
5265
5265
|
if (n === void 0 && r === void 0) return null;
|
|
5266
5266
|
let i = hg.get(e);
|
|
@@ -5273,8 +5273,8 @@ function gg(e, t) {
|
|
|
5273
5273
|
return hg.set(e, a), a;
|
|
5274
5274
|
}
|
|
5275
5275
|
function _g(e, t) {
|
|
5276
|
-
let n = "https://anywidget.dev/en/afm/", r =
|
|
5277
|
-
if (
|
|
5276
|
+
let n = "https://anywidget.dev/en/afm/", r = Ge(e) && We(e, "render"), i = Ge(e) && We(e, "initialize");
|
|
5277
|
+
if (Ge(e) && e.default !== void 0) return /* @__PURE__ */ Error(`Anywidget module at ${t} has an invalid default export. Expected a factory function or an object with \`render\` or \`initialize\`. See ${n}`);
|
|
5278
5278
|
if (r || i) {
|
|
5279
5279
|
let e = [r ? "`render`" : null, i ? "`initialize`" : null].filter(Boolean).join(" and "), a = [r ? "render" : null, i ? "initialize" : null].filter((e) => e !== null), o = `export default { ${a.join(", ")} }`, s = a.length === 1 ? `export function ${a[0]}` : "named export function ...";
|
|
5280
5280
|
return /* @__PURE__ */ Error(`Anywidget module at ${t} uses named exports (${e}). Per the AFM spec, use a default export instead: \`${o}\` (not \`${s}\`). See ${n}`);
|
|
@@ -5286,7 +5286,7 @@ function _g(e, t) {
|
|
|
5286
5286
|
function vg(e) {
|
|
5287
5287
|
return e.startsWith(".") ? e.slice(1) : e;
|
|
5288
5288
|
}
|
|
5289
|
-
function yg(e, t =
|
|
5289
|
+
function yg(e, t = xa()) {
|
|
5290
5290
|
let n = bg(e, t);
|
|
5291
5291
|
if (!n) return e;
|
|
5292
5292
|
let r = ka(n);
|
|
@@ -5343,8 +5343,8 @@ var Dg = class {
|
|
|
5343
5343
|
}
|
|
5344
5344
|
async #t(e, t = {}) {
|
|
5345
5345
|
if (!(Sg(e) || t.kernelAuthored === !0 && /^(https?:|data:)/.test(e))) throw Error(`Refusing to load anywidget module from untrusted URL: ${String(e)}`);
|
|
5346
|
-
let n =
|
|
5347
|
-
return
|
|
5346
|
+
let n = ha(e).toString();
|
|
5347
|
+
return ga() && (n = yg(n)), import(
|
|
5348
5348
|
/* @vite-ignore */
|
|
5349
5349
|
n
|
|
5350
5350
|
);
|
|
@@ -5451,7 +5451,7 @@ var Ag = class e {
|
|
|
5451
5451
|
#r;
|
|
5452
5452
|
#i;
|
|
5453
5453
|
#a = new AbortController();
|
|
5454
|
-
#o = new
|
|
5454
|
+
#o = new fa();
|
|
5455
5455
|
#s = /* @__PURE__ */ new Set();
|
|
5456
5456
|
#c = /* @__PURE__ */ new Map();
|
|
5457
5457
|
#l;
|
|
@@ -5691,7 +5691,7 @@ function Rg(e) {
|
|
|
5691
5691
|
//#endregion
|
|
5692
5692
|
//#region src/plugins/impl/anywidget/registry.ts
|
|
5693
5693
|
function zg() {
|
|
5694
|
-
let e = os.get(
|
|
5694
|
+
let e = os.get(Sa).mode;
|
|
5695
5695
|
return e === "edit" || e === "present";
|
|
5696
5696
|
}
|
|
5697
5697
|
var Bg = new class {
|
|
@@ -5761,7 +5761,7 @@ async function Vg(e, t) {
|
|
|
5761
5761
|
return;
|
|
5762
5762
|
}
|
|
5763
5763
|
e.createModel(n, (e) => {
|
|
5764
|
-
let t =
|
|
5764
|
+
let t = ga() ? {
|
|
5765
5765
|
sendUpdate: async () => void 0,
|
|
5766
5766
|
sendCustomMessage: async () => void 0
|
|
5767
5767
|
} : {
|
|
@@ -5771,7 +5771,7 @@ async function Vg(e, t) {
|
|
|
5771
5771
|
return;
|
|
5772
5772
|
}
|
|
5773
5773
|
let { state: r, buffers: i, bufferPaths: a } = Lg(t);
|
|
5774
|
-
await
|
|
5774
|
+
await Ve().sendModelValue({
|
|
5775
5775
|
modelId: n,
|
|
5776
5776
|
message: {
|
|
5777
5777
|
method: "update",
|
|
@@ -5786,7 +5786,7 @@ async function Vg(e, t) {
|
|
|
5786
5786
|
c.debug(`[Model] sendCustomMessage suppressed for model=${n} (signal aborted)`);
|
|
5787
5787
|
return;
|
|
5788
5788
|
}
|
|
5789
|
-
await
|
|
5789
|
+
await Ve().sendModelValue({
|
|
5790
5790
|
modelId: n,
|
|
5791
5791
|
message: {
|
|
5792
5792
|
method: "custom",
|
|
@@ -5820,10 +5820,10 @@ async function Vg(e, t) {
|
|
|
5820
5820
|
sg(await e.getModel(n)).updateAndEmitDiffs(o);
|
|
5821
5821
|
return;
|
|
5822
5822
|
}
|
|
5823
|
-
default:
|
|
5823
|
+
default: yi(r);
|
|
5824
5824
|
}
|
|
5825
5825
|
}
|
|
5826
|
-
|
|
5826
|
+
gt(Bg, "WIDGET_REGISTRY");
|
|
5827
5827
|
//#endregion
|
|
5828
5828
|
//#region src/components/ui/navigation.tsx
|
|
5829
5829
|
var Hg = J.forwardRef((e, t) => {
|
|
@@ -6156,7 +6156,7 @@ function l_(e) {
|
|
|
6156
6156
|
}
|
|
6157
6157
|
function u_(e) {
|
|
6158
6158
|
let t = new URL(globalThis.location.href);
|
|
6159
|
-
return
|
|
6159
|
+
return _a({
|
|
6160
6160
|
href: e,
|
|
6161
6161
|
queryParams: t.search,
|
|
6162
6162
|
keys: [ss.filePath]
|
|
@@ -6190,7 +6190,7 @@ var f_ = class e {
|
|
|
6190
6190
|
let n = this.entries.get(e);
|
|
6191
6191
|
n === void 0 ? this.entries.set(e, {
|
|
6192
6192
|
objectId: e,
|
|
6193
|
-
value:
|
|
6193
|
+
value: ve(t, this),
|
|
6194
6194
|
elements: /* @__PURE__ */ new Set([t])
|
|
6195
6195
|
}) : n.elements.add(t);
|
|
6196
6196
|
}
|
|
@@ -6255,14 +6255,14 @@ var f_ = class e {
|
|
|
6255
6255
|
detail: { objectId: t }
|
|
6256
6256
|
})));
|
|
6257
6257
|
}
|
|
6258
|
-
}, p_ = f_.INSTANCE, m_ = new
|
|
6259
|
-
await
|
|
6258
|
+
}, p_ = f_.INSTANCE, m_ = new Le("function-call-result", async (e, t) => {
|
|
6259
|
+
await Ve().sendFunctionRequest({
|
|
6260
6260
|
functionCallId: e,
|
|
6261
6261
|
...t
|
|
6262
6262
|
});
|
|
6263
6263
|
}), h_ = (e) => {
|
|
6264
6264
|
let t = (0, X.c)(5), { children: n } = e, r = rs(hs), i;
|
|
6265
|
-
t[0] === r ? i = t[1] : (i =
|
|
6265
|
+
t[0] === r ? i = t[1] : (i = bn(r), t[0] = r, t[1] = i);
|
|
6266
6266
|
let a;
|
|
6267
6267
|
return t[2] !== n || t[3] !== i ? (a = /* @__PURE__ */ (0, Y.jsx)(Yo, {
|
|
6268
6268
|
locale: i,
|
|
@@ -6295,7 +6295,7 @@ function v_(e, t) {
|
|
|
6295
6295
|
function y_(e, t) {
|
|
6296
6296
|
if (!t) return [];
|
|
6297
6297
|
let n = e;
|
|
6298
|
-
if (
|
|
6298
|
+
if (Un(t)) return [{
|
|
6299
6299
|
column_id: n,
|
|
6300
6300
|
operator: t.operator,
|
|
6301
6301
|
type: "condition",
|
|
@@ -6333,7 +6333,7 @@ function y_(e, t) {
|
|
|
6333
6333
|
type: "condition",
|
|
6334
6334
|
negate: !1
|
|
6335
6335
|
}];
|
|
6336
|
-
default:
|
|
6336
|
+
default: yi(t);
|
|
6337
6337
|
}
|
|
6338
6338
|
case "text": switch (t.operator) {
|
|
6339
6339
|
case "contains":
|
|
@@ -6362,12 +6362,12 @@ function y_(e, t) {
|
|
|
6362
6362
|
type: "condition",
|
|
6363
6363
|
negate: !1
|
|
6364
6364
|
}];
|
|
6365
|
-
default:
|
|
6365
|
+
default: yi(t);
|
|
6366
6366
|
}
|
|
6367
6367
|
case "date":
|
|
6368
6368
|
case "datetime":
|
|
6369
6369
|
case "time": {
|
|
6370
|
-
let e = t.type === "date" ?
|
|
6370
|
+
let e = t.type === "date" ? fn : t.type === "time" ? Dr : Pn;
|
|
6371
6371
|
switch (t.operator) {
|
|
6372
6372
|
case "between": return [{
|
|
6373
6373
|
column_id: n,
|
|
@@ -6391,7 +6391,7 @@ function y_(e, t) {
|
|
|
6391
6391
|
type: "condition",
|
|
6392
6392
|
negate: !1
|
|
6393
6393
|
}];
|
|
6394
|
-
default:
|
|
6394
|
+
default: yi(t);
|
|
6395
6395
|
}
|
|
6396
6396
|
}
|
|
6397
6397
|
case "boolean": return [{
|
|
@@ -6400,7 +6400,7 @@ function y_(e, t) {
|
|
|
6400
6400
|
type: "condition",
|
|
6401
6401
|
negate: !1
|
|
6402
6402
|
}];
|
|
6403
|
-
default:
|
|
6403
|
+
default: yi(t);
|
|
6404
6404
|
}
|
|
6405
6405
|
}
|
|
6406
6406
|
function b_(e) {
|
|
@@ -9010,7 +9010,7 @@ function Gx(e) {
|
|
|
9010
9010
|
let t = (0, X.c)(9), { option: n, checked: r, renderOption: i } = e, a = r || void 0, o = n.value, s;
|
|
9011
9011
|
t[0] !== r || t[1] !== n || t[2] !== i ? (s = i ? i(n, { checked: r }) : n.label, t[0] = r, t[1] = n, t[2] = i, t[3] = s) : s = t[3];
|
|
9012
9012
|
let c;
|
|
9013
|
-
return t[4] !== n.disabled || t[5] !== a || t[6] !== o || t[7] !== s ? (c = /* @__PURE__ */ (0, Y.jsx)(
|
|
9013
|
+
return t[4] !== n.disabled || t[5] !== a || t[6] !== o || t[7] !== s ? (c = /* @__PURE__ */ (0, Y.jsx)(En, {
|
|
9014
9014
|
"data-slot": "select-option",
|
|
9015
9015
|
"data-checked": a,
|
|
9016
9016
|
value: o,
|
|
@@ -9043,7 +9043,7 @@ function Yx(e) {
|
|
|
9043
9043
|
allowSelectNone: s,
|
|
9044
9044
|
pinSelected: b
|
|
9045
9045
|
}, t[0] = s, t[1] = o, t[2] = a, t[3] = i, t[4] = n, t[5] = b, t[6] = r, t[7] = O) : O = t[7];
|
|
9046
|
-
let k =
|
|
9046
|
+
let k = Wn(O), A;
|
|
9047
9047
|
t[8] !== s || t[9] !== o || t[10] !== a || t[11] !== i ? (A = (e) => {
|
|
9048
9048
|
if (!a) {
|
|
9049
9049
|
if (e == null && !s) return;
|
|
@@ -9057,12 +9057,12 @@ function Yx(e) {
|
|
|
9057
9057
|
if (t[13] !== k.bulkActions) {
|
|
9058
9058
|
if (M = k.bulkActions.map(Xx), M.length > 0) {
|
|
9059
9059
|
let e;
|
|
9060
|
-
t[15] === Symbol.for("react.memo_cache_sentinel") ? (e = /* @__PURE__ */ (0, Y.jsx)(
|
|
9060
|
+
t[15] === Symbol.for("react.memo_cache_sentinel") ? (e = /* @__PURE__ */ (0, Y.jsx)(Ln, { "data-slot": "select-separator" }, "_bulk_separator"), t[15] = e) : e = t[15], M.push(e);
|
|
9061
9061
|
}
|
|
9062
9062
|
t[13] = k.bulkActions, t[14] = M;
|
|
9063
9063
|
} else M = t[14];
|
|
9064
9064
|
let N;
|
|
9065
|
-
t[16] !== k.pinnedCount || t[17] !== k.visibleOptions.length ? (N = (e) => k.pinnedCount > 0 && e === k.pinnedCount && k.pinnedCount < k.visibleOptions.length ? /* @__PURE__ */ (0, Y.jsx)(
|
|
9065
|
+
t[16] !== k.pinnedCount || t[17] !== k.visibleOptions.length ? (N = (e) => k.pinnedCount > 0 && e === k.pinnedCount && k.pinnedCount < k.visibleOptions.length ? /* @__PURE__ */ (0, Y.jsx)(Ln, { "data-slot": "select-separator" }, "_pinned_separator") : null, t[16] = k.pinnedCount, t[17] = k.visibleOptions.length, t[18] = N) : N = t[18];
|
|
9066
9066
|
let P = N, F;
|
|
9067
9067
|
t[19] !== M || t[20] !== k || t[21] !== P || t[22] !== g || t[23] !== E || t[24] !== D ? (F = () => {
|
|
9068
9068
|
if (k.visibleOptions.length > E) return /* @__PURE__ */ (0, Y.jsx)(tx, {
|
|
@@ -9099,7 +9099,7 @@ function Yx(e) {
|
|
|
9099
9099
|
return t.length === 0 ? /* @__PURE__ */ (0, Y.jsx)("span", {
|
|
9100
9100
|
className: "text-muted-foreground",
|
|
9101
9101
|
children: S
|
|
9102
|
-
}) : /* @__PURE__ */ (0, Y.jsx)(
|
|
9102
|
+
}) : /* @__PURE__ */ (0, Y.jsx)(Jn, {
|
|
9103
9103
|
items: t.map(k.labelOf),
|
|
9104
9104
|
max: 3
|
|
9105
9105
|
});
|
|
@@ -9128,13 +9128,13 @@ function Yx(e) {
|
|
|
9128
9128
|
id: h
|
|
9129
9129
|
}, t[36] = C, t[37] = h, t[38] = k.open, t[39] = k.searchQuery, t[40] = k.setOpen, t[41] = k.setSearchQuery, t[42] = S, t[43] = ee, t[44] = z, t[45] = te, t[46] = B, t[47] = oe, t[48] = se) : se = t[48];
|
|
9130
9130
|
let ce = se, V;
|
|
9131
|
-
return t[49] !== ce || t[50] !== j || t[51] !== a || t[52] !== I || t[53] !== r ? (V = a ? /* @__PURE__ */ (0, Y.jsx)(
|
|
9131
|
+
return t[49] !== ce || t[50] !== j || t[51] !== a || t[52] !== I || t[53] !== r ? (V = a ? /* @__PURE__ */ (0, Y.jsx)(vn, {
|
|
9132
9132
|
...ce,
|
|
9133
9133
|
multiple: !0,
|
|
9134
9134
|
value: r,
|
|
9135
9135
|
onValueChange: j,
|
|
9136
9136
|
children: I()
|
|
9137
|
-
}) : /* @__PURE__ */ (0, Y.jsx)(
|
|
9137
|
+
}) : /* @__PURE__ */ (0, Y.jsx)(vn, {
|
|
9138
9138
|
...ce,
|
|
9139
9139
|
multiple: !1,
|
|
9140
9140
|
value: r,
|
|
@@ -9144,7 +9144,7 @@ function Yx(e) {
|
|
|
9144
9144
|
}
|
|
9145
9145
|
function Xx(e) {
|
|
9146
9146
|
let t = "enabled" in e ? !e.enabled : e.items.length === 0;
|
|
9147
|
-
return /* @__PURE__ */ (0, Y.jsx)(
|
|
9147
|
+
return /* @__PURE__ */ (0, Y.jsx)(Zn, {
|
|
9148
9148
|
"data-slot": "select-bulk",
|
|
9149
9149
|
className: "pl-6 m-1 py-1",
|
|
9150
9150
|
value: `__bulk_${e.kind}`,
|
|
@@ -9183,7 +9183,7 @@ var Zx = ie, Qx = D, $x = A, eS = k, tS = (e) => {
|
|
|
9183
9183
|
className: "text-muted-foreground border-muted-foreground-20",
|
|
9184
9184
|
children: [o, /* @__PURE__ */ (0, Y.jsx)(Qx, {
|
|
9185
9185
|
className: "text-[0.84375rem]",
|
|
9186
|
-
children: /* @__PURE__ */ (0, Y.jsx)(
|
|
9186
|
+
children: /* @__PURE__ */ (0, Y.jsx)(mr, { data: r })
|
|
9187
9187
|
})]
|
|
9188
9188
|
})
|
|
9189
9189
|
}), t[6] = r, t[7] = s);
|
|
@@ -9221,10 +9221,10 @@ function rS(e) {
|
|
|
9221
9221
|
//#region src/plugins/core/registerReactComponent.tsx
|
|
9222
9222
|
var iS = 3, aS = 150;
|
|
9223
9223
|
function oS({ hostElement: e, plugin: t, children: n, getInitialValue: r }, i) {
|
|
9224
|
-
let [s, l] = (0, J.useState)(n), [u, d] = (0, J.useState)(r()), { theme: f } = fs(), [p, m] = (0, J.useState)(() => t.validator.safeParse(
|
|
9224
|
+
let [s, l] = (0, J.useState)(n), [u, d] = (0, J.useState)(r()), { theme: f } = fs(), [p, m] = (0, J.useState)(() => t.validator.safeParse(At(e))), [h, g] = (0, J.useState)(0);
|
|
9225
9225
|
(0, J.useImperativeHandle)(i, () => ({
|
|
9226
9226
|
reset: () => {
|
|
9227
|
-
d(r()), m(t.validator.safeParse(
|
|
9227
|
+
d(r()), m(t.validator.safeParse(At(e))), g((e) => e + 1);
|
|
9228
9228
|
},
|
|
9229
9229
|
setChildren: (e) => {
|
|
9230
9230
|
l(e);
|
|
@@ -9233,7 +9233,7 @@ function oS({ hostElement: e, plugin: t, children: n, getInitialValue: r }, i) {
|
|
|
9233
9233
|
t.detail.element === e && d(t.detail.value);
|
|
9234
9234
|
}), (0, J.useEffect)(() => {
|
|
9235
9235
|
let n = new MutationObserver((n) => {
|
|
9236
|
-
n.some((e) => e.type === "attributes" && e.attributeName?.startsWith("data-")) && m(t.validator.safeParse(
|
|
9236
|
+
n.some((e) => e.type === "attributes" && e.attributeName?.startsWith("data-")) && m(t.validator.safeParse(At(e)));
|
|
9237
9237
|
});
|
|
9238
9238
|
return n.observe(e, { attributes: !0 }), () => {
|
|
9239
9239
|
n.disconnect();
|
|
@@ -9251,10 +9251,10 @@ function oS({ hostElement: e, plugin: t, children: n, getInitialValue: r }, i) {
|
|
|
9251
9251
|
let { input: t, output: a } = i;
|
|
9252
9252
|
n[r] = async (...n) => {
|
|
9253
9253
|
xs(n.length <= 1, `Plugin functions only supports a single argument. Called ${r}`);
|
|
9254
|
-
let i =
|
|
9254
|
+
let i = ga(), o = De.findElementThroughShadowDOMs(e)?.id, s = o ? De.parse(o) : null;
|
|
9255
9255
|
if (s && !i) {
|
|
9256
|
-
let e = os.get(
|
|
9257
|
-
if (
|
|
9256
|
+
let e = os.get(Ze), t = e.cellRuntime[s], n = e.cellData[s];
|
|
9257
|
+
if (Ue({
|
|
9258
9258
|
executionTime: t.runElapsedTimeMs ?? n.lastExecutionTime,
|
|
9259
9259
|
status: t.status,
|
|
9260
9260
|
errored: t.errored,
|
|
@@ -9357,7 +9357,7 @@ function uS(e) {
|
|
|
9357
9357
|
hostElement: this,
|
|
9358
9358
|
plugin: e,
|
|
9359
9359
|
ref: this.pluginRef,
|
|
9360
|
-
getInitialValue: () =>
|
|
9360
|
+
getInitialValue: () => ve(this, f_.INSTANCE),
|
|
9361
9361
|
children: this.getChildren()
|
|
9362
9362
|
}) })
|
|
9363
9363
|
}));
|
|
@@ -9428,7 +9428,7 @@ function hS() {
|
|
|
9428
9428
|
inputListener = a.NOOP;
|
|
9429
9429
|
init() {
|
|
9430
9430
|
if (this.initialized) return;
|
|
9431
|
-
let e =
|
|
9431
|
+
let e = Ke.parseOrThrow(this);
|
|
9432
9432
|
this.inputListener = (n) => {
|
|
9433
9433
|
e !== null && n.detail.element === this.firstElementChild && (p_.has(e) || p_.registerInstance(e, t), p_.broadcastValueUpdate(t, e, n.detail.value));
|
|
9434
9434
|
};
|
|
@@ -9449,14 +9449,14 @@ function hS() {
|
|
|
9449
9449
|
}
|
|
9450
9450
|
connectedCallback() {
|
|
9451
9451
|
if (this.init(), this.initialized) {
|
|
9452
|
-
let e =
|
|
9452
|
+
let e = Ke.parseOrThrow(this), t = this.firstElementChild;
|
|
9453
9453
|
p_.registerInstance(e, t), document.addEventListener(wa.TYPE, this.inputListener);
|
|
9454
9454
|
}
|
|
9455
9455
|
}
|
|
9456
9456
|
disconnectedCallback() {
|
|
9457
9457
|
if (this.initialized) {
|
|
9458
9458
|
document.removeEventListener(wa.TYPE, this.inputListener);
|
|
9459
|
-
let e =
|
|
9459
|
+
let e = Ke.parseOrThrow(this);
|
|
9460
9460
|
p_.removeInstance(e, this.firstElementChild);
|
|
9461
9461
|
}
|
|
9462
9462
|
}
|
|
@@ -9465,7 +9465,7 @@ function hS() {
|
|
|
9465
9465
|
fS(e) ? e.reset() : c.error("[marimo-ui-element] first child must have a reset method");
|
|
9466
9466
|
}
|
|
9467
9467
|
static get observedAttributes() {
|
|
9468
|
-
return [
|
|
9468
|
+
return [yt];
|
|
9469
9469
|
}
|
|
9470
9470
|
attributeChangedCallback(e, t, n) {
|
|
9471
9471
|
if (this.initialized && e === "random-id" && t !== n) {
|
|
@@ -9479,16 +9479,16 @@ function hS() {
|
|
|
9479
9479
|
}
|
|
9480
9480
|
function gS(e) {
|
|
9481
9481
|
if (!e) return null;
|
|
9482
|
-
if (e.nodeName === mS) return
|
|
9482
|
+
if (e.nodeName === mS) return Ke.parseOrThrow(e);
|
|
9483
9483
|
let t = e.parentElement;
|
|
9484
|
-
return t?.nodeName === mS ?
|
|
9484
|
+
return t?.nodeName === mS ? Ke.parseOrThrow(t) : null;
|
|
9485
9485
|
}
|
|
9486
9486
|
function _S(e) {
|
|
9487
9487
|
return e.tagName === mS;
|
|
9488
9488
|
}
|
|
9489
9489
|
//#endregion
|
|
9490
9490
|
//#region src/components/editor/renderers/vertical-layout/sidebar/state.ts
|
|
9491
|
-
var vS =
|
|
9491
|
+
var vS = Re({ isOpen: !0 }, (e, t) => {
|
|
9492
9492
|
if (!t) return e;
|
|
9493
9493
|
switch (t.type) {
|
|
9494
9494
|
case "toggle": return {
|
|
@@ -9520,21 +9520,21 @@ function bS() {
|
|
|
9520
9520
|
this.observer && (this.observer.disconnect(), this.unmountReactComponent());
|
|
9521
9521
|
}
|
|
9522
9522
|
mountReactComponent() {
|
|
9523
|
-
this.syncWidth(),
|
|
9524
|
-
name:
|
|
9523
|
+
this.syncWidth(), Xn.mount({
|
|
9524
|
+
name: Qn.SIDEBAR,
|
|
9525
9525
|
ref: this.uniqueId,
|
|
9526
9526
|
children: this.getContents()
|
|
9527
9527
|
});
|
|
9528
9528
|
}
|
|
9529
9529
|
unmountReactComponent() {
|
|
9530
|
-
|
|
9531
|
-
name:
|
|
9530
|
+
Xn.unmount({
|
|
9531
|
+
name: Qn.SIDEBAR,
|
|
9532
9532
|
ref: this.uniqueId
|
|
9533
9533
|
});
|
|
9534
9534
|
}
|
|
9535
9535
|
updateReactComponent() {
|
|
9536
|
-
this.syncWidth(),
|
|
9537
|
-
name:
|
|
9536
|
+
this.syncWidth(), Xn.update({
|
|
9537
|
+
name: Qn.SIDEBAR,
|
|
9538
9538
|
ref: this.uniqueId,
|
|
9539
9539
|
children: this.getContents()
|
|
9540
9540
|
});
|
|
@@ -9633,7 +9633,7 @@ var SS = xS("marimo-anywidget").withData(W({ modelId: Ro(rg, { message: "Expecte
|
|
|
9633
9633
|
let i, a, o;
|
|
9634
9634
|
if (t[1] !== r || t[2] !== n) {
|
|
9635
9635
|
let e = n.split("-");
|
|
9636
|
-
i =
|
|
9636
|
+
i = Gi, t[6] === r ? a = t[7] : (a = l("flex gap-1 items-center", r), t[6] = r, t[7] = a), o = e.map(ES).map(AS), t[1] = r, t[2] = n, t[3] = i, t[4] = a, t[5] = o;
|
|
9637
9637
|
} else i = t[3], a = t[4], o = t[5];
|
|
9638
9638
|
let s;
|
|
9639
9639
|
return t[8] !== i || t[9] !== a || t[10] !== o ? (s = /* @__PURE__ */ (0, Y.jsx)(i, {
|
|
@@ -9775,8 +9775,8 @@ function kS(e) {
|
|
|
9775
9775
|
tabIndex: -1,
|
|
9776
9776
|
content: t,
|
|
9777
9777
|
delayDuration: 300,
|
|
9778
|
-
children: /* @__PURE__ */ (0, Y.jsx)(
|
|
9779
|
-
}, t) : /* @__PURE__ */ (0, Y.jsx)(
|
|
9778
|
+
children: /* @__PURE__ */ (0, Y.jsx)(cn, { children: n }, t)
|
|
9779
|
+
}, t) : /* @__PURE__ */ (0, Y.jsx)(cn, { children: OS(t) }, t);
|
|
9780
9780
|
}
|
|
9781
9781
|
function AS(e) {
|
|
9782
9782
|
let [t, n] = e;
|
|
@@ -9895,7 +9895,7 @@ var PS = (e) => {
|
|
|
9895
9895
|
e !== "indeterminate" && r(e);
|
|
9896
9896
|
}, t[0] = r, t[1] = a);
|
|
9897
9897
|
let o = a, s = (0, J.useId)(), c;
|
|
9898
|
-
t[2] !== i.disabled || t[3] !== s || t[4] !== o || t[5] !== n ? (c = /* @__PURE__ */ (0, Y.jsx)(
|
|
9898
|
+
t[2] !== i.disabled || t[3] !== s || t[4] !== o || t[5] !== n ? (c = /* @__PURE__ */ (0, Y.jsx)(Me, {
|
|
9899
9899
|
"data-testid": "marimo-plugin-checkbox",
|
|
9900
9900
|
checked: n,
|
|
9901
9901
|
onCheckedChange: o,
|
|
@@ -9940,7 +9940,7 @@ var PS = (e) => {
|
|
|
9940
9940
|
onChange: u,
|
|
9941
9941
|
disabled: f
|
|
9942
9942
|
}, t[2] = e.setValue, t[3] = e.value, t[4] = l, t[5] = f, t[6] = p) : p = t[6];
|
|
9943
|
-
let { onChange: m } =
|
|
9943
|
+
let { onChange: m } = ra(p), h;
|
|
9944
9944
|
t[7] !== e || t[8] !== m ? (h = (t) => {
|
|
9945
9945
|
s((e) => t), typeof e.debounce == "number" ? m(t) : e.debounce || e.setValue(t);
|
|
9946
9946
|
}, t[7] = e, t[8] = m, t[9] = h) : h = t[9];
|
|
@@ -9992,7 +9992,7 @@ var PS = (e) => {
|
|
|
9992
9992
|
output: t
|
|
9993
9993
|
};
|
|
9994
9994
|
} };
|
|
9995
|
-
} }, BS = J.lazy(() => import("./chat-ui-
|
|
9995
|
+
} }, BS = J.lazy(() => import("./chat-ui-HJZsTl7o.js").then((e) => ({ default: e.Chatbot }))), VS = G(W({
|
|
9996
9996
|
id: U(),
|
|
9997
9997
|
role: Io([
|
|
9998
9998
|
"system",
|
|
@@ -10047,9 +10047,9 @@ var PS = (e) => {
|
|
|
10047
10047
|
let s = r || "rounded-md border", c;
|
|
10048
10048
|
t[2] === s ? c = t[3] : (c = l(s), t[2] = s, t[3] = c);
|
|
10049
10049
|
let u;
|
|
10050
|
-
t[4] === Symbol.for("react.memo_cache_sentinel") ? (u = /* @__PURE__ */ (0, Y.jsx)(
|
|
10050
|
+
t[4] === Symbol.for("react.memo_cache_sentinel") ? (u = /* @__PURE__ */ (0, Y.jsx)(Fr, { children: Array.from({ length: 1 }).map(qS) }), t[4] = u) : u = t[4];
|
|
10051
10051
|
let d;
|
|
10052
|
-
t[5] === a ? d = t[6] : (d = /* @__PURE__ */ (0, Y.jsxs)(
|
|
10052
|
+
t[5] === a ? d = t[6] : (d = /* @__PURE__ */ (0, Y.jsxs)(Pr, { children: [u, /* @__PURE__ */ (0, Y.jsx)(Ur, { children: Array.from({ length: a }).map(YS) })] }), t[5] = a, t[6] = d);
|
|
10053
10053
|
let f;
|
|
10054
10054
|
t[7] !== c || t[8] !== d ? (f = /* @__PURE__ */ (0, Y.jsx)("div", {
|
|
10055
10055
|
part: "table-wrapper",
|
|
@@ -10065,16 +10065,16 @@ var PS = (e) => {
|
|
|
10065
10065
|
}), t[11] = o, t[12] = f, t[13] = m) : m = t[13], m;
|
|
10066
10066
|
};
|
|
10067
10067
|
function KS(e, t) {
|
|
10068
|
-
return /* @__PURE__ */ (0, Y.jsx)(
|
|
10068
|
+
return /* @__PURE__ */ (0, Y.jsx)(ir, { children: /* @__PURE__ */ (0, Y.jsx)("div", { className: "h-4 bg-(--slate-5) animate-pulse rounded-md w-[70%]" }) }, t);
|
|
10069
10069
|
}
|
|
10070
10070
|
function qS(e, t) {
|
|
10071
|
-
return /* @__PURE__ */ (0, Y.jsx)(
|
|
10071
|
+
return /* @__PURE__ */ (0, Y.jsx)(Gr, { children: Array.from({ length: 8 }).map(KS) }, t);
|
|
10072
10072
|
}
|
|
10073
10073
|
function JS(e, t) {
|
|
10074
|
-
return /* @__PURE__ */ (0, Y.jsx)(
|
|
10074
|
+
return /* @__PURE__ */ (0, Y.jsx)(Cr, { children: /* @__PURE__ */ (0, Y.jsx)("div", { className: "h-4 bg-(--slate-5) animate-pulse rounded-md w-[90%]" }) }, t);
|
|
10075
10075
|
}
|
|
10076
10076
|
function YS(e, t) {
|
|
10077
|
-
return /* @__PURE__ */ (0, Y.jsx)(
|
|
10077
|
+
return /* @__PURE__ */ (0, Y.jsx)(Gr, { children: Array.from({ length: 8 }).map(JS) }, t);
|
|
10078
10078
|
}
|
|
10079
10079
|
//#endregion
|
|
10080
10080
|
//#region src/core/kernel/messages.ts
|
|
@@ -10396,7 +10396,7 @@ function LC(e) {
|
|
|
10396
10396
|
];
|
|
10397
10397
|
return new Map(i);
|
|
10398
10398
|
}
|
|
10399
|
-
default: return
|
|
10399
|
+
default: return mi(e), t;
|
|
10400
10400
|
}
|
|
10401
10401
|
}
|
|
10402
10402
|
//#endregion
|
|
@@ -10448,7 +10448,7 @@ function RC(e, t) {
|
|
|
10448
10448
|
newColumnName: e.newName
|
|
10449
10449
|
});
|
|
10450
10450
|
break;
|
|
10451
|
-
default:
|
|
10451
|
+
default: mi(e);
|
|
10452
10452
|
}
|
|
10453
10453
|
}
|
|
10454
10454
|
return {
|
|
@@ -10458,7 +10458,7 @@ function RC(e, t) {
|
|
|
10458
10458
|
}
|
|
10459
10459
|
//#endregion
|
|
10460
10460
|
//#region src/plugins/impl/DataEditorPlugin.tsx
|
|
10461
|
-
var zC = J.lazy(() => import("./glide-data-editor-
|
|
10461
|
+
var zC = J.lazy(() => import("./glide-data-editor-Ohetlgag.js").then((e) => e.t)), BC = xS("marimo-data-editor", { cssStyles: [WS] }).withData(W({
|
|
10462
10462
|
initialValue: W({ edits: G(W({
|
|
10463
10463
|
rowIdx: K(),
|
|
10464
10464
|
columnId: U(),
|
|
@@ -10480,13 +10480,13 @@ var zC = J.lazy(() => import("./glide-data-editor-CBIPbkXG.js").then((e) => e.t)
|
|
|
10480
10480
|
})), VC = (e) => {
|
|
10481
10481
|
let t = (0, X.c)(20), [n, r] = (0, J.useState)(null), i, a;
|
|
10482
10482
|
t[0] !== e.columnNames || t[1] !== e.data || t[2] !== e.fieldTypes ? (i = async () => {
|
|
10483
|
-
let t =
|
|
10483
|
+
let t = un(e.fieldTypes ?? []), n = Array.isArray(e.data) ? e.data : await Bs(e.data, {
|
|
10484
10484
|
type: "csv",
|
|
10485
10485
|
parse: Rs(Object.fromEntries(t))
|
|
10486
10486
|
}, { handleBigIntAndNumberLike: !0 });
|
|
10487
10487
|
return {
|
|
10488
10488
|
data: n,
|
|
10489
|
-
columnFields: NC(
|
|
10489
|
+
columnFields: NC(un(e.fieldTypes ?? Zr(n)), e.columnNames)
|
|
10490
10490
|
};
|
|
10491
10491
|
}, a = [
|
|
10492
10492
|
e.fieldTypes,
|
|
@@ -10511,7 +10511,7 @@ var zC = J.lazy(() => import("./glide-data-editor-CBIPbkXG.js").then((e) => e.t)
|
|
|
10511
10511
|
}
|
|
10512
10512
|
if (n === null) {
|
|
10513
10513
|
let e;
|
|
10514
|
-
return t[12] === Symbol.for("react.memo_cache_sentinel") ? (e = /* @__PURE__ */ (0, Y.jsx)(
|
|
10514
|
+
return t[12] === Symbol.for("react.memo_cache_sentinel") ? (e = /* @__PURE__ */ (0, Y.jsx)(Mr, {
|
|
10515
10515
|
milliseconds: 200,
|
|
10516
10516
|
children: /* @__PURE__ */ (0, Y.jsx)(GS, { pageSize: 10 })
|
|
10517
10517
|
}), t[12] = e) : e = t[12], e;
|
|
@@ -10751,7 +10751,7 @@ ${n}
|
|
|
10751
10751
|
}
|
|
10752
10752
|
function iw(e) {
|
|
10753
10753
|
let t = {};
|
|
10754
|
-
for (let [n, r] of Object.entries(e)) r !== void 0 && (t[n] = n === "field" && typeof r == "string" ? new ZC(
|
|
10754
|
+
for (let [n, r] of Object.entries(e)) r !== void 0 && (t[n] = n === "field" && typeof r == "string" ? new ZC(Mt(r)) : new ZC(r));
|
|
10755
10755
|
return t;
|
|
10756
10756
|
}
|
|
10757
10757
|
//#endregion
|
|
@@ -10759,7 +10759,7 @@ function iw(e) {
|
|
|
10759
10759
|
var aw = (0, J.createContext)({
|
|
10760
10760
|
fields: [],
|
|
10761
10761
|
saveForm: a.NOOP,
|
|
10762
|
-
chartType:
|
|
10762
|
+
chartType: Wt.LINE
|
|
10763
10763
|
}), ow = () => (0, J.use)(aw);
|
|
10764
10764
|
//#endregion
|
|
10765
10765
|
//#region src/hooks/useBoolean.ts
|
|
@@ -10819,7 +10819,7 @@ var lw = J.forwardRef((e, t) => {
|
|
|
10819
10819
|
})
|
|
10820
10820
|
}), n[8] = s.setFalse, n[9] = s.setTrue, n[10] = p) : p = n[10];
|
|
10821
10821
|
let m;
|
|
10822
|
-
n[11] !== c || n[12] !== i.value || n[13] !== a ? (m = i.value != null && i.value.length === 1 && /* @__PURE__ */ (0, Y.jsx)(ue, { children:
|
|
10822
|
+
n[11] !== c || n[12] !== i.value || n[13] !== a ? (m = i.value != null && i.value.length === 1 && /* @__PURE__ */ (0, Y.jsx)(ue, { children: zi(a(i.value[0]), { locale: c }) }, i.value[0]), n[11] = c, n[12] = i.value, n[13] = a, n[14] = m) : m = n[14];
|
|
10823
10823
|
let h;
|
|
10824
10824
|
n[15] === m ? h = n[16] : (h = /* @__PURE__ */ (0, Y.jsx)(pe, { children: m }), n[15] = m, n[16] = h);
|
|
10825
10825
|
let g;
|
|
@@ -10891,9 +10891,9 @@ function fw(e) {
|
|
|
10891
10891
|
//#endregion
|
|
10892
10892
|
//#region src/components/editor/cell/useAddCell.ts
|
|
10893
10893
|
function pw() {
|
|
10894
|
-
let e = (0, X.c)(4), t = rs(ls), n =
|
|
10894
|
+
let e = (0, X.c)(4), t = rs(ls), n = Ne(), { createNewCell: r } = ot(), i;
|
|
10895
10895
|
return e[0] !== t || e[1] !== r || e[2] !== n ? (i = (e) => {
|
|
10896
|
-
e.includes("alt") &&
|
|
10896
|
+
e.includes("alt") && ct({
|
|
10897
10897
|
autoInstantiate: t,
|
|
10898
10898
|
createNewCell: r,
|
|
10899
10899
|
fromCellId: n
|
|
@@ -12164,7 +12164,7 @@ var hw = [mw({
|
|
|
12164
12164
|
borderBottom: "2px solid var(--cm-reactive-reference-border-color)"
|
|
12165
12165
|
},
|
|
12166
12166
|
".mo-cm-reactive-reference-hover": { cursor: "pointer" }
|
|
12167
|
-
})], _w = [
|
|
12167
|
+
})], _w = [_e(), _s.lineWrapping], vw = [Os(), _s.lineWrapping], yw = [ks(), _s.lineWrapping];
|
|
12168
12168
|
function bw(e) {
|
|
12169
12169
|
switch (e) {
|
|
12170
12170
|
case "sql": return vw;
|
|
@@ -12248,10 +12248,10 @@ var Sw = (e) => {
|
|
|
12248
12248
|
}), t[3] = r, t[4] = a), a;
|
|
12249
12249
|
}, Cw = (e) => {
|
|
12250
12250
|
let t = (0, X.c)(9), n = e.hidden ? "Show code" : "Hide code", r = e.hidden ? "Show code" : "Hide code", i;
|
|
12251
|
-
t[0] === e.hidden ? i = t[1] : (i = e.hidden ? /* @__PURE__ */ (0, Y.jsx)(
|
|
12251
|
+
t[0] === e.hidden ? i = t[1] : (i = e.hidden ? /* @__PURE__ */ (0, Y.jsx)(ut, {
|
|
12252
12252
|
size: 14,
|
|
12253
12253
|
strokeWidth: 1.5
|
|
12254
|
-
}) : /* @__PURE__ */ (0, Y.jsx)(
|
|
12254
|
+
}) : /* @__PURE__ */ (0, Y.jsx)(rr, {
|
|
12255
12255
|
size: 14,
|
|
12256
12256
|
strokeWidth: 1.5
|
|
12257
12257
|
}), t[0] = e.hidden, t[1] = i);
|
|
@@ -12303,7 +12303,7 @@ var Ew = (e) => {
|
|
|
12303
12303
|
let t = (0, X.c)(5), { text: n, tooltip: r } = e, i;
|
|
12304
12304
|
t[0] === r ? i = t[1] : (i = r && /* @__PURE__ */ (0, Y.jsx)(me, {
|
|
12305
12305
|
content: r,
|
|
12306
|
-
children: /* @__PURE__ */ (0, Y.jsx)(
|
|
12306
|
+
children: /* @__PURE__ */ (0, Y.jsx)(Ct, { className: "w-3 h-3 mt-0.5" })
|
|
12307
12307
|
}), t[0] = r, t[1] = i);
|
|
12308
12308
|
let a;
|
|
12309
12309
|
return t[2] !== i || t[3] !== n ? (a = /* @__PURE__ */ (0, Y.jsxs)("h2", {
|
|
@@ -12387,7 +12387,7 @@ var Ew = (e) => {
|
|
|
12387
12387
|
let p = f, m;
|
|
12388
12388
|
t[10] !== p || t[11] !== r || t[12] !== n || t[13] !== s || t[14] !== o || t[15] !== i || t[16] !== d || t[17] !== l ? (m = (e) => {
|
|
12389
12389
|
let { field: t } = e;
|
|
12390
|
-
return /* @__PURE__ */ (0, Y.jsx)(yh, { children: /* @__PURE__ */ (0, Y.jsx)(xh, { children: /* @__PURE__ */ (0, Y.jsxs)(
|
|
12390
|
+
return /* @__PURE__ */ (0, Y.jsx)(yh, { children: /* @__PURE__ */ (0, Y.jsx)(xh, { children: /* @__PURE__ */ (0, Y.jsxs)(ji, {
|
|
12391
12391
|
...t,
|
|
12392
12392
|
onValueChange: (e) => {
|
|
12393
12393
|
if (e === Fw) {
|
|
@@ -12399,28 +12399,28 @@ var Ew = (e) => {
|
|
|
12399
12399
|
return;
|
|
12400
12400
|
}
|
|
12401
12401
|
let t = r.find((t) => t.name === e);
|
|
12402
|
-
t && (s.setValue(n, e), s.setValue(l, t.type), s.setValue(d,
|
|
12402
|
+
t && (s.setValue(n, e), s.setValue(l, t.type), s.setValue(d, Ut(t.type)), i?.(n, t.type));
|
|
12403
12403
|
},
|
|
12404
12404
|
value: t.value ?? "",
|
|
12405
|
-
children: [/* @__PURE__ */ (0, Y.jsx)(
|
|
12405
|
+
children: [/* @__PURE__ */ (0, Y.jsx)(Ai, {
|
|
12406
12406
|
className: "w-40 truncate",
|
|
12407
12407
|
onClear: t.value ? p : void 0,
|
|
12408
|
-
children: /* @__PURE__ */ (0, Y.jsx)(
|
|
12409
|
-
}), /* @__PURE__ */ (0, Y.jsxs)(
|
|
12410
|
-
t.value && /* @__PURE__ */ (0, Y.jsx)(
|
|
12408
|
+
children: /* @__PURE__ */ (0, Y.jsx)(Ci, { placeholder: "Select column" })
|
|
12409
|
+
}), /* @__PURE__ */ (0, Y.jsxs)(Di, { children: [
|
|
12410
|
+
t.value && /* @__PURE__ */ (0, Y.jsx)(wi, {
|
|
12411
12411
|
value: Fw,
|
|
12412
12412
|
children: /* @__PURE__ */ (0, Y.jsxs)("div", {
|
|
12413
12413
|
className: "flex items-center truncate",
|
|
12414
|
-
children: [/* @__PURE__ */ (0, Y.jsx)(
|
|
12414
|
+
children: [/* @__PURE__ */ (0, Y.jsx)(pi, { className: "w-3 h-3 mr-2" }), "Clear"]
|
|
12415
12415
|
})
|
|
12416
12416
|
}),
|
|
12417
|
-
o && /* @__PURE__ */ (0, Y.jsxs)(Y.Fragment, { children: [/* @__PURE__ */ (0, Y.jsx)(
|
|
12417
|
+
o && /* @__PURE__ */ (0, Y.jsxs)(Y.Fragment, { children: [/* @__PURE__ */ (0, Y.jsx)(wi, {
|
|
12418
12418
|
value: "__count__",
|
|
12419
12419
|
children: /* @__PURE__ */ (0, Y.jsxs)("div", {
|
|
12420
12420
|
className: "flex items-center truncate",
|
|
12421
|
-
children: [/* @__PURE__ */ (0, Y.jsx)(
|
|
12421
|
+
children: [/* @__PURE__ */ (0, Y.jsx)(jt, { className: "w-3 h-3 mr-2" }), "Count of records"]
|
|
12422
12422
|
})
|
|
12423
|
-
}, "__count__"), /* @__PURE__ */ (0, Y.jsx)(
|
|
12423
|
+
}, "__count__"), /* @__PURE__ */ (0, Y.jsx)(Oi, {})] }),
|
|
12424
12424
|
r.map(Yw)
|
|
12425
12425
|
] })]
|
|
12426
12426
|
}) }) });
|
|
@@ -12437,14 +12437,14 @@ var Ew = (e) => {
|
|
|
12437
12437
|
let { field: t } = e;
|
|
12438
12438
|
return /* @__PURE__ */ (0, Y.jsxs)(yh, {
|
|
12439
12439
|
className: "flex flex-row items-center justify-between",
|
|
12440
|
-
children: [/* @__PURE__ */ (0, Y.jsx)(bh, { children: r }), /* @__PURE__ */ (0, Y.jsx)(xh, { children: /* @__PURE__ */ (0, Y.jsxs)(
|
|
12440
|
+
children: [/* @__PURE__ */ (0, Y.jsx)(bh, { children: r }), /* @__PURE__ */ (0, Y.jsx)(xh, { children: /* @__PURE__ */ (0, Y.jsxs)(ji, {
|
|
12441
12441
|
...t,
|
|
12442
12442
|
onValueChange: t.onChange,
|
|
12443
12443
|
value: t.value ?? a,
|
|
12444
|
-
children: [/* @__PURE__ */ (0, Y.jsx)(
|
|
12444
|
+
children: [/* @__PURE__ */ (0, Y.jsx)(Ai, {
|
|
12445
12445
|
className: "truncate",
|
|
12446
|
-
children: /* @__PURE__ */ (0, Y.jsx)(
|
|
12447
|
-
}), /* @__PURE__ */ (0, Y.jsx)(
|
|
12446
|
+
children: /* @__PURE__ */ (0, Y.jsx)(Ci, { placeholder: "Select an option" })
|
|
12447
|
+
}), /* @__PURE__ */ (0, Y.jsx)(Di, { children: /* @__PURE__ */ (0, Y.jsx)(ki, { children: i.filter(Xw).map(Zw) }) })]
|
|
12448
12448
|
}) })]
|
|
12449
12449
|
});
|
|
12450
12450
|
}, t[0] = a, t[1] = r, t[2] = i, t[3] = s) : s = t[3];
|
|
@@ -12460,7 +12460,7 @@ var Ew = (e) => {
|
|
|
12460
12460
|
let { field: t } = e;
|
|
12461
12461
|
return /* @__PURE__ */ (0, Y.jsxs)(yh, {
|
|
12462
12462
|
className: "flex flex-row gap-2 items-center",
|
|
12463
|
-
children: [/* @__PURE__ */ (0, Y.jsx)(bh, { children: r }), /* @__PURE__ */ (0, Y.jsx)(xh, { children: /* @__PURE__ */ (0, Y.jsx)(
|
|
12463
|
+
children: [/* @__PURE__ */ (0, Y.jsx)(bh, { children: r }), /* @__PURE__ */ (0, Y.jsx)(xh, { children: /* @__PURE__ */ (0, Y.jsx)(ta, {
|
|
12464
12464
|
...t,
|
|
12465
12465
|
value: t.value ?? "",
|
|
12466
12466
|
onValueChange: t.onChange,
|
|
@@ -12485,7 +12485,7 @@ var Ew = (e) => {
|
|
|
12485
12485
|
children: [/* @__PURE__ */ (0, Y.jsx)(bh, {
|
|
12486
12486
|
className: "whitespace-nowrap",
|
|
12487
12487
|
children: o
|
|
12488
|
-
}), /* @__PURE__ */ (0, Y.jsx)(xh, { children: /* @__PURE__ */ (0, Y.jsx)(
|
|
12488
|
+
}), /* @__PURE__ */ (0, Y.jsx)(xh, { children: /* @__PURE__ */ (0, Y.jsx)($i, {
|
|
12489
12489
|
...t,
|
|
12490
12490
|
value: t.value,
|
|
12491
12491
|
onValueChange: t.onChange,
|
|
@@ -12509,7 +12509,7 @@ var Ew = (e) => {
|
|
|
12509
12509
|
let { field: t } = e;
|
|
12510
12510
|
return /* @__PURE__ */ (0, Y.jsxs)(yh, {
|
|
12511
12511
|
className: l("flex flex-row items-center gap-2", i),
|
|
12512
|
-
children: [/* @__PURE__ */ (0, Y.jsx)(bh, { children: r }), /* @__PURE__ */ (0, Y.jsx)(xh, { children: /* @__PURE__ */ (0, Y.jsx)(
|
|
12512
|
+
children: [/* @__PURE__ */ (0, Y.jsx)(bh, { children: r }), /* @__PURE__ */ (0, Y.jsx)(xh, { children: /* @__PURE__ */ (0, Y.jsx)(Me, {
|
|
12513
12513
|
checked: t.value ?? a ?? !1,
|
|
12514
12514
|
onCheckedChange: t.onChange,
|
|
12515
12515
|
className: "w-4 h-4"
|
|
@@ -12599,7 +12599,7 @@ var Ew = (e) => {
|
|
|
12599
12599
|
size: "sm",
|
|
12600
12600
|
onClick: () => h(t),
|
|
12601
12601
|
className: "h-4 w-4 p-0",
|
|
12602
|
-
children: /* @__PURE__ */ (0, Y.jsx)(
|
|
12602
|
+
children: /* @__PURE__ */ (0, Y.jsx)(pi, { className: "h-2 w-2" })
|
|
12603
12603
|
})
|
|
12604
12604
|
]
|
|
12605
12605
|
}, t)), /* @__PURE__ */ (0, Y.jsxs)(_, {
|
|
@@ -12627,27 +12627,27 @@ var Ew = (e) => {
|
|
|
12627
12627
|
let { field: t } = e;
|
|
12628
12628
|
return /* @__PURE__ */ (0, Y.jsxs)(yh, {
|
|
12629
12629
|
className: "flex flex-row items-center justify-between w-full",
|
|
12630
|
-
children: [/* @__PURE__ */ (0, Y.jsx)(bh, { children: r }), /* @__PURE__ */ (0, Y.jsx)(xh, { children: /* @__PURE__ */ (0, Y.jsxs)(
|
|
12630
|
+
children: [/* @__PURE__ */ (0, Y.jsx)(bh, { children: r }), /* @__PURE__ */ (0, Y.jsx)(xh, { children: /* @__PURE__ */ (0, Y.jsxs)(ji, {
|
|
12631
12631
|
...t,
|
|
12632
12632
|
onValueChange: (e) => {
|
|
12633
12633
|
e === Fw ? o() : t.onChange(e);
|
|
12634
12634
|
},
|
|
12635
12635
|
value: t.value ?? "yearmonthdate",
|
|
12636
|
-
children: [/* @__PURE__ */ (0, Y.jsx)(
|
|
12636
|
+
children: [/* @__PURE__ */ (0, Y.jsx)(Ai, {
|
|
12637
12637
|
onClear: t.value ? o : void 0,
|
|
12638
|
-
children: /* @__PURE__ */ (0, Y.jsx)(
|
|
12639
|
-
}), /* @__PURE__ */ (0, Y.jsxs)(
|
|
12638
|
+
children: /* @__PURE__ */ (0, Y.jsx)(Ci, { placeholder: "Select unit" })
|
|
12639
|
+
}), /* @__PURE__ */ (0, Y.jsxs)(Di, {
|
|
12640
12640
|
className: "w-72",
|
|
12641
|
-
children: [t.value && /* @__PURE__ */ (0, Y.jsxs)(Y.Fragment, { children: [/* @__PURE__ */ (0, Y.jsx)(
|
|
12641
|
+
children: [t.value && /* @__PURE__ */ (0, Y.jsxs)(Y.Fragment, { children: [/* @__PURE__ */ (0, Y.jsx)(wi, {
|
|
12642
12642
|
value: Fw,
|
|
12643
12643
|
children: /* @__PURE__ */ (0, Y.jsxs)("div", {
|
|
12644
12644
|
className: "flex items-center truncate",
|
|
12645
|
-
children: [/* @__PURE__ */ (0, Y.jsx)(
|
|
12645
|
+
children: [/* @__PURE__ */ (0, Y.jsx)(pi, { className: "w-3 h-3 mr-2" }), "Clear"]
|
|
12646
12646
|
})
|
|
12647
|
-
}), /* @__PURE__ */ (0, Y.jsx)(
|
|
12648
|
-
|
|
12649
|
-
/* @__PURE__ */ (0, Y.jsx)(
|
|
12650
|
-
|
|
12647
|
+
}), /* @__PURE__ */ (0, Y.jsx)(Oi, {})] }), /* @__PURE__ */ (0, Y.jsxs)(ki, { children: [
|
|
12648
|
+
Rt.map(s),
|
|
12649
|
+
/* @__PURE__ */ (0, Y.jsx)(Oi, {}),
|
|
12650
|
+
Bt.map(s)
|
|
12651
12651
|
] })]
|
|
12652
12652
|
})]
|
|
12653
12653
|
}) })]
|
|
@@ -12665,7 +12665,7 @@ var Ew = (e) => {
|
|
|
12665
12665
|
let { field: t } = e;
|
|
12666
12666
|
return /* @__PURE__ */ (0, Y.jsxs)(yh, {
|
|
12667
12667
|
className: "flex flex-row items-center justify-between w-full",
|
|
12668
|
-
children: [/* @__PURE__ */ (0, Y.jsx)(bh, { children: r }), /* @__PURE__ */ (0, Y.jsx)(xh, { children: /* @__PURE__ */ (0, Y.jsxs)(
|
|
12668
|
+
children: [/* @__PURE__ */ (0, Y.jsx)(bh, { children: r }), /* @__PURE__ */ (0, Y.jsx)(xh, { children: /* @__PURE__ */ (0, Y.jsxs)(ji, {
|
|
12669
12669
|
...t,
|
|
12670
12670
|
onValueChange: (e) => {
|
|
12671
12671
|
t.onChange(e), a?.(e);
|
|
@@ -12673,18 +12673,18 @@ var Ew = (e) => {
|
|
|
12673
12673
|
value: t.value ?? i,
|
|
12674
12674
|
open: o,
|
|
12675
12675
|
onOpenChange: s,
|
|
12676
|
-
children: [/* @__PURE__ */ (0, Y.jsx)(
|
|
12677
|
-
let t =
|
|
12678
|
-
return /* @__PURE__ */ (0, Y.jsx)(
|
|
12676
|
+
children: [/* @__PURE__ */ (0, Y.jsx)(Ai, { children: /* @__PURE__ */ (0, Y.jsx)(Ci, { placeholder: "Select an option" }) }), /* @__PURE__ */ (0, Y.jsx)(Di, { children: /* @__PURE__ */ (0, Y.jsx)(ki, { children: zt.map((e) => {
|
|
12677
|
+
let t = rt[e], n = e === "string" ? "categorical" : e;
|
|
12678
|
+
return /* @__PURE__ */ (0, Y.jsx)(wi, {
|
|
12679
12679
|
value: e,
|
|
12680
12680
|
className: "flex flex-col items-start justify-center",
|
|
12681
12681
|
subtitle: o && /* @__PURE__ */ (0, Y.jsx)("span", {
|
|
12682
12682
|
className: "text-xs text-muted-foreground",
|
|
12683
|
-
children:
|
|
12683
|
+
children: en[e]
|
|
12684
12684
|
}),
|
|
12685
12685
|
children: /* @__PURE__ */ (0, Y.jsx)(Aw, {
|
|
12686
12686
|
Icon: t,
|
|
12687
|
-
text:
|
|
12687
|
+
text: Ni(n)
|
|
12688
12688
|
})
|
|
12689
12689
|
}, e);
|
|
12690
12690
|
}) }) })]
|
|
@@ -12698,7 +12698,7 @@ var Ew = (e) => {
|
|
|
12698
12698
|
render: l
|
|
12699
12699
|
}), t[5] = n, t[6] = c.control, t[7] = l, t[8] = u) : u = t[8], u;
|
|
12700
12700
|
}, Gw = (e) => {
|
|
12701
|
-
let t = (0, X.c)(12), { fieldName: n, selectedDataType: r, binFieldName: i, defaultAggregation: a } = e, o = Ip(), s = r === "string" ?
|
|
12701
|
+
let t = (0, X.c)(12), { fieldName: n, selectedDataType: r, binFieldName: i, defaultAggregation: a } = e, o = Ip(), s = r === "string" ? Gt : Lt, { chartType: c } = ow(), l = c !== Wt.HEATMAP, u = eT, d = tT, f;
|
|
12702
12702
|
t[0] !== i || t[1] !== o ? (f = (e) => {
|
|
12703
12703
|
let { value: t, previousValue: n, onChange: r } = e;
|
|
12704
12704
|
t === "bin" ? o.setValue(i, !0) : n === "bin" && o.setValue(i, !1), r(t);
|
|
@@ -12706,7 +12706,7 @@ var Ew = (e) => {
|
|
|
12706
12706
|
let p = f, m;
|
|
12707
12707
|
t[3] !== s || t[4] !== a || t[5] !== p || t[6] !== l ? (m = (e) => {
|
|
12708
12708
|
let { field: t } = e;
|
|
12709
|
-
return /* @__PURE__ */ (0, Y.jsx)(yh, { children: /* @__PURE__ */ (0, Y.jsx)(xh, { children: /* @__PURE__ */ (0, Y.jsxs)(
|
|
12709
|
+
return /* @__PURE__ */ (0, Y.jsx)(yh, { children: /* @__PURE__ */ (0, Y.jsx)(xh, { children: /* @__PURE__ */ (0, Y.jsxs)(ji, {
|
|
12710
12710
|
...t,
|
|
12711
12711
|
value: (t.value ?? a ?? "none").toString(),
|
|
12712
12712
|
onValueChange: (e) => {
|
|
@@ -12716,16 +12716,16 @@ var Ew = (e) => {
|
|
|
12716
12716
|
onChange: t.onChange
|
|
12717
12717
|
});
|
|
12718
12718
|
},
|
|
12719
|
-
children: [/* @__PURE__ */ (0, Y.jsx)(
|
|
12719
|
+
children: [/* @__PURE__ */ (0, Y.jsx)(Ai, {
|
|
12720
12720
|
variant: "ghost",
|
|
12721
|
-
children: /* @__PURE__ */ (0, Y.jsx)(
|
|
12722
|
-
}), /* @__PURE__ */ (0, Y.jsx)(
|
|
12723
|
-
let t =
|
|
12721
|
+
children: /* @__PURE__ */ (0, Y.jsx)(Ci, {})
|
|
12722
|
+
}), /* @__PURE__ */ (0, Y.jsx)(Di, { children: /* @__PURE__ */ (0, Y.jsxs)(ki, { children: [/* @__PURE__ */ (0, Y.jsx)(xi, { children: "Aggregation" }), s.map((e) => {
|
|
12723
|
+
let t = It[e], n = u(Vt[e] ?? "Other"), r = d({
|
|
12724
12724
|
value: e,
|
|
12725
|
-
Icon: t ??
|
|
12725
|
+
Icon: t ?? jt,
|
|
12726
12726
|
subtitle: n
|
|
12727
12727
|
});
|
|
12728
|
-
return e === "bin" ? l ? /* @__PURE__ */ (0, Y.jsxs)("div", { children: [/* @__PURE__ */ (0, Y.jsx)(
|
|
12728
|
+
return e === "bin" ? l ? /* @__PURE__ */ (0, Y.jsxs)("div", { children: [/* @__PURE__ */ (0, Y.jsx)(Oi, {}), r] }, e) : null : r;
|
|
12729
12729
|
})] }) })]
|
|
12730
12730
|
}) }) });
|
|
12731
12731
|
}, t[3] = s, t[4] = a, t[5] = p, t[6] = l, t[7] = m) : m = t[7];
|
|
@@ -12759,7 +12759,7 @@ var Ew = (e) => {
|
|
|
12759
12759
|
}), t[3] = n, t[4] = i.control, t[5] = s, t[6] = c) : c = t[6], c;
|
|
12760
12760
|
}, qw = (e) => {
|
|
12761
12761
|
let t = (0, X.c)(5), { fieldName: n, label: r, defaultValue: i } = e, a;
|
|
12762
|
-
t[0] === Symbol.for("react.memo_cache_sentinel") ? (a =
|
|
12762
|
+
t[0] === Symbol.for("react.memo_cache_sentinel") ? (a = Jt.map(aT), t[0] = a) : a = t[0];
|
|
12763
12763
|
let o = i ?? "ascending", s;
|
|
12764
12764
|
return t[1] !== n || t[2] !== r || t[3] !== o ? (s = /* @__PURE__ */ (0, Y.jsx)(Lw, {
|
|
12765
12765
|
fieldName: n,
|
|
@@ -12797,8 +12797,8 @@ var Ew = (e) => {
|
|
|
12797
12797
|
};
|
|
12798
12798
|
function Yw(e) {
|
|
12799
12799
|
if (e.name.trim() === "") return null;
|
|
12800
|
-
let t =
|
|
12801
|
-
return /* @__PURE__ */ (0, Y.jsx)(
|
|
12800
|
+
let t = rt[e.type];
|
|
12801
|
+
return /* @__PURE__ */ (0, Y.jsx)(wi, {
|
|
12802
12802
|
value: e.name,
|
|
12803
12803
|
children: /* @__PURE__ */ (0, Y.jsxs)("div", {
|
|
12804
12804
|
className: "flex items-center truncate",
|
|
@@ -12810,7 +12810,7 @@ function Xw(e) {
|
|
|
12810
12810
|
return e.value !== "";
|
|
12811
12811
|
}
|
|
12812
12812
|
function Zw(e) {
|
|
12813
|
-
return /* @__PURE__ */ (0, Y.jsx)(
|
|
12813
|
+
return /* @__PURE__ */ (0, Y.jsx)(wi, {
|
|
12814
12814
|
value: e.value,
|
|
12815
12815
|
children: e.display
|
|
12816
12816
|
}, e.value);
|
|
@@ -12819,8 +12819,8 @@ function Qw(e) {
|
|
|
12819
12819
|
return e;
|
|
12820
12820
|
}
|
|
12821
12821
|
function $w(e) {
|
|
12822
|
-
let [t, n] =
|
|
12823
|
-
return /* @__PURE__ */ (0, Y.jsx)(
|
|
12822
|
+
let [t, n] = Ft[e];
|
|
12823
|
+
return /* @__PURE__ */ (0, Y.jsx)(wi, {
|
|
12824
12824
|
value: e,
|
|
12825
12825
|
className: "flex flex-row",
|
|
12826
12826
|
subtitle: /* @__PURE__ */ (0, Y.jsx)("span", {
|
|
@@ -12838,13 +12838,13 @@ function eT(e) {
|
|
|
12838
12838
|
}
|
|
12839
12839
|
function tT(e) {
|
|
12840
12840
|
let { value: t, Icon: n, subtitle: r } = e;
|
|
12841
|
-
return /* @__PURE__ */ (0, Y.jsx)(
|
|
12841
|
+
return /* @__PURE__ */ (0, Y.jsx)(wi, {
|
|
12842
12842
|
value: t,
|
|
12843
12843
|
className: "flex flex-col items-start justify-center",
|
|
12844
12844
|
subtitle: r,
|
|
12845
12845
|
children: /* @__PURE__ */ (0, Y.jsxs)("div", {
|
|
12846
12846
|
className: "flex items-center",
|
|
12847
|
-
children: [/* @__PURE__ */ (0, Y.jsx)(n, { className: "w-3 h-3 mr-2" }),
|
|
12847
|
+
children: [/* @__PURE__ */ (0, Y.jsx)(n, { className: "w-3 h-3 mr-2" }), Ni(t)]
|
|
12848
12848
|
})
|
|
12849
12849
|
}, t);
|
|
12850
12850
|
}
|
|
@@ -12863,8 +12863,8 @@ function iT(e) {
|
|
|
12863
12863
|
function aT(e) {
|
|
12864
12864
|
return {
|
|
12865
12865
|
display: /* @__PURE__ */ (0, Y.jsx)(Aw, {
|
|
12866
|
-
Icon: e === "ascending" ? Ou :
|
|
12867
|
-
text:
|
|
12866
|
+
Icon: e === "ascending" ? Ou : br,
|
|
12867
|
+
text: Ni(e)
|
|
12868
12868
|
}),
|
|
12869
12869
|
value: e
|
|
12870
12870
|
};
|
|
@@ -12872,7 +12872,7 @@ function aT(e) {
|
|
|
12872
12872
|
//#endregion
|
|
12873
12873
|
//#region src/components/data-table/charts/components/chart-items.tsx
|
|
12874
12874
|
function oT(e) {
|
|
12875
|
-
return
|
|
12875
|
+
return Yt(e?.field) && e?.field !== "__count__";
|
|
12876
12876
|
}
|
|
12877
12877
|
function sT(e) {
|
|
12878
12878
|
return e?.selectedDataType === "string" && oT(e);
|
|
@@ -12887,7 +12887,7 @@ function uT(e) {
|
|
|
12887
12887
|
return e?.selectedDataType !== "temporal" && oT(e);
|
|
12888
12888
|
}
|
|
12889
12889
|
function dT(e) {
|
|
12890
|
-
let t = e?.type ?
|
|
12890
|
+
let t = e?.type ? Ut(e.type) : "string";
|
|
12891
12891
|
return {
|
|
12892
12892
|
inferredDataType: t,
|
|
12893
12893
|
selectedDataType: e?.selectedDataType || t
|
|
@@ -12918,38 +12918,38 @@ var fT = (e) => {
|
|
|
12918
12918
|
t[0] === Symbol.for("react.memo_cache_sentinel") ? (i = p({
|
|
12919
12919
|
variant: "outline",
|
|
12920
12920
|
className: "user-select-none w-full justify-between px-3"
|
|
12921
|
-
}), a = /* @__PURE__ */ (0, Y.jsx)(
|
|
12921
|
+
}), a = /* @__PURE__ */ (0, Y.jsx)(Ci, {}), t[0] = i, t[1] = a) : (i = t[0], a = t[1]);
|
|
12922
12922
|
let o;
|
|
12923
|
-
t[2] === Symbol.for("react.memo_cache_sentinel") ? (o = /* @__PURE__ */ (0, Y.jsxs)(
|
|
12923
|
+
t[2] === Symbol.for("react.memo_cache_sentinel") ? (o = /* @__PURE__ */ (0, Y.jsxs)(bi, {
|
|
12924
12924
|
className: i,
|
|
12925
|
-
children: [a, /* @__PURE__ */ (0, Y.jsx)(
|
|
12925
|
+
children: [a, /* @__PURE__ */ (0, Y.jsx)(Mi, {
|
|
12926
12926
|
asChild: !0,
|
|
12927
|
-
children: /* @__PURE__ */ (0, Y.jsx)(
|
|
12927
|
+
children: /* @__PURE__ */ (0, Y.jsx)(_i, { className: "h-4 w-4 opacity-50" })
|
|
12928
12928
|
})]
|
|
12929
12929
|
}), t[2] = o) : o = t[2];
|
|
12930
12930
|
let s;
|
|
12931
12931
|
t[3] === Symbol.for("react.memo_cache_sentinel") ? (s = /* @__PURE__ */ (0, Y.jsxs)("div", {
|
|
12932
12932
|
className: "flex flex-row gap-2 items-center",
|
|
12933
|
-
children: [o, /* @__PURE__ */ (0, Y.jsx)(
|
|
12933
|
+
children: [o, /* @__PURE__ */ (0, Y.jsx)(Di, { children: qt.map(yT) })]
|
|
12934
12934
|
}), t[3] = s) : s = t[3];
|
|
12935
12935
|
let c;
|
|
12936
|
-
return t[4] !== r || t[5] !== n ? (c = /* @__PURE__ */ (0, Y.jsx)(
|
|
12936
|
+
return t[4] !== r || t[5] !== n ? (c = /* @__PURE__ */ (0, Y.jsx)(ji, {
|
|
12937
12937
|
value: n,
|
|
12938
12938
|
onValueChange: r,
|
|
12939
12939
|
children: s
|
|
12940
12940
|
}), t[4] = r, t[5] = n, t[6] = c) : c = t[6], c;
|
|
12941
12941
|
}, mT = (e) => {
|
|
12942
|
-
let t = (0, X.c)(10), { chartType: n } = e, r =
|
|
12942
|
+
let t = (0, X.c)(10), { chartType: n } = e, r = $t[n], i;
|
|
12943
12943
|
t[0] === r ? i = t[1] : (i = /* @__PURE__ */ (0, Y.jsx)(r, { className: "w-4 h-4 mr-2" }), t[0] = r, t[1] = i);
|
|
12944
12944
|
let a;
|
|
12945
|
-
t[2] === n ? a = t[3] : (a =
|
|
12945
|
+
t[2] === n ? a = t[3] : (a = Ni(n), t[2] = n, t[3] = a);
|
|
12946
12946
|
let o;
|
|
12947
12947
|
t[4] !== i || t[5] !== a ? (o = /* @__PURE__ */ (0, Y.jsxs)("div", {
|
|
12948
12948
|
className: "flex items-center",
|
|
12949
12949
|
children: [i, a]
|
|
12950
12950
|
}), t[4] = i, t[5] = a, t[6] = o) : o = t[6];
|
|
12951
12951
|
let s;
|
|
12952
|
-
return t[7] !== n || t[8] !== o ? (s = /* @__PURE__ */ (0, Y.jsx)(
|
|
12952
|
+
return t[7] !== n || t[8] !== o ? (s = /* @__PURE__ */ (0, Y.jsx)(wi, {
|
|
12953
12953
|
value: n,
|
|
12954
12954
|
className: "gap-2",
|
|
12955
12955
|
children: o
|
|
@@ -12959,7 +12959,7 @@ var fT = (e) => {
|
|
|
12959
12959
|
e[0] === t.control ? n = e[1] : (n = { control: t.control }, e[0] = t.control, e[1] = n);
|
|
12960
12960
|
let r = qp(n), i = ow(), a = r.general?.xColumn, o;
|
|
12961
12961
|
e[2] === a ? o = e[3] : (o = dT(a), e[2] = a, e[3] = o);
|
|
12962
|
-
let { inferredDataType: s } = o, c = i.chartType ===
|
|
12962
|
+
let { inferredDataType: s } = o, c = i.chartType === Wt.LINE || i.chartType === Wt.BAR || i.chartType === Wt.AREA, l;
|
|
12963
12963
|
e[4] === Symbol.for("react.memo_cache_sentinel") ? (l = /* @__PURE__ */ (0, Y.jsx)(Ew, { text: "X-Axis" }), e[4] = l) : l = e[4];
|
|
12964
12964
|
let u;
|
|
12965
12965
|
e[5] !== i.fields || e[6] !== a ? (u = /* @__PURE__ */ (0, Y.jsx)(fT, {
|
|
@@ -12997,13 +12997,13 @@ var fT = (e) => {
|
|
|
12997
12997
|
let e = (0, X.c)(29), t = Ip(), n;
|
|
12998
12998
|
e[0] === t.control ? n = e[1] : (n = { control: t.control }, e[0] = t.control, e[1] = n);
|
|
12999
12999
|
let r = qp(n), i = ow(), a = r.general?.yColumn, o = a?.field, s;
|
|
13000
|
-
e[2] === o ? s = e[3] : (s =
|
|
13000
|
+
e[2] === o ? s = e[3] : (s = Yt(o), e[2] = o, e[3] = s);
|
|
13001
13001
|
let c = s, l = r.general?.xColumn?.field, u;
|
|
13002
|
-
e[4] === l ? u = e[5] : (u =
|
|
13002
|
+
e[4] === l ? u = e[5] : (u = Yt(l), e[4] = l, e[5] = u);
|
|
13003
13003
|
let d = u, f;
|
|
13004
13004
|
e[6] === a ? f = e[7] : (f = dT(a), e[6] = a, e[7] = f);
|
|
13005
13005
|
let { inferredDataType: p } = f, m;
|
|
13006
|
-
cT(a) ? m =
|
|
13006
|
+
cT(a) ? m = tn : sT(a) && (m = "count");
|
|
13007
13007
|
let h;
|
|
13008
13008
|
e[8] === Symbol.for("react.memo_cache_sentinel") ? (h = /* @__PURE__ */ (0, Y.jsx)(Ew, { text: "Y-Axis" }), e[8] = h) : h = e[8];
|
|
13009
13009
|
let g;
|
|
@@ -13068,14 +13068,14 @@ var fT = (e) => {
|
|
|
13068
13068
|
e[0] === n.control ? r = e[1] : (r = { control: n.control }, e[0] = n.control, e[1] = r);
|
|
13069
13069
|
let i = qp(r), a;
|
|
13070
13070
|
e[2] !== t || e[3] !== i.general?.facet ? (a = (e) => {
|
|
13071
|
-
let n = i.general?.facet?.[e], r =
|
|
13071
|
+
let n = i.general?.facet?.[e], r = Yt(n?.field), { inferredDataType: a } = dT(n), o = e === "row" ? "general.facet.row.linkYAxis" : "general.facet.column.linkXAxis";
|
|
13072
13072
|
return /* @__PURE__ */ (0, Y.jsxs)("div", {
|
|
13073
13073
|
className: "flex flex-col gap-1",
|
|
13074
13074
|
children: [/* @__PURE__ */ (0, Y.jsxs)("div", {
|
|
13075
13075
|
className: "flex flex-row justify-between",
|
|
13076
13076
|
children: [/* @__PURE__ */ (0, Y.jsx)("p", {
|
|
13077
13077
|
className: "font-semibold",
|
|
13078
|
-
children:
|
|
13078
|
+
children: Ni(e)
|
|
13079
13079
|
}), /* @__PURE__ */ (0, Y.jsx)(Iw, {
|
|
13080
13080
|
fieldName: `general.facet.${e}.field`,
|
|
13081
13081
|
columns: t
|
|
@@ -13130,9 +13130,9 @@ var bT = () => {
|
|
|
13130
13130
|
let e = (0, X.c)(17), t = Ip(), n;
|
|
13131
13131
|
e[0] === t.control ? n = e[1] : (n = { control: t.control }, e[0] = t.control, e[1] = n);
|
|
13132
13132
|
let r = qp(n), i = r.general?.yColumn, a = r.general?.colorByColumn, o = i?.field, s;
|
|
13133
|
-
e[2] === o ? s = e[3] : (s =
|
|
13133
|
+
e[2] === o ? s = e[3] : (s = Yt(o), e[2] = o, e[3] = s);
|
|
13134
13134
|
let c = s, { chartType: l } = ow(), u;
|
|
13135
|
-
e[4] !== l || e[5] !== a?.field ? (u =
|
|
13135
|
+
e[4] !== l || e[5] !== a?.field ? (u = Yt(a?.field) && (l === Wt.BAR || l === Wt.LINE), e[4] = l, e[5] = a?.field, e[6] = u) : u = e[6];
|
|
13136
13136
|
let d = u, f, p, m;
|
|
13137
13137
|
e[7] === Symbol.for("react.memo_cache_sentinel") ? (f = /* @__PURE__ */ (0, Y.jsx)(me, {
|
|
13138
13138
|
delayDuration: 100,
|
|
@@ -13175,7 +13175,7 @@ var bT = () => {
|
|
|
13175
13175
|
label: "Plot title",
|
|
13176
13176
|
fieldName: "general.title"
|
|
13177
13177
|
}), e[1] = r) : r = e[1];
|
|
13178
|
-
let i = t ===
|
|
13178
|
+
let i = t === Wt.SCATTER, a;
|
|
13179
13179
|
e[2] === i ? a = e[3] : (a = /* @__PURE__ */ (0, Y.jsxs)(Mw, {
|
|
13180
13180
|
value: "general",
|
|
13181
13181
|
children: [n, /* @__PURE__ */ (0, Y.jsxs)(Nw, { children: [r, /* @__PURE__ */ (0, Y.jsx)(Bw, {
|
|
@@ -13222,15 +13222,15 @@ var bT = () => {
|
|
|
13222
13222
|
e[9] === Symbol.for("react.memo_cache_sentinel") ? (d = /* @__PURE__ */ (0, Y.jsx)(Lw, {
|
|
13223
13223
|
fieldName: "color.field",
|
|
13224
13224
|
label: "Field",
|
|
13225
|
-
options:
|
|
13226
|
-
defaultValue:
|
|
13225
|
+
options: Xt.map(CT),
|
|
13226
|
+
defaultValue: Qt
|
|
13227
13227
|
}), e[9] = d) : d = e[9];
|
|
13228
13228
|
let f, p;
|
|
13229
13229
|
e[10] === Symbol.for("react.memo_cache_sentinel") ? (f = /* @__PURE__ */ (0, Y.jsx)(Lw, {
|
|
13230
13230
|
fieldName: "color.scheme",
|
|
13231
13231
|
label: "Color scheme",
|
|
13232
|
-
defaultValue:
|
|
13233
|
-
options:
|
|
13232
|
+
defaultValue: Pt,
|
|
13233
|
+
options: nn.map(wT)
|
|
13234
13234
|
}), p = /* @__PURE__ */ (0, Y.jsx)(Hw, {
|
|
13235
13235
|
fieldName: "color.range",
|
|
13236
13236
|
label: "Color range"
|
|
@@ -13244,7 +13244,7 @@ var bT = () => {
|
|
|
13244
13244
|
p,
|
|
13245
13245
|
/* @__PURE__ */ (0, Y.jsxs)("p", {
|
|
13246
13246
|
className: "text-xs",
|
|
13247
|
-
children: [/* @__PURE__ */ (0, Y.jsx)(
|
|
13247
|
+
children: [/* @__PURE__ */ (0, Y.jsx)(Ct, { className: "w-2.5 h-2.5 inline mb-1 mr-1" }), "If you are using color range, color scheme will be ignored."]
|
|
13248
13248
|
})
|
|
13249
13249
|
] })]
|
|
13250
13250
|
}), e[12] = m) : m = e[12];
|
|
@@ -13300,13 +13300,13 @@ var bT = () => {
|
|
|
13300
13300
|
};
|
|
13301
13301
|
function CT(e) {
|
|
13302
13302
|
return {
|
|
13303
|
-
display:
|
|
13303
|
+
display: Ni(e),
|
|
13304
13304
|
value: e
|
|
13305
13305
|
};
|
|
13306
13306
|
}
|
|
13307
13307
|
function wT(e) {
|
|
13308
13308
|
return {
|
|
13309
|
-
display:
|
|
13309
|
+
display: Ni(e),
|
|
13310
13310
|
value: e
|
|
13311
13311
|
};
|
|
13312
13312
|
}
|
|
@@ -13316,9 +13316,9 @@ var TT = () => {
|
|
|
13316
13316
|
let e = (0, X.c)(17), t = Ip(), n;
|
|
13317
13317
|
e[0] === t.control ? n = e[1] : (n = { control: t.control }, e[0] = t.control, e[1] = n);
|
|
13318
13318
|
let r = qp(n), i = r.general?.xColumn?.field, a;
|
|
13319
|
-
e[2] === i ? a = e[3] : (a =
|
|
13319
|
+
e[2] === i ? a = e[3] : (a = Yt(i), e[2] = i, e[3] = a);
|
|
13320
13320
|
let o = a, s = r.general?.yColumn?.field, c;
|
|
13321
|
-
e[4] === s ? c = e[5] : (c =
|
|
13321
|
+
e[4] === s ? c = e[5] : (c = Yt(s), e[4] = s, e[5] = c);
|
|
13322
13322
|
let l = c, u;
|
|
13323
13323
|
e[6] === Symbol.for("react.memo_cache_sentinel") ? (u = /* @__PURE__ */ (0, Y.jsx)(hT, {}), e[6] = u) : u = e[6];
|
|
13324
13324
|
let d;
|
|
@@ -13352,7 +13352,7 @@ var TT = () => {
|
|
|
13352
13352
|
let i = qp(r), a = i.general?.colorByColumn, o = i.general?.yColumn?.selectedDataType;
|
|
13353
13353
|
(o === "" || !o) && (o = "string");
|
|
13354
13354
|
let s;
|
|
13355
|
-
e[2] === a ? s = e[3] : (s = a?.type ?
|
|
13355
|
+
e[2] === a ? s = e[3] : (s = a?.type ? Ut(a.type) : "string", e[2] = a, e[3] = s);
|
|
13356
13356
|
let c = s, l;
|
|
13357
13357
|
e[4] === Symbol.for("react.memo_cache_sentinel") ? (l = /* @__PURE__ */ (0, Y.jsx)(Ew, { text: "Color by" }), e[4] = l) : l = e[4];
|
|
13358
13358
|
let u;
|
|
@@ -13362,7 +13362,7 @@ var TT = () => {
|
|
|
13362
13362
|
includeCountField: !1
|
|
13363
13363
|
}), e[5] = n, e[6] = u);
|
|
13364
13364
|
let d;
|
|
13365
|
-
e[7] !== a?.field || e[8] !== c ? (d =
|
|
13365
|
+
e[7] !== a?.field || e[8] !== c ? (d = Yt(a?.field) && /* @__PURE__ */ (0, Y.jsx)(Ww, {
|
|
13366
13366
|
fieldName: "general.colorByColumn.selectedDataType",
|
|
13367
13367
|
label: "Data Type",
|
|
13368
13368
|
defaultValue: c
|
|
@@ -13410,11 +13410,11 @@ var TT = () => {
|
|
|
13410
13410
|
}
|
|
13411
13411
|
let o;
|
|
13412
13412
|
t[1] !== r || t[2] !== i || t[3] !== a ? (o = (e) => {
|
|
13413
|
-
if (typeof e == "string") return /* @__PURE__ */ (0, Y.jsx)(
|
|
13414
|
-
let t =
|
|
13413
|
+
if (typeof e == "string") return /* @__PURE__ */ (0, Y.jsx)(gn, { children: e });
|
|
13414
|
+
let t = Zt(e, r);
|
|
13415
13415
|
return /* @__PURE__ */ (0, Y.jsx)(J.Suspense, {
|
|
13416
13416
|
fallback: /* @__PURE__ */ (0, Y.jsx)(OT, {}),
|
|
13417
|
-
children: /* @__PURE__ */ (0, Y.jsx)(
|
|
13417
|
+
children: /* @__PURE__ */ (0, Y.jsx)(On, {
|
|
13418
13418
|
spec: t,
|
|
13419
13419
|
"data-container-width": Ls(t),
|
|
13420
13420
|
options: {
|
|
@@ -13440,7 +13440,7 @@ var TT = () => {
|
|
|
13440
13440
|
}), t[5] = n, t[6] = s, t[7] = c) : c = t[7], c;
|
|
13441
13441
|
}, OT = () => {
|
|
13442
13442
|
let e = (0, X.c)(1), t;
|
|
13443
|
-
return e[0] === Symbol.for("react.memo_cache_sentinel") ? (t = /* @__PURE__ */ (0, Y.jsx)(
|
|
13443
|
+
return e[0] === Symbol.for("react.memo_cache_sentinel") ? (t = /* @__PURE__ */ (0, Y.jsx)(gn, {
|
|
13444
13444
|
className: "mt-14",
|
|
13445
13445
|
children: "Loading chart..."
|
|
13446
13446
|
}), e[0] = t) : t = e[0], t;
|
|
@@ -13451,10 +13451,10 @@ var TT = () => {
|
|
|
13451
13451
|
}), AT = W({
|
|
13452
13452
|
field: U().optional(),
|
|
13453
13453
|
type: Io([...XS, ""]).catch("unknown").optional(),
|
|
13454
|
-
selectedDataType: Io([...
|
|
13455
|
-
sort: Io(
|
|
13456
|
-
timeUnit: Io(
|
|
13457
|
-
}), jT = AT.extend({ aggregate: Io(
|
|
13454
|
+
selectedDataType: Io([...zt, ""]).optional(),
|
|
13455
|
+
sort: Io(Jt).default("ascending").optional(),
|
|
13456
|
+
timeUnit: Io(Ht).optional()
|
|
13457
|
+
}), jT = AT.extend({ aggregate: Io(Lt).default(Qt).optional() }), MT = AT.extend({
|
|
13458
13458
|
linkYAxis: H().default(!0),
|
|
13459
13459
|
binned: H().default(!0),
|
|
13460
13460
|
maxbins: K().default(6)
|
|
@@ -13486,8 +13486,8 @@ var TT = () => {
|
|
|
13486
13486
|
bin: kT.optional()
|
|
13487
13487
|
}).optional(),
|
|
13488
13488
|
color: W({
|
|
13489
|
-
field: Io([...
|
|
13490
|
-
scheme: U().default(
|
|
13489
|
+
field: Io([...Xt, Qt]).default(Qt),
|
|
13490
|
+
scheme: U().default(Pt).optional(),
|
|
13491
13491
|
range: G(U()).optional(),
|
|
13492
13492
|
domain: G(U()).optional(),
|
|
13493
13493
|
bin: kT.optional()
|
|
@@ -13522,7 +13522,7 @@ function FT() {
|
|
|
13522
13522
|
}
|
|
13523
13523
|
} },
|
|
13524
13524
|
color: {
|
|
13525
|
-
field:
|
|
13525
|
+
field: Qt,
|
|
13526
13526
|
scheme: "default"
|
|
13527
13527
|
},
|
|
13528
13528
|
tooltips: {
|
|
@@ -13537,7 +13537,7 @@ var IT = "marimo:charts:v2", LT = W({
|
|
|
13537
13537
|
tabName: U().transform((e) => e),
|
|
13538
13538
|
chartType: U().transform((e) => e),
|
|
13539
13539
|
config: PT
|
|
13540
|
-
}), RT = G(to([U().transform((e) => e), G(LT)])), zT = new
|
|
13540
|
+
}), RT = G(to([U().transform((e) => e), G(LT)])), zT = new Ie(IT, RT, () => []), BT = {
|
|
13541
13541
|
getItem: (e) => {
|
|
13542
13542
|
try {
|
|
13543
13543
|
let t = zT.get(e);
|
|
@@ -13552,9 +13552,9 @@ var IT = "marimo:charts:v2", LT = W({
|
|
|
13552
13552
|
removeItem: (e) => {
|
|
13553
13553
|
zT.remove(e);
|
|
13554
13554
|
}
|
|
13555
|
-
}, VT =
|
|
13555
|
+
}, VT = ge(IT, /* @__PURE__ */ new Map(), BT);
|
|
13556
13556
|
function HT(e, t) {
|
|
13557
|
-
let n =
|
|
13557
|
+
let n = Ni(t);
|
|
13558
13558
|
return e === 0 ? `${n} Chart` : `${n} Chart ${e + 1}`;
|
|
13559
13559
|
}
|
|
13560
13560
|
var UT = BT.getItem(IT);
|
|
@@ -13612,24 +13612,24 @@ var ZT = ({ cellId: e, data: t, dataTable: n, totalRows: r, columns: i, getDataU
|
|
|
13612
13612
|
} : e), o = new Map(u).set(e, a);
|
|
13613
13613
|
d(o), m(a[i].tabName);
|
|
13614
13614
|
}, C = r === "too_many" || r > JT || i > YT;
|
|
13615
|
-
return /* @__PURE__ */ (0, Y.jsxs)(
|
|
13615
|
+
return /* @__PURE__ */ (0, Y.jsxs)(on, {
|
|
13616
13616
|
value: p,
|
|
13617
13617
|
className: "-mt-1",
|
|
13618
13618
|
children: [
|
|
13619
|
-
/* @__PURE__ */ (0, Y.jsxs)(
|
|
13619
|
+
/* @__PURE__ */ (0, Y.jsxs)(An, {
|
|
13620
13620
|
part: "table-tabs",
|
|
13621
13621
|
children: [
|
|
13622
|
-
/* @__PURE__ */ (0, Y.jsx)(
|
|
13622
|
+
/* @__PURE__ */ (0, Y.jsx)(Mn, {
|
|
13623
13623
|
className: "text-xs",
|
|
13624
13624
|
value: KT,
|
|
13625
13625
|
onClick: () => m(KT),
|
|
13626
13626
|
children: "Table"
|
|
13627
13627
|
}),
|
|
13628
|
-
f.map((e, t) => /* @__PURE__ */ (0, Y.jsxs)(
|
|
13628
|
+
f.map((e, t) => /* @__PURE__ */ (0, Y.jsxs)(Mn, {
|
|
13629
13629
|
className: "text-xs",
|
|
13630
13630
|
value: e.tabName,
|
|
13631
13631
|
onClick: () => m(e.tabName),
|
|
13632
|
-
children: [e.tabName, /* @__PURE__ */ (0, Y.jsx)(
|
|
13632
|
+
children: [e.tabName, /* @__PURE__ */ (0, Y.jsx)(pi, {
|
|
13633
13633
|
className: "w-3 h-3 ml-1 mt-[0.5px] hover:text-red-500 hover:font-semibold",
|
|
13634
13634
|
onClick: (t) => {
|
|
13635
13635
|
t.stopPropagation(), b(e.tabName);
|
|
@@ -13645,12 +13645,12 @@ var ZT = ({ cellId: e, data: t, dataTable: n, totalRows: r, columns: i, getDataU
|
|
|
13645
13645
|
})
|
|
13646
13646
|
]
|
|
13647
13647
|
}),
|
|
13648
|
-
/* @__PURE__ */ (0, Y.jsx)(
|
|
13648
|
+
/* @__PURE__ */ (0, Y.jsx)(Tr, {
|
|
13649
13649
|
className: "mt-1 overflow-hidden",
|
|
13650
13650
|
value: KT,
|
|
13651
13651
|
children: n
|
|
13652
13652
|
}),
|
|
13653
|
-
f.map((e, r) => /* @__PURE__ */ (0, Y.jsx)(
|
|
13653
|
+
f.map((e, r) => /* @__PURE__ */ (0, Y.jsx)(Tr, {
|
|
13654
13654
|
value: e.tabName,
|
|
13655
13655
|
className: "h-[400px] mt-0",
|
|
13656
13656
|
children: /* @__PURE__ */ (0, Y.jsx)($T, {
|
|
@@ -13668,7 +13668,7 @@ var ZT = ({ cellId: e, data: t, dataTable: n, totalRows: r, columns: i, getDataU
|
|
|
13668
13668
|
S(e.tabName, t);
|
|
13669
13669
|
},
|
|
13670
13670
|
getDataUrl: a,
|
|
13671
|
-
fieldTypes: XT(o ??
|
|
13671
|
+
fieldTypes: XT(o ?? Zr(n.props.data), s),
|
|
13672
13672
|
isLargeDataset: C
|
|
13673
13673
|
})
|
|
13674
13674
|
}, r))
|
|
@@ -13685,7 +13685,7 @@ var ZT = ({ cellId: e, data: t, dataTable: n, totalRows: r, columns: i, getDataU
|
|
|
13685
13685
|
type: "csv",
|
|
13686
13686
|
parse: "auto"
|
|
13687
13687
|
}, { replacePeriod: !0 });
|
|
13688
|
-
}, [e, m]), x = l.watch(), S = (0, J.useMemo)(() => structuredClone(x), [x]), C =
|
|
13688
|
+
}, [e, m]), x = l.watch(), S = (0, J.useMemo)(() => structuredClone(x), [x]), C = Kt(u, S, c, "container", qT), w = (0, J.useMemo)(() => y ? /* @__PURE__ */ (0, Y.jsx)(Sn, {}) : b ? /* @__PURE__ */ (0, Y.jsx)(In, { error: b }) : m ? /* @__PURE__ */ (0, Y.jsx)(DT, {
|
|
13689
13689
|
baseSpec: C,
|
|
13690
13690
|
data: v,
|
|
13691
13691
|
height: qT
|
|
@@ -13728,24 +13728,24 @@ var ZT = ({ cellId: e, data: t, dataTable: n, totalRows: r, columns: i, getDataU
|
|
|
13728
13728
|
className: "border-border ml-auto",
|
|
13729
13729
|
onClick: () => p((e) => !e),
|
|
13730
13730
|
title: f ? "Expand sidebar" : "Collapse sidebar",
|
|
13731
|
-
children: f ? /* @__PURE__ */ (0, Y.jsx)(
|
|
13731
|
+
children: f ? /* @__PURE__ */ (0, Y.jsx)(na, { className: "w-4 h-5" }) : /* @__PURE__ */ (0, Y.jsx)(jr, { className: "w-4 h-5" })
|
|
13732
13732
|
})]
|
|
13733
13733
|
}), /* @__PURE__ */ (0, Y.jsx)("div", {
|
|
13734
13734
|
className: "flex-1 overflow-auto h-full w-full mt-3",
|
|
13735
13735
|
children: (() => {
|
|
13736
13736
|
let e = QT;
|
|
13737
|
-
return typeof C != "string" && (e = rw(C, "_df", "_chart")), /* @__PURE__ */ (0, Y.jsxs)(
|
|
13737
|
+
return typeof C != "string" && (e = rw(C, "_df", "_chart")), /* @__PURE__ */ (0, Y.jsxs)(on, {
|
|
13738
13738
|
defaultValue: "chart",
|
|
13739
13739
|
children: [
|
|
13740
13740
|
/* @__PURE__ */ (0, Y.jsx)("div", {
|
|
13741
13741
|
className: "flex flex-row gap-1.5 items-center",
|
|
13742
|
-
children: /* @__PURE__ */ (0, Y.jsxs)(
|
|
13743
|
-
/* @__PURE__ */ (0, Y.jsxs)(
|
|
13742
|
+
children: /* @__PURE__ */ (0, Y.jsxs)(An, { children: [
|
|
13743
|
+
/* @__PURE__ */ (0, Y.jsxs)(Mn, {
|
|
13744
13744
|
value: "chart",
|
|
13745
13745
|
className: "h-6",
|
|
13746
|
-
children: [/* @__PURE__ */ (0, Y.jsx)(
|
|
13746
|
+
children: [/* @__PURE__ */ (0, Y.jsx)(Nt, { className: "text-muted-foreground mr-2 w-4 h-4" }), "Chart"]
|
|
13747
13747
|
}),
|
|
13748
|
-
/* @__PURE__ */ (0, Y.jsxs)(
|
|
13748
|
+
/* @__PURE__ */ (0, Y.jsxs)(Mn, {
|
|
13749
13749
|
value: "code",
|
|
13750
13750
|
className: "h-6",
|
|
13751
13751
|
children: [/* @__PURE__ */ (0, Y.jsx)(GC, { className: "text-muted-foreground mr-2" }), "Python code"]
|
|
@@ -13753,12 +13753,12 @@ var ZT = ({ cellId: e, data: t, dataTable: n, totalRows: r, columns: i, getDataU
|
|
|
13753
13753
|
!1
|
|
13754
13754
|
] })
|
|
13755
13755
|
}),
|
|
13756
|
-
/* @__PURE__ */ (0, Y.jsx)(
|
|
13756
|
+
/* @__PURE__ */ (0, Y.jsx)(Tr, {
|
|
13757
13757
|
value: "chart",
|
|
13758
13758
|
ref: g,
|
|
13759
13759
|
children: w
|
|
13760
13760
|
}),
|
|
13761
|
-
/* @__PURE__ */ (0, Y.jsx)(
|
|
13761
|
+
/* @__PURE__ */ (0, Y.jsx)(Tr, {
|
|
13762
13762
|
value: "code",
|
|
13763
13763
|
children: /* @__PURE__ */ (0, Y.jsx)(Pw, {
|
|
13764
13764
|
code: e,
|
|
@@ -13785,8 +13785,8 @@ var ZT = ({ cellId: e, data: t, dataTable: n, totalRows: r, columns: i, getDataU
|
|
|
13785
13785
|
let e = n.getValues();
|
|
13786
13786
|
r(e);
|
|
13787
13787
|
}, t[3] = n, t[4] = r, t[5] = c) : c = t[5];
|
|
13788
|
-
let l =
|
|
13789
|
-
a ===
|
|
13788
|
+
let l = Ii(c, 300), u = bT;
|
|
13789
|
+
a === Wt.PIE ? u = ET : a === Wt.HEATMAP && (u = TT);
|
|
13790
13790
|
let d;
|
|
13791
13791
|
t[6] !== a || t[7] !== l || t[8] !== s ? (d = {
|
|
13792
13792
|
fields: s,
|
|
@@ -13794,36 +13794,36 @@ var ZT = ({ cellId: e, data: t, dataTable: n, totalRows: r, columns: i, getDataU
|
|
|
13794
13794
|
chartType: a
|
|
13795
13795
|
}, t[6] = a, t[7] = l, t[8] = s, t[9] = d) : d = t[9];
|
|
13796
13796
|
let f;
|
|
13797
|
-
t[10] === Symbol.for("react.memo_cache_sentinel") ? (f = /* @__PURE__ */ (0, Y.jsxs)(
|
|
13797
|
+
t[10] === Symbol.for("react.memo_cache_sentinel") ? (f = /* @__PURE__ */ (0, Y.jsxs)(Mn, {
|
|
13798
13798
|
value: "data",
|
|
13799
13799
|
className: "w-1/2 h-6",
|
|
13800
|
-
children: [/* @__PURE__ */ (0, Y.jsx)(
|
|
13800
|
+
children: [/* @__PURE__ */ (0, Y.jsx)(Qe, { className: "w-4 h-4 mr-2" }), "Data"]
|
|
13801
13801
|
}), t[10] = f) : f = t[10];
|
|
13802
13802
|
let p;
|
|
13803
|
-
t[11] === Symbol.for("react.memo_cache_sentinel") ? (p = /* @__PURE__ */ (0, Y.jsxs)(
|
|
13803
|
+
t[11] === Symbol.for("react.memo_cache_sentinel") ? (p = /* @__PURE__ */ (0, Y.jsxs)(An, {
|
|
13804
13804
|
className: "w-full",
|
|
13805
|
-
children: [f, /* @__PURE__ */ (0, Y.jsxs)(
|
|
13805
|
+
children: [f, /* @__PURE__ */ (0, Y.jsxs)(Mn, {
|
|
13806
13806
|
value: "style",
|
|
13807
13807
|
className: "w-1/2 h-6",
|
|
13808
|
-
children: [/* @__PURE__ */ (0, Y.jsx)(
|
|
13808
|
+
children: [/* @__PURE__ */ (0, Y.jsx)(xt, { className: "w-4 h-4 mr-2" }), "Style"]
|
|
13809
13809
|
})]
|
|
13810
13810
|
}), t[11] = p) : p = t[11];
|
|
13811
13811
|
let m;
|
|
13812
13812
|
t[12] === Symbol.for("react.memo_cache_sentinel") ? (m = /* @__PURE__ */ (0, Y.jsx)("hr", { className: "my-2" }), t[12] = m) : m = t[12];
|
|
13813
13813
|
let h;
|
|
13814
|
-
t[13] === u ? h = t[14] : (h = /* @__PURE__ */ (0, Y.jsxs)(
|
|
13814
|
+
t[13] === u ? h = t[14] : (h = /* @__PURE__ */ (0, Y.jsxs)(Tr, {
|
|
13815
13815
|
value: "data",
|
|
13816
13816
|
children: [m, /* @__PURE__ */ (0, Y.jsx)(Dw, { children: /* @__PURE__ */ (0, Y.jsx)(u, {}) })]
|
|
13817
13817
|
}), t[13] = u, t[14] = h);
|
|
13818
13818
|
let g;
|
|
13819
13819
|
t[15] === Symbol.for("react.memo_cache_sentinel") ? (g = /* @__PURE__ */ (0, Y.jsx)("hr", { className: "my-2" }), t[15] = g) : g = t[15];
|
|
13820
13820
|
let _;
|
|
13821
|
-
t[16] === Symbol.for("react.memo_cache_sentinel") ? (_ = /* @__PURE__ */ (0, Y.jsxs)(
|
|
13821
|
+
t[16] === Symbol.for("react.memo_cache_sentinel") ? (_ = /* @__PURE__ */ (0, Y.jsxs)(Tr, {
|
|
13822
13822
|
value: "style",
|
|
13823
13823
|
children: [g, /* @__PURE__ */ (0, Y.jsx)(Dw, { children: /* @__PURE__ */ (0, Y.jsx)(xT, {}) })]
|
|
13824
13824
|
}), t[16] = _) : _ = t[16];
|
|
13825
13825
|
let v;
|
|
13826
|
-
t[17] === h ? v = t[18] : (v = /* @__PURE__ */ (0, Y.jsxs)(
|
|
13826
|
+
t[17] === h ? v = t[18] : (v = /* @__PURE__ */ (0, Y.jsxs)(on, {
|
|
13827
13827
|
defaultValue: "data",
|
|
13828
13828
|
children: [
|
|
13829
13829
|
p,
|
|
@@ -13860,7 +13860,7 @@ function nE(e) {
|
|
|
13860
13860
|
//#endregion
|
|
13861
13861
|
//#region src/components/data-table/hooks/use-panel-ownership.ts
|
|
13862
13862
|
function rE(e, t) {
|
|
13863
|
-
let n = (0, X.c)(16), r = rs(w_), { focusCell: i } =
|
|
13863
|
+
let n = (0, X.c)(16), r = rs(w_), { focusCell: i } = xe(), a = Ne(), [o, s] = as(S_), [l, u] = as(x_), [d, f] = as(C_), p = iE(e, t);
|
|
13864
13864
|
!t && r && (c.error("CellId is not found, defaulting to fixed mode"), r = !1);
|
|
13865
13865
|
let m = (e) => l === p && d && e === o, h = a === t, g = l && aE(l, t);
|
|
13866
13866
|
r && h && l !== p && !g && u(p);
|
|
@@ -13901,7 +13901,7 @@ var oE = zS.input(W({ format: Io([
|
|
|
13901
13901
|
function sE({ error: e, missingPackages: t, refetchPreview: n }) {
|
|
13902
13902
|
return /* @__PURE__ */ (0, Y.jsxs)("div", {
|
|
13903
13903
|
className: "text-xs text-muted-foreground p-2 border border-border rounded flex items-center justify-between",
|
|
13904
|
-
children: [/* @__PURE__ */ (0, Y.jsx)("span", { children: e }), t && /* @__PURE__ */ (0, Y.jsx)(
|
|
13904
|
+
children: [/* @__PURE__ */ (0, Y.jsx)("span", { children: e }), t && /* @__PURE__ */ (0, Y.jsx)(_r, {
|
|
13905
13905
|
packages: t,
|
|
13906
13906
|
showMaxPackages: 1,
|
|
13907
13907
|
className: "w-32",
|
|
@@ -13917,11 +13917,11 @@ function cE({ stats: e, dataType: t, locale: n }) {
|
|
|
13917
13917
|
children: [
|
|
13918
13918
|
/* @__PURE__ */ (0, Y.jsx)("span", {
|
|
13919
13919
|
className: "text-xs min-w-[60px] capitalize",
|
|
13920
|
-
children:
|
|
13920
|
+
children: qe(e, t)
|
|
13921
13921
|
}),
|
|
13922
13922
|
/* @__PURE__ */ (0, Y.jsx)("span", {
|
|
13923
13923
|
className: "text-xs font-bold text-muted-foreground tracking-wide",
|
|
13924
|
-
children:
|
|
13924
|
+
children: la(r, n)
|
|
13925
13925
|
}),
|
|
13926
13926
|
/* @__PURE__ */ (0, Y.jsx)(w, {
|
|
13927
13927
|
className: "h-3 w-3 invisible group-hover:visible",
|
|
@@ -13938,7 +13938,7 @@ var lE = /* @__PURE__ */ (0, Y.jsx)("div", {
|
|
|
13938
13938
|
function uE(e, t) {
|
|
13939
13939
|
return /* @__PURE__ */ (0, Y.jsx)(J.Suspense, {
|
|
13940
13940
|
fallback: lE,
|
|
13941
|
-
children: /* @__PURE__ */ (0, Y.jsx)(
|
|
13941
|
+
children: /* @__PURE__ */ (0, Y.jsx)(On, {
|
|
13942
13942
|
"data-container-width": "container",
|
|
13943
13943
|
spec: ((e) => ({
|
|
13944
13944
|
...e,
|
|
@@ -13959,9 +13959,9 @@ function uE(e, t) {
|
|
|
13959
13959
|
});
|
|
13960
13960
|
}
|
|
13961
13961
|
var dE = (e) => {
|
|
13962
|
-
let t = (0, X.c)(10), { chartCode: n } = e, r = rs(ls), i =
|
|
13962
|
+
let t = (0, X.c)(10), { chartCode: n } = e, r = rs(ls), i = Ne(), { createNewCell: a } = ot(), o;
|
|
13963
13963
|
t[0] !== r || t[1] !== a || t[2] !== i ? (o = (e) => {
|
|
13964
|
-
e.includes("alt") &&
|
|
13964
|
+
e.includes("alt") && ct({
|
|
13965
13965
|
autoInstantiate: r,
|
|
13966
13966
|
createNewCell: a,
|
|
13967
13967
|
fromCellId: i
|
|
@@ -13991,7 +13991,7 @@ var dE = (e) => {
|
|
|
13991
13991
|
//#endregion
|
|
13992
13992
|
//#region src/components/data-table/column-explorer-panel/column-explorer.tsx
|
|
13993
13993
|
function fE({ previewColumn: e, fieldTypes: t, totalRows: n, totalColumns: r, tableId: i, table: a }) {
|
|
13994
|
-
let [o, s] = (0, J.useState)(""), { locale: c } = Xo(), l = t?.filter(([e]) => !(e === "__select__" || e === "_marimo_row_id" || e.startsWith("__m_column__"))), u = l?.filter(([e]) =>
|
|
13994
|
+
let [o, s] = (0, J.useState)(""), { locale: c } = Xo(), l = t?.filter(([e]) => !(e === "__select__" || e === "_marimo_row_id" || e.startsWith("__m_column__"))), u = l?.filter(([e]) => rn(o, e)), { totalColumns: d, hiddenColumns: f } = jn(a, r), { visible: p } = hn(a), m = Fn(a), { rowsAndColumns: h, hiddenSuffix: g } = wr({
|
|
13995
13995
|
numRows: n,
|
|
13996
13996
|
totalColumns: d,
|
|
13997
13997
|
locale: c,
|
|
@@ -14021,7 +14021,7 @@ function fE({ previewColumn: e, fieldTypes: t, totalRows: n, totalColumns: r, ta
|
|
|
14021
14021
|
className: "gap-1",
|
|
14022
14022
|
disabled: f === 0,
|
|
14023
14023
|
onClick: () => a.toggleAllColumnsVisible(!0),
|
|
14024
|
-
children: [/* @__PURE__ */ (0, Y.jsx)(
|
|
14024
|
+
children: [/* @__PURE__ */ (0, Y.jsx)(ut, { className: "w-3 h-3" }), "Show all"]
|
|
14025
14025
|
})
|
|
14026
14026
|
}), /* @__PURE__ */ (0, Y.jsx)(me, {
|
|
14027
14027
|
content: "Hide all columns",
|
|
@@ -14033,21 +14033,21 @@ function fE({ previewColumn: e, fieldTypes: t, totalRows: n, totalColumns: r, ta
|
|
|
14033
14033
|
className: "gap-1",
|
|
14034
14034
|
disabled: p === 0,
|
|
14035
14035
|
onClick: () => a.toggleAllColumnsVisible(!1),
|
|
14036
|
-
children: [/* @__PURE__ */ (0, Y.jsx)(
|
|
14036
|
+
children: [/* @__PURE__ */ (0, Y.jsx)(rr, { className: "w-3 h-3" }), "Hide all"]
|
|
14037
14037
|
})
|
|
14038
14038
|
})]
|
|
14039
14039
|
})
|
|
14040
14040
|
]
|
|
14041
|
-
}), /* @__PURE__ */ (0, Y.jsxs)(
|
|
14041
|
+
}), /* @__PURE__ */ (0, Y.jsxs)(Br, {
|
|
14042
14042
|
className: "h-5/6 bg-background",
|
|
14043
14043
|
shouldFilter: !1,
|
|
14044
|
-
children: [/* @__PURE__ */ (0, Y.jsx)(
|
|
14044
|
+
children: [/* @__PURE__ */ (0, Y.jsx)($n, {
|
|
14045
14045
|
placeholder: "Search columns...",
|
|
14046
14046
|
value: o,
|
|
14047
14047
|
onValueChange: (e) => s(e)
|
|
14048
|
-
}), /* @__PURE__ */ (0, Y.jsxs)(
|
|
14048
|
+
}), /* @__PURE__ */ (0, Y.jsxs)(er, {
|
|
14049
14049
|
className: "max-h-full",
|
|
14050
|
-
children: [/* @__PURE__ */ (0, Y.jsx)(
|
|
14050
|
+
children: [/* @__PURE__ */ (0, Y.jsx)(wn, { children: "No results." }), u?.map(([t, [n, r]], o) => {
|
|
14051
14051
|
let s = a.getColumn(t);
|
|
14052
14052
|
return /* @__PURE__ */ (0, Y.jsx)(pE, {
|
|
14053
14053
|
columnName: t,
|
|
@@ -14066,12 +14066,12 @@ function fE({ previewColumn: e, fieldTypes: t, totalRows: n, totalColumns: r, ta
|
|
|
14066
14066
|
}
|
|
14067
14067
|
function pE({ columnName: e, column: t, dataType: n, externalType: r, previewColumn: i, table: a, showOnlyColumnState: o, defaultExpanded: s = !1 }) {
|
|
14068
14068
|
let [c, u] = (0, J.useState)(s);
|
|
14069
|
-
return /* @__PURE__ */ (0, Y.jsxs)(Y.Fragment, { children: [/* @__PURE__ */ (0, Y.jsxs)(
|
|
14069
|
+
return /* @__PURE__ */ (0, Y.jsxs)(Y.Fragment, { children: [/* @__PURE__ */ (0, Y.jsxs)(Zn, {
|
|
14070
14070
|
onSelect: () => u(!c),
|
|
14071
14071
|
className: "flex flex-row items-center gap-1.5 group w-full cursor-pointer",
|
|
14072
14072
|
children: [
|
|
14073
|
-
c ? /* @__PURE__ */ (0, Y.jsx)(
|
|
14074
|
-
/* @__PURE__ */ (0, Y.jsx)(
|
|
14073
|
+
c ? /* @__PURE__ */ (0, Y.jsx)(_i, { className: "w-3 h-3 shrink-0 text-muted-foreground" }) : /* @__PURE__ */ (0, Y.jsx)(na, { className: "w-3 h-3 shrink-0 text-muted-foreground" }),
|
|
14074
|
+
/* @__PURE__ */ (0, Y.jsx)(pn, {
|
|
14075
14075
|
columnName: /* @__PURE__ */ (0, Y.jsx)("span", {
|
|
14076
14076
|
className: c ? "font-semibold" : "",
|
|
14077
14077
|
children: e
|
|
@@ -14087,10 +14087,10 @@ function pE({ columnName: e, column: t, dataType: n, externalType: r, previewCol
|
|
|
14087
14087
|
className: "h-3 w-3",
|
|
14088
14088
|
buttonClassName: l("inline-flex items-center justify-center rounded-md h-6 w-6", "group-hover:opacity-100 opacity-0 hover:bg-muted text-muted-foreground hover:text-primary")
|
|
14089
14089
|
}),
|
|
14090
|
-
t?.getCanHide() && /* @__PURE__ */ (0, Y.jsxs)(Y.Fragment, { children: [/* @__PURE__ */ (0, Y.jsx)(
|
|
14090
|
+
t?.getCanHide() && /* @__PURE__ */ (0, Y.jsxs)(Y.Fragment, { children: [/* @__PURE__ */ (0, Y.jsx)(Hn, {
|
|
14091
14091
|
table: a,
|
|
14092
14092
|
columnIds: [e],
|
|
14093
|
-
disabled:
|
|
14093
|
+
disabled: xn(o, [e]),
|
|
14094
14094
|
className: l(t.getIsVisible() ? "group-hover:opacity-100 opacity-0" : "opacity-100")
|
|
14095
14095
|
}), /* @__PURE__ */ (0, Y.jsx)(me, {
|
|
14096
14096
|
content: t.getIsVisible() ? "Hide column" : "Show column",
|
|
@@ -14104,10 +14104,10 @@ function pE({ columnName: e, column: t, dataType: n, externalType: r, previewCol
|
|
|
14104
14104
|
onClick: (e) => {
|
|
14105
14105
|
e.preventDefault(), e.stopPropagation(), t.toggleVisibility(!t.getIsVisible());
|
|
14106
14106
|
},
|
|
14107
|
-
children: t.getIsVisible() ? /* @__PURE__ */ (0, Y.jsx)(
|
|
14107
|
+
children: t.getIsVisible() ? /* @__PURE__ */ (0, Y.jsx)(ut, {
|
|
14108
14108
|
className: "h-3 w-3",
|
|
14109
14109
|
strokeWidth: 2.5
|
|
14110
|
-
}) : /* @__PURE__ */ (0, Y.jsx)(
|
|
14110
|
+
}) : /* @__PURE__ */ (0, Y.jsx)(rr, {
|
|
14111
14111
|
className: "h-3 w-3",
|
|
14112
14112
|
strokeWidth: 2.5
|
|
14113
14113
|
})
|
|
@@ -14128,9 +14128,9 @@ function pE({ columnName: e, column: t, dataType: n, externalType: r, previewCol
|
|
|
14128
14128
|
}
|
|
14129
14129
|
var mE = ({ previewColumn: e, columnName: t, dataType: n }) => {
|
|
14130
14130
|
let { theme: r } = fs(), { locale: i } = Xo(), { data: a, error: o, isPending: s, refetch: c } = Ns(async () => await e({ column: t }), []);
|
|
14131
|
-
if (o) return /* @__PURE__ */ (0, Y.jsx)(
|
|
14132
|
-
if (s) return /* @__PURE__ */ (0, Y.jsx)(
|
|
14133
|
-
if (!a) return /* @__PURE__ */ (0, Y.jsx)(
|
|
14131
|
+
if (o) return /* @__PURE__ */ (0, Y.jsx)(Er, { error: o });
|
|
14132
|
+
if (s) return /* @__PURE__ */ (0, Y.jsx)(an, { message: "Loading..." });
|
|
14133
|
+
if (!a) return /* @__PURE__ */ (0, Y.jsx)(Nn, {
|
|
14134
14134
|
content: "No data",
|
|
14135
14135
|
className: "pl-4"
|
|
14136
14136
|
});
|
|
@@ -14143,7 +14143,7 @@ var mE = ({ previewColumn: e, columnName: t, dataType: n }) => {
|
|
|
14143
14143
|
dataType: n,
|
|
14144
14144
|
locale: i
|
|
14145
14145
|
}), g = l && uE(l, r);
|
|
14146
|
-
return /* @__PURE__ */ (0, Y.jsxs)(
|
|
14146
|
+
return /* @__PURE__ */ (0, Y.jsxs)(dn, {
|
|
14147
14147
|
className: "px-2 py-1",
|
|
14148
14148
|
children: [
|
|
14149
14149
|
m,
|
|
@@ -14153,7 +14153,7 @@ var mE = ({ previewColumn: e, columnName: t, dataType: n }) => {
|
|
|
14153
14153
|
]
|
|
14154
14154
|
});
|
|
14155
14155
|
}, hE = ({ rowIdx: e, setRowIdx: t, totalRows: n, fieldTypes: r, getRow: i, isSelectable: a, isRowSelected: o, handleRowSelectionChange: s }) => {
|
|
14156
|
-
let [c, l] = (0, J.useState)(""), u = (0, J.useRef)(null), d = (0, J.useId)(), { locale: f } = Xo(), p = n ===
|
|
14156
|
+
let [c, l] = (0, J.useState)(""), u = (0, J.useRef)(null), d = (0, J.useId)(), { locale: f } = Xo(), p = n === Vn, { data: m, error: h } = Ns(async () => (await i(e)).rows, [
|
|
14157
14157
|
i,
|
|
14158
14158
|
e,
|
|
14159
14159
|
n
|
|
@@ -14197,7 +14197,7 @@ var mE = ({ previewColumn: e, columnName: t, dataType: n }) => {
|
|
|
14197
14197
|
title: "Select/unselect the current row",
|
|
14198
14198
|
children: [/* @__PURE__ */ (0, Y.jsxs)("div", {
|
|
14199
14199
|
className: "flex items-center gap-1.5",
|
|
14200
|
-
children: [/* @__PURE__ */ (0, Y.jsx)(
|
|
14200
|
+
children: [/* @__PURE__ */ (0, Y.jsx)(Me, {
|
|
14201
14201
|
id: d,
|
|
14202
14202
|
checked: o,
|
|
14203
14203
|
onCheckedChange: v,
|
|
@@ -14219,7 +14219,7 @@ var mE = ({ previewColumn: e, columnName: t, dataType: n }) => {
|
|
|
14219
14219
|
onClick: () => g(0),
|
|
14220
14220
|
disabled: e === 0,
|
|
14221
14221
|
"aria-label": "Go to first row",
|
|
14222
|
-
children: /* @__PURE__ */ (0, Y.jsx)(
|
|
14222
|
+
children: /* @__PURE__ */ (0, Y.jsx)(hr, {})
|
|
14223
14223
|
}),
|
|
14224
14224
|
/* @__PURE__ */ (0, Y.jsx)(_, {
|
|
14225
14225
|
variant: "outline",
|
|
@@ -14228,11 +14228,11 @@ var mE = ({ previewColumn: e, columnName: t, dataType: n }) => {
|
|
|
14228
14228
|
onClick: () => g(e - 1),
|
|
14229
14229
|
disabled: e === 0,
|
|
14230
14230
|
"aria-label": "Previous row",
|
|
14231
|
-
children: /* @__PURE__ */ (0, Y.jsx)(
|
|
14231
|
+
children: /* @__PURE__ */ (0, Y.jsx)(jr, {})
|
|
14232
14232
|
}),
|
|
14233
14233
|
/* @__PURE__ */ (0, Y.jsx)("span", {
|
|
14234
14234
|
className: "text-xs",
|
|
14235
|
-
children: p ? `Row ${e + 1}` : `Row ${e + 1} of ${
|
|
14235
|
+
children: p ? `Row ${e + 1}` : `Row ${e + 1} of ${kn(n, f)}`
|
|
14236
14236
|
}),
|
|
14237
14237
|
/* @__PURE__ */ (0, Y.jsx)(_, {
|
|
14238
14238
|
variant: "outline",
|
|
@@ -14241,7 +14241,7 @@ var mE = ({ previewColumn: e, columnName: t, dataType: n }) => {
|
|
|
14241
14241
|
onClick: () => g(e + 1),
|
|
14242
14242
|
disabled: !p && e === n - 1,
|
|
14243
14243
|
"aria-label": "Next row",
|
|
14244
|
-
children: /* @__PURE__ */ (0, Y.jsx)(
|
|
14244
|
+
children: /* @__PURE__ */ (0, Y.jsx)(na, {})
|
|
14245
14245
|
}),
|
|
14246
14246
|
/* @__PURE__ */ (0, Y.jsx)(_, {
|
|
14247
14247
|
variant: "outline",
|
|
@@ -14252,14 +14252,14 @@ var mE = ({ previewColumn: e, columnName: t, dataType: n }) => {
|
|
|
14252
14252
|
},
|
|
14253
14253
|
disabled: p || e === n - 1,
|
|
14254
14254
|
"aria-label": "Go to last row",
|
|
14255
|
-
children: /* @__PURE__ */ (0, Y.jsx)(
|
|
14255
|
+
children: /* @__PURE__ */ (0, Y.jsx)(ur, {})
|
|
14256
14256
|
})
|
|
14257
14257
|
]
|
|
14258
14258
|
}),
|
|
14259
|
-
/* @__PURE__ */ (0, Y.jsx)(
|
|
14259
|
+
/* @__PURE__ */ (0, Y.jsx)(Br, {
|
|
14260
14260
|
className: "bg-background",
|
|
14261
14261
|
shouldFilter: !1,
|
|
14262
|
-
children: /* @__PURE__ */ (0, Y.jsx)(
|
|
14262
|
+
children: /* @__PURE__ */ (0, Y.jsx)($n, {
|
|
14263
14263
|
placeholder: "Search",
|
|
14264
14264
|
value: c,
|
|
14265
14265
|
onValueChange: l,
|
|
@@ -14273,10 +14273,10 @@ var mE = ({ previewColumn: e, columnName: t, dataType: n }) => {
|
|
|
14273
14273
|
});
|
|
14274
14274
|
if (n === 0) return /* @__PURE__ */ (0, Y.jsx)(_E, {
|
|
14275
14275
|
kind: "info",
|
|
14276
|
-
Icon:
|
|
14276
|
+
Icon: Ct,
|
|
14277
14277
|
message: "No rows selected"
|
|
14278
14278
|
});
|
|
14279
|
-
if (!m) return /* @__PURE__ */ (0, Y.jsx)(
|
|
14279
|
+
if (!m) return /* @__PURE__ */ (0, Y.jsx)(Mr, {
|
|
14280
14280
|
milliseconds: 200,
|
|
14281
14281
|
children: /* @__PURE__ */ (0, Y.jsx)(ne, {
|
|
14282
14282
|
size: "medium",
|
|
@@ -14298,23 +14298,23 @@ var mE = ({ previewColumn: e, columnName: t, dataType: n }) => {
|
|
|
14298
14298
|
message: "Row is not an object. Please report the issue."
|
|
14299
14299
|
});
|
|
14300
14300
|
let t = {};
|
|
14301
|
-
for (let [n, r] of Object.entries(e)) n !== "__select__" && n !== "_marimo_row_id" && (n.startsWith("__m_column__") ? t[n.slice(
|
|
14302
|
-
return /* @__PURE__ */ (0, Y.jsxs)(
|
|
14301
|
+
for (let [n, r] of Object.entries(e)) n !== "__select__" && n !== "_marimo_row_id" && (n.startsWith("__m_column__") ? t[n.slice(cr.length)] = r : t[n] = r);
|
|
14302
|
+
return /* @__PURE__ */ (0, Y.jsxs)(Pr, {
|
|
14303
14303
|
className: "mb-4",
|
|
14304
|
-
children: [/* @__PURE__ */ (0, Y.jsx)(
|
|
14304
|
+
children: [/* @__PURE__ */ (0, Y.jsx)(Fr, { children: /* @__PURE__ */ (0, Y.jsxs)(Gr, { children: [/* @__PURE__ */ (0, Y.jsx)(ir, {
|
|
14305
14305
|
className: "w-1/4",
|
|
14306
14306
|
children: "Column"
|
|
14307
|
-
}), /* @__PURE__ */ (0, Y.jsx)(
|
|
14307
|
+
}), /* @__PURE__ */ (0, Y.jsx)(ir, {
|
|
14308
14308
|
className: "w-3/4",
|
|
14309
14309
|
children: "Value"
|
|
14310
|
-
})] }) }), /* @__PURE__ */ (0, Y.jsx)(
|
|
14310
|
+
})] }) }), /* @__PURE__ */ (0, Y.jsx)(Ur, { children: r?.map(([e, [n, r]]) => {
|
|
14311
14311
|
let i = t[e];
|
|
14312
14312
|
if (!gE({
|
|
14313
14313
|
columnName: e,
|
|
14314
14314
|
columnValue: i,
|
|
14315
14315
|
searchQuery: c
|
|
14316
14316
|
})) return null;
|
|
14317
|
-
let a =
|
|
14317
|
+
let a = dr({
|
|
14318
14318
|
column: {
|
|
14319
14319
|
id: e,
|
|
14320
14320
|
columnDef: { meta: {
|
|
@@ -14329,12 +14329,12 @@ var mE = ({ previewColumn: e, columnName: t, dataType: n }) => {
|
|
|
14329
14329
|
selectCell: void 0,
|
|
14330
14330
|
cellStyles: "text-left break-word"
|
|
14331
14331
|
}), o = typeof i == "object" ? JSON.stringify(i) : String(i);
|
|
14332
|
-
return /* @__PURE__ */ (0, Y.jsxs)(
|
|
14332
|
+
return /* @__PURE__ */ (0, Y.jsxs)(Gr, {
|
|
14333
14333
|
className: "group",
|
|
14334
|
-
children: [/* @__PURE__ */ (0, Y.jsx)(
|
|
14334
|
+
children: [/* @__PURE__ */ (0, Y.jsx)(Cr, { children: /* @__PURE__ */ (0, Y.jsx)(pn, {
|
|
14335
14335
|
columnName: /* @__PURE__ */ (0, Y.jsx)("span", { children: e }),
|
|
14336
14336
|
dataType: n
|
|
14337
|
-
}) }), /* @__PURE__ */ (0, Y.jsx)(
|
|
14337
|
+
}) }), /* @__PURE__ */ (0, Y.jsx)(Cr, { children: /* @__PURE__ */ (0, Y.jsxs)("div", {
|
|
14338
14338
|
className: "flex flex-row items-center justify-between gap-1",
|
|
14339
14339
|
children: [a, /* @__PURE__ */ (0, Y.jsx)(w, {
|
|
14340
14340
|
value: o,
|
|
@@ -14383,22 +14383,22 @@ function xE({ rowIdx: e, setRowIdx: t, totalRows: n, fieldTypes: r, getRow: i, i
|
|
|
14383
14383
|
table: f
|
|
14384
14384
|
});
|
|
14385
14385
|
if (!v) return p ? y : m ? b : null;
|
|
14386
|
-
let x = h ??
|
|
14387
|
-
return /* @__PURE__ */ (0, Y.jsxs)(
|
|
14386
|
+
let x = h ?? Cn.ROW_VIEWER;
|
|
14387
|
+
return /* @__PURE__ */ (0, Y.jsxs)(on, {
|
|
14388
14388
|
value: x,
|
|
14389
14389
|
onValueChange: (e) => g(e),
|
|
14390
14390
|
className: "flex flex-col min-w-[350px]",
|
|
14391
14391
|
children: [
|
|
14392
|
-
/* @__PURE__ */ (0, Y.jsx)(
|
|
14393
|
-
name:
|
|
14392
|
+
/* @__PURE__ */ (0, Y.jsx)(pr, {
|
|
14393
|
+
name: Qn.CONTEXT_AWARE_PANEL_HEADER,
|
|
14394
14394
|
children: /* @__PURE__ */ (0, Y.jsxs)("div", {
|
|
14395
14395
|
className: "flex items-center gap-1",
|
|
14396
14396
|
children: [
|
|
14397
14397
|
/* @__PURE__ */ (0, Y.jsx)(_, {
|
|
14398
14398
|
variant: "text",
|
|
14399
14399
|
size: "xs",
|
|
14400
|
-
onClick: () => g(
|
|
14401
|
-
className: l(vE, x ===
|
|
14400
|
+
onClick: () => g(Cn.ROW_VIEWER),
|
|
14401
|
+
className: l(vE, x === Cn.ROW_VIEWER ? yE : bE),
|
|
14402
14402
|
children: "Rows"
|
|
14403
14403
|
}),
|
|
14404
14404
|
/* @__PURE__ */ (0, Y.jsx)("span", {
|
|
@@ -14408,20 +14408,20 @@ function xE({ rowIdx: e, setRowIdx: t, totalRows: n, fieldTypes: r, getRow: i, i
|
|
|
14408
14408
|
/* @__PURE__ */ (0, Y.jsx)(_, {
|
|
14409
14409
|
variant: "text",
|
|
14410
14410
|
size: "xs",
|
|
14411
|
-
onClick: () => g(
|
|
14412
|
-
className: l(vE, x ===
|
|
14411
|
+
onClick: () => g(Cn.COLUMN_EXPLORER),
|
|
14412
|
+
className: l(vE, x === Cn.COLUMN_EXPLORER ? yE : bE),
|
|
14413
14413
|
children: "Columns"
|
|
14414
14414
|
})
|
|
14415
14415
|
]
|
|
14416
14416
|
})
|
|
14417
14417
|
}),
|
|
14418
|
-
/* @__PURE__ */ (0, Y.jsx)(
|
|
14419
|
-
value:
|
|
14418
|
+
/* @__PURE__ */ (0, Y.jsx)(Tr, {
|
|
14419
|
+
value: Cn.ROW_VIEWER,
|
|
14420
14420
|
className: "flex-1 overflow-auto",
|
|
14421
14421
|
children: y
|
|
14422
14422
|
}),
|
|
14423
|
-
/* @__PURE__ */ (0, Y.jsx)(
|
|
14424
|
-
value:
|
|
14423
|
+
/* @__PURE__ */ (0, Y.jsx)(Tr, {
|
|
14424
|
+
value: Cn.COLUMN_EXPLORER,
|
|
14425
14425
|
className: "flex-1 overflow-auto",
|
|
14426
14426
|
children: b
|
|
14427
14427
|
})
|
|
@@ -14484,7 +14484,7 @@ var CE = no([
|
|
|
14484
14484
|
label: U().nullable(),
|
|
14485
14485
|
data: no([U(), G(W({}).passthrough())]),
|
|
14486
14486
|
rawData: no([U(), G(io({}))]).nullish(),
|
|
14487
|
-
totalRows: no([K(), Xa(
|
|
14487
|
+
totalRows: no([K(), Xa(Vn)]),
|
|
14488
14488
|
pagination: H().default(!1),
|
|
14489
14489
|
pageSize: K().default(10),
|
|
14490
14490
|
selection: Io([
|
|
@@ -14546,7 +14546,7 @@ var CE = no([
|
|
|
14546
14546
|
max_columns: K().nullable().optional()
|
|
14547
14547
|
})).output(W({
|
|
14548
14548
|
data: no([U(), G(W({}).passthrough())]),
|
|
14549
|
-
total_rows: no([K(), Xa(
|
|
14549
|
+
total_rows: no([K(), Xa(Vn)]),
|
|
14550
14550
|
cell_styles: ao(U(), ao(U(), W({}).passthrough())).nullable(),
|
|
14551
14551
|
cell_hover_texts: DE.nullable(),
|
|
14552
14552
|
raw_data: no([U(), G(io({}))]).nullish()
|
|
@@ -14599,8 +14599,8 @@ function jE(e, t) {
|
|
|
14599
14599
|
var ME = (e) => {
|
|
14600
14600
|
let t = (0, X.c)(13), { isLazy: n, children: r, preload: i, host: a } = e, o, s, c, l;
|
|
14601
14601
|
if (t[0] !== a || t[1] !== n || t[2] !== i) {
|
|
14602
|
-
let e = a.closest(`[${
|
|
14603
|
-
l = e ?
|
|
14602
|
+
let e = a.closest(`[${je}]`);
|
|
14603
|
+
l = e ? Ke.parse(e) : null, o = a.closest(`[${yt}]`)?.getAttribute(yt), s = J.useState, c = n && !i && !AE(l, o), t[0] = a, t[1] = n, t[2] = i, t[3] = o, t[4] = s, t[5] = c, t[6] = l;
|
|
14604
14604
|
} else o = t[3], s = t[4], c = t[5], l = t[6];
|
|
14605
14605
|
let [u, d] = s(c);
|
|
14606
14606
|
if (u) {
|
|
@@ -14609,7 +14609,7 @@ var ME = (e) => {
|
|
|
14609
14609
|
jE(l, o), d(!1);
|
|
14610
14610
|
}, t[7] = o, t[8] = l, t[9] = e) : e = t[9];
|
|
14611
14611
|
let n;
|
|
14612
|
-
t[10] === Symbol.for("react.memo_cache_sentinel") ? (n = /* @__PURE__ */ (0, Y.jsx)(
|
|
14612
|
+
t[10] === Symbol.for("react.memo_cache_sentinel") ? (n = /* @__PURE__ */ (0, Y.jsx)(Tt, { className: "mr-2 h-4 w-4" }), t[10] = n) : n = t[10];
|
|
14613
14613
|
let r;
|
|
14614
14614
|
return t[11] === e ? r = t[12] : (r = /* @__PURE__ */ (0, Y.jsx)("div", {
|
|
14615
14615
|
className: "flex h-20 items-center justify-center",
|
|
@@ -14624,7 +14624,7 @@ var ME = (e) => {
|
|
|
14624
14624
|
return r;
|
|
14625
14625
|
}, NE = (0, J.memo)((e) => {
|
|
14626
14626
|
let t = (0, X.c)(119), n;
|
|
14627
|
-
t[0] === e.host ? n = t[1] : (n =
|
|
14627
|
+
t[0] === e.host ? n = t[1] : (n = Ee(e.host), t[0] = e.host, t[1] = n);
|
|
14628
14628
|
let r = n, i = e.search, a = e.setValue, o;
|
|
14629
14629
|
t[2] === Symbol.for("react.memo_cache_sentinel") ? (o = [], t[2] = o) : o = t[2];
|
|
14630
14630
|
let [s, l] = (0, J.useState)(o), u;
|
|
@@ -14674,7 +14674,7 @@ var ME = (e) => {
|
|
|
14674
14674
|
let e = await f;
|
|
14675
14675
|
t = e.data, n = e.raw_data, r = e.total_rows, a = e.cell_styles || {}, o = e.cell_hover_texts || {};
|
|
14676
14676
|
}
|
|
14677
|
-
let [m, h] = await
|
|
14677
|
+
let [m, h] = await $r(t, n);
|
|
14678
14678
|
return t = m, {
|
|
14679
14679
|
rows: t,
|
|
14680
14680
|
rawRows: h,
|
|
@@ -14698,7 +14698,7 @@ var ME = (e) => {
|
|
|
14698
14698
|
d.pageSize,
|
|
14699
14699
|
d.pageIndex
|
|
14700
14700
|
], t[35] = g, t[36] = d.pageIndex, t[37] = d.pageSize, t[38] = e.cellHoverTexts, t[39] = e.cellStyles, t[40] = e.data, t[41] = e.lazy, t[42] = e.totalRows, t[43] = i, t[44] = p, t[45] = s, t[46] = E, t[47] = D) : D = t[47];
|
|
14701
|
-
let { data: O, error: k, isPending: A, isFetching: j } = Ns(T, D), M = rs(
|
|
14701
|
+
let { data: O, error: k, isPending: A, isFetching: j } = Ns(T, D), M = rs(ei), N;
|
|
14702
14702
|
t[48] !== M || t[49] !== e ? (N = async () => !M || !e.showDownload || e.lazy || e.totalRows === 0 ? null : (await e.get_size_bytes({})).size_bytes ?? null, t[48] = M, t[49] = e, t[50] = N) : N = t[50];
|
|
14703
14703
|
let P = e.showDownload, F = e.get_size_bytes, I = e.lazy, L = e.totalRows, R = Ys(g), ee = Ys(s), z;
|
|
14704
14704
|
t[51] !== M || t[52] !== e.get_size_bytes || t[53] !== e.lazy || t[54] !== e.showDownload || t[55] !== e.totalRows || t[56] !== p || t[57] !== R || t[58] !== ee ? (z = [
|
|
@@ -14721,7 +14721,7 @@ var ME = (e) => {
|
|
|
14721
14721
|
filters: b_(g),
|
|
14722
14722
|
max_columns: null
|
|
14723
14723
|
});
|
|
14724
|
-
return { rows: await
|
|
14724
|
+
return { rows: await ii(n.data) };
|
|
14725
14725
|
}, t[60] = g, t[61] = i, t[62] = p, t[63] = s, t[64] = ie) : ie = t[64];
|
|
14726
14726
|
let ae = ie, oe;
|
|
14727
14727
|
t[65] === Symbol.for("react.memo_cache_sentinel") ? (oe = () => {
|
|
@@ -14731,7 +14731,7 @@ var ME = (e) => {
|
|
|
14731
14731
|
t[66] === se ? ce = t[67] : (ce = [se], t[66] = se, t[67] = ce), (0, J.useEffect)(oe, ce);
|
|
14732
14732
|
let V;
|
|
14733
14733
|
t[68] === e ? V = t[69] : (V = async () => {
|
|
14734
|
-
let t =
|
|
14734
|
+
let t = ga();
|
|
14735
14735
|
return e.totalRows === 0 || !e.showColumnSummaries || t ? {
|
|
14736
14736
|
data: null,
|
|
14737
14737
|
stats: {},
|
|
@@ -14754,7 +14754,7 @@ var ME = (e) => {
|
|
|
14754
14754
|
de && c.error(de);
|
|
14755
14755
|
}, pe = [de], t[77] = de, t[78] = fe, t[79] = pe), (0, J.useEffect)(fe, pe), A) {
|
|
14756
14756
|
let n = e.totalRows !== "too_many" && e.totalRows > 0 ? Math.min(e.totalRows, e.pageSize) : e.pageSize, r;
|
|
14757
|
-
return t[80] === n ? r = t[81] : (r = /* @__PURE__ */ (0, Y.jsx)(
|
|
14757
|
+
return t[80] === n ? r = t[81] : (r = /* @__PURE__ */ (0, Y.jsx)(Mr, {
|
|
14758
14758
|
milliseconds: 200,
|
|
14759
14759
|
children: /* @__PURE__ */ (0, Y.jsx)(GS, { pageSize: n })
|
|
14760
14760
|
}), t[80] = n, t[81] = r), r;
|
|
@@ -14763,7 +14763,7 @@ var ME = (e) => {
|
|
|
14763
14763
|
if (k) {
|
|
14764
14764
|
c.error(k);
|
|
14765
14765
|
let e;
|
|
14766
|
-
t[82] === k ? e = t[83] : (e = !
|
|
14766
|
+
t[82] === k ? e = t[83] : (e = !ga() && /* @__PURE__ */ (0, Y.jsxs)(Fs, {
|
|
14767
14767
|
variant: "destructive",
|
|
14768
14768
|
className: "mb-2",
|
|
14769
14769
|
children: [/* @__PURE__ */ (0, Y.jsx)(Ps, { children: "Error" }), /* @__PURE__ */ (0, Y.jsx)("div", {
|
|
@@ -14815,34 +14815,34 @@ var ME = (e) => {
|
|
|
14815
14815
|
rowHeaders: e.rowHeaders,
|
|
14816
14816
|
cellId: r
|
|
14817
14817
|
}) : we, t[105] = r, t[106] = we, t[107] = O?.rows, t[108] = y, t[109] = e.fieldTypes, t[110] = e.get_data_url, t[111] = e.rowHeaders, t[112] = e.showChartBuilder, t[113] = e.totalColumns, t[114] = e.totalRows, t[115] = Te) : Te = t[115];
|
|
14818
|
-
let
|
|
14819
|
-
return t[116] !== me || t[117] !== Te ? (
|
|
14818
|
+
let De;
|
|
14819
|
+
return t[116] !== me || t[117] !== Te ? (De = /* @__PURE__ */ (0, Y.jsxs)(Y.Fragment, { children: [me, Te] }), t[116] = me, t[117] = Te, t[118] = De) : De = t[118], De;
|
|
14820
14820
|
});
|
|
14821
14821
|
NE.displayName = "LoadingDataTableComponent";
|
|
14822
14822
|
var PE = (e) => {
|
|
14823
14823
|
let t = (0, X.c)(142), { label: n, data: r, rawData: i, totalRows: o, sizeBytes: s, sizeBytesIsLoading: c, maxColumns: l, pagination: u, selection: d, value: f, showFilters: p, showDownload: m, showPageSizeSelector: h, showColumnExplorer: g, showRowExplorer: _, showChartBuilder: v, showDataTypes: y, rowHeaders: b, fieldTypes: x, paginationState: S, setPaginationState: C, download_as: w, columnSummaries: T, className: E, setValue: D, sorting: O, setSorting: k, showSearch: A, searchQuery: j, setSearchQuery: M, filters: N, setFilters: P, reloading: F, freezeColumnsLeft: I, freezeColumnsRight: L, hiddenColumns: R, textJustifyColumns: ee, wrappedColumns: z, columnWidths: te, headerTooltip: B, totalColumns: ne, get_row_ids: re, cellStyles: ie, hoverTemplate: ae, cellHoverTexts: oe, toggleDisplayHeader: se, isChartBuilderOpen: ce, calculate_top_k_rows: V, preview_column: le, getRow: ue, cellId: de, maxHeight: fe } = e, pe = d, me = y, he = (0, J.useId)(), { locale: ge } = Xo(), [_e, ve] = (0, J.useState)(0), { isPanelOpen: ye, isAnyPanelOpen: be, togglePanel: xe, panelType: Se, setPanelType: Ce } = rE(he, de), we;
|
|
14824
|
-
t[0] === Symbol.for("react.memo_cache_sentinel") ? (we =
|
|
14824
|
+
t[0] === Symbol.for("react.memo_cache_sentinel") ? (we = ga(), t[0] = we) : we = t[0];
|
|
14825
14825
|
let Te = we, Ee;
|
|
14826
14826
|
bb0: {
|
|
14827
14827
|
if (!T) {
|
|
14828
|
-
Ee =
|
|
14828
|
+
Ee = Rr.EMPTY;
|
|
14829
14829
|
break bb0;
|
|
14830
14830
|
}
|
|
14831
14831
|
if (!x || !T.stats) {
|
|
14832
|
-
Ee =
|
|
14832
|
+
Ee = Rr.EMPTY;
|
|
14833
14833
|
break bb0;
|
|
14834
14834
|
}
|
|
14835
14835
|
let e;
|
|
14836
14836
|
if (t[1] !== T.bin_values || t[2] !== T.data || t[3] !== T.show_charts || t[4] !== T.stats || t[5] !== T.value_counts || t[6] !== x) {
|
|
14837
|
-
let n =
|
|
14838
|
-
e = new
|
|
14837
|
+
let n = un(x);
|
|
14838
|
+
e = new Rr(T.data || [], n, T.stats, T.bin_values, T.value_counts, { includeCharts: T.show_charts }), t[1] = T.bin_values, t[2] = T.data, t[3] = T.show_charts, t[4] = T.stats, t[5] = T.value_counts, t[6] = x, t[7] = e;
|
|
14839
14839
|
} else e = t[7];
|
|
14840
14840
|
Ee = e;
|
|
14841
14841
|
}
|
|
14842
14842
|
let De = Ee, Oe;
|
|
14843
14843
|
t[8] === b ? Oe = t[9] : (Oe = new Set(b.map(BE)), t[8] = b, t[9] = Oe);
|
|
14844
14844
|
let ke = Oe, Ae;
|
|
14845
|
-
t[10] !== r || t[11] !== x || t[12] !== ke ? (Ae = x ??
|
|
14845
|
+
t[10] !== r || t[11] !== x || t[12] !== ke ? (Ae = x ?? Zr(r).filter((e) => {
|
|
14846
14846
|
let [t] = e;
|
|
14847
14847
|
return !ke.has(t);
|
|
14848
14848
|
}), t[10] = r, t[11] = x, t[12] = ke, t[13] = Ae) : Ae = t[13];
|
|
@@ -14875,7 +14875,7 @@ var PE = (e) => {
|
|
|
14875
14875
|
let Fe = Pe, Ie = Ys(b), Le = Ys(ee), Re = Ys(z), ze = Ys(te), Be = Ys(De), Ve = Ys(Fe), He = Ne.length;
|
|
14876
14876
|
x || (me = !1), Te && (pe = null);
|
|
14877
14877
|
let Ue;
|
|
14878
|
-
t[20] !== V || t[21] !== Ve || t[22] !== B || t[23] !== Be || t[24] !== Ne || t[25] !== ze || t[26] !== Ie || t[27] !== Le || t[28] !== Re || t[29] !== pe || t[30] !== me ? (Ue =
|
|
14878
|
+
t[20] !== V || t[21] !== Ve || t[22] !== B || t[23] !== Be || t[24] !== Ne || t[25] !== ze || t[26] !== Ie || t[27] !== Le || t[28] !== Re || t[29] !== pe || t[30] !== me ? (Ue = kr({
|
|
14879
14879
|
rowHeaders: Ie,
|
|
14880
14880
|
selection: pe,
|
|
14881
14881
|
chartSpecModel: Be,
|
|
@@ -14904,7 +14904,7 @@ var PE = (e) => {
|
|
|
14904
14904
|
let Je = ns(qe), Ye;
|
|
14905
14905
|
t[38] !== S || t[39] !== C || t[40] !== ve || t[41] !== o ? (Ye = (e) => {
|
|
14906
14906
|
if (ve(e), e < 0 || typeof o == "number" && e >= o || o === "too_many") return;
|
|
14907
|
-
let t =
|
|
14907
|
+
let t = nr(e, S.pageIndex, S.pageSize);
|
|
14908
14908
|
t !== null && C((e) => ({
|
|
14909
14909
|
...e,
|
|
14910
14910
|
pageIndex: t
|
|
@@ -14934,7 +14934,7 @@ var PE = (e) => {
|
|
|
14934
14934
|
break bb2;
|
|
14935
14935
|
}
|
|
14936
14936
|
let e;
|
|
14937
|
-
t[51] !== nt || t[52] !== ue || t[53] !== Je || t[54] !== he || t[55] !== tt || t[56] !== je || t[57] !== Se || t[58] !== le || t[59] !== Ke || t[60] !== Ce || t[61] !== Xe || t[62] !== _ || t[63] !== ne || t[64] !== o || t[65] !== _e ? (e = (e) => /* @__PURE__ */ (0, Y.jsx)(
|
|
14937
|
+
t[51] !== nt || t[52] !== ue || t[53] !== Je || t[54] !== he || t[55] !== tt || t[56] !== je || t[57] !== Se || t[58] !== le || t[59] !== Ke || t[60] !== Ce || t[61] !== Xe || t[62] !== _ || t[63] !== ne || t[64] !== o || t[65] !== _e ? (e = (e) => /* @__PURE__ */ (0, Y.jsx)(zr, { children: /* @__PURE__ */ (0, Y.jsx)(xE, {
|
|
14938
14938
|
rowIdx: _e,
|
|
14939
14939
|
setRowIdx: Xe,
|
|
14940
14940
|
totalRows: o,
|
|
@@ -14978,10 +14978,10 @@ var PE = (e) => {
|
|
|
14978
14978
|
className: "mb-1 rounded",
|
|
14979
14979
|
children: [
|
|
14980
14980
|
"Showing the first ",
|
|
14981
|
-
/* @__PURE__ */ (0, Y.jsx)("strong", { children:
|
|
14981
|
+
/* @__PURE__ */ (0, Y.jsx)("strong", { children: la(r.length, ge) }),
|
|
14982
14982
|
" ",
|
|
14983
14983
|
"of ",
|
|
14984
|
-
/* @__PURE__ */ (0, Y.jsx)("strong", { children:
|
|
14984
|
+
/* @__PURE__ */ (0, Y.jsx)("strong", { children: la(o, ge) }),
|
|
14985
14985
|
" rows. Increase the table's ",
|
|
14986
14986
|
/* @__PURE__ */ (0, Y.jsx)("code", { children: "page_size" }),
|
|
14987
14987
|
" to embed more in the static export."
|
|
@@ -14995,7 +14995,7 @@ var PE = (e) => {
|
|
|
14995
14995
|
let pt = m ? w : void 0, mt = v && !ot, ht = (_ || nt) && !it && !ot, gt;
|
|
14996
14996
|
t[81] === ve ? gt = t[82] : (gt = (e) => ve(e), t[81] = ve, t[82] = gt);
|
|
14997
14997
|
let _t;
|
|
14998
|
-
t[83] !== V || t[84] !== oe || t[85] !== Qe || t[86] !== ie || t[87] !== E || t[88] !== We || t[89] !== r || t[90] !== N || t[91] !== I || t[92] !== L || t[93] !== re || t[94] !== et || t[95] !== Je || t[96] !== R || t[97] !== ae || t[98] !== be || t[99] !== ce || t[100] !== ye || t[101] !== fe || t[102] !== u || t[103] !== S || t[104] !== i || t[105] !== F || t[106] !== ct || t[107] !== Ke || t[108] !== j || t[109] !== pe || t[110] !== P || t[111] !== C || t[112] !== M || t[113] !== k || t[114] !== p || t[115] !== h || t[116] !== A || t[117] !== s || t[118] !== c || t[119] !== O || t[120] !== pt || t[121] !== mt || t[122] !== ht || t[123] !== gt || t[124] !== se || t[125] !== xe || t[126] !== ne || t[127] !== o || t[128] !== _e ? (_t = /* @__PURE__ */ (0, Y.jsx)(
|
|
14998
|
+
t[83] !== V || t[84] !== oe || t[85] !== Qe || t[86] !== ie || t[87] !== E || t[88] !== We || t[89] !== r || t[90] !== N || t[91] !== I || t[92] !== L || t[93] !== re || t[94] !== et || t[95] !== Je || t[96] !== R || t[97] !== ae || t[98] !== be || t[99] !== ce || t[100] !== ye || t[101] !== fe || t[102] !== u || t[103] !== S || t[104] !== i || t[105] !== F || t[106] !== ct || t[107] !== Ke || t[108] !== j || t[109] !== pe || t[110] !== P || t[111] !== C || t[112] !== M || t[113] !== k || t[114] !== p || t[115] !== h || t[116] !== A || t[117] !== s || t[118] !== c || t[119] !== O || t[120] !== pt || t[121] !== mt || t[122] !== ht || t[123] !== gt || t[124] !== se || t[125] !== xe || t[126] !== ne || t[127] !== o || t[128] !== _e ? (_t = /* @__PURE__ */ (0, Y.jsx)(yr, {
|
|
14999
14999
|
data: r,
|
|
15000
15000
|
rawData: i,
|
|
15001
15001
|
columns: We,
|
|
@@ -15053,7 +15053,7 @@ var PE = (e) => {
|
|
|
15053
15053
|
children: _t
|
|
15054
15054
|
}), t[130] = n, t[131] = _t, t[132] = vt) : vt = t[132];
|
|
15055
15055
|
let yt;
|
|
15056
|
-
t[133] !== De || t[134] !== vt ? (yt = /* @__PURE__ */ (0, Y.jsx)(
|
|
15056
|
+
t[133] !== De || t[134] !== vt ? (yt = /* @__PURE__ */ (0, Y.jsx)(gr, {
|
|
15057
15057
|
value: De,
|
|
15058
15058
|
children: vt
|
|
15059
15059
|
}), t[133] = De, t[134] = vt, t[135] = yt) : yt = t[135];
|
|
@@ -15069,8 +15069,8 @@ var PE = (e) => {
|
|
|
15069
15069
|
let t = (0, X.c)(2), { children: n } = e, r;
|
|
15070
15070
|
return t[0] === n ? r = t[1] : (r = /* @__PURE__ */ (0, Y.jsx)(Ua, { children: /* @__PURE__ */ (0, Y.jsx)(gs, {
|
|
15071
15071
|
store: os,
|
|
15072
|
-
children: /* @__PURE__ */ (0, Y.jsx)(
|
|
15073
|
-
controller:
|
|
15072
|
+
children: /* @__PURE__ */ (0, Y.jsx)(Jr, {
|
|
15073
|
+
controller: Xn,
|
|
15074
15074
|
children: n
|
|
15075
15075
|
})
|
|
15076
15076
|
}) }), t[0] = n, t[1] = r), r;
|
|
@@ -15135,13 +15135,13 @@ var UE = class {
|
|
|
15135
15135
|
e.setValue(n);
|
|
15136
15136
|
}, t[0] = e, t[1] = n);
|
|
15137
15137
|
let r = n, i = e.label, a = e.fullWidth, o;
|
|
15138
|
-
t[2] === e.value ? o = t[3] : (o =
|
|
15138
|
+
t[2] === e.value ? o = t[3] : (o = qr(e.value), t[2] = e.value, t[3] = o);
|
|
15139
15139
|
let s = e.label ?? "date picker", c;
|
|
15140
|
-
t[4] === e.start ? c = t[5] : (c =
|
|
15140
|
+
t[4] === e.start ? c = t[5] : (c = qr(e.start), t[4] = e.start, t[5] = c);
|
|
15141
15141
|
let l;
|
|
15142
|
-
t[6] === e.stop ? l = t[7] : (l =
|
|
15142
|
+
t[6] === e.stop ? l = t[7] : (l = qr(e.stop), t[6] = e.stop, t[7] = l);
|
|
15143
15143
|
let u;
|
|
15144
|
-
t[8] !== r || t[9] !== e.disabled || t[10] !== o || t[11] !== s || t[12] !== c || t[13] !== l ? (u = /* @__PURE__ */ (0, Y.jsx)(
|
|
15144
|
+
t[8] !== r || t[9] !== e.disabled || t[10] !== o || t[11] !== s || t[12] !== c || t[13] !== l ? (u = /* @__PURE__ */ (0, Y.jsx)(_n, {
|
|
15145
15145
|
granularity: "day",
|
|
15146
15146
|
value: o,
|
|
15147
15147
|
onChange: r,
|
|
@@ -15182,20 +15182,20 @@ var UE = class {
|
|
|
15182
15182
|
e.setValue(i);
|
|
15183
15183
|
}, t[0] = e, t[1] = n);
|
|
15184
15184
|
let r = n, i = e.label, a = e.fullWidth, o;
|
|
15185
|
-
t[2] === e.value[0] ? o = t[3] : (o =
|
|
15185
|
+
t[2] === e.value[0] ? o = t[3] : (o = qr(e.value[0]), t[2] = e.value[0], t[3] = o);
|
|
15186
15186
|
let s;
|
|
15187
|
-
t[4] === e.value[1] ? s = t[5] : (s =
|
|
15187
|
+
t[4] === e.value[1] ? s = t[5] : (s = qr(e.value[1]), t[4] = e.value[1], t[5] = s);
|
|
15188
15188
|
let c;
|
|
15189
15189
|
t[6] !== o || t[7] !== s ? (c = {
|
|
15190
15190
|
start: o,
|
|
15191
15191
|
end: s
|
|
15192
15192
|
}, t[6] = o, t[7] = s, t[8] = c) : c = t[8];
|
|
15193
15193
|
let l = e.label ?? "date range picker", u;
|
|
15194
|
-
t[9] === e.start ? u = t[10] : (u =
|
|
15194
|
+
t[9] === e.start ? u = t[10] : (u = qr(e.start), t[9] = e.start, t[10] = u);
|
|
15195
15195
|
let d;
|
|
15196
|
-
t[11] === e.stop ? d = t[12] : (d =
|
|
15196
|
+
t[11] === e.stop ? d = t[12] : (d = qr(e.stop), t[11] = e.stop, t[12] = d);
|
|
15197
15197
|
let f;
|
|
15198
|
-
t[13] !== r || t[14] !== e.disabled || t[15] !== c || t[16] !== l || t[17] !== u || t[18] !== d ? (f = /* @__PURE__ */ (0, Y.jsx)(
|
|
15198
|
+
t[13] !== r || t[14] !== e.disabled || t[15] !== c || t[16] !== l || t[17] !== u || t[18] !== d ? (f = /* @__PURE__ */ (0, Y.jsx)(Tn, {
|
|
15199
15199
|
granularity: "day",
|
|
15200
15200
|
value: c,
|
|
15201
15201
|
onChange: r,
|
|
@@ -15241,13 +15241,13 @@ var UE = class {
|
|
|
15241
15241
|
e.setValue(n);
|
|
15242
15242
|
}, t[0] = e, t[1] = n);
|
|
15243
15243
|
let r = n, i;
|
|
15244
|
-
t[2] === e.value ? i = t[3] : (i = e.value ?
|
|
15244
|
+
t[2] === e.value ? i = t[3] : (i = e.value ? fr(e.value) : void 0, t[2] = e.value, t[3] = i);
|
|
15245
15245
|
let a = i, o = e.label, s = e.fullWidth, c = e.precision, l = e.label ?? "date time picker", u;
|
|
15246
|
-
t[4] === e.start ? u = t[5] : (u =
|
|
15246
|
+
t[4] === e.start ? u = t[5] : (u = fr(e.start), t[4] = e.start, t[5] = u);
|
|
15247
15247
|
let d;
|
|
15248
|
-
t[6] === e.stop ? d = t[7] : (d =
|
|
15248
|
+
t[6] === e.stop ? d = t[7] : (d = fr(e.stop), t[6] = e.stop, t[7] = d);
|
|
15249
15249
|
let f;
|
|
15250
|
-
t[8] !== r || t[9] !== a || t[10] !== e.disabled || t[11] !== e.precision || t[12] !== l || t[13] !== u || t[14] !== d ? (f = /* @__PURE__ */ (0, Y.jsx)(
|
|
15250
|
+
t[8] !== r || t[9] !== a || t[10] !== e.disabled || t[11] !== e.precision || t[12] !== l || t[13] !== u || t[14] !== d ? (f = /* @__PURE__ */ (0, Y.jsx)(_n, {
|
|
15251
15251
|
granularity: c,
|
|
15252
15252
|
value: a,
|
|
15253
15253
|
onChange: r,
|
|
@@ -15380,7 +15380,7 @@ var $E = class {
|
|
|
15380
15380
|
}, e), t[10] = i, t[11] = e), g = r.map(e), t[7] = r, t[8] = i, t[9] = g;
|
|
15381
15381
|
} else g = t[9];
|
|
15382
15382
|
let _;
|
|
15383
|
-
t[12] !== c || t[13] !== u || t[14] !== f || t[15] !== p || t[16] !== m || t[17] !== h || t[18] !== g ? (_ = /* @__PURE__ */ (0, Y.jsxs)(
|
|
15383
|
+
t[12] !== c || t[13] !== u || t[14] !== f || t[15] !== p || t[16] !== m || t[17] !== h || t[18] !== g ? (_ = /* @__PURE__ */ (0, Y.jsxs)(Ei, {
|
|
15384
15384
|
"data-testid": "marimo-plugin-dropdown",
|
|
15385
15385
|
onChange: p,
|
|
15386
15386
|
className: m,
|
|
@@ -15408,7 +15408,7 @@ var $E = class {
|
|
|
15408
15408
|
too_many_values: !1
|
|
15409
15409
|
})), sD = (e) => {
|
|
15410
15410
|
let t = (0, X.c)(4), { type: n } = e, r;
|
|
15411
|
-
t[0] === n ? r = t[1] : (r = () => n.startsWith("int") || n.startsWith("float") || n.startsWith("uint") || n.startsWith("number") || n.startsWith("complex") ? /* @__PURE__ */ (0, Y.jsx)(Au, { size: 14 }) : n.startsWith("object") || n.startsWith("string") ? /* @__PURE__ */ (0, Y.jsx)(Mu, { size: 14 }) : n.startsWith("date") || n.startsWith("time") ? /* @__PURE__ */ (0, Y.jsx)(
|
|
15411
|
+
t[0] === n ? r = t[1] : (r = () => n.startsWith("int") || n.startsWith("float") || n.startsWith("uint") || n.startsWith("number") || n.startsWith("complex") ? /* @__PURE__ */ (0, Y.jsx)(Au, { size: 14 }) : n.startsWith("object") || n.startsWith("string") ? /* @__PURE__ */ (0, Y.jsx)(Mu, { size: 14 }) : n.startsWith("date") || n.startsWith("time") ? /* @__PURE__ */ (0, Y.jsx)(si, { size: 14 }) : n.startsWith("bool") ? /* @__PURE__ */ (0, Y.jsx)(ui, { size: 14 }) : /* @__PURE__ */ (0, Y.jsx)(st, { size: 14 }), t[0] = n, t[1] = r);
|
|
15412
15412
|
let i = r, a;
|
|
15413
15413
|
return t[2] === i ? a = t[3] : (a = /* @__PURE__ */ (0, Y.jsx)("div", {
|
|
15414
15414
|
className: "border p-px border-border bg-(--slate-2) flex items-center justify-center rounded",
|
|
@@ -15427,7 +15427,7 @@ var $E = class {
|
|
|
15427
15427
|
render: ({ field: e }) => /* @__PURE__ */ (0, Y.jsxs)(yh, { children: [
|
|
15428
15428
|
/* @__PURE__ */ (0, Y.jsx)(bh, { children: i }),
|
|
15429
15429
|
/* @__PURE__ */ (0, Y.jsx)(Sh, { children: a }),
|
|
15430
|
-
/* @__PURE__ */ (0, Y.jsx)(xh, { children: /* @__PURE__ */ (0, Y.jsxs)(
|
|
15430
|
+
/* @__PURE__ */ (0, Y.jsx)(xh, { children: /* @__PURE__ */ (0, Y.jsxs)(ji, {
|
|
15431
15431
|
"data-testid": "marimo-plugin-data-frames-column-select",
|
|
15432
15432
|
value: e.value == null ? e.value : JSON.stringify(e.value),
|
|
15433
15433
|
onValueChange: (t) => {
|
|
@@ -15436,11 +15436,11 @@ var $E = class {
|
|
|
15436
15436
|
},
|
|
15437
15437
|
children: [/* @__PURE__ */ (0, Y.jsxs)("div", {
|
|
15438
15438
|
className: "flex items-center gap-1",
|
|
15439
|
-
children: [/* @__PURE__ */ (0, Y.jsx)(
|
|
15439
|
+
children: [/* @__PURE__ */ (0, Y.jsx)(Ai, {
|
|
15440
15440
|
className: "min-w-[180px]",
|
|
15441
|
-
children: /* @__PURE__ */ (0, Y.jsx)(
|
|
15441
|
+
children: /* @__PURE__ */ (0, Y.jsx)(Ci, { placeholder: "--" })
|
|
15442
15442
|
}), /* @__PURE__ */ (0, Y.jsx)(pD, {})]
|
|
15443
|
-
}), /* @__PURE__ */ (0, Y.jsx)(
|
|
15443
|
+
}), /* @__PURE__ */ (0, Y.jsx)(Di, { children: /* @__PURE__ */ (0, Y.jsxs)(ki, { children: [[...r.entries()].map(([e, t]) => /* @__PURE__ */ (0, Y.jsx)(wi, {
|
|
15444
15444
|
value: JSON.stringify(e),
|
|
15445
15445
|
children: /* @__PURE__ */ (0, Y.jsxs)("span", {
|
|
15446
15446
|
className: "flex items-center gap-2 flex-1",
|
|
@@ -15460,7 +15460,7 @@ var $E = class {
|
|
|
15460
15460
|
})
|
|
15461
15461
|
]
|
|
15462
15462
|
})
|
|
15463
|
-
}, e)), r.size === 0 && /* @__PURE__ */ (0, Y.jsx)(
|
|
15463
|
+
}, e)), r.size === 0 && /* @__PURE__ */ (0, Y.jsx)(wi, {
|
|
15464
15464
|
disabled: !0,
|
|
15465
15465
|
value: "--",
|
|
15466
15466
|
children: "No columns"
|
|
@@ -15497,7 +15497,7 @@ var $E = class {
|
|
|
15497
15497
|
return /* @__PURE__ */ (0, Y.jsxs)(yh, { children: [
|
|
15498
15498
|
/* @__PURE__ */ (0, Y.jsx)(bh, { children: a }),
|
|
15499
15499
|
/* @__PURE__ */ (0, Y.jsx)(Sh, { children: c }),
|
|
15500
|
-
/* @__PURE__ */ (0, Y.jsx)(xh, { children: /* @__PURE__ */ (0, Y.jsx)(
|
|
15500
|
+
/* @__PURE__ */ (0, Y.jsx)(xh, { children: /* @__PURE__ */ (0, Y.jsx)(vn, {
|
|
15501
15501
|
className: "min-w-[180px]",
|
|
15502
15502
|
placeholder: u,
|
|
15503
15503
|
displayValue: String,
|
|
@@ -15535,7 +15535,7 @@ var $E = class {
|
|
|
15535
15535
|
render: ({ field: e }) => /* @__PURE__ */ (0, Y.jsxs)(yh, { children: [
|
|
15536
15536
|
/* @__PURE__ */ (0, Y.jsx)(bh, { children: r }),
|
|
15537
15537
|
/* @__PURE__ */ (0, Y.jsx)(Sh, { children: i }),
|
|
15538
|
-
/* @__PURE__ */ (0, Y.jsx)(xh, { children: /* @__PURE__ */ (0, Y.jsx)(
|
|
15538
|
+
/* @__PURE__ */ (0, Y.jsx)(xh, { children: /* @__PURE__ */ (0, Y.jsx)(ta, {
|
|
15539
15539
|
...e,
|
|
15540
15540
|
value: e.value,
|
|
15541
15541
|
onValueChange: e.onChange,
|
|
@@ -15555,14 +15555,14 @@ var $E = class {
|
|
|
15555
15555
|
children: r
|
|
15556
15556
|
}),
|
|
15557
15557
|
/* @__PURE__ */ (0, Y.jsx)(Sh, { children: i }),
|
|
15558
|
-
/* @__PURE__ */ (0, Y.jsx)(xh, { children: /* @__PURE__ */ (0, Y.jsx)(
|
|
15558
|
+
/* @__PURE__ */ (0, Y.jsx)(xh, { children: /* @__PURE__ */ (0, Y.jsx)(vn, {
|
|
15559
15559
|
className: "min-w-[180px]",
|
|
15560
15560
|
placeholder: a,
|
|
15561
15561
|
multiple: !1,
|
|
15562
15562
|
displayValue: (e) => e,
|
|
15563
15563
|
value: Array.isArray(e.value) ? e.value[0] : e.value,
|
|
15564
15564
|
onValueChange: e.onChange,
|
|
15565
|
-
children: d.map((e) => /* @__PURE__ */ (0, Y.jsx)(
|
|
15565
|
+
children: d.map((e) => /* @__PURE__ */ (0, Y.jsx)(En, {
|
|
15566
15566
|
value: e,
|
|
15567
15567
|
children: e
|
|
15568
15568
|
}, e))
|
|
@@ -15665,14 +15665,14 @@ var $E = class {
|
|
|
15665
15665
|
children: " "
|
|
15666
15666
|
}),
|
|
15667
15667
|
/* @__PURE__ */ (0, Y.jsx)(Sh, { children: o }),
|
|
15668
|
-
/* @__PURE__ */ (0, Y.jsx)(xh, { children: /* @__PURE__ */ (0, Y.jsxs)(
|
|
15668
|
+
/* @__PURE__ */ (0, Y.jsx)(xh, { children: /* @__PURE__ */ (0, Y.jsxs)(ji, {
|
|
15669
15669
|
"data-testid": "marimo-plugin-data-frames-filter-operator-select",
|
|
15670
15670
|
value: t.value,
|
|
15671
15671
|
onValueChange: t.onChange,
|
|
15672
|
-
children: [/* @__PURE__ */ (0, Y.jsx)(
|
|
15672
|
+
children: [/* @__PURE__ */ (0, Y.jsx)(Ai, {
|
|
15673
15673
|
className: "min-w-[140px]",
|
|
15674
|
-
children: /* @__PURE__ */ (0, Y.jsx)(
|
|
15675
|
-
}), /* @__PURE__ */ (0, Y.jsx)(
|
|
15674
|
+
children: /* @__PURE__ */ (0, Y.jsx)(Ci, { placeholder: "--" })
|
|
15675
|
+
}), /* @__PURE__ */ (0, Y.jsx)(Di, { children: /* @__PURE__ */ (0, Y.jsx)(ki, { children: i.map(yD) }) })]
|
|
15676
15676
|
}) }),
|
|
15677
15677
|
/* @__PURE__ */ (0, Y.jsx)(Ch, {})
|
|
15678
15678
|
] });
|
|
@@ -15715,7 +15715,7 @@ var $E = class {
|
|
|
15715
15715
|
];
|
|
15716
15716
|
function _D(e) {
|
|
15717
15717
|
let [t, n] = e;
|
|
15718
|
-
return /* @__PURE__ */ (0, Y.jsx)(
|
|
15718
|
+
return /* @__PURE__ */ (0, Y.jsx)(En, {
|
|
15719
15719
|
value: t,
|
|
15720
15720
|
children: /* @__PURE__ */ (0, Y.jsxs)("span", {
|
|
15721
15721
|
className: "flex items-center gap-2 flex-1",
|
|
@@ -15742,9 +15742,9 @@ function vD(e) {
|
|
|
15742
15742
|
return t === "column_id";
|
|
15743
15743
|
}
|
|
15744
15744
|
function yD(e) {
|
|
15745
|
-
return /* @__PURE__ */ (0, Y.jsx)(
|
|
15745
|
+
return /* @__PURE__ */ (0, Y.jsx)(wi, {
|
|
15746
15746
|
value: e,
|
|
15747
|
-
children:
|
|
15747
|
+
children: Si.startCase(e)
|
|
15748
15748
|
}, e);
|
|
15749
15749
|
}
|
|
15750
15750
|
//#endregion
|
|
@@ -15886,7 +15886,7 @@ var xD = ({ initialValue: e, columns: t, onChange: n, onInvalidChange: r, getCol
|
|
|
15886
15886
|
"to automatically apply transformations."
|
|
15887
15887
|
] })]
|
|
15888
15888
|
}),
|
|
15889
|
-
children: /* @__PURE__ */ (0, Y.jsx)(
|
|
15889
|
+
children: /* @__PURE__ */ (0, Y.jsx)(Ct, { className: "w-3 h-3 text-muted-foreground hover:text-foreground cursor-help" })
|
|
15890
15890
|
})]
|
|
15891
15891
|
})
|
|
15892
15892
|
]
|
|
@@ -15904,7 +15904,7 @@ var xD = ({ initialValue: e, columns: t, onChange: n, onInvalidChange: r, getCol
|
|
|
15904
15904
|
className: l("flex flex-row min-h-[40px] items-center px-2 cursor-pointer hover:bg-accent/50 text-sm overflow-hidden hover-actions-parent border border-muted border-l-2 border-l-transparent", { "border-l-primary bg-accent text-accent-foreground": r === t }),
|
|
15905
15905
|
children: [/* @__PURE__ */ (0, Y.jsx)("div", {
|
|
15906
15906
|
className: "grow text-ellipsis",
|
|
15907
|
-
children:
|
|
15907
|
+
children: Si.startCase(e.type)
|
|
15908
15908
|
}), /* @__PURE__ */ (0, Y.jsx)(P, {
|
|
15909
15909
|
className: "w-3 h-3 hover-action text-muted-foreground hover:text-destructive",
|
|
15910
15910
|
onClick: (e) => {
|
|
@@ -15941,24 +15941,24 @@ var xD = ({ initialValue: e, columns: t, onChange: n, onInvalidChange: r, getCol
|
|
|
15941
15941
|
}), t[14] = c, t[15] = d, t[16] = f) : f = t[16], f;
|
|
15942
15942
|
}, CD = (e) => {
|
|
15943
15943
|
let t = (0, X.c)(12), { onAdd: n, children: r } = e, i;
|
|
15944
|
-
t[0] === r ? i = t[1] : (i = /* @__PURE__ */ (0, Y.jsx)(
|
|
15944
|
+
t[0] === r ? i = t[1] : (i = /* @__PURE__ */ (0, Y.jsx)(qi, {
|
|
15945
15945
|
asChild: !0,
|
|
15946
15946
|
children: r
|
|
15947
15947
|
}), t[0] = r, t[1] = i);
|
|
15948
15948
|
let a, o;
|
|
15949
|
-
t[2] === Symbol.for("react.memo_cache_sentinel") ? (a = /* @__PURE__ */ (0, Y.jsx)(
|
|
15949
|
+
t[2] === Symbol.for("react.memo_cache_sentinel") ? (a = /* @__PURE__ */ (0, Y.jsx)(Ui, { children: "Add Transform" }), o = /* @__PURE__ */ (0, Y.jsx)(aa, {}), t[2] = a, t[3] = o) : (a = t[2], o = t[3]);
|
|
15950
15950
|
let s;
|
|
15951
15951
|
t[4] === n ? s = t[5] : (s = Object.values(jC.options).map((e) => {
|
|
15952
15952
|
let t = Ph(e), r = wD[t.value];
|
|
15953
|
-
return /* @__PURE__ */ (0, Y.jsxs)(
|
|
15953
|
+
return /* @__PURE__ */ (0, Y.jsxs)(Zi, {
|
|
15954
15954
|
onSelect: (t) => {
|
|
15955
15955
|
t.stopPropagation(), n(e);
|
|
15956
15956
|
},
|
|
15957
|
-
children: [/* @__PURE__ */ (0, Y.jsx)(r, { className: "w-3.5 h-3.5 mr-2" }), /* @__PURE__ */ (0, Y.jsx)("span", { children:
|
|
15957
|
+
children: [/* @__PURE__ */ (0, Y.jsx)(r, { className: "w-3.5 h-3.5 mr-2" }), /* @__PURE__ */ (0, Y.jsx)("span", { children: Si.startCase(t.value) })]
|
|
15958
15958
|
}, t.value);
|
|
15959
15959
|
}), t[4] = n, t[5] = s);
|
|
15960
15960
|
let c;
|
|
15961
|
-
t[6] === Symbol.for("react.memo_cache_sentinel") ? (c = /* @__PURE__ */ (0, Y.jsx)(
|
|
15961
|
+
t[6] === Symbol.for("react.memo_cache_sentinel") ? (c = /* @__PURE__ */ (0, Y.jsx)(Zi, {
|
|
15962
15962
|
onSelect: TD,
|
|
15963
15963
|
children: /* @__PURE__ */ (0, Y.jsx)("span", {
|
|
15964
15964
|
className: "underline text-primary text-xs cursor-pointer",
|
|
@@ -15966,23 +15966,23 @@ var xD = ({ initialValue: e, columns: t, onChange: n, onInvalidChange: r, getCol
|
|
|
15966
15966
|
})
|
|
15967
15967
|
}, "_request_"), t[6] = c) : c = t[6];
|
|
15968
15968
|
let l;
|
|
15969
|
-
t[7] === s ? l = t[8] : (l = /* @__PURE__ */ (0, Y.jsxs)(
|
|
15969
|
+
t[7] === s ? l = t[8] : (l = /* @__PURE__ */ (0, Y.jsxs)(ea, {
|
|
15970
15970
|
className: "w-56",
|
|
15971
15971
|
children: [
|
|
15972
15972
|
a,
|
|
15973
15973
|
o,
|
|
15974
|
-
/* @__PURE__ */ (0, Y.jsxs)(
|
|
15974
|
+
/* @__PURE__ */ (0, Y.jsxs)(ia, { children: [s, c] })
|
|
15975
15975
|
]
|
|
15976
15976
|
}), t[7] = s, t[8] = l);
|
|
15977
15977
|
let u;
|
|
15978
|
-
return t[9] !== i || t[10] !== l ? (u = /* @__PURE__ */ (0, Y.jsxs)(
|
|
15978
|
+
return t[9] !== i || t[10] !== l ? (u = /* @__PURE__ */ (0, Y.jsxs)(oa, {
|
|
15979
15979
|
modal: !1,
|
|
15980
15980
|
children: [i, l]
|
|
15981
15981
|
}), t[9] = i, t[10] = l, t[11] = u) : u = t[11], u;
|
|
15982
15982
|
}, wD = {
|
|
15983
|
-
aggregate:
|
|
15984
|
-
column_conversion:
|
|
15985
|
-
filter_rows:
|
|
15983
|
+
aggregate: jt,
|
|
15984
|
+
column_conversion: nt,
|
|
15985
|
+
filter_rows: Sr,
|
|
15986
15986
|
group_by: Ku,
|
|
15987
15987
|
rename_column: La,
|
|
15988
15988
|
select_columns: nd,
|
|
@@ -15992,7 +15992,7 @@ var xD = ({ initialValue: e, columns: t, onChange: n, onInvalidChange: r, getCol
|
|
|
15992
15992
|
explode_columns: ju,
|
|
15993
15993
|
expand_dict: Lu,
|
|
15994
15994
|
unique: Fu,
|
|
15995
|
-
pivot:
|
|
15995
|
+
pivot: Tt
|
|
15996
15996
|
};
|
|
15997
15997
|
function TD(e) {
|
|
15998
15998
|
e.stopPropagation(), window.open("https://github.com/marimo-team/marimo/issues/new?title=New%20dataframe%20transform:&labels=enhancement&template=feature_request.yaml", "_blank");
|
|
@@ -16078,27 +16078,27 @@ var ED = xS("marimo-dataframe").withData(W({
|
|
|
16078
16078
|
c
|
|
16079
16079
|
], t[13] = v, t[14] = c, t[15] = R, t[16] = ee) : ee = t[16], (0, J.useEffect)(L, ee);
|
|
16080
16080
|
let z;
|
|
16081
|
-
t[17] === Symbol.for("react.memo_cache_sentinel") ? (z = /* @__PURE__ */ (0, Y.jsxs)(
|
|
16081
|
+
t[17] === Symbol.for("react.memo_cache_sentinel") ? (z = /* @__PURE__ */ (0, Y.jsxs)(Mn, {
|
|
16082
16082
|
value: "transform",
|
|
16083
16083
|
className: "text-xs py-1",
|
|
16084
|
-
children: [/* @__PURE__ */ (0, Y.jsx)(
|
|
16084
|
+
children: [/* @__PURE__ */ (0, Y.jsx)(jt, { className: "w-3 h-3 mr-2" }), "Transform"]
|
|
16085
16085
|
}), t[17] = z) : z = t[17];
|
|
16086
16086
|
let te;
|
|
16087
|
-
t[18] === D ? te = t[19] : (te = D && /* @__PURE__ */ (0, Y.jsxs)(
|
|
16087
|
+
t[18] === D ? te = t[19] : (te = D && /* @__PURE__ */ (0, Y.jsxs)(Mn, {
|
|
16088
16088
|
value: "python-code",
|
|
16089
16089
|
className: "text-xs py-1",
|
|
16090
16090
|
children: [/* @__PURE__ */ (0, Y.jsx)(Nu, { className: "w-3 h-3 mr-2" }), "Python Code"]
|
|
16091
16091
|
}), t[18] = D, t[19] = te);
|
|
16092
16092
|
let B;
|
|
16093
|
-
t[20] === O ? B = t[21] : (B = O && /* @__PURE__ */ (0, Y.jsxs)(
|
|
16093
|
+
t[20] === O ? B = t[21] : (B = O && /* @__PURE__ */ (0, Y.jsxs)(Mn, {
|
|
16094
16094
|
value: "sql-code",
|
|
16095
16095
|
className: "text-xs py-1",
|
|
16096
|
-
children: [/* @__PURE__ */ (0, Y.jsx)(
|
|
16096
|
+
children: [/* @__PURE__ */ (0, Y.jsx)(Qe, { className: "w-3 h-3 mr-2" }), "SQL Code"]
|
|
16097
16097
|
}), t[20] = O, t[21] = B);
|
|
16098
16098
|
let re;
|
|
16099
16099
|
t[22] === Symbol.for("react.memo_cache_sentinel") ? (re = /* @__PURE__ */ (0, Y.jsx)("div", { className: "grow" }), t[22] = re) : re = t[22];
|
|
16100
16100
|
let ie;
|
|
16101
|
-
t[23] !== te || t[24] !== B ? (ie = /* @__PURE__ */ (0, Y.jsxs)(
|
|
16101
|
+
t[23] !== te || t[24] !== B ? (ie = /* @__PURE__ */ (0, Y.jsxs)(An, {
|
|
16102
16102
|
className: "h-8",
|
|
16103
16103
|
children: [
|
|
16104
16104
|
z,
|
|
@@ -16119,7 +16119,7 @@ var ED = xS("marimo-dataframe").withData(W({
|
|
|
16119
16119
|
ds(e, s) || (c(e), j(e));
|
|
16120
16120
|
}, t[31] = c, t[32] = s, t[33] = se) : se = t[33];
|
|
16121
16121
|
let ce;
|
|
16122
|
-
t[34] !== E || t[35] !== n || t[36] !== u || t[37] !== A || t[38] !== o || t[39] !== se ? (ce = /* @__PURE__ */ (0, Y.jsx)(
|
|
16122
|
+
t[34] !== E || t[35] !== n || t[36] !== u || t[37] !== A || t[38] !== o || t[39] !== se ? (ce = /* @__PURE__ */ (0, Y.jsx)(Tr, {
|
|
16123
16123
|
value: "transform",
|
|
16124
16124
|
className: "mt-1 border rounded-t overflow-hidden",
|
|
16125
16125
|
children: /* @__PURE__ */ (0, Y.jsx)(xD, {
|
|
@@ -16134,7 +16134,7 @@ var ED = xS("marimo-dataframe").withData(W({
|
|
|
16134
16134
|
})
|
|
16135
16135
|
}), t[34] = E, t[35] = n, t[36] = u, t[37] = A, t[38] = o, t[39] = se, t[40] = ce) : ce = t[40];
|
|
16136
16136
|
let V;
|
|
16137
|
-
t[41] === D ? V = t[42] : (V = D && /* @__PURE__ */ (0, Y.jsx)(
|
|
16137
|
+
t[41] === D ? V = t[42] : (V = D && /* @__PURE__ */ (0, Y.jsx)(Tr, {
|
|
16138
16138
|
value: "python-code",
|
|
16139
16139
|
className: "mt-1 border rounded-t overflow-hidden",
|
|
16140
16140
|
children: /* @__PURE__ */ (0, Y.jsx)(xw, {
|
|
@@ -16145,7 +16145,7 @@ var ED = xS("marimo-dataframe").withData(W({
|
|
|
16145
16145
|
})
|
|
16146
16146
|
}), t[41] = D, t[42] = V);
|
|
16147
16147
|
let le;
|
|
16148
|
-
t[43] === O ? le = t[44] : (le = O && /* @__PURE__ */ (0, Y.jsx)(
|
|
16148
|
+
t[43] === O ? le = t[44] : (le = O && /* @__PURE__ */ (0, Y.jsx)(Tr, {
|
|
16149
16149
|
value: "sql-code",
|
|
16150
16150
|
className: "mt-1 border rounded-t overflow-hidden",
|
|
16151
16151
|
children: /* @__PURE__ */ (0, Y.jsx)(xw, {
|
|
@@ -16156,7 +16156,7 @@ var ED = xS("marimo-dataframe").withData(W({
|
|
|
16156
16156
|
})
|
|
16157
16157
|
}), t[43] = O, t[44] = le);
|
|
16158
16158
|
let ue;
|
|
16159
|
-
t[45] !== P || t[46] !== oe || t[47] !== ce || t[48] !== V || t[49] !== le ? (ue = /* @__PURE__ */ (0, Y.jsxs)(
|
|
16159
|
+
t[45] !== P || t[46] !== oe || t[47] !== ce || t[48] !== V || t[49] !== le ? (ue = /* @__PURE__ */ (0, Y.jsxs)(on, {
|
|
16160
16160
|
defaultValue: "transform",
|
|
16161
16161
|
onValueChange: P,
|
|
16162
16162
|
children: [
|
|
@@ -16268,12 +16268,12 @@ var MD = {
|
|
|
16268
16268
|
python: Ru,
|
|
16269
16269
|
code: Ru,
|
|
16270
16270
|
json: Lu,
|
|
16271
|
-
text:
|
|
16271
|
+
text: Ye,
|
|
16272
16272
|
image: qu,
|
|
16273
16273
|
audio: zu,
|
|
16274
16274
|
video: Bu,
|
|
16275
16275
|
data: Vu,
|
|
16276
|
-
pdf:
|
|
16276
|
+
pdf: Ye,
|
|
16277
16277
|
zip: Hu,
|
|
16278
16278
|
unknown: Da
|
|
16279
16279
|
};
|
|
@@ -16333,7 +16333,7 @@ function ID(e) {
|
|
|
16333
16333
|
let s = !r, c;
|
|
16334
16334
|
t[2] === s ? c = t[3] : (c = l({ "hidden group-hover:flex group-focus:flex": s }), t[2] = s, t[3] = c);
|
|
16335
16335
|
let u;
|
|
16336
|
-
t[4] !== r || t[5] !== e || t[6] !== i || t[7] !== c ? (u = /* @__PURE__ */ (0, Y.jsx)(
|
|
16336
|
+
t[4] !== r || t[5] !== e || t[6] !== i || t[7] !== c ? (u = /* @__PURE__ */ (0, Y.jsx)(Me, {
|
|
16337
16337
|
checked: r,
|
|
16338
16338
|
"aria-label": e,
|
|
16339
16339
|
tabIndex: -1,
|
|
@@ -16360,7 +16360,7 @@ function ID(e) {
|
|
|
16360
16360
|
}), t[18] = a, t[19] = s), s;
|
|
16361
16361
|
}
|
|
16362
16362
|
var LD = ({ value: e, setValue: t, initialPath: n, selectionMode: r, multiple: i, label: a, restrictNavigation: o, list_directory: s, host: c }) => {
|
|
16363
|
-
let [u, d] =
|
|
16363
|
+
let [u, d] = yn(n), [f, p] = (0, J.useState)(!1), [m, h] = (0, J.useState)(!1), [g, v] = (0, J.useState)(0), y = (0, J.useRef)([]), b = (0, J.useRef)(null), S = (0, J.useRef)(!1), C = c.closest(`[${yt}]`)?.getAttribute(yt), { data: w, error: T, isPending: D } = Ns(() => s({ path: u }), [
|
|
16364
16364
|
u,
|
|
16365
16365
|
C,
|
|
16366
16366
|
s
|
|
@@ -16392,7 +16392,7 @@ var LD = ({ value: e, setValue: t, initialPath: n, selectionMode: r, multiple: i
|
|
|
16392
16392
|
kind: "danger",
|
|
16393
16393
|
children: T.message
|
|
16394
16394
|
});
|
|
16395
|
-
let L =
|
|
16395
|
+
let L = vt.guessDeliminator(n).deliminator, R = e.map((e) => /* @__PURE__ */ (0, Y.jsx)("li", { children: e.path }, e.id));
|
|
16396
16396
|
function ee(e) {
|
|
16397
16397
|
if (f) return;
|
|
16398
16398
|
if (p(!0), e === FD) {
|
|
@@ -16400,7 +16400,7 @@ var LD = ({ value: e, setValue: t, initialPath: n, selectionMode: r, multiple: i
|
|
|
16400
16400
|
p(!1);
|
|
16401
16401
|
return;
|
|
16402
16402
|
}
|
|
16403
|
-
e =
|
|
16403
|
+
e = ke.dirname(u), e === "" && (e = L);
|
|
16404
16404
|
}
|
|
16405
16405
|
let t = e.length < n.length;
|
|
16406
16406
|
if (o && t) {
|
|
@@ -16430,7 +16430,7 @@ var LD = ({ value: e, setValue: t, initialPath: n, selectionMode: r, multiple: i
|
|
|
16430
16430
|
M.has(n) ? t(e.filter((e) => e.path !== n)) : t(i ? [...e, o] : [o]);
|
|
16431
16431
|
}
|
|
16432
16432
|
function B() {
|
|
16433
|
-
t(e.filter((e) =>
|
|
16433
|
+
t(e.filter((e) => ke.dirname(e.path) !== u));
|
|
16434
16434
|
}
|
|
16435
16435
|
function re() {
|
|
16436
16436
|
let n = [];
|
|
@@ -16500,7 +16500,7 @@ var LD = ({ value: e, setValue: t, initialPath: n, selectionMode: r, multiple: i
|
|
|
16500
16500
|
delimiter: L,
|
|
16501
16501
|
initialPath: n,
|
|
16502
16502
|
restrictNavigation: o
|
|
16503
|
-
}), ce = r === "all" ?
|
|
16503
|
+
}), ce = r === "all" ? $e.of("file", "folder") : r === "directory" ? $e.of("folder") : $e.of("file");
|
|
16504
16504
|
return /* @__PURE__ */ (0, Y.jsxs)("div", { children: [
|
|
16505
16505
|
T && /* @__PURE__ */ (0, Y.jsx)(qo, {
|
|
16506
16506
|
kind: "danger",
|
|
@@ -16521,7 +16521,7 @@ var LD = ({ value: e, setValue: t, initialPath: n, selectionMode: r, multiple: i
|
|
|
16521
16521
|
}) })]
|
|
16522
16522
|
}) : t;
|
|
16523
16523
|
})(),
|
|
16524
|
-
/* @__PURE__ */ (0, Y.jsx)(
|
|
16524
|
+
/* @__PURE__ */ (0, Y.jsx)(Ei, {
|
|
16525
16525
|
className: "mt-2 w-full",
|
|
16526
16526
|
placeholder: u,
|
|
16527
16527
|
value: u,
|
|
@@ -16544,13 +16544,13 @@ var LD = ({ value: e, setValue: t, initialPath: n, selectionMode: r, multiple: i
|
|
|
16544
16544
|
className: "absolute inset-0 flex flex-col items-center justify-center gap-2 bg-background/80 text-xs text-muted-foreground pointer-events-none z-10",
|
|
16545
16545
|
role: "status",
|
|
16546
16546
|
children: [/* @__PURE__ */ (0, Y.jsx)(ne, { size: "small" }), /* @__PURE__ */ (0, Y.jsx)("span", { children: "Listing files..." })]
|
|
16547
|
-
}), /* @__PURE__ */ (0, Y.jsx)(
|
|
16547
|
+
}), /* @__PURE__ */ (0, Y.jsx)(Pr, {
|
|
16548
16548
|
ref: b,
|
|
16549
16549
|
className: "cursor-pointer table-fixed",
|
|
16550
16550
|
role: "grid",
|
|
16551
16551
|
"aria-label": "File browser",
|
|
16552
16552
|
"aria-multiselectable": i,
|
|
16553
|
-
children: /* @__PURE__ */ (0, Y.jsx)(
|
|
16553
|
+
children: /* @__PURE__ */ (0, Y.jsx)(Ur, { children: ie.map((e, t) => /* @__PURE__ */ (0, Y.jsxs)(Gr, {
|
|
16554
16554
|
role: "row",
|
|
16555
16555
|
ref: (e) => {
|
|
16556
16556
|
y.current[t] = e;
|
|
@@ -16561,7 +16561,7 @@ var LD = ({ value: e, setValue: t, initialPath: n, selectionMode: r, multiple: i
|
|
|
16561
16561
|
className: l("hover:bg-accent group select-none focus-visible:outline-hidden focus-visible:ring-1 focus-visible:ring-ring focus-visible:ring-inset", { "bg-primary/25 hover:bg-primary/35": e.isSelected }),
|
|
16562
16562
|
"aria-selected": e.canSelect ? e.isSelected : void 0,
|
|
16563
16563
|
onClick: e.onPrimary,
|
|
16564
|
-
children: [/* @__PURE__ */ (0, Y.jsx)(
|
|
16564
|
+
children: [/* @__PURE__ */ (0, Y.jsx)(Cr, {
|
|
16565
16565
|
role: "gridcell",
|
|
16566
16566
|
className: "w-[50px] pl-4",
|
|
16567
16567
|
children: /* @__PURE__ */ (0, Y.jsx)(ID, {
|
|
@@ -16571,7 +16571,7 @@ var LD = ({ value: e, setValue: t, initialPath: n, selectionMode: r, multiple: i
|
|
|
16571
16571
|
Icon: e.Icon,
|
|
16572
16572
|
onSelect: () => e.onToggleSelect?.()
|
|
16573
16573
|
})
|
|
16574
|
-
}), /* @__PURE__ */ (0, Y.jsx)(
|
|
16574
|
+
}), /* @__PURE__ */ (0, Y.jsx)(Cr, {
|
|
16575
16575
|
role: "gridcell",
|
|
16576
16576
|
children: e.name
|
|
16577
16577
|
})]
|
|
@@ -19278,7 +19278,7 @@ var Wk = (e) => {
|
|
|
19278
19278
|
variant: "secondary",
|
|
19279
19279
|
onClick: n,
|
|
19280
19280
|
className: "w-[50px]",
|
|
19281
|
-
children: /* @__PURE__ */ (0, Y.jsx)(
|
|
19281
|
+
children: /* @__PURE__ */ (0, Y.jsx)(Ji, {
|
|
19282
19282
|
className: l("w-6 h-6 border border-input rounded-full"),
|
|
19283
19283
|
strokeWidth: 1.5,
|
|
19284
19284
|
fill: "var(--red-9)"
|
|
@@ -19294,7 +19294,7 @@ var Wk = (e) => {
|
|
|
19294
19294
|
className: "w-5 h-5 rounded-sm",
|
|
19295
19295
|
fill: "var(--red-9)",
|
|
19296
19296
|
strokeWidth: 1.5
|
|
19297
|
-
}), /* @__PURE__ */ (0, Y.jsx)(
|
|
19297
|
+
}), /* @__PURE__ */ (0, Y.jsx)(Ji, {
|
|
19298
19298
|
className: l("w-6 h-6 absolute opacity-20 animate-ping"),
|
|
19299
19299
|
fill: "var(--red-9)",
|
|
19300
19300
|
style: { animationDuration: "1.5s" },
|
|
@@ -19380,7 +19380,7 @@ function qk(e) {
|
|
|
19380
19380
|
let v = ns(_), y;
|
|
19381
19381
|
t[8] === f ? y = t[9] : (y = () => {
|
|
19382
19382
|
o.current?.stream.getTracks().forEach(Jk), o.current?.stop(), f.stop();
|
|
19383
|
-
}, t[8] = f, t[9] = y),
|
|
19383
|
+
}, t[8] = f, t[9] = y), li(y);
|
|
19384
19384
|
let b;
|
|
19385
19385
|
return t[10] !== s || t[11] !== v || t[12] !== u || t[13] !== i || t[14] !== m || t[15] !== g || t[16] !== f.time ? (b = {
|
|
19386
19386
|
start: m,
|
|
@@ -20015,7 +20015,7 @@ var yA = (e) => {
|
|
|
20015
20015
|
else if (e.type === "binary" && n && n.length > 0) t.receiveBinary(n[0]);
|
|
20016
20016
|
else if (e.type === "download" && n && n.length > 0) {
|
|
20017
20017
|
let t = e.format || "png", r = n[0], i = r.buffer.slice(r.byteOffset, r.byteOffset + r.byteLength);
|
|
20018
|
-
|
|
20018
|
+
Qr(new Blob([i], { type: `image/${t}` }), `figure.${t}`);
|
|
20019
20019
|
}
|
|
20020
20020
|
}
|
|
20021
20021
|
};
|
|
@@ -20103,14 +20103,14 @@ var yA = (e) => {
|
|
|
20103
20103
|
disabled: a,
|
|
20104
20104
|
onChange: e.setValue
|
|
20105
20105
|
}, t[2] = i, t[3] = e.setValue, t[4] = a, t[5] = o) : o = t[5];
|
|
20106
|
-
let { value: s, onChange: c } =
|
|
20106
|
+
let { value: s, onChange: c } = ra(o), u;
|
|
20107
20107
|
t[6] === c ? u = t[7] : (u = (e) => {
|
|
20108
20108
|
c(SA(e));
|
|
20109
20109
|
}, t[6] = c, t[7] = u);
|
|
20110
20110
|
let d = u, f = e.label, p = n, m = e.fullWidth, h = e.fullWidth && "w-full", g;
|
|
20111
20111
|
t[8] === h ? g = t[9] : (g = l("min-w-[3em]", h), t[8] = h, t[9] = g);
|
|
20112
20112
|
let _ = e.start ?? void 0, v = e.stop ?? void 0, y = s ?? NaN, b = e.label || "Number input", x;
|
|
20113
|
-
t[10] !== d || t[11] !== n || t[12] !== e.disabled || t[13] !== e.step || t[14] !== v || t[15] !== y || t[16] !== b || t[17] !== g || t[18] !== _ ? (x = /* @__PURE__ */ (0, Y.jsx)(
|
|
20113
|
+
t[10] !== d || t[11] !== n || t[12] !== e.disabled || t[13] !== e.step || t[14] !== v || t[15] !== y || t[16] !== b || t[17] !== g || t[18] !== _ ? (x = /* @__PURE__ */ (0, Y.jsx)(Hi, {
|
|
20114
20114
|
"data-testid": "marimo-plugin-number-input",
|
|
20115
20115
|
className: g,
|
|
20116
20116
|
minValue: _,
|
|
@@ -20581,7 +20581,7 @@ function fj(e) {
|
|
|
20581
20581
|
}, t[5] = n, t[6] = p);
|
|
20582
20582
|
let m;
|
|
20583
20583
|
t[7] !== a || t[8] !== n ? (m = [n, a], t[7] = a, t[8] = n, t[9] = m) : m = t[9], (0, J.useEffect)(p, m);
|
|
20584
|
-
let h =
|
|
20584
|
+
let h = vr(s) ?? s, g, _;
|
|
20585
20585
|
t[10] !== s.layout || t[11] !== h.layout ? (g = () => {
|
|
20586
20586
|
f((e) => dj(s.layout, h.layout, e));
|
|
20587
20587
|
}, _ = [s.layout, h.layout], t[10] = s.layout, t[11] = h.layout, t[12] = g, t[13] = _) : (g = t[12], _ = t[13]), (0, J.useEffect)(g, _);
|
|
@@ -20771,7 +20771,7 @@ var yj = class {
|
|
|
20771
20771
|
let r;
|
|
20772
20772
|
t[5] === n ? r = t[6] : (r = (e, t) => /* @__PURE__ */ (0, Y.jsxs)("div", {
|
|
20773
20773
|
className: "flex items-center space-x-2",
|
|
20774
|
-
children: [/* @__PURE__ */ (0, Y.jsx)(
|
|
20774
|
+
children: [/* @__PURE__ */ (0, Y.jsx)(Yn, {
|
|
20775
20775
|
value: e,
|
|
20776
20776
|
id: `${n}-${t.toString()}`
|
|
20777
20777
|
}), /* @__PURE__ */ (0, Y.jsx)(Jo, {
|
|
@@ -20782,7 +20782,7 @@ var yj = class {
|
|
|
20782
20782
|
}, t), t[5] = n, t[6] = r), d = e.options.map(r), t[2] = n, t[3] = e.options, t[4] = d;
|
|
20783
20783
|
} else d = t[4];
|
|
20784
20784
|
let f;
|
|
20785
|
-
t[7] !== e.disabled || t[8] !== e.setValue || t[9] !== a || t[10] !== c || t[11] !== d ? (f = /* @__PURE__ */ (0, Y.jsx)(
|
|
20785
|
+
t[7] !== e.disabled || t[8] !== e.setValue || t[9] !== a || t[10] !== c || t[11] !== d ? (f = /* @__PURE__ */ (0, Y.jsx)(Gn, {
|
|
20786
20786
|
"data-testid": "marimo-plugin-radio",
|
|
20787
20787
|
value: a,
|
|
20788
20788
|
onValueChange: o,
|
|
@@ -20866,7 +20866,7 @@ var yj = class {
|
|
|
20866
20866
|
})
|
|
20867
20867
|
}), n[23] = s.setFalse, n[24] = s.setTrue, n[25] = M) : M = n[25];
|
|
20868
20868
|
let N;
|
|
20869
|
-
n[26] !== c || n[27] !== i.value || n[28] !== a ? (N = i.value != null && i.value.length === 2 && /* @__PURE__ */ (0, Y.jsx)(ue, { children:
|
|
20869
|
+
n[26] !== c || n[27] !== i.value || n[28] !== a ? (N = i.value != null && i.value.length === 2 && /* @__PURE__ */ (0, Y.jsx)(ue, { children: zi(a(i.value[0]), { locale: c }) }, i.value[0]), n[26] = c, n[27] = i.value, n[28] = a, n[29] = N) : N = n[29];
|
|
20870
20870
|
let P;
|
|
20871
20871
|
n[30] === N ? P = n[31] : (P = /* @__PURE__ */ (0, Y.jsx)(pe, { children: N }), n[30] = N, n[31] = P);
|
|
20872
20872
|
let F;
|
|
@@ -20888,7 +20888,7 @@ var yj = class {
|
|
|
20888
20888
|
})
|
|
20889
20889
|
}), n[36] = s.setFalse, n[37] = s.setTrue, n[38] = I) : I = n[38];
|
|
20890
20890
|
let L;
|
|
20891
|
-
n[39] !== c || n[40] !== i.value || n[41] !== a ? (L = i.value != null && i.value.length === 2 && /* @__PURE__ */ (0, Y.jsx)(ue, { children:
|
|
20891
|
+
n[39] !== c || n[40] !== i.value || n[41] !== a ? (L = i.value != null && i.value.length === 2 && /* @__PURE__ */ (0, Y.jsx)(ue, { children: zi(a(i.value[1]), { locale: c }) }, i.value[1]), n[39] = c, n[40] = i.value, n[41] = a, n[42] = L) : L = n[42];
|
|
20892
20892
|
let R;
|
|
20893
20893
|
n[43] === L ? R = n[44] : (R = /* @__PURE__ */ (0, Y.jsx)(pe, { children: L }), n[43] = L, n[44] = R);
|
|
20894
20894
|
let ee;
|
|
@@ -20978,7 +20978,7 @@ var Sj = class {
|
|
|
20978
20978
|
let P;
|
|
20979
20979
|
t[34] !== _ || t[35] !== g || t[36] !== d || t[37] !== m ? (P = d && /* @__PURE__ */ (0, Y.jsx)("div", {
|
|
20980
20980
|
className: "text-xs text-muted-foreground min-w-[16px]",
|
|
20981
|
-
children: `${
|
|
20981
|
+
children: `${zi(m(_[0]), { locale: g })}, ${zi(m(_[1]), { locale: g })}`
|
|
20982
20982
|
}), t[34] = _, t[35] = g, t[36] = d, t[37] = m, t[38] = P) : P = t[38];
|
|
20983
20983
|
let F;
|
|
20984
20984
|
t[39] !== N || t[40] !== P || t[41] !== E ? (F = /* @__PURE__ */ (0, Y.jsxs)("div", {
|
|
@@ -21134,7 +21134,7 @@ var Sj = class {
|
|
|
21134
21134
|
className: l(s, "border mb-0 rounded", c && "border-r-0 rounded-tr-none rounded-br-none"),
|
|
21135
21135
|
onClick: o,
|
|
21136
21136
|
children: /* @__PURE__ */ (0, Y.jsx)(Zu, { className: l("w-3.5 h-3.5", i && "animate-spin") })
|
|
21137
|
-
}), /* @__PURE__ */ (0, Y.jsxs)(
|
|
21137
|
+
}), /* @__PURE__ */ (0, Y.jsxs)(Ei, {
|
|
21138
21138
|
"data-testid": "marimo-plugin-refresh-select",
|
|
21139
21139
|
onChange: (e) => {
|
|
21140
21140
|
r(e.target.value);
|
|
@@ -21196,13 +21196,13 @@ function Nj(e) {
|
|
|
21196
21196
|
r > 0 && r < n && (n = r);
|
|
21197
21197
|
}
|
|
21198
21198
|
(!Number.isFinite(n) || n <= 0) && (n = 1);
|
|
21199
|
-
let r =
|
|
21199
|
+
let r = sa(e, n);
|
|
21200
21200
|
return {
|
|
21201
21201
|
steps: e,
|
|
21202
21202
|
fractionDigits: r,
|
|
21203
|
-
minValue:
|
|
21204
|
-
maxValue:
|
|
21205
|
-
inputStep:
|
|
21203
|
+
minValue: Fi(t[0], r),
|
|
21204
|
+
maxValue: Fi(t[t.length - 1], r),
|
|
21205
|
+
inputStep: Fi(n, r),
|
|
21206
21206
|
formatOptions: {
|
|
21207
21207
|
minimumFractionDigits: 0,
|
|
21208
21208
|
maximumFractionDigits: r
|
|
@@ -21224,7 +21224,7 @@ var Pj = (e) => {
|
|
|
21224
21224
|
b(0), r(0);
|
|
21225
21225
|
return;
|
|
21226
21226
|
}
|
|
21227
|
-
let i =
|
|
21227
|
+
let i = Fi(e, n), a = Mj(t, i), o = Fi(t[y] ?? t[0], n);
|
|
21228
21228
|
a === y && i !== o && (a = i > o ? Math.min(y + 1, t.length - 1) : Math.max(y - 1, 0)), b(a), r(a);
|
|
21229
21229
|
return;
|
|
21230
21230
|
}
|
|
@@ -21233,7 +21233,7 @@ var Pj = (e) => {
|
|
|
21233
21233
|
}, t[5] = y, t[6] = r, t[7] = a, t[8] = w, t[9] = T) : T = t[9];
|
|
21234
21234
|
let E = T, D;
|
|
21235
21235
|
t[10] !== y || t[11] !== a || t[12] !== s || t[13] !== w || t[14] !== o || t[15] !== m ? (D = w ? {
|
|
21236
|
-
value:
|
|
21236
|
+
value: Fi(m(y), w.fractionDigits),
|
|
21237
21237
|
minValue: w.minValue,
|
|
21238
21238
|
maxValue: w.maxValue,
|
|
21239
21239
|
step: w.inputStep,
|
|
@@ -21277,10 +21277,10 @@ var Pj = (e) => {
|
|
|
21277
21277
|
let z;
|
|
21278
21278
|
t[41] !== y || t[42] !== v || t[43] !== f || t[44] !== m ? (z = f && /* @__PURE__ */ (0, Y.jsx)("div", {
|
|
21279
21279
|
className: "text-xs text-muted-foreground min-w-[16px]",
|
|
21280
|
-
children:
|
|
21280
|
+
children: zi(m(y), { locale: v })
|
|
21281
21281
|
}), t[41] = y, t[42] = v, t[43] = f, t[44] = m, t[45] = z) : z = t[45];
|
|
21282
21282
|
let te;
|
|
21283
|
-
t[46] !== g || t[47] !== E || t[48] !== h || t[49] !== O || t[50] !== n ? (te = h && /* @__PURE__ */ (0, Y.jsx)(
|
|
21283
|
+
t[46] !== g || t[47] !== E || t[48] !== h || t[49] !== O || t[50] !== n ? (te = h && /* @__PURE__ */ (0, Y.jsx)(Hi, {
|
|
21284
21284
|
...O,
|
|
21285
21285
|
onChange: E,
|
|
21286
21286
|
className: "w-24",
|
|
@@ -21317,7 +21317,7 @@ var Pj = (e) => {
|
|
|
21317
21317
|
}
|
|
21318
21318
|
}, Ij = (e) => {
|
|
21319
21319
|
let t = (0, X.c)(9), { value: n, setValue: r, data: i } = e, a = (0, J.useId)(), o;
|
|
21320
|
-
t[0] !== i.disabled || t[1] !== a || t[2] !== r || t[3] !== n ? (o = /* @__PURE__ */ (0, Y.jsx)(
|
|
21320
|
+
t[0] !== i.disabled || t[1] !== a || t[2] !== r || t[3] !== n ? (o = /* @__PURE__ */ (0, Y.jsx)(lr, {
|
|
21321
21321
|
"data-testid": "marimo-plugin-switch",
|
|
21322
21322
|
checked: n,
|
|
21323
21323
|
onCheckedChange: r,
|
|
@@ -21364,14 +21364,14 @@ var Pj = (e) => {
|
|
|
21364
21364
|
let b;
|
|
21365
21365
|
if (t[8] !== p || t[9] !== n) {
|
|
21366
21366
|
let e;
|
|
21367
|
-
t[11] === p ? e = t[12] : (e = (e, t) => /* @__PURE__ */ (0, Y.jsx)(
|
|
21367
|
+
t[11] === p ? e = t[12] : (e = (e, t) => /* @__PURE__ */ (0, Y.jsx)(Mn, {
|
|
21368
21368
|
value: t.toString(),
|
|
21369
21369
|
className: l(p && "w-full justify-start"),
|
|
21370
21370
|
children: E({ html: e })
|
|
21371
21371
|
}, t), t[11] = p, t[12] = e), b = n.map(e), t[8] = p, t[9] = n, t[10] = b;
|
|
21372
21372
|
} else b = t[10];
|
|
21373
21373
|
let x;
|
|
21374
|
-
t[13] !== y || t[14] !== b ? (x = /* @__PURE__ */ (0, Y.jsx)(
|
|
21374
|
+
t[13] !== y || t[14] !== b ? (x = /* @__PURE__ */ (0, Y.jsx)(An, {
|
|
21375
21375
|
className: y,
|
|
21376
21376
|
children: b
|
|
21377
21377
|
}), t[13] = y, t[14] = b, t[15] = x) : x = t[15];
|
|
@@ -21385,7 +21385,7 @@ var Pj = (e) => {
|
|
|
21385
21385
|
children: w
|
|
21386
21386
|
}), t[20] = C, t[21] = w, t[22] = T) : T = t[22];
|
|
21387
21387
|
let D;
|
|
21388
|
-
t[23] !== f || t[24] !== c || t[25] !== i || t[26] !== T || t[27] !== _ || t[28] !== x ? (D = /* @__PURE__ */ (0, Y.jsxs)(
|
|
21388
|
+
t[23] !== f || t[24] !== c || t[25] !== i || t[26] !== T || t[27] !== _ || t[28] !== x ? (D = /* @__PURE__ */ (0, Y.jsxs)(on, {
|
|
21389
21389
|
value: c,
|
|
21390
21390
|
onValueChange: f,
|
|
21391
21391
|
orientation: i,
|
|
@@ -21401,7 +21401,7 @@ var Pj = (e) => {
|
|
|
21401
21401
|
}), t[30] = r, t[31] = D, t[32] = O) : O = t[32], O;
|
|
21402
21402
|
};
|
|
21403
21403
|
function zj(e, t) {
|
|
21404
|
-
return /* @__PURE__ */ (0, Y.jsx)(
|
|
21404
|
+
return /* @__PURE__ */ (0, Y.jsx)(Tr, {
|
|
21405
21405
|
value: t.toString(),
|
|
21406
21406
|
children: e
|
|
21407
21407
|
}, t);
|
|
@@ -21535,7 +21535,7 @@ var Bj = class {
|
|
|
21535
21535
|
passwordHasValue: H().optional()
|
|
21536
21536
|
});
|
|
21537
21537
|
render(e) {
|
|
21538
|
-
let t = e.data.kind === "password" ? e.host.closest(`[${
|
|
21538
|
+
let t = e.data.kind === "password" ? e.host.closest(`[${yt}]`)?.getAttribute(yt) : void 0;
|
|
21539
21539
|
return /* @__PURE__ */ (0, Y.jsx)(Wj, {
|
|
21540
21540
|
...e.data,
|
|
21541
21541
|
value: e.value,
|
|
@@ -21577,7 +21577,7 @@ var Bj = class {
|
|
|
21577
21577
|
let w = C, T;
|
|
21578
21578
|
if (e.debounce === !0) {
|
|
21579
21579
|
let n = y[e.kind], r = e.minLength != null && e.minLength > 0, i;
|
|
21580
|
-
t[15] !== x || t[16] !== w || t[17] !== f || t[18] !== s || t[19] !== e.disabled || t[20] !== e.kind || t[21] !== e.maxLength || t[22] !== e.minLength || t[23] !== u || t[24] !== n || t[25] !== r || t[26] !== o ? (i = /* @__PURE__ */ (0, Y.jsx)(
|
|
21580
|
+
t[15] !== x || t[16] !== w || t[17] !== f || t[18] !== s || t[19] !== e.disabled || t[20] !== e.kind || t[21] !== e.maxLength || t[22] !== e.minLength || t[23] !== u || t[24] !== n || t[25] !== r || t[26] !== o ? (i = /* @__PURE__ */ (0, Y.jsx)(Yi, {
|
|
21581
21581
|
"data-testid": "marimo-plugin-text-input",
|
|
21582
21582
|
type: e.kind,
|
|
21583
21583
|
icon: n,
|
|
@@ -21596,7 +21596,7 @@ var Bj = class {
|
|
|
21596
21596
|
let n = y[e.kind], r = e.minLength != null && e.minLength > 0, i;
|
|
21597
21597
|
t[28] === Symbol.for("react.memo_cache_sentinel") ? (i = (e) => m(e.currentTarget.value), t[28] = i) : i = t[28];
|
|
21598
21598
|
let a;
|
|
21599
|
-
t[29] !== x || t[30] !== w || t[31] !== f || t[32] !== s || t[33] !== e.debounce || t[34] !== e.disabled || t[35] !== e.kind || t[36] !== e.maxLength || t[37] !== e.minLength || t[38] !== u || t[39] !== n || t[40] !== r || t[41] !== o ? (a = /* @__PURE__ */ (0, Y.jsx)(
|
|
21599
|
+
t[29] !== x || t[30] !== w || t[31] !== f || t[32] !== s || t[33] !== e.debounce || t[34] !== e.disabled || t[35] !== e.kind || t[36] !== e.maxLength || t[37] !== e.minLength || t[38] !== u || t[39] !== n || t[40] !== r || t[41] !== o ? (a = /* @__PURE__ */ (0, Y.jsx)(ta, {
|
|
21600
21600
|
"data-testid": "marimo-plugin-text-input",
|
|
21601
21601
|
type: e.kind,
|
|
21602
21602
|
icon: n,
|
|
@@ -21619,7 +21619,7 @@ var Bj = class {
|
|
|
21619
21619
|
let a;
|
|
21620
21620
|
t[45] === Symbol.for("react.memo_cache_sentinel") ? (a = (e) => m(e.currentTarget.value), t[45] = a) : a = t[45];
|
|
21621
21621
|
let c;
|
|
21622
|
-
t[46] !== x || t[47] !== w || t[48] !== f || t[49] !== s || t[50] !== e.disabled || t[51] !== e.kind || t[52] !== e.maxLength || t[53] !== e.minLength || t[54] !== n || t[55] !== r || t[56] !== i || t[57] !== o ? (c = /* @__PURE__ */ (0, Y.jsx)(
|
|
21622
|
+
t[46] !== x || t[47] !== w || t[48] !== f || t[49] !== s || t[50] !== e.disabled || t[51] !== e.kind || t[52] !== e.maxLength || t[53] !== e.minLength || t[54] !== n || t[55] !== r || t[56] !== i || t[57] !== o ? (c = /* @__PURE__ */ (0, Y.jsx)(Xi, {
|
|
21623
21623
|
"data-testid": "marimo-plugin-text-input",
|
|
21624
21624
|
type: e.kind,
|
|
21625
21625
|
icon: n,
|
|
@@ -21653,7 +21653,7 @@ function Gj(e, t) {
|
|
|
21653
21653
|
}
|
|
21654
21654
|
//#endregion
|
|
21655
21655
|
//#region src/plugins/impl/vega/VegaPlugin.tsx
|
|
21656
|
-
var Kj = J.lazy(() => import("./vega-component-
|
|
21656
|
+
var Kj = J.lazy(() => import("./vega-component-CNf5gcrm.js")), qj = class {
|
|
21657
21657
|
tagName = "marimo-vega";
|
|
21658
21658
|
validator = W({
|
|
21659
21659
|
spec: W({}).passthrough().transform((e) => e),
|
|
@@ -21731,7 +21731,7 @@ var Kj = J.lazy(() => import("./vega-component-D0QXopU8.js")), qj = class {
|
|
|
21731
21731
|
children: i
|
|
21732
21732
|
}), t[2] = i, t[3] = s);
|
|
21733
21733
|
let c;
|
|
21734
|
-
t[4] === n ? c = t[5] : (c = /* @__PURE__ */ (0, Y.jsx)(
|
|
21734
|
+
t[4] === n ? c = t[5] : (c = /* @__PURE__ */ (0, Y.jsx)(qn, {
|
|
21735
21735
|
html: n,
|
|
21736
21736
|
alwaysSanitizeHtml: !0
|
|
21737
21737
|
}), t[4] = n, t[5] = c);
|
|
@@ -21799,13 +21799,13 @@ var Qj = class {
|
|
|
21799
21799
|
return;
|
|
21800
21800
|
}
|
|
21801
21801
|
if (n.preventDefault(), !e.lazy) {
|
|
21802
|
-
|
|
21802
|
+
ri(e.data, e.filename ?? void 0);
|
|
21803
21803
|
return;
|
|
21804
21804
|
}
|
|
21805
21805
|
r(!0);
|
|
21806
21806
|
try {
|
|
21807
21807
|
let n = await t({});
|
|
21808
|
-
|
|
21808
|
+
ri(n.data || e.data, n.filename ?? e.filename ?? void 0);
|
|
21809
21809
|
} catch (e) {
|
|
21810
21810
|
x({
|
|
21811
21811
|
title: "Failed to download",
|
|
@@ -21814,7 +21814,7 @@ var Qj = class {
|
|
|
21814
21814
|
} finally {
|
|
21815
21815
|
r(!1);
|
|
21816
21816
|
}
|
|
21817
|
-
}, a = n ? F :
|
|
21817
|
+
}, a = n ? F : sr, o = e.label ? E({ html: e.label }) : "Download";
|
|
21818
21818
|
return /* @__PURE__ */ (0, Y.jsxs)("a", {
|
|
21819
21819
|
href: e.data,
|
|
21820
21820
|
download: e.filename ?? "",
|
|
@@ -21850,7 +21850,7 @@ var Qj = class {
|
|
|
21850
21850
|
});
|
|
21851
21851
|
render({ data: e }) {
|
|
21852
21852
|
let t = e.name === void 0 ? !1 : e.name || "";
|
|
21853
|
-
return /* @__PURE__ */ (0, Y.jsx)(
|
|
21853
|
+
return /* @__PURE__ */ (0, Y.jsx)(mr, {
|
|
21854
21854
|
data: e.jsonData,
|
|
21855
21855
|
format: "auto",
|
|
21856
21856
|
valueTypes: e.valueTypes,
|
|
@@ -21869,7 +21869,7 @@ var Qj = class {
|
|
|
21869
21869
|
root: null,
|
|
21870
21870
|
rootMargin: "0px"
|
|
21871
21871
|
}, t[0] = o) : o = t[0];
|
|
21872
|
-
let [s, c] =
|
|
21872
|
+
let [s, c] = xr(o);
|
|
21873
21873
|
c?.isIntersecting && !i && a(!0);
|
|
21874
21874
|
let l;
|
|
21875
21875
|
t[1] !== n || t[2] !== i ? (l = (e) => i ? n({}) : (e.previous(), Promise.resolve(void 0)), t[1] = n, t[2] = i, t[3] = l) : l = t[3];
|
|
@@ -21900,7 +21900,7 @@ var Qj = class {
|
|
|
21900
21900
|
]).transform((e) => e)
|
|
21901
21901
|
});
|
|
21902
21902
|
render({ data: e }) {
|
|
21903
|
-
return e.data ? /* @__PURE__ */ (0, Y.jsx)(
|
|
21903
|
+
return e.data ? /* @__PURE__ */ (0, Y.jsx)(Ar, { message: {
|
|
21904
21904
|
data: e.data,
|
|
21905
21905
|
channel: "output",
|
|
21906
21906
|
mimetype: e.mime
|
|
@@ -21924,7 +21924,7 @@ var Qj = class {
|
|
|
21924
21924
|
//#endregion
|
|
21925
21925
|
//#region src/components/editor/chrome/panels/outline/useActiveOutline.tsx
|
|
21926
21926
|
function vM() {
|
|
21927
|
-
return
|
|
21927
|
+
return va() === "edit" ? document.getElementById("App") : void 0;
|
|
21928
21928
|
}
|
|
21929
21929
|
function yM(e) {
|
|
21930
21930
|
let t = (0, X.c)(7), [n, r] = (0, J.useState)(void 0), [i, a] = (0, J.useState)(void 0), o = (0, J.useRef)(null), s = (0, J.useRef)(null), c;
|
|
@@ -21936,7 +21936,7 @@ function yM(e) {
|
|
|
21936
21936
|
let n = e.target;
|
|
21937
21937
|
e.isIntersecting ? (!s.current || n.getBoundingClientRect().top < s.current.getBoundingClientRect().top) && (s.current = n, t = !0) : n === s.current && (s.current = null, t = !0);
|
|
21938
21938
|
}), t && s.current) {
|
|
21939
|
-
let e =
|
|
21939
|
+
let e = He(s.current), t = "id" in e ? e.id : e.path;
|
|
21940
21940
|
r(t), a(l.current.get(s.current));
|
|
21941
21941
|
}
|
|
21942
21942
|
}, {
|
|
@@ -21945,7 +21945,7 @@ function yM(e) {
|
|
|
21945
21945
|
threshold: 0
|
|
21946
21946
|
}), e.forEach((t) => {
|
|
21947
21947
|
if (t) {
|
|
21948
|
-
let n =
|
|
21948
|
+
let n = He(t[0]), r = e.map(bM).filter((e) => "id" in n ? e.id === n.id : e.textContent === t[0].textContent).indexOf(t[0]);
|
|
21949
21949
|
l.current.set(t[0], r), o.current?.observe(t[0]);
|
|
21950
21950
|
}
|
|
21951
21951
|
}), () => {
|
|
@@ -21990,7 +21990,7 @@ function CM(e, t) {
|
|
|
21990
21990
|
//#endregion
|
|
21991
21991
|
//#region src/components/editor/chrome/panels/outline/floating-outline.tsx
|
|
21992
21992
|
var wM = () => {
|
|
21993
|
-
let e = (0, X.c)(19), { items: t } = rs(
|
|
21993
|
+
let e = (0, X.c)(19), { items: t } = rs(tt), n;
|
|
21994
21994
|
e[0] === t ? n = e[1] : (n = xM(t), e[0] = t, e[1] = n);
|
|
21995
21995
|
let { activeHeaderId: r, activeOccurrences: i } = yM(n), [a, o] = J.useState(!1);
|
|
21996
21996
|
if (t.length < 2) return null;
|
|
@@ -22061,7 +22061,7 @@ var wM = () => {
|
|
|
22061
22061
|
children: s
|
|
22062
22062
|
}), t[8] = o, t[9] = s, t[10] = c) : c = t[10], c;
|
|
22063
22063
|
}, DM = (e) => {
|
|
22064
|
-
let t = (0, X.c)(12), { label: n } = e, { items: r } = rs(
|
|
22064
|
+
let t = (0, X.c)(12), { label: n } = e, { items: r } = rs(tt), i;
|
|
22065
22065
|
t[0] === r ? i = t[1] : (i = xM(r), t[0] = r, t[1] = i);
|
|
22066
22066
|
let { activeHeaderId: a, activeOccurrences: o } = yM(i);
|
|
22067
22067
|
if (r.length === 0) {
|
|
@@ -22871,7 +22871,7 @@ var wM = () => {
|
|
|
22871
22871
|
let t = (0, X.c)(24), { title: n, subtitle: r, progress: i, total: a, eta: o, rate: s } = e, c = typeof i == "number" ? "items-start" : "items-center", l;
|
|
22872
22872
|
t[0] !== i || t[1] !== a ? (l = () => typeof i == "number" && a != null && a > 0 ? /* @__PURE__ */ (0, Y.jsxs)("div", {
|
|
22873
22873
|
className: "flex gap-3 text-sm text-muted-foreground items-baseline",
|
|
22874
|
-
children: [/* @__PURE__ */ (0, Y.jsx)(
|
|
22874
|
+
children: [/* @__PURE__ */ (0, Y.jsx)(Bn, { value: MM(i / a * 100) }), /* @__PURE__ */ (0, Y.jsxs)("span", {
|
|
22875
22875
|
className: "shrink-0",
|
|
22876
22876
|
children: [
|
|
22877
22877
|
i,
|
|
@@ -23183,10 +23183,10 @@ var FM = (/* @__PURE__ */ i(((e) => {
|
|
|
23183
23183
|
}
|
|
23184
23184
|
}, BM = (e) => {
|
|
23185
23185
|
let t = (0, X.c)(31), { value: n, label: r, caption: i, bordered: a, direction: o, target_direction: s, slot: u } = e, { locale: d } = Xo(), f;
|
|
23186
|
-
t[0] !== d || t[1] !== n ? (f = () => n == null ? /* @__PURE__ */ (0, Y.jsx)("i", { children: "No value" }) : typeof n == "string" ? n : typeof n == "number" ?
|
|
23186
|
+
t[0] !== d || t[1] !== n ? (f = () => n == null ? /* @__PURE__ */ (0, Y.jsx)("i", { children: "No value" }) : typeof n == "string" ? n : typeof n == "number" ? la(n, d) : typeof n == "boolean" ? n ? "True" : "False" : String(n), t[0] = d, t[1] = n, t[2] = f) : f = t[2];
|
|
23187
23187
|
let p = f, m = o === s, h = m ? "var(--grass-8)" : "var(--red-8)", g = m ? "var(--grass-9)" : "var(--red-9)", _;
|
|
23188
23188
|
t[3] === u ? _ = t[4] : (_ = () => {
|
|
23189
|
-
let e =
|
|
23189
|
+
let e = ti(u);
|
|
23190
23190
|
if (e?.[0]) {
|
|
23191
23191
|
let { mimetype: t, data: n } = e[0];
|
|
23192
23192
|
return t !== "text/html" && c.warn(`Expected text/html, got ${t}`), E({
|
|
@@ -26426,7 +26426,7 @@ var nP = (0, ZN.WidthProvider)(ZN.Responsive), rP = [0, 0], iP = "grid-drag-hand
|
|
|
26426
26426
|
t[7] === v ? (y = t[8], b = t[9]) : ({isDragging: b, ...y} = v, t[7] = v, t[8] = y, t[9] = b);
|
|
26427
26427
|
let x = !o && !f, S, C, w, T, E, D, O, k, A, j, M, N, P, F, I, L, R, ee, z, te, B, ne, re, ie, ae, oe;
|
|
26428
26428
|
if (t[10] !== i || t[11] !== h || t[12] !== y || t[13] !== u || t[14] !== x || t[15] !== c || t[16] !== b || t[17] !== o || t[18] !== n || t[19] !== a || t[20] !== r) {
|
|
26429
|
-
let e =
|
|
26429
|
+
let e = mn.keyBy(n.cells, pP), s;
|
|
26430
26430
|
t[47] !== n || t[48] !== r ? (s = (e) => (t) => {
|
|
26431
26431
|
let i = new Set(n.scrollableCells);
|
|
26432
26432
|
t ? i.add(e) : i.delete(e), r({
|
|
@@ -26474,7 +26474,7 @@ var nP = (0, ZN.WidthProvider)(ZN.Responsive), rP = [0, 0], iP = "grid-drag-hand
|
|
|
26474
26474
|
cellId: t.id,
|
|
26475
26475
|
output: t.output,
|
|
26476
26476
|
status: t.status,
|
|
26477
|
-
stale:
|
|
26477
|
+
stale: Ot(t, !1),
|
|
26478
26478
|
isScrollable: o,
|
|
26479
26479
|
side: s,
|
|
26480
26480
|
hidden: t.errored || t.interrupted || t.stopped
|
|
@@ -26550,7 +26550,7 @@ var nP = (0, ZN.WidthProvider)(ZN.Responsive), rP = [0, 0], iP = "grid-drag-hand
|
|
|
26550
26550
|
cellId: e.id,
|
|
26551
26551
|
output: e.output,
|
|
26552
26552
|
status: e.status,
|
|
26553
|
-
stale:
|
|
26553
|
+
stale: Ot(e, !1),
|
|
26554
26554
|
isScrollable: !1,
|
|
26555
26555
|
hidden: !1
|
|
26556
26556
|
}, e.id), t[130] = a, t[131] = r), me = /* @__PURE__ */ (0, Y.jsxs)(Y.Fragment, { children: [ce, /* @__PURE__ */ (0, Y.jsx)("div", {
|
|
@@ -26608,7 +26608,7 @@ var nP = (0, ZN.WidthProvider)(ZN.Responsive), rP = [0, 0], iP = "grid-drag-hand
|
|
|
26608
26608
|
output: e.output,
|
|
26609
26609
|
isScrollable: !1,
|
|
26610
26610
|
status: e.status,
|
|
26611
|
-
stale:
|
|
26611
|
+
stale: Ot(e, !1),
|
|
26612
26612
|
hidden: !1
|
|
26613
26613
|
})
|
|
26614
26614
|
}, e.id), t[146] = n.columns, t[147] = n.rowHeight, t[148] = a, t[149] = m) : m = t[149], ue = s.map(m);
|
|
@@ -26642,7 +26642,7 @@ var nP = (0, ZN.WidthProvider)(ZN.Responsive), rP = [0, 0], iP = "grid-drag-hand
|
|
|
26642
26642
|
let h = s && "invisible", g = c ? "overflow-y-auto" : "overflow-y-hidden", _ = u === "top" && "flex items-start", v = u === "bottom" && "flex items-end", y = u === "left" && "flex justify-start", b = u === "right" && "flex justify-end", x;
|
|
26643
26643
|
t[5] !== d || t[6] !== h || t[7] !== g || t[8] !== _ || t[9] !== v || t[10] !== y || t[11] !== b ? (x = l(d, "h-full w-full p-2 overflow-x-auto", h, g, _, v, y, b), t[5] = d, t[6] = h, t[7] = g, t[8] = _, t[9] = v, t[10] = y, t[11] = b, t[12] = x) : x = t[12];
|
|
26644
26644
|
let S;
|
|
26645
|
-
t[13] !== r || t[14] !== m || t[15] !== n || t[16] !== f ? (S = /* @__PURE__ */ (0, Y.jsx)(
|
|
26645
|
+
t[13] !== r || t[14] !== m || t[15] !== n || t[16] !== f ? (S = /* @__PURE__ */ (0, Y.jsx)(Ir, {
|
|
26646
26646
|
allowExpand: !1,
|
|
26647
26647
|
output: n,
|
|
26648
26648
|
cellId: r,
|
|
@@ -26672,7 +26672,7 @@ var sP = (e) => {
|
|
|
26672
26672
|
let c;
|
|
26673
26673
|
t[4] !== n.columns || t[5] !== s ? (c = /* @__PURE__ */ (0, Y.jsxs)("div", {
|
|
26674
26674
|
className: "flex flex-row items-center gap-2",
|
|
26675
|
-
children: [o, /* @__PURE__ */ (0, Y.jsx)(
|
|
26675
|
+
children: [o, /* @__PURE__ */ (0, Y.jsx)(Hi, {
|
|
26676
26676
|
"data-testid": "grid-columns-input",
|
|
26677
26677
|
id: "columns",
|
|
26678
26678
|
value: n.columns,
|
|
@@ -26697,7 +26697,7 @@ var sP = (e) => {
|
|
|
26697
26697
|
let d;
|
|
26698
26698
|
t[11] !== n.rowHeight || t[12] !== u ? (d = /* @__PURE__ */ (0, Y.jsxs)("div", {
|
|
26699
26699
|
className: "flex flex-row items-center gap-2",
|
|
26700
|
-
children: [l, /* @__PURE__ */ (0, Y.jsx)(
|
|
26700
|
+
children: [l, /* @__PURE__ */ (0, Y.jsx)(Hi, {
|
|
26701
26701
|
"data-testid": "grid-row-height-input",
|
|
26702
26702
|
id: "rowHeight",
|
|
26703
26703
|
value: n.rowHeight,
|
|
@@ -26722,7 +26722,7 @@ var sP = (e) => {
|
|
|
26722
26722
|
let m;
|
|
26723
26723
|
t[18] !== n.maxWidth || t[19] !== p ? (m = /* @__PURE__ */ (0, Y.jsxs)("div", {
|
|
26724
26724
|
className: "flex flex-row items-center gap-2",
|
|
26725
|
-
children: [f, /* @__PURE__ */ (0, Y.jsx)(
|
|
26725
|
+
children: [f, /* @__PURE__ */ (0, Y.jsx)(Hi, {
|
|
26726
26726
|
"data-testid": "grid-max-width-input",
|
|
26727
26727
|
id: "maxWidth",
|
|
26728
26728
|
value: n.maxWidth,
|
|
@@ -26748,7 +26748,7 @@ var sP = (e) => {
|
|
|
26748
26748
|
let _;
|
|
26749
26749
|
t[25] !== n.bordered || t[26] !== g ? (_ = /* @__PURE__ */ (0, Y.jsxs)("div", {
|
|
26750
26750
|
className: "flex flex-row items-center gap-2",
|
|
26751
|
-
children: [h, /* @__PURE__ */ (0, Y.jsx)(
|
|
26751
|
+
children: [h, /* @__PURE__ */ (0, Y.jsx)(lr, {
|
|
26752
26752
|
"data-testid": "grid-bordered-switch",
|
|
26753
26753
|
id: "lock",
|
|
26754
26754
|
checked: n.bordered,
|
|
@@ -26765,7 +26765,7 @@ var sP = (e) => {
|
|
|
26765
26765
|
let y;
|
|
26766
26766
|
t[29] !== i || t[30] !== a ? (y = /* @__PURE__ */ (0, Y.jsxs)("div", {
|
|
26767
26767
|
className: "flex flex-row items-center gap-2",
|
|
26768
|
-
children: [v, /* @__PURE__ */ (0, Y.jsx)(
|
|
26768
|
+
children: [v, /* @__PURE__ */ (0, Y.jsx)(lr, {
|
|
26769
26769
|
"data-testid": "grid-lock-switch",
|
|
26770
26770
|
id: "lock",
|
|
26771
26771
|
checked: i,
|
|
@@ -26815,32 +26815,32 @@ var lP = (e) => {
|
|
|
26815
26815
|
let g = c === "side", _;
|
|
26816
26816
|
t[4] === u ? _ = t[5] : (_ = (e) => u(e ? "side" : void 0), t[4] = u, t[5] = _);
|
|
26817
26817
|
let v;
|
|
26818
|
-
t[6] === d ? v = t[7] : (v = /* @__PURE__ */ (0, Y.jsx)(
|
|
26818
|
+
t[6] === d ? v = t[7] : (v = /* @__PURE__ */ (0, Y.jsx)(qi, {
|
|
26819
26819
|
asChild: !0,
|
|
26820
26820
|
children: d ? /* @__PURE__ */ (0, Y.jsx)(d, { className: "h-4 w-4 opacity-60 hover:opacity-100" }) : /* @__PURE__ */ (0, Y.jsx)(Tu, { className: "h-4 w-4 opacity-60 hover:opacity-100" })
|
|
26821
26821
|
}), t[6] = d, t[7] = v);
|
|
26822
26822
|
let y;
|
|
26823
26823
|
t[8] !== a || t[9] !== i ? (y = Es.entries(dP).map((e) => {
|
|
26824
26824
|
let [t, n] = e;
|
|
26825
|
-
return /* @__PURE__ */ (0, Y.jsxs)(
|
|
26825
|
+
return /* @__PURE__ */ (0, Y.jsxs)(Zi, {
|
|
26826
26826
|
onSelect: () => a(t),
|
|
26827
26827
|
children: [
|
|
26828
26828
|
/* @__PURE__ */ (0, Y.jsx)(n, { className: "h-4 w-3 mr-2" }),
|
|
26829
26829
|
/* @__PURE__ */ (0, Y.jsx)("span", {
|
|
26830
26830
|
className: "flex-1",
|
|
26831
|
-
children:
|
|
26831
|
+
children: Si.startCase(t)
|
|
26832
26832
|
}),
|
|
26833
|
-
t === i && /* @__PURE__ */ (0, Y.jsx)(
|
|
26833
|
+
t === i && /* @__PURE__ */ (0, Y.jsx)(fi, { className: "h-4 w-4" })
|
|
26834
26834
|
]
|
|
26835
26835
|
}, t);
|
|
26836
26836
|
}), t[8] = a, t[9] = i, t[10] = y) : y = t[10];
|
|
26837
26837
|
let b;
|
|
26838
|
-
t[11] === y ? b = t[12] : (b = /* @__PURE__ */ (0, Y.jsx)(
|
|
26838
|
+
t[11] === y ? b = t[12] : (b = /* @__PURE__ */ (0, Y.jsx)(ea, {
|
|
26839
26839
|
side: "bottom",
|
|
26840
26840
|
children: y
|
|
26841
26841
|
}), t[11] = y, t[12] = b);
|
|
26842
26842
|
let x;
|
|
26843
|
-
t[13] !== g || t[14] !== _ || t[15] !== v || t[16] !== b ? (x = /* @__PURE__ */ (0, Y.jsxs)(
|
|
26843
|
+
t[13] !== g || t[14] !== _ || t[15] !== v || t[16] !== b ? (x = /* @__PURE__ */ (0, Y.jsxs)(oa, {
|
|
26844
26844
|
open: g,
|
|
26845
26845
|
onOpenChange: _,
|
|
26846
26846
|
children: [v, b]
|
|
@@ -26848,7 +26848,7 @@ var lP = (e) => {
|
|
|
26848
26848
|
let S = c === "scroll", C;
|
|
26849
26849
|
t[18] === u ? C = t[19] : (C = (e) => u(e ? "scroll" : void 0), t[18] = u, t[19] = C);
|
|
26850
26850
|
let w;
|
|
26851
|
-
t[20] === Symbol.for("react.memo_cache_sentinel") ? (w = /* @__PURE__ */ (0, Y.jsx)(
|
|
26851
|
+
t[20] === Symbol.for("react.memo_cache_sentinel") ? (w = /* @__PURE__ */ (0, Y.jsx)(qi, {
|
|
26852
26852
|
asChild: !0,
|
|
26853
26853
|
children: /* @__PURE__ */ (0, Y.jsx)(Qu, { className: "h-4 w-4 opacity-60 hover:opacity-100" })
|
|
26854
26854
|
}), t[20] = w) : w = t[20];
|
|
@@ -26860,30 +26860,30 @@ var lP = (e) => {
|
|
|
26860
26860
|
children: "Scrollable"
|
|
26861
26861
|
}), t[24] = E) : E = t[24];
|
|
26862
26862
|
let D;
|
|
26863
|
-
t[25] !== o || t[26] !== s ? (D = /* @__PURE__ */ (0, Y.jsx)(
|
|
26863
|
+
t[25] !== o || t[26] !== s ? (D = /* @__PURE__ */ (0, Y.jsx)(lr, {
|
|
26864
26864
|
"data-testid": "grid-scrollable-switch",
|
|
26865
26865
|
checked: o,
|
|
26866
26866
|
size: "sm",
|
|
26867
26867
|
onCheckedChange: s
|
|
26868
26868
|
}), t[25] = o, t[26] = s, t[27] = D) : D = t[27];
|
|
26869
26869
|
let O;
|
|
26870
|
-
t[28] !== T || t[29] !== D ? (O = /* @__PURE__ */ (0, Y.jsx)(
|
|
26870
|
+
t[28] !== T || t[29] !== D ? (O = /* @__PURE__ */ (0, Y.jsx)(ea, {
|
|
26871
26871
|
side: "bottom",
|
|
26872
|
-
children: /* @__PURE__ */ (0, Y.jsxs)(
|
|
26872
|
+
children: /* @__PURE__ */ (0, Y.jsxs)(Zi, {
|
|
26873
26873
|
onSelect: T,
|
|
26874
26874
|
children: [E, D]
|
|
26875
26875
|
})
|
|
26876
26876
|
}), t[28] = T, t[29] = D, t[30] = O) : O = t[30];
|
|
26877
26877
|
let k;
|
|
26878
|
-
t[31] !== S || t[32] !== C || t[33] !== O ? (k = /* @__PURE__ */ (0, Y.jsxs)(
|
|
26878
|
+
t[31] !== S || t[32] !== C || t[33] !== O ? (k = /* @__PURE__ */ (0, Y.jsxs)(oa, {
|
|
26879
26879
|
open: S,
|
|
26880
26880
|
onOpenChange: C,
|
|
26881
26881
|
children: [w, O]
|
|
26882
26882
|
}), t[31] = S, t[32] = C, t[33] = O, t[34] = k) : k = t[34];
|
|
26883
26883
|
let A;
|
|
26884
|
-
t[35] === Symbol.for("react.memo_cache_sentinel") ? (A = /* @__PURE__ */ (0, Y.jsx)(
|
|
26884
|
+
t[35] === Symbol.for("react.memo_cache_sentinel") ? (A = /* @__PURE__ */ (0, Y.jsx)(Hr, { className: l(iP, "cursor-move", "h-4 w-4 opacity-60 hover:opacity-100") }), t[35] = A) : A = t[35];
|
|
26885
26885
|
let j;
|
|
26886
|
-
t[36] === r ? j = t[37] : (j = /* @__PURE__ */ (0, Y.jsx)(
|
|
26886
|
+
t[36] === r ? j = t[37] : (j = /* @__PURE__ */ (0, Y.jsx)(pi, {
|
|
26887
26887
|
className: "h-4 w-4 opacity-60 hover:opacity-100",
|
|
26888
26888
|
onClick: () => r()
|
|
26889
26889
|
}), t[36] = r, t[37] = j);
|
|
@@ -26975,7 +26975,7 @@ var gP = {
|
|
|
26975
26975
|
};
|
|
26976
26976
|
},
|
|
26977
26977
|
serializeLayout: (e, t) => {
|
|
26978
|
-
let n =
|
|
26978
|
+
let n = mn.keyBy(e.cells, (e) => e.i), r = t.map((t) => {
|
|
26979
26979
|
let r = n.get(t.id);
|
|
26980
26980
|
if (!r) return { position: null };
|
|
26981
26981
|
let i = { position: [
|
|
@@ -27054,10 +27054,10 @@ var yP = (e) => {
|
|
|
27054
27054
|
//#endregion
|
|
27055
27055
|
//#region src/components/editor/cell/useDeleteCell.tsx
|
|
27056
27056
|
function bP() {
|
|
27057
|
-
let e = (0, X.c)(4), { deleteCell: t, undoDeleteCell: n } =
|
|
27057
|
+
let e = (0, X.c)(4), { deleteCell: t, undoDeleteCell: n } = ot(), { sendDeleteCell: r } = kt(), i;
|
|
27058
27058
|
return e[0] !== t || e[1] !== r || e[2] !== n ? (i = (e) => {
|
|
27059
|
-
if (os.get(
|
|
27060
|
-
let { cellId: i } = e, a = (os.get(
|
|
27059
|
+
if (os.get(lt)) return;
|
|
27060
|
+
let { cellId: i } = e, a = (os.get(Ze).cellData[i]?.code ?? "").trim() === "";
|
|
27061
27061
|
if (t({ cellId: i }), r({ cellId: i }).catch(() => {
|
|
27062
27062
|
n();
|
|
27063
27063
|
}), !a) {
|
|
@@ -29530,7 +29530,7 @@ var ZL = (e) => {
|
|
|
29530
29530
|
//#region src/components/slides/minimap.tsx
|
|
29531
29531
|
function QL(e) {
|
|
29532
29532
|
if (!e || e === "slide") return null;
|
|
29533
|
-
let { label: t, description: n, Icon: r } =
|
|
29533
|
+
let { label: t, description: n, Icon: r } = or[e];
|
|
29534
29534
|
return {
|
|
29535
29535
|
label: t,
|
|
29536
29536
|
description: n,
|
|
@@ -29587,7 +29587,7 @@ function cR() {
|
|
|
29587
29587
|
return /* @__PURE__ */ new Set();
|
|
29588
29588
|
}
|
|
29589
29589
|
var lR = ({ cells: e, thumbnailWidth: t, canReorder: n, activeCellId: r, skippedIds: i, noOutputIds: a, slideTypes: o, onSlideClick: s }) => {
|
|
29590
|
-
let l =
|
|
29590
|
+
let l = it(), { moveCellToIndex: u, createNewCell: d } = ot(), f = bP(), p = (0, J.useRef)(null), m = sR(p), [h, g] = (0, J.useState)(null), [_, v] = (0, J.useState)(null), y = nR(t), b = (e, t) => {
|
|
29591
29591
|
d({
|
|
29592
29592
|
cellId: e,
|
|
29593
29593
|
before: t,
|
|
@@ -29671,7 +29671,7 @@ var lR = ({ cells: e, thumbnailWidth: t, canReorder: n, activeCellId: r, skipped
|
|
|
29671
29671
|
ref: p,
|
|
29672
29672
|
children: [/* @__PURE__ */ (0, Y.jsxs)("div", {
|
|
29673
29673
|
className: "text-xs text-gray-500 flex items-center gap-0.5",
|
|
29674
|
-
children: [/* @__PURE__ */ (0, Y.jsx)(
|
|
29674
|
+
children: [/* @__PURE__ */ (0, Y.jsx)(Ct, { className: "h-3 w-3" }), "Reordering is not supported in multi-column mode"]
|
|
29675
29675
|
}), e.map((e, t) => /* @__PURE__ */ (0, Y.jsx)(fR, {
|
|
29676
29676
|
cell: e,
|
|
29677
29677
|
dimensions: y,
|
|
@@ -29771,31 +29771,31 @@ var lR = ({ cells: e, thumbnailWidth: t, canReorder: n, activeCellId: r, skipped
|
|
|
29771
29771
|
let j = A;
|
|
29772
29772
|
if (!f && !u) return j;
|
|
29773
29773
|
let M;
|
|
29774
|
-
t[46] === j ? M = t[47] : (M = /* @__PURE__ */ (0, Y.jsx)(
|
|
29774
|
+
t[46] === j ? M = t[47] : (M = /* @__PURE__ */ (0, Y.jsx)(Kn, {
|
|
29775
29775
|
asChild: !0,
|
|
29776
29776
|
children: j
|
|
29777
29777
|
}), t[46] = j, t[47] = M);
|
|
29778
29778
|
let N;
|
|
29779
|
-
t[48] === f ? N = t[49] : (N = f && /* @__PURE__ */ (0, Y.jsxs)(
|
|
29779
|
+
t[48] === f ? N = t[49] : (N = f && /* @__PURE__ */ (0, Y.jsxs)(ai, {
|
|
29780
29780
|
onSelect: f,
|
|
29781
29781
|
children: [/* @__PURE__ */ (0, Y.jsx)(Ha, { className: "mr-2 h-3.5 w-3.5" }), "Add cell"]
|
|
29782
29782
|
}), t[48] = f, t[49] = N);
|
|
29783
29783
|
let F;
|
|
29784
|
-
t[50] === Symbol.for("react.memo_cache_sentinel") ? (F = /* @__PURE__ */ (0, Y.jsx)(
|
|
29784
|
+
t[50] === Symbol.for("react.memo_cache_sentinel") ? (F = /* @__PURE__ */ (0, Y.jsx)(sn, {}), t[50] = F) : F = t[50];
|
|
29785
29785
|
let I;
|
|
29786
|
-
t[51] === u ? I = t[52] : (I = u && /* @__PURE__ */ (0, Y.jsxs)(
|
|
29786
|
+
t[51] === u ? I = t[52] : (I = u && /* @__PURE__ */ (0, Y.jsxs)(ai, {
|
|
29787
29787
|
variant: "danger",
|
|
29788
29788
|
onSelect: u,
|
|
29789
29789
|
children: [/* @__PURE__ */ (0, Y.jsx)(P, { className: "mr-2 h-3.5 w-3.5" }), "Delete cell"]
|
|
29790
29790
|
}), t[51] = u, t[52] = I);
|
|
29791
29791
|
let L;
|
|
29792
|
-
t[53] !== N || t[54] !== I ? (L = /* @__PURE__ */ (0, Y.jsxs)(
|
|
29792
|
+
t[53] !== N || t[54] !== I ? (L = /* @__PURE__ */ (0, Y.jsxs)(Rn, { children: [
|
|
29793
29793
|
N,
|
|
29794
29794
|
F,
|
|
29795
29795
|
I
|
|
29796
29796
|
] }), t[53] = N, t[54] = I, t[55] = L) : L = t[55];
|
|
29797
29797
|
let R;
|
|
29798
|
-
return t[56] !== M || t[57] !== L ? (R = /* @__PURE__ */ (0, Y.jsxs)(
|
|
29798
|
+
return t[56] !== M || t[57] !== L ? (R = /* @__PURE__ */ (0, Y.jsxs)(Dn, { children: [M, L] }), t[56] = M, t[57] = L, t[58] = R) : R = t[58], R;
|
|
29799
29799
|
}, pR = (e) => {
|
|
29800
29800
|
let t = (0, X.c)(10), { position: n, onInsert: r } = e, i = n === "below" ? "bottom-0 translate-y-1/2" : "top-0 -translate-y-1/2", a;
|
|
29801
29801
|
t[0] === i ? a = t[1] : (a = l("absolute left-0 right-0 z-30 flex h-3 items-center justify-center", "opacity-0 transition-opacity hover:opacity-80 focus-visible:opacity-100 focus:outline-hidden", i), t[0] = i, t[1] = a);
|
|
@@ -29855,11 +29855,11 @@ var lR = ({ cells: e, thumbnailWidth: t, canReorder: n, activeCellId: r, skipped
|
|
|
29855
29855
|
width: b / S,
|
|
29856
29856
|
height: x / S
|
|
29857
29857
|
},
|
|
29858
|
-
children: y ? /* @__PURE__ */ (0, Y.jsx)(hR, { code: n.code }) : /* @__PURE__ */ (0, Y.jsx)(
|
|
29858
|
+
children: y ? /* @__PURE__ */ (0, Y.jsx)(hR, { code: n.code }) : /* @__PURE__ */ (0, Y.jsx)(Yr, {
|
|
29859
29859
|
cellId: n.id,
|
|
29860
29860
|
status: n.status,
|
|
29861
29861
|
output: n.output,
|
|
29862
|
-
stale:
|
|
29862
|
+
stale: Ot(n, !1)
|
|
29863
29863
|
})
|
|
29864
29864
|
}), t[30] = n, t[31] = x, t[32] = y, t[33] = S, t[34] = k, t[35] = b, t[36] = P) : P = t[36];
|
|
29865
29865
|
let F;
|
|
@@ -29932,12 +29932,12 @@ function bR(e) {
|
|
|
29932
29932
|
}
|
|
29933
29933
|
//#endregion
|
|
29934
29934
|
//#region src/components/editor/renderers/slides-layout/slides-layout.tsx
|
|
29935
|
-
var xR = J.lazy(() => import("./reveal-component-
|
|
29936
|
-
let t = (0, X.c)(33), { layout: n, setLayout: r, cells: i, mode: a } = e, o = rs(
|
|
29935
|
+
var xR = J.lazy(() => import("./reveal-component-BujcZI2B.js")), SR = (e) => {
|
|
29936
|
+
let t = (0, X.c)(33), { layout: n, setLayout: r, cells: i, mode: a } = e, o = rs(Ca), s = a === "read" || o, c = rs(_t) > 1, [l, u] = (0, J.useState)(null), d;
|
|
29937
29937
|
t[0] !== i || t[1] !== n ? (d = vP(i, n), t[0] = i, t[1] = n, t[2] = d) : d = t[2];
|
|
29938
29938
|
let { slideCells: f, skippedIds: p, noOutputIds: m, slideTypes: h, startCellIndex: g } = d, _;
|
|
29939
29939
|
t[3] !== l || t[4] !== f || t[5] !== g ? (_ = l ? f.findIndex((e) => e.id === l) : g, t[3] = l, t[4] = f, t[5] = g, t[6] = _) : _ = t[6];
|
|
29940
|
-
let v = _, y = v === -1 ? g : v, b =
|
|
29940
|
+
let v = _, y = v === -1 ? g : v, b = Vr(o, window.location.search), x = s && l == null && window.location.hash.startsWith("#/"), S = b || x ? void 0 : y, C;
|
|
29941
29941
|
t[7] === f ? C = t[8] : (C = (e) => {
|
|
29942
29942
|
let t = f[e];
|
|
29943
29943
|
t && u(t.id);
|
|
@@ -30139,7 +30139,7 @@ var jR = (e) => {
|
|
|
30139
30139
|
let m;
|
|
30140
30140
|
t[12] === n ? m = t[13] : (m = () => n("bt"), t[12] = n, t[13] = m);
|
|
30141
30141
|
let h;
|
|
30142
|
-
t[14] === Symbol.for("react.memo_cache_sentinel") ? (h = /* @__PURE__ */ (0, Y.jsx)(
|
|
30142
|
+
t[14] === Symbol.for("react.memo_cache_sentinel") ? (h = /* @__PURE__ */ (0, Y.jsx)(ht, {
|
|
30143
30143
|
fontSize: 36,
|
|
30144
30144
|
className: "w-5 h-5"
|
|
30145
30145
|
}), t[14] = h) : h = t[14];
|
|
@@ -30158,7 +30158,7 @@ var jR = (e) => {
|
|
|
30158
30158
|
let v;
|
|
30159
30159
|
t[17] === n ? v = t[18] : (v = () => n("help"), t[17] = n, t[18] = v);
|
|
30160
30160
|
let y;
|
|
30161
|
-
t[19] === Symbol.for("react.memo_cache_sentinel") ? (y = /* @__PURE__ */ (0, Y.jsx)(
|
|
30161
|
+
t[19] === Symbol.for("react.memo_cache_sentinel") ? (y = /* @__PURE__ */ (0, Y.jsx)(pa, {
|
|
30162
30162
|
fontSize: 36,
|
|
30163
30163
|
className: "w-5 h-5"
|
|
30164
30164
|
}), t[19] = y) : y = t[19];
|
|
@@ -30220,13 +30220,13 @@ function MR(e = !0) {
|
|
|
30220
30220
|
//#endregion
|
|
30221
30221
|
//#region src/components/editor/actions/name-cell-input.tsx
|
|
30222
30222
|
var NR = (e) => {
|
|
30223
|
-
let t = (0, X.c)(12), { value: n, cellId: r, className: i } = e, { updateCellName: a } =
|
|
30223
|
+
let t = (0, X.c)(12), { value: n, cellId: r, className: i } = e, { updateCellName: a } = ot(), o;
|
|
30224
30224
|
t[0] !== r || t[1] !== a ? (o = (e) => a({
|
|
30225
30225
|
cellId: r,
|
|
30226
30226
|
name: e
|
|
30227
30227
|
}), t[0] = r, t[1] = a, t[2] = o) : o = t[2];
|
|
30228
30228
|
let s = PR(n, o);
|
|
30229
|
-
if (
|
|
30229
|
+
if (we(n)) return null;
|
|
30230
30230
|
let c = s.focusing ? "" : "text-ellipsis", u;
|
|
30231
30231
|
t[3] !== i || t[4] !== c ? (u = l("outline-hidden border hover:border-cyan-500/40 focus:border-cyan-500/40", c, i), t[3] = i, t[4] = c, t[5] = u) : u = t[5];
|
|
30232
30232
|
let d;
|
|
@@ -30248,28 +30248,28 @@ function PR(e, t) {
|
|
|
30248
30248
|
let n = (0, X.c)(13), [r, i] = (0, J.useState)(e), [a, o] = (0, J.useState)(!1), s;
|
|
30249
30249
|
n[0] !== t || n[1] !== e ? (s = (n) => {
|
|
30250
30250
|
if (n !== e) {
|
|
30251
|
-
if (!n ||
|
|
30251
|
+
if (!n || we(n)) {
|
|
30252
30252
|
t(n);
|
|
30253
30253
|
return;
|
|
30254
30254
|
}
|
|
30255
|
-
t(
|
|
30255
|
+
t(Fe(n, mt()));
|
|
30256
30256
|
}
|
|
30257
30257
|
}, n[0] = t, n[1] = e, n[2] = s) : s = n[2];
|
|
30258
30258
|
let c = s, l;
|
|
30259
|
-
n[3] === r ? l = n[4] : (l =
|
|
30259
|
+
n[3] === r ? l = n[4] : (l = we(r) ? "" : r, n[3] = r, n[4] = l);
|
|
30260
30260
|
let u;
|
|
30261
30261
|
n[5] === Symbol.for("react.memo_cache_sentinel") ? (u = (e) => {
|
|
30262
|
-
let t = e.target.value, n =
|
|
30262
|
+
let t = e.target.value, n = Oe(t);
|
|
30263
30263
|
i(n);
|
|
30264
30264
|
}, n[5] = u) : u = n[5];
|
|
30265
30265
|
let d;
|
|
30266
30266
|
n[6] === c ? d = n[7] : (d = (e) => {
|
|
30267
30267
|
if (e.target instanceof HTMLInputElement) {
|
|
30268
30268
|
let t = e.target.value;
|
|
30269
|
-
c(
|
|
30269
|
+
c(Oe(t));
|
|
30270
30270
|
} else if (e.target instanceof HTMLSpanElement) {
|
|
30271
30271
|
let t = e.target.innerText.trim();
|
|
30272
|
-
c(
|
|
30272
|
+
c(Oe(t)), e.target.scrollLeft = 0, o(!1);
|
|
30273
30273
|
}
|
|
30274
30274
|
}, n[6] = c, n[7] = d);
|
|
30275
30275
|
let f;
|
|
@@ -30290,7 +30290,7 @@ function FR(e) {
|
|
|
30290
30290
|
}
|
|
30291
30291
|
//#endregion
|
|
30292
30292
|
//#region src/components/editor/output/useWrapText.ts
|
|
30293
|
-
var IR =
|
|
30293
|
+
var IR = ge("marimo:console:wrapText", !1, St);
|
|
30294
30294
|
function LR() {
|
|
30295
30295
|
let e = (0, X.c)(3), [t, n] = as(IR), r;
|
|
30296
30296
|
return e[0] !== n || e[1] !== t ? (r = {
|
|
@@ -30315,13 +30315,13 @@ var zR = (e) => {
|
|
|
30315
30315
|
value: s,
|
|
30316
30316
|
setValue: c
|
|
30317
30317
|
}, t[0] = s, t[1] = u);
|
|
30318
|
-
let d = kR(u), { consoleOutputs: f, stale: p, interrupted: m, cellName: h, cellId: g, onSubmitDebugger: v, onClear: y, onRefactorWithAI: b, className: x } = e, S = RR(f), C = S.length > 0, T = MR(C), E =
|
|
30318
|
+
let d = kR(u), { consoleOutputs: f, stale: p, interrupted: m, cellName: h, cellId: g, onSubmitDebugger: v, onClear: y, onRefactorWithAI: b, className: x } = e, S = RR(f), C = S.length > 0, T = MR(C), E = zn(n, C), D;
|
|
30319
30319
|
if (t[2] === Symbol.for("react.memo_cache_sentinel") ? (D = () => {
|
|
30320
30320
|
let e = n.current;
|
|
30321
30321
|
if (!e) return;
|
|
30322
30322
|
let t = e.scrollHeight - e.clientHeight;
|
|
30323
30323
|
t - e.scrollTop < 120 && (e.scrollTop = t);
|
|
30324
|
-
}, t[2] = D) : D = t[2], (0, J.useLayoutEffect)(D), !C &&
|
|
30324
|
+
}, t[2] = D) : D = t[2], (0, J.useLayoutEffect)(D), !C && we(h)) return null;
|
|
30325
30325
|
let O, k, A, j, M, N, P, F, I, L;
|
|
30326
30326
|
if (t[3] !== g || t[4] !== x || t[5] !== S || t[6] !== C || t[7] !== d || t[8] !== m || t[9] !== a || t[10] !== E || t[11] !== y || t[12] !== b || t[13] !== v || t[14] !== T || t[15] !== o || t[16] !== i || t[17] !== p || t[18] !== s || t[19] !== r) {
|
|
30327
30327
|
let e = S.toReversed(), u = e.some(WR), f = e.findIndex(GR), h;
|
|
@@ -30342,7 +30342,7 @@ var zR = (e) => {
|
|
|
30342
30342
|
className: "p-1 rounded bg-transparent text-muted-foreground data-hovered:text-foreground data-selected:text-foreground",
|
|
30343
30343
|
isSelected: r,
|
|
30344
30344
|
onChange: i,
|
|
30345
|
-
children: /* @__PURE__ */ (0, Y.jsx)(
|
|
30345
|
+
children: /* @__PURE__ */ (0, Y.jsx)(Nr, { className: "h-4 w-4" })
|
|
30346
30346
|
}) })
|
|
30347
30347
|
}),
|
|
30348
30348
|
(E || a) && /* @__PURE__ */ (0, Y.jsx)(_, {
|
|
@@ -30353,10 +30353,10 @@ var zR = (e) => {
|
|
|
30353
30353
|
variant: null,
|
|
30354
30354
|
children: a ? /* @__PURE__ */ (0, Y.jsx)(me, {
|
|
30355
30355
|
content: "Collapse output",
|
|
30356
|
-
children: /* @__PURE__ */ (0, Y.jsx)(
|
|
30356
|
+
children: /* @__PURE__ */ (0, Y.jsx)(Lr, { className: "h-4 w-4" })
|
|
30357
30357
|
}) : /* @__PURE__ */ (0, Y.jsx)(me, {
|
|
30358
30358
|
content: "Expand output",
|
|
30359
|
-
children: /* @__PURE__ */ (0, Y.jsx)(
|
|
30359
|
+
children: /* @__PURE__ */ (0, Y.jsx)(Xr, { className: "h-4 w-4 " })
|
|
30360
30360
|
})
|
|
30361
30361
|
})
|
|
30362
30362
|
]
|
|
@@ -30383,7 +30383,7 @@ var zR = (e) => {
|
|
|
30383
30383
|
interrupted: m
|
|
30384
30384
|
}, t);
|
|
30385
30385
|
}
|
|
30386
|
-
return /* @__PURE__ */ (0, Y.jsx)(J.Fragment, { children: /* @__PURE__ */ (0, Y.jsx)(
|
|
30386
|
+
return /* @__PURE__ */ (0, Y.jsx)(J.Fragment, { children: /* @__PURE__ */ (0, Y.jsx)(Ar, {
|
|
30387
30387
|
cellId: g,
|
|
30388
30388
|
onRefactorWithAI: b,
|
|
30389
30389
|
message: e,
|
|
@@ -30419,7 +30419,7 @@ var zR = (e) => {
|
|
|
30419
30419
|
let m = o ? "password" : "text", h;
|
|
30420
30420
|
t[2] === r ? h = t[3] : (h = (e) => r(e.target.value), t[2] = r, t[3] = h);
|
|
30421
30421
|
let g;
|
|
30422
|
-
t[4] === Symbol.for("react.memo_cache_sentinel") ? (g = /* @__PURE__ */ (0, Y.jsx)(
|
|
30422
|
+
t[4] === Symbol.for("react.memo_cache_sentinel") ? (g = /* @__PURE__ */ (0, Y.jsx)(na, { className: "w-5 h-5" }), t[4] = g) : g = t[4];
|
|
30423
30423
|
let _;
|
|
30424
30424
|
t[5] !== f || t[6] !== d || t[7] !== u || t[8] !== c || t[9] !== r || t[10] !== n ? (_ = (e) => {
|
|
30425
30425
|
if (e.key === "ArrowUp") {
|
|
@@ -30433,7 +30433,7 @@ var zR = (e) => {
|
|
|
30433
30433
|
e.key === "Enter" && !e.shiftKey && (n && f(n), c(n), r(""), e.preventDefault(), e.stopPropagation()), e.key === "Enter" && e.metaKey && (e.preventDefault(), e.stopPropagation());
|
|
30434
30434
|
}, t[5] = f, t[6] = d, t[7] = u, t[8] = c, t[9] = r, t[10] = n, t[11] = _) : _ = t[11];
|
|
30435
30435
|
let v;
|
|
30436
|
-
t[12] !== m || t[13] !== h || t[14] !== _ || t[15] !== n ? (v = /* @__PURE__ */ (0, Y.jsx)(
|
|
30436
|
+
t[12] !== m || t[13] !== h || t[14] !== _ || t[15] !== n ? (v = /* @__PURE__ */ (0, Y.jsx)(Xi, {
|
|
30437
30437
|
"data-testid": "console-input",
|
|
30438
30438
|
"data-stdin-blocking": !0,
|
|
30439
30439
|
type: m,
|
|
@@ -30467,7 +30467,7 @@ var zR = (e) => {
|
|
|
30467
30467
|
t[2] !== o || t[3] !== i || t[4] !== r || t[5] !== s ? (l = !i && !s && /* @__PURE__ */ (0, Y.jsxs)("span", {
|
|
30468
30468
|
className: "inline-flex items-center gap-1 text-(--sky-11)",
|
|
30469
30469
|
"aria-label": "stdin response",
|
|
30470
|
-
children: [/* @__PURE__ */ (0, Y.jsx)(
|
|
30470
|
+
children: [/* @__PURE__ */ (0, Y.jsx)(na, { className: "w-4 h-4 shrink-0 opacity-70" }), o ? r : /* @__PURE__ */ (0, Y.jsx)("span", {
|
|
30471
30471
|
className: "italic opacity-70",
|
|
30472
30472
|
children: "(empty)"
|
|
30473
30473
|
})]
|
|
@@ -30477,7 +30477,7 @@ var zR = (e) => {
|
|
|
30477
30477
|
className: "flex gap-2 items-center",
|
|
30478
30478
|
children: [c, l]
|
|
30479
30479
|
}), t[7] = c, t[8] = l, t[9] = u) : u = t[9], u;
|
|
30480
|
-
}, UR = (e) => e ? /* @__PURE__ */ (0, Y.jsx)(
|
|
30480
|
+
}, UR = (e) => e ? /* @__PURE__ */ (0, Y.jsx)(oi, { text: e }) : null;
|
|
30481
30481
|
function WR(e) {
|
|
30482
30482
|
return typeof e.data == "string" && e.data.includes("(Pdb)");
|
|
30483
30483
|
}
|
|
@@ -30492,7 +30492,7 @@ function qR(e) {
|
|
|
30492
30492
|
}
|
|
30493
30493
|
//#endregion
|
|
30494
30494
|
//#region src/core/cells/readonly-code-display.ts
|
|
30495
|
-
var JR = new
|
|
30495
|
+
var JR = new Xe(), YR = new wt();
|
|
30496
30496
|
function XR(e) {
|
|
30497
30497
|
let t = e.trim();
|
|
30498
30498
|
return t ? JR.isSupported(t) ? {
|
|
@@ -30512,7 +30512,7 @@ function XR(e) {
|
|
|
30512
30512
|
//#endregion
|
|
30513
30513
|
//#region src/core/export/layout.ts
|
|
30514
30514
|
async function ZR() {
|
|
30515
|
-
return await
|
|
30515
|
+
return await Be(), Dz();
|
|
30516
30516
|
}
|
|
30517
30517
|
//#endregion
|
|
30518
30518
|
//#region src/core/static/virtual-file-tracker.ts
|
|
@@ -30553,13 +30553,13 @@ function ez(e) {
|
|
|
30553
30553
|
//#endregion
|
|
30554
30554
|
//#region src/core/static/download-html.ts
|
|
30555
30555
|
async function tz(e) {
|
|
30556
|
-
let t =
|
|
30556
|
+
let t = Ve(), { includeCode: n } = e, r = await t.exportAsHTML({
|
|
30557
30557
|
download: !0,
|
|
30558
30558
|
includeCode: n,
|
|
30559
30559
|
files: $R.INSTANCE.filenames(),
|
|
30560
30560
|
layout: await ZR()
|
|
30561
30561
|
});
|
|
30562
|
-
|
|
30562
|
+
ar(r);
|
|
30563
30563
|
}
|
|
30564
30564
|
//#endregion
|
|
30565
30565
|
//#region src/components/editor/renderers/vertical-layout/useDelayVisibility.ts
|
|
@@ -30575,7 +30575,7 @@ function rz(e, t) {
|
|
|
30575
30575
|
i(!1);
|
|
30576
30576
|
}, n);
|
|
30577
30577
|
return () => clearTimeout(r);
|
|
30578
|
-
}, n[0] = t, n[1] = e, n[2] = a) : a = n[2],
|
|
30578
|
+
}, n[0] = t, n[1] = e, n[2] = a) : a = n[2], di(a);
|
|
30579
30579
|
let o;
|
|
30580
30580
|
return n[3] === r ? o = n[4] : (o = { invisible: r }, n[3] = r, n[4] = o), o;
|
|
30581
30581
|
}
|
|
@@ -30584,10 +30584,10 @@ function rz(e, t) {
|
|
|
30584
30584
|
function iz({ showCodeInRunModePreference: e, kioskMode: t }) {
|
|
30585
30585
|
if (!e) return !1;
|
|
30586
30586
|
let n = new URLSearchParams(window.location.search).get(ss.showCode);
|
|
30587
|
-
return n === null ?
|
|
30587
|
+
return n === null ? ga() || da() || t : n === "true";
|
|
30588
30588
|
}
|
|
30589
30589
|
function az(e) {
|
|
30590
|
-
|
|
30590
|
+
ga() && ba((t) => {
|
|
30591
30591
|
t.set(ss.showCode, String(e));
|
|
30592
30592
|
});
|
|
30593
30593
|
}
|
|
@@ -30599,7 +30599,7 @@ function oz(e) {
|
|
|
30599
30599
|
}), [...t.entries()].toSorted(([e], [t]) => e - t);
|
|
30600
30600
|
}
|
|
30601
30601
|
function sz(e, t) {
|
|
30602
|
-
let n = new
|
|
30602
|
+
let n = new Te().isSupported(e), r = t !== null && !L(t);
|
|
30603
30603
|
return n && r || e.trim() === "";
|
|
30604
30604
|
}
|
|
30605
30605
|
//#endregion
|
|
@@ -30620,7 +30620,7 @@ var cz = (e) => {
|
|
|
30620
30620
|
children: h
|
|
30621
30621
|
}), t[12] = s, t[13] = h, t[14] = g) : g = t[14], g;
|
|
30622
30622
|
}, lz = (e) => {
|
|
30623
|
-
let t = (0, X.c)(33), { cells: n, appConfig: r, mode: i } = e, { invisible: a } = rz(n.length, i), o = rs(
|
|
30623
|
+
let t = (0, X.c)(33), { cells: n, appConfig: r, mode: i } = e, { invisible: a } = rz(n.length, i), o = rs(Ca), s = rs(Gs), [c] = ps(), u = rs(Us), d;
|
|
30624
30624
|
t[0] !== o || t[1] !== u ? (d = () => iz({
|
|
30625
30625
|
showCodeInRunModePreference: u,
|
|
30626
30626
|
kioskMode: o
|
|
@@ -30703,13 +30703,13 @@ var cz = (e) => {
|
|
|
30703
30703
|
]
|
|
30704
30704
|
}), t[28] = r, t[29] = a, t[30] = w, t[31] = T, t[32] = D) : D = t[32], D;
|
|
30705
30705
|
}, uz = (e) => {
|
|
30706
|
-
let t = (0, X.c)(26), { canShowCode: n, showCode: r, onToggleShowCode: i } = e, { readCode: a } =
|
|
30706
|
+
let t = (0, X.c)(26), { canShowCode: n, showCode: r, onToggleShowCode: i } = e, { readCode: a } = kt(), o = mz, s = hz, c;
|
|
30707
30707
|
t[0] === a ? c = t[1] : (c = async () => {
|
|
30708
30708
|
let e = await a();
|
|
30709
|
-
|
|
30709
|
+
Qr(new Blob([e.contents], { type: "text/plain" }), ln.toPY(document.title));
|
|
30710
30710
|
}, t[0] = a, t[1] = c);
|
|
30711
30711
|
let u = c, d;
|
|
30712
|
-
t[2] === Symbol.for("react.memo_cache_sentinel") ? (d =
|
|
30712
|
+
t[2] === Symbol.for("react.memo_cache_sentinel") ? (d = ga(), t[2] = d) : d = t[2];
|
|
30713
30713
|
let f = d, p;
|
|
30714
30714
|
if (t[3] !== n || t[4] !== u || t[5] !== i || t[6] !== r) {
|
|
30715
30715
|
if (p = [], n) {
|
|
@@ -30723,9 +30723,9 @@ var cz = (e) => {
|
|
|
30723
30723
|
children: "Show code"
|
|
30724
30724
|
}), t[8] = e, t[9] = n) : (e = t[8], n = t[9]);
|
|
30725
30725
|
let a;
|
|
30726
|
-
t[10] === r ? a = t[11] : (a = r && /* @__PURE__ */ (0, Y.jsx)(
|
|
30726
|
+
t[10] === r ? a = t[11] : (a = r && /* @__PURE__ */ (0, Y.jsx)(fi, { className: "h-4 w-4" }), t[10] = r, t[11] = a);
|
|
30727
30727
|
let o;
|
|
30728
|
-
t[12] !== i || t[13] !== a ? (o = /* @__PURE__ */ (0, Y.jsxs)(
|
|
30728
|
+
t[12] !== i || t[13] !== a ? (o = /* @__PURE__ */ (0, Y.jsxs)(Zi, {
|
|
30729
30729
|
onSelect: i,
|
|
30730
30730
|
"data-testid": "notebook-action-show-code",
|
|
30731
30731
|
children: [
|
|
@@ -30735,11 +30735,11 @@ var cz = (e) => {
|
|
|
30735
30735
|
]
|
|
30736
30736
|
}, "show-code"), t[12] = i, t[13] = a, t[14] = o) : o = t[14];
|
|
30737
30737
|
let s;
|
|
30738
|
-
t[15] === Symbol.for("react.memo_cache_sentinel") ? (s = /* @__PURE__ */ (0, Y.jsx)(
|
|
30738
|
+
t[15] === Symbol.for("react.memo_cache_sentinel") ? (s = /* @__PURE__ */ (0, Y.jsx)(aa, {}, "show-code-separator"), t[15] = s) : s = t[15], p.push(o, s);
|
|
30739
30739
|
}
|
|
30740
30740
|
if (!f) {
|
|
30741
30741
|
let e;
|
|
30742
|
-
if (t[16] === Symbol.for("react.memo_cache_sentinel") ? (e = /* @__PURE__ */ (0, Y.jsxs)(
|
|
30742
|
+
if (t[16] === Symbol.for("react.memo_cache_sentinel") ? (e = /* @__PURE__ */ (0, Y.jsxs)(Zi, {
|
|
30743
30743
|
onSelect: s,
|
|
30744
30744
|
"data-testid": "notebook-action-download-html",
|
|
30745
30745
|
children: [/* @__PURE__ */ (0, Y.jsx)(Uu, {
|
|
@@ -30749,22 +30749,22 @@ var cz = (e) => {
|
|
|
30749
30749
|
}), "Download as HTML"]
|
|
30750
30750
|
}, "download-html"), t[16] = e) : e = t[16], p.push(e), n) {
|
|
30751
30751
|
let e;
|
|
30752
|
-
t[17] === Symbol.for("react.memo_cache_sentinel") ? (e = /* @__PURE__ */ (0, Y.jsx)(
|
|
30752
|
+
t[17] === Symbol.for("react.memo_cache_sentinel") ? (e = /* @__PURE__ */ (0, Y.jsx)(Or, {
|
|
30753
30753
|
className: "mr-2",
|
|
30754
30754
|
size: 14,
|
|
30755
30755
|
strokeWidth: 1.5
|
|
30756
30756
|
}), t[17] = e) : e = t[17];
|
|
30757
30757
|
let n;
|
|
30758
|
-
t[18] === u ? n = t[19] : (n = /* @__PURE__ */ (0, Y.jsxs)(
|
|
30758
|
+
t[18] === u ? n = t[19] : (n = /* @__PURE__ */ (0, Y.jsxs)(Zi, {
|
|
30759
30759
|
onSelect: u,
|
|
30760
30760
|
"data-testid": "notebook-action-download-python",
|
|
30761
30761
|
children: [e, "Download notebook source"]
|
|
30762
30762
|
}, "download-python"), t[18] = u, t[19] = n), p.push(n);
|
|
30763
30763
|
}
|
|
30764
30764
|
let r;
|
|
30765
|
-
t[20] === Symbol.for("react.memo_cache_sentinel") ? (r = /* @__PURE__ */ (0, Y.jsx)(
|
|
30765
|
+
t[20] === Symbol.for("react.memo_cache_sentinel") ? (r = /* @__PURE__ */ (0, Y.jsx)(aa, {}, "download-separator"), t[20] = r) : r = t[20];
|
|
30766
30766
|
let i;
|
|
30767
|
-
t[21] === Symbol.for("react.memo_cache_sentinel") ? (i = /* @__PURE__ */ (0, Y.jsxs)(
|
|
30767
|
+
t[21] === Symbol.for("react.memo_cache_sentinel") ? (i = /* @__PURE__ */ (0, Y.jsxs)(Zi, {
|
|
30768
30768
|
onSelect: o,
|
|
30769
30769
|
"data-testid": "notebook-action-download-png",
|
|
30770
30770
|
children: [/* @__PURE__ */ (0, Y.jsx)(qu, {
|
|
@@ -30778,23 +30778,23 @@ var cz = (e) => {
|
|
|
30778
30778
|
} else p = t[7];
|
|
30779
30779
|
if (p.length === 0) return null;
|
|
30780
30780
|
let m;
|
|
30781
|
-
t[22] === Symbol.for("react.memo_cache_sentinel") ? (m = l("right-0 top-0 z-50 m-4 print:hidden flex gap-2",
|
|
30781
|
+
t[22] === Symbol.for("react.memo_cache_sentinel") ? (m = l("right-0 top-0 z-50 m-4 print:hidden flex gap-2", ga() ? "absolute" : "fixed"), t[22] = m) : m = t[22];
|
|
30782
30782
|
let h;
|
|
30783
|
-
t[23] === Symbol.for("react.memo_cache_sentinel") ? (h = /* @__PURE__ */ (0, Y.jsx)(
|
|
30783
|
+
t[23] === Symbol.for("react.memo_cache_sentinel") ? (h = /* @__PURE__ */ (0, Y.jsx)(qi, {
|
|
30784
30784
|
asChild: !0,
|
|
30785
30785
|
children: /* @__PURE__ */ (0, Y.jsx)(_, {
|
|
30786
30786
|
variant: "secondary",
|
|
30787
30787
|
size: "xs",
|
|
30788
|
-
children: /* @__PURE__ */ (0, Y.jsx)(
|
|
30788
|
+
children: /* @__PURE__ */ (0, Y.jsx)(Wr, { className: "w-4 h-4" })
|
|
30789
30789
|
})
|
|
30790
30790
|
}), t[23] = h) : h = t[23];
|
|
30791
30791
|
let g;
|
|
30792
30792
|
return t[24] === p ? g = t[25] : (g = /* @__PURE__ */ (0, Y.jsx)("div", {
|
|
30793
30793
|
"data-testid": "notebook-actions-dropdown",
|
|
30794
30794
|
className: m,
|
|
30795
|
-
children: /* @__PURE__ */ (0, Y.jsxs)(
|
|
30795
|
+
children: /* @__PURE__ */ (0, Y.jsxs)(oa, {
|
|
30796
30796
|
modal: !1,
|
|
30797
|
-
children: [h, /* @__PURE__ */ (0, Y.jsx)(
|
|
30797
|
+
children: [h, /* @__PURE__ */ (0, Y.jsx)(ea, {
|
|
30798
30798
|
align: "end",
|
|
30799
30799
|
className: "print:hidden w-[220px]",
|
|
30800
30800
|
children: p
|
|
@@ -30803,7 +30803,7 @@ var cz = (e) => {
|
|
|
30803
30803
|
}), t[24] = p, t[25] = g), g;
|
|
30804
30804
|
}, dz = (0, J.memo)((e) => {
|
|
30805
30805
|
let t = (0, X.c)(57), { output: n, consoleOutputs: r, cellOutputArea: i, cellId: a, status: o, stopped: s, errored: c, config: u, interrupted: d, staleInputs: f, runStartTimestamp: p, code: m, showCode: h, mode: g, name: _, kiosk: v, showErrorTracebacks: y } = e, b = (0, J.useRef)(null), x;
|
|
30806
|
-
t[0] !== d || t[1] !== n || t[2] !== p || t[3] !== f || t[4] !== o ? (x =
|
|
30806
|
+
t[0] !== d || t[1] !== n || t[2] !== p || t[3] !== f || t[4] !== o ? (x = Ot({
|
|
30807
30807
|
status: o,
|
|
30808
30808
|
output: n,
|
|
30809
30809
|
interrupted: d,
|
|
@@ -30814,8 +30814,8 @@ var cz = (e) => {
|
|
|
30814
30814
|
t[6] === o ? C = t[7] : (C = ye(o), t[6] = o, t[7] = C);
|
|
30815
30815
|
let w = C, T = v && g !== "present", E;
|
|
30816
30816
|
if (t[8] !== m || t[9] !== c || t[10] !== T || t[11] !== h || t[12] !== s) {
|
|
30817
|
-
let e = new
|
|
30818
|
-
E = l("marimo-cell", "hover-actions-parent empty:invisible", !h && !T ?
|
|
30817
|
+
let e = new Te().isSupported(m);
|
|
30818
|
+
E = l("marimo-cell", "hover-actions-parent empty:invisible", !h && !T ? Se({
|
|
30819
30819
|
errored: c,
|
|
30820
30820
|
stopped: s
|
|
30821
30821
|
}) : {
|
|
@@ -30827,7 +30827,7 @@ var cz = (e) => {
|
|
|
30827
30827
|
let D = E;
|
|
30828
30828
|
if (g === "read" && h || T) {
|
|
30829
30829
|
let e;
|
|
30830
|
-
t[14] !== a || t[15] !== w || t[16] !== n || t[17] !== S ? (e = /* @__PURE__ */ (0, Y.jsx)(
|
|
30830
|
+
t[14] !== a || t[15] !== w || t[16] !== n || t[17] !== S ? (e = /* @__PURE__ */ (0, Y.jsx)(Ir, {
|
|
30831
30831
|
allowExpand: !0,
|
|
30832
30832
|
output: n,
|
|
30833
30833
|
className: ms.outputArea,
|
|
@@ -30840,7 +30840,7 @@ var cz = (e) => {
|
|
|
30840
30840
|
let c = s, l;
|
|
30841
30841
|
t[22] !== m || t[23] !== c ? (l = c ? null : XR(m), t[22] = m, t[23] = c, t[24] = l) : l = t[24];
|
|
30842
30842
|
let f = l, p;
|
|
30843
|
-
t[25] !== a || t[26] !== _ ? (p =
|
|
30843
|
+
t[25] !== a || t[26] !== _ ? (p = Kr(a, _), t[25] = a, t[26] = _, t[27] = p) : p = t[27];
|
|
30844
30844
|
let h = i === "above" && o, g;
|
|
30845
30845
|
t[28] !== u || t[29] !== f ? (g = f && /* @__PURE__ */ (0, Y.jsx)("div", {
|
|
30846
30846
|
className: "tray",
|
|
@@ -30874,7 +30874,7 @@ var cz = (e) => {
|
|
|
30874
30874
|
]
|
|
30875
30875
|
}), t[37] = D, t[38] = v, t[39] = y, t[40] = p, t[41] = h, t[42] = g, t[43] = x) : x = t[43], x;
|
|
30876
30876
|
}
|
|
30877
|
-
if (
|
|
30877
|
+
if (Pe({
|
|
30878
30878
|
errored: c,
|
|
30879
30879
|
interrupted: d,
|
|
30880
30880
|
stopped: s,
|
|
@@ -30882,9 +30882,9 @@ var cz = (e) => {
|
|
|
30882
30882
|
showErrorTracebacks: y
|
|
30883
30883
|
})) return null;
|
|
30884
30884
|
let O;
|
|
30885
|
-
t[44] !== a || t[45] !== _ ? (O =
|
|
30885
|
+
t[44] !== a || t[45] !== _ ? (O = Kr(a, _), t[44] = a, t[45] = _, t[46] = O) : O = t[46];
|
|
30886
30886
|
let k = g === "edit", A;
|
|
30887
|
-
t[47] !== a || t[48] !== w || t[49] !== n || t[50] !== S || t[51] !== k ? (A = /* @__PURE__ */ (0, Y.jsx)(
|
|
30887
|
+
t[47] !== a || t[48] !== w || t[49] !== n || t[50] !== S || t[51] !== k ? (A = /* @__PURE__ */ (0, Y.jsx)(Ir, {
|
|
30888
30888
|
allowExpand: k,
|
|
30889
30889
|
output: n,
|
|
30890
30890
|
className: ms.outputArea,
|
|
@@ -30917,10 +30917,10 @@ function pz(e) {
|
|
|
30917
30917
|
}
|
|
30918
30918
|
async function mz() {
|
|
30919
30919
|
let e = document.getElementById("App");
|
|
30920
|
-
e && await
|
|
30920
|
+
e && await ni({
|
|
30921
30921
|
element: e,
|
|
30922
30922
|
filename: document.title,
|
|
30923
|
-
prepare:
|
|
30923
|
+
prepare: tr
|
|
30924
30924
|
});
|
|
30925
30925
|
}
|
|
30926
30926
|
async function hz() {
|
|
@@ -30972,7 +30972,7 @@ function Sz(e, t) {
|
|
|
30972
30972
|
selectedLayout: t
|
|
30973
30973
|
};
|
|
30974
30974
|
}
|
|
30975
|
-
var { valueAtom: Cz, useActions: wz } =
|
|
30975
|
+
var { valueAtom: Cz, useActions: wz } = ci(xz, {
|
|
30976
30976
|
setLayoutView: Sz,
|
|
30977
30977
|
setLayoutData: ({ pendingLayout: e, ...t }, n) => ({
|
|
30978
30978
|
...t,
|
|
@@ -31012,11 +31012,11 @@ function Ez({ state: e, plugin: t, cells: n }) {
|
|
|
31012
31012
|
}) : t.getInitialLayout(n));
|
|
31013
31013
|
}
|
|
31014
31014
|
function Dz() {
|
|
31015
|
-
let e =
|
|
31015
|
+
let e = Je(), t = os.get(Cz), { selectedLayout: n } = t;
|
|
31016
31016
|
if (n === "vertical") return null;
|
|
31017
31017
|
let r = _z.find((e) => e.type === n);
|
|
31018
31018
|
if (r === void 0) return c.error(`Unknown layout type: ${n}`), null;
|
|
31019
|
-
let i =
|
|
31019
|
+
let i = Ce(e), a = Ez({
|
|
31020
31020
|
state: t,
|
|
31021
31021
|
plugin: r,
|
|
31022
31022
|
cells: i
|
|
@@ -31032,7 +31032,7 @@ function Oz(e) {
|
|
|
31032
31032
|
let { codes: t, names: n, configs: r, cell_ids: i, last_executed_code: a, last_execution_time: o } = e, s = a || {}, c = o || {};
|
|
31033
31033
|
return t.map((e, t) => {
|
|
31034
31034
|
let a = i[t], o = s[a];
|
|
31035
|
-
return
|
|
31035
|
+
return Dt({
|
|
31036
31036
|
id: a,
|
|
31037
31037
|
code: e,
|
|
31038
31038
|
edited: o ? o !== e : !1,
|
|
@@ -31072,7 +31072,7 @@ function jz(e, t) {
|
|
|
31072
31072
|
return;
|
|
31073
31073
|
}
|
|
31074
31074
|
let { objectIds: y, values: b } = Az(), x = g ? Object.fromEntries(n.map((e) => [e.id, e.code])) : void 0;
|
|
31075
|
-
|
|
31075
|
+
Ve().sendInstantiate({
|
|
31076
31076
|
objectIds: y,
|
|
31077
31077
|
values: b,
|
|
31078
31078
|
autoRun: r,
|
|
@@ -31323,10 +31323,10 @@ function Qz(e) {
|
|
|
31323
31323
|
return null;
|
|
31324
31324
|
}
|
|
31325
31325
|
function $z(e) {
|
|
31326
|
-
return
|
|
31326
|
+
return Ge(e) ? e.schemaVersion === 1 && typeof e.appId == "string" && (e.dependencies === void 0 || Array.isArray(e.dependencies) && e.dependencies.every((e) => typeof e == "string")) && Array.isArray(e.cells) && e.cells.every(eB) : !1;
|
|
31327
31327
|
}
|
|
31328
31328
|
function eB(e) {
|
|
31329
|
-
return
|
|
31329
|
+
return Ge(e) ? typeof e.cellId == "string" && typeof e.code == "string" && typeof e.outputHtml == "string" && typeof e.outputMimetype == "string" && typeof e.reactive == "boolean" && typeof e.displayCode == "boolean" && typeof e.displayOutput == "boolean" : !1;
|
|
31330
31330
|
}
|
|
31331
31331
|
//#endregion
|
|
31332
31332
|
//#region src/core/islands/components/IslandControls.tsx
|
|
@@ -31346,7 +31346,7 @@ var tB = (e) => {
|
|
|
31346
31346
|
children: a
|
|
31347
31347
|
}), t[3] = a, t[4] = n, t[5] = o) : o = t[5], o;
|
|
31348
31348
|
}, nB = (e) => {
|
|
31349
|
-
let t = (0, X.c)(18), { cellId: n, codeCallback: r, visible: i } = e, { sendRun: a } =
|
|
31349
|
+
let t = (0, X.c)(18), { cellId: n, codeCallback: r, visible: i } = e, { sendRun: a } = kt(), o;
|
|
31350
31350
|
t[0] === r ? o = t[1] : (o = () => {
|
|
31351
31351
|
S(r());
|
|
31352
31352
|
}, t[0] = r, t[1] = o);
|
|
@@ -31420,7 +31420,7 @@ var aB = (e) => {
|
|
|
31420
31420
|
let t = (0, X.c)(19), { cellId: n, codeCallback: r, alwaysShowRun: i, children: a } = e, o = rB(i), s = (0, J.useRef)(null), c;
|
|
31421
31421
|
t[0] === n ? c = t[1] : (c = (e) => e.cellRuntime[n], t[0] = n, t[1] = c);
|
|
31422
31422
|
let l = c, u;
|
|
31423
|
-
t[2] === l ? u = t[3] : (u =
|
|
31423
|
+
t[2] === l ? u = t[3] : (u = et(Ze, l), t[2] = l, t[3] = u);
|
|
31424
31424
|
let d = rs(u), f = rs(Ks);
|
|
31425
31425
|
if (oB(s, d?.status ?? "idle"), !f || !d?.output) {
|
|
31426
31426
|
let e;
|
|
@@ -31435,7 +31435,7 @@ var aB = (e) => {
|
|
|
31435
31435
|
return t[6] === Symbol.for("react.memo_cache_sentinel") ? (e = /* @__PURE__ */ (0, Y.jsx)("div", { ref: s }), t[6] = e) : e = t[6], e;
|
|
31436
31436
|
}
|
|
31437
31437
|
let p;
|
|
31438
|
-
t[7] === d.output ? p = t[8] : (p = /* @__PURE__ */ (0, Y.jsx)(
|
|
31438
|
+
t[7] === d.output ? p = t[8] : (p = /* @__PURE__ */ (0, Y.jsx)(Ar, { message: d.output }), t[7] = d.output, t[8] = p);
|
|
31439
31439
|
let m;
|
|
31440
31440
|
t[9] === d ? m = t[10] : (m = /* @__PURE__ */ (0, Y.jsx)(sB, { state: d }), t[9] = d, t[10] = m);
|
|
31441
31441
|
let h;
|
|
@@ -31510,7 +31510,7 @@ var sB = (e) => {
|
|
|
31510
31510
|
return Yz(this);
|
|
31511
31511
|
}
|
|
31512
31512
|
getCellIdFromIndex(e) {
|
|
31513
|
-
let { cellIds: t } = os.get(
|
|
31513
|
+
let { cellIds: t } = os.get(Ze);
|
|
31514
31514
|
return t.inOrderIds.at(e);
|
|
31515
31515
|
}
|
|
31516
31516
|
connectedCallback() {
|
|
@@ -31524,7 +31524,7 @@ var sB = (e) => {
|
|
|
31524
31524
|
};
|
|
31525
31525
|
syncCellIdsSubscription() {
|
|
31526
31526
|
if (this.isReactive) {
|
|
31527
|
-
this.unsubscribeCellIds ??= os.sub(
|
|
31527
|
+
this.unsubscribeCellIds ??= os.sub(pt, () => {
|
|
31528
31528
|
this.runtimeCellId = this.cellId, this.renderIsland();
|
|
31529
31529
|
});
|
|
31530
31530
|
return;
|
|
@@ -31537,7 +31537,7 @@ var sB = (e) => {
|
|
|
31537
31537
|
code: r,
|
|
31538
31538
|
output: t
|
|
31539
31539
|
});
|
|
31540
|
-
let i = (this.querySelector(e.editorTagName)?.parentElement)?.getAttribute(
|
|
31540
|
+
let i = (this.querySelector(e.editorTagName)?.parentElement)?.getAttribute(je);
|
|
31541
31541
|
return {
|
|
31542
31542
|
html: t,
|
|
31543
31543
|
codeCallback: n && i ? () => {
|
|
@@ -31596,7 +31596,7 @@ function pB() {
|
|
|
31596
31596
|
//#region src/core/islands/bootstrap.ts
|
|
31597
31597
|
async function mB(e) {
|
|
31598
31598
|
let t = e.store || os, n = e.root || document, r = e.bridge;
|
|
31599
|
-
t.set(
|
|
31599
|
+
t.set(be, r), t.set(ma, "read"), t.set(Ws, null), e.autoInitializePlugins !== !1 && YM();
|
|
31600
31600
|
let i = Array.from(n.querySelectorAll(yu.ISLAND));
|
|
31601
31601
|
if (i.length === 0) {
|
|
31602
31602
|
c.log("No islands found, skipping initialization");
|
|
@@ -31604,8 +31604,8 @@ async function mB(e) {
|
|
|
31604
31604
|
}
|
|
31605
31605
|
c.log(`Initializing ${i.length} island(s)`);
|
|
31606
31606
|
for (let e of i) e.classList.add(Cu.NAMESPACE);
|
|
31607
|
-
let a =
|
|
31608
|
-
t.set(
|
|
31607
|
+
let a = bt((e) => {
|
|
31608
|
+
t.set(Ze, (t) => dt(t, e));
|
|
31609
31609
|
});
|
|
31610
31610
|
t.sub(Js, () => {
|
|
31611
31611
|
let e = t.get(Js), r = n.querySelectorAll(yu.ISLAND);
|
|
@@ -31624,7 +31624,7 @@ async function mB(e) {
|
|
|
31624
31624
|
}
|
|
31625
31625
|
function hB(e, t, n, r) {
|
|
31626
31626
|
try {
|
|
31627
|
-
let i =
|
|
31627
|
+
let i = Ae(e);
|
|
31628
31628
|
switch (c.debug("Islands received message:", i.op), i.op) {
|
|
31629
31629
|
case "banner":
|
|
31630
31630
|
case "missing-package-alert":
|
|
@@ -31710,7 +31710,7 @@ function hB(e, t, n, r) {
|
|
|
31710
31710
|
return;
|
|
31711
31711
|
case "consumer-capabilities": return;
|
|
31712
31712
|
default:
|
|
31713
|
-
|
|
31713
|
+
mi(i);
|
|
31714
31714
|
return;
|
|
31715
31715
|
}
|
|
31716
31716
|
} catch (e) {
|
|
@@ -31969,12 +31969,12 @@ var MB = class {
|
|
|
31969
31969
|
store;
|
|
31970
31970
|
root;
|
|
31971
31971
|
session;
|
|
31972
|
-
sessionReady = new
|
|
31972
|
+
sessionReady = new fa();
|
|
31973
31973
|
nextSessionGeneration = 0;
|
|
31974
31974
|
activeSessionGenerations = /* @__PURE__ */ new Set();
|
|
31975
31975
|
appTransition = Promise.resolve();
|
|
31976
|
-
workerReady = new
|
|
31977
|
-
initialized = new
|
|
31976
|
+
workerReady = new fa();
|
|
31977
|
+
initialized = new fa();
|
|
31978
31978
|
constructor(e = {}) {
|
|
31979
31979
|
this.store = e.store || os, this.root = e.root || document;
|
|
31980
31980
|
try {
|
|
@@ -32017,7 +32017,7 @@ var MB = class {
|
|
|
32017
32017
|
appId: n.id,
|
|
32018
32018
|
sessionGeneration: ++this.nextSessionGeneration
|
|
32019
32019
|
}, a = this.session, o = t && a !== void 0;
|
|
32020
|
-
this.activeSessionGenerations.add(r.sessionGeneration), o && this.store.set(
|
|
32020
|
+
this.activeSessionGenerations.add(r.sessionGeneration), o && this.store.set(Ze, Et()), (t || !a) && (t && this.sessionReady.status !== "pending" && (this.sessionReady = new fa()), this.session = {
|
|
32021
32021
|
...r,
|
|
32022
32022
|
code: t ? e : void 0
|
|
32023
32023
|
});
|
|
@@ -32035,7 +32035,7 @@ var MB = class {
|
|
|
32035
32035
|
t?.code === void 0 || e && t.appId !== e || (this.activeSessionGenerations.delete(t.sessionGeneration), await this.rpc.proxy.request.stopSession({
|
|
32036
32036
|
appId: t.appId,
|
|
32037
32037
|
sessionGeneration: t.sessionGeneration
|
|
32038
|
-
}), this.store.set(Ws, null), this.session = void 0, this.sessionReady = new
|
|
32038
|
+
}), this.store.set(Ws, null), this.session = void 0, this.sessionReady = new fa(), this.store.set(Ze, Et()));
|
|
32039
32039
|
});
|
|
32040
32040
|
}
|
|
32041
32041
|
enqueueAppTransition(e) {
|
|
@@ -32051,7 +32051,7 @@ var MB = class {
|
|
|
32051
32051
|
sendComponentValues = async (e) => (await this.putControlRequest({
|
|
32052
32052
|
type: "update-ui-element",
|
|
32053
32053
|
...e,
|
|
32054
|
-
token:
|
|
32054
|
+
token: he()
|
|
32055
32055
|
}), null);
|
|
32056
32056
|
sendInstantiate = async () => null;
|
|
32057
32057
|
sendFunctionRequest = async (e) => (await this.putControlRequest({
|