ode-explorer 1.4.19-develop.202411061500 → 1.4.19-develop.202411071619

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/lib/index2.js CHANGED
@@ -1,21 +1,21 @@
1
- import { jsxs as N, Fragment as G, jsx as c } from "react/jsx-runtime";
2
- import { useEffect as $, Suspense as M, lazy as Q, useState as de, useRef as be, Fragment as we } from "react";
3
- import { useSensor as se, PointerSensor as xe, TouchSensor as Te, KeyboardSensor as Ce, useSensors as Fe, DndContext as Re } from "@dnd-kit/core";
4
- import { snapCenterToCursor as Ne } from "@dnd-kit/modifiers";
5
- import { findNodeById as J, wrapTreeNode as Ee, findParentNode as Pe, useToast as L, moveNode as Ae, deleteNode as Qe, useUser as ue, useShareMutation as qe, useUpdateMutation as Oe, useOdeClient as v, addNode as ke, updateNode as Ue, getAncestors as ae, LoadingScreen as U, FormControl as Me, Input as Le, SearchButton as ve, Dropdown as j, useToggle as Be, useScrollToTop as Ke, TreeView as $e, Button as _e, IconButton as ze, useXitiTrackPageLoad as je, isActionAvailable as ce, AppHeader as Ve, Breadcrumb as We, Grid as re } from "@edifice-ui/react";
6
- import { odeServices as P, FOLDER as R, SORT_ORDER as He, ResourceService as he } from "edifice-ts-client";
7
- import { t as E } from "i18next";
8
- import { createStore as Ge, useStore as Je } from "zustand";
9
- import { useQuery as Xe, queryOptions as Ye, useQueryClient as k, useMutation as B, useInfiniteQuery as Ze } from "@tanstack/react-query";
1
+ import { jsxs as E, Fragment as G, jsx as c } from "react/jsx-runtime";
2
+ import { useEffect as $, Suspense as M, lazy as q, useState as le, useRef as Se, Fragment as be } from "react";
3
+ import { useSensor as oe, PointerSensor as we, KeyboardSensor as xe, useSensors as Te, DndContext as Ce } from "@dnd-kit/core";
4
+ import { snapCenterToCursor as Fe } from "@dnd-kit/modifiers";
5
+ import { findNodeById as J, wrapTreeNode as Re, findParentNode as Ne, useToast as L, moveNode as Ee, deleteNode as Pe, useUser as de, useShareMutation as Ae, useUpdateMutation as Qe, useOdeClient as v, addNode as qe, updateNode as Oe, getAncestors as ne, LoadingScreen as U, FormControl as ke, Input as Ue, SearchButton as Me, Dropdown as j, useToggle as Le, useScrollToTop as ve, TreeView as Be, Button as Ke, IconButton as $e, useXitiTrackPageLoad as _e, isActionAvailable as ae, AppHeader as ze, Breadcrumb as je, Grid as te } from "@edifice-ui/react";
6
+ import { odeServices as A, FOLDER as N, SORT_ORDER as Ve, ResourceService as ue } from "edifice-ts-client";
7
+ import { t as P } from "i18next";
8
+ import { createStore as We, useStore as He } from "zustand";
9
+ import { useQuery as Ge, queryOptions as Je, useQueryClient as k, useMutation as B, useInfiniteQuery as Xe } from "@tanstack/react-query";
10
10
  import { useTranslation as _ } from "react-i18next";
11
- import { Filter as et, Delete as tt, Plus as st, ArrowLeft as rt } from "@edifice-ui/icons";
12
- const pe = async (e) => {
13
- const t = await P.resource(e.application).searchContext(e);
11
+ import { Filter as Ye, Delete as Ze, Plus as et, ArrowLeft as tt } from "@edifice-ui/icons";
12
+ const he = async (e) => {
13
+ const t = await A.resource(e.application).searchContext(e);
14
14
  return {
15
15
  ...t,
16
16
  folders: t.folders.filter((s) => !s.trashed)
17
17
  };
18
- }, ot = async ({
18
+ }, st = async ({
19
19
  searchParams: e,
20
20
  name: t,
21
21
  parentId: s
@@ -26,8 +26,8 @@ const pe = async (e) => {
26
26
  application: e.application,
27
27
  type: e.types[0]
28
28
  };
29
- return await P.resource(e.application).createFolder(r);
30
- }, nt = async ({
29
+ return await A.resource(e.application).createFolder(r);
30
+ }, rt = async ({
31
31
  folderId: e,
32
32
  searchParams: t,
33
33
  parentId: s,
@@ -40,8 +40,8 @@ const pe = async (e) => {
40
40
  application: t.application,
41
41
  type: t.types[0]
42
42
  };
43
- return await P.resource(t.application).updateFolder(o);
44
- }, at = async ({
43
+ return await A.resource(t.application).updateFolder(o);
44
+ }, ot = async ({
45
45
  searchParams: e,
46
46
  resourceIds: t,
47
47
  useAssetIds: s,
@@ -53,8 +53,8 @@ const pe = async (e) => {
53
53
  resourceIds: t,
54
54
  folderIds: r
55
55
  };
56
- return await P.resource(e.application).trashAll(o, s);
57
- }, ct = async ({
56
+ return await A.resource(e.application).trashAll(o, s);
57
+ }, nt = async ({
58
58
  searchParams: e,
59
59
  resourceIds: t,
60
60
  useAssetIds: s,
@@ -66,8 +66,8 @@ const pe = async (e) => {
66
66
  resourceIds: t,
67
67
  folderIds: r
68
68
  };
69
- return await P.resource(e.application).deleteAll(o, s);
70
- }, it = async ({
69
+ return await A.resource(e.application).deleteAll(o, s);
70
+ }, at = async ({
71
71
  searchParams: e,
72
72
  resourceIds: t,
73
73
  folderIds: s,
@@ -79,11 +79,11 @@ const pe = async (e) => {
79
79
  resourceIds: t,
80
80
  folderIds: s
81
81
  };
82
- return await P.resource(e.application).restoreAll(o, r);
83
- }, lt = async (e, t) => await P.resource(e.application).copy({
82
+ return await A.resource(e.application).restoreAll(o, r);
83
+ }, ct = async (e, t) => await A.resource(e.application).copy({
84
84
  application: e.application,
85
85
  resourceId: t
86
- }), fe = async ({
86
+ }), pe = async ({
87
87
  searchParams: e,
88
88
  resourceIds: t,
89
89
  folderId: s,
@@ -96,59 +96,59 @@ const pe = async (e) => {
96
96
  resourceIds: t,
97
97
  folderIds: r
98
98
  };
99
- return await P.resource(e.application).moveToFolder(a, o);
100
- }, dt = async (e) => await P.rights().sessionHasWorkflowRights(e), ut = ({
99
+ return await A.resource(e.application).moveToFolder(a, o);
100
+ }, it = async (e) => await A.rights().sessionHasWorkflowRights(e), lt = ({
101
101
  searchParams: e,
102
102
  assetId: t
103
103
  }) => {
104
- const s = P.resource(e.application).getViewUrl(t);
104
+ const s = A.resource(e.application).getViewUrl(t);
105
105
  window.open(s, "_self");
106
- }, ht = ({
106
+ }, dt = ({
107
107
  searchParams: e,
108
108
  params: t
109
- }) => P.resource(e.application).create(t), pt = ({
109
+ }) => A.resource(e.application).create(t), ut = ({
110
110
  searchParams: e,
111
111
  assetId: t
112
112
  }) => {
113
- const s = P.resource(e.application).getPrintUrl(t);
113
+ const s = A.resource(e.application).getPrintUrl(t);
114
114
  return window.open(s, "_blank");
115
- }, ds = ({
115
+ }, is = ({
116
116
  searchParams: e,
117
117
  folderId: t
118
118
  }) => {
119
- const s = P.resource(e.application).getFormUrl(t);
119
+ const s = A.resource(e.application).getFormUrl(t);
120
120
  return window.open(s, "_self");
121
- }, us = ({
121
+ }, ls = ({
122
122
  searchParams: e,
123
123
  assetId: t
124
124
  }) => {
125
- const s = P.resource(e.application).getEditUrl(t);
125
+ const s = A.resource(e.application).getEditUrl(t);
126
126
  return window.open(s, "_self");
127
- }, hs = ({
127
+ }, ds = ({
128
128
  searchParams: e,
129
129
  assetId: t
130
130
  }) => {
131
- const s = P.resource(e.application).getExportUrl(t);
131
+ const s = A.resource(e.application).getExportUrl(t);
132
132
  return window.open(s, "_self");
133
- }, ge = {
134
- id: R.DEFAULT,
135
- name: E("explorer.filters.mine"),
133
+ }, fe = {
134
+ id: N.DEFAULT,
135
+ name: P("explorer.filters.mine"),
136
136
  section: !0,
137
137
  children: []
138
- }, ft = {
138
+ }, ht = {
139
139
  config: void 0,
140
140
  searchConfig: {
141
141
  minLength: 1
142
142
  },
143
143
  searchParams: {
144
144
  filters: {
145
- folder: R.DEFAULT,
145
+ folder: N.DEFAULT,
146
146
  owner: void 0,
147
147
  shared: void 0,
148
148
  public: void 0
149
149
  },
150
150
  orders: {
151
- updatedAt: He.DESC
151
+ updatedAt: Ve.DESC
152
152
  },
153
153
  application: "",
154
154
  types: [],
@@ -159,7 +159,7 @@ const pe = async (e) => {
159
159
  },
160
160
  trashed: !1
161
161
  },
162
- treeData: ge,
162
+ treeData: fe,
163
163
  selectedNodeId: "default",
164
164
  currentFolder: {
165
165
  id: "default"
@@ -181,8 +181,8 @@ const pe = async (e) => {
181
181
  },
182
182
  resourceActionDisable: !1,
183
183
  status: void 0
184
- }, gt = Ge()((e, t) => ({
185
- ...ft,
184
+ }, pt = We()((e, t) => ({
185
+ ...ht,
186
186
  actions: {
187
187
  setConfig: (s) => e({
188
188
  config: s
@@ -277,7 +277,7 @@ const pe = async (e) => {
277
277
  const {
278
278
  searchParams: r
279
279
  } = t();
280
- ut({
280
+ lt({
281
281
  searchParams: r,
282
282
  assetId: s.assetId
283
283
  });
@@ -295,7 +295,7 @@ const pe = async (e) => {
295
295
  if (r.length !== 1)
296
296
  throw new Error("Cannot open more than 1 resource");
297
297
  const a = r.find((n) => n.id === o[0]);
298
- pt({
298
+ ut({
299
299
  searchParams: s,
300
300
  assetId: a.assetId
301
301
  });
@@ -327,7 +327,7 @@ const pe = async (e) => {
327
327
  ...a.filters,
328
328
  folder: s
329
329
  },
330
- trashed: s === R.BIN
330
+ trashed: s === N.BIN
331
331
  }
332
332
  })));
333
333
  },
@@ -343,7 +343,7 @@ const pe = async (e) => {
343
343
  folderId: a,
344
344
  trashed: !1
345
345
  }],
346
- queryFn: async () => await pe({
346
+ queryFn: async () => await he({
347
347
  ...t().searchParams,
348
348
  filters: {
349
349
  ...t().searchParams.filters,
@@ -351,7 +351,7 @@ const pe = async (e) => {
351
351
  }
352
352
  })
353
353
  });
354
- t().actions.setTreeData(Ee(t().treeData, n == null ? void 0 : n.folders, a || R.DEFAULT));
354
+ t().actions.setTreeData(Re(t().treeData, n == null ? void 0 : n.folders, a || N.DEFAULT));
355
355
  },
356
356
  selectTreeItem: (s, r) => {
357
357
  const {
@@ -382,13 +382,13 @@ const pe = async (e) => {
382
382
  openFolder: a
383
383
  } = t().actions;
384
384
  if (o.search && a({
385
- folder: ge,
386
- folderId: R.DEFAULT
385
+ folder: fe,
386
+ folderId: N.DEFAULT
387
387
  }), !s) return;
388
- const n = Pe(r, s);
388
+ const n = Ne(r, s);
389
389
  a({
390
390
  folder: n,
391
- folderId: (n == null ? void 0 : n.id) || R.DEFAULT
391
+ folderId: (n == null ? void 0 : n.id) || N.DEFAULT
392
392
  });
393
393
  },
394
394
  goToTrash: () => {
@@ -403,28 +403,28 @@ const pe = async (e) => {
403
403
  ...s.searchParams,
404
404
  search: void 0,
405
405
  filters: {
406
- folder: R.BIN
406
+ folder: N.BIN
407
407
  },
408
408
  trashed: !0
409
409
  },
410
410
  currentFolder: {
411
- id: R.BIN
411
+ id: N.BIN
412
412
  }
413
413
  }));
414
414
  }
415
415
  }
416
416
  }));
417
417
  function T(e) {
418
- return Je(gt, e);
418
+ return He(pt, e);
419
419
  }
420
- const mt = (e) => e.treeData, yt = (e) => e.actions, V = () => T(mt), F = () => T(yt), A = () => T((e) => e.searchParams), oe = () => T((e) => e.selectedNodeId), ps = () => T((e) => e.selectedFolders), fs = () => T((e) => e.selectedResources), It = () => T((e) => e.searchConfig), X = () => T((e) => e.folderIds), Y = () => T((e) => e.resourceIds), Z = () => T((e) => e.selectedResources.map((t) => t.assetId)), ee = () => T((e) => e.selectedResources.filter((t) => t.assetId === t.id)), W = () => T((e) => e.currentFolder), ne = () => {
420
+ const ft = (e) => e.treeData, gt = (e) => e.actions, V = () => T(ft), F = () => T(gt), Q = () => T((e) => e.searchParams), se = () => T((e) => e.selectedNodeId), us = () => T((e) => e.selectedFolders), hs = () => T((e) => e.selectedResources), mt = () => T((e) => e.searchConfig), X = () => T((e) => e.folderIds), Y = () => T((e) => e.resourceIds), Z = () => T((e) => e.selectedResources.map((t) => t.assetId)), ee = () => T((e) => e.selectedResources.filter((t) => t.assetId === t.id)), W = () => T((e) => e.currentFolder), re = () => {
421
421
  const e = W();
422
- return (e == null ? void 0 : e.id) === R.BIN;
423
- }, Dt = () => T((e) => e.resourceIsTrash), gs = () => T((e) => e.resourceOrFolderIsDraggable), St = () => T((e) => e.elementDragOver), bt = () => T((e) => e.resourceActionDisable), wt = () => {
422
+ return (e == null ? void 0 : e.id) === N.BIN;
423
+ }, yt = () => T((e) => e.resourceIsTrash), ps = () => T((e) => e.resourceOrFolderIsDraggable), It = () => T((e) => e.elementDragOver), Dt = () => T((e) => e.resourceActionDisable), St = () => {
424
424
  const e = W();
425
425
  return (e == null ? void 0 : e.id) === "default";
426
- }, xt = () => T((e) => e.status), Tt = () => {
427
- const e = bt(), {
426
+ }, bt = () => T((e) => e.status), wt = () => {
427
+ const e = Dt(), {
428
428
  clearSelectedIds: t,
429
429
  setResourceActionDisable: s,
430
430
  clearSelectedItems: r
@@ -435,8 +435,8 @@ const mt = (e) => e.treeData, yt = (e) => e.actions, V = () => T(mt), F = () =>
435
435
  t(), r(), s(!1);
436
436
  }
437
437
  };
438
- }, Ct = () => {
439
- const e = Dt(), {
438
+ }, xt = () => {
439
+ const e = yt(), {
440
440
  clearSelectedIds: t,
441
441
  setResourceIsTrash: s,
442
442
  clearSelectedItems: r
@@ -447,8 +447,8 @@ const mt = (e) => e.treeData, yt = (e) => e.actions, V = () => T(mt), F = () =>
447
447
  t(), r(), s(!1);
448
448
  }
449
449
  };
450
- }, Ft = 175, Rt = 10, me = "blog", ye = "blog";
451
- class Ie extends he {
450
+ }, Tt = 175, Ct = 10, ge = "blog", me = "blog";
451
+ class ye extends ue {
452
452
  getEditUrl() {
453
453
  throw new Error("Method not implemented.");
454
454
  }
@@ -484,10 +484,10 @@ class Ie extends he {
484
484
  };
485
485
  }
486
486
  getResourceType() {
487
- return ye;
487
+ return me;
488
488
  }
489
489
  getApplication() {
490
- return me;
490
+ return ge;
491
491
  }
492
492
  getFormUrl(t) {
493
493
  return t ? `/blog?folderid=${t}#/edit/new` : "/blog#/edit/new";
@@ -499,13 +499,13 @@ class Ie extends he {
499
499
  return `/blog/print/${t}`;
500
500
  }
501
501
  }
502
- he.register({
503
- application: me,
504
- resourceType: ye
505
- }, (e) => new Ie(e));
502
+ ue.register({
503
+ application: ge,
504
+ resourceType: me
505
+ }, (e) => new ye(e));
506
506
  const K = document.querySelector("[data-explorer-config]");
507
- let ie;
508
- function ms() {
507
+ let ce;
508
+ function fs() {
509
509
  var e;
510
510
  if ((e = K == null ? void 0 : K.dataset) != null && e.explorerConfig) {
511
511
  const {
@@ -513,22 +513,22 @@ function ms() {
513
513
  } = K.dataset;
514
514
  try {
515
515
  const s = JSON.parse(t);
516
- ie = {
516
+ ce = {
517
517
  ...s,
518
- service: Ie,
518
+ service: ye,
519
519
  enableOnboarding: s.enableOnboarding !== void 0 ? s.enableOnboarding : !0
520
520
  };
521
521
  } catch (s) {
522
522
  console.error("[Explorer Config] could not parse app params from root data attributes:", K == null ? void 0 : K.dataset, s);
523
523
  }
524
524
  }
525
- return ie;
525
+ return ce;
526
526
  }
527
- const Nt = (e, t) => {
527
+ const Ft = (e, t) => {
528
528
  const s = e.map((o) => o.workflow), r = new Set(s);
529
- return Ye({
529
+ return Je({
530
530
  queryKey: [...r],
531
- queryFn: () => dt([...r]),
531
+ queryFn: () => it([...r]),
532
532
  select: (o) => e.filter((a) => o[a.workflow]).map((a) => ({
533
533
  ...a,
534
534
  available: !0
@@ -536,11 +536,11 @@ const Nt = (e, t) => {
536
536
  staleTime: 1 / 0,
537
537
  enabled: !!t
538
538
  });
539
- }, Et = (e) => {
539
+ }, Rt = (e) => {
540
540
  const t = T((s) => s.config);
541
- return Xe(Nt(e, t));
542
- }, Pt = () => {
543
- const e = T((n) => n.config), t = A(), {
541
+ return Ge(Ft(e, t));
542
+ }, Nt = () => {
543
+ const e = T((n) => n.config), t = Q(), {
544
544
  filters: s,
545
545
  trashed: r,
546
546
  search: o
@@ -550,11 +550,11 @@ const Nt = (e, t) => {
550
550
  trashed: r,
551
551
  search: o
552
552
  }];
553
- return Ze({
553
+ return Xe({
554
554
  queryKey: a,
555
555
  queryFn: async ({
556
556
  pageParam: n
557
- }) => await pe({
557
+ }) => await he({
558
558
  ...t,
559
559
  application: e == null ? void 0 : e.app,
560
560
  types: e == null ? void 0 : e.types,
@@ -569,103 +569,103 @@ const Nt = (e, t) => {
569
569
  retry: !1,
570
570
  getNextPageParam: (n) => n.pagination.startIdx + n.pagination.pageSize
571
571
  });
572
- }, ys = () => {
573
- const e = L(), t = k(), s = A(), r = V(), o = X(), a = Z(), n = Y(), u = ee().length > 0, p = u ? a : n, {
574
- clearSelectedItems: l,
575
- clearSelectedIds: d,
572
+ }, gs = () => {
573
+ const e = L(), t = k(), s = Q(), r = V(), o = X(), a = Z(), n = Y(), u = ee().length > 0, p = u ? a : n, {
574
+ clearSelectedItems: i,
575
+ clearSelectedIds: l,
576
576
  setTreeData: h,
577
- setSearchParams: i
577
+ setSearchParams: d
578
578
  } = F(), {
579
579
  filters: f,
580
580
  trashed: m
581
- } = s, S = ["context", {
581
+ } = s, D = ["context", {
582
582
  folderId: f.folder,
583
583
  filters: f,
584
584
  trashed: m
585
585
  }];
586
586
  return B({
587
- mutationFn: async () => await at({
587
+ mutationFn: async () => await ot({
588
588
  searchParams: s,
589
589
  folderIds: o,
590
590
  resourceIds: p,
591
591
  useAssetIds: u
592
592
  }),
593
- onError(y) {
594
- typeof y == "string" && e.error(E(y));
593
+ onError(I) {
594
+ typeof I == "string" && e.error(P(I));
595
595
  },
596
- onSuccess: async (y) => {
596
+ onSuccess: async (I) => {
597
597
  if (await t.cancelQueries({
598
- queryKey: S
599
- }), t.getQueryData(S))
600
- return e.success(E("explorer.trash.title")), t.setQueryData(S, (C) => {
601
- var q;
598
+ queryKey: D
599
+ }), t.getQueryData(D))
600
+ return e.success(P("explorer.trash.title")), t.setQueryData(D, (C) => {
601
+ var O;
602
602
  if (C) {
603
- const O = {
603
+ const x = {
604
604
  ...C,
605
- pages: C == null ? void 0 : C.pages.map((b) => {
606
- var I;
605
+ pages: C == null ? void 0 : C.pages.map((y) => {
606
+ var g;
607
607
  return {
608
- ...b,
609
- folders: b.folders.filter((g) => !o.includes(g.id)),
608
+ ...y,
609
+ folders: y.folders.filter((S) => !o.includes(S.id)),
610
610
  pagination: {
611
- ...b.pagination,
611
+ ...y.pagination,
612
612
  // @ts-ignore
613
- maxIdx: ((I = b == null ? void 0 : b.pagination) == null ? void 0 : I.maxIdx) - y.resources.length
613
+ maxIdx: ((g = y == null ? void 0 : y.pagination) == null ? void 0 : g.maxIdx) - I.resources.length
614
614
  },
615
- resources: b.resources.filter((g) => u ? !a.includes(g.assetId) : !p.includes(g.id))
615
+ resources: y.resources.filter((S) => u ? !a.includes(S.assetId) : !p.includes(S.id))
616
616
  };
617
617
  })
618
- }, x = Qe(r, {
618
+ }, b = Pe(r, {
619
619
  folders: o
620
620
  });
621
- return h(x), i({
621
+ return h(b), d({
622
622
  ...s,
623
623
  pagination: {
624
624
  ...s.pagination,
625
625
  // @ts-ignore
626
- maxIdx: ((q = s.pagination) == null ? void 0 : q.maxIdx) - y.resources.length
626
+ maxIdx: ((O = s.pagination) == null ? void 0 : O.maxIdx) - I.resources.length
627
627
  }
628
- }), O;
628
+ }), x;
629
629
  }
630
630
  });
631
631
  },
632
632
  onSettled: () => {
633
- l(), d();
633
+ i(), l();
634
634
  }
635
635
  });
636
- }, Is = () => {
637
- const e = L(), t = k(), s = A(), r = X(), o = Z(), a = Y(), n = ee().length > 0, u = n ? o : a, {
636
+ }, ms = () => {
637
+ const e = L(), t = k(), s = Q(), r = X(), o = Z(), a = Y(), n = ee().length > 0, u = n ? o : a, {
638
638
  setFolderIds: p,
639
- setResourceIds: l,
640
- setSelectedResources: d,
639
+ setResourceIds: i,
640
+ setSelectedResources: l,
641
641
  setSelectedFolders: h
642
642
  } = F(), {
643
- filters: i,
643
+ filters: d,
644
644
  trashed: f
645
645
  } = s, m = ["context", {
646
- folderId: i.folder,
647
- filters: i,
646
+ folderId: d.folder,
647
+ filters: d,
648
648
  trashed: f
649
649
  }];
650
650
  return B({
651
- mutationFn: async () => await it({
651
+ mutationFn: async () => await at({
652
652
  searchParams: s,
653
653
  folderIds: r,
654
654
  resourceIds: u,
655
655
  useAssetIds: n
656
656
  }),
657
- onError(S) {
658
- typeof S == "string" && e.error(E(S));
657
+ onError(D) {
658
+ typeof D == "string" && e.error(P(D));
659
659
  },
660
660
  onSuccess: async () => {
661
661
  if (await t.cancelQueries({
662
662
  queryKey: m
663
663
  }), t.getQueryData(m))
664
- return e.success(E("explorer.trash.toast")), t.setQueryData(m, (y) => {
665
- if (y)
664
+ return e.success(P("explorer.trash.toast")), t.setQueryData(m, (I) => {
665
+ if (I)
666
666
  return {
667
- ...y,
668
- pages: y == null ? void 0 : y.pages.map((w) => ({
667
+ ...I,
668
+ pages: I == null ? void 0 : I.pages.map((w) => ({
669
669
  ...w,
670
670
  folders: w.folders.filter((C) => !r.includes(C.id)),
671
671
  resources: w.resources.filter((C) => n ? !o.includes(C.assetId) : !u.includes(C.id))
@@ -674,55 +674,55 @@ const Nt = (e, t) => {
674
674
  });
675
675
  },
676
676
  onSettled: () => {
677
- l([]), d([]), p([]), h([]);
677
+ i([]), l([]), p([]), h([]);
678
678
  }
679
679
  });
680
- }, Ds = () => {
681
- const e = L(), t = k(), s = A(), r = X(), o = Z(), a = Y(), n = ee().length > 0, u = n ? o : a, {
680
+ }, ys = () => {
681
+ const e = L(), t = k(), s = Q(), r = X(), o = Z(), a = Y(), n = ee().length > 0, u = n ? o : a, {
682
682
  clearSelectedItems: p,
683
- clearSelectedIds: l
683
+ clearSelectedIds: i
684
684
  } = F(), {
685
- filters: d,
685
+ filters: l,
686
686
  trashed: h
687
- } = s, i = ["context", {
688
- folderId: d.folder,
689
- filters: d,
687
+ } = s, d = ["context", {
688
+ folderId: l.folder,
689
+ filters: l,
690
690
  trashed: h
691
691
  }];
692
692
  return B({
693
- mutationFn: async () => await ct({
693
+ mutationFn: async () => await nt({
694
694
  searchParams: s,
695
695
  folderIds: r,
696
696
  resourceIds: u,
697
697
  useAssetIds: n
698
698
  }),
699
699
  onError(f) {
700
- typeof f == "string" && e.error(E(f));
700
+ typeof f == "string" && e.error(P(f));
701
701
  },
702
702
  onSuccess: async () => {
703
703
  if (await t.cancelQueries({
704
- queryKey: i
705
- }), t.getQueryData(i))
706
- return e.success(E("explorer.removed.from.trash")), t.setQueryData(i, (m) => {
704
+ queryKey: d
705
+ }), t.getQueryData(d))
706
+ return e.success(P("explorer.removed.from.trash")), t.setQueryData(d, (m) => {
707
707
  if (m)
708
708
  return {
709
709
  ...m,
710
- pages: m == null ? void 0 : m.pages.map((y) => ({
711
- ...y,
712
- folders: y.folders.filter((w) => !r.includes(w.id)),
713
- resources: y.resources.filter((w) => n ? !o.includes(w.assetId) : !u.includes(w.id))
710
+ pages: m == null ? void 0 : m.pages.map((I) => ({
711
+ ...I,
712
+ folders: I.folders.filter((w) => !r.includes(w.id)),
713
+ resources: I.resources.filter((w) => n ? !o.includes(w.assetId) : !u.includes(w.id))
714
714
  }))
715
715
  };
716
716
  });
717
717
  },
718
718
  onSettled: () => {
719
- p(), l();
719
+ p(), i();
720
720
  }
721
721
  });
722
- }, Ss = () => {
723
- const e = L(), t = A(), s = k(), {
722
+ }, Is = () => {
723
+ const e = L(), t = Q(), s = k(), {
724
724
  user: r
725
- } = ue(), o = W(), {
725
+ } = de(), o = W(), {
726
726
  filters: a,
727
727
  trashed: n
728
728
  } = t, u = "duplicate_start", p = ["context", {
@@ -731,22 +731,22 @@ const Nt = (e, t) => {
731
731
  trashed: n
732
732
  }];
733
733
  return B({
734
- mutationFn: async (l) => (e.info(E("duplicate.start"), {
734
+ mutationFn: async (i) => (e.info(P("duplicate.start"), {
735
735
  id: u
736
- }), await lt(t, l.assetId)),
737
- onSuccess: async (l, d) => {
738
- e.remove(u), e.success(E("duplicate.done")), await s.cancelQueries({
736
+ }), await ct(t, i.assetId)),
737
+ onSuccess: async (i, l) => {
738
+ e.remove(u), e.success(P("duplicate.done")), await s.cancelQueries({
739
739
  queryKey: p
740
740
  });
741
- const h = s.getQueryData(p), i = {
742
- ...d,
743
- name: `${d.name}${E("duplicate.suffix")}`,
744
- assetId: l.duplicateId,
745
- id: l.duplicateId,
741
+ const h = s.getQueryData(p), d = {
742
+ ...l,
743
+ name: `${l.name}${P("duplicate.suffix")}`,
744
+ assetId: i.duplicateId,
745
+ id: i.duplicateId,
746
746
  creatorId: r == null ? void 0 : r.userId,
747
747
  creatorName: r == null ? void 0 : r.username,
748
748
  createdAt: Date.now(),
749
- slug: d.slug || "",
749
+ slug: l.slug || "",
750
750
  modifiedAt: Date.now(),
751
751
  modifierId: (r == null ? void 0 : r.userId) || "",
752
752
  modifierName: (r == null ? void 0 : r.username) || "",
@@ -760,88 +760,88 @@ const Nt = (e, t) => {
760
760
  ...f,
761
761
  pages: f == null ? void 0 : f.pages.map((m) => ({
762
762
  ...m,
763
- resources: [i, ...m.resources]
763
+ resources: [d, ...m.resources]
764
764
  }))
765
765
  };
766
- }), o.id && o.id !== R.DEFAULT && fe({
766
+ }), o.id && o.id !== N.DEFAULT && pe({
767
767
  searchParams: t,
768
- resourceIds: [l.duplicateId],
768
+ resourceIds: [i.duplicateId],
769
769
  folderId: o.id,
770
770
  folderIds: [],
771
771
  useAssetIds: !0
772
772
  });
773
773
  },
774
- onError: (l) => {
775
- e.remove(u), typeof l == "string" && e.error(`${E("duplicate.error")}: ${l}`);
774
+ onError: (i) => {
775
+ e.remove(u), typeof i == "string" && e.error(`${P("duplicate.error")}: ${i}`);
776
776
  }
777
777
  });
778
- }, At = () => {
779
- const e = L(), t = k(), s = A(), r = V(), o = X(), a = Z(), n = Y(), u = ee().length > 0, p = u ? a : n, {
780
- clearSelectedIds: l,
781
- clearSelectedItems: d,
778
+ }, Et = () => {
779
+ const e = L(), t = k(), s = Q(), r = V(), o = X(), a = Z(), n = Y(), u = ee().length > 0, p = u ? a : n, {
780
+ clearSelectedIds: i,
781
+ clearSelectedItems: l,
782
782
  setTreeData: h,
783
- setSearchParams: i
783
+ setSearchParams: d
784
784
  } = F(), {
785
785
  filters: f,
786
786
  trashed: m
787
- } = s, S = ["context", {
787
+ } = s, D = ["context", {
788
788
  folderId: f.folder,
789
789
  filters: f,
790
790
  trashed: m
791
791
  }];
792
792
  return B({
793
- mutationFn: async (y) => await fe({
793
+ mutationFn: async (I) => await pe({
794
794
  searchParams: s,
795
- folderId: y,
795
+ folderId: I,
796
796
  folderIds: o,
797
797
  resourceIds: p,
798
798
  useAssetIds: u
799
799
  }),
800
- onError(y) {
801
- typeof y == "string" && e.error(E(y));
800
+ onError(I) {
801
+ typeof I == "string" && e.error(P(I));
802
802
  },
803
- onSuccess: async (y, w) => {
804
- if (t.getQueryData(S))
805
- return t.setQueryData(S, (q) => {
806
- var O;
807
- if (q) {
808
- const x = Ae(r, {
803
+ onSuccess: async (I, w) => {
804
+ if (t.getQueryData(D))
805
+ return t.setQueryData(D, (O) => {
806
+ var x;
807
+ if (O) {
808
+ const b = Ee(r, {
809
809
  destinationId: w,
810
810
  folders: o
811
- }), b = {
812
- ...q,
813
- pages: q == null ? void 0 : q.pages.map((I) => {
814
- var g;
811
+ }), y = {
812
+ ...O,
813
+ pages: O == null ? void 0 : O.pages.map((g) => {
814
+ var S;
815
815
  return {
816
- ...I,
817
- folders: I.folders.filter((D) => !o.includes(D.id)),
816
+ ...g,
817
+ folders: g.folders.filter((R) => !o.includes(R.id)),
818
818
  pagination: {
819
- ...I.pagination,
819
+ ...g.pagination,
820
820
  // @ts-ignore
821
- maxIdx: ((g = I.pagination) == null ? void 0 : g.maxIdx) - y.resources.length
821
+ maxIdx: ((S = g.pagination) == null ? void 0 : S.maxIdx) - I.resources.length
822
822
  },
823
- resources: I.resources.filter((D) => u ? !a.includes(D.assetId) : !p.includes(D.id))
823
+ resources: g.resources.filter((R) => u ? !a.includes(R.assetId) : !p.includes(R.id))
824
824
  };
825
825
  })
826
826
  };
827
- return h(x), i({
827
+ return h(b), d({
828
828
  ...s,
829
829
  pagination: {
830
830
  ...s.pagination,
831
831
  // @ts-ignore
832
- maxIdx: ((O = s.pagination) == null ? void 0 : O.maxIdx) - y.resources.length
832
+ maxIdx: ((x = s.pagination) == null ? void 0 : x.maxIdx) - I.resources.length
833
833
  }
834
- }), b;
834
+ }), y;
835
835
  }
836
836
  });
837
837
  t.invalidateQueries();
838
838
  },
839
839
  onSettled: () => {
840
- d(), l();
840
+ l(), i();
841
841
  }
842
842
  });
843
- }, bs = () => {
844
- const e = L(), t = k(), s = A(), r = V(), {
843
+ }, Ds = () => {
844
+ const e = L(), t = k(), s = Q(), r = V(), {
845
845
  setTreeData: o
846
846
  } = F(), {
847
847
  filters: a,
@@ -854,36 +854,36 @@ const Nt = (e, t) => {
854
854
  return B({
855
855
  mutationFn: async ({
856
856
  name: p,
857
- parentId: l
858
- }) => await ot({
857
+ parentId: i
858
+ }) => await st({
859
859
  searchParams: s,
860
860
  name: p,
861
- parentId: l
861
+ parentId: i
862
862
  }),
863
863
  onError(p) {
864
- typeof p == "string" && e.error(E(p));
864
+ typeof p == "string" && e.error(P(p));
865
865
  },
866
- onSuccess: async (p, l) => {
866
+ onSuccess: async (p, i) => {
867
867
  await t.cancelQueries({
868
868
  queryKey: u
869
869
  });
870
- const d = t.getQueryData(u), h = {
870
+ const l = t.getQueryData(u), h = {
871
871
  ...p,
872
- parentId: l.parentId,
872
+ parentId: i.parentId,
873
873
  children: [],
874
874
  rights: [`creator:${p == null ? void 0 : p.creator_id}`]
875
875
  };
876
- if (d)
877
- return t.setQueryData(u, (i) => {
878
- if (i) {
876
+ if (l)
877
+ return t.setQueryData(u, (d) => {
878
+ if (d) {
879
879
  const f = {
880
- ...i,
881
- pages: i == null ? void 0 : i.pages.map((S) => ({
882
- ...S,
883
- folders: [...S.folders, h]
880
+ ...d,
881
+ pages: d == null ? void 0 : d.pages.map((D) => ({
882
+ ...D,
883
+ folders: [...D.folders, h]
884
884
  }))
885
- }, m = ke(r, {
886
- parentId: l.parentId,
885
+ }, m = qe(r, {
886
+ parentId: i.parentId,
887
887
  newFolder: h
888
888
  });
889
889
  return o(m), f;
@@ -891,54 +891,54 @@ const Nt = (e, t) => {
891
891
  });
892
892
  }
893
893
  });
894
- }, ws = () => {
895
- const e = L(), t = k(), s = A(), r = V(), {
894
+ }, Ss = () => {
895
+ const e = L(), t = k(), s = Q(), r = V(), {
896
896
  setFolderIds: o,
897
897
  setSelectedFolders: a,
898
898
  setTreeData: n
899
899
  } = F(), {
900
900
  filters: u,
901
901
  trashed: p
902
- } = s, l = ["context", {
902
+ } = s, i = ["context", {
903
903
  folderId: u.folder,
904
904
  filters: u,
905
905
  trashed: p
906
906
  }];
907
907
  return B({
908
908
  mutationFn: async ({
909
- folderId: d,
909
+ folderId: l,
910
910
  name: h,
911
- parentId: i
912
- }) => await nt({
911
+ parentId: d
912
+ }) => await rt({
913
913
  searchParams: s,
914
- folderId: d,
915
- parentId: i,
914
+ folderId: l,
915
+ parentId: d,
916
916
  name: h
917
917
  }),
918
- onError(d) {
919
- typeof d == "string" && e.error(E(d));
918
+ onError(l) {
919
+ typeof l == "string" && e.error(P(l));
920
920
  },
921
- onSuccess: async (d, h) => {
921
+ onSuccess: async (l, h) => {
922
922
  if (await t.cancelQueries({
923
- queryKey: l
924
- }), t.getQueryData(l))
925
- return t.setQueryData(l, (f) => {
923
+ queryKey: i
924
+ }), t.getQueryData(i))
925
+ return t.setQueryData(i, (f) => {
926
926
  if (f) {
927
927
  const m = {
928
928
  ...f,
929
- pages: f == null ? void 0 : f.pages.map((y) => ({
930
- ...y,
931
- folders: y.folders.map((w) => w.id === d.id ? {
932
- ...d,
929
+ pages: f == null ? void 0 : f.pages.map((I) => ({
930
+ ...I,
931
+ folders: I.folders.map((w) => w.id === l.id ? {
932
+ ...l,
933
933
  parentId: h.parentId,
934
934
  rights: w.rights
935
935
  } : w)
936
936
  }))
937
- }, S = Ue(r, {
937
+ }, D = Oe(r, {
938
938
  folderId: h.folderId,
939
- newFolder: d
939
+ newFolder: l
940
940
  });
941
- return n(S), m;
941
+ return n(D), m;
942
942
  }
943
943
  });
944
944
  },
@@ -946,8 +946,8 @@ const Nt = (e, t) => {
946
946
  o([]), a([]);
947
947
  }
948
948
  });
949
- }, xs = (e) => {
950
- const t = k(), s = A(), {
949
+ }, bs = (e) => {
950
+ const t = k(), s = Q(), {
951
951
  setResourceIds: r,
952
952
  setSelectedResources: o
953
953
  } = F(), {
@@ -958,10 +958,10 @@ const Nt = (e, t) => {
958
958
  filters: a,
959
959
  trashed: n
960
960
  }];
961
- return qe({
961
+ return Ae({
962
962
  application: e,
963
963
  options: {
964
- onSuccess: async (p, l) => {
964
+ onSuccess: async (p, i) => {
965
965
  if (await t.cancelQueries({
966
966
  queryKey: u
967
967
  }), t.getQueryData(u))
@@ -969,12 +969,12 @@ const Nt = (e, t) => {
969
969
  if (h)
970
970
  return {
971
971
  ...h,
972
- pages: h == null ? void 0 : h.pages.map((i) => ({
973
- ...i,
974
- resources: i.resources.map((f) => {
975
- if (f.assetId === (l == null ? void 0 : l.resourceId)) {
972
+ pages: h == null ? void 0 : h.pages.map((d) => ({
973
+ ...d,
974
+ resources: d.resources.map((f) => {
975
+ if (f.assetId === (i == null ? void 0 : i.resourceId)) {
976
976
  let m = [`creator:${f.creatorId}`];
977
- return (l == null ? void 0 : l.rights.length) >= 1 && (m = [...m, ...l.rights.flatMap((S) => S.actions.map((y) => `${S.type}:${S.id}:${y.id}`))]), {
977
+ return (i == null ? void 0 : i.rights.length) >= 1 && (m = [...m, ...i.rights.flatMap((D) => D.actions.map((I) => `${D.type}:${D.id}:${I.id}`))]), {
978
978
  ...f,
979
979
  rights: m
980
980
  };
@@ -990,8 +990,8 @@ const Nt = (e, t) => {
990
990
  }
991
991
  }
992
992
  });
993
- }, Ts = (e) => {
994
- const t = k(), s = A(), {
993
+ }, ws = (e) => {
994
+ const t = k(), s = Q(), {
995
995
  filters: r,
996
996
  trashed: o
997
997
  } = s, a = ["context", {
@@ -999,38 +999,38 @@ const Nt = (e, t) => {
999
999
  filters: r,
1000
1000
  trashed: o
1001
1001
  }];
1002
- return Oe({
1002
+ return Qe({
1003
1003
  application: e,
1004
1004
  options: {
1005
1005
  onSuccess: async (n, u) => {
1006
1006
  if (await t.cancelQueries({
1007
1007
  queryKey: a
1008
1008
  }), t.getQueryData(a))
1009
- return t.setQueryData(a, (l) => {
1010
- if (l)
1009
+ return t.setQueryData(a, (i) => {
1010
+ if (i)
1011
1011
  return {
1012
- ...l,
1013
- pages: l == null ? void 0 : l.pages.map((d) => ({
1014
- ...d,
1015
- resources: d.resources.map((h) => {
1012
+ ...i,
1013
+ pages: i == null ? void 0 : i.pages.map((l) => ({
1014
+ ...l,
1015
+ resources: l.resources.map((h) => {
1016
1016
  if (h.assetId === (u == null ? void 0 : u.entId)) {
1017
1017
  const {
1018
- name: i,
1018
+ name: d,
1019
1019
  thumbnail: f,
1020
1020
  public: m,
1021
- description: S,
1022
- slug: y,
1021
+ description: D,
1022
+ slug: I,
1023
1023
  ...w
1024
1024
  } = u;
1025
1025
  return {
1026
1026
  ...h,
1027
1027
  ...w,
1028
1028
  // add any custom field
1029
- name: i,
1029
+ name: d,
1030
1030
  thumbnail: typeof f == "string" ? f : URL.createObjectURL(f),
1031
1031
  public: m,
1032
- description: S,
1033
- slug: y
1032
+ description: D,
1033
+ slug: I
1034
1034
  };
1035
1035
  } else
1036
1036
  return h;
@@ -1041,10 +1041,10 @@ const Nt = (e, t) => {
1041
1041
  }
1042
1042
  }
1043
1043
  });
1044
- }, Cs = () => {
1045
- const e = L(), t = k(), s = A(), {
1044
+ }, xs = () => {
1045
+ const e = L(), t = k(), s = Q(), {
1046
1046
  user: r
1047
- } = ue(), {
1047
+ } = de(), {
1048
1048
  appCode: o
1049
1049
  } = v(), a = ["context", {
1050
1050
  folderId: s.filters.folder,
@@ -1052,19 +1052,19 @@ const Nt = (e, t) => {
1052
1052
  trashed: s.trashed
1053
1053
  }];
1054
1054
  return B({
1055
- mutationFn: async (n) => await ht({
1055
+ mutationFn: async (n) => await dt({
1056
1056
  searchParams: s,
1057
1057
  params: n
1058
1058
  }),
1059
1059
  onError(n) {
1060
- typeof n == "string" && e.error(E(n));
1060
+ typeof n == "string" && e.error(P(n));
1061
1061
  },
1062
1062
  onSuccess: async (n, u) => {
1063
- var d, h, i;
1063
+ var l, h, d;
1064
1064
  await t.cancelQueries({
1065
1065
  queryKey: a
1066
1066
  });
1067
- const p = t.getQueryData(a), l = {
1067
+ const p = t.getQueryData(a), i = {
1068
1068
  ...u,
1069
1069
  thumbnail: n.thumbnail || "",
1070
1070
  application: o,
@@ -1074,9 +1074,9 @@ const Nt = (e, t) => {
1074
1074
  creatorName: r == null ? void 0 : r.username,
1075
1075
  createdAt: Date.now(),
1076
1076
  slug: u.slug || "",
1077
- modifiedAt: ((d = n.modified) == null ? void 0 : d.$date) || "",
1077
+ modifiedAt: ((l = n.modified) == null ? void 0 : l.$date) || "",
1078
1078
  modifierId: ((h = n.author) == null ? void 0 : h.userId) || "",
1079
- modifierName: ((i = n.author) == null ? void 0 : i.username) || "",
1079
+ modifierName: ((d = n.author) == null ? void 0 : d.username) || "",
1080
1080
  updatedAt: Date.now(),
1081
1081
  trashed: !1,
1082
1082
  rights: [`creator:${r == null ? void 0 : r.userId}`]
@@ -1088,20 +1088,20 @@ const Nt = (e, t) => {
1088
1088
  ...f,
1089
1089
  pages: f == null ? void 0 : f.pages.map((m) => ({
1090
1090
  ...m,
1091
- resources: [l, ...m.resources]
1091
+ resources: [i, ...m.resources]
1092
1092
  }))
1093
1093
  };
1094
1094
  });
1095
1095
  }
1096
1096
  });
1097
1097
  };
1098
- function le(e, t) {
1098
+ function ie(e, t) {
1099
1099
  var r;
1100
1100
  const s = J(e, t);
1101
- return (r = s == null ? void 0 : s.folder) != null && r.childrenIds ? [...(s == null ? void 0 : s.folder.childrenIds) || [], t] : t === R.BIN ? [R.BIN] : [R.DEFAULT];
1101
+ return (r = s == null ? void 0 : s.folder) != null && r.childrenIds ? [...(s == null ? void 0 : s.folder.childrenIds) || [], t] : t === N.BIN ? [N.BIN] : [N.DEFAULT];
1102
1102
  }
1103
- function Qt() {
1104
- const e = k(), t = At(), s = L(), {
1103
+ function Pt() {
1104
+ const e = k(), t = Et(), s = L(), {
1105
1105
  appCode: r
1106
1106
  } = v(), {
1107
1107
  t: o
@@ -1111,22 +1111,20 @@ function Qt() {
1111
1111
  setResourceOrFolderIsDraggable: n,
1112
1112
  setElementDragOver: u,
1113
1113
  setResourceIds: p,
1114
- setFolderIds: l,
1115
- fetchTreeData: d
1116
- } = F(), h = V(), i = {
1117
- delay: Ft,
1118
- tolerance: Rt
1119
- }, f = se(xe, {
1120
- activationConstraint: i
1121
- }), m = se(Te, {
1122
- activationConstraint: i
1123
- }), S = se(Ce), y = Fe(f, m, S), w = (x, b) => {
1124
- var I;
1125
- ((I = x.data.current) == null ? void 0 : I.type) === "resource" ? s.success(/* @__PURE__ */ N(G, { children: [
1114
+ setFolderIds: i,
1115
+ fetchTreeData: l
1116
+ } = F(), h = V(), f = oe(we, {
1117
+ activationConstraint: {
1118
+ delay: Tt,
1119
+ tolerance: Ct
1120
+ }
1121
+ }), m = oe(xe), D = Te(f, m), I = (x, b) => {
1122
+ var y;
1123
+ ((y = x.data.current) == null ? void 0 : y.type) === "resource" ? s.success(/* @__PURE__ */ E(G, { children: [
1126
1124
  o("explorer.dragged.resource"),
1127
1125
  " ",
1128
1126
  /* @__PURE__ */ c("strong", { children: b })
1129
- ] })) : s.success(/* @__PURE__ */ N(G, { children: [
1127
+ ] })) : s.success(/* @__PURE__ */ E(G, { children: [
1130
1128
  o("explorer.dragged.folder"),
1131
1129
  " ",
1132
1130
  /* @__PURE__ */ c("strong", { children: b })
@@ -1136,17 +1134,17 @@ function Qt() {
1136
1134
  handleDragEnd: async (x) => {
1137
1135
  const {
1138
1136
  over: b,
1139
- active: I
1140
- } = x, g = b == null ? void 0 : b.data.current, D = I.data.current, z = ae(h, g == null ? void 0 : g.id), te = le(h, g == null ? void 0 : g.id);
1141
- if ((D == null ? void 0 : D.id) == (g == null ? void 0 : g.id) || z.includes(D == null ? void 0 : D.id) || te.includes(D == null ? void 0 : D.id))
1142
- p([]), l([]);
1137
+ active: y
1138
+ } = x, g = b == null ? void 0 : b.data.current, S = y.data.current, R = ne(h, g == null ? void 0 : g.id), z = ie(h, g == null ? void 0 : g.id);
1139
+ if ((S == null ? void 0 : S.id) == (g == null ? void 0 : g.id) || R.includes(S == null ? void 0 : S.id) || z.includes(S == null ? void 0 : S.id))
1140
+ p([]), i([]);
1143
1141
  else {
1144
1142
  const H = (g == null ? void 0 : g.name) ?? a;
1145
1143
  if (b)
1146
1144
  try {
1147
- await t.mutate(g == null ? void 0 : g.id), w(I, H);
1148
- } catch (Se) {
1149
- console.error(Se);
1145
+ await t.mutate(g == null ? void 0 : g.id), I(y, H);
1146
+ } catch (De) {
1147
+ console.error(De);
1150
1148
  } finally {
1151
1149
  u({
1152
1150
  isOver: !1,
@@ -1164,17 +1162,17 @@ function Qt() {
1164
1162
  handleDragStart: (x) => {
1165
1163
  const {
1166
1164
  active: b
1167
- } = x, I = b.data.current;
1168
- (I == null ? void 0 : I.type) === "resource" ? p([I == null ? void 0 : I.id]) : (I == null ? void 0 : I.type) === "folder" && l([I == null ? void 0 : I.id]), n({
1165
+ } = x, y = b.data.current;
1166
+ (y == null ? void 0 : y.type) === "resource" ? p([y == null ? void 0 : y.id]) : (y == null ? void 0 : y.type) === "folder" && i([y == null ? void 0 : y.id]), n({
1169
1167
  isDrag: !0,
1170
- elementDrag: I == null ? void 0 : I.id
1168
+ elementDrag: y == null ? void 0 : y.id
1171
1169
  });
1172
1170
  },
1173
1171
  handleDragOver: (x) => {
1174
1172
  const {
1175
1173
  over: b,
1176
- active: I
1177
- } = x, g = b == null ? void 0 : b.data.current, D = I == null ? void 0 : I.data.current, z = ae(h, g == null ? void 0 : g.id), te = le(h, g == null ? void 0 : g.id);
1174
+ active: y
1175
+ } = x, g = b == null ? void 0 : b.data.current, S = y == null ? void 0 : y.data.current, R = ne(h, g == null ? void 0 : g.id), z = ie(h, g == null ? void 0 : g.id);
1178
1176
  if (b) {
1179
1177
  const H = {
1180
1178
  isOver: !0,
@@ -1182,10 +1180,10 @@ function Qt() {
1182
1180
  overId: g == null ? void 0 : g.id,
1183
1181
  isTreeview: g == null ? void 0 : g.isTreeview
1184
1182
  };
1185
- (D == null ? void 0 : D.id) === (g == null ? void 0 : g.id) || z.includes(D == null ? void 0 : D.id) || te.includes(D == null ? void 0 : D.id) ? u({
1183
+ (S == null ? void 0 : S.id) === (g == null ? void 0 : g.id) || R.includes(S == null ? void 0 : S.id) || z.includes(S == null ? void 0 : S.id) ? u({
1186
1184
  ...H,
1187
1185
  canMove: !1
1188
- }) : (d(g == null ? void 0 : g.id, e), u({
1186
+ }) : (l(g == null ? void 0 : g.id, e), u({
1189
1187
  ...H,
1190
1188
  canMove: !0
1191
1189
  }));
@@ -1197,50 +1195,50 @@ function Qt() {
1197
1195
  isTreeview: !1
1198
1196
  });
1199
1197
  },
1200
- sensors: y
1198
+ sensors: D
1201
1199
  };
1202
1200
  }
1203
- const qt = /* @__PURE__ */ Q(async () => await import("./EmptyScreenApp.js")), Ot = /* @__PURE__ */ Q(async () => await import("./EmptyScreenSearch.js")), kt = /* @__PURE__ */ Q(async () => await import("./EmptyScreenError.js")), Ut = /* @__PURE__ */ Q(async () => await import("./EmptyScreenNoContentInFolder.js")), Mt = /* @__PURE__ */ Q(async () => await import("./EmptyScreenTrash.js")), Lt = /* @__PURE__ */ Q(async () => await import("./FoldersList.js")), vt = /* @__PURE__ */ Q(async () => await import("./ResourcesList.js")), Bt = () => {
1204
- const e = wt(), t = ne(), s = oe(), r = A(), o = W(), a = L(), n = k(), {
1201
+ const At = /* @__PURE__ */ q(async () => await import("./EmptyScreenApp.js")), Qt = /* @__PURE__ */ q(async () => await import("./EmptyScreenSearch.js")), qt = /* @__PURE__ */ q(async () => await import("./EmptyScreenError.js")), Ot = /* @__PURE__ */ q(async () => await import("./EmptyScreenNoContentInFolder.js")), kt = /* @__PURE__ */ q(async () => await import("./EmptyScreenTrash.js")), Ut = /* @__PURE__ */ q(async () => await import("./FoldersList.js")), Mt = /* @__PURE__ */ q(async () => await import("./ResourcesList.js")), Lt = () => {
1202
+ const e = St(), t = re(), s = se(), r = Q(), o = W(), a = L(), n = k(), {
1205
1203
  appCode: u
1206
1204
  } = v(), {
1207
1205
  t: p
1208
1206
  } = _([u]), {
1209
- setSearchParams: l,
1210
- setSearchConfig: d,
1207
+ setSearchParams: i,
1208
+ setSearchConfig: l,
1211
1209
  fetchTreeData: h
1212
1210
  } = F(), {
1213
- data: i,
1211
+ data: d,
1214
1212
  isError: f,
1215
1213
  error: m,
1216
- isLoading: S,
1217
- isFetching: y,
1214
+ isLoading: D,
1215
+ isFetching: I,
1218
1216
  fetchNextPage: w
1219
- } = Pt(), C = (i == null ? void 0 : i.pages[0].folders.length) === 0, q = (i == null ? void 0 : i.pages[0].resources.length) === 0, O = C && q;
1217
+ } = Nt(), C = (d == null ? void 0 : d.pages[0].folders.length) === 0, O = (d == null ? void 0 : d.pages[0].resources.length) === 0, x = C && O;
1220
1218
  return $(() => {
1221
- var x, b;
1222
- i && ((x = i == null ? void 0 : i.pages[0]) != null && x.searchConfig && d(i.pages[0].searchConfig), !r.search && o.id === "default" && h(o.id, n), l({
1219
+ var b, y;
1220
+ d && ((b = d == null ? void 0 : d.pages[0]) != null && b.searchConfig && l(d.pages[0].searchConfig), !r.search && o.id === "default" && h(o.id, n), i({
1223
1221
  ...r,
1224
- pagination: (b = i == null ? void 0 : i.pages[(i == null ? void 0 : i.pages.length) - 1]) == null ? void 0 : b.pagination
1222
+ pagination: (y = d == null ? void 0 : d.pages[(d == null ? void 0 : d.pages.length) - 1]) == null ? void 0 : y.pagination
1225
1223
  }));
1226
- }, [i]), $(() => {
1224
+ }, [d]), $(() => {
1227
1225
  m && typeof m == "string" && a.error(p(m));
1228
- }, [m]), S ? /* @__PURE__ */ c(U, {}) : f ? /* @__PURE__ */ c(M, { fallback: /* @__PURE__ */ c(U, {}), children: /* @__PURE__ */ c(kt, {}) }) : r.search && O ? /* @__PURE__ */ c(M, { fallback: /* @__PURE__ */ c(U, {}), children: /* @__PURE__ */ c(Ot, {}) }) : e && O ? /* @__PURE__ */ c(M, { fallback: /* @__PURE__ */ c(U, {}), children: /* @__PURE__ */ c(qt, {}) }) : s && O && !t ? /* @__PURE__ */ c(M, { fallback: /* @__PURE__ */ c(U, {}), children: /* @__PURE__ */ c(Ut, {}) }) : t && (i == null ? void 0 : i.pages[0].resources.length) === 0 ? /* @__PURE__ */ c(M, { fallback: /* @__PURE__ */ c(U, {}), children: /* @__PURE__ */ c(Mt, {}) }) : /* @__PURE__ */ N(M, { fallback: /* @__PURE__ */ c(U, {}), children: [
1229
- /* @__PURE__ */ c(Lt, { data: i, isFetching: y }),
1230
- /* @__PURE__ */ c(vt, { data: i, isFetching: y, fetchNextPage: w })
1226
+ }, [m]), D ? /* @__PURE__ */ c(U, {}) : f ? /* @__PURE__ */ c(M, { fallback: /* @__PURE__ */ c(U, {}), children: /* @__PURE__ */ c(qt, {}) }) : r.search && x ? /* @__PURE__ */ c(M, { fallback: /* @__PURE__ */ c(U, {}), children: /* @__PURE__ */ c(Qt, {}) }) : e && x ? /* @__PURE__ */ c(M, { fallback: /* @__PURE__ */ c(U, {}), children: /* @__PURE__ */ c(At, {}) }) : s && x && !t ? /* @__PURE__ */ c(M, { fallback: /* @__PURE__ */ c(U, {}), children: /* @__PURE__ */ c(Ot, {}) }) : t && (d == null ? void 0 : d.pages[0].resources.length) === 0 ? /* @__PURE__ */ c(M, { fallback: /* @__PURE__ */ c(U, {}), children: /* @__PURE__ */ c(kt, {}) }) : /* @__PURE__ */ E(M, { fallback: /* @__PURE__ */ c(U, {}), children: [
1227
+ /* @__PURE__ */ c(Ut, { data: d, isFetching: I }),
1228
+ /* @__PURE__ */ c(Mt, { data: d, isFetching: I, fetchNextPage: w })
1231
1229
  ] });
1232
- }, De = () => {
1233
- const e = A(), [t, s] = de(""), r = It(), o = xt(), a = be(null), {
1230
+ }, Ie = () => {
1231
+ const e = Q(), [t, s] = le(""), r = mt(), o = bt(), a = Se(null), {
1234
1232
  setSearchParams: n
1235
- } = F(), u = (d) => {
1236
- const h = d.target.value;
1233
+ } = F(), u = (l) => {
1234
+ const h = l.target.value;
1237
1235
  s(h.toString());
1238
- }, p = (d) => {
1239
- (d.key === "Enter" || d.key === "Return") && (d.preventDefault(), n({
1236
+ }, p = (l) => {
1237
+ (l.key === "Enter" || l.key === "Return") && (l.preventDefault(), n({
1240
1238
  search: t || void 0
1241
1239
  }));
1242
- }, l = (d) => {
1243
- d.preventDefault(), n({
1240
+ }, i = (l) => {
1241
+ l.preventDefault(), n({
1244
1242
  search: t || void 0
1245
1243
  });
1246
1244
  };
@@ -1256,44 +1254,44 @@ const qt = /* @__PURE__ */ Q(async () => await import("./EmptyScreenApp.js")), O
1256
1254
  o === "select" && s("");
1257
1255
  }, [o]), $(() => {
1258
1256
  s(() => {
1259
- var d;
1260
- return ((d = e.search) == null ? void 0 : d.toString()) ?? "";
1257
+ var l;
1258
+ return ((l = e.search) == null ? void 0 : l.toString()) ?? "";
1261
1259
  });
1262
1260
  }, [e]), {
1263
1261
  formRef: a,
1264
1262
  inputSearch: t,
1265
1263
  handleInputSearchChange: u,
1266
1264
  handleKeyPress: p,
1267
- handleSearchSubmit: l
1265
+ handleSearchSubmit: i
1268
1266
  };
1269
- }, Kt = () => {
1267
+ }, vt = () => {
1270
1268
  const {
1271
1269
  appCode: e,
1272
1270
  currentApp: t
1273
1271
  } = v(), {
1274
1272
  t: s
1275
- } = _(), [r, o] = de(""), a = (d) => {
1276
- if (d === "0") {
1273
+ } = _(), [r, o] = le(""), a = (l) => {
1274
+ if (l === "0") {
1277
1275
  o("");
1278
1276
  return;
1279
1277
  }
1280
- o(d);
1281
- }, n = W(), u = A(), {
1278
+ o(l);
1279
+ }, n = W(), u = Q(), {
1282
1280
  setSearchParams: p
1283
1281
  } = F();
1284
1282
  $(() => {
1285
- const d = () => r.includes("1") ? !0 : void 0, h = () => r.includes("2") ? !0 : void 0, i = () => r.includes("7") ? !0 : void 0;
1283
+ const l = () => r.includes("1") ? !0 : void 0, h = () => r.includes("2") ? !0 : void 0, d = () => r.includes("7") ? !0 : void 0;
1286
1284
  p({
1287
1285
  ...u,
1288
1286
  filters: {
1289
- owner: d(),
1290
- public: i(),
1287
+ owner: l(),
1288
+ public: d(),
1291
1289
  shared: h(),
1292
1290
  folder: n ? n.id : "default"
1293
1291
  }
1294
1292
  });
1295
1293
  }, [n, p, r]);
1296
- const l = [{
1294
+ const i = [{
1297
1295
  label: s("explorer.filter.all", {
1298
1296
  ns: e
1299
1297
  }),
@@ -1328,10 +1326,10 @@ const qt = /* @__PURE__ */ Q(async () => await import("./EmptyScreenApp.js")), O
1328
1326
  }] : []];
1329
1327
  return {
1330
1328
  selectedFilters: r,
1331
- options: l,
1329
+ options: i,
1332
1330
  handleOnSelectFilter: a
1333
1331
  };
1334
- }, $t = () => {
1332
+ }, Bt = () => {
1335
1333
  const {
1336
1334
  appCode: e
1337
1335
  } = v(), {
@@ -1340,31 +1338,31 @@ const qt = /* @__PURE__ */ Q(async () => await import("./EmptyScreenApp.js")), O
1340
1338
  selectedFilters: s,
1341
1339
  options: r,
1342
1340
  handleOnSelectFilter: o
1343
- } = Kt(), {
1341
+ } = vt(), {
1344
1342
  formRef: a,
1345
1343
  inputSearch: n,
1346
1344
  handleInputSearchChange: u,
1347
1345
  handleKeyPress: p,
1348
- handleSearchSubmit: l
1349
- } = De(), d = s.length > 0 ? s.length : void 0;
1350
- return /* @__PURE__ */ N("form", { noValidate: !0, className: "bg-light p-16 ps-24 ms-n16 ms-lg-n24 me-n16 position-relative d-flex gap-8", ref: a, children: [
1351
- /* @__PURE__ */ N(Me, { id: "search", className: "input-group", children: [
1352
- /* @__PURE__ */ c(Le, { type: "search", placeholder: t("explorer.label.search", {
1346
+ handleSearchSubmit: i
1347
+ } = Ie(), l = s.length > 0 ? s.length : void 0;
1348
+ return /* @__PURE__ */ E("form", { noValidate: !0, className: "bg-light p-16 ps-24 ms-n16 ms-lg-n24 me-n16 position-relative d-flex gap-8", ref: a, children: [
1349
+ /* @__PURE__ */ E(ke, { id: "search", className: "input-group", children: [
1350
+ /* @__PURE__ */ c(Ue, { type: "search", placeholder: t("explorer.label.search", {
1353
1351
  ns: e
1354
1352
  }), size: "lg", noValidationIcon: !0, value: n, onChange: u, onKeyDown: p }),
1355
- /* @__PURE__ */ c(ve, { type: "submit", "aria-label": t("explorer.label.search", {
1353
+ /* @__PURE__ */ c(Me, { type: "submit", "aria-label": t("explorer.label.search", {
1356
1354
  ns: e
1357
- }), onClick: l })
1355
+ }), onClick: i })
1358
1356
  ] }),
1359
- /* @__PURE__ */ N(j, { placement: "bottom-end", children: [
1360
- /* @__PURE__ */ c(j.Trigger, { label: t("explorer.filters"), icon: /* @__PURE__ */ c(et, { width: 20 }), variant: "ghost", badgeContent: d }),
1361
- /* @__PURE__ */ c(j.Menu, { children: r.map((h) => h.value === "0" ? /* @__PURE__ */ N(we, { children: [
1357
+ /* @__PURE__ */ E(j, { placement: "bottom-end", children: [
1358
+ /* @__PURE__ */ c(j.Trigger, { label: t("explorer.filters"), icon: /* @__PURE__ */ c(Ye, { width: 20 }), variant: "ghost", badgeContent: l }),
1359
+ /* @__PURE__ */ c(j.Menu, { children: r.map((h) => h.value === "0" ? /* @__PURE__ */ E(be, { children: [
1362
1360
  /* @__PURE__ */ c(j.RadioItem, { value: h.value, model: s, onChange: () => o(h.value), children: h.label }),
1363
1361
  /* @__PURE__ */ c(j.Separator, {})
1364
1362
  ] }, "0") : /* @__PURE__ */ c(j.RadioItem, { value: h.value, model: s, onChange: () => o(h.value), children: h.label }, h.value)) })
1365
1363
  ] })
1366
1364
  ] });
1367
- }, _t = ({
1365
+ }, Kt = ({
1368
1366
  id: e,
1369
1367
  selected: t,
1370
1368
  onSelect: s
@@ -1372,48 +1370,50 @@ const qt = /* @__PURE__ */ Q(async () => await import("./EmptyScreenApp.js")), O
1372
1370
  const {
1373
1371
  t: r
1374
1372
  } = _();
1375
- return /* @__PURE__ */ c("div", { className: "treeview", children: /* @__PURE__ */ c("ul", { role: "tree", className: "m-0 p-0", children: /* @__PURE__ */ c("li", { id: e, role: "treeitem", "aria-selected": t, children: /* @__PURE__ */ c("div", { children: /* @__PURE__ */ c("div", { className: "action-container", children: /* @__PURE__ */ c("div", { onClick: s, role: "button", tabIndex: 0, children: /* @__PURE__ */ N("div", { className: "d-flex align-items-center gap-8 py-8 ps-24", children: [
1376
- /* @__PURE__ */ c(tt, { width: "20", height: "20" }),
1373
+ return /* @__PURE__ */ c("div", { className: "treeview", children: /* @__PURE__ */ c("ul", { role: "tree", className: "m-0 p-0", children: /* @__PURE__ */ c("li", { id: e, role: "treeitem", "aria-selected": t, children: /* @__PURE__ */ c("div", { children: /* @__PURE__ */ c("div", { className: "action-container", children: /* @__PURE__ */ c("div", { onClick: s, role: "button", tabIndex: 0, children: /* @__PURE__ */ E("div", { className: "d-flex align-items-center gap-8 py-8 ps-24", children: [
1374
+ /* @__PURE__ */ c(Ze, { width: "20", height: "20" }),
1377
1375
  /* @__PURE__ */ c("span", { children: r("explorer.tree.trash") })
1378
1376
  ] }) }) }) }) }) }) });
1379
- }, zt = /* @__PURE__ */ Q(async () => await import("./FolderModal.js")), jt = () => {
1380
- const [e, t] = Be(), s = k(), r = V(), o = ne(), a = oe(), n = St(), u = Ke(), p = o ? R.BIN : a, {
1381
- appCode: l
1377
+ }, $t = /* @__PURE__ */ q(async () => await import("./FolderModal.js")), _t = () => {
1378
+ const [e, t] = Le(), s = k(), r = V(), o = re(), a = se(), n = It(), u = ve(), p = o ? N.BIN : a, {
1379
+ appCode: i
1382
1380
  } = v(), {
1383
- t: d
1384
- } = _(["common", l]), h = {
1381
+ t: l
1382
+ } = _(["common", i]), h = {
1385
1383
  ...r,
1386
- name: d("explorer.filters.mine", {
1387
- ns: l
1384
+ name: l("explorer.filters.mine", {
1385
+ ns: i
1388
1386
  })
1389
1387
  }, {
1390
- goToTrash: i,
1388
+ goToTrash: d,
1391
1389
  selectTreeItem: f,
1392
1390
  clearSelectedItems: m,
1393
- clearSelectedIds: S,
1394
- fetchTreeData: y
1395
- } = F(), w = (O) => {
1396
- f(O, s), u();
1397
- }, C = (O) => {
1398
- var I, g;
1399
- const x = J(r, O), b = (I = x == null ? void 0 : x.children) == null ? void 0 : I.some((D) => {
1391
+ clearSelectedIds: D,
1392
+ fetchTreeData: I
1393
+ } = F(), w = (x) => {
1394
+ f(x, s), u();
1395
+ }, C = (x) => {
1396
+ var g, S;
1397
+ const b = J(r, x), y = (g = b == null ? void 0 : b.children) == null ? void 0 : g.some((R) => {
1400
1398
  var z;
1401
- return Array.isArray(D == null ? void 0 : D.children) && ((z = D.children) == null ? void 0 : z.length) > 0;
1399
+ return Array.isArray(R == null ? void 0 : R.children) && ((z = R.children) == null ? void 0 : z.length) > 0;
1402
1400
  });
1403
- (g = x == null ? void 0 : x.children) == null || g.forEach((D) => {
1404
- b || y(D.id, s);
1401
+ (S = b == null ? void 0 : b.children) == null || S.forEach((R) => {
1402
+ y || I(R.id, s);
1405
1403
  });
1406
- }, q = () => {
1407
- m(), S(), t();
1404
+ }, O = () => {
1405
+ m(), D(), t();
1408
1406
  };
1409
- return /* @__PURE__ */ N(G, { children: [
1410
- /* @__PURE__ */ c($e, { data: h, selectedNodeId: p, draggedNode: n != null && n.isTreeview ? n : void 0, onTreeItemClick: w, onTreeItemUnfold: C }),
1411
- /* @__PURE__ */ c(_t, { id: R.BIN, selected: o, onSelect: i }),
1412
- /* @__PURE__ */ c("div", { className: "d-grid my-16", children: /* @__PURE__ */ c(_e, { disabled: o, type: "button", color: "primary", variant: "outline", leftIcon: /* @__PURE__ */ c(st, {}), onClick: q, children: d("explorer.folder.new") }) }),
1413
- /* @__PURE__ */ c(M, { fallback: /* @__PURE__ */ c(U, {}), children: e && /* @__PURE__ */ c(zt, { edit: !1, isOpen: e, onSuccess: t, onCancel: t }) })
1407
+ return console.log({
1408
+ elementDragOver: n
1409
+ }), /* @__PURE__ */ E(G, { children: [
1410
+ /* @__PURE__ */ c(Be, { data: h, selectedNodeId: p, draggedNode: n != null && n.isTreeview ? n : void 0, onTreeItemClick: w, onTreeItemUnfold: C }),
1411
+ /* @__PURE__ */ c(Kt, { id: N.BIN, selected: o, onSelect: d }),
1412
+ /* @__PURE__ */ c("div", { className: "d-grid my-16", children: /* @__PURE__ */ c(Ke, { disabled: o, type: "button", color: "primary", variant: "outline", leftIcon: /* @__PURE__ */ c(et, {}), onClick: O, children: l("explorer.folder.new") }) }),
1413
+ /* @__PURE__ */ c(M, { fallback: /* @__PURE__ */ c(U, {}), children: e && /* @__PURE__ */ c($t, { edit: !1, isOpen: e, onSuccess: t, onCancel: t }) })
1414
1414
  ] });
1415
1415
  };
1416
- function Vt() {
1416
+ function zt() {
1417
1417
  const {
1418
1418
  appCode: e
1419
1419
  } = v(), {
@@ -1422,18 +1422,18 @@ function Vt() {
1422
1422
  t: s
1423
1423
  } = _(["common", e]), {
1424
1424
  inputSearch: r
1425
- } = De(), o = oe(), a = ne(), n = W(), u = s("explorer.tree.trash"), p = s("explorer.tree.search"), l = s("explorer.filters.mine", {
1425
+ } = Ie(), o = se(), a = re(), n = W(), u = s("explorer.tree.trash"), p = s("explorer.tree.search"), i = s("explorer.filters.mine", {
1426
1426
  ns: e
1427
- }), d = (n == null ? void 0 : n.name) || l;
1428
- return /* @__PURE__ */ c("div", { className: "py-16", children: o && o !== "bin" && o !== "default" && !a ? /* @__PURE__ */ N("div", { className: "d-flex align-items-center gap-8", children: [
1429
- /* @__PURE__ */ c(ze, { icon: /* @__PURE__ */ c(rt, {}), variant: "ghost", color: "tertiary", "aria-label": s("back"), className: "ms-n16", onClick: t }),
1430
- /* @__PURE__ */ c("p", { className: "body py-8 text-truncate", children: /* @__PURE__ */ c("strong", { children: d }) })
1431
- ] }) : /* @__PURE__ */ c("h2", { className: "body py-8 fw-bold", children: r.length !== 0 ? p : a ? u : l }) });
1427
+ }), l = (n == null ? void 0 : n.name) || i;
1428
+ return /* @__PURE__ */ c("div", { className: "py-16", children: o && o !== "bin" && o !== "default" && !a ? /* @__PURE__ */ E("div", { className: "d-flex align-items-center gap-8", children: [
1429
+ /* @__PURE__ */ c($e, { icon: /* @__PURE__ */ c(tt, {}), variant: "ghost", color: "tertiary", "aria-label": s("back"), className: "ms-n16", onClick: t }),
1430
+ /* @__PURE__ */ c("p", { className: "body py-8 text-truncate", children: /* @__PURE__ */ c("strong", { children: l }) })
1431
+ ] }) : /* @__PURE__ */ c("h2", { className: "body py-8 fw-bold", children: r.length !== 0 ? p : a ? u : i }) });
1432
1432
  }
1433
- const Wt = /* @__PURE__ */ Q(async () => await import("./AppAction.js")), Ht = /* @__PURE__ */ Q(async () => await import("./Library.js")), Gt = /* @__PURE__ */ Q(async () => await import("./ActionBarContainer.js")), Jt = /* @__PURE__ */ Q(async () => await import("./DisableModal.js")), Xt = /* @__PURE__ */ Q(async () => await import("./TrashModal.js")), Yt = /* @__PURE__ */ Q(async () => await import("./OnboardingModal.js")), Fs = ({
1433
+ const jt = /* @__PURE__ */ q(async () => await import("./AppAction.js")), Vt = /* @__PURE__ */ q(async () => await import("./Library.js")), Wt = /* @__PURE__ */ q(async () => await import("./ActionBarContainer.js")), Ht = /* @__PURE__ */ q(async () => await import("./DisableModal.js")), Gt = /* @__PURE__ */ q(async () => await import("./TrashModal.js")), Jt = /* @__PURE__ */ q(async () => await import("./OnboardingModal.js")), Ts = ({
1434
1434
  config: e
1435
1435
  }) => {
1436
- const t = A(), {
1436
+ const t = Q(), {
1437
1437
  setConfig: s,
1438
1438
  setSearchParams: r
1439
1439
  } = F();
@@ -1448,35 +1448,35 @@ const Wt = /* @__PURE__ */ Q(async () => await import("./AppAction.js")), Ht = /
1448
1448
  currentApp: o
1449
1449
  } = v(), {
1450
1450
  data: a
1451
- } = Et(e.actions), {
1451
+ } = Rt(e.actions), {
1452
1452
  isTrashedModalOpen: n,
1453
1453
  onTrashedCancel: u
1454
- } = Ct(), {
1454
+ } = xt(), {
1455
1455
  isActionDisableModalOpen: p,
1456
- onActionDisableCancel: l
1457
- } = Tt(), {
1458
- handleDragEnd: d,
1456
+ onActionDisableCancel: i
1457
+ } = wt(), {
1458
+ handleDragEnd: l,
1459
1459
  handleDragOver: h,
1460
- handleDragStart: i,
1460
+ handleDragStart: d,
1461
1461
  sensors: f
1462
- } = Qt();
1463
- je();
1464
- const m = ce("publish", a), S = ce("create", a);
1465
- return e && /* @__PURE__ */ N(G, { children: [
1466
- /* @__PURE__ */ c(Ve, { render: () => S ? /* @__PURE__ */ c(M, { fallback: /* @__PURE__ */ c(U, {}), children: /* @__PURE__ */ c(Wt, {}) }) : null, children: /* @__PURE__ */ c(We, { app: o }) }),
1467
- /* @__PURE__ */ c(re, { className: "flex-grow-1", children: /* @__PURE__ */ N(Re, { sensors: f, modifiers: [Ne], onDragStart: i, onDragEnd: d, onDragOver: h, children: [
1468
- /* @__PURE__ */ c(re.Col, { sm: "3", lg: "2", xl: "3", className: "border-end pt-16 pe-16 d-none d-lg-block", as: "aside", children: /* @__PURE__ */ N(M, { fallback: /* @__PURE__ */ c(U, {}), children: [
1469
- /* @__PURE__ */ c(jt, {}),
1470
- m && /* @__PURE__ */ c(Ht, {})
1462
+ } = Pt();
1463
+ _e();
1464
+ const m = ae("publish", a), D = ae("create", a);
1465
+ return e && /* @__PURE__ */ E(G, { children: [
1466
+ /* @__PURE__ */ c(ze, { render: () => D ? /* @__PURE__ */ c(M, { fallback: /* @__PURE__ */ c(U, {}), children: /* @__PURE__ */ c(jt, {}) }) : null, children: /* @__PURE__ */ c(je, { app: o }) }),
1467
+ /* @__PURE__ */ c(te, { className: "flex-grow-1", children: /* @__PURE__ */ E(Ce, { sensors: f, modifiers: [Fe], onDragStart: d, onDragEnd: l, onDragOver: h, children: [
1468
+ /* @__PURE__ */ c(te.Col, { sm: "3", lg: "2", xl: "3", className: "border-end pt-16 pe-16 d-none d-lg-block", as: "aside", children: /* @__PURE__ */ E(M, { fallback: /* @__PURE__ */ c(U, {}), children: [
1469
+ /* @__PURE__ */ c(_t, {}),
1470
+ m && /* @__PURE__ */ c(Vt, {})
1471
1471
  ] }) }),
1472
- /* @__PURE__ */ N(re.Col, { sm: "4", md: "8", lg: "6", xl: "9", children: [
1473
- /* @__PURE__ */ c($t, {}),
1474
- /* @__PURE__ */ c(Vt, {}),
1475
- /* @__PURE__ */ c(Bt, {})
1472
+ /* @__PURE__ */ E(te.Col, { sm: "4", md: "8", lg: "6", xl: "9", children: [
1473
+ /* @__PURE__ */ c(Bt, {}),
1474
+ /* @__PURE__ */ c(zt, {}),
1475
+ /* @__PURE__ */ c(Lt, {})
1476
1476
  ] }),
1477
- /* @__PURE__ */ N(M, { fallback: /* @__PURE__ */ c(U, {}), children: [
1478
- /* @__PURE__ */ c(Gt, {}),
1479
- e.enableOnboarding && /* @__PURE__ */ c(Yt, { id: "showOnboardingTrash", items: [{
1477
+ /* @__PURE__ */ E(M, { fallback: /* @__PURE__ */ c(U, {}), children: [
1478
+ /* @__PURE__ */ c(Wt, {}),
1479
+ e.enableOnboarding && /* @__PURE__ */ c(Jt, { id: "showOnboardingTrash", items: [{
1480
1480
  src: "onboarding/illu-trash-menu.svg",
1481
1481
  alt: "explorer.modal.onboarding.trash.screen1.alt",
1482
1482
  text: "explorer.modal.onboarding.trash.screen1.title"
@@ -1494,40 +1494,40 @@ const Wt = /* @__PURE__ */ Q(async () => await import("./AppAction.js")), Ht = /
1494
1494
  nextText: "explorer.modal.onboarding.trash.next",
1495
1495
  closeText: "explorer.modal.onboarding.trash.close"
1496
1496
  } }),
1497
- n && /* @__PURE__ */ c(Xt, { isOpen: n, onCancel: u }),
1498
- p && /* @__PURE__ */ c(Jt, { isOpen: p, onCancel: l })
1497
+ n && /* @__PURE__ */ c(Gt, { isOpen: n, onCancel: u }),
1498
+ p && /* @__PURE__ */ c(Ht, { isOpen: p, onCancel: i })
1499
1499
  ] })
1500
1500
  ] }) })
1501
1501
  ] });
1502
1502
  };
1503
1503
  export {
1504
- hs as A,
1505
- ms as B,
1506
- Fs as E,
1504
+ ds as A,
1505
+ fs as B,
1506
+ Ts as E,
1507
1507
  F as a,
1508
- Et as b,
1508
+ Rt as b,
1509
1509
  W as c,
1510
- Cs as d,
1511
- A as e,
1512
- ne as f,
1513
- ds as g,
1510
+ xs as d,
1511
+ Q as e,
1512
+ re as f,
1513
+ is as g,
1514
1514
  Y as h,
1515
- fs as i,
1516
- ps as j,
1515
+ hs as i,
1516
+ us as j,
1517
1517
  X as k,
1518
- Is as l,
1519
- Dt as m,
1520
- Ss as n,
1521
- gs as o,
1522
- us as p,
1523
- xs as q,
1524
- Ts as r,
1525
- St as s,
1526
- bs as t,
1518
+ ms as l,
1519
+ yt as m,
1520
+ Is as n,
1521
+ ps as o,
1522
+ ls as p,
1523
+ bs as q,
1524
+ ws as r,
1525
+ It as s,
1526
+ Ds as t,
1527
1527
  T as u,
1528
- ws as v,
1529
- Ds as w,
1530
- ys as x,
1531
- At as y,
1528
+ Ss as v,
1529
+ ys as w,
1530
+ gs as x,
1531
+ Et as y,
1532
1532
  V as z
1533
1533
  };