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