@epam/ai-dial-publish-panel 1.1.0-dev.174 → 1.1.0-dev.176
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/components/PublishAccessRuleEditor/PublishAccessRuleEditor.d.ts.map +1 -1
- package/components/PublishAccessRules/PublishAccessRules.d.ts +21 -4
- package/components/PublishAccessRules/PublishAccessRules.d.ts.map +1 -1
- package/components/PublishPanel/PublishPanel.d.ts.map +1 -1
- package/index.css +1 -1
- package/index.d.ts +1 -1
- package/index.d.ts.map +1 -1
- package/index.js +908 -909
- package/package.json +3 -4
package/index.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as e from "react";
|
|
2
2
|
import t, { createContext as n, createElement as r, forwardRef as i, memo as a, useCallback as o, useContext as s, useEffect as c, useId as l, useImperativeHandle as u, useLayoutEffect as d, useMemo as f, useRef as p, useState as m } from "react";
|
|
3
|
-
import { BASE_ICON_PROPS as h, BASE_ICON_SIZE as g, ButtonAppearance as _, ButtonDropdown as v, ButtonVariant as y, CloseButton as b, ConfirmationPopup as x, ConfirmationPopupVariant as S, DEFAULT_GRID_DATE_FORMAT_OPTIONS as C, DEFAULT_GRID_DATE_LOCALE as w, DIAL_ICON_SIZE as T, DialBreadcrumb as E, DialCheckbox as ee, DialCollapsibleSidebar as D, DialConditionalResizableContainer as O, DialDateCellRenderer as te, DialEllipsisTooltip as k, DialFileIcon as ne, DialFileName as A, DialFileNodeType as re, DialFolderName as ie, DialGrid as j, DialIcon as ae, DialItemType as oe, DialNoDataContent as se, DialRadioGroup as ce, DialSearch as le, DialSharedEntityIndicator as ue, DialSwitch as de, DialTabs as fe,
|
|
3
|
+
import { BASE_ICON_PROPS as h, BASE_ICON_SIZE as g, ButtonAppearance as _, ButtonDropdown as v, ButtonVariant as y, CloseButton as b, ConfirmationPopup as x, ConfirmationPopupVariant as S, DEFAULT_GRID_DATE_FORMAT_OPTIONS as C, DEFAULT_GRID_DATE_LOCALE as w, DIAL_ICON_SIZE as T, DialBreadcrumb as E, DialCheckbox as ee, DialCollapsibleSidebar as D, DialConditionalResizableContainer as O, DialDateCellRenderer as te, DialEllipsisTooltip as k, DialFileIcon as ne, DialFileName as A, DialFileNodeType as re, DialFolderName as ie, DialGrid as j, DialIcon as ae, DialItemType as oe, DialNoDataContent as se, DialRadioGroup as ce, DialSearch as le, DialSharedEntityIndicator as ue, DialSwitch as de, DialTabs as fe, DialTooltip as pe, DialTooltipContainer as me, DialTooltipContent as he, DialTooltipTrigger as ge, Dropdown as _e, DropdownItemType as ve, DropdownTrigger as ye, ElementSize as be, FlexibleActionsDirection as xe, GhostButton as Se, GhostIconButton as Ce, Input as we, NOT_ALLOWED_SYMBOLS_REGEXP as Te, NeutralButton as Ee, Notification as De, NotificationType as Oe, NotificationVariant as ke, Popup as Ae, PopupSize as je, PrimaryButton as Me, RadioGroupOrientation as Ne, ScreenResolution as Pe, Select as Fe, Skeleton as Ie, SkeletonVariant as Le, Spinner as Re, Tag as ze, TagInput as Be, convertGridDateToDate as Ve, editableContainerProps as He, mergeClasses as Ue, useEditableItem as We } from "@epam/ai-dial-ui-kit";
|
|
4
4
|
import { Fragment as Ge, jsx as M, jsxs as N } from "react/jsx-runtime";
|
|
5
5
|
import { IconAlertCircleFilled as Ke, IconAlertTriangleFilled as qe, IconArrowLeft as Je, IconCaretRightFilled as Ye, IconChevronDown as Xe, IconCircleFilled as Ze, IconCopy as Qe, IconCopyMinus as $e, IconDotsVertical as et, IconDownload as tt, IconExternalLink as nt, IconEye as rt, IconEyeOff as it, IconFile as at, IconFileDescription as ot, IconFileZip as st, IconFolder as ct, IconFolderPlus as lt, IconInfoCircle as ut, IconMessageCircle as dt, IconPencilMinus as ft, IconPlus as pt, IconSearch as mt, IconTrashX as ht, IconUserX as gt, IconX as _t, IconZoomCancel as vt } from "@tabler/icons-react";
|
|
6
6
|
import { createPortal as yt } from "react-dom";
|
|
@@ -2228,48 +2228,48 @@ var Ni = $r(/* @__PURE__ */ "a.abbr.acronym.address.area.article.aside.audio.b.b
|
|
|
2228
2228
|
};
|
|
2229
2229
|
function la() {
|
|
2230
2230
|
let e = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : aa(), t = (e) => la(e);
|
|
2231
|
-
if (t.version = "3.4.
|
|
2231
|
+
if (t.version = "3.4.13", t.removed = [], !e || !e.document || e.document.nodeType !== ia.document || !e.Element) return t.isSupported = !1, t;
|
|
2232
2232
|
let n = e.document, r = n, i = r.currentScript;
|
|
2233
2233
|
e.DocumentFragment;
|
|
2234
2234
|
let a = e.HTMLTemplateElement, o = e.Node, s = e.Element, c = e.NodeFilter;
|
|
2235
2235
|
e.NamedNodeMap === void 0 && (e.NamedNodeMap || e.MozNamedAttrMap), e.HTMLFormElement;
|
|
2236
|
-
let l = e.DOMParser, u = e.trustedTypes, d = s.prototype, f = ji(d, "cloneNode"), p = ji(d, "remove"), m = ji(d, "nextSibling"), h = ji(d, "childNodes"), g = ji(d, "parentNode"), _ = ji(d, "shadowRoot"), v = ji(d, "attributes"), y = o && o.prototype ? ji(o.prototype, "nodeType") : null, b = o && o.prototype ? ji(o.prototype, "nodeName") : null;
|
|
2236
|
+
let l = e.DOMParser, u = e.trustedTypes, d = s.prototype, f = ji(d, "cloneNode"), p = ji(d, "remove"), m = ji(d, "nextSibling"), h = ji(d, "childNodes"), g = ji(d, "parentNode"), _ = ji(d, "shadowRoot"), v = ji(d, "attributes"), y = o && o.prototype ? ji(o.prototype, "nodeType") : null, b = o && o.prototype ? ji(o.prototype, "nodeName") : null, x = o && o.prototype ? ji(o.prototype, "ownerDocument") : null;
|
|
2237
2237
|
if (typeof a == "function") {
|
|
2238
2238
|
let e = n.createElement("template");
|
|
2239
2239
|
e.content && e.content.ownerDocument && (n = e.content.ownerDocument);
|
|
2240
2240
|
}
|
|
2241
|
-
let
|
|
2242
|
-
if (
|
|
2243
|
-
},
|
|
2244
|
-
|
|
2241
|
+
let S, C = "", w, T = !1, E = 0, ee = function() {
|
|
2242
|
+
if (E > 0) throw wi("A configured TRUSTED_TYPES_POLICY callback (createHTML or createScriptURL) must not call DOMPurify.sanitize, as that causes infinite recursion. Do not pass a policy whose callbacks wrap DOMPurify as TRUSTED_TYPES_POLICY; see the \"DOMPurify and Trusted Types\" section of the README.");
|
|
2243
|
+
}, D = function(e) {
|
|
2244
|
+
ee(), E++;
|
|
2245
2245
|
try {
|
|
2246
|
-
return
|
|
2246
|
+
return S.createHTML(e);
|
|
2247
2247
|
} finally {
|
|
2248
|
-
|
|
2248
|
+
E--;
|
|
2249
2249
|
}
|
|
2250
|
-
},
|
|
2251
|
-
|
|
2250
|
+
}, O = function(e) {
|
|
2251
|
+
ee(), E++;
|
|
2252
2252
|
try {
|
|
2253
|
-
return
|
|
2253
|
+
return S.createScriptURL(e);
|
|
2254
2254
|
} finally {
|
|
2255
|
-
|
|
2255
|
+
E--;
|
|
2256
2256
|
}
|
|
2257
|
-
},
|
|
2258
|
-
return
|
|
2259
|
-
},
|
|
2260
|
-
t.isSupported = typeof Jr == "function" && typeof g == "function" &&
|
|
2261
|
-
let
|
|
2257
|
+
}, te = function() {
|
|
2258
|
+
return T ||= (w = oa(u, i), !0), w;
|
|
2259
|
+
}, k = n, ne = k.implementation, A = k.createNodeIterator, re = k.createDocumentFragment, ie = k.getElementsByTagName, j = r.importNode, ae = sa();
|
|
2260
|
+
t.isSupported = typeof Jr == "function" && typeof g == "function" && ne && ne.createHTMLDocument !== void 0;
|
|
2261
|
+
let oe = Wi, se = Gi, ce = Ki, le = qi, ue = Ji, de = Xi, fe = Zi, pe = $i, me = Yi, he = null, ge = Di({}, [
|
|
2262
2262
|
...Ni,
|
|
2263
2263
|
...Pi,
|
|
2264
2264
|
...Fi,
|
|
2265
2265
|
...Li,
|
|
2266
2266
|
...zi
|
|
2267
|
-
]),
|
|
2267
|
+
]), _e = null, ve = Di({}, [
|
|
2268
2268
|
...Bi,
|
|
2269
2269
|
...Vi,
|
|
2270
2270
|
...Hi,
|
|
2271
2271
|
...Ui
|
|
2272
|
-
]),
|
|
2272
|
+
]), ye = Object.seal(ti(null, {
|
|
2273
2273
|
tagNameCheck: {
|
|
2274
2274
|
writable: !0,
|
|
2275
2275
|
configurable: !1,
|
|
@@ -2288,7 +2288,7 @@ function la() {
|
|
|
2288
2288
|
enumerable: !0,
|
|
2289
2289
|
value: !1
|
|
2290
2290
|
}
|
|
2291
|
-
})),
|
|
2291
|
+
})), be = null, xe = null, Se = Object.seal(ti(null, {
|
|
2292
2292
|
tagCheck: {
|
|
2293
2293
|
writable: !0,
|
|
2294
2294
|
configurable: !1,
|
|
@@ -2301,14 +2301,14 @@ function la() {
|
|
|
2301
2301
|
enumerable: !0,
|
|
2302
2302
|
value: null
|
|
2303
2303
|
}
|
|
2304
|
-
})),
|
|
2304
|
+
})), Ce = !0, we = !0, Te = !1, Ee = !0, De = !1, Oe = !0, ke = !1, Ae = !1, je = null, Me = null, Ne = !1, Pe = !1, Fe = !1, Ie = !1, Le = !0, Re = !1, ze = "user-content-", Be = !0, Ve = !1, He = {}, Ue = null, We = Di({}, /* @__PURE__ */ "annotation-xml.audio.colgroup.desc.foreignobject.head.iframe.math.mi.mn.mo.ms.mtext.noembed.noframes.noscript.plaintext.script.selectedcontent.style.svg.template.thead.title.video.xmp".split(".")), Ge = null, M = Di({}, [
|
|
2305
2305
|
"audio",
|
|
2306
2306
|
"video",
|
|
2307
2307
|
"img",
|
|
2308
2308
|
"source",
|
|
2309
2309
|
"image",
|
|
2310
2310
|
"track"
|
|
2311
|
-
]),
|
|
2311
|
+
]), N = null, Ke = Di({}, [
|
|
2312
2312
|
"alt",
|
|
2313
2313
|
"class",
|
|
2314
2314
|
"for",
|
|
@@ -2323,78 +2323,78 @@ function la() {
|
|
|
2323
2323
|
"value",
|
|
2324
2324
|
"style",
|
|
2325
2325
|
"xmlns"
|
|
2326
|
-
]),
|
|
2327
|
-
Ke,
|
|
2326
|
+
]), qe = "http://www.w3.org/1998/Math/MathML", Je = "http://www.w3.org/2000/svg", Ye = "http://www.w3.org/1999/xhtml", Xe = Ye, Ze = !1, Qe = null, $e = Di({}, [
|
|
2328
2327
|
qe,
|
|
2329
|
-
Je
|
|
2330
|
-
|
|
2328
|
+
Je,
|
|
2329
|
+
Ye
|
|
2330
|
+
], fi), et = $r([
|
|
2331
2331
|
"mi",
|
|
2332
2332
|
"mo",
|
|
2333
2333
|
"mn",
|
|
2334
2334
|
"ms",
|
|
2335
2335
|
"mtext"
|
|
2336
|
-
]),
|
|
2336
|
+
]), tt = Di({}, et), nt = $r(["annotation-xml"]), rt = Di({}, nt), it = Di({}, [
|
|
2337
2337
|
"title",
|
|
2338
2338
|
"style",
|
|
2339
2339
|
"font",
|
|
2340
2340
|
"a",
|
|
2341
2341
|
"script"
|
|
2342
|
-
]),
|
|
2342
|
+
]), at = null, ot = ["application/xhtml+xml", "text/html"], st = null, ct = null, lt = n.createElement("form"), ut = function(e) {
|
|
2343
2343
|
return e instanceof RegExp || e instanceof Function;
|
|
2344
|
-
},
|
|
2344
|
+
}, dt = function() {
|
|
2345
2345
|
let e = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {};
|
|
2346
|
-
if (
|
|
2347
|
-
(!e || typeof e != "object") && (e = {}), e = ki(e),
|
|
2348
|
-
transform:
|
|
2349
|
-
base:
|
|
2350
|
-
}),
|
|
2351
|
-
transform:
|
|
2352
|
-
base:
|
|
2353
|
-
}),
|
|
2346
|
+
if (ct && ct === e) return;
|
|
2347
|
+
(!e || typeof e != "object") && (e = {}), e = ki(e), at = ot.indexOf(e.PARSER_MEDIA_TYPE) === -1 ? "text/html" : e.PARSER_MEDIA_TYPE, st = at === "application/xhtml+xml" ? fi : di, he = ca(e, "ALLOWED_TAGS", ge, { transform: st }), _e = ca(e, "ALLOWED_ATTR", ve, { transform: st }), Qe = ca(e, "ALLOWED_NAMESPACES", $e, { transform: fi }), N = ca(e, "ADD_URI_SAFE_ATTR", Ke, {
|
|
2348
|
+
transform: st,
|
|
2349
|
+
base: Ke
|
|
2350
|
+
}), Ge = ca(e, "ADD_DATA_URI_TAGS", M, {
|
|
2351
|
+
transform: st,
|
|
2352
|
+
base: M
|
|
2353
|
+
}), Ue = ca(e, "FORBID_CONTENTS", We, { transform: st }), be = ca(e, "FORBID_TAGS", ki({}), { transform: st }), xe = ca(e, "FORBID_ATTR", ki({}), { transform: st }), He = xi(e, "USE_PROFILES") ? e.USE_PROFILES && typeof e.USE_PROFILES == "object" ? ki(e.USE_PROFILES) : e.USE_PROFILES : !1, Ce = e.ALLOW_ARIA_ATTR !== !1, we = e.ALLOW_DATA_ATTR !== !1, Te = e.ALLOW_UNKNOWN_PROTOCOLS || !1, Ee = e.ALLOW_SELF_CLOSE_IN_ATTR !== !1, De = e.SAFE_FOR_TEMPLATES || !1, Oe = e.SAFE_FOR_XML !== !1, ke = e.WHOLE_DOCUMENT || !1, Pe = e.RETURN_DOM || !1, Fe = e.RETURN_DOM_FRAGMENT || !1, Ie = e.RETURN_TRUSTED_TYPE || !1, Ne = e.FORCE_BODY || !1, Le = e.SANITIZE_DOM !== !1, Re = e.SANITIZE_NAMED_PROPS || !1, Be = e.KEEP_CONTENT !== !1, Ve = e.IN_PLACE || !1, me = Mi(e.ALLOWED_URI_REGEXP) ? e.ALLOWED_URI_REGEXP : Yi, Xe = typeof e.NAMESPACE == "string" ? e.NAMESPACE : Ye, tt = xi(e, "MATHML_TEXT_INTEGRATION_POINTS") && e.MATHML_TEXT_INTEGRATION_POINTS && typeof e.MATHML_TEXT_INTEGRATION_POINTS == "object" ? ki(e.MATHML_TEXT_INTEGRATION_POINTS) : Di({}, et), rt = xi(e, "HTML_INTEGRATION_POINTS") && e.HTML_INTEGRATION_POINTS && typeof e.HTML_INTEGRATION_POINTS == "object" ? ki(e.HTML_INTEGRATION_POINTS) : Di({}, nt);
|
|
2354
2354
|
let t = xi(e, "CUSTOM_ELEMENT_HANDLING") && e.CUSTOM_ELEMENT_HANDLING && typeof e.CUSTOM_ELEMENT_HANDLING == "object" ? ki(e.CUSTOM_ELEMENT_HANDLING) : ti(null);
|
|
2355
|
-
if (
|
|
2355
|
+
if (ye = ti(null), xi(t, "tagNameCheck") && ut(t.tagNameCheck) && (ye.tagNameCheck = t.tagNameCheck), xi(t, "attributeNameCheck") && ut(t.attributeNameCheck) && (ye.attributeNameCheck = t.attributeNameCheck), xi(t, "allowCustomizedBuiltInElements") && typeof t.allowCustomizedBuiltInElements == "boolean" && (ye.allowCustomizedBuiltInElements = t.allowCustomizedBuiltInElements), ei(ye), De && (we = !1), Fe && (Pe = !0), He && (he = Di({}, zi), _e = ti(null), He.html === !0 && (Di(he, Ni), Di(_e, Bi)), He.svg === !0 && (Di(he, Pi), Di(_e, Vi), Di(_e, Ui)), He.svgFilters === !0 && (Di(he, Fi), Di(_e, Vi), Di(_e, Ui)), He.mathMl === !0 && (Di(he, Li), Di(_e, Hi), Di(_e, Ui))), Se.tagCheck = null, Se.attributeCheck = null, xi(e, "ADD_TAGS") && (typeof e.ADD_TAGS == "function" ? Se.tagCheck = e.ADD_TAGS : ui(e.ADD_TAGS) && (he === ge && (he = ki(he)), Di(he, e.ADD_TAGS, st))), xi(e, "ADD_ATTR") && (typeof e.ADD_ATTR == "function" ? Se.attributeCheck = e.ADD_ATTR : ui(e.ADD_ATTR) && (_e === ve && (_e = ki(_e)), Di(_e, e.ADD_ATTR, st))), xi(e, "ADD_URI_SAFE_ATTR") && ui(e.ADD_URI_SAFE_ATTR) && Di(N, e.ADD_URI_SAFE_ATTR, st), xi(e, "FORBID_CONTENTS") && ui(e.FORBID_CONTENTS) && (Ue === We && (Ue = ki(Ue)), Di(Ue, e.FORBID_CONTENTS, st)), xi(e, "ADD_FORBID_CONTENTS") && ui(e.ADD_FORBID_CONTENTS) && (Ue === We && (Ue = ki(Ue)), Di(Ue, e.ADD_FORBID_CONTENTS, st)), Be && (he["#text"] = !0), ke && Di(he, [
|
|
2356
2356
|
"html",
|
|
2357
2357
|
"head",
|
|
2358
2358
|
"body"
|
|
2359
|
-
]),
|
|
2359
|
+
]), he.table && (Di(he, ["tbody"]), delete be.tbody), e.TRUSTED_TYPES_POLICY) {
|
|
2360
2360
|
if (typeof e.TRUSTED_TYPES_POLICY.createHTML != "function") throw wi("TRUSTED_TYPES_POLICY configuration option must provide a \"createHTML\" hook.");
|
|
2361
2361
|
if (typeof e.TRUSTED_TYPES_POLICY.createScriptURL != "function") throw wi("TRUSTED_TYPES_POLICY configuration option must provide a \"createScriptURL\" hook.");
|
|
2362
|
-
let t =
|
|
2363
|
-
|
|
2362
|
+
let t = S;
|
|
2363
|
+
S = e.TRUSTED_TYPES_POLICY;
|
|
2364
2364
|
try {
|
|
2365
|
-
|
|
2365
|
+
C = D("");
|
|
2366
2366
|
} catch (e) {
|
|
2367
|
-
throw
|
|
2367
|
+
throw S = t, e;
|
|
2368
2368
|
}
|
|
2369
|
-
} else e.TRUSTED_TYPES_POLICY === null ? (
|
|
2370
|
-
$r && $r(e),
|
|
2371
|
-
},
|
|
2369
|
+
} else e.TRUSTED_TYPES_POLICY === null ? (S = void 0, C = "") : (S === void 0 && (S = te()), S && typeof C == "string" && (C = D("")));
|
|
2370
|
+
$r && $r(e), ct = e;
|
|
2371
|
+
}, ft = Di({}, [
|
|
2372
2372
|
...Pi,
|
|
2373
2373
|
...Fi,
|
|
2374
2374
|
...Ii
|
|
2375
|
-
]),
|
|
2376
|
-
return t.namespaceURI ===
|
|
2377
|
-
}, mt = function(e, t, n) {
|
|
2378
|
-
return t.namespaceURI === Je ? e === "math" : t.namespaceURI === qe ? e === "math" && nt[n] : !!ft[e];
|
|
2375
|
+
]), pt = Di({}, [...Li, ...Ri]), mt = function(e, t, n) {
|
|
2376
|
+
return t.namespaceURI === Ye ? e === "svg" : t.namespaceURI === qe ? e === "svg" && (n === "annotation-xml" || tt[n]) : !!ft[e];
|
|
2379
2377
|
}, ht = function(e, t, n) {
|
|
2380
|
-
return t.namespaceURI ===
|
|
2381
|
-
}, gt = function(e) {
|
|
2378
|
+
return t.namespaceURI === Ye ? e === "math" : t.namespaceURI === Je ? e === "math" && rt[n] : !!pt[e];
|
|
2379
|
+
}, gt = function(e, t, n) {
|
|
2380
|
+
return t.namespaceURI === Je && !rt[n] || t.namespaceURI === qe && !tt[n] ? !1 : !pt[e] && (it[e] || !ft[e]);
|
|
2381
|
+
}, _t = function(e) {
|
|
2382
2382
|
let t = g(e);
|
|
2383
2383
|
(!t || !t.tagName) && (t = {
|
|
2384
|
-
namespaceURI:
|
|
2384
|
+
namespaceURI: Xe,
|
|
2385
2385
|
tagName: "template"
|
|
2386
2386
|
});
|
|
2387
2387
|
let n = di(e.tagName), r = di(t.tagName);
|
|
2388
|
-
return
|
|
2389
|
-
},
|
|
2388
|
+
return Qe[e.namespaceURI] ? e.namespaceURI === Je ? mt(n, t, r) : e.namespaceURI === qe ? ht(n, t, r) : e.namespaceURI === Ye ? gt(n, t, r) : !!(at === "application/xhtml+xml" && Qe[e.namespaceURI]) : !1;
|
|
2389
|
+
}, vt = function(e) {
|
|
2390
2390
|
ci(t.removed, { element: e });
|
|
2391
2391
|
try {
|
|
2392
2392
|
g(e).removeChild(e);
|
|
2393
2393
|
} catch {
|
|
2394
2394
|
if (p(e), !g(e)) throw wi("a node selected for removal could not be detached from its tree and cannot be safely returned; refusing to sanitize in place");
|
|
2395
2395
|
}
|
|
2396
|
-
},
|
|
2397
|
-
|
|
2396
|
+
}, yt = function(e) {
|
|
2397
|
+
St(e);
|
|
2398
2398
|
let t = h(e);
|
|
2399
2399
|
if (t) {
|
|
2400
2400
|
let e = [];
|
|
@@ -2413,7 +2413,7 @@ function la() {
|
|
|
2413
2413
|
e.removeAttribute(i);
|
|
2414
2414
|
} catch {}
|
|
2415
2415
|
}
|
|
2416
|
-
},
|
|
2416
|
+
}, bt = function(e, n) {
|
|
2417
2417
|
try {
|
|
2418
2418
|
ci(t.removed, {
|
|
2419
2419
|
attribute: n.getAttributeNode(e),
|
|
@@ -2425,30 +2425,30 @@ function la() {
|
|
|
2425
2425
|
from: n
|
|
2426
2426
|
});
|
|
2427
2427
|
}
|
|
2428
|
-
if (n.removeAttribute(e), e === "is") if (
|
|
2429
|
-
|
|
2428
|
+
if (n.removeAttribute(e), e === "is") if (Pe || Fe) try {
|
|
2429
|
+
vt(n);
|
|
2430
2430
|
} catch {}
|
|
2431
2431
|
else try {
|
|
2432
2432
|
n.setAttribute(e, "");
|
|
2433
2433
|
} catch {}
|
|
2434
|
-
},
|
|
2434
|
+
}, xt = function(e) {
|
|
2435
2435
|
let t = v(e);
|
|
2436
2436
|
if (t) for (let n = t.length - 1; n >= 0; --n) {
|
|
2437
2437
|
let r = t[n], i = r && r.name;
|
|
2438
|
-
if (!(typeof i != "string" ||
|
|
2438
|
+
if (!(typeof i != "string" || _e[st(i)])) try {
|
|
2439
2439
|
e.removeAttribute(i);
|
|
2440
2440
|
} catch {}
|
|
2441
2441
|
}
|
|
2442
|
-
},
|
|
2442
|
+
}, St = function(e) {
|
|
2443
2443
|
let t = [e];
|
|
2444
2444
|
for (; t.length > 0;) {
|
|
2445
2445
|
let e = t.pop();
|
|
2446
|
-
(y ? y(e) : e.nodeType) === ia.element &&
|
|
2446
|
+
(y ? y(e) : e.nodeType) === ia.element && xt(e);
|
|
2447
2447
|
let n = h(e);
|
|
2448
2448
|
if (n) for (let e = n.length - 1; e >= 0; --e) t.push(n[e]);
|
|
2449
2449
|
}
|
|
2450
|
-
},
|
|
2451
|
-
if (!
|
|
2450
|
+
}, Ct = function(e) {
|
|
2451
|
+
if (!Oe) return;
|
|
2452
2452
|
let t = [e];
|
|
2453
2453
|
for (; t.length > 0;) {
|
|
2454
2454
|
let e = t.pop(), n = y ? y(e) : e.nodeType;
|
|
@@ -2459,7 +2459,7 @@ function la() {
|
|
|
2459
2459
|
continue;
|
|
2460
2460
|
}
|
|
2461
2461
|
if (n === ia.element) {
|
|
2462
|
-
let t = e, n =
|
|
2462
|
+
let t = e, n = st(b ? b(e) : e.nodeName);
|
|
2463
2463
|
try {
|
|
2464
2464
|
t.hasAttribute && t.hasAttribute("patchsrc") && t.removeAttribute("patchsrc"), t.hasAttribute && t.hasAttribute("for") && n !== "label" && n !== "output" && t.removeAttribute("for");
|
|
2465
2465
|
} catch {}
|
|
@@ -2467,49 +2467,50 @@ function la() {
|
|
|
2467
2467
|
let r = h(e);
|
|
2468
2468
|
if (r) for (let e = r.length - 1; e >= 0; --e) t.push(r[e]);
|
|
2469
2469
|
}
|
|
2470
|
-
},
|
|
2470
|
+
}, wt = function(e) {
|
|
2471
2471
|
let t = null, r = null;
|
|
2472
|
-
if (
|
|
2472
|
+
if (Ne) e = "<remove></remove>" + e;
|
|
2473
2473
|
else {
|
|
2474
2474
|
let t = pi(e, /^[\r\n\t ]+/);
|
|
2475
2475
|
r = t && t[0];
|
|
2476
2476
|
}
|
|
2477
|
-
|
|
2478
|
-
let i =
|
|
2479
|
-
if (
|
|
2480
|
-
t = new l().parseFromString(i,
|
|
2477
|
+
at === "application/xhtml+xml" && Xe === Ye && (e = "<html xmlns=\"http://www.w3.org/1999/xhtml\"><head></head><body>" + e + "</body></html>");
|
|
2478
|
+
let i = S ? D(e) : e;
|
|
2479
|
+
if (Xe === Ye) try {
|
|
2480
|
+
t = new l().parseFromString(i, at);
|
|
2481
2481
|
} catch {}
|
|
2482
2482
|
if (!t || !t.documentElement) {
|
|
2483
|
-
t =
|
|
2483
|
+
t = ne.createDocument(Xe, "template", null);
|
|
2484
2484
|
try {
|
|
2485
|
-
t.documentElement.innerHTML =
|
|
2485
|
+
t.documentElement.innerHTML = Ze ? C : i;
|
|
2486
2486
|
} catch {}
|
|
2487
2487
|
}
|
|
2488
2488
|
let a = t.body || t.documentElement;
|
|
2489
|
-
return e && r && a.insertBefore(n.createTextNode(r), a.childNodes[0] || null),
|
|
2490
|
-
}, wt = function(e) {
|
|
2491
|
-
return ne.call(e.ownerDocument || e, e, c.SHOW_ELEMENT | c.SHOW_COMMENT | c.SHOW_TEXT | c.SHOW_PROCESSING_INSTRUCTION | c.SHOW_CDATA_SECTION, null);
|
|
2489
|
+
return e && r && a.insertBefore(n.createTextNode(r), a.childNodes[0] || null), Xe === Ye ? ie.call(t, ke ? "html" : "body")[0] : ke ? t.documentElement : a;
|
|
2492
2490
|
}, Tt = function(e) {
|
|
2493
|
-
|
|
2491
|
+
let t = x ? x(e) : e.ownerDocument;
|
|
2492
|
+
return A.call(t || e, e, c.SHOW_ELEMENT | c.SHOW_COMMENT | c.SHOW_TEXT | c.SHOW_PROCESSING_INSTRUCTION | c.SHOW_CDATA_SECTION, null);
|
|
2494
2493
|
}, Et = function(e) {
|
|
2494
|
+
return e = mi(e, oe, " "), e = mi(e, se, " "), e = mi(e, ce, " "), e;
|
|
2495
|
+
}, Dt = function(e) {
|
|
2495
2496
|
e.normalize();
|
|
2496
|
-
let t =
|
|
2497
|
-
for (;
|
|
2498
|
-
let
|
|
2499
|
-
|
|
2500
|
-
|
|
2497
|
+
let t = x ? x(e) : e.ownerDocument, n = A.call(t || e, e, c.SHOW_TEXT | c.SHOW_COMMENT | c.SHOW_CDATA_SECTION | c.SHOW_PROCESSING_INSTRUCTION, null), r = n.nextNode();
|
|
2498
|
+
for (; r;) r.data = Et(r.data), r = n.nextNode();
|
|
2499
|
+
let i = e.querySelectorAll?.call(e, "template");
|
|
2500
|
+
i && ai(i, (e) => {
|
|
2501
|
+
kt(e.content) && Dt(e.content);
|
|
2501
2502
|
});
|
|
2502
|
-
}, Dt = function(e) {
|
|
2503
|
-
let t = b ? b(e) : null;
|
|
2504
|
-
return typeof t != "string" || ot(t) !== "form" ? !1 : typeof e.nodeName != "string" || typeof e.textContent != "string" || typeof e.removeChild != "function" || e.attributes !== v(e) || typeof e.removeAttribute != "function" || typeof e.setAttribute != "function" || typeof e.namespaceURI != "string" || typeof e.insertBefore != "function" || typeof e.hasChildNodes != "function" || e.nodeType !== y(e) || e.childNodes !== h(e);
|
|
2505
2503
|
}, Ot = function(e) {
|
|
2504
|
+
let t = b ? b(e) : null;
|
|
2505
|
+
return typeof t != "string" || st(t) !== "form" ? !1 : typeof e.nodeName != "string" || typeof e.textContent != "string" || typeof e.removeChild != "function" || e.attributes !== v(e) || typeof e.removeAttribute != "function" || typeof e.setAttribute != "function" || typeof e.namespaceURI != "string" || typeof e.insertBefore != "function" || typeof e.hasChildNodes != "function" || e.nodeType !== y(e) || e.childNodes !== h(e);
|
|
2506
|
+
}, kt = function(e) {
|
|
2506
2507
|
if (!y || typeof e != "object" || !e) return !1;
|
|
2507
2508
|
try {
|
|
2508
2509
|
return y(e) === ia.documentFragment;
|
|
2509
2510
|
} catch {
|
|
2510
2511
|
return !1;
|
|
2511
2512
|
}
|
|
2512
|
-
},
|
|
2513
|
+
}, At = function(e) {
|
|
2513
2514
|
if (!y || typeof e != "object" || !e) return !1;
|
|
2514
2515
|
try {
|
|
2515
2516
|
return typeof y(e) == "number";
|
|
@@ -2517,55 +2518,57 @@ function la() {
|
|
|
2517
2518
|
return !1;
|
|
2518
2519
|
}
|
|
2519
2520
|
};
|
|
2520
|
-
function
|
|
2521
|
+
function jt(e, n, r) {
|
|
2521
2522
|
e.length !== 0 && ai(e, (e) => {
|
|
2522
|
-
e.call(t, n, r,
|
|
2523
|
+
e.call(t, n, r, ct);
|
|
2523
2524
|
});
|
|
2524
2525
|
}
|
|
2525
|
-
let
|
|
2526
|
-
return !!(
|
|
2527
|
-
},
|
|
2528
|
-
if (!
|
|
2529
|
-
if (
|
|
2530
|
-
let t = g(e),
|
|
2531
|
-
if (
|
|
2532
|
-
let
|
|
2533
|
-
for (let
|
|
2534
|
-
let
|
|
2535
|
-
t.insertBefore(
|
|
2526
|
+
let Mt = function(e, t) {
|
|
2527
|
+
return !!(Oe && e.hasChildNodes() && !At(e.firstElementChild) && Ci(ea, e.textContent) && Ci(ea, e.innerHTML) || Oe && e.namespaceURI === Ye && t === "style" && At(e.firstElementChild) || e.nodeType === ia.processingInstruction || Oe && e.nodeType === ia.comment && Ci(ta, e.data));
|
|
2528
|
+
}, Nt = function(e, t, n) {
|
|
2529
|
+
if (!be[t] && Rt(t) && (ye.tagNameCheck instanceof RegExp && Ci(ye.tagNameCheck, t) || ye.tagNameCheck instanceof Function && ye.tagNameCheck(t))) return !1;
|
|
2530
|
+
if (Be && !Ue[t]) {
|
|
2531
|
+
let t = g(e), r = h(e);
|
|
2532
|
+
if (r && t) {
|
|
2533
|
+
let i = r.length;
|
|
2534
|
+
for (let a = i - 1; a >= 0; --a) {
|
|
2535
|
+
let i = e === n ? f(r[a], !0) : r[a];
|
|
2536
|
+
t.insertBefore(i, m(e));
|
|
2536
2537
|
}
|
|
2537
2538
|
}
|
|
2538
2539
|
}
|
|
2539
|
-
return
|
|
2540
|
-
},
|
|
2541
|
-
|
|
2542
|
-
|
|
2543
|
-
|
|
2544
|
-
if (
|
|
2540
|
+
return vt(e), !0;
|
|
2541
|
+
}, Pt = function(e, t, n, r) {
|
|
2542
|
+
return e.length === 0 ? t : t === n || t === r ? ki(t) : t;
|
|
2543
|
+
}, Ft = function(e, n) {
|
|
2544
|
+
if (jt(ae.beforeSanitizeElements, e, null), e !== n && g(e) === null) return Ve && St(e), !0;
|
|
2545
|
+
if (Ot(e)) return vt(e), !0;
|
|
2546
|
+
let r = st(b ? b(e) : e.nodeName);
|
|
2547
|
+
if (he = Pt(ae.uponSanitizeElement, he, ge, je), jt(ae.uponSanitizeElement, e, {
|
|
2545
2548
|
tagName: r,
|
|
2546
|
-
allowedTags:
|
|
2547
|
-
}), e !== n && g(e) === null) return !0;
|
|
2548
|
-
if (
|
|
2549
|
-
if (
|
|
2550
|
-
let t =
|
|
2551
|
-
return t === !1 &&
|
|
2552
|
-
}
|
|
2553
|
-
if ((y ? y(e) : e.nodeType) === ia.element && !
|
|
2554
|
-
if (
|
|
2555
|
-
let n =
|
|
2549
|
+
allowedTags: he
|
|
2550
|
+
}), e !== n && g(e) === null) return Ve && St(e), !0;
|
|
2551
|
+
if (Mt(e, r)) return vt(e), !0;
|
|
2552
|
+
if (be[r] || !(Se.tagCheck instanceof Function && Se.tagCheck(r)) && !he[r]) {
|
|
2553
|
+
let t = Nt(e, r, n);
|
|
2554
|
+
return t === !1 && jt(ae.afterSanitizeElements, e, null), t;
|
|
2555
|
+
}
|
|
2556
|
+
if ((y ? y(e) : e.nodeType) === ia.element && !_t(e) || (r === "noscript" || r === "noembed" || r === "noframes") && Ci(na, e.innerHTML)) return vt(e), !0;
|
|
2557
|
+
if (De && e.nodeType === ia.text) {
|
|
2558
|
+
let n = Et(e.textContent);
|
|
2556
2559
|
e.textContent !== n && (ci(t.removed, { element: e.cloneNode() }), e.textContent = n);
|
|
2557
2560
|
}
|
|
2558
|
-
return
|
|
2559
|
-
},
|
|
2560
|
-
if (
|
|
2561
|
-
let i =
|
|
2562
|
-
if (!(
|
|
2561
|
+
return jt(ae.afterSanitizeElements, e, null), !1;
|
|
2562
|
+
}, It = function(e, t, r) {
|
|
2563
|
+
if (xe[t] || Oe && t === "patchsrc" || Oe && t === "for" && e !== "label" && e !== "output" || Le && (t === "id" || t === "name") && (r in n || r in lt)) return !1;
|
|
2564
|
+
let i = _e[t] || Se.attributeCheck instanceof Function && Se.attributeCheck(t, e);
|
|
2565
|
+
if (!(we && Ci(le, t)) && !(Ce && Ci(ue, t))) {
|
|
2563
2566
|
if (!i) {
|
|
2564
|
-
if (!(
|
|
2565
|
-
} else if (!
|
|
2567
|
+
if (!(Rt(e) && (ye.tagNameCheck instanceof RegExp && Ci(ye.tagNameCheck, e) || ye.tagNameCheck instanceof Function && ye.tagNameCheck(e)) && (ye.attributeNameCheck instanceof RegExp && Ci(ye.attributeNameCheck, t) || ye.attributeNameCheck instanceof Function && ye.attributeNameCheck(t, e)) || t === "is" && ye.allowCustomizedBuiltInElements && (ye.tagNameCheck instanceof RegExp && Ci(ye.tagNameCheck, r) || ye.tagNameCheck instanceof Function && ye.tagNameCheck(r)))) return !1;
|
|
2568
|
+
} else if (!N[t] && !Ci(me, mi(r, fe, "")) && !((t === "src" || t === "xlink:href" || t === "href") && e !== "script" && hi(r, "data:") === 0 && Ge[e]) && !(Te && !Ci(de, mi(r, fe, ""))) && r) return !1;
|
|
2566
2569
|
}
|
|
2567
2570
|
return !0;
|
|
2568
|
-
},
|
|
2571
|
+
}, Lt = Di({}, [
|
|
2569
2572
|
"annotation-xml",
|
|
2570
2573
|
"color-profile",
|
|
2571
2574
|
"font-face",
|
|
@@ -2574,66 +2577,67 @@ function la() {
|
|
|
2574
2577
|
"font-face-src",
|
|
2575
2578
|
"font-face-uri",
|
|
2576
2579
|
"missing-glyph"
|
|
2577
|
-
]),
|
|
2578
|
-
return !
|
|
2579
|
-
},
|
|
2580
|
-
if (
|
|
2581
|
-
case "TrustedHTML": return
|
|
2582
|
-
case "TrustedScriptURL": return
|
|
2580
|
+
]), Rt = function(e) {
|
|
2581
|
+
return !Lt[di(e)] && Ci(pe, e);
|
|
2582
|
+
}, zt = function(e, t, n, r) {
|
|
2583
|
+
if (S && typeof u == "object" && typeof u.getAttributeType == "function" && !n) switch (u.getAttributeType(e, t)) {
|
|
2584
|
+
case "TrustedHTML": return D(r);
|
|
2585
|
+
case "TrustedScriptURL": return O(r);
|
|
2583
2586
|
}
|
|
2584
2587
|
return r;
|
|
2585
|
-
},
|
|
2588
|
+
}, Bt = function(e, n, r, i) {
|
|
2586
2589
|
try {
|
|
2587
|
-
r ? e.setAttributeNS(r, n, i) : e.setAttribute(n, i),
|
|
2590
|
+
r ? e.setAttributeNS(r, n, i) : e.setAttribute(n, i), Ot(e) ? vt(e) : si(t.removed);
|
|
2588
2591
|
} catch {
|
|
2589
|
-
|
|
2592
|
+
bt(n, e);
|
|
2590
2593
|
}
|
|
2591
|
-
},
|
|
2592
|
-
|
|
2594
|
+
}, Vt = function(e) {
|
|
2595
|
+
jt(ae.beforeSanitizeAttributes, e, null);
|
|
2593
2596
|
let t = e.attributes;
|
|
2594
|
-
if (!t ||
|
|
2597
|
+
if (!t || Ot(e)) return;
|
|
2598
|
+
_e = Pt(ae.uponSanitizeAttribute, _e, ve, Me);
|
|
2595
2599
|
let n = {
|
|
2596
2600
|
attrName: "",
|
|
2597
2601
|
attrValue: "",
|
|
2598
2602
|
keepAttr: !0,
|
|
2599
|
-
allowedAttributes:
|
|
2603
|
+
allowedAttributes: _e,
|
|
2600
2604
|
forceKeepAttr: void 0
|
|
2601
|
-
}, r = t.length, i =
|
|
2605
|
+
}, r = t.length, i = st(e.nodeName);
|
|
2602
2606
|
for (; r--;) {
|
|
2603
|
-
let a = t[r], o = a.name, s = a.namespaceURI, c = a.value, l =
|
|
2604
|
-
if (n.attrName = l, n.attrValue = d, n.keepAttr = !0, n.forceKeepAttr = void 0,
|
|
2605
|
-
|
|
2607
|
+
let a = t[r], o = a.name, s = a.namespaceURI, c = a.value, l = st(o), u = c, d = o === "value" ? u : gi(u);
|
|
2608
|
+
if (n.attrName = l, n.attrValue = d, n.keepAttr = !0, n.forceKeepAttr = void 0, jt(ae.uponSanitizeAttribute, e, n), d = n.attrValue, Re && (l === "id" || l === "name") && hi(d, ze) !== 0 && (bt(o, e), d = ze + d), Oe && Ci(/((--!?|])>)|<\/(style|script|title|xmp|textarea|noscript|iframe|noembed|noframes)/i, d)) {
|
|
2609
|
+
bt(o, e);
|
|
2606
2610
|
continue;
|
|
2607
2611
|
}
|
|
2608
2612
|
if (l === "attributename" && pi(d, "href")) {
|
|
2609
|
-
|
|
2613
|
+
bt(o, e);
|
|
2610
2614
|
continue;
|
|
2611
2615
|
}
|
|
2612
2616
|
if (!n.forceKeepAttr) {
|
|
2613
2617
|
if (!n.keepAttr) {
|
|
2614
|
-
|
|
2618
|
+
bt(o, e);
|
|
2615
2619
|
continue;
|
|
2616
2620
|
}
|
|
2617
|
-
if (!
|
|
2618
|
-
|
|
2621
|
+
if (!Ee && Ci(ra, d)) {
|
|
2622
|
+
bt(o, e);
|
|
2619
2623
|
continue;
|
|
2620
2624
|
}
|
|
2621
|
-
if (
|
|
2622
|
-
|
|
2625
|
+
if (De && (d = Et(d)), !It(i, l, d)) {
|
|
2626
|
+
bt(o, e);
|
|
2623
2627
|
continue;
|
|
2624
2628
|
}
|
|
2625
|
-
d =
|
|
2629
|
+
d = zt(i, l, s, d), d !== u && Bt(e, o, s, d);
|
|
2626
2630
|
}
|
|
2627
2631
|
}
|
|
2628
|
-
|
|
2629
|
-
},
|
|
2630
|
-
let t = null, n =
|
|
2631
|
-
for (
|
|
2632
|
+
jt(ae.afterSanitizeAttributes, e, null);
|
|
2633
|
+
}, Ht = function(e) {
|
|
2634
|
+
let t = null, n = Tt(e);
|
|
2635
|
+
for (jt(ae.beforeSanitizeShadowDOM, e, null); t = n.nextNode();) if (jt(ae.uponSanitizeShadowNode, t, null), Ft(t, e), Vt(t), kt(t.content) && Ht(t.content), (y ? y(t) : t.nodeType) === ia.element) {
|
|
2632
2636
|
let e = _(t);
|
|
2633
|
-
|
|
2637
|
+
kt(e) && (Ut(e), Ht(e));
|
|
2634
2638
|
}
|
|
2635
|
-
|
|
2636
|
-
},
|
|
2639
|
+
jt(ae.afterSanitizeShadowDOM, e, null);
|
|
2640
|
+
}, Ut = function(e) {
|
|
2637
2641
|
let t = [{
|
|
2638
2642
|
node: e,
|
|
2639
2643
|
shadow: null
|
|
@@ -2641,7 +2645,7 @@ function la() {
|
|
|
2641
2645
|
for (; t.length > 0;) {
|
|
2642
2646
|
let e = t.pop();
|
|
2643
2647
|
if (e.shadow) {
|
|
2644
|
-
|
|
2648
|
+
Ht(e.shadow);
|
|
2645
2649
|
continue;
|
|
2646
2650
|
}
|
|
2647
2651
|
let n = e.node, r = (y ? y(n) : n.nodeType) === ia.element, i = h(n);
|
|
@@ -2651,9 +2655,9 @@ function la() {
|
|
|
2651
2655
|
});
|
|
2652
2656
|
if (r) {
|
|
2653
2657
|
let e = b ? b(n) : null;
|
|
2654
|
-
if (typeof e == "string" &&
|
|
2658
|
+
if (typeof e == "string" && st(e) === "template") {
|
|
2655
2659
|
let e = n.content;
|
|
2656
|
-
|
|
2660
|
+
kt(e) && t.push({
|
|
2657
2661
|
node: e,
|
|
2658
2662
|
shadow: null
|
|
2659
2663
|
});
|
|
@@ -2661,7 +2665,7 @@ function la() {
|
|
|
2661
2665
|
}
|
|
2662
2666
|
if (r) {
|
|
2663
2667
|
let e = _(n);
|
|
2664
|
-
|
|
2668
|
+
kt(e) && t.push({
|
|
2665
2669
|
node: null,
|
|
2666
2670
|
shadow: e
|
|
2667
2671
|
}, {
|
|
@@ -2673,67 +2677,68 @@ function la() {
|
|
|
2673
2677
|
};
|
|
2674
2678
|
return t.sanitize = function(e) {
|
|
2675
2679
|
let n = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {}, i = null, a = null, o = null, s = null;
|
|
2676
|
-
if (
|
|
2680
|
+
if (Ze = !e, Ze && (e = "<!-->"), typeof e != "string" && !At(e) && (e = Ai(e), typeof e != "string")) throw wi("dirty is not a string, aborting");
|
|
2677
2681
|
if (!t.isSupported) return e;
|
|
2678
|
-
|
|
2679
|
-
let c =
|
|
2682
|
+
Ae ? (he = je, _e = Me) : dt(n), (ae.uponSanitizeElement.length > 0 || ae.uponSanitizeAttribute.length > 0) && (he = ki(he)), ae.uponSanitizeAttribute.length > 0 && (_e = ki(_e)), t.removed = [];
|
|
2683
|
+
let c = Ve && typeof e != "string" && At(e);
|
|
2680
2684
|
if (c) {
|
|
2681
|
-
|
|
2685
|
+
Ct(e);
|
|
2682
2686
|
let t = b ? b(e) : e.nodeName;
|
|
2683
2687
|
if (typeof t == "string") {
|
|
2684
|
-
let n =
|
|
2685
|
-
if (!
|
|
2688
|
+
let n = st(t);
|
|
2689
|
+
if (!he[n] || be[n]) throw yt(e), wi("root node is forbidden and cannot be sanitized in-place");
|
|
2686
2690
|
}
|
|
2687
|
-
if (
|
|
2691
|
+
if (Ot(e)) throw yt(e), wi("root node is clobbered and cannot be sanitized in-place");
|
|
2688
2692
|
try {
|
|
2689
|
-
|
|
2693
|
+
Ut(e);
|
|
2690
2694
|
} catch (t) {
|
|
2691
|
-
throw
|
|
2695
|
+
throw yt(e), t;
|
|
2692
2696
|
}
|
|
2693
|
-
} else if (
|
|
2697
|
+
} else if (At(e)) i = wt("<!---->"), a = i.ownerDocument.importNode(e, !0), a.nodeType === ia.element && a.nodeName === "BODY" || a.nodeName === "HTML" ? i = a : i.appendChild(a), Ut(a);
|
|
2694
2698
|
else {
|
|
2695
|
-
if (!
|
|
2696
|
-
if (i =
|
|
2699
|
+
if (!Pe && !De && !ke && e.indexOf("<") === -1) return S && Ie ? D(e) : e;
|
|
2700
|
+
if (i = wt(e), !i) return Pe ? null : Ie ? C : "";
|
|
2697
2701
|
}
|
|
2698
|
-
i &&
|
|
2699
|
-
let l = c ? e : i
|
|
2702
|
+
i && Ne && vt(i.firstChild);
|
|
2703
|
+
let l = c ? e : i;
|
|
2700
2704
|
try {
|
|
2701
|
-
|
|
2705
|
+
let e = Tt(l);
|
|
2706
|
+
for (; o = e.nextNode();) Ft(o, l), Vt(o), kt(o.content) && Ht(o.content);
|
|
2702
2707
|
} catch (n) {
|
|
2703
|
-
throw c && (
|
|
2704
|
-
e.element &&
|
|
2708
|
+
throw c && (yt(e), ai(t.removed, (e) => {
|
|
2709
|
+
e.element && St(e.element);
|
|
2705
2710
|
})), n;
|
|
2706
2711
|
}
|
|
2707
2712
|
if (c) return ai(t.removed, (e) => {
|
|
2708
|
-
e.element &&
|
|
2709
|
-
}),
|
|
2710
|
-
if (
|
|
2711
|
-
if (
|
|
2713
|
+
e.element && St(e.element);
|
|
2714
|
+
}), De && Dt(e), e;
|
|
2715
|
+
if (Pe) {
|
|
2716
|
+
if (De && Dt(i), Fe) for (s = re.call(i.ownerDocument); i.firstChild;) s.appendChild(i.firstChild);
|
|
2712
2717
|
else s = i;
|
|
2713
|
-
return (
|
|
2718
|
+
return (_e.shadowroot || _e.shadowrootmode) && (s = j.call(r, s, !0)), s;
|
|
2714
2719
|
}
|
|
2715
|
-
let
|
|
2716
|
-
return
|
|
2720
|
+
let u = ke ? i.outerHTML : i.innerHTML;
|
|
2721
|
+
return ke && he["!doctype"] && i.ownerDocument && i.ownerDocument.doctype && i.ownerDocument.doctype.name && Ci(Qi, i.ownerDocument.doctype.name) && (u = "<!DOCTYPE " + i.ownerDocument.doctype.name + ">\n" + u), De && (u = Et(u)), S && Ie ? D(u) : u;
|
|
2717
2722
|
}, t.setConfig = function() {
|
|
2718
|
-
|
|
2723
|
+
dt(arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {}), Ae = !0, je = he, Me = _e;
|
|
2719
2724
|
}, t.clearConfig = function() {
|
|
2720
|
-
|
|
2725
|
+
ct = null, Ae = !1, je = null, Me = null, S = w, C = "";
|
|
2721
2726
|
}, t.isValidAttribute = function(e, t, n) {
|
|
2722
|
-
return
|
|
2727
|
+
return ct || dt({}), It(st(e), st(t), n);
|
|
2723
2728
|
}, t.addHook = function(e, t) {
|
|
2724
|
-
typeof t == "function" && xi(
|
|
2729
|
+
typeof t == "function" && xi(ae, e) && ci(ae[e], t);
|
|
2725
2730
|
}, t.removeHook = function(e, t) {
|
|
2726
|
-
if (xi(
|
|
2731
|
+
if (xi(ae, e)) {
|
|
2727
2732
|
if (t !== void 0) {
|
|
2728
|
-
let n = oi(
|
|
2729
|
-
return n === -1 ? void 0 : li(
|
|
2733
|
+
let n = oi(ae[e], t);
|
|
2734
|
+
return n === -1 ? void 0 : li(ae[e], n, 1)[0];
|
|
2730
2735
|
}
|
|
2731
|
-
return si(
|
|
2736
|
+
return si(ae[e]);
|
|
2732
2737
|
}
|
|
2733
2738
|
}, t.removeHooks = function(e) {
|
|
2734
|
-
xi(
|
|
2739
|
+
xi(ae, e) && (ae[e] = []);
|
|
2735
2740
|
}, t.removeAllHooks = function() {
|
|
2736
|
-
|
|
2741
|
+
ae = sa();
|
|
2737
2742
|
}, t;
|
|
2738
2743
|
}
|
|
2739
2744
|
la();
|
|
@@ -49627,7 +49632,7 @@ var pj = 2e3, mj = (e, t = pj) => {
|
|
|
49627
49632
|
}, xj = {
|
|
49628
49633
|
dark: bj,
|
|
49629
49634
|
light: bj
|
|
49630
|
-
}, Sj = a(({ language: e, value: t, isStreaming: n, theme: r = fn.Dark, copyLabel: i = "Copy code", copiedLabel: a = "Copied!", downloadLabel: o = "Download code", hideDownload: s = !1, containerClassName: c, headerClassName: l, codeClassName: u = "dial-code-text", languageLabelClassName: d = "dial-tiny-semi-text
|
|
49635
|
+
}, Sj = a(({ language: e, value: t, isStreaming: n, theme: r = fn.Dark, copyLabel: i = "Copy code", copiedLabel: a = "Copied!", downloadLabel: o = "Download code", hideDownload: s = !1, containerClassName: c, headerClassName: l, codeClassName: u = "dial-code-text", languageLabelClassName: d = "dial-tiny-lead-semi-text", title: f, titleSlot: p, colors: m }) => {
|
|
49631
49636
|
let { isCopied: h, copy: g } = mj(t), _ = r === fn.Light;
|
|
49632
49637
|
return /* @__PURE__ */ N("div", {
|
|
49633
49638
|
style: Vr({
|
|
@@ -49646,14 +49651,14 @@ var pj = 2e3, mj = (e, t = pj) => {
|
|
|
49646
49651
|
children: f ?? e
|
|
49647
49652
|
}), !n && /* @__PURE__ */ N("div", {
|
|
49648
49653
|
className: "flex items-center gap-1",
|
|
49649
|
-
children: [!s && /* @__PURE__ */ M(
|
|
49654
|
+
children: [!s && /* @__PURE__ */ M(Ce, {
|
|
49650
49655
|
icon: /* @__PURE__ */ M(Mh, { size: T.SM }),
|
|
49651
49656
|
"aria-label": o,
|
|
49652
|
-
size:
|
|
49657
|
+
size: be.Small,
|
|
49653
49658
|
onClick: () => {
|
|
49654
49659
|
Dh(t, `code.${Ch(e)}`);
|
|
49655
49660
|
}
|
|
49656
|
-
}), /* @__PURE__ */ M(
|
|
49661
|
+
}), /* @__PURE__ */ M(Ce, {
|
|
49657
49662
|
icon: h ? /* @__PURE__ */ M(Ah, {
|
|
49658
49663
|
size: T.SM,
|
|
49659
49664
|
className: hj.copiedIcon,
|
|
@@ -49663,7 +49668,7 @@ var pj = 2e3, mj = (e, t = pj) => {
|
|
|
49663
49668
|
"aria-hidden": !0
|
|
49664
49669
|
}),
|
|
49665
49670
|
"aria-label": h ? a : i,
|
|
49666
|
-
size:
|
|
49671
|
+
size: be.Small,
|
|
49667
49672
|
onClick: g
|
|
49668
49673
|
})]
|
|
49669
49674
|
})]
|
|
@@ -49757,7 +49762,7 @@ var pj = 2e3, mj = (e, t = pj) => {
|
|
|
49757
49762
|
tabIndex: u ? 0 : void 0,
|
|
49758
49763
|
children: /* @__PURE__ */ M("table", {
|
|
49759
49764
|
ref: a,
|
|
49760
|
-
className: Br("w-max min-w-full border-collapse", t.tableFont ?? "text
|
|
49765
|
+
className: Br("w-max min-w-full border-collapse", t.tableFont ?? "dial-small-text"),
|
|
49761
49766
|
children: e
|
|
49762
49767
|
})
|
|
49763
49768
|
})
|
|
@@ -49817,7 +49822,7 @@ var pj = 2e3, mj = (e, t = pj) => {
|
|
|
49817
49822
|
children: t
|
|
49818
49823
|
}),
|
|
49819
49824
|
strong: ({ children: t }) => /* @__PURE__ */ M("strong", {
|
|
49820
|
-
className: e.strong ?? "
|
|
49825
|
+
className: e.strong ?? "dial-body-paragraph-semi-text",
|
|
49821
49826
|
children: t
|
|
49822
49827
|
}),
|
|
49823
49828
|
em: ({ children: t }) => /* @__PURE__ */ M("em", {
|
|
@@ -49873,11 +49878,11 @@ var pj = 2e3, mj = (e, t = pj) => {
|
|
|
49873
49878
|
},
|
|
49874
49879
|
th: ({ children: t }) => /* @__PURE__ */ M("th", {
|
|
49875
49880
|
scope: "col",
|
|
49876
|
-
className: Br("sticky top-0 z-[2] max-w-96 whitespace-normal break-words border-b px-3 py-2.5 text-start
|
|
49881
|
+
className: Br("sticky top-0 z-[2] max-w-96 whitespace-normal break-words border-b px-3 py-2.5 text-start", Ej.rowDivider, Ej.tableHeaderCell, e.tableHeaderFont ?? "dial-tiny-lead-semi-text", e.tableCell, e.tableHeader),
|
|
49877
49882
|
children: t
|
|
49878
49883
|
}),
|
|
49879
49884
|
td: ({ children: t }) => /* @__PURE__ */ M("td", {
|
|
49880
|
-
className: Br("max-w-96 whitespace-normal
|
|
49885
|
+
className: Br("max-w-96 whitespace-normal border-b px-3 py-2.5 align-top [overflow-wrap:anywhere]", Ej.rowDivider, e.tableBodyCell, e.tableCell),
|
|
49881
49886
|
children: t
|
|
49882
49887
|
})
|
|
49883
49888
|
}), Ij = a(({ content: e, isStreaming: t, streamCharactersPerSecond: n, classNames: r = Mj, components: i, rehypePlugins: a = jj, thinkingLabel: o = "Thinking", codeBlockCopyLabel: s, codeBlockCopiedLabel: c, codeBlockTheme: l, colors: u, tableScrollRegionAriaLabel: d }) => {
|
|
@@ -49925,11 +49930,11 @@ var pj = 2e3, mj = (e, t = pj) => {
|
|
|
49925
49930
|
h3: "dial-h3-text mb-2 mt-4 first:mt-0 [text-wrap:balance]",
|
|
49926
49931
|
h4: "mb-2 mt-4 dial-body-semi-text first:mt-0 [text-wrap:balance]",
|
|
49927
49932
|
h5: "mb-2 mt-4 dial-small-semi-text first:mt-0 [text-wrap:balance]",
|
|
49928
|
-
h6: "mb-2 mt-4
|
|
49933
|
+
h6: "mb-2 mt-4 dial-tiny-text first:mt-0 [text-wrap:balance]",
|
|
49929
49934
|
p: "dial-body-paragraph-text mb-3 break-words [overflow-wrap:anywhere] [text-wrap:pretty] last:mb-0",
|
|
49930
49935
|
ul: "mb-3 space-y-1",
|
|
49931
49936
|
ol: "mb-3 space-y-1",
|
|
49932
|
-
codeInline: "mx-0.5 px-1.5
|
|
49937
|
+
codeInline: "mx-0.5 px-1.5 break-words [overflow-wrap:anywhere]",
|
|
49933
49938
|
blockquote: "my-4",
|
|
49934
49939
|
link: "break-words [overflow-wrap:anywhere]",
|
|
49935
49940
|
tableWrapper: "my-4"
|
|
@@ -49945,111 +49950,32 @@ a(({ content: e, isStreaming: t, thinkingLabel: n, components: r, codeBlockCopyL
|
|
|
49945
49950
|
classNames: Lj
|
|
49946
49951
|
}));
|
|
49947
49952
|
var Rj = {
|
|
49948
|
-
container: "_container_1kcxu_2",
|
|
49949
|
-
icon: "_icon_1kcxu_25",
|
|
49950
|
-
input: "_input_1kcxu_29"
|
|
49951
|
-
}, zj = ({ value: e, onChange: t, labels: n, iconSize: r = T.MD, iconStrokeWidth: i, styles: a }) => {
|
|
49952
|
-
let { placeholder: o = "Search", ariaLabel: s, clearLabel: c = "Clear search" } = n ?? {}, { colors: l, containerClassName: u, iconClassName: d, inputClassName: f, clearButtonClassName: p } = a ?? {}, m = s ?? o;
|
|
49953
|
-
return /* @__PURE__ */ M("div", {
|
|
49954
|
-
role: "search",
|
|
49955
|
-
style: Vr({
|
|
49956
|
-
"--search-bar-bg": l?.background,
|
|
49957
|
-
"--search-bar-border-focus": l?.borderFocus,
|
|
49958
|
-
"--search-bar-icon": l?.icon,
|
|
49959
|
-
"--search-bar-text": l?.text,
|
|
49960
|
-
"--search-bar-placeholder": l?.placeholder
|
|
49961
|
-
}),
|
|
49962
|
-
children: /* @__PURE__ */ N("div", {
|
|
49963
|
-
className: Br(Rj.container, "flex cursor-text items-center gap-3 rounded-xl border px-4 py-2 transition-[border-color,box-shadow] duration-150 ease-in-out", u),
|
|
49964
|
-
children: [
|
|
49965
|
-
/* @__PURE__ */ M(mt, {
|
|
49966
|
-
size: r,
|
|
49967
|
-
stroke: i,
|
|
49968
|
-
className: Br(Rj.icon, "shrink-0 transition-colors duration-150 ease-in-out", d),
|
|
49969
|
-
"aria-hidden": !0
|
|
49970
|
-
}),
|
|
49971
|
-
/* @__PURE__ */ M("input", {
|
|
49972
|
-
type: "text",
|
|
49973
|
-
className: Br(Rj.input, "dial-small-text min-w-0 flex-1 border-0 p-0 outline-none", f),
|
|
49974
|
-
value: e,
|
|
49975
|
-
placeholder: o,
|
|
49976
|
-
"aria-label": m,
|
|
49977
|
-
onChange: (e) => t(e.target.value)
|
|
49978
|
-
}),
|
|
49979
|
-
e && /* @__PURE__ */ M("button", {
|
|
49980
|
-
type: "button",
|
|
49981
|
-
onClick: () => t(""),
|
|
49982
|
-
"aria-label": c,
|
|
49983
|
-
className: Br("flex shrink-0 items-center justify-center", p),
|
|
49984
|
-
children: /* @__PURE__ */ M(_t, {
|
|
49985
|
-
size: r,
|
|
49986
|
-
stroke: i,
|
|
49987
|
-
className: Br(Rj.icon, d),
|
|
49988
|
-
"aria-hidden": !0
|
|
49989
|
-
})
|
|
49990
|
-
})
|
|
49991
|
-
]
|
|
49992
|
-
})
|
|
49993
|
-
});
|
|
49994
|
-
}, Bj = {
|
|
49995
|
-
tabContainer: "_tabContainer_1917c_1",
|
|
49996
|
-
tabActive: "_tabActive_1917c_19"
|
|
49997
|
-
};
|
|
49998
|
-
a(({ tabs: e, activeTabId: t, onTabChange: n, styles: r }) => {
|
|
49999
|
-
let { tabClassName: i = "dial-tiny-semi-text" } = r?.typography ?? {};
|
|
50000
|
-
return /* @__PURE__ */ M("div", {
|
|
50001
|
-
className: "flex flex-nowrap gap-1",
|
|
50002
|
-
role: "tablist",
|
|
50003
|
-
style: Vr({
|
|
50004
|
-
"--pt-tab-text": r?.colors?.tabText,
|
|
50005
|
-
"--pt-tab-text-hover": r?.colors?.tabTextHover,
|
|
50006
|
-
"--pt-tab-active-text": r?.colors?.activeTabText
|
|
50007
|
-
}),
|
|
50008
|
-
children: e.map((e) => {
|
|
50009
|
-
let r = t === e.id;
|
|
50010
|
-
return /* @__PURE__ */ M("div", {
|
|
50011
|
-
role: "tab",
|
|
50012
|
-
"aria-selected": r,
|
|
50013
|
-
className: "contents",
|
|
50014
|
-
children: /* @__PURE__ */ M(pe, {
|
|
50015
|
-
label: e.label,
|
|
50016
|
-
selected: r,
|
|
50017
|
-
onClick: () => n(e.id),
|
|
50018
|
-
className: Br("box-border h-auto shrink-0 justify-center rounded-full p-2 text-center", i, Bj.tabContainer, r && Bj.tabActive)
|
|
50019
|
-
})
|
|
50020
|
-
}, e.id);
|
|
50021
|
-
})
|
|
50022
|
-
});
|
|
50023
|
-
});
|
|
50024
|
-
//#endregion
|
|
50025
|
-
//#region ../ai-dial-kit/src/components/TagInput/TagInput.tsx
|
|
50026
|
-
var Vj = (e) => /* @__PURE__ */ M(me, { ...e }), Hj = {
|
|
50027
49953
|
dialog: "_dialog_v6cml_1",
|
|
50028
49954
|
label: "_label_v6cml_11",
|
|
50029
49955
|
error: "_error_v6cml_15"
|
|
50030
|
-
},
|
|
49956
|
+
}, zj = 20, Bj = 200, Vj = 8, Hj = (e) => {
|
|
50031
49957
|
let t = e.trim();
|
|
50032
|
-
if (t.length === 0 || t.length >
|
|
49958
|
+
if (t.length === 0 || t.length > Bj) return !1;
|
|
50033
49959
|
try {
|
|
50034
49960
|
return new RegExp(t) instanceof RegExp;
|
|
50035
49961
|
} catch {
|
|
50036
49962
|
return !1;
|
|
50037
49963
|
}
|
|
50038
|
-
},
|
|
49964
|
+
}, Uj = ({ sourceOptions: e, onSave: t, onCancel: n, disabled: r = !1, maxTargets: i = zj, labels: a = {}, labelClassName: o = "dial-small-semi-text", errorClassName: s = "dial-small-text", colors: u }) => {
|
|
50039
49965
|
let d = Vr({
|
|
50040
49966
|
"--pare-mobile-bg": u?.mobileBackground,
|
|
50041
49967
|
"--pare-border": u?.border,
|
|
50042
49968
|
"--pare-bg": u?.background,
|
|
50043
49969
|
"--pare-label-text": u?.labelText,
|
|
50044
49970
|
"--pare-error-text": u?.errorText
|
|
50045
|
-
}), { sourceLabel: h = "Source", sourcePlaceholder: g = "Select...", functionLabel: _ = "Function", equalOptionLabel: v = "Equal", containOptionLabel: y = "Contain", regexOptionLabel: b = "Regex", targetsLabel: x = "Targets", targetsPlaceholder: S = "Add a target", patternLabel: C = "Pattern", patternPlaceholder: w = "Enter a regular expression", invalidRegexError: T = "Enter a valid regular expression.", saveLabel: E = "Save", cancelLabel: ee = "Cancel", dialogAriaLabel: D = "Add access rule" } = a, O = l(), te = l(), k = l(), ne = p(null);
|
|
49971
|
+
}), { sourceLabel: h = "Source", sourcePlaceholder: g = "Select...", functionLabel: _ = "Function", equalOptionLabel: v = "Equal", containOptionLabel: y = "Contain", regexOptionLabel: b = "Regex", targetsLabel: x = "Targets", targetsPlaceholder: S = "Add a target", patternLabel: C = "Pattern", patternPlaceholder: w = "Enter a regular expression", invalidRegexError: T = "Enter a valid regular expression.", saveLabel: E = "Save", cancelLabel: ee = "Cancel", dialogAriaLabel: D = "Add access rule" } = a, O = l(), te = l(), k = l(), ne = l(), A = p(null);
|
|
50046
49972
|
c(() => {
|
|
50047
|
-
|
|
49973
|
+
A.current?.focus();
|
|
50048
49974
|
}, []);
|
|
50049
|
-
let [
|
|
49975
|
+
let [re, ie] = m(), [j, ae] = m(), [oe, se] = m([]), [ce, le] = m(""), ue = f(() => e.map((e) => ({
|
|
50050
49976
|
value: e,
|
|
50051
49977
|
label: e
|
|
50052
|
-
})), [e]),
|
|
49978
|
+
})), [e]), de = f(() => [
|
|
50053
49979
|
{
|
|
50054
49980
|
value: Mt.Equal,
|
|
50055
49981
|
label: v
|
|
@@ -50066,9 +49992,9 @@ var Vj = (e) => /* @__PURE__ */ M(me, { ...e }), Hj = {
|
|
|
50066
49992
|
v,
|
|
50067
49993
|
y,
|
|
50068
49994
|
b
|
|
50069
|
-
]),
|
|
49995
|
+
]), fe = j === Mt.Regex, pe = Hj(ce), me = re != null && j != null && (fe ? pe : oe.length > 0);
|
|
50070
49996
|
return /* @__PURE__ */ N("div", {
|
|
50071
|
-
ref:
|
|
49997
|
+
ref: A,
|
|
50072
49998
|
role: "dialog",
|
|
50073
49999
|
"aria-modal": "true",
|
|
50074
50000
|
"aria-label": D,
|
|
@@ -50077,206 +50003,228 @@ var Vj = (e) => /* @__PURE__ */ M(me, { ...e }), Hj = {
|
|
|
50077
50003
|
e.key === "Escape" && (e.stopPropagation(), n());
|
|
50078
50004
|
},
|
|
50079
50005
|
style: d,
|
|
50080
|
-
className: Br("fixed inset-0 z-[60] flex flex-col gap-3 overflow-y-auto p-4", "desktop:static desktop:z-auto desktop:flex-none desktop:overflow-visible desktop:rounded-lg desktop:border desktop:p-3",
|
|
50006
|
+
className: Br("fixed inset-0 z-[60] flex flex-col gap-3 overflow-y-auto p-4", "desktop:static desktop:z-auto desktop:flex-none desktop:overflow-visible desktop:rounded-lg desktop:border desktop:p-3", Rj.dialog),
|
|
50081
50007
|
children: [
|
|
50082
|
-
/* @__PURE__ */ M(
|
|
50008
|
+
/* @__PURE__ */ M(Fe, {
|
|
50083
50009
|
id: te,
|
|
50084
50010
|
labelProps: { label: h },
|
|
50085
|
-
options:
|
|
50086
|
-
value:
|
|
50087
|
-
onChange: (e) =>
|
|
50011
|
+
options: ue,
|
|
50012
|
+
value: re,
|
|
50013
|
+
onChange: (e) => ie(Array.isArray(e) ? e[0] : e),
|
|
50088
50014
|
placeholder: g,
|
|
50089
|
-
searchable: e.length >
|
|
50015
|
+
searchable: e.length > Vj,
|
|
50090
50016
|
searchPlaceholder: g,
|
|
50091
50017
|
disabled: r
|
|
50092
50018
|
}),
|
|
50093
|
-
/* @__PURE__ */ M(
|
|
50019
|
+
/* @__PURE__ */ M(Fe, {
|
|
50094
50020
|
labelProps: { label: _ },
|
|
50095
50021
|
id: k,
|
|
50096
|
-
options:
|
|
50097
|
-
value:
|
|
50022
|
+
options: de,
|
|
50023
|
+
value: j,
|
|
50098
50024
|
onChange: (e) => {
|
|
50099
|
-
|
|
50025
|
+
ae(Array.isArray(e) ? e[0] : e), se([]), le("");
|
|
50100
50026
|
},
|
|
50101
50027
|
placeholder: _,
|
|
50102
50028
|
disabled: r
|
|
50103
50029
|
}),
|
|
50104
|
-
|
|
50030
|
+
fe ? /* @__PURE__ */ N("div", { children: [/* @__PURE__ */ M(we, {
|
|
50105
50031
|
id: `${O}-input`,
|
|
50106
50032
|
labelProps: { label: C },
|
|
50107
50033
|
placeholder: w,
|
|
50108
|
-
value:
|
|
50109
|
-
onChange: (e) =>
|
|
50110
|
-
invalid:
|
|
50111
|
-
"aria-describedby":
|
|
50034
|
+
value: ce,
|
|
50035
|
+
onChange: (e) => le(e ?? ""),
|
|
50036
|
+
invalid: ce.length > 0 && !pe,
|
|
50037
|
+
"aria-describedby": ce.length > 0 && !pe ? O : void 0,
|
|
50112
50038
|
disabled: r
|
|
50113
|
-
}),
|
|
50039
|
+
}), ce.length > 0 && !pe && /* @__PURE__ */ M("span", {
|
|
50114
50040
|
id: O,
|
|
50115
50041
|
role: "alert",
|
|
50116
|
-
className: Br("mt-1 block", s,
|
|
50042
|
+
className: Br("mt-1 block", s, Rj.error),
|
|
50117
50043
|
children: T
|
|
50118
|
-
})] }) : /* @__PURE__ */ M(
|
|
50119
|
-
|
|
50120
|
-
label: x,
|
|
50044
|
+
})] }) : /* @__PURE__ */ M(Be, {
|
|
50045
|
+
id: ne,
|
|
50046
|
+
labelProps: { label: x },
|
|
50121
50047
|
placeholder: S,
|
|
50122
|
-
|
|
50048
|
+
value: oe,
|
|
50123
50049
|
onChange: (e) => {
|
|
50124
50050
|
let t = [];
|
|
50125
50051
|
for (let n of e) {
|
|
50126
50052
|
let e = n.trim();
|
|
50127
50053
|
if (!(e.length === 0 || t.includes(e)) && (t.push(e), t.length >= i)) break;
|
|
50128
50054
|
}
|
|
50129
|
-
|
|
50055
|
+
se(t);
|
|
50130
50056
|
},
|
|
50131
50057
|
disabled: r
|
|
50132
|
-
}
|
|
50058
|
+
}),
|
|
50133
50059
|
/* @__PURE__ */ N("div", {
|
|
50134
50060
|
className: "mt-auto flex justify-end gap-2 desktop:mt-2",
|
|
50135
|
-
children: [/* @__PURE__ */ M(
|
|
50061
|
+
children: [/* @__PURE__ */ M(Ee, {
|
|
50136
50062
|
label: ee,
|
|
50137
50063
|
onClick: n,
|
|
50138
50064
|
disabled: r
|
|
50139
|
-
}), /* @__PURE__ */ M(
|
|
50065
|
+
}), /* @__PURE__ */ M(Me, {
|
|
50140
50066
|
label: E,
|
|
50141
50067
|
onClick: () => {
|
|
50142
|
-
!
|
|
50143
|
-
source:
|
|
50144
|
-
function:
|
|
50145
|
-
targets:
|
|
50068
|
+
!me || re == null || j == null || t({
|
|
50069
|
+
source: re,
|
|
50070
|
+
function: j,
|
|
50071
|
+
targets: fe ? [ce.trim()] : oe
|
|
50146
50072
|
});
|
|
50147
50073
|
},
|
|
50148
|
-
disabled: r || !
|
|
50074
|
+
disabled: r || !me
|
|
50149
50075
|
})]
|
|
50150
50076
|
})
|
|
50151
50077
|
]
|
|
50152
50078
|
});
|
|
50153
|
-
},
|
|
50154
|
-
ruleRow: "
|
|
50155
|
-
heading: "
|
|
50156
|
-
|
|
50157
|
-
|
|
50158
|
-
|
|
50159
|
-
|
|
50160
|
-
|
|
50161
|
-
"--par-rule-
|
|
50162
|
-
"--par-
|
|
50163
|
-
"--par-
|
|
50164
|
-
"--par-
|
|
50165
|
-
|
|
50079
|
+
}, Wj = {
|
|
50080
|
+
ruleRow: "_ruleRow_176t8_1",
|
|
50081
|
+
heading: "_heading_176t8_6",
|
|
50082
|
+
hint: "_hint_176t8_10",
|
|
50083
|
+
loading: "_loading_176t8_14",
|
|
50084
|
+
ruleText: "_ruleText_176t8_18"
|
|
50085
|
+
}, Gj = 20, Kj = (e, t) => e === Mt.Equal ? t.equal : e === Mt.Contain ? t.contain : t.regex, qj = ({ rules: e, onRulesChange: t, sourceOptions: n, folderName: r, disabled: i = !1, isLoading: a = !1, hasLoadError: o = !1, maxRules: s = Gj, maxTargetsPerRule: u, labels: d = {}, headingClassName: f = "dial-body-semi-text", hintClassName: h = "dial-small-text", loadingClassName: g = "dial-small-text", ruleTextClassName: _ = "dial-small-text", ruleSourceClassName: v = "dial-small-semi-text", colors: b }) => {
|
|
50086
|
+
let x = Vr({
|
|
50087
|
+
"--par-rule-border": b?.ruleBorder,
|
|
50088
|
+
"--par-rule-bg": b?.ruleBackground,
|
|
50089
|
+
"--par-heading-text": b?.headingText,
|
|
50090
|
+
"--par-hint-text": b?.hintText,
|
|
50091
|
+
"--par-loading-text": b?.loadingText,
|
|
50092
|
+
"--par-rule-text": b?.ruleText
|
|
50093
|
+
}), { heading: S = "Allow access if all match", folderScopeHint: C = "These rules apply to \"{folder}\". Selecting another folder loads that folder's own rules instead.", noFolderScopeHint: w = "Access rules apply to the destination folder — pick a folder above to set its rules.", rulesWithoutFolderWarning: E = "These rules have no destination yet. Select a folder above to apply them.", maxRulesReachedLabel: ee = "Rule limit reached ({max}). Remove a rule to add another.", addRuleLabel: D = "Add rule", clearAllLabel: O = "Clear all", orSeparatorLabel: te = "Or", removeRuleAriaLabelTemplate: k = "Remove rule for {source}: {targets}", equalFunctionLabel: ne = "Equal", containFunctionLabel: A = "Contain", regexFunctionLabel: re = "Regex", loadingLabel: ie = "Loading existing rules…", loadErrorLabel: j = "Couldn't load existing rules for this folder. You can still add rules manually.", ruleAddedAnnouncement: ae = "Rule added.", ruleRemovedAnnouncement: oe = "Rule removed.", rulesClearedAnnouncement: se = "All rules cleared.", rulesLoadedAnnouncement: ce = "Existing rules loaded for the selected folder.", editorLabels: le } = d, ue = l(), [de, fe] = m(!1), [pe, me] = m(""), he = p(null), ge = p(a);
|
|
50166
50094
|
c(() => {
|
|
50167
|
-
|
|
50095
|
+
ge.current && !a && e.length > 0 && me(ce), ge.current = a;
|
|
50168
50096
|
}, [
|
|
50169
|
-
|
|
50097
|
+
a,
|
|
50170
50098
|
e,
|
|
50171
|
-
|
|
50099
|
+
ce
|
|
50172
50100
|
]);
|
|
50173
|
-
let
|
|
50174
|
-
|
|
50175
|
-
},
|
|
50176
|
-
|
|
50177
|
-
},
|
|
50178
|
-
t([...e, n]),
|
|
50179
|
-
},
|
|
50180
|
-
t(e.filter((e, t) => t !== n)),
|
|
50181
|
-
},
|
|
50182
|
-
t([]),
|
|
50183
|
-
},
|
|
50184
|
-
equal:
|
|
50185
|
-
contain:
|
|
50186
|
-
regex:
|
|
50187
|
-
},
|
|
50101
|
+
let _e = () => {
|
|
50102
|
+
he.current = document.activeElement, fe(!0);
|
|
50103
|
+
}, ve = () => {
|
|
50104
|
+
fe(!1), he.current?.focus?.();
|
|
50105
|
+
}, ye = (n) => {
|
|
50106
|
+
t([...e, n]), me(ae), ve();
|
|
50107
|
+
}, be = (n) => {
|
|
50108
|
+
t(e.filter((e, t) => t !== n)), me(oe);
|
|
50109
|
+
}, xe = () => {
|
|
50110
|
+
t([]), me(se);
|
|
50111
|
+
}, we = {
|
|
50112
|
+
equal: ne,
|
|
50113
|
+
contain: A,
|
|
50114
|
+
regex: re
|
|
50115
|
+
}, Te = e.length >= s, Ee = i || Te, Ae = r != null && r !== "";
|
|
50188
50116
|
return /* @__PURE__ */ N("div", {
|
|
50189
|
-
|
|
50117
|
+
role: "group",
|
|
50118
|
+
"aria-labelledby": ue,
|
|
50119
|
+
className: Br(i && "pointer-events-none opacity-60"),
|
|
50190
50120
|
children: [
|
|
50191
50121
|
/* @__PURE__ */ M("span", {
|
|
50192
50122
|
role: "status",
|
|
50193
50123
|
"aria-live": "polite",
|
|
50194
50124
|
className: "sr-only",
|
|
50195
|
-
children:
|
|
50125
|
+
children: pe
|
|
50196
50126
|
}),
|
|
50197
50127
|
/* @__PURE__ */ M("div", {
|
|
50198
|
-
|
|
50199
|
-
|
|
50128
|
+
id: ue,
|
|
50129
|
+
className: Br("mb-1", f, Wj.heading),
|
|
50130
|
+
children: S
|
|
50131
|
+
}),
|
|
50132
|
+
/* @__PURE__ */ M("p", {
|
|
50133
|
+
className: Br("mb-2", h, Wj.hint),
|
|
50134
|
+
children: Ae ? C.replace("{folder}", r) : w
|
|
50135
|
+
}),
|
|
50136
|
+
e.length > 0 && !Ae && /* @__PURE__ */ M("div", {
|
|
50137
|
+
className: "mb-2",
|
|
50138
|
+
children: /* @__PURE__ */ M(De, {
|
|
50139
|
+
type: Oe.SectionMessage,
|
|
50140
|
+
variant: ke.Warning,
|
|
50141
|
+
message: E
|
|
50142
|
+
})
|
|
50200
50143
|
}),
|
|
50201
|
-
|
|
50202
|
-
className: Br("mb-2 flex items-center gap-2",
|
|
50203
|
-
children: [/* @__PURE__ */ M(
|
|
50144
|
+
a && /* @__PURE__ */ N("div", {
|
|
50145
|
+
className: Br("mb-2 flex items-center gap-2", g, Wj.loading),
|
|
50146
|
+
children: [/* @__PURE__ */ M(Re, {
|
|
50204
50147
|
size: 16,
|
|
50205
|
-
ariaLabel:
|
|
50206
|
-
}), /* @__PURE__ */ M("span", { children:
|
|
50148
|
+
ariaLabel: ie
|
|
50149
|
+
}), /* @__PURE__ */ M("span", { children: ie })]
|
|
50207
50150
|
}),
|
|
50208
|
-
|
|
50151
|
+
o && /* @__PURE__ */ M("div", {
|
|
50209
50152
|
className: "mb-2",
|
|
50210
|
-
children: /* @__PURE__ */ M(
|
|
50211
|
-
type:
|
|
50212
|
-
variant:
|
|
50213
|
-
message:
|
|
50153
|
+
children: /* @__PURE__ */ M(De, {
|
|
50154
|
+
type: Oe.SectionMessage,
|
|
50155
|
+
variant: ke.Warning,
|
|
50156
|
+
message: j
|
|
50214
50157
|
})
|
|
50215
50158
|
}),
|
|
50216
50159
|
e.length > 0 && /* @__PURE__ */ M("ul", {
|
|
50217
50160
|
className: "mb-3 flex flex-col gap-2",
|
|
50218
50161
|
children: e.map((e, t) => {
|
|
50219
|
-
let n = e.targets.join(` ${
|
|
50162
|
+
let n = e.targets.join(` ${te} `), r = k.replace("{source}", e.source).replace("{targets}", n);
|
|
50220
50163
|
return /* @__PURE__ */ N("li", {
|
|
50221
|
-
style:
|
|
50222
|
-
className: Br("flex items-center justify-between gap-2 rounded-lg border px-3 py-2",
|
|
50164
|
+
style: x,
|
|
50165
|
+
className: Br("flex items-center justify-between gap-2 rounded-lg border px-3 py-2", Wj.ruleRow),
|
|
50223
50166
|
children: [/* @__PURE__ */ N("span", {
|
|
50224
|
-
className: Br("truncate",
|
|
50167
|
+
className: Br("truncate", _, Wj.ruleText),
|
|
50225
50168
|
children: [
|
|
50226
50169
|
/* @__PURE__ */ M("span", {
|
|
50227
|
-
className:
|
|
50170
|
+
className: v,
|
|
50228
50171
|
children: e.source
|
|
50229
50172
|
}),
|
|
50230
50173
|
" ",
|
|
50231
|
-
|
|
50174
|
+
Kj(e.function, we),
|
|
50232
50175
|
": ",
|
|
50233
50176
|
n
|
|
50234
50177
|
]
|
|
50235
|
-
}), /* @__PURE__ */ M(
|
|
50178
|
+
}), /* @__PURE__ */ M(Ce, {
|
|
50236
50179
|
icon: /* @__PURE__ */ M(_t, {
|
|
50237
50180
|
size: T.SM,
|
|
50238
50181
|
"aria-hidden": !0
|
|
50239
50182
|
}),
|
|
50240
|
-
"aria-label":
|
|
50241
|
-
onClick: () =>
|
|
50242
|
-
disabled:
|
|
50183
|
+
"aria-label": r,
|
|
50184
|
+
onClick: () => be(t),
|
|
50185
|
+
disabled: i
|
|
50243
50186
|
})]
|
|
50244
50187
|
}, t);
|
|
50245
50188
|
})
|
|
50246
50189
|
}),
|
|
50247
|
-
|
|
50190
|
+
de && /* @__PURE__ */ M(Uj, {
|
|
50248
50191
|
sourceOptions: n,
|
|
50249
|
-
onSave:
|
|
50250
|
-
onCancel:
|
|
50251
|
-
disabled:
|
|
50252
|
-
maxTargets:
|
|
50253
|
-
labels:
|
|
50192
|
+
onSave: ye,
|
|
50193
|
+
onCancel: ve,
|
|
50194
|
+
disabled: i,
|
|
50195
|
+
maxTargets: u,
|
|
50196
|
+
labels: le
|
|
50254
50197
|
}),
|
|
50255
50198
|
/* @__PURE__ */ N("div", {
|
|
50256
|
-
className: "flex items-center gap-2",
|
|
50257
|
-
children: [/* @__PURE__ */ M(
|
|
50258
|
-
label:
|
|
50199
|
+
className: "flex flex-wrap items-center gap-2",
|
|
50200
|
+
children: [/* @__PURE__ */ M(Me, {
|
|
50201
|
+
label: D,
|
|
50259
50202
|
iconBefore: /* @__PURE__ */ M(pt, {
|
|
50260
50203
|
size: T.SM,
|
|
50261
50204
|
"aria-hidden": !0
|
|
50262
50205
|
}),
|
|
50263
|
-
onClick:
|
|
50264
|
-
disabled:
|
|
50265
|
-
}), e.length > 0 && /* @__PURE__ */ M(
|
|
50266
|
-
|
|
50267
|
-
|
|
50268
|
-
|
|
50206
|
+
onClick: _e,
|
|
50207
|
+
disabled: Ee
|
|
50208
|
+
}), e.length > 0 && /* @__PURE__ */ M(Se, {
|
|
50209
|
+
variant: y.Primary,
|
|
50210
|
+
label: O,
|
|
50211
|
+
onClick: xe,
|
|
50212
|
+
disabled: i
|
|
50269
50213
|
})]
|
|
50214
|
+
}),
|
|
50215
|
+
Te && /* @__PURE__ */ M("p", {
|
|
50216
|
+
className: Br("mt-2", h, Wj.hint),
|
|
50217
|
+
children: ee.replace("{max}", String(s))
|
|
50270
50218
|
})
|
|
50271
50219
|
]
|
|
50272
50220
|
});
|
|
50273
|
-
},
|
|
50221
|
+
}, Jj = {
|
|
50274
50222
|
currentBadge: "_currentBadge_1c7hb_1",
|
|
50275
50223
|
version: "_version_1c7hb_7",
|
|
50276
50224
|
date: "_date_1c7hb_11",
|
|
50277
50225
|
emptyState: "_emptyState_1c7hb_15",
|
|
50278
50226
|
stripedRow: "_stripedRow_1c7hb_19"
|
|
50279
|
-
},
|
|
50227
|
+
}, Yj = ({ entries: e, currentVersion: t, isLoading: n = !1, hasError: r = !1, versionPrefix: i = "Version", currentBadgeLabel: a = "Current", emptyStateLabel: o = "Not published to this folder yet — this will be the first version here.", loadingLabel: s = "Loading history…", errorLabel: c = "Failed to load publish history.", versionClassName: l = "dial-small-text", dateClassName: u = "dial-small-text", emptyStateClassName: d = "dial-small-text", colors: f }) => {
|
|
50280
50228
|
let p = Vr({
|
|
50281
50229
|
"--phl-badge-border": f?.currentBadgeBorder,
|
|
50282
50230
|
"--phl-badge-bg": f?.currentBadgeBackground,
|
|
@@ -50285,7 +50233,7 @@ var Vj = (e) => /* @__PURE__ */ M(me, { ...e }), Hj = {
|
|
|
50285
50233
|
"--phl-date-text": f?.dateText,
|
|
50286
50234
|
"--phl-empty-text": f?.emptyStateText,
|
|
50287
50235
|
"--phl-striped-bg": f?.stripedBackground
|
|
50288
|
-
}), m = Br(d,
|
|
50236
|
+
}), m = Br(d, Jj.emptyState);
|
|
50289
50237
|
return n ? /* @__PURE__ */ M("p", {
|
|
50290
50238
|
style: p,
|
|
50291
50239
|
className: m,
|
|
@@ -50302,28 +50250,28 @@ var Vj = (e) => /* @__PURE__ */ M(me, { ...e }), Hj = {
|
|
|
50302
50250
|
}) : /* @__PURE__ */ M("ul", {
|
|
50303
50251
|
style: p,
|
|
50304
50252
|
children: e.map((e, n) => /* @__PURE__ */ N("li", {
|
|
50305
|
-
className: Br("flex items-center justify-between gap-2 rounded-lg px-3 py-[11px]", n % 2 == 0 &&
|
|
50253
|
+
className: Br("flex items-center justify-between gap-2 rounded-lg px-3 py-[11px]", n % 2 == 0 && Jj.stripedRow),
|
|
50306
50254
|
children: [/* @__PURE__ */ N("span", {
|
|
50307
50255
|
className: "flex min-w-0 items-center gap-2",
|
|
50308
50256
|
style: p,
|
|
50309
50257
|
children: [/* @__PURE__ */ N("span", {
|
|
50310
|
-
className: Br(l,
|
|
50258
|
+
className: Br(l, Jj.version),
|
|
50311
50259
|
children: [
|
|
50312
50260
|
i,
|
|
50313
50261
|
" ",
|
|
50314
50262
|
e.version
|
|
50315
50263
|
]
|
|
50316
|
-
}), e.version === t && /* @__PURE__ */ M(
|
|
50264
|
+
}), e.version === t && /* @__PURE__ */ M(ze, {
|
|
50317
50265
|
label: a,
|
|
50318
|
-
className: Br("shrink-0
|
|
50266
|
+
className: Br("shrink-0 whitespace-nowrap", Jj.currentBadge)
|
|
50319
50267
|
})]
|
|
50320
50268
|
}), /* @__PURE__ */ M("span", {
|
|
50321
|
-
className: Br(u,
|
|
50269
|
+
className: Br(u, Jj.date),
|
|
50322
50270
|
children: It(e.publishedAt)
|
|
50323
50271
|
})]
|
|
50324
50272
|
}, `${e.version}-${n}`))
|
|
50325
50273
|
});
|
|
50326
|
-
},
|
|
50274
|
+
}, Xj = /* @__PURE__ */ Dt(((e, t) => {
|
|
50327
50275
|
(function() {
|
|
50328
50276
|
var e = {}.hasOwnProperty;
|
|
50329
50277
|
function n() {
|
|
@@ -50349,8 +50297,8 @@ var Vj = (e) => /* @__PURE__ */ M(me, { ...e }), Hj = {
|
|
|
50349
50297
|
return n;
|
|
50350
50298
|
}) : window.classNames = n;
|
|
50351
50299
|
})();
|
|
50352
|
-
})),
|
|
50353
|
-
|
|
50300
|
+
})), Zj = /* @__PURE__ */ Ot({ default: () => Qj }), Qj, $j = Et((() => {
|
|
50301
|
+
Qj = {
|
|
50354
50302
|
"application/1d-interleaved-parityfec": { source: "iana" },
|
|
50355
50303
|
"application/3gpdash-qoe-report+xml": {
|
|
50356
50304
|
source: "iana",
|
|
@@ -57969,11 +57917,11 @@ var Vj = (e) => /* @__PURE__ */ M(me, { ...e }), Hj = {
|
|
|
57969
57917
|
"x-shader/x-fragment": { compressible: !0 },
|
|
57970
57918
|
"x-shader/x-vertex": { compressible: !0 }
|
|
57971
57919
|
};
|
|
57972
|
-
})),
|
|
57973
|
-
t.exports = (
|
|
57974
|
-
})),
|
|
57920
|
+
})), eM = /* @__PURE__ */ Dt(((e, t) => {
|
|
57921
|
+
t.exports = ($j(), jt(Zj).default);
|
|
57922
|
+
})), tM = /* @__PURE__ */ Dt(((e, t) => {
|
|
57975
57923
|
t.exports = {};
|
|
57976
|
-
})),
|
|
57924
|
+
})), nM = /* @__PURE__ */ Dt(((e, t) => {
|
|
57977
57925
|
var n = {
|
|
57978
57926
|
"prs.": 100,
|
|
57979
57927
|
"x-": 200,
|
|
@@ -57997,8 +57945,8 @@ var Vj = (e) => /* @__PURE__ */ M(me, { ...e }), Hj = {
|
|
|
57997
57945
|
let [a, o] = e.split("/"), s = n[o.replace(/(\.|x-).*/, "$1")] || n.default, c = r[t] || r.default, l = i[a] || i.default, u = 1 - e.length / 100;
|
|
57998
57946
|
return s + c + l + u;
|
|
57999
57947
|
};
|
|
58000
|
-
})),
|
|
58001
|
-
var t =
|
|
57948
|
+
})), rM = /* @__PURE__ */ Dt(((e) => {
|
|
57949
|
+
var t = eM(), n = tM().extname, r = nM(), i = /^\s*([^;\s]*)(?:;|\s|$)/, a = /^text\//i;
|
|
58002
57950
|
e.charset = o, e.charsets = { lookup: o }, e.contentType = s, e.extension = c, e.extensions = Object.create(null), e.lookup = l, e.types = Object.create(null), e._extensionConflicts = [], u(e.extensions, e.types);
|
|
58003
57951
|
function o(e) {
|
|
58004
57952
|
if (!e || typeof e != "string") return !1;
|
|
@@ -58055,7 +58003,7 @@ var Vj = (e) => /* @__PURE__ */ M(me, { ...e }), Hj = {
|
|
|
58055
58003
|
], o = r ? a.indexOf(t[r].source) : 0, s = i ? a.indexOf(t[i].source) : 0;
|
|
58056
58004
|
return e.types[c] !== "application/octet-stream" && (o > s || o === s && e.types[c]?.slice(0, 12) === "application/") || o > s ? r : i;
|
|
58057
58005
|
}
|
|
58058
|
-
})),
|
|
58006
|
+
})), iM = /* @__PURE__ */ At(Xj(), 1), aM = rM(), oM = (t) => /* @__PURE__ */ e.createElement("svg", {
|
|
58059
58007
|
width: 18,
|
|
58060
58008
|
height: 18,
|
|
58061
58009
|
viewBox: "0 0 18 18",
|
|
@@ -58067,7 +58015,7 @@ var Vj = (e) => /* @__PURE__ */ M(me, { ...e }), Hj = {
|
|
|
58067
58015
|
clipRule: "evenodd",
|
|
58068
58016
|
d: "M15.1812 1.2002H2.80615C2.43319 1.2002 2.07551 1.34835 1.81178 1.61208C1.54806 1.8758 1.3999 2.23348 1.3999 2.60645V5.48145C1.3999 5.85441 1.54806 6.21209 1.81178 6.47581C2.07551 6.73954 2.43319 6.8877 2.80615 6.8877H15.1812C15.5541 6.8877 15.9118 6.73954 16.1755 6.47581C16.4392 6.21209 16.5874 5.85441 16.5874 5.48145V2.60645C16.5874 2.23348 16.4392 1.8758 16.1755 1.61208C15.9118 1.34835 15.5541 1.2002 15.1812 1.2002ZM14.8999 5.2002H3.0874V2.8877H14.8999V5.2002ZM12 7.80017C12.3107 7.80017 12.5625 8.05201 12.5625 8.36267V11.7377H15.9375C16.2482 11.7377 16.5 11.9895 16.5 12.3002C16.5 12.6108 16.2482 12.8627 15.9375 12.8627H12.5625V16.2377C12.5625 16.5483 12.3107 16.8002 12 16.8002C11.6893 16.8002 11.4375 16.5483 11.4375 16.2377V12.8627H8.0625C7.75184 12.8627 7.5 12.6108 7.5 12.3002C7.5 11.9895 7.75184 11.7377 8.0625 11.7377H11.4375V8.36267C11.4375 8.05201 11.6893 7.80017 12 7.80017ZM2.41188 12.5883C2.14816 12.3246 2 11.9669 2 11.5939V9.00018H3.6875V11.3127H6.1001V13.0002H3.40625C3.03329 13.0002 2.6756 12.852 2.41188 12.5883Z",
|
|
58069
58017
|
fill: "currentColor"
|
|
58070
|
-
})),
|
|
58018
|
+
})), sM = (t) => /* @__PURE__ */ e.createElement("svg", {
|
|
58071
58019
|
width: 18,
|
|
58072
58020
|
height: 18,
|
|
58073
58021
|
viewBox: "0 0 18 18",
|
|
@@ -58077,7 +58025,7 @@ var Vj = (e) => /* @__PURE__ */ M(me, { ...e }), Hj = {
|
|
|
58077
58025
|
}, /* @__PURE__ */ e.createElement("path", {
|
|
58078
58026
|
d: "M9.00049 7.7998C9.3108 7.80007 9.56279 8.05198 9.56299 8.3623V11.7373H12.938C13.2483 11.7376 13.5003 11.9895 13.5005 12.2998C13.5005 12.6103 13.2484 12.862 12.938 12.8623H9.56299V16.2373C9.56299 16.5478 9.31092 16.7995 9.00049 16.7998C8.68983 16.7998 8.43799 16.548 8.43799 16.2373V12.8623H5.06299C4.75233 12.8623 4.50049 12.6105 4.50049 12.2998C4.50069 11.9893 4.75245 11.7373 5.06299 11.7373H8.43799V8.3623C8.43819 8.05181 8.68995 7.7998 9.00049 7.7998ZM15.1812 1.2002C15.5541 1.2002 15.9116 1.34858 16.1753 1.6123C16.439 1.87603 16.5874 2.23348 16.5874 2.60645V5.48145C16.5874 5.85441 16.439 6.21186 16.1753 6.47559C15.9116 6.73931 15.5541 6.8877 15.1812 6.8877H2.80615C2.43319 6.8877 2.07573 6.73931 1.81201 6.47559C1.54829 6.21186 1.3999 5.85441 1.3999 5.48145V2.60645C1.3999 2.23348 1.54829 1.87603 1.81201 1.6123C2.07573 1.34858 2.43319 1.2002 2.80615 1.2002H15.1812ZM3.0874 2.8877V5.2002H14.8999V2.8877H3.0874Z",
|
|
58079
58027
|
fill: "currentColor"
|
|
58080
|
-
})),
|
|
58028
|
+
})), cM = (t) => /* @__PURE__ */ e.createElement("svg", {
|
|
58081
58029
|
width: 18,
|
|
58082
58030
|
height: 18,
|
|
58083
58031
|
viewBox: "0 0 18 18",
|
|
@@ -58090,7 +58038,7 @@ var Vj = (e) => /* @__PURE__ */ M(me, { ...e }), Hj = {
|
|
|
58090
58038
|
strokeWidth: 1.5,
|
|
58091
58039
|
strokeLinecap: "round",
|
|
58092
58040
|
strokeLinejoin: "round"
|
|
58093
|
-
})),
|
|
58041
|
+
})), lM = (t) => /* @__PURE__ */ e.createElement("svg", {
|
|
58094
58042
|
width: 18,
|
|
58095
58043
|
height: 18,
|
|
58096
58044
|
viewBox: "0 0 18 18",
|
|
@@ -58103,7 +58051,7 @@ var Vj = (e) => /* @__PURE__ */ M(me, { ...e }), Hj = {
|
|
|
58103
58051
|
strokeWidth: 1.5,
|
|
58104
58052
|
strokeLinecap: "round",
|
|
58105
58053
|
strokeLinejoin: "round"
|
|
58106
|
-
})),
|
|
58054
|
+
})), uM = (t) => /* @__PURE__ */ e.createElement("svg", {
|
|
58107
58055
|
width: 18,
|
|
58108
58056
|
height: 18,
|
|
58109
58057
|
viewBox: "0 0 18 18",
|
|
@@ -58116,14 +58064,14 @@ var Vj = (e) => /* @__PURE__ */ M(me, { ...e }), Hj = {
|
|
|
58116
58064
|
strokeWidth: 1.5,
|
|
58117
58065
|
strokeLinecap: "round",
|
|
58118
58066
|
strokeLinejoin: "round"
|
|
58119
|
-
})),
|
|
58120
|
-
|
|
58121
|
-
|
|
58122
|
-
|
|
58123
|
-
|
|
58124
|
-
|
|
58125
|
-
],
|
|
58126
|
-
let v = a.length === 1, y = v ? a[0]?.name : "", b = u?.[
|
|
58067
|
+
})), dM = /* @__PURE__ */ ((e) => (e.MyFiles = "my_files", e.Shared = "shared", e.Organization = "organization", e.Review = "review", e))(dM || {}), $ = /* @__PURE__ */ ((e) => (e.AddSibling = "addSibling", e.AddChild = "addChild", e.Duplicate = "duplicate", e.Copy = "copy", e.Move = "move", e.Download = "download", e.Delete = "delete", e.Rename = "rename", e.Info = "info", e.Unshare = "unshare", e.RemoveAccess = "removeAccess", e.ManagePermissions = "managePermissions", e.Preview = "preview", e.OpenInNewTab = "openInNewTab", e))($ || {}), fM = /* @__PURE__ */ ((e) => (e.Replace = "replace", e.Duplicate = "duplicate", e.Cancel = "cancel", e))(fM || {}), pM = /* @__PURE__ */ ((e) => (e.ReplaceAll = "replaceAll", e.DuplicateAll = "duplicateAll", e.DecideForEach = "decideForEach", e))(pM || {}), mM = /* @__PURE__ */ ((e) => (e.Copy = "copy", e.Move = "move", e))(mM || {}), hM = /* @__PURE__ */ ((e) => (e.Tree = "tree", e.Grid = "grid", e))(hM || {}), gM = /* @__PURE__ */ ((e) => (e.Tree = "tree", e.Grid = "grid", e))(gM || {}), _M = /* @__PURE__ */ ((e) => (e.Folder = "folder", e.Child = "child", e.Sibling = "sibling", e))(_M || {}), vM = /* @__PURE__ */ ((e) => (e.Name = "name", e.UpdatedAt = "updatedAt", e.Size = "size", e.Author = "author", e.Owner = "owner", e.Path = "path", e.Actions = "__actions", e.Version = "version", e))(vM || {}), yM = "w-full h-full grid grid-rows-[auto_1fr] gap-5 p-6 overflow-hidden min-w-0 bg-layer-1", bM = "w-full text-secondary flex items-center gap-2", xM = "flex min-h-0 min-w-0 h-full gap-4 overflow-hidden", SM = "flex flex-col flex-1 min-h-0 min-w-0 h-full gap-4", CM = "h-full rounded bg-layer-raised text-secondary min-w-0", wM = "flex-1 w-full rounded text-secondary overflow-auto min-h-0 min-w-0", TM = "opacity-0 pointer-events-none group-hover/grid-row:opacity-100 group-hover/grid-row:pointer-events-auto", EM = 280, DM = "Files", OM = 20, kM = "Files", AM = ".dial_folder", jM = "New folder", MM = 280, NM = 460, PM = 44, FM = 800, IM = [
|
|
58068
|
+
vM.Name,
|
|
58069
|
+
vM.UpdatedAt,
|
|
58070
|
+
vM.Size,
|
|
58071
|
+
vM.Author,
|
|
58072
|
+
vM.Actions
|
|
58073
|
+
], LM = /* @__PURE__ */ ((e) => (e.ITEM = "item", e.FOLDER = "folder", e))(LM || {}), RM = /* @__PURE__ */ ((e) => (e.FILE = "FILE", e.PROMPT = "PROMPT", e.CONVERSATION = "CONVERSATION", e.APPLICATION = "APPLICATION", e.TOOLSET = "TOOL_SET", e))(RM || {}), zM = /* @__PURE__ */ ((e) => (e.READ = "READ", e.WRITE = "WRITE", e.SHARE = "SHARE", e))(zM || {}), BM = ({ open: e, onClose: t, onReplace: n, onDuplicate: r, onDecideForEach: i, conflictingFiles: a, singleFileTitle: s = "Replace Or Duplicate Item", multipleFilesTitle: c = "Replace Or Duplicate Items", message: l, actionLabels: u, strategyLabels: d, confirmLabel: p = "Confirm", cancelLabel: h = "Cancel", nameColumnLabel: g = "Name", actionColumnLabel: _ = "Action" }) => {
|
|
58074
|
+
let v = a.length === 1, y = v ? a[0]?.name : "", b = u?.[fM.Replace] ?? "Replace", x = u?.[fM.Duplicate] ?? "Duplicate", S = u?.[fM.Cancel] ?? "Cancel", C = d?.[pM.ReplaceAll] ?? "Replace all", w = d?.[pM.DuplicateAll] ?? "Duplicate all", E = d?.[pM.DecideForEach] ?? "Decide for each", [ee, D] = m(fM.Replace), [O, te] = m(pM.ReplaceAll), [k, ne] = m(new Map(a.map((e) => [e.path, fM.Replace]))), [re, ae] = m(void 0), oe = v ? s : c, se = /* @__PURE__ */ N(Ge, { children: [
|
|
58127
58075
|
"Item with the name ",
|
|
58128
58076
|
/* @__PURE__ */ N("span", {
|
|
58129
58077
|
className: "text-primary",
|
|
@@ -58136,17 +58084,17 @@ var Vj = (e) => /* @__PURE__ */ M(me, { ...e }), Hj = {
|
|
|
58136
58084
|
" ",
|
|
58137
58085
|
"already exists in this destination."
|
|
58138
58086
|
] }), le = `${a.length} items with the same names already exist in this destination.`, ue = l ?? (v ? se : le), de = f(() => [{
|
|
58139
|
-
id:
|
|
58087
|
+
id: fM.Replace,
|
|
58140
58088
|
name: b
|
|
58141
58089
|
}, {
|
|
58142
|
-
id:
|
|
58090
|
+
id: fM.Duplicate,
|
|
58143
58091
|
name: x
|
|
58144
58092
|
}], [b, x]), fe = f(() => a.map((e) => ({
|
|
58145
58093
|
id: e.path,
|
|
58146
58094
|
name: e.name,
|
|
58147
58095
|
path: e.path,
|
|
58148
|
-
nodeType: e.nodeType ??
|
|
58149
|
-
action: k.get(e.path) ||
|
|
58096
|
+
nodeType: e.nodeType ?? LM.ITEM,
|
|
58097
|
+
action: k.get(e.path) || fM.Replace
|
|
58150
58098
|
})), [a, k]), pe = f(() => [{
|
|
58151
58099
|
field: "name",
|
|
58152
58100
|
headerName: g,
|
|
@@ -58155,12 +58103,12 @@ var Vj = (e) => /* @__PURE__ */ M(me, { ...e }), Hj = {
|
|
|
58155
58103
|
floatingFilter: !1,
|
|
58156
58104
|
filter: !1,
|
|
58157
58105
|
resizable: !1,
|
|
58158
|
-
cellRenderer: (e) => e.data?.nodeType ===
|
|
58106
|
+
cellRenderer: (e) => e.data?.nodeType === LM.FOLDER ? /* @__PURE__ */ M(ie, {
|
|
58159
58107
|
name: e.data.name,
|
|
58160
|
-
iconSize:
|
|
58108
|
+
iconSize: OM
|
|
58161
58109
|
}) : /* @__PURE__ */ M(A, {
|
|
58162
58110
|
name: e.data.name,
|
|
58163
|
-
iconSize:
|
|
58111
|
+
iconSize: OM
|
|
58164
58112
|
})
|
|
58165
58113
|
}, {
|
|
58166
58114
|
field: "action",
|
|
@@ -58175,7 +58123,7 @@ var Vj = (e) => /* @__PURE__ */ M(me, { ...e }), Hj = {
|
|
|
58175
58123
|
if (!e.data) return null;
|
|
58176
58124
|
let t = [
|
|
58177
58125
|
{
|
|
58178
|
-
key:
|
|
58126
|
+
key: fM.Replace,
|
|
58179
58127
|
label: b,
|
|
58180
58128
|
icon: /* @__PURE__ */ M(Ze, {
|
|
58181
58129
|
size: 10,
|
|
@@ -58183,7 +58131,7 @@ var Vj = (e) => /* @__PURE__ */ M(me, { ...e }), Hj = {
|
|
|
58183
58131
|
})
|
|
58184
58132
|
},
|
|
58185
58133
|
{
|
|
58186
|
-
key:
|
|
58134
|
+
key: fM.Duplicate,
|
|
58187
58135
|
label: x,
|
|
58188
58136
|
icon: /* @__PURE__ */ M(Ze, {
|
|
58189
58137
|
size: 10,
|
|
@@ -58191,7 +58139,7 @@ var Vj = (e) => /* @__PURE__ */ M(me, { ...e }), Hj = {
|
|
|
58191
58139
|
})
|
|
58192
58140
|
},
|
|
58193
58141
|
{
|
|
58194
|
-
key:
|
|
58142
|
+
key: fM.Cancel,
|
|
58195
58143
|
label: S,
|
|
58196
58144
|
icon: /* @__PURE__ */ M(Ze, {
|
|
58197
58145
|
size: 10,
|
|
@@ -58201,8 +58149,8 @@ var Vj = (e) => /* @__PURE__ */ M(me, { ...e }), Hj = {
|
|
|
58201
58149
|
], n = t.find((t) => t.key === e.data.action), r = re === e.data.path;
|
|
58202
58150
|
return /* @__PURE__ */ M("div", {
|
|
58203
58151
|
className: "flex items-center h-full",
|
|
58204
|
-
children: /* @__PURE__ */ M(
|
|
58205
|
-
trigger: [
|
|
58152
|
+
children: /* @__PURE__ */ M(_e, {
|
|
58153
|
+
trigger: [ye.Click],
|
|
58206
58154
|
open: r,
|
|
58207
58155
|
items: t,
|
|
58208
58156
|
onItemClick: ({ key: t }) => {
|
|
@@ -58225,7 +58173,7 @@ var Vj = (e) => /* @__PURE__ */ M(me, { ...e }), Hj = {
|
|
|
58225
58173
|
children: [n?.icon, n?.label ?? b]
|
|
58226
58174
|
}), /* @__PURE__ */ M(Xe, {
|
|
58227
58175
|
size: T.SM,
|
|
58228
|
-
className: (0,
|
|
58176
|
+
className: (0, iM.default)("text-secondary transition-transform", r && "rotate-180")
|
|
58229
58177
|
})]
|
|
58230
58178
|
})
|
|
58231
58179
|
})
|
|
@@ -58240,17 +58188,17 @@ var Vj = (e) => /* @__PURE__ */ M(me, { ...e }), Hj = {
|
|
|
58240
58188
|
re
|
|
58241
58189
|
]), me = f(() => [
|
|
58242
58190
|
{
|
|
58243
|
-
id:
|
|
58191
|
+
id: pM.ReplaceAll,
|
|
58244
58192
|
name: C
|
|
58245
58193
|
},
|
|
58246
58194
|
{
|
|
58247
|
-
id:
|
|
58195
|
+
id: pM.DuplicateAll,
|
|
58248
58196
|
name: w
|
|
58249
58197
|
},
|
|
58250
58198
|
{
|
|
58251
|
-
id:
|
|
58199
|
+
id: pM.DecideForEach,
|
|
58252
58200
|
name: E,
|
|
58253
|
-
content: O ===
|
|
58201
|
+
content: O === pM.DecideForEach ? /* @__PURE__ */ M("div", {
|
|
58254
58202
|
className: "mt-4",
|
|
58255
58203
|
children: /* @__PURE__ */ M(j, {
|
|
58256
58204
|
columnDefs: pe,
|
|
@@ -58270,13 +58218,13 @@ var Vj = (e) => /* @__PURE__ */ M(me, { ...e }), Hj = {
|
|
|
58270
58218
|
pe,
|
|
58271
58219
|
fe
|
|
58272
58220
|
]), he = o(() => {
|
|
58273
|
-
D(
|
|
58221
|
+
D(fM.Replace), te(pM.ReplaceAll), ne(new Map(a.map((e) => [e.path, fM.Replace])));
|
|
58274
58222
|
}, [a]), ge = o(() => {
|
|
58275
58223
|
he(), t();
|
|
58276
|
-
}, [he, t]),
|
|
58277
|
-
he(), v ? ee ===
|
|
58224
|
+
}, [he, t]), ve = o(() => {
|
|
58225
|
+
he(), v ? ee === fM.Replace ? n() : r() : O === pM.ReplaceAll ? n() : O === pM.DuplicateAll ? r() : O === pM.DecideForEach && i && i(a.map((e) => ({
|
|
58278
58226
|
file: e,
|
|
58279
|
-
action: k.get(e.path) ||
|
|
58227
|
+
action: k.get(e.path) || fM.Replace
|
|
58280
58228
|
})));
|
|
58281
58229
|
}, [
|
|
58282
58230
|
he,
|
|
@@ -58289,20 +58237,20 @@ var Vj = (e) => /* @__PURE__ */ M(me, { ...e }), Hj = {
|
|
|
58289
58237
|
a,
|
|
58290
58238
|
k
|
|
58291
58239
|
]);
|
|
58292
|
-
return /* @__PURE__ */ M(
|
|
58240
|
+
return /* @__PURE__ */ M(Ae, {
|
|
58293
58241
|
open: e,
|
|
58294
58242
|
onClose: ge,
|
|
58295
|
-
size: v ?
|
|
58296
|
-
className: (0,
|
|
58243
|
+
size: v ? je.Sm : je.Md,
|
|
58244
|
+
className: (0, iM.default)([!v && "w-[600px]"]),
|
|
58297
58245
|
header: oe,
|
|
58298
58246
|
preventKeyboardOnOpen: !0,
|
|
58299
58247
|
footer: /* @__PURE__ */ N("div", {
|
|
58300
58248
|
className: "flex justify-end gap-3 py-4 px-6 border-t border-tertiary",
|
|
58301
|
-
children: [/* @__PURE__ */ M(
|
|
58249
|
+
children: [/* @__PURE__ */ M(Ee, {
|
|
58302
58250
|
onClick: ge,
|
|
58303
58251
|
label: h
|
|
58304
|
-
}), /* @__PURE__ */ M(
|
|
58305
|
-
onClick:
|
|
58252
|
+
}), /* @__PURE__ */ M(Me, {
|
|
58253
|
+
onClick: ve,
|
|
58306
58254
|
label: p
|
|
58307
58255
|
})]
|
|
58308
58256
|
}),
|
|
@@ -58315,19 +58263,19 @@ var Vj = (e) => /* @__PURE__ */ M(me, { ...e }), Hj = {
|
|
|
58315
58263
|
elementId: "single-file-conflict",
|
|
58316
58264
|
radioButtons: de,
|
|
58317
58265
|
activeRadioButton: ee,
|
|
58318
|
-
orientation:
|
|
58266
|
+
orientation: Ne.Column,
|
|
58319
58267
|
onChange: (e) => D(e)
|
|
58320
58268
|
}) : /* @__PURE__ */ M(ce, {
|
|
58321
58269
|
elementId: "multiple-files-conflict",
|
|
58322
58270
|
radioButtons: me,
|
|
58323
58271
|
activeRadioButton: O,
|
|
58324
|
-
orientation:
|
|
58272
|
+
orientation: Ne.Column,
|
|
58325
58273
|
onChange: (e) => te(e),
|
|
58326
58274
|
formItemChildrenClassName: "gap-3"
|
|
58327
58275
|
})]
|
|
58328
58276
|
})
|
|
58329
58277
|
});
|
|
58330
|
-
},
|
|
58278
|
+
}, VM = ({ getContextMenuItems: e, isRowDisabled: t, allowedFileTypes: n, maxSelectableFileSize: r, buttonClassName: i }) => {
|
|
58331
58279
|
let a = p(e);
|
|
58332
58280
|
c(() => {
|
|
58333
58281
|
a.current = e;
|
|
@@ -58335,7 +58283,7 @@ var Vj = (e) => /* @__PURE__ */ M(me, { ...e }), Hj = {
|
|
|
58335
58283
|
let s = o((e) => {
|
|
58336
58284
|
if (!e.data || t(e.data, n, r)) return null;
|
|
58337
58285
|
let o = e.data ? a.current?.(e.data) ?? [] : [];
|
|
58338
|
-
return o.length ? /* @__PURE__ */ M(
|
|
58286
|
+
return o.length ? /* @__PURE__ */ M(_e, {
|
|
58339
58287
|
placement: "bottom-start",
|
|
58340
58288
|
allowedPlacements: [
|
|
58341
58289
|
"top-start",
|
|
@@ -58344,7 +58292,7 @@ var Vj = (e) => /* @__PURE__ */ M(me, { ...e }), Hj = {
|
|
|
58344
58292
|
],
|
|
58345
58293
|
items: o,
|
|
58346
58294
|
className: Ue("sticky right-0", i),
|
|
58347
|
-
children: /* @__PURE__ */ M(
|
|
58295
|
+
children: /* @__PURE__ */ M(Ce, { icon: /* @__PURE__ */ M(et, { ...h }) })
|
|
58348
58296
|
}) : null;
|
|
58349
58297
|
}, [
|
|
58350
58298
|
n,
|
|
@@ -58365,19 +58313,19 @@ var Vj = (e) => /* @__PURE__ */ M(me, { ...e }), Hj = {
|
|
|
58365
58313
|
floatingFilter: !1,
|
|
58366
58314
|
cellRenderer: s
|
|
58367
58315
|
}), [s]) };
|
|
58368
|
-
},
|
|
58369
|
-
let [t, n] = m(
|
|
58316
|
+
}, HM = ({ onRename: e }) => {
|
|
58317
|
+
let [t, n] = m(hM.Grid);
|
|
58370
58318
|
return {
|
|
58371
58319
|
renameTriggerView: t,
|
|
58372
58320
|
onGridRename: o((t) => {
|
|
58373
|
-
e(t), n(
|
|
58321
|
+
e(t), n(hM.Grid);
|
|
58374
58322
|
}, [e]),
|
|
58375
58323
|
onTreeRename: o((t) => {
|
|
58376
|
-
e(t), n(
|
|
58324
|
+
e(t), n(hM.Tree);
|
|
58377
58325
|
}, [e])
|
|
58378
58326
|
};
|
|
58379
58327
|
};
|
|
58380
|
-
function
|
|
58328
|
+
function UM(e, t) {
|
|
58381
58329
|
let n = p(null), [r, i] = m(!1);
|
|
58382
58330
|
return c(() => {
|
|
58383
58331
|
if (!n.current) return;
|
|
@@ -58391,31 +58339,31 @@ function qM(e, t) {
|
|
|
58391
58339
|
isBelowBreakpoint: r
|
|
58392
58340
|
};
|
|
58393
58341
|
}
|
|
58394
|
-
var
|
|
58342
|
+
var WM = (e, t) => {
|
|
58395
58343
|
if (!(!e || !e.length || !t)) for (let n of e) {
|
|
58396
58344
|
if (n.path === t) return n;
|
|
58397
|
-
let e =
|
|
58345
|
+
let e = WM(n.items, t);
|
|
58398
58346
|
if (e) return e;
|
|
58399
58347
|
}
|
|
58400
|
-
},
|
|
58348
|
+
}, GM = (e, t) => {
|
|
58401
58349
|
if (!e?.length) return;
|
|
58402
58350
|
if (!t) return e[0];
|
|
58403
|
-
let n =
|
|
58404
|
-
if (n && n.nodeType ===
|
|
58351
|
+
let n = WM(e, t);
|
|
58352
|
+
if (n && n.nodeType === LM.FOLDER) return n;
|
|
58405
58353
|
let r = t.split("/").filter(Boolean);
|
|
58406
|
-
return r.length <= 1 ? e[0] :
|
|
58407
|
-
},
|
|
58354
|
+
return r.length <= 1 ? e[0] : WM(e, "/" + r.slice(0, r.length - 1).join("/")) ?? e[0];
|
|
58355
|
+
}, KM = (e) => (e ?? "").toLowerCase(), qM = (e) => KM(e).replace(/^\./, ""), JM = (e) => {
|
|
58408
58356
|
if (!e) return [];
|
|
58409
58357
|
let t = [], n = (e) => {
|
|
58410
58358
|
let r = e.items ?? [];
|
|
58411
|
-
for (let e of r) t.push(e), e.nodeType ===
|
|
58359
|
+
for (let e of r) t.push(e), e.nodeType === LM.FOLDER && n(e);
|
|
58412
58360
|
};
|
|
58413
58361
|
return n(e), t;
|
|
58414
|
-
},
|
|
58362
|
+
}, YM = (e) => (e.name ?? e.path.split("/").pop() ?? "").startsWith("."), XM = (e) => {
|
|
58415
58363
|
if (!e) return "0 bytes";
|
|
58416
58364
|
let t = 1024, n = t * 1024;
|
|
58417
58365
|
return e >= n ? `${(e / n).toFixed(1)} MB` : e >= t ? `${(e / t).toFixed(0)} KB` : `${e} bytes`;
|
|
58418
|
-
},
|
|
58366
|
+
}, ZM = (e, t = "en-US", n = {
|
|
58419
58367
|
year: "numeric",
|
|
58420
58368
|
month: "short",
|
|
58421
58369
|
day: "2-digit"
|
|
@@ -58427,7 +58375,7 @@ var JM = (e, t) => {
|
|
|
58427
58375
|
return e;
|
|
58428
58376
|
}
|
|
58429
58377
|
};
|
|
58430
|
-
function
|
|
58378
|
+
function QM(e, t, n) {
|
|
58431
58379
|
if (!e || e.includes("*/*")) return !0;
|
|
58432
58380
|
let r = t.toLowerCase(), i = n && n.includes(".") ? `.${n.split(".").at(-1).toLowerCase()}` : void 0;
|
|
58433
58381
|
return e.some((e) => {
|
|
@@ -58440,21 +58388,21 @@ function nN(e, t, n) {
|
|
|
58440
58388
|
return r === t;
|
|
58441
58389
|
});
|
|
58442
58390
|
}
|
|
58443
|
-
var
|
|
58391
|
+
var $M = (e) => e?.map((e) => e.endsWith("/*") ? e.replace("/*", "s") : eN(e).flat().map((e) => `.${e}`)).flat().join(", ") || "", eN = (e) => {
|
|
58444
58392
|
let [t, n] = e.split("/");
|
|
58445
|
-
return t === "*" ? ["all"] : n === "*" ? Object.entries(
|
|
58393
|
+
return t === "*" ? ["all"] : n === "*" ? Object.entries(aM.extensions).reduce((e, [n, r]) => {
|
|
58446
58394
|
let [i] = n.split("/");
|
|
58447
58395
|
return i === t && e.push(...r), e;
|
|
58448
|
-
}, []) :
|
|
58449
|
-
},
|
|
58396
|
+
}, []) : aM.extensions[e] || [];
|
|
58397
|
+
}, tN = (e) => {
|
|
58450
58398
|
if (!e) return;
|
|
58451
58399
|
let t = e.flags.replace(/[gy]/g, "");
|
|
58452
58400
|
return new RegExp(e.source, t);
|
|
58453
58401
|
};
|
|
58454
|
-
function
|
|
58455
|
-
if (t &&
|
|
58402
|
+
function nN(e, t, n) {
|
|
58403
|
+
if (t && tN(t)?.test(e.name)) return n ?? `This ${e.isFolder ? "folder" : "file"} contains forbidden characters in its name. Please rename it.`;
|
|
58456
58404
|
}
|
|
58457
|
-
var
|
|
58405
|
+
var rN = (e) => {
|
|
58458
58406
|
let t = e.lastIndexOf("/");
|
|
58459
58407
|
return t >= 0 ? {
|
|
58460
58408
|
parent: e.slice(0, t),
|
|
@@ -58463,22 +58411,22 @@ var sN = (e) => {
|
|
|
58463
58411
|
parent: "",
|
|
58464
58412
|
name: e
|
|
58465
58413
|
};
|
|
58466
|
-
},
|
|
58467
|
-
let r = !e.contentLength || n == null || e.contentLength <= n, i = !e.contentType ||
|
|
58414
|
+
}, iN = (e, t, n) => {
|
|
58415
|
+
let r = !e.contentLength || n == null || e.contentLength <= n, i = !e.contentType || QM(t, e.contentType, e.name);
|
|
58468
58416
|
return r && i;
|
|
58469
|
-
},
|
|
58470
|
-
if (e.nodeType ===
|
|
58417
|
+
}, aN = (e, t, n, r, i) => {
|
|
58418
|
+
if (e.nodeType === LM.FOLDER) return;
|
|
58471
58419
|
let a = !e.contentLength || n == null || e.contentLength <= n;
|
|
58472
|
-
if (!(!e.contentType ||
|
|
58473
|
-
if (!a) return i ?? `File is too large. Maximum size: ${
|
|
58474
|
-
},
|
|
58475
|
-
let t = `${
|
|
58420
|
+
if (!(!e.contentType || QM(t, e.contentType, e.name))) return r ?? (t?.length ? `Unsupported file type. Supported types: ${$M(t)}.` : "Unsupported file type.");
|
|
58421
|
+
if (!a) return i ?? `File is too large. Maximum size: ${XM(n)}.`;
|
|
58422
|
+
}, oN = (e) => e.replace(/\/+$/, "").split("/").filter(Boolean).length, sN = (e) => {
|
|
58423
|
+
let t = `${jM} `, n = RegExp(`^${jM} (\\d+)$`), r = new Set(e.map((e) => e.name.toLowerCase())), i = e.map((e) => {
|
|
58476
58424
|
let t = e.name.match(n);
|
|
58477
58425
|
return t ? parseInt(t[1], 10) : 0;
|
|
58478
58426
|
}).reduce((e, t) => Math.max(e, t), 0), a = `${t}${i + 1}`, o = i + 1;
|
|
58479
58427
|
for (; r.has(a.toLowerCase());) o++, a = `${t}${o}`;
|
|
58480
58428
|
return a;
|
|
58481
|
-
},
|
|
58429
|
+
}, cN = (e) => {
|
|
58482
58430
|
let [t, n] = m(e?.showHiddenFiles ?? !1), r = !!e?.onShowHiddenFilesChange, i = r ? e.showHiddenFiles ?? !1 : t, a = o((t) => {
|
|
58483
58431
|
r ? e?.onShowHiddenFilesChange?.(t) : n(t);
|
|
58484
58432
|
}, [r, e]);
|
|
@@ -58494,7 +58442,7 @@ var sN = (e) => {
|
|
|
58494
58442
|
]),
|
|
58495
58443
|
setAreHiddenFilesVisible: a
|
|
58496
58444
|
};
|
|
58497
|
-
},
|
|
58445
|
+
}, lN = (e) => {
|
|
58498
58446
|
let [t, n] = m(e?.collapsed ?? !1), r = !!e?.onCollapseChange, i = r ? e.collapsed ?? !1 : t, a = o((t) => {
|
|
58499
58447
|
r ? e?.onCollapseChange?.(t) : n(t);
|
|
58500
58448
|
}, [r, e]);
|
|
@@ -58510,9 +58458,9 @@ var sN = (e) => {
|
|
|
58510
58458
|
]),
|
|
58511
58459
|
setIsTreeCollapsed: a
|
|
58512
58460
|
};
|
|
58513
|
-
},
|
|
58461
|
+
}, uN = (e, t, n) => {
|
|
58514
58462
|
if (!t.has(e)) return e;
|
|
58515
|
-
let r = n ===
|
|
58463
|
+
let r = n === LM.FOLDER ? (e, t) => `${e} (${t})` : (e, t) => {
|
|
58516
58464
|
let n = e.lastIndexOf("."), r = n > 0;
|
|
58517
58465
|
return `${r ? e.slice(0, n) : e} (${t})${r ? e.slice(n) : ""}`;
|
|
58518
58466
|
};
|
|
@@ -58520,38 +58468,38 @@ var sN = (e) => {
|
|
|
58520
58468
|
let i = r(e, n);
|
|
58521
58469
|
if (!t.has(i)) return i;
|
|
58522
58470
|
}
|
|
58523
|
-
},
|
|
58471
|
+
}, dN = (e) => e.name, fN = ({ getDestinationFiles: e, onResolve: t }) => {
|
|
58524
58472
|
let [n, r] = m([]), [i, a] = m(!1), [s, c] = m(null), l = p(!1), u = o((e) => {
|
|
58525
58473
|
l.current = !0, r(e), a(!0);
|
|
58526
58474
|
}, []), d = o(() => {
|
|
58527
58475
|
l.current = !1, a(!1), r([]), c(null);
|
|
58528
58476
|
}, []), f = o((t, n) => {
|
|
58529
|
-
let r = e(t), i = new Set(r.map(
|
|
58477
|
+
let r = e(t), i = new Set(r.map(dN)), a = n.filter((e) => i.has(e.name));
|
|
58530
58478
|
return {
|
|
58531
58479
|
hasConflicts: a.length > 0,
|
|
58532
58480
|
conflicts: a
|
|
58533
58481
|
};
|
|
58534
58482
|
}, [e]), h = o((t, n, r, i) => {
|
|
58535
|
-
let a = e(t), o = new Set(a.map(
|
|
58483
|
+
let a = e(t), o = new Set(a.map(dN));
|
|
58536
58484
|
return n.map((e) => {
|
|
58537
|
-
let n = e.name, a = o.has(n), s = r && a ? n :
|
|
58485
|
+
let n = e.name, a = o.has(n), s = r && a ? n : uN(n, o, e.nodeType);
|
|
58538
58486
|
return (!r || !a) && o.add(s), {
|
|
58539
58487
|
sourceUrl: e.path,
|
|
58540
58488
|
destinationUrl: `${t}/${s}`,
|
|
58541
58489
|
overwrite: r && a,
|
|
58542
|
-
nodeType: e.nodeType ??
|
|
58490
|
+
nodeType: e.nodeType ?? LM.ITEM,
|
|
58543
58491
|
...i ?? {}
|
|
58544
58492
|
};
|
|
58545
58493
|
});
|
|
58546
58494
|
}, [e]), g = o((t, n, r, i) => {
|
|
58547
|
-
let a = e(t), o = new Set(a.map(
|
|
58548
|
-
return n.filter((e) => r.get(e.path) !==
|
|
58549
|
-
let n = r.get(e.path), a = o.has(e.name), s = n ===
|
|
58495
|
+
let a = e(t), o = new Set(a.map(dN));
|
|
58496
|
+
return n.filter((e) => r.get(e.path) !== fM.Cancel).map((e) => {
|
|
58497
|
+
let n = r.get(e.path), a = o.has(e.name), s = n === fM.Replace && a, c = s ? e.name : uN(e.name, o, e.nodeType);
|
|
58550
58498
|
return s || o.add(c), {
|
|
58551
58499
|
sourceUrl: e.path,
|
|
58552
58500
|
destinationUrl: `${t}/${c}`,
|
|
58553
58501
|
overwrite: s,
|
|
58554
|
-
nodeType: e.nodeType ??
|
|
58502
|
+
nodeType: e.nodeType ?? LM.ITEM,
|
|
58555
58503
|
...i ?? {}
|
|
58556
58504
|
};
|
|
58557
58505
|
});
|
|
@@ -58595,7 +58543,7 @@ var sN = (e) => {
|
|
|
58595
58543
|
]),
|
|
58596
58544
|
handleCancelAll: o(() => {
|
|
58597
58545
|
if (!s) return;
|
|
58598
|
-
let { files: e, destinationFolder: r, metadata: i } = s, a = g(r, e, new Map(n.map((e) => [e.path,
|
|
58546
|
+
let { files: e, destinationFolder: r, metadata: i } = s, a = g(r, e, new Map(n.map((e) => [e.path, fM.Cancel])), i);
|
|
58599
58547
|
t?.(a, r), d();
|
|
58600
58548
|
}, [
|
|
58601
58549
|
d,
|
|
@@ -58615,17 +58563,17 @@ var sN = (e) => {
|
|
|
58615
58563
|
d
|
|
58616
58564
|
])
|
|
58617
58565
|
};
|
|
58618
|
-
},
|
|
58619
|
-
let [l, u] = m(!1), [d, f] = m([]), [p, h] = m([]), [g, _] = m(
|
|
58566
|
+
}, pN = ({ getDestinationFiles: e, onCopyFiles: t, onMoveToFiles: n, onCopySuccess: r, onMoveSuccess: i, onDuplicateSuccess: a, getCopyHeader: s, getMoveHeader: c }) => {
|
|
58567
|
+
let [l, u] = m(!1), [d, f] = m([]), [p, h] = m([]), [g, _] = m(mM.Copy), [v, y] = m(), [b, x] = m(null), { conflictingFiles: S, conflictResolutionOpen: C, hasActiveConflictRef: w, startConflictResolution: T, resolveConflictsWithStrategy: E, closeConflictResolution: ee, openConflictResolution: D, handleReplaceAll: O, handleDuplicateAll: te, handleCancelAll: k, handleDecideForEach: ne } = fN({
|
|
58620
58568
|
getDestinationFiles: e,
|
|
58621
58569
|
onResolve: (e, a) => {
|
|
58622
|
-
e?.length && (b?.type ===
|
|
58570
|
+
e?.length && (b?.type === mM.Copy ? (t?.(e, a), r?.()) : b?.type === mM.Move && b.sourceFolder && (n?.(e, b.sourceFolder, a), i?.()));
|
|
58623
58571
|
}
|
|
58624
58572
|
}), A = o(() => {
|
|
58625
58573
|
f([]), h([]), x(null), y(void 0);
|
|
58626
58574
|
}, []), re = o((e) => {
|
|
58627
|
-
let n = T(e, d, { type:
|
|
58628
|
-
if (x({ type:
|
|
58575
|
+
let n = T(e, d, { type: mM.Copy });
|
|
58576
|
+
if (x({ type: mM.Copy }), !n.hasConflicts) {
|
|
58629
58577
|
let n = E(e, d, !1);
|
|
58630
58578
|
t?.(n, e), r?.(), A();
|
|
58631
58579
|
}
|
|
@@ -58639,7 +58587,7 @@ var sN = (e) => {
|
|
|
58639
58587
|
]), ie = o((e, t) => {
|
|
58640
58588
|
let r = t || (b?.sourceFolder ?? "/");
|
|
58641
58589
|
if (!T(e, p, {
|
|
58642
|
-
type:
|
|
58590
|
+
type: mM.Move,
|
|
58643
58591
|
sourceFolderPath: r
|
|
58644
58592
|
}).hasConflicts) {
|
|
58645
58593
|
let t = E(e, p, !0);
|
|
@@ -58689,7 +58637,7 @@ var sN = (e) => {
|
|
|
58689
58637
|
h(e);
|
|
58690
58638
|
let t = e[0]?.parentPath ?? e[0]?.folderId;
|
|
58691
58639
|
y(t), x({
|
|
58692
|
-
type:
|
|
58640
|
+
type: mM.Move,
|
|
58693
58641
|
sourceFolder: t
|
|
58694
58642
|
}), c && e.length > 0 ? fe(c(e.length, e[0]?.name)) : fe(void 0);
|
|
58695
58643
|
}, [c]),
|
|
@@ -58704,7 +58652,7 @@ var sN = (e) => {
|
|
|
58704
58652
|
handleConflictDecideForEach: se,
|
|
58705
58653
|
sourceFolder: v
|
|
58706
58654
|
};
|
|
58707
|
-
},
|
|
58655
|
+
}, mN = ({ path: e, defaultPath: t, onPathChange: n, onSelectionClear: r }) => {
|
|
58708
58656
|
let i = e !== void 0, [a, s] = m(t), c = i ? e : a, l = o((e) => {
|
|
58709
58657
|
i || s(e), n?.(e);
|
|
58710
58658
|
}, [i, n]);
|
|
@@ -58715,7 +58663,7 @@ var sN = (e) => {
|
|
|
58715
58663
|
l(e), r?.();
|
|
58716
58664
|
}, [l, r])
|
|
58717
58665
|
};
|
|
58718
|
-
},
|
|
58666
|
+
}, hN = ({ onDeleteFiles: e, onDeleteSuccess: t }) => {
|
|
58719
58667
|
let [n, r] = m(!1), [i, a] = m([]), [s, c] = m(""), l = o((e, t) => {
|
|
58720
58668
|
a(e), c(t), r(!0);
|
|
58721
58669
|
}, []), u = o(() => {
|
|
@@ -58739,16 +58687,16 @@ var sN = (e) => {
|
|
|
58739
58687
|
s
|
|
58740
58688
|
])
|
|
58741
58689
|
};
|
|
58742
|
-
},
|
|
58690
|
+
}, gN = ({ onDownloadFiles: e, customDownloadItemsAction: t, onDownloadSuccess: n }) => ({ handleDownloadFiles: o((r) => {
|
|
58743
58691
|
t && r.length > 0 ? t(r) : e && r.length > 0 && (e(r), n?.());
|
|
58744
58692
|
}, [
|
|
58745
58693
|
e,
|
|
58746
58694
|
n,
|
|
58747
58695
|
t
|
|
58748
|
-
]) }),
|
|
58749
|
-
let [d, h] = m(!1), [g, _] = m(!1), [v, y] = m(), b = p(null), x = p(""), S = p([]), C = f(() => !!u?.permissions?.includes(
|
|
58696
|
+
]) }), _N = (e) => "dataTransfer" in e && e.dataTransfer !== null, vN = ({ onUploadFiles: e, onValidateUpload: t, maxFileSize: n, allowedFileTypes: r, validationMessages: i = {}, onUploadArchive: a, prepareUploadFileName: s, uploadEnabled: l = !0, currentFolder: u } = {}) => {
|
|
58697
|
+
let [d, h] = m(!1), [g, _] = m(!1), [v, y] = m(), b = p(null), x = p(""), S = p([]), C = f(() => !!u?.permissions?.includes(zM.WRITE), [u]), [w, T] = m(/* @__PURE__ */ new Map()), [E, ee] = m(null), D = o((e) => !r || r.includes("*/*") ? e : e.filter(({ fileContent: e, name: t }) => QM(r, e.type, t)), [r]), O = o(() => {
|
|
58750
58698
|
T(/* @__PURE__ */ new Map()), ee(null);
|
|
58751
|
-
}, []), { conflictingFiles: te, conflictResolutionOpen: k, hasActiveConflictRef: ne, startConflictResolution: A, closeConflictResolution: re, openConflictResolution: ie, handleReplaceAll: j, handleDuplicateAll: ae, handleCancelAll: oe, handleDecideForEach: se } =
|
|
58699
|
+
}, []), { conflictingFiles: te, conflictResolutionOpen: k, hasActiveConflictRef: ne, startConflictResolution: A, closeConflictResolution: re, openConflictResolution: ie, handleReplaceAll: j, handleDuplicateAll: ae, handleCancelAll: oe, handleDecideForEach: se } = fN({
|
|
58752
58700
|
getDestinationFiles: () => S.current,
|
|
58753
58701
|
onResolve: (t, n) => {
|
|
58754
58702
|
if (!l || !C) {
|
|
@@ -58782,7 +58730,7 @@ var sN = (e) => {
|
|
|
58782
58730
|
]), c(() => {
|
|
58783
58731
|
if (!l || !C) return;
|
|
58784
58732
|
let e = 0, t = (t) => {
|
|
58785
|
-
|
|
58733
|
+
_N(t) && t.dataTransfer.types.includes(kM) && (e++, _(!0));
|
|
58786
58734
|
}, n = () => {
|
|
58787
58735
|
e--, e === 0 && _(!1);
|
|
58788
58736
|
}, r = () => {
|
|
@@ -58799,7 +58747,7 @@ var sN = (e) => {
|
|
|
58799
58747
|
name: e.name,
|
|
58800
58748
|
folderId: t,
|
|
58801
58749
|
path: e.name,
|
|
58802
|
-
nodeType:
|
|
58750
|
+
nodeType: LM.ITEM,
|
|
58803
58751
|
parentPath: t,
|
|
58804
58752
|
contentLength: e.fileContent.size
|
|
58805
58753
|
})), []), ue = o(async (r, a, o) => {
|
|
@@ -58947,7 +58895,7 @@ var sN = (e) => {
|
|
|
58947
58895
|
name: o,
|
|
58948
58896
|
folderId: e,
|
|
58949
58897
|
path: `${e}/${o}`,
|
|
58950
|
-
nodeType:
|
|
58898
|
+
nodeType: LM.FOLDER,
|
|
58951
58899
|
parentPath: e,
|
|
58952
58900
|
contentLength: r.size,
|
|
58953
58901
|
contentType: r.type
|
|
@@ -58997,35 +58945,35 @@ var sN = (e) => {
|
|
|
58997
58945
|
handleUploadConflictCancel: pe,
|
|
58998
58946
|
handleUploadConflictDecideForEach: me
|
|
58999
58947
|
};
|
|
59000
|
-
},
|
|
58948
|
+
}, yN = n(void 0), bN = { hiddenItemWarning: `${ke.Warning}__A dot at the start of the name will make the item hidden` }, xN = { consecutiveDotsError: "Name cannot contain consecutive dots" }, SN = {
|
|
59001
58949
|
emptyName: "Name cannot be empty",
|
|
59002
58950
|
duplicateName: "An item with this name already exists",
|
|
59003
|
-
hiddenItemWarning:
|
|
59004
|
-
consecutiveDotsError:
|
|
58951
|
+
hiddenItemWarning: bN.hiddenItemWarning,
|
|
58952
|
+
consecutiveDotsError: xN.consecutiveDotsError
|
|
59005
58953
|
};
|
|
59006
|
-
function
|
|
58954
|
+
function CN(e) {
|
|
59007
58955
|
let t = e.length;
|
|
59008
58956
|
for (; t > 0 && e[t - 1] === "/";) t--;
|
|
59009
58957
|
return e.slice(0, t);
|
|
59010
58958
|
}
|
|
59011
|
-
function
|
|
59012
|
-
let n =
|
|
58959
|
+
function wN(e, t) {
|
|
58960
|
+
let n = CN(e), r = n.lastIndexOf("/");
|
|
59013
58961
|
return r === -1 ? t : n.slice(0, r + 1) + t;
|
|
59014
58962
|
}
|
|
59015
|
-
function
|
|
58963
|
+
function TN(e) {
|
|
59016
58964
|
let t = e.lastIndexOf(".");
|
|
59017
58965
|
return t === -1 || t === 0 ? e : e.substring(0, t);
|
|
59018
58966
|
}
|
|
59019
|
-
function
|
|
58967
|
+
function EN(e) {
|
|
59020
58968
|
let t = e.lastIndexOf(".");
|
|
59021
58969
|
return t === -1 || t === 0 ? "" : e.substring(t);
|
|
59022
58970
|
}
|
|
59023
|
-
var
|
|
58971
|
+
var DN = ({ items: e, onRenameValidate: t, validationMessages: n, onMoveToFiles: r }) => {
|
|
59024
58972
|
let [i, a] = m(), s = f(() => ({
|
|
59025
|
-
...
|
|
58973
|
+
...SN,
|
|
59026
58974
|
...n
|
|
59027
58975
|
}), [n]), c = f(() => i?.path, [i]), l = o((t) => {
|
|
59028
|
-
let n =
|
|
58976
|
+
let n = WM(e, t);
|
|
59029
58977
|
n && a(n);
|
|
59030
58978
|
}, [e]), u = o(() => {
|
|
59031
58979
|
a(void 0);
|
|
@@ -59039,16 +58987,16 @@ var jN = ({ items: e, onRenameValidate: t, validationMessages: n, onMoveToFiles:
|
|
|
59039
58987
|
a(void 0);
|
|
59040
58988
|
return;
|
|
59041
58989
|
}
|
|
59042
|
-
let t = i.nodeType ===
|
|
58990
|
+
let t = i.nodeType === LM.ITEM, n = e.trim();
|
|
59043
58991
|
if (t) {
|
|
59044
|
-
let e =
|
|
58992
|
+
let e = EN(i.name);
|
|
59045
58993
|
e && !n.endsWith(e) && (n += e);
|
|
59046
58994
|
}
|
|
59047
58995
|
if (n === i.name) {
|
|
59048
58996
|
a(void 0);
|
|
59049
58997
|
return;
|
|
59050
58998
|
}
|
|
59051
|
-
let o =
|
|
58999
|
+
let o = wN(i.path, n), s = i.parentPath;
|
|
59052
59000
|
if (!s) {
|
|
59053
59001
|
a(void 0);
|
|
59054
59002
|
return;
|
|
@@ -59065,14 +59013,14 @@ var jN = ({ items: e, onRenameValidate: t, validationMessages: n, onMoveToFiles:
|
|
|
59065
59013
|
if (!i) return s.emptyName;
|
|
59066
59014
|
if (i.includes("..")) return s.consecutiveDotsError;
|
|
59067
59015
|
if (i.startsWith(".")) return s.hiddenItemWarning;
|
|
59068
|
-
let a = r.nodeType ===
|
|
59016
|
+
let a = r.nodeType === LM.ITEM, o = i;
|
|
59069
59017
|
if (a) {
|
|
59070
|
-
let e =
|
|
59018
|
+
let e = EN(r.name);
|
|
59071
59019
|
e && !o.endsWith(e) && (o += e);
|
|
59072
59020
|
}
|
|
59073
59021
|
let c = r.parentPath;
|
|
59074
59022
|
if (c) {
|
|
59075
|
-
let t =
|
|
59023
|
+
let t = WM(e, c);
|
|
59076
59024
|
if (t && new Set((t.items ?? []).filter((e) => e.path !== r.path).map((e) => e.name.toLowerCase())).has(o.toLowerCase())) return s.duplicateName;
|
|
59077
59025
|
}
|
|
59078
59026
|
if (t) {
|
|
@@ -59085,9 +59033,9 @@ var jN = ({ items: e, onRenameValidate: t, validationMessages: n, onMoveToFiles:
|
|
|
59085
59033
|
s,
|
|
59086
59034
|
e
|
|
59087
59035
|
]),
|
|
59088
|
-
getDisplayName: o((e) => e.nodeType ===
|
|
59036
|
+
getDisplayName: o((e) => e.nodeType === LM.ITEM ? TN(e.name) : e.name, [])
|
|
59089
59037
|
};
|
|
59090
|
-
},
|
|
59038
|
+
}, ON = (e) => {
|
|
59091
59039
|
let [t, n] = m(e?.expandedPaths ?? /* @__PURE__ */ new Set()), r = f(() => !!e?.onExpandedPathsChange, [e?.onExpandedPathsChange]), i = f(() => r ? e?.expandedPaths ?? /* @__PURE__ */ new Set() : t, [
|
|
59092
59040
|
r,
|
|
59093
59041
|
e?.expandedPaths,
|
|
@@ -59119,7 +59067,7 @@ var jN = ({ items: e, onRenameValidate: t, validationMessages: n, onMoveToFiles:
|
|
|
59119
59067
|
}, [i, a]),
|
|
59120
59068
|
isControlled: r
|
|
59121
59069
|
};
|
|
59122
|
-
},
|
|
59070
|
+
}, kN = ({ newActions: e, currentFolder: t, onUploadFiles: n, onCreateFolder: r, onUploadArchive: i, onCreateNewItem: a, isNewButtonDisabled: o }) => {
|
|
59123
59071
|
let s = f(() => {
|
|
59124
59072
|
let t = [];
|
|
59125
59073
|
return e && (e.newFolder && t.push({
|
|
@@ -59173,30 +59121,30 @@ var jN = ({ items: e, onRenameValidate: t, validationMessages: n, onMoveToFiles:
|
|
|
59173
59121
|
return {
|
|
59174
59122
|
newActions: s,
|
|
59175
59123
|
isNewButtonVisible: f(() => s?.length > 0, [s]),
|
|
59176
|
-
isNewButtonDisabled: f(() => !t?.permissions?.includes(
|
|
59124
|
+
isNewButtonDisabled: f(() => !t?.permissions?.includes(zM.WRITE) || !!o, [t, o])
|
|
59177
59125
|
};
|
|
59178
|
-
},
|
|
59126
|
+
}, AN = {
|
|
59179
59127
|
emptyName: "Folder name cannot be empty",
|
|
59180
59128
|
duplicateName: "A folder with this name already exists",
|
|
59181
|
-
hiddenItemWarning:
|
|
59182
|
-
consecutiveDotsError:
|
|
59183
|
-
},
|
|
59184
|
-
let [a, s] = m(!1), [l, u] = m(null), [d, h] = m(
|
|
59185
|
-
...
|
|
59129
|
+
hiddenItemWarning: bN.hiddenItemWarning,
|
|
59130
|
+
consecutiveDotsError: xN.consecutiveDotsError
|
|
59131
|
+
}, jN = ({ currentFolder: e, onCreateFolder: t, onValidateFolderName: n, validationMessages: r, items: i = [] }) => {
|
|
59132
|
+
let [a, s] = m(!1), [l, u] = m(null), [d, h] = m(_M.Folder), [g, _] = m(null), [v, y] = m(null), [b, x] = m(""), S = p(e?.path), C = f(() => ({
|
|
59133
|
+
...AN,
|
|
59186
59134
|
...r
|
|
59187
59135
|
}), [r]), w = f(() => {
|
|
59188
|
-
if (d ===
|
|
59189
|
-
if (d ===
|
|
59190
|
-
let e =
|
|
59136
|
+
if (d === _M.Folder) return e;
|
|
59137
|
+
if (d === _M.Sibling && g) {
|
|
59138
|
+
let e = GM(i, g.parentPath || "");
|
|
59191
59139
|
return {
|
|
59192
59140
|
path: g.parentPath,
|
|
59193
59141
|
items: e?.items || [],
|
|
59194
|
-
nodeType:
|
|
59142
|
+
nodeType: LM.FOLDER,
|
|
59195
59143
|
name: g?.parentPath?.split("/")?.pop() || "",
|
|
59196
59144
|
folderId: ""
|
|
59197
59145
|
};
|
|
59198
59146
|
}
|
|
59199
|
-
return d ===
|
|
59147
|
+
return d === _M.Child ? g : e;
|
|
59200
59148
|
}, [
|
|
59201
59149
|
d,
|
|
59202
59150
|
g,
|
|
@@ -59210,30 +59158,30 @@ var jN = ({ items: e, onRenameValidate: t, validationMessages: n, onMoveToFiles:
|
|
|
59210
59158
|
let T = o(() => {
|
|
59211
59159
|
if (a) return;
|
|
59212
59160
|
S.current = e?.path || "/";
|
|
59213
|
-
let t = `__new_folder_${Date.now()}`, n =
|
|
59214
|
-
u(t), x(n), s(!0), h(
|
|
59161
|
+
let t = `__new_folder_${Date.now()}`, n = sN((e?.items ?? []).filter((e) => e.nodeType === LM.FOLDER));
|
|
59162
|
+
u(t), x(n), s(!0), h(_M.Folder), _(e || null);
|
|
59215
59163
|
}, [a, e]), E = o((e) => {
|
|
59216
59164
|
if (a) return;
|
|
59217
59165
|
S.current = e?.parentPath || "/";
|
|
59218
59166
|
let t = `__new_folder_${Date.now()}`;
|
|
59219
|
-
x(
|
|
59167
|
+
x(sN((GM(i, e?.parentPath || "/")?.items ?? []).filter((e) => e.nodeType === LM.FOLDER))), u(t), s(!0), h(_M.Sibling), _(e), y(e?.parentPath || "/");
|
|
59220
59168
|
}, [a, i]), ee = o((e) => {
|
|
59221
59169
|
if (a) return;
|
|
59222
59170
|
S.current = e.path;
|
|
59223
59171
|
let t = `__new_folder_${Date.now()}`;
|
|
59224
|
-
x(
|
|
59172
|
+
x(sN((e?.items ?? []).filter((e) => e.nodeType === LM.FOLDER))), u(t), s(!0), h(_M.Child), _(e), y(e?.path || "/");
|
|
59225
59173
|
}, [a]), D = o((e) => {
|
|
59226
|
-
a || (S.current = e?.parentPath || "/", x(
|
|
59174
|
+
a || (S.current = e?.parentPath || "/", x(sN((GM(i, e?.parentPath || "/")?.items ?? []).filter((e) => e.nodeType === LM.FOLDER))), h(_M.Sibling), _(e), y(e?.parentPath || "/"), s(!0));
|
|
59227
59175
|
}, [a, i]), O = o((e) => {
|
|
59228
|
-
a || (S.current = e.path, x(
|
|
59176
|
+
a || (S.current = e.path, x(sN((e?.items ?? []).filter((e) => e.nodeType === LM.FOLDER))), h(_M.Child), _(e), y(e?.path || "/"), s(!0));
|
|
59229
59177
|
}, [a]), te = o(() => {
|
|
59230
|
-
s(!1), u(null), h(
|
|
59178
|
+
s(!1), u(null), h(_M.Folder), _(null), y(null), S.current = void 0, x("");
|
|
59231
59179
|
}, []), k = o((e) => {
|
|
59232
59180
|
let t = e.trim();
|
|
59233
59181
|
if (!t) return C.emptyName;
|
|
59234
59182
|
if (t.includes("..")) return C.consecutiveDotsError;
|
|
59235
59183
|
if (t.startsWith(".") && t.length > 1) return C.hiddenItemWarning;
|
|
59236
|
-
if (w && w.items && new Set((w.items ?? []).filter((e) => e.nodeType ===
|
|
59184
|
+
if (w && w.items && new Set((w.items ?? []).filter((e) => e.nodeType === LM.FOLDER).map((e) => e.name.toLowerCase())).has(t.toLowerCase())) return C.duplicateName;
|
|
59237
59185
|
if (n && w) {
|
|
59238
59186
|
let e = n(t, w);
|
|
59239
59187
|
if (e) return e;
|
|
@@ -59259,9 +59207,9 @@ var jN = ({ items: e, onRenameValidate: t, validationMessages: n, onMoveToFiles:
|
|
|
59259
59207
|
let n = e.trim();
|
|
59260
59208
|
if (!n) return;
|
|
59261
59209
|
te();
|
|
59262
|
-
let r = `${w?.path ?? "/"}/${n}`, i = `${r}/${
|
|
59263
|
-
fileContent: new File([],
|
|
59264
|
-
name:
|
|
59210
|
+
let r = `${w?.path ?? "/"}/${n}`, i = `${r}/${AM}`, a = {
|
|
59211
|
+
fileContent: new File([], AM, { type: "text/plain" }),
|
|
59212
|
+
name: AM
|
|
59265
59213
|
};
|
|
59266
59214
|
t && await t(a, r, i);
|
|
59267
59215
|
}, [
|
|
@@ -59271,11 +59219,11 @@ var jN = ({ items: e, onRenameValidate: t, validationMessages: n, onMoveToFiles:
|
|
|
59271
59219
|
]),
|
|
59272
59220
|
validateFolderName: k
|
|
59273
59221
|
};
|
|
59274
|
-
},
|
|
59222
|
+
}, MN = ({ additionalButtons: e, expandedPathsLength: t, collapseAll: n }) => {
|
|
59275
59223
|
let r = t === 0;
|
|
59276
|
-
return { additionalButtons: f(() => /* @__PURE__ */ N(Ge, { children: [e, /* @__PURE__ */ M(
|
|
59224
|
+
return { additionalButtons: f(() => /* @__PURE__ */ N(Ge, { children: [e, /* @__PURE__ */ M(Ce, {
|
|
59277
59225
|
disabled: r,
|
|
59278
|
-
size:
|
|
59226
|
+
size: be.Small,
|
|
59279
59227
|
onClick: n,
|
|
59280
59228
|
icon: /* @__PURE__ */ M($e, {
|
|
59281
59229
|
size: T.LG,
|
|
@@ -59287,7 +59235,7 @@ var jN = ({ items: e, onRenameValidate: t, validationMessages: n, onMoveToFiles:
|
|
|
59287
59235
|
r,
|
|
59288
59236
|
n
|
|
59289
59237
|
]) };
|
|
59290
|
-
},
|
|
59238
|
+
}, NN = ({ onGetInfo: e }) => {
|
|
59291
59239
|
let [t, n] = m(!1), [r, i] = m(void 0);
|
|
59292
59240
|
return {
|
|
59293
59241
|
isMetadataPopupOpen: t,
|
|
@@ -59300,18 +59248,18 @@ var jN = ({ items: e, onRenameValidate: t, validationMessages: n, onMoveToFiles:
|
|
|
59300
59248
|
}, [])
|
|
59301
59249
|
};
|
|
59302
59250
|
};
|
|
59303
|
-
function
|
|
59251
|
+
function PN(e) {
|
|
59304
59252
|
let t = [];
|
|
59305
59253
|
function n(e) {
|
|
59306
59254
|
for (let r of e) t.push(r), r.items && n(r.items);
|
|
59307
59255
|
}
|
|
59308
59256
|
return n(e), t;
|
|
59309
59257
|
}
|
|
59310
|
-
function
|
|
59311
|
-
let n =
|
|
59312
|
-
return e.filter((e) =>
|
|
59258
|
+
function FN(e, t) {
|
|
59259
|
+
let n = KM(t);
|
|
59260
|
+
return e.filter((e) => KM(e.name).includes(n));
|
|
59313
59261
|
}
|
|
59314
|
-
function
|
|
59262
|
+
function IN({ onSearchFiles: e, clearSearchResults: t, currentPath: n, searchResults: r = [], searchInProgress: i = !1, navigationPanelValue: a, onNavigationPanelSearchChange: s, allItems: l = [], activeTab: u }) {
|
|
59315
59263
|
let [d, h] = m(""), g = p(!1), _ = p(!1), v = p([]), y = p(n), b = p(u);
|
|
59316
59264
|
c(() => {
|
|
59317
59265
|
a != null && h(String(a));
|
|
@@ -59353,9 +59301,9 @@ function BN({ onSearchFiles: e, clearSearchResults: t, currentPath: n, searchRes
|
|
|
59353
59301
|
searchResultsRows: f(() => {
|
|
59354
59302
|
if (e) {
|
|
59355
59303
|
let e = i ? v.current : r;
|
|
59356
|
-
return !x || e.length === 0 ? e :
|
|
59304
|
+
return !x || e.length === 0 ? e : FN(e, x);
|
|
59357
59305
|
}
|
|
59358
|
-
return !x || !l.length ? [] :
|
|
59306
|
+
return !x || !l.length ? [] : FN(PN(l), x);
|
|
59359
59307
|
}, [
|
|
59360
59308
|
e,
|
|
59361
59309
|
r,
|
|
@@ -59365,7 +59313,7 @@ function BN({ onSearchFiles: e, clearSearchResults: t, currentPath: n, searchRes
|
|
|
59365
59313
|
])
|
|
59366
59314
|
};
|
|
59367
59315
|
}
|
|
59368
|
-
function
|
|
59316
|
+
function LN({ selectedPaths: e, defaultSelectedPaths: t, onSelectedPathsChange: n }) {
|
|
59369
59317
|
let r = e !== void 0, [i, a] = m(() => t ?? /* @__PURE__ */ new Set()), s = f(() => r ? e : i, [
|
|
59370
59318
|
r,
|
|
59371
59319
|
e,
|
|
@@ -59383,14 +59331,14 @@ function VN({ selectedPaths: e, defaultSelectedPaths: t, onSelectedPathsChange:
|
|
|
59383
59331
|
isControlled: r
|
|
59384
59332
|
};
|
|
59385
59333
|
}
|
|
59386
|
-
var
|
|
59387
|
-
let { selectedPaths: it, clearSelection: at, setSelectedPaths: ot } =
|
|
59334
|
+
var RN = ({ managerLabel: e, children: t, className: n, items: r = [], rootItem: i, path: a, defaultPath: s, filesLoading: l, selectedPaths: u, defaultSelectedPaths: d, onSelectedPathsChange: h, showHiddenFiles: g, onShowHiddenFilesChange: _, treeOptions: v, showNavigationPanel: y = !0, navigationPanelOptions: b, deleteConfirmationOptions: x, gridOptions: S, toolbarOptions: C, bulkActionsToolbarOptions: w, destinationFolderPopupOptions: T, conflictResolutionPopupOptions: E, onPathChange: ee, onTableFileClick: D, handleSelectionClick: O, onGridApiChange: te, onCopyFiles: k, onMoveToFiles: ne, onDeleteFiles: A, onDownloadFiles: re, onRenameValidate: ie, renameValidationMessages: j, forbiddenSymbolsRegExp: ae = Te, forbiddenSymbolsTooltip: oe, onUploadFiles: se, onValidateUpload: ce, uploadEnabled: le, uploadValidationMessages: ue, maxFileSize: de, onUploadArchive: fe, prepareUploadFileName: pe, onCreateFolder: me, onCreateFolderValidate: he, folderCreationValidationMessages: ge, fileMetadataPopupOptions: _e, onGetInfo: ve, onUnshareFiles: ye, onRemoveFilesAccess: be, actionsRef: xe, sharedByMePaths: Se, onSearchFiles: Ce, searchResults: we, searchInProgress: Ee, clearSearchResults: De, allowedFileTypes: Oe, maxSelectableFileSize: ke, getDisabledTooltip: Ae, fileTooLargeTooltip: je, unsupportedFileTypeTooltip: Me, emptyStateIcon: Ne, emptyStateTitle: Pe, emptyStateDescription: Fe, sharedWithMeIds: Ie, onFolderPopupPathChange: Le, onManagePermissions: Re, onPreview: ze, onOpenInNewTab: Be, previewExtensions: Ve, isRenameFileAvailable: He, isDuplicateFolderAvailable: Ue, customUploadFileAction: We, customCreateNewItemAction: Ge, customDuplicateAction: N, customDeleteItemsAction: Ke, customDownloadItemsAction: qe, customBreakpointRef: Je, gridClassName: Ye, nonClickableTableColumns: Xe, hideSearchPathItemName: Ze, showHiddenFileSwitcherInDestinationPopup: Qe, showCreateFolderButtonInDestinationPopup: $e, autoSelectUploadedItems: et = !1, maxNewFolderDepth: tt, onNewFolderDepthExceeded: nt, initialUploadFilesOpen: rt }) => {
|
|
59335
|
+
let { selectedPaths: it, clearSelection: at, setSelectedPaths: ot } = LN({
|
|
59388
59336
|
selectedPaths: u,
|
|
59389
59337
|
defaultSelectedPaths: d,
|
|
59390
59338
|
onSelectedPathsChange: h
|
|
59391
59339
|
}), st = p(!1), ct = p(null), lt = o((e, t, n) => {
|
|
59392
59340
|
if (et) {
|
|
59393
|
-
let { parent: e, name: n } =
|
|
59341
|
+
let { parent: e, name: n } = rN(t);
|
|
59394
59342
|
ct.current = {
|
|
59395
59343
|
fileNames: /* @__PURE__ */ new Set([n]),
|
|
59396
59344
|
destinationFolder: e
|
|
@@ -59410,20 +59358,20 @@ var HN = ({ managerLabel: e, children: t, className: n, items: r = [], rootItem:
|
|
|
59410
59358
|
}, [fe, et]), ft = f(() => {
|
|
59411
59359
|
let e = /* @__PURE__ */ new Map();
|
|
59412
59360
|
return it.forEach((t) => {
|
|
59413
|
-
let n =
|
|
59361
|
+
let n = WM(r, t);
|
|
59414
59362
|
n && e.set(t, n);
|
|
59415
59363
|
}), e;
|
|
59416
59364
|
}, [it, r]);
|
|
59417
59365
|
c(() => {
|
|
59418
59366
|
if (it.size === 0) return;
|
|
59419
59367
|
let e = !1;
|
|
59420
|
-
for (let t of it) if (!
|
|
59368
|
+
for (let t of it) if (!WM(r, t)) {
|
|
59421
59369
|
e = !0;
|
|
59422
59370
|
break;
|
|
59423
59371
|
}
|
|
59424
59372
|
if (e) {
|
|
59425
59373
|
let e = /* @__PURE__ */ new Set();
|
|
59426
|
-
for (let t of it)
|
|
59374
|
+
for (let t of it) WM(r, t) && e.add(t);
|
|
59427
59375
|
ot(e);
|
|
59428
59376
|
}
|
|
59429
59377
|
}, [
|
|
@@ -59431,7 +59379,7 @@ var HN = ({ managerLabel: e, children: t, className: n, items: r = [], rootItem:
|
|
|
59431
59379
|
it,
|
|
59432
59380
|
ot
|
|
59433
59381
|
]);
|
|
59434
|
-
let { currentPath: pt, setCurrentPath: mt, handlePathChange: ht } =
|
|
59382
|
+
let { currentPath: pt, setCurrentPath: mt, handlePathChange: ht } = mN({
|
|
59435
59383
|
path: a,
|
|
59436
59384
|
defaultPath: s,
|
|
59437
59385
|
onPathChange: ee,
|
|
@@ -59445,31 +59393,31 @@ var HN = ({ managerLabel: e, children: t, className: n, items: r = [], rootItem:
|
|
|
59445
59393
|
};
|
|
59446
59394
|
}, [S]), _t = gt.showFiles, vt = gt.showFolders, [yt, bt] = m(), xt = T?.destinationFolderPath ?? yt, St = o((e) => {
|
|
59447
59395
|
T?.setDestinationFolderPath ? T.setDestinationFolderPath(e) : bt(e);
|
|
59448
|
-
}, [T]), { areHiddenFilesVisible: Ct, toggleHiddenFilesVisibility: wt } =
|
|
59396
|
+
}, [T]), { areHiddenFilesVisible: Ct, toggleHiddenFilesVisibility: wt } = cN({
|
|
59449
59397
|
showHiddenFiles: g,
|
|
59450
59398
|
onShowHiddenFilesChange: _
|
|
59451
|
-
}), { isTreeCollapsed: Tt, toggleTreeCollapse: Et, setIsTreeCollapsed: Dt } =
|
|
59399
|
+
}), { isTreeCollapsed: Tt, toggleTreeCollapse: Et, setIsTreeCollapsed: Dt } = lN({
|
|
59452
59400
|
collapsed: v?.collapsed,
|
|
59453
59401
|
onCollapseChange: v?.onCollapseChange
|
|
59454
|
-
}), { renamedPath: Ot, renamedItem: kt, renameHandler: At, renameSaveHandler: jt, renameCancelHandler: Mt, renameValidateHandler: Nt, getDisplayName: Pt } =
|
|
59402
|
+
}), { renamedPath: Ot, renamedItem: kt, renameHandler: At, renameSaveHandler: jt, renameCancelHandler: Mt, renameValidateHandler: Nt, getDisplayName: Pt } = DN({
|
|
59455
59403
|
items: r,
|
|
59456
59404
|
onRenameValidate: ie,
|
|
59457
59405
|
validationMessages: j,
|
|
59458
59406
|
onMoveToFiles: ne
|
|
59459
|
-
}), { isSearchMode: Ft, searchValue: It, effectiveSearchValue: Lt, setSearchValue: Rt, handleSearchChange: zt, handleSearchClear: Bt, searchResultsRows: Vt } =
|
|
59407
|
+
}), { isSearchMode: Ft, searchValue: It, effectiveSearchValue: Lt, setSearchValue: Rt, handleSearchChange: zt, handleSearchClear: Bt, searchResultsRows: Vt } = IN({
|
|
59460
59408
|
onSearchFiles: Ce,
|
|
59461
|
-
clearSearchResults:
|
|
59409
|
+
clearSearchResults: De,
|
|
59462
59410
|
currentPath: pt,
|
|
59463
59411
|
searchResults: we,
|
|
59464
|
-
searchInProgress:
|
|
59412
|
+
searchInProgress: Ee,
|
|
59465
59413
|
navigationPanelValue: b?.value,
|
|
59466
59414
|
onNavigationPanelSearchChange: b?.onSearchChange,
|
|
59467
59415
|
allItems: r,
|
|
59468
59416
|
activeTab: C?.activeTab
|
|
59469
|
-
}), Ht = f(() =>
|
|
59417
|
+
}), Ht = f(() => GM(r, pt) ?? r[0], [r, pt]), Ut = o((e, t) => !t || !e ? !1 : oN(e.path) > t, []), Wt = o(() => {
|
|
59470
59418
|
nt?.();
|
|
59471
|
-
}, [nt]), { handleCopyTo: Gt, handleMoveTo: Kt, handleDuplicate: qt, handleOpenDestinationFolderPopup: Jt, handleCloseDestinationFolderPopup: Yt, openDestinationFolderPopup: Xt, handleSetCopiedFiles: Zt, handleSetMovedFiles: Qt, destinationFolderMode: $t, destinationFolderTitle: en, conflictingFiles: tn, conflictResolutionOpen: nn, closeConflictResolution: rn, handleConflictReplace: an, handleConflictDuplicate: on, handleConflictCancel: sn, handleConflictDecideForEach: cn, sourceFolder: ln } =
|
|
59472
|
-
getDestinationFiles: (e) =>
|
|
59419
|
+
}, [nt]), { handleCopyTo: Gt, handleMoveTo: Kt, handleDuplicate: qt, handleOpenDestinationFolderPopup: Jt, handleCloseDestinationFolderPopup: Yt, openDestinationFolderPopup: Xt, handleSetCopiedFiles: Zt, handleSetMovedFiles: Qt, destinationFolderMode: $t, destinationFolderTitle: en, conflictingFiles: tn, conflictResolutionOpen: nn, closeConflictResolution: rn, handleConflictReplace: an, handleConflictDuplicate: on, handleConflictCancel: sn, handleConflictDecideForEach: cn, sourceFolder: ln } = pN({
|
|
59420
|
+
getDestinationFiles: (e) => GM(r, e)?.items ?? [],
|
|
59473
59421
|
onCopyFiles: k,
|
|
59474
59422
|
onMoveToFiles: ne,
|
|
59475
59423
|
onCopySuccess: at,
|
|
@@ -59481,14 +59429,14 @@ var HN = ({ managerLabel: e, children: t, className: n, items: r = [], rootItem:
|
|
|
59481
59429
|
c(() => {
|
|
59482
59430
|
Xt || St(void 0);
|
|
59483
59431
|
}, [Xt, St]);
|
|
59484
|
-
let { deleteConfirmationOpen: un, itemsToDelete: dn, openDeleteConfirmation: fn, closeDeleteConfirmation: pn, confirmDelete: mn } =
|
|
59432
|
+
let { deleteConfirmationOpen: un, itemsToDelete: dn, openDeleteConfirmation: fn, closeDeleteConfirmation: pn, confirmDelete: mn } = hN({
|
|
59485
59433
|
onDeleteFiles: A,
|
|
59486
59434
|
onDeleteSuccess: at
|
|
59487
|
-
}), { handleDownloadFiles: hn } =
|
|
59435
|
+
}), { handleDownloadFiles: hn } = gN({
|
|
59488
59436
|
onDownloadFiles: re,
|
|
59489
59437
|
customDownloadItemsAction: qe,
|
|
59490
59438
|
onDownloadSuccess: at
|
|
59491
|
-
}), { isDragging: gn, isDraggingOverWindow: _n, uploadError: vn, handleDragEnter: yn, handleDragLeave: bn, handleDragOver: xn, handleDrop: Sn, clearError: Cn, openFileDialog: wn, fileInputRef: Tn, openArchiveDialog: En, uploadConflictingFiles: Dn, uploadConflictResolutionOpen: On, closeUploadConflictResolution: kn, handleUploadConflictReplace: An, handleUploadConflictDuplicate: jn, handleUploadConflictCancel: Mn, handleUploadConflictDecideForEach: Nn } =
|
|
59439
|
+
}), { isDragging: gn, isDraggingOverWindow: _n, uploadError: vn, handleDragEnter: yn, handleDragLeave: bn, handleDragOver: xn, handleDrop: Sn, clearError: Cn, openFileDialog: wn, fileInputRef: Tn, openArchiveDialog: En, uploadConflictingFiles: Dn, uploadConflictResolutionOpen: On, closeUploadConflictResolution: kn, handleUploadConflictReplace: An, handleUploadConflictDuplicate: jn, handleUploadConflictCancel: Mn, handleUploadConflictDecideForEach: Nn } = vN({
|
|
59492
59440
|
onUploadFiles: ut,
|
|
59493
59441
|
onValidateUpload: ce,
|
|
59494
59442
|
maxFileSize: de,
|
|
@@ -59535,7 +59483,7 @@ var HN = ({ managerLabel: e, children: t, className: n, items: r = [], rootItem:
|
|
|
59535
59483
|
Bt
|
|
59536
59484
|
]), zn = o((e) => {
|
|
59537
59485
|
N?.(e);
|
|
59538
|
-
}, [N]), { isCreatingFolder: Bn, newFolderTempId: Vn, createdFolderPath: Hn, newFolderDefaultName: Un, startFolderCreation: Wn, startGridSiblingFolderCreation: Gn, startTreeSiblingFolderCreation: Kn, startGridChildFolderCreation: qn, startTreeChildFolderCreation: Jn, cancelFolderCreation: Yn, saveFolderCreation: Xn, validateFolderName: Zn } =
|
|
59486
|
+
}, [N]), { isCreatingFolder: Bn, newFolderTempId: Vn, createdFolderPath: Hn, newFolderDefaultName: Un, startFolderCreation: Wn, startGridSiblingFolderCreation: Gn, startTreeSiblingFolderCreation: Kn, startGridChildFolderCreation: qn, startTreeChildFolderCreation: Jn, cancelFolderCreation: Yn, saveFolderCreation: Xn, validateFolderName: Zn } = jN({
|
|
59539
59487
|
currentFolder: Ht,
|
|
59540
59488
|
onCreateFolder: lt,
|
|
59541
59489
|
onValidateFolderName: he,
|
|
@@ -59554,7 +59502,7 @@ var HN = ({ managerLabel: e, children: t, className: n, items: r = [], rootItem:
|
|
|
59554
59502
|
tt,
|
|
59555
59503
|
Ut,
|
|
59556
59504
|
Wt
|
|
59557
|
-
]), { newActions: $n, isNewButtonVisible: er, isNewButtonDisabled: tr } =
|
|
59505
|
+
]), { newActions: $n, isNewButtonVisible: er, isNewButtonDisabled: tr } = kN({
|
|
59558
59506
|
newActions: C?.newActions,
|
|
59559
59507
|
currentFolder: Ht,
|
|
59560
59508
|
onUploadFiles: We ? Ln : Fn,
|
|
@@ -59565,7 +59513,7 @@ var HN = ({ managerLabel: e, children: t, className: n, items: r = [], rootItem:
|
|
|
59565
59513
|
}), nr = f(() => {
|
|
59566
59514
|
if (Ft) {
|
|
59567
59515
|
let e = Vt;
|
|
59568
|
-
_t || (e = e.filter((e) => e.nodeType !==
|
|
59516
|
+
_t || (e = e.filter((e) => e.nodeType !== LM.ITEM)), vt || (e = e.filter((e) => e.nodeType !== LM.FOLDER)), Ct || (e = e.filter((e) => !e.path.split("/").filter(Boolean).some((e) => e.startsWith("."))));
|
|
59569
59517
|
let t = e.map((e) => ({
|
|
59570
59518
|
...e,
|
|
59571
59519
|
id: e.id ?? e.path,
|
|
@@ -59587,14 +59535,14 @@ var HN = ({ managerLabel: e, children: t, className: n, items: r = [], rootItem:
|
|
|
59587
59535
|
updatedAt: void 0,
|
|
59588
59536
|
author: void 0,
|
|
59589
59537
|
path: pt ?? "/",
|
|
59590
|
-
nodeType:
|
|
59538
|
+
nodeType: LM.FOLDER,
|
|
59591
59539
|
extension: void 0,
|
|
59592
59540
|
isTemporary: !0,
|
|
59593
59541
|
owner: void 0
|
|
59594
59542
|
}), t;
|
|
59595
59543
|
}
|
|
59596
|
-
let e =
|
|
59597
|
-
_t || (n = n.filter((e) => e.nodeType !==
|
|
59544
|
+
let e = KM(Lt).trim(), t = Ht?.items ?? [], n = e ? JM(Ht) : t;
|
|
59545
|
+
_t || (n = n.filter((e) => e.nodeType !== LM.ITEM)), vt || (n = n.filter((e) => e.nodeType !== LM.FOLDER)), Ct || (n = n.filter((t) => e ? !t.path.split("/").filter(Boolean).some((e) => e.startsWith(".")) : !YM(t)));
|
|
59598
59546
|
let r = n.map((e) => ({
|
|
59599
59547
|
...e,
|
|
59600
59548
|
id: e.id ?? e.path,
|
|
@@ -59617,7 +59565,7 @@ var HN = ({ managerLabel: e, children: t, className: n, items: r = [], rootItem:
|
|
|
59617
59565
|
updatedAt: void 0,
|
|
59618
59566
|
author: void 0,
|
|
59619
59567
|
path: pt ?? "/",
|
|
59620
|
-
nodeType:
|
|
59568
|
+
nodeType: LM.FOLDER,
|
|
59621
59569
|
extension: void 0,
|
|
59622
59570
|
isTemporary: !0,
|
|
59623
59571
|
owner: void 0
|
|
@@ -59625,7 +59573,7 @@ var HN = ({ managerLabel: e, children: t, className: n, items: r = [], rootItem:
|
|
|
59625
59573
|
let i = e.split(/\s+/).filter(Boolean);
|
|
59626
59574
|
return r.filter((e) => {
|
|
59627
59575
|
if (e.isTemporary) return !0;
|
|
59628
|
-
let t =
|
|
59576
|
+
let t = KM(e.name), n = KM(e.author), r = qM(e.extension);
|
|
59629
59577
|
return i.every((e) => t.includes(e) || n.includes(e) || r.includes(e));
|
|
59630
59578
|
});
|
|
59631
59579
|
}, [
|
|
@@ -59648,10 +59596,10 @@ var HN = ({ managerLabel: e, children: t, className: n, items: r = [], rootItem:
|
|
|
59648
59596
|
ct.current = null;
|
|
59649
59597
|
return;
|
|
59650
59598
|
}
|
|
59651
|
-
let t =
|
|
59599
|
+
let t = GM(r, e.destinationFolder);
|
|
59652
59600
|
if (!t?.items) return;
|
|
59653
59601
|
let n = /* @__PURE__ */ new Set();
|
|
59654
|
-
for (let r of t.items) e.fileNames.has(r.name) &&
|
|
59602
|
+
for (let r of t.items) e.fileNames.has(r.name) && iN(r, Oe, ke) && n.add(r.path);
|
|
59655
59603
|
n.size > 0 && (ot(n), ct.current = null);
|
|
59656
59604
|
}, [
|
|
59657
59605
|
r,
|
|
@@ -59667,11 +59615,11 @@ var HN = ({ managerLabel: e, children: t, className: n, items: r = [], rootItem:
|
|
|
59667
59615
|
}, [ht]), ir = o((e) => {
|
|
59668
59616
|
ht(e);
|
|
59669
59617
|
}, [ht]), ar = o((e) => {
|
|
59670
|
-
e.nodeType ===
|
|
59671
|
-
}, [ht, D]), { expandedPaths: or, setExpandedPaths: sr, collapseAll: cr } =
|
|
59618
|
+
e.nodeType === LM.FOLDER ? ht(e.path) : D?.(e);
|
|
59619
|
+
}, [ht, D]), { expandedPaths: or, setExpandedPaths: sr, collapseAll: cr } = ON({
|
|
59672
59620
|
expandedPaths: v?.expandedPaths,
|
|
59673
59621
|
onExpandedPathsChange: v?.onExpandedPathsChange
|
|
59674
|
-
}), { additionalButtons: lr } =
|
|
59622
|
+
}), { additionalButtons: lr } = MN({
|
|
59675
59623
|
collapseAll: cr,
|
|
59676
59624
|
expandedPathsLength: or.size,
|
|
59677
59625
|
additionalButtons: v?.additionalButtons
|
|
@@ -59737,10 +59685,10 @@ var HN = ({ managerLabel: e, children: t, className: n, items: r = [], rootItem:
|
|
|
59737
59685
|
tt,
|
|
59738
59686
|
Ut,
|
|
59739
59687
|
Wt
|
|
59740
|
-
]), { isMetadataPopupOpen: mr, selectedFileForMetadata: P, openMetadataPopup: hr, closeMetadataPopup: gr } =
|
|
59688
|
+
]), { isMetadataPopupOpen: mr, selectedFileForMetadata: P, openMetadataPopup: hr, closeMetadataPopup: gr } = NN({ onGetInfo: ve }), _r = o(() => {
|
|
59741
59689
|
gr(), _e?.clearMetadata?.();
|
|
59742
59690
|
}, [gr, _e]), vr = f(() => {
|
|
59743
|
-
if (ae) return
|
|
59691
|
+
if (ae) return tN(ae);
|
|
59744
59692
|
}, [ae]), yr = {
|
|
59745
59693
|
managerLabel: e,
|
|
59746
59694
|
className: n,
|
|
@@ -59873,9 +59821,9 @@ var HN = ({ managerLabel: e, children: t, className: n, items: r = [], rootItem:
|
|
|
59873
59821
|
actionsRef: xe,
|
|
59874
59822
|
sharedByMePaths: Se,
|
|
59875
59823
|
onSearchFiles: Ce,
|
|
59876
|
-
searchInProgress:
|
|
59824
|
+
searchInProgress: Ee,
|
|
59877
59825
|
searchResults: we,
|
|
59878
|
-
clearSearchResults:
|
|
59826
|
+
clearSearchResults: De,
|
|
59879
59827
|
isSearchMode: Ft,
|
|
59880
59828
|
emptyStateIcon: Ne,
|
|
59881
59829
|
emptyStateTitle: Pe,
|
|
@@ -59901,11 +59849,11 @@ var HN = ({ managerLabel: e, children: t, className: n, items: r = [], rootItem:
|
|
|
59901
59849
|
maxNewFolderDepth: tt,
|
|
59902
59850
|
onNewFolderDepthExceeded: nt
|
|
59903
59851
|
};
|
|
59904
|
-
return /* @__PURE__ */ M(
|
|
59852
|
+
return /* @__PURE__ */ M(yN.Provider, {
|
|
59905
59853
|
value: yr,
|
|
59906
59854
|
children: t
|
|
59907
59855
|
});
|
|
59908
|
-
},
|
|
59856
|
+
}, zN = ({ disabledGridRowIds: e, gridRows: t, getDisabledTooltip: n, getRowDisabledTooltip: r, allowedFileTypes: i, maxSelectableFileSize: a }) => {
|
|
59909
59857
|
let [o, s] = m(null), [l, u] = m(null);
|
|
59910
59858
|
c(() => {
|
|
59911
59859
|
let e = () => {
|
|
@@ -59945,13 +59893,13 @@ var HN = ({ managerLabel: e, children: t, className: n, items: r = [], rootItem:
|
|
|
59945
59893
|
i,
|
|
59946
59894
|
a
|
|
59947
59895
|
]);
|
|
59948
|
-
return /* @__PURE__ */ M(Ge, { children: p && l && yt(/* @__PURE__ */ N(
|
|
59896
|
+
return /* @__PURE__ */ M(Ge, { children: p && l && yt(/* @__PURE__ */ N(me, {
|
|
59949
59897
|
open: !0,
|
|
59950
59898
|
placement: "top",
|
|
59951
|
-
children: [/* @__PURE__ */ M(
|
|
59899
|
+
children: [/* @__PURE__ */ M(ge, {
|
|
59952
59900
|
asChild: !0,
|
|
59953
59901
|
children: /* @__PURE__ */ M("div", {
|
|
59954
|
-
className: (0,
|
|
59902
|
+
className: (0, iM.default)("fixed z-[-1]", p && "pointer-events-none"),
|
|
59955
59903
|
style: {
|
|
59956
59904
|
top: l.top,
|
|
59957
59905
|
left: l.left,
|
|
@@ -59959,19 +59907,19 @@ var HN = ({ managerLabel: e, children: t, className: n, items: r = [], rootItem:
|
|
|
59959
59907
|
height: l.height
|
|
59960
59908
|
}
|
|
59961
59909
|
})
|
|
59962
|
-
}), /* @__PURE__ */ M(
|
|
59910
|
+
}), /* @__PURE__ */ M(he, {
|
|
59963
59911
|
className: "max-w-[300px] rounded border border-ui-outline-primary bg-ui-popover px-3 py-1.5 text-center text-primary shadow-md fill-ui-popover",
|
|
59964
59912
|
children: p
|
|
59965
59913
|
})]
|
|
59966
59914
|
}), document.body) });
|
|
59967
|
-
},
|
|
59968
|
-
let [e, t] = m(
|
|
59915
|
+
}, BN = () => typeof window < "u" && window.innerWidth < 640, VN = () => {
|
|
59916
|
+
let [e, t] = m(BN());
|
|
59969
59917
|
return c(() => {
|
|
59970
|
-
let e = () => t(
|
|
59918
|
+
let e = () => t(BN());
|
|
59971
59919
|
return window.addEventListener("resize", e), () => window.removeEventListener("resize", e);
|
|
59972
59920
|
}, []), e;
|
|
59973
|
-
},
|
|
59974
|
-
let [O, te] = m(!1), [k, ne] = m(!1), A = p(null), re =
|
|
59921
|
+
}, HN = ({ onClose: e, onConfirm: t, onFolderPopupPathChange: n, setDestinationFolderPath: r, open: i, copyLabel: a = "Copy", moveLabel: s = "Move", addFolderLabel: c = "Add folder", mode: l = mM.Copy, hiddenFilesSwitcherLabel: u = "Show hidden files", showHiddenFileSwitcher: d = !0, showCreateFolderButton: g = !0, onUploadFiles: v, onValidateUpload: y, maxFileSize: b, header: x, sourceFolder: S, disabledPathTooltip: C = "Unavailable for the original path. Please select another folder", path: w, collapsedFileTree: T = !1, alertProps: E, processDestinationFolderPath: ee, ...D }) => {
|
|
59922
|
+
let [O, te] = m(!1), [k, ne] = m(!1), A = p(null), re = VN(), ie = o((e) => {
|
|
59975
59923
|
te(e);
|
|
59976
59924
|
}, []), j = f(() => {
|
|
59977
59925
|
let e = [];
|
|
@@ -60010,29 +59958,29 @@ var HN = ({ managerLabel: e, children: t, className: n, items: r = [], rootItem:
|
|
|
60010
59958
|
n,
|
|
60011
59959
|
r,
|
|
60012
59960
|
ee
|
|
60013
|
-
]), oe = l ===
|
|
60014
|
-
return /* @__PURE__ */ M(
|
|
59961
|
+
]), oe = l === mM.Copy ? "Copy to" : "Move to", se = f(() => !w || !S ? !1 : S === w, [w, S]);
|
|
59962
|
+
return /* @__PURE__ */ M(Ae, {
|
|
60015
59963
|
open: i,
|
|
60016
59964
|
onClose: () => {
|
|
60017
59965
|
e();
|
|
60018
59966
|
},
|
|
60019
|
-
size:
|
|
59967
|
+
size: je.Lg,
|
|
60020
59968
|
className: "md:!h-[800px] !bg-layer-sunken",
|
|
60021
59969
|
footer: /* @__PURE__ */ N("div", {
|
|
60022
59970
|
className: "flex justify-between items-center gap-2 p-4 md:px-6",
|
|
60023
59971
|
children: [/* @__PURE__ */ M("div", {
|
|
60024
59972
|
className: "flex items-center gap-4 min-w-0",
|
|
60025
|
-
children: re ? /* @__PURE__ */ M(
|
|
59973
|
+
children: re ? /* @__PURE__ */ M(_e, {
|
|
60026
59974
|
items: j,
|
|
60027
59975
|
open: k,
|
|
60028
59976
|
onOpenChange: ne,
|
|
60029
|
-
children: /* @__PURE__ */ M(
|
|
60030
|
-
size:
|
|
59977
|
+
children: /* @__PURE__ */ M(Ce, {
|
|
59978
|
+
size: be.Large,
|
|
60031
59979
|
"aria-label": "More options",
|
|
60032
59980
|
icon: /* @__PURE__ */ M(et, { ...h })
|
|
60033
59981
|
})
|
|
60034
59982
|
}) : /* @__PURE__ */ N(Ge, { children: [
|
|
60035
|
-
g && /* @__PURE__ */ M(
|
|
59983
|
+
g && /* @__PURE__ */ M(Me, {
|
|
60036
59984
|
label: c,
|
|
60037
59985
|
appearance: _.Ghost,
|
|
60038
59986
|
iconBefore: /* @__PURE__ */ M(lt, { ...h }),
|
|
@@ -60053,18 +60001,18 @@ var HN = ({ managerLabel: e, children: t, className: n, items: r = [], rootItem:
|
|
|
60053
60001
|
] })
|
|
60054
60002
|
}), /* @__PURE__ */ N("div", {
|
|
60055
60003
|
className: "flex space-x-4 items-center",
|
|
60056
|
-
children: [/* @__PURE__ */ M(
|
|
60004
|
+
children: [/* @__PURE__ */ M(Ee, {
|
|
60057
60005
|
onClick: e,
|
|
60058
60006
|
label: "Cancel"
|
|
60059
|
-
}), se ? /* @__PURE__ */ M(
|
|
60007
|
+
}), se ? /* @__PURE__ */ M(pe, {
|
|
60060
60008
|
tooltip: C,
|
|
60061
|
-
children: /* @__PURE__ */ M(
|
|
60009
|
+
children: /* @__PURE__ */ M(Me, {
|
|
60062
60010
|
onClick: t,
|
|
60063
60011
|
label: l === "copy" ? a : s,
|
|
60064
60012
|
disabled: se,
|
|
60065
60013
|
"aria-disabled": se
|
|
60066
60014
|
})
|
|
60067
|
-
}) : /* @__PURE__ */ M(
|
|
60015
|
+
}) : /* @__PURE__ */ M(Me, {
|
|
60068
60016
|
onClick: t,
|
|
60069
60017
|
label: l === "copy" ? a : s
|
|
60070
60018
|
})]
|
|
@@ -60076,10 +60024,10 @@ var HN = ({ managerLabel: e, children: t, className: n, items: r = [], rootItem:
|
|
|
60076
60024
|
className: "bg-layer-sunken h-full flex flex-col",
|
|
60077
60025
|
children: [E && /* @__PURE__ */ M("div", {
|
|
60078
60026
|
className: "px-6 mb-4 pt-4",
|
|
60079
|
-
children: /* @__PURE__ */ M(
|
|
60027
|
+
children: /* @__PURE__ */ M(De, { ...E })
|
|
60080
60028
|
}), /* @__PURE__ */ M("div", {
|
|
60081
60029
|
className: "flex-1 min-h-0",
|
|
60082
|
-
children: /* @__PURE__ */ M(
|
|
60030
|
+
children: /* @__PURE__ */ M(wP, {
|
|
60083
60031
|
...D,
|
|
60084
60032
|
gridClassName: "size-full",
|
|
60085
60033
|
className: Ue(D.className, "bg-layer-sunken h-full flex pt-0"),
|
|
@@ -60110,10 +60058,10 @@ var HN = ({ managerLabel: e, children: t, className: n, items: r = [], rootItem:
|
|
|
60110
60058
|
})
|
|
60111
60059
|
});
|
|
60112
60060
|
};
|
|
60113
|
-
function
|
|
60061
|
+
function UN({ actions: e, direction: t = xe.Normal, moreButtonWidth: n = g, actionsGap: r = 8, containerPadding: i = 8, dependencies: a = [] }) {
|
|
60114
60062
|
let s = p(null), l = p(null), u = p(null), f = p(null), h = p([]), [_, v] = m(0), y = o((e, a) => {
|
|
60115
60063
|
let o = (u.current?.offsetWidth ?? 0) + (f.current?.offsetWidth ?? 0), s = a.getBoundingClientRect().width - o - n - r * 2 - i * 2, c = 0, l = 0;
|
|
60116
|
-
if (t ===
|
|
60064
|
+
if (t === xe.Reverse) for (let t = e.length - 1; t >= 0 && (c += e[t] + r, !(c > s)); t--) l++;
|
|
60117
60065
|
else for (let t of e) {
|
|
60118
60066
|
if (c += t + r, c > s) break;
|
|
60119
60067
|
l++;
|
|
@@ -60150,9 +60098,9 @@ function qN({ actions: e, direction: t = Ce.Normal, moreButtonWidth: n = g, acti
|
|
|
60150
60098
|
y,
|
|
60151
60099
|
...a
|
|
60152
60100
|
]);
|
|
60153
|
-
let b = t ===
|
|
60101
|
+
let b = t === xe.Reverse ? e.slice(0, e.length - _) : e.slice(_);
|
|
60154
60102
|
return {
|
|
60155
|
-
visibleActions: t ===
|
|
60103
|
+
visibleActions: t === xe.Reverse ? e.slice(e.length - _) : e.slice(0, _),
|
|
60156
60104
|
hiddenActions: b,
|
|
60157
60105
|
refs: {
|
|
60158
60106
|
containerRef: s,
|
|
@@ -60162,18 +60110,18 @@ function qN({ actions: e, direction: t = Ce.Normal, moreButtonWidth: n = g, acti
|
|
|
60162
60110
|
}
|
|
60163
60111
|
};
|
|
60164
60112
|
}
|
|
60165
|
-
var
|
|
60166
|
-
let i =
|
|
60113
|
+
var WN = 12, GN = 8, KN = ({ getSelectionLabel: e, onClearSelection: t, actions: n, selectedCount: r }) => {
|
|
60114
|
+
let i = VN(), { refs: { containerRef: a, leftSectionRef: o, measureRef: s }, visibleActions: c, hiddenActions: l } = UN({
|
|
60167
60115
|
actions: n,
|
|
60168
|
-
direction:
|
|
60116
|
+
direction: xe.Reverse,
|
|
60169
60117
|
dependencies: [i],
|
|
60170
|
-
actionsGap:
|
|
60171
|
-
containerPadding:
|
|
60118
|
+
actionsGap: WN,
|
|
60119
|
+
containerPadding: GN
|
|
60172
60120
|
}), u = e(r);
|
|
60173
60121
|
return /* @__PURE__ */ N(Ge, { children: [/* @__PURE__ */ M("div", {
|
|
60174
60122
|
ref: s,
|
|
60175
60123
|
className: "absolute top-0 left-0 invisible pointer-events-none overflow-hidden whitespace-nowrap flex gap-3",
|
|
60176
|
-
children: n.map(({ key: e, icon: t, title: n }) => /* @__PURE__ */ M(
|
|
60124
|
+
children: n.map(({ key: e, icon: t, title: n }) => /* @__PURE__ */ M(Ee, {
|
|
60177
60125
|
iconBefore: t,
|
|
60178
60126
|
label: n
|
|
60179
60127
|
}, e))
|
|
@@ -60184,7 +60132,7 @@ var JN = 12, YN = 8, XN = ({ getSelectionLabel: e, onClearSelection: t, actions:
|
|
|
60184
60132
|
"aria-label": "File bulk actions",
|
|
60185
60133
|
children: [/* @__PURE__ */ M("div", {
|
|
60186
60134
|
ref: o,
|
|
60187
|
-
children: /* @__PURE__ */ M(
|
|
60135
|
+
children: /* @__PURE__ */ M(Me, {
|
|
60188
60136
|
label: u,
|
|
60189
60137
|
onClick: t,
|
|
60190
60138
|
textClassName: "text-accent whitespace-nowrap",
|
|
@@ -60193,14 +60141,14 @@ var JN = 12, YN = 8, XN = ({ getSelectionLabel: e, onClearSelection: t, actions:
|
|
|
60193
60141
|
})
|
|
60194
60142
|
}), /* @__PURE__ */ N("div", {
|
|
60195
60143
|
className: "flex flex-1 w-full gap-3 items-center justify-end",
|
|
60196
|
-
children: [l.length > 0 && /* @__PURE__ */ M(
|
|
60144
|
+
children: [l.length > 0 && /* @__PURE__ */ M(_e, {
|
|
60197
60145
|
items: l,
|
|
60198
60146
|
allowedPlacements: ["bottom", "bottom-start"],
|
|
60199
|
-
children: /* @__PURE__ */ M(
|
|
60147
|
+
children: /* @__PURE__ */ M(Ce, {
|
|
60200
60148
|
className: "h-[38px]",
|
|
60201
60149
|
icon: /* @__PURE__ */ M(et, { ...h })
|
|
60202
60150
|
})
|
|
60203
|
-
}), c.map(({ key: e, icon: t, tooltip: n, title: r, onClick: i, disabled: a }) => /* @__PURE__ */ M(
|
|
60151
|
+
}), c.map(({ key: e, icon: t, tooltip: n, title: r, onClick: i, disabled: a }) => /* @__PURE__ */ M(Ee, {
|
|
60204
60152
|
className: "!p-[9px]",
|
|
60205
60153
|
iconBefore: t,
|
|
60206
60154
|
label: r,
|
|
@@ -60213,7 +60161,7 @@ var JN = 12, YN = 8, XN = ({ getSelectionLabel: e, onClearSelection: t, actions:
|
|
|
60213
60161
|
}, e))]
|
|
60214
60162
|
})]
|
|
60215
60163
|
})] });
|
|
60216
|
-
},
|
|
60164
|
+
}, qN = ({ open: e, itemsToDelete: t, onClose: n, onConfirm: r, cancelLabel: i = "Cancel", confirmLabel: a = "Delete", titleRenderer: o, contentRenderer: s }) => {
|
|
60217
60165
|
let c = t.map((e) => e.name), l = "Confirm Deleting Items", u = o?.(c) || l, d = /* @__PURE__ */ N("div", {
|
|
60218
60166
|
className: "px-6 py-3 dial-small-text",
|
|
60219
60167
|
children: [/* @__PURE__ */ M("p", {
|
|
@@ -60271,12 +60219,12 @@ var JN = 12, YN = 8, XN = ({ getSelectionLabel: e, onClearSelection: t, actions:
|
|
|
60271
60219
|
onConfirm: r,
|
|
60272
60220
|
children: f
|
|
60273
60221
|
});
|
|
60274
|
-
},
|
|
60222
|
+
}, JN = (e) => e.split("/").map((e) => e.trim()).filter(Boolean), YN = "w-full flex items-center justify-between gap-4", XN = "min-w-0 h-[38px] flex-1 overflow-hidden bg-layer-raised px-3 flex items-center rounded", ZN = "w-[260px]", QN = ({ ariaLabel: e = "Breadcrumb", labelClassName: t, onItemClick: n, path: r, makeHref: i, rootItemPath: a, rootItemLabel: s, breadcrumbsHiddenPathPart: c, className: l, breadcrumbClassName: u, searchable: d = !0, value: p, elementId: g = "file-manager-search", disabled: _, invalid: v, onSearchChange: y, searchClassName: b, searchContainerClassName: x, isCompactView: S = !1 }) => {
|
|
60275
60223
|
let C = f(() => {
|
|
60276
60224
|
if (!r) return;
|
|
60277
|
-
let e =
|
|
60225
|
+
let e = JN(r), t = [...e], o = 0;
|
|
60278
60226
|
if (c) {
|
|
60279
|
-
let t =
|
|
60227
|
+
let t = JN(c);
|
|
60280
60228
|
if (t.length) {
|
|
60281
60229
|
let n = e.findIndex((n, r) => t.every((t, n) => e[r + n] === t));
|
|
60282
60230
|
n !== -1 && (o = t.length, e = [...e.slice(0, n), ...e.slice(n + t.length)]);
|
|
@@ -60326,14 +60274,14 @@ var JN = 12, YN = 8, XN = ({ getSelectionLabel: e, onClearSelection: t, actions:
|
|
|
60326
60274
|
S
|
|
60327
60275
|
]), D = o(() => {
|
|
60328
60276
|
(!p || String(p).trim() === "") && y?.("");
|
|
60329
|
-
}, [p, y]), O = o(() => S && w ? /* @__PURE__ */ M(
|
|
60277
|
+
}, [p, y]), O = o(() => S && w ? /* @__PURE__ */ M(Ee, {
|
|
60330
60278
|
className: "!p-[9px]",
|
|
60331
60279
|
iconBefore: /* @__PURE__ */ M(Je, { ...h }),
|
|
60332
60280
|
onClick: () => {
|
|
60333
60281
|
T(!1), y?.("");
|
|
60334
60282
|
}
|
|
60335
60283
|
}) : /* @__PURE__ */ M("div", {
|
|
60336
|
-
className:
|
|
60284
|
+
className: XN,
|
|
60337
60285
|
children: /* @__PURE__ */ M(E, {
|
|
60338
60286
|
pathItems: C,
|
|
60339
60287
|
ariaLabel: e,
|
|
@@ -60350,10 +60298,10 @@ var JN = 12, YN = 8, XN = ({ getSelectionLabel: e, onClearSelection: t, actions:
|
|
|
60350
60298
|
y
|
|
60351
60299
|
]);
|
|
60352
60300
|
return /* @__PURE__ */ N("div", {
|
|
60353
|
-
className: Ue(
|
|
60301
|
+
className: Ue(YN, { "gap-3": S }, l),
|
|
60354
60302
|
"aria-label": "navigation-panel",
|
|
60355
60303
|
children: [O(), d && /* @__PURE__ */ M("div", {
|
|
60356
|
-
className: Ue(
|
|
60304
|
+
className: Ue(ZN, {
|
|
60357
60305
|
"w-[40px]": S && !w,
|
|
60358
60306
|
"w-full": S && w
|
|
60359
60307
|
}),
|
|
@@ -60373,8 +60321,8 @@ var JN = 12, YN = 8, XN = ({ getSelectionLabel: e, onClearSelection: t, actions:
|
|
|
60373
60321
|
})
|
|
60374
60322
|
})]
|
|
60375
60323
|
});
|
|
60376
|
-
},
|
|
60377
|
-
let _ =
|
|
60324
|
+
}, $N = ({ tabs: e, activeTab: t, onTabChange: n, areHiddenFilesVisible: r, onToggleHiddenFiles: i, isNewButtonVisible: a, isNewButtonDisabled: o, newButtonVariant: s = y.Primary, newButtonDropdownItems: c = [], newButtonLabel: l = "New", hiddenFilesSwitcherLabel: u = "Hidden files", showHiddenFilesLabel: d = "Show hidden files", hideHiddenFilesLabel: p = "Hide hidden files", showHiddenFilesToggle: m = !0, disabledNewButtonTooltip: g }) => {
|
|
60325
|
+
let _ = VN(), b = f(() => [{
|
|
60378
60326
|
key: "hidden-files-switch",
|
|
60379
60327
|
label: r ? p : d,
|
|
60380
60328
|
icon: M(r ? it : rt, {
|
|
@@ -60396,23 +60344,23 @@ var JN = 12, YN = 8, XN = ({ getSelectionLabel: e, onClearSelection: t, actions:
|
|
|
60396
60344
|
tabs: e,
|
|
60397
60345
|
activeTab: t,
|
|
60398
60346
|
onClick: (e) => n(e),
|
|
60399
|
-
screenThreshold:
|
|
60347
|
+
screenThreshold: Pe.Tablet,
|
|
60400
60348
|
smallScreenContainerClassName: "w-fit bg-transparent h-[38px] overflow-hidden",
|
|
60401
60349
|
smallScreenDropdownItemClassName: "px-3 h-[38px]"
|
|
60402
60350
|
}) : null
|
|
60403
60351
|
}), /* @__PURE__ */ M("div", {
|
|
60404
60352
|
className: "flex gap-2 shrink-0 items-center",
|
|
60405
|
-
children: _ ? /* @__PURE__ */ N(Ge, { children: [/* @__PURE__ */ M(
|
|
60353
|
+
children: _ ? /* @__PURE__ */ N(Ge, { children: [/* @__PURE__ */ M(_e, {
|
|
60406
60354
|
items: b,
|
|
60407
60355
|
allowedPlacements: ["bottom", "bottom-start"],
|
|
60408
|
-
children: /* @__PURE__ */ M(
|
|
60409
|
-
size:
|
|
60356
|
+
children: /* @__PURE__ */ M(Ce, {
|
|
60357
|
+
size: be.Small,
|
|
60410
60358
|
icon: /* @__PURE__ */ M(et, {
|
|
60411
60359
|
stroke: 2,
|
|
60412
60360
|
size: T.SM
|
|
60413
60361
|
})
|
|
60414
60362
|
})
|
|
60415
|
-
}), a ? /* @__PURE__ */ M(
|
|
60363
|
+
}), a ? /* @__PURE__ */ M(pe, {
|
|
60416
60364
|
tooltip: o && g ? g : void 0,
|
|
60417
60365
|
children: /* @__PURE__ */ M(v, {
|
|
60418
60366
|
label: l,
|
|
@@ -60425,7 +60373,7 @@ var JN = 12, YN = 8, XN = ({ getSelectionLabel: e, onClearSelection: t, actions:
|
|
|
60425
60373
|
label: u,
|
|
60426
60374
|
isOn: r,
|
|
60427
60375
|
onChange: i
|
|
60428
|
-
}), a && /* @__PURE__ */ M(
|
|
60376
|
+
}), a && /* @__PURE__ */ M(pe, {
|
|
60429
60377
|
tooltip: o && g ? g : void 0,
|
|
60430
60378
|
children: /* @__PURE__ */ M(v, {
|
|
60431
60379
|
label: l,
|
|
@@ -60436,116 +60384,116 @@ var JN = 12, YN = 8, XN = ({ getSelectionLabel: e, onClearSelection: t, actions:
|
|
|
60436
60384
|
})] })
|
|
60437
60385
|
})]
|
|
60438
60386
|
});
|
|
60439
|
-
},
|
|
60387
|
+
}, eP = 100, tP = 16, nP = "text-secondary", rP = "text-primary min-w-0", iP = "text-primary break-words min-w-0", aP = "bg-layer-sunken", oP = ({ open: e, onClose: t, fileMetadata: n, loading: r = !1, header: i = "Information", nameLabel: a = "Name:", pathLabel: o = "Path:", modifiedDateLabel: s = "Modified Date:", sizeLabel: c = "Size:", authorLabel: l = "Author:", dateLocale: u = "en-US", dateOptions: d }) => /* @__PURE__ */ M(Ae, {
|
|
60440
60388
|
open: e,
|
|
60441
60389
|
onClose: t,
|
|
60442
|
-
size:
|
|
60390
|
+
size: je.Sm,
|
|
60443
60391
|
header: i,
|
|
60444
60392
|
ariaLabel: "File information",
|
|
60445
60393
|
children: /* @__PURE__ */ M("div", {
|
|
60446
60394
|
className: "px-6 py-4",
|
|
60447
60395
|
children: /* @__PURE__ */ M("div", {
|
|
60448
60396
|
className: "grid gap-4 items-center dial-small-text",
|
|
60449
|
-
style: { gridTemplateColumns: `${
|
|
60397
|
+
style: { gridTemplateColumns: `${eP}px 1fr` },
|
|
60450
60398
|
children: r ? /* @__PURE__ */ N(Ge, { children: [
|
|
60451
60399
|
/* @__PURE__ */ M("div", {
|
|
60452
|
-
className:
|
|
60400
|
+
className: nP,
|
|
60453
60401
|
children: a
|
|
60454
60402
|
}),
|
|
60455
|
-
/* @__PURE__ */ M(
|
|
60456
|
-
variant:
|
|
60403
|
+
/* @__PURE__ */ M(Ie, {
|
|
60404
|
+
variant: Le.Text,
|
|
60457
60405
|
width: "100%",
|
|
60458
|
-
height:
|
|
60459
|
-
className:
|
|
60406
|
+
height: tP,
|
|
60407
|
+
className: aP
|
|
60460
60408
|
}),
|
|
60461
60409
|
/* @__PURE__ */ M("div", {
|
|
60462
|
-
className:
|
|
60410
|
+
className: nP,
|
|
60463
60411
|
children: s
|
|
60464
60412
|
}),
|
|
60465
|
-
/* @__PURE__ */ M(
|
|
60466
|
-
variant:
|
|
60413
|
+
/* @__PURE__ */ M(Ie, {
|
|
60414
|
+
variant: Le.Text,
|
|
60467
60415
|
width: "90%",
|
|
60468
|
-
height:
|
|
60469
|
-
className:
|
|
60416
|
+
height: tP,
|
|
60417
|
+
className: aP
|
|
60470
60418
|
}),
|
|
60471
60419
|
/* @__PURE__ */ M("div", {
|
|
60472
|
-
className:
|
|
60420
|
+
className: nP,
|
|
60473
60421
|
children: c
|
|
60474
60422
|
}),
|
|
60475
|
-
/* @__PURE__ */ M(
|
|
60476
|
-
variant:
|
|
60423
|
+
/* @__PURE__ */ M(Ie, {
|
|
60424
|
+
variant: Le.Text,
|
|
60477
60425
|
width: "60%",
|
|
60478
|
-
height:
|
|
60479
|
-
className:
|
|
60426
|
+
height: tP,
|
|
60427
|
+
className: aP
|
|
60480
60428
|
}),
|
|
60481
60429
|
/* @__PURE__ */ M("div", {
|
|
60482
|
-
className:
|
|
60430
|
+
className: nP,
|
|
60483
60431
|
children: l
|
|
60484
60432
|
}),
|
|
60485
|
-
/* @__PURE__ */ M(
|
|
60486
|
-
variant:
|
|
60433
|
+
/* @__PURE__ */ M(Ie, {
|
|
60434
|
+
variant: Le.Text,
|
|
60487
60435
|
width: "80%",
|
|
60488
|
-
height:
|
|
60489
|
-
className:
|
|
60436
|
+
height: tP,
|
|
60437
|
+
className: aP
|
|
60490
60438
|
}),
|
|
60491
60439
|
/* @__PURE__ */ M("div", {
|
|
60492
|
-
className:
|
|
60440
|
+
className: nP,
|
|
60493
60441
|
children: o
|
|
60494
60442
|
}),
|
|
60495
|
-
/* @__PURE__ */ M(
|
|
60496
|
-
variant:
|
|
60443
|
+
/* @__PURE__ */ M(Ie, {
|
|
60444
|
+
variant: Le.Text,
|
|
60497
60445
|
width: "70%",
|
|
60498
|
-
height:
|
|
60499
|
-
className:
|
|
60446
|
+
height: tP,
|
|
60447
|
+
className: aP
|
|
60500
60448
|
})
|
|
60501
60449
|
] }) : n ? /* @__PURE__ */ N(Ge, { children: [
|
|
60502
60450
|
/* @__PURE__ */ M("div", {
|
|
60503
|
-
className:
|
|
60451
|
+
className: nP,
|
|
60504
60452
|
children: a
|
|
60505
60453
|
}),
|
|
60506
60454
|
/* @__PURE__ */ M("div", {
|
|
60507
|
-
className:
|
|
60455
|
+
className: rP,
|
|
60508
60456
|
children: /* @__PURE__ */ M(k, { text: n.name })
|
|
60509
60457
|
}),
|
|
60510
60458
|
/* @__PURE__ */ M("div", {
|
|
60511
|
-
className:
|
|
60459
|
+
className: nP,
|
|
60512
60460
|
children: s
|
|
60513
60461
|
}),
|
|
60514
60462
|
/* @__PURE__ */ M("div", {
|
|
60515
|
-
className:
|
|
60516
|
-
children: /* @__PURE__ */ M(k, { text:
|
|
60463
|
+
className: rP,
|
|
60464
|
+
children: /* @__PURE__ */ M(k, { text: ZM(n.updatedAt, u, d) })
|
|
60517
60465
|
}),
|
|
60518
60466
|
/* @__PURE__ */ M("div", {
|
|
60519
|
-
className:
|
|
60467
|
+
className: nP,
|
|
60520
60468
|
children: c
|
|
60521
60469
|
}),
|
|
60522
60470
|
/* @__PURE__ */ M("div", {
|
|
60523
|
-
className:
|
|
60524
|
-
children: /* @__PURE__ */ M(k, { text:
|
|
60471
|
+
className: rP,
|
|
60472
|
+
children: /* @__PURE__ */ M(k, { text: XM(n.contentLength) })
|
|
60525
60473
|
}),
|
|
60526
60474
|
/* @__PURE__ */ M("div", {
|
|
60527
|
-
className:
|
|
60475
|
+
className: nP,
|
|
60528
60476
|
children: l
|
|
60529
60477
|
}),
|
|
60530
60478
|
/* @__PURE__ */ M("div", {
|
|
60531
|
-
className:
|
|
60479
|
+
className: rP,
|
|
60532
60480
|
children: /* @__PURE__ */ M(k, { text: n.author || "—" })
|
|
60533
60481
|
}),
|
|
60534
60482
|
/* @__PURE__ */ M("div", {
|
|
60535
|
-
className:
|
|
60483
|
+
className: nP,
|
|
60536
60484
|
children: o
|
|
60537
60485
|
}),
|
|
60538
60486
|
/* @__PURE__ */ M("div", {
|
|
60539
|
-
className:
|
|
60487
|
+
className: iP,
|
|
60540
60488
|
children: decodeURIComponent(n.path)
|
|
60541
60489
|
})
|
|
60542
60490
|
] }) : null
|
|
60543
60491
|
})
|
|
60544
60492
|
})
|
|
60545
|
-
}),
|
|
60493
|
+
}), sP = {
|
|
60546
60494
|
size: 10,
|
|
60547
60495
|
stroke: 2
|
|
60548
|
-
},
|
|
60496
|
+
}, cP = 26, lP = "__new_folder", uP = ({ name: e, type: t, shared: n = !1, loading: r = !1, sharedIndicatorClassName: i, sharedIndicatorTooltip: a, fileExtension: o, ...s }) => {
|
|
60549
60497
|
let c = (e) => /* @__PURE__ */ N("span", {
|
|
60550
60498
|
className: "inline-flex relative text-secondary",
|
|
60551
60499
|
role: "img",
|
|
@@ -60557,7 +60505,7 @@ var JN = 12, YN = 8, XN = ({ getSelectionLabel: e, onClearSelection: t, actions:
|
|
|
60557
60505
|
})
|
|
60558
60506
|
})]
|
|
60559
60507
|
});
|
|
60560
|
-
if (r) return c(/* @__PURE__ */ M(
|
|
60508
|
+
if (r) return c(/* @__PURE__ */ M(Re, {}));
|
|
60561
60509
|
if (t === oe.File) {
|
|
60562
60510
|
let t = o || (e.includes(".") ? e.split(".").pop() : void 0);
|
|
60563
60511
|
return /* @__PURE__ */ M(ne, {
|
|
@@ -60579,12 +60527,12 @@ var JN = 12, YN = 8, XN = ({ getSelectionLabel: e, onClearSelection: t, actions:
|
|
|
60579
60527
|
}),
|
|
60580
60528
|
className: "inline-block align-middle"
|
|
60581
60529
|
})) : null;
|
|
60582
|
-
},
|
|
60530
|
+
}, dP = ({ name: e, type: t, elementId: n, loading: r = !1, shared: i = !1, iconClassName: a, iconIndicator: o, iconLabel: s, iconSize: c, iconStroke: l, inputInvalid: u, inputInvalidMessage: d, inputContainerClassName: f, inputIconAfter: p, inputRef: m, onChange: g, sharedIndicatorClassName: _, sharedIndicatorTooltip: v, fileExtension: y }) => {
|
|
60583
60531
|
let b = () => {
|
|
60584
|
-
let e = d?.startsWith(`${
|
|
60532
|
+
let e = d?.startsWith(`${ke.Warning}__`);
|
|
60585
60533
|
if (!u && !e) return null;
|
|
60586
|
-
let t = d?.replace(`${
|
|
60587
|
-
return /* @__PURE__ */ M(
|
|
60534
|
+
let t = d?.replace(`${ke.Warning}__`, "");
|
|
60535
|
+
return /* @__PURE__ */ M(pe, {
|
|
60588
60536
|
tooltip: t,
|
|
60589
60537
|
children: p || (e ? /* @__PURE__ */ M(qe, {
|
|
60590
60538
|
...h,
|
|
@@ -60600,7 +60548,7 @@ var JN = 12, YN = 8, XN = ({ getSelectionLabel: e, onClearSelection: t, actions:
|
|
|
60600
60548
|
return /* @__PURE__ */ N("div", {
|
|
60601
60549
|
className: "flex gap-2 items-center",
|
|
60602
60550
|
...He,
|
|
60603
|
-
children: [/* @__PURE__ */ M(
|
|
60551
|
+
children: [/* @__PURE__ */ M(uP, {
|
|
60604
60552
|
name: e,
|
|
60605
60553
|
type: t,
|
|
60606
60554
|
label: s,
|
|
@@ -60613,7 +60561,7 @@ var JN = 12, YN = 8, XN = ({ getSelectionLabel: e, onClearSelection: t, actions:
|
|
|
60613
60561
|
fileExtension: y,
|
|
60614
60562
|
sharedIndicatorClassName: _,
|
|
60615
60563
|
sharedIndicatorTooltip: v
|
|
60616
|
-
}), /* @__PURE__ */ M(
|
|
60564
|
+
}), /* @__PURE__ */ M(we, {
|
|
60617
60565
|
containerClassName: Ue("!h-5 !py-[1px] !pl-[7px] pr-[7px]", f),
|
|
60618
60566
|
id: n,
|
|
60619
60567
|
value: e,
|
|
@@ -60623,7 +60571,7 @@ var JN = 12, YN = 8, XN = ({ getSelectionLabel: e, onClearSelection: t, actions:
|
|
|
60623
60571
|
inputRef: m
|
|
60624
60572
|
})]
|
|
60625
60573
|
});
|
|
60626
|
-
},
|
|
60574
|
+
}, fP = ({ name: e, type: t, elementId: n, editing: r = !1, loading: i = !1, creating: a = !1, shared: o = !1, iconSize: s = g, validate: c, onSave: l, fileExtension: u, onCancel: d, onCreateFolderCancel: f, onCreateFolderSave: p, inputContainerClassName: m, sharedIndicatorClassName: h, sharedIndicatorTooltip: _, hideTooltip: v = !1, forbiddenSymbolsRegExp: y, forbiddenSymbolsTooltip: b, ...x }) => {
|
|
60627
60575
|
let { value: S, invalid: C, invalidMessage: w, onChange: T, inputRef: E } = We({
|
|
60628
60576
|
value: e,
|
|
60629
60577
|
isEditing: r,
|
|
@@ -60636,7 +60584,7 @@ var JN = 12, YN = 8, XN = ({ getSelectionLabel: e, onClearSelection: t, actions:
|
|
|
60636
60584
|
onCreateFolderSave: p
|
|
60637
60585
|
});
|
|
60638
60586
|
if (!r && !a) {
|
|
60639
|
-
let n =
|
|
60587
|
+
let n = nN({
|
|
60640
60588
|
name: e,
|
|
60641
60589
|
isFolder: t === oe.Folder
|
|
60642
60590
|
}, y, b), r = !!n;
|
|
@@ -60662,7 +60610,7 @@ var JN = 12, YN = 8, XN = ({ getSelectionLabel: e, onClearSelection: t, actions:
|
|
|
60662
60610
|
tooltipContent: n
|
|
60663
60611
|
});
|
|
60664
60612
|
}
|
|
60665
|
-
return /* @__PURE__ */ M(
|
|
60613
|
+
return /* @__PURE__ */ M(dP, {
|
|
60666
60614
|
type: t,
|
|
60667
60615
|
name: S,
|
|
60668
60616
|
elementId: n,
|
|
@@ -60676,8 +60624,8 @@ var JN = 12, YN = 8, XN = ({ getSelectionLabel: e, onClearSelection: t, actions:
|
|
|
60676
60624
|
sharedIndicatorTooltip: _,
|
|
60677
60625
|
sharedIndicatorClassName: h
|
|
60678
60626
|
});
|
|
60679
|
-
},
|
|
60680
|
-
let { expandedPaths: ee, togglePath: D } =
|
|
60627
|
+
}, pP = ({ items: e, showFiles: t = !1, expandedPaths: n, loadingPaths: r = /* @__PURE__ */ new Set(), loadedPaths: i = /* @__PURE__ */ new Set(), sharedByMePaths: a = /* @__PURE__ */ new Set(), selectedPath: o, emptyStateTitle: s = "No Folders", emptyStateDescription: c, emptyStateIcon: l, areHiddenFilesVisible: u = !1, renamedPath: d, createdFolderPath: f, rootItemLabel: p, rootItemPath: m, onItemClick: g, getContextMenuItems: _, onRenameSave: v, onRenameCancel: y, onRenameValidate: b, onExpandedPathsChange: x, onCreateFolderSave: S, onCreateFolderCancel: C, forbiddenSymbolsRegExp: w, forbiddenSymbolsTooltip: T, newFolderDefaultName: E }) => {
|
|
60628
|
+
let { expandedPaths: ee, togglePath: D } = ON({
|
|
60681
60629
|
expandedPaths: n ?? /* @__PURE__ */ new Set(),
|
|
60682
60630
|
onExpandedPathsChange: x
|
|
60683
60631
|
}), O = (e) => {
|
|
@@ -60685,18 +60633,18 @@ var JN = 12, YN = 8, XN = ({ getSelectionLabel: e, onClearSelection: t, actions:
|
|
|
60685
60633
|
}, te = (e, n, s) => {
|
|
60686
60634
|
let c = e;
|
|
60687
60635
|
return s && s.path === f && (c = [{
|
|
60688
|
-
folderId:
|
|
60689
|
-
id:
|
|
60636
|
+
folderId: lP,
|
|
60637
|
+
id: lP,
|
|
60690
60638
|
items: [],
|
|
60691
60639
|
name: E || "",
|
|
60692
|
-
nodeType:
|
|
60640
|
+
nodeType: LM.FOLDER,
|
|
60693
60641
|
parentPath: f,
|
|
60694
|
-
path: `${f}/${
|
|
60642
|
+
path: `${f}/${lP}`
|
|
60695
60643
|
}, ...e]), c.map((e) => {
|
|
60696
|
-
let { path: s, nodeType: c, name: l, items: g } = e, x = c ===
|
|
60697
|
-
if (!u &&
|
|
60644
|
+
let { path: s, nodeType: c, name: l, items: g } = e, x = c === LM.FOLDER;
|
|
60645
|
+
if (!u && YM(e)) return null;
|
|
60698
60646
|
if (!x && !t) return;
|
|
60699
|
-
let E = Array.isArray(g) && g.length > 0 && g.some((e) => e.nodeType ===
|
|
60647
|
+
let E = Array.isArray(g) && g.length > 0 && g.some((e) => e.nodeType === LM.FOLDER || t), D = ee.has(s), k = o === s, ne = r.has(s), A = d === s || s === `${f}/${lP}`, re = i.has(s), ie = a.has(s), j = m && p && s === m && x, ae = b && ((t) => b(t, e)), se = k ? "bg-accent-primary-alpha border-l-2 border-l-accent-primary rounded" : "border-l-2 border-l-transparent", ce = j ? [] : _?.(e) ?? [], le = w ? nN({
|
|
60700
60648
|
name: e.name,
|
|
60701
60649
|
isFolder: x
|
|
60702
60650
|
}, w, T) : void 0;
|
|
@@ -60705,13 +60653,13 @@ var JN = 12, YN = 8, XN = ({ getSelectionLabel: e, onClearSelection: t, actions:
|
|
|
60705
60653
|
children: /* @__PURE__ */ N("div", {
|
|
60706
60654
|
className: "flex flex-col w-full",
|
|
60707
60655
|
"aria-label": "folder",
|
|
60708
|
-
children: [/* @__PURE__ */ M(
|
|
60709
|
-
trigger: [
|
|
60656
|
+
children: [/* @__PURE__ */ M(_e, {
|
|
60657
|
+
trigger: [ye.ContextMenu],
|
|
60710
60658
|
className: "w-full",
|
|
60711
60659
|
anchorToMouse: !0,
|
|
60712
60660
|
items: ce,
|
|
60713
60661
|
children: /* @__PURE__ */ N("div", {
|
|
60714
|
-
style: { paddingLeft: `${n *
|
|
60662
|
+
style: { paddingLeft: `${n * cP}px` },
|
|
60715
60663
|
className: Ue("py-1 gap-[2px] dial-small-text flex justify-between hover:bg-accent-primary-alpha rounded group/item w-full mb-[2px] relative", se),
|
|
60716
60664
|
"aria-selected": k,
|
|
60717
60665
|
children: [
|
|
@@ -60723,21 +60671,21 @@ var JN = 12, YN = 8, XN = ({ getSelectionLabel: e, onClearSelection: t, actions:
|
|
|
60723
60671
|
className: "relative flex flex-row truncate items-center w-fit h-6 gap-x-1 pl-1",
|
|
60724
60672
|
onClick: () => !A && O(e),
|
|
60725
60673
|
children: /* @__PURE__ */ N(Ge, { children: [x && /* @__PURE__ */ M(Ye, {
|
|
60726
|
-
...
|
|
60727
|
-
className: (0,
|
|
60728
|
-
}), /* @__PURE__ */ M(
|
|
60674
|
+
...sP,
|
|
60675
|
+
className: (0, iM.default)("flex-shrink-0", D && "rotate-90 transition-all", re && !E && "text-transparent")
|
|
60676
|
+
}), /* @__PURE__ */ M(fP, {
|
|
60729
60677
|
elementId: `${s}-tree-item`,
|
|
60730
60678
|
name: j ? p : l,
|
|
60731
60679
|
type: x ? oe.Folder : oe.File,
|
|
60732
60680
|
loading: ne,
|
|
60733
60681
|
shared: ie,
|
|
60734
60682
|
sharedIndicatorClassName: Ue("group-hover/item:bg-accent-primary-alpha", k && "bg-accent-primary-alpha"),
|
|
60735
|
-
iconSize:
|
|
60683
|
+
iconSize: OM,
|
|
60736
60684
|
forbiddenSymbolsRegExp: w,
|
|
60737
60685
|
forbiddenSymbolsTooltip: le,
|
|
60738
60686
|
...!j && {
|
|
60739
60687
|
editing: A,
|
|
60740
|
-
creating: s === `${f}/${
|
|
60688
|
+
creating: s === `${f}/${lP}`,
|
|
60741
60689
|
onSave: v,
|
|
60742
60690
|
onCancel: y,
|
|
60743
60691
|
validate: ae,
|
|
@@ -60748,13 +60696,13 @@ var JN = 12, YN = 8, XN = ({ getSelectionLabel: e, onClearSelection: t, actions:
|
|
|
60748
60696
|
}),
|
|
60749
60697
|
ce.length > 0 && !A && !j && /* @__PURE__ */ M("div", {
|
|
60750
60698
|
className: "flex-1 flex justify-end",
|
|
60751
|
-
children: /* @__PURE__ */ M(
|
|
60699
|
+
children: /* @__PURE__ */ M(_e, {
|
|
60752
60700
|
placement: "bottom-start",
|
|
60753
60701
|
allowedPlacements: ["top-start", "top-end"],
|
|
60754
60702
|
items: ce,
|
|
60755
60703
|
className: "sticky right-0",
|
|
60756
|
-
children: /* @__PURE__ */ M(
|
|
60757
|
-
size:
|
|
60704
|
+
children: /* @__PURE__ */ M(Ce, {
|
|
60705
|
+
size: be.Small,
|
|
60758
60706
|
className: "invisible group-hover/item:visible",
|
|
60759
60707
|
icon: /* @__PURE__ */ M(et, { ...h })
|
|
60760
60708
|
})
|
|
@@ -60776,10 +60724,10 @@ var JN = 12, YN = 8, XN = ({ getSelectionLabel: e, onClearSelection: t, actions:
|
|
|
60776
60724
|
icon: l
|
|
60777
60725
|
})
|
|
60778
60726
|
});
|
|
60779
|
-
},
|
|
60727
|
+
}, mP = ({ selectedFiles: e, actionLabels: t, onDuplicate: n, onCopy: r, onMove: i, onDownload: a, onUnshare: o, onRemoveAccess: s, onDelete: c, getCurrentFolderPath: l, sharedWithMeIds: u, sharedByMePaths: d, onClearSelection: p, forbiddenSymbolsRegExp: m }) => f(() => {
|
|
60780
60728
|
let f = [], g = Array.from(e.values());
|
|
60781
60729
|
if (!g.length || !t) return f;
|
|
60782
|
-
let _ =
|
|
60730
|
+
let _ = tN(m), v = _ ? g.some((e) => _.test(e.name)) : !1;
|
|
60783
60731
|
if (t[$.RemoveAccess] && s) {
|
|
60784
60732
|
let e = g.some((e) => !d?.has(e.path));
|
|
60785
60733
|
f.push({
|
|
@@ -60800,7 +60748,7 @@ var JN = 12, YN = 8, XN = ({ getSelectionLabel: e, onClearSelection: t, actions:
|
|
|
60800
60748
|
key: $.Move,
|
|
60801
60749
|
label: t[$.Move],
|
|
60802
60750
|
title: t[$.Move],
|
|
60803
|
-
icon: /* @__PURE__ */ M(
|
|
60751
|
+
icon: /* @__PURE__ */ M(lM, {
|
|
60804
60752
|
width: h.size,
|
|
60805
60753
|
height: h.size,
|
|
60806
60754
|
className: "text-secondary"
|
|
@@ -60810,7 +60758,7 @@ var JN = 12, YN = 8, XN = ({ getSelectionLabel: e, onClearSelection: t, actions:
|
|
|
60810
60758
|
key: $.Copy,
|
|
60811
60759
|
label: t[$.Copy],
|
|
60812
60760
|
title: t[$.Copy],
|
|
60813
|
-
icon: /* @__PURE__ */ M(
|
|
60761
|
+
icon: /* @__PURE__ */ M(cM, {
|
|
60814
60762
|
width: h.size,
|
|
60815
60763
|
height: h.size,
|
|
60816
60764
|
className: "text-secondary"
|
|
@@ -60826,7 +60774,7 @@ var JN = 12, YN = 8, XN = ({ getSelectionLabel: e, onClearSelection: t, actions:
|
|
|
60826
60774
|
}),
|
|
60827
60775
|
onClick: () => n(g)
|
|
60828
60776
|
}), t[$.Delete]) {
|
|
60829
|
-
let e = g.some((e) => e.permissions && !e.permissions.includes(
|
|
60777
|
+
let e = g.some((e) => e.permissions && !e.permissions.includes(zM.WRITE));
|
|
60830
60778
|
f.push({
|
|
60831
60779
|
key: $.Delete,
|
|
60832
60780
|
label: t[$.Delete],
|
|
@@ -60859,7 +60807,7 @@ var JN = 12, YN = 8, XN = ({ getSelectionLabel: e, onClearSelection: t, actions:
|
|
|
60859
60807
|
title: t[$.Unshare],
|
|
60860
60808
|
disabled: e,
|
|
60861
60809
|
tooltip: e ? "Selected items contain item which can not be unshared" : void 0,
|
|
60862
|
-
icon: /* @__PURE__ */ M(
|
|
60810
|
+
icon: /* @__PURE__ */ M(uM, {
|
|
60863
60811
|
width: h.size,
|
|
60864
60812
|
height: h.size,
|
|
60865
60813
|
className: "text-secondary"
|
|
@@ -60885,16 +60833,16 @@ var JN = 12, YN = 8, XN = ({ getSelectionLabel: e, onClearSelection: t, actions:
|
|
|
60885
60833
|
p,
|
|
60886
60834
|
d,
|
|
60887
60835
|
m
|
|
60888
|
-
]),
|
|
60836
|
+
]), hP = ({ id: e, name: t, nodeType: n, size: r, updatedAt: i, dateLocale: a, dateOptions: o, shared: s, sharedIndicatorClassName: c, hideTooltip: l = !1, forbiddenSymbolsRegExp: u, forbiddenSymbolsTooltip: d }) => /* @__PURE__ */ M("div", {
|
|
60889
60837
|
className: "flex",
|
|
60890
60838
|
children: /* @__PURE__ */ M("div", {
|
|
60891
60839
|
className: "flex flex-1 min-w-0",
|
|
60892
|
-
children: /* @__PURE__ */ M(
|
|
60893
|
-
type: n ===
|
|
60840
|
+
children: /* @__PURE__ */ M(fP, {
|
|
60841
|
+
type: n === LM.FOLDER ? oe.Folder : oe.File,
|
|
60894
60842
|
name: t,
|
|
60895
60843
|
elementId: e,
|
|
60896
60844
|
shared: s,
|
|
60897
|
-
iconSize:
|
|
60845
|
+
iconSize: OM,
|
|
60898
60846
|
sharedIndicatorClassName: c,
|
|
60899
60847
|
hideTooltip: l,
|
|
60900
60848
|
forbiddenSymbolsRegExp: u,
|
|
@@ -60902,7 +60850,7 @@ var JN = 12, YN = 8, XN = ({ getSelectionLabel: e, onClearSelection: t, actions:
|
|
|
60902
60850
|
details: /* @__PURE__ */ N("div", {
|
|
60903
60851
|
className: "flex items-center gap-1 dial-tiny-text text-secondary",
|
|
60904
60852
|
children: [
|
|
60905
|
-
/* @__PURE__ */ M("span", { children: n ===
|
|
60853
|
+
/* @__PURE__ */ M("span", { children: n === LM.ITEM ? XM(r) : "" }),
|
|
60906
60854
|
i && r && /* @__PURE__ */ M(Ze, {
|
|
60907
60855
|
size: 2,
|
|
60908
60856
|
className: "text-secondary"
|
|
@@ -60918,15 +60866,15 @@ var JN = 12, YN = 8, XN = ({ getSelectionLabel: e, onClearSelection: t, actions:
|
|
|
60918
60866
|
})
|
|
60919
60867
|
})
|
|
60920
60868
|
})
|
|
60921
|
-
}),
|
|
60922
|
-
colId:
|
|
60869
|
+
}), gP = (e) => (t, n, r) => ({
|
|
60870
|
+
colId: vM.Name,
|
|
60923
60871
|
field: "name",
|
|
60924
60872
|
headerName: e,
|
|
60925
60873
|
flex: 1,
|
|
60926
60874
|
minWidth: 200,
|
|
60927
60875
|
cellRenderer: (e) => {
|
|
60928
60876
|
let i = e.data.nodeType, { saveFolderCreation: a, validateFolderName: o, cancelFolderCreation: s, newFolderTempId: c, sharedByMePaths: l, selectedPaths: u, disabledRowIds: d, filesLoading: f } = e.context, p = l?.has(e.data.path), m = u?.has(e.data.path), h = d?.has(e.data.path) ?? !1, g = Ue(["group-hover/grid-row:bg-accent-primary-alpha", m && "bg-accent-primary-alpha"]);
|
|
60929
|
-
if (e.data?.isTemporary && e.data.id === c) return /* @__PURE__ */ M(
|
|
60877
|
+
if (e.data?.isTemporary && e.data.id === c) return /* @__PURE__ */ M(fP, {
|
|
60930
60878
|
name: e.data.name,
|
|
60931
60879
|
type: oe.Folder,
|
|
60932
60880
|
elementId: `new-folder-${e.data.id}`,
|
|
@@ -60935,31 +60883,31 @@ var JN = 12, YN = 8, XN = ({ getSelectionLabel: e, onClearSelection: t, actions:
|
|
|
60935
60883
|
loading: f,
|
|
60936
60884
|
shared: p,
|
|
60937
60885
|
sharedIndicatorClassName: g,
|
|
60938
|
-
iconSize:
|
|
60886
|
+
iconSize: OM,
|
|
60939
60887
|
validate: o,
|
|
60940
60888
|
onSave: a,
|
|
60941
60889
|
onCancel: s,
|
|
60942
60890
|
onCreateFolderSave: a,
|
|
60943
60891
|
onCreateFolderCancel: s,
|
|
60944
|
-
inputContainerClassName: Ue(["!h-9", r && i ===
|
|
60892
|
+
inputContainerClassName: Ue(["!h-9", r && i === LM.ITEM && "!h-10"])
|
|
60945
60893
|
});
|
|
60946
60894
|
let { renameTriggerView: _, renamedPath: v, renamedItem: y, getDisplayName: b, onRenameValidate: x, onRenameSave: S, onRenameCancel: C } = e.context;
|
|
60947
|
-
if (_ ===
|
|
60895
|
+
if (_ === hM.Grid && v === e.data?.path && y && e.data) return /* @__PURE__ */ M(fP, {
|
|
60948
60896
|
name: b(y),
|
|
60949
|
-
type: i ===
|
|
60897
|
+
type: i === LM.FOLDER ? oe.Folder : oe.File,
|
|
60950
60898
|
fileExtension: y.name.split(".").pop(),
|
|
60951
60899
|
elementId: `rename-${e.data.id}`,
|
|
60952
60900
|
editing: !0,
|
|
60953
60901
|
shared: p,
|
|
60954
60902
|
sharedIndicatorClassName: g,
|
|
60955
|
-
iconSize:
|
|
60903
|
+
iconSize: OM,
|
|
60956
60904
|
validate: (e) => x(e, y),
|
|
60957
60905
|
onSave: S,
|
|
60958
60906
|
onCancel: C,
|
|
60959
|
-
inputContainerClassName: Ue(["!h-9", r && i ===
|
|
60907
|
+
inputContainerClassName: Ue(["!h-9", r && i === LM.ITEM && "!h-10"]),
|
|
60960
60908
|
forbiddenSymbolsRegExp: e.context.forbiddenSymbolsRegExp
|
|
60961
60909
|
});
|
|
60962
|
-
if (r) return /* @__PURE__ */ M(
|
|
60910
|
+
if (r) return /* @__PURE__ */ M(hP, {
|
|
60963
60911
|
id: e.data.id,
|
|
60964
60912
|
name: e.data.name,
|
|
60965
60913
|
nodeType: i,
|
|
@@ -60973,15 +60921,15 @@ var JN = 12, YN = 8, XN = ({ getSelectionLabel: e, onClearSelection: t, actions:
|
|
|
60973
60921
|
forbiddenSymbolsRegExp: e.context.forbiddenSymbolsRegExp,
|
|
60974
60922
|
forbiddenSymbolsTooltip: e.context.forbiddenSymbolsTooltip
|
|
60975
60923
|
});
|
|
60976
|
-
let w =
|
|
60924
|
+
let w = nN({
|
|
60977
60925
|
name: e.data.name,
|
|
60978
|
-
isFolder: i ===
|
|
60926
|
+
isFolder: i === LM.FOLDER
|
|
60979
60927
|
}, e.context.forbiddenSymbolsRegExp, e.context.forbiddenSymbolsTooltip);
|
|
60980
|
-
return i ===
|
|
60928
|
+
return i === LM.FOLDER ? /* @__PURE__ */ M(ie, {
|
|
60981
60929
|
name: e.data.name,
|
|
60982
60930
|
shared: p,
|
|
60983
60931
|
sharedIndicatorClassName: g,
|
|
60984
|
-
iconSize:
|
|
60932
|
+
iconSize: OM,
|
|
60985
60933
|
hideTooltip: h,
|
|
60986
60934
|
isInvalidName: !!w,
|
|
60987
60935
|
tooltipContent: w
|
|
@@ -60989,14 +60937,14 @@ var JN = 12, YN = 8, XN = ({ getSelectionLabel: e, onClearSelection: t, actions:
|
|
|
60989
60937
|
name: e.data.name,
|
|
60990
60938
|
shared: p,
|
|
60991
60939
|
sharedIndicatorClassName: g,
|
|
60992
|
-
iconSize:
|
|
60940
|
+
iconSize: OM,
|
|
60993
60941
|
hideTooltip: h,
|
|
60994
60942
|
isInvalidName: !!w,
|
|
60995
60943
|
tooltipContent: w
|
|
60996
60944
|
});
|
|
60997
60945
|
}
|
|
60998
|
-
}),
|
|
60999
|
-
colId:
|
|
60946
|
+
}), _P = (e) => (t, n) => ({
|
|
60947
|
+
colId: vM.UpdatedAt,
|
|
61000
60948
|
field: "updatedAt",
|
|
61001
60949
|
headerName: e,
|
|
61002
60950
|
width: 168,
|
|
@@ -61016,15 +60964,15 @@ var JN = 12, YN = 8, XN = ({ getSelectionLabel: e, onClearSelection: t, actions:
|
|
|
61016
60964
|
let r = e.data[e.colDef.field || ""], i = Ve(r);
|
|
61017
60965
|
return i ? new Intl.DateTimeFormat(t || w, n || C).format(i) : "";
|
|
61018
60966
|
}
|
|
61019
|
-
}),
|
|
61020
|
-
colId:
|
|
60967
|
+
}), vP = (e) => ({
|
|
60968
|
+
colId: vM.Size,
|
|
61021
60969
|
field: "size",
|
|
61022
60970
|
headerName: e,
|
|
61023
60971
|
width: 120,
|
|
61024
60972
|
suppressSizeToFit: !0,
|
|
61025
|
-
cellRenderer: (e) => e.data.nodeType ===
|
|
61026
|
-
filterValueGetter: (e) => e.data.nodeType ===
|
|
61027
|
-
}),
|
|
60973
|
+
cellRenderer: (e) => e.data.nodeType === LM.ITEM ? XM(e.data.contentLength) : "",
|
|
60974
|
+
filterValueGetter: (e) => e.data.nodeType === LM.ITEM ? XM(e.data.contentLength) : ""
|
|
60975
|
+
}), yP = (e) => {
|
|
61028
60976
|
let t = e.event;
|
|
61029
60977
|
if (!(t?.target ?? null)?.closest("input") || !t) return !1;
|
|
61030
60978
|
switch (t.key) {
|
|
@@ -61037,11 +60985,11 @@ var JN = 12, YN = 8, XN = ({ getSelectionLabel: e, onClearSelection: t, actions:
|
|
|
61037
60985
|
default: return !1;
|
|
61038
60986
|
}
|
|
61039
60987
|
};
|
|
61040
|
-
function
|
|
60988
|
+
function bP({ userColumnDefs: e, filterable: t, dateLocale: n, dateOptions: r, effectiveVisibleColumns: i, isCompactView: a, hasActions: o, actionsColumnDef: s, rootItemLabel: c, rootItemPath: l }) {
|
|
61041
60989
|
let u = f(() => [
|
|
61042
|
-
|
|
60990
|
+
gP("Name")(n, r, a),
|
|
61043
60991
|
{
|
|
61044
|
-
colId:
|
|
60992
|
+
colId: vM.Path,
|
|
61045
60993
|
field: "path",
|
|
61046
60994
|
headerName: "Path",
|
|
61047
60995
|
flex: 1,
|
|
@@ -61057,10 +61005,10 @@ function wP({ userColumnDefs: e, filterable: t, dateLocale: n, dateOptions: r, e
|
|
|
61057
61005
|
});
|
|
61058
61006
|
}
|
|
61059
61007
|
},
|
|
61060
|
-
|
|
61061
|
-
|
|
61008
|
+
_P("Modified Date")(n, r),
|
|
61009
|
+
vP("Size"),
|
|
61062
61010
|
{
|
|
61063
|
-
colId:
|
|
61011
|
+
colId: vM.Author,
|
|
61064
61012
|
field: "author",
|
|
61065
61013
|
headerName: "Author",
|
|
61066
61014
|
width: 200,
|
|
@@ -61068,7 +61016,7 @@ function wP({ userColumnDefs: e, filterable: t, dateLocale: n, dateOptions: r, e
|
|
|
61068
61016
|
cellRenderer: (e) => e.data.author
|
|
61069
61017
|
},
|
|
61070
61018
|
{
|
|
61071
|
-
colId:
|
|
61019
|
+
colId: vM.Owner,
|
|
61072
61020
|
field: "owner",
|
|
61073
61021
|
headerName: "Owner",
|
|
61074
61022
|
width: 200,
|
|
@@ -61085,14 +61033,14 @@ function wP({ userColumnDefs: e, filterable: t, dateLocale: n, dateOptions: r, e
|
|
|
61085
61033
|
return { columnDefs: f(() => {
|
|
61086
61034
|
let c = e?.map((e) => typeof e == "function" ? e(n, r, a) : e), l = c ?? u;
|
|
61087
61035
|
c || (l = l.filter((e) => e.colId && i.includes(e.colId))), o && (a && (l = l.slice(0, 1)), l.push(s));
|
|
61088
|
-
let d = (e) => e.colId ===
|
|
61036
|
+
let d = (e) => e.colId === vM.Name;
|
|
61089
61037
|
return l.map((e) => {
|
|
61090
61038
|
let n = {
|
|
61091
61039
|
...e,
|
|
61092
61040
|
filter: t ? e.filter : !1,
|
|
61093
61041
|
floatingFilter: t ? e.floatingFilter : !1
|
|
61094
61042
|
};
|
|
61095
|
-
return d(e) && !e.suppressKeyboardEvent && (n.suppressKeyboardEvent =
|
|
61043
|
+
return d(e) && !e.suppressKeyboardEvent && (n.suppressKeyboardEvent = yP), n;
|
|
61096
61044
|
});
|
|
61097
61045
|
}, [
|
|
61098
61046
|
s,
|
|
@@ -61106,27 +61054,27 @@ function wP({ userColumnDefs: e, filterable: t, dateLocale: n, dateOptions: r, e
|
|
|
61106
61054
|
e
|
|
61107
61055
|
]) };
|
|
61108
61056
|
}
|
|
61109
|
-
var
|
|
61110
|
-
let e = s(
|
|
61057
|
+
var xP = () => {
|
|
61058
|
+
let e = s(yN);
|
|
61111
61059
|
if (!e) throw Error("useFileManagerContext must be used within <FileManagerProvider>");
|
|
61112
61060
|
return e;
|
|
61113
|
-
},
|
|
61061
|
+
}, SP = ({ actionLabels: e, onDuplicate: t, onCopy: n, onMove: r, onDownload: i, onRename: a, onDelete: o, onInfo: s, onUnshare: c, onRemoveAccess: l, sharedWithMeIds: u, sharedByMePaths: d, onManagePermissions: p, onPreview: m, onOpenInNewTab: g, previewExtensions: _, isRenameFileAvailable: v = !0, isDuplicateFolderAvailable: y = !0, forbiddenSymbolsRegExp: b, onGridCreateSiblingFolder: x, onGridCreateChildFolder: S }) => f(() => (f) => {
|
|
61114
61062
|
let C = [];
|
|
61115
61063
|
if (!e) return C;
|
|
61116
|
-
let w =
|
|
61117
|
-
e[$.AddSibling] && f.nodeType ===
|
|
61064
|
+
let w = tN(b)?.test(f.name);
|
|
61065
|
+
e[$.AddSibling] && f.nodeType === LM.FOLDER && C.push({
|
|
61118
61066
|
key: "addSibling",
|
|
61119
61067
|
label: e[$.AddSibling],
|
|
61120
|
-
icon: /* @__PURE__ */ M(
|
|
61068
|
+
icon: /* @__PURE__ */ M(sM, {
|
|
61121
61069
|
width: h.size,
|
|
61122
61070
|
height: h.size,
|
|
61123
61071
|
className: "text-secondary"
|
|
61124
61072
|
}),
|
|
61125
61073
|
onClick: () => x([f])
|
|
61126
|
-
}), e[$.AddChild] && f.nodeType ===
|
|
61074
|
+
}), e[$.AddChild] && f.nodeType === LM.FOLDER && !w && C.push({
|
|
61127
61075
|
key: "addChild",
|
|
61128
61076
|
label: e[$.AddChild],
|
|
61129
|
-
icon: /* @__PURE__ */ M(
|
|
61077
|
+
icon: /* @__PURE__ */ M(oM, {
|
|
61130
61078
|
width: h.size,
|
|
61131
61079
|
height: h.size,
|
|
61132
61080
|
className: "text-secondary"
|
|
@@ -61134,8 +61082,8 @@ var TP = () => {
|
|
|
61134
61082
|
onClick: () => S([f])
|
|
61135
61083
|
}, {
|
|
61136
61084
|
key: "divider",
|
|
61137
|
-
type:
|
|
61138
|
-
}), e[$.OpenInNewTab] && typeof g == "function" && f.nodeType ===
|
|
61085
|
+
type: ve.Divider
|
|
61086
|
+
}), e[$.OpenInNewTab] && typeof g == "function" && f.nodeType === LM.ITEM && !w && C.push({
|
|
61139
61087
|
key: $.OpenInNewTab,
|
|
61140
61088
|
label: e[$.OpenInNewTab],
|
|
61141
61089
|
icon: /* @__PURE__ */ M(nt, {
|
|
@@ -61144,7 +61092,7 @@ var TP = () => {
|
|
|
61144
61092
|
}),
|
|
61145
61093
|
onClick: () => g?.(f)
|
|
61146
61094
|
});
|
|
61147
|
-
let T = f.nodeType ===
|
|
61095
|
+
let T = f.nodeType === LM.ITEM || f.nodeType === LM.FOLDER && y;
|
|
61148
61096
|
e[$.Duplicate] && T && !w && C.push({
|
|
61149
61097
|
key: $.Duplicate,
|
|
61150
61098
|
label: e[$.Duplicate],
|
|
@@ -61156,7 +61104,7 @@ var TP = () => {
|
|
|
61156
61104
|
}), e[$.Copy] && !w && C.push({
|
|
61157
61105
|
key: $.Copy,
|
|
61158
61106
|
label: e[$.Copy],
|
|
61159
|
-
icon: /* @__PURE__ */ M(
|
|
61107
|
+
icon: /* @__PURE__ */ M(cM, {
|
|
61160
61108
|
width: h.size,
|
|
61161
61109
|
height: h.size,
|
|
61162
61110
|
className: "text-secondary"
|
|
@@ -61165,7 +61113,7 @@ var TP = () => {
|
|
|
61165
61113
|
}), e[$.Move] && !w && C.push({
|
|
61166
61114
|
key: $.Move,
|
|
61167
61115
|
label: e[$.Move],
|
|
61168
|
-
icon: /* @__PURE__ */ M(
|
|
61116
|
+
icon: /* @__PURE__ */ M(lM, {
|
|
61169
61117
|
width: h.size,
|
|
61170
61118
|
height: h.size,
|
|
61171
61119
|
className: "text-secondary"
|
|
@@ -61179,7 +61127,7 @@ var TP = () => {
|
|
|
61179
61127
|
className: "text-secondary"
|
|
61180
61128
|
}),
|
|
61181
61129
|
onClick: () => i(f)
|
|
61182
|
-
}), e[$.ManagePermissions] && typeof p == "function" && f.nodeType ===
|
|
61130
|
+
}), e[$.ManagePermissions] && typeof p == "function" && f.nodeType === LM.FOLDER && !w && C.push({
|
|
61183
61131
|
key: $.ManagePermissions,
|
|
61184
61132
|
label: e[$.ManagePermissions],
|
|
61185
61133
|
icon: /* @__PURE__ */ M(nt, {
|
|
@@ -61189,7 +61137,7 @@ var TP = () => {
|
|
|
61189
61137
|
onClick: () => p?.(f.path)
|
|
61190
61138
|
});
|
|
61191
61139
|
let E = f.name.split("."), ee = E.length > 1 ? E[E.length - 1] : "", D = ee && _?.includes(`.${ee}`);
|
|
61192
|
-
e[$.Preview] && typeof m == "function" && f.nodeType ===
|
|
61140
|
+
e[$.Preview] && typeof m == "function" && f.nodeType === LM.ITEM && D && !w && C.push({
|
|
61193
61141
|
key: $.Preview,
|
|
61194
61142
|
label: e[$.Preview],
|
|
61195
61143
|
icon: /* @__PURE__ */ M(rt, {
|
|
@@ -61198,7 +61146,7 @@ var TP = () => {
|
|
|
61198
61146
|
}),
|
|
61199
61147
|
onClick: () => m?.(f.path)
|
|
61200
61148
|
});
|
|
61201
|
-
let O = !f.permissions || f.permissions.includes(
|
|
61149
|
+
let O = !f.permissions || f.permissions.includes(zM.WRITE);
|
|
61202
61150
|
e[$.Delete] && O && C.push({
|
|
61203
61151
|
key: $.Delete,
|
|
61204
61152
|
label: e[$.Delete],
|
|
@@ -61208,7 +61156,7 @@ var TP = () => {
|
|
|
61208
61156
|
}),
|
|
61209
61157
|
onClick: () => o(f, f.parentPath ?? "")
|
|
61210
61158
|
});
|
|
61211
|
-
let te = f.nodeType ===
|
|
61159
|
+
let te = f.nodeType === LM.FOLDER || f.nodeType === LM.ITEM && v;
|
|
61212
61160
|
return e[$.Rename] && te && O && C.push({
|
|
61213
61161
|
key: $.Rename,
|
|
61214
61162
|
label: e[$.Rename],
|
|
@@ -61217,7 +61165,7 @@ var TP = () => {
|
|
|
61217
61165
|
className: "text-secondary"
|
|
61218
61166
|
}),
|
|
61219
61167
|
onClick: () => a(f.path)
|
|
61220
|
-
}), e[$.Info] && f.nodeType ===
|
|
61168
|
+
}), e[$.Info] && f.nodeType === LM.ITEM && !w && C.push({
|
|
61221
61169
|
key: $.Info,
|
|
61222
61170
|
label: e[$.Info],
|
|
61223
61171
|
icon: /* @__PURE__ */ M(ut, {
|
|
@@ -61228,7 +61176,7 @@ var TP = () => {
|
|
|
61228
61176
|
}), e[$.Unshare] && u?.includes(f.path) && C.push({
|
|
61229
61177
|
key: $.Unshare,
|
|
61230
61178
|
label: e[$.Unshare],
|
|
61231
|
-
icon: /* @__PURE__ */ M(
|
|
61179
|
+
icon: /* @__PURE__ */ M(uM, {
|
|
61232
61180
|
width: h.size,
|
|
61233
61181
|
height: h.size,
|
|
61234
61182
|
className: "text-secondary"
|
|
@@ -61265,28 +61213,28 @@ var TP = () => {
|
|
|
61265
61213
|
b,
|
|
61266
61214
|
S,
|
|
61267
61215
|
x
|
|
61268
|
-
]),
|
|
61269
|
-
let [i, a] = m(
|
|
61216
|
+
]), CP = ({ onGridAddSibling: e, onGridAddChild: t, onTreeAddSibling: n, onTreeAddChild: r }) => {
|
|
61217
|
+
let [i, a] = m(gM.Grid);
|
|
61270
61218
|
return {
|
|
61271
61219
|
createFolderTriggerView: i,
|
|
61272
61220
|
onGridCreateSiblingFolder: o((t) => {
|
|
61273
|
-
e?.(t), a(
|
|
61221
|
+
e?.(t), a(gM.Grid);
|
|
61274
61222
|
}, [e]),
|
|
61275
61223
|
onTreeCreateSiblingFolder: o((e) => {
|
|
61276
|
-
n?.(e), a(
|
|
61224
|
+
n?.(e), a(gM.Tree);
|
|
61277
61225
|
}, [n]),
|
|
61278
61226
|
onGridCreateChildFolder: o((e) => {
|
|
61279
|
-
t?.(e), a(
|
|
61227
|
+
t?.(e), a(gM.Grid);
|
|
61280
61228
|
}, [t]),
|
|
61281
61229
|
onTreeCreateChildFolder: o((e) => {
|
|
61282
|
-
r?.(e), a(
|
|
61230
|
+
r?.(e), a(gM.Tree);
|
|
61283
61231
|
}, [r])
|
|
61284
61232
|
};
|
|
61285
|
-
},
|
|
61233
|
+
}, wP = (e) => /* @__PURE__ */ M(RN, {
|
|
61286
61234
|
...e,
|
|
61287
|
-
children: /* @__PURE__ */ M(
|
|
61288
|
-
}),
|
|
61289
|
-
let { managerLabel: e, className: t, items: n, rootItem: r, filesLoading: i, treeOptions: a, showNavigationPanel: s, navigationPanelOptions: c, gridOptions: l, toolbarOptions: d, bulkActionsToolbarOptions: g, deleteConfirmationOptions: _, destinationFolderPopupOptions: v, conflictResolutionPopupOptions: y, compactViewWidthBreakpoint: b =
|
|
61235
|
+
children: /* @__PURE__ */ M(TP, {})
|
|
61236
|
+
}), TP = () => {
|
|
61237
|
+
let { managerLabel: e, className: t, items: n, rootItem: r, filesLoading: i, treeOptions: a, showNavigationPanel: s, navigationPanelOptions: c, gridOptions: l, toolbarOptions: d, bulkActionsToolbarOptions: g, deleteConfirmationOptions: _, destinationFolderPopupOptions: v, conflictResolutionPopupOptions: y, compactViewWidthBreakpoint: b = FM, customBreakpointRef: x, sharedByMePaths: S, allowedFileTypes: C, maxSelectableFileSize: w, areHiddenFilesVisible: T, toggleHiddenFilesVisibility: E, isTreeCollapsed: ee, toggleTreeCollapse: te, currentPath: k, gridRows: ne, selectedPaths: A, selectedFiles: re, clearSelection: ie, setSelectedPaths: ae, effectiveSearchValue: oe, handleBreadcrumbItemClick: ce, handleSearchChange: le, handleTreeItemClick: ue, handleTableRowClick: de, handleSelectionClick: fe, onGridApiChange: pe, handleOpenDestinationFolderPopup: me, handleCloseDestinationFolderPopup: he, openDestinationFolderPopup: ge, destinationFolderMode: _e, handleSetCopiedFiles: ye, handleSetMovedFiles: be, handleDuplicate: xe, handleCopyTo: Se, handleMoveTo: Ce, handleGridAddSibling: we, handleGridAddChild: Te, handleTreeAddSibling: Ee, handleTreeAddChild: De, handleDownloadFiles: Oe, openDeleteConfirmation: ke, closeDeleteConfirmation: Ae, confirmDelete: je, deleteConfirmationOpen: Me, itemsToDelete: Ne, renamedPath: Pe, renamedItem: Fe, onRename: Ie, onRenameSave: Le, onRenameCancel: Re, onRenameValidate: ze, createdFolderPath: Be, forbiddenSymbolsRegExp: Ve, forbiddenSymbolsTooltip: He, getDisplayName: We, isDragging: Ge, isDraggingOverWindow: Ke, handleDragEnter: qe, handleDragLeave: Je, handleDragOver: Ye, handleDrop: Xe, onUploadFiles: Ze, onValidateUpload: $e, maxFileSize: et, newActions: rt, isNewButtonVisible: it, isNewButtonDisabled: at, newFolderTempId: st, cancelFolderCreation: ct, saveFolderCreation: lt, validateFolderName: ut, startFolderCreation: dt, conflictingFiles: pt, conflictResolutionOpen: mt, handleConflictReplace: _t, handleConflictDuplicate: vt, handleConflictCancel: yt, handleConflictDecideForEach: bt, uploadConflictingFiles: xt, uploadConflictResolutionOpen: St, handleUploadConflictReplace: Ct, handleUploadConflictDuplicate: wt, handleUploadConflictCancel: Tt, handleUploadConflictDecideForEach: Et, openMetadataPopup: Dt, fileMetadataPopupOptions: Ot, isMetadataPopupOpen: kt, selectedFileForMetadata: At, closeMetadataPopup: jt, onUnshareFiles: Mt, onRemoveFilesAccess: Nt, actionsRef: Pt, searchInProgress: Ft, isSearchMode: It, emptyStateIcon: Lt, emptyStateTitle: Rt = "You don't have any files", emptyStateDescription: zt = "Upload or drag and drop files", sharedWithMeIds: Bt, onFolderPopupPathChange: Vt, onManagePermissions: Ht, onPreview: Ut, onOpenInNewTab: Wt, previewExtensions: Gt, isRenameFileAvailable: Kt, isDuplicateFolderAvailable: qt, getDisabledTooltip: Jt, fileTooLargeTooltip: Yt, unsupportedFileTypeTooltip: Xt, gridClassName: Zt, nonClickableTableColumns: Qt, hideSearchPathItemName: $t, showHiddenFileSwitcherInDestinationPopup: en, showCreateFolderButtonInDestinationPopup: tn, newFolderDefaultName: nn } = xP(), { width: rn = EM, header: an = DM, containerClassName: on = CM, additionalButtons: sn, ...cn } = a ?? {}, [ln, un] = m(rn), { renameTriggerView: dn, onGridRename: fn, onTreeRename: pn } = HM({ onRename: Ie }), { createFolderTriggerView: mn, onGridCreateSiblingFolder: hn, onTreeCreateSiblingFolder: gn, onGridCreateChildFolder: _n, onTreeCreateChildFolder: vn } = CP({
|
|
61290
61238
|
onGridAddSibling: we,
|
|
61291
61239
|
onGridAddChild: Te,
|
|
61292
61240
|
onTreeAddSibling: Ee,
|
|
@@ -61295,11 +61243,11 @@ var TP = () => {
|
|
|
61295
61243
|
yn.current === null && (yn.current = requestAnimationFrame(() => {
|
|
61296
61244
|
un(e), yn.current = null;
|
|
61297
61245
|
}));
|
|
61298
|
-
}, { columnDefs: xn, filterable: Sn = !0, dateLocale: Cn, dateOptions: wn, selectionMode: Tn, wrapCustomCellRenderers: En, visibleColumns: Dn =
|
|
61299
|
-
|
|
61300
|
-
|
|
61301
|
-
|
|
61302
|
-
] : Dn, [It, Dn]), Nn = o((e, t, n) =>
|
|
61246
|
+
}, { columnDefs: xn, filterable: Sn = !0, dateLocale: Cn, dateOptions: wn, selectionMode: Tn, wrapCustomCellRenderers: En, visibleColumns: Dn = IM, allowDisabledContextMenu: On = !1, ...kn } = l ?? {}, { containerRef: An, isBelowBreakpoint: jn } = UM(b, x), Mn = f(() => It ? [
|
|
61247
|
+
vM.Name,
|
|
61248
|
+
vM.Path,
|
|
61249
|
+
vM.Actions
|
|
61250
|
+
] : Dn, [It, Dn]), Nn = o((e, t, n) => aN(e, t, n, Xt, Yt), [Yt, Xt]), Pn = o((e, t, n) => !!Jt?.(e) || !!Nn(e, t, n), [Nn, Jt]), Fn = f(() => {
|
|
61303
61251
|
let e = /* @__PURE__ */ new Set();
|
|
61304
61252
|
for (let t of ne) Pn(t, C, w) && e.add(t.path);
|
|
61305
61253
|
return e;
|
|
@@ -61310,19 +61258,19 @@ var TP = () => {
|
|
|
61310
61258
|
Pn
|
|
61311
61259
|
]), In = o((e) => {
|
|
61312
61260
|
let t = [], n = [], r = !e.parentPath, i = Ve?.test(e.name);
|
|
61313
|
-
return a?.actionLabels && (a.actionLabels[$.AddSibling] && e.nodeType ===
|
|
61261
|
+
return a?.actionLabels && (a.actionLabels[$.AddSibling] && e.nodeType === LM.FOLDER && !r && t.push({
|
|
61314
61262
|
key: "addSibling",
|
|
61315
61263
|
label: a.actionLabels[$.AddSibling],
|
|
61316
|
-
icon: /* @__PURE__ */ M(
|
|
61264
|
+
icon: /* @__PURE__ */ M(sM, {
|
|
61317
61265
|
width: h.size,
|
|
61318
61266
|
height: h.size,
|
|
61319
61267
|
className: "text-secondary"
|
|
61320
61268
|
}),
|
|
61321
61269
|
onClick: () => gn([e])
|
|
61322
|
-
}), a.actionLabels[$.AddChild] && e.nodeType ===
|
|
61270
|
+
}), a.actionLabels[$.AddChild] && e.nodeType === LM.FOLDER && !i && t.push({
|
|
61323
61271
|
key: "addChild",
|
|
61324
61272
|
label: a.actionLabels[$.AddChild],
|
|
61325
|
-
icon: /* @__PURE__ */ M(
|
|
61273
|
+
icon: /* @__PURE__ */ M(oM, {
|
|
61326
61274
|
width: h.size,
|
|
61327
61275
|
height: h.size,
|
|
61328
61276
|
className: "text-secondary"
|
|
@@ -61337,26 +61285,26 @@ var TP = () => {
|
|
|
61337
61285
|
}),
|
|
61338
61286
|
onClick: () => xe([e])
|
|
61339
61287
|
}), a.actionLabels[$.Copy] && !r && !i && n.push({
|
|
61340
|
-
key:
|
|
61288
|
+
key: mM.Copy,
|
|
61341
61289
|
label: a.actionLabels[$.Copy],
|
|
61342
|
-
icon: /* @__PURE__ */ M(
|
|
61290
|
+
icon: /* @__PURE__ */ M(cM, {
|
|
61343
61291
|
width: h.size,
|
|
61344
61292
|
height: h.size,
|
|
61345
61293
|
className: "text-secondary"
|
|
61346
61294
|
}),
|
|
61347
61295
|
onClick: () => {
|
|
61348
|
-
|
|
61296
|
+
ye([e]), me(mM.Copy);
|
|
61349
61297
|
}
|
|
61350
61298
|
}), a.actionLabels[$.Move] && !r && !i && n.push({
|
|
61351
|
-
key:
|
|
61299
|
+
key: mM.Move,
|
|
61352
61300
|
label: a.actionLabels[$.Move],
|
|
61353
|
-
icon: /* @__PURE__ */ M(
|
|
61301
|
+
icon: /* @__PURE__ */ M(lM, {
|
|
61354
61302
|
width: h.size,
|
|
61355
61303
|
height: h.size,
|
|
61356
61304
|
className: "text-secondary"
|
|
61357
61305
|
}),
|
|
61358
61306
|
onClick: () => {
|
|
61359
|
-
|
|
61307
|
+
be([e]), me(mM.Move);
|
|
61360
61308
|
}
|
|
61361
61309
|
}), a.actionLabels[$.Download] && !r && !i && n.push({
|
|
61362
61310
|
key: "download",
|
|
@@ -61366,7 +61314,7 @@ var TP = () => {
|
|
|
61366
61314
|
className: "text-secondary"
|
|
61367
61315
|
}),
|
|
61368
61316
|
onClick: () => Oe([e])
|
|
61369
|
-
}), a.actionLabels[$.ManagePermissions] && typeof Ht == "function" && e.nodeType ===
|
|
61317
|
+
}), a.actionLabels[$.ManagePermissions] && typeof Ht == "function" && e.nodeType === LM.FOLDER && !r && n.push({
|
|
61370
61318
|
key: $.ManagePermissions,
|
|
61371
61319
|
label: a.actionLabels[$.ManagePermissions],
|
|
61372
61320
|
icon: /* @__PURE__ */ M(nt, {
|
|
@@ -61374,7 +61322,7 @@ var TP = () => {
|
|
|
61374
61322
|
className: "text-secondary"
|
|
61375
61323
|
}),
|
|
61376
61324
|
onClick: () => Ht?.(e.path)
|
|
61377
|
-
}), a.actionLabels[$.Delete] && e.permissions?.includes(
|
|
61325
|
+
}), a.actionLabels[$.Delete] && e.permissions?.includes(zM.WRITE) && !r && n.push({
|
|
61378
61326
|
key: "delete",
|
|
61379
61327
|
label: a.actionLabels[$.Delete],
|
|
61380
61328
|
icon: /* @__PURE__ */ M(ht, {
|
|
@@ -61393,7 +61341,7 @@ var TP = () => {
|
|
|
61393
61341
|
}), a.actionLabels[$.Unshare] && Bt?.includes(e.path) && !r && n.push({
|
|
61394
61342
|
key: "unshare",
|
|
61395
61343
|
label: a.actionLabels[$.Unshare],
|
|
61396
|
-
icon: /* @__PURE__ */ M(
|
|
61344
|
+
icon: /* @__PURE__ */ M(uM, {
|
|
61397
61345
|
width: h.size,
|
|
61398
61346
|
height: h.size,
|
|
61399
61347
|
className: "text-secondary"
|
|
@@ -61411,7 +61359,7 @@ var TP = () => {
|
|
|
61411
61359
|
...t,
|
|
61412
61360
|
{
|
|
61413
61361
|
key: "divider",
|
|
61414
|
-
type:
|
|
61362
|
+
type: ve.Divider
|
|
61415
61363
|
},
|
|
61416
61364
|
...n
|
|
61417
61365
|
] : n;
|
|
@@ -61420,9 +61368,9 @@ var TP = () => {
|
|
|
61420
61368
|
Ve,
|
|
61421
61369
|
Ht,
|
|
61422
61370
|
xe,
|
|
61423
|
-
ve,
|
|
61424
|
-
me,
|
|
61425
61371
|
ye,
|
|
61372
|
+
me,
|
|
61373
|
+
be,
|
|
61426
61374
|
Oe,
|
|
61427
61375
|
pn,
|
|
61428
61376
|
Mt,
|
|
@@ -61437,15 +61385,15 @@ var TP = () => {
|
|
|
61437
61385
|
return re.forEach((t, n) => e.add(n)), e;
|
|
61438
61386
|
}, [re]), Rn = o((e, t) => {
|
|
61439
61387
|
ae(e), fe?.(t);
|
|
61440
|
-
}, [fe, ae]), zn =
|
|
61388
|
+
}, [fe, ae]), zn = mP({
|
|
61441
61389
|
selectedFiles: re,
|
|
61442
61390
|
actionLabels: g?.actionLabels,
|
|
61443
61391
|
onDuplicate: xe,
|
|
61444
61392
|
onCopy: (e) => {
|
|
61445
|
-
|
|
61393
|
+
ye(e), me(mM.Copy);
|
|
61446
61394
|
},
|
|
61447
61395
|
onMove: (e) => {
|
|
61448
|
-
|
|
61396
|
+
be(e), me(mM.Move);
|
|
61449
61397
|
},
|
|
61450
61398
|
onDownload: Oe,
|
|
61451
61399
|
onDelete: ke,
|
|
@@ -61459,10 +61407,10 @@ var TP = () => {
|
|
|
61459
61407
|
}), Bn = o((e) => {
|
|
61460
61408
|
d?.onTabChange?.(e), ct();
|
|
61461
61409
|
}, [d, ct]), Vn = o(() => d && A.size === 0 ? /* @__PURE__ */ N("div", {
|
|
61462
|
-
className:
|
|
61410
|
+
className: bM,
|
|
61463
61411
|
role: "toolbar",
|
|
61464
61412
|
"aria-label": "File Manager Toolbar",
|
|
61465
|
-
children: [e, /* @__PURE__ */ M(
|
|
61413
|
+
children: [e, /* @__PURE__ */ M($N, {
|
|
61466
61414
|
...d,
|
|
61467
61415
|
onTabChange: Bn,
|
|
61468
61416
|
areHiddenFilesVisible: T,
|
|
@@ -61472,10 +61420,10 @@ var TP = () => {
|
|
|
61472
61420
|
newButtonDropdownItems: rt
|
|
61473
61421
|
})]
|
|
61474
61422
|
}) : A.size > 0 && g ? /* @__PURE__ */ M("div", {
|
|
61475
|
-
className:
|
|
61423
|
+
className: bM,
|
|
61476
61424
|
role: "toolbar",
|
|
61477
61425
|
"aria-label": "File Manager Toolbar",
|
|
61478
|
-
children: /* @__PURE__ */ M(
|
|
61426
|
+
children: /* @__PURE__ */ M(KN, {
|
|
61479
61427
|
...g,
|
|
61480
61428
|
selectedCount: A.size,
|
|
61481
61429
|
onClearSelection: ie,
|
|
@@ -61505,8 +61453,8 @@ var TP = () => {
|
|
|
61505
61453
|
width: ln,
|
|
61506
61454
|
onResizeStop: un,
|
|
61507
61455
|
onResize: bn,
|
|
61508
|
-
minWidth:
|
|
61509
|
-
maxWidth:
|
|
61456
|
+
minWidth: MM,
|
|
61457
|
+
maxWidth: NM,
|
|
61510
61458
|
enabled: !ee,
|
|
61511
61459
|
children: /* @__PURE__ */ M(D, {
|
|
61512
61460
|
width: ln,
|
|
@@ -61516,7 +61464,7 @@ var TP = () => {
|
|
|
61516
61464
|
additionalButtons: sn,
|
|
61517
61465
|
isOpened: !ee,
|
|
61518
61466
|
onToggle: te,
|
|
61519
|
-
children: /* @__PURE__ */ M(
|
|
61467
|
+
children: /* @__PURE__ */ M(pP, {
|
|
61520
61468
|
...cn,
|
|
61521
61469
|
items: n,
|
|
61522
61470
|
rootItemPath: r?.path,
|
|
@@ -61528,11 +61476,11 @@ var TP = () => {
|
|
|
61528
61476
|
onItemClick: ue,
|
|
61529
61477
|
areHiddenFilesVisible: T,
|
|
61530
61478
|
getContextMenuItems: In,
|
|
61531
|
-
renamedPath: dn ===
|
|
61479
|
+
renamedPath: dn === hM.Tree ? Pe : void 0,
|
|
61532
61480
|
onRenameSave: Le,
|
|
61533
61481
|
onRenameCancel: Re,
|
|
61534
61482
|
onRenameValidate: ze,
|
|
61535
|
-
createdFolderPath: mn ===
|
|
61483
|
+
createdFolderPath: mn === gM.Tree ? Be : null,
|
|
61536
61484
|
onCreateFolderCancel: ct,
|
|
61537
61485
|
onCreateFolderSave: lt,
|
|
61538
61486
|
newFolderDefaultName: nn
|
|
@@ -61568,14 +61516,14 @@ var TP = () => {
|
|
|
61568
61516
|
ct,
|
|
61569
61517
|
lt,
|
|
61570
61518
|
nn
|
|
61571
|
-
]), Un =
|
|
61519
|
+
]), Un = SP({
|
|
61572
61520
|
actionLabels: l?.actionLabels,
|
|
61573
61521
|
onDuplicate: (e) => xe([e]),
|
|
61574
61522
|
onCopy: (e) => {
|
|
61575
|
-
|
|
61523
|
+
ye([e]), me(mM.Copy);
|
|
61576
61524
|
},
|
|
61577
61525
|
onMove: (e) => {
|
|
61578
|
-
|
|
61526
|
+
be([e]), me(mM.Move);
|
|
61579
61527
|
},
|
|
61580
61528
|
onDownload: (e) => Oe([e]),
|
|
61581
61529
|
onRename: fn,
|
|
@@ -61595,14 +61543,14 @@ var TP = () => {
|
|
|
61595
61543
|
onGridCreateSiblingFolder: hn,
|
|
61596
61544
|
onGridCreateChildFolder: _n
|
|
61597
61545
|
}), Wn = o((e) => {
|
|
61598
|
-
let t =
|
|
61546
|
+
let t = WM(n, e.path);
|
|
61599
61547
|
return t ? Un(t) : [];
|
|
61600
|
-
}, [n, Un]), { actionsColumnDef: Gn } =
|
|
61548
|
+
}, [n, Un]), { actionsColumnDef: Gn } = VM({
|
|
61601
61549
|
getContextMenuItems: Wn,
|
|
61602
61550
|
isRowDisabled: o((e, t, n) => On ? !1 : Pn(e, t, n), [On, Pn]),
|
|
61603
61551
|
allowedFileTypes: C,
|
|
61604
|
-
buttonClassName: jn ? "" :
|
|
61605
|
-
}), { columnDefs: Kn } =
|
|
61552
|
+
buttonClassName: jn ? "" : TM
|
|
61553
|
+
}), { columnDefs: Kn } = bP({
|
|
61606
61554
|
userColumnDefs: xn,
|
|
61607
61555
|
filterable: Sn,
|
|
61608
61556
|
dateLocale: Cn,
|
|
@@ -61614,7 +61562,7 @@ var TP = () => {
|
|
|
61614
61562
|
rootItemLabel: r?.label,
|
|
61615
61563
|
rootItemPath: r?.path
|
|
61616
61564
|
}), qn = o((e) => {
|
|
61617
|
-
e.colDef.colId === "ag-Grid-SelectionColumn" || e.colDef.colId ===
|
|
61565
|
+
e.colDef.colId === "ag-Grid-SelectionColumn" || e.colDef.colId === vM.Actions || Pe && e.data?.path === Pe || e.data?.isTemporary || Qt && Qt.includes(e.colDef.colId) || e.data && de(e.data);
|
|
61618
61566
|
}, [
|
|
61619
61567
|
Pe,
|
|
61620
61568
|
de,
|
|
@@ -61634,11 +61582,11 @@ var TP = () => {
|
|
|
61634
61582
|
zt,
|
|
61635
61583
|
Lt,
|
|
61636
61584
|
Rt
|
|
61637
|
-
]), Yn = f(() => (e) => e.path, []), Xn = f(() => (0,
|
|
61585
|
+
]), Yn = f(() => (e) => e.path, []), Xn = f(() => (0, iM.default)("min-h-[248px] overflow-auto md:min-h-[266px]", Ge ? "border border-dashed border-info" : "", Ke && !Ge ? "border border-dashed border-primary" : ""), [Ge, Ke]), Zn = f(() => ({
|
|
61638
61586
|
...kn.additionalGridOptions,
|
|
61639
61587
|
onCellClicked: qn,
|
|
61640
|
-
headerHeight:
|
|
61641
|
-
rowHeight:
|
|
61588
|
+
headerHeight: PM,
|
|
61589
|
+
rowHeight: PM,
|
|
61642
61590
|
rowClass: "group/grid-row",
|
|
61643
61591
|
defaultColDef: {
|
|
61644
61592
|
...kn.additionalGridOptions?.defaultColDef,
|
|
@@ -61735,7 +61683,7 @@ var TP = () => {
|
|
|
61735
61683
|
ref: An,
|
|
61736
61684
|
className: "size-full",
|
|
61737
61685
|
children: /* @__PURE__ */ N("div", {
|
|
61738
|
-
className: Ue(
|
|
61686
|
+
className: Ue(yM, {
|
|
61739
61687
|
"gap-3 pt-4": g && A.size > 0,
|
|
61740
61688
|
"gap-4 p-3 pt-4": jn,
|
|
61741
61689
|
"gap-2 pt-2": jn && g && A.size > 0
|
|
@@ -61743,10 +61691,10 @@ var TP = () => {
|
|
|
61743
61691
|
children: [
|
|
61744
61692
|
Vn(),
|
|
61745
61693
|
/* @__PURE__ */ N("div", {
|
|
61746
|
-
className: Ue(
|
|
61694
|
+
className: Ue(xM, Zt),
|
|
61747
61695
|
children: [Hn(), /* @__PURE__ */ N("div", {
|
|
61748
|
-
className: Ue(
|
|
61749
|
-
children: [s && /* @__PURE__ */ M(
|
|
61696
|
+
className: Ue(SM, { "gap-3": jn }),
|
|
61697
|
+
children: [s && /* @__PURE__ */ M(QN, {
|
|
61750
61698
|
...c ?? {},
|
|
61751
61699
|
makeHref: (e) => e.join("/"),
|
|
61752
61700
|
path: k,
|
|
@@ -61760,12 +61708,12 @@ var TP = () => {
|
|
|
61760
61708
|
}), /* @__PURE__ */ N("section", {
|
|
61761
61709
|
role: "region",
|
|
61762
61710
|
"aria-label": "File Manager Grid View",
|
|
61763
|
-
className: Ue(
|
|
61711
|
+
className: Ue(wM, "relative"),
|
|
61764
61712
|
onDragEnter: qe,
|
|
61765
61713
|
onDragLeave: Je,
|
|
61766
61714
|
onDragOver: Ye,
|
|
61767
61715
|
onDrop: Xe,
|
|
61768
|
-
children: [Qn, /* @__PURE__ */ M(
|
|
61716
|
+
children: [Qn, /* @__PURE__ */ M(zN, {
|
|
61769
61717
|
disabledGridRowIds: Fn,
|
|
61770
61718
|
gridRows: ne,
|
|
61771
61719
|
getDisabledTooltip: Jt,
|
|
@@ -61776,26 +61724,26 @@ var TP = () => {
|
|
|
61776
61724
|
})]
|
|
61777
61725
|
})]
|
|
61778
61726
|
}),
|
|
61779
|
-
/* @__PURE__ */ M(
|
|
61727
|
+
/* @__PURE__ */ M(qN, {
|
|
61780
61728
|
..._,
|
|
61781
61729
|
open: Me,
|
|
61782
61730
|
itemsToDelete: Ne,
|
|
61783
61731
|
onClose: Ae,
|
|
61784
61732
|
onConfirm: je
|
|
61785
61733
|
}),
|
|
61786
|
-
/* @__PURE__ */ M(
|
|
61734
|
+
/* @__PURE__ */ M(HN, {
|
|
61787
61735
|
...v,
|
|
61788
61736
|
open: ge,
|
|
61789
61737
|
onClose: he,
|
|
61790
61738
|
onConfirm: () => {
|
|
61791
61739
|
let e = v?.destinationFolderPath ?? "/";
|
|
61792
|
-
_e ===
|
|
61740
|
+
_e === mM.Copy ? Se(e) : Ce(e), he();
|
|
61793
61741
|
},
|
|
61794
61742
|
mode: _e,
|
|
61795
61743
|
items: n,
|
|
61796
61744
|
rootItem: r,
|
|
61797
61745
|
gridOptions: {
|
|
61798
|
-
columnDefs: Kn.filter((e) => e.colId !==
|
|
61746
|
+
columnDefs: Kn.filter((e) => e.colId !== vM.Actions),
|
|
61799
61747
|
loading: i
|
|
61800
61748
|
},
|
|
61801
61749
|
onUploadFiles: Ze,
|
|
@@ -61812,7 +61760,7 @@ var TP = () => {
|
|
|
61812
61760
|
showCreateFolderButton: tn,
|
|
61813
61761
|
hideSearchPathItemName: $t
|
|
61814
61762
|
}),
|
|
61815
|
-
/* @__PURE__ */ M(
|
|
61763
|
+
/* @__PURE__ */ M(BM, {
|
|
61816
61764
|
...y,
|
|
61817
61765
|
open: mt,
|
|
61818
61766
|
onClose: yt,
|
|
@@ -61821,7 +61769,7 @@ var TP = () => {
|
|
|
61821
61769
|
onDecideForEach: bt,
|
|
61822
61770
|
conflictingFiles: pt
|
|
61823
61771
|
}),
|
|
61824
|
-
/* @__PURE__ */ M(
|
|
61772
|
+
/* @__PURE__ */ M(BM, {
|
|
61825
61773
|
...y,
|
|
61826
61774
|
open: St,
|
|
61827
61775
|
onClose: Tt,
|
|
@@ -61830,7 +61778,7 @@ var TP = () => {
|
|
|
61830
61778
|
onDecideForEach: Et,
|
|
61831
61779
|
conflictingFiles: xt
|
|
61832
61780
|
}),
|
|
61833
|
-
/* @__PURE__ */ M(
|
|
61781
|
+
/* @__PURE__ */ M(oP, {
|
|
61834
61782
|
open: kt,
|
|
61835
61783
|
onClose: jt,
|
|
61836
61784
|
fileMetadata: Ot?.fileMetadata ?? At,
|
|
@@ -61847,7 +61795,7 @@ var TP = () => {
|
|
|
61847
61795
|
]
|
|
61848
61796
|
})
|
|
61849
61797
|
});
|
|
61850
|
-
},
|
|
61798
|
+
}, EP = ({ items: e, selectedPath: t, onSelectedPathChange: n, onCreateFolder: r, searchQuery: i, disabled: a = !1, createFolderLabel: o = "Create new folder", addSiblingFolderLabel: s = "Add sibling", addChildFolderLabel: c = "Add child", newFolderDefaultName: l = "New folder", noResultsLabel: u = "No folders match \"{query}\".", emptyFolderNameError: d = "Folder name cannot be empty.", invalidFolderNameError: h = "Folder name contains invalid characters.", duplicateFolderNameError: g = "A folder with this name already exists.", rootLabel: _ = "Organization", expandedPaths: v, onExpandedPathsChange: y, loadingPaths: b }) => {
|
|
61851
61799
|
let [x, S] = m(() => new Set(t?.map((e, n) => Kt(t.slice(0, n + 1))) ?? [])), C = v ?? x, w = (e) => {
|
|
61852
61800
|
let t = new Set(e);
|
|
61853
61801
|
t.delete(""), y ? y(t) : S(t);
|
|
@@ -61863,7 +61811,7 @@ var TP = () => {
|
|
|
61863
61811
|
path: "",
|
|
61864
61812
|
name: _,
|
|
61865
61813
|
folderId: "",
|
|
61866
|
-
nodeType:
|
|
61814
|
+
nodeType: LM.FOLDER,
|
|
61867
61815
|
items: se
|
|
61868
61816
|
}], [
|
|
61869
61817
|
se,
|
|
@@ -61903,7 +61851,7 @@ var TP = () => {
|
|
|
61903
61851
|
};
|
|
61904
61852
|
return /* @__PURE__ */ N("div", {
|
|
61905
61853
|
className: Br(a && "pointer-events-none opacity-60"),
|
|
61906
|
-
children: [/* @__PURE__ */ M(
|
|
61854
|
+
children: [/* @__PURE__ */ M(pP, {
|
|
61907
61855
|
items: ce,
|
|
61908
61856
|
showFiles: !1,
|
|
61909
61857
|
selectedPath: t == null ? void 0 : Kt(t),
|
|
@@ -61924,7 +61872,7 @@ var TP = () => {
|
|
|
61924
61872
|
onCreateFolderCancel: () => ee(null),
|
|
61925
61873
|
onRenameValidate: (e) => he(e),
|
|
61926
61874
|
emptyStateTitle: ie ? u.replace("{query}", k) : void 0
|
|
61927
|
-
}), /* @__PURE__ */ M(
|
|
61875
|
+
}), /* @__PURE__ */ M(Ee, {
|
|
61928
61876
|
onClick: pe,
|
|
61929
61877
|
label: o,
|
|
61930
61878
|
iconBefore: /* @__PURE__ */ M(pt, {
|
|
@@ -61934,7 +61882,7 @@ var TP = () => {
|
|
|
61934
61882
|
disabled: a
|
|
61935
61883
|
})]
|
|
61936
61884
|
});
|
|
61937
|
-
},
|
|
61885
|
+
}, DP = {
|
|
61938
61886
|
wrapper: "_wrapper_1t670_1",
|
|
61939
61887
|
header: "_header_1t670_6",
|
|
61940
61888
|
appear: "_appear_1t670_18",
|
|
@@ -61942,7 +61890,7 @@ var TP = () => {
|
|
|
61942
61890
|
resizeHandler: "_resizeHandler_1t670_22"
|
|
61943
61891
|
};
|
|
61944
61892
|
a(({ title: e, titleClassName: t = "dial-h1-text", leftActions: n, className: r, rightActions: i }) => /* @__PURE__ */ N("div", {
|
|
61945
|
-
className: Br("flex h-12 items-center px-4", r,
|
|
61893
|
+
className: Br("flex h-12 items-center px-4", r, DP.header),
|
|
61946
61894
|
children: [
|
|
61947
61895
|
n && /* @__PURE__ */ M("div", {
|
|
61948
61896
|
className: "flex items-center gap-1",
|
|
@@ -61958,12 +61906,59 @@ a(({ title: e, titleClassName: t = "dial-h1-text", leftActions: n, className: r,
|
|
|
61958
61906
|
})
|
|
61959
61907
|
]
|
|
61960
61908
|
}));
|
|
61961
|
-
var
|
|
61962
|
-
|
|
61909
|
+
var OP = {
|
|
61910
|
+
container: "_container_1kcxu_2",
|
|
61911
|
+
icon: "_icon_1kcxu_25",
|
|
61912
|
+
input: "_input_1kcxu_29"
|
|
61913
|
+
}, kP = ({ value: e, onChange: t, labels: n, iconSize: r = T.MD, iconStrokeWidth: i, styles: a }) => {
|
|
61914
|
+
let { placeholder: o = "Search", ariaLabel: s, clearLabel: c = "Clear search" } = n ?? {}, { colors: l, containerClassName: u, iconClassName: d, inputClassName: f, inputTextClassName: p = "dial-small-text", clearButtonClassName: m } = a ?? {}, h = s ?? o;
|
|
61915
|
+
return /* @__PURE__ */ M("div", {
|
|
61916
|
+
role: "search",
|
|
61917
|
+
style: Vr({
|
|
61918
|
+
"--search-bar-bg": l?.background,
|
|
61919
|
+
"--search-bar-border-focus": l?.borderFocus,
|
|
61920
|
+
"--search-bar-icon": l?.icon,
|
|
61921
|
+
"--search-bar-text": l?.text,
|
|
61922
|
+
"--search-bar-placeholder": l?.placeholder
|
|
61923
|
+
}),
|
|
61924
|
+
children: /* @__PURE__ */ N("div", {
|
|
61925
|
+
className: Br(OP.container, "flex cursor-text items-center gap-3 rounded-xl border px-4 py-2 transition-[border-color,box-shadow] duration-150 ease-in-out", u),
|
|
61926
|
+
children: [
|
|
61927
|
+
/* @__PURE__ */ M(mt, {
|
|
61928
|
+
size: r,
|
|
61929
|
+
stroke: i,
|
|
61930
|
+
className: Br(OP.icon, "shrink-0 transition-colors duration-150 ease-in-out", d),
|
|
61931
|
+
"aria-hidden": !0
|
|
61932
|
+
}),
|
|
61933
|
+
/* @__PURE__ */ M("input", {
|
|
61934
|
+
type: "text",
|
|
61935
|
+
className: Br(OP.input, "min-w-0 flex-1 border-0 p-0 outline-none", p, f),
|
|
61936
|
+
value: e,
|
|
61937
|
+
placeholder: o,
|
|
61938
|
+
"aria-label": h,
|
|
61939
|
+
onChange: (e) => t(e.target.value)
|
|
61940
|
+
}),
|
|
61941
|
+
e && /* @__PURE__ */ M("button", {
|
|
61942
|
+
type: "button",
|
|
61943
|
+
onClick: () => t(""),
|
|
61944
|
+
"aria-label": c,
|
|
61945
|
+
className: Br("flex shrink-0 items-center justify-center", m),
|
|
61946
|
+
children: /* @__PURE__ */ M(_t, {
|
|
61947
|
+
size: r,
|
|
61948
|
+
stroke: i,
|
|
61949
|
+
className: Br(OP.icon, d),
|
|
61950
|
+
"aria-hidden": !0
|
|
61951
|
+
})
|
|
61952
|
+
})
|
|
61953
|
+
]
|
|
61954
|
+
})
|
|
61955
|
+
});
|
|
61956
|
+
}, AP = { icon: "_icon_nu4hc_1" }, jP = a(({ value: e, onChange: t, labels: n, styles: r }) => {
|
|
61957
|
+
let { colors: i, iconClassName: a = AP.icon, wrapperClassName: o, rowClassName: s } = r ?? {}, c = f(() => Vr({ "--si-icon": i?.icon }), [i]);
|
|
61963
61958
|
return /* @__PURE__ */ M("div", {
|
|
61964
61959
|
className: Br("px-3 py-2", o),
|
|
61965
61960
|
style: c,
|
|
61966
|
-
children: /* @__PURE__ */ M(
|
|
61961
|
+
children: /* @__PURE__ */ M(kP, {
|
|
61967
61962
|
value: e,
|
|
61968
61963
|
onChange: t,
|
|
61969
61964
|
labels: {
|
|
@@ -61996,11 +61991,11 @@ a(({ label: e, icon: t = dt, iconSize: n = 48 }) => /* @__PURE__ */ M(Ph, {
|
|
|
61996
61991
|
}),
|
|
61997
61992
|
label: e
|
|
61998
61993
|
}));
|
|
61999
|
-
var
|
|
61994
|
+
var MP = {
|
|
62000
61995
|
summaryRow: "_summaryRow_1xcyd_1",
|
|
62001
61996
|
summaryTitle: "_summaryTitle_1xcyd_6",
|
|
62002
61997
|
sectionHeading: "_sectionHeading_1xcyd_10"
|
|
62003
|
-
},
|
|
61998
|
+
}, NP = ({ resource: e, renderSummary: t, history: n, isHistoryLoading: r = !1, hasHistoryError: i = !1, folderItems: a, selectedFolderPath: o, onSelectedFolderPathChange: s, onCreateFolder: c, expandedPaths: l, onExpandedPathsChange: u, loadingPaths: d, hasExistingPublicationInFolder: p, hasWriteAccess: h, isSubmitting: g, hasSubmitError: _ = !1, allowReplace: v = !0, rules: y, onRulesChange: b, ruleSourceOptions: x, isRulesLoading: S = !1, hasRulesLoadError: C = !1, labels: w = {}, summaryTitleClassName: T = "dial-body-semi-text", headingClassName: E = "dial-body-semi-text", colors: ee }) => {
|
|
62004
61999
|
let D = Vr({
|
|
62005
62000
|
"--pp-summary-border": ee?.summaryBorder,
|
|
62006
62001
|
"--pp-summary-bg": ee?.summaryBackground,
|
|
@@ -62034,20 +62029,20 @@ var PP = {
|
|
|
62034
62029
|
children: [
|
|
62035
62030
|
/* @__PURE__ */ M("div", {
|
|
62036
62031
|
style: D,
|
|
62037
|
-
className: Br("flex items-center justify-between gap-3 rounded-xl border px-3.5 py-3",
|
|
62032
|
+
className: Br("flex items-center justify-between gap-3 rounded-xl border px-3.5 py-3", MP.summaryRow),
|
|
62038
62033
|
children: t ? t() : /* @__PURE__ */ M("span", {
|
|
62039
|
-
className: Br("truncate", T,
|
|
62034
|
+
className: Br("truncate", T, MP.summaryTitle),
|
|
62040
62035
|
children: e?.title
|
|
62041
62036
|
})
|
|
62042
62037
|
}),
|
|
62043
62038
|
/* @__PURE__ */ N("div", { children: [
|
|
62044
62039
|
/* @__PURE__ */ M("div", {
|
|
62045
|
-
className: Br("mb-2", E,
|
|
62040
|
+
className: Br("mb-2", E, MP.sectionHeading),
|
|
62046
62041
|
children: O
|
|
62047
62042
|
}),
|
|
62048
62043
|
/* @__PURE__ */ M("div", {
|
|
62049
62044
|
className: "mb-3",
|
|
62050
|
-
children: /* @__PURE__ */ M(
|
|
62045
|
+
children: /* @__PURE__ */ M(jP, {
|
|
62051
62046
|
value: me,
|
|
62052
62047
|
onChange: he,
|
|
62053
62048
|
labels: {
|
|
@@ -62060,7 +62055,7 @@ var PP = {
|
|
|
62060
62055
|
}
|
|
62061
62056
|
})
|
|
62062
62057
|
}),
|
|
62063
|
-
/* @__PURE__ */ M(
|
|
62058
|
+
/* @__PURE__ */ M(EP, {
|
|
62064
62059
|
items: a,
|
|
62065
62060
|
selectedPath: o,
|
|
62066
62061
|
onSelectedPathChange: s,
|
|
@@ -62080,10 +62075,10 @@ var PP = {
|
|
|
62080
62075
|
}),
|
|
62081
62076
|
_e.calloutKind !== Nt.None && _e.calloutKind !== Nt.Info && /* @__PURE__ */ M("div", {
|
|
62082
62077
|
className: "mt-3",
|
|
62083
|
-
children: /* @__PURE__ */ M(
|
|
62084
|
-
type:
|
|
62085
|
-
variant:
|
|
62086
|
-
message:
|
|
62078
|
+
children: /* @__PURE__ */ M(De, {
|
|
62079
|
+
type: Oe.SectionMessage,
|
|
62080
|
+
variant: PP(_e.calloutKind),
|
|
62081
|
+
message: IP(_e.calloutKind, {
|
|
62087
62082
|
replaceWarning: A,
|
|
62088
62083
|
noAccessError: re,
|
|
62089
62084
|
submitError: ie,
|
|
@@ -62091,21 +62086,25 @@ var PP = {
|
|
|
62091
62086
|
version: e?.version
|
|
62092
62087
|
})
|
|
62093
62088
|
})
|
|
62089
|
+
}),
|
|
62090
|
+
/* @__PURE__ */ M("div", {
|
|
62091
|
+
className: "mt-4",
|
|
62092
|
+
children: /* @__PURE__ */ M(qj, {
|
|
62093
|
+
rules: y,
|
|
62094
|
+
onRulesChange: b,
|
|
62095
|
+
sourceOptions: x,
|
|
62096
|
+
folderName: ge ? ve : void 0,
|
|
62097
|
+
disabled: g,
|
|
62098
|
+
isLoading: S,
|
|
62099
|
+
hasLoadError: C,
|
|
62100
|
+
labels: pe
|
|
62101
|
+
})
|
|
62094
62102
|
})
|
|
62095
62103
|
] }),
|
|
62096
|
-
/* @__PURE__ */ M(Zj, {
|
|
62097
|
-
rules: y,
|
|
62098
|
-
onRulesChange: b,
|
|
62099
|
-
sourceOptions: x,
|
|
62100
|
-
disabled: g,
|
|
62101
|
-
isLoading: S,
|
|
62102
|
-
hasLoadError: C,
|
|
62103
|
-
labels: pe
|
|
62104
|
-
}),
|
|
62105
62104
|
ge && e?.version != null && /* @__PURE__ */ N("div", { children: [/* @__PURE__ */ M("div", {
|
|
62106
|
-
className: Br("mb-2", E,
|
|
62105
|
+
className: Br("mb-2", E, MP.sectionHeading),
|
|
62107
62106
|
children: ne
|
|
62108
|
-
}), /* @__PURE__ */ M(
|
|
62107
|
+
}), /* @__PURE__ */ M(Yj, {
|
|
62109
62108
|
entries: ye,
|
|
62110
62109
|
isLoading: r,
|
|
62111
62110
|
hasError: i,
|
|
@@ -62115,7 +62114,7 @@ var PP = {
|
|
|
62115
62114
|
})] })
|
|
62116
62115
|
]
|
|
62117
62116
|
});
|
|
62118
|
-
},
|
|
62117
|
+
}, PP = (e) => e === Nt.ReplaceWarning ? ke.Warning : ke.Error, FP = (e, t) => {
|
|
62119
62118
|
let [n, r, ...i] = e.split("{folder}");
|
|
62120
62119
|
return r === void 0 || i.length > 0 ? e : /* @__PURE__ */ N(Ge, { children: [
|
|
62121
62120
|
n,
|
|
@@ -62125,29 +62124,29 @@ var PP = {
|
|
|
62125
62124
|
}),
|
|
62126
62125
|
r
|
|
62127
62126
|
] });
|
|
62128
|
-
},
|
|
62127
|
+
}, IP = (e, t) => e === Nt.ReplaceWarning ? FP(t.replaceWarning.replace("{version}", t.version ?? ""), t.folderName) : e === Nt.NoAccess ? FP(t.noAccessError, t.folderName) : t.submitError, LP = { footer: "_footer_dks1v_1" }, RP = ({ version: e, hasExistingPublicationInFolder: t, isSubmitDisabled: n, isSubmitLoading: r, onCancel: i, onSubmit: a, labels: o = {}, colors: s }) => {
|
|
62129
62128
|
let c = Vr({ "--pf-border": s?.border }), { cancelLabel: l = "Cancel", publishDefaultLabel: u = "Publish", updateLabel: d = "Update version {version}", publishingInProgressLabel: f = "Publishing…" } = o, p = r ? f : t && e != null ? d.replace("{version}", e) : u;
|
|
62130
62129
|
return /* @__PURE__ */ N("div", {
|
|
62131
62130
|
style: c,
|
|
62132
|
-
className: Br("flex items-center justify-end gap-2 border-t px-3.5 py-4 rtl:flex-row-reverse rtl:justify-start",
|
|
62133
|
-
children: [/* @__PURE__ */ M(
|
|
62131
|
+
className: Br("flex items-center justify-end gap-2 border-t px-3.5 py-4 rtl:flex-row-reverse rtl:justify-start", LP.footer),
|
|
62132
|
+
children: [/* @__PURE__ */ M(Se, {
|
|
62134
62133
|
label: l,
|
|
62135
62134
|
disabled: r,
|
|
62136
62135
|
onClick: i
|
|
62137
|
-
}), /* @__PURE__ */ M(
|
|
62136
|
+
}), /* @__PURE__ */ M(Ee, {
|
|
62138
62137
|
label: p,
|
|
62139
62138
|
disabled: n,
|
|
62140
|
-
iconBefore: r ? /* @__PURE__ */ M(
|
|
62139
|
+
iconBefore: r ? /* @__PURE__ */ M(Re, { size: T.SM }) : void 0,
|
|
62141
62140
|
onClick: a
|
|
62142
62141
|
})]
|
|
62143
62142
|
});
|
|
62144
|
-
},
|
|
62143
|
+
}, zP = {
|
|
62145
62144
|
backdrop: "_backdrop_1rdk6_1",
|
|
62146
62145
|
panel: "_panel_1rdk6_5",
|
|
62147
62146
|
divider: "_divider_1rdk6_10",
|
|
62148
62147
|
content: "_content_1rdk6_14",
|
|
62149
62148
|
title: "_title_1rdk6_19"
|
|
62150
|
-
},
|
|
62149
|
+
}, BP = ({ isOpen: e, resource: t, renderSummary: n, history: r, isHistoryLoading: i = !1, hasHistoryError: a = !1, folderItems: o, selectedFolderPath: s, onSelectedFolderPathChange: l, onCreateFolder: u, expandedPaths: d, onExpandedPathsChange: m, loadingPaths: h, hasExistingPublicationInFolder: g, hasWriteAccess: _, isSubmitting: v, hasSubmitError: y = !1, allowReplace: x = !0, rules: S, onRulesChange: C, ruleSourceOptions: w, isRulesLoading: T = !1, hasRulesLoadError: E = !1, onClose: ee, returnFocusRef: D, onSubmit: O, panelLabels: te, footerLabels: k, labels: ne = {}, titleClassName: A = "dial-body-semi-text", colors: re }) => {
|
|
62151
62150
|
let ie = Vr({
|
|
62152
62151
|
"--spp-backdrop-bg": re?.backdropBackground,
|
|
62153
62152
|
"--spp-panel-bg": re?.panelBackground,
|
|
@@ -62196,7 +62195,7 @@ var PP = {
|
|
|
62196
62195
|
};
|
|
62197
62196
|
}, [e, ee]), /* @__PURE__ */ N(Ge, { children: [/* @__PURE__ */ M("div", {
|
|
62198
62197
|
style: ie,
|
|
62199
|
-
className: Br("fixed inset-0 z-[51] transition-opacity duration-300",
|
|
62198
|
+
className: Br("fixed inset-0 z-[51] transition-opacity duration-300", zP.backdrop, e ? "opacity-100" : "pointer-events-none opacity-0"),
|
|
62200
62199
|
onClick: ee,
|
|
62201
62200
|
"aria-hidden": "true"
|
|
62202
62201
|
}), /* @__PURE__ */ N("div", {
|
|
@@ -62208,14 +62207,14 @@ var PP = {
|
|
|
62208
62207
|
inert: !e,
|
|
62209
62208
|
tabIndex: -1,
|
|
62210
62209
|
style: ie,
|
|
62211
|
-
className: Br("fixed inset-y-0 end-0 z-[52] flex w-full flex-col overflow-hidden", "desktop:rounded-ts-xl desktop:rounded-bs-xl desktop:w-[540px] desktop:border-s", "transition-transform duration-300",
|
|
62210
|
+
className: Br("fixed inset-y-0 end-0 z-[52] flex w-full flex-col overflow-hidden", "desktop:rounded-ts-xl desktop:rounded-bs-xl desktop:w-[540px] desktop:border-s", "transition-transform duration-300", zP.panel, e ? "translate-x-0" : "translate-x-full rtl:-translate-x-full"),
|
|
62212
62211
|
children: [
|
|
62213
62212
|
/* @__PURE__ */ N("div", {
|
|
62214
62213
|
className: "flex shrink-0 items-center gap-2 px-[22px] py-3",
|
|
62215
62214
|
children: [
|
|
62216
62215
|
/* @__PURE__ */ M("div", { className: "flex-1" }),
|
|
62217
62216
|
/* @__PURE__ */ M("span", {
|
|
62218
|
-
className: Br("flex-1 text-center", A,
|
|
62217
|
+
className: Br("flex-1 text-center", A, zP.title),
|
|
62219
62218
|
children: ae
|
|
62220
62219
|
}),
|
|
62221
62220
|
/* @__PURE__ */ M("div", {
|
|
@@ -62228,12 +62227,12 @@ var PP = {
|
|
|
62228
62227
|
})
|
|
62229
62228
|
]
|
|
62230
62229
|
}),
|
|
62231
|
-
/* @__PURE__ */ M("div", { className: Br("shrink-0",
|
|
62230
|
+
/* @__PURE__ */ M("div", { className: Br("shrink-0", zP.divider) }),
|
|
62232
62231
|
/* @__PURE__ */ M("div", {
|
|
62233
|
-
className: Br("min-h-0 flex-1 overflow-y-auto",
|
|
62232
|
+
className: Br("min-h-0 flex-1 overflow-y-auto", zP.content),
|
|
62234
62233
|
children: /* @__PURE__ */ M("div", {
|
|
62235
62234
|
className: "p-[22px]",
|
|
62236
|
-
children: /* @__PURE__ */ M(
|
|
62235
|
+
children: /* @__PURE__ */ M(NP, {
|
|
62237
62236
|
resource: t,
|
|
62238
62237
|
renderSummary: n,
|
|
62239
62238
|
history: r,
|
|
@@ -62260,7 +62259,7 @@ var PP = {
|
|
|
62260
62259
|
})
|
|
62261
62260
|
})
|
|
62262
62261
|
}),
|
|
62263
|
-
/* @__PURE__ */ M(
|
|
62262
|
+
/* @__PURE__ */ M(RP, {
|
|
62264
62263
|
version: t?.version,
|
|
62265
62264
|
hasExistingPublicationInFolder: g,
|
|
62266
62265
|
isSubmitDisabled: ce.isSubmitDisabled,
|
|
@@ -62273,4 +62272,4 @@ var PP = {
|
|
|
62273
62272
|
})] });
|
|
62274
62273
|
};
|
|
62275
62274
|
//#endregion
|
|
62276
|
-
export { Mt as PublicationRuleFunction,
|
|
62275
|
+
export { Mt as PublicationRuleFunction, Uj as PublishAccessRuleEditor, qj as PublishAccessRules, Nt as PublishCalloutKind, EP as PublishFoldersTree, RP as PublishFooter, Yj as PublishHistoryList, NP as PublishPanel, BP as StandalonePublishPanel, Gt as collectFolderKeys, Pt as derivePublishState, Bt as filterFolderTree, It as formatPublishedDate, qt as fromFolderPathKey, Qt as getSiblingFolderNames, Zt as getUniqueFolderName, Wt as mergeFolderPaths, Ht as sortFolderTree, Jt as toDialFileTree, Kt as toFolderPathKey, zt as usePublishFlow, Xt as validateFolderName };
|