@burdenoff/microfe-files 2026.1123.2 → 2026.1125.1
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/files/components/ConfirmDialog.js +20 -15
- package/dist/files/components/ConfirmDialog.js.map +1 -1
- package/dist/files/components/CopyDialog.js +99 -81
- package/dist/files/components/CopyDialog.js.map +1 -1
- package/dist/files/components/FileBrowser.js +124 -123
- package/dist/files/components/FileBrowser.js.map +1 -1
- package/dist/files/components/FileInfoPanel.js +109 -101
- package/dist/files/components/FileInfoPanel.js.map +1 -1
- package/dist/files/components/FileVersionPanel.js +113 -109
- package/dist/files/components/FileVersionPanel.js.map +1 -1
- package/dist/files/components/MoveDialog.js +75 -65
- package/dist/files/components/MoveDialog.js.map +1 -1
- package/dist/files/components/ShareAccessParts.js +8 -7
- package/dist/files/components/ShareAccessParts.js.map +1 -1
- package/dist/files/components/ShareDialog.js +17 -16
- package/dist/files/components/ShareDialog.js.map +1 -1
- package/dist/files/components/SharedFolderView.js +29 -26
- package/dist/files/components/SharedFolderView.js.map +1 -1
- package/dist/files/components/UploadQueue.js +1 -0
- package/dist/files/components/UploadQueue.js.map +1 -1
- package/dist/files/components/loadingSystem.d.ts +64 -0
- package/dist/files/components/loadingSystem.js +56 -0
- package/dist/files/components/loadingSystem.js.map +1 -0
- package/dist/files/pages/BrowserPage.js +495 -475
- package/dist/files/pages/BrowserPage.js.map +1 -1
- package/dist/files/v2/FilesPage.js +10 -9
- package/dist/files/v2/FilesPage.js.map +1 -1
- package/package.json +2 -2
|
@@ -12,23 +12,24 @@ import { useSharePermissions as oe } from "../hooks/useSharePermissions.js";
|
|
|
12
12
|
import { shareEntryDeniedReason as se, sharePermissionMessages as ce } from "../utils/sharePermission.js";
|
|
13
13
|
import { canStartFileDrag as le, canStartFolderDrag as ue, fileCapabilities as a, folderCapabilities as o, isShareOffered as de, shareLookupTarget as fe } from "../utils/itemCapabilities.js";
|
|
14
14
|
import { useDragDrop as pe } from "../hooks/useDragDrop.js";
|
|
15
|
-
import {
|
|
16
|
-
import {
|
|
17
|
-
import {
|
|
18
|
-
import {
|
|
19
|
-
import {
|
|
15
|
+
import { SkeletonBlock as me } from "./loadingSystem.js";
|
|
16
|
+
import { useState as he } from "react";
|
|
17
|
+
import { ArrowDown as ge, ArrowUp as _e, ArrowUpDown as ve, Folder as ye, Star as be } from "lucide-react";
|
|
18
|
+
import { Fragment as xe, jsx as s, jsxs as c } from "react/jsx-runtime";
|
|
19
|
+
import { ShowTechnicalDetails as Se } from "@burdenoff/fe-libs/ui";
|
|
20
|
+
import { useI18n as Ce } from "@burdenoff/fe-libs/shared/providers/shell/I18nProvider";
|
|
20
21
|
// src/files/components/FileBrowser.tsx
|
|
21
|
-
var l = ({ files: l, folders:
|
|
22
|
-
let { t: O } =
|
|
22
|
+
var l = ({ files: l, folders: u, loading: we = !1, error: d = null, preserveSortOrder: Te = !1, onFilePreview: Ee, onFileShare: f, onFileDelete: p, onFileRestore: m, onFileFavorite: h, onFileRename: g, onFileDownload: _, onFileCopy: v, onFileMove: y, onFileInfo: b, onFolderOpen: De, onFolderShare: x, onFolderDelete: S, onFolderRestore: C, onFolderRename: w, onFolderFavorite: T, onFolderCopy: Oe, onFolderMove: E, onFolderInfo: D, onMoveFile: ke, onCopyFile: Ae, onMoveFolder: je, onCopyFolder: Me }) => {
|
|
23
|
+
let { t: O } = Ce(), { viewMode: Ne, sortBy: k, sortDirection: A, selectedFiles: Pe, selectedFolders: Fe } = e(), { navigationV2: Ie = !1 } = t(), [Le, Re] = he(null), [ze, j] = he({
|
|
23
24
|
draggedItem: null,
|
|
24
25
|
dropTargetFolderId: null
|
|
25
|
-
}), [M,
|
|
26
|
-
onMoveFile:
|
|
27
|
-
onCopyFile:
|
|
28
|
-
onMoveFolder:
|
|
29
|
-
onCopyFolder:
|
|
30
|
-
}),
|
|
31
|
-
le(e, t) && (
|
|
26
|
+
}), [M, Be] = he(null), N = oe(), { draggedItem: P, startDrag: Ve, endDrag: He, handleDrop: Ue } = pe({
|
|
27
|
+
onMoveFile: ke,
|
|
28
|
+
onCopyFile: Ae,
|
|
29
|
+
onMoveFolder: je,
|
|
30
|
+
onCopyFolder: Me
|
|
31
|
+
}), We = (e, t) => {
|
|
32
|
+
le(e, t) && (Ve({
|
|
32
33
|
type: "file",
|
|
33
34
|
item: e,
|
|
34
35
|
operation: t
|
|
@@ -40,8 +41,8 @@ var l = ({ files: l, folders: Ce, loading: we = !1, error: u = null, preserveSor
|
|
|
40
41
|
},
|
|
41
42
|
dropTargetFolderId: null
|
|
42
43
|
}));
|
|
43
|
-
},
|
|
44
|
-
ue(e, t) && (
|
|
44
|
+
}, Ge = (e, t) => {
|
|
45
|
+
ue(e, t) && (Ve({
|
|
45
46
|
type: "folder",
|
|
46
47
|
item: e,
|
|
47
48
|
operation: t
|
|
@@ -53,68 +54,68 @@ var l = ({ files: l, folders: Ce, loading: we = !1, error: u = null, preserveSor
|
|
|
53
54
|
},
|
|
54
55
|
dropTargetFolderId: null
|
|
55
56
|
}));
|
|
56
|
-
},
|
|
57
|
-
|
|
57
|
+
}, Ke = () => {
|
|
58
|
+
He(), j({
|
|
58
59
|
draggedItem: null,
|
|
59
60
|
dropTargetFolderId: null
|
|
60
61
|
});
|
|
61
|
-
},
|
|
62
|
-
P && (await
|
|
62
|
+
}, qe = async (e) => {
|
|
63
|
+
P && (await Ue(e.id), j({
|
|
63
64
|
draggedItem: null,
|
|
64
65
|
dropTargetFolderId: null
|
|
65
66
|
}));
|
|
66
|
-
},
|
|
67
|
+
}, Je = (e) => {
|
|
67
68
|
j((t) => ({
|
|
68
69
|
...t,
|
|
69
70
|
dropTargetFolderId: e
|
|
70
71
|
}));
|
|
71
|
-
},
|
|
72
|
+
}, Ye = () => {
|
|
72
73
|
j((e) => ({
|
|
73
74
|
...e,
|
|
74
75
|
dropTargetFolderId: null
|
|
75
76
|
}));
|
|
76
|
-
},
|
|
77
|
-
let r =
|
|
78
|
-
f && r && N.ensure(r),
|
|
77
|
+
}, Xe = (e, t, n) => {
|
|
78
|
+
let r = R(e);
|
|
79
|
+
f && r && N.ensure(r), Be({
|
|
79
80
|
item: e,
|
|
80
81
|
type: "file",
|
|
81
82
|
x: t,
|
|
82
83
|
y: n
|
|
83
84
|
});
|
|
84
|
-
},
|
|
85
|
-
let r =
|
|
86
|
-
x && r && N.ensure(r),
|
|
85
|
+
}, Ze = (e, t, n) => {
|
|
86
|
+
let r = U(e);
|
|
87
|
+
x && r && N.ensure(r), Be({
|
|
87
88
|
item: e,
|
|
88
89
|
type: "folder",
|
|
89
90
|
x: t,
|
|
90
91
|
y: n
|
|
91
92
|
});
|
|
92
|
-
},
|
|
93
|
-
|
|
94
|
-
},
|
|
95
|
-
let t =
|
|
93
|
+
}, Qe = () => {
|
|
94
|
+
Be(null);
|
|
95
|
+
}, $e = (e) => a(e).canPreview, F = (e) => a(e).canCopy, I = (e) => a(e).canUpdate, L = (e) => a(e).canMove, et = (e) => a(e).canDelete, tt = (e) => L(e) || F(e), nt = (e) => de(a(e).share), R = (e) => fe(a(e).share), rt = (e) => o(e).canOpen, z = (e) => o(e).canUpdate, B = (e) => o(e).canMove, V = (e) => o(e).canDelete, it = (e) => B(e) || !!Me, at = (e) => o(e).canAcceptDrop, H = (e) => de(o(e).share), U = (e) => fe(o(e).share), ot = ce(O), st = (e) => e ? se(N.statusOf(e), ot) : void 0, ct = (e) => st(R(e)), W = (e) => st(U(e)), G = f ? (e) => {
|
|
96
|
+
let t = R(e);
|
|
96
97
|
f(e, t ? N.guard(t) : void 0);
|
|
97
|
-
} : void 0,
|
|
98
|
-
let t =
|
|
98
|
+
} : void 0, K = x ? (e) => {
|
|
99
|
+
let t = U(e);
|
|
99
100
|
x(e, t ? N.guard(t) : void 0);
|
|
100
|
-
} : void 0,
|
|
101
|
+
} : void 0, q = (e) => !e || !(e.kind === "file" ? f : x) ? {} : {
|
|
101
102
|
onPointerOver: () => N.prefetch(e),
|
|
102
103
|
onPointerDown: () => N.ensure(e),
|
|
103
104
|
onFocus: () => N.ensure(e)
|
|
104
|
-
},
|
|
105
|
+
}, J = () => {
|
|
105
106
|
if (!M) return [];
|
|
106
107
|
if (M.type === "file") {
|
|
107
108
|
let e = M.item;
|
|
108
109
|
return re({
|
|
109
|
-
onShare:
|
|
110
|
-
shareDeniedReason:
|
|
110
|
+
onShare: G && nt(e) ? () => G(e) : void 0,
|
|
111
|
+
shareDeniedReason: ct(e),
|
|
111
112
|
onDownload: _ ? () => _(e) : void 0,
|
|
112
113
|
onCopy: v && F(e) ? () => v(e) : void 0,
|
|
113
114
|
onRename: g && I(e) ? () => g(e) : void 0,
|
|
114
115
|
onStar: h && I(e) ? () => h(e) : void 0,
|
|
115
116
|
onMove: y && L(e) ? () => y(e) : void 0,
|
|
116
117
|
onInfo: b ? () => b(e) : void 0,
|
|
117
|
-
onDelete: p &&
|
|
118
|
+
onDelete: p && et(e) ? () => p(e) : void 0,
|
|
118
119
|
onRestore: m ? () => m(e) : void 0,
|
|
119
120
|
isStarred: e.starred
|
|
120
121
|
}, O);
|
|
@@ -122,28 +123,28 @@ var l = ({ files: l, folders: Ce, loading: we = !1, error: u = null, preserveSor
|
|
|
122
123
|
{
|
|
123
124
|
let e = M.item;
|
|
124
125
|
return ie({
|
|
125
|
-
onShare:
|
|
126
|
-
shareDeniedReason:
|
|
127
|
-
onRename: w &&
|
|
128
|
-
onStar: T &&
|
|
129
|
-
onMove: E &&
|
|
126
|
+
onShare: K && H(e) ? () => K(e) : void 0,
|
|
127
|
+
shareDeniedReason: W(e),
|
|
128
|
+
onRename: w && z(e) ? () => w(e) : void 0,
|
|
129
|
+
onStar: T && z(e) ? () => T(e) : void 0,
|
|
130
|
+
onMove: E && B(e) ? () => E(e) : void 0,
|
|
130
131
|
onInfo: D ? () => D(e) : void 0,
|
|
131
|
-
onDelete: S &&
|
|
132
|
+
onDelete: S && V(e) ? () => S(e) : void 0,
|
|
132
133
|
onRestore: C ? () => C(e) : void 0,
|
|
133
134
|
isStarred: e.starred
|
|
134
135
|
}, O);
|
|
135
136
|
}
|
|
136
|
-
}, Y =
|
|
137
|
+
}, Y = Te ? l : ae(l, k, A), X = Te ? u : ae(u, k, A), Z = Ie && !Te, Q = (e) => k === e ? A === "asc" ? "ascending" : "descending" : "none", lt = (t) => {
|
|
137
138
|
e.setState((e) => ({
|
|
138
139
|
sortBy: t,
|
|
139
140
|
sortDirection: e.sortBy === t && e.sortDirection === "asc" ? "desc" : "asc"
|
|
140
141
|
}));
|
|
141
142
|
}, $ = (e, t, n = "start") => {
|
|
142
143
|
if (!Z) return t;
|
|
143
|
-
let r = k === e, ee = r ? A === "asc" ?
|
|
144
|
+
let r = k === e, ee = r ? A === "asc" ? _e : ge : ve;
|
|
144
145
|
return /* @__PURE__ */ c("button", {
|
|
145
146
|
type: "button",
|
|
146
|
-
onClick: () =>
|
|
147
|
+
onClick: () => lt(e),
|
|
147
148
|
className: `inline-flex items-center gap-1 rounded px-1 -mx-1 transition-colors hover:text-text-primary focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-action-primary-border ${n === "end" ? "flex-row-reverse" : ""} ${r ? "text-text-primary" : ""}`,
|
|
148
149
|
"aria-label": i(O, "files.browser.sortBy", "Sort by {{column}}", { column: t }),
|
|
149
150
|
children: [t, /* @__PURE__ */ s(ee, {
|
|
@@ -161,13 +162,13 @@ var l = ({ files: l, folders: Ce, loading: we = !1, error: u = null, preserveSor
|
|
|
161
162
|
className: "grid grid-cols-2 gap-4 @md:grid-cols-3 @lg:grid-cols-4 @xl:grid-cols-5",
|
|
162
163
|
children: Array.from({ length: 10 }).map((e, t) => /* @__PURE__ */ c("div", {
|
|
163
164
|
className: "overflow-hidden rounded-card border border-border-seam bg-bg-surface",
|
|
164
|
-
children: [/* @__PURE__ */ s(
|
|
165
|
+
children: [/* @__PURE__ */ s(me, { className: "aspect-[4/3] w-full animate-vc-shimmer bg-bg-sunken" }), /* @__PURE__ */ c("div", {
|
|
165
166
|
className: "space-y-2 p-3",
|
|
166
|
-
children: [/* @__PURE__ */ s(
|
|
167
|
+
children: [/* @__PURE__ */ s(me, { className: "h-3 w-3/4 animate-vc-shimmer rounded bg-bg-sunken" }), /* @__PURE__ */ s(me, { className: "h-3 w-1/2 animate-vc-shimmer rounded bg-bg-sunken" })]
|
|
167
168
|
})]
|
|
168
169
|
}, t))
|
|
169
170
|
})
|
|
170
|
-
}) :
|
|
171
|
+
}) : d ? /* @__PURE__ */ s("div", {
|
|
171
172
|
className: "flex items-center justify-center min-h-[500px]",
|
|
172
173
|
children: /* @__PURE__ */ c("div", {
|
|
173
174
|
className: "text-center max-w-md",
|
|
@@ -176,18 +177,18 @@ var l = ({ files: l, folders: Ce, loading: we = !1, error: u = null, preserveSor
|
|
|
176
177
|
className: "mb-3 text-xl font-semibold text-status-error-text",
|
|
177
178
|
children: i(O, "files.browser.loadError", "Failed to load files")
|
|
178
179
|
}),
|
|
179
|
-
|
|
180
|
+
Ie ? /* @__PURE__ */ c("div", {
|
|
180
181
|
className: "mb-6 space-y-2",
|
|
181
182
|
children: [/* @__PURE__ */ s("p", {
|
|
182
183
|
className: "text-sm text-text-secondary",
|
|
183
184
|
children: i(O, "files.browser.loadErrorHelp", "Something went wrong while loading your files. Try again in a moment.")
|
|
184
|
-
}),
|
|
185
|
+
}), d.message && /* @__PURE__ */ s(Se, {
|
|
185
186
|
copyable: !0,
|
|
186
|
-
children:
|
|
187
|
+
children: d.message
|
|
187
188
|
})]
|
|
188
189
|
}) : /* @__PURE__ */ s("p", {
|
|
189
190
|
className: "mb-6 text-sm text-text-secondary",
|
|
190
|
-
children:
|
|
191
|
+
children: d.message || i(O, "files.browser.unexpectedError", "An unexpected error occurred")
|
|
191
192
|
}),
|
|
192
193
|
/* @__PURE__ */ s("button", {
|
|
193
194
|
type: "button",
|
|
@@ -197,12 +198,12 @@ var l = ({ files: l, folders: Ce, loading: we = !1, error: u = null, preserveSor
|
|
|
197
198
|
})
|
|
198
199
|
]
|
|
199
200
|
})
|
|
200
|
-
}) : l.length === 0 &&
|
|
201
|
+
}) : l.length === 0 && u.length === 0 ? /* @__PURE__ */ s(xe, { children: M && /* @__PURE__ */ s(ne, {
|
|
201
202
|
x: M.x,
|
|
202
203
|
y: M.y,
|
|
203
|
-
onClose:
|
|
204
|
-
items:
|
|
205
|
-
}) }) :
|
|
204
|
+
onClose: Qe,
|
|
205
|
+
items: J()
|
|
206
|
+
}) }) : Ne === "list" ? Ne === "list" ? /* @__PURE__ */ c("div", {
|
|
206
207
|
className: "@container bg-bg-canvas",
|
|
207
208
|
children: [
|
|
208
209
|
/* @__PURE__ */ c("div", {
|
|
@@ -241,27 +242,27 @@ var l = ({ files: l, folders: Ce, loading: we = !1, error: u = null, preserveSor
|
|
|
241
242
|
/* @__PURE__ */ c("div", {
|
|
242
243
|
className: "divide-y divide-border-subtle",
|
|
243
244
|
children: [X.map((t) => /* @__PURE__ */ c("div", {
|
|
244
|
-
className: `group flex items-center gap-3 border-b border-border-seam bg-bg-surface p-3 transition-colors hover:bg-bg-sunken focus-within:bg-bg-sunken ${
|
|
245
|
+
className: `group flex items-center gap-3 border-b border-border-seam bg-bg-surface p-3 transition-colors hover:bg-bg-sunken focus-within:bg-bg-sunken ${ze.dropTargetFolderId === t.id && P?.item.id !== t.id ? "bg-action-primary-bg/10" : ""} ${P?.item.id === t.id ? "opacity-50" : ""}`,
|
|
245
246
|
onClick: () => {
|
|
246
|
-
|
|
247
|
+
rt(t) && De?.(t);
|
|
247
248
|
},
|
|
248
249
|
onDragOver: (e) => {
|
|
249
|
-
P && P.item.id !== t.id &&
|
|
250
|
+
P && P.item.id !== t.id && at(t) && (e.preventDefault(), Je(t.id));
|
|
250
251
|
},
|
|
251
|
-
onDragLeave:
|
|
252
|
+
onDragLeave: Ye,
|
|
252
253
|
onDrop: async (e) => {
|
|
253
|
-
e.preventDefault(), P && P.item.id !== t.id &&
|
|
254
|
+
e.preventDefault(), P && P.item.id !== t.id && at(t) && await qe(t);
|
|
254
255
|
},
|
|
255
256
|
onContextMenu: (e) => {
|
|
256
|
-
e.preventDefault(),
|
|
257
|
+
e.preventDefault(), Ze(t, e.clientX, e.clientY);
|
|
257
258
|
},
|
|
258
|
-
...
|
|
259
|
+
...q(U(t)),
|
|
259
260
|
children: [
|
|
260
261
|
/* @__PURE__ */ s("div", {
|
|
261
262
|
className: "flex-shrink-0",
|
|
262
263
|
children: /* @__PURE__ */ s("input", {
|
|
263
264
|
type: "checkbox",
|
|
264
|
-
checked:
|
|
265
|
+
checked: Fe.has(t.id),
|
|
265
266
|
onChange: (n) => {
|
|
266
267
|
n.stopPropagation(), e.getState().toggleFolderSelection(t.id);
|
|
267
268
|
},
|
|
@@ -269,7 +270,7 @@ var l = ({ files: l, folders: Ce, loading: we = !1, error: u = null, preserveSor
|
|
|
269
270
|
"aria-label": `Select ${t.name}`
|
|
270
271
|
})
|
|
271
272
|
}),
|
|
272
|
-
/* @__PURE__ */ s(
|
|
273
|
+
/* @__PURE__ */ s(ye, { className: "size-6 text-action-primary-bg flex-shrink-0" }),
|
|
273
274
|
/* @__PURE__ */ s("div", {
|
|
274
275
|
className: "flex-1 min-w-0",
|
|
275
276
|
children: /* @__PURE__ */ c("div", {
|
|
@@ -277,12 +278,12 @@ var l = ({ files: l, folders: Ce, loading: we = !1, error: u = null, preserveSor
|
|
|
277
278
|
children: [/* @__PURE__ */ s("button", {
|
|
278
279
|
type: "button",
|
|
279
280
|
onClick: (e) => {
|
|
280
|
-
e.stopPropagation(),
|
|
281
|
+
e.stopPropagation(), rt(t) && De?.(t);
|
|
281
282
|
},
|
|
282
283
|
className: "min-w-0 truncate rounded-sm text-left font-text-md font-weight-medium text-text-primary focus:outline-none focus-visible:ring-2 focus-visible:ring-action-primary-bg",
|
|
283
284
|
"aria-label": `${i(O, "files.browser.openFolder", "Open folder")} ${t.name}`,
|
|
284
285
|
children: t.name
|
|
285
|
-
}), t.starred && /* @__PURE__ */ s(
|
|
286
|
+
}), t.starred && /* @__PURE__ */ s(be, { className: "size-3 flex-shrink-0 fill-status-warning-text text-status-warning-text" })]
|
|
286
287
|
})
|
|
287
288
|
}),
|
|
288
289
|
/* @__PURE__ */ s("div", {
|
|
@@ -320,15 +321,15 @@ var l = ({ files: l, folders: Ce, loading: we = !1, error: u = null, preserveSor
|
|
|
320
321
|
/* @__PURE__ */ c("div", {
|
|
321
322
|
className: "flex w-32 flex-shrink-0 items-center gap-1 opacity-0 transition-opacity group-hover:opacity-100 group-focus-within:opacity-100",
|
|
322
323
|
children: [
|
|
323
|
-
|
|
324
|
+
H(t) && K && /* @__PURE__ */ s("button", {
|
|
324
325
|
type: "button",
|
|
325
326
|
onClick: (e) => {
|
|
326
|
-
e.stopPropagation(),
|
|
327
|
+
e.stopPropagation(), K(t);
|
|
327
328
|
},
|
|
328
|
-
"data-share-denied":
|
|
329
|
-
className: `p-1.5 rounded transition-colors hover:bg-action-ghost-bg-hover ${
|
|
329
|
+
"data-share-denied": W(t) !== void 0 || void 0,
|
|
330
|
+
className: `p-1.5 rounded transition-colors hover:bg-action-ghost-bg-hover ${W(t) === void 0 ? "" : "opacity-50"}`,
|
|
330
331
|
"aria-label": i(O, "files.browser.share", "Share"),
|
|
331
|
-
title:
|
|
332
|
+
title: W(t) ?? i(O, "files.browser.shareFolder", "Share folder"),
|
|
332
333
|
children: /* @__PURE__ */ s("svg", {
|
|
333
334
|
className: "size-4 text-text-primary",
|
|
334
335
|
fill: "none",
|
|
@@ -342,7 +343,7 @@ var l = ({ files: l, folders: Ce, loading: we = !1, error: u = null, preserveSor
|
|
|
342
343
|
})
|
|
343
344
|
})
|
|
344
345
|
}),
|
|
345
|
-
|
|
346
|
+
z(t) && w && /* @__PURE__ */ s("button", {
|
|
346
347
|
type: "button",
|
|
347
348
|
onClick: (e) => {
|
|
348
349
|
e.stopPropagation(), w(t);
|
|
@@ -363,7 +364,7 @@ var l = ({ files: l, folders: Ce, loading: we = !1, error: u = null, preserveSor
|
|
|
363
364
|
})
|
|
364
365
|
})
|
|
365
366
|
}),
|
|
366
|
-
|
|
367
|
+
V(t) && S && /* @__PURE__ */ s("button", {
|
|
367
368
|
type: "button",
|
|
368
369
|
onClick: (e) => {
|
|
369
370
|
e.stopPropagation(), S(t);
|
|
@@ -388,20 +389,20 @@ var l = ({ files: l, folders: Ce, loading: we = !1, error: u = null, preserveSor
|
|
|
388
389
|
onClick: (e) => e.stopPropagation(),
|
|
389
390
|
children: /* @__PURE__ */ s(te, {
|
|
390
391
|
items: ie({
|
|
391
|
-
onShare:
|
|
392
|
-
shareDeniedReason:
|
|
393
|
-
onRename:
|
|
394
|
-
onStar:
|
|
395
|
-
onMove:
|
|
392
|
+
onShare: H(t) && K ? () => K(t) : void 0,
|
|
393
|
+
shareDeniedReason: W(t),
|
|
394
|
+
onRename: z(t) && w ? () => w(t) : void 0,
|
|
395
|
+
onStar: z(t) && T ? () => T(t) : void 0,
|
|
396
|
+
onMove: B(t) && E ? () => E(t) : void 0,
|
|
396
397
|
onInfo: () => D?.(t),
|
|
397
398
|
onRestore: C ? () => C(t) : void 0,
|
|
398
|
-
onDelete:
|
|
399
|
+
onDelete: V(t) && S ? () => S(t) : void 0,
|
|
399
400
|
isStarred: t.starred
|
|
400
401
|
}, O),
|
|
401
|
-
isOpen:
|
|
402
|
+
isOpen: Le === t.id,
|
|
402
403
|
onToggle: (e) => {
|
|
403
|
-
let n =
|
|
404
|
-
e && x && n && N.ensure(n),
|
|
404
|
+
let n = U(t);
|
|
405
|
+
e && x && n && N.ensure(n), Re(e ? t.id : null);
|
|
405
406
|
}
|
|
406
407
|
})
|
|
407
408
|
})
|
|
@@ -410,15 +411,15 @@ var l = ({ files: l, folders: Ce, loading: we = !1, error: u = null, preserveSor
|
|
|
410
411
|
]
|
|
411
412
|
}, t.id)), Y.map((e) => /* @__PURE__ */ s("div", {
|
|
412
413
|
className: "contents",
|
|
413
|
-
...
|
|
414
|
+
...q(R(e)),
|
|
414
415
|
children: /* @__PURE__ */ s(r, {
|
|
415
416
|
file: e,
|
|
416
|
-
isSelected:
|
|
417
|
+
isSelected: Pe.has(e.id),
|
|
417
418
|
isDragging: P?.item.id === e.id,
|
|
418
|
-
onPreview:
|
|
419
|
-
onShare:
|
|
420
|
-
shareDeniedReason:
|
|
421
|
-
onDelete:
|
|
419
|
+
onPreview: $e(e) ? Ee : void 0,
|
|
420
|
+
onShare: nt(e) ? G : void 0,
|
|
421
|
+
shareDeniedReason: ct(e),
|
|
422
|
+
onDelete: et(e) ? p : void 0,
|
|
422
423
|
onRestore: m,
|
|
423
424
|
onFavorite: I(e) ? h : void 0,
|
|
424
425
|
onRename: I(e) ? g : void 0,
|
|
@@ -426,17 +427,17 @@ var l = ({ files: l, folders: Ce, loading: we = !1, error: u = null, preserveSor
|
|
|
426
427
|
onCopy: F(e) ? v : void 0,
|
|
427
428
|
onMove: L(e) ? y : void 0,
|
|
428
429
|
onInfo: b,
|
|
429
|
-
onDragStart:
|
|
430
|
-
onDragEnd:
|
|
431
|
-
onContextMenu:
|
|
430
|
+
onDragStart: tt(e) ? We : void 0,
|
|
431
|
+
onDragEnd: Ke,
|
|
432
|
+
onContextMenu: Xe
|
|
432
433
|
})
|
|
433
434
|
}, e.id))]
|
|
434
435
|
}),
|
|
435
436
|
M && /* @__PURE__ */ s(ne, {
|
|
436
437
|
x: M.x,
|
|
437
438
|
y: M.y,
|
|
438
|
-
onClose:
|
|
439
|
-
items:
|
|
439
|
+
onClose: Qe,
|
|
440
|
+
items: J()
|
|
440
441
|
})
|
|
441
442
|
]
|
|
442
443
|
}) : null : /* @__PURE__ */ c("div", {
|
|
@@ -451,27 +452,27 @@ var l = ({ files: l, folders: Ce, loading: we = !1, error: u = null, preserveSor
|
|
|
451
452
|
className: "grid grid-cols-1 @sm:grid-cols-2 @lg:grid-cols-3 @xl:grid-cols-4 gap-2",
|
|
452
453
|
children: X.map((e) => /* @__PURE__ */ s("div", {
|
|
453
454
|
className: "contents",
|
|
454
|
-
...
|
|
455
|
+
...q(U(e)),
|
|
455
456
|
children: /* @__PURE__ */ s(ee, {
|
|
456
457
|
folder: e,
|
|
457
|
-
isSelected:
|
|
458
|
+
isSelected: Fe.has(e.id),
|
|
458
459
|
isDragging: P?.item.id === e.id,
|
|
459
|
-
isDropTarget:
|
|
460
|
+
isDropTarget: ze.dropTargetFolderId === e.id,
|
|
460
461
|
draggedItem: P,
|
|
461
|
-
onOpen:
|
|
462
|
-
onShare:
|
|
463
|
-
shareDeniedReason:
|
|
464
|
-
onDelete:
|
|
462
|
+
onOpen: rt(e) ? De : void 0,
|
|
463
|
+
onShare: H(e) ? K : void 0,
|
|
464
|
+
shareDeniedReason: W(e),
|
|
465
|
+
onDelete: V(e) ? S : void 0,
|
|
465
466
|
onRestore: C,
|
|
466
|
-
onRename:
|
|
467
|
-
onFavorite:
|
|
468
|
-
onCopy:
|
|
469
|
-
onMove:
|
|
467
|
+
onRename: z(e) ? w : void 0,
|
|
468
|
+
onFavorite: z(e) ? T : void 0,
|
|
469
|
+
onCopy: Oe,
|
|
470
|
+
onMove: B(e) ? E : void 0,
|
|
470
471
|
onInfo: D,
|
|
471
|
-
onDragStart:
|
|
472
|
-
onDragEnd:
|
|
473
|
-
onDrop:
|
|
474
|
-
onContextMenu:
|
|
472
|
+
onDragStart: it(e) ? Ge : void 0,
|
|
473
|
+
onDragEnd: Ke,
|
|
474
|
+
onDrop: at(e) ? qe : void 0,
|
|
475
|
+
onContextMenu: Ze
|
|
475
476
|
})
|
|
476
477
|
}, e.id))
|
|
477
478
|
})]
|
|
@@ -483,15 +484,15 @@ var l = ({ files: l, folders: Ce, loading: we = !1, error: u = null, preserveSor
|
|
|
483
484
|
className: "grid grid-cols-2 @md:grid-cols-3 @lg:grid-cols-4 @xl:grid-cols-5 gap-4",
|
|
484
485
|
children: Y.map((e) => /* @__PURE__ */ s("div", {
|
|
485
486
|
className: "contents",
|
|
486
|
-
...
|
|
487
|
+
...q(R(e)),
|
|
487
488
|
children: /* @__PURE__ */ s(n, {
|
|
488
489
|
file: e,
|
|
489
|
-
isSelected:
|
|
490
|
+
isSelected: Pe.has(e.id),
|
|
490
491
|
isDragging: P?.item.id === e.id,
|
|
491
|
-
onPreview:
|
|
492
|
-
onShare:
|
|
493
|
-
shareDeniedReason:
|
|
494
|
-
onDelete:
|
|
492
|
+
onPreview: $e(e) ? Ee : void 0,
|
|
493
|
+
onShare: nt(e) ? G : void 0,
|
|
494
|
+
shareDeniedReason: ct(e),
|
|
495
|
+
onDelete: et(e) ? p : void 0,
|
|
495
496
|
onRestore: m,
|
|
496
497
|
onFavorite: I(e) ? h : void 0,
|
|
497
498
|
onRename: I(e) ? g : void 0,
|
|
@@ -499,17 +500,17 @@ var l = ({ files: l, folders: Ce, loading: we = !1, error: u = null, preserveSor
|
|
|
499
500
|
onCopy: F(e) ? v : void 0,
|
|
500
501
|
onMove: L(e) ? y : void 0,
|
|
501
502
|
onInfo: b,
|
|
502
|
-
onDragStart:
|
|
503
|
-
onDragEnd:
|
|
504
|
-
onContextMenu:
|
|
503
|
+
onDragStart: tt(e) ? We : void 0,
|
|
504
|
+
onDragEnd: Ke,
|
|
505
|
+
onContextMenu: Xe
|
|
505
506
|
})
|
|
506
507
|
}, e.id))
|
|
507
508
|
})] }),
|
|
508
509
|
M && /* @__PURE__ */ s(ne, {
|
|
509
510
|
x: M.x,
|
|
510
511
|
y: M.y,
|
|
511
|
-
onClose:
|
|
512
|
-
items:
|
|
512
|
+
onClose: Qe,
|
|
513
|
+
items: J()
|
|
513
514
|
})
|
|
514
515
|
]
|
|
515
516
|
});
|