@opencloud-eu/web-client 7.1.2 → 7.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,34 +1,16 @@
1
- import { a as e, i as t, n, r } from "./axios-idnwLrbl.js";
2
- import { c as i, i as a, l as o, n as s, o as c, r as l, t as u, u as d } from "./toString-DIrlTUQN.js";
3
- //#region src/helpers/call.ts
4
- var f = function* (e) {
5
- return yield e;
6
- }, p = class extends Error {
7
- response;
8
- statusCode;
9
- constructor(e, t, n = null) {
10
- super(e), this.response = t, this.statusCode = n;
11
- }
12
- }, m = class extends p {
13
- errorCode;
14
- constructor(e, t, n, r = null) {
15
- super(e, n, r), this.errorCode = t;
16
- }
17
- }, h = ({ message: e, statusCode: t, xReqId: n }) => new p(e, new Response(void 0, {
18
- headers: { "x-request-id": n },
19
- status: t
20
- }), t);
21
- //#endregion
1
+ import { a as e, i as t, n, r } from "./axios-DvF8YTlk.js";
2
+ import { t as i } from "./urlJoin-_pUL1TUx.js";
3
+ import { c as a, i as o, l as s, n as c, o as l, r as u, t as d } from "./toString-B4UEwRgf.js";
22
4
  //#region src/helpers/publicLink/functions.ts
23
- function g(e, t = "") {
5
+ function f(e, t = "") {
24
6
  return `/public-files/${e}/${t}`.split("/").filter(Boolean).join("/");
25
7
  }
26
- function _(e, t = "") {
8
+ function p(e, t = "") {
27
9
  return `/ocm/${e}/${t}`.split("/").filter(Boolean).join("/");
28
10
  }
29
11
  //#endregion
30
12
  //#region src/webdav/constants/dav.ts
31
- var v = /* @__PURE__ */ e((/* @__PURE__ */ t(((e, t) => {
13
+ var m = /* @__PURE__ */ e((/* @__PURE__ */ t(((e, t) => {
32
14
  n();
33
15
  function i(e) {
34
16
  if (typeof e != "string") throw TypeError("Path must be a string. Received " + JSON.stringify(e));
@@ -39,7 +21,7 @@ var v = /* @__PURE__ */ e((/* @__PURE__ */ t(((e, t) => {
39
21
  else if (o === 47) break;
40
22
  else o = 47;
41
23
  if (o === 47) {
42
- if (!(i === s - 1 || a === 1)) if (i !== s - 1 && a === 2) {
24
+ if (i !== s - 1 && a !== 1) if (i !== s - 1 && a === 2) {
43
25
  if (n.length < 2 || r !== 2 || n.charCodeAt(n.length - 1) !== 46 || n.charCodeAt(n.length - 2) !== 46) {
44
26
  if (n.length > 2) {
45
27
  var c = n.lastIndexOf("/");
@@ -137,15 +119,14 @@ var v = /* @__PURE__ */ e((/* @__PURE__ */ t(((e, t) => {
137
119
  } else c === -1 && (a = !1, c = o + 1), s >= 0 && (l === t.charCodeAt(s) ? --s === -1 && (r = o) : (s = -1, r = c));
138
120
  }
139
121
  return n === r ? r = c : r === -1 && (r = e.length), e.slice(n, r);
140
- } else {
141
- for (o = e.length - 1; o >= 0; --o) if (e.charCodeAt(o) === 47) {
142
- if (!a) {
143
- n = o + 1;
144
- break;
145
- }
146
- } else r === -1 && (a = !1, r = o + 1);
147
- return r === -1 ? "" : e.slice(n, r);
148
122
  }
123
+ for (o = e.length - 1; o >= 0; --o) if (e.charCodeAt(o) === 47) {
124
+ if (!a) {
125
+ n = o + 1;
126
+ break;
127
+ }
128
+ } else r === -1 && (a = !1, r = o + 1);
129
+ return r === -1 ? "" : e.slice(n, r);
149
130
  },
150
131
  extname: function(e) {
151
132
  i(e);
@@ -188,7 +169,7 @@ var v = /* @__PURE__ */ e((/* @__PURE__ */ t(((e, t) => {
188
169
  }
189
170
  c === -1 && (l = !1, c = u + 1), n === 46 ? o === -1 ? o = u : d !== 1 && (d = 1) : o !== -1 && (d = -1);
190
171
  }
191
- return o === -1 || c === -1 || d === 0 || d === 1 && o === c - 1 && o === s + 1 ? c !== -1 && (s === 0 && r ? t.base = t.name = e.slice(1, c) : t.base = t.name = e.slice(s, c)) : (s === 0 && r ? (t.name = e.slice(1, o), t.base = e.slice(1, c)) : (t.name = e.slice(s, o), t.base = e.slice(s, c)), t.ext = e.slice(o, c)), s > 0 ? t.dir = e.slice(0, s - 1) : r && (t.dir = "/"), t;
172
+ return o === -1 || c === -1 || d === 0 || d === 1 && o === c - 1 && o === s + 1 ? c !== -1 && (t.base = t.name = s === 0 && r ? e.slice(1, c) : e.slice(s, c)) : (s === 0 && r ? (t.name = e.slice(1, o), t.base = e.slice(1, c)) : (t.name = e.slice(s, o), t.base = e.slice(s, c)), t.ext = e.slice(o, c)), s > 0 ? t.dir = e.slice(0, s - 1) : r && (t.dir = "/"), t;
192
173
  },
193
174
  sep: "/",
194
175
  delimiter: ":",
@@ -196,7 +177,7 @@ var v = /* @__PURE__ */ e((/* @__PURE__ */ t(((e, t) => {
196
177
  posix: null
197
178
  };
198
179
  s.posix = s, t.exports = s;
199
- })))(), 1), y = class {
180
+ })))(), 1), h = class {
200
181
  static Shared = "S";
201
182
  static Shareable = "R";
202
183
  static Mounted = "M";
@@ -208,24 +189,24 @@ var v = /* @__PURE__ */ e((/* @__PURE__ */ t(((e, t) => {
208
189
  static FolderCreateable = "CK";
209
190
  static Deny = "Z";
210
191
  static SecureView = "X";
211
- }, ee = /* @__PURE__ */ function(e) {
192
+ }, g = /* @__PURE__ */ function(e) {
212
193
  return e.copy = "COPY", e.delete = "DELETE", e.lock = "LOCK", e.mkcol = "MKCOL", e.move = "MOVE", e.propfind = "PROPFIND", e.proppatch = "PROPPATCH", e.put = "PUT", e.report = "REPORT", e.unlock = "UNLOCK", e;
213
- }({}), b = (e) => ({
194
+ }({}), _ = (e) => ({
214
195
  value: e,
215
196
  type: null
216
- }), te = (e) => b(e), x = (e) => b(e), S = (e) => b(e), ne = {
217
- Permissions: x("permissions"),
218
- IsFavorite: S("favorite"),
219
- FileId: x("fileid"),
220
- FileParent: x("file-parent"),
221
- Name: x("name"),
222
- OwnerId: x("owner-id"),
223
- OwnerDisplayName: x("owner-display-name"),
224
- PrivateLink: x("privatelink"),
225
- ContentLength: S("getcontentlength"),
226
- ContentSize: S("size"),
227
- LastModifiedDate: x("getlastmodified"),
228
- Tags: te("tags"),
197
+ }), ee = (e) => _(e), v = (e) => _(e), y = (e) => _(e), te = {
198
+ Permissions: v("permissions"),
199
+ IsFavorite: y("favorite"),
200
+ FileId: v("fileid"),
201
+ FileParent: v("file-parent"),
202
+ Name: v("name"),
203
+ OwnerId: v("owner-id"),
204
+ OwnerDisplayName: v("owner-display-name"),
205
+ PrivateLink: v("privatelink"),
206
+ ContentLength: y("getcontentlength"),
207
+ ContentSize: y("size"),
208
+ LastModifiedDate: v("getlastmodified"),
209
+ Tags: ee("tags"),
229
210
  Audio: {
230
211
  value: "audio",
231
212
  type: null
@@ -242,96 +223,96 @@ var v = /* @__PURE__ */ e((/* @__PURE__ */ t(((e, t) => {
242
223
  value: "photo",
243
224
  type: null
244
225
  },
245
- ETag: x("getetag"),
246
- MimeType: x("getcontenttype"),
247
- ResourceType: ((e) => b(e))("resourcetype"),
226
+ ETag: v("getetag"),
227
+ MimeType: v("getcontenttype"),
228
+ ResourceType: ((e) => _(e))("resourcetype"),
248
229
  LockDiscovery: {
249
230
  value: "lockdiscovery",
250
231
  type: null
251
232
  },
252
- LockOwner: x("owner"),
253
- LockTime: x("locktime"),
233
+ LockOwner: v("owner"),
234
+ LockTime: v("locktime"),
254
235
  ActiveLock: {
255
236
  value: "activelock",
256
237
  type: null
257
238
  },
258
- DownloadURL: x("downloadURL"),
259
- Highlights: x("highlights"),
260
- MetaPathForUser: x("meta-path-for-user"),
261
- RemoteItemId: x("remote-item-id"),
262
- HasPreview: S("has-preview"),
263
- ShareId: x("shareid"),
264
- ShareRoot: x("shareroot"),
239
+ DownloadURL: v("downloadURL"),
240
+ Highlights: v("highlights"),
241
+ MetaPathForUser: v("meta-path-for-user"),
242
+ RemoteItemId: v("remote-item-id"),
243
+ HasPreview: y("has-preview"),
244
+ ShareId: v("shareid"),
245
+ ShareRoot: v("shareroot"),
265
246
  ShareTypes: {
266
247
  value: "share-types",
267
248
  type: null
268
249
  },
269
- SharePermissions: x("share-permissions"),
270
- TrashbinOriginalFilename: x("trashbin-original-filename"),
271
- TrashbinOriginalLocation: x("trashbin-original-location"),
272
- TrashbinDeletedDate: x("trashbin-delete-datetime"),
273
- PublicLinkItemType: x("public-link-item-type"),
274
- PublicLinkPermission: x("public-link-permission"),
275
- PublicLinkExpiration: x("public-link-expiration"),
276
- PublicLinkShareDate: x("public-link-share-datetime"),
277
- PublicLinkShareOwner: x("public-link-share-owner")
278
- }, C = Object.fromEntries(Object.entries(ne).map(([e, t]) => [e, t.value])), re = class e {
250
+ SharePermissions: v("share-permissions"),
251
+ TrashbinOriginalFilename: v("trashbin-original-filename"),
252
+ TrashbinOriginalLocation: v("trashbin-original-location"),
253
+ TrashbinDeletedDate: v("trashbin-delete-datetime"),
254
+ PublicLinkItemType: v("public-link-item-type"),
255
+ PublicLinkPermission: v("public-link-permission"),
256
+ PublicLinkExpiration: v("public-link-expiration"),
257
+ PublicLinkShareDate: v("public-link-share-datetime"),
258
+ PublicLinkShareOwner: v("public-link-share-owner")
259
+ }, b = Object.fromEntries(Object.entries(te).map(([e, t]) => [e, t.value])), ne = class e {
279
260
  static Default = [
280
- C.Permissions,
281
- C.IsFavorite,
282
- C.FileId,
283
- C.FileParent,
284
- C.Name,
285
- C.LockDiscovery,
286
- C.ActiveLock,
287
- C.OwnerId,
288
- C.OwnerDisplayName,
289
- C.RemoteItemId,
290
- C.ShareRoot,
291
- C.ShareTypes,
292
- C.PrivateLink,
293
- C.ContentLength,
294
- C.ContentSize,
295
- C.LastModifiedDate,
296
- C.ETag,
297
- C.MimeType,
298
- C.ResourceType,
299
- C.Tags,
300
- C.Audio,
301
- C.Location,
302
- C.Image,
303
- C.Photo,
304
- C.HasPreview
261
+ b.Permissions,
262
+ b.IsFavorite,
263
+ b.FileId,
264
+ b.FileParent,
265
+ b.Name,
266
+ b.LockDiscovery,
267
+ b.ActiveLock,
268
+ b.OwnerId,
269
+ b.OwnerDisplayName,
270
+ b.RemoteItemId,
271
+ b.ShareRoot,
272
+ b.ShareTypes,
273
+ b.PrivateLink,
274
+ b.ContentLength,
275
+ b.ContentSize,
276
+ b.LastModifiedDate,
277
+ b.ETag,
278
+ b.MimeType,
279
+ b.ResourceType,
280
+ b.Tags,
281
+ b.Audio,
282
+ b.Location,
283
+ b.Image,
284
+ b.Photo,
285
+ b.HasPreview
305
286
  ];
306
287
  static PublicLink = e.Default.concat([
307
- C.PublicLinkItemType,
308
- C.PublicLinkPermission,
309
- C.PublicLinkExpiration,
310
- C.PublicLinkShareDate,
311
- C.PublicLinkShareOwner
288
+ b.PublicLinkItemType,
289
+ b.PublicLinkPermission,
290
+ b.PublicLinkExpiration,
291
+ b.PublicLinkShareDate,
292
+ b.PublicLinkShareOwner
312
293
  ]);
313
294
  static Trashbin = [
314
- C.ContentLength,
315
- C.ResourceType,
316
- C.TrashbinOriginalLocation,
317
- C.TrashbinOriginalFilename,
318
- C.TrashbinDeletedDate,
319
- C.Permissions,
320
- C.FileParent
295
+ b.ContentLength,
296
+ b.ResourceType,
297
+ b.TrashbinOriginalLocation,
298
+ b.TrashbinOriginalFilename,
299
+ b.TrashbinDeletedDate,
300
+ b.Permissions,
301
+ b.FileParent
321
302
  ];
322
303
  static DavNamespace = [
323
- C.ContentLength,
324
- C.LastModifiedDate,
325
- C.ETag,
326
- C.MimeType,
327
- C.ResourceType,
328
- C.LockDiscovery,
329
- C.ActiveLock
304
+ b.ContentLength,
305
+ b.LastModifiedDate,
306
+ b.ETag,
307
+ b.MimeType,
308
+ b.ResourceType,
309
+ b.LockDiscovery,
310
+ b.ActiveLock
330
311
  ];
331
312
  };
332
313
  //#endregion
333
314
  //#region ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/identity.js
334
- function w(e) {
315
+ function re(e) {
335
316
  return e;
336
317
  }
337
318
  //#endregion
@@ -372,7 +353,7 @@ function ue(e) {
372
353
  //#region ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/_defineProperty.js
373
354
  var de = function() {
374
355
  try {
375
- var e = l(Object, "defineProperty");
356
+ var e = u(Object, "defineProperty");
376
357
  return e({}, "", {}), e;
377
358
  } catch {}
378
359
  }(), fe = le(de ? function(e, t) {
@@ -382,7 +363,7 @@ var de = function() {
382
363
  value: ue(t),
383
364
  writable: !0
384
365
  });
385
- } : w);
366
+ } : re);
386
367
  //#endregion
387
368
  //#region ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/_baseFindIndex.js
388
369
  function pe(e, t, n, r) {
@@ -424,7 +405,7 @@ function ye(e, t, n) {
424
405
  //#endregion
425
406
  //#region ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/_baseRest.js
426
407
  function be(e, t) {
427
- return fe(ye(e, t, w), e + "");
408
+ return fe(ye(e, t, re), e + "");
428
409
  }
429
410
  //#endregion
430
411
  //#region ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/isLength.js
@@ -435,7 +416,7 @@ function Se(e) {
435
416
  //#endregion
436
417
  //#region ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/isArrayLike.js
437
418
  function Ce(e) {
438
- return e != null && Se(e.length) && !a(e);
419
+ return e != null && Se(e.length) && !o(e);
439
420
  }
440
421
  //#endregion
441
422
  //#region ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/_baseUnary.js
@@ -471,59 +452,59 @@ function ke(e) {
471
452
  }
472
453
  //#endregion
473
454
  //#region ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/_unicodeToArray.js
474
- var Ae = "\\ud800-\\udfff", je = "\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff", Me = "\\ufe0e\\ufe0f", Ne = "[" + Ae + "]", T = "[" + je + "]", E = "\\ud83c[\\udffb-\\udfff]", Pe = "(?:" + T + "|" + E + ")", Fe = "[^" + Ae + "]", Ie = "(?:\\ud83c[\\udde6-\\uddff]){2}", Le = "[\\ud800-\\udbff][\\udc00-\\udfff]", Re = "\\u200d", ze = Pe + "?", Be = "[" + Me + "]?", Ve = "(?:" + Re + "(?:" + [
455
+ var Ae = "\\ud800-\\udfff", je = "\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff", Me = "\\ufe0e\\ufe0f", Ne = "[" + Ae + "]", x = "[" + je + "]", S = "\\ud83c[\\udffb-\\udfff]", Pe = "(?:" + x + "|" + S + ")", C = "[^" + Ae + "]", Fe = "(?:\\ud83c[\\udde6-\\uddff]){2}", w = "[\\ud800-\\udbff][\\udc00-\\udfff]", Ie = "\\u200d", T = Pe + "?", E = "[" + Me + "]?", Le = "(?:" + Ie + "(?:" + [
456
+ C,
457
+ Fe,
458
+ w
459
+ ].join("|") + ")" + E + T + ")*", Re = E + T + Le, ze = "(?:" + [
460
+ C + x + "?",
461
+ x,
475
462
  Fe,
476
- Ie,
477
- Le
478
- ].join("|") + ")" + Be + ze + ")*", He = Be + ze + Ve, Ue = "(?:" + [
479
- Fe + T + "?",
480
- T,
481
- Ie,
482
- Le,
463
+ w,
483
464
  Ne
484
- ].join("|") + ")", We = RegExp(E + "(?=" + E + ")|" + Ue + He, "g");
485
- function Ge(e) {
486
- return e.match(We) || [];
465
+ ].join("|") + ")", Be = RegExp(S + "(?=" + S + ")|" + ze + Re, "g");
466
+ function Ve(e) {
467
+ return e.match(Be) || [];
487
468
  }
488
469
  //#endregion
489
470
  //#region ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/_stringToArray.js
490
- function Ke(e) {
491
- return Oe(e) ? Ge(e) : ke(e);
471
+ function He(e) {
472
+ return Oe(e) ? Ve(e) : ke(e);
492
473
  }
493
474
  //#endregion
494
475
  //#region ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/_createCaseFirst.js
495
- function qe(e) {
476
+ function Ue(e) {
496
477
  return function(t) {
497
- t = u(t);
498
- var n = Oe(t) ? Ke(t) : void 0, r = n ? n[0] : t.charAt(0), i = n ? Ee(n, 1).join("") : t.slice(1);
478
+ t = d(t);
479
+ var n = Oe(t) ? He(t) : void 0, r = n ? n[0] : t.charAt(0), i = n ? Ee(n, 1).join("") : t.slice(1);
499
480
  return r[e]() + i;
500
481
  };
501
482
  }
502
483
  //#endregion
503
484
  //#region ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/upperFirst.js
504
- var Je = qe("toUpperCase");
485
+ var We = Ue("toUpperCase");
505
486
  //#endregion
506
487
  //#region ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/capitalize.js
507
- function Ye(e) {
508
- return Je(u(e).toLowerCase());
488
+ function Ge(e) {
489
+ return We(d(e).toLowerCase());
509
490
  }
510
491
  //#endregion
511
492
  //#region ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/_arrayReduce.js
512
- function Xe(e, t, n, r) {
493
+ function Ke(e, t, n, r) {
513
494
  var i = -1, a = e == null ? 0 : e.length;
514
495
  for (r && a && (n = e[++i]); ++i < a;) n = t(n, e[i], i, e);
515
496
  return n;
516
497
  }
517
498
  //#endregion
518
499
  //#region ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/_basePropertyOf.js
519
- function Ze(e) {
500
+ function qe(e) {
520
501
  return function(t) {
521
502
  return e?.[t];
522
503
  };
523
504
  }
524
505
  //#endregion
525
506
  //#region ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/_deburrLetter.js
526
- var Qe = Ze({
507
+ var Je = qe({
527
508
  À: "A",
528
509
  Á: "A",
529
510
  Â: "A",
@@ -714,86 +695,86 @@ var Qe = Ze({
714
695
  œ: "oe",
715
696
  ʼn: "'n",
716
697
  ſ: "s"
717
- }), $e = /[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g, et = RegExp("[\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]", "g");
718
- function tt(e) {
719
- return e = u(e), e && e.replace($e, Qe).replace(et, "");
698
+ }), Ye = /[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g, Xe = RegExp("[\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]", "g");
699
+ function Ze(e) {
700
+ return e = d(e), e && e.replace(Ye, Je).replace(Xe, "");
720
701
  }
721
702
  //#endregion
722
703
  //#region ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/_asciiWords.js
723
- var nt = /[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g;
724
- function rt(e) {
725
- return e.match(nt) || [];
704
+ var Qe = /[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g;
705
+ function $e(e) {
706
+ return e.match(Qe) || [];
726
707
  }
727
708
  //#endregion
728
709
  //#region ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/_hasUnicodeWord.js
729
- var it = /[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/;
730
- function at(e) {
731
- return it.test(e);
710
+ var et = /[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/;
711
+ function tt(e) {
712
+ return et.test(e);
732
713
  }
733
714
  //#endregion
734
715
  //#region ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/_unicodeWords.js
735
- var ot = "\\ud800-\\udfff", st = "\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff", ct = "\\u2700-\\u27bf", lt = "a-z\\xdf-\\xf6\\xf8-\\xff", ut = "\\xac\\xb1\\xd7\\xf7", dt = "\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf", ft = "\\u2000-\\u206f", pt = " \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000", mt = "A-Z\\xc0-\\xd6\\xd8-\\xde", ht = "\\ufe0e\\ufe0f", gt = ut + dt + ft + pt, _t = "['’]", vt = "[" + gt + "]", yt = "[" + st + "]", bt = "\\d+", xt = "[" + ct + "]", St = "[" + lt + "]", D = "[^" + ot + gt + bt + ct + lt + mt + "]", Ct = "(?:" + yt + "|\\ud83c[\\udffb-\\udfff])", wt = "[^" + ot + "]", O = "(?:\\ud83c[\\udde6-\\uddff]){2}", k = "[\\ud800-\\udbff][\\udc00-\\udfff]", A = "[" + mt + "]", Tt = "\\u200d", j = "(?:" + St + "|" + D + ")", Et = "(?:" + A + "|" + D + ")", M = "(?:" + _t + "(?:d|ll|m|re|s|t|ve))?", N = "(?:" + _t + "(?:D|LL|M|RE|S|T|VE))?", P = Ct + "?", F = "[" + ht + "]?", Dt = "(?:" + Tt + "(?:" + [
736
- wt,
716
+ var D = "\\ud800-\\udfff", nt = "\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff", rt = "\\u2700-\\u27bf", it = "a-z\\xdf-\\xf6\\xf8-\\xff", at = "\\xac\\xb1\\xd7\\xf7", ot = "\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf", st = "\\u2000-\\u206f", ct = " \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000", lt = "A-Z\\xc0-\\xd6\\xd8-\\xde", ut = "\\ufe0e\\ufe0f", dt = at + ot + st + ct, ft = "['’]", pt = "[" + dt + "]", mt = "[" + nt + "]", ht = "\\d+", gt = "[" + rt + "]", _t = "[" + it + "]", vt = "[^" + D + dt + ht + rt + it + lt + "]", yt = "(?:" + mt + "|\\ud83c[\\udffb-\\udfff])", bt = "[^" + D + "]", O = "(?:\\ud83c[\\udde6-\\uddff]){2}", k = "[\\ud800-\\udbff][\\udc00-\\udfff]", A = "[" + lt + "]", xt = "\\u200d", j = "(?:" + _t + "|" + vt + ")", St = "(?:" + A + "|" + vt + ")", M = "(?:" + ft + "(?:d|ll|m|re|s|t|ve))?", N = "(?:" + ft + "(?:D|LL|M|RE|S|T|VE))?", P = yt + "?", F = "[" + ut + "]?", Ct = "(?:" + xt + "(?:" + [
717
+ bt,
737
718
  O,
738
719
  k
739
- ].join("|") + ")" + F + P + ")*", Ot = "\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])", kt = "\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])", At = F + P + Dt, jt = "(?:" + [
740
- xt,
720
+ ].join("|") + ")" + F + P + ")*", wt = "\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])", Tt = "\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])", Et = F + P + Ct, Dt = "(?:" + [
721
+ gt,
741
722
  O,
742
723
  k
743
- ].join("|") + ")" + At, Mt = RegExp([
744
- A + "?" + St + "+" + M + "(?=" + [
745
- vt,
724
+ ].join("|") + ")" + Et, Ot = RegExp([
725
+ A + "?" + _t + "+" + M + "(?=" + [
726
+ pt,
746
727
  A,
747
728
  "$"
748
729
  ].join("|") + ")",
749
- Et + "+" + N + "(?=" + [
750
- vt,
730
+ St + "+" + N + "(?=" + [
731
+ pt,
751
732
  A + j,
752
733
  "$"
753
734
  ].join("|") + ")",
754
735
  A + "?" + j + "+" + M,
755
736
  A + "+" + N,
756
- kt,
757
- Ot,
758
- bt,
759
- jt
737
+ Tt,
738
+ wt,
739
+ ht,
740
+ Dt
760
741
  ].join("|"), "g");
761
- function Nt(e) {
762
- return e.match(Mt) || [];
742
+ function kt(e) {
743
+ return e.match(Ot) || [];
763
744
  }
764
745
  //#endregion
765
746
  //#region ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/words.js
766
- function Pt(e, t, n) {
767
- return e = u(e), t = n ? void 0 : t, t === void 0 ? at(e) ? Nt(e) : rt(e) : e.match(t) || [];
747
+ function At(e, t, n) {
748
+ return e = d(e), t = n ? void 0 : t, t === void 0 ? tt(e) ? kt(e) : $e(e) : e.match(t) || [];
768
749
  }
769
750
  //#endregion
770
751
  //#region ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/_createCompounder.js
771
- var Ft = RegExp("['’]", "g");
772
- function It(e) {
752
+ var jt = RegExp("['’]", "g");
753
+ function Mt(e) {
773
754
  return function(t) {
774
- return Xe(Pt(tt(t).replace(Ft, "")), e, "");
755
+ return Ke(At(Ze(t).replace(jt, "")), e, "");
775
756
  };
776
757
  }
777
758
  //#endregion
778
759
  //#region ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/camelCase.js
779
- var Lt = It(function(e, t, n) {
780
- return t = t.toLowerCase(), e + (n ? Ye(t) : t);
781
- }), I = l(o, "Set"), Rt = "__lodash_hash_undefined__";
782
- function zt(e) {
783
- return this.__data__.set(e, Rt), this;
760
+ var Nt = Mt(function(e, t, n) {
761
+ return t = t.toLowerCase(), e + (n ? Ge(t) : t);
762
+ }), I = u(s, "Set"), Pt = "__lodash_hash_undefined__";
763
+ function Ft(e) {
764
+ return this.__data__.set(e, Pt), this;
784
765
  }
785
766
  //#endregion
786
767
  //#region ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/_setCacheHas.js
787
- function Bt(e) {
768
+ function It(e) {
788
769
  return this.__data__.has(e);
789
770
  }
790
771
  //#endregion
791
772
  //#region ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/_SetCache.js
792
773
  function L(e) {
793
774
  var t = -1, n = e == null ? 0 : e.length;
794
- for (this.__data__ = new s(); ++t < n;) this.add(e[t]);
775
+ for (this.__data__ = new c(); ++t < n;) this.add(e[t]);
795
776
  }
796
- L.prototype.add = L.prototype.push = zt, L.prototype.has = Bt;
777
+ L.prototype.add = L.prototype.push = Ft, L.prototype.has = It;
797
778
  //#endregion
798
779
  //#region ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/_cacheHas.js
799
780
  function R(e, t) {
@@ -809,26 +790,26 @@ function z(e) {
809
790
  }
810
791
  //#endregion
811
792
  //#region ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/isArrayLikeObject.js
812
- function Vt(e) {
813
- return i(e) && Ce(e);
793
+ function Lt(e) {
794
+ return a(e) && Ce(e);
814
795
  }
815
796
  //#endregion
816
797
  //#region ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/_arrayIncludesWith.js
817
- function Ht(e, t, n) {
798
+ function Rt(e, t, n) {
818
799
  for (var r = -1, i = e == null ? 0 : e.length; ++r < i;) if (n(t, e[r])) return !0;
819
800
  return !1;
820
801
  }
821
802
  //#endregion
822
803
  //#region ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/_baseIntersection.js
823
- var Ut = Math.min;
824
- function Wt(e, t, n) {
825
- for (var r = n ? Ht : _e, i = e[0].length, a = e.length, o = a, s = Array(a), l = Infinity, u = []; o--;) {
804
+ var zt = Math.min;
805
+ function Bt(e, t, n) {
806
+ for (var r = n ? Rt : _e, i = e[0].length, a = e.length, o = a, s = Array(a), c = Infinity, u = []; o--;) {
826
807
  var d = e[o];
827
- o && t && (d = c(d, we(t))), l = Ut(d.length, l), s[o] = !n && (t || i >= 120 && d.length >= 120) ? new L(o && d) : void 0;
808
+ o && t && (d = l(d, we(t))), c = zt(d.length, c), s[o] = !n && (t || i >= 120 && d.length >= 120) ? new L(o && d) : void 0;
828
809
  }
829
810
  d = e[0];
830
811
  var f = -1, p = s[0];
831
- outer: for (; ++f < i && u.length < l;) {
812
+ outer: for (; ++f < i && u.length < c;) {
832
813
  var m = d[f], h = t ? t(m) : m;
833
814
  if (m = n || m !== 0 ? m : 0, !(p ? R(p, h) : r(u, h, n))) {
834
815
  for (o = a; --o;) {
@@ -842,22 +823,22 @@ function Wt(e, t, n) {
842
823
  }
843
824
  //#endregion
844
825
  //#region ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/_castArrayLikeObject.js
845
- function Gt(e) {
846
- return Vt(e) ? e : [];
826
+ function Vt(e) {
827
+ return Lt(e) ? e : [];
847
828
  }
848
829
  //#endregion
849
830
  //#region ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/intersection.js
850
- var Kt = be(function(e) {
851
- var t = c(e, Gt);
852
- return t.length && t[0] === e[0] ? Wt(t) : [];
853
- }), qt = I && 1 / z(new I([, -0]))[1] == Infinity ? function(e) {
831
+ var Ht = be(function(e) {
832
+ var t = l(e, Vt);
833
+ return t.length && t[0] === e[0] ? Bt(t) : [];
834
+ }), Ut = I && 1 / z(new I([, -0]))[1] == Infinity ? function(e) {
854
835
  return new I(e);
855
- } : ae, Jt = 200;
856
- function Yt(e, t, n) {
836
+ } : ae, Wt = 200;
837
+ function Gt(e, t, n) {
857
838
  var r = -1, i = _e, a = e.length, o = !0, s = [], c = s;
858
- if (n) o = !1, i = Ht;
859
- else if (a >= Jt) {
860
- var l = t ? null : qt(e);
839
+ if (n) o = !1, i = Rt;
840
+ else if (a >= Wt) {
841
+ var l = t ? null : Ut(e);
861
842
  if (l) return z(l);
862
843
  o = !1, i = R, c = new L();
863
844
  } else c = t ? [] : s;
@@ -872,16 +853,16 @@ function Yt(e, t, n) {
872
853
  }
873
854
  //#endregion
874
855
  //#region ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/uniq.js
875
- function Xt(e) {
876
- return e && e.length ? Yt(e) : [];
856
+ function Kt(e) {
857
+ return e && e.length ? Gt(e) : [];
877
858
  }
878
859
  //#endregion
879
860
  //#region src/helpers/resource/functions.ts
880
- var Zt = { complex: [
861
+ var qt = { complex: [
881
862
  "tar.bz2",
882
863
  "tar.gz",
883
864
  "tar.xz"
884
- ] }, Qt = (e) => Object.hasOwn(e, "ddate"), $t = (e) => Object.hasOwn(e, "highlights"), B = (e) => e.replace(/[^A-Za-z0-9\-_]/g, ""), en = (e, t) => !e || typeof e != "string" ? "" : e.indexOf("!") >= 0 ? e.split("!")[t] : "", V = (e) => en(e, 0), H = (e) => en(e, 1), tn = (e) => {
865
+ ] }, Jt = (e) => Object.hasOwn(e, "ddate"), Yt = (e) => Object.hasOwn(e, "highlights"), B = (e) => e.replace(/[^A-Za-z0-9\-_]/g, ""), Xt = (e, t) => !e || typeof e != "string" ? "" : e.indexOf("!") >= 0 ? e.split("!")[t] : "", V = (e) => Xt(e, 0), H = (e) => Xt(e, 1), Zt = (e) => {
885
866
  let t = e.extension || "", n = e.name || "";
886
867
  if (!t.length) return n;
887
868
  let r = n.lastIndexOf(`.${t}`);
@@ -890,28 +871,28 @@ var Zt = { complex: [
890
871
  let t = e.name.split(".");
891
872
  if (t.length > 2) for (let e = 0; e < t.length; e++) {
892
873
  let n = t.slice(e, t.length).join(".");
893
- if (Zt.complex.includes(n)) return n;
874
+ if (qt.complex.includes(n)) return n;
894
875
  }
895
876
  return t.length < 2 ? "" : t[t.length - 1];
896
- }, nn = (e) => (0, v.basename)((0, v.dirname)(e.path)) || null, rn = (e) => typeof e.isShareRoot == "function" && e.isShareRoot(), W = (e) => {
877
+ }, Qt = (e) => (0, m.basename)((0, m.dirname)(e.path)) || null, $t = (e) => typeof e.isShareRoot == "function" && e.isShareRoot(), W = (e) => {
897
878
  if (!e) return e;
898
879
  let t = {};
899
880
  return Object.keys(e).forEach((n) => {
900
- t[Lt(n)] = e[n];
881
+ t[Nt(n)] = e[n];
901
882
  }), t;
902
883
  };
903
- function an(e, t = []) {
904
- let n = e.props[C.Name]?.toString() || (0, v.basename)(e.filename), r = e.props[C.FileId], i = e.type === "directory", a;
884
+ function en(e, t = []) {
885
+ let n = e.props[b.Name]?.toString() || (0, m.basename)(e.filename), r = e.props[b.FileId], i = e.type === "directory", a;
905
886
  a = e.filename.startsWith("/files") || e.filename.startsWith("/space") ? e.filename.split("/").slice(3).join("/") : e.filename, a.startsWith("/") || (a = `/${a}`);
906
887
  let o = U({
907
888
  ...e,
908
889
  id: r,
909
890
  name: n,
910
891
  path: a
911
- }), s = e.props[C.LockDiscovery], c, l, u;
912
- s && (c = s[C.ActiveLock], l = c[C.LockOwner], u = c[C.LockTime]);
892
+ }), s = e.props[b.LockDiscovery], c, l, u;
893
+ s && (c = s[b.ActiveLock], l = c[b.LockOwner], u = c[b.LockTime]);
913
894
  let d = [];
914
- e.props[C.ShareTypes] && (d = e.props[C.ShareTypes]["share-type"], Array.isArray(d) || (d = [d]));
895
+ e.props[b.ShareTypes] && (d = e.props[b.ShareTypes]["share-type"], Array.isArray(d) || (d = [d]));
915
896
  let f = {};
916
897
  for (let n of t || []) {
917
898
  let t = n.split(":").pop();
@@ -921,8 +902,8 @@ function an(e, t = []) {
921
902
  id: r,
922
903
  fileId: r,
923
904
  storageId: V(r),
924
- parentFolderId: e.props[C.FileParent],
925
- mimeType: e.props[C.MimeType],
905
+ parentFolderId: e.props[b.FileParent],
906
+ mimeType: e.props[b.MimeType],
926
907
  name: n,
927
908
  extension: o,
928
909
  path: a,
@@ -933,56 +914,60 @@ function an(e, t = []) {
933
914
  lockOwner: l,
934
915
  lockTime: u,
935
916
  processing: e.processing || !1,
936
- mdate: e.props[C.LastModifiedDate],
937
- size: i ? e.props[C.ContentSize]?.toString() || "0" : e.props[C.ContentLength]?.toString() || "0",
938
- permissions: e.props[C.Permissions] || "",
939
- starred: e.props[C.IsFavorite] === 1,
940
- etag: e.props[C.ETag],
917
+ mdate: e.props[b.LastModifiedDate],
918
+ size: i ? e.props[b.ContentSize]?.toString() || "0" : e.props[b.ContentLength]?.toString() || "0",
919
+ permissions: e.props[b.Permissions] || "",
920
+ isInVault: !1,
921
+ starred: e.props[b.IsFavorite] === 1,
922
+ etag: e.props[b.ETag],
941
923
  shareTypes: d,
942
- privateLink: e.props[C.PrivateLink],
943
- downloadURL: e.props[C.DownloadURL],
944
- remoteItemId: e.props[C.RemoteItemId],
945
- remoteItemPath: e.props[C.ShareRoot],
924
+ privateLink: e.props[b.PrivateLink],
925
+ downloadURL: e.props[b.DownloadURL],
926
+ remoteItemId: e.props[b.RemoteItemId],
927
+ remoteItemPath: e.props[b.ShareRoot],
946
928
  owner: {
947
- id: e.props[C.OwnerId],
948
- displayName: e.props[C.OwnerDisplayName]
929
+ id: e.props[b.OwnerId],
930
+ displayName: e.props[b.OwnerDisplayName]
949
931
  },
950
- tags: (e.props[C.Tags] || "").toString().split(",").filter(Boolean),
951
- audio: W(e.props[C.Audio]),
952
- location: W(e.props[C.Location]),
953
- image: W(e.props[C.Image]),
954
- photo: W(e.props[C.Photo]),
932
+ tags: (e.props[b.Tags] || "").toString().split(",").filter(Boolean),
933
+ audio: W(e.props[b.Audio]),
934
+ location: W(e.props[b.Location]),
935
+ image: W(e.props[b.Image]),
936
+ photo: W(e.props[b.Photo]),
955
937
  extraProps: f,
956
- hasPreview: () => e.props[C.HasPreview] === 1,
938
+ hasPreview: () => e.props[b.HasPreview] === 1,
957
939
  canUpload: function() {
958
- return this.permissions.indexOf(y.FolderCreateable) >= 0;
940
+ return this.permissions.indexOf(h.FolderCreateable) >= 0;
959
941
  },
960
942
  canDownload: function() {
961
- return this.permissions.indexOf(y.SecureView) === -1;
943
+ return this.permissions.indexOf(h.SecureView) === -1;
962
944
  },
963
945
  canBeDeleted: function() {
964
- return this.permissions.indexOf(y.Deletable) >= 0;
946
+ return this.permissions.indexOf(h.Deletable) >= 0;
965
947
  },
966
948
  canRename: function() {
967
- return this.permissions.indexOf(y.Renameable) >= 0;
949
+ return this.permissions.indexOf(h.Renameable) >= 0;
968
950
  },
969
951
  canShare: function({ ability: e }) {
970
- return e.can("create-all", "Share") && this.permissions.indexOf(y.Shareable) >= 0;
952
+ return e.can("create-all", "Share") && this.permissions.indexOf(h.Shareable) >= 0;
971
953
  },
972
954
  canCreate: function() {
973
- return this.permissions.indexOf(y.FolderCreateable) >= 0;
955
+ return this.permissions.indexOf(h.FolderCreateable) >= 0;
974
956
  },
975
957
  canEditTags: function() {
976
- return this.permissions.indexOf(y.Updateable) >= 0 || this.permissions.indexOf(y.FileUpdateable) >= 0 || this.permissions.indexOf(y.FolderCreateable) >= 0;
958
+ return this.permissions.indexOf(h.Updateable) >= 0 || this.permissions.indexOf(h.FileUpdateable) >= 0 || this.permissions.indexOf(h.FolderCreateable) >= 0;
959
+ },
960
+ canListVersions: function() {
961
+ return !this.isFolder;
977
962
  },
978
963
  isMounted: function() {
979
- return this.permissions.indexOf(y.Mounted) >= 0;
964
+ return this.permissions.indexOf(h.Mounted) >= 0;
980
965
  },
981
966
  isReceivedShare: function() {
982
- return this.permissions.indexOf(y.Shared) >= 0;
967
+ return this.permissions.indexOf(h.Shared) >= 0;
983
968
  },
984
969
  isShareRoot() {
985
- return e.props[C.ShareRoot] ? e.filename.split("/").length === 3 : !1;
970
+ return e.props[b.ShareRoot] ? e.filename.split("/").length === 3 : !1;
986
971
  },
987
972
  getDomSelector: () => B(r)
988
973
  };
@@ -990,20 +975,20 @@ function an(e, t = []) {
990
975
  return H(this.id);
991
976
  } }), p;
992
977
  }
993
- function on(e) {
994
- let t = e.type === "directory", n = e.props[C.TrashbinOriginalFilename]?.toString(), r = U({
978
+ function tn(e) {
979
+ let t = e.type === "directory", n = e.props[b.TrashbinOriginalFilename]?.toString(), r = U({
995
980
  name: n,
996
981
  type: e.type
997
- }), i = v.default.basename(e.filename);
982
+ }), a = m.default.basename(e.filename);
998
983
  return {
999
984
  type: t ? "folder" : e.type,
1000
985
  isFolder: t,
1001
- ddate: e.props[C.TrashbinDeletedDate],
1002
- name: v.default.basename(n),
986
+ ddate: e.props[b.TrashbinDeletedDate],
987
+ name: m.default.basename(n),
1003
988
  extension: r,
1004
- path: d(e.props[C.TrashbinOriginalLocation], { leadingSlash: !0 }),
1005
- id: i,
1006
- parentFolderId: e.props[C.FileParent],
989
+ path: i(e.props[b.TrashbinOriginalLocation], { leadingSlash: !0 }),
990
+ id: a,
991
+ parentFolderId: e.props[b.FileParent],
1007
992
  webDavPath: "",
1008
993
  canUpload: () => !1,
1009
994
  canDownload: () => !1,
@@ -1018,18 +1003,13 @@ function on(e) {
1018
1003
  isReceivedShare: () => !1,
1019
1004
  hasPreview: () => !1,
1020
1005
  isShareRoot: () => !1,
1021
- getDomSelector: () => B(i)
1006
+ canListVersions: () => !1,
1007
+ getDomSelector: () => B(a)
1022
1008
  };
1023
1009
  }
1024
1010
  //#endregion
1025
- //#region src/helpers/share/constants.ts
1026
- var sn = class {
1027
- static Read = 1;
1028
- static Update = 2;
1029
- static Create = 4;
1030
- static Delete = 8;
1031
- static Share = 16;
1032
- }, G = /* @__PURE__ */ function(e) {
1011
+ //#region src/helpers/share/types.ts
1012
+ var G = /* @__PURE__ */ function(e) {
1033
1013
  return e.createUpload = "libre.graph/driveItem/upload/create", e.createPermissions = "libre.graph/driveItem/permissions/create", e.createChildren = "libre.graph/driveItem/children/create", e.readBasic = "libre.graph/driveItem/basic/read", e.readPath = "libre.graph/driveItem/path/read", e.readQuota = "libre.graph/driveItem/quota/read", e.readContent = "libre.graph/driveItem/content/read", e.readChildren = "libre.graph/driveItem/children/read", e.readDeleted = "libre.graph/driveItem/deleted/read", e.readPermissions = "libre.graph/driveItem/permissions/read", e.readVersions = "libre.graph/driveItem/versions/read", e.updatePath = "libre.graph/driveItem/path/update", e.updateDeleted = "libre.graph/driveItem/deleted/update", e.updatePermissions = "libre.graph/driveItem/permissions/update", e.updateVersions = "libre.graph/driveItem/versions/update", e.deleteStandard = "libre.graph/driveItem/standard/delete", e.deleteDeleted = "libre.graph/driveItem/deleted/delete", e.deletePermissions = "libre.graph/driveItem/permissions/delete", e;
1034
1014
  }({}), K = (e) => e, q = class {
1035
1015
  _key;
@@ -1057,6 +1037,7 @@ var sn = class {
1057
1037
  static link = new q("link", 3, K("Link"), "link");
1058
1038
  static guest = new q("guest", 4, K("Guest"), "global");
1059
1039
  static remote = new q("remote", 6, K("External"), "earth");
1040
+ static contact = new q("contact", 100, K("Contact"), "global");
1060
1041
  static individuals = [
1061
1042
  this.user,
1062
1043
  this.guest,
@@ -1075,7 +1056,8 @@ var sn = class {
1075
1056
  this.group,
1076
1057
  this.link,
1077
1058
  this.guest,
1078
- this.remote
1059
+ this.remote,
1060
+ this.contact
1079
1061
  ];
1080
1062
  static isIndividual(e) {
1081
1063
  return this.individuals.includes(e);
@@ -1102,18 +1084,18 @@ var sn = class {
1102
1084
  return e.map((e) => e.value);
1103
1085
  }
1104
1086
  static containsAnyValue(e, t) {
1105
- return Kt(this.getValues(e), t).length > 0;
1087
+ return Ht(this.getValues(e), t).length > 0;
1106
1088
  }
1107
- }, cn = "a0ca6a90-a365-4782-871e-d44447bbc668", ln = "89f37a33-858b-45fa-8890-a1f2b27d90e1", un = (e) => e?.type === "space", Y = (e) => e?.driveType === "personal", dn = (e) => e?.driveType === "project", fn = (e) => e?.driveType === "share", pn = (e) => e?.driveType === "mountpoint", mn = (e) => e?.driveType === "public";
1089
+ }, nn = "a0ca6a90-a365-4782-871e-d44447bbc668", rn = "89f37a33-858b-45fa-8890-a1f2b27d90e1", an = (e) => e?.type === "space", Y = (e) => e?.driveType === "personal", on = (e) => e?.driveType === "project", sn = (e) => e?.driveType === "share", cn = (e) => e?.driveType === "mountpoint", ln = (e) => e?.driveType === "public";
1108
1090
  //#endregion
1109
1091
  //#region src/helpers/space/functions.ts
1110
1092
  function X(e, t) {
1111
- return d("spaces", e, t, { leadingSlash: !0 });
1093
+ return i("spaces", e, t, { leadingSlash: !0 });
1112
1094
  }
1113
- function hn(e, t = "") {
1114
- return d("spaces", "trash-bin", e, t, { leadingSlash: !0 });
1095
+ function un(e, t = "") {
1096
+ return i("spaces", "trash-bin", e, t, { leadingSlash: !0 });
1115
1097
  }
1116
- function gn(e, t) {
1098
+ function dn(e, t) {
1117
1099
  let n = e[{
1118
1100
  image: "spaceImageData",
1119
1101
  readme: "spaceReadmeData"
@@ -1122,18 +1104,18 @@ function gn(e, t) {
1122
1104
  let r = decodeURI(n.webDavUrl).split("/"), i = r.find((t) => t.startsWith(e.id));
1123
1105
  return i ? r.slice(r.indexOf(i) + 1).join("/") : "";
1124
1106
  }
1125
- function _n(e) {
1107
+ function fn(e) {
1126
1108
  return e.permissions.includes(G.deletePermissions);
1127
1109
  }
1128
- var vn = (e, t) => e.root.permissions?.filter((e) => {
1110
+ var pn = (e, t) => e.root.permissions?.filter((e) => {
1129
1111
  let n = [];
1130
1112
  e["@libre.graph.permissions.actions"] && (n = e["@libre.graph.permissions.actions"]);
1131
1113
  let r = t[e.roles?.[0]];
1132
1114
  return r && !n.length && (n = r.rolePermissions.find(({ condition: e }) => e === "exists @Resource.Root")?.allowedResourceActions || []), n.includes(G.deletePermissions);
1133
1115
  });
1134
- function yn(e) {
1135
- let t = e.publicLinkPassword, n = e.props?.[C.FileId], r = e.props?.[C.PublicLinkItemType], i = e.props?.[C.PublicLinkPermission], a = e.props?.[C.PublicLinkExpiration], o = e.props?.[C.PublicLinkShareDate], s = e.props?.[C.PublicLinkShareOwner], c = e.publicLinkType, l, u;
1136
- return c === "ocm" ? (l = `ocm/${e.id}`, u = _(e.id)) : (l = `public/${e.id}`, u = g(e.id)), Object.assign(Z({
1116
+ function mn(e) {
1117
+ let t = e.publicLinkPassword, n = e.props?.[b.FileId], r = e.props?.[b.PublicLinkItemType], i = e.props?.[b.PublicLinkPermission], a = e.props?.[b.PublicLinkExpiration], o = e.props?.[b.PublicLinkShareDate], s = e.props?.[b.PublicLinkShareOwner], c = e.publicLinkType, l, u;
1118
+ return c === "ocm" ? (l = `ocm/${e.id}`, u = p(e.id)) : (l = `public/${e.id}`, u = f(e.id)), Object.assign(Z({
1137
1119
  ...e,
1138
1120
  driveType: "public",
1139
1121
  driveAlias: l,
@@ -1149,22 +1131,22 @@ function yn(e) {
1149
1131
  publicLinkType: c
1150
1132
  });
1151
1133
  }
1152
- function bn({ driveAliasPrefix: e, id: t, shareName: n, serverUrl: r }) {
1153
- let i = Z({
1134
+ function hn({ driveAliasPrefix: e, id: t, shareName: n, serverUrl: r, graphPermissions: i }) {
1135
+ let a = Z({
1154
1136
  id: t,
1155
1137
  driveAlias: `${e}/${n}`,
1156
1138
  driveType: "share",
1157
1139
  name: n,
1158
1140
  serverUrl: r
1159
1141
  });
1160
- return i.rename = (t) => {
1161
- i.driveAlias = `${e}/${t}`, i.name = t;
1162
- }, i;
1142
+ return a.rename = (t) => {
1143
+ a.driveAlias = `${e}/${t}`, a.name = t;
1144
+ }, i && (a.graphPermissions = i), a;
1163
1145
  }
1164
1146
  function Z(e) {
1165
1147
  let t, n;
1166
1148
  e.special && (t = e.special.find((e) => e.specialFolder.name === "image"), n = e.special.find((e) => e.specialFolder.name === "readme"), t && (t.webDavUrl = decodeURI(t.webDavUrl)), n && (n.webDavUrl = decodeURI(n.webDavUrl)));
1167
- let r = e.root?.deleted?.state === "trashed", i = d(e.webDavPath || X(e.id), { leadingSlash: !0 }), a = d(e.serverUrl, "dav", i), o = d(e.webDavTrashPath || hn(e.id), { leadingSlash: !0 }), s = d(e.serverUrl, "dav", o), c = {
1149
+ let r = e.root?.deleted?.state === "trashed", a = i(e.webDavPath || X(e.id), { leadingSlash: !0 }), o = i(e.serverUrl, "dav", a), s = i(e.webDavTrashPath || un(e.id), { leadingSlash: !0 }), c = i(e.serverUrl, "dav", s), l = {
1168
1150
  id: e.id,
1169
1151
  fileId: e.id,
1170
1152
  storageId: e.id,
@@ -1173,8 +1155,8 @@ function Z(e) {
1173
1155
  description: e.description,
1174
1156
  extension: "",
1175
1157
  path: "/",
1176
- webDavPath: i,
1177
- webDavTrashPath: o,
1158
+ webDavPath: a,
1159
+ webDavTrashPath: s,
1178
1160
  driveAlias: e.driveAlias,
1179
1161
  driveType: e.driveType,
1180
1162
  type: "space",
@@ -1221,10 +1203,10 @@ function Z(e) {
1221
1203
  return this.graphPermissions?.includes(G.createPermissions);
1222
1204
  },
1223
1205
  canEditImage: function() {
1224
- return this.disabled ? !1 : this.graphPermissions?.includes(G.deletePermissions);
1206
+ return !this.disabled && this.graphPermissions?.includes(G.deletePermissions);
1225
1207
  },
1226
1208
  canEditReadme: function() {
1227
- return this.disabled ? !1 : this.graphPermissions?.includes(G.deletePermissions);
1209
+ return !this.disabled && this.graphPermissions?.includes(G.deletePermissions);
1228
1210
  },
1229
1211
  canRestoreFromTrashbin: function() {
1230
1212
  return this.graphPermissions?.includes(G.updateDeleted);
@@ -1232,8 +1214,8 @@ function Z(e) {
1232
1214
  canDeleteFromTrashBin: function({ user: e } = {}) {
1233
1215
  return Y(this) && this.isOwner(e) ? !0 : this.graphPermissions?.includes(G.deletePermissions);
1234
1216
  },
1235
- canListVersions: function({ user: e } = {}) {
1236
- return Y(this) && this.isOwner(e) ? !0 : this.graphPermissions?.includes(G.readVersions);
1217
+ canListVersions: function() {
1218
+ return !1;
1237
1219
  },
1238
1220
  canCreate: function() {
1239
1221
  return !0;
@@ -1256,23 +1238,23 @@ function Z(e) {
1256
1238
  },
1257
1239
  getDomSelector: () => B(e.id),
1258
1240
  getDriveAliasAndItem({ path: e }) {
1259
- return d(this.driveAlias, e, { leadingSlash: !1 });
1241
+ return i(this.driveAlias, e, { leadingSlash: !1 });
1260
1242
  },
1261
1243
  getWebDavUrl({ path: e }) {
1262
- return d(a, e);
1244
+ return i(o, e);
1263
1245
  },
1264
1246
  getWebDavTrashUrl({ path: e }) {
1265
- return d(s, e);
1247
+ return i(c, e);
1266
1248
  },
1267
1249
  isOwner(e) {
1268
1250
  return e?.id === this.owner?.id;
1269
1251
  }
1270
1252
  };
1271
- return Object.defineProperty(c, "nodeId", { get() {
1253
+ return Object.defineProperty(l, "nodeId", { get() {
1272
1254
  return H(this.id);
1273
- } }), c;
1255
+ } }), l;
1274
1256
  }
1275
- function xn(e) {
1257
+ function gn(e) {
1276
1258
  return {
1277
1259
  id: e.spaceImageData.id,
1278
1260
  name: e.spaceImageData.name,
@@ -1280,17 +1262,17 @@ function xn(e) {
1280
1262
  extension: U({ name: e.spaceImageData.name }),
1281
1263
  mimeType: e.spaceImageData.file.mimeType,
1282
1264
  type: "file",
1283
- webDavPath: d(e.webDavPath, ".space", e.spaceImageData.name),
1265
+ webDavPath: i(e.webDavPath, ".space", e.spaceImageData.name),
1284
1266
  hasPreview: () => !0,
1285
1267
  canDownload: () => !0
1286
1268
  };
1287
1269
  }
1288
1270
  //#endregion
1289
1271
  //#region src/helpers/share/functions.ts
1290
- var Q = (e) => Object.hasOwn(e, "sharedWith"), Sn = (e) => Q(e) && e.outgoing, Cn = (e) => Q(e) && !e.outgoing, wn = (e) => Object.hasOwn(e, "role"), Tn = (e) => !Object.hasOwn(e, "role"), En = ({ driveItem: e, graphRoles: t }) => e.remoteItem?.permissions.reduce((e, n) => (n.roles?.forEach((n) => {
1272
+ var Q = (e) => Object.hasOwn(e, "sharedWith"), _n = (e) => Q(e) && e.outgoing, vn = (e) => Q(e) && !e.outgoing, yn = (e) => Object.hasOwn(e, "role"), bn = (e) => !Object.hasOwn(e, "role"), xn = ({ driveItem: e, graphRoles: t }) => e.remoteItem?.permissions.reduce((e, n) => (n.roles?.forEach((n) => {
1291
1273
  let r = t[n];
1292
1274
  r && !e.some(({ id: e }) => e === r.id) && e.push(r);
1293
- }), e), []), Dn = ({ driveItem: e, shareRoles: t }) => {
1275
+ }), e), []), Sn = ({ driveItem: e, shareRoles: t }) => {
1294
1276
  if (!t.length) {
1295
1277
  let t = e.remoteItem?.permissions.reduce((e, t) => {
1296
1278
  let n = t["@libre.graph.permissions.actions"];
@@ -1303,25 +1285,25 @@ var Q = (e) => Object.hasOwn(e, "sharedWith"), Sn = (e) => Q(e) && e.outgoing, C
1303
1285
  }), e), []);
1304
1286
  return [...new Set(n)];
1305
1287
  };
1306
- function On({ driveItem: e, graphRoles: t, serverUrl: n }) {
1307
- let r = e.name || e.remoteItem.name, i = V(e.remoteItem.id), a = e.remoteItem.permissions.map((e) => {
1288
+ function Cn({ driveItem: e, graphRoles: t, serverUrl: n }) {
1289
+ let r = e.name || e.remoteItem.name, a = V(e.remoteItem.id), o = e.remoteItem.permissions.map((e) => {
1308
1290
  let { grantedToV2: t } = e;
1309
1291
  return {
1310
1292
  ...t.group || t.user,
1311
1293
  shareType: $(e)
1312
1294
  };
1313
- }), o = e.remoteItem.permissions.reduce((e, t) => {
1295
+ }), s = e.remoteItem.permissions.reduce((e, t) => {
1314
1296
  let n = t.invitation.invitedBy.user;
1315
1297
  return e.some(({ id: e }) => e === n.id) || e.push(n), e;
1316
- }, []), s = Xt(e.remoteItem.permissions.map($));
1317
- o.some((e) => e["@libre.graph.userType"] === "Federated") && (s = [J.remote.value]);
1318
- let c = En({
1298
+ }, []), c = Kt(e.remoteItem.permissions.map($));
1299
+ s.some((e) => e["@libre.graph.userType"] === "Federated") && (c = [J.remote.value]);
1300
+ let l = xn({
1319
1301
  driveItem: e,
1320
1302
  graphRoles: t
1321
- }), l = Dn({
1303
+ }), u = Sn({
1322
1304
  driveItem: e,
1323
- shareRoles: c
1324
- }), u = {
1305
+ shareRoles: l
1306
+ }), d = {
1325
1307
  id: e.id,
1326
1308
  remoteItemId: e.remoteItem.id,
1327
1309
  driveId: e.parentReference?.driveId,
@@ -1329,45 +1311,46 @@ function On({ driveItem: e, graphRoles: t, serverUrl: n }) {
1329
1311
  name: r,
1330
1312
  fileId: e.remoteItem.id,
1331
1313
  size: e.size,
1332
- storageId: i,
1314
+ storageId: a,
1333
1315
  parentFolderId: e.parentReference?.id,
1334
1316
  sdate: e.remoteItem.permissions[0].createdDateTime,
1335
1317
  tags: [],
1336
1318
  webDavPath: X(e.remoteItem.id, "/"),
1337
- sharedBy: o,
1319
+ sharedBy: s,
1338
1320
  owner: e.remoteItem.createdBy?.user,
1339
- sharedWith: a,
1340
- shareTypes: s,
1321
+ sharedWith: o,
1322
+ shareTypes: c,
1341
1323
  isFolder: !!e.folder,
1342
1324
  type: e.folder ? "folder" : "file",
1343
1325
  mimeType: e.file?.mimeType || "httpd/unix-directory",
1344
1326
  mdate: e.lastModifiedDateTime ? new Date(e.lastModifiedDateTime).toUTCString() : void 0,
1345
1327
  syncEnabled: e["@client.synchronize"],
1346
1328
  hidden: e["@UI.Hidden"],
1347
- shareRoles: c,
1348
- sharePermissions: l,
1329
+ shareRoles: l,
1330
+ sharePermissions: u,
1349
1331
  outgoing: !1,
1350
- privateLink: d(n, "f", e.remoteItem.id),
1332
+ privateLink: i(n, "f", e.remoteItem.id),
1351
1333
  hasPreview: () => !!e.thumbnails,
1352
1334
  canRename: () => e["@client.synchronize"],
1353
- canDownload: () => l.includes(G.readContent),
1354
- canUpload: () => l.includes(G.createUpload),
1355
- canCreate: () => l.includes(G.createChildren),
1356
- canBeDeleted: () => l.includes(G.deleteStandard),
1357
- canEditTags: () => l.includes(G.createUpload),
1335
+ canDownload: () => u.includes(G.readContent),
1336
+ canUpload: () => u.includes(G.createUpload),
1337
+ canCreate: () => u.includes(G.createChildren),
1338
+ canBeDeleted: () => u.includes(G.deleteStandard),
1339
+ canEditTags: () => u.includes(G.createUpload),
1340
+ canListVersions: () => !e.folder && u.includes(G.readVersions),
1358
1341
  isMounted: () => !1,
1359
1342
  isReceivedShare: () => !0,
1360
1343
  canShare: () => !1,
1361
1344
  isShareRoot: () => !0,
1362
1345
  getDomSelector: () => B(e.id)
1363
1346
  };
1364
- return u.extension = U(u), u;
1347
+ return d.extension = U(d), d;
1365
1348
  }
1366
- function kn({ driveItem: e, user: t, serverUrl: n }) {
1367
- let r = V(e.id), i = d(e.parentReference.path, e.name), a = {
1349
+ function wn({ driveItem: e, user: t, serverUrl: n }) {
1350
+ let r = V(e.id), a = i(e.parentReference.path, e.name), o = {
1368
1351
  id: e.id,
1369
1352
  driveId: e.parentReference?.driveId,
1370
- path: i,
1353
+ path: a,
1371
1354
  name: e.name,
1372
1355
  fileId: e.id,
1373
1356
  size: e.size,
@@ -1375,7 +1358,7 @@ function kn({ driveItem: e, user: t, serverUrl: n }) {
1375
1358
  parentFolderId: e.parentReference?.id,
1376
1359
  sdate: e.permissions[0].createdDateTime,
1377
1360
  tags: [],
1378
- webDavPath: X(r, i),
1361
+ webDavPath: X(r, a),
1379
1362
  sharedBy: [{
1380
1363
  id: t.id,
1381
1364
  displayName: t.displayName
@@ -1401,7 +1384,7 @@ function kn({ driveItem: e, user: t, serverUrl: n }) {
1401
1384
  type: e.folder ? "folder" : "file",
1402
1385
  mimeType: e.file?.mimeType || "httpd/unix-directory",
1403
1386
  outgoing: !0,
1404
- privateLink: d(n, "f", e.id),
1387
+ privateLink: i(n, "f", e.id),
1405
1388
  hasPreview: () => !!e.thumbnails,
1406
1389
  canRename: () => !0,
1407
1390
  canDownload: () => !0,
@@ -1409,15 +1392,16 @@ function kn({ driveItem: e, user: t, serverUrl: n }) {
1409
1392
  canCreate: () => !0,
1410
1393
  canBeDeleted: () => !0,
1411
1394
  canEditTags: () => !0,
1395
+ canListVersions: () => !e.folder,
1412
1396
  isMounted: () => !1,
1413
1397
  isShareRoot: () => !1,
1414
1398
  isReceivedShare: () => !0,
1415
1399
  canShare: () => !0,
1416
1400
  getDomSelector: () => B(e.id)
1417
1401
  };
1418
- return a.extension = U(a), a;
1402
+ return o.extension = U(o), o;
1419
1403
  }
1420
- function An({ graphPermission: e, graphRoles: t, resourceId: n, indirect: r = !1 }) {
1404
+ function Tn({ graphPermission: e, graphRoles: t, resourceId: n, indirect: r = !1 }) {
1421
1405
  let i = t[e.roles?.[0]], a = e.invitation?.invitedBy?.user;
1422
1406
  return {
1423
1407
  id: e.id,
@@ -1435,7 +1419,7 @@ function An({ graphPermission: e, graphRoles: t, resourceId: n, indirect: r = !1
1435
1419
  expirationDateTime: e.expirationDateTime
1436
1420
  };
1437
1421
  }
1438
- function jn({ graphPermission: e, resourceId: t, indirect: n = !1 }) {
1422
+ function En({ graphPermission: e, resourceId: t, indirect: n = !1 }) {
1439
1423
  let r = e.invitation?.invitedBy?.user;
1440
1424
  return {
1441
1425
  id: e.id,
@@ -1460,4 +1444,4 @@ function $({ link: e, grantedToV2: t }) {
1460
1444
  return e ? J.link.value : t?.group ? J.group.value : t?.user?.["@libre.graph.userType"] === "Federated" ? J.remote.value : J.user.value;
1461
1445
  }
1462
1446
  //#endregion
1463
- export { f as $, J as A, V as B, pn as C, fn as D, mn as E, B as F, y as G, rn as H, U as I, _ as J, re as K, tn as L, sn as M, on as N, un as O, an as P, p as Q, H as R, cn as S, dn as T, Qt as U, $t as V, ee as W, h as X, g as Y, m as Z, hn as _, Dn as a, _n as b, Cn as c, Q as d, yn as f, X as g, xn as h, kn as i, G as j, q as k, Tn as l, Z as m, On as n, En as o, bn as p, C as q, jn as r, wn as s, An as t, Sn as u, gn as v, Y as w, ln as x, vn as y, nn as z };
1447
+ export { J as A, Yt as B, cn as C, sn as D, ln as E, U as F, ne as G, Jt as H, Zt as I, f as J, b as K, H as L, tn as M, en as N, an as O, B as P, Qt as R, nn as S, on as T, g as U, $t as V, h as W, un as _, Sn as a, fn as b, vn as c, Q as d, mn as f, X as g, gn as h, wn as i, G as j, q as k, bn as l, Z as m, Cn as n, xn as o, hn as p, p as q, En as r, yn as s, Tn as t, _n as u, dn as v, Y as w, rn as x, pn as y, V as z };