@llmnative/react 1.7.1 → 1.8.0
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/index.js +13 -13
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +794 -581
- package/dist/index.mjs.map +1 -1
- package/dist/types/src/I18n.d.ts +9 -0
- package/dist/types/src/components/widgets/grid-core/types.d.ts +60 -10
- package/dist/types/src/index.d.ts +1 -1
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -13,12 +13,12 @@ import { addDoc as ie, collection as ae, deleteDoc as oe, doc as se, getCountFro
|
|
|
13
13
|
import { createClient as ye } from "@supabase/supabase-js";
|
|
14
14
|
import { deleteObject as be, getDownloadURL as xe, getMetadata as Se, getStorage as Ce, listAll as we, ref as Te, uploadBytesResumable as Ee, uploadString as De } from "firebase/storage";
|
|
15
15
|
import Oe from "papaparse";
|
|
16
|
-
import
|
|
17
|
-
import
|
|
18
|
-
import
|
|
19
|
-
import
|
|
20
|
-
import
|
|
21
|
-
import { endAt as
|
|
16
|
+
import ke from "react-markdown";
|
|
17
|
+
import Ae from "remark-gfm";
|
|
18
|
+
import je from "rehype-slug";
|
|
19
|
+
import Me from "rehype-autolink-headings";
|
|
20
|
+
import Ne from "rehype-sanitize";
|
|
21
|
+
import { endAt as Pe, equalTo as J, get as Fe, getDatabase as Ie, onValue as Le, orderByChild as Re, orderByKey as ze, orderByValue as Be, query as Ve, ref as He, remove as Ue, set as We, startAt as Ge, update as Ke } from "firebase/database";
|
|
22
22
|
import "react-dom/server";
|
|
23
23
|
//#region \0rolldown/runtime.js
|
|
24
24
|
var qe = Object.defineProperty, Je = (e, t) => {
|
|
@@ -2437,7 +2437,16 @@ var vn = "data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10
|
|
|
2437
2437
|
grid: {
|
|
2438
2438
|
buttonAdd: "Add",
|
|
2439
2439
|
deleteConfirm: "Delete record",
|
|
2440
|
-
emptyState: "No records found"
|
|
2440
|
+
emptyState: "No records found",
|
|
2441
|
+
filtersButton: "Filters",
|
|
2442
|
+
filtersPanelTitle: "Filters",
|
|
2443
|
+
filtersClearAll: "Clear all",
|
|
2444
|
+
filtersSelectPlaceholder: "All",
|
|
2445
|
+
filtersRangeFrom: "From",
|
|
2446
|
+
filtersRangeTo: "To",
|
|
2447
|
+
filtersRangeMin: "Min",
|
|
2448
|
+
filtersRangeMax: "Max",
|
|
2449
|
+
filtersSelectedCountTemplate: "{count} selected"
|
|
2441
2450
|
},
|
|
2442
2451
|
select: {
|
|
2443
2452
|
placeholder: "Select...",
|
|
@@ -3716,7 +3725,7 @@ var Ti = "rounded-lg border border-border bg-card text-card-foreground shadow-sm
|
|
|
3716
3725
|
}))
|
|
3717
3726
|
}, e);
|
|
3718
3727
|
}, Pi = ({ menuKey: e, as: n = "ul", badges: r = {}, before: i = void 0, after: a = void 0, wrapperClassName: o = void 0, className: s = void 0, headerClassName: c = void 0, itemClassName: u = void 0, linkClassName: d = void 0, iconClassName: f = void 0, textClassName: p = void 0, badgeClassName: m = void 0, arrowClassName: g = void 0, submenuClassName: _ = void 0 }) => {
|
|
3719
|
-
let y =
|
|
3728
|
+
let y = Vh(e), b = Y("menu"), x = ({ item: e, index: i }) => {
|
|
3720
3729
|
let [a, o] = h(e.active);
|
|
3721
3730
|
l(() => {
|
|
3722
3731
|
o(e.active);
|
|
@@ -10872,22 +10881,22 @@ var cd = (e) => {
|
|
|
10872
10881
|
type: t,
|
|
10873
10882
|
message: e
|
|
10874
10883
|
});
|
|
10875
|
-
}, [b]), [ye, be] = h({}), xe = m({}), Se = m(null), Ce = m(L), we = m(c), Te = m(g), Ee = m(_), De = m(v), Oe = m(o),
|
|
10884
|
+
}, [b]), [ye, be] = h({}), xe = m({}), Se = m(null), Ce = m(L), we = m(c), Te = m(g), Ee = m(_), De = m(v), Oe = m(o), ke = m(y), Ae = s(() => {
|
|
10876
10885
|
pe(), he(), ne(null);
|
|
10877
|
-
}, [pe, he]),
|
|
10886
|
+
}, [pe, he]), je = s(() => {
|
|
10878
10887
|
let e = me();
|
|
10879
10888
|
if (!e) {
|
|
10880
10889
|
ne(null);
|
|
10881
10890
|
return;
|
|
10882
10891
|
}
|
|
10883
10892
|
R(wt(e)), ne("restored");
|
|
10884
|
-
}, [me]),
|
|
10893
|
+
}, [me]), Me = s(() => {
|
|
10885
10894
|
be({}), _e(void 0), ne(null), he();
|
|
10886
|
-
}, [he]),
|
|
10895
|
+
}, [he]), Ne = s((e, t) => {
|
|
10887
10896
|
xe.current[e] = t;
|
|
10888
|
-
}, []), Ne = s((e) => {
|
|
10889
|
-
delete xe.current[e];
|
|
10890
10897
|
}, []), Pe = s((e) => {
|
|
10898
|
+
delete xe.current[e];
|
|
10899
|
+
}, []), J = s((e) => {
|
|
10891
10900
|
be((t) => {
|
|
10892
10901
|
if (!t[e]) return t;
|
|
10893
10902
|
let { [e]: n, ...r } = t;
|
|
@@ -10931,7 +10940,7 @@ var cd = (e) => {
|
|
|
10931
10940
|
u,
|
|
10932
10941
|
U
|
|
10933
10942
|
]), Le = s(async (e) => {
|
|
10934
|
-
if (
|
|
10943
|
+
if (ke.current && Oe.current && P) {
|
|
10935
10944
|
let t = (/* @__PURE__ */ new Date()).toISOString(), n = Yr("user");
|
|
10936
10945
|
P.set(`/log/${Oe.current}/${ct(t)}`, {
|
|
10937
10946
|
user: n?.email ?? "unknown",
|
|
@@ -11021,7 +11030,7 @@ var cd = (e) => {
|
|
|
11021
11030
|
]), l(() => {
|
|
11022
11031
|
Ce.current = L, L !== void 0 && f?.(L);
|
|
11023
11032
|
}, [L, f]), l(() => {
|
|
11024
|
-
we.current = c, Te.current = g, Ee.current = _, De.current = v, Oe.current = o,
|
|
11033
|
+
we.current = c, Te.current = g, Ee.current = _, De.current = v, Oe.current = o, ke.current = y;
|
|
11025
11034
|
}, [
|
|
11026
11035
|
c,
|
|
11027
11036
|
y,
|
|
@@ -11064,17 +11073,17 @@ var cd = (e) => {
|
|
|
11064
11073
|
I.bindActions({
|
|
11065
11074
|
save: Re,
|
|
11066
11075
|
delete: ze,
|
|
11067
|
-
reset:
|
|
11068
|
-
restoreDraft:
|
|
11069
|
-
discardDraft:
|
|
11076
|
+
reset: Me,
|
|
11077
|
+
restoreDraft: je,
|
|
11078
|
+
discardDraft: Ae
|
|
11070
11079
|
});
|
|
11071
11080
|
}, [
|
|
11072
11081
|
I,
|
|
11073
|
-
|
|
11082
|
+
Ae,
|
|
11074
11083
|
ze,
|
|
11075
11084
|
Re,
|
|
11076
|
-
|
|
11077
|
-
|
|
11085
|
+
Me,
|
|
11086
|
+
je
|
|
11078
11087
|
]), l(() => {
|
|
11079
11088
|
I.setState({
|
|
11080
11089
|
record: Ce.current,
|
|
@@ -11106,14 +11115,14 @@ var cd = (e) => {
|
|
|
11106
11115
|
let Be = s((e) => {
|
|
11107
11116
|
e.defaultPrevented || !((e.ctrlKey || e.metaKey) && e.key.toLowerCase() === "s") || F.saveDisabled || (e.preventDefault(), F.save());
|
|
11108
11117
|
}, [F]), Ve = p(() => ({
|
|
11109
|
-
registerField:
|
|
11110
|
-
unregisterField:
|
|
11111
|
-
clearFieldError:
|
|
11118
|
+
registerField: Ne,
|
|
11119
|
+
unregisterField: Pe,
|
|
11120
|
+
clearFieldError: J,
|
|
11112
11121
|
errors: ye
|
|
11113
11122
|
}), [
|
|
11114
|
-
Me,
|
|
11115
11123
|
Ne,
|
|
11116
11124
|
Pe,
|
|
11125
|
+
J,
|
|
11117
11126
|
ye
|
|
11118
11127
|
]), He = p(() => ({
|
|
11119
11128
|
record: L,
|
|
@@ -11142,18 +11151,18 @@ var cd = (e) => {
|
|
|
11142
11151
|
}, /* @__PURE__ */ t.createElement("div", { className: "flex items-start justify-between gap-3" }, /* @__PURE__ */ t.createElement("div", { className: "min-w-0" }, /* @__PURE__ */ t.createElement("div", { className: "font-medium" }, e), /* @__PURE__ */ t.createElement("div", { className: "text-sm opacity-90" }, n)), /* @__PURE__ */ t.createElement("div", { className: "flex shrink-0 items-center gap-2" }, G === "restore" ? /* @__PURE__ */ t.createElement(t.Fragment, null, /* @__PURE__ */ t.createElement(Br, {
|
|
11143
11152
|
label: ue,
|
|
11144
11153
|
variant: "warning",
|
|
11145
|
-
onClick: () =>
|
|
11154
|
+
onClick: () => je()
|
|
11146
11155
|
}), /* @__PURE__ */ t.createElement(Br, {
|
|
11147
11156
|
label: de,
|
|
11148
11157
|
variant: "outline-secondary",
|
|
11149
|
-
onClick: () =>
|
|
11158
|
+
onClick: () => Ae()
|
|
11150
11159
|
})) : /* @__PURE__ */ t.createElement(Br, {
|
|
11151
11160
|
label: de,
|
|
11152
11161
|
variant: "outline-secondary",
|
|
11153
|
-
onClick: () =>
|
|
11162
|
+
onClick: () => Ae()
|
|
11154
11163
|
}))));
|
|
11155
11164
|
}, [
|
|
11156
|
-
|
|
11165
|
+
Ae,
|
|
11157
11166
|
de,
|
|
11158
11167
|
G,
|
|
11159
11168
|
ue,
|
|
@@ -11161,7 +11170,7 @@ var cd = (e) => {
|
|
|
11161
11170
|
ce,
|
|
11162
11171
|
q,
|
|
11163
11172
|
fe,
|
|
11164
|
-
|
|
11173
|
+
je
|
|
11165
11174
|
]), Ke = p(() => {
|
|
11166
11175
|
switch (n) {
|
|
11167
11176
|
case "empty": return /* @__PURE__ */ t.createElement(t.Fragment, null, Ge, Ue, We);
|
|
@@ -11576,7 +11585,7 @@ function Od({ columns: e = void 0, records: n = void 0, footer: r = void 0, onRo
|
|
|
11576
11585
|
F.Table.scrollClassName,
|
|
11577
11586
|
j ? `${j} overflow-auto` : "",
|
|
11578
11587
|
M || ""
|
|
11579
|
-
].filter(Boolean).join(" "), Oe = !!j,
|
|
11588
|
+
].filter(Boolean).join(" "), Oe = !!j, ke = Ee.length + +!!ve + +!!ue, Ae = Oe ? "sticky top-0 z-10 bg-card" : "", je = (e, n, r, i) => !K || K.key !== e || K.position !== n ? null : /* @__PURE__ */ t.createElement("tr", {
|
|
11580
11589
|
"aria-hidden": "true",
|
|
11581
11590
|
onDragOver: (t) => {
|
|
11582
11591
|
ue && (t.preventDefault(), ne !== e && re(e), ie({
|
|
@@ -11591,10 +11600,10 @@ function Od({ columns: e = void 0, records: n = void 0, footer: r = void 0, onRo
|
|
|
11591
11600
|
}), Te(r, i));
|
|
11592
11601
|
}
|
|
11593
11602
|
}, /* @__PURE__ */ t.createElement("td", {
|
|
11594
|
-
colSpan:
|
|
11603
|
+
colSpan: ke,
|
|
11595
11604
|
className: "border-0 p-0"
|
|
11596
|
-
}, /* @__PURE__ */ t.createElement("div", { className: "relative h-5 cursor-grab" }, /* @__PURE__ */ t.createElement("div", { className: "absolute inset-x-2 top-1/2 -translate-y-1/2" }, /* @__PURE__ */ t.createElement("div", { className: "h-0 rounded-full border-t-2 border-primary/80" }), /* @__PURE__ */ t.createElement("div", { className: "absolute left-0 top-1/2 h-2 w-2 -translate-y-1/2 rounded-full bg-primary shadow-sm" }))))),
|
|
11597
|
-
className: ["px-3 py-2 font-semibold text-muted-foreground",
|
|
11605
|
+
}, /* @__PURE__ */ t.createElement("div", { className: "relative h-5 cursor-grab" }, /* @__PURE__ */ t.createElement("div", { className: "absolute inset-x-2 top-1/2 -translate-y-1/2" }, /* @__PURE__ */ t.createElement("div", { className: "h-0 rounded-full border-t-2 border-primary/80" }), /* @__PURE__ */ t.createElement("div", { className: "absolute left-0 top-1/2 h-2 w-2 -translate-y-1/2 rounded-full bg-primary shadow-sm" }))))), Me = /* @__PURE__ */ t.createElement("tr", null, ve && /* @__PURE__ */ t.createElement("th", {
|
|
11606
|
+
className: ["px-3 py-2 font-semibold text-muted-foreground", Ae].filter(Boolean).join(" "),
|
|
11598
11607
|
style: {
|
|
11599
11608
|
width: "1%",
|
|
11600
11609
|
whiteSpace: "nowrap"
|
|
@@ -11608,7 +11617,7 @@ function Od({ columns: e = void 0, records: n = void 0, footer: r = void 0, onRo
|
|
|
11608
11617
|
ye(t);
|
|
11609
11618
|
}
|
|
11610
11619
|
}))), ue && /* @__PURE__ */ t.createElement("th", {
|
|
11611
|
-
className: ["px-3 py-2 font-semibold text-muted-foreground",
|
|
11620
|
+
className: ["px-3 py-2 font-semibold text-muted-foreground", Ae].filter(Boolean).join(" "),
|
|
11612
11621
|
style: {
|
|
11613
11622
|
width: "1%",
|
|
11614
11623
|
whiteSpace: "nowrap"
|
|
@@ -11619,7 +11628,7 @@ function Od({ columns: e = void 0, records: n = void 0, footer: r = void 0, onRo
|
|
|
11619
11628
|
key: e.key,
|
|
11620
11629
|
className: [
|
|
11621
11630
|
"px-3 py-2 font-semibold text-muted-foreground",
|
|
11622
|
-
|
|
11631
|
+
Ae,
|
|
11623
11632
|
e.className || ""
|
|
11624
11633
|
].filter(Boolean).join(" "),
|
|
11625
11634
|
"aria-sort": i
|
|
@@ -11638,12 +11647,12 @@ function Od({ columns: e = void 0, records: n = void 0, footer: r = void 0, onRo
|
|
|
11638
11647
|
}, r ? H?.dir === "desc" ? /* @__PURE__ */ t.createElement(E, { size: 14 }) : /* @__PURE__ */ t.createElement(D, { size: 14 }) : /* @__PURE__ */ t.createElement(O, { size: 14 })), /* @__PURE__ */ t.createElement("span", null, e.label)) : /* @__PURE__ */ t.createElement("div", { className: "th-inner py-1" }, e.label));
|
|
11639
11648
|
})() : /* @__PURE__ */ t.createElement("th", {
|
|
11640
11649
|
key: e.key,
|
|
11641
|
-
className: ["px-3 py-2 font-semibold text-muted-foreground",
|
|
11650
|
+
className: ["px-3 py-2 font-semibold text-muted-foreground", Ae].filter(Boolean).join(" "),
|
|
11642
11651
|
style: {
|
|
11643
11652
|
width: "1%",
|
|
11644
11653
|
whiteSpace: "nowrap"
|
|
11645
11654
|
}
|
|
11646
|
-
}))),
|
|
11655
|
+
}))), Ne = /* @__PURE__ */ t.createElement(Hp, {
|
|
11647
11656
|
records: be,
|
|
11648
11657
|
appendTo: W,
|
|
11649
11658
|
wrapperClassName: "px-3 pt-4 pb-2",
|
|
@@ -11655,9 +11664,9 @@ function Od({ columns: e = void 0, records: n = void 0, footer: r = void 0, onRo
|
|
|
11655
11664
|
a = u;
|
|
11656
11665
|
let f = ge.includes(l), p = ne === l, m = te === l, h = L && (g === void 0 ? ae : g) === l;
|
|
11657
11666
|
return /* @__PURE__ */ t.createElement(t.Fragment, { key: l }, d && /* @__PURE__ */ t.createElement("tr", { "aria-hidden": "true" }, /* @__PURE__ */ t.createElement("td", {
|
|
11658
|
-
colSpan:
|
|
11667
|
+
colSpan: ke,
|
|
11659
11668
|
className: "bg-muted/40 px-3 py-1.5 text-xs font-semibold uppercase tracking-wide text-muted-foreground"
|
|
11660
|
-
}, u)),
|
|
11669
|
+
}, u)), je(l, "before", e, s), /* @__PURE__ */ t.createElement("tr", {
|
|
11661
11670
|
draggable: ue,
|
|
11662
11671
|
className: [
|
|
11663
11672
|
"odd:bg-muted/30 hover:bg-muted/20 transition-colors",
|
|
@@ -11734,13 +11743,13 @@ function Od({ columns: e = void 0, records: n = void 0, footer: r = void 0, onRo
|
|
|
11734
11743
|
}, /* @__PURE__ */ t.createElement(k, { size: 14 }))), Ee.map((n) => /* @__PURE__ */ t.createElement("td", {
|
|
11735
11744
|
key: n.key,
|
|
11736
11745
|
className: "px-3 py-2 border-b border-border/50"
|
|
11737
|
-
}, Se(e, n.key, s)))),
|
|
11746
|
+
}, Se(e, n.key, s)))), je(l, "after", e, s));
|
|
11738
11747
|
});
|
|
11739
11748
|
});
|
|
11740
11749
|
return /* @__PURE__ */ t.createElement("div", { className: "flex items-stretch gap-3" }, b && /* @__PURE__ */ t.createElement("div", { className: "table-before flex shrink-0 items-center self-stretch" }, b), /* @__PURE__ */ t.createElement("div", {
|
|
11741
11750
|
ref: ce,
|
|
11742
11751
|
className: "min-w-0 flex-1 overflow-x-auto " + (S || F.Table.wrapperClassName)
|
|
11743
|
-
}, /* @__PURE__ */ t.createElement("div", { className: De }, /* @__PURE__ */ t.createElement("table", { className: "w-full text-left text-sm border-collapse " + (C || F.Table.className) }, /* @__PURE__ */ t.createElement("thead", { className: "border-b " + (w || F.Table.headerClassName) },
|
|
11752
|
+
}, /* @__PURE__ */ t.createElement("div", { className: De }, /* @__PURE__ */ t.createElement("table", { className: "w-full text-left text-sm border-collapse " + (C || F.Table.className) }, /* @__PURE__ */ t.createElement("thead", { className: "border-b " + (w || F.Table.headerClassName) }, Me), /* @__PURE__ */ t.createElement("tbody", { className: T || F.Table.bodyClassName }, Ne), r && /* @__PURE__ */ t.createElement("tfoot", { className: A || F.Table.footerClassName }, r)))), x && /* @__PURE__ */ t.createElement("div", { className: "table-after flex shrink-0 items-center self-stretch" }, x));
|
|
11744
11753
|
}
|
|
11745
11754
|
//#endregion
|
|
11746
11755
|
//#region src/components/ui/LayoutBuilder.tsx
|
|
@@ -13713,7 +13722,7 @@ function Ff({ group: e, expanded: n, openItems: r, showIcons: i, onToggle: a })
|
|
|
13713
13722
|
}))));
|
|
13714
13723
|
}
|
|
13715
13724
|
function If({ menuKey: e, items: n, defaultCollapsed: r = !1, showIcons: i = !0, showCollapseButton: a = !0, footer: o, header: c, embedded: u = !1 }) {
|
|
13716
|
-
let { pathname: d } = x(), f = Y("sideNav"), p =
|
|
13725
|
+
let { pathname: d } = x(), f = Y("sideNav"), p = Vh(e ?? ""), g = n ?? (e ? kf(p) : []), [_, v] = h(r), [y, b] = h(!1), [S, C] = h(/* @__PURE__ */ new Set()), w = m(null), T = !_ || y;
|
|
13717
13726
|
l(() => {
|
|
13718
13727
|
C((e) => {
|
|
13719
13728
|
let t = new Set(e);
|
|
@@ -13841,7 +13850,7 @@ function zf({ path: e, fromUrl: n, where: r, order: i, fieldMap: a, recordId: o
|
|
|
13841
13850
|
dir: n
|
|
13842
13851
|
};
|
|
13843
13852
|
}, [i]), f = s.sortable === void 0 || s.sortable === !0 ? d ?? s.sortable : s.sortable;
|
|
13844
|
-
return /* @__PURE__ */ t.createElement(
|
|
13853
|
+
return /* @__PURE__ */ t.createElement(nm, {
|
|
13845
13854
|
...s,
|
|
13846
13855
|
records: u,
|
|
13847
13856
|
recordId: o,
|
|
@@ -14469,12 +14478,12 @@ function Bp({ content: e, components: n, className: r, wrapperClassName: i, meta
|
|
|
14469
14478
|
title: a?.title ?? s
|
|
14470
14479
|
} : void 0);
|
|
14471
14480
|
let c = t.useMemo(() => zp(o), [o]);
|
|
14472
|
-
return /* @__PURE__ */ t.createElement("div", { className: X("rf-markdown-reader max-w-none text-sm text-foreground", i, r) }, /* @__PURE__ */ t.createElement(
|
|
14473
|
-
remarkPlugins: [
|
|
14481
|
+
return /* @__PURE__ */ t.createElement("div", { className: X("rf-markdown-reader max-w-none text-sm text-foreground", i, r) }, /* @__PURE__ */ t.createElement(ke, {
|
|
14482
|
+
remarkPlugins: [Ae],
|
|
14474
14483
|
rehypePlugins: [
|
|
14475
|
-
|
|
14476
|
-
[
|
|
14477
|
-
|
|
14484
|
+
je,
|
|
14485
|
+
[Me, { behavior: "wrap" }],
|
|
14486
|
+
Ne
|
|
14478
14487
|
],
|
|
14479
14488
|
components: {
|
|
14480
14489
|
...c,
|
|
@@ -15128,8 +15137,145 @@ function Jp({ selection: e }) {
|
|
|
15128
15137
|
}
|
|
15129
15138
|
//#endregion
|
|
15130
15139
|
//#region src/components/widgets/grid-core/GridCore.tsx
|
|
15131
|
-
var Yp = (e, t, n, r, i) => t?.kind === "delete" ? typeof t.title == "function" ? t.title(n) : t.title || r : t?.kind === "modal" ? typeof t.title == "function" ? t.title(n) : t.title || Xf(e, t, i) : Xf(e, t, i)
|
|
15132
|
-
|
|
15140
|
+
var Yp = (e, t, n, r, i) => t?.kind === "delete" ? typeof t.title == "function" ? t.title(n) : t.title || r : t?.kind === "modal" ? typeof t.title == "function" ? t.title(n) : t.title || Xf(e, t, i) : Xf(e, t, i), Xp = (e) => {
|
|
15141
|
+
switch (e.kind) {
|
|
15142
|
+
case "select": return "";
|
|
15143
|
+
case "multiselect": return [];
|
|
15144
|
+
case "dateRange": return {
|
|
15145
|
+
from: "",
|
|
15146
|
+
to: ""
|
|
15147
|
+
};
|
|
15148
|
+
case "numberRange": return {
|
|
15149
|
+
min: void 0,
|
|
15150
|
+
max: void 0
|
|
15151
|
+
};
|
|
15152
|
+
default: return e.defaultValue ?? !1;
|
|
15153
|
+
}
|
|
15154
|
+
}, Zp = (e, t) => {
|
|
15155
|
+
switch (e.kind) {
|
|
15156
|
+
case "select": return typeof t == "string" && t !== "";
|
|
15157
|
+
case "multiselect": return Array.isArray(t) && t.length > 0;
|
|
15158
|
+
case "dateRange": {
|
|
15159
|
+
let e = t;
|
|
15160
|
+
return !!e?.from || !!e?.to;
|
|
15161
|
+
}
|
|
15162
|
+
case "numberRange": {
|
|
15163
|
+
let e = t;
|
|
15164
|
+
return e?.min !== void 0 || e?.max !== void 0;
|
|
15165
|
+
}
|
|
15166
|
+
default: return !!t != !!(e.defaultValue ?? !1);
|
|
15167
|
+
}
|
|
15168
|
+
}, Qp = (e, t, n) => {
|
|
15169
|
+
switch (e.kind) {
|
|
15170
|
+
case "select": return e.predicate(t, n);
|
|
15171
|
+
case "multiselect": return e.predicate(t, n);
|
|
15172
|
+
case "dateRange": return e.predicate(t, n);
|
|
15173
|
+
case "numberRange": return e.predicate(t, n);
|
|
15174
|
+
default: return e.predicate(t, n);
|
|
15175
|
+
}
|
|
15176
|
+
}, $p = (e, t, n) => {
|
|
15177
|
+
switch (e.kind) {
|
|
15178
|
+
case "select": {
|
|
15179
|
+
let n = e.options.find((e) => e.value === t);
|
|
15180
|
+
return `${e.label}: ${n?.label ?? String(t)}`;
|
|
15181
|
+
}
|
|
15182
|
+
case "multiselect": {
|
|
15183
|
+
let r = t;
|
|
15184
|
+
if (r.length === 1) {
|
|
15185
|
+
let t = e.options.find((e) => e.value === r[0]);
|
|
15186
|
+
return `${e.label}: ${t?.label ?? r[0]}`;
|
|
15187
|
+
}
|
|
15188
|
+
return `${e.label}: ${n.filtersSelectedCountTemplate.replace("{count}", String(r.length))}`;
|
|
15189
|
+
}
|
|
15190
|
+
case "dateRange": {
|
|
15191
|
+
let r = t;
|
|
15192
|
+
return r.from && r.to ? `${e.label}: ${r.from} → ${r.to}` : r.from ? `${e.label}: ${n.filtersRangeFrom} ${r.from}` : `${e.label}: ${n.filtersRangeTo} ${r.to}`;
|
|
15193
|
+
}
|
|
15194
|
+
case "numberRange": {
|
|
15195
|
+
let r = t;
|
|
15196
|
+
return r.min !== void 0 && r.max !== void 0 ? `${e.label}: ${r.min}–${r.max}` : r.min === void 0 ? `${e.label}: ${n.filtersRangeMax} ${r.max}` : `${e.label}: ${n.filtersRangeMin} ${r.min}`;
|
|
15197
|
+
}
|
|
15198
|
+
default: return e.label;
|
|
15199
|
+
}
|
|
15200
|
+
}, em = "w-full rounded-md border border-input bg-background px-2 py-1.5 text-sm placeholder:text-muted-foreground focus:outline-none focus:ring-2 focus:ring-ring";
|
|
15201
|
+
function tm({ filter: e, value: n, onChange: r, dict: i }) {
|
|
15202
|
+
if (e.kind === "select") return /* @__PURE__ */ t.createElement("label", { className: "flex flex-col gap-1.5" }, /* @__PURE__ */ t.createElement("span", { className: "text-sm font-medium text-foreground" }, e.label), /* @__PURE__ */ t.createElement("select", {
|
|
15203
|
+
className: em,
|
|
15204
|
+
value: n,
|
|
15205
|
+
onChange: (e) => r(e.target.value)
|
|
15206
|
+
}, /* @__PURE__ */ t.createElement("option", { value: "" }, i.filtersSelectPlaceholder), e.options.map((e) => /* @__PURE__ */ t.createElement("option", {
|
|
15207
|
+
key: e.value,
|
|
15208
|
+
value: e.value
|
|
15209
|
+
}, e.label))));
|
|
15210
|
+
if (e.kind === "multiselect") {
|
|
15211
|
+
let i = n, a = (e) => r(i.includes(e) ? i.filter((t) => t !== e) : [...i, e]);
|
|
15212
|
+
return /* @__PURE__ */ t.createElement("div", { className: "flex flex-col gap-1.5" }, /* @__PURE__ */ t.createElement("span", { className: "text-sm font-medium text-foreground" }, e.label), /* @__PURE__ */ t.createElement("div", { className: "flex flex-col gap-1" }, e.options.map((e) => /* @__PURE__ */ t.createElement("label", {
|
|
15213
|
+
key: e.value,
|
|
15214
|
+
className: "flex cursor-pointer items-center gap-2 text-sm text-muted-foreground"
|
|
15215
|
+
}, /* @__PURE__ */ t.createElement("input", {
|
|
15216
|
+
type: "checkbox",
|
|
15217
|
+
checked: i.includes(e.value),
|
|
15218
|
+
onChange: () => a(e.value)
|
|
15219
|
+
}), e.label))));
|
|
15220
|
+
}
|
|
15221
|
+
if (e.kind === "dateRange") {
|
|
15222
|
+
let a = n;
|
|
15223
|
+
return /* @__PURE__ */ t.createElement("div", { className: "flex flex-col gap-1.5" }, /* @__PURE__ */ t.createElement("span", { className: "text-sm font-medium text-foreground" }, e.label), /* @__PURE__ */ t.createElement("div", { className: "flex items-center gap-2" }, /* @__PURE__ */ t.createElement("input", {
|
|
15224
|
+
type: "date",
|
|
15225
|
+
"aria-label": `${e.label} ${i.filtersRangeFrom}`,
|
|
15226
|
+
className: em,
|
|
15227
|
+
value: a.from,
|
|
15228
|
+
onChange: (e) => r({
|
|
15229
|
+
...a,
|
|
15230
|
+
from: e.target.value
|
|
15231
|
+
})
|
|
15232
|
+
}), /* @__PURE__ */ t.createElement("span", { className: "shrink-0 text-xs text-muted-foreground" }, i.filtersRangeTo), /* @__PURE__ */ t.createElement("input", {
|
|
15233
|
+
type: "date",
|
|
15234
|
+
"aria-label": `${e.label} ${i.filtersRangeTo}`,
|
|
15235
|
+
className: em,
|
|
15236
|
+
value: a.to,
|
|
15237
|
+
onChange: (e) => r({
|
|
15238
|
+
...a,
|
|
15239
|
+
to: e.target.value
|
|
15240
|
+
})
|
|
15241
|
+
})));
|
|
15242
|
+
}
|
|
15243
|
+
if (e.kind === "numberRange") {
|
|
15244
|
+
let a = n;
|
|
15245
|
+
return /* @__PURE__ */ t.createElement("div", { className: "flex flex-col gap-1.5" }, /* @__PURE__ */ t.createElement("span", { className: "text-sm font-medium text-foreground" }, e.label), /* @__PURE__ */ t.createElement("div", { className: "flex items-center gap-2" }, /* @__PURE__ */ t.createElement("input", {
|
|
15246
|
+
type: "number",
|
|
15247
|
+
placeholder: i.filtersRangeMin,
|
|
15248
|
+
"aria-label": `${e.label} ${i.filtersRangeMin}`,
|
|
15249
|
+
className: em,
|
|
15250
|
+
value: a.min ?? "",
|
|
15251
|
+
onChange: (e) => r({
|
|
15252
|
+
...a,
|
|
15253
|
+
min: e.target.value === "" ? void 0 : Number(e.target.value)
|
|
15254
|
+
})
|
|
15255
|
+
}), /* @__PURE__ */ t.createElement("span", { className: "shrink-0 text-xs text-muted-foreground" }, "–"), /* @__PURE__ */ t.createElement("input", {
|
|
15256
|
+
type: "number",
|
|
15257
|
+
placeholder: i.filtersRangeMax,
|
|
15258
|
+
"aria-label": `${e.label} ${i.filtersRangeMax}`,
|
|
15259
|
+
className: em,
|
|
15260
|
+
value: a.max ?? "",
|
|
15261
|
+
onChange: (e) => r({
|
|
15262
|
+
...a,
|
|
15263
|
+
max: e.target.value === "" ? void 0 : Number(e.target.value)
|
|
15264
|
+
})
|
|
15265
|
+
})));
|
|
15266
|
+
}
|
|
15267
|
+
let a = n;
|
|
15268
|
+
return /* @__PURE__ */ t.createElement("label", { className: "inline-flex cursor-pointer items-center gap-2 select-none" }, /* @__PURE__ */ t.createElement("span", { className: "relative inline-flex h-5 w-9 shrink-0 items-center" }, /* @__PURE__ */ t.createElement("input", {
|
|
15269
|
+
type: "checkbox",
|
|
15270
|
+
checked: a,
|
|
15271
|
+
onChange: () => r(!a),
|
|
15272
|
+
className: "peer absolute inset-0 m-0 h-full w-full cursor-pointer opacity-0"
|
|
15273
|
+
}), /* @__PURE__ */ t.createElement("span", {
|
|
15274
|
+
"aria-hidden": "true",
|
|
15275
|
+
className: X("pointer-events-none absolute inset-0 rounded-full transition-colors duration-200 ease-out peer-focus-visible:ring-2 peer-focus-visible:ring-ring peer-focus-visible:ring-offset-2", a ? "bg-primary" : "bg-muted-foreground/35")
|
|
15276
|
+
}, /* @__PURE__ */ t.createElement("span", { className: X("pointer-events-none absolute top-0.5 left-0.5 h-4 w-4 rounded-full bg-background shadow-sm transition-transform duration-200 ease-out", a && "translate-x-4") }))), /* @__PURE__ */ t.createElement("span", { className: "text-sm text-foreground" }, e.label));
|
|
15277
|
+
}
|
|
15278
|
+
function nm({ records: e, recordId: n, sourcePath: r, columns: i, actions: a, form: o, editDeepLink: c, header: u, footer: d, view: f = "table", views: m, sticky: g, wrapperClassName: _, cardClassName: v, bodyClassName: y, loading: b = !1, title: x, before: S, after: C, sortable: w = !0, pagination: T, selection: E, onRowClick: D, reorderable: O = !1, onReorder: k, groupBy: A, searchable: j, filters: M, onSave: N, onDelete: P, onComplete: F, audit: I = !1, onLoad: L }) {
|
|
15133
15279
|
let R = Y("grid"), z = Nn("grid"), B = Nn("common"), V = p(() => ({ add: z.buttonAdd }), [z.buttonAdd]), H = Ci(), { preparedRecords: U, loading: W } = qp({
|
|
15134
15280
|
records: e,
|
|
15135
15281
|
onLoad: L
|
|
@@ -15137,65 +15283,87 @@ function Xp({ records: e, recordId: n, sourcePath: r, columns: i, actions: a, fo
|
|
|
15137
15283
|
columns: i,
|
|
15138
15284
|
records: U,
|
|
15139
15285
|
form: o
|
|
15140
|
-
}), [te, G] = h(() => Object.fromEntries((M ?? []).map((e) => [e.key, e
|
|
15286
|
+
}), [te, G] = h(() => Object.fromEntries((M ?? []).map((e) => [e.key, Xp(e)]))), [ne, re] = h(!1), K = s((e, t) => {
|
|
15287
|
+
G((n) => ({
|
|
15288
|
+
...n,
|
|
15289
|
+
[e]: t
|
|
15290
|
+
}));
|
|
15291
|
+
}, []), ie = s((e) => {
|
|
15141
15292
|
G((t) => ({
|
|
15142
15293
|
...t,
|
|
15143
|
-
[e]:
|
|
15294
|
+
[e.key]: Xp(e)
|
|
15144
15295
|
}));
|
|
15145
|
-
}, []),
|
|
15296
|
+
}, []), ae = (M ?? []).filter((e) => Zp(e, te[e.key] ?? Xp(e))), oe = p(() => !M || M.length === 0 ? U : U.filter((e) => M.every((t) => Qp(t, e, te[t.key] ?? Xp(t)))), [
|
|
15146
15297
|
U,
|
|
15147
15298
|
M,
|
|
15148
15299
|
te
|
|
15149
|
-
]),
|
|
15150
|
-
|
|
15151
|
-
|
|
15152
|
-
|
|
15153
|
-
|
|
15154
|
-
|
|
15155
|
-
|
|
15156
|
-
|
|
15157
|
-
|
|
15158
|
-
|
|
15159
|
-
|
|
15160
|
-
|
|
15161
|
-
|
|
15162
|
-
|
|
15163
|
-
})) : null,
|
|
15164
|
-
|
|
15165
|
-
|
|
15166
|
-
|
|
15300
|
+
]), se = M && M.length > 0 ? /* @__PURE__ */ t.createElement("div", { className: "flex flex-wrap items-center gap-2" }, /* @__PURE__ */ t.createElement(Br, {
|
|
15301
|
+
icon: "filter",
|
|
15302
|
+
label: z.filtersButton,
|
|
15303
|
+
variant: "outline-secondary",
|
|
15304
|
+
badge: ae.length > 0 ? ae.length : void 0,
|
|
15305
|
+
onClick: () => re(!0)
|
|
15306
|
+
}), ae.map((e) => /* @__PURE__ */ t.createElement("span", {
|
|
15307
|
+
key: e.key,
|
|
15308
|
+
className: "inline-flex shrink-0 items-center gap-1.5 rounded-full border border-primary/20 bg-primary/10 px-2.5 py-1 text-xs font-medium text-primary"
|
|
15309
|
+
}, $p(e, te[e.key] ?? Xp(e), z), /* @__PURE__ */ t.createElement("button", {
|
|
15310
|
+
type: "button",
|
|
15311
|
+
"aria-label": `${z.filtersClearAll} ${e.label}`,
|
|
15312
|
+
className: "opacity-60 transition-opacity hover:opacity-100",
|
|
15313
|
+
onClick: () => ie(e)
|
|
15314
|
+
}, "×")))) : null, ce = M && M.length > 0 ? se : null, le = ne && M && M.length > 0 ? /* @__PURE__ */ t.createElement(Ai, {
|
|
15315
|
+
title: z.filtersPanelTitle,
|
|
15316
|
+
size: "sm",
|
|
15317
|
+
position: "right",
|
|
15318
|
+
onClose: () => re(!1),
|
|
15319
|
+
footer: /* @__PURE__ */ t.createElement(Br, {
|
|
15320
|
+
label: z.filtersClearAll,
|
|
15321
|
+
variant: "link",
|
|
15322
|
+
disabled: ae.length === 0,
|
|
15323
|
+
onClick: () => G(Object.fromEntries(M.map((e) => [e.key, Xp(e)])))
|
|
15324
|
+
})
|
|
15325
|
+
}, /* @__PURE__ */ t.createElement("div", { className: "flex flex-col gap-5" }, M.map((e) => /* @__PURE__ */ t.createElement(tm, {
|
|
15326
|
+
key: e.key,
|
|
15327
|
+
filter: e,
|
|
15328
|
+
value: te[e.key] ?? Xp(e),
|
|
15329
|
+
onChange: (t) => K(e.key, t),
|
|
15330
|
+
dict: z
|
|
15331
|
+
})))) : null, ue = j === !0 ? {} : j || void 0, [de, fe] = h(""), q = p(() => {
|
|
15332
|
+
if (!ue || !de.trim()) return oe;
|
|
15333
|
+
let e = de.trim().toLowerCase(), t = ue.fields?.map(String);
|
|
15334
|
+
return oe.filter((n) => (t ?? Object.keys(n)).some((t) => {
|
|
15167
15335
|
let r = Mt(n, t);
|
|
15168
15336
|
return typeof r == "string" && r.toLowerCase().includes(e);
|
|
15169
15337
|
}));
|
|
15170
15338
|
}, [
|
|
15171
|
-
|
|
15172
|
-
|
|
15173
|
-
|
|
15174
|
-
]),
|
|
15339
|
+
oe,
|
|
15340
|
+
ue,
|
|
15341
|
+
de
|
|
15342
|
+
]), pe = ue ? /* @__PURE__ */ t.createElement("div", { className: "flex min-w-0 items-center gap-2" }, /* @__PURE__ */ t.createElement("input", {
|
|
15175
15343
|
type: "search",
|
|
15176
|
-
value:
|
|
15177
|
-
onChange: (e) =>
|
|
15178
|
-
placeholder:
|
|
15344
|
+
value: de,
|
|
15345
|
+
onChange: (e) => fe(e.target.value),
|
|
15346
|
+
placeholder: ue.placeholder ?? B.search,
|
|
15179
15347
|
className: "w-full max-w-xs rounded-md border border-input bg-background px-2 py-1 text-sm placeholder:text-muted-foreground focus:outline-none focus:ring-2 focus:ring-ring"
|
|
15180
|
-
}), /* @__PURE__ */ t.createElement("span", { className: "shrink-0 text-xs text-muted-foreground" },
|
|
15348
|
+
}), /* @__PURE__ */ t.createElement("span", { className: "shrink-0 text-xs text-muted-foreground" }, q.length, " / ", oe.length)) : null, me = m ?? {}, he = me.table ?? {}, ge = me.gallery ?? {}, [_e, ve] = h(f);
|
|
15181
15349
|
l(() => {
|
|
15182
|
-
|
|
15350
|
+
ve(f);
|
|
15183
15351
|
}, [f]);
|
|
15184
|
-
let [
|
|
15185
|
-
|
|
15352
|
+
let [ye, be] = h(() => new Set(ee.filter((e) => e.defaultVisible === !1).map((e) => String(e.key)))), xe = s((e) => {
|
|
15353
|
+
be((t) => {
|
|
15186
15354
|
let n = new Set(t);
|
|
15187
15355
|
return n.has(e) ? n.delete(e) : n.add(e), n;
|
|
15188
15356
|
});
|
|
15189
|
-
}, []),
|
|
15190
|
-
|
|
15357
|
+
}, []), Se = p(() => ee.filter((e) => !ye.has(String(e.key))), [ee, ye]), Ce = ge.fields ?? [], [we, Te] = h(() => new Set(Ce.filter((e) => e.defaultVisible === !1).map((e) => String(e.key)))), Ee = s((e) => {
|
|
15358
|
+
Te((t) => {
|
|
15191
15359
|
let n = new Set(t);
|
|
15192
15360
|
return n.has(e) ? n.delete(e) : n.add(e), n;
|
|
15193
15361
|
});
|
|
15194
|
-
}, []),
|
|
15362
|
+
}, []), De = p(() => Ce.filter((e) => !we.has(String(e.key))), [Ce, we]), Oe = p(() => {
|
|
15195
15363
|
let e = [];
|
|
15196
|
-
if (
|
|
15364
|
+
if (De.length) {
|
|
15197
15365
|
let n = /* @__PURE__ */ new Map();
|
|
15198
|
-
|
|
15366
|
+
De.forEach((e) => {
|
|
15199
15367
|
let t = e.position ?? "bottomLeft";
|
|
15200
15368
|
n.has(t) || n.set(t, []), n.get(t).push(e);
|
|
15201
15369
|
}), e.push(...Array.from(n.entries()).map(([e, n]) => ({
|
|
@@ -15209,9 +15377,9 @@ function Xp({ records: e, recordId: n, sourcePath: r, columns: i, actions: a, fo
|
|
|
15209
15377
|
}))
|
|
15210
15378
|
})));
|
|
15211
15379
|
}
|
|
15212
|
-
let n = [...
|
|
15380
|
+
let n = [...ge.overlays ?? [], ...e];
|
|
15213
15381
|
return n.length ? n : void 0;
|
|
15214
|
-
}, [
|
|
15382
|
+
}, [ge.overlays, De]), { mode: ke, activeSelectionKeys: Ae, selectionState: je, handleSelectionChange: Me } = Jp({ selection: E }), { normalizedActions: Ne, activeAction: Pe, activeActionConfig: J, activeActionBody: Fe, activeKey: Ie, runAction: Le, close: Re, getActionContext: ze, getModalActionContext: Be, getRecordKey: Ve, formController: He } = Gp({
|
|
15215
15383
|
actions: a,
|
|
15216
15384
|
form: o,
|
|
15217
15385
|
editDeepLink: c,
|
|
@@ -15223,66 +15391,66 @@ function Xp({ records: e, recordId: n, sourcePath: r, columns: i, actions: a, fo
|
|
|
15223
15391
|
onDelete: P,
|
|
15224
15392
|
onComplete: F,
|
|
15225
15393
|
audit: I
|
|
15226
|
-
}),
|
|
15227
|
-
if (D?.(e), !
|
|
15228
|
-
let t =
|
|
15229
|
-
if (
|
|
15230
|
-
|
|
15394
|
+
}), Ue = Ne.edit, We = !!Ue && (Ue.kind !== "modal" || !!o), Ge = s((e) => {
|
|
15395
|
+
if (D?.(e), !We) return;
|
|
15396
|
+
let t = Ve(e);
|
|
15397
|
+
if (Pe?.actionKey === "edit" && Pe.record && Ve(Pe.record) === t) {
|
|
15398
|
+
Re();
|
|
15231
15399
|
return;
|
|
15232
15400
|
}
|
|
15233
|
-
|
|
15401
|
+
Le("edit", e);
|
|
15234
15402
|
}, [
|
|
15235
|
-
|
|
15236
|
-
|
|
15403
|
+
Pe?.actionKey,
|
|
15404
|
+
Pe?.record,
|
|
15405
|
+
We,
|
|
15237
15406
|
Re,
|
|
15238
|
-
|
|
15239
|
-
Fe,
|
|
15407
|
+
Ve,
|
|
15240
15408
|
D,
|
|
15241
|
-
|
|
15242
|
-
]),
|
|
15243
|
-
let i =
|
|
15409
|
+
Le
|
|
15410
|
+
]), Ke = D || We ? Ge : void 0, qe = s((e, n, r) => {
|
|
15411
|
+
let i = Ne[e];
|
|
15244
15412
|
return !i || !Jf(i, n) ? null : /* @__PURE__ */ t.createElement(Br, {
|
|
15245
15413
|
className: r || (e === "add" ? "btn-primary" : void 0),
|
|
15246
15414
|
icon: i.icon,
|
|
15247
15415
|
label: Xf(e, i, V),
|
|
15248
15416
|
disabled: Yf(i, n),
|
|
15249
|
-
onClick: () =>
|
|
15417
|
+
onClick: () => Le(e, n)
|
|
15250
15418
|
});
|
|
15251
15419
|
}, [
|
|
15252
|
-
|
|
15253
|
-
|
|
15420
|
+
Ne,
|
|
15421
|
+
Le,
|
|
15254
15422
|
V
|
|
15255
|
-
]),
|
|
15423
|
+
]), Je = p(() => Object.entries(Ne).filter(([e, t]) => e !== "edit" && e !== "delete" && Jf(t, void 0)).map(([e]) => e), [Ne]), Ye = p(() => ({
|
|
15256
15424
|
title: x,
|
|
15257
15425
|
records: U,
|
|
15258
|
-
selection:
|
|
15259
|
-
runAction:
|
|
15426
|
+
selection: je,
|
|
15427
|
+
runAction: Le
|
|
15260
15428
|
}), [
|
|
15261
15429
|
U,
|
|
15430
|
+
Le,
|
|
15262
15431
|
je,
|
|
15263
|
-
Te,
|
|
15264
15432
|
x
|
|
15265
|
-
]),
|
|
15433
|
+
]), Xe = p(() => ({
|
|
15266
15434
|
records: U,
|
|
15267
|
-
selection:
|
|
15268
|
-
runAction:
|
|
15435
|
+
selection: je,
|
|
15436
|
+
runAction: Le
|
|
15269
15437
|
}), [
|
|
15270
15438
|
U,
|
|
15271
|
-
|
|
15272
|
-
|
|
15273
|
-
]),
|
|
15439
|
+
Le,
|
|
15440
|
+
je
|
|
15441
|
+
]), Ze = me.toggle ? /* @__PURE__ */ t.createElement("span", { className: "inline-flex rounded-md border border-border overflow-hidden" }, /* @__PURE__ */ t.createElement(Br, {
|
|
15274
15442
|
icon: "list",
|
|
15275
15443
|
ariaLabel: "Table view",
|
|
15276
15444
|
title: "Table view",
|
|
15277
|
-
className: "rounded-none border-0 " + (
|
|
15278
|
-
onClick: () =>
|
|
15445
|
+
className: "rounded-none border-0 " + (_e === "table" ? "bg-card text-foreground shadow-sm" : "bg-transparent text-muted-foreground"),
|
|
15446
|
+
onClick: () => ve("table")
|
|
15279
15447
|
}), /* @__PURE__ */ t.createElement(Br, {
|
|
15280
15448
|
icon: "layout-grid",
|
|
15281
15449
|
ariaLabel: "Gallery view",
|
|
15282
15450
|
title: "Gallery view",
|
|
15283
|
-
className: "rounded-none border-0 border-l border-border " + (
|
|
15284
|
-
onClick: () =>
|
|
15285
|
-
})) : null,
|
|
15451
|
+
className: "rounded-none border-0 border-l border-border " + (_e === "gallery" ? "bg-card text-foreground shadow-sm" : "bg-transparent text-muted-foreground"),
|
|
15452
|
+
onClick: () => ve("gallery")
|
|
15453
|
+
})) : null, Qe = he.columnPicker && _e === "table" ? /* @__PURE__ */ t.createElement(Ii, {
|
|
15286
15454
|
trigger: {
|
|
15287
15455
|
icon: "columns",
|
|
15288
15456
|
title: "Columns"
|
|
@@ -15296,122 +15464,122 @@ function Xp({ records: e, recordId: n, sourcePath: r, columns: i, actions: a, fo
|
|
|
15296
15464
|
className: "flex cursor-pointer items-center gap-2 px-3 py-1.5 text-sm hover:bg-accent"
|
|
15297
15465
|
}, /* @__PURE__ */ t.createElement("input", {
|
|
15298
15466
|
type: "checkbox",
|
|
15299
|
-
checked: !
|
|
15300
|
-
onChange: () =>
|
|
15467
|
+
checked: !ye.has(n),
|
|
15468
|
+
onChange: () => xe(n)
|
|
15301
15469
|
}), e.label);
|
|
15302
|
-
})) : null,
|
|
15470
|
+
})) : null, $e = ge.fieldPicker && _e === "gallery" && Ce.length ? /* @__PURE__ */ t.createElement(Ii, {
|
|
15303
15471
|
trigger: {
|
|
15304
15472
|
icon: "sliders-horizontal",
|
|
15305
15473
|
title: "Fields"
|
|
15306
15474
|
},
|
|
15307
15475
|
triggerClassName: "btn btn-outline-secondary",
|
|
15308
15476
|
position: "end"
|
|
15309
|
-
},
|
|
15477
|
+
}, Ce.map((e) => {
|
|
15310
15478
|
let n = String(e.key);
|
|
15311
15479
|
return /* @__PURE__ */ t.createElement("label", {
|
|
15312
15480
|
key: n,
|
|
15313
15481
|
className: "flex cursor-pointer items-center gap-2 px-3 py-1.5 text-sm hover:bg-accent"
|
|
15314
15482
|
}, /* @__PURE__ */ t.createElement("input", {
|
|
15315
15483
|
type: "checkbox",
|
|
15316
|
-
checked: !
|
|
15317
|
-
onChange: () =>
|
|
15484
|
+
checked: !we.has(n),
|
|
15485
|
+
onChange: () => Ee(n)
|
|
15318
15486
|
}), e.label);
|
|
15319
|
-
})) : null,
|
|
15320
|
-
if (u !== void 0) return typeof u == "function" ? u(
|
|
15321
|
-
if (!(!x && !
|
|
15487
|
+
})) : null, et = p(() => {
|
|
15488
|
+
if (u !== void 0) return typeof u == "function" ? u(Ye) : u;
|
|
15489
|
+
if (!(!x && !pe && !ce && !Je.length && !Ze && !Qe && !$e)) return /* @__PURE__ */ t.createElement(t.Fragment, null, pe || ce ? /* @__PURE__ */ t.createElement("span", { className: "flex min-w-0 flex-1 items-center gap-3" }, x, pe, ce) : x || /* @__PURE__ */ t.createElement("span", null), Je.length || Ze || Qe || $e ? /* @__PURE__ */ t.createElement("span", { className: "flex flex-wrap items-center gap-2" }, Qe, $e, Ze, Je.map((e) => /* @__PURE__ */ t.createElement(t.Fragment, { key: e }, qe(e)))) : null);
|
|
15322
15490
|
}, [
|
|
15323
|
-
|
|
15491
|
+
qe,
|
|
15324
15492
|
u,
|
|
15325
|
-
|
|
15326
|
-
|
|
15493
|
+
Je,
|
|
15494
|
+
Ye,
|
|
15327
15495
|
x,
|
|
15328
|
-
|
|
15329
|
-
|
|
15330
|
-
|
|
15331
|
-
|
|
15332
|
-
|
|
15333
|
-
]),
|
|
15334
|
-
if (d !== void 0) return typeof d == "function" ? d(
|
|
15335
|
-
}, [d,
|
|
15336
|
-
if (!(!
|
|
15496
|
+
Ze,
|
|
15497
|
+
Qe,
|
|
15498
|
+
$e,
|
|
15499
|
+
pe,
|
|
15500
|
+
ce
|
|
15501
|
+
]), tt = p(() => {
|
|
15502
|
+
if (d !== void 0) return typeof d == "function" ? d(Xe) : d;
|
|
15503
|
+
}, [d, Xe]), nt = p(() => {
|
|
15504
|
+
if (!(!Pe || !J || J.kind !== "modal" && J.kind !== "delete")) return Be(Pe.actionKey, Pe.record);
|
|
15337
15505
|
}, [
|
|
15338
|
-
|
|
15506
|
+
Pe,
|
|
15339
15507
|
J,
|
|
15340
|
-
|
|
15341
|
-
]),
|
|
15342
|
-
if (!(!J || J.kind !== "modal" && J.kind !== "delete" || J.header === void 0 || !
|
|
15343
|
-
}, [J,
|
|
15508
|
+
Be
|
|
15509
|
+
]), rt = p(() => {
|
|
15510
|
+
if (!(!J || J.kind !== "modal" && J.kind !== "delete" || J.header === void 0 || !nt)) return typeof J.header == "function" ? J.header(nt) : J.header;
|
|
15511
|
+
}, [J, nt]), it = p(() => {
|
|
15344
15512
|
if (!(!J || J.kind !== "modal" && J.kind !== "delete")) {
|
|
15345
15513
|
if (J.footer === !1) return !1;
|
|
15346
|
-
if (!(J.footer === void 0 || !
|
|
15514
|
+
if (!(J.footer === void 0 || !nt)) return typeof J.footer == "function" ? J.footer(nt) : J.footer;
|
|
15347
15515
|
}
|
|
15348
|
-
}, [J,
|
|
15516
|
+
}, [J, nt]), at = Zf(w);
|
|
15349
15517
|
return /* @__PURE__ */ t.createElement(t.Fragment, null, /* @__PURE__ */ t.createElement(ki, {
|
|
15350
15518
|
wrapperClassName: _,
|
|
15351
|
-
header:
|
|
15352
|
-
footer:
|
|
15519
|
+
header: et,
|
|
15520
|
+
footer: tt,
|
|
15353
15521
|
className: X(R.Grid.Card.className, g ? `sticky-${g}` : "", v),
|
|
15354
15522
|
headerClassName: R.Grid.Card.headerClassName,
|
|
15355
15523
|
bodyClassName: X(R.Grid.Card.bodyClassName, y),
|
|
15356
15524
|
footerClassName: R.Grid.Card.footerClassName,
|
|
15357
15525
|
loading: b || W
|
|
15358
|
-
},
|
|
15359
|
-
records:
|
|
15526
|
+
}, _e === "gallery" ? /* @__PURE__ */ t.createElement(Wp, {
|
|
15527
|
+
records: q,
|
|
15360
15528
|
recordId: n,
|
|
15361
|
-
sortable:
|
|
15529
|
+
sortable: at || w,
|
|
15362
15530
|
pagination: T,
|
|
15363
|
-
selection:
|
|
15364
|
-
selectedKeys:
|
|
15365
|
-
onSelectionChange:
|
|
15366
|
-
onRowClick:
|
|
15531
|
+
selection: ke,
|
|
15532
|
+
selectedKeys: Ae,
|
|
15533
|
+
onSelectionChange: ke ? Me : void 0,
|
|
15534
|
+
onRowClick: Ke,
|
|
15367
15535
|
groupBy: A,
|
|
15368
15536
|
wrapperClassName: R.Grid.Gallery.wrapperClassName,
|
|
15369
15537
|
before: S,
|
|
15370
15538
|
after: C,
|
|
15371
|
-
columns:
|
|
15372
|
-
overlays:
|
|
15539
|
+
columns: ge.columns,
|
|
15540
|
+
overlays: Oe
|
|
15373
15541
|
}) : /* @__PURE__ */ t.createElement(Qf, {
|
|
15374
|
-
records:
|
|
15542
|
+
records: q,
|
|
15375
15543
|
recordId: n,
|
|
15376
|
-
columns:
|
|
15377
|
-
runAction:
|
|
15378
|
-
sortable:
|
|
15544
|
+
columns: Se,
|
|
15545
|
+
runAction: Le,
|
|
15546
|
+
sortable: at || w,
|
|
15379
15547
|
pagination: T,
|
|
15380
|
-
selection:
|
|
15381
|
-
selectedKeys:
|
|
15382
|
-
onSelectionChange:
|
|
15383
|
-
onRowClick:
|
|
15548
|
+
selection: ke,
|
|
15549
|
+
selectedKeys: Ae,
|
|
15550
|
+
onSelectionChange: ke ? Me : void 0,
|
|
15551
|
+
onRowClick: Ke,
|
|
15384
15552
|
reorderable: O,
|
|
15385
15553
|
onReorder: k,
|
|
15386
|
-
activeKey:
|
|
15554
|
+
activeKey: Ie,
|
|
15387
15555
|
groupBy: A,
|
|
15388
15556
|
wrapperClassName: R.Grid.Table.wrapperClassName,
|
|
15389
|
-
className:
|
|
15390
|
-
heightClassName:
|
|
15391
|
-
scrollClassName:
|
|
15392
|
-
headerClassName:
|
|
15557
|
+
className: he.className,
|
|
15558
|
+
heightClassName: he.heightClassName,
|
|
15559
|
+
scrollClassName: he.scrollClassName,
|
|
15560
|
+
headerClassName: he.headerClassName,
|
|
15393
15561
|
before: S,
|
|
15394
15562
|
after: C
|
|
15395
|
-
})),
|
|
15563
|
+
})), le, Pe && J && (J.kind === "modal" || J.kind === "delete") && /* @__PURE__ */ t.createElement(Ai, {
|
|
15396
15564
|
size: (J.kind === "modal" || J.kind === "delete") && J.size || R.Grid.Modal.size,
|
|
15397
15565
|
position: (J.kind === "modal" || J.kind === "delete") && J.position || R.Grid.Modal.position,
|
|
15398
|
-
header:
|
|
15399
|
-
title: Yp(
|
|
15400
|
-
onClose:
|
|
15401
|
-
onSave: J.kind === "modal" && J.footer === void 0 && (
|
|
15566
|
+
header: rt,
|
|
15567
|
+
title: Yp(Pe.actionKey, J, J.kind === "modal" || J.kind === "delete" ? Be(Pe.actionKey, Pe.record) : ze(Pe.actionKey, Pe.record), z.deleteConfirm, V),
|
|
15568
|
+
onClose: Re,
|
|
15569
|
+
onSave: J.kind === "modal" && J.footer === void 0 && (Pe.actionKey === "add" || Pe.actionKey === "edit") ? (e) => He.save(e) : void 0,
|
|
15402
15570
|
onDelete: J.kind === "delete" ? async () => {
|
|
15403
|
-
let e =
|
|
15571
|
+
let e = Pe.record;
|
|
15404
15572
|
if (!e) return !1;
|
|
15405
|
-
let t = P ? await P({ record: e }) : r ? `${r}/${
|
|
15573
|
+
let t = P ? await P({ record: e }) : r ? `${r}/${Ve(e)}` : void 0;
|
|
15406
15574
|
if (!t && !P) return !1;
|
|
15407
15575
|
t && await H.remove(t);
|
|
15408
15576
|
let n = await F?.({
|
|
15409
15577
|
record: e,
|
|
15410
15578
|
action: "delete"
|
|
15411
15579
|
}) ?? !0;
|
|
15412
|
-
return n &&
|
|
15413
|
-
} : J.kind === "modal" && J.footer === void 0 &&
|
|
15414
|
-
footer:
|
|
15580
|
+
return n && Re(), n;
|
|
15581
|
+
} : J.kind === "modal" && J.footer === void 0 && Pe.actionKey === "edit" && Pe.record && Ne.delete ? async () => (await Be(Pe.actionKey, Pe.record).runAction("remove"), !1) : void 0,
|
|
15582
|
+
footer: it,
|
|
15415
15583
|
showCancel: J.kind === "modal" || J.kind === "delete" ? J.footer === void 0 : !0,
|
|
15416
15584
|
allowFullscreen: J.kind === "modal" || J.kind === "delete" ? J.allowFullscreen : !0,
|
|
15417
15585
|
wrapperClassName: R.Grid.Modal.wrapperClassName,
|
|
@@ -15420,22 +15588,22 @@ function Xp({ records: e, recordId: n, sourcePath: r, columns: i, actions: a, fo
|
|
|
15420
15588
|
titleClassName: R.Grid.Modal.titleClassName,
|
|
15421
15589
|
bodyClassName: R.Grid.Modal.bodyClassName,
|
|
15422
15590
|
footerClassName: R.Grid.Modal.footerClassName
|
|
15423
|
-
},
|
|
15591
|
+
}, Fe));
|
|
15424
15592
|
}
|
|
15425
15593
|
//#endregion
|
|
15426
15594
|
//#region src/components/widgets/grid-core/GridArray.tsx
|
|
15427
|
-
function
|
|
15428
|
-
return /* @__PURE__ */ t.createElement(
|
|
15595
|
+
function rm(e) {
|
|
15596
|
+
return /* @__PURE__ */ t.createElement(nm, e);
|
|
15429
15597
|
}
|
|
15430
15598
|
//#endregion
|
|
15431
15599
|
//#region src/components/widgets/Grid.tsx
|
|
15432
|
-
function
|
|
15433
|
-
return "records" in e ? /* @__PURE__ */ t.createElement(
|
|
15600
|
+
function im(e) {
|
|
15601
|
+
return "records" in e ? /* @__PURE__ */ t.createElement(rm, e) : /* @__PURE__ */ t.createElement(zf, e);
|
|
15434
15602
|
}
|
|
15435
15603
|
//#endregion
|
|
15436
15604
|
//#region src/pages/Users.tsx
|
|
15437
|
-
function
|
|
15438
|
-
return /* @__PURE__ */ t.createElement(
|
|
15605
|
+
function am() {
|
|
15606
|
+
return /* @__PURE__ */ t.createElement(im, {
|
|
15439
15607
|
path: "/users",
|
|
15440
15608
|
recordId: (e) => `${e.email ?? ""}`.replace("@", "-"),
|
|
15441
15609
|
form: /* @__PURE__ */ t.createElement(t.Fragment, null, /* @__PURE__ */ t.createElement(gs, {
|
|
@@ -15462,10 +15630,10 @@ function $p() {
|
|
|
15462
15630
|
}
|
|
15463
15631
|
//#endregion
|
|
15464
15632
|
//#region src/pages/NotFound.tsx
|
|
15465
|
-
var
|
|
15633
|
+
var om = () => {
|
|
15466
15634
|
let e = Nn("common");
|
|
15467
15635
|
return /* @__PURE__ */ t.createElement("div", { className: "flex flex-col justify-center items-center vh-100" }, /* @__PURE__ */ t.createElement("h1", null, "404"), /* @__PURE__ */ t.createElement("p", null, e.notFoundMessage), /* @__PURE__ */ t.createElement(v, { to: "/" }, /* @__PURE__ */ t.createElement(Q, { name: "house-door" }), " ", e.goHome));
|
|
15468
|
-
},
|
|
15636
|
+
}, sm = ({ size: e = 28 }) => /* @__PURE__ */ t.createElement("svg", {
|
|
15469
15637
|
xmlns: "http://www.w3.org/2000/svg",
|
|
15470
15638
|
width: e,
|
|
15471
15639
|
height: e,
|
|
@@ -15485,7 +15653,7 @@ var em = () => {
|
|
|
15485
15653
|
x2: "12.01",
|
|
15486
15654
|
y1: "17",
|
|
15487
15655
|
y2: "17"
|
|
15488
|
-
})),
|
|
15656
|
+
})), cm = ({ open: e }) => /* @__PURE__ */ t.createElement("svg", {
|
|
15489
15657
|
xmlns: "http://www.w3.org/2000/svg",
|
|
15490
15658
|
width: "13",
|
|
15491
15659
|
height: "13",
|
|
@@ -15500,7 +15668,7 @@ var em = () => {
|
|
|
15500
15668
|
transform: e ? "rotate(180deg)" : "none",
|
|
15501
15669
|
flexShrink: 0
|
|
15502
15670
|
}
|
|
15503
|
-
}, /* @__PURE__ */ t.createElement("polyline", { points: "6 9 12 15 18 9" })),
|
|
15671
|
+
}, /* @__PURE__ */ t.createElement("polyline", { points: "6 9 12 15 18 9" })), lm = () => /* @__PURE__ */ t.createElement("svg", {
|
|
15504
15672
|
xmlns: "http://www.w3.org/2000/svg",
|
|
15505
15673
|
width: "13",
|
|
15506
15674
|
height: "13",
|
|
@@ -15517,7 +15685,7 @@ var em = () => {
|
|
|
15517
15685
|
y: "8",
|
|
15518
15686
|
rx: "2",
|
|
15519
15687
|
ry: "2"
|
|
15520
|
-
}), /* @__PURE__ */ t.createElement("path", { d: "M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2" })),
|
|
15688
|
+
}), /* @__PURE__ */ t.createElement("path", { d: "M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2" })), um = () => /* @__PURE__ */ t.createElement("svg", {
|
|
15521
15689
|
xmlns: "http://www.w3.org/2000/svg",
|
|
15522
15690
|
width: "13",
|
|
15523
15691
|
height: "13",
|
|
@@ -15527,7 +15695,7 @@ var em = () => {
|
|
|
15527
15695
|
strokeWidth: "2",
|
|
15528
15696
|
strokeLinecap: "round",
|
|
15529
15697
|
strokeLinejoin: "round"
|
|
15530
|
-
}, /* @__PURE__ */ t.createElement("path", { d: "m22 2-7 20-4-9-9-4Z" }), /* @__PURE__ */ t.createElement("path", { d: "M22 2 11 13" })),
|
|
15698
|
+
}, /* @__PURE__ */ t.createElement("path", { d: "m22 2-7 20-4-9-9-4Z" }), /* @__PURE__ */ t.createElement("path", { d: "M22 2 11 13" })), dm = () => /* @__PURE__ */ t.createElement("svg", {
|
|
15531
15699
|
xmlns: "http://www.w3.org/2000/svg",
|
|
15532
15700
|
width: "14",
|
|
15533
15701
|
height: "14",
|
|
@@ -15537,7 +15705,7 @@ var em = () => {
|
|
|
15537
15705
|
strokeWidth: "2",
|
|
15538
15706
|
strokeLinecap: "round",
|
|
15539
15707
|
strokeLinejoin: "round"
|
|
15540
|
-
}, /* @__PURE__ */ t.createElement("path", { d: "m8 2 1.88 1.88M14.12 3.88 16 2" }), /* @__PURE__ */ t.createElement("path", { d: "M9 7.13v-1a3.003 3.003 0 1 1 6 0v1" }), /* @__PURE__ */ t.createElement("path", { d: "M12 20c-3.3 0-6-2.7-6-6v-3a4 4 0 0 1 4-4h4a4 4 0 0 1 4 4v3c0 3.3-2.7 6-6 6z" }), /* @__PURE__ */ t.createElement("path", { d: "M12 20v-9" }), /* @__PURE__ */ t.createElement("path", { d: "M6.53 9C4.6 8.8 3 7.1 3 5" }), /* @__PURE__ */ t.createElement("path", { d: "M6 13H2" }), /* @__PURE__ */ t.createElement("path", { d: "M3 21c0-2.1 1.7-3.9 3.8-4" }), /* @__PURE__ */ t.createElement("path", { d: "M20.97 5c0 2.1-1.6 3.8-3.5 4" }), /* @__PURE__ */ t.createElement("path", { d: "M22 13h-4" }), /* @__PURE__ */ t.createElement("path", { d: "M17.2 17c2.1.1 3.8 1.9 3.8 4" })),
|
|
15708
|
+
}, /* @__PURE__ */ t.createElement("path", { d: "m8 2 1.88 1.88M14.12 3.88 16 2" }), /* @__PURE__ */ t.createElement("path", { d: "M9 7.13v-1a3.003 3.003 0 1 1 6 0v1" }), /* @__PURE__ */ t.createElement("path", { d: "M12 20c-3.3 0-6-2.7-6-6v-3a4 4 0 0 1 4-4h4a4 4 0 0 1 4 4v3c0 3.3-2.7 6-6 6z" }), /* @__PURE__ */ t.createElement("path", { d: "M12 20v-9" }), /* @__PURE__ */ t.createElement("path", { d: "M6.53 9C4.6 8.8 3 7.1 3 5" }), /* @__PURE__ */ t.createElement("path", { d: "M6 13H2" }), /* @__PURE__ */ t.createElement("path", { d: "M3 21c0-2.1 1.7-3.9 3.8-4" }), /* @__PURE__ */ t.createElement("path", { d: "M20.97 5c0 2.1-1.6 3.8-3.5 4" }), /* @__PURE__ */ t.createElement("path", { d: "M22 13h-4" }), /* @__PURE__ */ t.createElement("path", { d: "M17.2 17c2.1.1 3.8 1.9 3.8 4" })), fm = (e, t) => ({
|
|
15541
15709
|
error: {
|
|
15542
15710
|
message: e.message,
|
|
15543
15711
|
stack: e.stack ?? ""
|
|
@@ -15548,8 +15716,8 @@ var em = () => {
|
|
|
15548
15716
|
userAgent: typeof navigator < "u" ? navigator.userAgent : "",
|
|
15549
15717
|
timestamp: (/* @__PURE__ */ new Date()).toISOString()
|
|
15550
15718
|
}
|
|
15551
|
-
}),
|
|
15552
|
-
let n =
|
|
15719
|
+
}), pm = (e, t) => {
|
|
15720
|
+
let n = fm(e, t);
|
|
15553
15721
|
return [
|
|
15554
15722
|
`Error: ${n.error.message}`,
|
|
15555
15723
|
"",
|
|
@@ -15564,7 +15732,7 @@ var em = () => {
|
|
|
15564
15732
|
`Timestamp: ${n.context.timestamp}`,
|
|
15565
15733
|
`Agent: ${n.context.userAgent}`
|
|
15566
15734
|
].join("\n");
|
|
15567
|
-
},
|
|
15735
|
+
}, mm = class extends t.Component {
|
|
15568
15736
|
constructor(e) {
|
|
15569
15737
|
super(e), this.state = {
|
|
15570
15738
|
error: null,
|
|
@@ -15586,7 +15754,7 @@ var em = () => {
|
|
|
15586
15754
|
};
|
|
15587
15755
|
copy = () => {
|
|
15588
15756
|
let { error: e, errorInfo: t } = this.state;
|
|
15589
|
-
e && navigator.clipboard?.writeText(
|
|
15757
|
+
e && navigator.clipboard?.writeText(pm(e, t)).then(() => {
|
|
15590
15758
|
this.setState({ copied: !0 }), setTimeout(() => this.setState({ copied: !1 }), 2e3);
|
|
15591
15759
|
});
|
|
15592
15760
|
};
|
|
@@ -15595,7 +15763,7 @@ var em = () => {
|
|
|
15595
15763
|
!e || !n || (this.setState({ reportState: "sending" }), fetch(n, {
|
|
15596
15764
|
method: "POST",
|
|
15597
15765
|
headers: { "Content-Type": "application/json" },
|
|
15598
|
-
body: JSON.stringify(
|
|
15766
|
+
body: JSON.stringify(fm(e, t))
|
|
15599
15767
|
}).then((e) => this.setState({ reportState: e.ok ? "sent" : "failed" })).catch(() => this.setState({ reportState: "failed" })));
|
|
15600
15768
|
};
|
|
15601
15769
|
render() {
|
|
@@ -15605,16 +15773,16 @@ var em = () => {
|
|
|
15605
15773
|
if (typeof s == "function") return s(e, this.reset);
|
|
15606
15774
|
if (s != null) return s;
|
|
15607
15775
|
let d = (e.stack ?? e.message).split("\n").map((e) => e.trim()).filter(Boolean), f = (n?.componentStack ?? "").split("\n").map((e) => e.trim()).filter(Boolean), p = l ? "flex min-h-screen flex-col items-center justify-center bg-background p-8" : "flex min-h-[calc(100vh-4rem)] flex-col items-center justify-center p-8";
|
|
15608
|
-
return /* @__PURE__ */ t.createElement("div", { className: p }, /* @__PURE__ */ t.createElement("div", { className: "flex w-full max-w-xl flex-col gap-4 rounded-xl border border-destructive/25 bg-destructive/5 p-6" }, /* @__PURE__ */ t.createElement("div", { className: "flex items-start gap-4" }, /* @__PURE__ */ t.createElement("div", { className: "flex h-11 w-11 shrink-0 items-center justify-center rounded-full bg-destructive/12 text-destructive" }, /* @__PURE__ */ t.createElement(
|
|
15776
|
+
return /* @__PURE__ */ t.createElement("div", { className: p }, /* @__PURE__ */ t.createElement("div", { className: "flex w-full max-w-xl flex-col gap-4 rounded-xl border border-destructive/25 bg-destructive/5 p-6" }, /* @__PURE__ */ t.createElement("div", { className: "flex items-start gap-4" }, /* @__PURE__ */ t.createElement("div", { className: "flex h-11 w-11 shrink-0 items-center justify-center rounded-full bg-destructive/12 text-destructive" }, /* @__PURE__ */ t.createElement(sm, { size: 22 })), /* @__PURE__ */ t.createElement("div", null, /* @__PURE__ */ t.createElement("p", { className: "text-sm font-semibold text-foreground" }, "This page ran into a problem"), /* @__PURE__ */ t.createElement("p", { className: "mt-0.5 text-xs text-muted-foreground" }, "An unexpected error occurred while rendering this content."))), /* @__PURE__ */ t.createElement("div", { className: "rounded-lg border bg-background/60" }, /* @__PURE__ */ t.createElement("button", {
|
|
15609
15777
|
onClick: () => this.setState((e) => ({ detailsOpen: !e.detailsOpen })),
|
|
15610
15778
|
className: "flex w-full items-center gap-2 px-3 py-2.5 text-left text-xs font-medium text-muted-foreground transition-colors hover:text-foreground"
|
|
15611
|
-
}, /* @__PURE__ */ t.createElement(
|
|
15779
|
+
}, /* @__PURE__ */ t.createElement(cm, { open: r }), "Technical details", /* @__PURE__ */ t.createElement("span", { className: "ml-auto truncate max-w-[280px] font-mono text-[11px] text-muted-foreground/70" }, e.message)), r && /* @__PURE__ */ t.createElement("div", { className: "border-t" }, /* @__PURE__ */ t.createElement("pre", { className: "max-h-48 overflow-y-auto px-3 py-3 text-[11px] leading-relaxed text-muted-foreground font-mono whitespace-before-wrap break-all" }, d.join("\n")))), u && /* @__PURE__ */ t.createElement("div", { className: "rounded-lg border border-amber-200/60 bg-amber-50/40 dark:border-amber-900/40 dark:bg-amber-950/20" }, /* @__PURE__ */ t.createElement("button", {
|
|
15612
15780
|
onClick: () => this.setState((e) => ({ debugOpen: !e.debugOpen })),
|
|
15613
15781
|
className: "flex w-full items-center gap-2 px-3 py-2.5 text-left text-xs font-medium text-amber-700 dark:text-amber-400 transition-colors hover:opacity-80"
|
|
15614
|
-
}, /* @__PURE__ */ t.createElement(
|
|
15782
|
+
}, /* @__PURE__ */ t.createElement(dm, null), /* @__PURE__ */ t.createElement(cm, { open: i }), "Debug information", /* @__PURE__ */ t.createElement("span", { className: "ml-auto text-[10px] font-normal opacity-60" }, "DEV")), i && /* @__PURE__ */ t.createElement("div", { className: "border-t border-amber-200/60 dark:border-amber-900/40 px-3 py-3 space-y-3" }, /* @__PURE__ */ t.createElement("div", { className: "space-y-1" }, /* @__PURE__ */ t.createElement("p", { className: "text-[10px] font-semibold uppercase tracking-wide text-amber-700/70 dark:text-amber-400/70" }, "Context"), /* @__PURE__ */ t.createElement("dl", { className: "grid grid-cols-[5rem_1fr] gap-x-2 gap-y-0.5 text-[11px] font-mono" }, /* @__PURE__ */ t.createElement("dt", { className: "text-muted-foreground" }, "URL"), /* @__PURE__ */ t.createElement("dd", { className: "truncate text-foreground" }, typeof window < "u" ? window.location.href : "-"), /* @__PURE__ */ t.createElement("dt", { className: "text-muted-foreground" }, "Time"), /* @__PURE__ */ t.createElement("dd", { className: "text-foreground" }, (/* @__PURE__ */ new Date()).toISOString()), /* @__PURE__ */ t.createElement("dt", { className: "text-muted-foreground" }, "Agent"), /* @__PURE__ */ t.createElement("dd", { className: "truncate text-foreground opacity-70" }, typeof navigator < "u" ? navigator.userAgent : "-"))), f.length > 0 && /* @__PURE__ */ t.createElement("div", { className: "space-y-1" }, /* @__PURE__ */ t.createElement("p", { className: "text-[10px] font-semibold uppercase tracking-wide text-amber-700/70 dark:text-amber-400/70" }, "Component tree"), /* @__PURE__ */ t.createElement("pre", { className: "max-h-36 overflow-y-auto text-[11px] font-mono leading-relaxed text-foreground/80 whitespace-before-wrap" }, f.join("\n"))), /* @__PURE__ */ t.createElement("button", {
|
|
15615
15783
|
onClick: this.copy,
|
|
15616
15784
|
className: "flex items-center gap-1.5 rounded border px-2.5 py-1 text-[11px] font-medium transition-colors hover:bg-accent"
|
|
15617
|
-
}, /* @__PURE__ */ t.createElement(
|
|
15785
|
+
}, /* @__PURE__ */ t.createElement(lm, null), a ? "Copied!" : "Copy debug info"))), /* @__PURE__ */ t.createElement("div", { className: "flex flex-wrap items-center gap-2" }, /* @__PURE__ */ t.createElement("button", {
|
|
15618
15786
|
onClick: this.reset,
|
|
15619
15787
|
className: "rounded-md border bg-background px-4 py-1.5 text-sm font-medium shadow-sm transition-colors hover:bg-accent"
|
|
15620
15788
|
}, "Try again"), /* @__PURE__ */ t.createElement("a", {
|
|
@@ -15624,15 +15792,15 @@ var em = () => {
|
|
|
15624
15792
|
onClick: this.sendReport,
|
|
15625
15793
|
disabled: o === "sending" || o === "sent",
|
|
15626
15794
|
className: "ml-auto flex items-center gap-1.5 rounded-md border px-4 py-1.5 text-sm font-medium transition-colors hover:bg-accent disabled:opacity-50"
|
|
15627
|
-
}, /* @__PURE__ */ t.createElement(
|
|
15795
|
+
}, /* @__PURE__ */ t.createElement(um, null), o === "idle" && "Send report", o === "sending" && "Sending...", o === "sent" && "Report sent ✓", o === "failed" && "Failed - retry"))));
|
|
15628
15796
|
}
|
|
15629
|
-
},
|
|
15797
|
+
}, hm = async () => {
|
|
15630
15798
|
window.google?.accounts?.id || (vt([{
|
|
15631
15799
|
src: "https://accounts.google.com/gsi/client",
|
|
15632
15800
|
async: !0,
|
|
15633
15801
|
clean: !0
|
|
15634
15802
|
}]), await new Promise((e) => setTimeout(e, 0)));
|
|
15635
|
-
},
|
|
15803
|
+
}, gm = class {
|
|
15636
15804
|
getConfigurationState() {
|
|
15637
15805
|
return ii("GoogleAuthProvider", ri(Ea("oAuth2"), ["clientId"], "google.oAuth2."));
|
|
15638
15806
|
}
|
|
@@ -15655,7 +15823,7 @@ var em = () => {
|
|
|
15655
15823
|
async signIn(e = {}) {
|
|
15656
15824
|
let t = Ea("oAuth2");
|
|
15657
15825
|
if (!this.isConfigured() || !t?.clientId) throw Error("GoogleAuthProvider: missing google.oAuth2.clientId configuration.");
|
|
15658
|
-
return await
|
|
15826
|
+
return await hm(), new Promise((n, r) => {
|
|
15659
15827
|
if (!window.google?.accounts?.id) {
|
|
15660
15828
|
r(/* @__PURE__ */ Error("GoogleAuthProvider: Google Identity Services script is not available."));
|
|
15661
15829
|
return;
|
|
@@ -15736,41 +15904,41 @@ var em = () => {
|
|
|
15736
15904
|
isAuthenticated() {
|
|
15737
15905
|
return !!this.getUser();
|
|
15738
15906
|
}
|
|
15739
|
-
},
|
|
15907
|
+
}, _m = a(null), vm = ({ registry: e, defaultKey: n, children: r }) => {
|
|
15740
15908
|
let i = p(() => ({
|
|
15741
15909
|
registry: e,
|
|
15742
15910
|
defaultKey: n
|
|
15743
15911
|
}), [e, n]);
|
|
15744
|
-
return /* @__PURE__ */ t.createElement(
|
|
15745
|
-
},
|
|
15746
|
-
let t = c(
|
|
15912
|
+
return /* @__PURE__ */ t.createElement(_m.Provider, { value: i }, r);
|
|
15913
|
+
}, ym = (e) => {
|
|
15914
|
+
let t = c(_m);
|
|
15747
15915
|
if (!t) return null;
|
|
15748
15916
|
let n = e ?? t.defaultKey;
|
|
15749
15917
|
return t.registry[n] ?? null;
|
|
15750
|
-
},
|
|
15918
|
+
}, bm = a(null), xm = ({ registry: e, defaultKey: n, children: r }) => {
|
|
15751
15919
|
let i = p(() => ({
|
|
15752
15920
|
registry: e,
|
|
15753
15921
|
defaultKey: n
|
|
15754
15922
|
}), [e, n]);
|
|
15755
|
-
return /* @__PURE__ */ t.createElement(
|
|
15756
|
-
},
|
|
15757
|
-
let t = c(
|
|
15923
|
+
return /* @__PURE__ */ t.createElement(bm.Provider, { value: i }, r);
|
|
15924
|
+
}, Sm = (e) => {
|
|
15925
|
+
let t = c(bm);
|
|
15758
15926
|
if (!t) throw Error("useCredentialsProvider must be used inside <App providers={...} />.");
|
|
15759
15927
|
let n = e ?? t.defaultKey, r = t.registry[n];
|
|
15760
15928
|
if (!r) throw Error(`CredentialsProvider '${n}' is not registered. Available: ${Object.keys(t.registry).join(", ")}`);
|
|
15761
15929
|
return r;
|
|
15762
|
-
},
|
|
15930
|
+
}, Cm = {
|
|
15763
15931
|
key: "@key",
|
|
15764
15932
|
value: "@value"
|
|
15765
|
-
},
|
|
15933
|
+
}, wm = () => Ie(), Tm = (e, t, n) => {
|
|
15766
15934
|
let r = `Error during ${e}: ${String(t)}`;
|
|
15767
15935
|
if (n) throw Error(r);
|
|
15768
15936
|
console.error(r);
|
|
15769
|
-
},
|
|
15937
|
+
}, Em = (e, t) => {
|
|
15770
15938
|
if (!e || !(t in e)) return e;
|
|
15771
15939
|
let { [t]: n, ...r } = e;
|
|
15772
15940
|
return Object.keys(r).length ? r : void 0;
|
|
15773
|
-
},
|
|
15941
|
+
}, Dm = (e) => {
|
|
15774
15942
|
let t = typeof e == "object" && e && !Array.isArray(e) ? e : Array.isArray(e) ? { in: e } : { eq: e }, n;
|
|
15775
15943
|
return t.gt !== void 0 && (n = {
|
|
15776
15944
|
...n,
|
|
@@ -15788,40 +15956,40 @@ var em = () => {
|
|
|
15788
15956
|
condition: t,
|
|
15789
15957
|
clientCondition: n
|
|
15790
15958
|
};
|
|
15791
|
-
},
|
|
15959
|
+
}, Om = (e, t) => {
|
|
15792
15960
|
switch (t) {
|
|
15793
|
-
case
|
|
15794
|
-
case
|
|
15961
|
+
case Cm.key: return Ve(e, ze());
|
|
15962
|
+
case Cm.value: return Ve(e, Be());
|
|
15795
15963
|
default: return Ve(e, Re(t));
|
|
15796
15964
|
}
|
|
15797
|
-
},
|
|
15965
|
+
}, km = (e, t, n) => {
|
|
15798
15966
|
let [r] = Object.entries(t || {});
|
|
15799
15967
|
if (!r) return {
|
|
15800
15968
|
dbRef: e,
|
|
15801
15969
|
clientWhere: n
|
|
15802
15970
|
};
|
|
15803
|
-
let [i] = r, a =
|
|
15971
|
+
let [i] = r, a = Om(e, i), o = n?.[i];
|
|
15804
15972
|
if (o == null) return {
|
|
15805
15973
|
dbRef: a,
|
|
15806
15974
|
clientWhere: n
|
|
15807
15975
|
};
|
|
15808
|
-
let { condition: s, clientCondition: c } =
|
|
15976
|
+
let { condition: s, clientCondition: c } = Dm(o);
|
|
15809
15977
|
switch (!0) {
|
|
15810
15978
|
case s.eq !== void 0: return {
|
|
15811
|
-
dbRef: Ve(a,
|
|
15812
|
-
clientWhere:
|
|
15979
|
+
dbRef: Ve(a, J(s.eq)),
|
|
15980
|
+
clientWhere: Em(n, i)
|
|
15813
15981
|
};
|
|
15814
15982
|
case s.gte !== void 0 && s.lte !== void 0:
|
|
15815
|
-
a = Ve(a, Ge(s.gte),
|
|
15983
|
+
a = Ve(a, Ge(s.gte), Pe(s.lte));
|
|
15816
15984
|
break;
|
|
15817
15985
|
case s.gte !== void 0 && s.lt !== void 0:
|
|
15818
|
-
a = Ve(a, Ge(s.gte),
|
|
15986
|
+
a = Ve(a, Ge(s.gte), Pe(s.lt));
|
|
15819
15987
|
break;
|
|
15820
15988
|
case s.gt !== void 0 && s.lte !== void 0:
|
|
15821
|
-
a = Ve(a, Ge(s.gt),
|
|
15989
|
+
a = Ve(a, Ge(s.gt), Pe(s.lte));
|
|
15822
15990
|
break;
|
|
15823
15991
|
case s.gt !== void 0 && s.lt !== void 0:
|
|
15824
|
-
a = Ve(a, Ge(s.gt),
|
|
15992
|
+
a = Ve(a, Ge(s.gt), Pe(s.lt));
|
|
15825
15993
|
break;
|
|
15826
15994
|
case s.gte !== void 0:
|
|
15827
15995
|
a = Ve(a, Ge(s.gte));
|
|
@@ -15830,20 +15998,20 @@ var em = () => {
|
|
|
15830
15998
|
a = Ve(a, Ge(s.gt));
|
|
15831
15999
|
break;
|
|
15832
16000
|
case s.lte !== void 0:
|
|
15833
|
-
a = Ve(a,
|
|
16001
|
+
a = Ve(a, Pe(s.lte));
|
|
15834
16002
|
break;
|
|
15835
16003
|
case s.lt !== void 0:
|
|
15836
|
-
a = Ve(a,
|
|
16004
|
+
a = Ve(a, Pe(s.lt));
|
|
15837
16005
|
break;
|
|
15838
16006
|
}
|
|
15839
16007
|
return {
|
|
15840
16008
|
dbRef: a,
|
|
15841
16009
|
clientWhere: c ? {
|
|
15842
|
-
...
|
|
16010
|
+
...Em(n, i) || {},
|
|
15843
16011
|
[i]: c
|
|
15844
|
-
} :
|
|
16012
|
+
} : Em(n, i)
|
|
15845
16013
|
};
|
|
15846
|
-
},
|
|
16014
|
+
}, Am = (e, t) => {
|
|
15847
16015
|
if (!t) return e;
|
|
15848
16016
|
let n = t.split("."), r = e;
|
|
15849
16017
|
for (let e of n) {
|
|
@@ -15851,10 +16019,10 @@ var em = () => {
|
|
|
15851
16019
|
r = r[e];
|
|
15852
16020
|
}
|
|
15853
16021
|
return r;
|
|
15854
|
-
},
|
|
16022
|
+
}, jm = (e, t) => e === t ? 0 : e == null ? -1 : t == null ? 1 : typeof e == "number" && typeof t == "number" ? e - t : typeof e == "boolean" && typeof t == "boolean" ? Number(e) - Number(t) : globalThis.String(e).localeCompare(globalThis.String(t), void 0, {
|
|
15855
16023
|
numeric: !0,
|
|
15856
16024
|
sensitivity: "base"
|
|
15857
|
-
}),
|
|
16025
|
+
}), Mm = (e, t) => {
|
|
15858
16026
|
let n = typeof t == "object" && t && !Array.isArray(t) ? t : { eq: t };
|
|
15859
16027
|
for (let [t, r] of Object.entries(n)) switch (t) {
|
|
15860
16028
|
case "eq":
|
|
@@ -15881,23 +16049,23 @@ var em = () => {
|
|
|
15881
16049
|
default: return !1;
|
|
15882
16050
|
}
|
|
15883
16051
|
return !0;
|
|
15884
|
-
},
|
|
16052
|
+
}, Nm = (e, t, n) => {
|
|
15885
16053
|
let [r, ...i] = Object.entries(n || {}), a = Object.entries(t || {}), o = Object.entries(e);
|
|
15886
|
-
if (a.length && (o = o.filter(([, e]) => a.every(([t, n]) =>
|
|
16054
|
+
if (a.length && (o = o.filter(([, e]) => a.every(([t, n]) => Mm(Am(e, t), n)))), r) {
|
|
15887
16055
|
let e = [r, ...i];
|
|
15888
16056
|
o.sort((t, n) => {
|
|
15889
16057
|
for (let [r, i] of e) {
|
|
15890
|
-
let e =
|
|
16058
|
+
let e = jm(Am(t[1], r), Am(n[1], r));
|
|
15891
16059
|
if (e) return i === "desc" ? -e : e;
|
|
15892
16060
|
}
|
|
15893
16061
|
return 0;
|
|
15894
16062
|
});
|
|
15895
16063
|
}
|
|
15896
16064
|
return Object.fromEntries(o);
|
|
15897
|
-
},
|
|
15898
|
-
let t = await Na()?.currentUser?.getIdToken().catch(() => void 0), n = new URL(`${e}.json`, He(
|
|
16065
|
+
}, Pm = async (e) => {
|
|
16066
|
+
let t = await Na()?.currentUser?.getIdToken().catch(() => void 0), n = new URL(`${e}.json`, He(wm()).toString());
|
|
15899
16067
|
return n.searchParams.set("shallow", "true"), t && n.searchParams.set("auth", t), n.toString();
|
|
15900
|
-
},
|
|
16068
|
+
}, Fm = class e {
|
|
15901
16069
|
static listenerRegistered = !1;
|
|
15902
16070
|
constructor() {
|
|
15903
16071
|
!e.listenerRegistered && typeof Sa == "function" && (e.listenerRegistered = !0, Sa((e) => {
|
|
@@ -15912,43 +16080,43 @@ var em = () => {
|
|
|
15912
16080
|
}
|
|
15913
16081
|
readShallow = async (e, t = !1) => {
|
|
15914
16082
|
try {
|
|
15915
|
-
let t = await
|
|
16083
|
+
let t = await Pm(e), n = await fetch(t);
|
|
15916
16084
|
if (!n.ok) throw Error(`${n.status} ${n.statusText}`);
|
|
15917
16085
|
let r = await n.json();
|
|
15918
16086
|
return r ? Object.keys(r) : [];
|
|
15919
16087
|
} catch (n) {
|
|
15920
|
-
return
|
|
16088
|
+
return Tm(`reading SHALLOW data in Firebase for ${e}`, n, t), [];
|
|
15921
16089
|
}
|
|
15922
16090
|
};
|
|
15923
16091
|
read = async (e, { where: t, order: n, toArray: r = !1, exception: i = !1 } = {}) => {
|
|
15924
|
-
let { dbRef: a, clientWhere: o } =
|
|
16092
|
+
let { dbRef: a, clientWhere: o } = km(He(wm(), e), n, t);
|
|
15925
16093
|
try {
|
|
15926
16094
|
let t = await Fe(a);
|
|
15927
16095
|
if (t.exists()) {
|
|
15928
16096
|
`${e}`;
|
|
15929
|
-
let i =
|
|
16097
|
+
let i = Nm(t.val(), o, n);
|
|
15930
16098
|
return r ? Object.values(i) : i;
|
|
15931
|
-
} else i &&
|
|
16099
|
+
} else i && Tm(`Data not found in Firebase for path ${e}`, null, i);
|
|
15932
16100
|
} catch (t) {
|
|
15933
|
-
|
|
16101
|
+
Tm(`reading data in Firebase for ${e}`, t, i);
|
|
15934
16102
|
}
|
|
15935
16103
|
};
|
|
15936
16104
|
update = async (e, t, n = !1) => {
|
|
15937
16105
|
try {
|
|
15938
|
-
await Ke(He(
|
|
16106
|
+
await Ke(He(wm(), e), t), `${e}`;
|
|
15939
16107
|
} catch (t) {
|
|
15940
|
-
|
|
16108
|
+
Tm(`updating data in Firebase for ${e}`, t, n);
|
|
15941
16109
|
}
|
|
15942
16110
|
};
|
|
15943
16111
|
set = async (e, t, n = !1) => {
|
|
15944
16112
|
try {
|
|
15945
|
-
await We(He(
|
|
16113
|
+
await We(He(wm(), e), t), `${e}`;
|
|
15946
16114
|
} catch (t) {
|
|
15947
|
-
|
|
16115
|
+
Tm(`updating data in Firebase for ${e}`, t, n);
|
|
15948
16116
|
}
|
|
15949
16117
|
};
|
|
15950
16118
|
setChunks = async (e, t, { chunkSize: n = 1e3, purge: r = !1, onProgress: i } = {}) => {
|
|
15951
|
-
let a = He(
|
|
16119
|
+
let a = He(wm(), e);
|
|
15952
16120
|
try {
|
|
15953
16121
|
r && (await Ue(a), i?.(0, 0, `Purging existing data at ${e}`));
|
|
15954
16122
|
let o = Object.entries(Nt(t)), s = Math.ceil(o.length / n);
|
|
@@ -15958,14 +16126,14 @@ var em = () => {
|
|
|
15958
16126
|
i?.(t, s, `Saving chunk ${t}/${s}`);
|
|
15959
16127
|
}
|
|
15960
16128
|
} catch (t) {
|
|
15961
|
-
|
|
16129
|
+
Tm(`setting data in chunks in Firebase for ${e}`, t, !1);
|
|
15962
16130
|
}
|
|
15963
16131
|
};
|
|
15964
16132
|
remove = async (e, t = !1) => {
|
|
15965
16133
|
try {
|
|
15966
|
-
await Ue(He(
|
|
16134
|
+
await Ue(He(wm(), e)), `${e}`;
|
|
15967
16135
|
} catch (n) {
|
|
15968
|
-
|
|
16136
|
+
Tm(`removing data from Firebase for ${e}`, n, t);
|
|
15969
16137
|
}
|
|
15970
16138
|
};
|
|
15971
16139
|
count = async (e) => (await this.readShallow(e)).length;
|
|
@@ -15973,14 +16141,14 @@ var em = () => {
|
|
|
15973
16141
|
let o = Na();
|
|
15974
16142
|
if (!o || !e) return () => void 0;
|
|
15975
16143
|
let s = () => {
|
|
15976
|
-
let { dbRef: o, clientWhere: s } =
|
|
16144
|
+
let { dbRef: o, clientWhere: s } = km(He(wm(), e), r, n);
|
|
15977
16145
|
return Le(o, (e) => {
|
|
15978
16146
|
let n = e.val();
|
|
15979
16147
|
if (!n) {
|
|
15980
16148
|
t([]);
|
|
15981
16149
|
return;
|
|
15982
16150
|
}
|
|
15983
|
-
let o = a ? a(
|
|
16151
|
+
let o = a ? a(Nm(n, s, r)) : Nm(n, s, r), c = Object.entries(o);
|
|
15984
16152
|
if (!i) {
|
|
15985
16153
|
t(c.map(([e, t], n) => typeof t == "object" && t ? {
|
|
15986
16154
|
_index: n,
|
|
@@ -15989,22 +16157,22 @@ var em = () => {
|
|
|
15989
16157
|
} : {
|
|
15990
16158
|
_index: n,
|
|
15991
16159
|
[La]: e,
|
|
15992
|
-
[
|
|
16160
|
+
[Cm.value]: t
|
|
15993
16161
|
}));
|
|
15994
16162
|
return;
|
|
15995
16163
|
}
|
|
15996
16164
|
let l = Object.keys(i);
|
|
15997
16165
|
t(c.map(([e, t], n) => {
|
|
15998
16166
|
let r = typeof t == "object" && t ? {
|
|
15999
|
-
[
|
|
16167
|
+
[Cm.key]: e,
|
|
16000
16168
|
...t
|
|
16001
16169
|
} : {
|
|
16002
|
-
[
|
|
16003
|
-
[
|
|
16170
|
+
[Cm.key]: e,
|
|
16171
|
+
[Cm.value]: t
|
|
16004
16172
|
}, a = {};
|
|
16005
16173
|
for (let n of l) {
|
|
16006
16174
|
let o = i[n];
|
|
16007
|
-
a[n] = o.includes("{") ? et.parse(r, o) : o ===
|
|
16175
|
+
a[n] = o.includes("{") ? et.parse(r, o) : o === Cm.key ? e : o === Cm.value ? t : r[o];
|
|
16008
16176
|
}
|
|
16009
16177
|
return {
|
|
16010
16178
|
[La]: e,
|
|
@@ -16021,10 +16189,10 @@ var em = () => {
|
|
|
16021
16189
|
};
|
|
16022
16190
|
};
|
|
16023
16191
|
};
|
|
16024
|
-
new
|
|
16192
|
+
new Fm();
|
|
16025
16193
|
//#endregion
|
|
16026
16194
|
//#region src/providers/auth/firebase/FirebaseAuthProvider.ts
|
|
16027
|
-
var
|
|
16195
|
+
var Im = {
|
|
16028
16196
|
github: "github.com",
|
|
16029
16197
|
apple: "apple.com",
|
|
16030
16198
|
microsoft: "microsoft.com",
|
|
@@ -16032,10 +16200,10 @@ var Am = {
|
|
|
16032
16200
|
twitter: "twitter.com",
|
|
16033
16201
|
facebook: "facebook.com"
|
|
16034
16202
|
};
|
|
16035
|
-
function
|
|
16036
|
-
return new R(
|
|
16203
|
+
function Lm(e) {
|
|
16204
|
+
return new R(Im[e] ?? e);
|
|
16037
16205
|
}
|
|
16038
|
-
function
|
|
16206
|
+
function Rm(e) {
|
|
16039
16207
|
return e ? {
|
|
16040
16208
|
uid: e.uid,
|
|
16041
16209
|
email: e.email ?? void 0,
|
|
@@ -16044,7 +16212,7 @@ function Mm(e) {
|
|
|
16044
16212
|
isAnonymous: e.isAnonymous
|
|
16045
16213
|
} : null;
|
|
16046
16214
|
}
|
|
16047
|
-
var
|
|
16215
|
+
var zm = class {
|
|
16048
16216
|
options;
|
|
16049
16217
|
appName;
|
|
16050
16218
|
initPromise;
|
|
@@ -16058,7 +16226,7 @@ var Nm = class {
|
|
|
16058
16226
|
return this.getConfigurationState().configured;
|
|
16059
16227
|
}
|
|
16060
16228
|
getUser() {
|
|
16061
|
-
return
|
|
16229
|
+
return Rm(Na(this.appName)?.currentUser ?? null);
|
|
16062
16230
|
}
|
|
16063
16231
|
isAuthenticated() {
|
|
16064
16232
|
return !!this.getUser();
|
|
@@ -16070,18 +16238,18 @@ var Nm = class {
|
|
|
16070
16238
|
let n = e.method ?? "password";
|
|
16071
16239
|
if (n === "anonymous") {
|
|
16072
16240
|
let { user: e } = await ee(t);
|
|
16073
|
-
return
|
|
16241
|
+
return Rm(e);
|
|
16074
16242
|
}
|
|
16075
16243
|
if (n === "oauth") {
|
|
16076
16244
|
let { provider: n } = e;
|
|
16077
16245
|
if (!n) throw Error("FirebaseAuthProvider.signIn: provider is required for oauth");
|
|
16078
|
-
let { user: r } = await re(t,
|
|
16079
|
-
return
|
|
16246
|
+
let { user: r } = await re(t, Lm(n));
|
|
16247
|
+
return Rm(r);
|
|
16080
16248
|
}
|
|
16081
16249
|
let { email: r, password: i } = e;
|
|
16082
16250
|
if (!r || !i) throw Error("FirebaseAuthProvider.signIn: email and password are required");
|
|
16083
16251
|
let { user: a } = await ne(t, r, i);
|
|
16084
|
-
return
|
|
16252
|
+
return Rm(a);
|
|
16085
16253
|
}
|
|
16086
16254
|
async signOut() {
|
|
16087
16255
|
await this.initPromise;
|
|
@@ -16092,7 +16260,7 @@ var Nm = class {
|
|
|
16092
16260
|
onAuthChange(e) {
|
|
16093
16261
|
if (!this.options.config) {
|
|
16094
16262
|
let t = Na(this.appName);
|
|
16095
|
-
return t ? H(t, (t) => e(
|
|
16263
|
+
return t ? H(t, (t) => e(Rm(t))) : (e(null), () => {});
|
|
16096
16264
|
}
|
|
16097
16265
|
let t = () => {}, n = !1;
|
|
16098
16266
|
return this.initPromise.then(() => {
|
|
@@ -16102,7 +16270,7 @@ var Nm = class {
|
|
|
16102
16270
|
e(null);
|
|
16103
16271
|
return;
|
|
16104
16272
|
}
|
|
16105
|
-
t = H(r, (t) => e(
|
|
16273
|
+
t = H(r, (t) => e(Rm(t)));
|
|
16106
16274
|
}), () => {
|
|
16107
16275
|
n = !0, t();
|
|
16108
16276
|
};
|
|
@@ -16120,26 +16288,26 @@ var Nm = class {
|
|
|
16120
16288
|
let { claims: n } = await t.currentUser.getIdTokenResult(e);
|
|
16121
16289
|
return n;
|
|
16122
16290
|
}
|
|
16123
|
-
},
|
|
16124
|
-
function
|
|
16291
|
+
}, Bm = "https://oauth2.googleapis.com/token";
|
|
16292
|
+
function Vm(e) {
|
|
16125
16293
|
let t = e.replace(/-----BEGIN PRIVATE KEY-----/, "").replace(/-----END PRIVATE KEY-----/, "").replace(/\s+/g, ""), n = atob(t), r = new Uint8Array(n.length);
|
|
16126
16294
|
for (let e = 0; e < n.length; e++) r[e] = n.charCodeAt(e);
|
|
16127
16295
|
return r.buffer;
|
|
16128
16296
|
}
|
|
16129
|
-
function
|
|
16297
|
+
function Hm(e) {
|
|
16130
16298
|
return btoa(typeof e == "string" ? e : String.fromCharCode(...new Uint8Array(e))).replace(/\+/g, "-").replace(/\//g, "_").replace(/=+$/, "");
|
|
16131
16299
|
}
|
|
16132
|
-
async function
|
|
16133
|
-
let n = `${
|
|
16300
|
+
async function Um(e, t) {
|
|
16301
|
+
let n = `${Hm(JSON.stringify({
|
|
16134
16302
|
alg: "RS256",
|
|
16135
16303
|
typ: "JWT"
|
|
16136
|
-
}))}.${
|
|
16304
|
+
}))}.${Hm(JSON.stringify(e))}`, r = await crypto.subtle.importKey("pkcs8", Vm(t), {
|
|
16137
16305
|
name: "RSASSA-PKCS1-v1_5",
|
|
16138
16306
|
hash: "SHA-256"
|
|
16139
16307
|
}, !1, ["sign"]);
|
|
16140
|
-
return `${n}.${
|
|
16308
|
+
return `${n}.${Hm(await crypto.subtle.sign("RSASSA-PKCS1-v1_5", r, new TextEncoder().encode(n)))}`;
|
|
16141
16309
|
}
|
|
16142
|
-
var
|
|
16310
|
+
var Wm = class {
|
|
16143
16311
|
config;
|
|
16144
16312
|
cache = /* @__PURE__ */ new Map();
|
|
16145
16313
|
constructor(e) {
|
|
@@ -16148,13 +16316,13 @@ var Rm = class {
|
|
|
16148
16316
|
async getToken(e = "https://www.googleapis.com/auth/cloud-platform") {
|
|
16149
16317
|
let t = this.cache.get(e);
|
|
16150
16318
|
if (t && t.expiresAt > Date.now() + 6e4) return t.token;
|
|
16151
|
-
let n = Math.floor(Date.now() / 1e3), r = await
|
|
16319
|
+
let n = Math.floor(Date.now() / 1e3), r = await Um({
|
|
16152
16320
|
iss: this.config.client_email,
|
|
16153
16321
|
scope: e,
|
|
16154
|
-
aud:
|
|
16322
|
+
aud: Bm,
|
|
16155
16323
|
iat: n,
|
|
16156
16324
|
exp: n + 3600
|
|
16157
|
-
}, this.config.private_key), i = await fetch(
|
|
16325
|
+
}, this.config.private_key), i = await fetch(Bm, {
|
|
16158
16326
|
method: "POST",
|
|
16159
16327
|
headers: { "Content-Type": "application/x-www-form-urlencoded" },
|
|
16160
16328
|
body: new URLSearchParams({
|
|
@@ -16172,7 +16340,7 @@ var Rm = class {
|
|
|
16172
16340
|
expiresAt: Date.now() + (a.expires_in ?? 3600) * 1e3
|
|
16173
16341
|
}), a.access_token;
|
|
16174
16342
|
}
|
|
16175
|
-
},
|
|
16343
|
+
}, Gm = "www.dropbox.com/oauth2", Km = class {
|
|
16176
16344
|
config;
|
|
16177
16345
|
constructor(e) {
|
|
16178
16346
|
this.config = e;
|
|
@@ -16196,7 +16364,7 @@ var Rm = class {
|
|
|
16196
16364
|
async signIn(e = {}) {
|
|
16197
16365
|
if (!this.isConfigured()) throw Error("DropboxAuthProvider: missing dropbox.clientId configuration.");
|
|
16198
16366
|
return di({
|
|
16199
|
-
authServer:
|
|
16367
|
+
authServer: Gm,
|
|
16200
16368
|
clientID: this.config.clientId,
|
|
16201
16369
|
scopes: e.scopes,
|
|
16202
16370
|
refreshParamName: "token_access_type"
|
|
@@ -16217,7 +16385,7 @@ var Rm = class {
|
|
|
16217
16385
|
isAuthenticated() {
|
|
16218
16386
|
return this.isConfigured() ? !!gi(this.config.clientId)?.access_token : !1;
|
|
16219
16387
|
}
|
|
16220
|
-
},
|
|
16388
|
+
}, qm = (e) => {
|
|
16221
16389
|
let t = Ea("oAuth2");
|
|
16222
16390
|
if (!t) return console.warn("GoogleAuth: Missing oAuth2.clientId in configuration"), Promise.reject("Google client ID not found");
|
|
16223
16391
|
let n = e.join(" "), r = `googleAccessToken::${n}`, i = `googleExpiresAt::${n}`;
|
|
@@ -16234,8 +16402,8 @@ var Rm = class {
|
|
|
16234
16402
|
};
|
|
16235
16403
|
//#endregion
|
|
16236
16404
|
//#region src/providers/email/google/email.ts
|
|
16237
|
-
async function
|
|
16238
|
-
let i = await
|
|
16405
|
+
async function Jm({ to: e, bcc: t, subject: n, message: r }) {
|
|
16406
|
+
let i = await qm(["https://www.googleapis.com/auth/gmail.send"]), a = [`To: ${e.join(", ")}`];
|
|
16239
16407
|
t && t.length && a.push(`Bcc: ${t.join(", ")}`);
|
|
16240
16408
|
let o = [
|
|
16241
16409
|
...a,
|
|
@@ -16260,7 +16428,7 @@ async function Hm({ to: e, bcc: t, subject: n, message: r }) {
|
|
|
16260
16428
|
}
|
|
16261
16429
|
//#endregion
|
|
16262
16430
|
//#region src/providers/email/google/GmailEmailProvider.ts
|
|
16263
|
-
var
|
|
16431
|
+
var Ym = class {
|
|
16264
16432
|
getConfigurationState() {
|
|
16265
16433
|
return ii("GmailEmailProvider", ri(Ea("oAuth2"), ["clientId"], "google.oAuth2."));
|
|
16266
16434
|
}
|
|
@@ -16269,7 +16437,7 @@ var Um = class {
|
|
|
16269
16437
|
}
|
|
16270
16438
|
async send(e) {
|
|
16271
16439
|
if (!this.isConfigured()) throw Error(this.getConfigurationState().reason || "GmailEmailProvider is not configured.");
|
|
16272
|
-
await
|
|
16440
|
+
await Jm({
|
|
16273
16441
|
to: Array.isArray(e.to) ? e.to : [e.to],
|
|
16274
16442
|
bcc: e.bcc ? Array.isArray(e.bcc) ? e.bcc : [e.bcc] : void 0,
|
|
16275
16443
|
subject: e.subject,
|
|
@@ -16279,7 +16447,7 @@ var Um = class {
|
|
|
16279
16447
|
};
|
|
16280
16448
|
//#endregion
|
|
16281
16449
|
//#region src/providers/auth/supabase/SupabaseAuthProvider.ts
|
|
16282
|
-
function
|
|
16450
|
+
function Xm(e) {
|
|
16283
16451
|
return e ? {
|
|
16284
16452
|
uid: e.id,
|
|
16285
16453
|
email: e.email ?? void 0,
|
|
@@ -16288,7 +16456,7 @@ function Wm(e) {
|
|
|
16288
16456
|
raw: e
|
|
16289
16457
|
} : null;
|
|
16290
16458
|
}
|
|
16291
|
-
var
|
|
16459
|
+
var Zm = class {
|
|
16292
16460
|
config;
|
|
16293
16461
|
get client() {
|
|
16294
16462
|
return Ya(this.config.url, this.config.anonKey);
|
|
@@ -16303,7 +16471,7 @@ var Gm = class {
|
|
|
16303
16471
|
return this.getConfigurationState().configured;
|
|
16304
16472
|
}
|
|
16305
16473
|
getUser() {
|
|
16306
|
-
return
|
|
16474
|
+
return Xm((this.client.auth?._session ?? null)?.user ?? null);
|
|
16307
16475
|
}
|
|
16308
16476
|
isAuthenticated() {
|
|
16309
16477
|
return !!this.getUser();
|
|
@@ -16313,7 +16481,7 @@ var Gm = class {
|
|
|
16313
16481
|
if (t === "anonymous") {
|
|
16314
16482
|
let { data: e, error: t } = await this.client.auth.signInAnonymously();
|
|
16315
16483
|
if (t) throw t;
|
|
16316
|
-
return
|
|
16484
|
+
return Xm(e.user);
|
|
16317
16485
|
}
|
|
16318
16486
|
if (t === "magic_link") {
|
|
16319
16487
|
let t = e.email;
|
|
@@ -16342,7 +16510,7 @@ var Gm = class {
|
|
|
16342
16510
|
password: r
|
|
16343
16511
|
});
|
|
16344
16512
|
if (a) throw a;
|
|
16345
|
-
return
|
|
16513
|
+
return Xm(i.user);
|
|
16346
16514
|
}
|
|
16347
16515
|
async signOut() {
|
|
16348
16516
|
let { error: e } = await this.client.auth.signOut();
|
|
@@ -16350,10 +16518,10 @@ var Gm = class {
|
|
|
16350
16518
|
}
|
|
16351
16519
|
onAuthChange(e) {
|
|
16352
16520
|
this.client.auth.getSession().then(({ data: t }) => {
|
|
16353
|
-
e(
|
|
16521
|
+
e(Xm(t.session?.user ?? null));
|
|
16354
16522
|
});
|
|
16355
16523
|
let { data: { subscription: t } } = this.client.auth.onAuthStateChange((t, n) => {
|
|
16356
|
-
e(
|
|
16524
|
+
e(Xm(n?.user ?? null));
|
|
16357
16525
|
});
|
|
16358
16526
|
return () => t.unsubscribe();
|
|
16359
16527
|
}
|
|
@@ -16364,15 +16532,15 @@ var Gm = class {
|
|
|
16364
16532
|
if (!n) throw Error("SupabaseAuthProvider: no active session");
|
|
16365
16533
|
return n;
|
|
16366
16534
|
}
|
|
16367
|
-
},
|
|
16368
|
-
function
|
|
16535
|
+
}, Qm = "https://api.anthropic.com/v1/models", $m = "https://api.anthropic.com/v1/messages";
|
|
16536
|
+
function eh(e) {
|
|
16369
16537
|
return {
|
|
16370
16538
|
name: e.name,
|
|
16371
16539
|
description: e.description,
|
|
16372
16540
|
input_schema: e.inputSchema
|
|
16373
16541
|
};
|
|
16374
16542
|
}
|
|
16375
|
-
function
|
|
16543
|
+
function th(e) {
|
|
16376
16544
|
if (e.role === "user") return {
|
|
16377
16545
|
role: "user",
|
|
16378
16546
|
content: e.content
|
|
@@ -16404,7 +16572,7 @@ function Ym(e) {
|
|
|
16404
16572
|
}))
|
|
16405
16573
|
};
|
|
16406
16574
|
}
|
|
16407
|
-
function
|
|
16575
|
+
function nh(e) {
|
|
16408
16576
|
let t = e?.content;
|
|
16409
16577
|
if (!Array.isArray(t)) return null;
|
|
16410
16578
|
let n = t.filter((e) => e?.type === "text").map((e) => String(e.text ?? "")), r = t.filter((e) => e?.type === "tool_use");
|
|
@@ -16423,7 +16591,7 @@ function Xm(e) {
|
|
|
16423
16591
|
text: i
|
|
16424
16592
|
} : null;
|
|
16425
16593
|
}
|
|
16426
|
-
var
|
|
16594
|
+
var rh = {
|
|
16427
16595
|
id: "anthropic",
|
|
16428
16596
|
label: "Anthropic",
|
|
16429
16597
|
description: "Claude models via the Anthropic API.",
|
|
@@ -16447,7 +16615,7 @@ var Zm = {
|
|
|
16447
16615
|
supportsDocuments: !0
|
|
16448
16616
|
},
|
|
16449
16617
|
discoverModels: async (e) => {
|
|
16450
|
-
let t = await Ht(
|
|
16618
|
+
let t = await Ht(Qm, { headers: {
|
|
16451
16619
|
"x-api-key": e,
|
|
16452
16620
|
"anthropic-version": "2023-06-01"
|
|
16453
16621
|
} }, rl);
|
|
@@ -16475,7 +16643,7 @@ var Zm = {
|
|
|
16475
16643
|
type: "text",
|
|
16476
16644
|
text: n.prompt
|
|
16477
16645
|
}] : n.prompt;
|
|
16478
|
-
return
|
|
16646
|
+
return nh(await Ht($m, {
|
|
16479
16647
|
method: "POST",
|
|
16480
16648
|
headers: {
|
|
16481
16649
|
"x-api-key": t,
|
|
@@ -16486,18 +16654,18 @@ var Zm = {
|
|
|
16486
16654
|
model: n.model,
|
|
16487
16655
|
max_tokens: 4096,
|
|
16488
16656
|
...n.role ? { system: Kc.parseRole(n.role, n) } : {},
|
|
16489
|
-
messages: [...(n.history ?? []).map(
|
|
16657
|
+
messages: [...(n.history ?? []).map(th), ...n.prompt ? [{
|
|
16490
16658
|
role: "user",
|
|
16491
16659
|
content: i
|
|
16492
16660
|
}] : []],
|
|
16493
|
-
...n.tools?.length ? { tools: n.tools.map(
|
|
16661
|
+
...n.tools?.length ? { tools: n.tools.map(eh) } : {},
|
|
16494
16662
|
...typeof n.temperature == "number" ? { temperature: n.temperature } : {}
|
|
16495
16663
|
},
|
|
16496
16664
|
signal: n.signal
|
|
16497
16665
|
}, rl));
|
|
16498
16666
|
}
|
|
16499
|
-
},
|
|
16500
|
-
function
|
|
16667
|
+
}, ih = (e) => e.replace(/\/+$/, "");
|
|
16668
|
+
function ah(e) {
|
|
16501
16669
|
return {
|
|
16502
16670
|
type: "function",
|
|
16503
16671
|
function: {
|
|
@@ -16507,7 +16675,7 @@ function $m(e) {
|
|
|
16507
16675
|
}
|
|
16508
16676
|
};
|
|
16509
16677
|
}
|
|
16510
|
-
function
|
|
16678
|
+
function oh(e) {
|
|
16511
16679
|
if (typeof e != "string") return {};
|
|
16512
16680
|
try {
|
|
16513
16681
|
return JSON.parse(e);
|
|
@@ -16515,7 +16683,7 @@ function eh(e) {
|
|
|
16515
16683
|
return {};
|
|
16516
16684
|
}
|
|
16517
16685
|
}
|
|
16518
|
-
function
|
|
16686
|
+
function sh(e) {
|
|
16519
16687
|
return e.role === "user" ? [{
|
|
16520
16688
|
role: "user",
|
|
16521
16689
|
content: e.content
|
|
@@ -16536,7 +16704,7 @@ function th(e) {
|
|
|
16536
16704
|
content: typeof e.output == "string" ? e.output : JSON.stringify(e.output)
|
|
16537
16705
|
}));
|
|
16538
16706
|
}
|
|
16539
|
-
function
|
|
16707
|
+
function ch(e) {
|
|
16540
16708
|
let t = e?.choices?.[0]?.message;
|
|
16541
16709
|
if (!t) return null;
|
|
16542
16710
|
let n = Array.isArray(t.tool_calls) ? t.tool_calls : [];
|
|
@@ -16549,7 +16717,7 @@ function nh(e) {
|
|
|
16549
16717
|
return {
|
|
16550
16718
|
id: String(e.id),
|
|
16551
16719
|
name: String(t.name ?? ""),
|
|
16552
|
-
input:
|
|
16720
|
+
input: oh(t.arguments)
|
|
16553
16721
|
};
|
|
16554
16722
|
}),
|
|
16555
16723
|
text: e || void 0
|
|
@@ -16561,8 +16729,8 @@ function nh(e) {
|
|
|
16561
16729
|
text: r
|
|
16562
16730
|
} : null;
|
|
16563
16731
|
}
|
|
16564
|
-
var
|
|
16565
|
-
let m =
|
|
16732
|
+
var lh = ({ id: t, label: n, description: r, configKey: i, requiredConfigKeys: a, defaultModel: o, fallbackModels: s, baseUrl: c, modelsUrl: l, chatCompletionsUrl: u, dashboardUrl: d, credentialsHint: f, validateApiKey: p }) => {
|
|
16733
|
+
let m = ih(c), h = l || `${m}/models`, g = u || `${m}/chat/completions`;
|
|
16566
16734
|
return {
|
|
16567
16735
|
id: t,
|
|
16568
16736
|
label: n,
|
|
@@ -16639,22 +16807,22 @@ var rh = ({ id: t, label: n, description: r, configKey: i, requiredConfigKeys: a
|
|
|
16639
16807
|
role: "system",
|
|
16640
16808
|
content: Kc.parseRole(r.role, r)
|
|
16641
16809
|
}] : [],
|
|
16642
|
-
...(r.history ?? []).flatMap(
|
|
16810
|
+
...(r.history ?? []).flatMap(sh),
|
|
16643
16811
|
...r.prompt ? [{
|
|
16644
16812
|
role: "user",
|
|
16645
16813
|
content: a
|
|
16646
16814
|
}] : []
|
|
16647
16815
|
],
|
|
16648
|
-
...r.tools?.length ? { tools: r.tools.map(
|
|
16816
|
+
...r.tools?.length ? { tools: r.tools.map(ah) } : {},
|
|
16649
16817
|
...typeof r.temperature == "number" ? { temperature: r.temperature } : {}
|
|
16650
16818
|
},
|
|
16651
16819
|
signal: r.signal
|
|
16652
16820
|
}, rl);
|
|
16653
16821
|
if (!o) throw ll(n);
|
|
16654
|
-
return
|
|
16822
|
+
return ch(o);
|
|
16655
16823
|
}
|
|
16656
16824
|
};
|
|
16657
|
-
},
|
|
16825
|
+
}, uh = lh({
|
|
16658
16826
|
id: "deepseek",
|
|
16659
16827
|
label: "DeepSeek",
|
|
16660
16828
|
description: "Cost-efficient reasoning and chat models.",
|
|
@@ -16664,15 +16832,15 @@ var rh = ({ id: t, label: n, description: r, configKey: i, requiredConfigKeys: a
|
|
|
16664
16832
|
baseUrl: "https://api.deepseek.com",
|
|
16665
16833
|
dashboardUrl: "https://platform.deepseek.com/api_keys",
|
|
16666
16834
|
credentialsHint: "DeepSeek platform → API Keys → Create new API key."
|
|
16667
|
-
}),
|
|
16668
|
-
function
|
|
16835
|
+
}), dh = "https://generativelanguage.googleapis.com/v1beta/models", fh = "https://generativelanguage.googleapis.com/v1beta/models";
|
|
16836
|
+
function ph(e) {
|
|
16669
16837
|
return [{ function_declarations: e.map((e) => ({
|
|
16670
16838
|
name: e.name,
|
|
16671
16839
|
description: e.description,
|
|
16672
16840
|
parameters: e.inputSchema
|
|
16673
16841
|
})) }];
|
|
16674
16842
|
}
|
|
16675
|
-
function
|
|
16843
|
+
function mh(e) {
|
|
16676
16844
|
if (e.role === "user") return {
|
|
16677
16845
|
role: "user",
|
|
16678
16846
|
parts: [{ text: e.content }]
|
|
@@ -16697,7 +16865,7 @@ function ch(e) {
|
|
|
16697
16865
|
} }))
|
|
16698
16866
|
};
|
|
16699
16867
|
}
|
|
16700
|
-
function
|
|
16868
|
+
function hh(e) {
|
|
16701
16869
|
let t = e?.candidates?.[0]?.content?.parts;
|
|
16702
16870
|
if (!Array.isArray(t)) return null;
|
|
16703
16871
|
let n = t.filter((e) => typeof e?.text == "string").map((e) => e.text), r = t.filter((e) => e?.functionCall);
|
|
@@ -16716,7 +16884,7 @@ function lh(e) {
|
|
|
16716
16884
|
text: i
|
|
16717
16885
|
} : null;
|
|
16718
16886
|
}
|
|
16719
|
-
var
|
|
16887
|
+
var gh = {
|
|
16720
16888
|
id: "gemini",
|
|
16721
16889
|
label: "Gemini",
|
|
16722
16890
|
description: "Google's multimodal Gemini model family.",
|
|
@@ -16740,12 +16908,12 @@ var uh = {
|
|
|
16740
16908
|
supportsDocuments: !0
|
|
16741
16909
|
},
|
|
16742
16910
|
discoverModels: async (e) => {
|
|
16743
|
-
let t = await Ht(`${
|
|
16911
|
+
let t = await Ht(`${dh}?key=${e}`, null, rl);
|
|
16744
16912
|
return Array.isArray(t?.models) ? t.models.map((e) => e.name?.replace(/^models\//, "")).filter(Boolean) : [];
|
|
16745
16913
|
},
|
|
16746
16914
|
validateApiKey: async (e) => {
|
|
16747
16915
|
try {
|
|
16748
|
-
let t = await Ht(`${
|
|
16916
|
+
let t = await Ht(`${dh}?key=${e}`, null, rl);
|
|
16749
16917
|
return t === null ? {
|
|
16750
16918
|
valid: !1,
|
|
16751
16919
|
error: "Nessuna risposta dal server (CORS o rete)"
|
|
@@ -16766,22 +16934,22 @@ var uh = {
|
|
|
16766
16934
|
mime_type: e.mimeType,
|
|
16767
16935
|
data: e.base64
|
|
16768
16936
|
} }), { text: n.prompt }];
|
|
16769
|
-
return
|
|
16937
|
+
return hh(await Ht(`${fh}/${n.model}:generateContent?key=${t}`, {
|
|
16770
16938
|
method: "POST",
|
|
16771
16939
|
headers: n.logId ? { [e]: n.logId } : void 0,
|
|
16772
16940
|
body: {
|
|
16773
|
-
contents: [...(n.history ?? []).map(
|
|
16941
|
+
contents: [...(n.history ?? []).map(mh), ...n.prompt ? [{
|
|
16774
16942
|
role: "user",
|
|
16775
16943
|
parts: r
|
|
16776
16944
|
}] : []],
|
|
16777
16945
|
...n.role ? { systemInstruction: { parts: [{ text: Kc.parseRole(n.role, n) }] } } : {},
|
|
16778
|
-
...n.tools?.length ? { tools:
|
|
16946
|
+
...n.tools?.length ? { tools: ph(n.tools) } : {},
|
|
16779
16947
|
generationConfig: typeof n.temperature == "number" ? { temperature: n.temperature } : void 0
|
|
16780
16948
|
},
|
|
16781
16949
|
signal: n.signal
|
|
16782
16950
|
}, rl));
|
|
16783
16951
|
}
|
|
16784
|
-
},
|
|
16952
|
+
}, _h = lh({
|
|
16785
16953
|
id: "mistral",
|
|
16786
16954
|
label: "Mistral",
|
|
16787
16955
|
description: "European-hosted open and commercial language models.",
|
|
@@ -16795,7 +16963,7 @@ var uh = {
|
|
|
16795
16963
|
baseUrl: "https://api.mistral.ai/v1",
|
|
16796
16964
|
dashboardUrl: "https://console.mistral.ai/api-keys",
|
|
16797
16965
|
credentialsHint: "Mistral Console → API Keys → Create new key."
|
|
16798
|
-
}),
|
|
16966
|
+
}), vh = lh({
|
|
16799
16967
|
id: "openai",
|
|
16800
16968
|
label: "OpenAI",
|
|
16801
16969
|
description: "GPT models via the OpenAI API.",
|
|
@@ -16813,7 +16981,7 @@ var uh = {
|
|
|
16813
16981
|
baseUrl: "https://api.openai.com/v1",
|
|
16814
16982
|
dashboardUrl: "https://platform.openai.com/api-keys",
|
|
16815
16983
|
credentialsHint: "OpenAI dashboard → API keys → Create new secret key."
|
|
16816
|
-
}),
|
|
16984
|
+
}), yh = "https://opencode.ai/zen/v1/models", bh = "https://opencode.ai/zen/v1/chat/completions", xh = [
|
|
16817
16985
|
"big-pickle",
|
|
16818
16986
|
"deepseek-v4-flash-free",
|
|
16819
16987
|
"glm-5",
|
|
@@ -16825,16 +16993,16 @@ var uh = {
|
|
|
16825
16993
|
"minimax-m2.5",
|
|
16826
16994
|
"minimax-m2.7",
|
|
16827
16995
|
"nemotron-3-super-free"
|
|
16828
|
-
],
|
|
16996
|
+
], Sh = (e) => {
|
|
16829
16997
|
let t = e.endpoint || "", n = e.ai_sdk_package || e.aiSdkPackage || "";
|
|
16830
16998
|
return t.includes("/chat/completions") || n.includes("openai-compatible");
|
|
16831
|
-
},
|
|
16999
|
+
}, Ch = {
|
|
16832
17000
|
id: "opencode",
|
|
16833
17001
|
label: "OpenCode",
|
|
16834
17002
|
description: "OpenCode Zen — a curated set of coding-focused models.",
|
|
16835
17003
|
configKey: "openCodeApiKey",
|
|
16836
17004
|
defaultModel: "deepseek-v4-flash-free",
|
|
16837
|
-
fallbackModels:
|
|
17005
|
+
fallbackModels: xh,
|
|
16838
17006
|
dashboardUrl: "https://opencode.ai",
|
|
16839
17007
|
credentialsHint: "OpenCode Zen dashboard → API Keys → Create Key.",
|
|
16840
17008
|
credentialFields: [{
|
|
@@ -16848,8 +17016,8 @@ var uh = {
|
|
|
16848
17016
|
supportsDocuments: !0
|
|
16849
17017
|
},
|
|
16850
17018
|
discoverModels: async (e) => {
|
|
16851
|
-
let t = await Ht(
|
|
16852
|
-
return (Array.isArray(t?.data) ? t.data : Array.isArray(t?.models) ? t.models : Array.isArray(t) ? t : []).filter((e) =>
|
|
17019
|
+
let t = await Ht(yh, { headers: { Authorization: `Bearer ${e}` } }, rl);
|
|
17020
|
+
return (Array.isArray(t?.data) ? t.data : Array.isArray(t?.models) ? t.models : Array.isArray(t) ? t : []).filter((e) => Sh(e)).map((e) => e.id).filter((e) => typeof e == "string" && e.length > 0);
|
|
16853
17021
|
},
|
|
16854
17022
|
complete: async (t, n) => {
|
|
16855
17023
|
let r = n.attachments ?? [], i = r.length > 0 ? r.map((e) => e.mimeType.startsWith("image/") ? {
|
|
@@ -16864,7 +17032,7 @@ var uh = {
|
|
|
16864
17032
|
}).concat({
|
|
16865
17033
|
type: "text",
|
|
16866
17034
|
text: n.prompt
|
|
16867
|
-
}) : n.prompt, a = await Ht(
|
|
17035
|
+
}) : n.prompt, a = await Ht(bh, {
|
|
16868
17036
|
method: "POST",
|
|
16869
17037
|
headers: {
|
|
16870
17038
|
Authorization: `Bearer ${t}`,
|
|
@@ -16877,21 +17045,21 @@ var uh = {
|
|
|
16877
17045
|
role: "system",
|
|
16878
17046
|
content: Kc.parseRole(n.role, n)
|
|
16879
17047
|
}] : [],
|
|
16880
|
-
...(n.history ?? []).flatMap(
|
|
17048
|
+
...(n.history ?? []).flatMap(sh),
|
|
16881
17049
|
...n.prompt ? [{
|
|
16882
17050
|
role: "user",
|
|
16883
17051
|
content: i
|
|
16884
17052
|
}] : []
|
|
16885
17053
|
],
|
|
16886
|
-
...n.tools?.length ? { tools: n.tools.map(
|
|
17054
|
+
...n.tools?.length ? { tools: n.tools.map(ah) } : {},
|
|
16887
17055
|
...typeof n.temperature == "number" ? { temperature: n.temperature } : {}
|
|
16888
17056
|
},
|
|
16889
17057
|
signal: n.signal
|
|
16890
17058
|
}, rl);
|
|
16891
17059
|
if (!a) throw ll("OpenCode");
|
|
16892
|
-
return
|
|
17060
|
+
return ch(a);
|
|
16893
17061
|
}
|
|
16894
|
-
},
|
|
17062
|
+
}, wh = lh({
|
|
16895
17063
|
id: "openrouter",
|
|
16896
17064
|
label: "OpenRouter",
|
|
16897
17065
|
description: "Unified access to many model providers through one API.",
|
|
@@ -16925,10 +17093,10 @@ var uh = {
|
|
|
16925
17093
|
};
|
|
16926
17094
|
}
|
|
16927
17095
|
}
|
|
16928
|
-
}),
|
|
17096
|
+
}), Th = {
|
|
16929
17097
|
dbRealtime: {
|
|
16930
17098
|
service: "data",
|
|
16931
|
-
create: () => new
|
|
17099
|
+
create: () => new Fm()
|
|
16932
17100
|
},
|
|
16933
17101
|
firestoreDb: {
|
|
16934
17102
|
service: "data",
|
|
@@ -16940,26 +17108,26 @@ var uh = {
|
|
|
16940
17108
|
},
|
|
16941
17109
|
firebaseAuth: {
|
|
16942
17110
|
service: "auth",
|
|
16943
|
-
create: () => new
|
|
17111
|
+
create: () => new zm()
|
|
16944
17112
|
}
|
|
16945
|
-
},
|
|
17113
|
+
}, Eh = {
|
|
16946
17114
|
googleAuth: {
|
|
16947
17115
|
service: "auth",
|
|
16948
|
-
create: () => new
|
|
17116
|
+
create: () => new gm()
|
|
16949
17117
|
},
|
|
16950
17118
|
gmail: {
|
|
16951
17119
|
service: "email",
|
|
16952
|
-
create: () => new
|
|
17120
|
+
create: () => new Ym()
|
|
16953
17121
|
},
|
|
16954
17122
|
googleServiceAccount: {
|
|
16955
17123
|
service: "credentials",
|
|
16956
|
-
create: (e) => new
|
|
17124
|
+
create: (e) => new Wm(e.serviceAccount),
|
|
16957
17125
|
when: (e) => !!e.serviceAccount
|
|
16958
17126
|
}
|
|
16959
|
-
},
|
|
17127
|
+
}, Dh = { dropboxAuth: {
|
|
16960
17128
|
service: "auth",
|
|
16961
|
-
create: (e) => new
|
|
16962
|
-
} },
|
|
17129
|
+
create: (e) => new Km(e)
|
|
17130
|
+
} }, Oh = {
|
|
16963
17131
|
supabaseDb: {
|
|
16964
17132
|
service: "data",
|
|
16965
17133
|
create: (e) => new oo(e)
|
|
@@ -16970,32 +17138,32 @@ var uh = {
|
|
|
16970
17138
|
},
|
|
16971
17139
|
supabaseAuth: {
|
|
16972
17140
|
service: "auth",
|
|
16973
|
-
create: (e) => new
|
|
17141
|
+
create: (e) => new Zm(e)
|
|
16974
17142
|
}
|
|
16975
|
-
},
|
|
17143
|
+
}, kh = { mock: {
|
|
16976
17144
|
service: "data",
|
|
16977
17145
|
create: (e) => new mo(e?.data)
|
|
16978
|
-
} },
|
|
17146
|
+
} }, Ah = (e, t) => ({
|
|
16979
17147
|
service: "ai",
|
|
16980
17148
|
create: (n) => new hl(e, n?.[t] || ""),
|
|
16981
17149
|
when: (e) => !!e?.[t]
|
|
16982
|
-
}),
|
|
16983
|
-
firebase:
|
|
16984
|
-
google:
|
|
16985
|
-
dropbox:
|
|
16986
|
-
supabase:
|
|
16987
|
-
mock:
|
|
17150
|
+
}), jh = {
|
|
17151
|
+
firebase: Th,
|
|
17152
|
+
google: Eh,
|
|
17153
|
+
dropbox: Dh,
|
|
17154
|
+
supabase: Oh,
|
|
17155
|
+
mock: kh,
|
|
16988
17156
|
ai: {
|
|
16989
|
-
openai:
|
|
16990
|
-
openrouter: wh
|
|
16991
|
-
opencode:
|
|
16992
|
-
deepseek:
|
|
16993
|
-
gemini:
|
|
16994
|
-
anthropic:
|
|
16995
|
-
mistral:
|
|
17157
|
+
openai: Ah(vh, "openaiApiKey"),
|
|
17158
|
+
openrouter: Ah(wh, "openRouterApiKey"),
|
|
17159
|
+
opencode: Ah(Ch, "openCodeApiKey"),
|
|
17160
|
+
deepseek: Ah(uh, "deepSeekApiKey"),
|
|
17161
|
+
gemini: Ah(gh, "geminiApiKey"),
|
|
17162
|
+
anthropic: Ah(rh, "anthropicApiKey"),
|
|
17163
|
+
mistral: Ah(_h, "mistralApiKey")
|
|
16996
17164
|
}
|
|
16997
|
-
},
|
|
16998
|
-
function
|
|
17165
|
+
}, Mh = () => /* @__PURE__ */ t.createElement("div", { className: "flex min-h-[calc(100vh-4rem)] items-center justify-center" }, /* @__PURE__ */ t.createElement("div", { className: "h-8 w-8 animate-spin rounded-full border-2 border-muted border-t-primary" }));
|
|
17166
|
+
function Nh(e, t) {
|
|
16999
17167
|
if (!t) return;
|
|
17000
17168
|
let n = t, r = typeof t == "object" && !Array.isArray(t) ? Object.entries(n) : [];
|
|
17001
17169
|
if (r.length > 0 && r.every(([, e]) => typeof e == "object" && !!e)) {
|
|
@@ -17004,10 +17172,10 @@ function Dh(e, t) {
|
|
|
17004
17172
|
}
|
|
17005
17173
|
e.custom = t;
|
|
17006
17174
|
}
|
|
17007
|
-
function
|
|
17175
|
+
function Ph(e, t, n = "default") {
|
|
17008
17176
|
return t && e[t] ? t : Object.keys(e)[0] ?? n;
|
|
17009
17177
|
}
|
|
17010
|
-
function
|
|
17178
|
+
function Fh(e = {}) {
|
|
17011
17179
|
let t = {
|
|
17012
17180
|
data: {},
|
|
17013
17181
|
storage: {},
|
|
@@ -17016,24 +17184,24 @@ function kh(e = {}) {
|
|
|
17016
17184
|
ai: {},
|
|
17017
17185
|
credentials: {}
|
|
17018
17186
|
}, n = (e) => t[e] ??= {};
|
|
17019
|
-
for (let [t, r] of Object.entries(
|
|
17187
|
+
for (let [t, r] of Object.entries(jh)) {
|
|
17020
17188
|
let i = e[t];
|
|
17021
17189
|
if (i !== void 0) for (let [e, t] of Object.entries(r)) t.when && !t.when(i) || (n(t.service)[e] = t.create(i));
|
|
17022
17190
|
}
|
|
17023
|
-
for (let [t, r] of Object.entries(e.custom ?? {}))
|
|
17024
|
-
Object.keys(t.data).length === 0 && (t.data.mock = new mo()), Object.keys(t.auth).length === 0 && (t.auth.googleAuth = new
|
|
17191
|
+
for (let [t, r] of Object.entries(e.custom ?? {})) Nh(n(t), r);
|
|
17192
|
+
Object.keys(t.data).length === 0 && (t.data.mock = new mo()), Object.keys(t.auth).length === 0 && (t.auth.googleAuth = new gm());
|
|
17025
17193
|
let r = e.services ?? {}, i = {};
|
|
17026
17194
|
for (let [e, n] of Object.entries(t)) i[e] = {
|
|
17027
17195
|
registry: n,
|
|
17028
|
-
defaultKey:
|
|
17196
|
+
defaultKey: Ph(n, r[e])
|
|
17029
17197
|
};
|
|
17030
17198
|
return i;
|
|
17031
17199
|
}
|
|
17032
|
-
var
|
|
17033
|
-
|
|
17034
|
-
},
|
|
17035
|
-
function
|
|
17036
|
-
let [p, g] = h(() =>
|
|
17200
|
+
var Ih = {}, Lh = (e) => {
|
|
17201
|
+
Ih = e;
|
|
17202
|
+
}, Rh = (e) => Ih[e] || [];
|
|
17203
|
+
function zh({ contextProviders: e, providers: n = {}, appName: r = "LLM Native", scrapeConfig: i, iconProvider: a, googleMaps: o, themeProvider: s, i18n: c, children: l, errorReportUrl: u, debug: d, basename: f }) {
|
|
17204
|
+
let [p, g] = h(() => Fh(n)), v = m(p);
|
|
17037
17205
|
v.current = p;
|
|
17038
17206
|
let y = m(void 0);
|
|
17039
17207
|
y.current ||= (async (e, t, n) => {
|
|
@@ -17050,7 +17218,7 @@ function Nh({ contextProviders: e, providers: n = {}, appName: r = "LLM Native",
|
|
|
17050
17218
|
})));
|
|
17051
17219
|
});
|
|
17052
17220
|
let b = y.current, x = e ?? t.Fragment;
|
|
17053
|
-
return /* @__PURE__ */ t.createElement(
|
|
17221
|
+
return /* @__PURE__ */ t.createElement(mm, {
|
|
17054
17222
|
fullPage: !0,
|
|
17055
17223
|
reportUrl: u,
|
|
17056
17224
|
debug: d
|
|
@@ -17072,10 +17240,10 @@ function Nh({ contextProviders: e, providers: n = {}, appName: r = "LLM Native",
|
|
|
17072
17240
|
} }, /* @__PURE__ */ t.createElement(ma, {
|
|
17073
17241
|
registries: p,
|
|
17074
17242
|
setProvider: b
|
|
17075
|
-
}, /* @__PURE__ */ t.createElement($r, p.auth, /* @__PURE__ */ t.createElement(
|
|
17243
|
+
}, /* @__PURE__ */ t.createElement($r, p.auth, /* @__PURE__ */ t.createElement(xm, p.credentials, /* @__PURE__ */ t.createElement(Si, p.data, /* @__PURE__ */ t.createElement(oc, p.storage, /* @__PURE__ */ t.createElement(vm, p.email, /* @__PURE__ */ t.createElement(Xc, p.ai, /* @__PURE__ */ t.createElement(br, { config: a }, /* @__PURE__ */ t.createElement(Vd, { config: o }, /* @__PURE__ */ t.createElement(bp, { appName: r }, /* @__PURE__ */ t.createElement(Mn, { config: c }, /* @__PURE__ */ t.createElement(yn, { config: s }, /* @__PURE__ */ t.createElement(x, null, l))))))))))))))));
|
|
17076
17244
|
}
|
|
17077
|
-
function
|
|
17078
|
-
|
|
17245
|
+
function Bh({ importPage: e, LayoutDefault: n = void 0, menuConfig: r = {}, children: a, ...o }) {
|
|
17246
|
+
Lh(r);
|
|
17079
17247
|
let s = ({ children: e }) => /* @__PURE__ */ t.createElement(t.Fragment, null, e), c = ({ pageSource: e, message: n }) => /* @__PURE__ */ t.createElement(Po, { variant: "warning" }, "Missing Page: ", e, n && /* @__PURE__ */ t.createElement("code", { className: "ml-2" }, n));
|
|
17080
17248
|
function l(r, a, l) {
|
|
17081
17249
|
let u = `./pages${a.component ? "/" + a.component : a.path === "/" ? "/Home" : et.toCamel(a.path.split("*")[0])}.js`, d = a.page || t.lazy(() => e(u).then((e) => typeof e.default == "function" ? { default: e.default } : (console.warn(`⚠️ Invalid default export in ${u}`), { default: () => /* @__PURE__ */ t.createElement(c, { pageSource: u }) })).catch((e) => (console.error(`❌ Failed to load ${u}:`, e), { default: () => /* @__PURE__ */ t.createElement(c, {
|
|
@@ -17085,32 +17253,32 @@ function Ph({ importPage: e, LayoutDefault: n = void 0, menuConfig: r = {}, chil
|
|
|
17085
17253
|
return /* @__PURE__ */ t.createElement(y, {
|
|
17086
17254
|
key: `${r}-${l}`,
|
|
17087
17255
|
path: a.path,
|
|
17088
|
-
element: /* @__PURE__ */ t.createElement(f, null, /* @__PURE__ */ t.createElement(
|
|
17256
|
+
element: /* @__PURE__ */ t.createElement(f, null, /* @__PURE__ */ t.createElement(mm, {
|
|
17089
17257
|
key: a.path,
|
|
17090
17258
|
reportUrl: o.errorReportUrl,
|
|
17091
17259
|
debug: o.debug
|
|
17092
|
-
}, /* @__PURE__ */ t.createElement(i, { fallback: /* @__PURE__ */ t.createElement(
|
|
17260
|
+
}, /* @__PURE__ */ t.createElement(i, { fallback: /* @__PURE__ */ t.createElement(Mh, null) }, /* @__PURE__ */ t.createElement(d, null))))
|
|
17093
17261
|
});
|
|
17094
17262
|
}
|
|
17095
17263
|
let u = (e) => Object.keys(e).flatMap((t) => e[t].flatMap((e, n) => [e.path && l(t, e, n), e.children && u({ children: e.children })].filter(Boolean)));
|
|
17096
|
-
return /* @__PURE__ */ t.createElement(
|
|
17264
|
+
return /* @__PURE__ */ t.createElement(zh, o, a, /* @__PURE__ */ t.createElement(b, null, /* @__PURE__ */ t.createElement(y, {
|
|
17097
17265
|
path: oi,
|
|
17098
17266
|
element: /* @__PURE__ */ t.createElement(pi, null)
|
|
17099
17267
|
}), /* @__PURE__ */ t.createElement(t.Fragment, null, u({
|
|
17100
17268
|
default: [{ path: "/" }],
|
|
17101
|
-
...
|
|
17269
|
+
...Ih,
|
|
17102
17270
|
_auth: [{
|
|
17103
17271
|
path: "/users",
|
|
17104
|
-
page:
|
|
17272
|
+
page: am,
|
|
17105
17273
|
layout: n
|
|
17106
17274
|
}]
|
|
17107
17275
|
})), /* @__PURE__ */ t.createElement(y, {
|
|
17108
17276
|
path: "*",
|
|
17109
|
-
element: /* @__PURE__ */ t.createElement(
|
|
17277
|
+
element: /* @__PURE__ */ t.createElement(om, null)
|
|
17110
17278
|
})));
|
|
17111
17279
|
}
|
|
17112
|
-
var
|
|
17113
|
-
let t =
|
|
17280
|
+
var Vh = (e) => {
|
|
17281
|
+
let t = Rh(e), n = x(), r = (e) => e.map((e) => {
|
|
17114
17282
|
let t = n.pathname === e.path, i = e.children ? r(e.children) : [], a = t || i.some((e) => e.active);
|
|
17115
17283
|
return {
|
|
17116
17284
|
...e,
|
|
@@ -17119,7 +17287,7 @@ var Fh = (e) => {
|
|
|
17119
17287
|
};
|
|
17120
17288
|
});
|
|
17121
17289
|
return p(() => r(t), [n.pathname]);
|
|
17122
|
-
},
|
|
17290
|
+
}, Hh = {
|
|
17123
17291
|
common: {
|
|
17124
17292
|
save: "Salva",
|
|
17125
17293
|
cancel: "Annulla",
|
|
@@ -17159,7 +17327,16 @@ var Fh = (e) => {
|
|
|
17159
17327
|
grid: {
|
|
17160
17328
|
buttonAdd: "Aggiungi",
|
|
17161
17329
|
deleteConfirm: "Sei sicuro di voler eliminare questo elemento?",
|
|
17162
|
-
emptyState: "Nessun elemento da mostrare"
|
|
17330
|
+
emptyState: "Nessun elemento da mostrare",
|
|
17331
|
+
filtersButton: "Filtri",
|
|
17332
|
+
filtersPanelTitle: "Filtri",
|
|
17333
|
+
filtersClearAll: "Cancella tutti",
|
|
17334
|
+
filtersSelectPlaceholder: "Tutti",
|
|
17335
|
+
filtersRangeFrom: "Da",
|
|
17336
|
+
filtersRangeTo: "A",
|
|
17337
|
+
filtersRangeMin: "Min",
|
|
17338
|
+
filtersRangeMax: "Max",
|
|
17339
|
+
filtersSelectedCountTemplate: "{count} selezionati"
|
|
17163
17340
|
},
|
|
17164
17341
|
select: {
|
|
17165
17342
|
placeholder: "Seleziona...",
|
|
@@ -17277,7 +17454,7 @@ var Fh = (e) => {
|
|
|
17277
17454
|
notConfigured: "La ricerca indirizzi non è configurata (manca la API key Google Maps).",
|
|
17278
17455
|
loadError: "Impossibile caricare la ricerca indirizzi."
|
|
17279
17456
|
}
|
|
17280
|
-
},
|
|
17457
|
+
}, Uh = {
|
|
17281
17458
|
common: {
|
|
17282
17459
|
save: "Speichern",
|
|
17283
17460
|
cancel: "Abbrechen",
|
|
@@ -17317,7 +17494,16 @@ var Fh = (e) => {
|
|
|
17317
17494
|
grid: {
|
|
17318
17495
|
buttonAdd: "Hinzufügen",
|
|
17319
17496
|
deleteConfirm: "Dieses Element wirklich löschen?",
|
|
17320
|
-
emptyState: "Keine Elemente vorhanden"
|
|
17497
|
+
emptyState: "Keine Elemente vorhanden",
|
|
17498
|
+
filtersButton: "Filter",
|
|
17499
|
+
filtersPanelTitle: "Filter",
|
|
17500
|
+
filtersClearAll: "Alle zurücksetzen",
|
|
17501
|
+
filtersSelectPlaceholder: "Alle",
|
|
17502
|
+
filtersRangeFrom: "Von",
|
|
17503
|
+
filtersRangeTo: "Bis",
|
|
17504
|
+
filtersRangeMin: "Min",
|
|
17505
|
+
filtersRangeMax: "Max",
|
|
17506
|
+
filtersSelectedCountTemplate: "{count} ausgewählt"
|
|
17321
17507
|
},
|
|
17322
17508
|
select: {
|
|
17323
17509
|
placeholder: "Auswählen...",
|
|
@@ -17435,7 +17621,7 @@ var Fh = (e) => {
|
|
|
17435
17621
|
notConfigured: "Adresssuche ist nicht konfiguriert (Google Maps API-Schlüssel fehlt).",
|
|
17436
17622
|
loadError: "Adresssuche konnte nicht geladen werden."
|
|
17437
17623
|
}
|
|
17438
|
-
},
|
|
17624
|
+
}, Wh = {
|
|
17439
17625
|
common: {
|
|
17440
17626
|
save: "Сохранить",
|
|
17441
17627
|
cancel: "Отменить",
|
|
@@ -17475,7 +17661,16 @@ var Fh = (e) => {
|
|
|
17475
17661
|
grid: {
|
|
17476
17662
|
buttonAdd: "Добавить",
|
|
17477
17663
|
deleteConfirm: "Вы уверены, что хотите удалить этот элемент?",
|
|
17478
|
-
emptyState: "Нет элементов для отображения"
|
|
17664
|
+
emptyState: "Нет элементов для отображения",
|
|
17665
|
+
filtersButton: "Фильтры",
|
|
17666
|
+
filtersPanelTitle: "Фильтры",
|
|
17667
|
+
filtersClearAll: "Сбросить все",
|
|
17668
|
+
filtersSelectPlaceholder: "Все",
|
|
17669
|
+
filtersRangeFrom: "От",
|
|
17670
|
+
filtersRangeTo: "До",
|
|
17671
|
+
filtersRangeMin: "Мин",
|
|
17672
|
+
filtersRangeMax: "Макс",
|
|
17673
|
+
filtersSelectedCountTemplate: "Выбрано: {count}"
|
|
17479
17674
|
},
|
|
17480
17675
|
select: {
|
|
17481
17676
|
placeholder: "Выбрать...",
|
|
@@ -17593,7 +17788,7 @@ var Fh = (e) => {
|
|
|
17593
17788
|
notConfigured: "Поиск адресов не настроен (отсутствует ключ Google Maps API).",
|
|
17594
17789
|
loadError: "Не удалось загрузить поиск адресов."
|
|
17595
17790
|
}
|
|
17596
|
-
},
|
|
17791
|
+
}, Gh = {
|
|
17597
17792
|
common: {
|
|
17598
17793
|
save: "保存",
|
|
17599
17794
|
cancel: "取消",
|
|
@@ -17633,7 +17828,16 @@ var Fh = (e) => {
|
|
|
17633
17828
|
grid: {
|
|
17634
17829
|
buttonAdd: "添加",
|
|
17635
17830
|
deleteConfirm: "确定要删除此项目吗?",
|
|
17636
|
-
emptyState: "暂无数据"
|
|
17831
|
+
emptyState: "暂无数据",
|
|
17832
|
+
filtersButton: "筛选",
|
|
17833
|
+
filtersPanelTitle: "筛选",
|
|
17834
|
+
filtersClearAll: "清除全部",
|
|
17835
|
+
filtersSelectPlaceholder: "全部",
|
|
17836
|
+
filtersRangeFrom: "从",
|
|
17837
|
+
filtersRangeTo: "到",
|
|
17838
|
+
filtersRangeMin: "最小",
|
|
17839
|
+
filtersRangeMax: "最大",
|
|
17840
|
+
filtersSelectedCountTemplate: "已选 {count} 项"
|
|
17637
17841
|
},
|
|
17638
17842
|
select: {
|
|
17639
17843
|
placeholder: "请选择...",
|
|
@@ -17751,7 +17955,7 @@ var Fh = (e) => {
|
|
|
17751
17955
|
notConfigured: "地址搜索未配置(缺少 Google Maps API 密钥)。",
|
|
17752
17956
|
loadError: "无法加载地址搜索。"
|
|
17753
17957
|
}
|
|
17754
|
-
},
|
|
17958
|
+
}, Kh = {
|
|
17755
17959
|
common: {
|
|
17756
17960
|
save: "حفظ",
|
|
17757
17961
|
cancel: "إلغاء",
|
|
@@ -17791,7 +17995,16 @@ var Fh = (e) => {
|
|
|
17791
17995
|
grid: {
|
|
17792
17996
|
buttonAdd: "إضافة",
|
|
17793
17997
|
deleteConfirm: "هل أنت متأكد من حذف هذا العنصر؟",
|
|
17794
|
-
emptyState: "لا توجد عناصر للعرض"
|
|
17998
|
+
emptyState: "لا توجد عناصر للعرض",
|
|
17999
|
+
filtersButton: "الفلاتر",
|
|
18000
|
+
filtersPanelTitle: "الفلاتر",
|
|
18001
|
+
filtersClearAll: "مسح الكل",
|
|
18002
|
+
filtersSelectPlaceholder: "الكل",
|
|
18003
|
+
filtersRangeFrom: "من",
|
|
18004
|
+
filtersRangeTo: "إلى",
|
|
18005
|
+
filtersRangeMin: "أدنى",
|
|
18006
|
+
filtersRangeMax: "أقصى",
|
|
18007
|
+
filtersSelectedCountTemplate: "تم اختيار {count}"
|
|
17795
18008
|
},
|
|
17796
18009
|
select: {
|
|
17797
18010
|
placeholder: "اختر...",
|
|
@@ -17909,22 +18122,22 @@ var Fh = (e) => {
|
|
|
17909
18122
|
notConfigured: "البحث عن العناوين غير مُعد (مفتاح Google Maps API مفقود).",
|
|
17910
18123
|
loadError: "تعذر تحميل البحث عن العناوين."
|
|
17911
18124
|
}
|
|
17912
|
-
},
|
|
17913
|
-
ar: () =>
|
|
17914
|
-
de: () =>
|
|
18125
|
+
}, qh = /* @__PURE__ */ Je({
|
|
18126
|
+
ar: () => Kh,
|
|
18127
|
+
de: () => Uh,
|
|
17915
18128
|
en: () => Sn,
|
|
17916
|
-
it: () =>
|
|
17917
|
-
ru: () =>
|
|
17918
|
-
zh: () =>
|
|
17919
|
-
}),
|
|
18129
|
+
it: () => Hh,
|
|
18130
|
+
ru: () => Wh,
|
|
18131
|
+
zh: () => Gh
|
|
18132
|
+
}), Jh = (e) => _a("api", e);
|
|
17920
18133
|
//#endregion
|
|
17921
18134
|
//#region src/providers/api/direct.ts
|
|
17922
|
-
async function
|
|
18135
|
+
async function Yh(e) {
|
|
17923
18136
|
if (!e.ok) throw Error(`ApiProvider request failed: ${e.status} ${e.statusText}`);
|
|
17924
18137
|
let t = await e.text();
|
|
17925
18138
|
return t ? JSON.parse(t) : void 0;
|
|
17926
18139
|
}
|
|
17927
|
-
var
|
|
18140
|
+
var Xh = class {
|
|
17928
18141
|
config;
|
|
17929
18142
|
constructor(e) {
|
|
17930
18143
|
this.config = e;
|
|
@@ -17939,7 +18152,7 @@ var Wh = class {
|
|
|
17939
18152
|
...e.body,
|
|
17940
18153
|
...this.config.body
|
|
17941
18154
|
};
|
|
17942
|
-
return
|
|
18155
|
+
return Yh(await rl(n.toString(), {
|
|
17943
18156
|
method: t,
|
|
17944
18157
|
headers: {
|
|
17945
18158
|
"Content-Type": "application/json",
|
|
@@ -17948,7 +18161,7 @@ var Wh = class {
|
|
|
17948
18161
|
body: t === "GET" || t === "HEAD" ? void 0 : JSON.stringify(r)
|
|
17949
18162
|
}));
|
|
17950
18163
|
}
|
|
17951
|
-
},
|
|
18164
|
+
}, Zh = class {
|
|
17952
18165
|
resolver;
|
|
17953
18166
|
constructor(e) {
|
|
17954
18167
|
this.resolver = e;
|
|
@@ -17956,7 +18169,7 @@ var Wh = class {
|
|
|
17956
18169
|
async fetch(e) {
|
|
17957
18170
|
return this.resolver(e);
|
|
17958
18171
|
}
|
|
17959
|
-
},
|
|
18172
|
+
}, Qh = class {
|
|
17960
18173
|
config;
|
|
17961
18174
|
constructor(e) {
|
|
17962
18175
|
this.config = e;
|
|
@@ -17967,7 +18180,7 @@ var Wh = class {
|
|
|
17967
18180
|
request: e
|
|
17968
18181
|
}, void 0, this.config.region);
|
|
17969
18182
|
}
|
|
17970
|
-
},
|
|
18183
|
+
}, $h = class {
|
|
17971
18184
|
config;
|
|
17972
18185
|
constructor(e) {
|
|
17973
18186
|
this.config = e;
|
|
@@ -17980,7 +18193,7 @@ var Wh = class {
|
|
|
17980
18193
|
if (n) throw n;
|
|
17981
18194
|
return t;
|
|
17982
18195
|
}
|
|
17983
|
-
},
|
|
18196
|
+
}, eg = [
|
|
17984
18197
|
{
|
|
17985
18198
|
id: "resend",
|
|
17986
18199
|
label: "Resend",
|
|
@@ -18091,7 +18304,7 @@ var Wh = class {
|
|
|
18091
18304
|
],
|
|
18092
18305
|
credentialsHint: "Ask your mail host or hosting provider for the SMTP host, port, and credentials."
|
|
18093
18306
|
}
|
|
18094
|
-
],
|
|
18307
|
+
], tg = [
|
|
18095
18308
|
{
|
|
18096
18309
|
id: "cloudflare_pages",
|
|
18097
18310
|
label: "Cloudflare Pages",
|
|
@@ -18321,15 +18534,15 @@ var Wh = class {
|
|
|
18321
18534
|
description: "No vendor — packages the build as a downloadable archive for self-hosting anywhere else.",
|
|
18322
18535
|
credentialFields: []
|
|
18323
18536
|
}
|
|
18324
|
-
],
|
|
18325
|
-
fh,
|
|
18537
|
+
], ng = [
|
|
18326
18538
|
vh,
|
|
18327
|
-
|
|
18328
|
-
|
|
18539
|
+
wh,
|
|
18540
|
+
Ch,
|
|
18329
18541
|
uh,
|
|
18330
|
-
|
|
18331
|
-
|
|
18332
|
-
|
|
18542
|
+
gh,
|
|
18543
|
+
rh,
|
|
18544
|
+
_h,
|
|
18545
|
+
lh({
|
|
18333
18546
|
id: "glm",
|
|
18334
18547
|
label: "ZhipuAI (GLM)",
|
|
18335
18548
|
description: "Zhipu AI's GLM model family.",
|
|
@@ -18346,7 +18559,7 @@ var Wh = class {
|
|
|
18346
18559
|
dashboardUrl: "https://bigmodel.cn/usercenter/apikeys",
|
|
18347
18560
|
credentialsHint: "Zhipu BigModel → User Center → API Keys → Create Key."
|
|
18348
18561
|
})
|
|
18349
|
-
],
|
|
18562
|
+
], rg = (e) => ({
|
|
18350
18563
|
id: e.id,
|
|
18351
18564
|
label: e.label,
|
|
18352
18565
|
description: e.description ?? "",
|
|
@@ -18357,7 +18570,7 @@ var Wh = class {
|
|
|
18357
18570
|
}],
|
|
18358
18571
|
credentialsUrl: e.dashboardUrl,
|
|
18359
18572
|
credentialsHint: e.credentialsHint
|
|
18360
|
-
}),
|
|
18573
|
+
}), ig = ng.map(rg), ag = {
|
|
18361
18574
|
id: "openai-compatible",
|
|
18362
18575
|
label: "OpenAI-compatible",
|
|
18363
18576
|
description: "Any OpenAI-compatible endpoint (self-hosted or third-party).",
|
|
@@ -18371,9 +18584,9 @@ var Wh = class {
|
|
|
18371
18584
|
type: "text",
|
|
18372
18585
|
placeholder: "https://api.example.com/v1"
|
|
18373
18586
|
}]
|
|
18374
|
-
},
|
|
18587
|
+
}, og = (e) => {
|
|
18375
18588
|
let t = e?.openAICompatible?.baseUrl?.trim();
|
|
18376
|
-
return t ? [
|
|
18589
|
+
return t ? [lh({
|
|
18377
18590
|
id: "openai-compatible",
|
|
18378
18591
|
label: e?.openAICompatible?.label?.trim() || "OpenAI-compatible",
|
|
18379
18592
|
description: "Any OpenAI-compatible endpoint (self-hosted or third-party).",
|
|
@@ -18385,35 +18598,35 @@ var Wh = class {
|
|
|
18385
18598
|
modelsUrl: e?.openAICompatible?.modelsUrl?.trim() || void 0,
|
|
18386
18599
|
chatCompletionsUrl: e?.openAICompatible?.chatCompletionsUrl?.trim() || void 0
|
|
18387
18600
|
})] : [];
|
|
18388
|
-
},
|
|
18601
|
+
}, sg = (e) => e ? [...ng, ...og(e)].reduce((t, n) => {
|
|
18389
18602
|
let r = n.id === "openai-compatible" ? e.openAICompatible?.apiKey?.trim() || "" : typeof n.configKey == "string" && typeof e[n.configKey] == "string" ? String(e[n.configKey] || "").trim() : "";
|
|
18390
18603
|
return r && (t[n.id] = new hl(n, r)), t;
|
|
18391
|
-
}, {}) : {},
|
|
18604
|
+
}, {}) : {}, cg = void 0;
|
|
18392
18605
|
typeof Sa == "function" && Sa((e) => {
|
|
18393
|
-
|
|
18606
|
+
cg = e.google;
|
|
18394
18607
|
});
|
|
18395
|
-
var
|
|
18608
|
+
var lg = {
|
|
18396
18609
|
ita: "geoTargetConstants/2380",
|
|
18397
18610
|
rome: "geoTargetConstants/1033236",
|
|
18398
18611
|
mil: "geoTargetConstants/1033239",
|
|
18399
18612
|
nap: "geoTargetConstants/1033245",
|
|
18400
18613
|
tor: "geoTargetConstants/1033247"
|
|
18401
|
-
},
|
|
18614
|
+
}, ug = {
|
|
18402
18615
|
it: "languageConstants/1000",
|
|
18403
18616
|
en: "languageConstants/1001",
|
|
18404
18617
|
fr: "languageConstants/1002",
|
|
18405
18618
|
es: "languageConstants/1003",
|
|
18406
18619
|
de: "languageConstants/1005"
|
|
18407
18620
|
};
|
|
18408
|
-
function
|
|
18409
|
-
return
|
|
18621
|
+
function dg(e) {
|
|
18622
|
+
return lg[e.toLowerCase()] || "geoTargetConstants/2380";
|
|
18410
18623
|
}
|
|
18411
|
-
function
|
|
18412
|
-
return
|
|
18624
|
+
function fg(e) {
|
|
18625
|
+
return ug[e.toLowerCase()] || "languageConstants/1000";
|
|
18413
18626
|
}
|
|
18414
|
-
async function
|
|
18415
|
-
if (!
|
|
18416
|
-
let i = await
|
|
18627
|
+
async function pg({ keyword: e, googleAdsAccountId: t, geoCode: n = "ita", languageCode: r = "it" }) {
|
|
18628
|
+
if (!cg?.developerToken) return console.error("\n❌ Google Ads API: developerToken non configurato.\n\nPer ottenere un developerToken segui questi passaggi:\n\n1️⃣ Vai su https://ads.google.com/aw/apicenter\n2️⃣ Seleziona o crea un account Google Ads Manager (MCC) se non ne hai uno.\n3️⃣ Vai alla sezione \"Strumenti e impostazioni\" → \"Accesso API\" (o \"API Center\").\n4️⃣ Clicca su \"Richiedi accesso API\" se non l'hai ancora fatto.\n5️⃣ Copia il valore del tuo Developer Token (è un identificatore simile a: 'ABc123456789xyz').\n6️⃣ Inseriscilo nel tuo file di configurazione, nella sezione:\n config.google.developerToken\n\nℹ️ Attenzione: Inizialmente il token sarà in modalità di test. Per usarlo in produzione, dovrai richiedere l'approvazione da Google Ads.\n"), [];
|
|
18629
|
+
let i = await qm(["https://www.googleapis.com/auth/adwords"]), a = dg(n), o = fg(r), s = `https://googleads.googleapis.com/v13/customers/${t}:generateKeywordIdeas`, c = {
|
|
18417
18630
|
keywordSeed: { keywords: [e] },
|
|
18418
18631
|
geoTargetConstants: [a],
|
|
18419
18632
|
language: o
|
|
@@ -18421,7 +18634,7 @@ async function sg({ keyword: e, googleAdsAccountId: t, geoCode: n = "ita", langu
|
|
|
18421
18634
|
method: "POST",
|
|
18422
18635
|
headers: {
|
|
18423
18636
|
Authorization: `Bearer ${i}`,
|
|
18424
|
-
"developer-token":
|
|
18637
|
+
"developer-token": cg.developerToken,
|
|
18425
18638
|
"Content-Type": "application/json"
|
|
18426
18639
|
},
|
|
18427
18640
|
body: JSON.stringify(c)
|
|
@@ -18439,7 +18652,7 @@ async function sg({ keyword: e, googleAdsAccountId: t, geoCode: n = "ita", langu
|
|
|
18439
18652
|
}
|
|
18440
18653
|
//#endregion
|
|
18441
18654
|
//#region src/providers/seo/google/trend.ts
|
|
18442
|
-
async function
|
|
18655
|
+
async function mg(e, t = "IT", n = "today 12-m") {
|
|
18443
18656
|
let r = `https://trends.google.com/trends/api/explore?hl=en-US&tz=0&req=${encodeURIComponent(JSON.stringify({
|
|
18444
18657
|
comparisonItem: [{
|
|
18445
18658
|
keyword: e,
|
|
@@ -18459,7 +18672,7 @@ async function cg(e, t = "IT", n = "today 12-m") {
|
|
|
18459
18672
|
}))
|
|
18460
18673
|
};
|
|
18461
18674
|
}
|
|
18462
|
-
async function
|
|
18675
|
+
async function hg(e, t = "IT", n = "today 12-m") {
|
|
18463
18676
|
let r = `https://trends.google.com/trends/api/explore?hl=en-US&tz=0&req=${encodeURIComponent(JSON.stringify({
|
|
18464
18677
|
comparisonItem: [{
|
|
18465
18678
|
keyword: e,
|
|
@@ -18485,13 +18698,13 @@ async function lg(e, t = "IT", n = "today 12-m") {
|
|
|
18485
18698
|
}
|
|
18486
18699
|
//#endregion
|
|
18487
18700
|
//#region src/providers/storage/dropbox.tsx
|
|
18488
|
-
var
|
|
18701
|
+
var gg = 5e3, _g = "https://www.dropbox.com/home", vg = void 0;
|
|
18489
18702
|
typeof Sa == "function" && Sa((e) => {
|
|
18490
|
-
|
|
18703
|
+
vg = e.dropbox;
|
|
18491
18704
|
});
|
|
18492
|
-
var
|
|
18493
|
-
if (!
|
|
18494
|
-
let r = await vi(
|
|
18705
|
+
var yg = async (e, t, n = {}) => {
|
|
18706
|
+
if (!vg) return console.error("DropBox: Config not found"), null;
|
|
18707
|
+
let r = await vi(vg.clientId);
|
|
18495
18708
|
if (!r) throw Error("DropBox: Access token not found");
|
|
18496
18709
|
return await fetch(e, {
|
|
18497
18710
|
method: "POST",
|
|
@@ -18504,12 +18717,12 @@ var pg = async (e, t, n = {}) => {
|
|
|
18504
18717
|
}).catch((e) => (console.error("There was a problem with the fetch operation:", e), null)).finally(() => {
|
|
18505
18718
|
console.log("DropBox: Fetch operation completed");
|
|
18506
18719
|
});
|
|
18507
|
-
},
|
|
18508
|
-
if (!
|
|
18720
|
+
}, bg = async (e, t, n = {}) => {
|
|
18721
|
+
if (!vg) {
|
|
18509
18722
|
console.error("DropBox: Config not found");
|
|
18510
18723
|
return;
|
|
18511
18724
|
}
|
|
18512
|
-
let r = await vi(
|
|
18725
|
+
let r = await vi(vg.clientId);
|
|
18513
18726
|
if (!r) {
|
|
18514
18727
|
console.error("DropBox: Access token not found");
|
|
18515
18728
|
return;
|
|
@@ -18534,47 +18747,47 @@ var pg = async (e, t, n = {}) => {
|
|
|
18534
18747
|
}).finally(() => {
|
|
18535
18748
|
console.log("DropBox: Fetch operation completed", e, t);
|
|
18536
18749
|
});
|
|
18537
|
-
},
|
|
18538
|
-
let n =
|
|
18539
|
-
return (t ?
|
|
18540
|
-
},
|
|
18750
|
+
}, xg = (e, t = !1) => {
|
|
18751
|
+
let n = vg?.rootPath || "";
|
|
18752
|
+
return (t ? _g : "") + (e.startsWith(n) ? e : n + e);
|
|
18753
|
+
}, Sg = async (e, t = "", n = !1) => {
|
|
18541
18754
|
let r = {};
|
|
18542
|
-
return (await
|
|
18755
|
+
return (await Ig.listFolders({
|
|
18543
18756
|
path: `${e + t}`,
|
|
18544
18757
|
recursive: !0
|
|
18545
18758
|
})).forEach((e) => {
|
|
18546
18759
|
e[".tag"] !== "folder" && (r[n ? ti.changeFilename(e.path_display, { ext: "" }) : e.path_display] = e.name);
|
|
18547
18760
|
}), r;
|
|
18548
|
-
},
|
|
18761
|
+
}, Cg = async (e, t) => {
|
|
18549
18762
|
if (!e.async_job_id) return Promise.reject(e);
|
|
18550
18763
|
let n, r = !0;
|
|
18551
|
-
for (; r;) await ut(100), n = await
|
|
18764
|
+
for (; r;) await ut(100), n = await bg(`https://api.dropboxapi.com/2/${t}/check`, { async_job_id: e.async_job_id }), console.log("DropBox: Check folders response: ", n), n?.[".tag"] !== "in_progress" && (r = !1);
|
|
18552
18765
|
return n?.[".tag"] === "complete" ? Promise.resolve(n.entries) : Promise.reject(n);
|
|
18553
|
-
},
|
|
18554
|
-
let n = "files/create_folder_batch", r = await
|
|
18766
|
+
}, wg = async (e, t = "") => {
|
|
18767
|
+
let n = "files/create_folder_batch", r = await bg(`https://api.dropboxapi.com/2/${n}`, {
|
|
18555
18768
|
autorename: !1,
|
|
18556
18769
|
force_async: !0,
|
|
18557
|
-
paths: e.map((e) =>
|
|
18770
|
+
paths: e.map((e) => xg(t + e))
|
|
18558
18771
|
});
|
|
18559
|
-
return r ?
|
|
18560
|
-
},
|
|
18561
|
-
let n = "files/create_folder_batch", r = await
|
|
18562
|
-
return r ?
|
|
18563
|
-
},
|
|
18772
|
+
return r ? Cg(r, n) : void 0;
|
|
18773
|
+
}, Tg = async (e, t = "") => {
|
|
18774
|
+
let n = "files/create_folder_batch", r = await bg(`https://api.dropboxapi.com/2/${n}`, { entries: e.map((e) => ({ path: xg(t + e) })) });
|
|
18775
|
+
return r ? Cg(r, n) : void 0;
|
|
18776
|
+
}, Eg = async (e, t) => bg("https://api.dropboxapi.com/2/files/tags/add", {
|
|
18564
18777
|
path: e,
|
|
18565
18778
|
tag_text: t.toLowerCase().replaceAll(/[^a-z0-9]/g, "")
|
|
18566
|
-
}),
|
|
18567
|
-
for (let n in e) for (let r of e[n]) await
|
|
18568
|
-
},
|
|
18569
|
-
let n = [], r = async ({ path: e, cursor: t, recursive: n }) => e ? await
|
|
18779
|
+
}), Dg = async (e, t = "") => {
|
|
18780
|
+
for (let n in e) for (let r of e[n]) await Eg(xg(t + n), r);
|
|
18781
|
+
}, Og = async ({ path: e = "", recursive: t = !1 } = {}) => {
|
|
18782
|
+
let n = [], r = async ({ path: e, cursor: t, recursive: n }) => e ? await bg("https://api.dropboxapi.com/2/files/list_folder", {
|
|
18570
18783
|
include_deleted: !1,
|
|
18571
18784
|
include_has_explicit_shared_members: !1,
|
|
18572
18785
|
include_media_info: !1,
|
|
18573
18786
|
include_mounted_folders: !0,
|
|
18574
18787
|
include_non_downloadable_files: !0,
|
|
18575
|
-
path:
|
|
18788
|
+
path: xg(e),
|
|
18576
18789
|
recursive: n
|
|
18577
|
-
}) : await
|
|
18790
|
+
}) : await bg("https://api.dropboxapi.com/2/files/list_folder/continue", { cursor: t }), i = {
|
|
18578
18791
|
has_more: !0,
|
|
18579
18792
|
cursor: "",
|
|
18580
18793
|
entries: []
|
|
@@ -18587,44 +18800,44 @@ var pg = async (e, t, n = {}) => {
|
|
|
18587
18800
|
recursive: t
|
|
18588
18801
|
}), i && n.push(...i.entries);
|
|
18589
18802
|
return n;
|
|
18590
|
-
},
|
|
18591
|
-
let t = async (e) => await
|
|
18803
|
+
}, kg = async (e) => {
|
|
18804
|
+
let t = async (e) => await bg("https://api.dropboxapi.com/2/files/copy_batch_v2", {
|
|
18592
18805
|
entries: e,
|
|
18593
18806
|
autorename: !1
|
|
18594
|
-
}), n = async (e) => await
|
|
18807
|
+
}), n = async (e) => await bg("https://api.dropboxapi.com/2/files/copy_batch/check_v2", { async_job_id: e }), r = [], i = [];
|
|
18595
18808
|
for (let a = 0; a < e.length; a += 900) {
|
|
18596
18809
|
i = e.slice(a, a + 900).map((e) => ({
|
|
18597
|
-
from_path:
|
|
18598
|
-
to_path:
|
|
18810
|
+
from_path: xg(e.from),
|
|
18811
|
+
to_path: xg(e.to)
|
|
18599
18812
|
}));
|
|
18600
18813
|
let o = await t(i);
|
|
18601
18814
|
if (!o) continue;
|
|
18602
18815
|
if (o.error) throw Error(`Error starting copy: ${o.error}`);
|
|
18603
18816
|
let s = o;
|
|
18604
|
-
for (; s?.[".tag"] === "async_job_id" || s?.[".tag"] === "in_progress";) await ut(
|
|
18817
|
+
for (; s?.[".tag"] === "async_job_id" || s?.[".tag"] === "in_progress";) await ut(gg), s = await n(o.async_job_id ?? "");
|
|
18605
18818
|
if (s?.[".tag"] === "failed") throw Error(`Copy operation failed: ${s[".tag"]}`);
|
|
18606
18819
|
s?.[".tag"] === "complete" && s.entries && r.push(...s.entries);
|
|
18607
18820
|
}
|
|
18608
18821
|
return r.filter((e) => e[".tag"] === "failure").map((e) => e.failure);
|
|
18609
|
-
},
|
|
18610
|
-
let t = async (e) => await
|
|
18822
|
+
}, Ag = async (e) => {
|
|
18823
|
+
let t = async (e) => await bg("https://api.dropboxapi.com/2/files/move_v2", {
|
|
18611
18824
|
...e,
|
|
18612
18825
|
autorename: !0
|
|
18613
18826
|
});
|
|
18614
18827
|
for (let n of e) await t({
|
|
18615
|
-
from_path:
|
|
18616
|
-
to_path:
|
|
18828
|
+
from_path: xg(n.from),
|
|
18829
|
+
to_path: xg(n.to)
|
|
18617
18830
|
});
|
|
18618
|
-
},
|
|
18831
|
+
}, jg = async ({ thumbnailsRequest: e = [], size: t = "w64h64", format: n = "jpeg", mode: r = "strict" }, i) => {
|
|
18619
18832
|
let a = {}, o = [];
|
|
18620
18833
|
for (let s = 0; s < e.length; s += 25) {
|
|
18621
18834
|
let c = e.slice(s, s + 25), l = c.map((e) => ({
|
|
18622
|
-
path:
|
|
18835
|
+
path: xg(e.path),
|
|
18623
18836
|
format: n,
|
|
18624
18837
|
size: t,
|
|
18625
18838
|
mode: r
|
|
18626
18839
|
}));
|
|
18627
|
-
await ut(100), o.push(
|
|
18840
|
+
await ut(100), o.push(bg("https://content.dropboxapi.com/2/files/get_thumbnail_batch", { entries: l }).then((e) => {
|
|
18628
18841
|
if (!e) return;
|
|
18629
18842
|
let n = e.entries.reduce((e, n, r) => {
|
|
18630
18843
|
let i = c[r].path, [a, o] = t.replace("w", "").split("h").map(Number), s = n;
|
|
@@ -18643,7 +18856,7 @@ var pg = async (e, t, n = {}) => {
|
|
|
18643
18856
|
}));
|
|
18644
18857
|
}
|
|
18645
18858
|
return Promise.all(o).then(() => a);
|
|
18646
|
-
},
|
|
18859
|
+
}, Mg = (e, t = "application/octet-stream", n = 512) => {
|
|
18647
18860
|
let r = atob(e), i = [];
|
|
18648
18861
|
for (let e = 0; e < r.length; e += n) {
|
|
18649
18862
|
let t = r.slice(e, e + n), a = Array(t.length);
|
|
@@ -18652,11 +18865,11 @@ var pg = async (e, t, n = {}) => {
|
|
|
18652
18865
|
i.push(o);
|
|
18653
18866
|
}
|
|
18654
18867
|
return new Blob(i, { type: t });
|
|
18655
|
-
},
|
|
18868
|
+
}, Ng = async (e, t) => {
|
|
18656
18869
|
try {
|
|
18657
18870
|
let n = t.split(",")[1];
|
|
18658
|
-
|
|
18659
|
-
path:
|
|
18871
|
+
yg("https://content.dropboxapi.com/2/files/upload", Mg(n, "application/octet-stream"), { "Dropbox-API-Arg": JSON.stringify({
|
|
18872
|
+
path: xg(e),
|
|
18660
18873
|
mode: "overwrite",
|
|
18661
18874
|
autorename: !0,
|
|
18662
18875
|
mute: !1
|
|
@@ -18666,12 +18879,12 @@ var pg = async (e, t, n = {}) => {
|
|
|
18666
18879
|
} catch (e) {
|
|
18667
18880
|
console.error("Errore durante il caricamento su Dropbox:", e);
|
|
18668
18881
|
}
|
|
18669
|
-
},
|
|
18670
|
-
if (!
|
|
18882
|
+
}, Pg = (e = !1) => vg ? hi(vg.clientId, e) : !1, Fg = (e = {}) => {
|
|
18883
|
+
if (!vg) return /* @__PURE__ */ t.createElement("div", {
|
|
18671
18884
|
title: "DropBox: configurazione mancante. Recupera il \"Client ID\" accedendo a https://www.dropbox.com/developers, vai su \"App Console\", seleziona un'app esistente o chiedi il Client ID a chi ha configurato il sistema.",
|
|
18672
18885
|
className: "text-danger flex items-center gap-2"
|
|
18673
18886
|
}, /* @__PURE__ */ t.createElement(Q, { name: "warning" }), /* @__PURE__ */ t.createElement("span", null, "Dropbox non configurato"));
|
|
18674
|
-
let n =
|
|
18887
|
+
let n = Pg(!0);
|
|
18675
18888
|
return /* @__PURE__ */ t.createElement(bi, {
|
|
18676
18889
|
provider: "dropboxAuth",
|
|
18677
18890
|
intent: "connect",
|
|
@@ -18683,33 +18896,33 @@ var pg = async (e, t, n = {}) => {
|
|
|
18683
18896
|
title: n ? "DropBox Connected" : "DropBox Disconnected"
|
|
18684
18897
|
}
|
|
18685
18898
|
});
|
|
18686
|
-
},
|
|
18899
|
+
}, Ig = {
|
|
18687
18900
|
setRootPath: (e) => {
|
|
18688
|
-
|
|
18901
|
+
vg && (vg.rootPath = e);
|
|
18689
18902
|
},
|
|
18690
|
-
resolvePath:
|
|
18691
|
-
createFolders:
|
|
18692
|
-
deleteBulk:
|
|
18693
|
-
addTags:
|
|
18694
|
-
listFolders:
|
|
18695
|
-
getThumbnails:
|
|
18696
|
-
search:
|
|
18697
|
-
upload:
|
|
18698
|
-
copy:
|
|
18699
|
-
move:
|
|
18700
|
-
},
|
|
18903
|
+
resolvePath: xg,
|
|
18904
|
+
createFolders: wg,
|
|
18905
|
+
deleteBulk: Tg,
|
|
18906
|
+
addTags: Dg,
|
|
18907
|
+
listFolders: Og,
|
|
18908
|
+
getThumbnails: jg,
|
|
18909
|
+
search: Sg,
|
|
18910
|
+
upload: Ng,
|
|
18911
|
+
copy: kg,
|
|
18912
|
+
move: Ag
|
|
18913
|
+
}, Lg = "https://api.serpapi.com/search", Rg = "google", zg = "google_images", Bg = "google_autocomplete", Vg = "google_trends", Hg = "google_maps", Ug = "google_maps_photos", Wg = "google_maps_reviews", Gg = {
|
|
18701
18914
|
engine: null,
|
|
18702
18915
|
device: null,
|
|
18703
18916
|
no_cache: !1,
|
|
18704
18917
|
async: !1,
|
|
18705
18918
|
output: "json"
|
|
18706
|
-
},
|
|
18919
|
+
}, Kg = { q: null }, qg = {
|
|
18707
18920
|
tbs: null,
|
|
18708
18921
|
safe: "active",
|
|
18709
18922
|
nfpr: 0,
|
|
18710
18923
|
filter: 1
|
|
18711
18924
|
};
|
|
18712
|
-
function
|
|
18925
|
+
function Jg(e) {
|
|
18713
18926
|
let t = Ic(), n = Ic(!0), r = Lc(!0), i = {
|
|
18714
18927
|
location: t,
|
|
18715
18928
|
uule: null
|
|
@@ -18727,13 +18940,13 @@ function Hg(e) {
|
|
|
18727
18940
|
hl: r
|
|
18728
18941
|
};
|
|
18729
18942
|
return {
|
|
18730
|
-
[
|
|
18731
|
-
...
|
|
18943
|
+
[Rg]: {
|
|
18944
|
+
...Gg,
|
|
18732
18945
|
...i,
|
|
18733
18946
|
...o,
|
|
18734
|
-
...
|
|
18735
|
-
...
|
|
18736
|
-
engine:
|
|
18947
|
+
...qg,
|
|
18948
|
+
...Kg,
|
|
18949
|
+
engine: Rg,
|
|
18737
18950
|
ludocid: null,
|
|
18738
18951
|
lsig: null,
|
|
18739
18952
|
kgmid: null,
|
|
@@ -18742,29 +18955,29 @@ function Hg(e) {
|
|
|
18742
18955
|
start: null,
|
|
18743
18956
|
num: null
|
|
18744
18957
|
},
|
|
18745
|
-
[
|
|
18746
|
-
...
|
|
18958
|
+
[zg]: {
|
|
18959
|
+
...Gg,
|
|
18747
18960
|
...i,
|
|
18748
18961
|
...o,
|
|
18749
|
-
...
|
|
18750
|
-
...
|
|
18751
|
-
engine:
|
|
18962
|
+
...qg,
|
|
18963
|
+
...Kg,
|
|
18964
|
+
engine: zg,
|
|
18752
18965
|
chips: null,
|
|
18753
18966
|
ijn: null
|
|
18754
18967
|
},
|
|
18755
|
-
[
|
|
18756
|
-
...
|
|
18968
|
+
[Bg]: {
|
|
18969
|
+
...Gg,
|
|
18757
18970
|
...o,
|
|
18758
|
-
...
|
|
18759
|
-
engine:
|
|
18971
|
+
...Kg,
|
|
18972
|
+
engine: Bg,
|
|
18760
18973
|
cp: null,
|
|
18761
18974
|
client: null
|
|
18762
18975
|
},
|
|
18763
|
-
[
|
|
18764
|
-
...
|
|
18976
|
+
[Vg]: {
|
|
18977
|
+
...Gg,
|
|
18765
18978
|
...a,
|
|
18766
|
-
...
|
|
18767
|
-
engine:
|
|
18979
|
+
...Kg,
|
|
18980
|
+
engine: Vg,
|
|
18768
18981
|
data_type: null,
|
|
18769
18982
|
tz: null,
|
|
18770
18983
|
cat: null,
|
|
@@ -18772,73 +18985,73 @@ function Hg(e) {
|
|
|
18772
18985
|
date: null,
|
|
18773
18986
|
csv: null
|
|
18774
18987
|
},
|
|
18775
|
-
[
|
|
18776
|
-
...
|
|
18988
|
+
[Hg]: {
|
|
18989
|
+
...Gg,
|
|
18777
18990
|
...i,
|
|
18778
18991
|
...o,
|
|
18779
|
-
...
|
|
18780
|
-
...
|
|
18781
|
-
engine:
|
|
18992
|
+
...qg,
|
|
18993
|
+
...Kg,
|
|
18994
|
+
engine: Hg
|
|
18782
18995
|
},
|
|
18783
|
-
[
|
|
18784
|
-
...
|
|
18996
|
+
[Ug]: {
|
|
18997
|
+
...Gg,
|
|
18785
18998
|
...s,
|
|
18786
|
-
engine:
|
|
18999
|
+
engine: Ug
|
|
18787
19000
|
},
|
|
18788
|
-
[
|
|
18789
|
-
...
|
|
19001
|
+
[Wg]: {
|
|
19002
|
+
...Gg,
|
|
18790
19003
|
...s,
|
|
18791
|
-
engine:
|
|
19004
|
+
engine: Wg
|
|
18792
19005
|
}
|
|
18793
19006
|
}[e] ?? {};
|
|
18794
19007
|
}
|
|
18795
|
-
var
|
|
19008
|
+
var Yg = void 0;
|
|
18796
19009
|
typeof Sa == "function" && Sa((e) => {
|
|
18797
|
-
|
|
19010
|
+
Yg = e.scrape;
|
|
18798
19011
|
});
|
|
18799
|
-
function
|
|
19012
|
+
function Xg(e) {
|
|
18800
19013
|
let t = {};
|
|
18801
19014
|
for (let n in e) e[n] !== null && (t[n] = e[n]);
|
|
18802
19015
|
return t;
|
|
18803
19016
|
}
|
|
18804
|
-
var
|
|
18805
|
-
function
|
|
18806
|
-
let t =
|
|
18807
|
-
return t.length === 0 ? null : (e &&
|
|
19017
|
+
var Zg = 0;
|
|
19018
|
+
function Qg(e = !1) {
|
|
19019
|
+
let t = Yg?.serpApiKey?.split(",").map((e) => e.trim()).filter(Boolean) || [];
|
|
19020
|
+
return t.length === 0 ? null : (e && Zg++, Zg < t.length ? t[Zg] : null);
|
|
18808
19021
|
}
|
|
18809
|
-
var
|
|
19022
|
+
var $g = async (e, t) => {
|
|
18810
19023
|
let n = (n) => {
|
|
18811
|
-
let r =
|
|
18812
|
-
...
|
|
19024
|
+
let r = Xg({
|
|
19025
|
+
...Jg(t),
|
|
18813
19026
|
api_key: n,
|
|
18814
19027
|
q: e
|
|
18815
19028
|
});
|
|
18816
|
-
return console.log(
|
|
18817
|
-
}, r =
|
|
19029
|
+
return console.log(Lg, r), `${Lg}?${new URLSearchParams(r)}`;
|
|
19030
|
+
}, r = Qg();
|
|
18818
19031
|
for (; r;) try {
|
|
18819
19032
|
return await Ht(n(r));
|
|
18820
19033
|
} catch (e) {
|
|
18821
19034
|
if (e?.error === "quota_exceeded") {
|
|
18822
|
-
console.warn(`SerpApi: invalid api key: ${r}`, e), r =
|
|
19035
|
+
console.warn(`SerpApi: invalid api key: ${r}`, e), r = Qg(!0);
|
|
18823
19036
|
continue;
|
|
18824
19037
|
}
|
|
18825
19038
|
throw console.error(`SerpApi: ${r}`, e), e;
|
|
18826
19039
|
}
|
|
18827
19040
|
return null;
|
|
18828
|
-
},
|
|
19041
|
+
}, e_ = async (e, t, n) => {
|
|
18829
19042
|
let r = `${Da}/${ct(t)}/${ct(e)}`, i = await n.read(r);
|
|
18830
19043
|
if (i) return i;
|
|
18831
|
-
let a = await
|
|
19044
|
+
let a = await $g(e, t);
|
|
18832
19045
|
return a ? n.set(r, a) : console.warn(`SerpApi ${t}: No Result`), a ?? {};
|
|
18833
|
-
},
|
|
18834
|
-
googleSearch: async (t) =>
|
|
18835
|
-
googleImages: async (t) =>
|
|
18836
|
-
googleAutocomplete: async (t) =>
|
|
18837
|
-
googleTrends: async (t) =>
|
|
18838
|
-
googleMaps: async (t) =>
|
|
18839
|
-
googleMapsPhotos: async (t) =>
|
|
18840
|
-
googleMapsReviews: async (t) =>
|
|
18841
|
-
}),
|
|
19046
|
+
}, t_ = (e) => ({
|
|
19047
|
+
googleSearch: async (t) => e_(t, Rg, e),
|
|
19048
|
+
googleImages: async (t) => e_(t, zg, e),
|
|
19049
|
+
googleAutocomplete: async (t) => e_(t, Bg, e),
|
|
19050
|
+
googleTrends: async (t) => e_(t, Vg, e),
|
|
19051
|
+
googleMaps: async (t) => e_(t, Hg, e),
|
|
19052
|
+
googleMapsPhotos: async (t) => e_(t, Ug, e),
|
|
19053
|
+
googleMapsReviews: async (t) => e_(t, Wg, e)
|
|
19054
|
+
}), n_ = {
|
|
18842
19055
|
"+": "+",
|
|
18843
19056
|
"﹢": "+",
|
|
18844
19057
|
"-": "-",
|
|
@@ -18913,7 +19126,7 @@ var qg = async (e, t) => {
|
|
|
18913
19126
|
x: "x",
|
|
18914
19127
|
y: "y",
|
|
18915
19128
|
z: "z"
|
|
18916
|
-
},
|
|
19129
|
+
}, r_ = {
|
|
18917
19130
|
email: {
|
|
18918
19131
|
description: "Email: no spaces -> Lower/Trim",
|
|
18919
19132
|
transformations: [{
|
|
@@ -18959,7 +19172,7 @@ var qg = async (e, t) => {
|
|
|
18959
19172
|
transformations: [],
|
|
18960
19173
|
mask: ["toSlug"]
|
|
18961
19174
|
}
|
|
18962
|
-
},
|
|
19175
|
+
}, i_ = [
|
|
18963
19176
|
{
|
|
18964
19177
|
pattern: "email*",
|
|
18965
19178
|
use: "email"
|
|
@@ -18976,24 +19189,24 @@ var qg = async (e, t) => {
|
|
|
18976
19189
|
pattern: "date*",
|
|
18977
19190
|
use: "date"
|
|
18978
19191
|
}
|
|
18979
|
-
],
|
|
18980
|
-
function
|
|
18981
|
-
return e ? e.normalize("NFKC").replace(
|
|
19192
|
+
], a_ = new RegExp(Object.keys(n_).join("|"), "g");
|
|
19193
|
+
function o_(e) {
|
|
19194
|
+
return e ? e.normalize("NFKC").replace(a_, (e) => n_[e] ?? e) : "";
|
|
18982
19195
|
}
|
|
18983
|
-
var
|
|
19196
|
+
var s_ = class {
|
|
18984
19197
|
config;
|
|
18985
19198
|
matches;
|
|
18986
19199
|
constructor(e = {}, t = []) {
|
|
18987
19200
|
this.config = {
|
|
18988
|
-
...
|
|
19201
|
+
...r_,
|
|
18989
19202
|
...e
|
|
18990
|
-
}, this.matches = [...
|
|
19203
|
+
}, this.matches = [...i_, ...t];
|
|
18991
19204
|
}
|
|
18992
19205
|
apply(e, t, n = !1) {
|
|
18993
19206
|
let r = this.config[e];
|
|
18994
19207
|
if (!r) return n ? Pt(t) : t;
|
|
18995
19208
|
let i = t;
|
|
18996
|
-
i =
|
|
19209
|
+
i = o_(String(i ?? ""));
|
|
18997
19210
|
let a = r.exclusions;
|
|
18998
19211
|
if (Array.isArray(a) && a.length) {
|
|
18999
19212
|
let e = String(i).toLowerCase();
|
|
@@ -19052,7 +19265,7 @@ var t_ = class {
|
|
|
19052
19265
|
};
|
|
19053
19266
|
//#endregion
|
|
19054
19267
|
//#region src/libs/csv.ts
|
|
19055
|
-
function
|
|
19268
|
+
function c_(e, t) {
|
|
19056
19269
|
let n = Oe.parse(e, {
|
|
19057
19270
|
header: !0,
|
|
19058
19271
|
skipEmptyLines: !0,
|
|
@@ -19065,6 +19278,6 @@ function n_(e, t) {
|
|
|
19065
19278
|
};
|
|
19066
19279
|
}
|
|
19067
19280
|
//#endregion
|
|
19068
|
-
export { Xc as AIProvider,
|
|
19281
|
+
export { Xc as AIProvider, ng as AI_PROVIDER_DEFINITIONS, ig as AI_PROVIDER_DESCRIPTORS, Br as ActionButton, ef as AddressAutocomplete, Po as Alert, Bh as App, zh as AppProvider, Li as AsyncDropdown, bi as AuthButton, $r as AuthProvider, Ks as Autocomplete, an as BUILT_IN_THEMES, en as BUILT_IN_THEME_IDS, Vr as BackLink, Xn as Badge, Yn as BadgeOverlay, Wi as Brand, Qi as Breadcrumbs, Sl as CONTEXT_MENU_SEARCH_THRESHOLD, ki as Card, $i as Carousel, Ul as Chatbot, ks as Checkbox, qs as Checklist, Uo as Code, Au as CodeEditor, du as CodeSyntaxError, Kn as Col, bs as Color, Mu as Component, Nu as ComponentBlock, Wn as Container, Rl as ContextMenu, _c as CropImage, np as DEFAULT_DOCUMENT_HEAD, tp as DEFAULT_HEAD_APP_NAME, rp as DEFAULT_LANGUAGE_HEAD, Ps as DEFAULT_ORDER, Si as DataProvider, xs as Date, Cs as DateTime, Xh as DirectApiProviderAdapter, Fg as DropBoxConnectButton, Km as DropboxAuthProvider, Ii as Dropdown, Ri as DropdownButton, Vi as DropdownDivider, Bi as DropdownHeader, zi as DropdownItem, Hi as DropdownMenu, eg as EMAIL_PROVIDER_DEFINITIONS, vs as Email, vm as EmailProvider, ps as FieldError, wc as FileNameEditor, Qh as FirebaseApiProviderAdapter, zm as FirebaseAuthProvider, Fm as FirebaseDataProvider, bo as FirebaseStorageProvider, qa as FirestoreDataProvider, sd as Form, Ku as FormControllerContext, Up as Gallery, Ym as GmailEmailProvider, Hr as GoSite, gm as GoogleAuthProvider, Vd as GoogleMapsProvider, Wm as GoogleServiceAccountProvider, im as Grid, rm as GridArray, nm as GridCore, zf as GridDB, Wp as GridGalleryView, Qf as GridTableView, Mp as Head, bp as HeadProvider, Os as Hidden, Mn as I18nProvider, Q as Icon, br as IconProvider, Ui as Image, ni as ImageAvatar, lc as ImageEditor, dc as ImageField, hs as Input, js as Label, zd as LayoutBuilder, Ef as ListCard, Ns as ListGroup, wi as Loader, zr as LoadingButton, Go as LocaleSwitcher, lr as LucideIconProvider, Bp as MarkdownReader, Pi as Menu, Zh as MockApiProviderAdapter, mo as MockDataProvider, Ai as Modal, Ni as ModalOk, Mi as ModalYesNo, Ts as Month, n_ as NORMALIZE_MAP, ea as Notifications, _s as Number, ag as OPENAI_COMPATIBLE_PROVIDER_DESCRIPTOR, Ls as Order, tg as PUBLISH_PROVIDER_DEFINITIONS, am as PageUsers, Hp as Pagination, ys as Password, Zo as Percentage, fr as PhosphorIconProvider, tu as Prompt, Wl as PromptMode, xl as PromptUtils, jo as ProviderSwitcher, Es as Range, Ur as ReferSite, _d as Repeat, wf as RichText, Gn as Row, s_ as Sanitizer, na as Search, Gs as Select, If as SideNav, oc as StorageProvider, gs as String, $h as SupabaseApiProviderAdapter, Zm as SupabaseAuthProvider, oo as SupabaseDataProvider, xo as SupabaseStorageProvider, As as Switch, Td as Tab, Vp as TabDynamic, Cd as TabItem, Sd as TabLayouts, Od as Table, Ms as TextArea, fa as ThemeSwitcher, Ss as Time, aa as Toolbar, tf as UploadCSV, Mc as UploadDocument, Nc as UploadImage, Ds as Url, ws as Week, Z as Wrapper, xt as arrayUnique, Et as arraysEqual, Tt as base64Encode, At as base64ToBlob, jt as base64ToUrl, Gi as buildBreadcrumbSchema, Fl as buildTextCommandContext, wr as buttonBaseClass, Dr as buttonDangerClass, Mr as buttonDarkClass, Ar as buttonInfoClass, jr as buttonLightClass, Lr as buttonLinkClass, Fr as buttonOutlineDangerClass, Nr as buttonOutlinePrimaryClass, Pr as buttonOutlineSecondaryClass, Ir as buttonOutlineSuccessClass, Tr as buttonPrimaryClass, Er as buttonSecondaryClass, Or as buttonSuccessClass, kr as buttonWarningClass, Ia as callFirebaseFunction, ht as checkConditions, Nt as cleanRecord, X as cn, nl as configureProxy, et as converter, it as copyToClipboard, gt as crc32, sg as createAIProviderRegistry, tr as createMotionTransition, wn as createTranslations, rt as decodeJWT, Cn as defineLocaleMessages, lt as dirname, Ig as dropBox, ft as eventClosest, Ht as fetchJson, Vt as fetchRest, Ut as fetchWithRetry, as as fieldAddonClass, ns as fieldControlBaseClass, ts as fieldFeedbackClass, is as fieldGroupClass, es as fieldLabelClass, rs as fieldTextAreaBaseClass, qc as formatAIModelRef, dt as generateUniqueId, ml as getAIModelCatalog, vi as getAccessToken, Ml as getAutoClosedSuffixLength, xu as getCodeValidationResult, jc as getFileUrl, Yr as getGlobalVars, mg as getGoogleTrendsData, hg as getGoogleTrendsRelated, pg as getKeywordIdeas, ai as getProviderConfigurationState, Mt as getRecordValue, yd as getTabLayoutConfig, xd as getTabPaneClassName, bd as getTabTriggerClassName, qm as googleGetAccessToken, jl as hasAutoClosedSuffix, Tn as interpolate, yt as intersectObjects, qn as isBadgeDescriptor, St as isEmpty, Ot as isInteractiveElement, al as isProxyEnabled, Gd as loadGoogleMaps, vt as loadScripts, qh as locales, Nl as matchCommandTrigger, Jn as normalizeBadgeProps, ct as normalizeKey, ot as normalizePath, o_ as normalizeVisualChars, Jc as parseAIModelRef, c_ as parseCsvText, ti as path, rl as proxyFetch, Co as registerProviderSessionFactory, Zr as removeGlobalVars, kt as render2Base64, mt as replacePlaceholders, bt as replaceVariables, nr as resolveMotionEffect, uu as runPrompt, wt as safeClone, Dt as sanitizeKey, t_ as scrape, Jm as sendEmail, Xr as setGlobalVars, ut as sleep, Pt as smartTypeCast, pt as substrCount, rg as toProviderDescriptor, at as trimPath, st as trimSlash, _t as ucfirst, Zc as useAIProvider, Qc as useAIProviderRegistry, hi as useAccessToken, Jh as useApiProvider, kp as useAssetsHead, ei as useAuthProvider, Sm as useCredentialsProvider, Ci as useDataProvider, Op as useDocumentHead, Pg as useDropBoxConnect, $o as useEditorHeight, ym as useEmailProvider, or as useEnterMotion, Tc as useFileUploadCore, Ju as useFormActions, rd as useFormContext, qu as useFormController, Jr as useGlobalVars, Hd as useGoogleMapsConfig, Cp as useHead, Tp as useHeadLinks, Nn as useI18n, Sr as useIconController, xr as useIconProvider, Qs as useImage, Dp as useLanguageHead, Vh as useMenu, rr as useMotionEffect, ir as useMotionState, Ep as usePaginationHead, ar as usePressMotion, _a as useProvider, ko as useProviderSession, il as useProxy, Ap as usePwaHead, jp as useSchemaOrgHead, ga as useSetProvider, wp as useSocialHead, sc as useStorageProvider, Y as useTheme, xn as useThemeController, bu as validateCodeSyntax };
|
|
19069
19282
|
|
|
19070
19283
|
//# sourceMappingURL=index.mjs.map
|