@opencloud-eu/web-client 6.0.0 → 6.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/axios-B1HWJqDx.js +1682 -0
- package/dist/dist-SL1_CMpG.js +809 -0
- package/dist/generated-DPf3CPe4.js +3317 -0
- package/dist/graph-Cld6mTON.js +372 -0
- package/dist/helpers-DoHY9e_0.js +1463 -0
- package/dist/ocs-B7FkclLT.js +2919 -0
- package/dist/src/graph/activities/activities.d.ts +2 -2
- package/dist/src/graph/activities/types.d.ts +2 -2
- package/dist/src/graph/applications/applications.d.ts +2 -2
- package/dist/src/graph/applications/types.d.ts +2 -2
- package/dist/src/graph/driveItems/driveItems.d.ts +2 -2
- package/dist/src/graph/driveItems/types.d.ts +3 -1
- package/dist/src/graph/drives/drives.d.ts +2 -2
- package/dist/src/graph/drives/types.d.ts +4 -3
- package/dist/src/graph/generated/api.d.ts +394 -1720
- package/dist/src/graph/generated/base.d.ts +11 -24
- package/dist/src/graph/generated/common.d.ts +15 -35
- package/dist/src/graph/generated/configuration.d.ts +24 -17
- package/dist/src/graph/generated/index.d.ts +2 -2
- package/dist/src/graph/groups/groups.d.ts +2 -2
- package/dist/src/graph/groups/types.d.ts +2 -2
- package/dist/src/graph/index.d.ts +2 -2
- package/dist/src/graph/permissions/permissions.d.ts +2 -2
- package/dist/src/graph/permissions/types.d.ts +2 -2
- package/dist/src/graph/photos/photo.d.ts +2 -2
- package/dist/src/graph/photos/types.d.ts +1 -1
- package/dist/src/graph/tags/tags.d.ts +2 -2
- package/dist/src/graph/tags/types.d.ts +2 -2
- package/dist/src/graph/types.d.ts +2 -2
- package/dist/src/graph/users/types.d.ts +2 -2
- package/dist/src/graph/users/users.d.ts +2 -2
- package/dist/src/helpers/space/functions.d.ts +1 -1
- package/dist/src/webdav/clearTrashBin.d.ts +1 -1
- package/dist/src/webdav/copyFiles.d.ts +1 -1
- package/dist/src/webdav/deleteFile.d.ts +1 -1
- package/dist/src/webdav/listFileVersions.d.ts +1 -1
- package/dist/src/webdav/moveFiles.d.ts +1 -1
- package/dist/src/webdav/putFileContents.d.ts +1 -1
- package/dist/src/webdav/restoreFile.d.ts +1 -1
- package/dist/src/webdav/restoreFileVersion.d.ts +1 -1
- package/dist/src/webdav/setFavorite.d.ts +1 -1
- package/dist/src/webdav/types.d.ts +0 -2
- package/dist/toString-DAQZ_8iK.js +287 -0
- package/dist/web-client/graph/generated.js +2 -5757
- package/dist/web-client/graph.js +2 -5
- package/dist/web-client/ocs.js +2 -5
- package/dist/web-client/sse.js +195 -201
- package/dist/web-client/webdav.js +3 -10
- package/dist/web-client.js +6 -82
- package/dist/webdav-BMNOaQXh.js +4425 -0
- package/package.json +9 -15
- package/dist/functions-BBKWOL6l.js +0 -1189
- package/dist/functions-VxhUeT1u.cjs +0 -1
- package/dist/index-BYnmk_Nt.cjs +0 -13
- package/dist/index-Bf956okn.js +0 -3874
- package/dist/index-Bjx4f50a.js +0 -1999
- package/dist/index-C32gBO3b.cjs +0 -6
- package/dist/index-D0bnLDAA.cjs +0 -1
- package/dist/index-Di51ZQKD.cjs +0 -4
- package/dist/index-Dn8UfKx7.js +0 -1520
- package/dist/index-Sp7XASDj.js +0 -688
- package/dist/index-_S-l3FmE.cjs +0 -1
- package/dist/index-cttW6Cve.js +0 -1018
- package/dist/src/webdav/listFavoriteFiles.d.ts +0 -12
- package/dist/toString-CKeGA2IK.js +0 -255
- package/dist/toString-DsGM1XcL.cjs +0 -1
- package/dist/vite.config.d.ts +0 -2
- package/dist/web-client/graph/generated.cjs +0 -1
- package/dist/web-client/graph.cjs +0 -1
- package/dist/web-client/ocs.cjs +0 -1
- package/dist/web-client/sse.cjs +0 -2
- package/dist/web-client/webdav.cjs +0 -1
- package/dist/web-client.cjs +0 -1
|
@@ -0,0 +1,1463 @@
|
|
|
1
|
+
import { a as e, i as t, n, r } from "./axios-B1HWJqDx.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-DAQZ_8iK.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
|
|
22
|
+
//#region src/helpers/publicLink/functions.ts
|
|
23
|
+
function g(e, t = "") {
|
|
24
|
+
return `/public-files/${e}/${t}`.split("/").filter(Boolean).join("/");
|
|
25
|
+
}
|
|
26
|
+
function _(e, t = "") {
|
|
27
|
+
return `/ocm/${e}/${t}`.split("/").filter(Boolean).join("/");
|
|
28
|
+
}
|
|
29
|
+
//#endregion
|
|
30
|
+
//#region src/webdav/constants/dav.ts
|
|
31
|
+
var v = /* @__PURE__ */ e((/* @__PURE__ */ t(((e, t) => {
|
|
32
|
+
n();
|
|
33
|
+
function i(e) {
|
|
34
|
+
if (typeof e != "string") throw TypeError("Path must be a string. Received " + JSON.stringify(e));
|
|
35
|
+
}
|
|
36
|
+
function a(e, t) {
|
|
37
|
+
for (var n = "", r = 0, i = -1, a = 0, o, s = 0; s <= e.length; ++s) {
|
|
38
|
+
if (s < e.length) o = e.charCodeAt(s);
|
|
39
|
+
else if (o === 47) break;
|
|
40
|
+
else o = 47;
|
|
41
|
+
if (o === 47) {
|
|
42
|
+
if (!(i === s - 1 || a === 1)) if (i !== s - 1 && a === 2) {
|
|
43
|
+
if (n.length < 2 || r !== 2 || n.charCodeAt(n.length - 1) !== 46 || n.charCodeAt(n.length - 2) !== 46) {
|
|
44
|
+
if (n.length > 2) {
|
|
45
|
+
var c = n.lastIndexOf("/");
|
|
46
|
+
if (c !== n.length - 1) {
|
|
47
|
+
c === -1 ? (n = "", r = 0) : (n = n.slice(0, c), r = n.length - 1 - n.lastIndexOf("/")), i = s, a = 0;
|
|
48
|
+
continue;
|
|
49
|
+
}
|
|
50
|
+
} else if (n.length === 2 || n.length === 1) {
|
|
51
|
+
n = "", r = 0, i = s, a = 0;
|
|
52
|
+
continue;
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
t && (n.length > 0 ? n += "/.." : n = "..", r = 2);
|
|
56
|
+
} else n.length > 0 ? n += "/" + e.slice(i + 1, s) : n = e.slice(i + 1, s), r = s - i - 1;
|
|
57
|
+
i = s, a = 0;
|
|
58
|
+
} else o === 46 && a !== -1 ? ++a : a = -1;
|
|
59
|
+
}
|
|
60
|
+
return n;
|
|
61
|
+
}
|
|
62
|
+
function o(e, t) {
|
|
63
|
+
var n = t.dir || t.root, r = t.base || (t.name || "") + (t.ext || "");
|
|
64
|
+
return n ? n === t.root ? n + r : n + e + r : r;
|
|
65
|
+
}
|
|
66
|
+
var s = {
|
|
67
|
+
resolve: function() {
|
|
68
|
+
for (var e = "", t = !1, n, o = arguments.length - 1; o >= -1 && !t; o--) {
|
|
69
|
+
var s;
|
|
70
|
+
o >= 0 ? s = arguments[o] : (n === void 0 && (n = r.cwd()), s = n), i(s), s.length !== 0 && (e = s + "/" + e, t = s.charCodeAt(0) === 47);
|
|
71
|
+
}
|
|
72
|
+
return e = a(e, !t), t ? e.length > 0 ? "/" + e : "/" : e.length > 0 ? e : ".";
|
|
73
|
+
},
|
|
74
|
+
normalize: function(e) {
|
|
75
|
+
if (i(e), e.length === 0) return ".";
|
|
76
|
+
var t = e.charCodeAt(0) === 47, n = e.charCodeAt(e.length - 1) === 47;
|
|
77
|
+
return e = a(e, !t), e.length === 0 && !t && (e = "."), e.length > 0 && n && (e += "/"), t ? "/" + e : e;
|
|
78
|
+
},
|
|
79
|
+
isAbsolute: function(e) {
|
|
80
|
+
return i(e), e.length > 0 && e.charCodeAt(0) === 47;
|
|
81
|
+
},
|
|
82
|
+
join: function() {
|
|
83
|
+
if (arguments.length === 0) return ".";
|
|
84
|
+
for (var e, t = 0; t < arguments.length; ++t) {
|
|
85
|
+
var n = arguments[t];
|
|
86
|
+
i(n), n.length > 0 && (e === void 0 ? e = n : e += "/" + n);
|
|
87
|
+
}
|
|
88
|
+
return e === void 0 ? "." : s.normalize(e);
|
|
89
|
+
},
|
|
90
|
+
relative: function(e, t) {
|
|
91
|
+
if (i(e), i(t), e === t || (e = s.resolve(e), t = s.resolve(t), e === t)) return "";
|
|
92
|
+
for (var n = 1; n < e.length && e.charCodeAt(n) === 47; ++n);
|
|
93
|
+
for (var r = e.length, a = r - n, o = 1; o < t.length && t.charCodeAt(o) === 47; ++o);
|
|
94
|
+
for (var c = t.length - o, l = a < c ? a : c, u = -1, d = 0; d <= l; ++d) {
|
|
95
|
+
if (d === l) {
|
|
96
|
+
if (c > l) {
|
|
97
|
+
if (t.charCodeAt(o + d) === 47) return t.slice(o + d + 1);
|
|
98
|
+
if (d === 0) return t.slice(o + d);
|
|
99
|
+
} else a > l && (e.charCodeAt(n + d) === 47 ? u = d : d === 0 && (u = 0));
|
|
100
|
+
break;
|
|
101
|
+
}
|
|
102
|
+
var f = e.charCodeAt(n + d);
|
|
103
|
+
if (f !== t.charCodeAt(o + d)) break;
|
|
104
|
+
f === 47 && (u = d);
|
|
105
|
+
}
|
|
106
|
+
var p = "";
|
|
107
|
+
for (d = n + u + 1; d <= r; ++d) (d === r || e.charCodeAt(d) === 47) && (p.length === 0 ? p += ".." : p += "/..");
|
|
108
|
+
return p.length > 0 ? p + t.slice(o + u) : (o += u, t.charCodeAt(o) === 47 && ++o, t.slice(o));
|
|
109
|
+
},
|
|
110
|
+
_makeLong: function(e) {
|
|
111
|
+
return e;
|
|
112
|
+
},
|
|
113
|
+
dirname: function(e) {
|
|
114
|
+
if (i(e), e.length === 0) return ".";
|
|
115
|
+
for (var t = e.charCodeAt(0), n = t === 47, r = -1, a = !0, o = e.length - 1; o >= 1; --o) if (t = e.charCodeAt(o), t === 47) {
|
|
116
|
+
if (!a) {
|
|
117
|
+
r = o;
|
|
118
|
+
break;
|
|
119
|
+
}
|
|
120
|
+
} else a = !1;
|
|
121
|
+
return r === -1 ? n ? "/" : "." : n && r === 1 ? "//" : e.slice(0, r);
|
|
122
|
+
},
|
|
123
|
+
basename: function(e, t) {
|
|
124
|
+
if (t !== void 0 && typeof t != "string") throw TypeError("\"ext\" argument must be a string");
|
|
125
|
+
i(e);
|
|
126
|
+
var n = 0, r = -1, a = !0, o;
|
|
127
|
+
if (t !== void 0 && t.length > 0 && t.length <= e.length) {
|
|
128
|
+
if (t.length === e.length && t === e) return "";
|
|
129
|
+
var s = t.length - 1, c = -1;
|
|
130
|
+
for (o = e.length - 1; o >= 0; --o) {
|
|
131
|
+
var l = e.charCodeAt(o);
|
|
132
|
+
if (l === 47) {
|
|
133
|
+
if (!a) {
|
|
134
|
+
n = o + 1;
|
|
135
|
+
break;
|
|
136
|
+
}
|
|
137
|
+
} else c === -1 && (a = !1, c = o + 1), s >= 0 && (l === t.charCodeAt(s) ? --s === -1 && (r = o) : (s = -1, r = c));
|
|
138
|
+
}
|
|
139
|
+
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
|
+
}
|
|
149
|
+
},
|
|
150
|
+
extname: function(e) {
|
|
151
|
+
i(e);
|
|
152
|
+
for (var t = -1, n = 0, r = -1, a = !0, o = 0, s = e.length - 1; s >= 0; --s) {
|
|
153
|
+
var c = e.charCodeAt(s);
|
|
154
|
+
if (c === 47) {
|
|
155
|
+
if (!a) {
|
|
156
|
+
n = s + 1;
|
|
157
|
+
break;
|
|
158
|
+
}
|
|
159
|
+
continue;
|
|
160
|
+
}
|
|
161
|
+
r === -1 && (a = !1, r = s + 1), c === 46 ? t === -1 ? t = s : o !== 1 && (o = 1) : t !== -1 && (o = -1);
|
|
162
|
+
}
|
|
163
|
+
return t === -1 || r === -1 || o === 0 || o === 1 && t === r - 1 && t === n + 1 ? "" : e.slice(t, r);
|
|
164
|
+
},
|
|
165
|
+
format: function(e) {
|
|
166
|
+
if (typeof e != "object" || !e) throw TypeError("The \"pathObject\" argument must be of type Object. Received type " + typeof e);
|
|
167
|
+
return o("/", e);
|
|
168
|
+
},
|
|
169
|
+
parse: function(e) {
|
|
170
|
+
i(e);
|
|
171
|
+
var t = {
|
|
172
|
+
root: "",
|
|
173
|
+
dir: "",
|
|
174
|
+
base: "",
|
|
175
|
+
ext: "",
|
|
176
|
+
name: ""
|
|
177
|
+
};
|
|
178
|
+
if (e.length === 0) return t;
|
|
179
|
+
var n = e.charCodeAt(0), r = n === 47, a;
|
|
180
|
+
r ? (t.root = "/", a = 1) : a = 0;
|
|
181
|
+
for (var o = -1, s = 0, c = -1, l = !0, u = e.length - 1, d = 0; u >= a; --u) {
|
|
182
|
+
if (n = e.charCodeAt(u), n === 47) {
|
|
183
|
+
if (!l) {
|
|
184
|
+
s = u + 1;
|
|
185
|
+
break;
|
|
186
|
+
}
|
|
187
|
+
continue;
|
|
188
|
+
}
|
|
189
|
+
c === -1 && (l = !1, c = u + 1), n === 46 ? o === -1 ? o = u : d !== 1 && (d = 1) : o !== -1 && (d = -1);
|
|
190
|
+
}
|
|
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;
|
|
192
|
+
},
|
|
193
|
+
sep: "/",
|
|
194
|
+
delimiter: ":",
|
|
195
|
+
win32: null,
|
|
196
|
+
posix: null
|
|
197
|
+
};
|
|
198
|
+
s.posix = s, t.exports = s;
|
|
199
|
+
})))(), 1), y = class {
|
|
200
|
+
static Shared = "S";
|
|
201
|
+
static Shareable = "R";
|
|
202
|
+
static Mounted = "M";
|
|
203
|
+
static Deletable = "D";
|
|
204
|
+
static Renameable = "N";
|
|
205
|
+
static Moveable = "V";
|
|
206
|
+
static Updateable = "NV";
|
|
207
|
+
static FileUpdateable = "W";
|
|
208
|
+
static FolderCreateable = "CK";
|
|
209
|
+
static Deny = "Z";
|
|
210
|
+
static SecureView = "X";
|
|
211
|
+
}, ee = /* @__PURE__ */ function(e) {
|
|
212
|
+
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) => ({
|
|
214
|
+
value: e,
|
|
215
|
+
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"),
|
|
229
|
+
Audio: {
|
|
230
|
+
value: "audio",
|
|
231
|
+
type: null
|
|
232
|
+
},
|
|
233
|
+
Location: {
|
|
234
|
+
value: "location",
|
|
235
|
+
type: null
|
|
236
|
+
},
|
|
237
|
+
Image: {
|
|
238
|
+
value: "image",
|
|
239
|
+
type: null
|
|
240
|
+
},
|
|
241
|
+
Photo: {
|
|
242
|
+
value: "photo",
|
|
243
|
+
type: null
|
|
244
|
+
},
|
|
245
|
+
ETag: x("getetag"),
|
|
246
|
+
MimeType: x("getcontenttype"),
|
|
247
|
+
ResourceType: ((e) => b(e))("resourcetype"),
|
|
248
|
+
LockDiscovery: {
|
|
249
|
+
value: "lockdiscovery",
|
|
250
|
+
type: null
|
|
251
|
+
},
|
|
252
|
+
LockOwner: x("owner"),
|
|
253
|
+
LockTime: x("locktime"),
|
|
254
|
+
ActiveLock: {
|
|
255
|
+
value: "activelock",
|
|
256
|
+
type: null
|
|
257
|
+
},
|
|
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"),
|
|
265
|
+
ShareTypes: {
|
|
266
|
+
value: "share-types",
|
|
267
|
+
type: null
|
|
268
|
+
},
|
|
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 {
|
|
279
|
+
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
|
|
305
|
+
];
|
|
306
|
+
static PublicLink = e.Default.concat([
|
|
307
|
+
C.PublicLinkItemType,
|
|
308
|
+
C.PublicLinkPermission,
|
|
309
|
+
C.PublicLinkExpiration,
|
|
310
|
+
C.PublicLinkShareDate,
|
|
311
|
+
C.PublicLinkShareOwner
|
|
312
|
+
]);
|
|
313
|
+
static Trashbin = [
|
|
314
|
+
C.ContentLength,
|
|
315
|
+
C.ResourceType,
|
|
316
|
+
C.TrashbinOriginalLocation,
|
|
317
|
+
C.TrashbinOriginalFilename,
|
|
318
|
+
C.TrashbinDeletedDate,
|
|
319
|
+
C.Permissions,
|
|
320
|
+
C.FileParent
|
|
321
|
+
];
|
|
322
|
+
static DavNamespace = [
|
|
323
|
+
C.ContentLength,
|
|
324
|
+
C.LastModifiedDate,
|
|
325
|
+
C.ETag,
|
|
326
|
+
C.MimeType,
|
|
327
|
+
C.ResourceType,
|
|
328
|
+
C.LockDiscovery,
|
|
329
|
+
C.ActiveLock
|
|
330
|
+
];
|
|
331
|
+
};
|
|
332
|
+
//#endregion
|
|
333
|
+
//#region ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/identity.js
|
|
334
|
+
function w(e) {
|
|
335
|
+
return e;
|
|
336
|
+
}
|
|
337
|
+
//#endregion
|
|
338
|
+
//#region ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/_apply.js
|
|
339
|
+
function ie(e, t, n) {
|
|
340
|
+
switch (n.length) {
|
|
341
|
+
case 0: return e.call(t);
|
|
342
|
+
case 1: return e.call(t, n[0]);
|
|
343
|
+
case 2: return e.call(t, n[0], n[1]);
|
|
344
|
+
case 3: return e.call(t, n[0], n[1], n[2]);
|
|
345
|
+
}
|
|
346
|
+
return e.apply(t, n);
|
|
347
|
+
}
|
|
348
|
+
//#endregion
|
|
349
|
+
//#region ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/noop.js
|
|
350
|
+
function ae() {}
|
|
351
|
+
//#endregion
|
|
352
|
+
//#region ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/_shortOut.js
|
|
353
|
+
var oe = 800, se = 16, ce = Date.now;
|
|
354
|
+
function le(e) {
|
|
355
|
+
var t = 0, n = 0;
|
|
356
|
+
return function() {
|
|
357
|
+
var r = ce(), i = se - (r - n);
|
|
358
|
+
if (n = r, i > 0) {
|
|
359
|
+
if (++t >= oe) return arguments[0];
|
|
360
|
+
} else t = 0;
|
|
361
|
+
return e.apply(void 0, arguments);
|
|
362
|
+
};
|
|
363
|
+
}
|
|
364
|
+
//#endregion
|
|
365
|
+
//#region ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/constant.js
|
|
366
|
+
function ue(e) {
|
|
367
|
+
return function() {
|
|
368
|
+
return e;
|
|
369
|
+
};
|
|
370
|
+
}
|
|
371
|
+
//#endregion
|
|
372
|
+
//#region ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/_defineProperty.js
|
|
373
|
+
var de = function() {
|
|
374
|
+
try {
|
|
375
|
+
var e = l(Object, "defineProperty");
|
|
376
|
+
return e({}, "", {}), e;
|
|
377
|
+
} catch {}
|
|
378
|
+
}(), fe = le(de ? function(e, t) {
|
|
379
|
+
return de(e, "toString", {
|
|
380
|
+
configurable: !0,
|
|
381
|
+
enumerable: !1,
|
|
382
|
+
value: ue(t),
|
|
383
|
+
writable: !0
|
|
384
|
+
});
|
|
385
|
+
} : w);
|
|
386
|
+
//#endregion
|
|
387
|
+
//#region ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/_baseFindIndex.js
|
|
388
|
+
function pe(e, t, n, r) {
|
|
389
|
+
for (var i = e.length, a = n + (r ? 1 : -1); r ? a-- : ++a < i;) if (t(e[a], a, e)) return a;
|
|
390
|
+
return -1;
|
|
391
|
+
}
|
|
392
|
+
//#endregion
|
|
393
|
+
//#region ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/_baseIsNaN.js
|
|
394
|
+
function me(e) {
|
|
395
|
+
return e !== e;
|
|
396
|
+
}
|
|
397
|
+
//#endregion
|
|
398
|
+
//#region ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/_strictIndexOf.js
|
|
399
|
+
function he(e, t, n) {
|
|
400
|
+
for (var r = n - 1, i = e.length; ++r < i;) if (e[r] === t) return r;
|
|
401
|
+
return -1;
|
|
402
|
+
}
|
|
403
|
+
//#endregion
|
|
404
|
+
//#region ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/_baseIndexOf.js
|
|
405
|
+
function ge(e, t, n) {
|
|
406
|
+
return t === t ? he(e, t, n) : pe(e, me, n);
|
|
407
|
+
}
|
|
408
|
+
//#endregion
|
|
409
|
+
//#region ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/_arrayIncludes.js
|
|
410
|
+
function _e(e, t) {
|
|
411
|
+
return !!(e != null && e.length) && ge(e, t, 0) > -1;
|
|
412
|
+
}
|
|
413
|
+
//#endregion
|
|
414
|
+
//#region ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/_overRest.js
|
|
415
|
+
var ve = Math.max;
|
|
416
|
+
function ye(e, t, n) {
|
|
417
|
+
return t = ve(t === void 0 ? e.length - 1 : t, 0), function() {
|
|
418
|
+
for (var r = arguments, i = -1, a = ve(r.length - t, 0), o = Array(a); ++i < a;) o[i] = r[t + i];
|
|
419
|
+
i = -1;
|
|
420
|
+
for (var s = Array(t + 1); ++i < t;) s[i] = r[i];
|
|
421
|
+
return s[t] = n(o), ie(e, this, s);
|
|
422
|
+
};
|
|
423
|
+
}
|
|
424
|
+
//#endregion
|
|
425
|
+
//#region ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/_baseRest.js
|
|
426
|
+
function be(e, t) {
|
|
427
|
+
return fe(ye(e, t, w), e + "");
|
|
428
|
+
}
|
|
429
|
+
//#endregion
|
|
430
|
+
//#region ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/isLength.js
|
|
431
|
+
var xe = 9007199254740991;
|
|
432
|
+
function Se(e) {
|
|
433
|
+
return typeof e == "number" && e > -1 && e % 1 == 0 && e <= xe;
|
|
434
|
+
}
|
|
435
|
+
//#endregion
|
|
436
|
+
//#region ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/isArrayLike.js
|
|
437
|
+
function Ce(e) {
|
|
438
|
+
return e != null && Se(e.length) && !a(e);
|
|
439
|
+
}
|
|
440
|
+
//#endregion
|
|
441
|
+
//#region ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/_baseUnary.js
|
|
442
|
+
function we(e) {
|
|
443
|
+
return function(t) {
|
|
444
|
+
return e(t);
|
|
445
|
+
};
|
|
446
|
+
}
|
|
447
|
+
//#endregion
|
|
448
|
+
//#region ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/_baseSlice.js
|
|
449
|
+
function Te(e, t, n) {
|
|
450
|
+
var r = -1, i = e.length;
|
|
451
|
+
t < 0 && (t = -t > i ? 0 : i + t), n = n > i ? i : n, n < 0 && (n += i), i = t > n ? 0 : n - t >>> 0, t >>>= 0;
|
|
452
|
+
for (var a = Array(i); ++r < i;) a[r] = e[r + t];
|
|
453
|
+
return a;
|
|
454
|
+
}
|
|
455
|
+
//#endregion
|
|
456
|
+
//#region ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/_castSlice.js
|
|
457
|
+
function Ee(e, t, n) {
|
|
458
|
+
var r = e.length;
|
|
459
|
+
return n = n === void 0 ? r : n, !t && n >= r ? e : Te(e, t, n);
|
|
460
|
+
}
|
|
461
|
+
//#endregion
|
|
462
|
+
//#region ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/_hasUnicode.js
|
|
463
|
+
var De = RegExp("[\\u200d\\ud800-\\udfff\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff\\ufe0e\\ufe0f]");
|
|
464
|
+
function Oe(e) {
|
|
465
|
+
return De.test(e);
|
|
466
|
+
}
|
|
467
|
+
//#endregion
|
|
468
|
+
//#region ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/_asciiToArray.js
|
|
469
|
+
function ke(e) {
|
|
470
|
+
return e.split("");
|
|
471
|
+
}
|
|
472
|
+
//#endregion
|
|
473
|
+
//#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 + "(?:" + [
|
|
475
|
+
Fe,
|
|
476
|
+
Ie,
|
|
477
|
+
Le
|
|
478
|
+
].join("|") + ")" + Be + ze + ")*", He = Be + ze + Ve, Ue = "(?:" + [
|
|
479
|
+
Fe + T + "?",
|
|
480
|
+
T,
|
|
481
|
+
Ie,
|
|
482
|
+
Le,
|
|
483
|
+
Ne
|
|
484
|
+
].join("|") + ")", We = RegExp(E + "(?=" + E + ")|" + Ue + He, "g");
|
|
485
|
+
function Ge(e) {
|
|
486
|
+
return e.match(We) || [];
|
|
487
|
+
}
|
|
488
|
+
//#endregion
|
|
489
|
+
//#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);
|
|
492
|
+
}
|
|
493
|
+
//#endregion
|
|
494
|
+
//#region ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/_createCaseFirst.js
|
|
495
|
+
function qe(e) {
|
|
496
|
+
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);
|
|
499
|
+
return r[e]() + i;
|
|
500
|
+
};
|
|
501
|
+
}
|
|
502
|
+
//#endregion
|
|
503
|
+
//#region ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/upperFirst.js
|
|
504
|
+
var Je = qe("toUpperCase");
|
|
505
|
+
//#endregion
|
|
506
|
+
//#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());
|
|
509
|
+
}
|
|
510
|
+
//#endregion
|
|
511
|
+
//#region ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/_arrayReduce.js
|
|
512
|
+
function Xe(e, t, n, r) {
|
|
513
|
+
var i = -1, a = e == null ? 0 : e.length;
|
|
514
|
+
for (r && a && (n = e[++i]); ++i < a;) n = t(n, e[i], i, e);
|
|
515
|
+
return n;
|
|
516
|
+
}
|
|
517
|
+
//#endregion
|
|
518
|
+
//#region ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/_basePropertyOf.js
|
|
519
|
+
function Ze(e) {
|
|
520
|
+
return function(t) {
|
|
521
|
+
return e?.[t];
|
|
522
|
+
};
|
|
523
|
+
}
|
|
524
|
+
//#endregion
|
|
525
|
+
//#region ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/_deburrLetter.js
|
|
526
|
+
var Qe = Ze({
|
|
527
|
+
À: "A",
|
|
528
|
+
Á: "A",
|
|
529
|
+
Â: "A",
|
|
530
|
+
Ã: "A",
|
|
531
|
+
Ä: "A",
|
|
532
|
+
Å: "A",
|
|
533
|
+
à: "a",
|
|
534
|
+
á: "a",
|
|
535
|
+
â: "a",
|
|
536
|
+
ã: "a",
|
|
537
|
+
ä: "a",
|
|
538
|
+
å: "a",
|
|
539
|
+
Ç: "C",
|
|
540
|
+
ç: "c",
|
|
541
|
+
Ð: "D",
|
|
542
|
+
ð: "d",
|
|
543
|
+
È: "E",
|
|
544
|
+
É: "E",
|
|
545
|
+
Ê: "E",
|
|
546
|
+
Ë: "E",
|
|
547
|
+
è: "e",
|
|
548
|
+
é: "e",
|
|
549
|
+
ê: "e",
|
|
550
|
+
ë: "e",
|
|
551
|
+
Ì: "I",
|
|
552
|
+
Í: "I",
|
|
553
|
+
Î: "I",
|
|
554
|
+
Ï: "I",
|
|
555
|
+
ì: "i",
|
|
556
|
+
í: "i",
|
|
557
|
+
î: "i",
|
|
558
|
+
ï: "i",
|
|
559
|
+
Ñ: "N",
|
|
560
|
+
ñ: "n",
|
|
561
|
+
Ò: "O",
|
|
562
|
+
Ó: "O",
|
|
563
|
+
Ô: "O",
|
|
564
|
+
Õ: "O",
|
|
565
|
+
Ö: "O",
|
|
566
|
+
Ø: "O",
|
|
567
|
+
ò: "o",
|
|
568
|
+
ó: "o",
|
|
569
|
+
ô: "o",
|
|
570
|
+
õ: "o",
|
|
571
|
+
ö: "o",
|
|
572
|
+
ø: "o",
|
|
573
|
+
Ù: "U",
|
|
574
|
+
Ú: "U",
|
|
575
|
+
Û: "U",
|
|
576
|
+
Ü: "U",
|
|
577
|
+
ù: "u",
|
|
578
|
+
ú: "u",
|
|
579
|
+
û: "u",
|
|
580
|
+
ü: "u",
|
|
581
|
+
Ý: "Y",
|
|
582
|
+
ý: "y",
|
|
583
|
+
ÿ: "y",
|
|
584
|
+
Æ: "Ae",
|
|
585
|
+
æ: "ae",
|
|
586
|
+
Þ: "Th",
|
|
587
|
+
þ: "th",
|
|
588
|
+
ß: "ss",
|
|
589
|
+
Ā: "A",
|
|
590
|
+
Ă: "A",
|
|
591
|
+
Ą: "A",
|
|
592
|
+
ā: "a",
|
|
593
|
+
ă: "a",
|
|
594
|
+
ą: "a",
|
|
595
|
+
Ć: "C",
|
|
596
|
+
Ĉ: "C",
|
|
597
|
+
Ċ: "C",
|
|
598
|
+
Č: "C",
|
|
599
|
+
ć: "c",
|
|
600
|
+
ĉ: "c",
|
|
601
|
+
ċ: "c",
|
|
602
|
+
č: "c",
|
|
603
|
+
Ď: "D",
|
|
604
|
+
Đ: "D",
|
|
605
|
+
ď: "d",
|
|
606
|
+
đ: "d",
|
|
607
|
+
Ē: "E",
|
|
608
|
+
Ĕ: "E",
|
|
609
|
+
Ė: "E",
|
|
610
|
+
Ę: "E",
|
|
611
|
+
Ě: "E",
|
|
612
|
+
ē: "e",
|
|
613
|
+
ĕ: "e",
|
|
614
|
+
ė: "e",
|
|
615
|
+
ę: "e",
|
|
616
|
+
ě: "e",
|
|
617
|
+
Ĝ: "G",
|
|
618
|
+
Ğ: "G",
|
|
619
|
+
Ġ: "G",
|
|
620
|
+
Ģ: "G",
|
|
621
|
+
ĝ: "g",
|
|
622
|
+
ğ: "g",
|
|
623
|
+
ġ: "g",
|
|
624
|
+
ģ: "g",
|
|
625
|
+
Ĥ: "H",
|
|
626
|
+
Ħ: "H",
|
|
627
|
+
ĥ: "h",
|
|
628
|
+
ħ: "h",
|
|
629
|
+
Ĩ: "I",
|
|
630
|
+
Ī: "I",
|
|
631
|
+
Ĭ: "I",
|
|
632
|
+
Į: "I",
|
|
633
|
+
İ: "I",
|
|
634
|
+
ĩ: "i",
|
|
635
|
+
ī: "i",
|
|
636
|
+
ĭ: "i",
|
|
637
|
+
į: "i",
|
|
638
|
+
ı: "i",
|
|
639
|
+
Ĵ: "J",
|
|
640
|
+
ĵ: "j",
|
|
641
|
+
Ķ: "K",
|
|
642
|
+
ķ: "k",
|
|
643
|
+
ĸ: "k",
|
|
644
|
+
Ĺ: "L",
|
|
645
|
+
Ļ: "L",
|
|
646
|
+
Ľ: "L",
|
|
647
|
+
Ŀ: "L",
|
|
648
|
+
Ł: "L",
|
|
649
|
+
ĺ: "l",
|
|
650
|
+
ļ: "l",
|
|
651
|
+
ľ: "l",
|
|
652
|
+
ŀ: "l",
|
|
653
|
+
ł: "l",
|
|
654
|
+
Ń: "N",
|
|
655
|
+
Ņ: "N",
|
|
656
|
+
Ň: "N",
|
|
657
|
+
Ŋ: "N",
|
|
658
|
+
ń: "n",
|
|
659
|
+
ņ: "n",
|
|
660
|
+
ň: "n",
|
|
661
|
+
ŋ: "n",
|
|
662
|
+
Ō: "O",
|
|
663
|
+
Ŏ: "O",
|
|
664
|
+
Ő: "O",
|
|
665
|
+
ō: "o",
|
|
666
|
+
ŏ: "o",
|
|
667
|
+
ő: "o",
|
|
668
|
+
Ŕ: "R",
|
|
669
|
+
Ŗ: "R",
|
|
670
|
+
Ř: "R",
|
|
671
|
+
ŕ: "r",
|
|
672
|
+
ŗ: "r",
|
|
673
|
+
ř: "r",
|
|
674
|
+
Ś: "S",
|
|
675
|
+
Ŝ: "S",
|
|
676
|
+
Ş: "S",
|
|
677
|
+
Š: "S",
|
|
678
|
+
ś: "s",
|
|
679
|
+
ŝ: "s",
|
|
680
|
+
ş: "s",
|
|
681
|
+
š: "s",
|
|
682
|
+
Ţ: "T",
|
|
683
|
+
Ť: "T",
|
|
684
|
+
Ŧ: "T",
|
|
685
|
+
ţ: "t",
|
|
686
|
+
ť: "t",
|
|
687
|
+
ŧ: "t",
|
|
688
|
+
Ũ: "U",
|
|
689
|
+
Ū: "U",
|
|
690
|
+
Ŭ: "U",
|
|
691
|
+
Ů: "U",
|
|
692
|
+
Ű: "U",
|
|
693
|
+
Ų: "U",
|
|
694
|
+
ũ: "u",
|
|
695
|
+
ū: "u",
|
|
696
|
+
ŭ: "u",
|
|
697
|
+
ů: "u",
|
|
698
|
+
ű: "u",
|
|
699
|
+
ų: "u",
|
|
700
|
+
Ŵ: "W",
|
|
701
|
+
ŵ: "w",
|
|
702
|
+
Ŷ: "Y",
|
|
703
|
+
ŷ: "y",
|
|
704
|
+
Ÿ: "Y",
|
|
705
|
+
Ź: "Z",
|
|
706
|
+
Ż: "Z",
|
|
707
|
+
Ž: "Z",
|
|
708
|
+
ź: "z",
|
|
709
|
+
ż: "z",
|
|
710
|
+
ž: "z",
|
|
711
|
+
IJ: "IJ",
|
|
712
|
+
ij: "ij",
|
|
713
|
+
Œ: "Oe",
|
|
714
|
+
œ: "oe",
|
|
715
|
+
ʼn: "'n",
|
|
716
|
+
ſ: "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, "");
|
|
720
|
+
}
|
|
721
|
+
//#endregion
|
|
722
|
+
//#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) || [];
|
|
726
|
+
}
|
|
727
|
+
//#endregion
|
|
728
|
+
//#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);
|
|
732
|
+
}
|
|
733
|
+
//#endregion
|
|
734
|
+
//#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,
|
|
737
|
+
O,
|
|
738
|
+
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,
|
|
741
|
+
O,
|
|
742
|
+
k
|
|
743
|
+
].join("|") + ")" + At, Mt = RegExp([
|
|
744
|
+
A + "?" + St + "+" + M + "(?=" + [
|
|
745
|
+
vt,
|
|
746
|
+
A,
|
|
747
|
+
"$"
|
|
748
|
+
].join("|") + ")",
|
|
749
|
+
Et + "+" + N + "(?=" + [
|
|
750
|
+
vt,
|
|
751
|
+
A + j,
|
|
752
|
+
"$"
|
|
753
|
+
].join("|") + ")",
|
|
754
|
+
A + "?" + j + "+" + M,
|
|
755
|
+
A + "+" + N,
|
|
756
|
+
kt,
|
|
757
|
+
Ot,
|
|
758
|
+
bt,
|
|
759
|
+
jt
|
|
760
|
+
].join("|"), "g");
|
|
761
|
+
function Nt(e) {
|
|
762
|
+
return e.match(Mt) || [];
|
|
763
|
+
}
|
|
764
|
+
//#endregion
|
|
765
|
+
//#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) || [];
|
|
768
|
+
}
|
|
769
|
+
//#endregion
|
|
770
|
+
//#region ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/_createCompounder.js
|
|
771
|
+
var Ft = RegExp("['’]", "g");
|
|
772
|
+
function It(e) {
|
|
773
|
+
return function(t) {
|
|
774
|
+
return Xe(Pt(tt(t).replace(Ft, "")), e, "");
|
|
775
|
+
};
|
|
776
|
+
}
|
|
777
|
+
//#endregion
|
|
778
|
+
//#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;
|
|
784
|
+
}
|
|
785
|
+
//#endregion
|
|
786
|
+
//#region ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/_setCacheHas.js
|
|
787
|
+
function Bt(e) {
|
|
788
|
+
return this.__data__.has(e);
|
|
789
|
+
}
|
|
790
|
+
//#endregion
|
|
791
|
+
//#region ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/_SetCache.js
|
|
792
|
+
function L(e) {
|
|
793
|
+
var t = -1, n = e == null ? 0 : e.length;
|
|
794
|
+
for (this.__data__ = new s(); ++t < n;) this.add(e[t]);
|
|
795
|
+
}
|
|
796
|
+
L.prototype.add = L.prototype.push = zt, L.prototype.has = Bt;
|
|
797
|
+
//#endregion
|
|
798
|
+
//#region ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/_cacheHas.js
|
|
799
|
+
function R(e, t) {
|
|
800
|
+
return e.has(t);
|
|
801
|
+
}
|
|
802
|
+
//#endregion
|
|
803
|
+
//#region ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/_setToArray.js
|
|
804
|
+
function z(e) {
|
|
805
|
+
var t = -1, n = Array(e.size);
|
|
806
|
+
return e.forEach(function(e) {
|
|
807
|
+
n[++t] = e;
|
|
808
|
+
}), n;
|
|
809
|
+
}
|
|
810
|
+
//#endregion
|
|
811
|
+
//#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);
|
|
814
|
+
}
|
|
815
|
+
//#endregion
|
|
816
|
+
//#region ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/_arrayIncludesWith.js
|
|
817
|
+
function Ht(e, t, n) {
|
|
818
|
+
for (var r = -1, i = e == null ? 0 : e.length; ++r < i;) if (n(t, e[r])) return !0;
|
|
819
|
+
return !1;
|
|
820
|
+
}
|
|
821
|
+
//#endregion
|
|
822
|
+
//#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--;) {
|
|
826
|
+
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;
|
|
828
|
+
}
|
|
829
|
+
d = e[0];
|
|
830
|
+
var f = -1, p = s[0];
|
|
831
|
+
outer: for (; ++f < i && u.length < l;) {
|
|
832
|
+
var m = d[f], h = t ? t(m) : m;
|
|
833
|
+
if (m = n || m !== 0 ? m : 0, !(p ? R(p, h) : r(u, h, n))) {
|
|
834
|
+
for (o = a; --o;) {
|
|
835
|
+
var g = s[o];
|
|
836
|
+
if (!(g ? R(g, h) : r(e[o], h, n))) continue outer;
|
|
837
|
+
}
|
|
838
|
+
p && p.push(h), u.push(m);
|
|
839
|
+
}
|
|
840
|
+
}
|
|
841
|
+
return u;
|
|
842
|
+
}
|
|
843
|
+
//#endregion
|
|
844
|
+
//#region ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/_castArrayLikeObject.js
|
|
845
|
+
function Gt(e) {
|
|
846
|
+
return Vt(e) ? e : [];
|
|
847
|
+
}
|
|
848
|
+
//#endregion
|
|
849
|
+
//#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) {
|
|
854
|
+
return new I(e);
|
|
855
|
+
} : ae, Jt = 200;
|
|
856
|
+
function Yt(e, t, n) {
|
|
857
|
+
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);
|
|
861
|
+
if (l) return z(l);
|
|
862
|
+
o = !1, i = R, c = new L();
|
|
863
|
+
} else c = t ? [] : s;
|
|
864
|
+
outer: for (; ++r < a;) {
|
|
865
|
+
var u = e[r], d = t ? t(u) : u;
|
|
866
|
+
if (u = n || u !== 0 ? u : 0, o && d === d) {
|
|
867
|
+
for (var f = c.length; f--;) if (c[f] === d) continue outer;
|
|
868
|
+
t && c.push(d), s.push(u);
|
|
869
|
+
} else i(c, d, n) || (c !== s && c.push(d), s.push(u));
|
|
870
|
+
}
|
|
871
|
+
return s;
|
|
872
|
+
}
|
|
873
|
+
//#endregion
|
|
874
|
+
//#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) : [];
|
|
877
|
+
}
|
|
878
|
+
//#endregion
|
|
879
|
+
//#region src/helpers/resource/functions.ts
|
|
880
|
+
var Zt = { complex: [
|
|
881
|
+
"tar.bz2",
|
|
882
|
+
"tar.gz",
|
|
883
|
+
"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) => {
|
|
885
|
+
let t = e.extension || "", n = e.name || "";
|
|
886
|
+
if (!t.length) return n;
|
|
887
|
+
let r = n.lastIndexOf(`.${t}`);
|
|
888
|
+
return n.substring(0, r);
|
|
889
|
+
}, U = (e) => {
|
|
890
|
+
let t = e.name.split(".");
|
|
891
|
+
if (t.length > 2) for (let e = 0; e < t.length; e++) {
|
|
892
|
+
let n = t.slice(e, t.length).join(".");
|
|
893
|
+
if (Zt.complex.includes(n)) return n;
|
|
894
|
+
}
|
|
895
|
+
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) => {
|
|
897
|
+
if (!e) return e;
|
|
898
|
+
let t = {};
|
|
899
|
+
return Object.keys(e).forEach((n) => {
|
|
900
|
+
t[Lt(n)] = e[n];
|
|
901
|
+
}), t;
|
|
902
|
+
};
|
|
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;
|
|
905
|
+
a = e.filename.startsWith("/files") || e.filename.startsWith("/space") ? e.filename.split("/").slice(3).join("/") : e.filename, a.startsWith("/") || (a = `/${a}`);
|
|
906
|
+
let o = U({
|
|
907
|
+
...e,
|
|
908
|
+
id: r,
|
|
909
|
+
name: n,
|
|
910
|
+
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]);
|
|
913
|
+
let d = [];
|
|
914
|
+
e.props[C.ShareTypes] && (d = e.props[C.ShareTypes]["share-type"], Array.isArray(d) || (d = [d]));
|
|
915
|
+
let f = {};
|
|
916
|
+
for (let n of t || []) {
|
|
917
|
+
let t = n.split(":").pop();
|
|
918
|
+
e.props[t] && (f[n] = e.props[t]);
|
|
919
|
+
}
|
|
920
|
+
let p = {
|
|
921
|
+
id: r,
|
|
922
|
+
fileId: r,
|
|
923
|
+
storageId: V(r),
|
|
924
|
+
parentFolderId: e.props[C.FileParent],
|
|
925
|
+
mimeType: e.props[C.MimeType],
|
|
926
|
+
name: n,
|
|
927
|
+
extension: o,
|
|
928
|
+
path: a,
|
|
929
|
+
webDavPath: e.filename,
|
|
930
|
+
type: i ? "folder" : e.type,
|
|
931
|
+
isFolder: i,
|
|
932
|
+
locked: !!c,
|
|
933
|
+
lockOwner: l,
|
|
934
|
+
lockTime: u,
|
|
935
|
+
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],
|
|
941
|
+
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],
|
|
946
|
+
owner: {
|
|
947
|
+
id: e.props[C.OwnerId],
|
|
948
|
+
displayName: e.props[C.OwnerDisplayName]
|
|
949
|
+
},
|
|
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]),
|
|
955
|
+
extraProps: f,
|
|
956
|
+
hasPreview: () => e.props[C.HasPreview] === 1,
|
|
957
|
+
canUpload: function() {
|
|
958
|
+
return this.permissions.indexOf(y.FolderCreateable) >= 0;
|
|
959
|
+
},
|
|
960
|
+
canDownload: function() {
|
|
961
|
+
return this.permissions.indexOf(y.SecureView) === -1;
|
|
962
|
+
},
|
|
963
|
+
canBeDeleted: function() {
|
|
964
|
+
return this.permissions.indexOf(y.Deletable) >= 0;
|
|
965
|
+
},
|
|
966
|
+
canRename: function() {
|
|
967
|
+
return this.permissions.indexOf(y.Renameable) >= 0;
|
|
968
|
+
},
|
|
969
|
+
canShare: function({ ability: e }) {
|
|
970
|
+
return e.can("create-all", "Share") && this.permissions.indexOf(y.Shareable) >= 0;
|
|
971
|
+
},
|
|
972
|
+
canCreate: function() {
|
|
973
|
+
return this.permissions.indexOf(y.FolderCreateable) >= 0;
|
|
974
|
+
},
|
|
975
|
+
canEditTags: function() {
|
|
976
|
+
return this.permissions.indexOf(y.Updateable) >= 0 || this.permissions.indexOf(y.FileUpdateable) >= 0 || this.permissions.indexOf(y.FolderCreateable) >= 0;
|
|
977
|
+
},
|
|
978
|
+
isMounted: function() {
|
|
979
|
+
return this.permissions.indexOf(y.Mounted) >= 0;
|
|
980
|
+
},
|
|
981
|
+
isReceivedShare: function() {
|
|
982
|
+
return this.permissions.indexOf(y.Shared) >= 0;
|
|
983
|
+
},
|
|
984
|
+
isShareRoot() {
|
|
985
|
+
return e.props[C.ShareRoot] ? e.filename.split("/").length === 3 : !1;
|
|
986
|
+
},
|
|
987
|
+
getDomSelector: () => B(r)
|
|
988
|
+
};
|
|
989
|
+
return Object.defineProperty(p, "nodeId", { get() {
|
|
990
|
+
return H(this.id);
|
|
991
|
+
} }), p;
|
|
992
|
+
}
|
|
993
|
+
function on(e) {
|
|
994
|
+
let t = e.type === "directory", n = e.props[C.TrashbinOriginalFilename]?.toString(), r = U({
|
|
995
|
+
name: n,
|
|
996
|
+
type: e.type
|
|
997
|
+
}), i = v.default.basename(e.filename);
|
|
998
|
+
return {
|
|
999
|
+
type: t ? "folder" : e.type,
|
|
1000
|
+
isFolder: t,
|
|
1001
|
+
ddate: e.props[C.TrashbinDeletedDate],
|
|
1002
|
+
name: v.default.basename(n),
|
|
1003
|
+
extension: r,
|
|
1004
|
+
path: d(e.props[C.TrashbinOriginalLocation], { leadingSlash: !0 }),
|
|
1005
|
+
id: i,
|
|
1006
|
+
parentFolderId: e.props[C.FileParent],
|
|
1007
|
+
webDavPath: "",
|
|
1008
|
+
canUpload: () => !1,
|
|
1009
|
+
canDownload: () => !1,
|
|
1010
|
+
canBeDeleted: () => !0,
|
|
1011
|
+
canBeRestored: function() {
|
|
1012
|
+
return !0;
|
|
1013
|
+
},
|
|
1014
|
+
canRename: () => !1,
|
|
1015
|
+
canShare: () => !1,
|
|
1016
|
+
canCreate: () => !1,
|
|
1017
|
+
isMounted: () => !1,
|
|
1018
|
+
isReceivedShare: () => !1,
|
|
1019
|
+
hasPreview: () => !1,
|
|
1020
|
+
isShareRoot: () => !1,
|
|
1021
|
+
getDomSelector: () => B(i)
|
|
1022
|
+
};
|
|
1023
|
+
}
|
|
1024
|
+
//#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) {
|
|
1033
|
+
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
|
+
}({}), K = (e) => e, q = class {
|
|
1035
|
+
_key;
|
|
1036
|
+
_value;
|
|
1037
|
+
_label;
|
|
1038
|
+
_icon;
|
|
1039
|
+
constructor(e, t, n, r) {
|
|
1040
|
+
this._key = e, this._value = t, this._label = n, this._icon = r;
|
|
1041
|
+
}
|
|
1042
|
+
get key() {
|
|
1043
|
+
return this._key;
|
|
1044
|
+
}
|
|
1045
|
+
get value() {
|
|
1046
|
+
return this._value;
|
|
1047
|
+
}
|
|
1048
|
+
get label() {
|
|
1049
|
+
return this._label;
|
|
1050
|
+
}
|
|
1051
|
+
get icon() {
|
|
1052
|
+
return this._icon;
|
|
1053
|
+
}
|
|
1054
|
+
}, J = class {
|
|
1055
|
+
static user = new q("user", 0, K("User"), "user");
|
|
1056
|
+
static group = new q("group", 1, K("Group"), "group");
|
|
1057
|
+
static link = new q("link", 3, K("Link"), "link");
|
|
1058
|
+
static guest = new q("guest", 4, K("Guest"), "global");
|
|
1059
|
+
static remote = new q("remote", 6, K("External"), "earth");
|
|
1060
|
+
static individuals = [
|
|
1061
|
+
this.user,
|
|
1062
|
+
this.guest,
|
|
1063
|
+
this.remote
|
|
1064
|
+
];
|
|
1065
|
+
static collectives = [this.group];
|
|
1066
|
+
static unauthenticated = [this.link];
|
|
1067
|
+
static authenticated = [
|
|
1068
|
+
this.user,
|
|
1069
|
+
this.group,
|
|
1070
|
+
this.guest,
|
|
1071
|
+
this.remote
|
|
1072
|
+
];
|
|
1073
|
+
static all = [
|
|
1074
|
+
this.user,
|
|
1075
|
+
this.group,
|
|
1076
|
+
this.link,
|
|
1077
|
+
this.guest,
|
|
1078
|
+
this.remote
|
|
1079
|
+
];
|
|
1080
|
+
static isIndividual(e) {
|
|
1081
|
+
return this.individuals.includes(e);
|
|
1082
|
+
}
|
|
1083
|
+
static isCollective(e) {
|
|
1084
|
+
return this.collectives.includes(e);
|
|
1085
|
+
}
|
|
1086
|
+
static isUnauthenticated(e) {
|
|
1087
|
+
return this.unauthenticated.includes(e);
|
|
1088
|
+
}
|
|
1089
|
+
static isAuthenticated(e) {
|
|
1090
|
+
return this.authenticated.includes(e);
|
|
1091
|
+
}
|
|
1092
|
+
static getByValue(e) {
|
|
1093
|
+
return this.all.find((t) => t.value === e);
|
|
1094
|
+
}
|
|
1095
|
+
static getByValues(e) {
|
|
1096
|
+
return e.map((e) => this.getByValue(e));
|
|
1097
|
+
}
|
|
1098
|
+
static getByKeys(e) {
|
|
1099
|
+
return e.map((e) => this.all.find((t) => t.key === e));
|
|
1100
|
+
}
|
|
1101
|
+
static getValues(e) {
|
|
1102
|
+
return e.map((e) => e.value);
|
|
1103
|
+
}
|
|
1104
|
+
static containsAnyValue(e, t) {
|
|
1105
|
+
return Kt(this.getValues(e), t).length > 0;
|
|
1106
|
+
}
|
|
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";
|
|
1108
|
+
//#endregion
|
|
1109
|
+
//#region src/helpers/space/functions.ts
|
|
1110
|
+
function X(e, t) {
|
|
1111
|
+
return d("spaces", e, t, { leadingSlash: !0 });
|
|
1112
|
+
}
|
|
1113
|
+
function hn(e, t = "") {
|
|
1114
|
+
return d("spaces", "trash-bin", e, t, { leadingSlash: !0 });
|
|
1115
|
+
}
|
|
1116
|
+
function gn(e, t) {
|
|
1117
|
+
let n = e[{
|
|
1118
|
+
image: "spaceImageData",
|
|
1119
|
+
readme: "spaceReadmeData"
|
|
1120
|
+
}[t]];
|
|
1121
|
+
if (!n) return "";
|
|
1122
|
+
let r = decodeURI(n.webDavUrl).split("/"), i = r.find((t) => t.startsWith(e.id));
|
|
1123
|
+
return i ? r.slice(r.indexOf(i) + 1).join("/") : "";
|
|
1124
|
+
}
|
|
1125
|
+
function _n(e) {
|
|
1126
|
+
return e.permissions.includes(G.deletePermissions);
|
|
1127
|
+
}
|
|
1128
|
+
var vn = (e, t) => e.root.permissions?.filter((e) => {
|
|
1129
|
+
let n = [];
|
|
1130
|
+
e["@libre.graph.permissions.actions"] && (n = e["@libre.graph.permissions.actions"]);
|
|
1131
|
+
let r = t[e.roles?.[0]];
|
|
1132
|
+
return r && !n.length && (n = r.rolePermissions.find(({ condition: e }) => e === "exists @Resource.Root")?.allowedResourceActions || []), n.includes(G.deletePermissions);
|
|
1133
|
+
});
|
|
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({
|
|
1137
|
+
...e,
|
|
1138
|
+
driveType: "public",
|
|
1139
|
+
driveAlias: l,
|
|
1140
|
+
webDavPath: u
|
|
1141
|
+
}), {
|
|
1142
|
+
...n && { fileId: n },
|
|
1143
|
+
...t && { publicLinkPassword: t },
|
|
1144
|
+
...r && { publicLinkItemType: r },
|
|
1145
|
+
...i && { publicLinkPermission: parseInt(i) },
|
|
1146
|
+
...a && { publicLinkExpiration: a },
|
|
1147
|
+
...o && { publicLinkShareDate: o },
|
|
1148
|
+
...s && { publicLinkShareOwner: s },
|
|
1149
|
+
publicLinkType: c
|
|
1150
|
+
});
|
|
1151
|
+
}
|
|
1152
|
+
function bn({ driveAliasPrefix: e, id: t, shareName: n, serverUrl: r }) {
|
|
1153
|
+
let i = Z({
|
|
1154
|
+
id: t,
|
|
1155
|
+
driveAlias: `${e}/${n}`,
|
|
1156
|
+
driveType: "share",
|
|
1157
|
+
name: n,
|
|
1158
|
+
serverUrl: r
|
|
1159
|
+
});
|
|
1160
|
+
return i.rename = (t) => {
|
|
1161
|
+
i.driveAlias = `${e}/${t}`, i.name = t;
|
|
1162
|
+
}, i;
|
|
1163
|
+
}
|
|
1164
|
+
function Z(e) {
|
|
1165
|
+
let t, n;
|
|
1166
|
+
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, "remote.php/dav", i), o = d(e.webDavTrashPath || hn(e.id), { leadingSlash: !0 }), s = d(e.serverUrl, "remote.php/dav", o), c = {
|
|
1168
|
+
id: e.id,
|
|
1169
|
+
fileId: e.id,
|
|
1170
|
+
storageId: e.id,
|
|
1171
|
+
mimeType: "",
|
|
1172
|
+
name: e.name,
|
|
1173
|
+
description: e.description,
|
|
1174
|
+
extension: "",
|
|
1175
|
+
path: "/",
|
|
1176
|
+
webDavPath: i,
|
|
1177
|
+
webDavTrashPath: o,
|
|
1178
|
+
driveAlias: e.driveAlias,
|
|
1179
|
+
driveType: e.driveType,
|
|
1180
|
+
type: "space",
|
|
1181
|
+
isFolder: !0,
|
|
1182
|
+
mdate: e.lastModifiedDateTime,
|
|
1183
|
+
size: e.quota?.used || 0,
|
|
1184
|
+
tags: [],
|
|
1185
|
+
permissions: "",
|
|
1186
|
+
starred: !1,
|
|
1187
|
+
etag: "",
|
|
1188
|
+
shareTypes: [],
|
|
1189
|
+
privateLink: e.webUrl,
|
|
1190
|
+
downloadURL: "",
|
|
1191
|
+
owner: e.owner?.user,
|
|
1192
|
+
disabled: r,
|
|
1193
|
+
root: e.root,
|
|
1194
|
+
spaceQuota: e.quota,
|
|
1195
|
+
spaceImageData: t,
|
|
1196
|
+
spaceReadmeData: n,
|
|
1197
|
+
hasTrashedItems: e["@libre.graph.hasTrashedItems"] || !1,
|
|
1198
|
+
graphPermissions: void 0,
|
|
1199
|
+
canUpload: function({ user: e } = {}) {
|
|
1200
|
+
return Y(this) && this.isOwner(e) ? !0 : this.graphPermissions?.includes(G.createUpload);
|
|
1201
|
+
},
|
|
1202
|
+
canDownload: function() {
|
|
1203
|
+
return !0;
|
|
1204
|
+
},
|
|
1205
|
+
canBeDeleted: function({ ability: e } = {}) {
|
|
1206
|
+
return this.disabled ? e?.can("delete-all", "Drive") ? !0 : this.graphPermissions?.includes(G.deletePermissions) : !1;
|
|
1207
|
+
},
|
|
1208
|
+
canRename: function({ ability: e } = {}) {
|
|
1209
|
+
return e?.can("update-all", "Drive") ? !0 : this.graphPermissions?.includes(G.deletePermissions);
|
|
1210
|
+
},
|
|
1211
|
+
canEditDescription: function({ ability: e } = {}) {
|
|
1212
|
+
return e?.can("update-all", "Drive") ? !0 : this.graphPermissions?.includes(G.deletePermissions);
|
|
1213
|
+
},
|
|
1214
|
+
canRestore: function({ ability: e } = {}) {
|
|
1215
|
+
return this.disabled ? e?.can("update-all", "Drive") ? !0 : this.graphPermissions?.includes(G.deletePermissions) : !1;
|
|
1216
|
+
},
|
|
1217
|
+
canDisable: function({ ability: e } = {}) {
|
|
1218
|
+
return this.disabled ? !1 : e?.can("delete-all", "Drive") ? !0 : this.graphPermissions?.includes(G.deletePermissions);
|
|
1219
|
+
},
|
|
1220
|
+
canShare: function() {
|
|
1221
|
+
return this.graphPermissions?.includes(G.createPermissions);
|
|
1222
|
+
},
|
|
1223
|
+
canEditImage: function() {
|
|
1224
|
+
return this.disabled ? !1 : this.graphPermissions?.includes(G.deletePermissions);
|
|
1225
|
+
},
|
|
1226
|
+
canEditReadme: function() {
|
|
1227
|
+
return this.disabled ? !1 : this.graphPermissions?.includes(G.deletePermissions);
|
|
1228
|
+
},
|
|
1229
|
+
canRestoreFromTrashbin: function() {
|
|
1230
|
+
return this.graphPermissions?.includes(G.updateDeleted);
|
|
1231
|
+
},
|
|
1232
|
+
canDeleteFromTrashBin: function({ user: e } = {}) {
|
|
1233
|
+
return Y(this) && this.isOwner(e) ? !0 : this.graphPermissions?.includes(G.deletePermissions);
|
|
1234
|
+
},
|
|
1235
|
+
canListVersions: function({ user: e } = {}) {
|
|
1236
|
+
return Y(this) && this.isOwner(e) ? !0 : this.graphPermissions?.includes(G.readVersions);
|
|
1237
|
+
},
|
|
1238
|
+
canCreate: function() {
|
|
1239
|
+
return !0;
|
|
1240
|
+
},
|
|
1241
|
+
canEditTags: function() {
|
|
1242
|
+
return !1;
|
|
1243
|
+
},
|
|
1244
|
+
isMounted: function() {
|
|
1245
|
+
return !0;
|
|
1246
|
+
},
|
|
1247
|
+
isReceivedShare: function() {
|
|
1248
|
+
return !1;
|
|
1249
|
+
},
|
|
1250
|
+
isShareRoot: function() {
|
|
1251
|
+
return [
|
|
1252
|
+
"share",
|
|
1253
|
+
"mountpoint",
|
|
1254
|
+
"public"
|
|
1255
|
+
].includes(e.driveType);
|
|
1256
|
+
},
|
|
1257
|
+
getDomSelector: () => B(e.id),
|
|
1258
|
+
getDriveAliasAndItem({ path: e }) {
|
|
1259
|
+
return d(this.driveAlias, e, { leadingSlash: !1 });
|
|
1260
|
+
},
|
|
1261
|
+
getWebDavUrl({ path: e }) {
|
|
1262
|
+
return d(a, e);
|
|
1263
|
+
},
|
|
1264
|
+
getWebDavTrashUrl({ path: e }) {
|
|
1265
|
+
return d(s, e);
|
|
1266
|
+
},
|
|
1267
|
+
isOwner(e) {
|
|
1268
|
+
return e?.id === this.owner?.id;
|
|
1269
|
+
}
|
|
1270
|
+
};
|
|
1271
|
+
return Object.defineProperty(c, "nodeId", { get() {
|
|
1272
|
+
return H(this.id);
|
|
1273
|
+
} }), c;
|
|
1274
|
+
}
|
|
1275
|
+
function xn(e) {
|
|
1276
|
+
return {
|
|
1277
|
+
id: e.spaceImageData.id,
|
|
1278
|
+
name: e.spaceImageData.name,
|
|
1279
|
+
etag: e.spaceImageData.eTag,
|
|
1280
|
+
extension: U({ name: e.spaceImageData.name }),
|
|
1281
|
+
mimeType: e.spaceImageData.file.mimeType,
|
|
1282
|
+
type: "file",
|
|
1283
|
+
webDavPath: d(e.webDavPath, ".space", e.spaceImageData.name),
|
|
1284
|
+
hasPreview: () => !0,
|
|
1285
|
+
canDownload: () => !0
|
|
1286
|
+
};
|
|
1287
|
+
}
|
|
1288
|
+
//#endregion
|
|
1289
|
+
//#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) => {
|
|
1291
|
+
let r = t[n];
|
|
1292
|
+
r && !e.some(({ id: e }) => e === r.id) && e.push(r);
|
|
1293
|
+
}), e), []), Dn = ({ driveItem: e, shareRoles: t }) => {
|
|
1294
|
+
if (!t.length) {
|
|
1295
|
+
let t = e.remoteItem?.permissions.reduce((e, t) => {
|
|
1296
|
+
let n = t["@libre.graph.permissions.actions"];
|
|
1297
|
+
return n && e.push(...n), e;
|
|
1298
|
+
}, []);
|
|
1299
|
+
return [...new Set(t)];
|
|
1300
|
+
}
|
|
1301
|
+
let n = t.reduce((e, t) => (t.rolePermissions.forEach((t) => {
|
|
1302
|
+
e.push(...t.allowedResourceActions);
|
|
1303
|
+
}), e), []);
|
|
1304
|
+
return [...new Set(n)];
|
|
1305
|
+
};
|
|
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) => {
|
|
1308
|
+
let { grantedToV2: t } = e;
|
|
1309
|
+
return {
|
|
1310
|
+
...t.group || t.user,
|
|
1311
|
+
shareType: $(e)
|
|
1312
|
+
};
|
|
1313
|
+
}), o = e.remoteItem.permissions.reduce((e, t) => {
|
|
1314
|
+
let n = t.invitation.invitedBy.user;
|
|
1315
|
+
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({
|
|
1319
|
+
driveItem: e,
|
|
1320
|
+
graphRoles: t
|
|
1321
|
+
}), l = Dn({
|
|
1322
|
+
driveItem: e,
|
|
1323
|
+
shareRoles: c
|
|
1324
|
+
}), u = {
|
|
1325
|
+
id: e.id,
|
|
1326
|
+
remoteItemId: e.remoteItem.id,
|
|
1327
|
+
driveId: e.parentReference?.driveId,
|
|
1328
|
+
path: "/",
|
|
1329
|
+
name: r,
|
|
1330
|
+
fileId: e.remoteItem.id,
|
|
1331
|
+
size: e.size,
|
|
1332
|
+
storageId: i,
|
|
1333
|
+
parentFolderId: e.parentReference?.id,
|
|
1334
|
+
sdate: e.remoteItem.permissions[0].createdDateTime,
|
|
1335
|
+
tags: [],
|
|
1336
|
+
webDavPath: X(e.remoteItem.id, "/"),
|
|
1337
|
+
sharedBy: o,
|
|
1338
|
+
owner: e.remoteItem.createdBy?.user,
|
|
1339
|
+
sharedWith: a,
|
|
1340
|
+
shareTypes: s,
|
|
1341
|
+
isFolder: !!e.folder,
|
|
1342
|
+
type: e.folder ? "folder" : "file",
|
|
1343
|
+
mimeType: e.file?.mimeType || "httpd/unix-directory",
|
|
1344
|
+
mdate: e.lastModifiedDateTime ? new Date(e.lastModifiedDateTime).toUTCString() : void 0,
|
|
1345
|
+
syncEnabled: e["@client.synchronize"],
|
|
1346
|
+
hidden: e["@UI.Hidden"],
|
|
1347
|
+
shareRoles: c,
|
|
1348
|
+
sharePermissions: l,
|
|
1349
|
+
outgoing: !1,
|
|
1350
|
+
privateLink: d(n, "f", e.remoteItem.id),
|
|
1351
|
+
hasPreview: () => !!e.thumbnails,
|
|
1352
|
+
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),
|
|
1358
|
+
isMounted: () => !1,
|
|
1359
|
+
isReceivedShare: () => !0,
|
|
1360
|
+
canShare: () => !1,
|
|
1361
|
+
isShareRoot: () => !0,
|
|
1362
|
+
getDomSelector: () => B(e.id)
|
|
1363
|
+
};
|
|
1364
|
+
return u.extension = U(u), u;
|
|
1365
|
+
}
|
|
1366
|
+
function kn({ driveItem: e, user: t, serverUrl: n }) {
|
|
1367
|
+
let r = V(e.id), i = d(e.parentReference.path, e.name), a = {
|
|
1368
|
+
id: e.id,
|
|
1369
|
+
driveId: e.parentReference?.driveId,
|
|
1370
|
+
path: i,
|
|
1371
|
+
name: e.name,
|
|
1372
|
+
fileId: e.id,
|
|
1373
|
+
size: e.size,
|
|
1374
|
+
storageId: r,
|
|
1375
|
+
parentFolderId: e.parentReference?.id,
|
|
1376
|
+
sdate: e.permissions[0].createdDateTime,
|
|
1377
|
+
tags: [],
|
|
1378
|
+
webDavPath: X(r, i),
|
|
1379
|
+
sharedBy: [{
|
|
1380
|
+
id: t.id,
|
|
1381
|
+
displayName: t.displayName
|
|
1382
|
+
}],
|
|
1383
|
+
owner: {
|
|
1384
|
+
id: t.id,
|
|
1385
|
+
displayName: t.displayName
|
|
1386
|
+
},
|
|
1387
|
+
sharedWith: e.permissions.map((e) => {
|
|
1388
|
+
if (e.link) return {
|
|
1389
|
+
id: e.id,
|
|
1390
|
+
displayName: e.link["@libre.graph.displayName"],
|
|
1391
|
+
shareType: J.link.value
|
|
1392
|
+
};
|
|
1393
|
+
let t = $(e);
|
|
1394
|
+
return {
|
|
1395
|
+
...e.grantedToV2.user || e.grantedToV2.group,
|
|
1396
|
+
shareType: t
|
|
1397
|
+
};
|
|
1398
|
+
}),
|
|
1399
|
+
shareTypes: e.permissions.map($),
|
|
1400
|
+
isFolder: !!e.folder,
|
|
1401
|
+
type: e.folder ? "folder" : "file",
|
|
1402
|
+
mimeType: e.file?.mimeType || "httpd/unix-directory",
|
|
1403
|
+
outgoing: !0,
|
|
1404
|
+
privateLink: d(n, "f", e.id),
|
|
1405
|
+
hasPreview: () => !!e.thumbnails,
|
|
1406
|
+
canRename: () => !0,
|
|
1407
|
+
canDownload: () => !0,
|
|
1408
|
+
canUpload: () => !0,
|
|
1409
|
+
canCreate: () => !0,
|
|
1410
|
+
canBeDeleted: () => !0,
|
|
1411
|
+
canEditTags: () => !0,
|
|
1412
|
+
isMounted: () => !1,
|
|
1413
|
+
isShareRoot: () => !1,
|
|
1414
|
+
isReceivedShare: () => !0,
|
|
1415
|
+
canShare: () => !0,
|
|
1416
|
+
getDomSelector: () => B(e.id)
|
|
1417
|
+
};
|
|
1418
|
+
return a.extension = U(a), a;
|
|
1419
|
+
}
|
|
1420
|
+
function An({ graphPermission: e, graphRoles: t, resourceId: n, indirect: r = !1 }) {
|
|
1421
|
+
let i = t[e.roles?.[0]], a = e.invitation?.invitedBy?.user;
|
|
1422
|
+
return {
|
|
1423
|
+
id: e.id,
|
|
1424
|
+
resourceId: n,
|
|
1425
|
+
indirect: r,
|
|
1426
|
+
shareType: $(e),
|
|
1427
|
+
role: i,
|
|
1428
|
+
sharedBy: {
|
|
1429
|
+
id: a?.id,
|
|
1430
|
+
displayName: a?.displayName
|
|
1431
|
+
},
|
|
1432
|
+
sharedWith: e.grantedToV2.user || e.grantedToV2.group,
|
|
1433
|
+
permissions: e["@libre.graph.permissions.actions"] ? e["@libre.graph.permissions.actions"] : i.rolePermissions.flatMap((e) => e.allowedResourceActions),
|
|
1434
|
+
createdDateTime: e.createdDateTime,
|
|
1435
|
+
expirationDateTime: e.expirationDateTime
|
|
1436
|
+
};
|
|
1437
|
+
}
|
|
1438
|
+
function jn({ graphPermission: e, resourceId: t, indirect: n = !1 }) {
|
|
1439
|
+
let r = e.invitation?.invitedBy?.user;
|
|
1440
|
+
return {
|
|
1441
|
+
id: e.id,
|
|
1442
|
+
resourceId: t,
|
|
1443
|
+
indirect: n,
|
|
1444
|
+
shareType: J.link.value,
|
|
1445
|
+
sharedBy: {
|
|
1446
|
+
id: r?.id,
|
|
1447
|
+
displayName: r?.displayName
|
|
1448
|
+
},
|
|
1449
|
+
hasPassword: e.hasPassword,
|
|
1450
|
+
createdDateTime: e.createdDateTime,
|
|
1451
|
+
expirationDateTime: e.expirationDateTime,
|
|
1452
|
+
displayName: e.link["@libre.graph.displayName"],
|
|
1453
|
+
isQuickLink: e.link["@libre.graph.quickLink"],
|
|
1454
|
+
type: e.link.type,
|
|
1455
|
+
webUrl: e.link.webUrl,
|
|
1456
|
+
preventsDownload: e.link.preventsDownload
|
|
1457
|
+
};
|
|
1458
|
+
}
|
|
1459
|
+
function $({ link: e, grantedToV2: t }) {
|
|
1460
|
+
return e ? J.link.value : t?.group ? J.group.value : t?.user?.["@libre.graph.userType"] === "Federated" ? J.remote.value : J.user.value;
|
|
1461
|
+
}
|
|
1462
|
+
//#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 };
|