@pstdio/ui 0.44.0 → 0.45.0-nightly.20261021030241
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/{MermaidComponent-DhNTaUMt.js → MermaidComponent-CTWuGAqI.js} +2 -2
- package/dist/{MermaidComponent-DhNTaUMt.js.map → MermaidComponent-CTWuGAqI.js.map} +1 -1
- package/dist/alert-CO-uOKLm.js +409 -0
- package/dist/alert-CO-uOKLm.js.map +1 -0
- package/dist/chat-ui.d.ts +7 -5
- package/dist/chat-ui.js +1110 -1119
- package/dist/chat-ui.js.map +1 -1
- package/dist/{collection-view-grouping-BKIr4QAb.js → collection-view-grouping-BQMfKdQG.js} +2 -2
- package/dist/{collection-view-grouping-BKIr4QAb.js.map → collection-view-grouping-BQMfKdQG.js.map} +1 -1
- package/dist/{collection-view-search-D7HFymZW.js → collection-view-search-DS9U9WAl.js} +2 -2
- package/dist/{collection-view-search-D7HFymZW.js.map → collection-view-search-DS9U9WAl.js.map} +1 -1
- package/dist/collection-view.d.ts +90 -3
- package/dist/collection-view.js +1 -1
- package/dist/data-table.d.ts +1 -2
- package/dist/data-table.js +4 -4
- package/dist/{diff-viewer-Cpiw-1ut.js → diff-viewer-ChEyTNpa.js} +2 -2
- package/dist/{diff-viewer-Cpiw-1ut.js.map → diff-viewer-ChEyTNpa.js.map} +1 -1
- package/dist/diff.js +2 -2
- package/dist/{display-sort-control-BuqijDAl.js → display-sort-control-BUMkmlIu.js} +3 -3
- package/dist/{display-sort-control-BuqijDAl.js.map → display-sort-control-BUMkmlIu.js.map} +1 -1
- package/dist/{edit-mode-data-table-BwNTRik5.js → edit-mode-data-table-MKEjfFUw.js} +4 -4
- package/dist/{edit-mode-data-table-BwNTRik5.js.map → edit-mode-data-table-MKEjfFUw.js.map} +1 -1
- package/dist/icon-options-DpzDAnlu.js +313 -0
- package/dist/icon-options-DpzDAnlu.js.map +1 -0
- package/dist/{index-DTjRTEez.d.ts → index-C0PaeiBy.d.ts} +8 -1
- package/dist/{index-Bq1BDCBk.d.ts → index-eV_0Gjzo.d.ts} +4 -2
- package/dist/index.d.ts +16 -2
- package/dist/index.js +862 -780
- package/dist/index.js.map +1 -1
- package/dist/kanban-renderer.d.ts +2 -2
- package/dist/kanban-renderer.js +596 -397
- package/dist/kanban-renderer.js.map +1 -1
- package/dist/{markdown-editor-DUBUE7M-.js → markdown-editor-BPGIS9ku.js} +996 -876
- package/dist/markdown-editor-BPGIS9ku.js.map +1 -0
- package/dist/param-editor-Bva0M7Ns.js +374 -0
- package/dist/param-editor-Bva0M7Ns.js.map +1 -0
- package/dist/{param-editor-field-B5z6200g.js → param-editor-field-BPBlweVg.js} +1183 -1161
- package/dist/param-editor-field-BPBlweVg.js.map +1 -0
- package/dist/param-editor.d.ts +57 -2
- package/dist/param-editor.js +3 -3
- package/dist/{resolve-icon-component-Ck6ZyRnc.js → resolve-icon-component-Dy0pOuj5.js} +2 -2
- package/dist/{resolve-icon-component-Ck6ZyRnc.js.map → resolve-icon-component-Dy0pOuj5.js.map} +1 -1
- package/dist/{rich-text-2c_ra5gK.js → rich-text-CH2psble.js} +569 -524
- package/dist/rich-text-CH2psble.js.map +1 -0
- package/dist/rich-text.d.ts +1 -1
- package/dist/rich-text.js +3 -3
- package/dist/terminal.js +1 -1
- package/dist/{theme-Chgjys_o.js → theme-BsStBWWL.js} +255 -155
- package/dist/theme-BsStBWWL.js.map +1 -0
- package/dist/theme.js +1 -1
- package/dist/{tree-list-B8Gtot1M.js → tree-list-aNC_UTGS.js} +396 -341
- package/dist/tree-list-aNC_UTGS.js.map +1 -0
- package/package.json +2 -2
- package/dist/alert-MQ47wy7f.js +0 -388
- package/dist/alert-MQ47wy7f.js.map +0 -1
- package/dist/icon-options-Tt6Wzhtv.js +0 -308
- package/dist/icon-options-Tt6Wzhtv.js.map +0 -1
- package/dist/index-kYQwGcym.d.ts +0 -91
- package/dist/markdown-editor-DUBUE7M-.js.map +0 -1
- package/dist/param-editor-DK1uCOh3.js +0 -225
- package/dist/param-editor-DK1uCOh3.js.map +0 -1
- package/dist/param-editor-field-B5z6200g.js.map +0 -1
- package/dist/rich-text-2c_ra5gK.js.map +0 -1
- package/dist/theme-Chgjys_o.js.map +0 -1
- package/dist/tree-list-B8Gtot1M.js.map +0 -1
package/dist/index.js
CHANGED
|
@@ -1,34 +1,34 @@
|
|
|
1
|
-
import { a as e, c as t, i as n, l as r, n as i, o as a, r as o, s, t as c } from "./alert-
|
|
1
|
+
import { a as e, c as t, i as n, l as r, n as i, o as a, r as o, s, t as c } from "./alert-CO-uOKLm.js";
|
|
2
2
|
import { n as l, t as u } from "./scroll-area-IeoRS73V.js";
|
|
3
3
|
import { c as d, l as f, o as p, r as m, t as h, u as g } from "./list-row-BDDAVuVd.js";
|
|
4
4
|
import { t as _ } from "./use-virtualizer-CqDYJolY.js";
|
|
5
|
-
import { n as v, r as y, t as b } from "./tree-list-
|
|
5
|
+
import { n as v, r as y, t as b } from "./tree-list-aNC_UTGS.js";
|
|
6
6
|
import { a as x, i as S, n as C, o as w, r as T, s as E, t as D } from "./prism-E3-NXX_t.js";
|
|
7
7
|
import { a as O, i as k, n as A, o as j, r as M, t as N } from "./workspace-badge-DqQKSUJw.js";
|
|
8
|
-
import { a as P, i as
|
|
9
|
-
import { t as
|
|
10
|
-
import { t as
|
|
11
|
-
import { i as
|
|
12
|
-
import { n as
|
|
13
|
-
import { t as
|
|
14
|
-
import { n as
|
|
15
|
-
import { n as
|
|
16
|
-
import { a as
|
|
17
|
-
import { t as
|
|
18
|
-
import { AbsoluteCenter as
|
|
8
|
+
import { a as P, i as ee, n as F, r as I, t as L } from "./host-storage-28AkEy1N.js";
|
|
9
|
+
import { t as R } from "./drop-indicator-HjlBSIeV.js";
|
|
10
|
+
import { t as z } from "./empty-state-3mVV_pV-.js";
|
|
11
|
+
import { i as B, n as te, r as ne, t as re } from "./icon-options-DpzDAnlu.js";
|
|
12
|
+
import { n as ie, t as ae } from "./radio-CiFrDN6O.js";
|
|
13
|
+
import { t as V } from "./browser-storage-C_ipoNwP.js";
|
|
14
|
+
import { n as H, r as U, t as oe } from "./theme-BsStBWWL.js";
|
|
15
|
+
import { n as W, t as se } from "./theme-kKuLN2jb.js";
|
|
16
|
+
import { a as ce, c as le, i as ue, l as de, n as fe, o as pe, r as me, s as he, t as ge } from "./theme-preference-BV4cbJNB.js";
|
|
17
|
+
import { t as _e } from "./resolve-icon-component-Dy0pOuj5.js";
|
|
18
|
+
import { AbsoluteCenter as ve, Badge as ye, Box as G, Breadcrumb as be, Button as xe, Center as Se, ChakraProvider as Ce, CloseButton as we, Collapsible as Te, Dialog as K, Editable as Ee, Flex as q, Grid as De, HStack as J, Icon as Y, IconButton as Oe, Input as ke, InputGroup as Ae, Kbd as je, Menu as Me, Popover as Ne, Portal as Pe, Skeleton as Fe, Spacer as Ie, Spinner as Le, Stack as Re, Text as X, Textarea as ze, Toast as Be, Toaster as Ve, chakra as He, createSlotRecipeContext as Ue, createToaster as We, defineRecipe as Ge, defineSlotRecipe as Ke, useRecipe as qe, useSlotRecipe as Je } from "@chakra-ui/react";
|
|
19
19
|
import { c as Z } from "react/compiler-runtime";
|
|
20
20
|
import { Fragment as Ye, jsx as Q, jsxs as $ } from "react/jsx-runtime";
|
|
21
21
|
import * as Xe from "react";
|
|
22
22
|
import { Component as Ze, Fragment as Qe, createContext as $e, forwardRef as et, useContext as tt, useEffect as nt, useRef as rt, useState as it } from "react";
|
|
23
|
-
import { ArrowLeft as at, ArrowRight as ot, ArrowUp as st, Bell as ct, Check as lt, ChevronDown as ut, ChevronRight as dt, Command as ft, Copy as pt, Folder as mt, FolderPlus as ht, GripVertical as gt,
|
|
24
|
-
import { DndContext as
|
|
25
|
-
import { SortableContext as
|
|
26
|
-
import { useStore as
|
|
27
|
-
import { createJSONStorage as
|
|
28
|
-
import { createStore as
|
|
29
|
-
import { CSS as
|
|
23
|
+
import { ArrowLeft as at, ArrowRight as ot, ArrowUp as st, Bell as ct, Check as lt, ChevronDown as ut, ChevronRight as dt, Command as ft, Copy as pt, Folder as mt, FolderPlus as ht, GripVertical as gt, HardDrive as _t, Home as vt, Minus as yt, Option as bt, Paperclip as xt, Plus as St, Search as Ct, SquareArrowOutUpRight as wt, Trash2 as Tt, X as Et } from "lucide-react";
|
|
24
|
+
import { DndContext as Dt, KeyboardSensor as Ot, PointerSensor as kt, closestCenter as At, useSensor as jt, useSensors as Mt } from "@dnd-kit/core";
|
|
25
|
+
import { SortableContext as Nt, arrayMove as Pt, horizontalListSortingStrategy as Ft, sortableKeyboardCoordinates as It, useSortable as Lt, verticalListSortingStrategy as Rt } from "@dnd-kit/sortable";
|
|
26
|
+
import { useStore as zt } from "zustand";
|
|
27
|
+
import { createJSONStorage as Bt, persist as Vt } from "zustand/middleware";
|
|
28
|
+
import { createStore as Ht } from "zustand/vanilla";
|
|
29
|
+
import { CSS as Ut } from "@dnd-kit/utilities";
|
|
30
30
|
//#region src/components/activity/activity-composer.tsx
|
|
31
|
-
var
|
|
31
|
+
var Wt = (e) => {
|
|
32
32
|
let { actor: t, value: n, defaultValue: i = "", placeholder: a = "Leave a comment...", variant: o = "standalone", minRows: s = o === "standalone" ? 3 : 1, attachLabel: c = "Attach file", submitLabel: u = "Submit comment", actions: d, onAttach: f, onChange: p, onSubmit: m, ...h } = e, [g, _] = it(i), v = n ?? g, y = o === "inline", b = v.trim().length > 0, x = (e) => {
|
|
33
33
|
n === void 0 && _(e), p?.(e);
|
|
34
34
|
};
|
|
@@ -49,7 +49,7 @@ var Ut = (e) => {
|
|
|
49
49
|
alignItems: "flex-start",
|
|
50
50
|
gap: "xs",
|
|
51
51
|
padding: y ? "sm" : "md",
|
|
52
|
-
children: [t ? /* @__PURE__ */ Q(r, { actor: t }) : null, /* @__PURE__ */ $(
|
|
52
|
+
children: [t ? /* @__PURE__ */ Q(r, { actor: t }) : null, /* @__PURE__ */ $(G, {
|
|
53
53
|
flex: "1",
|
|
54
54
|
minW: "0",
|
|
55
55
|
children: [/* @__PURE__ */ Q(ze, {
|
|
@@ -80,7 +80,7 @@ var Ut = (e) => {
|
|
|
80
80
|
type: "button",
|
|
81
81
|
onClick: f,
|
|
82
82
|
children: /* @__PURE__ */ Q(Y, {
|
|
83
|
-
as:
|
|
83
|
+
as: xt,
|
|
84
84
|
boxSize: "14px"
|
|
85
85
|
})
|
|
86
86
|
})
|
|
@@ -104,7 +104,7 @@ var Ut = (e) => {
|
|
|
104
104
|
})]
|
|
105
105
|
})
|
|
106
106
|
});
|
|
107
|
-
},
|
|
107
|
+
}, Gt = {
|
|
108
108
|
Root: e,
|
|
109
109
|
Header: n,
|
|
110
110
|
Feed: o,
|
|
@@ -112,15 +112,15 @@ var Ut = (e) => {
|
|
|
112
112
|
Event: a,
|
|
113
113
|
Comment: s,
|
|
114
114
|
Reply: t,
|
|
115
|
-
Composer:
|
|
115
|
+
Composer: Wt,
|
|
116
116
|
Avatar: r
|
|
117
|
-
},
|
|
117
|
+
}, Kt = 48, qt = (e) => {
|
|
118
118
|
let t = typeof e.label == "string" ? e.label : "", n = typeof e.secondaryLabel == "string" ? e.secondaryLabel : "";
|
|
119
119
|
return `${t} ${e.searchText ?? ""} ${n}`;
|
|
120
|
-
},
|
|
121
|
-
let r = t.find((t) => t.id === n && t.inputPrefix &&
|
|
120
|
+
}, Jt = (e, t) => e.trimStart().startsWith(t), Yt = (e, t = [], n) => t.find((t) => t.inputPrefix && Jt(e, t.inputPrefix))?.id ?? n ?? t.find((e) => !e.inputPrefix)?.id ?? t[0]?.id, Xt = (e, t = [], n) => {
|
|
121
|
+
let r = t.find((t) => t.id === n && t.inputPrefix && Jt(e, t.inputPrefix));
|
|
122
122
|
return r?.inputPrefix ? e.trimStart().slice(r.inputPrefix.length).trim() : e.trim();
|
|
123
|
-
},
|
|
123
|
+
}, Zt = (e, t) => {
|
|
124
124
|
let n = {};
|
|
125
125
|
return e.filter((e) => {
|
|
126
126
|
let r = e.assetType;
|
|
@@ -128,10 +128,10 @@ var Ut = (e) => {
|
|
|
128
128
|
let i = n[r] ?? 0;
|
|
129
129
|
return i >= t ? !1 : (n[r] = i + 1, !0);
|
|
130
130
|
});
|
|
131
|
-
},
|
|
132
|
-
let n = (t.getEffectiveQuery?.(t.query) ?? t.query.trim()).toLowerCase(), r = e.filter((e) => t.mode && e.mode !== t.mode ? !1 : !n ||
|
|
133
|
-
return n || t.defaultAssetLimit === void 0 ? r :
|
|
134
|
-
},
|
|
131
|
+
}, Qt = (e, t) => {
|
|
132
|
+
let n = (t.getEffectiveQuery?.(t.query) ?? t.query.trim()).toLowerCase(), r = e.filter((e) => t.mode && e.mode !== t.mode ? !1 : !n || qt(e).toLowerCase().includes(n));
|
|
133
|
+
return n || t.defaultAssetLimit === void 0 ? r : Zt(r, t.defaultAssetLimit);
|
|
134
|
+
}, $t = 24, en = 40, tn = 384, nn = (e) => ({
|
|
135
135
|
id: e.id,
|
|
136
136
|
label: e.label,
|
|
137
137
|
description: e.description ?? e.secondaryLabel,
|
|
@@ -145,7 +145,7 @@ var Ut = (e) => {
|
|
|
145
145
|
}) : null]
|
|
146
146
|
}) : void 0),
|
|
147
147
|
onActivate: e.onActivate
|
|
148
|
-
}),
|
|
148
|
+
}), rn = (e) => {
|
|
149
149
|
let t = [];
|
|
150
150
|
return e.forEach((n, r) => {
|
|
151
151
|
let i = e[r - 1];
|
|
@@ -160,15 +160,15 @@ var Ut = (e) => {
|
|
|
160
160
|
entryIndex: r
|
|
161
161
|
});
|
|
162
162
|
}), t;
|
|
163
|
-
},
|
|
164
|
-
let t = Z(8), { entries: n, activeIndex: r, emptyLabel: i, onHover: a, scrollRef: o } = e, s =
|
|
163
|
+
}, an = (e, t) => e.findIndex((e) => e.type === "entry" && e.entryIndex === t), on = (e) => {
|
|
164
|
+
let t = Z(8), { entries: n, activeIndex: r, emptyLabel: i, onHover: a, scrollRef: o } = e, s = rn(n), c = an(s, r), { virtualizer: l, virtualItems: u, totalSize: d } = _({
|
|
165
165
|
count: s.length,
|
|
166
166
|
getScrollElement: () => o.current,
|
|
167
|
-
estimateSize: (e) => s[e]?.type === "group" ?
|
|
167
|
+
estimateSize: (e) => s[e]?.type === "group" ? $t : en,
|
|
168
168
|
getItemKey: (e) => s[e]?.id ?? e,
|
|
169
169
|
initialRect: {
|
|
170
170
|
width: 0,
|
|
171
|
-
height:
|
|
171
|
+
height: tn
|
|
172
172
|
},
|
|
173
173
|
overscan: 6
|
|
174
174
|
});
|
|
@@ -187,11 +187,11 @@ var Ut = (e) => {
|
|
|
187
187
|
children: i
|
|
188
188
|
}), t[0] = i, t[1] = e), e;
|
|
189
189
|
}
|
|
190
|
-
let f =
|
|
190
|
+
let f = G, p;
|
|
191
191
|
t[2] === d ? p = t[3] : (p = { height: d }, t[2] = d, t[3] = p);
|
|
192
192
|
let m = u.map((e) => {
|
|
193
193
|
let t = s[e.index];
|
|
194
|
-
return t ? /* @__PURE__ */ Q(
|
|
194
|
+
return t ? /* @__PURE__ */ Q(G, {
|
|
195
195
|
"data-index": e.index,
|
|
196
196
|
ref: l.measureElement,
|
|
197
197
|
position: "absolute",
|
|
@@ -207,7 +207,7 @@ var Ut = (e) => {
|
|
|
207
207
|
children: t.label
|
|
208
208
|
}) : /* @__PURE__ */ Q(h, {
|
|
209
209
|
variant: "full-width",
|
|
210
|
-
...
|
|
210
|
+
...nn(t.entry),
|
|
211
211
|
isSelected: t.entryIndex === r,
|
|
212
212
|
tabIndex: -1,
|
|
213
213
|
onPointerMove: () => a(t.entryIndex)
|
|
@@ -221,15 +221,15 @@ var Ut = (e) => {
|
|
|
221
221
|
style: p,
|
|
222
222
|
children: m
|
|
223
223
|
}), t[4] = f, t[5] = p, t[6] = m, t[7] = g) : g = t[7], g;
|
|
224
|
-
},
|
|
224
|
+
}, sn = (e) => e != null, cn = (e, t) => e && t ? "space-between" : t ? "flex-end" : "flex-start", ln = (e) => {
|
|
225
225
|
let t = Z(52), { children: n, searchValue: r, searchPlaceholder: i, searchAriaLabel: a, searchIcon: o, searchInputRef: s, searchAutoFocus: c, showSearch: l, title: d, showCloseButton: f, closeButtonLabel: p, bodyBefore: m, footerStart: h, footerEnd: g, scrollAreaProps: _, onSearchChange: v, onSearchKeyDown: y } = e, b = a === void 0 ? i : a, x = l === void 0 || l, S = f !== void 0 && f, C = p === void 0 ? "Close" : p, w;
|
|
226
226
|
if (t[0] !== m || t[1] !== n || t[2] !== C || t[3] !== g || t[4] !== h || t[5] !== v || t[6] !== y || t[7] !== _ || t[8] !== b || t[9] !== c || t[10] !== o || t[11] !== s || t[12] !== i || t[13] !== r || t[14] !== S || t[15] !== x || t[16] !== d) {
|
|
227
|
-
let e =
|
|
227
|
+
let e = sn(h), a = sn(g), l;
|
|
228
228
|
t[18] === _ ? l = t[19] : (l = _ ?? {}, t[18] = _, t[19] = l);
|
|
229
229
|
let f, p, T;
|
|
230
230
|
t[20] === l ? (f = t[21], p = t[22], T = t[23]) : ({maxH: p, showHorizontalScrollbar: T, ...f} = l, t[20] = l, t[21] = f, t[22] = p, t[23] = T);
|
|
231
231
|
let E = p === void 0 ? "24rem" : p, D = T !== void 0 && T, O;
|
|
232
|
-
t[24] !== x || t[25] !== d ? (O = d && /* @__PURE__ */ Q(
|
|
232
|
+
t[24] !== x || t[25] !== d ? (O = d && /* @__PURE__ */ Q(K.Title, {
|
|
233
233
|
srOnly: x,
|
|
234
234
|
px: "sm",
|
|
235
235
|
py: "sm",
|
|
@@ -254,16 +254,16 @@ var Ut = (e) => {
|
|
|
254
254
|
})
|
|
255
255
|
}), t[27] = v, t[28] = y, t[29] = b, t[30] = c, t[31] = o, t[32] = s, t[33] = i, t[34] = r, t[35] = x, t[36] = k) : k = t[36];
|
|
256
256
|
let A;
|
|
257
|
-
t[37] !== C || t[38] !== S ? (A = S ? /* @__PURE__ */ Q(
|
|
257
|
+
t[37] !== C || t[38] !== S ? (A = S ? /* @__PURE__ */ Q(K.CloseTrigger, {
|
|
258
258
|
asChild: !0,
|
|
259
|
-
children: /* @__PURE__ */ Q(
|
|
259
|
+
children: /* @__PURE__ */ Q(we, {
|
|
260
260
|
"aria-label": C,
|
|
261
261
|
size: "sm",
|
|
262
262
|
mr: "2"
|
|
263
263
|
})
|
|
264
264
|
}) : null, t[37] = C, t[38] = S, t[39] = A) : A = t[39];
|
|
265
265
|
let j;
|
|
266
|
-
t[40] !== A || t[41] !== O || t[42] !== k ? (j = /* @__PURE__ */ $(
|
|
266
|
+
t[40] !== A || t[41] !== O || t[42] !== k ? (j = /* @__PURE__ */ $(K.Header, {
|
|
267
267
|
px: "0",
|
|
268
268
|
py: "0",
|
|
269
269
|
minH: "3rem",
|
|
@@ -283,22 +283,22 @@ var Ut = (e) => {
|
|
|
283
283
|
children: n
|
|
284
284
|
}), t[44] = n, t[45] = E, t[46] = f, t[47] = D, t[48] = M) : M = t[48];
|
|
285
285
|
let N;
|
|
286
|
-
t[49] !== m || t[50] !== M ? (N = /* @__PURE__ */ $(
|
|
286
|
+
t[49] !== m || t[50] !== M ? (N = /* @__PURE__ */ $(K.Body, {
|
|
287
287
|
p: "0",
|
|
288
288
|
children: [m, M]
|
|
289
289
|
}), t[49] = m, t[50] = M, t[51] = N) : N = t[51], w = /* @__PURE__ */ $(Ye, { children: [
|
|
290
290
|
j,
|
|
291
291
|
N,
|
|
292
|
-
e || a ? /* @__PURE__ */ $(
|
|
293
|
-
justifyContent:
|
|
292
|
+
e || a ? /* @__PURE__ */ $(K.Footer, {
|
|
293
|
+
justifyContent: cn(e, a),
|
|
294
294
|
px: "sm",
|
|
295
295
|
py: "xs",
|
|
296
296
|
borderTopWidth: "1px",
|
|
297
297
|
borderTopColor: "border.subtle",
|
|
298
|
-
children: [e ? /* @__PURE__ */ Q(
|
|
298
|
+
children: [e ? /* @__PURE__ */ Q(G, {
|
|
299
299
|
minW: "0",
|
|
300
300
|
children: h
|
|
301
|
-
}) : null, a ? /* @__PURE__ */ Q(
|
|
301
|
+
}) : null, a ? /* @__PURE__ */ Q(G, {
|
|
302
302
|
flexShrink: 0,
|
|
303
303
|
children: g
|
|
304
304
|
}) : null]
|
|
@@ -306,141 +306,141 @@ var Ut = (e) => {
|
|
|
306
306
|
] }), t[0] = m, t[1] = n, t[2] = C, t[3] = g, t[4] = h, t[5] = v, t[6] = y, t[7] = _, t[8] = b, t[9] = c, t[10] = o, t[11] = s, t[12] = i, t[13] = r, t[14] = S, t[15] = x, t[16] = d, t[17] = w;
|
|
307
307
|
} else w = t[17];
|
|
308
308
|
return w;
|
|
309
|
-
},
|
|
309
|
+
}, un = (e, t, n) => typeof e == "function" ? e(t) : e ?? n, dn = (e) => {
|
|
310
310
|
let t = Z(109), { open: n, label: r, fullScreen: i, searchAutoFocus: a, entries: o, initialQuery: s, initialActiveIndex: c, mode: l, modes: u, resetKey: d, inputIcon: f, placeholder: p, emptyLabel: m, footerStart: h, footerEnd: g, filterEntries: _, onActiveEntryChange: v, onQueryChange: y, onClose: b, onEscape: x } = e, S = r === void 0 ? "Command palette" : r, C = i !== void 0 && i, w = a === void 0 || a, T = s === void 0 ? "" : s, E = c === void 0 ? 0 : c, D = d === void 0 ? "default" : d, O = m === void 0 ? "No results." : m, k;
|
|
311
311
|
t[0] === Symbol.for("react.memo_cache_sentinel") ? (k = { key: "palette" }, t[0] = k) : k = t[0];
|
|
312
312
|
let A = Je(k), j;
|
|
313
313
|
t[1] !== C || t[2] !== A ? (j = A({ fullScreen: C }), t[1] = C, t[2] = A, t[3] = j) : j = t[3];
|
|
314
314
|
let M = j, N;
|
|
315
315
|
t[4] !== o || t[5] !== _ || t[6] !== l || t[7] !== u ? (N = (e) => {
|
|
316
|
-
let t = l ??
|
|
317
|
-
return _ ? _(o, e, t) :
|
|
316
|
+
let t = l ?? Yt(e, u);
|
|
317
|
+
return _ ? _(o, e, t) : Qt(o, {
|
|
318
318
|
query: e,
|
|
319
319
|
mode: t,
|
|
320
|
-
getEffectiveQuery: (e) =>
|
|
320
|
+
getEffectiveQuery: (e) => Xt(e, u, t)
|
|
321
321
|
});
|
|
322
322
|
}, t[4] = o, t[5] = _, t[6] = l, t[7] = u, t[8] = N) : N = t[8];
|
|
323
|
-
let P = N,
|
|
324
|
-
t[9] !== P || t[10] !== E || t[11] !== T ? (
|
|
323
|
+
let P = N, ee;
|
|
324
|
+
t[9] !== P || t[10] !== E || t[11] !== T ? (ee = () => ({
|
|
325
325
|
query: T,
|
|
326
326
|
activeId: P(T)[E]?.id ?? null
|
|
327
|
-
}), t[9] = P, t[10] = E, t[11] = T, t[12] =
|
|
328
|
-
let [
|
|
329
|
-
t[13] === D ?
|
|
327
|
+
}), t[9] = P, t[10] = E, t[11] = T, t[12] = ee) : ee = t[12];
|
|
328
|
+
let [F, I] = it(ee), { query: L, activeId: R } = F, z;
|
|
329
|
+
t[13] === D ? z = t[14] : (z = {
|
|
330
330
|
open: !1,
|
|
331
331
|
resetKey: D
|
|
332
|
-
}, t[13] = D, t[14] =
|
|
333
|
-
let [
|
|
334
|
-
|
|
332
|
+
}, t[13] = D, t[14] = z);
|
|
333
|
+
let [B, te] = it(z), ne = rt(null), re = rt(null), ie = rt(null), ae = B.open !== n || B.resetKey !== D;
|
|
334
|
+
ae && (te({
|
|
335
335
|
open: n,
|
|
336
336
|
resetKey: D
|
|
337
|
-
}), n &&
|
|
337
|
+
}), n && I({
|
|
338
338
|
query: T,
|
|
339
339
|
activeId: P(T)[E]?.id ?? null
|
|
340
340
|
}));
|
|
341
|
-
let H, U,
|
|
342
|
-
if (t[15] !==
|
|
343
|
-
let e = l ??
|
|
344
|
-
|
|
341
|
+
let V, H, U, oe, W, se, ce;
|
|
342
|
+
if (t[15] !== R || t[16] !== P || t[17] !== f || t[18] !== l || t[19] !== u || t[20] !== p || t[21] !== L || t[22] !== F || t[23] !== ae) {
|
|
343
|
+
let e = l ?? Yt(L, u);
|
|
344
|
+
U = P(L);
|
|
345
345
|
let n;
|
|
346
|
-
t[31] ===
|
|
347
|
-
...
|
|
348
|
-
activeId:
|
|
346
|
+
t[31] === R ? n = t[32] : (n = (e) => e.id === R, t[31] = R, t[32] = n), H = Math.max(U.findIndex(n), 0), V = U[H] ?? null, !ae && (V?.id ?? null) !== R && I({
|
|
347
|
+
...F,
|
|
348
|
+
activeId: V?.id ?? null
|
|
349
349
|
});
|
|
350
350
|
let r;
|
|
351
351
|
t[33] === P ? r = t[34] : (r = (e) => {
|
|
352
|
-
|
|
352
|
+
I((t) => {
|
|
353
353
|
let n = P(t.query), r = Math.max(n.findIndex((e) => e.id === t.activeId), 0), i = typeof e == "function" ? e(r) : e;
|
|
354
354
|
return {
|
|
355
355
|
...t,
|
|
356
356
|
activeId: n[i]?.id ?? null
|
|
357
357
|
};
|
|
358
358
|
});
|
|
359
|
-
}, t[33] = P, t[34] = r),
|
|
360
|
-
query:
|
|
359
|
+
}, t[33] = P, t[34] = r), W = r, se = {
|
|
360
|
+
query: L,
|
|
361
361
|
mode: e,
|
|
362
|
-
activeIndex:
|
|
363
|
-
entries:
|
|
364
|
-
},
|
|
365
|
-
} else
|
|
366
|
-
let
|
|
367
|
-
t[35] === y ?
|
|
368
|
-
|
|
362
|
+
activeIndex: H,
|
|
363
|
+
entries: U
|
|
364
|
+
}, oe = un(f, se, null), ce = un(p, se, "Search"), t[15] = R, t[16] = P, t[17] = f, t[18] = l, t[19] = u, t[20] = p, t[21] = L, t[22] = F, t[23] = ae, t[24] = V, t[25] = H, t[26] = U, t[27] = oe, t[28] = W, t[29] = se, t[30] = ce;
|
|
365
|
+
} else V = t[24], H = t[25], U = t[26], oe = t[27], W = t[28], se = t[29], ce = t[30];
|
|
366
|
+
let le = ce, ue;
|
|
367
|
+
t[35] === y ? ue = t[36] : (ue = (e) => {
|
|
368
|
+
I({
|
|
369
369
|
query: e,
|
|
370
370
|
activeId: null
|
|
371
371
|
}), y?.(e);
|
|
372
|
-
}, t[35] = y, t[36] =
|
|
373
|
-
let
|
|
374
|
-
t[37] ===
|
|
375
|
-
|
|
376
|
-
}, t[37] =
|
|
377
|
-
let
|
|
378
|
-
t[39] === b ?
|
|
372
|
+
}, t[35] = y, t[36] = ue);
|
|
373
|
+
let de = ue, fe;
|
|
374
|
+
t[37] === V ? fe = t[38] : (fe = () => {
|
|
375
|
+
V?.onActivate();
|
|
376
|
+
}, t[37] = V, t[38] = fe);
|
|
377
|
+
let pe = fe, me;
|
|
378
|
+
t[39] === b ? me = t[40] : (me = () => {
|
|
379
379
|
b();
|
|
380
|
-
}, t[39] = b, t[40] =
|
|
381
|
-
let
|
|
382
|
-
t[41] !== w || t[42] !==
|
|
383
|
-
if (!
|
|
380
|
+
}, t[39] = b, t[40] = me);
|
|
381
|
+
let he = me, ge;
|
|
382
|
+
t[41] !== w || t[42] !== B.open ? (ge = () => {
|
|
383
|
+
if (!B.open || !w) return;
|
|
384
384
|
let e = setTimeout(() => {
|
|
385
|
-
let e =
|
|
385
|
+
let e = ne.current;
|
|
386
386
|
if (!e) return;
|
|
387
387
|
e.focus();
|
|
388
388
|
let t = e.value.length;
|
|
389
389
|
e.setSelectionRange(t, t);
|
|
390
390
|
}, 0);
|
|
391
391
|
return () => clearTimeout(e);
|
|
392
|
-
}, t[41] = w, t[42] =
|
|
393
|
-
let
|
|
394
|
-
t[44] !== w || t[45] !==
|
|
395
|
-
let
|
|
396
|
-
t[47] !==
|
|
397
|
-
v?.(
|
|
398
|
-
}, t[47] =
|
|
399
|
-
let
|
|
400
|
-
t[51] !==
|
|
401
|
-
let
|
|
402
|
-
t[54] !==
|
|
392
|
+
}, t[41] = w, t[42] = B.open, t[43] = ge) : ge = t[43];
|
|
393
|
+
let _e;
|
|
394
|
+
t[44] !== w || t[45] !== B ? (_e = [B, w], t[44] = w, t[45] = B, t[46] = _e) : _e = t[46], nt(ge, _e);
|
|
395
|
+
let ve = V?.id, ye;
|
|
396
|
+
t[47] !== V || t[48] !== H || t[49] !== v ? (ye = () => {
|
|
397
|
+
v?.(V, H);
|
|
398
|
+
}, t[47] = V, t[48] = H, t[49] = v, t[50] = ye) : ye = t[50];
|
|
399
|
+
let G;
|
|
400
|
+
t[51] !== ve || t[52] !== H ? (G = [ve, H], t[51] = ve, t[52] = H, t[53] = G) : G = t[53], nt(ye, G);
|
|
401
|
+
let be;
|
|
402
|
+
t[54] !== V || t[55] !== he || t[56] !== U || t[57] !== x || t[58] !== L || t[59] !== pe || t[60] !== W || t[61] !== de || t[62] !== se ? (be = () => {
|
|
403
403
|
if (!x?.({
|
|
404
|
-
...
|
|
405
|
-
activeEntry:
|
|
406
|
-
entryCount:
|
|
407
|
-
setQuery:
|
|
408
|
-
setActiveIndex:
|
|
409
|
-
runActiveEntry:
|
|
410
|
-
closePalette:
|
|
404
|
+
...se,
|
|
405
|
+
activeEntry: V,
|
|
406
|
+
entryCount: U.length,
|
|
407
|
+
setQuery: de,
|
|
408
|
+
setActiveIndex: W,
|
|
409
|
+
runActiveEntry: pe,
|
|
410
|
+
closePalette: he
|
|
411
411
|
})) {
|
|
412
|
-
if (
|
|
413
|
-
|
|
412
|
+
if (L.length > 0) {
|
|
413
|
+
de(""), W(0);
|
|
414
414
|
return;
|
|
415
415
|
}
|
|
416
|
-
|
|
416
|
+
he();
|
|
417
417
|
}
|
|
418
|
-
}, t[54] =
|
|
419
|
-
let
|
|
420
|
-
t[64] !==
|
|
418
|
+
}, t[54] = V, t[55] = he, t[56] = U, t[57] = x, t[58] = L, t[59] = pe, t[60] = W, t[61] = de, t[62] = se, t[63] = be) : be = t[63];
|
|
419
|
+
let xe = be, Se;
|
|
420
|
+
t[64] !== U || t[65] !== pe || t[66] !== W ? (Se = (e) => {
|
|
421
421
|
if (e.key === "ArrowDown") {
|
|
422
|
-
e.preventDefault(),
|
|
422
|
+
e.preventDefault(), W((e) => Math.min(e + 1, Math.max(U.length - 1, 0)));
|
|
423
423
|
return;
|
|
424
424
|
}
|
|
425
425
|
if (e.key === "ArrowUp") {
|
|
426
|
-
e.preventDefault(),
|
|
426
|
+
e.preventDefault(), W(fn);
|
|
427
427
|
return;
|
|
428
428
|
}
|
|
429
429
|
if (e.key === "Enter") {
|
|
430
|
-
e.preventDefault(),
|
|
430
|
+
e.preventDefault(), pe();
|
|
431
431
|
return;
|
|
432
432
|
}
|
|
433
|
-
}, t[64] =
|
|
434
|
-
let
|
|
435
|
-
t[68] === w ?
|
|
436
|
-
let we;
|
|
437
|
-
t[70] === be ? we = t[71] : (we = (e) => {
|
|
438
|
-
e.preventDefault(), e.stopPropagation(), be();
|
|
439
|
-
}, t[70] = be, t[71] = we);
|
|
433
|
+
}, t[64] = U, t[65] = pe, t[66] = W, t[67] = Se) : Se = t[67];
|
|
434
|
+
let Ce = Se, we;
|
|
435
|
+
t[68] === w ? we = t[69] : (we = () => w ? ne.current : re.current, t[68] = w, t[69] = we);
|
|
440
436
|
let Te;
|
|
441
|
-
t[
|
|
437
|
+
t[70] === xe ? Te = t[71] : (Te = (e) => {
|
|
438
|
+
e.preventDefault(), e.stopPropagation(), xe();
|
|
439
|
+
}, t[70] = xe, t[71] = Te);
|
|
442
440
|
let Ee;
|
|
443
|
-
t[
|
|
441
|
+
t[72] === he ? Ee = t[73] : (Ee = (e) => !e.open && he(), t[72] = he, t[73] = Ee);
|
|
442
|
+
let q;
|
|
443
|
+
t[74] === Symbol.for("react.memo_cache_sentinel") ? (q = /* @__PURE__ */ Q(K.Backdrop, {}), t[74] = q) : q = t[74];
|
|
444
444
|
let De;
|
|
445
445
|
t[75] === Symbol.for("react.memo_cache_sentinel") ? (De = { style: { overflowAnchor: "none" } }, t[75] = De) : De = t[75];
|
|
446
446
|
let J;
|
|
@@ -448,78 +448,78 @@ var Ut = (e) => {
|
|
|
448
448
|
maxH: "var(--palette-results-height)",
|
|
449
449
|
css: M.results,
|
|
450
450
|
showHorizontalScrollbar: !1,
|
|
451
|
-
viewportRef:
|
|
451
|
+
viewportRef: ie,
|
|
452
452
|
viewportProps: De
|
|
453
453
|
}, t[76] = M.results, t[77] = J);
|
|
454
454
|
let Y;
|
|
455
|
-
t[78] !==
|
|
456
|
-
|
|
457
|
-
}, t[78] =
|
|
455
|
+
t[78] !== W || t[79] !== de ? (Y = (e) => {
|
|
456
|
+
de(e), W(0);
|
|
457
|
+
}, t[78] = W, t[79] = de, t[80] = Y) : Y = t[80];
|
|
458
458
|
let Oe;
|
|
459
|
-
t[81] !==
|
|
460
|
-
entries:
|
|
461
|
-
activeIndex:
|
|
459
|
+
t[81] !== H || t[82] !== O || t[83] !== U || t[84] !== W ? (Oe = /* @__PURE__ */ Q(on, {
|
|
460
|
+
entries: U,
|
|
461
|
+
activeIndex: H,
|
|
462
462
|
emptyLabel: O,
|
|
463
|
-
onHover:
|
|
464
|
-
scrollRef:
|
|
465
|
-
}), t[81] =
|
|
463
|
+
onHover: W,
|
|
464
|
+
scrollRef: ie
|
|
465
|
+
}), t[81] = H, t[82] = O, t[83] = U, t[84] = W, t[85] = Oe) : Oe = t[85];
|
|
466
466
|
let ke;
|
|
467
|
-
t[86] !== g || t[87] !== h || t[88] !==
|
|
468
|
-
searchValue:
|
|
469
|
-
searchPlaceholder:
|
|
470
|
-
searchIcon:
|
|
471
|
-
searchInputRef:
|
|
467
|
+
t[86] !== g || t[87] !== h || t[88] !== Ce || t[89] !== L || t[90] !== oe || t[91] !== le || t[92] !== J || t[93] !== Y || t[94] !== Oe ? (ke = /* @__PURE__ */ Q(ln, {
|
|
468
|
+
searchValue: L,
|
|
469
|
+
searchPlaceholder: le,
|
|
470
|
+
searchIcon: oe,
|
|
471
|
+
searchInputRef: ne,
|
|
472
472
|
showCloseButton: !0,
|
|
473
473
|
footerStart: h,
|
|
474
474
|
footerEnd: g,
|
|
475
475
|
scrollAreaProps: J,
|
|
476
476
|
onSearchChange: Y,
|
|
477
|
-
onSearchKeyDown:
|
|
477
|
+
onSearchKeyDown: Ce,
|
|
478
478
|
children: Oe
|
|
479
|
-
}), t[86] = g, t[87] = h, t[88] =
|
|
479
|
+
}), t[86] = g, t[87] = h, t[88] = Ce, t[89] = L, t[90] = oe, t[91] = le, t[92] = J, t[93] = Y, t[94] = Oe, t[95] = ke) : ke = t[95];
|
|
480
480
|
let Ae;
|
|
481
|
-
t[96] !== S || t[97] !== M.content || t[98] !== ke ? (Ae = /* @__PURE__ */ Q(
|
|
482
|
-
ref:
|
|
481
|
+
t[96] !== S || t[97] !== M.content || t[98] !== ke ? (Ae = /* @__PURE__ */ Q(K.Content, {
|
|
482
|
+
ref: re,
|
|
483
483
|
tabIndex: -1,
|
|
484
484
|
css: M.content,
|
|
485
485
|
"aria-label": S,
|
|
486
486
|
children: ke
|
|
487
487
|
}), t[96] = S, t[97] = M.content, t[98] = ke, t[99] = Ae) : Ae = t[99];
|
|
488
488
|
let je;
|
|
489
|
-
t[100] !== M.positioner || t[101] !== Ae ? (je = /* @__PURE__ */ Q(
|
|
489
|
+
t[100] !== M.positioner || t[101] !== Ae ? (je = /* @__PURE__ */ Q(K.Positioner, {
|
|
490
490
|
css: M.positioner,
|
|
491
491
|
children: Ae
|
|
492
492
|
}), t[100] = M.positioner, t[101] = Ae, t[102] = je) : je = t[102];
|
|
493
493
|
let Me;
|
|
494
|
-
return t[103] !== n || t[104] !==
|
|
494
|
+
return t[103] !== n || t[104] !== we || t[105] !== Te || t[106] !== Ee || t[107] !== je ? (Me = /* @__PURE__ */ $(K.Root, {
|
|
495
495
|
open: n,
|
|
496
|
-
initialFocusEl:
|
|
497
|
-
onEscapeKeyDown:
|
|
498
|
-
onOpenChange:
|
|
499
|
-
children: [
|
|
500
|
-
}), t[103] = n, t[104] =
|
|
496
|
+
initialFocusEl: we,
|
|
497
|
+
onEscapeKeyDown: Te,
|
|
498
|
+
onOpenChange: Ee,
|
|
499
|
+
children: [q, je]
|
|
500
|
+
}), t[103] = n, t[104] = we, t[105] = Te, t[106] = Ee, t[107] = je, t[108] = Me) : Me = t[108], Me;
|
|
501
501
|
};
|
|
502
|
-
function
|
|
502
|
+
function fn(e) {
|
|
503
503
|
return Math.max(e - 1, 0);
|
|
504
504
|
}
|
|
505
505
|
//#endregion
|
|
506
506
|
//#region src/theme/recipes/shortcut-keys.ts
|
|
507
|
-
var
|
|
507
|
+
var pn = Ge({ base: {
|
|
508
508
|
display: "inline-flex",
|
|
509
509
|
alignItems: "center",
|
|
510
510
|
gap: "shortcut-key-gap",
|
|
511
511
|
verticalAlign: "middle",
|
|
512
512
|
whiteSpace: "nowrap"
|
|
513
|
-
} }),
|
|
513
|
+
} }), mn = He("span", pn), hn = {
|
|
514
514
|
alt: { label: "Alt" },
|
|
515
515
|
control: { label: "Ctrl" },
|
|
516
516
|
ctrl: { label: "Ctrl" },
|
|
517
517
|
mod: { label: "Ctrl" },
|
|
518
518
|
shift: { label: "Shift" }
|
|
519
|
-
},
|
|
519
|
+
}, gn = {
|
|
520
520
|
alt: {
|
|
521
521
|
label: "Option",
|
|
522
|
-
Icon:
|
|
522
|
+
Icon: bt
|
|
523
523
|
},
|
|
524
524
|
cmd: {
|
|
525
525
|
label: "Command",
|
|
@@ -539,10 +539,10 @@ var fn = Ge({ base: {
|
|
|
539
539
|
},
|
|
540
540
|
option: {
|
|
541
541
|
label: "Option",
|
|
542
|
-
Icon:
|
|
542
|
+
Icon: bt
|
|
543
543
|
},
|
|
544
544
|
shift: { label: "Shift" }
|
|
545
|
-
},
|
|
545
|
+
}, _n = {
|
|
546
546
|
arrowleft: {
|
|
547
547
|
label: "Arrow Left",
|
|
548
548
|
Icon: at
|
|
@@ -551,26 +551,26 @@ var fn = Ge({ base: {
|
|
|
551
551
|
label: "Arrow Right",
|
|
552
552
|
Icon: ot
|
|
553
553
|
}
|
|
554
|
-
},
|
|
554
|
+
}, vn = () => {
|
|
555
555
|
if (typeof navigator > "u") return "linux";
|
|
556
556
|
let e = navigator.platform?.toLowerCase() ?? "";
|
|
557
557
|
return e.includes("mac") ? "mac" : e.includes("win") ? "win" : "linux";
|
|
558
|
-
},
|
|
559
|
-
let n = e.toLowerCase(), r = t === "mac" ?
|
|
560
|
-
return
|
|
561
|
-
},
|
|
558
|
+
}, yn = (e, t = vn()) => {
|
|
559
|
+
let n = e.toLowerCase(), r = t === "mac" ? gn : hn;
|
|
560
|
+
return _n[n] ?? r[n] ?? { label: e };
|
|
561
|
+
}, bn = (e) => e.split("+").map((e) => e.trim()).filter(Boolean), xn = (e) => (Array.isArray(e) ? e.map(bn) : [bn(e)]).map((e) => e.map((e) => yn(e))), Sn = (e) => {
|
|
562
562
|
let t = Z(4), { binding: n } = e, r;
|
|
563
563
|
if (t[0] !== n) {
|
|
564
|
-
let e =
|
|
565
|
-
r = e.map((t, n) => /* @__PURE__ */ $(Qe, { children: [/* @__PURE__ */ Q(
|
|
564
|
+
let e = xn(n);
|
|
565
|
+
r = e.map((t, n) => /* @__PURE__ */ $(Qe, { children: [/* @__PURE__ */ Q(mn, { children: t.map(wn) }), n < e.length - 1 ? " then " : null] }, `${t.map(Cn).join("+")}-${n}`)), t[0] = n, t[1] = r;
|
|
566
566
|
} else r = t[1];
|
|
567
567
|
let i;
|
|
568
568
|
return t[2] === r ? i = t[3] : (i = /* @__PURE__ */ Q(Ye, { children: r }), t[2] = r, t[3] = i), i;
|
|
569
569
|
};
|
|
570
|
-
function
|
|
570
|
+
function Cn(e) {
|
|
571
571
|
return e.label;
|
|
572
572
|
}
|
|
573
|
-
function
|
|
573
|
+
function wn(e, t) {
|
|
574
574
|
return /* @__PURE__ */ Q(je, {
|
|
575
575
|
"aria-label": e.label,
|
|
576
576
|
children: e.Icon ? /* @__PURE__ */ Q(e.Icon, {
|
|
@@ -581,7 +581,7 @@ function Cn(e, t) {
|
|
|
581
581
|
}
|
|
582
582
|
//#endregion
|
|
583
583
|
//#region src/components/layout/horizontal-menu-stack.tsx
|
|
584
|
-
function
|
|
584
|
+
function Tn(e) {
|
|
585
585
|
let t = Z(14), n, r, i, a, o, s;
|
|
586
586
|
t[0] === e ? (n = t[1], r = t[2], i = t[3], a = t[4], o = t[5], s = t[6]) : ({children: n, h: i, px: a, py: o, borderBottomWidth: s, ...r} = e, t[0] = e, t[1] = n, t[2] = r, t[3] = i, t[4] = a, t[5] = o, t[6] = s);
|
|
587
587
|
let c = i === void 0 ? "41px" : i, l = a === void 0 ? "xs" : a, u = o === void 0 ? "xs" : o, d = s === void 0 ? "1px" : s, f;
|
|
@@ -599,7 +599,7 @@ function wn(e) {
|
|
|
599
599
|
}
|
|
600
600
|
//#endregion
|
|
601
601
|
//#region src/components/layout/item-section.tsx
|
|
602
|
-
var
|
|
602
|
+
var En = (e) => {
|
|
603
603
|
let t = Z(17), { children: n, title: r, defaultOpen: i, action: a } = e, o = i === void 0 || i, s;
|
|
604
604
|
t[0] === Symbol.for("react.memo_cache_sentinel") ? (s = { background: "bg.hover" }, t[0] = s) : s = t[0];
|
|
605
605
|
let c;
|
|
@@ -609,13 +609,13 @@ var Tn = (e) => {
|
|
|
609
609
|
children: r
|
|
610
610
|
}), t[1] = r, t[2] = c);
|
|
611
611
|
let l;
|
|
612
|
-
t[3] === Symbol.for("react.memo_cache_sentinel") ? (l = /* @__PURE__ */ Q(
|
|
612
|
+
t[3] === Symbol.for("react.memo_cache_sentinel") ? (l = /* @__PURE__ */ Q(Te.Indicator, {
|
|
613
613
|
transition: "transform 0.2s",
|
|
614
614
|
_open: { transform: "rotate(90deg)" },
|
|
615
615
|
children: /* @__PURE__ */ Q(dt, { size: 16 })
|
|
616
616
|
}), t[3] = l) : l = t[3];
|
|
617
617
|
let u;
|
|
618
|
-
t[4] === c ? u = t[5] : (u = /* @__PURE__ */ $(
|
|
618
|
+
t[4] === c ? u = t[5] : (u = /* @__PURE__ */ $(Te.Trigger, {
|
|
619
619
|
_hover: s,
|
|
620
620
|
padding: "sm",
|
|
621
621
|
height: "2rem",
|
|
@@ -628,28 +628,28 @@ var Tn = (e) => {
|
|
|
628
628
|
children: [c, l]
|
|
629
629
|
}), t[4] = c, t[5] = u);
|
|
630
630
|
let d;
|
|
631
|
-
t[6] === a ? d = t[7] : (d = a && /* @__PURE__ */ Q(
|
|
631
|
+
t[6] === a ? d = t[7] : (d = a && /* @__PURE__ */ Q(G, {
|
|
632
632
|
marginLeft: "auto",
|
|
633
|
-
onClick:
|
|
633
|
+
onClick: Dn,
|
|
634
634
|
children: a
|
|
635
635
|
}), t[6] = a, t[7] = d);
|
|
636
636
|
let f;
|
|
637
|
-
t[8] !== u || t[9] !== d ? (f = /* @__PURE__ */ $(
|
|
637
|
+
t[8] !== u || t[9] !== d ? (f = /* @__PURE__ */ $(q, { children: [u, d] }), t[8] = u, t[9] = d, t[10] = f) : f = t[10];
|
|
638
638
|
let p;
|
|
639
|
-
t[11] === n ? p = t[12] : (p = /* @__PURE__ */ Q(
|
|
639
|
+
t[11] === n ? p = t[12] : (p = /* @__PURE__ */ Q(Te.Content, { children: n }), t[11] = n, t[12] = p);
|
|
640
640
|
let m;
|
|
641
|
-
return t[13] !== o || t[14] !== f || t[15] !== p ? (m = /* @__PURE__ */ $(
|
|
641
|
+
return t[13] !== o || t[14] !== f || t[15] !== p ? (m = /* @__PURE__ */ $(Te.Root, {
|
|
642
642
|
defaultOpen: o,
|
|
643
643
|
width: "full",
|
|
644
644
|
children: [f, p]
|
|
645
645
|
}), t[13] = o, t[14] = f, t[15] = p, t[16] = m) : m = t[16], m;
|
|
646
646
|
};
|
|
647
|
-
function
|
|
647
|
+
function Dn(e) {
|
|
648
648
|
return e.stopPropagation();
|
|
649
649
|
}
|
|
650
650
|
//#endregion
|
|
651
651
|
//#region src/components/layout/panel-header.constants.ts
|
|
652
|
-
var
|
|
652
|
+
var On = "2.5rem", kn = "2xs", An = "sm", jn = (e) => e === "urgent" ? "red" : e === "high" ? "orange" : e === "low" ? "gray" : "blue", Mn = (e) => e !== "normal", Nn = (e) => [
|
|
653
653
|
e.title,
|
|
654
654
|
e.body,
|
|
655
655
|
e.kind,
|
|
@@ -659,10 +659,10 @@ var Dn = "2.5rem", On = "2xs", kn = "sm", An = (e) => e === "urgent" ? "red" : e
|
|
|
659
659
|
e.targetLabel,
|
|
660
660
|
e.searchText,
|
|
661
661
|
...(e.actions ?? []).map((e) => e.label)
|
|
662
|
-
].filter(Boolean).join(" ").toLowerCase(),
|
|
662
|
+
].filter(Boolean).join(" ").toLowerCase(), Pn = (e, t) => {
|
|
663
663
|
let n = t.trim().toLowerCase();
|
|
664
|
-
return n ? e.filter((e) =>
|
|
665
|
-
},
|
|
664
|
+
return n ? e.filter((e) => Nn(e).includes(n)) : e;
|
|
665
|
+
}, Fn = (e) => {
|
|
666
666
|
let t = e.filter((e) => e.kind === "blocked"), n = e.filter((e) => e.kind !== "blocked" && (e.priority === "urgent" || e.priority === "high")), r = e.filter((e) => e.kind !== "blocked" && (e.priority === "normal" || e.priority === "low"));
|
|
667
667
|
return [
|
|
668
668
|
{
|
|
@@ -681,31 +681,31 @@ var Dn = "2.5rem", On = "2xs", kn = "sm", An = (e) => e === "urgent" ? "red" : e
|
|
|
681
681
|
items: r
|
|
682
682
|
}
|
|
683
683
|
].filter((e) => e.items.length > 0);
|
|
684
|
-
},
|
|
684
|
+
}, In = (e) => Fn(e).flatMap((e) => e.items), Ln = (e) => [
|
|
685
685
|
e.body,
|
|
686
686
|
e.targetLabel,
|
|
687
687
|
e.sourceLabel,
|
|
688
688
|
e.timeLabel
|
|
689
|
-
].filter(Boolean).join(" · "),
|
|
689
|
+
].filter(Boolean).join(" · "), Rn = (e, t) => {
|
|
690
690
|
let n = [];
|
|
691
691
|
return t.onDismiss && n.push({
|
|
692
692
|
id: "dismiss",
|
|
693
693
|
label: "Dismiss",
|
|
694
|
-
icon: /* @__PURE__ */ Q(
|
|
694
|
+
icon: /* @__PURE__ */ Q(Et, { size: 14 }),
|
|
695
695
|
tooltip: "Dismiss",
|
|
696
696
|
onAction: () => t.onDismiss?.(e)
|
|
697
697
|
}), n;
|
|
698
|
-
},
|
|
698
|
+
}, zn = (e) => {
|
|
699
699
|
let t = Z(15), { actions: n, item: r, onRunAction: i } = e, a;
|
|
700
|
-
t[0] === r.priority ? a = t[1] : (a =
|
|
700
|
+
t[0] === r.priority ? a = t[1] : (a = Mn(r.priority) ? /* @__PURE__ */ Q(ye, {
|
|
701
701
|
size: "sm",
|
|
702
|
-
colorPalette:
|
|
702
|
+
colorPalette: jn(r.priority),
|
|
703
703
|
textTransform: "capitalize",
|
|
704
704
|
flexShrink: 0,
|
|
705
705
|
children: r.priority
|
|
706
706
|
}) : null, t[0] = r.priority, t[1] = a);
|
|
707
707
|
let o;
|
|
708
|
-
t[2] === r.status ? o = t[3] : (o = r.status === "open" ? /* @__PURE__ */ Q(
|
|
708
|
+
t[2] === r.status ? o = t[3] : (o = r.status === "open" ? /* @__PURE__ */ Q(ye, {
|
|
709
709
|
size: "sm",
|
|
710
710
|
colorPalette: "blue",
|
|
711
711
|
variant: "solid",
|
|
@@ -715,7 +715,7 @@ var Dn = "2.5rem", On = "2xs", kn = "sm", An = (e) => e === "urgent" ? "red" : e
|
|
|
715
715
|
let s;
|
|
716
716
|
if (t[4] !== n || t[5] !== r || t[6] !== i) {
|
|
717
717
|
let e;
|
|
718
|
-
t[8] !== r || t[9] !== i ? (e = (e) => /* @__PURE__ */ Q(
|
|
718
|
+
t[8] !== r || t[9] !== i ? (e = (e) => /* @__PURE__ */ Q(xe, {
|
|
719
719
|
size: "2xs",
|
|
720
720
|
variant: "outline",
|
|
721
721
|
colorPalette: e.destructive ? "red" : "gray",
|
|
@@ -741,8 +741,8 @@ var Dn = "2.5rem", On = "2xs", kn = "sm", An = (e) => e === "urgent" ? "red" : e
|
|
|
741
741
|
s
|
|
742
742
|
]
|
|
743
743
|
}), t[11] = a, t[12] = o, t[13] = s, t[14] = c) : c = t[14], c;
|
|
744
|
-
},
|
|
745
|
-
let { activeIndex: t, items: n, onActivateItem: r, onActiveIndexChange: i, onRunAction: a } = e, o =
|
|
744
|
+
}, Bn = (e) => {
|
|
745
|
+
let { activeIndex: t, items: n, onActivateItem: r, onActiveIndexChange: i, onRunAction: a } = e, o = Fn(n), s = 0;
|
|
746
746
|
return /* @__PURE__ */ Q(Re, {
|
|
747
747
|
gap: "2xs",
|
|
748
748
|
py: "xs",
|
|
@@ -759,20 +759,20 @@ var Dn = "2.5rem", On = "2xs", kn = "sm", An = (e) => e === "urgent" ? "red" : e
|
|
|
759
759
|
return s += 1, /* @__PURE__ */ Q(h, {
|
|
760
760
|
id: n.id,
|
|
761
761
|
label: n.title,
|
|
762
|
-
description:
|
|
762
|
+
description: Ln(n),
|
|
763
763
|
icon: /* @__PURE__ */ Q(Y, {
|
|
764
764
|
as: ct,
|
|
765
765
|
boxSize: "14px"
|
|
766
766
|
}),
|
|
767
|
-
iconColor: `${
|
|
767
|
+
iconColor: `${jn(n.priority)}.500`,
|
|
768
768
|
variant: "compact",
|
|
769
769
|
isSelected: o === t,
|
|
770
|
-
endContent: /* @__PURE__ */ Q(
|
|
770
|
+
endContent: /* @__PURE__ */ Q(zn, {
|
|
771
771
|
item: n,
|
|
772
772
|
actions: n.actions ?? [],
|
|
773
773
|
onRunAction: a
|
|
774
774
|
}),
|
|
775
|
-
actions:
|
|
775
|
+
actions: Rn(n, e),
|
|
776
776
|
tabIndex: -1,
|
|
777
777
|
onActivate: () => r?.(n),
|
|
778
778
|
onPointerMove: () => i(o)
|
|
@@ -780,7 +780,7 @@ var Dn = "2.5rem", On = "2xs", kn = "sm", An = (e) => e === "urgent" ? "red" : e
|
|
|
780
780
|
})]
|
|
781
781
|
}, n.id))
|
|
782
782
|
});
|
|
783
|
-
},
|
|
783
|
+
}, Vn = () => {
|
|
784
784
|
let e = Z(1), t;
|
|
785
785
|
return e[0] === Symbol.for("react.memo_cache_sentinel") ? (t = /* @__PURE__ */ Q(Re, {
|
|
786
786
|
gap: "2",
|
|
@@ -790,11 +790,11 @@ var Dn = "2.5rem", On = "2xs", kn = "sm", An = (e) => e === "urgent" ? "red" : e
|
|
|
790
790
|
1,
|
|
791
791
|
2,
|
|
792
792
|
3
|
|
793
|
-
].map(
|
|
793
|
+
].map(Un)
|
|
794
794
|
}), e[0] = t) : t = e[0], t;
|
|
795
|
-
},
|
|
795
|
+
}, Hn = (e) => {
|
|
796
796
|
let t = Z(49), { autoFocus: n, emptyLabel: r, error: i, footerEnd: a, footerStart: o, items: s, loading: l, onActivateItem: u, onEscape: d, onQueryChange: f, query: p } = e, m = n !== void 0 && n, h = r === void 0 ? "No notifications." : r, g = l !== void 0 && l, [_, v] = it(""), [y, b] = it(0), x = rt(null), S = p ?? _, C, w;
|
|
797
|
-
t[0] !== S || t[1] !== s ? (C =
|
|
797
|
+
t[0] !== S || t[1] !== s ? (C = Pn(s, S), w = In(C), t[0] = S, t[1] = s, t[2] = C, t[3] = w) : (C = t[2], w = t[3]);
|
|
798
798
|
let T = w, E = T[y] ?? null, D, O;
|
|
799
799
|
t[4] === m ? (D = t[5], O = t[6]) : (D = () => {
|
|
800
800
|
if (!m) return;
|
|
@@ -816,7 +816,7 @@ var Dn = "2.5rem", On = "2xs", kn = "sm", An = (e) => e === "urgent" ? "red" : e
|
|
|
816
816
|
return;
|
|
817
817
|
}
|
|
818
818
|
if (e.key === "ArrowUp") {
|
|
819
|
-
e.preventDefault(), b(
|
|
819
|
+
e.preventDefault(), b(Wn);
|
|
820
820
|
return;
|
|
821
821
|
}
|
|
822
822
|
if (e.key === "Enter") {
|
|
@@ -831,15 +831,15 @@ var Dn = "2.5rem", On = "2xs", kn = "sm", An = (e) => e === "urgent" ? "red" : e
|
|
|
831
831
|
d?.();
|
|
832
832
|
}
|
|
833
833
|
}, t[13] = E, t[14] = S, t[15] = T.length, t[16] = u, t[17] = d, t[18] = M, t[19] = N) : N = t[19];
|
|
834
|
-
let P = N,
|
|
835
|
-
t[20] === Symbol.for("react.memo_cache_sentinel") ? (
|
|
836
|
-
let
|
|
837
|
-
t[21] === Symbol.for("react.memo_cache_sentinel") ? (
|
|
834
|
+
let P = N, ee;
|
|
835
|
+
t[20] === Symbol.for("react.memo_cache_sentinel") ? (ee = /* @__PURE__ */ Q(Ct, { size: 14 }), t[20] = ee) : ee = t[20];
|
|
836
|
+
let F;
|
|
837
|
+
t[21] === Symbol.for("react.memo_cache_sentinel") ? (F = {
|
|
838
838
|
maxH: "24rem",
|
|
839
839
|
showHorizontalScrollbar: !1
|
|
840
|
-
}, t[21] =
|
|
841
|
-
let
|
|
842
|
-
t[22] === i ?
|
|
840
|
+
}, t[21] = F) : F = t[21];
|
|
841
|
+
let I;
|
|
842
|
+
t[22] === i ? I = t[23] : (I = i ? /* @__PURE__ */ Q(G, {
|
|
843
843
|
p: "sm",
|
|
844
844
|
children: /* @__PURE__ */ Q(c, {
|
|
845
845
|
status: "error",
|
|
@@ -848,45 +848,45 @@ var Dn = "2.5rem", On = "2xs", kn = "sm", An = (e) => e === "urgent" ? "red" : e
|
|
|
848
848
|
size: "sm",
|
|
849
849
|
children: i
|
|
850
850
|
})
|
|
851
|
-
}) : null, t[22] = i, t[23] =
|
|
851
|
+
}) : null, t[22] = i, t[23] = I);
|
|
852
|
+
let L;
|
|
853
|
+
t[24] !== i || t[25] !== g ? (L = !i && g && /* @__PURE__ */ Q(Vn, {}), t[24] = i, t[25] = g, t[26] = L) : L = t[26];
|
|
852
854
|
let R;
|
|
853
|
-
t[
|
|
854
|
-
let z;
|
|
855
|
-
t[27] !== h || t[28] !== i || t[29] !== C || t[30] !== g ? (z = !i && !g && C.length === 0 && /* @__PURE__ */ Q(X, {
|
|
855
|
+
t[27] !== h || t[28] !== i || t[29] !== C || t[30] !== g ? (R = !i && !g && C.length === 0 && /* @__PURE__ */ Q(X, {
|
|
856
856
|
textStyle: "paragraph/S/regular",
|
|
857
857
|
color: "fg.muted",
|
|
858
858
|
px: "sm",
|
|
859
859
|
py: "md",
|
|
860
860
|
children: h
|
|
861
|
-
}), t[27] = h, t[28] = i, t[29] = C, t[30] = g, t[31] =
|
|
862
|
-
let
|
|
863
|
-
t[32] !== y || t[33] !== i || t[34] !== C || t[35] !== g || t[36] !== e ? (
|
|
861
|
+
}), t[27] = h, t[28] = i, t[29] = C, t[30] = g, t[31] = R) : R = t[31];
|
|
862
|
+
let z;
|
|
863
|
+
t[32] !== y || t[33] !== i || t[34] !== C || t[35] !== g || t[36] !== e ? (z = !i && !g && C.length > 0 && /* @__PURE__ */ Q(Bn, {
|
|
864
864
|
...e,
|
|
865
865
|
items: C,
|
|
866
866
|
activeIndex: y,
|
|
867
867
|
onActiveIndexChange: b
|
|
868
|
-
}), t[32] = y, t[33] = i, t[34] = C, t[35] = g, t[36] = e, t[37] =
|
|
869
|
-
let
|
|
870
|
-
return t[38] !== S || t[39] !== m || t[40] !== a || t[41] !== o || t[42] !== P || t[43] !==
|
|
868
|
+
}), t[32] = y, t[33] = i, t[34] = C, t[35] = g, t[36] = e, t[37] = z) : z = t[37];
|
|
869
|
+
let B;
|
|
870
|
+
return t[38] !== S || t[39] !== m || t[40] !== a || t[41] !== o || t[42] !== P || t[43] !== I || t[44] !== L || t[45] !== R || t[46] !== z || t[47] !== M ? (B = /* @__PURE__ */ $(ln, {
|
|
871
871
|
searchValue: S,
|
|
872
872
|
searchPlaceholder: "Search notifications",
|
|
873
|
-
searchIcon:
|
|
873
|
+
searchIcon: ee,
|
|
874
874
|
searchInputRef: x,
|
|
875
875
|
searchAutoFocus: m,
|
|
876
876
|
footerStart: o,
|
|
877
877
|
footerEnd: a,
|
|
878
|
-
scrollAreaProps:
|
|
878
|
+
scrollAreaProps: F,
|
|
879
879
|
onSearchChange: M,
|
|
880
880
|
onSearchKeyDown: P,
|
|
881
881
|
children: [
|
|
882
|
+
I,
|
|
882
883
|
L,
|
|
883
884
|
R,
|
|
884
|
-
z
|
|
885
|
-
B
|
|
885
|
+
z
|
|
886
886
|
]
|
|
887
|
-
}), t[38] = S, t[39] = m, t[40] = a, t[41] = o, t[42] = P, t[43] =
|
|
887
|
+
}), t[38] = S, t[39] = m, t[40] = a, t[41] = o, t[42] = P, t[43] = I, t[44] = L, t[45] = R, t[46] = z, t[47] = M, t[48] = B) : B = t[48], B;
|
|
888
888
|
};
|
|
889
|
-
function
|
|
889
|
+
function Un(e) {
|
|
890
890
|
return /* @__PURE__ */ $(Re, {
|
|
891
891
|
gap: "2xs",
|
|
892
892
|
children: [/* @__PURE__ */ Q(Fe, {
|
|
@@ -900,16 +900,16 @@ function Hn(e) {
|
|
|
900
900
|
})]
|
|
901
901
|
}, e);
|
|
902
902
|
}
|
|
903
|
-
function
|
|
903
|
+
function Wn(e) {
|
|
904
904
|
return Math.max(e - 1, 0);
|
|
905
905
|
}
|
|
906
906
|
//#endregion
|
|
907
907
|
//#region src/components/overlays/attached-menu.tsx
|
|
908
|
-
var
|
|
908
|
+
var Gn = (e) => {
|
|
909
909
|
let t = Z(6), n, r;
|
|
910
910
|
t[0] === e ? (n = t[1], r = t[2]) : ({children: n, ...r} = e, t[0] = e, t[1] = n, t[2] = r);
|
|
911
911
|
let i;
|
|
912
|
-
return t[3] !== n || t[4] !== r ? (i = /* @__PURE__ */ Q(
|
|
912
|
+
return t[3] !== n || t[4] !== r ? (i = /* @__PURE__ */ Q(q, {
|
|
913
913
|
as: "aside",
|
|
914
914
|
direction: "column",
|
|
915
915
|
h: "full",
|
|
@@ -921,18 +921,18 @@ var Wn = (e) => {
|
|
|
921
921
|
...r,
|
|
922
922
|
children: n
|
|
923
923
|
}), t[3] = n, t[4] = r, t[5] = i) : i = t[5], i;
|
|
924
|
-
},
|
|
924
|
+
}, Kn = "20rem", qn = (e) => {
|
|
925
925
|
let t = Z(15), n, r, i, a, o, s;
|
|
926
926
|
t[0] === e ? (n = t[1], r = t[2], i = t[3], a = t[4], o = t[5], s = t[6]) : ({children: n, header: r, width: o, minWidth: i, resizable: s, ...a} = e, t[0] = e, t[1] = n, t[2] = r, t[3] = i, t[4] = a, t[5] = o, t[6] = s);
|
|
927
|
-
let c = o === void 0 ? "28rem" : o, l = s !== void 0 && s, u = i ?? (l ?
|
|
928
|
-
t[7] === n ? f = t[8] : (f = /* @__PURE__ */ Q(
|
|
927
|
+
let c = o === void 0 ? "28rem" : o, l = s !== void 0 && s, u = i ?? (l ? Kn : c), d = l ? "full" : c, f;
|
|
928
|
+
t[7] === n ? f = t[8] : (f = /* @__PURE__ */ Q(q, {
|
|
929
929
|
flex: "1",
|
|
930
930
|
minH: 0,
|
|
931
931
|
direction: "column",
|
|
932
932
|
children: n
|
|
933
933
|
}), t[7] = n, t[8] = f);
|
|
934
934
|
let p;
|
|
935
|
-
return t[9] !== r || t[10] !== u || t[11] !== d || t[12] !== a || t[13] !== f ? (p = /* @__PURE__ */ $(
|
|
935
|
+
return t[9] !== r || t[10] !== u || t[11] !== d || t[12] !== a || t[13] !== f ? (p = /* @__PURE__ */ $(q, {
|
|
936
936
|
direction: "column",
|
|
937
937
|
position: "relative",
|
|
938
938
|
flexShrink: 0,
|
|
@@ -944,7 +944,7 @@ var Wn = (e) => {
|
|
|
944
944
|
...a,
|
|
945
945
|
children: [r, f]
|
|
946
946
|
}), t[9] = r, t[10] = u, t[11] = d, t[12] = a, t[13] = f, t[14] = p) : p = t[14], p;
|
|
947
|
-
},
|
|
947
|
+
}, Jn = et(function(e, t) {
|
|
948
948
|
let n = Z(23), r, i, a, o, s;
|
|
949
949
|
n[0] === e ? (r = n[1], i = n[2], a = n[3], o = n[4], s = n[5]) : ({children: r, containerProps: i, isOpen: o, tooltip: s, ...a} = e, n[0] = e, n[1] = r, n[2] = i, n[3] = a, n[4] = o, n[5] = s);
|
|
950
950
|
let c = o !== void 0 && o, u;
|
|
@@ -983,84 +983,74 @@ var Wn = (e) => {
|
|
|
983
983
|
"aria-hidden": c,
|
|
984
984
|
children: _
|
|
985
985
|
}), n[18] = i, n[19] = c, n[20] = g, n[21] = _, n[22] = v) : v = n[22], v;
|
|
986
|
-
}),
|
|
987
|
-
let n = Z(
|
|
988
|
-
n[0] === Symbol.for("react.memo_cache_sentinel") ? (
|
|
989
|
-
let
|
|
990
|
-
n[1] ===
|
|
991
|
-
let
|
|
992
|
-
n[3]
|
|
993
|
-
gap: "1",
|
|
994
|
-
minW: "0",
|
|
995
|
-
children: a
|
|
996
|
-
}), n[3] = a, n[4] = O);
|
|
997
|
-
let k;
|
|
998
|
-
n[5] === Symbol.for("react.memo_cache_sentinel") ? (k = /* @__PURE__ */ Q(Ie, {}), n[5] = k) : k = n[5];
|
|
999
|
-
let A;
|
|
1000
|
-
n[6] !== c || n[7] !== u ? (A = c ? /* @__PURE__ */ Q(l, {
|
|
1001
|
-
content: u,
|
|
1002
|
-
children: /* @__PURE__ */ Q(Oe, {
|
|
1003
|
-
size: "2xs",
|
|
1004
|
-
variant: "ghost",
|
|
1005
|
-
"aria-label": u,
|
|
1006
|
-
onClick: c,
|
|
1007
|
-
children: /* @__PURE__ */ Q(Ct, { size: 16 })
|
|
1008
|
-
})
|
|
1009
|
-
}) : null, n[6] = c, n[7] = u, n[8] = A) : A = n[8];
|
|
1010
|
-
let j;
|
|
1011
|
-
n[9] !== s || n[10] !== o ? (j = o ? /* @__PURE__ */ Q(l, {
|
|
1012
|
-
content: s,
|
|
1013
|
-
children: /* @__PURE__ */ Q(Oe, {
|
|
1014
|
-
size: "2xs",
|
|
1015
|
-
variant: "ghost",
|
|
1016
|
-
"aria-label": s,
|
|
1017
|
-
onClick: o,
|
|
1018
|
-
children: /* @__PURE__ */ Q(vt, { size: 16 })
|
|
1019
|
-
})
|
|
1020
|
-
}) : null, n[9] = s, n[10] = o, n[11] = j) : j = n[11];
|
|
1021
|
-
let M;
|
|
1022
|
-
n[12] !== A || n[13] !== j ? (M = /* @__PURE__ */ $(J, {
|
|
1023
|
-
gap: "1",
|
|
1024
|
-
children: [A, j]
|
|
1025
|
-
}), n[12] = A, n[13] = j, n[14] = M) : M = n[14];
|
|
1026
|
-
let N;
|
|
1027
|
-
n[15] !== M || n[16] !== O ? (N = /* @__PURE__ */ $(p, {
|
|
986
|
+
}), Yn = et(function(e, t) {
|
|
987
|
+
let n = Z(28), { isOpen: r, title: i, menu: a, header: o, onClose: s, closeLabel: c, onPopOut: u, popOutLabel: d, width: f, height: m, containerProps: h, testId: g, "aria-label": _, children: v, overlay: y } = e, b = r !== void 0 && r, x = f === void 0 ? "28rem" : f, S = m === void 0 ? "38rem" : m, C;
|
|
988
|
+
n[0] === Symbol.for("react.memo_cache_sentinel") ? (C = { key: "bubblePanel" }, n[0] = C) : C = n[0];
|
|
989
|
+
let w = qe(C), T = _ ?? i, E;
|
|
990
|
+
n[1] === w ? E = n[2] : (E = w(), n[1] = w, n[2] = E);
|
|
991
|
+
let D = !b, O = !b, k;
|
|
992
|
+
n[3] !== c || n[4] !== o || n[5] !== a || n[6] !== s || n[7] !== u || n[8] !== d ? (k = o === void 0 ? /* @__PURE__ */ $(p, {
|
|
1028
993
|
variant: "main",
|
|
1029
994
|
gap: "sm",
|
|
1030
995
|
flexShrink: 0,
|
|
1031
996
|
children: [
|
|
1032
|
-
|
|
1033
|
-
|
|
1034
|
-
|
|
997
|
+
/* @__PURE__ */ Q(J, {
|
|
998
|
+
gap: "1",
|
|
999
|
+
minW: "0",
|
|
1000
|
+
children: a
|
|
1001
|
+
}),
|
|
1002
|
+
/* @__PURE__ */ Q(Ie, {}),
|
|
1003
|
+
/* @__PURE__ */ $(J, {
|
|
1004
|
+
gap: "1",
|
|
1005
|
+
children: [u ? /* @__PURE__ */ Q(l, {
|
|
1006
|
+
content: d,
|
|
1007
|
+
children: /* @__PURE__ */ Q(Oe, {
|
|
1008
|
+
size: "2xs",
|
|
1009
|
+
variant: "ghost",
|
|
1010
|
+
"aria-label": d,
|
|
1011
|
+
onClick: u,
|
|
1012
|
+
children: /* @__PURE__ */ Q(wt, { size: 16 })
|
|
1013
|
+
})
|
|
1014
|
+
}) : null, s ? /* @__PURE__ */ Q(l, {
|
|
1015
|
+
content: c,
|
|
1016
|
+
children: /* @__PURE__ */ Q(Oe, {
|
|
1017
|
+
size: "2xs",
|
|
1018
|
+
variant: "ghost",
|
|
1019
|
+
"aria-label": c,
|
|
1020
|
+
onClick: s,
|
|
1021
|
+
children: /* @__PURE__ */ Q(yt, { size: 16 })
|
|
1022
|
+
})
|
|
1023
|
+
}) : null]
|
|
1024
|
+
})
|
|
1035
1025
|
]
|
|
1036
|
-
}), n[
|
|
1037
|
-
let
|
|
1038
|
-
n[
|
|
1026
|
+
}) : o, n[3] = c, n[4] = o, n[5] = a, n[6] = s, n[7] = u, n[8] = d, n[9] = k) : k = n[9];
|
|
1027
|
+
let A;
|
|
1028
|
+
n[10] === v ? A = n[11] : (A = /* @__PURE__ */ Q(G, {
|
|
1039
1029
|
flex: "1",
|
|
1040
1030
|
minH: 0,
|
|
1041
1031
|
display: "flex",
|
|
1042
1032
|
flexDirection: "column",
|
|
1043
1033
|
gap: "sm",
|
|
1044
|
-
children:
|
|
1045
|
-
}), n[
|
|
1046
|
-
let
|
|
1047
|
-
n[
|
|
1034
|
+
children: v
|
|
1035
|
+
}), n[10] = v, n[11] = A);
|
|
1036
|
+
let j;
|
|
1037
|
+
n[12] !== k || n[13] !== A ? (j = /* @__PURE__ */ $(q, {
|
|
1048
1038
|
direction: "column",
|
|
1049
1039
|
h: "full",
|
|
1050
|
-
children: [
|
|
1051
|
-
}), n[
|
|
1052
|
-
let
|
|
1053
|
-
return n[
|
|
1040
|
+
children: [k, A]
|
|
1041
|
+
}), n[12] = k, n[13] = A, n[14] = j) : j = n[14];
|
|
1042
|
+
let M;
|
|
1043
|
+
return n[15] !== h || n[16] !== S || n[17] !== b || n[18] !== y || n[19] !== t || n[20] !== j || n[21] !== T || n[22] !== E || n[23] !== D || n[24] !== O || n[25] !== g || n[26] !== x ? (M = /* @__PURE__ */ Q(Pe, { children: /* @__PURE__ */ $(He.section, {
|
|
1054
1044
|
ref: t,
|
|
1055
1045
|
role: "dialog",
|
|
1056
|
-
"data-testid":
|
|
1057
|
-
"aria-label":
|
|
1046
|
+
"data-testid": g,
|
|
1047
|
+
"aria-label": T,
|
|
1058
1048
|
position: "fixed",
|
|
1059
1049
|
bottom: "3",
|
|
1060
1050
|
right: "3",
|
|
1061
|
-
w:
|
|
1051
|
+
w: x,
|
|
1062
1052
|
maxW: "calc(100vw - 2rem)",
|
|
1063
|
-
h:
|
|
1053
|
+
h: S,
|
|
1064
1054
|
maxH: "calc(100vh - 2rem)",
|
|
1065
1055
|
borderRadius: "xs",
|
|
1066
1056
|
borderWidth: "1px",
|
|
@@ -1068,45 +1058,45 @@ var Wn = (e) => {
|
|
|
1068
1058
|
bg: "bg",
|
|
1069
1059
|
overflow: "hidden",
|
|
1070
1060
|
zIndex: "dropdown",
|
|
1071
|
-
...
|
|
1072
|
-
css:
|
|
1073
|
-
"data-open":
|
|
1074
|
-
inert:
|
|
1075
|
-
"aria-hidden":
|
|
1076
|
-
children: [
|
|
1077
|
-
}) }), n[
|
|
1078
|
-
}),
|
|
1061
|
+
...h,
|
|
1062
|
+
css: E,
|
|
1063
|
+
"data-open": b,
|
|
1064
|
+
inert: D,
|
|
1065
|
+
"aria-hidden": O,
|
|
1066
|
+
children: [j, y]
|
|
1067
|
+
}) }), n[15] = h, n[16] = S, n[17] = b, n[18] = y, n[19] = t, n[20] = j, n[21] = T, n[22] = E, n[23] = D, n[24] = O, n[25] = g, n[26] = x, n[27] = M) : M = n[27], M;
|
|
1068
|
+
}), Xn = (e) => {
|
|
1079
1069
|
let [t, n] = it(!1), { headline: r, buttonText: i, notificationText: a, onDelete: o, open: s, onClose: c, children: l } = e;
|
|
1080
|
-
return /* @__PURE__ */ Q(
|
|
1070
|
+
return /* @__PURE__ */ Q(K.Root, {
|
|
1081
1071
|
size: "sm",
|
|
1082
1072
|
open: s,
|
|
1083
1073
|
onOpenChange: (e) => {
|
|
1084
1074
|
!e.open && !t && c();
|
|
1085
1075
|
},
|
|
1086
1076
|
closeOnInteractOutside: !1,
|
|
1087
|
-
children: /* @__PURE__ */ $(Pe, { children: [/* @__PURE__ */ Q(
|
|
1088
|
-
/* @__PURE__ */ $(
|
|
1077
|
+
children: /* @__PURE__ */ $(Pe, { children: [/* @__PURE__ */ Q(K.Backdrop, {}), /* @__PURE__ */ Q(K.Positioner, { children: /* @__PURE__ */ $(K.Content, { children: [
|
|
1078
|
+
/* @__PURE__ */ $(K.Header, { children: [/* @__PURE__ */ Q(X, {
|
|
1089
1079
|
textStyle: "heading/M",
|
|
1090
1080
|
children: r
|
|
1091
|
-
}), /* @__PURE__ */ Q(
|
|
1081
|
+
}), /* @__PURE__ */ Q(K.CloseTrigger, {
|
|
1092
1082
|
asChild: !0,
|
|
1093
|
-
children: /* @__PURE__ */ Q(
|
|
1083
|
+
children: /* @__PURE__ */ Q(we, {
|
|
1094
1084
|
size: "sm",
|
|
1095
1085
|
disabled: t
|
|
1096
1086
|
})
|
|
1097
1087
|
})] }),
|
|
1098
|
-
/* @__PURE__ */ Q(
|
|
1088
|
+
/* @__PURE__ */ Q(K.Body, { children: /* @__PURE__ */ $(Re, {
|
|
1099
1089
|
gap: "3",
|
|
1100
1090
|
children: [a ? /* @__PURE__ */ Q(X, { children: a }) : null, l]
|
|
1101
1091
|
}) }),
|
|
1102
|
-
/* @__PURE__ */ Q(
|
|
1092
|
+
/* @__PURE__ */ Q(K.Footer, { children: /* @__PURE__ */ $(Re, {
|
|
1103
1093
|
direction: "row",
|
|
1104
1094
|
gap: "1",
|
|
1105
|
-
children: [/* @__PURE__ */ Q(
|
|
1095
|
+
children: [/* @__PURE__ */ Q(xe, {
|
|
1106
1096
|
onClick: c,
|
|
1107
1097
|
disabled: t,
|
|
1108
1098
|
children: "Close"
|
|
1109
|
-
}), /* @__PURE__ */ Q(
|
|
1099
|
+
}), /* @__PURE__ */ Q(xe, {
|
|
1110
1100
|
loading: t,
|
|
1111
1101
|
variant: "destructive",
|
|
1112
1102
|
onClick: async () => {
|
|
@@ -1122,83 +1112,194 @@ var Wn = (e) => {
|
|
|
1122
1112
|
}) })
|
|
1123
1113
|
] }) })] })
|
|
1124
1114
|
});
|
|
1125
|
-
},
|
|
1126
|
-
let
|
|
1127
|
-
t
|
|
1128
|
-
let
|
|
1115
|
+
}, Zn = (e) => {
|
|
1116
|
+
let t = Z(43), { drives: n, currentPath: r, disabled: i, onNavigate: a } = e, o;
|
|
1117
|
+
t[0] === Symbol.for("react.memo_cache_sentinel") ? (o = { key: "folderPicker" }, t[0] = o) : o = t[0];
|
|
1118
|
+
let s = Je(o), c;
|
|
1119
|
+
t[1] === s ? c = t[2] : (c = s({}), t[1] = s, t[2] = c);
|
|
1120
|
+
let l = c, u, d, f, p, h, g, _, v, y, b;
|
|
1121
|
+
if (t[3] !== r || t[4] !== i || t[5] !== n || t[6] !== l.driveTrigger) {
|
|
1122
|
+
let e = r.match(/^[a-z]:[\\/]/i)?.[0].replaceAll("\\", "/").toUpperCase();
|
|
1123
|
+
f = n.find((t) => t.path.replaceAll("\\", "/").toUpperCase() === e), d = m, u = xe, p = "sm", h = "ghost", g = l.driveTrigger, _ = "Drive", v = i, t[17] === Symbol.for("react.memo_cache_sentinel") ? (y = /* @__PURE__ */ Q(_t, {}), t[17] = y) : y = t[17], b = f?.name ?? e?.slice(0, 2) ?? "Drive", t[3] = r, t[4] = i, t[5] = n, t[6] = l.driveTrigger, t[7] = u, t[8] = d, t[9] = f, t[10] = p, t[11] = h, t[12] = g, t[13] = _, t[14] = v, t[15] = y, t[16] = b;
|
|
1124
|
+
} else u = t[7], d = t[8], f = t[9], p = t[10], h = t[11], g = t[12], _ = t[13], v = t[14], y = t[15], b = t[16];
|
|
1125
|
+
let x;
|
|
1126
|
+
t[18] === Symbol.for("react.memo_cache_sentinel") ? (x = /* @__PURE__ */ Q(ut, {}), t[18] = x) : x = t[18];
|
|
1127
|
+
let S;
|
|
1128
|
+
t[19] !== u || t[20] !== p || t[21] !== h || t[22] !== g || t[23] !== _ || t[24] !== v || t[25] !== y || t[26] !== b ? (S = /* @__PURE__ */ $(u, {
|
|
1129
|
+
size: p,
|
|
1130
|
+
variant: h,
|
|
1131
|
+
css: g,
|
|
1132
|
+
"aria-label": _,
|
|
1133
|
+
disabled: v,
|
|
1134
|
+
children: [
|
|
1135
|
+
y,
|
|
1136
|
+
b,
|
|
1137
|
+
x
|
|
1138
|
+
]
|
|
1139
|
+
}), t[19] = u, t[20] = p, t[21] = h, t[22] = g, t[23] = _, t[24] = v, t[25] = y, t[26] = b, t[27] = S) : S = t[27];
|
|
1140
|
+
let C;
|
|
1141
|
+
if (t[28] !== n || t[29] !== a || t[30] !== f) {
|
|
1142
|
+
let e;
|
|
1143
|
+
t[32] !== a || t[33] !== f ? (e = (e) => ({
|
|
1144
|
+
id: e.path,
|
|
1145
|
+
label: e.name,
|
|
1146
|
+
icon: _t,
|
|
1147
|
+
isSelected: e === f,
|
|
1148
|
+
onSelect: () => a(e.path)
|
|
1149
|
+
}), t[32] = a, t[33] = f, t[34] = e) : e = t[34], C = n.map(e), t[28] = n, t[29] = a, t[30] = f, t[31] = C;
|
|
1150
|
+
} else C = t[31];
|
|
1151
|
+
let w;
|
|
1152
|
+
t[35] === l.driveLabel ? w = t[36] : (w = /* @__PURE__ */ Q(X, {
|
|
1153
|
+
css: l.driveLabel,
|
|
1154
|
+
children: "Drives"
|
|
1155
|
+
}), t[35] = l.driveLabel, t[36] = w);
|
|
1156
|
+
let T;
|
|
1157
|
+
t[37] === Symbol.for("react.memo_cache_sentinel") ? (T = {
|
|
1158
|
+
placement: "bottom-start",
|
|
1159
|
+
strategy: "fixed",
|
|
1160
|
+
hideWhenDetached: !0
|
|
1161
|
+
}, t[37] = T) : T = t[37];
|
|
1162
|
+
let E;
|
|
1163
|
+
return t[38] !== d || t[39] !== S || t[40] !== C || t[41] !== w ? (E = /* @__PURE__ */ Q(d, {
|
|
1164
|
+
trigger: S,
|
|
1165
|
+
items: C,
|
|
1166
|
+
header: w,
|
|
1167
|
+
width: "60",
|
|
1168
|
+
showSearch: !1,
|
|
1169
|
+
searchPlaceholder: "Search drives",
|
|
1170
|
+
emptyState: "No drives available.",
|
|
1171
|
+
portalled: !1,
|
|
1172
|
+
positioning: T
|
|
1173
|
+
}), t[38] = d, t[39] = S, t[40] = C, t[41] = w, t[42] = E) : E = t[42], E;
|
|
1174
|
+
}, Qn = (e) => {
|
|
1175
|
+
let t = Z(39), { entries: n, query: r, isLoading: i, isUnavailable: a, disabled: o, onNavigate: s } = e, c;
|
|
1176
|
+
t[0] === Symbol.for("react.memo_cache_sentinel") ? (c = { key: "folderPicker" }, t[0] = c) : c = t[0];
|
|
1177
|
+
let l = Je(c), d;
|
|
1178
|
+
t[1] === l ? d = t[2] : (d = l({}), t[1] = l, t[2] = d);
|
|
1179
|
+
let f = d, p, m, g, _, v, y, b, x, S;
|
|
1180
|
+
if (t[3] !== o || t[4] !== n || t[5] !== i || t[6] !== a || t[7] !== s || t[8] !== r || t[9] !== f.list || t[10] !== f.rows) {
|
|
1181
|
+
let e;
|
|
1182
|
+
t[20] === r ? e = t[21] : (e = (e) => e.isDirectory && e.name.toLocaleLowerCase().includes(r.toLocaleLowerCase()), t[20] = r, t[21] = e);
|
|
1183
|
+
let c = n.filter(e);
|
|
1184
|
+
m = u, S = f.list, p = G, g = f.rows, _ = "Folders", t[22] === i ? v = t[23] : (v = i && /* @__PURE__ */ Q(X, {
|
|
1185
|
+
color: "fg.muted",
|
|
1186
|
+
children: "Loading folders..."
|
|
1187
|
+
}), t[22] = i, t[23] = v), t[24] !== i || t[25] !== a ? (y = !i && a && /* @__PURE__ */ Q(X, {
|
|
1188
|
+
color: "fg.muted",
|
|
1189
|
+
children: "Choose another drive, enter a folder path, or go Home."
|
|
1190
|
+
}), t[24] = i, t[25] = a, t[26] = y) : y = t[26], b = !i && !a && c.length === 0 && /* @__PURE__ */ Q(X, {
|
|
1191
|
+
color: "fg.muted",
|
|
1192
|
+
children: r ? "No matching folders." : "This folder is empty."
|
|
1193
|
+
}), x = !i && c.map((e) => /* @__PURE__ */ Q(h, {
|
|
1194
|
+
id: e.path,
|
|
1195
|
+
label: e.name,
|
|
1196
|
+
icon: /* @__PURE__ */ Q(mt, {}),
|
|
1197
|
+
disabled: o,
|
|
1198
|
+
onActivate: () => s(e.path)
|
|
1199
|
+
}, e.path)), t[3] = o, t[4] = n, t[5] = i, t[6] = a, t[7] = s, t[8] = r, t[9] = f.list, t[10] = f.rows, t[11] = p, t[12] = m, t[13] = g, t[14] = _, t[15] = v, t[16] = y, t[17] = b, t[18] = x, t[19] = S;
|
|
1200
|
+
} else p = t[11], m = t[12], g = t[13], _ = t[14], v = t[15], y = t[16], b = t[17], x = t[18], S = t[19];
|
|
1201
|
+
let C;
|
|
1202
|
+
t[27] !== p || t[28] !== g || t[29] !== _ || t[30] !== v || t[31] !== y || t[32] !== b || t[33] !== x ? (C = /* @__PURE__ */ $(p, {
|
|
1203
|
+
css: g,
|
|
1204
|
+
"aria-label": _,
|
|
1205
|
+
children: [
|
|
1206
|
+
v,
|
|
1207
|
+
y,
|
|
1208
|
+
b,
|
|
1209
|
+
x
|
|
1210
|
+
]
|
|
1211
|
+
}), t[27] = p, t[28] = g, t[29] = _, t[30] = v, t[31] = y, t[32] = b, t[33] = x, t[34] = C) : C = t[34];
|
|
1212
|
+
let w;
|
|
1213
|
+
return t[35] !== m || t[36] !== C || t[37] !== S ? (w = /* @__PURE__ */ Q(m, {
|
|
1214
|
+
css: S,
|
|
1215
|
+
children: C
|
|
1216
|
+
}), t[35] = m, t[36] = C, t[37] = S, t[38] = w) : w = t[38], w;
|
|
1217
|
+
}, $n = (e) => {
|
|
1218
|
+
let { currentPath: t, entries: n, drives: r = [], isUnavailable: i, isLoading: a, isOpening: o, error: s, onClose: c, onSelect: l, onNavigate: u, onCreateFolder: d } = e, f = Je({ key: "folderPicker" })({}), [p, m] = it(t), [h, g] = it(t), [_, v] = it(""), [y, b] = it(!1), [x, S] = it(""), [C, w] = it(!1);
|
|
1219
|
+
t !== h && (g(t), m(t), v(""));
|
|
1220
|
+
let T = t.replaceAll("\\", "/"), E = T.match(/^\/\/[^/]+\/[^/]+/)?.[0] ?? T.match(/^[a-z]:\//i)?.[0] ?? "/", D = T.replace(/\/+$/, "").split("/").slice(0, -1).join("/"), O = D.length < E.length ? E : D, k = T.replace(/\/+$/, "") === E.replace(/\/+$/, ""), A = (e) => {
|
|
1221
|
+
b(!1), S(""), u(e);
|
|
1222
|
+
}, j = async () => {
|
|
1129
1223
|
if (x.trim()) {
|
|
1130
1224
|
w(!0);
|
|
1131
1225
|
try {
|
|
1132
|
-
await
|
|
1226
|
+
await d(x), b(!1), S("");
|
|
1133
1227
|
} catch {} finally {
|
|
1134
1228
|
w(!1);
|
|
1135
1229
|
}
|
|
1136
1230
|
}
|
|
1137
1231
|
};
|
|
1138
1232
|
return /* @__PURE__ */ $(Ye, { children: [
|
|
1139
|
-
/* @__PURE__ */ Q(
|
|
1140
|
-
css:
|
|
1141
|
-
children: /* @__PURE__ */ Q(
|
|
1233
|
+
/* @__PURE__ */ Q(K.Header, {
|
|
1234
|
+
css: f.header,
|
|
1235
|
+
children: /* @__PURE__ */ Q(K.Title, { children: "Open project folder" })
|
|
1142
1236
|
}),
|
|
1143
|
-
/* @__PURE__ */ $(
|
|
1144
|
-
css:
|
|
1237
|
+
/* @__PURE__ */ $(K.Body, {
|
|
1238
|
+
css: f.body,
|
|
1145
1239
|
children: [
|
|
1146
|
-
/* @__PURE__ */ $(
|
|
1147
|
-
css:
|
|
1240
|
+
/* @__PURE__ */ $(G, {
|
|
1241
|
+
css: f.navigation,
|
|
1148
1242
|
children: [
|
|
1149
|
-
/* @__PURE__ */ Q(
|
|
1243
|
+
/* @__PURE__ */ Q(xe, {
|
|
1150
1244
|
size: "sm",
|
|
1151
1245
|
variant: "outline",
|
|
1152
|
-
css:
|
|
1246
|
+
css: f.navigationButton,
|
|
1153
1247
|
"aria-label": "Go to home directory",
|
|
1154
|
-
disabled:
|
|
1155
|
-
onClick: () =>
|
|
1156
|
-
children: /* @__PURE__ */ Q(
|
|
1248
|
+
disabled: a || o || C,
|
|
1249
|
+
onClick: () => A("~"),
|
|
1250
|
+
children: /* @__PURE__ */ Q(vt, {})
|
|
1157
1251
|
}),
|
|
1158
|
-
/* @__PURE__ */ Q(
|
|
1252
|
+
/* @__PURE__ */ Q(xe, {
|
|
1159
1253
|
size: "sm",
|
|
1160
1254
|
variant: "outline",
|
|
1161
|
-
css:
|
|
1255
|
+
css: f.navigationButton,
|
|
1162
1256
|
"aria-label": "Go to parent directory",
|
|
1163
|
-
disabled:
|
|
1164
|
-
onClick: () =>
|
|
1257
|
+
disabled: a || o || C || k || !t || i,
|
|
1258
|
+
onClick: () => A(O),
|
|
1165
1259
|
children: /* @__PURE__ */ Q(st, {})
|
|
1166
1260
|
}),
|
|
1261
|
+
r.length > 0 && /* @__PURE__ */ Q(Zn, {
|
|
1262
|
+
drives: r,
|
|
1263
|
+
currentPath: t,
|
|
1264
|
+
disabled: !!(a || o || C),
|
|
1265
|
+
onNavigate: A
|
|
1266
|
+
}),
|
|
1167
1267
|
/* @__PURE__ */ Q(ke, {
|
|
1168
|
-
css:
|
|
1268
|
+
css: f.path,
|
|
1169
1269
|
size: "sm",
|
|
1170
1270
|
variant: "borderless",
|
|
1171
|
-
title:
|
|
1271
|
+
title: p,
|
|
1172
1272
|
"aria-label": "Folder path",
|
|
1173
|
-
value:
|
|
1174
|
-
onChange: (e) =>
|
|
1273
|
+
value: p,
|
|
1274
|
+
onChange: (e) => m(e.target.value),
|
|
1175
1275
|
onKeyDown: (e) => {
|
|
1176
|
-
e.key === "Enter" &&
|
|
1276
|
+
e.key === "Enter" && A(p);
|
|
1177
1277
|
},
|
|
1178
|
-
disabled:
|
|
1278
|
+
disabled: a || o || C
|
|
1179
1279
|
}),
|
|
1180
|
-
!y && /* @__PURE__ */ $(
|
|
1280
|
+
!y && /* @__PURE__ */ $(xe, {
|
|
1181
1281
|
variant: "outline",
|
|
1182
1282
|
size: "sm",
|
|
1183
|
-
disabled: !t ||
|
|
1283
|
+
disabled: !t || i || a || o,
|
|
1184
1284
|
onClick: () => b(!0),
|
|
1185
1285
|
children: [/* @__PURE__ */ Q(ht, {}), "New folder"]
|
|
1186
1286
|
})
|
|
1187
1287
|
]
|
|
1188
1288
|
}),
|
|
1189
1289
|
!y && /* @__PURE__ */ Q(Ae, {
|
|
1190
|
-
css:
|
|
1191
|
-
startElement: /* @__PURE__ */ Q(
|
|
1290
|
+
css: f.filter,
|
|
1291
|
+
startElement: /* @__PURE__ */ Q(Ct, {}),
|
|
1192
1292
|
children: /* @__PURE__ */ Q(ke, {
|
|
1193
1293
|
size: "sm",
|
|
1194
1294
|
"aria-label": "Filter folders",
|
|
1195
1295
|
placeholder: "Filter folders",
|
|
1196
1296
|
value: _,
|
|
1297
|
+
disabled: i,
|
|
1197
1298
|
onChange: (e) => v(e.target.value)
|
|
1198
1299
|
})
|
|
1199
1300
|
}),
|
|
1200
|
-
y && /* @__PURE__ */ $(
|
|
1201
|
-
css:
|
|
1301
|
+
y && /* @__PURE__ */ $(G, {
|
|
1302
|
+
css: f.creation,
|
|
1202
1303
|
children: [/* @__PURE__ */ Q(ke, {
|
|
1203
1304
|
size: "sm",
|
|
1204
1305
|
"aria-label": "New folder name",
|
|
@@ -1209,7 +1310,7 @@ var Wn = (e) => {
|
|
|
1209
1310
|
onKeyDown: (e) => {
|
|
1210
1311
|
e.key === "Enter" && j();
|
|
1211
1312
|
}
|
|
1212
|
-
}), /* @__PURE__ */ $(
|
|
1313
|
+
}), /* @__PURE__ */ $(xe, {
|
|
1213
1314
|
size: "sm",
|
|
1214
1315
|
variant: "primary",
|
|
1215
1316
|
disabled: !x.trim(),
|
|
@@ -1218,57 +1319,41 @@ var Wn = (e) => {
|
|
|
1218
1319
|
children: [/* @__PURE__ */ Q(ht, {}), "Create folder"]
|
|
1219
1320
|
})]
|
|
1220
1321
|
}),
|
|
1221
|
-
|
|
1322
|
+
s && /* @__PURE__ */ Q(X, {
|
|
1222
1323
|
role: "alert",
|
|
1223
1324
|
color: "fg.error",
|
|
1224
1325
|
textStyle: "paragraph/S/regular",
|
|
1225
|
-
children:
|
|
1326
|
+
children: s
|
|
1226
1327
|
}),
|
|
1227
|
-
/* @__PURE__ */ Q(
|
|
1228
|
-
|
|
1229
|
-
|
|
1230
|
-
|
|
1231
|
-
|
|
1232
|
-
|
|
1233
|
-
|
|
1234
|
-
color: "fg.muted",
|
|
1235
|
-
children: "Loading folders..."
|
|
1236
|
-
}),
|
|
1237
|
-
!r && T.length === 0 && /* @__PURE__ */ Q(X, {
|
|
1238
|
-
color: "fg.muted",
|
|
1239
|
-
children: _ ? "No matching folders." : "This folder is empty."
|
|
1240
|
-
}),
|
|
1241
|
-
!r && T.map((e) => /* @__PURE__ */ Q(h, {
|
|
1242
|
-
id: e.path,
|
|
1243
|
-
label: e.name,
|
|
1244
|
-
icon: /* @__PURE__ */ Q(mt, {}),
|
|
1245
|
-
disabled: r || i,
|
|
1246
|
-
onActivate: () => c(e.path)
|
|
1247
|
-
}, e.path))
|
|
1248
|
-
]
|
|
1249
|
-
})
|
|
1328
|
+
/* @__PURE__ */ Q(Qn, {
|
|
1329
|
+
entries: n,
|
|
1330
|
+
query: _,
|
|
1331
|
+
isLoading: a,
|
|
1332
|
+
isUnavailable: i,
|
|
1333
|
+
disabled: !!(a || o || C),
|
|
1334
|
+
onNavigate: A
|
|
1250
1335
|
})
|
|
1251
1336
|
]
|
|
1252
1337
|
}),
|
|
1253
|
-
/* @__PURE__ */ $(
|
|
1254
|
-
css:
|
|
1255
|
-
children: [/* @__PURE__ */ Q(
|
|
1338
|
+
/* @__PURE__ */ $(K.Footer, {
|
|
1339
|
+
css: f.footer,
|
|
1340
|
+
children: [/* @__PURE__ */ Q(xe, {
|
|
1256
1341
|
size: "sm",
|
|
1257
1342
|
variant: "outline",
|
|
1258
|
-
onClick:
|
|
1259
|
-
disabled:
|
|
1343
|
+
onClick: c,
|
|
1344
|
+
disabled: a || o || C,
|
|
1260
1345
|
children: "Cancel"
|
|
1261
|
-
}), !y && /* @__PURE__ */ Q(
|
|
1346
|
+
}), !y && /* @__PURE__ */ Q(xe, {
|
|
1262
1347
|
size: "sm",
|
|
1263
1348
|
variant: "primary",
|
|
1264
|
-
onClick:
|
|
1265
|
-
loading:
|
|
1266
|
-
disabled: !t ||
|
|
1349
|
+
onClick: l,
|
|
1350
|
+
loading: o,
|
|
1351
|
+
disabled: !t || i || a || C,
|
|
1267
1352
|
children: "Open folder"
|
|
1268
1353
|
})]
|
|
1269
1354
|
})
|
|
1270
1355
|
] });
|
|
1271
|
-
},
|
|
1356
|
+
}, er = (e) => {
|
|
1272
1357
|
let t = Z(15), n;
|
|
1273
1358
|
t[0] === Symbol.for("react.memo_cache_sentinel") ? (n = { key: "folderPicker" }, t[0] = n) : n = t[0];
|
|
1274
1359
|
let r = Je(n), i;
|
|
@@ -1278,16 +1363,16 @@ var Wn = (e) => {
|
|
|
1278
1363
|
t.open || e.onClose();
|
|
1279
1364
|
}, t[3] = e, t[4] = o);
|
|
1280
1365
|
let s;
|
|
1281
|
-
t[5] === Symbol.for("react.memo_cache_sentinel") ? (s = /* @__PURE__ */ Q(
|
|
1366
|
+
t[5] === Symbol.for("react.memo_cache_sentinel") ? (s = /* @__PURE__ */ Q(K.Backdrop, {}), t[5] = s) : s = t[5];
|
|
1282
1367
|
let c;
|
|
1283
|
-
t[6] === e ? c = t[7] : (c = /* @__PURE__ */ Q(
|
|
1368
|
+
t[6] === e ? c = t[7] : (c = /* @__PURE__ */ Q($n, { ...e }), t[6] = e, t[7] = c);
|
|
1284
1369
|
let l;
|
|
1285
|
-
t[8] !== a.content || t[9] !== c ? (l = /* @__PURE__ */ Q(
|
|
1370
|
+
t[8] !== a.content || t[9] !== c ? (l = /* @__PURE__ */ Q(K.Positioner, { children: /* @__PURE__ */ Q(K.Content, {
|
|
1286
1371
|
css: a.content,
|
|
1287
1372
|
children: c
|
|
1288
1373
|
}) }), t[8] = a.content, t[9] = c, t[10] = l) : l = t[10];
|
|
1289
1374
|
let u;
|
|
1290
|
-
return t[11] !== e.open || t[12] !== o || t[13] !== l ? (u = /* @__PURE__ */ $(
|
|
1375
|
+
return t[11] !== e.open || t[12] !== o || t[13] !== l ? (u = /* @__PURE__ */ $(K.Root, {
|
|
1291
1376
|
placement: "center",
|
|
1292
1377
|
scrollBehavior: "inside",
|
|
1293
1378
|
open: e.open,
|
|
@@ -1297,7 +1382,7 @@ var Wn = (e) => {
|
|
|
1297
1382
|
unmountOnExit: !0,
|
|
1298
1383
|
children: [s, l]
|
|
1299
1384
|
}), t[11] = e.open, t[12] = o, t[13] = l, t[14] = u) : u = t[14], u;
|
|
1300
|
-
},
|
|
1385
|
+
}, tr = {
|
|
1301
1386
|
alignItems: "center",
|
|
1302
1387
|
display: "inline-flex",
|
|
1303
1388
|
gap: "2xs",
|
|
@@ -1310,27 +1395,27 @@ var Wn = (e) => {
|
|
|
1310
1395
|
_active: { outline: "none" },
|
|
1311
1396
|
_focus: { outline: "none" },
|
|
1312
1397
|
_focusVisible: { outline: "none" }
|
|
1313
|
-
},
|
|
1314
|
-
...
|
|
1398
|
+
}, nr = {
|
|
1399
|
+
...tr,
|
|
1315
1400
|
color: "fg",
|
|
1316
1401
|
cursor: "default",
|
|
1317
1402
|
textDecoration: "none",
|
|
1318
1403
|
_hover: { textDecoration: "none" }
|
|
1319
|
-
},
|
|
1404
|
+
}, rr = (e) => !!(e.url || e.onClick), ir = (e) => {
|
|
1320
1405
|
let t = Z(16), { item: n, isCurrent: r, linkComponent: i } = e;
|
|
1321
|
-
if (r && !
|
|
1406
|
+
if (r && !rr(n)) {
|
|
1322
1407
|
let e = n.contextMenuActions?.length ? 0 : void 0, r;
|
|
1323
|
-
return t[0] !== n.title || t[1] !== e ? (r = /* @__PURE__ */ Q(
|
|
1324
|
-
|
|
1408
|
+
return t[0] !== n.title || t[1] !== e ? (r = /* @__PURE__ */ Q(be.CurrentLink, {
|
|
1409
|
+
...nr,
|
|
1325
1410
|
tabIndex: e,
|
|
1326
1411
|
children: n.title
|
|
1327
1412
|
}), t[0] = n.title, t[1] = e, t[2] = r) : r = t[2], r;
|
|
1328
1413
|
}
|
|
1329
1414
|
if (n.url && i) {
|
|
1330
1415
|
let e;
|
|
1331
|
-
return t[3] !== i || t[4] !== n.title || t[5] !== n.url ? (e = /* @__PURE__ */ Q(
|
|
1416
|
+
return t[3] !== i || t[4] !== n.title || t[5] !== n.url ? (e = /* @__PURE__ */ Q(be.Link, {
|
|
1332
1417
|
asChild: !0,
|
|
1333
|
-
...
|
|
1418
|
+
...tr,
|
|
1334
1419
|
children: /* @__PURE__ */ Q(i, {
|
|
1335
1420
|
to: n.url,
|
|
1336
1421
|
children: n.title
|
|
@@ -1339,32 +1424,32 @@ var Wn = (e) => {
|
|
|
1339
1424
|
}
|
|
1340
1425
|
if (n.url) {
|
|
1341
1426
|
let e;
|
|
1342
|
-
return t[7] !== n.title || t[8] !== n.url ? (e = /* @__PURE__ */ Q(
|
|
1427
|
+
return t[7] !== n.title || t[8] !== n.url ? (e = /* @__PURE__ */ Q(be.Link, {
|
|
1343
1428
|
href: n.url,
|
|
1344
|
-
...
|
|
1429
|
+
...tr,
|
|
1345
1430
|
children: n.title
|
|
1346
1431
|
}), t[7] = n.title, t[8] = n.url, t[9] = e) : e = t[9], e;
|
|
1347
1432
|
}
|
|
1348
1433
|
if (n.onClick) {
|
|
1349
1434
|
let e;
|
|
1350
|
-
return t[10] !== n.onClick || t[11] !== n.title ? (e = /* @__PURE__ */ Q(
|
|
1435
|
+
return t[10] !== n.onClick || t[11] !== n.title ? (e = /* @__PURE__ */ Q(be.Link, {
|
|
1351
1436
|
as: "button",
|
|
1352
1437
|
type: "button",
|
|
1353
1438
|
onClick: n.onClick,
|
|
1354
|
-
...
|
|
1439
|
+
...tr,
|
|
1355
1440
|
children: n.title
|
|
1356
1441
|
}), t[10] = n.onClick, t[11] = n.title, t[12] = e) : e = t[12], e;
|
|
1357
1442
|
}
|
|
1358
1443
|
let a = n.contextMenuActions?.length ? 0 : void 0, o;
|
|
1359
|
-
return t[13] !== n.title || t[14] !== a ? (o = /* @__PURE__ */ Q(
|
|
1444
|
+
return t[13] !== n.title || t[14] !== a ? (o = /* @__PURE__ */ Q(be.Link, {
|
|
1360
1445
|
as: "span",
|
|
1361
|
-
|
|
1446
|
+
...nr,
|
|
1362
1447
|
tabIndex: a,
|
|
1363
1448
|
children: n.title
|
|
1364
1449
|
}), t[13] = n.title, t[14] = a, t[15] = o) : o = t[15], o;
|
|
1365
|
-
},
|
|
1450
|
+
}, ar = (e) => {
|
|
1366
1451
|
let t = Z(8), { item: n } = e, r;
|
|
1367
|
-
t[0] === e ? r = t[1] : (r = /* @__PURE__ */ Q(
|
|
1452
|
+
t[0] === e ? r = t[1] : (r = /* @__PURE__ */ Q(ir, { ...e }), t[0] = e, t[1] = r);
|
|
1368
1453
|
let i = r;
|
|
1369
1454
|
if (!n.contextMenuActions?.length) return i;
|
|
1370
1455
|
let a;
|
|
@@ -1382,18 +1467,18 @@ var Wn = (e) => {
|
|
|
1382
1467
|
positioning: a,
|
|
1383
1468
|
children: o
|
|
1384
1469
|
}), t[5] = n.contextMenuActions, t[6] = o, t[7] = s) : s = t[7], s;
|
|
1385
|
-
},
|
|
1470
|
+
}, or = (e) => {
|
|
1386
1471
|
let t = Z(3), { separator: n } = e;
|
|
1387
1472
|
if (n === void 0) {
|
|
1388
1473
|
let e;
|
|
1389
|
-
return t[0] === Symbol.for("react.memo_cache_sentinel") ? (e = /* @__PURE__ */ Q(
|
|
1474
|
+
return t[0] === Symbol.for("react.memo_cache_sentinel") ? (e = /* @__PURE__ */ Q(be.Separator, { flexShrink: 0 }), t[0] = e) : e = t[0], e;
|
|
1390
1475
|
}
|
|
1391
1476
|
let r;
|
|
1392
|
-
return t[1] === n ? r = t[2] : (r = /* @__PURE__ */ Q(
|
|
1477
|
+
return t[1] === n ? r = t[2] : (r = /* @__PURE__ */ Q(be.Separator, {
|
|
1393
1478
|
flexShrink: 0,
|
|
1394
1479
|
children: n
|
|
1395
1480
|
}), t[1] = n, t[2] = r), r;
|
|
1396
|
-
},
|
|
1481
|
+
}, sr = Xe.forwardRef(function(e, t) {
|
|
1397
1482
|
let n = Z(21), r, i, a, o, s;
|
|
1398
1483
|
n[0] === e ? (r = n[1], i = n[2], a = n[3], o = n[4], s = n[5]) : ({separator: o, separatorGap: s, items: i, linkComponent: r, ...a} = e, n[0] = e, n[1] = r, n[2] = i, n[3] = a, n[4] = o, n[5] = s);
|
|
1399
1484
|
let c;
|
|
@@ -1401,20 +1486,20 @@ var Wn = (e) => {
|
|
|
1401
1486
|
let e;
|
|
1402
1487
|
n[10] !== r || n[11] !== i.length || n[12] !== o ? (e = (e, t) => {
|
|
1403
1488
|
let n = t === i.length - 1;
|
|
1404
|
-
return /* @__PURE__ */ $(Xe.Fragment, { children: [/* @__PURE__ */ Q(
|
|
1489
|
+
return /* @__PURE__ */ $(Xe.Fragment, { children: [/* @__PURE__ */ Q(be.Item, {
|
|
1405
1490
|
minW: "0",
|
|
1406
1491
|
flexShrink: +!!n,
|
|
1407
1492
|
overflow: "hidden",
|
|
1408
|
-
children: /* @__PURE__ */ Q(
|
|
1493
|
+
children: /* @__PURE__ */ Q(ar, {
|
|
1409
1494
|
item: e,
|
|
1410
1495
|
isCurrent: n,
|
|
1411
1496
|
linkComponent: r
|
|
1412
1497
|
})
|
|
1413
|
-
}), n ? null : /* @__PURE__ */ Q(
|
|
1498
|
+
}), n ? null : /* @__PURE__ */ Q(or, { separator: o })] }, t);
|
|
1414
1499
|
}, n[10] = r, n[11] = i.length, n[12] = o, n[13] = e) : e = n[13], c = i.map(e), n[6] = r, n[7] = i, n[8] = o, n[9] = c;
|
|
1415
1500
|
} else c = n[9];
|
|
1416
1501
|
let l;
|
|
1417
|
-
n[14] !== s || n[15] !== c ? (l = /* @__PURE__ */ Q(
|
|
1502
|
+
n[14] !== s || n[15] !== c ? (l = /* @__PURE__ */ Q(be.List, {
|
|
1418
1503
|
gap: s,
|
|
1419
1504
|
flexWrap: "nowrap",
|
|
1420
1505
|
minW: "0",
|
|
@@ -1423,27 +1508,27 @@ var Wn = (e) => {
|
|
|
1423
1508
|
children: c
|
|
1424
1509
|
}), n[14] = s, n[15] = c, n[16] = l) : l = n[16];
|
|
1425
1510
|
let u;
|
|
1426
|
-
return n[17] !== t || n[18] !== a || n[19] !== l ? (u = /* @__PURE__ */ Q(
|
|
1511
|
+
return n[17] !== t || n[18] !== a || n[19] !== l ? (u = /* @__PURE__ */ Q(be.Root, {
|
|
1427
1512
|
ref: t,
|
|
1428
1513
|
...a,
|
|
1429
1514
|
children: l
|
|
1430
1515
|
}), n[17] = t, n[18] = a, n[19] = l, n[20] = u) : u = n[20], u;
|
|
1431
|
-
}),
|
|
1516
|
+
}), cr = "url(\"data:image/svg+xml,%3Csvg width='6' height='6' viewBox='0 0 6 6' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='%239C92AC' fill-opacity='0.2' fillRule='evenodd'%3E%3Cpath d='M5 0h1L0 6V5zM6 5v1H5z'/%3E%3C/g%3E%3C/svg%3E\")", lr = (e) => {
|
|
1432
1517
|
let t = Z(3), n;
|
|
1433
1518
|
t[0] === Symbol.for("react.memo_cache_sentinel") ? (n = {
|
|
1434
1519
|
backgroundClip: "padding-box",
|
|
1435
|
-
backgroundImage:
|
|
1520
|
+
backgroundImage: cr,
|
|
1436
1521
|
display: "flex",
|
|
1437
1522
|
width: "100%"
|
|
1438
1523
|
}, t[0] = n) : n = t[0];
|
|
1439
1524
|
let r;
|
|
1440
|
-
return t[1] === e ? r = t[2] : (r = /* @__PURE__ */ Q(
|
|
1525
|
+
return t[1] === e ? r = t[2] : (r = /* @__PURE__ */ Q(G, {
|
|
1441
1526
|
...e,
|
|
1442
1527
|
css: n
|
|
1443
1528
|
}), t[1] = e, t[2] = r), r;
|
|
1444
|
-
},
|
|
1529
|
+
}, ur = (e) => {
|
|
1445
1530
|
let t = Z(2), n;
|
|
1446
|
-
return t[0] === e ? n = t[1] : (n = /* @__PURE__ */ Q(
|
|
1531
|
+
return t[0] === e ? n = t[1] : (n = /* @__PURE__ */ Q(G, {
|
|
1447
1532
|
p: "2",
|
|
1448
1533
|
children: /* @__PURE__ */ Q(X, {
|
|
1449
1534
|
color: "fg.muted",
|
|
@@ -1453,7 +1538,7 @@ var Wn = (e) => {
|
|
|
1453
1538
|
...e
|
|
1454
1539
|
})
|
|
1455
1540
|
}), t[0] = e, t[1] = n), n;
|
|
1456
|
-
},
|
|
1541
|
+
}, dr = (e) => {
|
|
1457
1542
|
let { text: t, label: n = "Copy", onCopy: r, onCopyError: i, disabled: a, ...o } = e, [s, c] = it("ready"), u = rt(null);
|
|
1458
1543
|
nt(() => () => {
|
|
1459
1544
|
u.current && clearTimeout(u.current);
|
|
@@ -1480,7 +1565,7 @@ var Wn = (e) => {
|
|
|
1480
1565
|
children: Q(s === "copied" ? lt : pt, {})
|
|
1481
1566
|
})
|
|
1482
1567
|
});
|
|
1483
|
-
},
|
|
1568
|
+
}, fr = class extends Ze {
|
|
1484
1569
|
state = { error: null };
|
|
1485
1570
|
static getDerivedStateFromError(e) {
|
|
1486
1571
|
return { error: e };
|
|
@@ -1493,62 +1578,51 @@ var Wn = (e) => {
|
|
|
1493
1578
|
};
|
|
1494
1579
|
render() {
|
|
1495
1580
|
let { children: e, fallback: t, label: n } = this.props, { error: r } = this.state;
|
|
1496
|
-
return r ? t || /* @__PURE__ */ Q(
|
|
1581
|
+
return r ? t || /* @__PURE__ */ Q(pr, {
|
|
1497
1582
|
error: r,
|
|
1498
1583
|
label: n,
|
|
1499
1584
|
onReset: this.handleReset
|
|
1500
1585
|
}) : e;
|
|
1501
1586
|
}
|
|
1502
|
-
},
|
|
1503
|
-
let t = Z(
|
|
1587
|
+
}, pr = (e) => {
|
|
1588
|
+
let t = Z(8), { error: n, label: r, onReset: i } = e, a = r ?? "Something went wrong", o;
|
|
1504
1589
|
t[0] === a ? o = t[1] : (o = /* @__PURE__ */ Q(X, {
|
|
1505
1590
|
textStyle: "paragraph/M/medium",
|
|
1506
1591
|
children: a
|
|
1507
1592
|
}), t[0] = a, t[1] = o);
|
|
1508
|
-
let s
|
|
1509
|
-
t[2] ===
|
|
1510
|
-
textStyle: "paragraph/S/regular",
|
|
1511
|
-
children: s
|
|
1512
|
-
}), t[2] = s, t[3] = l);
|
|
1513
|
-
let u;
|
|
1514
|
-
t[4] === i ? u = t[5] : (u = i ? /* @__PURE__ */ Q(be, {
|
|
1515
|
-
size: "sm",
|
|
1516
|
-
variant: "primary",
|
|
1593
|
+
let s;
|
|
1594
|
+
t[2] === i ? s = t[3] : (s = i ? /* @__PURE__ */ Q(xe, {
|
|
1517
1595
|
onClick: i,
|
|
1518
1596
|
children: "Try again"
|
|
1519
|
-
}) :
|
|
1520
|
-
let
|
|
1521
|
-
t[
|
|
1522
|
-
gap: "sm",
|
|
1523
|
-
children: [l, u]
|
|
1524
|
-
}), t[6] = l, t[7] = u, t[8] = d) : d = t[8];
|
|
1525
|
-
let f;
|
|
1526
|
-
return t[9] !== o || t[10] !== d ? (f = /* @__PURE__ */ Q(or, {
|
|
1597
|
+
}) : void 0, t[2] = i, t[3] = s);
|
|
1598
|
+
let l = n.message || "An unexpected error occurred while rendering this section.", u;
|
|
1599
|
+
return t[4] !== o || t[5] !== s || t[6] !== l ? (u = /* @__PURE__ */ Q(lr, {
|
|
1527
1600
|
height: "100%",
|
|
1528
1601
|
width: "100%",
|
|
1529
|
-
children: /* @__PURE__ */ Q(
|
|
1602
|
+
children: /* @__PURE__ */ Q(ve, { children: /* @__PURE__ */ Q(c, {
|
|
1530
1603
|
status: "error",
|
|
1531
1604
|
title: o,
|
|
1532
|
-
|
|
1605
|
+
endElement: s,
|
|
1606
|
+
children: l
|
|
1533
1607
|
}) })
|
|
1534
|
-
}), t[
|
|
1535
|
-
},
|
|
1608
|
+
}), t[4] = o, t[5] = s, t[6] = l, t[7] = u) : u = t[7], u;
|
|
1609
|
+
}, mr = (e) => !!e && e !== "circle", hr = (e) => {
|
|
1536
1610
|
let t = Z(18), n, r, i, a, o;
|
|
1537
1611
|
t[0] === e ? (n = t[1], r = t[2], i = t[3], a = t[4], o = t[5]) : ({color: n, icon: r, iconOptions: i, showIcon: o, ...a} = e, t[0] = e, t[1] = n, t[2] = r, t[3] = i, t[4] = a, t[5] = o);
|
|
1538
1612
|
let s = o === void 0 || o, c;
|
|
1539
|
-
t[6] !== r || t[7] !== i ? (c =
|
|
1613
|
+
t[6] !== r || t[7] !== i ? (c = re(r, i), t[6] = r, t[7] = i, t[8] = c) : c = t[8];
|
|
1540
1614
|
let l = c, u = `${n}.500/15`, d;
|
|
1541
|
-
t[9] !== l || t[10] !== n || t[11] !== r || t[12] !== s ? (d = s &&
|
|
1615
|
+
t[9] !== l || t[10] !== n || t[11] !== r || t[12] !== s ? (d = s && mr(r) ? /* @__PURE__ */ Q(Y, {
|
|
1542
1616
|
as: l,
|
|
1543
1617
|
boxSize: "icon-xs",
|
|
1544
1618
|
color: `${n}.500`
|
|
1545
|
-
}) : /* @__PURE__ */ Q(
|
|
1619
|
+
}) : /* @__PURE__ */ Q(G, {
|
|
1546
1620
|
boxSize: "tag-swatch-dot",
|
|
1547
1621
|
borderRadius: "full",
|
|
1548
1622
|
bg: `${n}.500`
|
|
1549
1623
|
}), t[9] = l, t[10] = n, t[11] = r, t[12] = s, t[13] = d) : d = t[13];
|
|
1550
1624
|
let f;
|
|
1551
|
-
return t[14] !== a || t[15] !== u || t[16] !== d ? (f = /* @__PURE__ */ Q(
|
|
1625
|
+
return t[14] !== a || t[15] !== u || t[16] !== d ? (f = /* @__PURE__ */ Q(Se, {
|
|
1552
1626
|
boxSize: "tag-swatch",
|
|
1553
1627
|
flexShrink: 0,
|
|
1554
1628
|
borderRadius: "compact",
|
|
@@ -1556,7 +1630,7 @@ var Wn = (e) => {
|
|
|
1556
1630
|
...a,
|
|
1557
1631
|
children: d
|
|
1558
1632
|
}), t[14] = a, t[15] = u, t[16] = d, t[17] = f) : f = t[17], f;
|
|
1559
|
-
},
|
|
1633
|
+
}, gr = He("button", { base: {
|
|
1560
1634
|
display: "inline-flex",
|
|
1561
1635
|
borderRadius: "compact",
|
|
1562
1636
|
cursor: "pointer",
|
|
@@ -1565,7 +1639,7 @@ var Wn = (e) => {
|
|
|
1565
1639
|
cursor: "not-allowed",
|
|
1566
1640
|
opacity: .5
|
|
1567
1641
|
}
|
|
1568
|
-
} }),
|
|
1642
|
+
} }), _r = He("button", { base: {
|
|
1569
1643
|
boxSize: "tag-color-dot",
|
|
1570
1644
|
borderRadius: "full",
|
|
1571
1645
|
cursor: "pointer",
|
|
@@ -1574,7 +1648,7 @@ var Wn = (e) => {
|
|
|
1574
1648
|
outlineOffset: "3xs",
|
|
1575
1649
|
outlineColor: "transparent",
|
|
1576
1650
|
_selected: { outlineColor: "fg" }
|
|
1577
|
-
} }),
|
|
1651
|
+
} }), vr = He("button", { base: {
|
|
1578
1652
|
display: "inline-flex",
|
|
1579
1653
|
alignItems: "center",
|
|
1580
1654
|
justifyContent: "center",
|
|
@@ -1583,11 +1657,11 @@ var Wn = (e) => {
|
|
|
1583
1657
|
color: "fg.muted",
|
|
1584
1658
|
cursor: "pointer",
|
|
1585
1659
|
_hover: { bg: "bg.hover" }
|
|
1586
|
-
} }),
|
|
1587
|
-
let t = Z(39), { color: n, colorOptions: r, icon: i, iconOptions: a, onColorChange: o, onIconChange: s, disabled: c, showIcons: l, colorLabel: u, iconLabel: d, "aria-label": f } = e, p = r === void 0 ?
|
|
1660
|
+
} }), yr = (e) => {
|
|
1661
|
+
let t = Z(39), { color: n, colorOptions: r, icon: i, iconOptions: a, onColorChange: o, onIconChange: s, disabled: c, showIcons: l, colorLabel: u, iconLabel: d, "aria-label": f } = e, p = r === void 0 ? te : r, m = a === void 0 ? ne : a, h = l === void 0 || l, g = u === void 0 ? "Color" : u, _ = d === void 0 ? "Icon" : d, v = f === void 0 ? "Pick color and icon" : f, y = i === "circle" ? null : i ?? null, b;
|
|
1588
1662
|
t[0] === Symbol.for("react.memo_cache_sentinel") ? (b = { placement: "bottom-start" }, t[0] = b) : b = t[0];
|
|
1589
1663
|
let x;
|
|
1590
|
-
t[1] !== n || t[2] !== i || t[3] !== m || t[4] !== h ? (x = /* @__PURE__ */ Q(
|
|
1664
|
+
t[1] !== n || t[2] !== i || t[3] !== m || t[4] !== h ? (x = /* @__PURE__ */ Q(hr, {
|
|
1591
1665
|
color: n,
|
|
1592
1666
|
icon: i,
|
|
1593
1667
|
iconOptions: m,
|
|
@@ -1596,7 +1670,7 @@ var Wn = (e) => {
|
|
|
1596
1670
|
let S;
|
|
1597
1671
|
t[6] !== v || t[7] !== c || t[8] !== x ? (S = /* @__PURE__ */ Q(Ne.Trigger, {
|
|
1598
1672
|
asChild: !0,
|
|
1599
|
-
children: /* @__PURE__ */ Q(
|
|
1673
|
+
children: /* @__PURE__ */ Q(gr, {
|
|
1600
1674
|
type: "button",
|
|
1601
1675
|
disabled: c,
|
|
1602
1676
|
"aria-label": v,
|
|
@@ -1612,7 +1686,7 @@ var Wn = (e) => {
|
|
|
1612
1686
|
let T = `repeat(${h ? 10 : 5}, 1fr)`, E;
|
|
1613
1687
|
if (t[12] !== n || t[13] !== p || t[14] !== o) {
|
|
1614
1688
|
let e;
|
|
1615
|
-
t[16] !== n || t[17] !== o ? (e = (e) => /* @__PURE__ */ Q(
|
|
1689
|
+
t[16] !== n || t[17] !== o ? (e = (e) => /* @__PURE__ */ Q(_r, {
|
|
1616
1690
|
type: "button",
|
|
1617
1691
|
bg: `${e}.500`,
|
|
1618
1692
|
"aria-label": e,
|
|
@@ -1630,7 +1704,7 @@ var Wn = (e) => {
|
|
|
1630
1704
|
}), t[19] = T, t[20] = E, t[21] = D) : D = t[21];
|
|
1631
1705
|
let O;
|
|
1632
1706
|
t[22] !== n || t[23] !== _ || t[24] !== m || t[25] !== s || t[26] !== y || t[27] !== h ? (O = h ? /* @__PURE__ */ $(Ye, { children: [
|
|
1633
|
-
/* @__PURE__ */ Q(
|
|
1707
|
+
/* @__PURE__ */ Q(G, { borderTop: "subtle" }),
|
|
1634
1708
|
/* @__PURE__ */ Q(X, {
|
|
1635
1709
|
textStyle: "label/S/medium",
|
|
1636
1710
|
color: "fg.muted",
|
|
@@ -1642,7 +1716,7 @@ var Wn = (e) => {
|
|
|
1642
1716
|
justifyItems: "center",
|
|
1643
1717
|
children: m.map((e) => {
|
|
1644
1718
|
let t = e.value === y;
|
|
1645
|
-
return /* @__PURE__ */ Q(
|
|
1719
|
+
return /* @__PURE__ */ Q(vr, {
|
|
1646
1720
|
type: "button",
|
|
1647
1721
|
color: t ? `${n}.500` : void 0,
|
|
1648
1722
|
bg: t ? `${n}.500/15` : void 0,
|
|
@@ -1679,11 +1753,11 @@ var Wn = (e) => {
|
|
|
1679
1753
|
positioning: b,
|
|
1680
1754
|
children: [S, A]
|
|
1681
1755
|
}), t[36] = A, t[37] = S, t[38] = j) : j = t[38], j;
|
|
1682
|
-
},
|
|
1756
|
+
}, br = (e) => {
|
|
1683
1757
|
let t = Z(6), n, r;
|
|
1684
1758
|
t[0] === e ? (n = t[1], r = t[2]) : ({children: n, ...r} = e, t[0] = e, t[1] = n, t[2] = r);
|
|
1685
1759
|
let i;
|
|
1686
|
-
return t[3] !== n || t[4] !== r ? (i = /* @__PURE__ */ Q(
|
|
1760
|
+
return t[3] !== n || t[4] !== r ? (i = /* @__PURE__ */ Q(G, {
|
|
1687
1761
|
borderWidth: "1px",
|
|
1688
1762
|
borderColor: "border.subtle",
|
|
1689
1763
|
borderRadius: "xs",
|
|
@@ -1691,16 +1765,16 @@ var Wn = (e) => {
|
|
|
1691
1765
|
...r,
|
|
1692
1766
|
children: n
|
|
1693
1767
|
}), t[3] = n, t[4] = r, t[5] = i) : i = t[5], i;
|
|
1694
|
-
},
|
|
1768
|
+
}, xr = (e) => {
|
|
1695
1769
|
let t = Z(6), n, r;
|
|
1696
1770
|
t[0] === e ? (n = t[1], r = t[2]) : ({children: n, ...r} = e, t[0] = e, t[1] = n, t[2] = r);
|
|
1697
1771
|
let i;
|
|
1698
|
-
return t[3] !== n || t[4] !== r ? (i = /* @__PURE__ */ Q(
|
|
1772
|
+
return t[3] !== n || t[4] !== r ? (i = /* @__PURE__ */ Q(G, {
|
|
1699
1773
|
p: "md",
|
|
1700
1774
|
...r,
|
|
1701
1775
|
children: n
|
|
1702
1776
|
}), t[3] = n, t[4] = r, t[5] = i) : i = t[5], i;
|
|
1703
|
-
},
|
|
1777
|
+
}, Sr = (e) => {
|
|
1704
1778
|
let t = Z(30), { icon: n, name: r, description: i, id: a, version: o, category: s, active: c, actionLabel: l } = e, u = c !== void 0 && c, d;
|
|
1705
1779
|
t[0] === n ? d = t[1] : (d = /* @__PURE__ */ Q(Y, {
|
|
1706
1780
|
boxSize: "1em",
|
|
@@ -1716,19 +1790,19 @@ var Wn = (e) => {
|
|
|
1716
1790
|
children: r
|
|
1717
1791
|
}), t[2] = r, t[3] = f);
|
|
1718
1792
|
let p;
|
|
1719
|
-
t[4] === a ? p = t[5] : (p = /* @__PURE__ */ Q(
|
|
1793
|
+
t[4] === a ? p = t[5] : (p = /* @__PURE__ */ Q(ye, {
|
|
1720
1794
|
size: "sm",
|
|
1721
1795
|
variant: "outline",
|
|
1722
1796
|
children: a
|
|
1723
1797
|
}), t[4] = a, t[5] = p);
|
|
1724
1798
|
let m;
|
|
1725
|
-
t[6] === o ? m = t[7] : (m = o && /* @__PURE__ */ $(
|
|
1799
|
+
t[6] === o ? m = t[7] : (m = o && /* @__PURE__ */ $(ye, {
|
|
1726
1800
|
size: "sm",
|
|
1727
1801
|
variant: "outline",
|
|
1728
1802
|
children: ["v", o]
|
|
1729
1803
|
}), t[6] = o, t[7] = m);
|
|
1730
1804
|
let h;
|
|
1731
|
-
t[8] === s ? h = t[9] : (h = s && /* @__PURE__ */ Q(
|
|
1805
|
+
t[8] === s ? h = t[9] : (h = s && /* @__PURE__ */ Q(ye, {
|
|
1732
1806
|
size: "sm",
|
|
1733
1807
|
variant: "outline",
|
|
1734
1808
|
children: s
|
|
@@ -1750,7 +1824,7 @@ var Wn = (e) => {
|
|
|
1750
1824
|
children: i
|
|
1751
1825
|
}), t[15] = i, t[16] = _);
|
|
1752
1826
|
let v;
|
|
1753
|
-
t[17] !== g || t[18] !== _ ? (v = /* @__PURE__ */ Q(
|
|
1827
|
+
t[17] !== g || t[18] !== _ ? (v = /* @__PURE__ */ Q(G, {
|
|
1754
1828
|
flex: "1",
|
|
1755
1829
|
minW: "0",
|
|
1756
1830
|
children: /* @__PURE__ */ $(Re, {
|
|
@@ -1764,7 +1838,7 @@ var Wn = (e) => {
|
|
|
1764
1838
|
children: /* @__PURE__ */ Q(lt, {})
|
|
1765
1839
|
}), t[20] = u, t[21] = y);
|
|
1766
1840
|
let b = l ?? (u ? "Active" : "Connect"), x;
|
|
1767
|
-
t[22] !== u || t[23] !== b || t[24] !== y ? (x = /* @__PURE__ */ $(
|
|
1841
|
+
t[22] !== u || t[23] !== b || t[24] !== y ? (x = /* @__PURE__ */ $(xe, {
|
|
1768
1842
|
type: "button",
|
|
1769
1843
|
disabled: u,
|
|
1770
1844
|
size: "sm",
|
|
@@ -1775,7 +1849,7 @@ var Wn = (e) => {
|
|
|
1775
1849
|
children: [y, b]
|
|
1776
1850
|
}), t[22] = u, t[23] = b, t[24] = y, t[25] = x) : x = t[25];
|
|
1777
1851
|
let S;
|
|
1778
|
-
return t[26] !== d || t[27] !== x || t[28] !== v ? (S = /* @__PURE__ */ Q(
|
|
1852
|
+
return t[26] !== d || t[27] !== x || t[28] !== v ? (S = /* @__PURE__ */ Q(br, { children: /* @__PURE__ */ Q(xr, { children: /* @__PURE__ */ $(J, {
|
|
1779
1853
|
gap: "4",
|
|
1780
1854
|
alignItems: "flex-start",
|
|
1781
1855
|
children: [
|
|
@@ -1784,7 +1858,7 @@ var Wn = (e) => {
|
|
|
1784
1858
|
x
|
|
1785
1859
|
]
|
|
1786
1860
|
}) }) }), t[26] = d, t[27] = x, t[28] = v, t[29] = S) : S = t[29], S;
|
|
1787
|
-
},
|
|
1861
|
+
}, Cr = Ke({
|
|
1788
1862
|
className: "ps-segmented-control",
|
|
1789
1863
|
slots: ["root", "item"],
|
|
1790
1864
|
base: {
|
|
@@ -1840,7 +1914,7 @@ var Wn = (e) => {
|
|
|
1840
1914
|
}
|
|
1841
1915
|
} },
|
|
1842
1916
|
defaultVariants: { size: "sm" }
|
|
1843
|
-
}), { withProvider:
|
|
1917
|
+
}), { withProvider: wr, withContext: Tr } = Ue({ recipe: Cr }), Er = wr("div", "root"), Dr = Tr("button", "item"), Or = (e) => {
|
|
1844
1918
|
let t = Z(20), n, r, i, a, o, s;
|
|
1845
1919
|
t[0] === e ? (n = t[1], r = t[2], i = t[3], a = t[4], o = t[5], s = t[6]) : ({options: a, value: s, onValueChange: i, disabled: r, "aria-label": n, ...o} = e, t[0] = e, t[1] = n, t[2] = r, t[3] = i, t[4] = a, t[5] = o, t[6] = s);
|
|
1846
1920
|
let c;
|
|
@@ -1848,7 +1922,7 @@ var Wn = (e) => {
|
|
|
1848
1922
|
let e;
|
|
1849
1923
|
t[12] !== r || t[13] !== i || t[14] !== s ? (e = (e) => {
|
|
1850
1924
|
let t = e.value === s;
|
|
1851
|
-
return /* @__PURE__ */ Q(
|
|
1925
|
+
return /* @__PURE__ */ Q(Dr, {
|
|
1852
1926
|
type: "button",
|
|
1853
1927
|
"aria-pressed": t,
|
|
1854
1928
|
"data-selected": t ? "" : void 0,
|
|
@@ -1859,25 +1933,31 @@ var Wn = (e) => {
|
|
|
1859
1933
|
}, t[12] = r, t[13] = i, t[14] = s, t[15] = e) : e = t[15], c = a.map(e), t[7] = r, t[8] = i, t[9] = a, t[10] = s, t[11] = c;
|
|
1860
1934
|
} else c = t[11];
|
|
1861
1935
|
let l;
|
|
1862
|
-
return t[16] !== n || t[17] !== o || t[18] !== c ? (l = /* @__PURE__ */ Q(
|
|
1936
|
+
return t[16] !== n || t[17] !== o || t[18] !== c ? (l = /* @__PURE__ */ Q(Er, {
|
|
1863
1937
|
role: "group",
|
|
1864
1938
|
"aria-label": n,
|
|
1865
1939
|
...o,
|
|
1866
1940
|
children: c
|
|
1867
1941
|
}), t[16] = n, t[17] = o, t[18] = c, t[19] = l) : l = t[19], l;
|
|
1868
|
-
},
|
|
1942
|
+
}, kr = We({
|
|
1869
1943
|
placement: "top",
|
|
1870
1944
|
pauseOnPageIdle: !0,
|
|
1871
|
-
duration: 1e4
|
|
1872
|
-
|
|
1945
|
+
duration: 1e4,
|
|
1946
|
+
offsets: {
|
|
1947
|
+
top: "var(--pstdio-toast-top-offset, var(--chakra-spacing-md))",
|
|
1948
|
+
bottom: "var(--chakra-spacing-md)",
|
|
1949
|
+
left: "var(--chakra-spacing-md)",
|
|
1950
|
+
right: "var(--chakra-spacing-md)"
|
|
1951
|
+
}
|
|
1952
|
+
}), Ar = () => {
|
|
1873
1953
|
let e = Z(1), t;
|
|
1874
1954
|
return e[0] === Symbol.for("react.memo_cache_sentinel") ? (t = /* @__PURE__ */ Q(Pe, { children: /* @__PURE__ */ Q(Ve, {
|
|
1875
|
-
toaster:
|
|
1955
|
+
toaster: kr,
|
|
1876
1956
|
insetInline: { mdDown: "4" },
|
|
1877
|
-
children:
|
|
1957
|
+
children: jr
|
|
1878
1958
|
}) }), e[0] = t) : t = e[0], t;
|
|
1879
1959
|
};
|
|
1880
|
-
function
|
|
1960
|
+
function jr(e) {
|
|
1881
1961
|
return /* @__PURE__ */ $(Be.Root, {
|
|
1882
1962
|
width: { md: "sm" },
|
|
1883
1963
|
alignItems: "start",
|
|
@@ -1917,22 +1997,22 @@ function Or(e) {
|
|
|
1917
1997
|
}
|
|
1918
1998
|
//#endregion
|
|
1919
1999
|
//#region src/components/sidenav/sidenav.store.ts
|
|
1920
|
-
var
|
|
2000
|
+
var Mr = {
|
|
1921
2001
|
open: !0,
|
|
1922
2002
|
expandedSections: [],
|
|
1923
2003
|
expandedNodes: [],
|
|
1924
2004
|
width: null
|
|
1925
|
-
},
|
|
2005
|
+
}, Nr = "pstdio/ui/sidenav", Pr = (e) => `${Nr}/${e}`, Fr = (e, t) => e.includes(t) ? e.filter((e) => e !== t) : [...e, t], Ir = (e, t, n) => n ? e.includes(t) ? e : [...e, t] : e.filter((e) => e !== t), Lr = (e) => ({
|
|
1926
2006
|
open: e.open,
|
|
1927
2007
|
expandedSections: e.expandedSections,
|
|
1928
2008
|
expandedNodes: e.expandedNodes,
|
|
1929
2009
|
width: e.width
|
|
1930
|
-
}),
|
|
2010
|
+
}), Rr = (e) => {
|
|
1931
2011
|
let { storageKey: t, initialState: n } = e, r = {
|
|
1932
|
-
...
|
|
2012
|
+
...Mr,
|
|
1933
2013
|
...n
|
|
1934
2014
|
};
|
|
1935
|
-
return
|
|
2015
|
+
return Ht()(Vt((e) => ({
|
|
1936
2016
|
...r,
|
|
1937
2017
|
openSidenav: () => e((e) => ({
|
|
1938
2018
|
...e,
|
|
@@ -1948,59 +2028,59 @@ var kr = {
|
|
|
1948
2028
|
})),
|
|
1949
2029
|
toggleSection: (t) => e((e) => ({
|
|
1950
2030
|
...e,
|
|
1951
|
-
expandedSections:
|
|
2031
|
+
expandedSections: Fr(e.expandedSections, t)
|
|
1952
2032
|
})),
|
|
1953
2033
|
toggleNode: (t) => e((e) => ({
|
|
1954
2034
|
...e,
|
|
1955
|
-
expandedNodes:
|
|
2035
|
+
expandedNodes: Fr(e.expandedNodes, t)
|
|
1956
2036
|
})),
|
|
1957
2037
|
setSectionExpanded: (t, n) => e((e) => ({
|
|
1958
2038
|
...e,
|
|
1959
|
-
expandedSections:
|
|
2039
|
+
expandedSections: Ir(e.expandedSections, t, n)
|
|
1960
2040
|
})),
|
|
1961
2041
|
setNodeExpanded: (t, n) => e((e) => ({
|
|
1962
2042
|
...e,
|
|
1963
|
-
expandedNodes:
|
|
2043
|
+
expandedNodes: Ir(e.expandedNodes, t, n)
|
|
1964
2044
|
})),
|
|
1965
2045
|
setWidth: (t) => e((e) => ({
|
|
1966
2046
|
...e,
|
|
1967
2047
|
width: t
|
|
1968
2048
|
})),
|
|
1969
|
-
reset: () => e(
|
|
2049
|
+
reset: () => e(Mr)
|
|
1970
2050
|
}), {
|
|
1971
|
-
name:
|
|
1972
|
-
storage:
|
|
1973
|
-
partialize:
|
|
2051
|
+
name: Pr(t),
|
|
2052
|
+
storage: Bt(V),
|
|
2053
|
+
partialize: Lr
|
|
1974
2054
|
}));
|
|
1975
|
-
},
|
|
1976
|
-
let n =
|
|
2055
|
+
}, zr = /* @__PURE__ */ new Map(), Br = (e, t) => {
|
|
2056
|
+
let n = zr.get(e);
|
|
1977
2057
|
if (n) return n;
|
|
1978
|
-
let r =
|
|
2058
|
+
let r = Rr({
|
|
1979
2059
|
storageKey: e,
|
|
1980
2060
|
initialState: t
|
|
1981
2061
|
});
|
|
1982
|
-
return
|
|
1983
|
-
},
|
|
2062
|
+
return zr.set(e, r), r;
|
|
2063
|
+
}, Vr = (e, t, n) => {
|
|
1984
2064
|
let r = Z(3), i;
|
|
1985
|
-
return r[0] !== n || r[1] !== e ? (i =
|
|
1986
|
-
},
|
|
2065
|
+
return r[0] !== n || r[1] !== e ? (i = Br(e, n), r[0] = n, r[1] = e, r[2] = i) : i = r[2], zt(i, t);
|
|
2066
|
+
}, Hr = (e) => {
|
|
1987
2067
|
let t = Z(2), { children: n } = e;
|
|
1988
2068
|
if (!n) return null;
|
|
1989
2069
|
let r;
|
|
1990
|
-
return t[0] === n ? r = t[1] : (r = /* @__PURE__ */ Q(
|
|
2070
|
+
return t[0] === n ? r = t[1] : (r = /* @__PURE__ */ Q(G, {
|
|
1991
2071
|
bg: "bg",
|
|
1992
2072
|
position: "sticky",
|
|
1993
2073
|
bottom: "0",
|
|
1994
2074
|
overflow: "hidden",
|
|
1995
2075
|
children: n
|
|
1996
2076
|
}), t[0] = n, t[1] = r), r;
|
|
1997
|
-
},
|
|
2077
|
+
}, Ur = (e) => {
|
|
1998
2078
|
let t = Z(2), { children: n } = e, r;
|
|
1999
2079
|
return t[0] === n ? r = t[1] : (r = /* @__PURE__ */ Q(J, {
|
|
2000
2080
|
"data-testid": "sidenav-header",
|
|
2001
2081
|
justify: "space-between",
|
|
2002
2082
|
align: "center",
|
|
2003
|
-
minH:
|
|
2083
|
+
minH: On,
|
|
2004
2084
|
bg: "bg",
|
|
2005
2085
|
position: "sticky",
|
|
2006
2086
|
top: "0",
|
|
@@ -2012,54 +2092,54 @@ var kr = {
|
|
|
2012
2092
|
children: n
|
|
2013
2093
|
})
|
|
2014
2094
|
}), t[0] = n, t[1] = r), r;
|
|
2015
|
-
},
|
|
2095
|
+
}, Wr = 240, Gr = 200, Kr = 480, qr = (e, t, n) => Math.min(Math.max(e, t), n), Jr = (e, t = Wr) => {
|
|
2016
2096
|
if (typeof e == "number") return e;
|
|
2017
2097
|
if (typeof e == "string") {
|
|
2018
2098
|
let t = parseInt(e, 10);
|
|
2019
2099
|
if (!Number.isNaN(t)) return t;
|
|
2020
2100
|
}
|
|
2021
2101
|
return t;
|
|
2022
|
-
},
|
|
2102
|
+
}, Yr = (e) => {
|
|
2023
2103
|
let t = Z(43), { storageKey: n, sections: r, activeNodeId: i, contextActions: a, header: o, footer: s, width: c, closable: l, emptyLabel: d, defaultExpandedSections: p, linkComponent: m, onNavigate: h, onOpenChange: g, resizable: _, defaultWidth: v, minWidth: y, maxWidth: x, virtualize: S } = e, C;
|
|
2024
2104
|
t[0] === a ? C = t[1] : (C = a === void 0 ? [] : a, t[0] = a, t[1] = C);
|
|
2025
|
-
let w = C, T = l === void 0 || l, E = d === void 0 ? "No items available." : d, D = _ === void 0 || _, O = y === void 0 ?
|
|
2026
|
-
t[2] !== v || t[3] !== c ? (M =
|
|
2105
|
+
let w = C, T = l === void 0 || l, E = d === void 0 ? "No items available." : d, D = _ === void 0 || _, O = y === void 0 ? Gr : y, k = x === void 0 ? Kr : x, A = S !== void 0 && S, j = rt(null), M;
|
|
2106
|
+
t[2] !== v || t[3] !== c ? (M = Jr(c, v), t[2] = v, t[3] = c, t[4] = M) : M = t[4];
|
|
2027
2107
|
let N = M, P;
|
|
2028
2108
|
t[5] === p ? P = t[6] : (P = p ? { expandedSections: p } : {}, t[5] = p, t[6] = P);
|
|
2029
|
-
let
|
|
2030
|
-
t[7] !== N || t[8] !== P ? (
|
|
2109
|
+
let ee;
|
|
2110
|
+
t[7] !== N || t[8] !== P ? (ee = {
|
|
2031
2111
|
...P,
|
|
2032
2112
|
width: N
|
|
2033
|
-
}, t[7] = N, t[8] = P, t[9] =
|
|
2034
|
-
let
|
|
2035
|
-
t[10] !== g || t[11] !==
|
|
2036
|
-
g?.(
|
|
2037
|
-
},
|
|
2038
|
-
let
|
|
2039
|
-
t[14] !== k || t[15] !== O || t[16] !==
|
|
2040
|
-
let
|
|
2041
|
-
if (!
|
|
2042
|
-
let
|
|
2043
|
-
t[18] === o ?
|
|
2044
|
-
let
|
|
2045
|
-
t[20] === Symbol.for("react.memo_cache_sentinel") ? (
|
|
2113
|
+
}, t[7] = N, t[8] = P, t[9] = ee) : ee = t[9];
|
|
2114
|
+
let F = ee, I = Vr(n, Xr, F), L = Vr(n, Zr, F), R = Vr(n, Qr, F), z = Vr(n, $r, F), B = Vr(n, ei, F), te = Vr(n, ti, F), ne, re;
|
|
2115
|
+
t[10] !== g || t[11] !== I ? (ne = () => {
|
|
2116
|
+
g?.(I);
|
|
2117
|
+
}, re = [g, I], t[10] = g, t[11] = I, t[12] = ne, t[13] = re) : (ne = t[12], re = t[13]), nt(ne, re);
|
|
2118
|
+
let ie = L ?? N, ae;
|
|
2119
|
+
t[14] !== k || t[15] !== O || t[16] !== ie ? (ae = qr(ie, O, k), t[14] = k, t[15] = O, t[16] = ie, t[17] = ae) : ae = t[17];
|
|
2120
|
+
let V = ae;
|
|
2121
|
+
if (!I && T) return null;
|
|
2122
|
+
let H = D ? `${V}px` : c ?? `${N}px`, U;
|
|
2123
|
+
t[18] === o ? U = t[19] : (U = /* @__PURE__ */ Q(Ur, { children: o }), t[18] = o, t[19] = U);
|
|
2124
|
+
let oe, W;
|
|
2125
|
+
t[20] === Symbol.for("react.memo_cache_sentinel") ? (oe = {
|
|
2046
2126
|
display: "block",
|
|
2047
2127
|
style: { overflowX: "hidden" }
|
|
2048
|
-
},
|
|
2128
|
+
}, W = { style: {
|
|
2049
2129
|
minWidth: "100%",
|
|
2050
2130
|
width: "100%",
|
|
2051
2131
|
minHeight: "100%",
|
|
2052
2132
|
display: "flex",
|
|
2053
2133
|
flexDirection: "column"
|
|
2054
|
-
} }, t[20] =
|
|
2055
|
-
let
|
|
2056
|
-
t[22] !== i || t[23] !== E || t[24] !==
|
|
2134
|
+
} }, t[20] = oe, t[21] = W) : (oe = t[20], W = t[21]);
|
|
2135
|
+
let se;
|
|
2136
|
+
t[22] !== i || t[23] !== E || t[24] !== z || t[25] !== R || t[26] !== m || t[27] !== h || t[28] !== r || t[29] !== te || t[30] !== B || t[31] !== A ? (se = /* @__PURE__ */ Q(u, {
|
|
2057
2137
|
flex: "1",
|
|
2058
2138
|
mt: "lg",
|
|
2059
2139
|
viewportRef: j,
|
|
2060
|
-
viewportProps:
|
|
2061
|
-
contentProps:
|
|
2062
|
-
children: /* @__PURE__ */ Q(
|
|
2140
|
+
viewportProps: oe,
|
|
2141
|
+
contentProps: W,
|
|
2142
|
+
children: /* @__PURE__ */ Q(G, {
|
|
2063
2143
|
w: "full",
|
|
2064
2144
|
minW: "0",
|
|
2065
2145
|
flex: "1 0 auto",
|
|
@@ -2072,71 +2152,71 @@ var kr = {
|
|
|
2072
2152
|
children: E
|
|
2073
2153
|
}) : /* @__PURE__ */ Q(b, {
|
|
2074
2154
|
sections: r,
|
|
2075
|
-
expandedSectionIds:
|
|
2076
|
-
expandedNodeIds:
|
|
2155
|
+
expandedSectionIds: R,
|
|
2156
|
+
expandedNodeIds: z,
|
|
2077
2157
|
activeNodeId: i,
|
|
2078
2158
|
rowVariant: "compact",
|
|
2079
2159
|
sectionGap: "md",
|
|
2080
2160
|
nodeGap: "1px",
|
|
2081
2161
|
linkComponent: m,
|
|
2082
2162
|
onNavigate: h,
|
|
2083
|
-
onToggleSection:
|
|
2084
|
-
onToggleNode:
|
|
2163
|
+
onToggleSection: B,
|
|
2164
|
+
onToggleNode: te,
|
|
2085
2165
|
virtualize: A,
|
|
2086
2166
|
scrollRef: j
|
|
2087
2167
|
})
|
|
2088
2168
|
})
|
|
2089
|
-
}), t[22] = i, t[23] = E, t[24] =
|
|
2090
|
-
let se;
|
|
2091
|
-
t[33] === s ? se = t[34] : (se = /* @__PURE__ */ Q(zr, { children: s }), t[33] = s, t[34] = se);
|
|
2169
|
+
}), t[22] = i, t[23] = E, t[24] = z, t[25] = R, t[26] = m, t[27] = h, t[28] = r, t[29] = te, t[30] = B, t[31] = A, t[32] = se) : se = t[32];
|
|
2092
2170
|
let ce;
|
|
2093
|
-
t[
|
|
2171
|
+
t[33] === s ? ce = t[34] : (ce = /* @__PURE__ */ Q(Hr, { children: s }), t[33] = s, t[34] = ce);
|
|
2172
|
+
let le;
|
|
2173
|
+
t[35] !== U || t[36] !== se || t[37] !== ce || t[38] !== H ? (le = /* @__PURE__ */ $(q, {
|
|
2094
2174
|
as: "aside",
|
|
2095
2175
|
"data-testid": "sidenav",
|
|
2096
2176
|
direction: "column",
|
|
2097
2177
|
position: "relative",
|
|
2098
2178
|
h: "100%",
|
|
2099
|
-
w:
|
|
2100
|
-
minW:
|
|
2101
|
-
maxW:
|
|
2179
|
+
w: H,
|
|
2180
|
+
minW: H,
|
|
2181
|
+
maxW: H,
|
|
2102
2182
|
flexShrink: 0,
|
|
2103
2183
|
borderRightWidth: "1px",
|
|
2104
2184
|
borderRightColor: "border.subtle",
|
|
2105
2185
|
bg: "bg",
|
|
2106
2186
|
children: [
|
|
2107
|
-
|
|
2108
|
-
|
|
2109
|
-
|
|
2187
|
+
U,
|
|
2188
|
+
se,
|
|
2189
|
+
ce
|
|
2110
2190
|
]
|
|
2111
|
-
}), t[35] =
|
|
2112
|
-
let
|
|
2113
|
-
return t[40] !==
|
|
2191
|
+
}), t[35] = U, t[36] = se, t[37] = ce, t[38] = H, t[39] = le) : le = t[39];
|
|
2192
|
+
let ue = le, de;
|
|
2193
|
+
return t[40] !== ue || t[41] !== w ? (de = /* @__PURE__ */ Q(f, {
|
|
2114
2194
|
actions: w,
|
|
2115
2195
|
closeOnSelect: !1,
|
|
2116
|
-
children:
|
|
2117
|
-
}), t[40] =
|
|
2196
|
+
children: ue
|
|
2197
|
+
}), t[40] = ue, t[41] = w, t[42] = de) : de = t[42], de;
|
|
2118
2198
|
};
|
|
2119
|
-
function
|
|
2199
|
+
function Xr(e) {
|
|
2120
2200
|
return e.open;
|
|
2121
2201
|
}
|
|
2122
|
-
function
|
|
2202
|
+
function Zr(e) {
|
|
2123
2203
|
return e.width;
|
|
2124
2204
|
}
|
|
2125
|
-
function
|
|
2205
|
+
function Qr(e) {
|
|
2126
2206
|
return e.expandedSections;
|
|
2127
2207
|
}
|
|
2128
|
-
function
|
|
2208
|
+
function $r(e) {
|
|
2129
2209
|
return e.expandedNodes;
|
|
2130
2210
|
}
|
|
2131
|
-
function
|
|
2211
|
+
function ei(e) {
|
|
2132
2212
|
return e.toggleSection;
|
|
2133
2213
|
}
|
|
2134
|
-
function
|
|
2214
|
+
function ti(e) {
|
|
2135
2215
|
return e.toggleNode;
|
|
2136
2216
|
}
|
|
2137
2217
|
//#endregion
|
|
2138
2218
|
//#region src/components/tab-strip/tab-visibility.store.ts
|
|
2139
|
-
var
|
|
2219
|
+
var ni = { tabOverrides: {} }, ri = "pstdio/ui/tab-visibility", ii = (e) => `${ri}/${e}`, ai = (e, t) => e ?? (t ? "hidden" : "shown"), oi = (e, t, n) => {
|
|
2140
2220
|
if (n === void 0) {
|
|
2141
2221
|
if (!(t in e)) return e;
|
|
2142
2222
|
let { [t]: n, ...r } = e;
|
|
@@ -2146,42 +2226,42 @@ var $r = { tabOverrides: {} }, ei = "pstdio/ui/tab-visibility", ti = (e) => `${e
|
|
|
2146
2226
|
...e,
|
|
2147
2227
|
[t]: n
|
|
2148
2228
|
};
|
|
2149
|
-
},
|
|
2150
|
-
|
|
2229
|
+
}, si = (e, t, n) => oi(e, t, ai(e[t], n) === "hidden" ? "shown" : "hidden"), ci = (e) => ({ tabOverrides: e.tabOverrides }), li = (e) => Ht()(Vt((e) => ({
|
|
2230
|
+
...ni,
|
|
2151
2231
|
setTab: (t, n) => e((e) => ({
|
|
2152
2232
|
...e,
|
|
2153
|
-
tabOverrides:
|
|
2233
|
+
tabOverrides: oi(e.tabOverrides, t, n)
|
|
2154
2234
|
})),
|
|
2155
2235
|
toggleTab: (t, n) => e((e) => ({
|
|
2156
2236
|
...e,
|
|
2157
|
-
tabOverrides:
|
|
2237
|
+
tabOverrides: si(e.tabOverrides, t, n)
|
|
2158
2238
|
})),
|
|
2159
2239
|
clearTab: (t) => e((e) => ({
|
|
2160
2240
|
...e,
|
|
2161
|
-
tabOverrides:
|
|
2241
|
+
tabOverrides: oi(e.tabOverrides, t, void 0)
|
|
2162
2242
|
})),
|
|
2163
|
-
reset: () => e(
|
|
2243
|
+
reset: () => e(ni)
|
|
2164
2244
|
}), {
|
|
2165
|
-
name:
|
|
2166
|
-
storage:
|
|
2167
|
-
partialize:
|
|
2168
|
-
})),
|
|
2169
|
-
let t =
|
|
2245
|
+
name: ii(e.storageKey),
|
|
2246
|
+
storage: Bt(V),
|
|
2247
|
+
partialize: ci
|
|
2248
|
+
})), ui = /* @__PURE__ */ new Map(), di = (e) => {
|
|
2249
|
+
let t = ui.get(e);
|
|
2170
2250
|
if (t) return t;
|
|
2171
|
-
let n =
|
|
2172
|
-
return
|
|
2173
|
-
},
|
|
2251
|
+
let n = li({ storageKey: e });
|
|
2252
|
+
return ui.set(e, n), n;
|
|
2253
|
+
}, fi = (e, t) => {
|
|
2174
2254
|
let n = Z(2), r;
|
|
2175
|
-
return n[0] === e ? r = n[1] : (r =
|
|
2176
|
-
},
|
|
2255
|
+
return n[0] === e ? r = n[1] : (r = di(e), n[0] = e, n[1] = r), zt(r, t);
|
|
2256
|
+
}, pi = (e, t) => typeof e == "string" ? e : t, mi = (e, t) => e ?? (t ? "hidden" : "shown"), hi = (e) => e.canHide === !0 || e.hiddenByDefault === !0, gi = (e, t) => mi(t[e.id], e.hiddenByDefault) === "shown", _i = (e, t) => {
|
|
2177
2257
|
let n = !1, r = [];
|
|
2178
2258
|
for (let i of e) {
|
|
2179
|
-
if (!
|
|
2259
|
+
if (!gi(i, t)) {
|
|
2180
2260
|
n = !0;
|
|
2181
2261
|
continue;
|
|
2182
2262
|
}
|
|
2183
2263
|
if (i.children && i.children.length > 0) {
|
|
2184
|
-
let e =
|
|
2264
|
+
let e = _i(i.children, t);
|
|
2185
2265
|
if (e !== i.children) {
|
|
2186
2266
|
n = !0, r.push({
|
|
2187
2267
|
...i,
|
|
@@ -2193,14 +2273,14 @@ var $r = { tabOverrides: {} }, ei = "pstdio/ui/tab-visibility", ti = (e) => `${e
|
|
|
2193
2273
|
r.push(i);
|
|
2194
2274
|
}
|
|
2195
2275
|
return n ? r : e;
|
|
2196
|
-
},
|
|
2276
|
+
}, vi = (e, t) => _i(e, t), yi = (e, t, n) => {
|
|
2197
2277
|
let r = !1, i = [];
|
|
2198
2278
|
for (let a of e) {
|
|
2199
|
-
if (
|
|
2279
|
+
if (mi(t[a.id], a.hiddenByDefault) === "hidden") {
|
|
2200
2280
|
r = !0;
|
|
2201
2281
|
continue;
|
|
2202
2282
|
}
|
|
2203
|
-
let e =
|
|
2283
|
+
let e = _i(a.nodes, n);
|
|
2204
2284
|
if (e.length === 0 && !a.emptyState && !a.actions?.length) {
|
|
2205
2285
|
r = !0;
|
|
2206
2286
|
continue;
|
|
@@ -2215,24 +2295,24 @@ var $r = { tabOverrides: {} }, ei = "pstdio/ui/tab-visibility", ti = (e) => `${e
|
|
|
2215
2295
|
i.push(a);
|
|
2216
2296
|
}
|
|
2217
2297
|
return r ? i : e;
|
|
2218
|
-
},
|
|
2219
|
-
let a = e.hiddenByDefault === !0, o =
|
|
2298
|
+
}, bi = (e, t) => e === "shown" ? t.visibleIcon : t.hiddenIcon, xi = (e, t, n, r, i) => {
|
|
2299
|
+
let a = e.hiddenByDefault === !0, o = mi(n[e.id], a);
|
|
2220
2300
|
return {
|
|
2221
2301
|
key: `section:${e.id}`,
|
|
2222
2302
|
label: t,
|
|
2223
2303
|
onClick: () => r.onToggleSection(e.id, a),
|
|
2224
|
-
endContent:
|
|
2304
|
+
endContent: bi(o, i)
|
|
2225
2305
|
};
|
|
2226
|
-
},
|
|
2227
|
-
let i = e.hiddenByDefault === !0, a =
|
|
2306
|
+
}, Si = (e, t, n, r) => {
|
|
2307
|
+
let i = e.hiddenByDefault === !0, a = mi(t[e.id], i);
|
|
2228
2308
|
return {
|
|
2229
2309
|
key: `node:${e.id}`,
|
|
2230
|
-
label:
|
|
2310
|
+
label: pi(e.label, e.id),
|
|
2231
2311
|
icon: e.icon,
|
|
2232
2312
|
onClick: () => n.onToggleNode(e.id, i),
|
|
2233
|
-
endContent:
|
|
2313
|
+
endContent: bi(a, r)
|
|
2234
2314
|
};
|
|
2235
|
-
},
|
|
2315
|
+
}, Ci = (e, t, n, r, i) => {
|
|
2236
2316
|
let a = [], o = (e) => {
|
|
2237
2317
|
e.length !== 0 && (a.length > 0 && (e[0] = {
|
|
2238
2318
|
...e[0],
|
|
@@ -2242,8 +2322,8 @@ var $r = { tabOverrides: {} }, ei = "pstdio/ui/tab-visibility", ti = (e) => `${e
|
|
|
2242
2322
|
let a = [];
|
|
2243
2323
|
for (let o of e) {
|
|
2244
2324
|
let e = o.label ?? o.menuLabel;
|
|
2245
|
-
e &&
|
|
2246
|
-
for (let e of o.nodes)
|
|
2325
|
+
e && hi(o) && a.push(xi(o, e, t, r, i));
|
|
2326
|
+
for (let e of o.nodes) hi(e) && a.push(Si(e, n, r, i));
|
|
2247
2327
|
}
|
|
2248
2328
|
return a;
|
|
2249
2329
|
};
|
|
@@ -2254,7 +2334,7 @@ var $r = { tabOverrides: {} }, ei = "pstdio/ui/tab-visibility", ti = (e) => `${e
|
|
|
2254
2334
|
separatorBefore: !0,
|
|
2255
2335
|
onClick: r.onResetAll
|
|
2256
2336
|
}), a;
|
|
2257
|
-
},
|
|
2337
|
+
}, wi = (e, t, n) => {
|
|
2258
2338
|
let r = !1, i = [];
|
|
2259
2339
|
for (let a of e) {
|
|
2260
2340
|
if (a.closable === !0) {
|
|
@@ -2265,19 +2345,19 @@ var $r = { tabOverrides: {} }, ei = "pstdio/ui/tab-visibility", ti = (e) => `${e
|
|
|
2265
2345
|
r = !0;
|
|
2266
2346
|
continue;
|
|
2267
2347
|
}
|
|
2268
|
-
if (
|
|
2348
|
+
if (mi(t[n(a)], a.hiddenByDefault) === "hidden") {
|
|
2269
2349
|
r = !0;
|
|
2270
2350
|
continue;
|
|
2271
2351
|
}
|
|
2272
2352
|
i.push(a);
|
|
2273
2353
|
}
|
|
2274
2354
|
return r ? i : e;
|
|
2275
|
-
},
|
|
2355
|
+
}, Ti = (e, t, n, r, i, a) => {
|
|
2276
2356
|
let o = [], s = 0;
|
|
2277
2357
|
for (let c of e) {
|
|
2278
2358
|
if (c.pinned === !0 || c.closable === !0) continue;
|
|
2279
2359
|
s += 1;
|
|
2280
|
-
let e = r(c), l = c.hiddenByDefault === !0, u =
|
|
2360
|
+
let e = r(c), l = c.hiddenByDefault === !0, u = mi(t[e], l);
|
|
2281
2361
|
o.push({
|
|
2282
2362
|
key: `tab:${e}`,
|
|
2283
2363
|
label: c.title ?? c.contributionId,
|
|
@@ -2293,14 +2373,14 @@ var $r = { tabOverrides: {} }, ei = "pstdio/ui/tab-visibility", ti = (e) => `${e
|
|
|
2293
2373
|
separatorBefore: !0,
|
|
2294
2374
|
onClick: n.onResetAll
|
|
2295
2375
|
}), o;
|
|
2296
|
-
}, { withProvider:
|
|
2376
|
+
}, { withProvider: Ei, withContext: Di } = Ue({ recipe: H }), Oi = Ei("div", "list"), ki = Di("div", "tab"), Ai = Di("button", "trigger"), ji = Di("span", "label"), Mi = Di("button", "close"), Ni = (e) => {
|
|
2297
2377
|
let t = Z(43), { tab: n, selected: r, tabIndex: i, reorderable: a, onSelect: o, onClose: s, onKeyDown: c } = e, u = !a, d;
|
|
2298
2378
|
t[0] !== u || t[1] !== n.id ? (d = {
|
|
2299
2379
|
id: n.id,
|
|
2300
2380
|
disabled: u
|
|
2301
2381
|
}, t[0] = u, t[1] = n.id, t[2] = d) : d = t[2];
|
|
2302
|
-
let { attributes: f, listeners: p, setNodeRef: m, setActivatorNodeRef: h, transform: g, transition: _, isDragging: v, isSorting: y } =
|
|
2303
|
-
t[3] === g ? S = t[4] : (S =
|
|
2382
|
+
let { attributes: f, listeners: p, setNodeRef: m, setActivatorNodeRef: h, transform: g, transition: _, isDragging: v, isSorting: y } = Lt(d), b = r ? "" : void 0, x = v ? "" : void 0, S;
|
|
2383
|
+
t[3] === g ? S = t[4] : (S = Ut.Translate.toString(g), t[3] = g, t[4] = S);
|
|
2304
2384
|
let C = !y && void 0, w;
|
|
2305
2385
|
t[5] === Symbol.for("react.memo_cache_sentinel") ? (w = { placement: "bottom" }, t[5] = w) : w = t[5];
|
|
2306
2386
|
let T;
|
|
@@ -2310,9 +2390,9 @@ var $r = { tabOverrides: {} }, ei = "pstdio/ui/tab-visibility", ti = (e) => `${e
|
|
|
2310
2390
|
p?.onKeyDown?.(e), !y && !e.defaultPrevented && c(e);
|
|
2311
2391
|
}, t[9] = y, t[10] = p, t[11] = c, t[12] = E) : E = t[12];
|
|
2312
2392
|
let D;
|
|
2313
|
-
t[13] === n.label ? D = t[14] : (D = /* @__PURE__ */ Q(
|
|
2393
|
+
t[13] === n.label ? D = t[14] : (D = /* @__PURE__ */ Q(ji, { children: n.label }), t[13] = n.label, t[14] = D);
|
|
2314
2394
|
let O;
|
|
2315
|
-
t[15] !== p || t[16] !== o || t[17] !== r || t[18] !== h || t[19] !== T || t[20] !== E || t[21] !== D || t[22] !== n.icon || t[23] !== n.label || t[24] !== i ? (O = /* @__PURE__ */ $(
|
|
2395
|
+
t[15] !== p || t[16] !== o || t[17] !== r || t[18] !== h || t[19] !== T || t[20] !== E || t[21] !== D || t[22] !== n.icon || t[23] !== n.label || t[24] !== i ? (O = /* @__PURE__ */ $(Ai, {
|
|
2316
2396
|
...T,
|
|
2317
2397
|
...p,
|
|
2318
2398
|
ref: h,
|
|
@@ -2335,9 +2415,9 @@ var $r = { tabOverrides: {} }, ei = "pstdio/ui/tab-visibility", ti = (e) => `${e
|
|
|
2335
2415
|
children: O
|
|
2336
2416
|
}), t[26] = O, t[27] = C, t[28] = n.label, t[29] = k) : k = t[29];
|
|
2337
2417
|
let A = `Close ${n.label}`, j = `Close ${n.label}`, M;
|
|
2338
|
-
t[30] === Symbol.for("react.memo_cache_sentinel") ? (M = /* @__PURE__ */ Q(
|
|
2418
|
+
t[30] === Symbol.for("react.memo_cache_sentinel") ? (M = /* @__PURE__ */ Q(Et, { "aria-hidden": "true" }), t[30] = M) : M = t[30];
|
|
2339
2419
|
let N;
|
|
2340
|
-
t[31] !== s || t[32] !== A || t[33] !== j ? (N = /* @__PURE__ */ Q(
|
|
2420
|
+
t[31] !== s || t[32] !== A || t[33] !== j ? (N = /* @__PURE__ */ Q(Mi, {
|
|
2341
2421
|
type: "button",
|
|
2342
2422
|
"aria-label": A,
|
|
2343
2423
|
title: j,
|
|
@@ -2345,7 +2425,7 @@ var $r = { tabOverrides: {} }, ei = "pstdio/ui/tab-visibility", ti = (e) => `${e
|
|
|
2345
2425
|
children: M
|
|
2346
2426
|
}), t[31] = s, t[32] = A, t[33] = j, t[34] = N) : N = t[34];
|
|
2347
2427
|
let P;
|
|
2348
|
-
return t[35] !== m || t[36] !== k || t[37] !== N || t[38] !== b || t[39] !== x || t[40] !== S || t[41] !== _ ? (P = /* @__PURE__ */ $(
|
|
2428
|
+
return t[35] !== m || t[36] !== k || t[37] !== N || t[38] !== b || t[39] !== x || t[40] !== S || t[41] !== _ ? (P = /* @__PURE__ */ $(ki, {
|
|
2349
2429
|
ref: m,
|
|
2350
2430
|
role: "presentation",
|
|
2351
2431
|
"data-selected": b,
|
|
@@ -2354,12 +2434,12 @@ var $r = { tabOverrides: {} }, ei = "pstdio/ui/tab-visibility", ti = (e) => `${e
|
|
|
2354
2434
|
transition: _,
|
|
2355
2435
|
children: [k, N]
|
|
2356
2436
|
}), t[35] = m, t[36] = k, t[37] = N, t[38] = b, t[39] = x, t[40] = S, t[41] = _, t[42] = P) : P = t[42], P;
|
|
2357
|
-
},
|
|
2437
|
+
}, Pi = (e) => {
|
|
2358
2438
|
let t = Z(48), { tabs: n, selectedId: r, onSelect: i, onClose: a, onReorder: o, "aria-label": s } = e, c = rt(null), l;
|
|
2359
2439
|
t[0] === Symbol.for("react.memo_cache_sentinel") ? (l = { activationConstraint: { distance: 6 } }, t[0] = l) : l = t[0];
|
|
2360
2440
|
let u;
|
|
2361
|
-
t[1] === Symbol.for("react.memo_cache_sentinel") ? (u = { coordinateGetter:
|
|
2362
|
-
let d = jt(
|
|
2441
|
+
t[1] === Symbol.for("react.memo_cache_sentinel") ? (u = { coordinateGetter: It }, t[1] = u) : u = t[1];
|
|
2442
|
+
let d = Mt(jt(kt, l), jt(Ot, u)), f, p;
|
|
2363
2443
|
t[2] === r ? (f = t[3], p = t[4]) : (f = () => {
|
|
2364
2444
|
r && c.current?.querySelector("[aria-selected=\"true\"]")?.scrollIntoView({
|
|
2365
2445
|
block: "nearest",
|
|
@@ -2383,10 +2463,10 @@ var $r = { tabOverrides: {} }, ei = "pstdio/ui/tab-visibility", ti = (e) => `${e
|
|
|
2383
2463
|
} else return;
|
|
2384
2464
|
t.preventDefault(), c.current?.querySelectorAll("[role=\"tab\"]")[a]?.focus(), i(n[a].id);
|
|
2385
2465
|
};
|
|
2386
|
-
g =
|
|
2466
|
+
g = Dt, _ = d, v = At, t[25] === Symbol.for("react.memo_cache_sentinel") ? (y = [Fi], t[25] = y) : y = t[25], t[26] === o ? b = t[27] : (b = (e) => {
|
|
2387
2467
|
let { active: t, over: n } = e;
|
|
2388
2468
|
n && t.id !== n.id && o?.(String(t.id), String(n.id));
|
|
2389
|
-
}, t[26] = o, t[27] = b), h =
|
|
2469
|
+
}, t[26] = o, t[27] = b), h = Nt, t[28] === n ? T = t[29] : (T = n.map(Ii), t[28] = n, t[29] = T), E = Ft, m = Oi, x = c, S = "tablist", C = s, w = n.map((t, a) => /* @__PURE__ */ Q(Ni, {
|
|
2390
2470
|
tab: t,
|
|
2391
2471
|
selected: t.id === r,
|
|
2392
2472
|
tabIndex: t.id === (r ?? n[0]?.id) ? 0 : -1,
|
|
@@ -2418,28 +2498,30 @@ var $r = { tabOverrides: {} }, ei = "pstdio/ui/tab-visibility", ti = (e) => `${e
|
|
|
2418
2498
|
children: O
|
|
2419
2499
|
}), t[41] = g, t[42] = _, t[43] = v, t[44] = y, t[45] = b, t[46] = O, t[47] = k) : k = t[47], k;
|
|
2420
2500
|
};
|
|
2421
|
-
function
|
|
2501
|
+
function Fi(e) {
|
|
2422
2502
|
let { transform: t } = e;
|
|
2423
2503
|
return {
|
|
2424
2504
|
...t,
|
|
2425
2505
|
y: 0
|
|
2426
2506
|
};
|
|
2427
2507
|
}
|
|
2428
|
-
function
|
|
2508
|
+
function Ii(e) {
|
|
2429
2509
|
return e.id;
|
|
2430
2510
|
}
|
|
2431
2511
|
//#endregion
|
|
2432
2512
|
//#region src/components/tab-strip/window-title-bar.tsx
|
|
2433
|
-
var { withProvider:
|
|
2434
|
-
let t = Z(
|
|
2435
|
-
t[0] ===
|
|
2436
|
-
let
|
|
2437
|
-
|
|
2438
|
-
|
|
2513
|
+
var { withProvider: Li, withContext: Ri } = Ue({ recipe: U }), zi = Li("div", "root"), Bi = Ri("div", "content"), Vi = Ri("div", "actions"), Hi = (e) => {
|
|
2514
|
+
let t = Z(8), { platform: n, children: r, actions: i } = e, a = n === "darwin" ? "mac" : "overlay", o;
|
|
2515
|
+
t[0] === i ? o = t[1] : (o = i && /* @__PURE__ */ Q(Vi, { children: i }), t[0] = i, t[1] = o);
|
|
2516
|
+
let s;
|
|
2517
|
+
t[2] !== r || t[3] !== o ? (s = /* @__PURE__ */ $(Bi, { children: [r, o] }), t[2] = r, t[3] = o, t[4] = s) : s = t[4];
|
|
2518
|
+
let c;
|
|
2519
|
+
return t[5] !== a || t[6] !== s ? (c = /* @__PURE__ */ Q(zi, {
|
|
2520
|
+
controls: a,
|
|
2439
2521
|
"data-window-title-bar": "",
|
|
2440
|
-
children:
|
|
2441
|
-
}), t[
|
|
2442
|
-
},
|
|
2522
|
+
children: s
|
|
2523
|
+
}), t[5] = a, t[6] = s, t[7] = c) : c = t[7], c;
|
|
2524
|
+
}, Ui = (e) => {
|
|
2443
2525
|
let t = Z(7), { children: n, hasChanges: r } = e, i;
|
|
2444
2526
|
t[0] === n ? i = t[1] : (i = /* @__PURE__ */ Q(X, {
|
|
2445
2527
|
textStyle: "label/L/medium",
|
|
@@ -2459,7 +2541,7 @@ var { withProvider: Pi, withContext: Fi } = Ue({ recipe: W }), Ii = Pi("div", "r
|
|
|
2459
2541
|
minWidth: "0",
|
|
2460
2542
|
children: [i, a]
|
|
2461
2543
|
}), t[4] = i, t[5] = a, t[6] = o) : o = t[6], o;
|
|
2462
|
-
},
|
|
2544
|
+
}, Wi = (e) => e.length === 0 ? "None" : e.length === 1 ? e[0].label : `${e[0].label} +${e.length - 1}`, Gi = (e) => {
|
|
2463
2545
|
let t = Z(54), { actions: n, disabled: r, label: i, options: a, optionName: o, onChange: s } = e, c, l, u, d, f, p, m, g, _, v, y, b, x, S;
|
|
2464
2546
|
if (t[0] !== n || t[1] !== r || t[2] !== i || t[3] !== s || t[4] !== o || t[5] !== a) {
|
|
2465
2547
|
let e;
|
|
@@ -2467,7 +2549,7 @@ var { withProvider: Pi, withContext: Fi } = Ue({ recipe: W }), Ii = Pi("div", "r
|
|
|
2467
2549
|
let h = a.filter(e), C;
|
|
2468
2550
|
t[22] !== n || t[23] !== s ? (C = (e) => {
|
|
2469
2551
|
s(n.includes(e) ? n.filter((t) => t !== e) : [...n, e]);
|
|
2470
|
-
}, t[22] = n, t[23] = s, t[24] = C) : C = t[24], S = C, u = Me.Root, x = !1, l = Me.Trigger, b = !0, c =
|
|
2552
|
+
}, t[22] = n, t[23] = s, t[24] = C) : C = t[24], S = C, u = Me.Root, x = !1, l = Me.Trigger, b = !0, c = xe, d = "2xs", f = "ghost", p = "xs", m = h.length === 0 ? "fg.subtle" : "fg", g = r, _ = `${i} for ${o}`, v = h[0]?.icon, y = Wi(h), t[0] = n, t[1] = r, t[2] = i, t[3] = s, t[4] = o, t[5] = a, t[6] = c, t[7] = l, t[8] = u, t[9] = d, t[10] = f, t[11] = p, t[12] = m, t[13] = g, t[14] = _, t[15] = v, t[16] = y, t[17] = b, t[18] = x, t[19] = S;
|
|
2471
2553
|
} else c = t[6], l = t[7], u = t[8], d = t[9], f = t[10], p = t[11], m = t[12], g = t[13], _ = t[14], v = t[15], y = t[16], b = t[17], x = t[18], S = t[19];
|
|
2472
2554
|
let C;
|
|
2473
2555
|
t[25] === Symbol.for("react.memo_cache_sentinel") ? (C = /* @__PURE__ */ Q(Y, {
|
|
@@ -2525,14 +2607,14 @@ var { withProvider: Pi, withContext: Fi } = Ue({ recipe: W }), Ii = Pi("div", "r
|
|
|
2525
2607
|
closeOnSelect: x,
|
|
2526
2608
|
children: [T, D]
|
|
2527
2609
|
}), t[49] = u, t[50] = T, t[51] = D, t[52] = x, t[53] = O) : O = t[53], O;
|
|
2528
|
-
},
|
|
2610
|
+
}, Ki = (e) => {
|
|
2529
2611
|
let t = Z(68), { actionOptions: n, actionsLabel: r, colorOptions: i, iconOptions: a, value: o, isSaving: s, readOnly: c, showDefault: l, showIcons: u, onActionsChange: d, onColorChange: f, onDelete: p, onIconChange: m, onNameChange: h } = e, g = r === void 0 ? "Actions" : r, _ = s || c, v;
|
|
2530
2612
|
t[0] !== _ || t[1] !== o.id ? (v = {
|
|
2531
2613
|
id: o.id,
|
|
2532
2614
|
disabled: _
|
|
2533
2615
|
}, t[0] = _, t[1] = o.id, t[2] = v) : v = t[2];
|
|
2534
|
-
let { attributes: y, listeners: b, setNodeRef: x, transform: S, transition: C, isDragging: w } =
|
|
2535
|
-
t[3] === S ? T = t[4] : (T =
|
|
2616
|
+
let { attributes: y, listeners: b, setNodeRef: x, transform: S, transition: C, isDragging: w } = Lt(v), T;
|
|
2617
|
+
t[3] === S ? T = t[4] : (T = Ut.Transform.toString(S), t[3] = S, t[4] = T);
|
|
2536
2618
|
let E;
|
|
2537
2619
|
t[5] !== T || t[6] !== C ? (E = {
|
|
2538
2620
|
transform: T,
|
|
@@ -2542,23 +2624,23 @@ var { withProvider: Pi, withContext: Fi } = Ue({ recipe: W }), Ii = Pi("div", "r
|
|
|
2542
2624
|
t[8] === j ? M = t[9] : (M = { bg: j }, t[8] = j, t[9] = M);
|
|
2543
2625
|
let N = c ? "default" : "grab", P;
|
|
2544
2626
|
t[10] === Symbol.for("react.memo_cache_sentinel") ? (P = { color: "fg.muted" }, t[10] = P) : P = t[10];
|
|
2545
|
-
let
|
|
2546
|
-
t[11] === Symbol.for("react.memo_cache_sentinel") ? (
|
|
2627
|
+
let ee = `Reorder ${o.name}`, F;
|
|
2628
|
+
t[11] === Symbol.for("react.memo_cache_sentinel") ? (F = /* @__PURE__ */ Q(Y, {
|
|
2547
2629
|
as: gt,
|
|
2548
2630
|
boxSize: "icon-xs"
|
|
2549
|
-
}), t[11] =
|
|
2550
|
-
let
|
|
2551
|
-
t[12] !== y || t[13] !== b || t[14] !== N || t[15] !==
|
|
2631
|
+
}), t[11] = F) : F = t[11];
|
|
2632
|
+
let I;
|
|
2633
|
+
t[12] !== y || t[13] !== b || t[14] !== N || t[15] !== ee ? (I = /* @__PURE__ */ Q(q, {
|
|
2552
2634
|
cursor: N,
|
|
2553
2635
|
color: "fg.subtle",
|
|
2554
2636
|
_groupHover: P,
|
|
2555
|
-
"aria-label":
|
|
2637
|
+
"aria-label": ee,
|
|
2556
2638
|
...y,
|
|
2557
2639
|
...b,
|
|
2558
|
-
children:
|
|
2559
|
-
}), t[12] = y, t[13] = b, t[14] = N, t[15] =
|
|
2560
|
-
let
|
|
2561
|
-
t[17] !== i || t[18] !== _ || t[19] !== a || t[20] !== f || t[21] !== m || t[22] !== u || t[23] !==
|
|
2640
|
+
children: F
|
|
2641
|
+
}), t[12] = y, t[13] = b, t[14] = N, t[15] = ee, t[16] = I) : I = t[16];
|
|
2642
|
+
let L = `Change ${o.name} appearance`, R;
|
|
2643
|
+
t[17] !== i || t[18] !== _ || t[19] !== a || t[20] !== f || t[21] !== m || t[22] !== u || t[23] !== L || t[24] !== o.color || t[25] !== o.icon ? (R = /* @__PURE__ */ Q(yr, {
|
|
2562
2644
|
color: o.color,
|
|
2563
2645
|
colorOptions: i,
|
|
2564
2646
|
icon: o.icon,
|
|
@@ -2567,45 +2649,45 @@ var { withProvider: Pi, withContext: Fi } = Ue({ recipe: W }), Ii = Pi("div", "r
|
|
|
2567
2649
|
onColorChange: f,
|
|
2568
2650
|
onIconChange: m,
|
|
2569
2651
|
disabled: _,
|
|
2570
|
-
"aria-label":
|
|
2571
|
-
}), t[17] = i, t[18] = _, t[19] = a, t[20] = f, t[21] = m, t[22] = u, t[23] =
|
|
2572
|
-
let
|
|
2573
|
-
t[27] !== h || t[28] !== o.name ? (
|
|
2652
|
+
"aria-label": L
|
|
2653
|
+
}), t[17] = i, t[18] = _, t[19] = a, t[20] = f, t[21] = m, t[22] = u, t[23] = L, t[24] = o.color, t[25] = o.icon, t[26] = R) : R = t[26];
|
|
2654
|
+
let z;
|
|
2655
|
+
t[27] !== h || t[28] !== o.name ? (z = (e) => {
|
|
2574
2656
|
let t = e.value.trim();
|
|
2575
2657
|
t && t !== o.name && h(t);
|
|
2576
|
-
}, t[27] = h, t[28] = o.name, t[29] =
|
|
2577
|
-
let
|
|
2578
|
-
t[30] === Symbol.for("react.memo_cache_sentinel") ? (
|
|
2579
|
-
let
|
|
2580
|
-
t[32] !== _ || t[33] !==
|
|
2658
|
+
}, t[27] = h, t[28] = o.name, t[29] = z) : z = t[29];
|
|
2659
|
+
let B, te;
|
|
2660
|
+
t[30] === Symbol.for("react.memo_cache_sentinel") ? (B = /* @__PURE__ */ Q(Ee.Preview, { textStyle: "paragraph/S/regular" }), te = /* @__PURE__ */ Q(Ee.Input, { textStyle: "paragraph/S/regular" }), t[30] = B, t[31] = te) : (B = t[30], te = t[31]);
|
|
2661
|
+
let ne;
|
|
2662
|
+
t[32] !== _ || t[33] !== z || t[34] !== o.isNew || t[35] !== o.name ? (ne = /* @__PURE__ */ $(Ee.Root, {
|
|
2581
2663
|
minWidth: "0",
|
|
2582
2664
|
defaultValue: o.name,
|
|
2583
2665
|
defaultEdit: o.isNew,
|
|
2584
2666
|
selectOnFocus: !0,
|
|
2585
2667
|
disabled: _,
|
|
2586
|
-
onValueCommit:
|
|
2587
|
-
children: [
|
|
2588
|
-
}, o.name), t[32] = _, t[33] =
|
|
2589
|
-
let
|
|
2590
|
-
t[37] !== l || t[38] !== o.isDefault ? (
|
|
2668
|
+
onValueCommit: z,
|
|
2669
|
+
children: [B, te]
|
|
2670
|
+
}, o.name), t[32] = _, t[33] = z, t[34] = o.isNew, t[35] = o.name, t[36] = ne) : ne = t[36];
|
|
2671
|
+
let re;
|
|
2672
|
+
t[37] !== l || t[38] !== o.isDefault ? (re = l && o.isDefault ? /* @__PURE__ */ Q(ye, {
|
|
2591
2673
|
size: "sm",
|
|
2592
2674
|
variant: "subtle",
|
|
2593
2675
|
colorPalette: "blue",
|
|
2594
2676
|
children: "Default"
|
|
2595
|
-
}) : null, t[37] = l, t[38] = o.isDefault, t[39] =
|
|
2596
|
-
let
|
|
2597
|
-
t[40] !==
|
|
2677
|
+
}) : null, t[37] = l, t[38] = o.isDefault, t[39] = re) : re = t[39];
|
|
2678
|
+
let ie;
|
|
2679
|
+
t[40] !== ne || t[41] !== re ? (ie = /* @__PURE__ */ $(q, {
|
|
2598
2680
|
flex: "1",
|
|
2599
2681
|
minWidth: "0",
|
|
2600
2682
|
alignItems: "center",
|
|
2601
2683
|
gap: "xs",
|
|
2602
|
-
children: [
|
|
2603
|
-
}), t[40] =
|
|
2604
|
-
let
|
|
2605
|
-
t[43] !== n || t[44] !== g || t[45] !== _ || t[46] !== d || t[47] !== o.actions || t[48] !== o.name ? (
|
|
2684
|
+
children: [ne, re]
|
|
2685
|
+
}), t[40] = ne, t[41] = re, t[42] = ie) : ie = t[42];
|
|
2686
|
+
let ae;
|
|
2687
|
+
t[43] !== n || t[44] !== g || t[45] !== _ || t[46] !== d || t[47] !== o.actions || t[48] !== o.name ? (ae = n ? /* @__PURE__ */ Q(q, {
|
|
2606
2688
|
width: "tag-editor-commands",
|
|
2607
2689
|
justifyContent: "flex-end",
|
|
2608
|
-
children: /* @__PURE__ */ Q(
|
|
2690
|
+
children: /* @__PURE__ */ Q(Gi, {
|
|
2609
2691
|
actions: o.actions ?? [],
|
|
2610
2692
|
disabled: _,
|
|
2611
2693
|
label: g,
|
|
@@ -2613,23 +2695,23 @@ var { withProvider: Pi, withContext: Fi } = Ue({ recipe: W }), Ii = Pi("div", "r
|
|
|
2613
2695
|
options: n,
|
|
2614
2696
|
onChange: d
|
|
2615
2697
|
})
|
|
2616
|
-
}) : null, t[43] = n, t[44] = g, t[45] = _, t[46] = d, t[47] = o.actions, t[48] = o.name, t[49] =
|
|
2617
|
-
let
|
|
2618
|
-
t[50] === Symbol.for("react.memo_cache_sentinel") ? (
|
|
2619
|
-
as:
|
|
2698
|
+
}) : null, t[43] = n, t[44] = g, t[45] = _, t[46] = d, t[47] = o.actions, t[48] = o.name, t[49] = ae) : ae = t[49];
|
|
2699
|
+
let V = _ || o.isDefault, H = `Delete ${o.name}`, U;
|
|
2700
|
+
t[50] === Symbol.for("react.memo_cache_sentinel") ? (U = /* @__PURE__ */ Q(Y, {
|
|
2701
|
+
as: Tt,
|
|
2620
2702
|
boxSize: "icon-xs"
|
|
2621
|
-
}), t[50] =
|
|
2622
|
-
let
|
|
2623
|
-
t[51] !== p || t[52] !==
|
|
2703
|
+
}), t[50] = U) : U = t[50];
|
|
2704
|
+
let oe;
|
|
2705
|
+
t[51] !== p || t[52] !== V || t[53] !== H ? (oe = /* @__PURE__ */ Q(Oe, {
|
|
2624
2706
|
size: "xs",
|
|
2625
2707
|
variant: "destructive-ghost",
|
|
2626
2708
|
onClick: p,
|
|
2627
|
-
disabled:
|
|
2628
|
-
"aria-label":
|
|
2629
|
-
children:
|
|
2630
|
-
}), t[51] = p, t[52] =
|
|
2631
|
-
let
|
|
2632
|
-
return t[55] !== x || t[56] !==
|
|
2709
|
+
disabled: V,
|
|
2710
|
+
"aria-label": H,
|
|
2711
|
+
children: U
|
|
2712
|
+
}), t[51] = p, t[52] = V, t[53] = H, t[54] = oe) : oe = t[54];
|
|
2713
|
+
let W;
|
|
2714
|
+
return t[55] !== x || t[56] !== I || t[57] !== R || t[58] !== ie || t[59] !== ae || t[60] !== oe || t[61] !== E || t[62] !== D || t[63] !== O || t[64] !== k || t[65] !== A || t[66] !== M ? (W = /* @__PURE__ */ $(q, {
|
|
2633
2715
|
ref: x,
|
|
2634
2716
|
style: E,
|
|
2635
2717
|
className: "group",
|
|
@@ -2645,18 +2727,18 @@ var { withProvider: Pi, withContext: Fi } = Ue({ recipe: W }), Ii = Pi("div", "r
|
|
|
2645
2727
|
boxShadow: A,
|
|
2646
2728
|
_hover: M,
|
|
2647
2729
|
children: [
|
|
2648
|
-
|
|
2649
|
-
|
|
2650
|
-
re,
|
|
2730
|
+
I,
|
|
2731
|
+
R,
|
|
2651
2732
|
ie,
|
|
2652
|
-
ae
|
|
2733
|
+
ae,
|
|
2734
|
+
oe
|
|
2653
2735
|
]
|
|
2654
|
-
}), t[55] = x, t[56] =
|
|
2655
|
-
},
|
|
2736
|
+
}), t[55] = x, t[56] = I, t[57] = R, t[58] = ie, t[59] = ae, t[60] = oe, t[61] = E, t[62] = D, t[63] = O, t[64] = k, t[65] = A, t[66] = M, t[67] = W) : W = t[67], W;
|
|
2737
|
+
}, qi = (e) => e.length > 0 ? Math.max(...e.map((e) => e.sortOrder)) + 1 : 0, Ji = (e) => {
|
|
2656
2738
|
let t = Z(12), { title: n, hasChanges: r, isSaving: i, onTitleChange: a } = e;
|
|
2657
2739
|
if (!a) {
|
|
2658
2740
|
let e;
|
|
2659
|
-
return t[0] !== r || t[1] !== n ? (e = /* @__PURE__ */ Q(
|
|
2741
|
+
return t[0] !== r || t[1] !== n ? (e = /* @__PURE__ */ Q(Ui, {
|
|
2660
2742
|
hasChanges: r,
|
|
2661
2743
|
children: n
|
|
2662
2744
|
}), t[0] = r, t[1] = n, t[2] = e) : e = t[2], e;
|
|
@@ -2667,16 +2749,16 @@ var { withProvider: Pi, withContext: Fi } = Ue({ recipe: W }), Ii = Pi("div", "r
|
|
|
2667
2749
|
t && t !== n && a(t);
|
|
2668
2750
|
}, t[3] = a, t[4] = n, t[5] = o) : o = t[5];
|
|
2669
2751
|
let s, c;
|
|
2670
|
-
t[6] === Symbol.for("react.memo_cache_sentinel") ? (s = /* @__PURE__ */ Q(
|
|
2752
|
+
t[6] === Symbol.for("react.memo_cache_sentinel") ? (s = /* @__PURE__ */ Q(Ee.Preview, { textStyle: "label/L/medium" }), c = /* @__PURE__ */ Q(Ee.Input, { textStyle: "label/L/medium" }), t[6] = s, t[7] = c) : (s = t[6], c = t[7]);
|
|
2671
2753
|
let l;
|
|
2672
|
-
return t[8] !== i || t[9] !== o || t[10] !== n ? (l = /* @__PURE__ */ $(
|
|
2754
|
+
return t[8] !== i || t[9] !== o || t[10] !== n ? (l = /* @__PURE__ */ $(Ee.Root, {
|
|
2673
2755
|
defaultValue: n,
|
|
2674
2756
|
disabled: i,
|
|
2675
2757
|
selectOnFocus: !0,
|
|
2676
2758
|
onValueCommit: o,
|
|
2677
2759
|
children: [s, c]
|
|
2678
2760
|
}, n), t[8] = i, t[9] = o, t[10] = n, t[11] = l) : l = t[11], l;
|
|
2679
|
-
},
|
|
2761
|
+
}, Yi = He("button", { base: {
|
|
2680
2762
|
display: "flex",
|
|
2681
2763
|
alignItems: "center",
|
|
2682
2764
|
gap: "xs",
|
|
@@ -2697,9 +2779,9 @@ var { withProvider: Pi, withContext: Fi } = Ue({ recipe: W }), Ii = Pi("div", "r
|
|
|
2697
2779
|
color: "fg.muted"
|
|
2698
2780
|
}
|
|
2699
2781
|
}
|
|
2700
|
-
} }),
|
|
2782
|
+
} }), Xi = (e) => {
|
|
2701
2783
|
let t = Z(9), { valueLabel: n, actionsLabel: r } = e, i;
|
|
2702
|
-
t[0] === Symbol.for("react.memo_cache_sentinel") ? (i = /* @__PURE__ */ Q(
|
|
2784
|
+
t[0] === Symbol.for("react.memo_cache_sentinel") ? (i = /* @__PURE__ */ Q(q, {
|
|
2703
2785
|
width: "tag-editor-lead",
|
|
2704
2786
|
flexShrink: "0"
|
|
2705
2787
|
}), t[0] = i) : i = t[0];
|
|
@@ -2720,12 +2802,12 @@ var { withProvider: Pi, withContext: Fi } = Ue({ recipe: W }), Ii = Pi("div", "r
|
|
|
2720
2802
|
children: r
|
|
2721
2803
|
}) : null, t[3] = r, t[4] = o);
|
|
2722
2804
|
let s;
|
|
2723
|
-
t[5] === Symbol.for("react.memo_cache_sentinel") ? (s = /* @__PURE__ */ Q(
|
|
2805
|
+
t[5] === Symbol.for("react.memo_cache_sentinel") ? (s = /* @__PURE__ */ Q(q, {
|
|
2724
2806
|
width: "tag-editor-trailing",
|
|
2725
2807
|
flexShrink: "0"
|
|
2726
2808
|
}), t[5] = s) : s = t[5];
|
|
2727
2809
|
let c;
|
|
2728
|
-
return t[6] !== a || t[7] !== o ? (c = /* @__PURE__ */ $(
|
|
2810
|
+
return t[6] !== a || t[7] !== o ? (c = /* @__PURE__ */ $(q, {
|
|
2729
2811
|
alignItems: "center",
|
|
2730
2812
|
gap: "compact",
|
|
2731
2813
|
paddingInline: "xs",
|
|
@@ -2740,9 +2822,9 @@ var { withProvider: Pi, withContext: Fi } = Ue({ recipe: W }), Ii = Pi("div", "r
|
|
|
2740
2822
|
s
|
|
2741
2823
|
]
|
|
2742
2824
|
}), t[6] = a, t[7] = o, t[8] = c) : c = t[8], c;
|
|
2743
|
-
},
|
|
2825
|
+
}, Zi = (e) => {
|
|
2744
2826
|
let t = Z(22), { label: n, values: r, disabled: i, onSelect: a } = e, o;
|
|
2745
|
-
t[0] === r ? o = t[1] : (o = r.find(
|
|
2827
|
+
t[0] === r ? o = t[1] : (o = r.find($i), t[0] = r, t[1] = o);
|
|
2746
2828
|
let s = o, c;
|
|
2747
2829
|
t[2] === n ? c = t[3] : (c = /* @__PURE__ */ Q(X, {
|
|
2748
2830
|
textStyle: "paragraph/S/regular",
|
|
@@ -2757,7 +2839,7 @@ var { withProvider: Pi, withContext: Fi } = Ue({ recipe: W }), Ii = Pi("div", "r
|
|
|
2757
2839
|
let d;
|
|
2758
2840
|
t[5] !== i || t[6] !== n || t[7] !== l ? (d = /* @__PURE__ */ Q(Me.Trigger, {
|
|
2759
2841
|
asChild: !0,
|
|
2760
|
-
children: /* @__PURE__ */ $(
|
|
2842
|
+
children: /* @__PURE__ */ $(xe, {
|
|
2761
2843
|
size: "2xs",
|
|
2762
2844
|
variant: "ghost",
|
|
2763
2845
|
gap: "xs",
|
|
@@ -2795,7 +2877,7 @@ var { withProvider: Pi, withContext: Fi } = Ue({ recipe: W }), Ii = Pi("div", "r
|
|
|
2795
2877
|
let m;
|
|
2796
2878
|
t[16] !== d || t[17] !== p ? (m = /* @__PURE__ */ $(Me.Root, { children: [d, p] }), t[16] = d, t[17] = p, t[18] = m) : m = t[18];
|
|
2797
2879
|
let g;
|
|
2798
|
-
return t[19] !== c || t[20] !== m ? (g = /* @__PURE__ */ $(
|
|
2880
|
+
return t[19] !== c || t[20] !== m ? (g = /* @__PURE__ */ $(q, {
|
|
2799
2881
|
alignItems: "center",
|
|
2800
2882
|
gap: "sm",
|
|
2801
2883
|
paddingInline: "xs",
|
|
@@ -2805,8 +2887,8 @@ var { withProvider: Pi, withContext: Fi } = Ue({ recipe: W }), Ii = Pi("div", "r
|
|
|
2805
2887
|
borderColor: "border.subtle",
|
|
2806
2888
|
children: [c, m]
|
|
2807
2889
|
}), t[19] = c, t[20] = m, t[21] = g) : g = t[21], g;
|
|
2808
|
-
},
|
|
2809
|
-
let { title: t, description: n, headerActions: r, values: i, onValuesChange: a, onDeleteValue: o, onSetDefault: s, onTitleChange: c, hasChanges: l, isSaving: u, readOnly: d, addLabel: f = "Add option", addName: p = "New option", actionOptions: m, actionsLabel: h, defaultValueLabel: g = "Default value", colorOptions: _, defaultAddColor: v = "blue", defaultAddIcon: y = null, deleteButtonText: b = "Delete tag", deleteHeadline: x = "Delete tag?", deleteNotificationText: S = (e) => `This will delete "${e.name}".`, iconOptions: C, showDefault: w, showIcons: T = !0, framed: E, showColumnHeaders: D, valueColumnLabel: O = "Name" } = e, [k, A] = it(null), j = jt(
|
|
2890
|
+
}, Qi = (e) => {
|
|
2891
|
+
let { title: t, description: n, headerActions: r, values: i, onValuesChange: a, onDeleteValue: o, onSetDefault: s, onTitleChange: c, hasChanges: l, isSaving: u, readOnly: d, addLabel: f = "Add option", addName: p = "New option", actionOptions: m, actionsLabel: h, defaultValueLabel: g = "Default value", colorOptions: _, defaultAddColor: v = "blue", defaultAddIcon: y = null, deleteButtonText: b = "Delete tag", deleteHeadline: x = "Delete tag?", deleteNotificationText: S = (e) => `This will delete "${e.name}".`, iconOptions: C, showDefault: w, showIcons: T = !0, framed: E, showColumnHeaders: D, valueColumnLabel: O = "Name" } = e, [k, A] = it(null), j = Mt(jt(kt, { activationConstraint: { distance: 5 } })), M = (e, t) => {
|
|
2810
2892
|
let n = [...i];
|
|
2811
2893
|
n[e] = {
|
|
2812
2894
|
...n[e],
|
|
@@ -2815,7 +2897,7 @@ var { withProvider: Pi, withContext: Fi } = Ue({ recipe: W }), Ii = Pi("div", "r
|
|
|
2815
2897
|
};
|
|
2816
2898
|
return /* @__PURE__ */ $(Ye, { children: [/* @__PURE__ */ $(Re, {
|
|
2817
2899
|
gap: "2xs",
|
|
2818
|
-
children: [t || r ? /* @__PURE__ */ $(
|
|
2900
|
+
children: [t || r ? /* @__PURE__ */ $(q, {
|
|
2819
2901
|
minHeight: "tag-editor-row",
|
|
2820
2902
|
alignItems: "center",
|
|
2821
2903
|
justifyContent: "space-between",
|
|
@@ -2823,7 +2905,7 @@ var { withProvider: Pi, withContext: Fi } = Ue({ recipe: W }), Ii = Pi("div", "r
|
|
|
2823
2905
|
children: [/* @__PURE__ */ $(Re, {
|
|
2824
2906
|
gap: "3xs",
|
|
2825
2907
|
minWidth: "0",
|
|
2826
|
-
children: [t ? /* @__PURE__ */ Q(
|
|
2908
|
+
children: [t ? /* @__PURE__ */ Q(Ji, {
|
|
2827
2909
|
title: t,
|
|
2828
2910
|
hasChanges: l,
|
|
2829
2911
|
isSaving: u,
|
|
@@ -2841,26 +2923,26 @@ var { withProvider: Pi, withContext: Fi } = Ue({ recipe: W }), Ii = Pi("div", "r
|
|
|
2841
2923
|
borderRadius: E ? "md" : void 0,
|
|
2842
2924
|
overflow: E ? "hidden" : void 0,
|
|
2843
2925
|
children: [
|
|
2844
|
-
D ? /* @__PURE__ */ Q(
|
|
2926
|
+
D ? /* @__PURE__ */ Q(Xi, {
|
|
2845
2927
|
valueLabel: O,
|
|
2846
2928
|
actionsLabel: m ? h : void 0
|
|
2847
2929
|
}) : null,
|
|
2848
|
-
/* @__PURE__ */ Q(
|
|
2930
|
+
/* @__PURE__ */ Q(Dt, {
|
|
2849
2931
|
sensors: j,
|
|
2850
|
-
collisionDetection:
|
|
2932
|
+
collisionDetection: At,
|
|
2851
2933
|
onDragEnd: d ? void 0 : (e) => {
|
|
2852
2934
|
let { active: t, over: n } = e;
|
|
2853
2935
|
if (!n || t.id === n.id) return;
|
|
2854
2936
|
let r = i.findIndex((e) => e.id === t.id), o = i.findIndex((e) => e.id === n.id);
|
|
2855
|
-
r < 0 || o < 0 || a(
|
|
2937
|
+
r < 0 || o < 0 || a(Pt(i, r, o).map((e, t) => ({
|
|
2856
2938
|
...e,
|
|
2857
2939
|
sortOrder: t
|
|
2858
2940
|
})));
|
|
2859
2941
|
},
|
|
2860
|
-
children: /* @__PURE__ */ Q(
|
|
2942
|
+
children: /* @__PURE__ */ Q(Nt, {
|
|
2861
2943
|
items: i.map((e) => e.id),
|
|
2862
|
-
strategy:
|
|
2863
|
-
children: i.map((e, t) => /* @__PURE__ */ Q(
|
|
2944
|
+
strategy: Rt,
|
|
2945
|
+
children: i.map((e, t) => /* @__PURE__ */ Q(Ki, {
|
|
2864
2946
|
value: e,
|
|
2865
2947
|
isSaving: u,
|
|
2866
2948
|
readOnly: d,
|
|
@@ -2878,7 +2960,7 @@ var { withProvider: Pi, withContext: Fi } = Ue({ recipe: W }), Ii = Pi("div", "r
|
|
|
2878
2960
|
}, e.id))
|
|
2879
2961
|
})
|
|
2880
2962
|
}),
|
|
2881
|
-
d ? null : /* @__PURE__ */ $(
|
|
2963
|
+
d ? null : /* @__PURE__ */ $(Yi, {
|
|
2882
2964
|
type: "button",
|
|
2883
2965
|
disabled: u,
|
|
2884
2966
|
onClick: () => {
|
|
@@ -2887,19 +2969,19 @@ var { withProvider: Pi, withContext: Fi } = Ue({ recipe: W }), Ii = Pi("div", "r
|
|
|
2887
2969
|
name: p,
|
|
2888
2970
|
color: v,
|
|
2889
2971
|
icon: y,
|
|
2890
|
-
sortOrder:
|
|
2972
|
+
sortOrder: qi(i),
|
|
2891
2973
|
isNew: !0
|
|
2892
2974
|
}]);
|
|
2893
2975
|
},
|
|
2894
2976
|
children: [/* @__PURE__ */ Q(Y, {
|
|
2895
|
-
as:
|
|
2977
|
+
as: St,
|
|
2896
2978
|
boxSize: "icon-xs"
|
|
2897
2979
|
}), /* @__PURE__ */ Q(X, {
|
|
2898
2980
|
textStyle: "paragraph/S/regular",
|
|
2899
2981
|
children: f
|
|
2900
2982
|
})]
|
|
2901
2983
|
}),
|
|
2902
|
-
w && i.length > 0 ? /* @__PURE__ */ Q(
|
|
2984
|
+
w && i.length > 0 ? /* @__PURE__ */ Q(Zi, {
|
|
2903
2985
|
label: g,
|
|
2904
2986
|
values: i,
|
|
2905
2987
|
disabled: u || d,
|
|
@@ -2907,7 +2989,7 @@ var { withProvider: Pi, withContext: Fi } = Ue({ recipe: W }), Ii = Pi("div", "r
|
|
|
2907
2989
|
}) : null
|
|
2908
2990
|
]
|
|
2909
2991
|
})]
|
|
2910
|
-
}), /* @__PURE__ */ Q(
|
|
2992
|
+
}), /* @__PURE__ */ Q(Xn, {
|
|
2911
2993
|
open: !!k,
|
|
2912
2994
|
onClose: () => A(null),
|
|
2913
2995
|
onDelete: () => {
|
|
@@ -2918,14 +3000,14 @@ var { withProvider: Pi, withContext: Fi } = Ue({ recipe: W }), Ii = Pi("div", "r
|
|
|
2918
3000
|
buttonText: b
|
|
2919
3001
|
})] });
|
|
2920
3002
|
};
|
|
2921
|
-
function
|
|
3003
|
+
function $i(e) {
|
|
2922
3004
|
return e.isDefault;
|
|
2923
3005
|
}
|
|
2924
3006
|
//#endregion
|
|
2925
3007
|
//#region src/components/tag-editor/tag-editor-save-bar.tsx
|
|
2926
|
-
var
|
|
3008
|
+
var ea = (e) => {
|
|
2927
3009
|
let t = Z(13), { onSave: n, onReset: r, hasChanges: i, isSaving: a, resetLabel: o, saveLabel: s } = e, c = o === void 0 ? "Reset" : o, l = s === void 0 ? "Save" : s, u;
|
|
2928
|
-
t[0] !== i || t[1] !== a || t[2] !== r || t[3] !== c ? (u = i ? /* @__PURE__ */ Q(
|
|
3010
|
+
t[0] !== i || t[1] !== a || t[2] !== r || t[3] !== c ? (u = i ? /* @__PURE__ */ Q(xe, {
|
|
2929
3011
|
size: "sm",
|
|
2930
3012
|
variant: "ghost",
|
|
2931
3013
|
onClick: r,
|
|
@@ -2933,7 +3015,7 @@ var Xi = (e) => {
|
|
|
2933
3015
|
children: c
|
|
2934
3016
|
}) : null, t[0] = i, t[1] = a, t[2] = r, t[3] = c, t[4] = u) : u = t[4];
|
|
2935
3017
|
let d = !i, f;
|
|
2936
|
-
t[5] !== a || t[6] !== n || t[7] !== l || t[8] !== d ? (f = /* @__PURE__ */ Q(
|
|
3018
|
+
t[5] !== a || t[6] !== n || t[7] !== l || t[8] !== d ? (f = /* @__PURE__ */ Q(xe, {
|
|
2937
3019
|
size: "sm",
|
|
2938
3020
|
variant: "primary",
|
|
2939
3021
|
onClick: n,
|
|
@@ -2946,14 +3028,14 @@ var Xi = (e) => {
|
|
|
2946
3028
|
gap: "xs",
|
|
2947
3029
|
children: [u, f]
|
|
2948
3030
|
}), t[10] = u, t[11] = f, t[12] = p) : p = t[12], p;
|
|
2949
|
-
},
|
|
3031
|
+
}, ta = (e, t) => e.sortOrder - t.sortOrder || e.name.localeCompare(t.name), na = (e, t) => e.map(t).sort(ta), ra = (e, t) => e.find((e) => e.id === t.id), ia = (e, t, n, r) => n.size > 0 || t.some((t) => {
|
|
2950
3032
|
if (t.isNew) return !0;
|
|
2951
|
-
let n =
|
|
3033
|
+
let n = ra(e, t);
|
|
2952
3034
|
return !n || r(n, t) || t.sortOrder !== n.sortOrder;
|
|
2953
|
-
}),
|
|
3035
|
+
}), aa = (e) => e instanceof Error ? e.message : e ? String(e) : null, oa = (e) => {
|
|
2954
3036
|
let { errorTitle: t, loadingText: n = "Loading...", resetLabel: r, saveLabel: i, values: a, loadError: o, onSave: s, readOnly: l, toEditorValue: u, valueNeedsUpdate: d, ...f } = e, [p, m] = it([]), [h, g] = it(/* @__PURE__ */ new Set()), [_, v] = it(!1), [y, b] = it(null), x = a ?? [];
|
|
2955
3037
|
nt(() => {
|
|
2956
|
-
a && m(
|
|
3038
|
+
a && m(na(a, u));
|
|
2957
3039
|
}, [a, u]);
|
|
2958
3040
|
let S = async () => {
|
|
2959
3041
|
v(!0), b(null);
|
|
@@ -2968,10 +3050,10 @@ var Xi = (e) => {
|
|
|
2968
3050
|
} finally {
|
|
2969
3051
|
v(!1);
|
|
2970
3052
|
}
|
|
2971
|
-
}, C =
|
|
3053
|
+
}, C = ia(x, p, h, d), w = aa(o) ?? aa(y), T = (e) => {
|
|
2972
3054
|
e.isNew || g(/* @__PURE__ */ new Set([...h, e.id])), m(p.filter((t) => t.id !== e.id));
|
|
2973
3055
|
}, E = () => {
|
|
2974
|
-
m(
|
|
3056
|
+
m(na(x, u)), g(/* @__PURE__ */ new Set()), b(null);
|
|
2975
3057
|
};
|
|
2976
3058
|
return /* @__PURE__ */ $(Re, {
|
|
2977
3059
|
boxSizing: "border-box",
|
|
@@ -2993,7 +3075,7 @@ var Xi = (e) => {
|
|
|
2993
3075
|
textStyle: "paragraph/S/regular",
|
|
2994
3076
|
children: n
|
|
2995
3077
|
})]
|
|
2996
|
-
}) : /* @__PURE__ */ Q(
|
|
3078
|
+
}) : /* @__PURE__ */ Q(Qi, {
|
|
2997
3079
|
...f,
|
|
2998
3080
|
readOnly: l,
|
|
2999
3081
|
values: p,
|
|
@@ -3005,7 +3087,7 @@ var Xi = (e) => {
|
|
|
3005
3087
|
}))) : f.onSetDefault,
|
|
3006
3088
|
hasChanges: C,
|
|
3007
3089
|
isSaving: _,
|
|
3008
|
-
headerActions: l ? void 0 : /* @__PURE__ */ Q(
|
|
3090
|
+
headerActions: l ? void 0 : /* @__PURE__ */ Q(ea, {
|
|
3009
3091
|
hasChanges: C,
|
|
3010
3092
|
isSaving: _,
|
|
3011
3093
|
resetLabel: r,
|
|
@@ -3015,35 +3097,35 @@ var Xi = (e) => {
|
|
|
3015
3097
|
})
|
|
3016
3098
|
})]
|
|
3017
3099
|
});
|
|
3018
|
-
},
|
|
3100
|
+
}, sa = {
|
|
3019
3101
|
sectionOrder: [],
|
|
3020
3102
|
nodeOrderBySection: {},
|
|
3021
3103
|
sectionSlotById: {},
|
|
3022
3104
|
groups: []
|
|
3023
|
-
},
|
|
3105
|
+
}, ca = "pstdio/ui/tree-list-order", la = (e) => `${ca}/${e}`, ua = (e) => {
|
|
3024
3106
|
let t = /* @__PURE__ */ new Set(), n = [];
|
|
3025
3107
|
for (let r of e) t.has(r) || (t.add(r), n.push(r));
|
|
3026
3108
|
return n;
|
|
3027
|
-
},
|
|
3109
|
+
}, da = (e) => ({
|
|
3028
3110
|
sectionOrder: e.sectionOrder,
|
|
3029
3111
|
nodeOrderBySection: e.nodeOrderBySection,
|
|
3030
3112
|
sectionSlotById: e.sectionSlotById,
|
|
3031
3113
|
groups: e.groups
|
|
3032
|
-
}),
|
|
3114
|
+
}), fa = (e) => {
|
|
3033
3115
|
let t = e.trim();
|
|
3034
3116
|
if (!t) throw Error("Enter a group name.");
|
|
3035
3117
|
return t;
|
|
3036
|
-
},
|
|
3037
|
-
...
|
|
3118
|
+
}, pa = (e) => Ht()(Vt((e) => ({
|
|
3119
|
+
...sa,
|
|
3038
3120
|
setSectionOrder: (t) => e((e) => ({
|
|
3039
3121
|
...e,
|
|
3040
|
-
sectionOrder:
|
|
3122
|
+
sectionOrder: ua(t)
|
|
3041
3123
|
})),
|
|
3042
3124
|
setNodeOrder: (t, n) => e((e) => ({
|
|
3043
3125
|
...e,
|
|
3044
3126
|
nodeOrderBySection: {
|
|
3045
3127
|
...e.nodeOrderBySection,
|
|
3046
|
-
[t]:
|
|
3128
|
+
[t]: ua(n)
|
|
3047
3129
|
}
|
|
3048
3130
|
})),
|
|
3049
3131
|
setSectionSlot: (t, n) => e((e) => ({
|
|
@@ -3056,12 +3138,12 @@ var Xi = (e) => {
|
|
|
3056
3138
|
addGroup: (t, n) => e((e) => ({
|
|
3057
3139
|
groups: [...e.groups, {
|
|
3058
3140
|
...t,
|
|
3059
|
-
label:
|
|
3141
|
+
label: fa(t.label)
|
|
3060
3142
|
}],
|
|
3061
|
-
sectionOrder:
|
|
3143
|
+
sectionOrder: ua([...n, t.id])
|
|
3062
3144
|
})),
|
|
3063
3145
|
renameGroup: (t, n) => {
|
|
3064
|
-
let r =
|
|
3146
|
+
let r = fa(n);
|
|
3065
3147
|
e((e) => ({ groups: e.groups.map((e) => e.id === t ? {
|
|
3066
3148
|
...e,
|
|
3067
3149
|
label: r
|
|
@@ -3088,21 +3170,21 @@ var Xi = (e) => {
|
|
|
3088
3170
|
nodeOrderBySection: r
|
|
3089
3171
|
};
|
|
3090
3172
|
}),
|
|
3091
|
-
reset: () => e(
|
|
3173
|
+
reset: () => e(sa)
|
|
3092
3174
|
}), {
|
|
3093
|
-
name:
|
|
3094
|
-
storage:
|
|
3095
|
-
partialize:
|
|
3096
|
-
})),
|
|
3175
|
+
name: la(e.storageKey),
|
|
3176
|
+
storage: F(e.storage),
|
|
3177
|
+
partialize: da
|
|
3178
|
+
})), ma = I((e, t) => pa({
|
|
3097
3179
|
storageKey: e,
|
|
3098
3180
|
storage: t
|
|
3099
|
-
})),
|
|
3100
|
-
let n = Z(3), r =
|
|
3101
|
-
return n[0] !== e || n[1] !== r ? (i =
|
|
3102
|
-
},
|
|
3181
|
+
})), ha = (e, t) => {
|
|
3182
|
+
let n = Z(3), r = ee(), i;
|
|
3183
|
+
return n[0] !== e || n[1] !== r ? (i = ma(e, r), n[0] = e, n[1] = r, n[2] = i) : i = n[2], zt(i, t);
|
|
3184
|
+
}, ga = (e, t) => {
|
|
3103
3185
|
let n = t.filter((e) => e.canReorder !== !1), r = 0, i = e.map((e) => e.canReorder === !1 ? e : n[r++]).filter((e) => !!e);
|
|
3104
3186
|
return i.push(...n.slice(r)), i.every((e, n) => e === t[n]) && i.length === t.length ? t : i;
|
|
3105
|
-
},
|
|
3187
|
+
}, _a = (e, t) => {
|
|
3106
3188
|
if (t.length === 0) return e;
|
|
3107
3189
|
let n = new Map(e.map((e, t) => [e.id, t])), r = /* @__PURE__ */ new Set(), i = [];
|
|
3108
3190
|
for (let a of t) {
|
|
@@ -3118,7 +3200,7 @@ var Xi = (e) => {
|
|
|
3118
3200
|
}
|
|
3119
3201
|
}
|
|
3120
3202
|
return a ? i : e;
|
|
3121
|
-
},
|
|
3203
|
+
}, va = (e, t, n, r = []) => {
|
|
3122
3204
|
let i = new Map(e.flatMap((e) => e.nodes.map((e) => [e.id, e]))), a = r.length ? [...e, ...r.map((e) => ({
|
|
3123
3205
|
...e,
|
|
3124
3206
|
canHide: !0,
|
|
@@ -3131,7 +3213,7 @@ var Xi = (e) => {
|
|
|
3131
3213
|
moveScope: n.moveScope,
|
|
3132
3214
|
nodes: []
|
|
3133
3215
|
}] : [];
|
|
3134
|
-
}), s = o.length > 0 ? [...a, ...o] : a, c = s !== e, l =
|
|
3216
|
+
}), s = o.length > 0 ? [...a, ...o] : a, c = s !== e, l = ga(s, _a(s, t));
|
|
3135
3217
|
l !== s && (c = !0);
|
|
3136
3218
|
let u = new Set(Object.entries(n).filter(([e]) => s.some((t) => t.id === e)).flatMap(([, e]) => e.filter((e) => i.has(e) && i.get(e)?.canReorder !== !1))), d = [];
|
|
3137
3219
|
for (let e of l) {
|
|
@@ -3147,17 +3229,17 @@ var Xi = (e) => {
|
|
|
3147
3229
|
let r = (t ?? []).flatMap((e) => {
|
|
3148
3230
|
let t = i.get(e);
|
|
3149
3231
|
return t && t.canReorder !== !1 ? [t] : [];
|
|
3150
|
-
}), a = e.nodes.filter((e) => !u.has(e.id)), o =
|
|
3232
|
+
}), a = e.nodes.filter((e) => !u.has(e.id)), o = ga(e.nodes, [...r, ...a]);
|
|
3151
3233
|
o.length !== e.nodes.length || o.some((t, n) => t !== e.nodes[n]) ? (c = !0, d.push({
|
|
3152
3234
|
...e,
|
|
3153
3235
|
nodes: o
|
|
3154
3236
|
})) : d.push(e);
|
|
3155
3237
|
}
|
|
3156
3238
|
return c ? d : e;
|
|
3157
|
-
},
|
|
3239
|
+
}, ya = {
|
|
3158
3240
|
sectionOverrides: {},
|
|
3159
3241
|
nodeOverrides: {}
|
|
3160
|
-
},
|
|
3242
|
+
}, ba = "pstdio/ui/tree-list-visibility", xa = (e) => `${ba}/${e}`, Sa = (e, t) => e ?? (t ? "hidden" : "shown"), Ca = (e) => e === "hidden" ? "shown" : "hidden", wa = (e, t, n) => {
|
|
3161
3243
|
if (n === void 0) {
|
|
3162
3244
|
if (!(t in e)) return e;
|
|
3163
3245
|
let { [t]: n, ...r } = e;
|
|
@@ -3167,81 +3249,81 @@ var Xi = (e) => {
|
|
|
3167
3249
|
...e,
|
|
3168
3250
|
[t]: n
|
|
3169
3251
|
};
|
|
3170
|
-
},
|
|
3252
|
+
}, Ta = (e, t, n) => wa(e, t, Ca(Sa(e[t], n))), Ea = (e) => ({
|
|
3171
3253
|
sectionOverrides: e.sectionOverrides,
|
|
3172
3254
|
nodeOverrides: e.nodeOverrides
|
|
3173
|
-
}),
|
|
3174
|
-
...
|
|
3255
|
+
}), Da = (e) => Ht()(Vt((e) => ({
|
|
3256
|
+
...ya,
|
|
3175
3257
|
setSection: (t, n) => e((e) => ({
|
|
3176
3258
|
...e,
|
|
3177
|
-
sectionOverrides:
|
|
3259
|
+
sectionOverrides: wa(e.sectionOverrides, t, n)
|
|
3178
3260
|
})),
|
|
3179
3261
|
setNode: (t, n) => e((e) => ({
|
|
3180
3262
|
...e,
|
|
3181
|
-
nodeOverrides:
|
|
3263
|
+
nodeOverrides: wa(e.nodeOverrides, t, n)
|
|
3182
3264
|
})),
|
|
3183
3265
|
toggleSection: (t, n) => e((e) => ({
|
|
3184
3266
|
...e,
|
|
3185
|
-
sectionOverrides:
|
|
3267
|
+
sectionOverrides: Ta(e.sectionOverrides, t, n)
|
|
3186
3268
|
})),
|
|
3187
3269
|
toggleNode: (t, n) => e((e) => ({
|
|
3188
3270
|
...e,
|
|
3189
|
-
nodeOverrides:
|
|
3271
|
+
nodeOverrides: Ta(e.nodeOverrides, t, n)
|
|
3190
3272
|
})),
|
|
3191
3273
|
clearSection: (t) => e((e) => ({
|
|
3192
3274
|
...e,
|
|
3193
|
-
sectionOverrides:
|
|
3275
|
+
sectionOverrides: wa(e.sectionOverrides, t, void 0)
|
|
3194
3276
|
})),
|
|
3195
3277
|
clearNode: (t) => e((e) => ({
|
|
3196
3278
|
...e,
|
|
3197
|
-
nodeOverrides:
|
|
3279
|
+
nodeOverrides: wa(e.nodeOverrides, t, void 0)
|
|
3198
3280
|
})),
|
|
3199
|
-
reset: () => e(
|
|
3281
|
+
reset: () => e(ya)
|
|
3200
3282
|
}), {
|
|
3201
|
-
name:
|
|
3202
|
-
storage:
|
|
3203
|
-
partialize:
|
|
3204
|
-
})),
|
|
3283
|
+
name: xa(e.storageKey),
|
|
3284
|
+
storage: F(e.storage),
|
|
3285
|
+
partialize: Ea
|
|
3286
|
+
})), Oa = I((e, t) => Da({
|
|
3205
3287
|
storageKey: e,
|
|
3206
3288
|
storage: t
|
|
3207
|
-
})),
|
|
3208
|
-
let n = Z(3), r =
|
|
3209
|
-
return n[0] !== e || n[1] !== r ? (i =
|
|
3210
|
-
},
|
|
3289
|
+
})), ka = (e, t) => {
|
|
3290
|
+
let n = Z(3), r = ee(), i;
|
|
3291
|
+
return n[0] !== e || n[1] !== r ? (i = Oa(e, r), n[0] = e, n[1] = r, n[2] = i) : i = n[2], zt(i, t);
|
|
3292
|
+
}, Aa = [], ja = (e, t) => typeof e == "string" && t.some((t) => t.id === e), Ma = (e) => {
|
|
3211
3293
|
let t = e.toLowerCase().split("."), n = [];
|
|
3212
3294
|
for (let e = 1; e < t.length; e += 1) n.push(t.slice(e).join("."));
|
|
3213
3295
|
return n;
|
|
3214
|
-
},
|
|
3296
|
+
}, Na = (e, t, n) => {
|
|
3215
3297
|
if (n) return e.defaults.folder;
|
|
3216
3298
|
let r = e.fileNames[t.toLowerCase()];
|
|
3217
3299
|
if (r) return r;
|
|
3218
|
-
for (let n of
|
|
3300
|
+
for (let n of Ma(t)) {
|
|
3219
3301
|
let t = e.fileExtensions[n];
|
|
3220
3302
|
if (t) return t;
|
|
3221
3303
|
}
|
|
3222
3304
|
return e.defaults.file;
|
|
3223
|
-
},
|
|
3305
|
+
}, Pa = (e, t) => {
|
|
3224
3306
|
if (t.fontId) {
|
|
3225
3307
|
let n = e.fonts.find((n) => n.fontFamily === `${e.id}-${t.fontId}`);
|
|
3226
3308
|
if (n) return n.fontFamily;
|
|
3227
3309
|
}
|
|
3228
3310
|
return e.fonts[0]?.fontFamily;
|
|
3229
|
-
},
|
|
3311
|
+
}, Fa = (e) => {
|
|
3230
3312
|
let t = /^\\([0-9a-fA-F]+)$/.exec(e);
|
|
3231
3313
|
return t ? String.fromCodePoint(Number.parseInt(t[1], 16)) : e;
|
|
3232
|
-
},
|
|
3314
|
+
}, Ia = (e, t, n = !1) => {
|
|
3233
3315
|
if (!e) return;
|
|
3234
|
-
let r =
|
|
3316
|
+
let r = Na(e, t, n);
|
|
3235
3317
|
if (!r) return;
|
|
3236
3318
|
let i = e.definitions[r];
|
|
3237
3319
|
if (!i?.fontCharacter) return;
|
|
3238
|
-
let a =
|
|
3320
|
+
let a = Pa(e, i);
|
|
3239
3321
|
if (a) return {
|
|
3240
3322
|
fontFamily: a,
|
|
3241
|
-
fontCharacter:
|
|
3323
|
+
fontCharacter: Fa(i.fontCharacter),
|
|
3242
3324
|
fontColor: i.fontColor
|
|
3243
3325
|
};
|
|
3244
|
-
},
|
|
3326
|
+
}, La = "data-pstdio-file-icon-fonts", Ra = (e) => {
|
|
3245
3327
|
let t = e.src.map((e) => `url("${e.url}")${e.format ? ` format("${e.format}")` : ""}`).join(", ");
|
|
3246
3328
|
return [
|
|
3247
3329
|
"@font-face {",
|
|
@@ -3251,27 +3333,27 @@ var Xi = (e) => {
|
|
|
3251
3333
|
` font-style: ${e.style ?? "normal"};`,
|
|
3252
3334
|
"}"
|
|
3253
3335
|
].join("\n");
|
|
3254
|
-
},
|
|
3336
|
+
}, za = (e, t) => {
|
|
3255
3337
|
if (typeof document > "u") return;
|
|
3256
|
-
let n = document.querySelector(`style[${
|
|
3257
|
-
n || (n = document.createElement("style"), n.setAttribute(
|
|
3338
|
+
let n = document.querySelector(`style[${La}]`);
|
|
3339
|
+
n || (n = document.createElement("style"), n.setAttribute(La, ""), document.head.appendChild(n));
|
|
3258
3340
|
let r = t.find((t) => t.id === e);
|
|
3259
|
-
n.textContent = (r?.fonts ?? []).map(
|
|
3260
|
-
},
|
|
3261
|
-
if (typeof window > "u") return
|
|
3262
|
-
let t =
|
|
3263
|
-
return
|
|
3264
|
-
},
|
|
3265
|
-
let t = Z(18), { children: n, themePreferences: r } = e, i = r === void 0 ?
|
|
3266
|
-
t[0] === i ? a = t[1] : (a = () =>
|
|
3341
|
+
n.textContent = (r?.fonts ?? []).map(Ra).join("\n\n");
|
|
3342
|
+
}, Ba = "file-icon-theme-preference", Va = (e) => e.find((e) => e.id.endsWith(".seti"))?.id ?? e[0]?.id ?? null, Ha = $e(null), Ua = (e) => {
|
|
3343
|
+
if (typeof window > "u") return Va(e);
|
|
3344
|
+
let t = V().getItem(Ba);
|
|
3345
|
+
return ja(t, e) ? t : Va(e);
|
|
3346
|
+
}, Wa = (e) => {
|
|
3347
|
+
let t = Z(18), { children: n, themePreferences: r } = e, i = r === void 0 ? Aa : r, a;
|
|
3348
|
+
t[0] === i ? a = t[1] : (a = () => Ua(i), t[0] = i, t[1] = a);
|
|
3267
3349
|
let [o, s] = it(a), c, l;
|
|
3268
3350
|
t[2] !== o || t[3] !== i ? (c = () => {
|
|
3269
|
-
let e =
|
|
3351
|
+
let e = ja(o, i) ? o : Va(i);
|
|
3270
3352
|
if (e !== o) {
|
|
3271
3353
|
s(e);
|
|
3272
3354
|
return;
|
|
3273
3355
|
}
|
|
3274
|
-
|
|
3356
|
+
za(e, i), typeof window < "u" && e && V().setItem(Ba, e);
|
|
3275
3357
|
}, l = [o, i], t[2] = o, t[3] = i, t[4] = c, t[5] = l) : (c = t[4], l = t[5]), nt(c, l);
|
|
3276
3358
|
let u;
|
|
3277
3359
|
if (t[6] !== o || t[7] !== i) {
|
|
@@ -3286,16 +3368,16 @@ var Xi = (e) => {
|
|
|
3286
3368
|
setFileIconThemePreference: s
|
|
3287
3369
|
}, t[11] = d, t[12] = o, t[13] = i, t[14] = f) : f = t[14];
|
|
3288
3370
|
let p;
|
|
3289
|
-
return t[15] !== n || t[16] !== f ? (p = /* @__PURE__ */ Q(
|
|
3371
|
+
return t[15] !== n || t[16] !== f ? (p = /* @__PURE__ */ Q(Ha, {
|
|
3290
3372
|
value: f,
|
|
3291
3373
|
children: n
|
|
3292
3374
|
}), t[15] = n, t[16] = f, t[17] = p) : p = t[17], p;
|
|
3293
|
-
},
|
|
3294
|
-
let e = tt(
|
|
3375
|
+
}, Ga = () => {
|
|
3376
|
+
let e = tt(Ha);
|
|
3295
3377
|
if (!e) throw Error("useFileIconThemePreference must be used within a FileIconThemePreferenceProvider");
|
|
3296
3378
|
return e;
|
|
3297
|
-
},
|
|
3298
|
-
let { isDirectory: n = !1, theme: r, size: i = 16 } = t, a =
|
|
3379
|
+
}, Ka = (e, t = {}) => {
|
|
3380
|
+
let { isDirectory: n = !1, theme: r, size: i = 16 } = t, a = Ia(r, e, n);
|
|
3299
3381
|
if (a) {
|
|
3300
3382
|
let e = {
|
|
3301
3383
|
fontFamily: `"${a.fontFamily}"`,
|
|
@@ -3315,6 +3397,6 @@ var Xi = (e) => {
|
|
|
3315
3397
|
return /* @__PURE__ */ Q(o, { size: i });
|
|
3316
3398
|
};
|
|
3317
3399
|
//#endregion
|
|
3318
|
-
export {
|
|
3400
|
+
export { Gt as Activity, r as ActivityAvatar, s as ActivityComment, Wt as ActivityComposer, a as ActivityEvent, o as ActivityFeed, n as ActivityHeader, t as ActivityReply, e as ActivityRoot, i as ActivityTimeline, c as AlertMessage, Gn as AttachedMenu, qn as AttachedPanel, E as AttachmentChip, sr as Breadcrumb, Jn as BubbleButton, Yn as BubblePanel, Ce as ChakraProvider, P as Checkbox, w as Chip, lr as ContentPlaceholder, ur as ContentPlaceholderLabel, dr as CopyButton, Kt as DEFAULT_PALETTE_ASSET_LIMIT, Xn as DeleteConfirmationModal, R as DropIndicator, z as EmptyState, fr as ErrorBoundary, Wa as FileIconThemePreferenceProvider, $n as FolderPicker, er as FolderPickerDialog, p as Header, Tn as HorizontalMenuStack, L as HostStorageProvider, yr as IconColorPicker, Sr as IntegrationCard, En as ItemSection, h as ListRow, Hn as NotificationCenter, kn as PANEL_HEADER_CONTROL_SIZE, On as PANEL_HEADER_HEIGHT, An as PANEL_HEADER_TAB_SIZE, dn as Palette, Sn as PaletteShortcut, ae as Radio, ie as RadioGroup, y as ResizableSplitLayout, d as ResourceActionMenu, S as ResourceBadge, f as ResourceContextMenu, g as ResourceMenuItems, u as ScrollArea, ln as SearchModalContent, m as SearchableMenu, Or as SegmentedControl, A as SessionIndicator, Yr as Sidenav, br as SimpleCard, xr as SimpleCardBody, T as Slider, C as Switch, Qi as TagEditor, Ui as TagEditorHeading, ea as TagEditorSaveBar, oa as TagSettingsPanel, hr as TagSwatch, ge as ThemePreferenceProvider, Ar as Toaster, l as Tooltip, b as TreeList, v as TreeListDragProvider, Pi as WindowTabs, Hi as WindowTitleBar, N as WorkspaceBadge, za as applyFileIconThemePreference, ue as applyThemePreference, va as applyTreeListOrder, Ti as buildTabVisibilityMenuActions, Ci as buildTreeVisibilityMenuActions, B as createGlyphIcon, se as createMonacoThemeFromVsCodeTheme, W as createThemePreferenceFromVsCodeTheme, Aa as defaultFileIconThemePreferences, ce as defaultThemePreferences, Qt as filterPaletteEntries, vi as filterVisibleNodes, yi as filterVisibleSections, wi as filterVisibleTabs, x as getFileTypeIcon, re as getIconComponent, fe as getInitialThemePreference, di as getTabVisibilityStore, pe as getThemePreferenceClassName, he as getThemePreferenceClassNames, le as getThemePreferenceMode, ma as getTreeListOrderStore, Oa as getTreeListVisibilityStore, j as handleDialogAcceptShortcut, D as installPrismGlobal, ja as isFileIconThemePreference, de as isThemePreference, te as optionColors, ne as optionIcons, oe as psTheme, Ka as resolveFileIconElement, Ia as resolveFileIconGlyph, _e as resolveIconComponent, M as resolveSessionIndicatorColor, k as resolveSessionIndicatorIcon, mi as resolveVisibility, O as sessionCompletionStatuses, kr as toaster, Ga as useFileIconThemePreference, Vr as useSidenavStore, fi as useTabVisibilityStore, me as useThemePreference, ha as useTreeListOrderStore, ka as useTreeListVisibilityStore };
|
|
3319
3401
|
|
|
3320
3402
|
//# sourceMappingURL=index.js.map
|