@hostlink/light 2.3.7 → 2.4.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/createClient.d.ts +2 -0
- package/dist/drive.d.ts +30 -0
- package/dist/light.js +370 -267
- package/dist/light.umd.cjs +12 -12
- package/package.json +1 -1
package/dist/light.js
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
var Xt = Object.defineProperty;
|
|
2
2
|
var Yt = (e, t, r) => t in e ? Xt(e, t, { enumerable: !0, configurable: !0, writable: !0, value: r }) : e[t] = r;
|
|
3
|
-
var
|
|
4
|
-
import { jsonToGraphQLQuery as
|
|
3
|
+
var A = (e, t, r) => Yt(e, typeof t != "symbol" ? t + "" : t, r);
|
|
4
|
+
import { jsonToGraphQLQuery as Tt, VariableType as W } from "json-to-graphql-query";
|
|
5
5
|
import Zt from "axios";
|
|
6
|
-
function
|
|
6
|
+
function Pt(e) {
|
|
7
7
|
const t = "==".slice(0, (4 - e.length % 4) % 4), r = e.replace(/-/g, "+").replace(/_/g, "/") + t, n = atob(r), i = new ArrayBuffer(n.length), s = new Uint8Array(i);
|
|
8
8
|
for (let o = 0; o < n.length; o++)
|
|
9
9
|
s[o] = n.charCodeAt(o);
|
|
@@ -19,14 +19,14 @@ function Nt(e) {
|
|
|
19
19
|
"_"
|
|
20
20
|
).replace(/=/g, "");
|
|
21
21
|
}
|
|
22
|
-
var
|
|
23
|
-
function
|
|
24
|
-
if (t ===
|
|
22
|
+
var h = "copy", _ = "convert";
|
|
23
|
+
function F(e, t, r) {
|
|
24
|
+
if (t === h)
|
|
25
25
|
return r;
|
|
26
|
-
if (t ===
|
|
26
|
+
if (t === _)
|
|
27
27
|
return e(r);
|
|
28
28
|
if (t instanceof Array)
|
|
29
|
-
return r.map((n) =>
|
|
29
|
+
return r.map((n) => F(e, t[0], n));
|
|
30
30
|
if (t instanceof Object) {
|
|
31
31
|
const n = {};
|
|
32
32
|
for (const [i, s] of Object.entries(t)) {
|
|
@@ -43,7 +43,7 @@ function P(e, t, r) {
|
|
|
43
43
|
n[i] = null;
|
|
44
44
|
continue;
|
|
45
45
|
}
|
|
46
|
-
n[i] =
|
|
46
|
+
n[i] = F(
|
|
47
47
|
e,
|
|
48
48
|
s.schema,
|
|
49
49
|
r[i]
|
|
@@ -59,7 +59,7 @@ function H(e, t) {
|
|
|
59
59
|
derive: t
|
|
60
60
|
};
|
|
61
61
|
}
|
|
62
|
-
function
|
|
62
|
+
function y(e) {
|
|
63
63
|
return {
|
|
64
64
|
required: !0,
|
|
65
65
|
schema: e
|
|
@@ -72,44 +72,44 @@ function b(e) {
|
|
|
72
72
|
};
|
|
73
73
|
}
|
|
74
74
|
var Bt = {
|
|
75
|
-
type:
|
|
76
|
-
id:
|
|
77
|
-
transports: b(
|
|
75
|
+
type: y(h),
|
|
76
|
+
id: y(_),
|
|
77
|
+
transports: b(h)
|
|
78
78
|
}, qt = {
|
|
79
|
-
appid: b(
|
|
80
|
-
appidExclude: b(
|
|
81
|
-
credProps: b(
|
|
82
|
-
},
|
|
83
|
-
appid: b(
|
|
84
|
-
appidExclude: b(
|
|
85
|
-
credProps: b(
|
|
79
|
+
appid: b(h),
|
|
80
|
+
appidExclude: b(h),
|
|
81
|
+
credProps: b(h)
|
|
82
|
+
}, Kt = {
|
|
83
|
+
appid: b(h),
|
|
84
|
+
appidExclude: b(h),
|
|
85
|
+
credProps: b(h)
|
|
86
86
|
}, kt = {
|
|
87
|
-
publicKey:
|
|
88
|
-
rp:
|
|
89
|
-
user:
|
|
90
|
-
id:
|
|
91
|
-
name:
|
|
92
|
-
displayName:
|
|
87
|
+
publicKey: y({
|
|
88
|
+
rp: y(h),
|
|
89
|
+
user: y({
|
|
90
|
+
id: y(_),
|
|
91
|
+
name: y(h),
|
|
92
|
+
displayName: y(h)
|
|
93
93
|
}),
|
|
94
|
-
challenge:
|
|
95
|
-
pubKeyCredParams:
|
|
96
|
-
timeout: b(
|
|
94
|
+
challenge: y(_),
|
|
95
|
+
pubKeyCredParams: y(h),
|
|
96
|
+
timeout: b(h),
|
|
97
97
|
excludeCredentials: b([Bt]),
|
|
98
|
-
authenticatorSelection: b(
|
|
99
|
-
attestation: b(
|
|
98
|
+
authenticatorSelection: b(h),
|
|
99
|
+
attestation: b(h),
|
|
100
100
|
extensions: b(qt)
|
|
101
101
|
}),
|
|
102
|
-
signal: b(
|
|
102
|
+
signal: b(h)
|
|
103
103
|
}, tr = {
|
|
104
|
-
type:
|
|
105
|
-
id:
|
|
106
|
-
rawId:
|
|
107
|
-
authenticatorAttachment: b(
|
|
108
|
-
response:
|
|
109
|
-
clientDataJSON:
|
|
110
|
-
attestationObject:
|
|
104
|
+
type: y(h),
|
|
105
|
+
id: y(h),
|
|
106
|
+
rawId: y(_),
|
|
107
|
+
authenticatorAttachment: b(h),
|
|
108
|
+
response: y({
|
|
109
|
+
clientDataJSON: y(_),
|
|
110
|
+
attestationObject: y(_),
|
|
111
111
|
transports: H(
|
|
112
|
-
|
|
112
|
+
h,
|
|
113
113
|
(e) => {
|
|
114
114
|
var t;
|
|
115
115
|
return ((t = e.getTransports) == null ? void 0 : t.call(e)) || [];
|
|
@@ -117,51 +117,51 @@ var Bt = {
|
|
|
117
117
|
)
|
|
118
118
|
}),
|
|
119
119
|
clientExtensionResults: H(
|
|
120
|
-
|
|
120
|
+
Kt,
|
|
121
121
|
(e) => e.getClientExtensionResults()
|
|
122
122
|
)
|
|
123
123
|
}, rr = {
|
|
124
|
-
mediation: b(
|
|
125
|
-
publicKey:
|
|
126
|
-
challenge:
|
|
127
|
-
timeout: b(
|
|
128
|
-
rpId: b(
|
|
124
|
+
mediation: b(h),
|
|
125
|
+
publicKey: y({
|
|
126
|
+
challenge: y(_),
|
|
127
|
+
timeout: b(h),
|
|
128
|
+
rpId: b(h),
|
|
129
129
|
allowCredentials: b([Bt]),
|
|
130
|
-
userVerification: b(
|
|
130
|
+
userVerification: b(h),
|
|
131
131
|
extensions: b(qt)
|
|
132
132
|
}),
|
|
133
|
-
signal: b(
|
|
133
|
+
signal: b(h)
|
|
134
134
|
}, er = {
|
|
135
|
-
type:
|
|
136
|
-
id:
|
|
137
|
-
rawId:
|
|
138
|
-
authenticatorAttachment: b(
|
|
139
|
-
response:
|
|
140
|
-
clientDataJSON:
|
|
141
|
-
authenticatorData:
|
|
142
|
-
signature:
|
|
143
|
-
userHandle:
|
|
135
|
+
type: y(h),
|
|
136
|
+
id: y(h),
|
|
137
|
+
rawId: y(_),
|
|
138
|
+
authenticatorAttachment: b(h),
|
|
139
|
+
response: y({
|
|
140
|
+
clientDataJSON: y(_),
|
|
141
|
+
authenticatorData: y(_),
|
|
142
|
+
signature: y(_),
|
|
143
|
+
userHandle: y(_)
|
|
144
144
|
}),
|
|
145
145
|
clientExtensionResults: H(
|
|
146
|
-
|
|
146
|
+
Kt,
|
|
147
147
|
(e) => e.getClientExtensionResults()
|
|
148
148
|
)
|
|
149
149
|
};
|
|
150
150
|
function nr(e) {
|
|
151
|
-
return
|
|
151
|
+
return F(Pt, kt, e);
|
|
152
152
|
}
|
|
153
153
|
function ir(e) {
|
|
154
|
-
return
|
|
154
|
+
return F(
|
|
155
155
|
Nt,
|
|
156
156
|
tr,
|
|
157
157
|
e
|
|
158
158
|
);
|
|
159
159
|
}
|
|
160
160
|
function sr(e) {
|
|
161
|
-
return
|
|
161
|
+
return F(Pt, rr, e);
|
|
162
162
|
}
|
|
163
163
|
function or(e) {
|
|
164
|
-
return
|
|
164
|
+
return F(
|
|
165
165
|
Nt,
|
|
166
166
|
er,
|
|
167
167
|
e
|
|
@@ -181,70 +181,80 @@ async function ur(e) {
|
|
|
181
181
|
}
|
|
182
182
|
const cr = (e) => ({
|
|
183
183
|
login: async (t) => {
|
|
184
|
-
const
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
184
|
+
const { app: r } = await w(e, {
|
|
185
|
+
app: {
|
|
186
|
+
auth: {
|
|
187
|
+
webAuthnRequestOptions: {
|
|
188
|
+
__args: {
|
|
189
|
+
username: t
|
|
190
|
+
}
|
|
191
|
+
}
|
|
188
192
|
}
|
|
189
193
|
}
|
|
190
|
-
})
|
|
194
|
+
}), n = r.auth.webAuthnRequestOptions, i = sr({
|
|
191
195
|
publicKey: n
|
|
192
196
|
}), s = await ur(i);
|
|
193
|
-
await
|
|
197
|
+
await f(e, "webAuthnAssertion", {
|
|
194
198
|
username: t,
|
|
195
199
|
assertion: s.toJSON()
|
|
196
200
|
});
|
|
197
201
|
},
|
|
198
202
|
register: async () => {
|
|
199
|
-
const t = await
|
|
200
|
-
|
|
203
|
+
const { app: t } = await w(e, {
|
|
204
|
+
app: {
|
|
205
|
+
auth: {
|
|
206
|
+
webAuthnCreationOptions: !0
|
|
207
|
+
}
|
|
208
|
+
}
|
|
209
|
+
}), r = nr({
|
|
210
|
+
publicKey: t.auth.webAuthnCreationOptions
|
|
201
211
|
}), n = await ar(r);
|
|
202
|
-
await
|
|
212
|
+
await f(e, "webAuthnRegister", {
|
|
203
213
|
registration: n.toJSON()
|
|
204
214
|
});
|
|
205
215
|
}
|
|
206
216
|
}), fr = (e) => ({
|
|
207
217
|
WebAuthn: cr(e),
|
|
208
|
-
facebookLogin: (t) =>
|
|
218
|
+
facebookLogin: (t) => f(e, "facebookLogin", {
|
|
209
219
|
access_token: t
|
|
210
220
|
}),
|
|
211
|
-
microsoftLogin: (t) =>
|
|
221
|
+
microsoftLogin: (t) => f(e, "microsoftLogin", {
|
|
212
222
|
access_token: t
|
|
213
223
|
}),
|
|
214
|
-
googleLogin: (t) =>
|
|
224
|
+
googleLogin: (t) => f(e, "googleLogin", {
|
|
215
225
|
credential: t
|
|
216
226
|
}),
|
|
217
|
-
login: (t, r, n = "") =>
|
|
227
|
+
login: (t, r, n = "") => f(e, "login", {
|
|
218
228
|
username: t,
|
|
219
229
|
password: r,
|
|
220
230
|
code: n
|
|
221
231
|
}),
|
|
222
|
-
logout: () =>
|
|
223
|
-
changeExpiredPassword: (t, r, n) =>
|
|
232
|
+
logout: () => f(e, "logout"),
|
|
233
|
+
changeExpiredPassword: (t, r, n) => f(e, "changeExpiredPassword", {
|
|
224
234
|
username: t,
|
|
225
235
|
old_password: r,
|
|
226
236
|
new_password: n
|
|
227
237
|
}),
|
|
228
|
-
updatePassword: (t, r) =>
|
|
238
|
+
updatePassword: (t, r) => f(e, "updatePassword", {
|
|
229
239
|
old_password: t,
|
|
230
240
|
new_password: r
|
|
231
241
|
}),
|
|
232
|
-
resetPassword: (t, r, n) =>
|
|
242
|
+
resetPassword: (t, r, n) => f(e, "resetPassword", {
|
|
233
243
|
username: t,
|
|
234
244
|
password: r,
|
|
235
245
|
code: n
|
|
236
246
|
}),
|
|
237
|
-
forgetPassword: (t, r) =>
|
|
247
|
+
forgetPassword: (t, r) => f(e, "forgetPassword", {
|
|
238
248
|
username: t,
|
|
239
249
|
email: r
|
|
240
250
|
}),
|
|
241
251
|
verifyCode(t, r) {
|
|
242
|
-
return
|
|
252
|
+
return f(e, "forgetPasswordVerifyCode", {
|
|
243
253
|
username: t,
|
|
244
254
|
code: r
|
|
245
255
|
});
|
|
246
256
|
},
|
|
247
|
-
granted: async (t) => (await
|
|
257
|
+
granted: async (t) => (await w(e, {
|
|
248
258
|
granted: {
|
|
249
259
|
__args: {
|
|
250
260
|
rights: t
|
|
@@ -266,32 +276,32 @@ const cr = (e) => ({
|
|
|
266
276
|
},
|
|
267
277
|
gqlFields(a) {
|
|
268
278
|
const c = [];
|
|
269
|
-
for (const
|
|
270
|
-
if (typeof
|
|
271
|
-
const v = u(
|
|
279
|
+
for (const p of a)
|
|
280
|
+
if (typeof p == "string") {
|
|
281
|
+
const v = u(p);
|
|
272
282
|
v && c.push(v.getGQLField());
|
|
273
|
-
} else typeof
|
|
283
|
+
} else typeof p == "object" && c.push(p);
|
|
274
284
|
return c;
|
|
275
285
|
},
|
|
276
286
|
async update(a, c) {
|
|
277
|
-
return await
|
|
287
|
+
return await f(i, "update" + n, { id: a, data: c });
|
|
278
288
|
},
|
|
279
289
|
async delete(a) {
|
|
280
|
-
return await
|
|
290
|
+
return await f(i, "delete" + n, { id: a });
|
|
281
291
|
},
|
|
282
292
|
async add(a) {
|
|
283
|
-
return await
|
|
293
|
+
return await f(i, "add" + n, { data: a });
|
|
284
294
|
},
|
|
285
295
|
fields(a) {
|
|
286
296
|
let c = [];
|
|
287
|
-
for (let
|
|
288
|
-
const v = u(
|
|
297
|
+
for (let p of a) {
|
|
298
|
+
const v = u(p);
|
|
289
299
|
v && c.push(v);
|
|
290
300
|
}
|
|
291
301
|
return c;
|
|
292
302
|
},
|
|
293
303
|
async get(a, c) {
|
|
294
|
-
return (await
|
|
304
|
+
return (await w(i, {
|
|
295
305
|
["list" + n]: {
|
|
296
306
|
__args: {
|
|
297
307
|
filters: a
|
|
@@ -306,7 +316,7 @@ const cr = (e) => ({
|
|
|
306
316
|
}))["list" + n].data[0];
|
|
307
317
|
},
|
|
308
318
|
async list(a, c) {
|
|
309
|
-
return (await
|
|
319
|
+
return (await w(i, {
|
|
310
320
|
["list" + n]: {
|
|
311
321
|
__args: {
|
|
312
322
|
filters: a
|
|
@@ -324,10 +334,10 @@ function hr(e) {
|
|
|
324
334
|
var t, r, n, i, s, o = String, u = 255;
|
|
325
335
|
for (e.slice(0, 2) === "<~" && e.slice(-2), e = e.slice(2, -2).replace(/\s/g, "").replace("z", "!!!!!"), t = "uuuuu".slice(e.length % 5 || 5), e += t, n = [], i = 0, s = e.length; s > i; i += 5) r = 52200625 * (e.charCodeAt(i) - 33) + 614125 * (e.charCodeAt(i + 1) - 33) + 7225 * (e.charCodeAt(i + 2) - 33) + 85 * (e.charCodeAt(i + 3) - 33) + (e.charCodeAt(i + 4) - 33), n.push(u & r >> 24, u & r >> 16, u & r >> 8, u & r);
|
|
326
336
|
return function(a, c) {
|
|
327
|
-
for (var
|
|
337
|
+
for (var p = c; p > 0; p--) a.pop();
|
|
328
338
|
}(n, t.length), o.fromCharCode.apply(o, n);
|
|
329
339
|
}
|
|
330
|
-
const
|
|
340
|
+
const M = (e = "") => {
|
|
331
341
|
const t = e, r = (n = "application/octet-stream") => {
|
|
332
342
|
const i = new Uint8Array(t.length);
|
|
333
343
|
for (let u = 0; u < t.length; u++)
|
|
@@ -346,10 +356,10 @@ const R = (e = "") => {
|
|
|
346
356
|
window.open(r(n), "_blank");
|
|
347
357
|
}
|
|
348
358
|
};
|
|
349
|
-
},
|
|
350
|
-
fromBase85: (e) =>
|
|
351
|
-
fromBase64: (e) =>
|
|
352
|
-
fromString: (e) =>
|
|
359
|
+
}, ho = {
|
|
360
|
+
fromBase85: (e) => M(hr(e)),
|
|
361
|
+
fromBase64: (e) => M(atob(e)),
|
|
362
|
+
fromString: (e) => M(e)
|
|
353
363
|
}, G = (e) => {
|
|
354
364
|
let t = {};
|
|
355
365
|
return typeof e == "string" ? (t[e] = !0, t) : e instanceof Array ? (e.forEach((r) => {
|
|
@@ -367,8 +377,8 @@ const R = (e = "") => {
|
|
|
367
377
|
}
|
|
368
378
|
t[r] = G(n);
|
|
369
379
|
}), t);
|
|
370
|
-
}, N = (e) => G(e),
|
|
371
|
-
let r =
|
|
380
|
+
}, N = (e) => G(e), w = async (e, t) => {
|
|
381
|
+
let r = Tt(N(t));
|
|
372
382
|
const n = await e.post("", {
|
|
373
383
|
query: `{ ${r} }`
|
|
374
384
|
});
|
|
@@ -388,32 +398,32 @@ function yr(e) {
|
|
|
388
398
|
return !0;
|
|
389
399
|
return !1;
|
|
390
400
|
}
|
|
391
|
-
const
|
|
401
|
+
const f = async (e, t, r = null, n = []) => {
|
|
392
402
|
let i = {
|
|
393
403
|
[t]: {}
|
|
394
404
|
};
|
|
395
405
|
const s = new FormData();
|
|
396
406
|
let o = !1;
|
|
397
407
|
if (r) {
|
|
398
|
-
const c = {},
|
|
399
|
-
let
|
|
408
|
+
const c = {}, p = {}, v = {};
|
|
409
|
+
let l = 0;
|
|
400
410
|
Object.entries(r).forEach(([m, g]) => {
|
|
401
411
|
if (g instanceof Array && pr(g)) {
|
|
402
412
|
o = !0;
|
|
403
413
|
let E = 0;
|
|
404
414
|
g.forEach((C) => {
|
|
405
|
-
C instanceof File && (c[m] = new W(m),
|
|
415
|
+
C instanceof File && (c[m] = new W(m), p[l] = ["variables." + m + "." + E], s.append(l.toString(), C), l++);
|
|
406
416
|
}), v[m] = "[Upload!]!";
|
|
407
|
-
} else g instanceof File ? (o = !0, c[m] = new W(m),
|
|
408
|
-
C instanceof File ? (c[m][E] = new W(E),
|
|
417
|
+
} else g instanceof File ? (o = !0, c[m] = new W(m), p[l] = ["variables." + m], s.append(l.toString(), g), v[m] = "Upload!", l++) : g instanceof Object && yr(g) ? (o = !0, c[m] = {}, Object.entries(g).forEach(([E, C]) => {
|
|
418
|
+
C instanceof File ? (c[m][E] = new W(E), p[l] = ["variables." + E], s.append(l.toString(), C), v[E] = "Upload!", l++) : c[m][E] = C;
|
|
409
419
|
})) : g !== void 0 && (c[m] = g);
|
|
410
|
-
}), i[t].__args = c, i.__variables = v, o && s.append("map", JSON.stringify(
|
|
420
|
+
}), i[t].__args = c, i.__variables = v, o && s.append("map", JSON.stringify(p));
|
|
411
421
|
}
|
|
412
|
-
Object.entries(N(n)).forEach(([c,
|
|
413
|
-
i[t][c] =
|
|
422
|
+
Object.entries(N(n)).forEach(([c, p]) => {
|
|
423
|
+
i[t][c] = p;
|
|
414
424
|
}), Object.entries(i[t]).length === 0 && (i[t] = !0);
|
|
415
425
|
let u = null;
|
|
416
|
-
const a =
|
|
426
|
+
const a = Tt({ mutation: i });
|
|
417
427
|
if (o ? (s.append("operations", JSON.stringify({
|
|
418
428
|
query: a
|
|
419
429
|
})), u = await e.post("", s)) : u = await e.post("", {
|
|
@@ -422,7 +432,7 @@ const y = async (e, t, r = null, n = []) => {
|
|
|
422
432
|
throw new Error(u.data.errors[0].message);
|
|
423
433
|
return u.data.data[t];
|
|
424
434
|
}, mr = (e) => ({
|
|
425
|
-
uploadTempFile: (t) =>
|
|
435
|
+
uploadTempFile: (t) => f(e, "fsUploadTempFile", {
|
|
426
436
|
file: t
|
|
427
437
|
}, {
|
|
428
438
|
name: !0,
|
|
@@ -431,7 +441,7 @@ const y = async (e, t, r = null, n = []) => {
|
|
|
431
441
|
mime: !0
|
|
432
442
|
}),
|
|
433
443
|
folders: {
|
|
434
|
-
list: async (t) => (await
|
|
444
|
+
list: async (t) => (await w(e, {
|
|
435
445
|
fsListFolders: {
|
|
436
446
|
__args: {
|
|
437
447
|
path: t
|
|
@@ -440,12 +450,12 @@ const y = async (e, t, r = null, n = []) => {
|
|
|
440
450
|
path: !0
|
|
441
451
|
}
|
|
442
452
|
})).fsListFolders,
|
|
443
|
-
create: (t) =>
|
|
444
|
-
delete: (t) =>
|
|
445
|
-
rename: (t, r) =>
|
|
453
|
+
create: (t) => f(e, "fsCreateFolder", { path: t }),
|
|
454
|
+
delete: (t) => f(e, "fsDeleteFolder", { path: t }),
|
|
455
|
+
rename: (t, r) => f(e, "fsRenameFolder", { path: t, name: r })
|
|
446
456
|
},
|
|
447
457
|
files: {
|
|
448
|
-
list: async (t) => (await
|
|
458
|
+
list: async (t) => (await w(e, {
|
|
449
459
|
fsListFiles: {
|
|
450
460
|
__args: {
|
|
451
461
|
path: t
|
|
@@ -459,7 +469,7 @@ const y = async (e, t, r = null, n = []) => {
|
|
|
459
469
|
}
|
|
460
470
|
})).fsListFiles,
|
|
461
471
|
read: async (t) => {
|
|
462
|
-
let r = await
|
|
472
|
+
let r = await w(e, {
|
|
463
473
|
fsFile: {
|
|
464
474
|
__args: {
|
|
465
475
|
path: t
|
|
@@ -469,13 +479,13 @@ const y = async (e, t, r = null, n = []) => {
|
|
|
469
479
|
});
|
|
470
480
|
return window.atob(r.fsFile.base64Content);
|
|
471
481
|
},
|
|
472
|
-
write: (t, r) =>
|
|
482
|
+
write: (t, r) => f(e, "fsWriteFile", {
|
|
473
483
|
path: t,
|
|
474
484
|
content: r
|
|
475
485
|
}),
|
|
476
|
-
delete: (t) =>
|
|
477
|
-
rename: (t, r) =>
|
|
478
|
-
move: (t, r) =>
|
|
486
|
+
delete: (t) => f(e, "fsDeleteFile", { path: t }),
|
|
487
|
+
rename: (t, r) => f(e, "fsRenameFile", { path: t, name: r }),
|
|
488
|
+
move: (t, r) => f(e, "fsMoveFile", { source: t, target: r })
|
|
479
489
|
}
|
|
480
490
|
}), dr = (e) => ({
|
|
481
491
|
get: async (t) => (await e({
|
|
@@ -486,13 +496,13 @@ const y = async (e, t, r = null, n = []) => {
|
|
|
486
496
|
}
|
|
487
497
|
})).config
|
|
488
498
|
}), vr = (e) => ({
|
|
489
|
-
send: (t, r, n) =>
|
|
499
|
+
send: (t, r, n) => f(e, "sendMail", {
|
|
490
500
|
email: t,
|
|
491
501
|
subject: r,
|
|
492
502
|
message: n
|
|
493
503
|
})
|
|
494
504
|
}), br = (e) => ({
|
|
495
|
-
list: async () => (await
|
|
505
|
+
list: async () => (await w(e, {
|
|
496
506
|
listUser: {
|
|
497
507
|
data: {
|
|
498
508
|
user_id: !0,
|
|
@@ -523,8 +533,8 @@ const y = async (e, t, r = null, n = []) => {
|
|
|
523
533
|
return a.field && typeof a.field == "function" ? a.field(c) : a.field && typeof a.field == "string" ? c[a.field] : c[this.getName()];
|
|
524
534
|
},
|
|
525
535
|
getFormattedValue(c) {
|
|
526
|
-
const
|
|
527
|
-
return a.format ? a.format(
|
|
536
|
+
const p = this.getValue(c);
|
|
537
|
+
return a.format ? a.format(p) : p;
|
|
528
538
|
}
|
|
529
539
|
});
|
|
530
540
|
}
|
|
@@ -535,7 +545,7 @@ const y = async (e, t, r = null, n = []) => {
|
|
|
535
545
|
}
|
|
536
546
|
};
|
|
537
547
|
}, wr = (e) => ({
|
|
538
|
-
list: async () => (await
|
|
548
|
+
list: async () => (await w(e, {
|
|
539
549
|
listRole: {
|
|
540
550
|
name: !0
|
|
541
551
|
}
|
|
@@ -544,7 +554,7 @@ const y = async (e, t, r = null, n = []) => {
|
|
|
544
554
|
function Ar(e) {
|
|
545
555
|
return e && e.__esModule && Object.prototype.hasOwnProperty.call(e, "default") ? e.default : e;
|
|
546
556
|
}
|
|
547
|
-
var
|
|
557
|
+
var Rt = { exports: {} }, _r = function() {
|
|
548
558
|
var t = this, r = -1;
|
|
549
559
|
return {
|
|
550
560
|
next: function() {
|
|
@@ -604,9 +614,9 @@ var Ir = function(t) {
|
|
|
604
614
|
} while (i < this.items.length);
|
|
605
615
|
else if (z(this.items) === "object") {
|
|
606
616
|
var u = Object.keys(this.items), a = function() {
|
|
607
|
-
var
|
|
608
|
-
|
|
609
|
-
return v.put(
|
|
617
|
+
var p = u.slice(i, i + t), v = new r.constructor({});
|
|
618
|
+
p.forEach(function(l) {
|
|
619
|
+
return v.put(l, r.items[l]);
|
|
610
620
|
}), n.push(v), i += t;
|
|
611
621
|
};
|
|
612
622
|
do
|
|
@@ -617,13 +627,13 @@ var Ir = function(t) {
|
|
|
617
627
|
return new this.constructor(n);
|
|
618
628
|
};
|
|
619
629
|
function Cr(e) {
|
|
620
|
-
return
|
|
630
|
+
return Pr(e) || Tr(e) || Fr(e) || Dr();
|
|
621
631
|
}
|
|
622
|
-
function
|
|
632
|
+
function Dr() {
|
|
623
633
|
throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
|
624
634
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`);
|
|
625
635
|
}
|
|
626
|
-
function
|
|
636
|
+
function Fr(e, t) {
|
|
627
637
|
if (e) {
|
|
628
638
|
if (typeof e == "string") return X(e, t);
|
|
629
639
|
var r = Object.prototype.toString.call(e).slice(8, -1);
|
|
@@ -631,10 +641,10 @@ function Pr(e, t) {
|
|
|
631
641
|
if (r === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)) return X(e, t);
|
|
632
642
|
}
|
|
633
643
|
}
|
|
634
|
-
function
|
|
644
|
+
function Tr(e) {
|
|
635
645
|
if (typeof Symbol < "u" && e[Symbol.iterator] != null || e["@@iterator"] != null) return Array.from(e);
|
|
636
646
|
}
|
|
637
|
-
function
|
|
647
|
+
function Pr(e) {
|
|
638
648
|
if (Array.isArray(e)) return X(e);
|
|
639
649
|
}
|
|
640
650
|
function X(e, t) {
|
|
@@ -648,13 +658,13 @@ var Nr = function() {
|
|
|
648
658
|
return new this.constructor((t = []).concat.apply(t, Cr(this.items)));
|
|
649
659
|
};
|
|
650
660
|
function Br(e, t) {
|
|
651
|
-
return Ur(e) ||
|
|
661
|
+
return Ur(e) || Rr(e, t) || Kr(e, t) || qr();
|
|
652
662
|
}
|
|
653
663
|
function qr() {
|
|
654
664
|
throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
655
665
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`);
|
|
656
666
|
}
|
|
657
|
-
function
|
|
667
|
+
function Kr(e, t) {
|
|
658
668
|
if (e) {
|
|
659
669
|
if (typeof e == "string") return pt(e, t);
|
|
660
670
|
var r = Object.prototype.toString.call(e).slice(8, -1);
|
|
@@ -668,7 +678,7 @@ function pt(e, t) {
|
|
|
668
678
|
n[r] = e[r];
|
|
669
679
|
return n;
|
|
670
680
|
}
|
|
671
|
-
function
|
|
681
|
+
function Rr(e, t) {
|
|
672
682
|
var r = e == null ? null : typeof Symbol < "u" && e[Symbol.iterator] || e["@@iterator"];
|
|
673
683
|
if (r != null) {
|
|
674
684
|
var n = [], i = !0, s = !1, o, u;
|
|
@@ -718,14 +728,14 @@ var Wr = function(t) {
|
|
|
718
728
|
} else typeof this.items == "string" && (i[this.items] = n);
|
|
719
729
|
return new this.constructor(i);
|
|
720
730
|
};
|
|
721
|
-
function
|
|
722
|
-
return
|
|
731
|
+
function Mr(e) {
|
|
732
|
+
return xr(e) || Lr(e) || Vr(e) || Jr();
|
|
723
733
|
}
|
|
724
734
|
function Jr() {
|
|
725
735
|
throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
|
726
736
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`);
|
|
727
737
|
}
|
|
728
|
-
function
|
|
738
|
+
function Vr(e, t) {
|
|
729
739
|
if (e) {
|
|
730
740
|
if (typeof e == "string") return Y(e, t);
|
|
731
741
|
var r = Object.prototype.toString.call(e).slice(8, -1);
|
|
@@ -733,10 +743,10 @@ function Mr(e, t) {
|
|
|
733
743
|
if (r === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)) return Y(e, t);
|
|
734
744
|
}
|
|
735
745
|
}
|
|
736
|
-
function
|
|
746
|
+
function Lr(e) {
|
|
737
747
|
if (typeof Symbol < "u" && e[Symbol.iterator] != null || e["@@iterator"] != null) return Array.from(e);
|
|
738
748
|
}
|
|
739
|
-
function
|
|
749
|
+
function xr(e) {
|
|
740
750
|
if (Array.isArray(e)) return Y(e);
|
|
741
751
|
}
|
|
742
752
|
function Y(e, t) {
|
|
@@ -749,7 +759,7 @@ var Wt = function(t) {
|
|
|
749
759
|
var r;
|
|
750
760
|
if (Array.isArray(t)) {
|
|
751
761
|
var n;
|
|
752
|
-
r = [], (n = r).push.apply(n,
|
|
762
|
+
r = [], (n = r).push.apply(n, Mr(t));
|
|
753
763
|
} else
|
|
754
764
|
r = {}, Object.keys(t).forEach(function(i) {
|
|
755
765
|
r[i] = t[i];
|
|
@@ -836,7 +846,7 @@ function k(e, t) {
|
|
|
836
846
|
n[r] = e[r];
|
|
837
847
|
return n;
|
|
838
848
|
}
|
|
839
|
-
var ne = $, ie = d, se = ie.isFunction,
|
|
849
|
+
var ne = $, ie = d, se = ie.isFunction, Mt = function(t, r) {
|
|
840
850
|
if (r !== void 0)
|
|
841
851
|
return Array.isArray(this.items) ? this.items.filter(function(i) {
|
|
842
852
|
return i[t] !== void 0 && i[t] === r;
|
|
@@ -865,9 +875,9 @@ var ne = $, ie = d, se = ie.isFunction, Rt = function(t, r) {
|
|
|
865
875
|
function t(s, o, u) {
|
|
866
876
|
var a = u[0];
|
|
867
877
|
a instanceof o && (a = a.all());
|
|
868
|
-
for (var c = u.slice(1),
|
|
878
|
+
for (var c = u.slice(1), p = !c.length, v = [], l = 0; l < a.length; l += 1) {
|
|
869
879
|
var m = s.slice();
|
|
870
|
-
m.push(a[
|
|
880
|
+
m.push(a[l]), p ? v.push(m) : v = v.concat(t(m, o, c));
|
|
871
881
|
}
|
|
872
882
|
return v;
|
|
873
883
|
}
|
|
@@ -909,22 +919,22 @@ var ne = $, ie = d, se = ie.isFunction, Rt = function(t, r) {
|
|
|
909
919
|
}, de = function() {
|
|
910
920
|
return console.log(this), this;
|
|
911
921
|
};
|
|
912
|
-
function
|
|
922
|
+
function K(e) {
|
|
913
923
|
"@babel/helpers - typeof";
|
|
914
|
-
return
|
|
924
|
+
return K = typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? function(t) {
|
|
915
925
|
return typeof t;
|
|
916
926
|
} : function(t) {
|
|
917
927
|
return t && typeof Symbol == "function" && t.constructor === Symbol && t !== Symbol.prototype ? "symbol" : typeof t;
|
|
918
|
-
},
|
|
928
|
+
}, K(e);
|
|
919
929
|
}
|
|
920
930
|
var ve = function() {
|
|
921
931
|
var t = this, r = [], n = {}, i = function(o) {
|
|
922
|
-
return Array.isArray(o) ||
|
|
932
|
+
return Array.isArray(o) || K(o) === "object" ? JSON.stringify(o) : o;
|
|
923
933
|
};
|
|
924
934
|
return Array.isArray(this.items) ? this.items.forEach(function(s, o) {
|
|
925
935
|
var u = i(s);
|
|
926
936
|
r.indexOf(u) === -1 ? r.push(u) : n[o] = s;
|
|
927
|
-
}) :
|
|
937
|
+
}) : K(this.items) === "object" && Object.keys(this.items).forEach(function(s) {
|
|
928
938
|
var o = i(t.items[s]);
|
|
929
939
|
r.indexOf(o) === -1 ? r.push(o) : n[s] = t.items[s];
|
|
930
940
|
}), new this.constructor(n);
|
|
@@ -1016,7 +1026,7 @@ function Ce(e, t) {
|
|
|
1016
1026
|
e ? e(t[n], n) && (r[n] = t[n]) : Jt(t[n]) || (r[n] = t[n]);
|
|
1017
1027
|
}), r;
|
|
1018
1028
|
}
|
|
1019
|
-
function
|
|
1029
|
+
function De(e, t) {
|
|
1020
1030
|
if (e)
|
|
1021
1031
|
return t.filter(e);
|
|
1022
1032
|
for (var r = [], n = 0; n < t.length; n += 1) {
|
|
@@ -1025,10 +1035,10 @@ function Te(e, t) {
|
|
|
1025
1035
|
}
|
|
1026
1036
|
return r;
|
|
1027
1037
|
}
|
|
1028
|
-
var
|
|
1038
|
+
var Fe = function(t) {
|
|
1029
1039
|
var r = t || !1, n = null;
|
|
1030
|
-
return Array.isArray(this.items) ? n =
|
|
1031
|
-
},
|
|
1040
|
+
return Array.isArray(this.items) ? n = De(r, this.items) : n = Ce(r, this.items), new this.constructor(n);
|
|
1041
|
+
}, Te = d, J = Te.isFunction, Pe = function(t, r) {
|
|
1032
1042
|
if (J(t)) {
|
|
1033
1043
|
for (var n = Object.keys(this.items), i = 0; i < n.length; i += 1) {
|
|
1034
1044
|
var s = n[i], o = this.items[s];
|
|
@@ -1053,22 +1063,22 @@ var Pe = function(t) {
|
|
|
1053
1063
|
if (i.isEmpty())
|
|
1054
1064
|
throw new Error("Item not found.");
|
|
1055
1065
|
return i.first();
|
|
1056
|
-
},
|
|
1066
|
+
}, Ke = function(t, r, n) {
|
|
1057
1067
|
return this.where(t, r, n).first() || null;
|
|
1058
|
-
},
|
|
1068
|
+
}, Re = function(t) {
|
|
1059
1069
|
return this.map(t).collapse();
|
|
1060
|
-
},
|
|
1070
|
+
}, Vt = d, V = Vt.isArray, L = Vt.isObject, Ue = function(t) {
|
|
1061
1071
|
var r = t || 1 / 0, n = !1, i = [], s = function(u) {
|
|
1062
|
-
i = [],
|
|
1063
|
-
|
|
1072
|
+
i = [], V(u) ? u.forEach(function(a) {
|
|
1073
|
+
V(a) ? i = i.concat(a) : L(a) ? Object.keys(a).forEach(function(c) {
|
|
1064
1074
|
i = i.concat(a[c]);
|
|
1065
1075
|
}) : i.push(a);
|
|
1066
1076
|
}) : Object.keys(u).forEach(function(a) {
|
|
1067
|
-
|
|
1077
|
+
V(u[a]) ? i = i.concat(u[a]) : L(u[a]) ? Object.keys(u[a]).forEach(function(c) {
|
|
1068
1078
|
i = i.concat(u[a][c]);
|
|
1069
1079
|
}) : i.push(u[a]);
|
|
1070
1080
|
}), n = i.filter(function(a) {
|
|
1071
|
-
return
|
|
1081
|
+
return L(a);
|
|
1072
1082
|
}), n = n.length === 0, r -= 1;
|
|
1073
1083
|
};
|
|
1074
1084
|
for (s(this.items); !n && r > 0; )
|
|
@@ -1081,16 +1091,16 @@ var Pe = function(t) {
|
|
|
1081
1091
|
}) : Object.keys(this.items).forEach(function(n) {
|
|
1082
1092
|
r[t.items[n]] = n;
|
|
1083
1093
|
}), new this.constructor(r);
|
|
1084
|
-
},
|
|
1094
|
+
}, Me = function(t, r) {
|
|
1085
1095
|
var n = this, i = {};
|
|
1086
1096
|
return Array.isArray(this.items) ? i = this.items.slice(t * r - r, t * r) : Object.keys(this.items).slice(t * r - r, t * r).forEach(function(s) {
|
|
1087
1097
|
i[s] = n.items[s];
|
|
1088
1098
|
}), new this.constructor(i);
|
|
1089
1099
|
}, Je = function(t) {
|
|
1090
1100
|
return Array.isArray(this.items) ? this.items.splice(t, 1) : delete this.items[t], this;
|
|
1091
|
-
},
|
|
1101
|
+
}, Ve = d, Le = Ve.isFunction, xe = function(t) {
|
|
1092
1102
|
var r = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : null;
|
|
1093
|
-
return this.items[t] !== void 0 ? this.items[t] :
|
|
1103
|
+
return this.items[t] !== void 0 ? this.items[t] : Le(r) ? r() : r !== null ? r : null;
|
|
1094
1104
|
}, j = function(t, r) {
|
|
1095
1105
|
try {
|
|
1096
1106
|
return r.split(".").reduce(function(n, i) {
|
|
@@ -1099,11 +1109,11 @@ var Pe = function(t) {
|
|
|
1099
1109
|
} catch {
|
|
1100
1110
|
return t;
|
|
1101
1111
|
}
|
|
1102
|
-
},
|
|
1112
|
+
}, x = j, He = d, Ge = He.isFunction, Qe = function(t) {
|
|
1103
1113
|
var r = this, n = {};
|
|
1104
1114
|
return this.items.forEach(function(i, s) {
|
|
1105
1115
|
var o;
|
|
1106
|
-
Ge(t) ? o = t(i, s) :
|
|
1116
|
+
Ge(t) ? o = t(i, s) : x(i, t) || x(i, t) === 0 ? o = x(i, t) : o = "", n[o] === void 0 && (n[o] = new r.constructor([])), n[o].push(i);
|
|
1107
1117
|
}), new this.constructor(n);
|
|
1108
1118
|
}, ze = U, Xe = function() {
|
|
1109
1119
|
for (var t = this, r = arguments.length, n = new Array(r), i = 0; i < r; i++)
|
|
@@ -1263,7 +1273,7 @@ var $n = function(t) {
|
|
|
1263
1273
|
});
|
|
1264
1274
|
};
|
|
1265
1275
|
function En(e, t) {
|
|
1266
|
-
return
|
|
1276
|
+
return Fn(e) || Dn(e, t) || Cn(e, t) || In();
|
|
1267
1277
|
}
|
|
1268
1278
|
function In() {
|
|
1269
1279
|
throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
@@ -1283,7 +1293,7 @@ function vt(e, t) {
|
|
|
1283
1293
|
n[r] = e[r];
|
|
1284
1294
|
return n;
|
|
1285
1295
|
}
|
|
1286
|
-
function
|
|
1296
|
+
function Dn(e, t) {
|
|
1287
1297
|
var r = e == null ? null : typeof Symbol < "u" && e[Symbol.iterator] || e["@@iterator"];
|
|
1288
1298
|
if (r != null) {
|
|
1289
1299
|
var n = [], i = !0, s = !1, o, u;
|
|
@@ -1302,10 +1312,10 @@ function Tn(e, t) {
|
|
|
1302
1312
|
return n;
|
|
1303
1313
|
}
|
|
1304
1314
|
}
|
|
1305
|
-
function
|
|
1315
|
+
function Fn(e) {
|
|
1306
1316
|
if (Array.isArray(e)) return e;
|
|
1307
1317
|
}
|
|
1308
|
-
var
|
|
1318
|
+
var Tn = function(t) {
|
|
1309
1319
|
var r = {};
|
|
1310
1320
|
return this.items.forEach(function(n, i) {
|
|
1311
1321
|
var s = t(n, i), o = En(s, 2), u = o[0], a = o[1];
|
|
@@ -1313,9 +1323,9 @@ var Fn = function(t) {
|
|
|
1313
1323
|
}), new this.constructor(r);
|
|
1314
1324
|
};
|
|
1315
1325
|
function bt(e, t) {
|
|
1316
|
-
return qn(e) || Bn(e, t) || Nn(e, t) ||
|
|
1326
|
+
return qn(e) || Bn(e, t) || Nn(e, t) || Pn();
|
|
1317
1327
|
}
|
|
1318
|
-
function
|
|
1328
|
+
function Pn() {
|
|
1319
1329
|
throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
1320
1330
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`);
|
|
1321
1331
|
}
|
|
@@ -1355,7 +1365,7 @@ function Bn(e, t) {
|
|
|
1355
1365
|
function qn(e) {
|
|
1356
1366
|
if (Array.isArray(e)) return e;
|
|
1357
1367
|
}
|
|
1358
|
-
var
|
|
1368
|
+
var Kn = function(t) {
|
|
1359
1369
|
var r = this, n = {};
|
|
1360
1370
|
return Array.isArray(this.items) ? this.items.forEach(function(i, s) {
|
|
1361
1371
|
var o = t(i, s), u = bt(o, 2), a = u[0], c = u[1];
|
|
@@ -1366,9 +1376,9 @@ var xn = function(t) {
|
|
|
1366
1376
|
}), new this.constructor(n);
|
|
1367
1377
|
};
|
|
1368
1378
|
function wt(e) {
|
|
1369
|
-
return
|
|
1379
|
+
return Mn(e) || Wn(e) || Un(e) || Rn();
|
|
1370
1380
|
}
|
|
1371
|
-
function
|
|
1381
|
+
function Rn() {
|
|
1372
1382
|
throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
|
1373
1383
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`);
|
|
1374
1384
|
}
|
|
@@ -1383,7 +1393,7 @@ function Un(e, t) {
|
|
|
1383
1393
|
function Wn(e) {
|
|
1384
1394
|
if (typeof Symbol < "u" && e[Symbol.iterator] != null || e["@@iterator"] != null) return Array.from(e);
|
|
1385
1395
|
}
|
|
1386
|
-
function
|
|
1396
|
+
function Mn(e) {
|
|
1387
1397
|
if (Array.isArray(e)) return nt(e);
|
|
1388
1398
|
}
|
|
1389
1399
|
function nt(e, t) {
|
|
@@ -1402,10 +1412,10 @@ var Jn = function(t) {
|
|
|
1402
1412
|
})));
|
|
1403
1413
|
}
|
|
1404
1414
|
return Math.max.apply(Math, wt(this.items));
|
|
1405
|
-
},
|
|
1415
|
+
}, Vn = function(t) {
|
|
1406
1416
|
var r = this.items.length;
|
|
1407
1417
|
return t === void 0 ? r % 2 === 0 ? (this.items[r / 2 - 1] + this.items[r / 2]) / 2 : this.items[Math.floor(r / 2)] : r % 2 === 0 ? (this.items[r / 2 - 1][t] + this.items[r / 2][t]) / 2 : this.items[Math.floor(r / 2)][t];
|
|
1408
|
-
},
|
|
1418
|
+
}, Ln = function(t) {
|
|
1409
1419
|
var r = t;
|
|
1410
1420
|
if (typeof r == "string" && (r = [r]), Array.isArray(this.items) && Array.isArray(r))
|
|
1411
1421
|
return new this.constructor(this.items.concat(r));
|
|
@@ -1414,13 +1424,13 @@ var Jn = function(t) {
|
|
|
1414
1424
|
n[i] = r[i];
|
|
1415
1425
|
}), new this.constructor(n);
|
|
1416
1426
|
};
|
|
1417
|
-
function
|
|
1427
|
+
function R(e) {
|
|
1418
1428
|
"@babel/helpers - typeof";
|
|
1419
|
-
return
|
|
1429
|
+
return R = typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? function(t) {
|
|
1420
1430
|
return typeof t;
|
|
1421
1431
|
} : function(t) {
|
|
1422
1432
|
return t && typeof Symbol == "function" && t.constructor === Symbol && t !== Symbol.prototype ? "symbol" : typeof t;
|
|
1423
|
-
},
|
|
1433
|
+
}, R(e);
|
|
1424
1434
|
}
|
|
1425
1435
|
function At(e, t) {
|
|
1426
1436
|
var r = Object.keys(e);
|
|
@@ -1436,21 +1446,21 @@ function _t(e) {
|
|
|
1436
1446
|
for (var t = 1; t < arguments.length; t++) {
|
|
1437
1447
|
var r = arguments[t] != null ? arguments[t] : {};
|
|
1438
1448
|
t % 2 ? At(Object(r), !0).forEach(function(n) {
|
|
1439
|
-
|
|
1449
|
+
xn(e, n, r[n]);
|
|
1440
1450
|
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(r)) : At(Object(r)).forEach(function(n) {
|
|
1441
1451
|
Object.defineProperty(e, n, Object.getOwnPropertyDescriptor(r, n));
|
|
1442
1452
|
});
|
|
1443
1453
|
}
|
|
1444
1454
|
return e;
|
|
1445
1455
|
}
|
|
1446
|
-
function
|
|
1456
|
+
function xn(e, t, r) {
|
|
1447
1457
|
return t in e ? Object.defineProperty(e, t, { value: r, enumerable: !0, configurable: !0, writable: !0 }) : e[t] = r, e;
|
|
1448
1458
|
}
|
|
1449
1459
|
var Hn = function(t) {
|
|
1450
1460
|
var r = function n(i, s) {
|
|
1451
1461
|
var o = {}, u = Object.keys(_t(_t({}, i), s));
|
|
1452
1462
|
return u.forEach(function(a) {
|
|
1453
|
-
i[a] === void 0 && s[a] !== void 0 ? o[a] = s[a] : i[a] !== void 0 && s[a] === void 0 ? o[a] = i[a] : i[a] !== void 0 && s[a] !== void 0 && (i[a] === s[a] ? o[a] = i[a] : !Array.isArray(i[a]) &&
|
|
1463
|
+
i[a] === void 0 && s[a] !== void 0 ? o[a] = s[a] : i[a] !== void 0 && s[a] === void 0 ? o[a] = i[a] : i[a] !== void 0 && s[a] !== void 0 && (i[a] === s[a] ? o[a] = i[a] : !Array.isArray(i[a]) && R(i[a]) === "object" && !Array.isArray(s[a]) && R(s[a]) === "object" ? o[a] = n(i[a], s[a]) : o[a] = [].concat(i[a], s[a]));
|
|
1454
1464
|
}), o;
|
|
1455
1465
|
};
|
|
1456
1466
|
return t ? t.constructor.name === "Collection" ? new this.constructor(r(this.items, t.all())) : new this.constructor(r(this.items, t)) : this;
|
|
@@ -1552,7 +1562,7 @@ var Yn = function(t) {
|
|
|
1552
1562
|
})), new this.constructor(n);
|
|
1553
1563
|
}, oi = function(t) {
|
|
1554
1564
|
return t(this);
|
|
1555
|
-
},
|
|
1565
|
+
}, Lt = d, ai = Lt.isArray, ui = Lt.isObject, T = j, ci = function(t) {
|
|
1556
1566
|
var r = {};
|
|
1557
1567
|
return t.forEach(function(n, i) {
|
|
1558
1568
|
function s(o, u) {
|
|
@@ -1569,8 +1579,8 @@ var Yn = function(t) {
|
|
|
1569
1579
|
var n = ci(this.items), i = [];
|
|
1570
1580
|
if (r !== void 0) {
|
|
1571
1581
|
var s = new RegExp("0.".concat(r), "g"), o = "0.".concat(r).split(".").length;
|
|
1572
|
-
Object.keys(n).forEach(function(
|
|
1573
|
-
var m =
|
|
1582
|
+
Object.keys(n).forEach(function(l) {
|
|
1583
|
+
var m = l.match(s);
|
|
1574
1584
|
if (m) {
|
|
1575
1585
|
var g = m[0];
|
|
1576
1586
|
g.split(".").length === o && i.push(n[g]);
|
|
@@ -1578,36 +1588,36 @@ var Yn = function(t) {
|
|
|
1578
1588
|
});
|
|
1579
1589
|
}
|
|
1580
1590
|
var u = [], a = new RegExp("0.".concat(t), "g"), c = "0.".concat(t).split(".").length;
|
|
1581
|
-
if (Object.keys(n).forEach(function(
|
|
1582
|
-
var m =
|
|
1591
|
+
if (Object.keys(n).forEach(function(l) {
|
|
1592
|
+
var m = l.match(a);
|
|
1583
1593
|
if (m) {
|
|
1584
1594
|
var g = m[0];
|
|
1585
1595
|
g.split(".").length === c && u.push(n[g]);
|
|
1586
1596
|
}
|
|
1587
1597
|
}), r !== void 0) {
|
|
1588
|
-
var
|
|
1589
|
-
return this.items.forEach(function(
|
|
1590
|
-
|
|
1591
|
-
}), new this.constructor(
|
|
1598
|
+
var p = {};
|
|
1599
|
+
return this.items.forEach(function(l, m) {
|
|
1600
|
+
p[i[m] || ""] = u;
|
|
1601
|
+
}), new this.constructor(p);
|
|
1592
1602
|
}
|
|
1593
1603
|
return new this.constructor([u]);
|
|
1594
1604
|
}
|
|
1595
1605
|
if (r !== void 0) {
|
|
1596
1606
|
var v = {};
|
|
1597
|
-
return this.items.forEach(function(
|
|
1598
|
-
|
|
1607
|
+
return this.items.forEach(function(l) {
|
|
1608
|
+
T(l, t) !== void 0 ? v[l[r] || ""] = T(l, t) : v[l[r] || ""] = null;
|
|
1599
1609
|
}), new this.constructor(v);
|
|
1600
1610
|
}
|
|
1601
|
-
return this.map(function(
|
|
1602
|
-
return
|
|
1611
|
+
return this.map(function(l) {
|
|
1612
|
+
return T(l, t) !== void 0 ? T(l, t) : null;
|
|
1603
1613
|
});
|
|
1604
|
-
}, li = U,
|
|
1614
|
+
}, li = U, xt = function(t) {
|
|
1605
1615
|
for (var r = arguments.length, n = new Array(r > 1 ? r - 1 : 0), i = 1; i < r; i++)
|
|
1606
1616
|
n[i - 1] = arguments[i];
|
|
1607
1617
|
li(n).forEach(function(s) {
|
|
1608
1618
|
delete t[s];
|
|
1609
1619
|
});
|
|
1610
|
-
}, Ht = d, hi = Ht.isArray, pi = Ht.isObject, St =
|
|
1620
|
+
}, Ht = d, hi = Ht.isArray, pi = Ht.isObject, St = xt, yi = function() {
|
|
1611
1621
|
var t = this, r = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : 1;
|
|
1612
1622
|
if (this.isEmpty())
|
|
1613
1623
|
return null;
|
|
@@ -1660,7 +1670,7 @@ function $t(e, t) {
|
|
|
1660
1670
|
}
|
|
1661
1671
|
return r;
|
|
1662
1672
|
}
|
|
1663
|
-
function
|
|
1673
|
+
function P(e) {
|
|
1664
1674
|
for (var t = 1; t < arguments.length; t++) {
|
|
1665
1675
|
var r = arguments[t] != null ? arguments[t] : {};
|
|
1666
1676
|
t % 2 ? $t(Object(r), !0).forEach(function(n) {
|
|
@@ -1684,10 +1694,10 @@ var ji = function(t) {
|
|
|
1684
1694
|
return new this.constructor(r);
|
|
1685
1695
|
}
|
|
1686
1696
|
if (t.constructor.name === "Collection") {
|
|
1687
|
-
var n =
|
|
1697
|
+
var n = P(P({}, this.items), t.all());
|
|
1688
1698
|
return new this.constructor(n);
|
|
1689
1699
|
}
|
|
1690
|
-
var i =
|
|
1700
|
+
var i = P(P({}, this.items), t);
|
|
1691
1701
|
return new this.constructor(i);
|
|
1692
1702
|
};
|
|
1693
1703
|
function I(e) {
|
|
@@ -1708,7 +1718,7 @@ function jt(e, t) {
|
|
|
1708
1718
|
}
|
|
1709
1719
|
return r;
|
|
1710
1720
|
}
|
|
1711
|
-
function
|
|
1721
|
+
function D(e) {
|
|
1712
1722
|
for (var t = 1; t < arguments.length; t++) {
|
|
1713
1723
|
var r = arguments[t] != null ? arguments[t] : {};
|
|
1714
1724
|
t % 2 ? jt(Object(r), !0).forEach(function(n) {
|
|
@@ -1724,23 +1734,23 @@ function Ei(e, t, r) {
|
|
|
1724
1734
|
}
|
|
1725
1735
|
var Ii = function(t) {
|
|
1726
1736
|
var r = function n(i, s) {
|
|
1727
|
-
var o =
|
|
1737
|
+
var o = D({}, i), u = Object.keys(D(D({}, i), s));
|
|
1728
1738
|
return u.forEach(function(a) {
|
|
1729
|
-
!Array.isArray(s[a]) && I(s[a]) === "object" ? o[a] = n(i[a], s[a]) : i[a] === void 0 && s[a] !== void 0 ? I(i[a]) === "object" ? o[a] =
|
|
1739
|
+
!Array.isArray(s[a]) && I(s[a]) === "object" ? o[a] = n(i[a], s[a]) : i[a] === void 0 && s[a] !== void 0 ? I(i[a]) === "object" ? o[a] = D({}, s[a]) : o[a] = s[a] : i[a] !== void 0 && s[a] === void 0 ? I(i[a]) === "object" ? o[a] = D({}, i[a]) : o[a] = i[a] : i[a] !== void 0 && s[a] !== void 0 && (I(s[a]) === "object" ? o[a] = D({}, s[a]) : o[a] = s[a]);
|
|
1730
1740
|
}), o;
|
|
1731
1741
|
};
|
|
1732
1742
|
return t ? !Array.isArray(t) && I(t) !== "object" ? new this.constructor(r(this.items, [t])) : t.constructor.name === "Collection" ? new this.constructor(r(this.items, t.all())) : new this.constructor(r(this.items, t)) : this;
|
|
1733
1743
|
}, Ci = function() {
|
|
1734
1744
|
var t = [].concat(this.items).reverse();
|
|
1735
1745
|
return new this.constructor(t);
|
|
1736
|
-
}, ut = d,
|
|
1746
|
+
}, ut = d, Di = ut.isArray, Fi = ut.isObject, Ti = ut.isFunction, Pi = function(t, r) {
|
|
1737
1747
|
var n = this, i, s = function(u, a) {
|
|
1738
|
-
return
|
|
1748
|
+
return Ti(t) ? t(n.items[a], a) : r ? n.items[a] === t : n.items[a] == t;
|
|
1739
1749
|
};
|
|
1740
|
-
return
|
|
1750
|
+
return Di(this.items) ? i = this.items.findIndex(s) : Fi(this.items) && (i = Object.keys(this.items).find(function(o) {
|
|
1741
1751
|
return s(n.items[o], o);
|
|
1742
1752
|
})), i === void 0 || i < 0 ? !1 : i;
|
|
1743
|
-
}, Gt = d, Ni = Gt.isArray, Bi = Gt.isObject, qi =
|
|
1753
|
+
}, Gt = d, Ni = Gt.isArray, Bi = Gt.isObject, qi = xt, Ki = function() {
|
|
1744
1754
|
var t = this, r = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : 1;
|
|
1745
1755
|
if (this.isEmpty())
|
|
1746
1756
|
return null;
|
|
@@ -1757,23 +1767,23 @@ var Ii = function(t) {
|
|
|
1757
1767
|
return qi(this.items, o), new this.constructor(u);
|
|
1758
1768
|
}
|
|
1759
1769
|
return null;
|
|
1760
|
-
},
|
|
1761
|
-
var t =
|
|
1770
|
+
}, Ri = $, Ui = function() {
|
|
1771
|
+
var t = Ri(this.items), r, n, i;
|
|
1762
1772
|
for (i = t.length; i; i -= 1)
|
|
1763
1773
|
r = Math.floor(Math.random() * i), n = t[i - 1], t[i - 1] = t[r], t[r] = n;
|
|
1764
1774
|
return this.items = t, this;
|
|
1765
|
-
}, Wi = d,
|
|
1775
|
+
}, Wi = d, Mi = Wi.isObject, Ji = function(t) {
|
|
1766
1776
|
var r = this;
|
|
1767
|
-
return
|
|
1777
|
+
return Mi(this.items) ? new this.constructor(Object.keys(this.items).reduce(function(n, i, s) {
|
|
1768
1778
|
return s + 1 > t && (n[i] = r.items[i]), n;
|
|
1769
1779
|
}, {})) : new this.constructor(this.items.slice(t));
|
|
1770
|
-
}, ct = d,
|
|
1780
|
+
}, ct = d, Vi = ct.isArray, Li = ct.isObject, xi = ct.isFunction, Hi = function(t) {
|
|
1771
1781
|
var r = this, n = null, i, s = function(u) {
|
|
1772
1782
|
return u === t;
|
|
1773
1783
|
};
|
|
1774
|
-
return
|
|
1784
|
+
return xi(t) && (s = t), Vi(this.items) && (i = this.items.filter(function(o) {
|
|
1775
1785
|
return n !== !0 && (n = s(o)), n;
|
|
1776
|
-
})),
|
|
1786
|
+
})), Li(this.items) && (i = Object.keys(this.items).reduce(function(o, u) {
|
|
1777
1787
|
return n !== !0 && (n = s(r.items[u])), n !== !1 && (o[u] = r.items[u]), o;
|
|
1778
1788
|
}, {})), new this.constructor(i);
|
|
1779
1789
|
}, ft = d, Gi = ft.isArray, Qi = ft.isObject, zi = ft.isFunction, Xi = function(t) {
|
|
@@ -1795,7 +1805,7 @@ var Ii = function(t) {
|
|
|
1795
1805
|
if (i.count() > 1)
|
|
1796
1806
|
throw new Error("Multiple items found.");
|
|
1797
1807
|
return i.first();
|
|
1798
|
-
}, rs =
|
|
1808
|
+
}, rs = Mt, es = rs, ns = function(t) {
|
|
1799
1809
|
var r = [].concat(this.items);
|
|
1800
1810
|
return t === void 0 ? this.every(function(n) {
|
|
1801
1811
|
return typeof n == "number";
|
|
@@ -1916,9 +1926,9 @@ function ot(e) {
|
|
|
1916
1926
|
return t && typeof Symbol == "function" && t.constructor === Symbol && t !== Symbol.prototype ? "symbol" : typeof t;
|
|
1917
1927
|
}, ot(e);
|
|
1918
1928
|
}
|
|
1919
|
-
var
|
|
1929
|
+
var Ds = function() {
|
|
1920
1930
|
return ot(this.items) === "object" && !Array.isArray(this.items) ? JSON.stringify(this.all()) : JSON.stringify(this.toArray());
|
|
1921
|
-
},
|
|
1931
|
+
}, Fs = function(t) {
|
|
1922
1932
|
var r = this;
|
|
1923
1933
|
if (Array.isArray(this.items))
|
|
1924
1934
|
this.items = this.items.map(t);
|
|
@@ -1944,17 +1954,17 @@ function It(e) {
|
|
|
1944
1954
|
for (var t = 1; t < arguments.length; t++) {
|
|
1945
1955
|
var r = arguments[t] != null ? arguments[t] : {};
|
|
1946
1956
|
t % 2 ? Et(Object(r), !0).forEach(function(n) {
|
|
1947
|
-
|
|
1957
|
+
Ts(e, n, r[n]);
|
|
1948
1958
|
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(r)) : Et(Object(r)).forEach(function(n) {
|
|
1949
1959
|
Object.defineProperty(e, n, Object.getOwnPropertyDescriptor(r, n));
|
|
1950
1960
|
});
|
|
1951
1961
|
}
|
|
1952
1962
|
return e;
|
|
1953
1963
|
}
|
|
1954
|
-
function
|
|
1964
|
+
function Ts(e, t, r) {
|
|
1955
1965
|
return t in e ? Object.defineProperty(e, t, { value: r, enumerable: !0, configurable: !0, writable: !0 }) : e[t] = r, e;
|
|
1956
1966
|
}
|
|
1957
|
-
var
|
|
1967
|
+
var Ps = function() {
|
|
1958
1968
|
var t = this;
|
|
1959
1969
|
if (Array.isArray(this.items))
|
|
1960
1970
|
return this;
|
|
@@ -1982,7 +1992,7 @@ var Ds = function() {
|
|
|
1982
1992
|
return r(this);
|
|
1983
1993
|
}
|
|
1984
1994
|
return this;
|
|
1985
|
-
},
|
|
1995
|
+
}, Dt = function(t, r) {
|
|
1986
1996
|
if (Array.isArray(this.items) && !this.items.length)
|
|
1987
1997
|
return t(this);
|
|
1988
1998
|
if (!Object.keys(this.items).length)
|
|
@@ -1999,7 +2009,7 @@ var Ds = function() {
|
|
|
1999
2009
|
return Object.keys(t).forEach(function(i) {
|
|
2000
2010
|
r.items[i] === void 0 && (n[i] = t[i]);
|
|
2001
2011
|
}), new this.constructor(n);
|
|
2002
|
-
}, qs = d,
|
|
2012
|
+
}, qs = d, Ks = qs.isFunction, Rs = function(t) {
|
|
2003
2013
|
var r;
|
|
2004
2014
|
if (t === void 0)
|
|
2005
2015
|
r = this.items.filter(function(u, a, c) {
|
|
@@ -2009,51 +2019,51 @@ var Ds = function() {
|
|
|
2009
2019
|
r = [];
|
|
2010
2020
|
for (var n = [], i = 0, s = this.items.length; i < s; i += 1) {
|
|
2011
2021
|
var o = void 0;
|
|
2012
|
-
|
|
2022
|
+
Ks(t) ? o = t(this.items[i]) : o = this.items[i][t], n.indexOf(o) === -1 && (r.push(this.items[i]), n.push(o));
|
|
2013
2023
|
}
|
|
2014
2024
|
}
|
|
2015
2025
|
return new this.constructor(r);
|
|
2016
2026
|
}, Us = function(t) {
|
|
2017
2027
|
return t instanceof this.constructor ? t.all() : t;
|
|
2018
|
-
}, Ws = $,
|
|
2028
|
+
}, Ws = $, Ms = function() {
|
|
2019
2029
|
return new this.constructor(Ws(this.items));
|
|
2020
2030
|
}, Js = function(t, r, n) {
|
|
2021
2031
|
return t ? r(this, t) : n ? n(this, t) : this;
|
|
2022
|
-
},
|
|
2023
|
-
var i = r, s = n, o =
|
|
2032
|
+
}, Vs = $, O = j, Ls = function(t, r, n) {
|
|
2033
|
+
var i = r, s = n, o = Vs(this.items);
|
|
2024
2034
|
if (r === void 0 || r === !0)
|
|
2025
2035
|
return new this.constructor(o.filter(function(a) {
|
|
2026
|
-
return
|
|
2036
|
+
return O(a, t);
|
|
2027
2037
|
}));
|
|
2028
2038
|
if (r === !1)
|
|
2029
2039
|
return new this.constructor(o.filter(function(a) {
|
|
2030
|
-
return !
|
|
2040
|
+
return !O(a, t);
|
|
2031
2041
|
}));
|
|
2032
2042
|
n === void 0 && (s = r, i = "===");
|
|
2033
2043
|
var u = o.filter(function(a) {
|
|
2034
2044
|
switch (i) {
|
|
2035
2045
|
case "==":
|
|
2036
|
-
return
|
|
2046
|
+
return O(a, t) === Number(s) || O(a, t) === s.toString();
|
|
2037
2047
|
default:
|
|
2038
2048
|
case "===":
|
|
2039
|
-
return
|
|
2049
|
+
return O(a, t) === s;
|
|
2040
2050
|
case "!=":
|
|
2041
2051
|
case "<>":
|
|
2042
|
-
return
|
|
2052
|
+
return O(a, t) !== Number(s) && O(a, t) !== s.toString();
|
|
2043
2053
|
case "!==":
|
|
2044
|
-
return
|
|
2054
|
+
return O(a, t) !== s;
|
|
2045
2055
|
case "<":
|
|
2046
|
-
return
|
|
2056
|
+
return O(a, t) < s;
|
|
2047
2057
|
case "<=":
|
|
2048
|
-
return
|
|
2058
|
+
return O(a, t) <= s;
|
|
2049
2059
|
case ">":
|
|
2050
|
-
return
|
|
2060
|
+
return O(a, t) > s;
|
|
2051
2061
|
case ">=":
|
|
2052
|
-
return
|
|
2062
|
+
return O(a, t) >= s;
|
|
2053
2063
|
}
|
|
2054
2064
|
});
|
|
2055
2065
|
return new this.constructor(u);
|
|
2056
|
-
},
|
|
2066
|
+
}, xs = function(t, r) {
|
|
2057
2067
|
return this.where(t, ">=", r[0]).where(t, "<=", r[r.length - 1]);
|
|
2058
2068
|
}, Hs = $, Gs = j, Qs = function(t, r) {
|
|
2059
2069
|
var n = Hs(r), i = this.items.filter(function(s) {
|
|
@@ -2064,9 +2074,9 @@ var Ds = function() {
|
|
|
2064
2074
|
return this.filter(function(r) {
|
|
2065
2075
|
return r instanceof t;
|
|
2066
2076
|
});
|
|
2067
|
-
},
|
|
2077
|
+
}, Ft = j, Xs = function(t, r) {
|
|
2068
2078
|
return this.filter(function(n) {
|
|
2069
|
-
return
|
|
2079
|
+
return Ft(n, t) < r[0] || Ft(n, t) > r[r.length - 1];
|
|
2070
2080
|
});
|
|
2071
2081
|
}, Ys = $, Zs = j, ks = function(t, r) {
|
|
2072
2082
|
var n = Ys(r), i = this.items.filter(function(s) {
|
|
@@ -2113,13 +2123,13 @@ var eo = function(t) {
|
|
|
2113
2123
|
var n = _r;
|
|
2114
2124
|
typeof Symbol < "u" && (r.prototype[Symbol.iterator] = n), r.prototype.toJSON = function() {
|
|
2115
2125
|
return this.items;
|
|
2116
|
-
}, r.prototype.all = Or, r.prototype.average = Ut, r.prototype.avg = Er, r.prototype.chunk = Ir, r.prototype.collapse = Nr, r.prototype.combine = Wr, r.prototype.concat = Gr, r.prototype.contains =
|
|
2126
|
+
}, r.prototype.all = Or, r.prototype.average = Ut, r.prototype.avg = Er, r.prototype.chunk = Ir, r.prototype.collapse = Nr, r.prototype.combine = Wr, r.prototype.concat = Gr, r.prototype.contains = Mt, r.prototype.containsOneItem = oe, r.prototype.count = ae, r.prototype.countBy = ue, r.prototype.crossJoin = ce, r.prototype.dd = fe, r.prototype.diff = le, r.prototype.diffAssoc = he, r.prototype.diffKeys = pe, r.prototype.diffUsing = ye, r.prototype.doesntContain = me, r.prototype.dump = de, r.prototype.duplicates = ve, r.prototype.each = be, r.prototype.eachSpread = Se, r.prototype.every = je, r.prototype.except = Ie, r.prototype.filter = Fe, r.prototype.first = Pe, r.prototype.firstOrFail = qe, r.prototype.firstWhere = Ke, r.prototype.flatMap = Re, r.prototype.flatten = Ue, r.prototype.flip = We, r.prototype.forPage = Me, r.prototype.forget = Je, r.prototype.get = xe, r.prototype.groupBy = Qe, r.prototype.has = Xe, r.prototype.implode = Ye, r.prototype.intersect = Ze, r.prototype.intersectByKeys = ke, r.prototype.isEmpty = tn, r.prototype.isNotEmpty = rn, r.prototype.join = en, r.prototype.keyBy = an, r.prototype.keys = un, r.prototype.last = fn, r.prototype.macro = ln, r.prototype.make = hn, r.prototype.map = pn, r.prototype.mapSpread = gn, r.prototype.mapToDictionary = $n, r.prototype.mapInto = jn, r.prototype.mapToGroups = Tn, r.prototype.mapWithKeys = Kn, r.prototype.max = Jn, r.prototype.median = Vn, r.prototype.merge = Ln, r.prototype.mergeRecursive = Hn, r.prototype.min = Yn, r.prototype.mode = Zn, r.prototype.nth = ti, r.prototype.only = ei, r.prototype.pad = ii, r.prototype.partition = si, r.prototype.pipe = oi, r.prototype.pluck = fi, r.prototype.pop = yi, r.prototype.prepend = mi, r.prototype.pull = bi, r.prototype.push = gi, r.prototype.put = wi, r.prototype.random = _i, r.prototype.reduce = Oi, r.prototype.reject = Si, r.prototype.replace = ji, r.prototype.replaceRecursive = Ii, r.prototype.reverse = Ci, r.prototype.search = Pi, r.prototype.shift = Ki, r.prototype.shuffle = Ui, r.prototype.skip = Ji, r.prototype.skipUntil = Hi, r.prototype.skipWhile = Xi, r.prototype.slice = Yi, r.prototype.sole = ts, r.prototype.some = es, r.prototype.sort = ns, r.prototype.sortDesc = is, r.prototype.sortBy = us, r.prototype.sortByDesc = cs, r.prototype.sortKeys = fs, r.prototype.sortKeysDesc = ls, r.prototype.splice = hs, r.prototype.split = ps, r.prototype.sum = vs, r.prototype.take = bs, r.prototype.takeUntil = _s, r.prototype.takeWhile = js, r.prototype.tap = Es, r.prototype.times = Is, r.prototype.toArray = Cs, r.prototype.toJson = Ds, r.prototype.transform = Fs, r.prototype.undot = Ps, r.prototype.unless = Ns, r.prototype.unlessEmpty = Ct, r.prototype.unlessNotEmpty = Dt, r.prototype.union = Bs, r.prototype.unique = Rs, r.prototype.unwrap = Us, r.prototype.values = Ms, r.prototype.when = Js, r.prototype.whenEmpty = Dt, r.prototype.whenNotEmpty = Ct, r.prototype.where = Ls, r.prototype.whereBetween = xs, r.prototype.whereIn = Qs, r.prototype.whereInstanceOf = zs, r.prototype.whereNotBetween = Xs, r.prototype.whereNotIn = ks, r.prototype.whereNull = to, r.prototype.whereNotNull = ro, r.prototype.wrap = eo, r.prototype.zip = no;
|
|
2117
2127
|
var i = function(o) {
|
|
2118
2128
|
return new r(o);
|
|
2119
2129
|
};
|
|
2120
2130
|
e.exports = i, e.exports.collect = i, e.exports.default = i, e.exports.Collection = r;
|
|
2121
|
-
})(
|
|
2122
|
-
var io =
|
|
2131
|
+
})(Rt);
|
|
2132
|
+
var io = Rt.exports;
|
|
2123
2133
|
const Qt = /* @__PURE__ */ Ar(io), zt = [
|
|
2124
2134
|
"chunk",
|
|
2125
2135
|
"shuffle",
|
|
@@ -2165,18 +2175,18 @@ const Qt = /* @__PURE__ */ Ar(io), zt = [
|
|
|
2165
2175
|
];
|
|
2166
2176
|
class S {
|
|
2167
2177
|
constructor(t, r) {
|
|
2168
|
-
|
|
2169
|
-
|
|
2170
|
-
|
|
2171
|
-
|
|
2172
|
-
|
|
2173
|
-
|
|
2174
|
-
|
|
2175
|
-
|
|
2176
|
-
|
|
2177
|
-
|
|
2178
|
-
|
|
2179
|
-
|
|
2178
|
+
A(this, "data_path", "");
|
|
2179
|
+
A(this, "axios");
|
|
2180
|
+
A(this, "filters");
|
|
2181
|
+
A(this, "steps");
|
|
2182
|
+
A(this, "fields");
|
|
2183
|
+
A(this, "already_limit", !1);
|
|
2184
|
+
A(this, "already_offset", !1);
|
|
2185
|
+
A(this, "limit", null);
|
|
2186
|
+
A(this, "offset", null);
|
|
2187
|
+
A(this, "_sort", null);
|
|
2188
|
+
A(this, "_sortDesc", !1);
|
|
2189
|
+
A(this, "meta", {});
|
|
2180
2190
|
this.axios = r, this.filters = {}, this.steps = [], this.fields = t;
|
|
2181
2191
|
}
|
|
2182
2192
|
}
|
|
@@ -2213,7 +2223,7 @@ S.prototype.fetchData = async function() {
|
|
|
2213
2223
|
}
|
|
2214
2224
|
n[u] = {}, n = n[u];
|
|
2215
2225
|
}
|
|
2216
|
-
let o = await
|
|
2226
|
+
let o = await w(this.axios, r);
|
|
2217
2227
|
for (const u of t)
|
|
2218
2228
|
o = o[u];
|
|
2219
2229
|
return this.meta = o.meta, Qt(o.data);
|
|
@@ -2256,11 +2266,101 @@ S.prototype.first = async function() {
|
|
|
2256
2266
|
const ao = (e, t, r) => {
|
|
2257
2267
|
const n = new S(r, t);
|
|
2258
2268
|
return n.data_path = "list" + e, n;
|
|
2259
|
-
},
|
|
2269
|
+
}, uo = (e, t) => ({
|
|
2270
|
+
folders: {
|
|
2271
|
+
list: async (r, n = {
|
|
2272
|
+
name: !0,
|
|
2273
|
+
path: !0
|
|
2274
|
+
}) => (await w(t, {
|
|
2275
|
+
app: {
|
|
2276
|
+
drive: {
|
|
2277
|
+
__args: {
|
|
2278
|
+
index: e
|
|
2279
|
+
},
|
|
2280
|
+
folders: {
|
|
2281
|
+
__args: {
|
|
2282
|
+
path: r
|
|
2283
|
+
},
|
|
2284
|
+
...n
|
|
2285
|
+
}
|
|
2286
|
+
}
|
|
2287
|
+
}
|
|
2288
|
+
})).app.drive.folders,
|
|
2289
|
+
create: (r) => f(t, "lightDriveCreateFolder", { index: e, path: r }),
|
|
2290
|
+
delete: (r) => f(t, "lightDriveDeleteFolder", { index: e, path: r }),
|
|
2291
|
+
rename: (r, n) => f(t, "lightDriveRenameFolder", { index: e, path: r, name: n })
|
|
2292
|
+
},
|
|
2293
|
+
files: {
|
|
2294
|
+
list: async (r, n = {
|
|
2295
|
+
name: !0,
|
|
2296
|
+
path: !0,
|
|
2297
|
+
size: !0,
|
|
2298
|
+
mime: !0,
|
|
2299
|
+
url: !0
|
|
2300
|
+
}) => (await w(t, {
|
|
2301
|
+
app: {
|
|
2302
|
+
drive: {
|
|
2303
|
+
__args: {
|
|
2304
|
+
index: e
|
|
2305
|
+
},
|
|
2306
|
+
files: {
|
|
2307
|
+
__args: {
|
|
2308
|
+
path: r
|
|
2309
|
+
},
|
|
2310
|
+
...n
|
|
2311
|
+
}
|
|
2312
|
+
}
|
|
2313
|
+
}
|
|
2314
|
+
})).app.drive.files,
|
|
2315
|
+
get: async (r, n = {
|
|
2316
|
+
name: !0,
|
|
2317
|
+
path: !0,
|
|
2318
|
+
size: !0,
|
|
2319
|
+
mime: !0,
|
|
2320
|
+
url: !0
|
|
2321
|
+
}) => (await w(t, {
|
|
2322
|
+
app: {
|
|
2323
|
+
drive: {
|
|
2324
|
+
__args: {
|
|
2325
|
+
index: e
|
|
2326
|
+
},
|
|
2327
|
+
file: {
|
|
2328
|
+
__args: {
|
|
2329
|
+
path: r
|
|
2330
|
+
},
|
|
2331
|
+
...n
|
|
2332
|
+
}
|
|
2333
|
+
}
|
|
2334
|
+
}
|
|
2335
|
+
})).app.drive.file,
|
|
2336
|
+
read: async (r) => {
|
|
2337
|
+
let n = await w(t, {
|
|
2338
|
+
app: {
|
|
2339
|
+
drive: {
|
|
2340
|
+
__args: {
|
|
2341
|
+
index: e
|
|
2342
|
+
},
|
|
2343
|
+
file: {
|
|
2344
|
+
__args: {
|
|
2345
|
+
path: r
|
|
2346
|
+
},
|
|
2347
|
+
base64Content: !0
|
|
2348
|
+
}
|
|
2349
|
+
}
|
|
2350
|
+
}
|
|
2351
|
+
});
|
|
2352
|
+
return window.atob(n.app.drive.file.base64Content);
|
|
2353
|
+
},
|
|
2354
|
+
write: (r, n) => f(t, "lightDriveWriteFile", { index: e, path: r, content: n }),
|
|
2355
|
+
delete: (r) => f(t, "lightDriveDeleteFile", { index: e, path: r }),
|
|
2356
|
+
rename: (r, n) => f(t, "lightDriveRenameFile", { index: e, path: r, name: n }),
|
|
2357
|
+
move: (r, n) => f(t, "lightDriveMoveFile", { index: e, source: r, destination: n })
|
|
2358
|
+
}
|
|
2359
|
+
}), po = (e) => {
|
|
2260
2360
|
const t = Zt.create({
|
|
2261
2361
|
baseURL: e,
|
|
2262
2362
|
withCredentials: !0
|
|
2263
|
-
}), r = (s, o = null, u = []) =>
|
|
2363
|
+
}), r = (s, o = null, u = []) => f(t, s, o, u), n = (s) => w(t, s), i = gr(t);
|
|
2264
2364
|
return {
|
|
2265
2365
|
baseURL: e,
|
|
2266
2366
|
axios: t,
|
|
@@ -2279,15 +2379,18 @@ const ao = (e, t, r) => {
|
|
|
2279
2379
|
collect: (s, o) => {
|
|
2280
2380
|
const u = ao(s, t, o);
|
|
2281
2381
|
return u.data_path = i.get(s).getDataPath(), u;
|
|
2382
|
+
},
|
|
2383
|
+
drive(s) {
|
|
2384
|
+
return uo(s, t);
|
|
2282
2385
|
}
|
|
2283
2386
|
};
|
|
2284
2387
|
};
|
|
2285
2388
|
export {
|
|
2286
|
-
|
|
2287
|
-
|
|
2389
|
+
ho as File,
|
|
2390
|
+
po as createClient,
|
|
2288
2391
|
ao as createCollection,
|
|
2289
|
-
|
|
2290
|
-
|
|
2291
|
-
|
|
2392
|
+
M as file,
|
|
2393
|
+
f as mutation,
|
|
2394
|
+
w as query,
|
|
2292
2395
|
N as toQuery
|
|
2293
2396
|
};
|