frappe-react-sdk 1.0.17 → 1.0.19
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/frappe-react-sdk.es.js +1978 -1879
- package/dist/frappe-react-sdk.umd.js +27 -24
- package/dist/lib/index.d.ts +5 -5
- package/package.json +4 -5
|
@@ -1,169 +1,169 @@
|
|
|
1
|
-
import
|
|
2
|
-
var
|
|
1
|
+
import je, { createContext as Zn, useContext as ne, useEffect as er, useLayoutEffect as Xr, useRef as ge, useMemo as tr, useCallback as H, useDebugValue as Hr, useState as k } from "react";
|
|
2
|
+
var j = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : {}, St = {}, Me = {}, Ye = {}, Ge = { exports: {} }, en = { exports: {} }, nr = function(r, t) {
|
|
3
3
|
return function() {
|
|
4
|
-
for (var a = new Array(arguments.length),
|
|
5
|
-
a[
|
|
6
|
-
return
|
|
4
|
+
for (var a = new Array(arguments.length), n = 0; n < a.length; n++)
|
|
5
|
+
a[n] = arguments[n];
|
|
6
|
+
return r.apply(t, a);
|
|
7
7
|
};
|
|
8
|
-
},
|
|
9
|
-
function
|
|
10
|
-
return Array.isArray(
|
|
8
|
+
}, Jr = nr, be = Object.prototype.toString;
|
|
9
|
+
function tn(e) {
|
|
10
|
+
return Array.isArray(e);
|
|
11
11
|
}
|
|
12
|
-
function
|
|
13
|
-
return typeof
|
|
12
|
+
function Jt(e) {
|
|
13
|
+
return typeof e > "u";
|
|
14
14
|
}
|
|
15
|
-
function
|
|
16
|
-
return
|
|
15
|
+
function Yr(e) {
|
|
16
|
+
return e !== null && !Jt(e) && e.constructor !== null && !Jt(e.constructor) && typeof e.constructor.isBuffer == "function" && e.constructor.isBuffer(e);
|
|
17
17
|
}
|
|
18
|
-
function
|
|
19
|
-
return
|
|
18
|
+
function rr(e) {
|
|
19
|
+
return be.call(e) === "[object ArrayBuffer]";
|
|
20
20
|
}
|
|
21
|
-
function
|
|
22
|
-
return
|
|
21
|
+
function Gr(e) {
|
|
22
|
+
return be.call(e) === "[object FormData]";
|
|
23
23
|
}
|
|
24
|
-
function
|
|
25
|
-
var
|
|
26
|
-
return typeof ArrayBuffer < "u" && ArrayBuffer.isView ?
|
|
24
|
+
function zr(e) {
|
|
25
|
+
var r;
|
|
26
|
+
return typeof ArrayBuffer < "u" && ArrayBuffer.isView ? r = ArrayBuffer.isView(e) : r = e && e.buffer && rr(e.buffer), r;
|
|
27
27
|
}
|
|
28
|
-
function
|
|
29
|
-
return typeof
|
|
28
|
+
function Kr(e) {
|
|
29
|
+
return typeof e == "string";
|
|
30
30
|
}
|
|
31
|
-
function
|
|
32
|
-
return typeof
|
|
31
|
+
function Qr(e) {
|
|
32
|
+
return typeof e == "number";
|
|
33
33
|
}
|
|
34
|
-
function
|
|
35
|
-
return
|
|
34
|
+
function ar(e) {
|
|
35
|
+
return e !== null && typeof e == "object";
|
|
36
36
|
}
|
|
37
|
-
function
|
|
38
|
-
if (
|
|
37
|
+
function st(e) {
|
|
38
|
+
if (be.call(e) !== "[object Object]")
|
|
39
39
|
return !1;
|
|
40
|
-
var
|
|
41
|
-
return
|
|
40
|
+
var r = Object.getPrototypeOf(e);
|
|
41
|
+
return r === null || r === Object.prototype;
|
|
42
42
|
}
|
|
43
|
-
function
|
|
44
|
-
return
|
|
43
|
+
function Zr(e) {
|
|
44
|
+
return be.call(e) === "[object Date]";
|
|
45
45
|
}
|
|
46
|
-
function
|
|
47
|
-
return
|
|
46
|
+
function ea(e) {
|
|
47
|
+
return be.call(e) === "[object File]";
|
|
48
48
|
}
|
|
49
|
-
function
|
|
50
|
-
return
|
|
49
|
+
function ta(e) {
|
|
50
|
+
return be.call(e) === "[object Blob]";
|
|
51
51
|
}
|
|
52
|
-
function
|
|
53
|
-
return
|
|
52
|
+
function or(e) {
|
|
53
|
+
return be.call(e) === "[object Function]";
|
|
54
54
|
}
|
|
55
|
-
function
|
|
56
|
-
return
|
|
55
|
+
function na(e) {
|
|
56
|
+
return ar(e) && or(e.pipe);
|
|
57
57
|
}
|
|
58
|
-
function
|
|
59
|
-
return
|
|
58
|
+
function ra(e) {
|
|
59
|
+
return be.call(e) === "[object URLSearchParams]";
|
|
60
60
|
}
|
|
61
|
-
function
|
|
62
|
-
return
|
|
61
|
+
function aa(e) {
|
|
62
|
+
return e.trim ? e.trim() : e.replace(/^\s+|\s+$/g, "");
|
|
63
63
|
}
|
|
64
|
-
function
|
|
64
|
+
function oa() {
|
|
65
65
|
return typeof navigator < "u" && (navigator.product === "ReactNative" || navigator.product === "NativeScript" || navigator.product === "NS") ? !1 : typeof window < "u" && typeof document < "u";
|
|
66
66
|
}
|
|
67
|
-
function
|
|
68
|
-
if (!(
|
|
69
|
-
if (typeof
|
|
70
|
-
for (var
|
|
71
|
-
|
|
67
|
+
function nn(e, r) {
|
|
68
|
+
if (!(e === null || typeof e > "u"))
|
|
69
|
+
if (typeof e != "object" && (e = [e]), tn(e))
|
|
70
|
+
for (var t = 0, o = e.length; t < o; t++)
|
|
71
|
+
r.call(null, e[t], t, e);
|
|
72
72
|
else
|
|
73
|
-
for (var a in
|
|
74
|
-
Object.prototype.hasOwnProperty.call(
|
|
73
|
+
for (var a in e)
|
|
74
|
+
Object.prototype.hasOwnProperty.call(e, a) && r.call(null, e[a], a, e);
|
|
75
75
|
}
|
|
76
|
-
function
|
|
77
|
-
var
|
|
78
|
-
function
|
|
79
|
-
|
|
76
|
+
function Yt() {
|
|
77
|
+
var e = {};
|
|
78
|
+
function r(a, n) {
|
|
79
|
+
st(e[n]) && st(a) ? e[n] = Yt(e[n], a) : st(a) ? e[n] = Yt({}, a) : tn(a) ? e[n] = a.slice() : e[n] = a;
|
|
80
80
|
}
|
|
81
|
-
for (var
|
|
82
|
-
|
|
83
|
-
return
|
|
81
|
+
for (var t = 0, o = arguments.length; t < o; t++)
|
|
82
|
+
nn(arguments[t], r);
|
|
83
|
+
return e;
|
|
84
84
|
}
|
|
85
|
-
function
|
|
86
|
-
return
|
|
87
|
-
|
|
88
|
-
}),
|
|
85
|
+
function ia(e, r, t) {
|
|
86
|
+
return nn(r, function(a, n) {
|
|
87
|
+
t && typeof a == "function" ? e[n] = Jr(a, t) : e[n] = a;
|
|
88
|
+
}), e;
|
|
89
89
|
}
|
|
90
|
-
function
|
|
91
|
-
return
|
|
90
|
+
function sa(e) {
|
|
91
|
+
return e.charCodeAt(0) === 65279 && (e = e.slice(1)), e;
|
|
92
92
|
}
|
|
93
|
-
var
|
|
94
|
-
isArray:
|
|
95
|
-
isArrayBuffer:
|
|
96
|
-
isBuffer:
|
|
97
|
-
isFormData:
|
|
98
|
-
isArrayBufferView:
|
|
99
|
-
isString:
|
|
100
|
-
isNumber:
|
|
101
|
-
isObject:
|
|
102
|
-
isPlainObject:
|
|
103
|
-
isUndefined:
|
|
104
|
-
isDate:
|
|
105
|
-
isFile:
|
|
106
|
-
isBlob:
|
|
107
|
-
isFunction:
|
|
108
|
-
isStream:
|
|
109
|
-
isURLSearchParams:
|
|
110
|
-
isStandardBrowserEnv:
|
|
111
|
-
forEach:
|
|
112
|
-
merge:
|
|
113
|
-
extend:
|
|
114
|
-
trim:
|
|
115
|
-
stripBOM:
|
|
116
|
-
},
|
|
117
|
-
function
|
|
118
|
-
return encodeURIComponent(
|
|
93
|
+
var ee = {
|
|
94
|
+
isArray: tn,
|
|
95
|
+
isArrayBuffer: rr,
|
|
96
|
+
isBuffer: Yr,
|
|
97
|
+
isFormData: Gr,
|
|
98
|
+
isArrayBufferView: zr,
|
|
99
|
+
isString: Kr,
|
|
100
|
+
isNumber: Qr,
|
|
101
|
+
isObject: ar,
|
|
102
|
+
isPlainObject: st,
|
|
103
|
+
isUndefined: Jt,
|
|
104
|
+
isDate: Zr,
|
|
105
|
+
isFile: ea,
|
|
106
|
+
isBlob: ta,
|
|
107
|
+
isFunction: or,
|
|
108
|
+
isStream: na,
|
|
109
|
+
isURLSearchParams: ra,
|
|
110
|
+
isStandardBrowserEnv: oa,
|
|
111
|
+
forEach: nn,
|
|
112
|
+
merge: Yt,
|
|
113
|
+
extend: ia,
|
|
114
|
+
trim: aa,
|
|
115
|
+
stripBOM: sa
|
|
116
|
+
}, ke = ee;
|
|
117
|
+
function yn(e) {
|
|
118
|
+
return encodeURIComponent(e).replace(/%3A/gi, ":").replace(/%24/g, "$").replace(/%2C/gi, ",").replace(/%20/g, "+").replace(/%5B/gi, "[").replace(/%5D/gi, "]");
|
|
119
119
|
}
|
|
120
|
-
var
|
|
121
|
-
if (!
|
|
122
|
-
return
|
|
120
|
+
var ir = function(r, t, o) {
|
|
121
|
+
if (!t)
|
|
122
|
+
return r;
|
|
123
123
|
var a;
|
|
124
|
-
if (
|
|
125
|
-
a =
|
|
126
|
-
else if (
|
|
127
|
-
a =
|
|
124
|
+
if (o)
|
|
125
|
+
a = o(t);
|
|
126
|
+
else if (ke.isURLSearchParams(t))
|
|
127
|
+
a = t.toString();
|
|
128
128
|
else {
|
|
129
|
-
var
|
|
130
|
-
|
|
131
|
-
d === null || typeof d > "u" || (
|
|
132
|
-
|
|
129
|
+
var n = [];
|
|
130
|
+
ke.forEach(t, function(d, s) {
|
|
131
|
+
d === null || typeof d > "u" || (ke.isArray(d) ? s = s + "[]" : d = [d], ke.forEach(d, function(l) {
|
|
132
|
+
ke.isDate(l) ? l = l.toISOString() : ke.isObject(l) && (l = JSON.stringify(l)), n.push(yn(s) + "=" + yn(l));
|
|
133
133
|
}));
|
|
134
|
-
}), a =
|
|
134
|
+
}), a = n.join("&");
|
|
135
135
|
}
|
|
136
136
|
if (a) {
|
|
137
|
-
var
|
|
138
|
-
|
|
137
|
+
var i = r.indexOf("#");
|
|
138
|
+
i !== -1 && (r = r.slice(0, i)), r += (r.indexOf("?") === -1 ? "?" : "&") + a;
|
|
139
139
|
}
|
|
140
|
-
return
|
|
141
|
-
},
|
|
142
|
-
function
|
|
140
|
+
return r;
|
|
141
|
+
}, ua = ee;
|
|
142
|
+
function lt() {
|
|
143
143
|
this.handlers = [];
|
|
144
144
|
}
|
|
145
|
-
|
|
145
|
+
lt.prototype.use = function(r, t, o) {
|
|
146
146
|
return this.handlers.push({
|
|
147
|
-
fulfilled:
|
|
148
|
-
rejected:
|
|
149
|
-
synchronous:
|
|
150
|
-
runWhen:
|
|
147
|
+
fulfilled: r,
|
|
148
|
+
rejected: t,
|
|
149
|
+
synchronous: o ? o.synchronous : !1,
|
|
150
|
+
runWhen: o ? o.runWhen : null
|
|
151
151
|
}), this.handlers.length - 1;
|
|
152
152
|
};
|
|
153
|
-
|
|
154
|
-
this.handlers[
|
|
153
|
+
lt.prototype.eject = function(r) {
|
|
154
|
+
this.handlers[r] && (this.handlers[r] = null);
|
|
155
155
|
};
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
156
|
+
lt.prototype.forEach = function(r) {
|
|
157
|
+
ua.forEach(this.handlers, function(o) {
|
|
158
|
+
o !== null && r(o);
|
|
159
159
|
});
|
|
160
160
|
};
|
|
161
|
-
var
|
|
162
|
-
|
|
163
|
-
|
|
161
|
+
var ca = lt, la = ee, fa = function(r, t) {
|
|
162
|
+
la.forEach(r, function(a, n) {
|
|
163
|
+
n !== t && n.toUpperCase() === t.toUpperCase() && (r[t] = a, delete r[n]);
|
|
164
164
|
});
|
|
165
|
-
},
|
|
166
|
-
return
|
|
165
|
+
}, sr = function(r, t, o, a, n) {
|
|
166
|
+
return r.config = t, o && (r.code = o), r.request = a, r.response = n, r.isAxiosError = !0, r.toJSON = function() {
|
|
167
167
|
return {
|
|
168
168
|
message: this.message,
|
|
169
169
|
name: this.name,
|
|
@@ -177,57 +177,57 @@ var aa = pt, ia = H, oa = function(n, e) {
|
|
|
177
177
|
code: this.code,
|
|
178
178
|
status: this.response && this.response.status ? this.response.status : null
|
|
179
179
|
};
|
|
180
|
-
},
|
|
181
|
-
},
|
|
180
|
+
}, r;
|
|
181
|
+
}, ur = {
|
|
182
182
|
silentJSONParsing: !0,
|
|
183
183
|
forcedJSONParsing: !0,
|
|
184
184
|
clarifyTimeoutError: !1
|
|
185
|
-
},
|
|
186
|
-
function
|
|
187
|
-
if (
|
|
188
|
-
return
|
|
189
|
-
|
|
190
|
-
var
|
|
191
|
-
return
|
|
192
|
-
var c = new Error(
|
|
193
|
-
return
|
|
194
|
-
},
|
|
185
|
+
}, Rt, bn;
|
|
186
|
+
function cr() {
|
|
187
|
+
if (bn)
|
|
188
|
+
return Rt;
|
|
189
|
+
bn = 1;
|
|
190
|
+
var e = sr;
|
|
191
|
+
return Rt = function(t, o, a, n, i) {
|
|
192
|
+
var c = new Error(t);
|
|
193
|
+
return e(c, o, a, n, i);
|
|
194
|
+
}, Rt;
|
|
195
195
|
}
|
|
196
|
-
var
|
|
197
|
-
function
|
|
198
|
-
if (
|
|
199
|
-
return
|
|
200
|
-
|
|
201
|
-
var
|
|
202
|
-
return
|
|
203
|
-
var
|
|
204
|
-
!a.status || !
|
|
196
|
+
var gt, En;
|
|
197
|
+
function da() {
|
|
198
|
+
if (En)
|
|
199
|
+
return gt;
|
|
200
|
+
En = 1;
|
|
201
|
+
var e = cr();
|
|
202
|
+
return gt = function(t, o, a) {
|
|
203
|
+
var n = a.config.validateStatus;
|
|
204
|
+
!a.status || !n || n(a.status) ? t(a) : o(e(
|
|
205
205
|
"Request failed with status code " + a.status,
|
|
206
206
|
a.config,
|
|
207
207
|
null,
|
|
208
208
|
a.request,
|
|
209
209
|
a
|
|
210
210
|
));
|
|
211
|
-
},
|
|
211
|
+
}, gt;
|
|
212
212
|
}
|
|
213
|
-
var Tt,
|
|
214
|
-
function
|
|
215
|
-
if (
|
|
213
|
+
var Tt, Sn;
|
|
214
|
+
function pa() {
|
|
215
|
+
if (Sn)
|
|
216
216
|
return Tt;
|
|
217
|
-
|
|
218
|
-
var
|
|
219
|
-
return Tt =
|
|
217
|
+
Sn = 1;
|
|
218
|
+
var e = ee;
|
|
219
|
+
return Tt = e.isStandardBrowserEnv() ? function() {
|
|
220
220
|
return {
|
|
221
|
-
write: function(
|
|
222
|
-
var
|
|
223
|
-
|
|
221
|
+
write: function(o, a, n, i, c, d) {
|
|
222
|
+
var s = [];
|
|
223
|
+
s.push(o + "=" + encodeURIComponent(a)), e.isNumber(n) && s.push("expires=" + new Date(n).toGMTString()), e.isString(i) && s.push("path=" + i), e.isString(c) && s.push("domain=" + c), d === !0 && s.push("secure"), document.cookie = s.join("; ");
|
|
224
224
|
},
|
|
225
|
-
read: function(
|
|
226
|
-
var a = document.cookie.match(new RegExp("(^|;\\s*)(" +
|
|
225
|
+
read: function(o) {
|
|
226
|
+
var a = document.cookie.match(new RegExp("(^|;\\s*)(" + o + ")=([^;]*)"));
|
|
227
227
|
return a ? decodeURIComponent(a[3]) : null;
|
|
228
228
|
},
|
|
229
|
-
remove: function(
|
|
230
|
-
this.write(
|
|
229
|
+
remove: function(o) {
|
|
230
|
+
this.write(o, "", Date.now() - 864e5);
|
|
231
231
|
}
|
|
232
232
|
};
|
|
233
233
|
}() : function() {
|
|
@@ -242,34 +242,34 @@ function ua() {
|
|
|
242
242
|
};
|
|
243
243
|
}(), Tt;
|
|
244
244
|
}
|
|
245
|
-
var
|
|
246
|
-
function
|
|
247
|
-
return
|
|
248
|
-
return /^([a-z][a-z\d+\-.]*:)?\/\//i.test(
|
|
249
|
-
}),
|
|
245
|
+
var Ct, Rn;
|
|
246
|
+
function ha() {
|
|
247
|
+
return Rn || (Rn = 1, Ct = function(r) {
|
|
248
|
+
return /^([a-z][a-z\d+\-.]*:)?\/\//i.test(r);
|
|
249
|
+
}), Ct;
|
|
250
250
|
}
|
|
251
|
-
var Ot,
|
|
252
|
-
function
|
|
253
|
-
return
|
|
254
|
-
return
|
|
251
|
+
var Ot, gn;
|
|
252
|
+
function va() {
|
|
253
|
+
return gn || (gn = 1, Ot = function(r, t) {
|
|
254
|
+
return t ? r.replace(/\/+$/, "") + "/" + t.replace(/^\/+/, "") : r;
|
|
255
255
|
}), Ot;
|
|
256
256
|
}
|
|
257
|
-
var
|
|
258
|
-
function
|
|
259
|
-
if (
|
|
260
|
-
return
|
|
261
|
-
|
|
262
|
-
var
|
|
263
|
-
return
|
|
264
|
-
return
|
|
265
|
-
},
|
|
257
|
+
var xt, Tn;
|
|
258
|
+
function ma() {
|
|
259
|
+
if (Tn)
|
|
260
|
+
return xt;
|
|
261
|
+
Tn = 1;
|
|
262
|
+
var e = ha(), r = va();
|
|
263
|
+
return xt = function(o, a) {
|
|
264
|
+
return o && !e(a) ? r(o, a) : a;
|
|
265
|
+
}, xt;
|
|
266
266
|
}
|
|
267
|
-
var
|
|
268
|
-
function
|
|
269
|
-
if (
|
|
270
|
-
return
|
|
271
|
-
|
|
272
|
-
var
|
|
267
|
+
var Ft, Cn;
|
|
268
|
+
function wa() {
|
|
269
|
+
if (Cn)
|
|
270
|
+
return Ft;
|
|
271
|
+
Cn = 1;
|
|
272
|
+
var e = ee, r = [
|
|
273
273
|
"age",
|
|
274
274
|
"authorization",
|
|
275
275
|
"content-length",
|
|
@@ -288,41 +288,41 @@ function da() {
|
|
|
288
288
|
"retry-after",
|
|
289
289
|
"user-agent"
|
|
290
290
|
];
|
|
291
|
-
return
|
|
292
|
-
var a = {},
|
|
293
|
-
return
|
|
294
|
-
`), function(
|
|
295
|
-
if (c =
|
|
296
|
-
if (a[
|
|
291
|
+
return Ft = function(o) {
|
|
292
|
+
var a = {}, n, i, c;
|
|
293
|
+
return o && e.forEach(o.split(`
|
|
294
|
+
`), function(s) {
|
|
295
|
+
if (c = s.indexOf(":"), n = e.trim(s.substr(0, c)).toLowerCase(), i = e.trim(s.substr(c + 1)), n) {
|
|
296
|
+
if (a[n] && r.indexOf(n) >= 0)
|
|
297
297
|
return;
|
|
298
|
-
|
|
298
|
+
n === "set-cookie" ? a[n] = (a[n] ? a[n] : []).concat([i]) : a[n] = a[n] ? a[n] + ", " + i : i;
|
|
299
299
|
}
|
|
300
300
|
}), a;
|
|
301
|
-
},
|
|
301
|
+
}, Ft;
|
|
302
302
|
}
|
|
303
|
-
var Dt,
|
|
304
|
-
function
|
|
305
|
-
if (
|
|
303
|
+
var Dt, On;
|
|
304
|
+
function _a() {
|
|
305
|
+
if (On)
|
|
306
306
|
return Dt;
|
|
307
|
-
|
|
308
|
-
var
|
|
309
|
-
return Dt =
|
|
310
|
-
var
|
|
311
|
-
function
|
|
312
|
-
var c =
|
|
313
|
-
return
|
|
314
|
-
href:
|
|
315
|
-
protocol:
|
|
316
|
-
host:
|
|
317
|
-
search:
|
|
318
|
-
hash:
|
|
319
|
-
hostname:
|
|
320
|
-
port:
|
|
321
|
-
pathname:
|
|
307
|
+
On = 1;
|
|
308
|
+
var e = ee;
|
|
309
|
+
return Dt = e.isStandardBrowserEnv() ? function() {
|
|
310
|
+
var t = /(msie|trident)/i.test(navigator.userAgent), o = document.createElement("a"), a;
|
|
311
|
+
function n(i) {
|
|
312
|
+
var c = i;
|
|
313
|
+
return t && (o.setAttribute("href", c), c = o.href), o.setAttribute("href", c), {
|
|
314
|
+
href: o.href,
|
|
315
|
+
protocol: o.protocol ? o.protocol.replace(/:$/, "") : "",
|
|
316
|
+
host: o.host,
|
|
317
|
+
search: o.search ? o.search.replace(/^\?/, "") : "",
|
|
318
|
+
hash: o.hash ? o.hash.replace(/^#/, "") : "",
|
|
319
|
+
hostname: o.hostname,
|
|
320
|
+
port: o.port,
|
|
321
|
+
pathname: o.pathname.charAt(0) === "/" ? o.pathname : "/" + o.pathname
|
|
322
322
|
};
|
|
323
323
|
}
|
|
324
|
-
return a =
|
|
325
|
-
var d =
|
|
324
|
+
return a = n(window.location.href), function(c) {
|
|
325
|
+
var d = e.isString(c) ? n(c) : c;
|
|
326
326
|
return d.protocol === a.protocol && d.host === a.host;
|
|
327
327
|
};
|
|
328
328
|
}() : function() {
|
|
@@ -331,125 +331,125 @@ function pa() {
|
|
|
331
331
|
};
|
|
332
332
|
}(), Dt;
|
|
333
333
|
}
|
|
334
|
-
var
|
|
335
|
-
function
|
|
336
|
-
if (
|
|
337
|
-
return
|
|
338
|
-
|
|
339
|
-
function
|
|
340
|
-
this.message =
|
|
334
|
+
var kt, xn;
|
|
335
|
+
function ft() {
|
|
336
|
+
if (xn)
|
|
337
|
+
return kt;
|
|
338
|
+
xn = 1;
|
|
339
|
+
function e(r) {
|
|
340
|
+
this.message = r;
|
|
341
341
|
}
|
|
342
|
-
return
|
|
342
|
+
return e.prototype.toString = function() {
|
|
343
343
|
return "Cancel" + (this.message ? ": " + this.message : "");
|
|
344
|
-
},
|
|
344
|
+
}, e.prototype.__CANCEL__ = !0, kt = e, kt;
|
|
345
345
|
}
|
|
346
|
-
var
|
|
347
|
-
function
|
|
348
|
-
if (
|
|
349
|
-
return
|
|
350
|
-
|
|
351
|
-
var
|
|
352
|
-
return
|
|
353
|
-
return new Promise(function(
|
|
354
|
-
var
|
|
355
|
-
function
|
|
356
|
-
|
|
346
|
+
var At, Fn;
|
|
347
|
+
function Dn() {
|
|
348
|
+
if (Fn)
|
|
349
|
+
return At;
|
|
350
|
+
Fn = 1;
|
|
351
|
+
var e = ee, r = da(), t = pa(), o = ir, a = ma(), n = wa(), i = _a(), c = cr(), d = ur, s = ft();
|
|
352
|
+
return At = function(l) {
|
|
353
|
+
return new Promise(function(h, b) {
|
|
354
|
+
var w = l.data, T = l.headers, x = l.responseType, S;
|
|
355
|
+
function O() {
|
|
356
|
+
l.cancelToken && l.cancelToken.unsubscribe(S), l.signal && l.signal.removeEventListener("abort", S);
|
|
357
357
|
}
|
|
358
|
-
|
|
359
|
-
var
|
|
360
|
-
if (
|
|
361
|
-
var
|
|
362
|
-
|
|
358
|
+
e.isFormData(w) && delete T["Content-Type"];
|
|
359
|
+
var m = new XMLHttpRequest();
|
|
360
|
+
if (l.auth) {
|
|
361
|
+
var I = l.auth.username || "", y = l.auth.password ? unescape(encodeURIComponent(l.auth.password)) : "";
|
|
362
|
+
T.Authorization = "Basic " + btoa(I + ":" + y);
|
|
363
363
|
}
|
|
364
|
-
var
|
|
365
|
-
|
|
366
|
-
function
|
|
367
|
-
if (!!
|
|
368
|
-
var
|
|
369
|
-
data:
|
|
370
|
-
status:
|
|
371
|
-
statusText:
|
|
372
|
-
headers:
|
|
373
|
-
config:
|
|
374
|
-
request:
|
|
364
|
+
var A = a(l.baseURL, l.url);
|
|
365
|
+
m.open(l.method.toUpperCase(), o(A, l.params, l.paramsSerializer), !0), m.timeout = l.timeout;
|
|
366
|
+
function M() {
|
|
367
|
+
if (!!m) {
|
|
368
|
+
var N = "getAllResponseHeaders" in m ? n(m.getAllResponseHeaders()) : null, J = !x || x === "text" || x === "json" ? m.responseText : m.response, K = {
|
|
369
|
+
data: J,
|
|
370
|
+
status: m.status,
|
|
371
|
+
statusText: m.statusText,
|
|
372
|
+
headers: N,
|
|
373
|
+
config: l,
|
|
374
|
+
request: m
|
|
375
375
|
};
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
}, function(
|
|
379
|
-
|
|
380
|
-
},
|
|
376
|
+
r(function(G) {
|
|
377
|
+
h(G), O();
|
|
378
|
+
}, function(G) {
|
|
379
|
+
b(G), O();
|
|
380
|
+
}, K), m = null;
|
|
381
381
|
}
|
|
382
382
|
}
|
|
383
|
-
if ("onloadend" in
|
|
384
|
-
!
|
|
385
|
-
},
|
|
386
|
-
!
|
|
387
|
-
},
|
|
388
|
-
|
|
389
|
-
},
|
|
390
|
-
var
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
|
|
395
|
-
|
|
396
|
-
)),
|
|
397
|
-
},
|
|
398
|
-
var
|
|
399
|
-
|
|
383
|
+
if ("onloadend" in m ? m.onloadend = M : m.onreadystatechange = function() {
|
|
384
|
+
!m || m.readyState !== 4 || m.status === 0 && !(m.responseURL && m.responseURL.indexOf("file:") === 0) || setTimeout(M);
|
|
385
|
+
}, m.onabort = function() {
|
|
386
|
+
!m || (b(c("Request aborted", l, "ECONNABORTED", m)), m = null);
|
|
387
|
+
}, m.onerror = function() {
|
|
388
|
+
b(c("Network Error", l, null, m)), m = null;
|
|
389
|
+
}, m.ontimeout = function() {
|
|
390
|
+
var J = l.timeout ? "timeout of " + l.timeout + "ms exceeded" : "timeout exceeded", K = l.transitional || d;
|
|
391
|
+
l.timeoutErrorMessage && (J = l.timeoutErrorMessage), b(c(
|
|
392
|
+
J,
|
|
393
|
+
l,
|
|
394
|
+
K.clarifyTimeoutError ? "ETIMEDOUT" : "ECONNABORTED",
|
|
395
|
+
m
|
|
396
|
+
)), m = null;
|
|
397
|
+
}, e.isStandardBrowserEnv()) {
|
|
398
|
+
var P = (l.withCredentials || i(A)) && l.xsrfCookieName ? t.read(l.xsrfCookieName) : void 0;
|
|
399
|
+
P && (T[l.xsrfHeaderName] = P);
|
|
400
400
|
}
|
|
401
|
-
"setRequestHeader" in
|
|
402
|
-
typeof
|
|
403
|
-
}),
|
|
404
|
-
!
|
|
405
|
-
},
|
|
401
|
+
"setRequestHeader" in m && e.forEach(T, function(J, K) {
|
|
402
|
+
typeof w > "u" && K.toLowerCase() === "content-type" ? delete T[K] : m.setRequestHeader(K, J);
|
|
403
|
+
}), e.isUndefined(l.withCredentials) || (m.withCredentials = !!l.withCredentials), x && x !== "json" && (m.responseType = l.responseType), typeof l.onDownloadProgress == "function" && m.addEventListener("progress", l.onDownloadProgress), typeof l.onUploadProgress == "function" && m.upload && m.upload.addEventListener("progress", l.onUploadProgress), (l.cancelToken || l.signal) && (S = function(N) {
|
|
404
|
+
!m || (b(!N || N && N.type ? new s("canceled") : N), m.abort(), m = null);
|
|
405
|
+
}, l.cancelToken && l.cancelToken.subscribe(S), l.signal && (l.signal.aborted ? S() : l.signal.addEventListener("abort", S))), w || (w = null), m.send(w);
|
|
406
406
|
});
|
|
407
|
-
},
|
|
407
|
+
}, At;
|
|
408
408
|
}
|
|
409
|
-
var
|
|
409
|
+
var Y = ee, kn = fa, ya = sr, ba = ur, Ea = {
|
|
410
410
|
"Content-Type": "application/x-www-form-urlencoded"
|
|
411
411
|
};
|
|
412
|
-
function
|
|
413
|
-
!
|
|
412
|
+
function An(e, r) {
|
|
413
|
+
!Y.isUndefined(e) && Y.isUndefined(e["Content-Type"]) && (e["Content-Type"] = r);
|
|
414
414
|
}
|
|
415
|
-
function
|
|
416
|
-
var
|
|
417
|
-
return (typeof XMLHttpRequest < "u" || typeof process < "u" && Object.prototype.toString.call(process) === "[object process]") && (
|
|
415
|
+
function Sa() {
|
|
416
|
+
var e;
|
|
417
|
+
return (typeof XMLHttpRequest < "u" || typeof process < "u" && Object.prototype.toString.call(process) === "[object process]") && (e = Dn()), e;
|
|
418
418
|
}
|
|
419
|
-
function
|
|
420
|
-
if (
|
|
419
|
+
function Ra(e, r, t) {
|
|
420
|
+
if (Y.isString(e))
|
|
421
421
|
try {
|
|
422
|
-
return (
|
|
423
|
-
} catch (
|
|
424
|
-
if (
|
|
425
|
-
throw
|
|
422
|
+
return (r || JSON.parse)(e), Y.trim(e);
|
|
423
|
+
} catch (o) {
|
|
424
|
+
if (o.name !== "SyntaxError")
|
|
425
|
+
throw o;
|
|
426
426
|
}
|
|
427
|
-
return (
|
|
427
|
+
return (t || JSON.stringify)(e);
|
|
428
428
|
}
|
|
429
|
-
var
|
|
430
|
-
transitional:
|
|
431
|
-
adapter:
|
|
432
|
-
transformRequest: [function(
|
|
433
|
-
return
|
|
429
|
+
var dt = {
|
|
430
|
+
transitional: ba,
|
|
431
|
+
adapter: Sa(),
|
|
432
|
+
transformRequest: [function(r, t) {
|
|
433
|
+
return kn(t, "Accept"), kn(t, "Content-Type"), Y.isFormData(r) || Y.isArrayBuffer(r) || Y.isBuffer(r) || Y.isStream(r) || Y.isFile(r) || Y.isBlob(r) ? r : Y.isArrayBufferView(r) ? r.buffer : Y.isURLSearchParams(r) ? (An(t, "application/x-www-form-urlencoded;charset=utf-8"), r.toString()) : Y.isObject(r) || t && t["Content-Type"] === "application/json" ? (An(t, "application/json"), Ra(r)) : r;
|
|
434
434
|
}],
|
|
435
|
-
transformResponse: [function(
|
|
436
|
-
var
|
|
437
|
-
if (
|
|
435
|
+
transformResponse: [function(r) {
|
|
436
|
+
var t = this.transitional || dt.transitional, o = t && t.silentJSONParsing, a = t && t.forcedJSONParsing, n = !o && this.responseType === "json";
|
|
437
|
+
if (n || a && Y.isString(r) && r.length)
|
|
438
438
|
try {
|
|
439
|
-
return JSON.parse(
|
|
440
|
-
} catch (
|
|
441
|
-
if (
|
|
442
|
-
throw
|
|
439
|
+
return JSON.parse(r);
|
|
440
|
+
} catch (i) {
|
|
441
|
+
if (n)
|
|
442
|
+
throw i.name === "SyntaxError" ? ya(i, this, "E_JSON_PARSE") : i;
|
|
443
443
|
}
|
|
444
|
-
return
|
|
444
|
+
return r;
|
|
445
445
|
}],
|
|
446
446
|
timeout: 0,
|
|
447
447
|
xsrfCookieName: "XSRF-TOKEN",
|
|
448
448
|
xsrfHeaderName: "X-XSRF-TOKEN",
|
|
449
449
|
maxContentLength: -1,
|
|
450
450
|
maxBodyLength: -1,
|
|
451
|
-
validateStatus: function(
|
|
452
|
-
return
|
|
451
|
+
validateStatus: function(r) {
|
|
452
|
+
return r >= 200 && r < 300;
|
|
453
453
|
},
|
|
454
454
|
headers: {
|
|
455
455
|
common: {
|
|
@@ -457,94 +457,94 @@ var vt = {
|
|
|
457
457
|
}
|
|
458
458
|
}
|
|
459
459
|
};
|
|
460
|
-
|
|
461
|
-
|
|
460
|
+
Y.forEach(["delete", "get", "head"], function(r) {
|
|
461
|
+
dt.headers[r] = {};
|
|
462
462
|
});
|
|
463
|
-
|
|
464
|
-
|
|
463
|
+
Y.forEach(["post", "put", "patch"], function(r) {
|
|
464
|
+
dt.headers[r] = Y.merge(Ea);
|
|
465
465
|
});
|
|
466
|
-
var
|
|
467
|
-
var a = this ||
|
|
468
|
-
return
|
|
469
|
-
|
|
470
|
-
}),
|
|
471
|
-
},
|
|
472
|
-
function
|
|
473
|
-
return
|
|
474
|
-
return !!(
|
|
475
|
-
}),
|
|
466
|
+
var rn = dt, ga = ee, Ta = rn, Ca = function(r, t, o) {
|
|
467
|
+
var a = this || Ta;
|
|
468
|
+
return ga.forEach(o, function(i) {
|
|
469
|
+
r = i.call(a, r, t);
|
|
470
|
+
}), r;
|
|
471
|
+
}, Lt, Ln;
|
|
472
|
+
function lr() {
|
|
473
|
+
return Ln || (Ln = 1, Lt = function(r) {
|
|
474
|
+
return !!(r && r.__CANCEL__);
|
|
475
|
+
}), Lt;
|
|
476
476
|
}
|
|
477
|
-
var
|
|
478
|
-
function
|
|
479
|
-
if (
|
|
480
|
-
throw new
|
|
477
|
+
var jn = ee, jt = Ca, Oa = lr(), xa = rn, Fa = ft();
|
|
478
|
+
function Pt(e) {
|
|
479
|
+
if (e.cancelToken && e.cancelToken.throwIfRequested(), e.signal && e.signal.aborted)
|
|
480
|
+
throw new Fa("canceled");
|
|
481
481
|
}
|
|
482
|
-
var
|
|
483
|
-
|
|
484
|
-
|
|
485
|
-
|
|
486
|
-
|
|
487
|
-
|
|
488
|
-
),
|
|
489
|
-
|
|
490
|
-
|
|
491
|
-
|
|
492
|
-
),
|
|
482
|
+
var Da = function(r) {
|
|
483
|
+
Pt(r), r.headers = r.headers || {}, r.data = jt.call(
|
|
484
|
+
r,
|
|
485
|
+
r.data,
|
|
486
|
+
r.headers,
|
|
487
|
+
r.transformRequest
|
|
488
|
+
), r.headers = jn.merge(
|
|
489
|
+
r.headers.common || {},
|
|
490
|
+
r.headers[r.method] || {},
|
|
491
|
+
r.headers
|
|
492
|
+
), jn.forEach(
|
|
493
493
|
["delete", "get", "head", "post", "put", "patch", "common"],
|
|
494
494
|
function(a) {
|
|
495
|
-
delete
|
|
495
|
+
delete r.headers[a];
|
|
496
496
|
}
|
|
497
497
|
);
|
|
498
|
-
var
|
|
499
|
-
return
|
|
500
|
-
return
|
|
501
|
-
|
|
498
|
+
var t = r.adapter || xa.adapter;
|
|
499
|
+
return t(r).then(function(a) {
|
|
500
|
+
return Pt(r), a.data = jt.call(
|
|
501
|
+
r,
|
|
502
502
|
a.data,
|
|
503
503
|
a.headers,
|
|
504
|
-
|
|
504
|
+
r.transformResponse
|
|
505
505
|
), a;
|
|
506
506
|
}, function(a) {
|
|
507
|
-
return
|
|
508
|
-
|
|
507
|
+
return Oa(a) || (Pt(r), a && a.response && (a.response.data = jt.call(
|
|
508
|
+
r,
|
|
509
509
|
a.response.data,
|
|
510
510
|
a.response.headers,
|
|
511
|
-
|
|
511
|
+
r.transformResponse
|
|
512
512
|
))), Promise.reject(a);
|
|
513
513
|
});
|
|
514
|
-
},
|
|
515
|
-
|
|
516
|
-
var
|
|
517
|
-
function a(
|
|
518
|
-
return
|
|
514
|
+
}, te = ee, fr = function(r, t) {
|
|
515
|
+
t = t || {};
|
|
516
|
+
var o = {};
|
|
517
|
+
function a(f, l) {
|
|
518
|
+
return te.isPlainObject(f) && te.isPlainObject(l) ? te.merge(f, l) : te.isPlainObject(l) ? te.merge({}, l) : te.isArray(l) ? l.slice() : l;
|
|
519
519
|
}
|
|
520
|
-
function
|
|
521
|
-
if (
|
|
522
|
-
if (!
|
|
523
|
-
return a(void 0,
|
|
520
|
+
function n(f) {
|
|
521
|
+
if (te.isUndefined(t[f])) {
|
|
522
|
+
if (!te.isUndefined(r[f]))
|
|
523
|
+
return a(void 0, r[f]);
|
|
524
524
|
} else
|
|
525
|
-
return a(
|
|
525
|
+
return a(r[f], t[f]);
|
|
526
526
|
}
|
|
527
|
-
function
|
|
528
|
-
if (!
|
|
529
|
-
return a(void 0,
|
|
527
|
+
function i(f) {
|
|
528
|
+
if (!te.isUndefined(t[f]))
|
|
529
|
+
return a(void 0, t[f]);
|
|
530
530
|
}
|
|
531
|
-
function c(
|
|
532
|
-
if (
|
|
533
|
-
if (!
|
|
534
|
-
return a(void 0,
|
|
531
|
+
function c(f) {
|
|
532
|
+
if (te.isUndefined(t[f])) {
|
|
533
|
+
if (!te.isUndefined(r[f]))
|
|
534
|
+
return a(void 0, r[f]);
|
|
535
535
|
} else
|
|
536
|
-
return a(void 0,
|
|
536
|
+
return a(void 0, t[f]);
|
|
537
537
|
}
|
|
538
|
-
function d(
|
|
539
|
-
if (
|
|
540
|
-
return a(
|
|
541
|
-
if (
|
|
542
|
-
return a(void 0,
|
|
538
|
+
function d(f) {
|
|
539
|
+
if (f in t)
|
|
540
|
+
return a(r[f], t[f]);
|
|
541
|
+
if (f in r)
|
|
542
|
+
return a(void 0, r[f]);
|
|
543
543
|
}
|
|
544
|
-
var
|
|
545
|
-
url:
|
|
546
|
-
method:
|
|
547
|
-
data:
|
|
544
|
+
var s = {
|
|
545
|
+
url: i,
|
|
546
|
+
method: i,
|
|
547
|
+
data: i,
|
|
548
548
|
baseURL: c,
|
|
549
549
|
transformRequest: c,
|
|
550
550
|
transformResponse: c,
|
|
@@ -569,1520 +569,1618 @@ var Ca = function(n) {
|
|
|
569
569
|
responseEncoding: c,
|
|
570
570
|
validateStatus: d
|
|
571
571
|
};
|
|
572
|
-
return
|
|
573
|
-
var
|
|
574
|
-
|
|
575
|
-
}),
|
|
576
|
-
},
|
|
577
|
-
function
|
|
578
|
-
return
|
|
572
|
+
return te.forEach(Object.keys(r).concat(Object.keys(t)), function(l) {
|
|
573
|
+
var _ = s[l] || n, h = _(l);
|
|
574
|
+
te.isUndefined(h) && _ !== d || (o[l] = h);
|
|
575
|
+
}), o;
|
|
576
|
+
}, Ut, Pn;
|
|
577
|
+
function dr() {
|
|
578
|
+
return Pn || (Pn = 1, Ut = {
|
|
579
579
|
version: "0.26.1"
|
|
580
|
-
}),
|
|
580
|
+
}), Ut;
|
|
581
581
|
}
|
|
582
|
-
var
|
|
583
|
-
["object", "boolean", "number", "function", "string", "symbol"].forEach(function(
|
|
584
|
-
|
|
585
|
-
return typeof
|
|
582
|
+
var ka = dr().version, an = {};
|
|
583
|
+
["object", "boolean", "number", "function", "string", "symbol"].forEach(function(e, r) {
|
|
584
|
+
an[e] = function(o) {
|
|
585
|
+
return typeof o === e || "a" + (r < 1 ? "n " : " ") + e;
|
|
586
586
|
};
|
|
587
587
|
});
|
|
588
|
-
var
|
|
589
|
-
|
|
590
|
-
function a(
|
|
591
|
-
return "[Axios v" +
|
|
588
|
+
var Un = {};
|
|
589
|
+
an.transitional = function(r, t, o) {
|
|
590
|
+
function a(n, i) {
|
|
591
|
+
return "[Axios v" + ka + "] Transitional option '" + n + "'" + i + (o ? ". " + o : "");
|
|
592
592
|
}
|
|
593
|
-
return function(
|
|
594
|
-
if (
|
|
595
|
-
throw new Error(a(
|
|
596
|
-
return
|
|
593
|
+
return function(n, i, c) {
|
|
594
|
+
if (r === !1)
|
|
595
|
+
throw new Error(a(i, " has been removed" + (t ? " in " + t : "")));
|
|
596
|
+
return t && !Un[i] && (Un[i] = !0, console.warn(
|
|
597
597
|
a(
|
|
598
|
-
|
|
599
|
-
" has been deprecated since v" +
|
|
598
|
+
i,
|
|
599
|
+
" has been deprecated since v" + t + " and will be removed in the near future"
|
|
600
600
|
)
|
|
601
|
-
)),
|
|
601
|
+
)), r ? r(n, i, c) : !0;
|
|
602
602
|
};
|
|
603
603
|
};
|
|
604
|
-
function
|
|
605
|
-
if (typeof
|
|
604
|
+
function Aa(e, r, t) {
|
|
605
|
+
if (typeof e != "object")
|
|
606
606
|
throw new TypeError("options must be an object");
|
|
607
|
-
for (var
|
|
608
|
-
var
|
|
609
|
-
if (
|
|
610
|
-
var c =
|
|
607
|
+
for (var o = Object.keys(e), a = o.length; a-- > 0; ) {
|
|
608
|
+
var n = o[a], i = r[n];
|
|
609
|
+
if (i) {
|
|
610
|
+
var c = e[n], d = c === void 0 || i(c, n, e);
|
|
611
611
|
if (d !== !0)
|
|
612
|
-
throw new TypeError("option " +
|
|
612
|
+
throw new TypeError("option " + n + " must be " + d);
|
|
613
613
|
continue;
|
|
614
614
|
}
|
|
615
|
-
if (
|
|
616
|
-
throw Error("Unknown option " +
|
|
615
|
+
if (t !== !0)
|
|
616
|
+
throw Error("Unknown option " + n);
|
|
617
617
|
}
|
|
618
618
|
}
|
|
619
|
-
var
|
|
620
|
-
assertOptions:
|
|
621
|
-
validators:
|
|
622
|
-
},
|
|
623
|
-
function ze(
|
|
624
|
-
this.defaults =
|
|
625
|
-
request: new
|
|
626
|
-
response: new
|
|
619
|
+
var La = {
|
|
620
|
+
assertOptions: Aa,
|
|
621
|
+
validators: an
|
|
622
|
+
}, pr = ee, ja = ir, Nn = ca, In = Da, pt = fr, hr = La, Ae = hr.validators;
|
|
623
|
+
function ze(e) {
|
|
624
|
+
this.defaults = e, this.interceptors = {
|
|
625
|
+
request: new Nn(),
|
|
626
|
+
response: new Nn()
|
|
627
627
|
};
|
|
628
628
|
}
|
|
629
|
-
ze.prototype.request = function(
|
|
630
|
-
typeof
|
|
631
|
-
var
|
|
632
|
-
|
|
633
|
-
silentJSONParsing:
|
|
634
|
-
forcedJSONParsing:
|
|
635
|
-
clarifyTimeoutError:
|
|
629
|
+
ze.prototype.request = function(r, t) {
|
|
630
|
+
typeof r == "string" ? (t = t || {}, t.url = r) : t = r || {}, t = pt(this.defaults, t), t.method ? t.method = t.method.toLowerCase() : this.defaults.method ? t.method = this.defaults.method.toLowerCase() : t.method = "get";
|
|
631
|
+
var o = t.transitional;
|
|
632
|
+
o !== void 0 && hr.assertOptions(o, {
|
|
633
|
+
silentJSONParsing: Ae.transitional(Ae.boolean),
|
|
634
|
+
forcedJSONParsing: Ae.transitional(Ae.boolean),
|
|
635
|
+
clarifyTimeoutError: Ae.transitional(Ae.boolean)
|
|
636
636
|
}, !1);
|
|
637
|
-
var a = [],
|
|
638
|
-
this.interceptors.request.forEach(function(
|
|
639
|
-
typeof
|
|
637
|
+
var a = [], n = !0;
|
|
638
|
+
this.interceptors.request.forEach(function(h) {
|
|
639
|
+
typeof h.runWhen == "function" && h.runWhen(t) === !1 || (n = n && h.synchronous, a.unshift(h.fulfilled, h.rejected));
|
|
640
640
|
});
|
|
641
|
-
var
|
|
642
|
-
this.interceptors.response.forEach(function(
|
|
643
|
-
|
|
641
|
+
var i = [];
|
|
642
|
+
this.interceptors.response.forEach(function(h) {
|
|
643
|
+
i.push(h.fulfilled, h.rejected);
|
|
644
644
|
});
|
|
645
645
|
var c;
|
|
646
|
-
if (!
|
|
647
|
-
var d = [
|
|
648
|
-
for (Array.prototype.unshift.apply(d, a), d = d.concat(
|
|
646
|
+
if (!n) {
|
|
647
|
+
var d = [In, void 0];
|
|
648
|
+
for (Array.prototype.unshift.apply(d, a), d = d.concat(i), c = Promise.resolve(t); d.length; )
|
|
649
649
|
c = c.then(d.shift(), d.shift());
|
|
650
650
|
return c;
|
|
651
651
|
}
|
|
652
|
-
for (var
|
|
653
|
-
var
|
|
652
|
+
for (var s = t; a.length; ) {
|
|
653
|
+
var f = a.shift(), l = a.shift();
|
|
654
654
|
try {
|
|
655
|
-
|
|
656
|
-
} catch (
|
|
657
|
-
|
|
655
|
+
s = f(s);
|
|
656
|
+
} catch (_) {
|
|
657
|
+
l(_);
|
|
658
658
|
break;
|
|
659
659
|
}
|
|
660
660
|
}
|
|
661
661
|
try {
|
|
662
|
-
c =
|
|
663
|
-
} catch (
|
|
664
|
-
return Promise.reject(
|
|
662
|
+
c = In(s);
|
|
663
|
+
} catch (_) {
|
|
664
|
+
return Promise.reject(_);
|
|
665
665
|
}
|
|
666
|
-
for (;
|
|
667
|
-
c = c.then(
|
|
666
|
+
for (; i.length; )
|
|
667
|
+
c = c.then(i.shift(), i.shift());
|
|
668
668
|
return c;
|
|
669
669
|
};
|
|
670
|
-
ze.prototype.getUri = function(
|
|
671
|
-
return
|
|
670
|
+
ze.prototype.getUri = function(r) {
|
|
671
|
+
return r = pt(this.defaults, r), ja(r.url, r.params, r.paramsSerializer).replace(/^\?/, "");
|
|
672
672
|
};
|
|
673
|
-
|
|
674
|
-
ze.prototype[
|
|
675
|
-
return this.request(
|
|
676
|
-
method:
|
|
677
|
-
url:
|
|
678
|
-
data: (
|
|
673
|
+
pr.forEach(["delete", "get", "head", "options"], function(r) {
|
|
674
|
+
ze.prototype[r] = function(t, o) {
|
|
675
|
+
return this.request(pt(o || {}, {
|
|
676
|
+
method: r,
|
|
677
|
+
url: t,
|
|
678
|
+
data: (o || {}).data
|
|
679
679
|
}));
|
|
680
680
|
};
|
|
681
681
|
});
|
|
682
|
-
|
|
683
|
-
ze.prototype[
|
|
684
|
-
return this.request(
|
|
685
|
-
method:
|
|
686
|
-
url:
|
|
687
|
-
data:
|
|
682
|
+
pr.forEach(["post", "put", "patch"], function(r) {
|
|
683
|
+
ze.prototype[r] = function(t, o, a) {
|
|
684
|
+
return this.request(pt(a || {}, {
|
|
685
|
+
method: r,
|
|
686
|
+
url: t,
|
|
687
|
+
data: o
|
|
688
688
|
}));
|
|
689
689
|
};
|
|
690
690
|
});
|
|
691
|
-
var
|
|
692
|
-
function
|
|
693
|
-
if (
|
|
694
|
-
return
|
|
695
|
-
|
|
696
|
-
var
|
|
697
|
-
function
|
|
698
|
-
if (typeof
|
|
691
|
+
var Pa = ze, Nt, qn;
|
|
692
|
+
function Ua() {
|
|
693
|
+
if (qn)
|
|
694
|
+
return Nt;
|
|
695
|
+
qn = 1;
|
|
696
|
+
var e = ft();
|
|
697
|
+
function r(t) {
|
|
698
|
+
if (typeof t != "function")
|
|
699
699
|
throw new TypeError("executor must be a function.");
|
|
700
|
-
var
|
|
701
|
-
this.promise = new Promise(function(
|
|
702
|
-
|
|
700
|
+
var o;
|
|
701
|
+
this.promise = new Promise(function(i) {
|
|
702
|
+
o = i;
|
|
703
703
|
});
|
|
704
704
|
var a = this;
|
|
705
|
-
this.promise.then(function(
|
|
705
|
+
this.promise.then(function(n) {
|
|
706
706
|
if (!!a._listeners) {
|
|
707
|
-
var
|
|
708
|
-
for (
|
|
709
|
-
a._listeners[
|
|
707
|
+
var i, c = a._listeners.length;
|
|
708
|
+
for (i = 0; i < c; i++)
|
|
709
|
+
a._listeners[i](n);
|
|
710
710
|
a._listeners = null;
|
|
711
711
|
}
|
|
712
|
-
}), this.promise.then = function(
|
|
713
|
-
var
|
|
714
|
-
a.subscribe(d),
|
|
715
|
-
}).then(
|
|
712
|
+
}), this.promise.then = function(n) {
|
|
713
|
+
var i, c = new Promise(function(d) {
|
|
714
|
+
a.subscribe(d), i = d;
|
|
715
|
+
}).then(n);
|
|
716
716
|
return c.cancel = function() {
|
|
717
|
-
a.unsubscribe(
|
|
717
|
+
a.unsubscribe(i);
|
|
718
718
|
}, c;
|
|
719
|
-
},
|
|
720
|
-
a.reason || (a.reason = new
|
|
719
|
+
}, t(function(i) {
|
|
720
|
+
a.reason || (a.reason = new e(i), o(a.reason));
|
|
721
721
|
});
|
|
722
722
|
}
|
|
723
|
-
return
|
|
723
|
+
return r.prototype.throwIfRequested = function() {
|
|
724
724
|
if (this.reason)
|
|
725
725
|
throw this.reason;
|
|
726
|
-
},
|
|
726
|
+
}, r.prototype.subscribe = function(o) {
|
|
727
727
|
if (this.reason) {
|
|
728
|
-
|
|
728
|
+
o(this.reason);
|
|
729
729
|
return;
|
|
730
730
|
}
|
|
731
|
-
this._listeners ? this._listeners.push(
|
|
732
|
-
},
|
|
731
|
+
this._listeners ? this._listeners.push(o) : this._listeners = [o];
|
|
732
|
+
}, r.prototype.unsubscribe = function(o) {
|
|
733
733
|
if (!!this._listeners) {
|
|
734
|
-
var a = this._listeners.indexOf(
|
|
734
|
+
var a = this._listeners.indexOf(o);
|
|
735
735
|
a !== -1 && this._listeners.splice(a, 1);
|
|
736
736
|
}
|
|
737
|
-
},
|
|
738
|
-
var
|
|
739
|
-
|
|
737
|
+
}, r.source = function() {
|
|
738
|
+
var o, a = new r(function(i) {
|
|
739
|
+
o = i;
|
|
740
740
|
});
|
|
741
741
|
return {
|
|
742
742
|
token: a,
|
|
743
|
-
cancel:
|
|
743
|
+
cancel: o
|
|
744
744
|
};
|
|
745
|
-
},
|
|
745
|
+
}, Nt = r, Nt;
|
|
746
746
|
}
|
|
747
|
-
var It,
|
|
748
|
-
function
|
|
749
|
-
return
|
|
750
|
-
return function(
|
|
751
|
-
return
|
|
747
|
+
var It, $n;
|
|
748
|
+
function Na() {
|
|
749
|
+
return $n || ($n = 1, It = function(r) {
|
|
750
|
+
return function(o) {
|
|
751
|
+
return r.apply(null, o);
|
|
752
752
|
};
|
|
753
753
|
}), It;
|
|
754
754
|
}
|
|
755
|
-
var
|
|
756
|
-
function
|
|
757
|
-
if (
|
|
758
|
-
return
|
|
759
|
-
|
|
760
|
-
var
|
|
761
|
-
return
|
|
762
|
-
return
|
|
763
|
-
},
|
|
755
|
+
var qt, Vn;
|
|
756
|
+
function Ia() {
|
|
757
|
+
if (Vn)
|
|
758
|
+
return qt;
|
|
759
|
+
Vn = 1;
|
|
760
|
+
var e = ee;
|
|
761
|
+
return qt = function(t) {
|
|
762
|
+
return e.isObject(t) && t.isAxiosError === !0;
|
|
763
|
+
}, qt;
|
|
764
764
|
}
|
|
765
|
-
var
|
|
766
|
-
function
|
|
767
|
-
var
|
|
768
|
-
return
|
|
769
|
-
return
|
|
770
|
-
},
|
|
765
|
+
var Bn = ee, qa = nr, ut = Pa, $a = fr, Va = rn;
|
|
766
|
+
function vr(e) {
|
|
767
|
+
var r = new ut(e), t = qa(ut.prototype.request, r);
|
|
768
|
+
return Bn.extend(t, ut.prototype, r), Bn.extend(t, r), t.create = function(a) {
|
|
769
|
+
return vr($a(e, a));
|
|
770
|
+
}, t;
|
|
771
771
|
}
|
|
772
|
-
var ce =
|
|
773
|
-
ce.Axios =
|
|
774
|
-
ce.Cancel =
|
|
775
|
-
ce.CancelToken =
|
|
776
|
-
ce.isCancel =
|
|
777
|
-
ce.VERSION =
|
|
778
|
-
ce.all = function(
|
|
779
|
-
return Promise.all(
|
|
772
|
+
var ce = vr(Va);
|
|
773
|
+
ce.Axios = ut;
|
|
774
|
+
ce.Cancel = ft();
|
|
775
|
+
ce.CancelToken = Ua();
|
|
776
|
+
ce.isCancel = lr();
|
|
777
|
+
ce.VERSION = dr().version;
|
|
778
|
+
ce.all = function(r) {
|
|
779
|
+
return Promise.all(r);
|
|
780
780
|
};
|
|
781
|
-
ce.spread =
|
|
782
|
-
ce.isAxiosError =
|
|
783
|
-
|
|
784
|
-
|
|
785
|
-
(function(
|
|
786
|
-
|
|
781
|
+
ce.spread = Na();
|
|
782
|
+
ce.isAxiosError = Ia();
|
|
783
|
+
en.exports = ce;
|
|
784
|
+
en.exports.default = ce;
|
|
785
|
+
(function(e) {
|
|
786
|
+
e.exports = en.exports;
|
|
787
787
|
})(Ge);
|
|
788
|
-
var
|
|
789
|
-
return
|
|
790
|
-
for (var
|
|
791
|
-
|
|
792
|
-
for (var a in
|
|
793
|
-
Object.prototype.hasOwnProperty.call(
|
|
794
|
-
}
|
|
795
|
-
return
|
|
796
|
-
},
|
|
797
|
-
},
|
|
798
|
-
function a(
|
|
799
|
-
return
|
|
800
|
-
|
|
788
|
+
var ct = j && j.__assign || function() {
|
|
789
|
+
return ct = Object.assign || function(e) {
|
|
790
|
+
for (var r, t = 1, o = arguments.length; t < o; t++) {
|
|
791
|
+
r = arguments[t];
|
|
792
|
+
for (var a in r)
|
|
793
|
+
Object.prototype.hasOwnProperty.call(r, a) && (e[a] = r[a]);
|
|
794
|
+
}
|
|
795
|
+
return e;
|
|
796
|
+
}, ct.apply(this, arguments);
|
|
797
|
+
}, et = j && j.__awaiter || function(e, r, t, o) {
|
|
798
|
+
function a(n) {
|
|
799
|
+
return n instanceof t ? n : new t(function(i) {
|
|
800
|
+
i(n);
|
|
801
801
|
});
|
|
802
802
|
}
|
|
803
|
-
return new (
|
|
804
|
-
function c(
|
|
803
|
+
return new (t || (t = Promise))(function(n, i) {
|
|
804
|
+
function c(f) {
|
|
805
805
|
try {
|
|
806
|
-
o
|
|
807
|
-
} catch (
|
|
808
|
-
|
|
806
|
+
s(o.next(f));
|
|
807
|
+
} catch (l) {
|
|
808
|
+
i(l);
|
|
809
809
|
}
|
|
810
810
|
}
|
|
811
|
-
function d(
|
|
811
|
+
function d(f) {
|
|
812
812
|
try {
|
|
813
|
-
o
|
|
814
|
-
} catch (
|
|
815
|
-
|
|
813
|
+
s(o.throw(f));
|
|
814
|
+
} catch (l) {
|
|
815
|
+
i(l);
|
|
816
816
|
}
|
|
817
817
|
}
|
|
818
|
-
function
|
|
819
|
-
|
|
818
|
+
function s(f) {
|
|
819
|
+
f.done ? n(f.value) : a(f.value).then(c, d);
|
|
820
820
|
}
|
|
821
|
-
|
|
821
|
+
s((o = o.apply(e, r || [])).next());
|
|
822
822
|
});
|
|
823
|
-
},
|
|
824
|
-
var
|
|
825
|
-
if (
|
|
826
|
-
throw
|
|
827
|
-
return
|
|
828
|
-
}, trys: [], ops: [] },
|
|
829
|
-
return
|
|
823
|
+
}, tt = j && j.__generator || function(e, r) {
|
|
824
|
+
var t = { label: 0, sent: function() {
|
|
825
|
+
if (n[0] & 1)
|
|
826
|
+
throw n[1];
|
|
827
|
+
return n[1];
|
|
828
|
+
}, trys: [], ops: [] }, o, a, n, i;
|
|
829
|
+
return i = { next: c(0), throw: c(1), return: c(2) }, typeof Symbol == "function" && (i[Symbol.iterator] = function() {
|
|
830
830
|
return this;
|
|
831
|
-
}),
|
|
832
|
-
function c(
|
|
833
|
-
return function(
|
|
834
|
-
return d([
|
|
831
|
+
}), i;
|
|
832
|
+
function c(s) {
|
|
833
|
+
return function(f) {
|
|
834
|
+
return d([s, f]);
|
|
835
835
|
};
|
|
836
836
|
}
|
|
837
|
-
function d(
|
|
838
|
-
if (
|
|
837
|
+
function d(s) {
|
|
838
|
+
if (o)
|
|
839
839
|
throw new TypeError("Generator is already executing.");
|
|
840
|
-
for (;
|
|
840
|
+
for (; t; )
|
|
841
841
|
try {
|
|
842
|
-
if (
|
|
843
|
-
return
|
|
844
|
-
switch (a = 0,
|
|
842
|
+
if (o = 1, a && (n = s[0] & 2 ? a.return : s[0] ? a.throw || ((n = a.return) && n.call(a), 0) : a.next) && !(n = n.call(a, s[1])).done)
|
|
843
|
+
return n;
|
|
844
|
+
switch (a = 0, n && (s = [s[0] & 2, n.value]), s[0]) {
|
|
845
845
|
case 0:
|
|
846
846
|
case 1:
|
|
847
|
-
|
|
847
|
+
n = s;
|
|
848
848
|
break;
|
|
849
849
|
case 4:
|
|
850
|
-
return
|
|
850
|
+
return t.label++, { value: s[1], done: !1 };
|
|
851
851
|
case 5:
|
|
852
|
-
|
|
852
|
+
t.label++, a = s[1], s = [0];
|
|
853
853
|
continue;
|
|
854
854
|
case 7:
|
|
855
|
-
|
|
855
|
+
s = t.ops.pop(), t.trys.pop();
|
|
856
856
|
continue;
|
|
857
857
|
default:
|
|
858
|
-
if (
|
|
859
|
-
|
|
858
|
+
if (n = t.trys, !(n = n.length > 0 && n[n.length - 1]) && (s[0] === 6 || s[0] === 2)) {
|
|
859
|
+
t = 0;
|
|
860
860
|
continue;
|
|
861
861
|
}
|
|
862
|
-
if (
|
|
863
|
-
|
|
862
|
+
if (s[0] === 3 && (!n || s[1] > n[0] && s[1] < n[3])) {
|
|
863
|
+
t.label = s[1];
|
|
864
864
|
break;
|
|
865
865
|
}
|
|
866
|
-
if (
|
|
867
|
-
|
|
866
|
+
if (s[0] === 6 && t.label < n[1]) {
|
|
867
|
+
t.label = n[1], n = s;
|
|
868
868
|
break;
|
|
869
869
|
}
|
|
870
|
-
if (
|
|
871
|
-
|
|
870
|
+
if (n && t.label < n[2]) {
|
|
871
|
+
t.label = n[2], t.ops.push(s);
|
|
872
872
|
break;
|
|
873
873
|
}
|
|
874
|
-
|
|
874
|
+
n[2] && t.ops.pop(), t.trys.pop();
|
|
875
875
|
continue;
|
|
876
876
|
}
|
|
877
|
-
|
|
878
|
-
} catch (
|
|
879
|
-
|
|
877
|
+
s = r.call(e, t);
|
|
878
|
+
} catch (f) {
|
|
879
|
+
s = [6, f], a = 0;
|
|
880
880
|
} finally {
|
|
881
|
-
|
|
881
|
+
o = n = 0;
|
|
882
882
|
}
|
|
883
|
-
if (
|
|
884
|
-
throw
|
|
885
|
-
return { value:
|
|
883
|
+
if (s[0] & 5)
|
|
884
|
+
throw s[1];
|
|
885
|
+
return { value: s[0] ? s[1] : void 0, done: !0 };
|
|
886
886
|
}
|
|
887
887
|
};
|
|
888
888
|
Object.defineProperty(Ye, "__esModule", { value: !0 });
|
|
889
889
|
Ye.FrappeCall = void 0;
|
|
890
|
-
var nt = Ge.exports,
|
|
891
|
-
function
|
|
892
|
-
this.appURL =
|
|
890
|
+
var nt = Ge.exports, Ba = function() {
|
|
891
|
+
function e(r) {
|
|
892
|
+
this.appURL = r;
|
|
893
893
|
}
|
|
894
|
-
return
|
|
895
|
-
return
|
|
896
|
-
var
|
|
897
|
-
return
|
|
898
|
-
return
|
|
894
|
+
return e.prototype.get = function(r, t) {
|
|
895
|
+
return et(this, void 0, void 0, function() {
|
|
896
|
+
var o;
|
|
897
|
+
return tt(this, function(a) {
|
|
898
|
+
return o = {
|
|
899
899
|
Accept: "application/json",
|
|
900
900
|
"Content-Type": "application/json; charset=utf-8",
|
|
901
901
|
"X-Frappe-Site-Name": window.location.hostname
|
|
902
|
-
}, window.csrf_token && window.csrf_token !== "{{ csrf_token }}" && (
|
|
903
|
-
headers:
|
|
904
|
-
params:
|
|
902
|
+
}, window.csrf_token && window.csrf_token !== "{{ csrf_token }}" && (o["X-Frappe-CSRF-Token"] = window.csrf_token), [2, nt.default.get("".concat(this.appURL, "/api/method/").concat(r), {
|
|
903
|
+
headers: o,
|
|
904
|
+
params: t,
|
|
905
905
|
withCredentials: !0
|
|
906
|
-
}).then(function(
|
|
907
|
-
return
|
|
908
|
-
}).catch(function(
|
|
909
|
-
var
|
|
906
|
+
}).then(function(n) {
|
|
907
|
+
return n.data;
|
|
908
|
+
}).catch(function(n) {
|
|
909
|
+
var i, c;
|
|
910
910
|
throw {
|
|
911
|
-
httpStatus:
|
|
912
|
-
httpStatusText:
|
|
913
|
-
message: (
|
|
914
|
-
exception: (c =
|
|
911
|
+
httpStatus: n.response.status,
|
|
912
|
+
httpStatusText: n.response.statusText,
|
|
913
|
+
message: (i = n.response.data.message) !== null && i !== void 0 ? i : "There was an error.",
|
|
914
|
+
exception: (c = n.response.data.exception) !== null && c !== void 0 ? c : ""
|
|
915
915
|
};
|
|
916
916
|
})];
|
|
917
917
|
});
|
|
918
918
|
});
|
|
919
|
-
},
|
|
920
|
-
return
|
|
921
|
-
var
|
|
922
|
-
return
|
|
923
|
-
return
|
|
919
|
+
}, e.prototype.post = function(r, t) {
|
|
920
|
+
return et(this, void 0, void 0, function() {
|
|
921
|
+
var o;
|
|
922
|
+
return tt(this, function(a) {
|
|
923
|
+
return o = {
|
|
924
924
|
Accept: "application/json",
|
|
925
925
|
"Content-Type": "application/json; charset=utf-8",
|
|
926
926
|
"X-Frappe-Site-Name": window.location.hostname
|
|
927
|
-
}, window.csrf_token && window.csrf_token !== "{{ csrf_token }}" && (
|
|
927
|
+
}, window.csrf_token && window.csrf_token !== "{{ csrf_token }}" && (o["X-Frappe-CSRF-Token"] = window.csrf_token), [2, nt.default.post("".concat(this.appURL, "/api/method/").concat(r), ct({}, t), {
|
|
928
928
|
withCredentials: !0,
|
|
929
|
-
headers:
|
|
930
|
-
}).then(function(
|
|
931
|
-
return
|
|
932
|
-
}).catch(function(
|
|
933
|
-
var
|
|
929
|
+
headers: o
|
|
930
|
+
}).then(function(n) {
|
|
931
|
+
return n.data;
|
|
932
|
+
}).catch(function(n) {
|
|
933
|
+
var i, c;
|
|
934
934
|
throw {
|
|
935
|
-
httpStatus:
|
|
936
|
-
httpStatusText:
|
|
937
|
-
message: (
|
|
938
|
-
exception: (c =
|
|
935
|
+
httpStatus: n.response.status,
|
|
936
|
+
httpStatusText: n.response.statusText,
|
|
937
|
+
message: (i = n.response.data.message) !== null && i !== void 0 ? i : "There was an error.",
|
|
938
|
+
exception: (c = n.response.data.exception) !== null && c !== void 0 ? c : ""
|
|
939
939
|
};
|
|
940
940
|
})];
|
|
941
941
|
});
|
|
942
942
|
});
|
|
943
|
-
},
|
|
944
|
-
return
|
|
945
|
-
var
|
|
946
|
-
return
|
|
947
|
-
return
|
|
943
|
+
}, e.prototype.put = function(r, t) {
|
|
944
|
+
return et(this, void 0, void 0, function() {
|
|
945
|
+
var o;
|
|
946
|
+
return tt(this, function(a) {
|
|
947
|
+
return o = {
|
|
948
948
|
Accept: "application/json",
|
|
949
949
|
"Content-Type": "application/json; charset=utf-8",
|
|
950
950
|
"X-Frappe-Site-Name": window.location.hostname
|
|
951
|
-
}, window.csrf_token && window.csrf_token !== "{{ csrf_token }}" && (
|
|
952
|
-
headers:
|
|
951
|
+
}, window.csrf_token && window.csrf_token !== "{{ csrf_token }}" && (o["X-Frappe-CSRF-Token"] = window.csrf_token), [2, nt.default.put("".concat(this.appURL, "/api/method/").concat(r), ct({}, t), {
|
|
952
|
+
headers: o,
|
|
953
953
|
withCredentials: !0
|
|
954
|
-
}).then(function(
|
|
955
|
-
return
|
|
956
|
-
}).catch(function(
|
|
957
|
-
var
|
|
954
|
+
}).then(function(n) {
|
|
955
|
+
return n.data;
|
|
956
|
+
}).catch(function(n) {
|
|
957
|
+
var i, c;
|
|
958
958
|
throw {
|
|
959
|
-
httpStatus:
|
|
960
|
-
httpStatusText:
|
|
961
|
-
message: (
|
|
962
|
-
exception: (c =
|
|
959
|
+
httpStatus: n.response.status,
|
|
960
|
+
httpStatusText: n.response.statusText,
|
|
961
|
+
message: (i = n.response.data.message) !== null && i !== void 0 ? i : "There was an error.",
|
|
962
|
+
exception: (c = n.response.data.exception) !== null && c !== void 0 ? c : ""
|
|
963
963
|
};
|
|
964
964
|
})];
|
|
965
965
|
});
|
|
966
966
|
});
|
|
967
|
-
},
|
|
968
|
-
return
|
|
969
|
-
var
|
|
970
|
-
return
|
|
971
|
-
return
|
|
967
|
+
}, e.prototype.delete = function(r, t) {
|
|
968
|
+
return et(this, void 0, void 0, function() {
|
|
969
|
+
var o;
|
|
970
|
+
return tt(this, function(a) {
|
|
971
|
+
return o = {
|
|
972
972
|
Accept: "application/json",
|
|
973
973
|
"Content-Type": "application/json; charset=utf-8",
|
|
974
974
|
"X-Frappe-Site-Name": window.location.hostname
|
|
975
|
-
}, window.csrf_token && window.csrf_token !== "{{ csrf_token }}" && (
|
|
976
|
-
headers:
|
|
977
|
-
params:
|
|
975
|
+
}, window.csrf_token && window.csrf_token !== "{{ csrf_token }}" && (o["X-Frappe-CSRF-Token"] = window.csrf_token), [2, nt.default.delete("".concat(this.appURL, "/api/method/").concat(r), {
|
|
976
|
+
headers: o,
|
|
977
|
+
params: t,
|
|
978
978
|
withCredentials: !0
|
|
979
|
-
}).then(function(
|
|
980
|
-
return
|
|
981
|
-
}).catch(function(
|
|
982
|
-
var
|
|
979
|
+
}).then(function(n) {
|
|
980
|
+
return n.data;
|
|
981
|
+
}).catch(function(n) {
|
|
982
|
+
var i, c;
|
|
983
983
|
throw {
|
|
984
|
-
httpStatus:
|
|
985
|
-
httpStatusText:
|
|
986
|
-
message: (
|
|
987
|
-
exception: (c =
|
|
984
|
+
httpStatus: n.response.status,
|
|
985
|
+
httpStatusText: n.response.statusText,
|
|
986
|
+
message: (i = n.response.data.message) !== null && i !== void 0 ? i : "There was an error.",
|
|
987
|
+
exception: (c = n.response.data.exception) !== null && c !== void 0 ? c : ""
|
|
988
988
|
};
|
|
989
989
|
})];
|
|
990
990
|
});
|
|
991
991
|
});
|
|
992
|
-
},
|
|
992
|
+
}, e;
|
|
993
993
|
}();
|
|
994
|
-
Ye.FrappeCall =
|
|
995
|
-
var Ke = {}, we =
|
|
996
|
-
return we = Object.assign || function(
|
|
997
|
-
for (var
|
|
998
|
-
|
|
999
|
-
for (var a in
|
|
1000
|
-
Object.prototype.hasOwnProperty.call(
|
|
1001
|
-
}
|
|
1002
|
-
return
|
|
994
|
+
Ye.FrappeCall = Ba;
|
|
995
|
+
var Ke = {}, we = j && j.__assign || function() {
|
|
996
|
+
return we = Object.assign || function(e) {
|
|
997
|
+
for (var r, t = 1, o = arguments.length; t < o; t++) {
|
|
998
|
+
r = arguments[t];
|
|
999
|
+
for (var a in r)
|
|
1000
|
+
Object.prototype.hasOwnProperty.call(r, a) && (e[a] = r[a]);
|
|
1001
|
+
}
|
|
1002
|
+
return e;
|
|
1003
1003
|
}, we.apply(this, arguments);
|
|
1004
|
-
},
|
|
1005
|
-
function a(
|
|
1006
|
-
return
|
|
1007
|
-
|
|
1004
|
+
}, Te = j && j.__awaiter || function(e, r, t, o) {
|
|
1005
|
+
function a(n) {
|
|
1006
|
+
return n instanceof t ? n : new t(function(i) {
|
|
1007
|
+
i(n);
|
|
1008
1008
|
});
|
|
1009
1009
|
}
|
|
1010
|
-
return new (
|
|
1011
|
-
function c(
|
|
1010
|
+
return new (t || (t = Promise))(function(n, i) {
|
|
1011
|
+
function c(f) {
|
|
1012
1012
|
try {
|
|
1013
|
-
o
|
|
1014
|
-
} catch (
|
|
1015
|
-
|
|
1013
|
+
s(o.next(f));
|
|
1014
|
+
} catch (l) {
|
|
1015
|
+
i(l);
|
|
1016
1016
|
}
|
|
1017
1017
|
}
|
|
1018
|
-
function d(
|
|
1018
|
+
function d(f) {
|
|
1019
1019
|
try {
|
|
1020
|
-
o
|
|
1021
|
-
} catch (
|
|
1022
|
-
|
|
1020
|
+
s(o.throw(f));
|
|
1021
|
+
} catch (l) {
|
|
1022
|
+
i(l);
|
|
1023
1023
|
}
|
|
1024
1024
|
}
|
|
1025
|
-
function
|
|
1026
|
-
|
|
1025
|
+
function s(f) {
|
|
1026
|
+
f.done ? n(f.value) : a(f.value).then(c, d);
|
|
1027
1027
|
}
|
|
1028
|
-
|
|
1028
|
+
s((o = o.apply(e, r || [])).next());
|
|
1029
1029
|
});
|
|
1030
|
-
},
|
|
1031
|
-
var
|
|
1032
|
-
if (
|
|
1033
|
-
throw
|
|
1034
|
-
return
|
|
1035
|
-
}, trys: [], ops: [] },
|
|
1036
|
-
return
|
|
1030
|
+
}, Ce = j && j.__generator || function(e, r) {
|
|
1031
|
+
var t = { label: 0, sent: function() {
|
|
1032
|
+
if (n[0] & 1)
|
|
1033
|
+
throw n[1];
|
|
1034
|
+
return n[1];
|
|
1035
|
+
}, trys: [], ops: [] }, o, a, n, i;
|
|
1036
|
+
return i = { next: c(0), throw: c(1), return: c(2) }, typeof Symbol == "function" && (i[Symbol.iterator] = function() {
|
|
1037
1037
|
return this;
|
|
1038
|
-
}),
|
|
1039
|
-
function c(
|
|
1040
|
-
return function(
|
|
1041
|
-
return d([
|
|
1038
|
+
}), i;
|
|
1039
|
+
function c(s) {
|
|
1040
|
+
return function(f) {
|
|
1041
|
+
return d([s, f]);
|
|
1042
1042
|
};
|
|
1043
1043
|
}
|
|
1044
|
-
function d(
|
|
1045
|
-
if (
|
|
1044
|
+
function d(s) {
|
|
1045
|
+
if (o)
|
|
1046
1046
|
throw new TypeError("Generator is already executing.");
|
|
1047
|
-
for (;
|
|
1047
|
+
for (; t; )
|
|
1048
1048
|
try {
|
|
1049
|
-
if (
|
|
1050
|
-
return
|
|
1051
|
-
switch (a = 0,
|
|
1049
|
+
if (o = 1, a && (n = s[0] & 2 ? a.return : s[0] ? a.throw || ((n = a.return) && n.call(a), 0) : a.next) && !(n = n.call(a, s[1])).done)
|
|
1050
|
+
return n;
|
|
1051
|
+
switch (a = 0, n && (s = [s[0] & 2, n.value]), s[0]) {
|
|
1052
1052
|
case 0:
|
|
1053
1053
|
case 1:
|
|
1054
|
-
|
|
1054
|
+
n = s;
|
|
1055
1055
|
break;
|
|
1056
1056
|
case 4:
|
|
1057
|
-
return
|
|
1057
|
+
return t.label++, { value: s[1], done: !1 };
|
|
1058
1058
|
case 5:
|
|
1059
|
-
|
|
1059
|
+
t.label++, a = s[1], s = [0];
|
|
1060
1060
|
continue;
|
|
1061
1061
|
case 7:
|
|
1062
|
-
|
|
1062
|
+
s = t.ops.pop(), t.trys.pop();
|
|
1063
1063
|
continue;
|
|
1064
1064
|
default:
|
|
1065
|
-
if (
|
|
1066
|
-
|
|
1065
|
+
if (n = t.trys, !(n = n.length > 0 && n[n.length - 1]) && (s[0] === 6 || s[0] === 2)) {
|
|
1066
|
+
t = 0;
|
|
1067
1067
|
continue;
|
|
1068
1068
|
}
|
|
1069
|
-
if (
|
|
1070
|
-
|
|
1069
|
+
if (s[0] === 3 && (!n || s[1] > n[0] && s[1] < n[3])) {
|
|
1070
|
+
t.label = s[1];
|
|
1071
1071
|
break;
|
|
1072
1072
|
}
|
|
1073
|
-
if (
|
|
1074
|
-
|
|
1073
|
+
if (s[0] === 6 && t.label < n[1]) {
|
|
1074
|
+
t.label = n[1], n = s;
|
|
1075
1075
|
break;
|
|
1076
1076
|
}
|
|
1077
|
-
if (
|
|
1078
|
-
|
|
1077
|
+
if (n && t.label < n[2]) {
|
|
1078
|
+
t.label = n[2], t.ops.push(s);
|
|
1079
1079
|
break;
|
|
1080
1080
|
}
|
|
1081
|
-
|
|
1081
|
+
n[2] && t.ops.pop(), t.trys.pop();
|
|
1082
1082
|
continue;
|
|
1083
1083
|
}
|
|
1084
|
-
|
|
1085
|
-
} catch (
|
|
1086
|
-
|
|
1084
|
+
s = r.call(e, t);
|
|
1085
|
+
} catch (f) {
|
|
1086
|
+
s = [6, f], a = 0;
|
|
1087
1087
|
} finally {
|
|
1088
|
-
|
|
1088
|
+
o = n = 0;
|
|
1089
1089
|
}
|
|
1090
|
-
if (
|
|
1091
|
-
throw
|
|
1092
|
-
return { value:
|
|
1090
|
+
if (s[0] & 5)
|
|
1091
|
+
throw s[1];
|
|
1092
|
+
return { value: s[0] ? s[1] : void 0, done: !0 };
|
|
1093
1093
|
}
|
|
1094
1094
|
};
|
|
1095
1095
|
Object.defineProperty(Ke, "__esModule", { value: !0 });
|
|
1096
1096
|
Ke.FrappeDB = void 0;
|
|
1097
|
-
var
|
|
1098
|
-
function
|
|
1099
|
-
this.appURL =
|
|
1097
|
+
var Le = Ge.exports, Ma = function() {
|
|
1098
|
+
function e(r) {
|
|
1099
|
+
this.appURL = r;
|
|
1100
1100
|
}
|
|
1101
|
-
return
|
|
1102
|
-
var
|
|
1103
|
-
return
|
|
1104
|
-
},
|
|
1105
|
-
return
|
|
1106
|
-
var
|
|
1107
|
-
return
|
|
1108
|
-
return
|
|
1101
|
+
return e.prototype.getRequestURL = function(r, t) {
|
|
1102
|
+
var o = "".concat(this.appURL, "/api/resource/");
|
|
1103
|
+
return t ? o += "".concat(r, "/").concat(t) : o += "".concat(r), o;
|
|
1104
|
+
}, e.prototype.getDoc = function(r, t) {
|
|
1105
|
+
return Te(this, void 0, void 0, function() {
|
|
1106
|
+
var o;
|
|
1107
|
+
return Ce(this, function(a) {
|
|
1108
|
+
return o = {
|
|
1109
1109
|
Accept: "application/json",
|
|
1110
1110
|
"Content-Type": "application/json; charset=utf-8",
|
|
1111
1111
|
"X-Frappe-Site-Name": window.location.hostname
|
|
1112
|
-
}, window.csrf_token && window.csrf_token !== "{{ csrf_token }}" && (
|
|
1113
|
-
headers:
|
|
1112
|
+
}, window.csrf_token && window.csrf_token !== "{{ csrf_token }}" && (o["X-Frappe-CSRF-Token"] = window.csrf_token), [2, Le.default.get(this.getRequestURL(r, t), {
|
|
1113
|
+
headers: o,
|
|
1114
1114
|
withCredentials: !0
|
|
1115
|
-
}).then(function(
|
|
1116
|
-
return
|
|
1117
|
-
}).catch(function(
|
|
1118
|
-
var
|
|
1115
|
+
}).then(function(n) {
|
|
1116
|
+
return n.data.data;
|
|
1117
|
+
}).catch(function(n) {
|
|
1118
|
+
var i, c;
|
|
1119
1119
|
throw {
|
|
1120
|
-
httpStatus:
|
|
1121
|
-
httpStatusText:
|
|
1120
|
+
httpStatus: n.response.status,
|
|
1121
|
+
httpStatusText: n.response.statusText,
|
|
1122
1122
|
message: "There was an error while fetching the document.",
|
|
1123
|
-
exception: (c = (
|
|
1123
|
+
exception: (c = (i = n.response.data.exception) !== null && i !== void 0 ? i : n.response.data.exc_type) !== null && c !== void 0 ? c : ""
|
|
1124
1124
|
};
|
|
1125
1125
|
})];
|
|
1126
1126
|
});
|
|
1127
1127
|
});
|
|
1128
|
-
},
|
|
1129
|
-
var
|
|
1130
|
-
return
|
|
1131
|
-
var a,
|
|
1132
|
-
return
|
|
1133
|
-
return a = {},
|
|
1134
|
-
fields:
|
|
1135
|
-
filters:
|
|
1128
|
+
}, e.prototype.getDocList = function(r, t) {
|
|
1129
|
+
var o;
|
|
1130
|
+
return Te(this, void 0, void 0, function() {
|
|
1131
|
+
var a, n, i, c, d, s, f, l, _, h, b;
|
|
1132
|
+
return Ce(this, function(w) {
|
|
1133
|
+
return a = {}, t && (n = t.fields, i = t.filters, c = t.orFilters, d = t.orderBy, s = t.limit, f = t.limit_start, l = t.asDict, _ = l === void 0 ? !0 : l, h = d ? "".concat(d == null ? void 0 : d.field, " ").concat((o = d == null ? void 0 : d.order) !== null && o !== void 0 ? o : "asc") : "", a = {
|
|
1134
|
+
fields: n ? JSON.stringify(n) : void 0,
|
|
1135
|
+
filters: i ? JSON.stringify(i) : void 0,
|
|
1136
1136
|
or_filters: c ? JSON.stringify(c) : void 0,
|
|
1137
|
-
order_by:
|
|
1138
|
-
limit:
|
|
1139
|
-
|
|
1140
|
-
as_dict:
|
|
1141
|
-
}),
|
|
1137
|
+
order_by: h,
|
|
1138
|
+
limit: s,
|
|
1139
|
+
limit_start: f,
|
|
1140
|
+
as_dict: _
|
|
1141
|
+
}), b = {
|
|
1142
1142
|
Accept: "application/json",
|
|
1143
1143
|
"Content-Type": "application/json; charset=utf-8",
|
|
1144
1144
|
"X-Frappe-Site-Name": window.location.hostname
|
|
1145
|
-
}, window.csrf_token && window.csrf_token !== "{{ csrf_token }}" && (
|
|
1145
|
+
}, window.csrf_token && window.csrf_token !== "{{ csrf_token }}" && (b["X-Frappe-CSRF-Token"] = window.csrf_token), [2, Le.default.get(this.getRequestURL(r), {
|
|
1146
1146
|
params: a,
|
|
1147
|
-
headers:
|
|
1147
|
+
headers: b,
|
|
1148
1148
|
withCredentials: !0
|
|
1149
|
-
}).then(function(
|
|
1150
|
-
return
|
|
1151
|
-
}).catch(function(
|
|
1152
|
-
var
|
|
1149
|
+
}).then(function(T) {
|
|
1150
|
+
return T.data.data;
|
|
1151
|
+
}).catch(function(T) {
|
|
1152
|
+
var x, S;
|
|
1153
1153
|
throw {
|
|
1154
|
-
httpStatus:
|
|
1155
|
-
httpStatusText:
|
|
1154
|
+
httpStatus: T.response.status,
|
|
1155
|
+
httpStatusText: T.response.statusText,
|
|
1156
1156
|
message: "There was an error while fetching the documents.",
|
|
1157
|
-
exception: (
|
|
1157
|
+
exception: (S = (x = T.response.data.exception) !== null && x !== void 0 ? x : T.response.data.exc_type) !== null && S !== void 0 ? S : ""
|
|
1158
1158
|
};
|
|
1159
1159
|
})];
|
|
1160
1160
|
});
|
|
1161
1161
|
});
|
|
1162
|
-
},
|
|
1163
|
-
return
|
|
1164
|
-
var
|
|
1165
|
-
return
|
|
1166
|
-
return
|
|
1162
|
+
}, e.prototype.createDoc = function(r, t) {
|
|
1163
|
+
return Te(this, void 0, void 0, function() {
|
|
1164
|
+
var o;
|
|
1165
|
+
return Ce(this, function(a) {
|
|
1166
|
+
return o = {
|
|
1167
1167
|
Accept: "application/json",
|
|
1168
1168
|
"Content-Type": "application/json; charset=utf-8",
|
|
1169
1169
|
"X-Frappe-Site-Name": window.location.hostname
|
|
1170
|
-
}, window.csrf_token && window.csrf_token !== "{{ csrf_token }}" && (
|
|
1171
|
-
headers:
|
|
1170
|
+
}, window.csrf_token && window.csrf_token !== "{{ csrf_token }}" && (o["X-Frappe-CSRF-Token"] = window.csrf_token), [2, Le.default.post(this.getRequestURL(r), we({}, t), {
|
|
1171
|
+
headers: o,
|
|
1172
1172
|
withCredentials: !0
|
|
1173
|
-
}).then(function(
|
|
1174
|
-
return
|
|
1175
|
-
}).catch(function(
|
|
1176
|
-
var
|
|
1173
|
+
}).then(function(n) {
|
|
1174
|
+
return n.data.data;
|
|
1175
|
+
}).catch(function(n) {
|
|
1176
|
+
var i, c, d;
|
|
1177
1177
|
throw {
|
|
1178
|
-
httpStatus:
|
|
1179
|
-
httpStatusText:
|
|
1180
|
-
message: (
|
|
1181
|
-
exception: (d = (c =
|
|
1178
|
+
httpStatus: n.response.status,
|
|
1179
|
+
httpStatusText: n.response.statusText,
|
|
1180
|
+
message: (i = n.response.data.message) !== null && i !== void 0 ? i : "There was an error while creating the document.",
|
|
1181
|
+
exception: (d = (c = n.response.data.exception) !== null && c !== void 0 ? c : n.response.data.exc_type) !== null && d !== void 0 ? d : ""
|
|
1182
1182
|
};
|
|
1183
1183
|
})];
|
|
1184
1184
|
});
|
|
1185
1185
|
});
|
|
1186
|
-
},
|
|
1187
|
-
return
|
|
1186
|
+
}, e.prototype.updateDoc = function(r, t, o) {
|
|
1187
|
+
return Te(this, void 0, void 0, function() {
|
|
1188
1188
|
var a;
|
|
1189
|
-
return
|
|
1189
|
+
return Ce(this, function(n) {
|
|
1190
1190
|
return a = {
|
|
1191
1191
|
Accept: "application/json",
|
|
1192
1192
|
"Content-Type": "application/json; charset=utf-8",
|
|
1193
1193
|
"X-Frappe-Site-Name": window.location.hostname
|
|
1194
|
-
}, window.csrf_token && window.csrf_token !== "{{ csrf_token }}" && (a["X-Frappe-CSRF-Token"] = window.csrf_token), [2,
|
|
1194
|
+
}, window.csrf_token && window.csrf_token !== "{{ csrf_token }}" && (a["X-Frappe-CSRF-Token"] = window.csrf_token), [2, Le.default.put(this.getRequestURL(r, t), we({}, o), {
|
|
1195
1195
|
headers: a,
|
|
1196
1196
|
withCredentials: !0
|
|
1197
|
-
}).then(function(
|
|
1198
|
-
return
|
|
1199
|
-
}).catch(function(
|
|
1200
|
-
var c, d,
|
|
1197
|
+
}).then(function(i) {
|
|
1198
|
+
return i.data.data;
|
|
1199
|
+
}).catch(function(i) {
|
|
1200
|
+
var c, d, s;
|
|
1201
1201
|
throw {
|
|
1202
|
-
httpStatus:
|
|
1203
|
-
httpStatusText:
|
|
1204
|
-
message: (c =
|
|
1205
|
-
exception: (
|
|
1202
|
+
httpStatus: i.response.status,
|
|
1203
|
+
httpStatusText: i.response.statusText,
|
|
1204
|
+
message: (c = i.response.data.message) !== null && c !== void 0 ? c : "There was an error while updating the document.",
|
|
1205
|
+
exception: (s = (d = i.response.data.exception) !== null && d !== void 0 ? d : i.response.data.exc_type) !== null && s !== void 0 ? s : ""
|
|
1206
1206
|
};
|
|
1207
1207
|
})];
|
|
1208
1208
|
});
|
|
1209
1209
|
});
|
|
1210
|
-
},
|
|
1211
|
-
return
|
|
1212
|
-
var
|
|
1213
|
-
return
|
|
1214
|
-
return
|
|
1210
|
+
}, e.prototype.deleteDoc = function(r, t) {
|
|
1211
|
+
return Te(this, void 0, void 0, function() {
|
|
1212
|
+
var o;
|
|
1213
|
+
return Ce(this, function(a) {
|
|
1214
|
+
return o = {
|
|
1215
1215
|
Accept: "application/json",
|
|
1216
1216
|
"Content-Type": "application/json; charset=utf-8",
|
|
1217
1217
|
"X-Frappe-Site-Name": window.location.hostname
|
|
1218
|
-
}, window.csrf_token && window.csrf_token !== "{{ csrf_token }}" && (
|
|
1219
|
-
headers:
|
|
1218
|
+
}, window.csrf_token && window.csrf_token !== "{{ csrf_token }}" && (o["X-Frappe-CSRF-Token"] = window.csrf_token), [2, Le.default.delete(this.getRequestURL(r, t), {
|
|
1219
|
+
headers: o,
|
|
1220
1220
|
withCredentials: !0
|
|
1221
|
-
}).then(function(
|
|
1222
|
-
return
|
|
1223
|
-
}).catch(function(
|
|
1224
|
-
var
|
|
1221
|
+
}).then(function(n) {
|
|
1222
|
+
return n.data;
|
|
1223
|
+
}).catch(function(n) {
|
|
1224
|
+
var i, c;
|
|
1225
1225
|
throw {
|
|
1226
|
-
httpStatus:
|
|
1227
|
-
httpStatusText:
|
|
1226
|
+
httpStatus: n.response.status,
|
|
1227
|
+
httpStatusText: n.response.statusText,
|
|
1228
1228
|
message: "There was an error while deleting the document.",
|
|
1229
|
-
exception: (c = (
|
|
1229
|
+
exception: (c = (i = n.response.data.exception) !== null && i !== void 0 ? i : n.response.data.exc_type) !== null && c !== void 0 ? c : ""
|
|
1230
1230
|
};
|
|
1231
1231
|
})];
|
|
1232
1232
|
});
|
|
1233
1233
|
});
|
|
1234
|
-
},
|
|
1235
|
-
return
|
|
1236
|
-
var
|
|
1237
|
-
return
|
|
1238
|
-
return
|
|
1239
|
-
doctype:
|
|
1234
|
+
}, e.prototype.getCount = function(r, t, o, a) {
|
|
1235
|
+
return o === void 0 && (o = !1), a === void 0 && (a = !1), Te(this, void 0, void 0, function() {
|
|
1236
|
+
var n, i;
|
|
1237
|
+
return Ce(this, function(c) {
|
|
1238
|
+
return n = {
|
|
1239
|
+
doctype: r,
|
|
1240
1240
|
debug: a,
|
|
1241
|
-
cache:
|
|
1241
|
+
cache: o,
|
|
1242
1242
|
filters: []
|
|
1243
|
-
},
|
|
1243
|
+
}, t && (n.filters = t ? JSON.stringify(t) : void 0), i = {
|
|
1244
1244
|
Accept: "application/json",
|
|
1245
1245
|
"Content-Type": "application/json; charset=utf-8",
|
|
1246
1246
|
"X-Frappe-Site-Name": window.location.hostname
|
|
1247
|
-
}, window.csrf_token && window.csrf_token !== "{{ csrf_token }}" && (
|
|
1248
|
-
params:
|
|
1249
|
-
headers:
|
|
1247
|
+
}, window.csrf_token && window.csrf_token !== "{{ csrf_token }}" && (i["X-Frappe-CSRF-Token"] = window.csrf_token), [2, Le.default.get("".concat(this.appURL, "/api/method/frappe.client.get_count"), {
|
|
1248
|
+
params: n,
|
|
1249
|
+
headers: i,
|
|
1250
1250
|
withCredentials: !0
|
|
1251
1251
|
}).then(function(d) {
|
|
1252
1252
|
return d.data.message;
|
|
1253
1253
|
}).catch(function(d) {
|
|
1254
|
-
var
|
|
1254
|
+
var s, f;
|
|
1255
1255
|
throw {
|
|
1256
1256
|
httpStatus: d.response.status,
|
|
1257
1257
|
httpStatusText: d.response.statusText,
|
|
1258
1258
|
message: "There was an error while getting the count.",
|
|
1259
|
-
exception: (
|
|
1259
|
+
exception: (f = (s = d.response.data.exception) !== null && s !== void 0 ? s : d.response.data.exc_type) !== null && f !== void 0 ? f : ""
|
|
1260
1260
|
};
|
|
1261
1261
|
})];
|
|
1262
1262
|
});
|
|
1263
1263
|
});
|
|
1264
|
-
},
|
|
1265
|
-
return
|
|
1266
|
-
var
|
|
1267
|
-
return
|
|
1268
|
-
switch (
|
|
1264
|
+
}, e.prototype.getLastDoc = function(r, t) {
|
|
1265
|
+
return Te(this, void 0, void 0, function() {
|
|
1266
|
+
var o, a;
|
|
1267
|
+
return Ce(this, function(n) {
|
|
1268
|
+
switch (n.label) {
|
|
1269
1269
|
case 0:
|
|
1270
|
-
return
|
|
1270
|
+
return o = {
|
|
1271
1271
|
orderBy: {
|
|
1272
1272
|
field: "creation",
|
|
1273
1273
|
order: "desc"
|
|
1274
1274
|
}
|
|
1275
|
-
},
|
|
1275
|
+
}, t && (o = we(we({}, o), t)), [4, this.getDocList(r, we(we({}, o), { limit: 1 }))];
|
|
1276
1276
|
case 1:
|
|
1277
|
-
return a =
|
|
1277
|
+
return a = n.sent(), a.length > 0 ? [2, this.getDoc(r, a[0].name)] : [2, {}];
|
|
1278
1278
|
}
|
|
1279
1279
|
});
|
|
1280
1280
|
});
|
|
1281
|
-
},
|
|
1281
|
+
}, e;
|
|
1282
1282
|
}();
|
|
1283
|
-
Ke.FrappeDB =
|
|
1284
|
-
var Qe = {},
|
|
1285
|
-
function a(
|
|
1286
|
-
return
|
|
1287
|
-
|
|
1283
|
+
Ke.FrappeDB = Ma;
|
|
1284
|
+
var Qe = {}, Wa = j && j.__awaiter || function(e, r, t, o) {
|
|
1285
|
+
function a(n) {
|
|
1286
|
+
return n instanceof t ? n : new t(function(i) {
|
|
1287
|
+
i(n);
|
|
1288
1288
|
});
|
|
1289
1289
|
}
|
|
1290
|
-
return new (
|
|
1291
|
-
function c(
|
|
1290
|
+
return new (t || (t = Promise))(function(n, i) {
|
|
1291
|
+
function c(f) {
|
|
1292
1292
|
try {
|
|
1293
|
-
o
|
|
1294
|
-
} catch (
|
|
1295
|
-
|
|
1293
|
+
s(o.next(f));
|
|
1294
|
+
} catch (l) {
|
|
1295
|
+
i(l);
|
|
1296
1296
|
}
|
|
1297
1297
|
}
|
|
1298
|
-
function d(
|
|
1298
|
+
function d(f) {
|
|
1299
1299
|
try {
|
|
1300
|
-
o
|
|
1301
|
-
} catch (
|
|
1302
|
-
|
|
1300
|
+
s(o.throw(f));
|
|
1301
|
+
} catch (l) {
|
|
1302
|
+
i(l);
|
|
1303
1303
|
}
|
|
1304
1304
|
}
|
|
1305
|
-
function
|
|
1306
|
-
|
|
1305
|
+
function s(f) {
|
|
1306
|
+
f.done ? n(f.value) : a(f.value).then(c, d);
|
|
1307
1307
|
}
|
|
1308
|
-
|
|
1308
|
+
s((o = o.apply(e, r || [])).next());
|
|
1309
1309
|
});
|
|
1310
|
-
},
|
|
1311
|
-
var
|
|
1312
|
-
if (
|
|
1313
|
-
throw
|
|
1314
|
-
return
|
|
1315
|
-
}, trys: [], ops: [] },
|
|
1316
|
-
return
|
|
1310
|
+
}, Xa = j && j.__generator || function(e, r) {
|
|
1311
|
+
var t = { label: 0, sent: function() {
|
|
1312
|
+
if (n[0] & 1)
|
|
1313
|
+
throw n[1];
|
|
1314
|
+
return n[1];
|
|
1315
|
+
}, trys: [], ops: [] }, o, a, n, i;
|
|
1316
|
+
return i = { next: c(0), throw: c(1), return: c(2) }, typeof Symbol == "function" && (i[Symbol.iterator] = function() {
|
|
1317
1317
|
return this;
|
|
1318
|
-
}),
|
|
1319
|
-
function c(
|
|
1320
|
-
return function(
|
|
1321
|
-
return d([
|
|
1318
|
+
}), i;
|
|
1319
|
+
function c(s) {
|
|
1320
|
+
return function(f) {
|
|
1321
|
+
return d([s, f]);
|
|
1322
1322
|
};
|
|
1323
1323
|
}
|
|
1324
|
-
function d(
|
|
1325
|
-
if (
|
|
1324
|
+
function d(s) {
|
|
1325
|
+
if (o)
|
|
1326
1326
|
throw new TypeError("Generator is already executing.");
|
|
1327
|
-
for (;
|
|
1327
|
+
for (; t; )
|
|
1328
1328
|
try {
|
|
1329
|
-
if (
|
|
1330
|
-
return
|
|
1331
|
-
switch (a = 0,
|
|
1329
|
+
if (o = 1, a && (n = s[0] & 2 ? a.return : s[0] ? a.throw || ((n = a.return) && n.call(a), 0) : a.next) && !(n = n.call(a, s[1])).done)
|
|
1330
|
+
return n;
|
|
1331
|
+
switch (a = 0, n && (s = [s[0] & 2, n.value]), s[0]) {
|
|
1332
1332
|
case 0:
|
|
1333
1333
|
case 1:
|
|
1334
|
-
|
|
1334
|
+
n = s;
|
|
1335
1335
|
break;
|
|
1336
1336
|
case 4:
|
|
1337
|
-
return
|
|
1337
|
+
return t.label++, { value: s[1], done: !1 };
|
|
1338
1338
|
case 5:
|
|
1339
|
-
|
|
1339
|
+
t.label++, a = s[1], s = [0];
|
|
1340
1340
|
continue;
|
|
1341
1341
|
case 7:
|
|
1342
|
-
|
|
1342
|
+
s = t.ops.pop(), t.trys.pop();
|
|
1343
1343
|
continue;
|
|
1344
1344
|
default:
|
|
1345
|
-
if (
|
|
1346
|
-
|
|
1345
|
+
if (n = t.trys, !(n = n.length > 0 && n[n.length - 1]) && (s[0] === 6 || s[0] === 2)) {
|
|
1346
|
+
t = 0;
|
|
1347
1347
|
continue;
|
|
1348
1348
|
}
|
|
1349
|
-
if (
|
|
1350
|
-
|
|
1349
|
+
if (s[0] === 3 && (!n || s[1] > n[0] && s[1] < n[3])) {
|
|
1350
|
+
t.label = s[1];
|
|
1351
1351
|
break;
|
|
1352
1352
|
}
|
|
1353
|
-
if (
|
|
1354
|
-
|
|
1353
|
+
if (s[0] === 6 && t.label < n[1]) {
|
|
1354
|
+
t.label = n[1], n = s;
|
|
1355
1355
|
break;
|
|
1356
1356
|
}
|
|
1357
|
-
if (
|
|
1358
|
-
|
|
1357
|
+
if (n && t.label < n[2]) {
|
|
1358
|
+
t.label = n[2], t.ops.push(s);
|
|
1359
1359
|
break;
|
|
1360
1360
|
}
|
|
1361
|
-
|
|
1361
|
+
n[2] && t.ops.pop(), t.trys.pop();
|
|
1362
1362
|
continue;
|
|
1363
1363
|
}
|
|
1364
|
-
|
|
1365
|
-
} catch (
|
|
1366
|
-
|
|
1364
|
+
s = r.call(e, t);
|
|
1365
|
+
} catch (f) {
|
|
1366
|
+
s = [6, f], a = 0;
|
|
1367
1367
|
} finally {
|
|
1368
|
-
|
|
1368
|
+
o = n = 0;
|
|
1369
1369
|
}
|
|
1370
|
-
if (
|
|
1371
|
-
throw
|
|
1372
|
-
return { value:
|
|
1370
|
+
if (s[0] & 5)
|
|
1371
|
+
throw s[1];
|
|
1372
|
+
return { value: s[0] ? s[1] : void 0, done: !0 };
|
|
1373
1373
|
}
|
|
1374
1374
|
};
|
|
1375
1375
|
Object.defineProperty(Qe, "__esModule", { value: !0 });
|
|
1376
1376
|
Qe.FrappeFileUpload = void 0;
|
|
1377
|
-
var
|
|
1378
|
-
function
|
|
1379
|
-
this.appURL =
|
|
1377
|
+
var Ha = Ge.exports, Ja = function() {
|
|
1378
|
+
function e(r) {
|
|
1379
|
+
this.appURL = r;
|
|
1380
1380
|
}
|
|
1381
|
-
return
|
|
1382
|
-
return
|
|
1383
|
-
var a,
|
|
1384
|
-
return
|
|
1385
|
-
return a = new FormData(),
|
|
1381
|
+
return e.prototype.uploadFile = function(r, t, o) {
|
|
1382
|
+
return Wa(this, void 0, void 0, function() {
|
|
1383
|
+
var a, n, i, c, d, s, f, l;
|
|
1384
|
+
return Xa(this, function(_) {
|
|
1385
|
+
return a = new FormData(), r && a.append("file", r, r.name), n = t.isPrivate, i = t.folder, c = t.file_url, d = t.doctype, s = t.docname, f = t.fieldname, n && a.append("is_private", "1"), i && a.append("folder", i), c && a.append("file_url", c), d && s && (a.append("doctype", d), a.append("docname", s), f && a.append("fieldname", f)), l = {
|
|
1386
1386
|
Accept: "application/json",
|
|
1387
1387
|
"Content-Type": "application/json; charset=utf-8",
|
|
1388
1388
|
"X-Frappe-Site-Name": window.location.hostname
|
|
1389
|
-
}, window.csrf_token && window.csrf_token !== "{{ csrf_token }}" && (
|
|
1390
|
-
headers:
|
|
1391
|
-
onUploadProgress: function(
|
|
1392
|
-
|
|
1389
|
+
}, window.csrf_token && window.csrf_token !== "{{ csrf_token }}" && (l["X-Frappe-CSRF-Token"] = window.csrf_token), [2, Ha.default.post("".concat(this.appURL, "/api/method/upload_file"), a, {
|
|
1390
|
+
headers: l,
|
|
1391
|
+
onUploadProgress: function(h) {
|
|
1392
|
+
o && o(h.loaded, h.total);
|
|
1393
1393
|
}
|
|
1394
|
-
}).catch(function(
|
|
1395
|
-
var
|
|
1394
|
+
}).catch(function(h) {
|
|
1395
|
+
var b, w;
|
|
1396
1396
|
throw {
|
|
1397
|
-
httpStatus:
|
|
1398
|
-
httpStatusText:
|
|
1399
|
-
message: (
|
|
1400
|
-
exception: (
|
|
1397
|
+
httpStatus: h.response.status,
|
|
1398
|
+
httpStatusText: h.response.statusText,
|
|
1399
|
+
message: (b = h.response.data.message) !== null && b !== void 0 ? b : "There was an error while uploading the file.",
|
|
1400
|
+
exception: (w = h.response.data.exception) !== null && w !== void 0 ? w : ""
|
|
1401
1401
|
};
|
|
1402
1402
|
})];
|
|
1403
1403
|
});
|
|
1404
1404
|
});
|
|
1405
|
-
},
|
|
1405
|
+
}, e;
|
|
1406
1406
|
}();
|
|
1407
|
-
Qe.FrappeFileUpload =
|
|
1408
|
-
var
|
|
1409
|
-
function
|
|
1410
|
-
if (
|
|
1411
|
-
return
|
|
1412
|
-
|
|
1413
|
-
var
|
|
1414
|
-
function
|
|
1415
|
-
this.url =
|
|
1416
|
-
}
|
|
1417
|
-
return
|
|
1418
|
-
return new
|
|
1419
|
-
},
|
|
1420
|
-
return new
|
|
1421
|
-
},
|
|
1422
|
-
return new
|
|
1423
|
-
},
|
|
1424
|
-
return new
|
|
1425
|
-
},
|
|
1407
|
+
Qe.FrappeFileUpload = Ja;
|
|
1408
|
+
var Mn;
|
|
1409
|
+
function Ya() {
|
|
1410
|
+
if (Mn)
|
|
1411
|
+
return Me;
|
|
1412
|
+
Mn = 1, Object.defineProperty(Me, "__esModule", { value: !0 }), Me.FrappeApp = void 0;
|
|
1413
|
+
var e = mr(), r = Ye, t = Ke, o = Qe, a = function() {
|
|
1414
|
+
function n(i, c) {
|
|
1415
|
+
this.url = i, this.name = c != null ? c : "FrappeApp";
|
|
1416
|
+
}
|
|
1417
|
+
return n.prototype.auth = function() {
|
|
1418
|
+
return new e.FrappeAuth(this.url);
|
|
1419
|
+
}, n.prototype.db = function() {
|
|
1420
|
+
return new t.FrappeDB(this.url);
|
|
1421
|
+
}, n.prototype.file = function() {
|
|
1422
|
+
return new o.FrappeFileUpload(this.url);
|
|
1423
|
+
}, n.prototype.call = function() {
|
|
1424
|
+
return new r.FrappeCall(this.url);
|
|
1425
|
+
}, n;
|
|
1426
1426
|
}();
|
|
1427
|
-
return
|
|
1427
|
+
return Me.FrappeApp = a, Me;
|
|
1428
1428
|
}
|
|
1429
|
-
var
|
|
1430
|
-
function a(
|
|
1431
|
-
return
|
|
1432
|
-
|
|
1429
|
+
var ht = {}, rt = j && j.__awaiter || function(e, r, t, o) {
|
|
1430
|
+
function a(n) {
|
|
1431
|
+
return n instanceof t ? n : new t(function(i) {
|
|
1432
|
+
i(n);
|
|
1433
1433
|
});
|
|
1434
1434
|
}
|
|
1435
|
-
return new (
|
|
1436
|
-
function c(
|
|
1435
|
+
return new (t || (t = Promise))(function(n, i) {
|
|
1436
|
+
function c(f) {
|
|
1437
1437
|
try {
|
|
1438
|
-
o
|
|
1439
|
-
} catch (
|
|
1440
|
-
|
|
1438
|
+
s(o.next(f));
|
|
1439
|
+
} catch (l) {
|
|
1440
|
+
i(l);
|
|
1441
1441
|
}
|
|
1442
1442
|
}
|
|
1443
|
-
function d(
|
|
1443
|
+
function d(f) {
|
|
1444
1444
|
try {
|
|
1445
|
-
o
|
|
1446
|
-
} catch (
|
|
1447
|
-
|
|
1445
|
+
s(o.throw(f));
|
|
1446
|
+
} catch (l) {
|
|
1447
|
+
i(l);
|
|
1448
1448
|
}
|
|
1449
1449
|
}
|
|
1450
|
-
function
|
|
1451
|
-
|
|
1450
|
+
function s(f) {
|
|
1451
|
+
f.done ? n(f.value) : a(f.value).then(c, d);
|
|
1452
1452
|
}
|
|
1453
|
-
|
|
1453
|
+
s((o = o.apply(e, r || [])).next());
|
|
1454
1454
|
});
|
|
1455
|
-
},
|
|
1456
|
-
var
|
|
1457
|
-
if (
|
|
1458
|
-
throw
|
|
1459
|
-
return
|
|
1460
|
-
}, trys: [], ops: [] },
|
|
1461
|
-
return
|
|
1455
|
+
}, at = j && j.__generator || function(e, r) {
|
|
1456
|
+
var t = { label: 0, sent: function() {
|
|
1457
|
+
if (n[0] & 1)
|
|
1458
|
+
throw n[1];
|
|
1459
|
+
return n[1];
|
|
1460
|
+
}, trys: [], ops: [] }, o, a, n, i;
|
|
1461
|
+
return i = { next: c(0), throw: c(1), return: c(2) }, typeof Symbol == "function" && (i[Symbol.iterator] = function() {
|
|
1462
1462
|
return this;
|
|
1463
|
-
}),
|
|
1464
|
-
function c(
|
|
1465
|
-
return function(
|
|
1466
|
-
return d([
|
|
1463
|
+
}), i;
|
|
1464
|
+
function c(s) {
|
|
1465
|
+
return function(f) {
|
|
1466
|
+
return d([s, f]);
|
|
1467
1467
|
};
|
|
1468
1468
|
}
|
|
1469
|
-
function d(
|
|
1470
|
-
if (
|
|
1469
|
+
function d(s) {
|
|
1470
|
+
if (o)
|
|
1471
1471
|
throw new TypeError("Generator is already executing.");
|
|
1472
|
-
for (;
|
|
1472
|
+
for (; t; )
|
|
1473
1473
|
try {
|
|
1474
|
-
if (
|
|
1475
|
-
return
|
|
1476
|
-
switch (a = 0,
|
|
1474
|
+
if (o = 1, a && (n = s[0] & 2 ? a.return : s[0] ? a.throw || ((n = a.return) && n.call(a), 0) : a.next) && !(n = n.call(a, s[1])).done)
|
|
1475
|
+
return n;
|
|
1476
|
+
switch (a = 0, n && (s = [s[0] & 2, n.value]), s[0]) {
|
|
1477
1477
|
case 0:
|
|
1478
1478
|
case 1:
|
|
1479
|
-
|
|
1479
|
+
n = s;
|
|
1480
1480
|
break;
|
|
1481
1481
|
case 4:
|
|
1482
|
-
return
|
|
1482
|
+
return t.label++, { value: s[1], done: !1 };
|
|
1483
1483
|
case 5:
|
|
1484
|
-
|
|
1484
|
+
t.label++, a = s[1], s = [0];
|
|
1485
1485
|
continue;
|
|
1486
1486
|
case 7:
|
|
1487
|
-
|
|
1487
|
+
s = t.ops.pop(), t.trys.pop();
|
|
1488
1488
|
continue;
|
|
1489
1489
|
default:
|
|
1490
|
-
if (
|
|
1491
|
-
|
|
1490
|
+
if (n = t.trys, !(n = n.length > 0 && n[n.length - 1]) && (s[0] === 6 || s[0] === 2)) {
|
|
1491
|
+
t = 0;
|
|
1492
1492
|
continue;
|
|
1493
1493
|
}
|
|
1494
|
-
if (
|
|
1495
|
-
|
|
1494
|
+
if (s[0] === 3 && (!n || s[1] > n[0] && s[1] < n[3])) {
|
|
1495
|
+
t.label = s[1];
|
|
1496
1496
|
break;
|
|
1497
1497
|
}
|
|
1498
|
-
if (
|
|
1499
|
-
|
|
1498
|
+
if (s[0] === 6 && t.label < n[1]) {
|
|
1499
|
+
t.label = n[1], n = s;
|
|
1500
1500
|
break;
|
|
1501
1501
|
}
|
|
1502
|
-
if (
|
|
1503
|
-
|
|
1502
|
+
if (n && t.label < n[2]) {
|
|
1503
|
+
t.label = n[2], t.ops.push(s);
|
|
1504
1504
|
break;
|
|
1505
1505
|
}
|
|
1506
|
-
|
|
1506
|
+
n[2] && t.ops.pop(), t.trys.pop();
|
|
1507
1507
|
continue;
|
|
1508
1508
|
}
|
|
1509
|
-
|
|
1510
|
-
} catch (
|
|
1511
|
-
|
|
1509
|
+
s = r.call(e, t);
|
|
1510
|
+
} catch (f) {
|
|
1511
|
+
s = [6, f], a = 0;
|
|
1512
1512
|
} finally {
|
|
1513
|
-
|
|
1513
|
+
o = n = 0;
|
|
1514
1514
|
}
|
|
1515
|
-
if (
|
|
1516
|
-
throw
|
|
1517
|
-
return { value:
|
|
1515
|
+
if (s[0] & 5)
|
|
1516
|
+
throw s[1];
|
|
1517
|
+
return { value: s[0] ? s[1] : void 0, done: !0 };
|
|
1518
1518
|
}
|
|
1519
1519
|
};
|
|
1520
|
-
Object.defineProperty(
|
|
1521
|
-
|
|
1522
|
-
var ot = Ge.exports,
|
|
1523
|
-
function
|
|
1524
|
-
this.appURL =
|
|
1520
|
+
Object.defineProperty(ht, "__esModule", { value: !0 });
|
|
1521
|
+
ht.FrappeAuth = void 0;
|
|
1522
|
+
var ot = Ge.exports, Ga = function() {
|
|
1523
|
+
function e(r) {
|
|
1524
|
+
this.appURL = r;
|
|
1525
1525
|
}
|
|
1526
|
-
return
|
|
1527
|
-
return
|
|
1528
|
-
var
|
|
1529
|
-
return
|
|
1530
|
-
return
|
|
1526
|
+
return e.prototype.loginWithUsernamePassword = function(r) {
|
|
1527
|
+
return rt(this, void 0, void 0, function() {
|
|
1528
|
+
var t, o, a, n;
|
|
1529
|
+
return at(this, function(i) {
|
|
1530
|
+
return t = r.username, o = r.password, a = r.device, n = {
|
|
1531
1531
|
Accept: "application/json",
|
|
1532
1532
|
"Content-Type": "application/json; charset=utf-8",
|
|
1533
1533
|
"X-Frappe-Site-Name": window.location.hostname
|
|
1534
|
-
}, window.csrf_token && window.csrf_token !== "{{ csrf_token }}" && (
|
|
1535
|
-
usr:
|
|
1536
|
-
pwd:
|
|
1534
|
+
}, window.csrf_token && window.csrf_token !== "{{ csrf_token }}" && (n["X-Frappe-CSRF-Token"] = window.csrf_token), [2, ot.default.post("".concat(this.appURL, "/api/method/login"), {
|
|
1535
|
+
usr: t,
|
|
1536
|
+
pwd: o,
|
|
1537
|
+
device: a
|
|
1537
1538
|
}, {
|
|
1538
|
-
headers:
|
|
1539
|
+
headers: n,
|
|
1539
1540
|
withCredentials: !0
|
|
1540
|
-
}).then(function(
|
|
1541
|
-
return
|
|
1542
|
-
}).catch(function(
|
|
1543
|
-
var
|
|
1541
|
+
}).then(function(c) {
|
|
1542
|
+
return c.data;
|
|
1543
|
+
}).catch(function(c) {
|
|
1544
|
+
var d, s;
|
|
1544
1545
|
throw {
|
|
1545
|
-
httpStatus:
|
|
1546
|
-
httpStatusText:
|
|
1547
|
-
message: (
|
|
1548
|
-
exception: (
|
|
1546
|
+
httpStatus: c.response.status,
|
|
1547
|
+
httpStatusText: c.response.statusText,
|
|
1548
|
+
message: (d = c.response.data.message) !== null && d !== void 0 ? d : "There was an error while logging in",
|
|
1549
|
+
exception: (s = c.response.data.exception) !== null && s !== void 0 ? s : ""
|
|
1549
1550
|
};
|
|
1550
1551
|
})];
|
|
1551
1552
|
});
|
|
1552
1553
|
});
|
|
1553
|
-
},
|
|
1554
|
-
return
|
|
1555
|
-
var
|
|
1556
|
-
return
|
|
1557
|
-
return
|
|
1554
|
+
}, e.prototype.getLoggedInUser = function() {
|
|
1555
|
+
return rt(this, void 0, void 0, function() {
|
|
1556
|
+
var r;
|
|
1557
|
+
return at(this, function(t) {
|
|
1558
|
+
return r = {
|
|
1558
1559
|
Accept: "application/json",
|
|
1559
1560
|
"Content-Type": "application/json; charset=utf-8",
|
|
1560
1561
|
"X-Frappe-Site-Name": window.location.hostname
|
|
1561
|
-
}, window.csrf_token && window.csrf_token !== "{{ csrf_token }}" && (
|
|
1562
|
-
headers:
|
|
1562
|
+
}, window.csrf_token && window.csrf_token !== "{{ csrf_token }}" && (r["X-Frappe-CSRF-Token"] = window.csrf_token), [2, ot.default.get("".concat(this.appURL, "/api/method/frappe.auth.get_logged_user"), {
|
|
1563
|
+
headers: r,
|
|
1563
1564
|
withCredentials: !0
|
|
1564
|
-
}).then(function(
|
|
1565
|
-
return
|
|
1566
|
-
}).catch(function(
|
|
1565
|
+
}).then(function(o) {
|
|
1566
|
+
return o.data.message;
|
|
1567
|
+
}).catch(function(o) {
|
|
1567
1568
|
var a;
|
|
1568
1569
|
throw {
|
|
1569
|
-
httpStatus:
|
|
1570
|
-
httpStatusText:
|
|
1570
|
+
httpStatus: o.response.status,
|
|
1571
|
+
httpStatusText: o.response.statusText,
|
|
1571
1572
|
message: "There was an error while fetching the logged in user",
|
|
1572
|
-
exception: (a =
|
|
1573
|
+
exception: (a = o.response.data.exception) !== null && a !== void 0 ? a : ""
|
|
1573
1574
|
};
|
|
1574
1575
|
})];
|
|
1575
1576
|
});
|
|
1576
1577
|
});
|
|
1577
|
-
},
|
|
1578
|
-
return
|
|
1579
|
-
var
|
|
1580
|
-
return
|
|
1581
|
-
return
|
|
1578
|
+
}, e.prototype.logout = function() {
|
|
1579
|
+
return rt(this, void 0, void 0, function() {
|
|
1580
|
+
var r;
|
|
1581
|
+
return at(this, function(t) {
|
|
1582
|
+
return r = {
|
|
1582
1583
|
Accept: "application/json",
|
|
1583
1584
|
"Content-Type": "application/json; charset=utf-8",
|
|
1584
1585
|
"X-Frappe-Site-Name": window.location.hostname
|
|
1585
|
-
}, window.csrf_token && window.csrf_token !== "{{ csrf_token }}" && (
|
|
1586
|
-
headers:
|
|
1586
|
+
}, window.csrf_token && window.csrf_token !== "{{ csrf_token }}" && (r["X-Frappe-CSRF-Token"] = window.csrf_token), [2, ot.default.post("".concat(this.appURL, "/api/method/logout"), {}, {
|
|
1587
|
+
headers: r,
|
|
1587
1588
|
withCredentials: !0
|
|
1588
1589
|
}).then(function() {
|
|
1589
|
-
}).catch(function(
|
|
1590
|
-
var a,
|
|
1590
|
+
}).catch(function(o) {
|
|
1591
|
+
var a, n;
|
|
1591
1592
|
throw {
|
|
1592
|
-
httpStatus:
|
|
1593
|
-
httpStatusText:
|
|
1594
|
-
message: (a =
|
|
1595
|
-
exception: (
|
|
1593
|
+
httpStatus: o.response.status,
|
|
1594
|
+
httpStatusText: o.response.statusText,
|
|
1595
|
+
message: (a = o.response.data.message) !== null && a !== void 0 ? a : "There was an error while logging out",
|
|
1596
|
+
exception: (n = o.response.data.exception) !== null && n !== void 0 ? n : ""
|
|
1596
1597
|
};
|
|
1597
1598
|
})];
|
|
1598
1599
|
});
|
|
1599
1600
|
});
|
|
1600
|
-
},
|
|
1601
|
-
return
|
|
1602
|
-
var
|
|
1603
|
-
return
|
|
1604
|
-
return
|
|
1601
|
+
}, e.prototype.forgetPassword = function(r) {
|
|
1602
|
+
return rt(this, void 0, void 0, function() {
|
|
1603
|
+
var t;
|
|
1604
|
+
return at(this, function(o) {
|
|
1605
|
+
return t = {
|
|
1605
1606
|
Accept: "application/json",
|
|
1606
1607
|
"Content-Type": "application/json; charset=utf-8",
|
|
1607
1608
|
"X-Frappe-Site-Name": window.location.hostname
|
|
1608
|
-
}, window.csrf_token && window.csrf_token !== "{{ csrf_token }}" && (
|
|
1609
|
+
}, window.csrf_token && window.csrf_token !== "{{ csrf_token }}" && (t["X-Frappe-CSRF-Token"] = window.csrf_token), [2, ot.default.post("".concat(this.appURL), {
|
|
1609
1610
|
cmd: "frappe.core.doctype.user.user.reset_password",
|
|
1610
|
-
user:
|
|
1611
|
+
user: r
|
|
1611
1612
|
}, {
|
|
1612
|
-
headers:
|
|
1613
|
+
headers: t,
|
|
1613
1614
|
withCredentials: !0
|
|
1614
1615
|
}).then(function() {
|
|
1615
1616
|
}).catch(function(a) {
|
|
1616
|
-
var
|
|
1617
|
+
var n, i;
|
|
1617
1618
|
throw {
|
|
1618
1619
|
httpStatus: a.response.status,
|
|
1619
1620
|
httpStatusText: a.response.statusText,
|
|
1620
|
-
message: (
|
|
1621
|
-
exception: (
|
|
1621
|
+
message: (n = a.response.data.message) !== null && n !== void 0 ? n : "There was an error sending password reset email.",
|
|
1622
|
+
exception: (i = a.response.data.exception) !== null && i !== void 0 ? i : ""
|
|
1622
1623
|
};
|
|
1623
1624
|
})];
|
|
1624
1625
|
});
|
|
1625
1626
|
});
|
|
1626
|
-
},
|
|
1627
|
+
}, e;
|
|
1627
1628
|
}();
|
|
1628
|
-
|
|
1629
|
-
var
|
|
1630
|
-
function
|
|
1631
|
-
return
|
|
1632
|
-
var
|
|
1633
|
-
|
|
1634
|
-
var c = Object.getOwnPropertyDescriptor(a,
|
|
1629
|
+
ht.FrappeAuth = Ga;
|
|
1630
|
+
var Wn;
|
|
1631
|
+
function mr() {
|
|
1632
|
+
return Wn || (Wn = 1, function(e) {
|
|
1633
|
+
var r = j && j.__createBinding || (Object.create ? function(o, a, n, i) {
|
|
1634
|
+
i === void 0 && (i = n);
|
|
1635
|
+
var c = Object.getOwnPropertyDescriptor(a, n);
|
|
1635
1636
|
(!c || ("get" in c ? !a.__esModule : c.writable || c.configurable)) && (c = { enumerable: !0, get: function() {
|
|
1636
|
-
return a[
|
|
1637
|
-
} }), Object.defineProperty(
|
|
1638
|
-
} : function(
|
|
1639
|
-
|
|
1640
|
-
}),
|
|
1641
|
-
for (var
|
|
1642
|
-
|
|
1637
|
+
return a[n];
|
|
1638
|
+
} }), Object.defineProperty(o, i, c);
|
|
1639
|
+
} : function(o, a, n, i) {
|
|
1640
|
+
i === void 0 && (i = n), o[i] = a[n];
|
|
1641
|
+
}), t = j && j.__exportStar || function(o, a) {
|
|
1642
|
+
for (var n in o)
|
|
1643
|
+
n !== "default" && !Object.prototype.hasOwnProperty.call(a, n) && r(a, o, n);
|
|
1643
1644
|
};
|
|
1644
|
-
Object.defineProperty(
|
|
1645
|
-
}(
|
|
1645
|
+
Object.defineProperty(e, "__esModule", { value: !0 }), t(Ya(), e), t(ht, e), t(Ke, e), t(Qe, e), t(Ye, e);
|
|
1646
|
+
}(St)), St;
|
|
1646
1647
|
}
|
|
1647
|
-
var
|
|
1648
|
-
|
|
1649
|
-
|
|
1650
|
-
|
|
1651
|
-
|
|
1652
|
-
|
|
1653
|
-
|
|
1654
|
-
|
|
1655
|
-
|
|
1656
|
-
|
|
1657
|
-
|
|
1658
|
-
|
|
1659
|
-
|
|
1660
|
-
|
|
1661
|
-
|
|
1662
|
-
|
|
1663
|
-
function
|
|
1664
|
-
return
|
|
1665
|
-
s(r);
|
|
1666
|
-
});
|
|
1648
|
+
var za = mr(), wr = { exports: {} }, $t = {};
|
|
1649
|
+
/**
|
|
1650
|
+
* @license React
|
|
1651
|
+
* use-sync-external-store-shim.production.min.js
|
|
1652
|
+
*
|
|
1653
|
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
1654
|
+
*
|
|
1655
|
+
* This source code is licensed under the MIT license found in the
|
|
1656
|
+
* LICENSE file in the root directory of this source tree.
|
|
1657
|
+
*/
|
|
1658
|
+
var Xn;
|
|
1659
|
+
function Ka() {
|
|
1660
|
+
if (Xn)
|
|
1661
|
+
return $t;
|
|
1662
|
+
Xn = 1;
|
|
1663
|
+
var e = je;
|
|
1664
|
+
function r(l, _) {
|
|
1665
|
+
return l === _ && (l !== 0 || 1 / l === 1 / _) || l !== l && _ !== _;
|
|
1667
1666
|
}
|
|
1668
|
-
|
|
1669
|
-
|
|
1670
|
-
|
|
1671
|
-
|
|
1672
|
-
|
|
1673
|
-
|
|
1667
|
+
var t = typeof Object.is == "function" ? Object.is : r, o = e.useState, a = e.useEffect, n = e.useLayoutEffect, i = e.useDebugValue;
|
|
1668
|
+
function c(l, _) {
|
|
1669
|
+
var h = _(), b = o({ inst: { value: h, getSnapshot: _ } }), w = b[0].inst, T = b[1];
|
|
1670
|
+
return n(function() {
|
|
1671
|
+
w.value = h, w.getSnapshot = _, d(w) && T({ inst: w });
|
|
1672
|
+
}, [l, h, _]), a(function() {
|
|
1673
|
+
return d(w) && T({ inst: w }), l(function() {
|
|
1674
|
+
d(w) && T({ inst: w });
|
|
1675
|
+
});
|
|
1676
|
+
}, [l]), i(h), h;
|
|
1677
|
+
}
|
|
1678
|
+
function d(l) {
|
|
1679
|
+
var _ = l.getSnapshot;
|
|
1680
|
+
l = l.value;
|
|
1681
|
+
try {
|
|
1682
|
+
var h = _();
|
|
1683
|
+
return !t(l, h);
|
|
1684
|
+
} catch {
|
|
1685
|
+
return !0;
|
|
1686
|
+
}
|
|
1687
|
+
}
|
|
1688
|
+
function s(l, _) {
|
|
1689
|
+
return _();
|
|
1690
|
+
}
|
|
1691
|
+
var f = typeof window > "u" || typeof window.document > "u" || typeof window.document.createElement > "u" ? s : c;
|
|
1692
|
+
return $t.useSyncExternalStore = e.useSyncExternalStore !== void 0 ? e.useSyncExternalStore : f, $t;
|
|
1693
|
+
}
|
|
1694
|
+
var Vt = {};
|
|
1695
|
+
/**
|
|
1696
|
+
* @license React
|
|
1697
|
+
* use-sync-external-store-shim.development.js
|
|
1698
|
+
*
|
|
1699
|
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
1700
|
+
*
|
|
1701
|
+
* This source code is licensed under the MIT license found in the
|
|
1702
|
+
* LICENSE file in the root directory of this source tree.
|
|
1703
|
+
*/
|
|
1704
|
+
var Hn;
|
|
1705
|
+
function Qa() {
|
|
1706
|
+
return Hn || (Hn = 1, process.env.NODE_ENV !== "production" && function() {
|
|
1707
|
+
typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ < "u" && typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart == "function" && __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(new Error());
|
|
1708
|
+
var e = je, r = e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;
|
|
1709
|
+
function t(O) {
|
|
1710
|
+
{
|
|
1711
|
+
for (var m = arguments.length, I = new Array(m > 1 ? m - 1 : 0), y = 1; y < m; y++)
|
|
1712
|
+
I[y - 1] = arguments[y];
|
|
1713
|
+
o("error", O, I);
|
|
1674
1714
|
}
|
|
1675
1715
|
}
|
|
1676
|
-
function
|
|
1677
|
-
|
|
1678
|
-
|
|
1679
|
-
|
|
1680
|
-
|
|
1716
|
+
function o(O, m, I) {
|
|
1717
|
+
{
|
|
1718
|
+
var y = r.ReactDebugCurrentFrame, A = y.getStackAddendum();
|
|
1719
|
+
A !== "" && (m += "%s", I = I.concat([A]));
|
|
1720
|
+
var M = I.map(function(P) {
|
|
1721
|
+
return String(P);
|
|
1722
|
+
});
|
|
1723
|
+
M.unshift("Warning: " + m), Function.prototype.apply.call(console[O], console, M);
|
|
1681
1724
|
}
|
|
1682
1725
|
}
|
|
1683
|
-
function
|
|
1684
|
-
|
|
1726
|
+
function a(O, m) {
|
|
1727
|
+
return O === m && (O !== 0 || 1 / O === 1 / m) || O !== O && m !== m;
|
|
1685
1728
|
}
|
|
1686
|
-
|
|
1687
|
-
|
|
1688
|
-
|
|
1689
|
-
|
|
1690
|
-
|
|
1691
|
-
|
|
1692
|
-
|
|
1693
|
-
|
|
1694
|
-
|
|
1695
|
-
|
|
1696
|
-
|
|
1697
|
-
|
|
1698
|
-
function c(o) {
|
|
1699
|
-
return function(l) {
|
|
1700
|
-
return d([o, l]);
|
|
1701
|
-
};
|
|
1702
|
-
}
|
|
1703
|
-
function d(o) {
|
|
1704
|
-
if (i)
|
|
1705
|
-
throw new TypeError("Generator is already executing.");
|
|
1706
|
-
for (; e; )
|
|
1707
|
-
try {
|
|
1708
|
-
if (i = 1, a && (r = o[0] & 2 ? a.return : o[0] ? a.throw || ((r = a.return) && r.call(a), 0) : a.next) && !(r = r.call(a, o[1])).done)
|
|
1709
|
-
return r;
|
|
1710
|
-
switch (a = 0, r && (o = [o[0] & 2, r.value]), o[0]) {
|
|
1711
|
-
case 0:
|
|
1712
|
-
case 1:
|
|
1713
|
-
r = o;
|
|
1714
|
-
break;
|
|
1715
|
-
case 4:
|
|
1716
|
-
return e.label++, { value: o[1], done: !1 };
|
|
1717
|
-
case 5:
|
|
1718
|
-
e.label++, a = o[1], o = [0];
|
|
1719
|
-
continue;
|
|
1720
|
-
case 7:
|
|
1721
|
-
o = e.ops.pop(), e.trys.pop();
|
|
1722
|
-
continue;
|
|
1723
|
-
default:
|
|
1724
|
-
if (r = e.trys, !(r = r.length > 0 && r[r.length - 1]) && (o[0] === 6 || o[0] === 2)) {
|
|
1725
|
-
e = 0;
|
|
1726
|
-
continue;
|
|
1727
|
-
}
|
|
1728
|
-
if (o[0] === 3 && (!r || o[1] > r[0] && o[1] < r[3])) {
|
|
1729
|
-
e.label = o[1];
|
|
1730
|
-
break;
|
|
1731
|
-
}
|
|
1732
|
-
if (o[0] === 6 && e.label < r[1]) {
|
|
1733
|
-
e.label = r[1], r = o;
|
|
1734
|
-
break;
|
|
1735
|
-
}
|
|
1736
|
-
if (r && e.label < r[2]) {
|
|
1737
|
-
e.label = r[2], e.ops.push(o);
|
|
1738
|
-
break;
|
|
1739
|
-
}
|
|
1740
|
-
r[2] && e.ops.pop(), e.trys.pop();
|
|
1741
|
-
continue;
|
|
1729
|
+
var n = typeof Object.is == "function" ? Object.is : a, i = e.useState, c = e.useEffect, d = e.useLayoutEffect, s = e.useDebugValue, f = !1, l = !1;
|
|
1730
|
+
function _(O, m, I) {
|
|
1731
|
+
f || e.startTransition !== void 0 && (f = !0, t("You are using an outdated, pre-release alpha of React 18 that does not support useSyncExternalStore. The use-sync-external-store shim will not work correctly. Upgrade to a newer pre-release."));
|
|
1732
|
+
var y = m();
|
|
1733
|
+
if (!l) {
|
|
1734
|
+
var A = m();
|
|
1735
|
+
n(y, A) || (t("The result of getSnapshot should be cached to avoid an infinite loop"), l = !0);
|
|
1736
|
+
}
|
|
1737
|
+
var M = i({
|
|
1738
|
+
inst: {
|
|
1739
|
+
value: y,
|
|
1740
|
+
getSnapshot: m
|
|
1742
1741
|
}
|
|
1743
|
-
|
|
1744
|
-
|
|
1745
|
-
|
|
1746
|
-
|
|
1747
|
-
|
|
1742
|
+
}), P = M[0].inst, N = M[1];
|
|
1743
|
+
return d(function() {
|
|
1744
|
+
P.value = y, P.getSnapshot = m, h(P) && N({
|
|
1745
|
+
inst: P
|
|
1746
|
+
});
|
|
1747
|
+
}, [O, y, m]), c(function() {
|
|
1748
|
+
h(P) && N({
|
|
1749
|
+
inst: P
|
|
1750
|
+
});
|
|
1751
|
+
var J = function() {
|
|
1752
|
+
h(P) && N({
|
|
1753
|
+
inst: P
|
|
1754
|
+
});
|
|
1755
|
+
};
|
|
1756
|
+
return O(J);
|
|
1757
|
+
}, [O]), s(y), y;
|
|
1758
|
+
}
|
|
1759
|
+
function h(O) {
|
|
1760
|
+
var m = O.getSnapshot, I = O.value;
|
|
1761
|
+
try {
|
|
1762
|
+
var y = m();
|
|
1763
|
+
return !n(I, y);
|
|
1764
|
+
} catch {
|
|
1765
|
+
return !0;
|
|
1748
1766
|
}
|
|
1749
|
-
|
|
1750
|
-
|
|
1751
|
-
|
|
1752
|
-
|
|
1767
|
+
}
|
|
1768
|
+
function b(O, m, I) {
|
|
1769
|
+
return m();
|
|
1770
|
+
}
|
|
1771
|
+
var w = typeof window < "u" && typeof window.document < "u" && typeof window.document.createElement < "u", T = !w, x = T ? b : _, S = e.useSyncExternalStore !== void 0 ? e.useSyncExternalStore : x;
|
|
1772
|
+
Vt.useSyncExternalStore = S, typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ < "u" && typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop == "function" && __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(new Error());
|
|
1773
|
+
}()), Vt;
|
|
1753
1774
|
}
|
|
1754
|
-
|
|
1755
|
-
|
|
1756
|
-
|
|
1757
|
-
},
|
|
1758
|
-
|
|
1759
|
-
|
|
1760
|
-
|
|
1761
|
-
},
|
|
1762
|
-
|
|
1763
|
-
|
|
1764
|
-
|
|
1765
|
-
|
|
1766
|
-
|
|
1767
|
-
|
|
1768
|
-
|
|
1769
|
-
|
|
1770
|
-
|
|
1775
|
+
(function(e) {
|
|
1776
|
+
process.env.NODE_ENV === "production" ? e.exports = Ka() : e.exports = Qa();
|
|
1777
|
+
})(wr);
|
|
1778
|
+
const he = /* @__PURE__ */ new WeakMap(), Jn = {}, _e = () => {
|
|
1779
|
+
}, ie = _e(), Bt = Object, U = (e) => e === ie, ve = (e) => typeof e == "function", ye = (e, r) => ({
|
|
1780
|
+
...e,
|
|
1781
|
+
...r
|
|
1782
|
+
}), on = "undefined", vt = typeof window != on, Gt = typeof document != on, Za = () => vt && typeof window.requestAnimationFrame != on, _r = (e, r) => {
|
|
1783
|
+
const t = he.get(e);
|
|
1784
|
+
return [
|
|
1785
|
+
() => e.get(r) || Jn,
|
|
1786
|
+
(o) => {
|
|
1787
|
+
const a = e.get(r);
|
|
1788
|
+
t[5](r, ye(a, o), a || Jn);
|
|
1789
|
+
},
|
|
1790
|
+
t[6]
|
|
1791
|
+
];
|
|
1792
|
+
}, it = /* @__PURE__ */ new WeakMap();
|
|
1793
|
+
let eo = 0;
|
|
1794
|
+
const He = (e) => {
|
|
1795
|
+
const r = typeof e, t = e && e.constructor, o = t == Date;
|
|
1796
|
+
let a, n;
|
|
1797
|
+
if (Bt(e) === e && !o && t != RegExp) {
|
|
1798
|
+
if (a = it.get(e), a)
|
|
1771
1799
|
return a;
|
|
1772
|
-
if (a = ++
|
|
1773
|
-
for (a = "@",
|
|
1774
|
-
a += He(
|
|
1775
|
-
|
|
1800
|
+
if (a = ++eo + "~", it.set(e, a), t == Array) {
|
|
1801
|
+
for (a = "@", n = 0; n < e.length; n++)
|
|
1802
|
+
a += He(e[n]) + ",";
|
|
1803
|
+
it.set(e, a);
|
|
1776
1804
|
}
|
|
1777
|
-
if (
|
|
1805
|
+
if (t == Bt) {
|
|
1778
1806
|
a = "#";
|
|
1779
|
-
|
|
1780
|
-
|
|
1781
|
-
|
|
1807
|
+
const i = Bt.keys(e).sort();
|
|
1808
|
+
for (; !U(n = i.pop()); )
|
|
1809
|
+
U(e[n]) || (a += n + ":" + He(e[n]) + ",");
|
|
1810
|
+
it.set(e, a);
|
|
1782
1811
|
}
|
|
1783
1812
|
} else
|
|
1784
|
-
a =
|
|
1813
|
+
a = o ? e.toJSON() : r == "symbol" ? e.toString() : r == "string" ? JSON.stringify(e) : "" + e;
|
|
1785
1814
|
return a;
|
|
1786
|
-
}
|
|
1787
|
-
|
|
1788
|
-
|
|
1789
|
-
|
|
1790
|
-
|
|
1791
|
-
|
|
1792
|
-
|
|
1793
|
-
|
|
1794
|
-
|
|
1795
|
-
|
|
1796
|
-
|
|
1797
|
-
|
|
1798
|
-
|
|
1799
|
-
|
|
1815
|
+
};
|
|
1816
|
+
let zt = !0;
|
|
1817
|
+
const to = () => zt, [Kt, Qt] = vt && window.addEventListener ? [
|
|
1818
|
+
window.addEventListener.bind(window),
|
|
1819
|
+
window.removeEventListener.bind(window)
|
|
1820
|
+
] : [
|
|
1821
|
+
_e,
|
|
1822
|
+
_e
|
|
1823
|
+
], no = () => {
|
|
1824
|
+
const e = Gt && document.visibilityState;
|
|
1825
|
+
return U(e) || e !== "hidden";
|
|
1826
|
+
}, ro = (e) => (Gt && document.addEventListener("visibilitychange", e), Kt("focus", e), () => {
|
|
1827
|
+
Gt && document.removeEventListener("visibilitychange", e), Qt("focus", e);
|
|
1828
|
+
}), ao = (e) => {
|
|
1829
|
+
const r = () => {
|
|
1830
|
+
zt = !0, e();
|
|
1831
|
+
}, t = () => {
|
|
1832
|
+
zt = !1;
|
|
1800
1833
|
};
|
|
1801
|
-
return
|
|
1802
|
-
|
|
1834
|
+
return Kt("online", r), Kt("offline", t), () => {
|
|
1835
|
+
Qt("online", r), Qt("offline", t);
|
|
1803
1836
|
};
|
|
1804
|
-
},
|
|
1805
|
-
isOnline:
|
|
1806
|
-
isVisible:
|
|
1807
|
-
},
|
|
1808
|
-
initFocus:
|
|
1809
|
-
initReconnect:
|
|
1810
|
-
},
|
|
1811
|
-
|
|
1812
|
-
|
|
1813
|
-
|
|
1837
|
+
}, oo = {
|
|
1838
|
+
isOnline: to,
|
|
1839
|
+
isVisible: no
|
|
1840
|
+
}, io = {
|
|
1841
|
+
initFocus: ro,
|
|
1842
|
+
initReconnect: ao
|
|
1843
|
+
}, Yn = !je.useId, Je = !vt || "Deno" in window, so = (e) => Za() ? window.requestAnimationFrame(e) : setTimeout(e, 1), Mt = Je ? er : Xr, Wt = typeof navigator < "u" && navigator.connection, Gn = !Je && Wt && ([
|
|
1844
|
+
"slow-2g",
|
|
1845
|
+
"2g"
|
|
1846
|
+
].includes(Wt.effectiveType) || Wt.saveData), sn = (e) => {
|
|
1847
|
+
if (ve(e))
|
|
1814
1848
|
try {
|
|
1815
|
-
|
|
1849
|
+
e = e();
|
|
1816
1850
|
} catch {
|
|
1817
|
-
|
|
1818
|
-
}
|
|
1819
|
-
|
|
1820
|
-
|
|
1821
|
-
|
|
1822
|
-
|
|
1823
|
-
|
|
1824
|
-
|
|
1825
|
-
|
|
1826
|
-
|
|
1827
|
-
|
|
1828
|
-
|
|
1829
|
-
|
|
1830
|
-
|
|
1831
|
-
|
|
1832
|
-
}
|
|
1833
|
-
|
|
1834
|
-
|
|
1835
|
-
|
|
1836
|
-
|
|
1837
|
-
|
|
1838
|
-
|
|
1839
|
-
|
|
1840
|
-
|
|
1841
|
-
|
|
1842
|
-
|
|
1843
|
-
|
|
1844
|
-
|
|
1845
|
-
|
|
1846
|
-
|
|
1847
|
-
|
|
1848
|
-
|
|
1849
|
-
|
|
1850
|
-
|
|
1851
|
-
|
|
1852
|
-
|
|
1853
|
-
|
|
1854
|
-
|
|
1855
|
-
|
|
1856
|
-
|
|
1857
|
-
|
|
1858
|
-
|
|
1859
|
-
|
|
1860
|
-
|
|
1861
|
-
|
|
1862
|
-
|
|
1863
|
-
|
|
1864
|
-
|
|
1865
|
-
|
|
1866
|
-
|
|
1867
|
-
|
|
1868
|
-
|
|
1869
|
-
|
|
1870
|
-
|
|
1871
|
-
|
|
1872
|
-
|
|
1873
|
-
|
|
1874
|
-
|
|
1851
|
+
e = "";
|
|
1852
|
+
}
|
|
1853
|
+
const r = e;
|
|
1854
|
+
return e = typeof e == "string" ? e : (Array.isArray(e) ? e.length : e) ? He(e) : "", [
|
|
1855
|
+
e,
|
|
1856
|
+
r
|
|
1857
|
+
];
|
|
1858
|
+
};
|
|
1859
|
+
let uo = 0;
|
|
1860
|
+
const Zt = () => ++uo, yr = 0, br = 1, Er = 2;
|
|
1861
|
+
var Xt = {
|
|
1862
|
+
__proto__: null,
|
|
1863
|
+
FOCUS_EVENT: yr,
|
|
1864
|
+
RECONNECT_EVENT: br,
|
|
1865
|
+
MUTATE_EVENT: Er
|
|
1866
|
+
};
|
|
1867
|
+
async function Sr(...e) {
|
|
1868
|
+
const [r, t, o, a] = e, n = ye({
|
|
1869
|
+
populateCache: !0,
|
|
1870
|
+
throwOnError: !0
|
|
1871
|
+
}, typeof a == "boolean" ? {
|
|
1872
|
+
revalidate: a
|
|
1873
|
+
} : a || {});
|
|
1874
|
+
let i = n.populateCache;
|
|
1875
|
+
const c = n.rollbackOnError;
|
|
1876
|
+
let d = n.optimisticData;
|
|
1877
|
+
const s = n.revalidate !== !1, f = (h) => typeof c == "function" ? c(h) : c !== !1, l = n.throwOnError;
|
|
1878
|
+
if (ve(t)) {
|
|
1879
|
+
const h = t, b = [], w = r.keys();
|
|
1880
|
+
for (let T = w.next(); !T.done; T = w.next()) {
|
|
1881
|
+
const x = T.value;
|
|
1882
|
+
!x.startsWith("$inf$") && h(r.get(x)._k) && b.push(x);
|
|
1883
|
+
}
|
|
1884
|
+
return Promise.all(b.map(_));
|
|
1885
|
+
}
|
|
1886
|
+
return _(t);
|
|
1887
|
+
async function _(h) {
|
|
1888
|
+
const [b] = sn(h);
|
|
1889
|
+
if (!b)
|
|
1890
|
+
return;
|
|
1891
|
+
const [w, T] = _r(r, b), [x, S, O] = he.get(r), m = x[b], I = () => s && (delete O[b], m && m[0]) ? m[0](Er).then(() => w().data) : w().data;
|
|
1892
|
+
if (e.length < 3)
|
|
1893
|
+
return I();
|
|
1894
|
+
let y = o, A;
|
|
1895
|
+
const M = Zt();
|
|
1896
|
+
S[b] = [
|
|
1897
|
+
M,
|
|
1898
|
+
0
|
|
1899
|
+
];
|
|
1900
|
+
const P = !U(d), N = w(), J = N.data, K = N._c, V = U(K) ? J : K;
|
|
1901
|
+
if (P && (d = ve(d) ? d(V) : d, T({
|
|
1902
|
+
data: d,
|
|
1903
|
+
_c: V
|
|
1904
|
+
})), ve(y))
|
|
1905
|
+
try {
|
|
1906
|
+
y = y(V);
|
|
1907
|
+
} catch (z) {
|
|
1908
|
+
A = z;
|
|
1875
1909
|
}
|
|
1876
|
-
|
|
1877
|
-
|
|
1878
|
-
|
|
1879
|
-
|
|
1880
|
-
|
|
1881
|
-
|
|
1882
|
-
|
|
1883
|
-
|
|
1884
|
-
|
|
1885
|
-
|
|
1886
|
-
|
|
1887
|
-
|
|
1888
|
-
|
|
1910
|
+
if (y && ve(y.then))
|
|
1911
|
+
if (y = await y.catch((z) => {
|
|
1912
|
+
A = z;
|
|
1913
|
+
}), M !== S[b][0]) {
|
|
1914
|
+
if (A)
|
|
1915
|
+
throw A;
|
|
1916
|
+
return y;
|
|
1917
|
+
} else
|
|
1918
|
+
A && P && f(A) && (i = !0, y = V, T({
|
|
1919
|
+
data: y,
|
|
1920
|
+
_c: ie
|
|
1921
|
+
}));
|
|
1922
|
+
i && (A || (ve(i) && (y = i(y, V)), T({
|
|
1923
|
+
data: y,
|
|
1924
|
+
_c: ie
|
|
1925
|
+
}))), S[b][1] = Zt();
|
|
1926
|
+
const G = await I();
|
|
1927
|
+
if (T({
|
|
1928
|
+
_c: ie
|
|
1929
|
+
}), A) {
|
|
1930
|
+
if (l)
|
|
1931
|
+
throw A;
|
|
1932
|
+
return;
|
|
1889
1933
|
}
|
|
1890
|
-
return
|
|
1934
|
+
return i ? G : y;
|
|
1935
|
+
}
|
|
1936
|
+
}
|
|
1937
|
+
const zn = (e, r) => {
|
|
1938
|
+
for (const t in e)
|
|
1939
|
+
e[t][0] && e[t][0](r);
|
|
1940
|
+
}, co = (e, r) => {
|
|
1941
|
+
if (!he.has(e)) {
|
|
1942
|
+
const t = ye(io, r), o = {}, a = Sr.bind(ie, e);
|
|
1943
|
+
let n = _e;
|
|
1944
|
+
const i = {}, c = (f, l) => {
|
|
1945
|
+
const _ = i[f] || [];
|
|
1946
|
+
return i[f] = _, _.push(l), () => _.splice(_.indexOf(l), 1);
|
|
1947
|
+
}, d = (f, l, _) => {
|
|
1948
|
+
e.set(f, l);
|
|
1949
|
+
const h = i[f];
|
|
1950
|
+
if (h)
|
|
1951
|
+
for (let b = h.length; b--; )
|
|
1952
|
+
h[b](_, l);
|
|
1953
|
+
}, s = () => {
|
|
1954
|
+
if (!he.has(e) && (he.set(e, [
|
|
1955
|
+
o,
|
|
1956
|
+
{},
|
|
1957
|
+
{},
|
|
1958
|
+
{},
|
|
1959
|
+
a,
|
|
1960
|
+
d,
|
|
1961
|
+
c
|
|
1962
|
+
]), !Je)) {
|
|
1963
|
+
const f = t.initFocus(setTimeout.bind(ie, zn.bind(ie, o, yr))), l = t.initReconnect(setTimeout.bind(ie, zn.bind(ie, o, br)));
|
|
1964
|
+
n = () => {
|
|
1965
|
+
f && f(), l && l(), he.delete(e);
|
|
1966
|
+
};
|
|
1967
|
+
}
|
|
1968
|
+
};
|
|
1969
|
+
return s(), [
|
|
1970
|
+
e,
|
|
1971
|
+
a,
|
|
1972
|
+
s,
|
|
1973
|
+
n
|
|
1974
|
+
];
|
|
1891
1975
|
}
|
|
1892
|
-
return [
|
|
1893
|
-
|
|
1894
|
-
|
|
1895
|
-
|
|
1896
|
-
},
|
|
1976
|
+
return [
|
|
1977
|
+
e,
|
|
1978
|
+
he.get(e)[4]
|
|
1979
|
+
];
|
|
1980
|
+
}, lo = (e, r, t, o, a) => {
|
|
1981
|
+
const n = t.errorRetryCount, i = a.retryCount, c = ~~((Math.random() + 0.5) * (1 << (i < 8 ? i : 8))) * t.errorRetryInterval;
|
|
1982
|
+
!U(n) && i > n || setTimeout(o, c, a);
|
|
1983
|
+
}, fo = (e, r) => He(e) == He(r), [Rr, po] = co(/* @__PURE__ */ new Map()), ho = ye(
|
|
1897
1984
|
{
|
|
1898
|
-
onLoadingSlow:
|
|
1899
|
-
onSuccess:
|
|
1900
|
-
onError:
|
|
1901
|
-
onErrorRetry:
|
|
1902
|
-
onDiscarded:
|
|
1985
|
+
onLoadingSlow: _e,
|
|
1986
|
+
onSuccess: _e,
|
|
1987
|
+
onError: _e,
|
|
1988
|
+
onErrorRetry: lo,
|
|
1989
|
+
onDiscarded: _e,
|
|
1903
1990
|
revalidateOnFocus: !0,
|
|
1904
1991
|
revalidateOnReconnect: !0,
|
|
1905
1992
|
revalidateIfStale: !0,
|
|
1906
1993
|
shouldRetryOnError: !0,
|
|
1907
|
-
errorRetryInterval:
|
|
1994
|
+
errorRetryInterval: Gn ? 1e4 : 5e3,
|
|
1908
1995
|
focusThrottleInterval: 5 * 1e3,
|
|
1909
1996
|
dedupingInterval: 2 * 1e3,
|
|
1910
|
-
loadingTimeout:
|
|
1911
|
-
compare:
|
|
1912
|
-
|
|
1913
|
-
|
|
1914
|
-
|
|
1915
|
-
return !1;
|
|
1916
|
-
},
|
|
1917
|
-
cache: si,
|
|
1918
|
-
mutate: ui,
|
|
1997
|
+
loadingTimeout: Gn ? 5e3 : 3e3,
|
|
1998
|
+
compare: fo,
|
|
1999
|
+
isPaused: () => !1,
|
|
2000
|
+
cache: Rr,
|
|
2001
|
+
mutate: po,
|
|
1919
2002
|
fallback: {}
|
|
1920
2003
|
},
|
|
1921
|
-
|
|
1922
|
-
),
|
|
1923
|
-
|
|
1924
|
-
if (
|
|
1925
|
-
|
|
1926
|
-
|
|
2004
|
+
oo
|
|
2005
|
+
), vo = (e, r) => {
|
|
2006
|
+
const t = ye(e, r);
|
|
2007
|
+
if (r) {
|
|
2008
|
+
const { use: o, fallback: a } = e, { use: n, fallback: i } = r;
|
|
2009
|
+
o && n && (t.use = o.concat(n)), a && i && (t.fallback = ye(a, i));
|
|
1927
2010
|
}
|
|
1928
|
-
return
|
|
1929
|
-
},
|
|
1930
|
-
|
|
1931
|
-
|
|
1932
|
-
|
|
1933
|
-
|
|
1934
|
-
|
|
1935
|
-
|
|
1936
|
-
|
|
1937
|
-
|
|
1938
|
-
|
|
1939
|
-
|
|
1940
|
-
|
|
1941
|
-
|
|
1942
|
-
|
|
1943
|
-
|
|
1944
|
-
|
|
1945
|
-
|
|
1946
|
-
|
|
1947
|
-
|
|
1948
|
-
|
|
1949
|
-
|
|
1950
|
-
|
|
1951
|
-
return
|
|
1952
|
-
|
|
1953
|
-
|
|
1954
|
-
for (var e = [], i = 0; i < arguments.length; i++)
|
|
1955
|
-
e[i] = arguments[i];
|
|
1956
|
-
var a = hi(), r = pi(e), s = r[0], c = r[1], d = r[2], o = li(a, d), l = t, f = o.use;
|
|
1957
|
-
if (f)
|
|
1958
|
-
for (var w = f.length; w-- > 0; )
|
|
1959
|
-
l = f[w](l);
|
|
1960
|
-
return l(s, c || o.fetcher, o);
|
|
1961
|
-
};
|
|
1962
|
-
}, Mr = function(t, n, e) {
|
|
1963
|
-
var i = n[t] || (n[t] = []);
|
|
1964
|
-
return i.push(e), function() {
|
|
1965
|
-
var a = i.indexOf(e);
|
|
1966
|
-
a >= 0 && (i[a] = i[i.length - 1], i.pop());
|
|
2011
|
+
return t;
|
|
2012
|
+
}, mo = Zn({}), gr = vt && window.__SWR_DEVTOOLS_USE__, wo = gr ? window.__SWR_DEVTOOLS_USE__ : [], _o = () => {
|
|
2013
|
+
gr && (window.__SWR_DEVTOOLS_REACT__ = je);
|
|
2014
|
+
}, yo = (e) => ve(e[1]) ? [
|
|
2015
|
+
e[0],
|
|
2016
|
+
e[1],
|
|
2017
|
+
e[2] || {}
|
|
2018
|
+
] : [
|
|
2019
|
+
e[0],
|
|
2020
|
+
null,
|
|
2021
|
+
(e[1] === null ? e[2] : e[1]) || {}
|
|
2022
|
+
], bo = () => ye(ho, ne(mo)), Eo = (e) => (r, t, o) => e(r, t && ((...n) => {
|
|
2023
|
+
const i = sn(r)[0], [, , , c] = he.get(Rr), d = c[i];
|
|
2024
|
+
return d ? (delete c[i], d) : t(...n);
|
|
2025
|
+
}), o), So = wo.concat(Eo), Ro = (e) => function(...t) {
|
|
2026
|
+
const o = bo(), [a, n, i] = yo(t), c = vo(o, i);
|
|
2027
|
+
let d = e;
|
|
2028
|
+
const { use: s } = c, f = (s || []).concat(So);
|
|
2029
|
+
for (let l = f.length; l--; )
|
|
2030
|
+
d = f[l](d);
|
|
2031
|
+
return d(a, n || c.fetcher || null, c);
|
|
2032
|
+
}, go = (e, r, t) => {
|
|
2033
|
+
const o = r[e] || (r[e] = []);
|
|
2034
|
+
return o.push(t), () => {
|
|
2035
|
+
const a = o.indexOf(t);
|
|
2036
|
+
a >= 0 && (o[a] = o[o.length - 1], o.pop());
|
|
1967
2037
|
};
|
|
1968
|
-
}
|
|
1969
|
-
|
|
1970
|
-
|
|
1971
|
-
|
|
1972
|
-
|
|
1973
|
-
},
|
|
1974
|
-
|
|
1975
|
-
|
|
1976
|
-
|
|
1977
|
-
|
|
1978
|
-
|
|
1979
|
-
|
|
1980
|
-
|
|
1981
|
-
|
|
1982
|
-
|
|
1983
|
-
|
|
1984
|
-
|
|
1985
|
-
|
|
1986
|
-
|
|
1987
|
-
|
|
1988
|
-
|
|
1989
|
-
|
|
1990
|
-
|
|
1991
|
-
|
|
1992
|
-
|
|
1993
|
-
|
|
1994
|
-
|
|
1995
|
-
|
|
1996
|
-
|
|
1997
|
-
|
|
1998
|
-
|
|
1999
|
-
|
|
2000
|
-
isValidating: !0
|
|
2001
|
-
}), ke({ isValidating: !0 }), ge.label = 1;
|
|
2002
|
-
case 1:
|
|
2003
|
-
return ge.trys.push([1, 3, , 4]), ae && (Je(i, m, le.current.data, le.current.error, !0), e.loadingTimeout && !i.get(m) && setTimeout(function() {
|
|
2004
|
-
Re && N() && k().onLoadingSlow(m, e);
|
|
2005
|
-
}, e.loadingTimeout), x[m] = [L.apply(void 0, E), Yt()]), Be = x[m], I = Be[0], $ = Be[1], [4, I];
|
|
2006
|
-
case 2:
|
|
2007
|
-
return I = ge.sent(), ae && setTimeout(Q, e.dedupingInterval), !x[m] || x[m][1] !== $ ? (ae && N() && k().onDiscarded(m), [2, !1]) : (G({
|
|
2008
|
-
error: J
|
|
2009
|
-
}), M.error = J, me = F[m], !W(me) && ($ <= me[0] || $ <= me[1] || me[1] === 0) ? (De(), ae && N() && k().onDiscarded(m), [2, !1]) : (a(le.current.data, I) ? M.data = le.current.data : M.data = I, a(i.get(m), I) || i.set(m, I), ae && N() && k().onSuccess(I, m, e), [3, 4]));
|
|
2010
|
-
case 3:
|
|
2011
|
-
return se = ge.sent(), Q(), k().isPaused() || (G({ error: se }), M.error = se, ae && N() && (k().onError(se, m, e), (typeof e.shouldRetryOnError == "boolean" && e.shouldRetryOnError || ye(e.shouldRetryOnError) && e.shouldRetryOnError(se)) && U() && k().onErrorRetry(se, m, e, fe, {
|
|
2012
|
-
retryCount: (ve.retryCount || 0) + 1,
|
|
2013
|
-
dedupe: !0
|
|
2014
|
-
}))), [3, 4];
|
|
2015
|
-
case 4:
|
|
2016
|
-
return Re = !1, De(), N() && ae && Je(i, m, M.data, M.error, !1), [2, !0];
|
|
2017
|
-
}
|
|
2018
|
-
});
|
|
2019
|
-
});
|
|
2020
|
-
},
|
|
2021
|
-
[m]
|
|
2022
|
-
), $e = P(
|
|
2023
|
-
wn.bind(J, i, function() {
|
|
2024
|
-
return oe.current;
|
|
2038
|
+
};
|
|
2039
|
+
_o();
|
|
2040
|
+
const Ht = {
|
|
2041
|
+
dedupe: !0
|
|
2042
|
+
}, To = (e, r, t) => {
|
|
2043
|
+
const { cache: o, compare: a, suspense: n, fallbackData: i, revalidateOnMount: c, refreshInterval: d, refreshWhenHidden: s, refreshWhenOffline: f, keepPreviousData: l } = t, [_, h, b] = he.get(o), [w, T] = sn(e), x = ge(!1), S = ge(!1), O = ge(w), m = ge(r), I = ge(t), y = () => I.current, A = () => y().isVisible() && y().isOnline(), [M, P, N] = _r(o, w), J = ge({}).current, K = U(i) ? t.fallback[w] : i, V = (D, q) => {
|
|
2044
|
+
let L = !0;
|
|
2045
|
+
for (const W in J) {
|
|
2046
|
+
const X = W;
|
|
2047
|
+
a(q[X], D[X]) || X === "data" && U(D[X]) && a(q[X], xe) || (L = !1);
|
|
2048
|
+
}
|
|
2049
|
+
return L;
|
|
2050
|
+
}, G = tr(() => {
|
|
2051
|
+
const D = (() => !w || !r ? !1 : U(c) ? !(y().isPaused() || n) : c)(), q = () => {
|
|
2052
|
+
const W = M(), X = ye(W);
|
|
2053
|
+
return delete X._k, D ? {
|
|
2054
|
+
isValidating: !0,
|
|
2055
|
+
isLoading: !0,
|
|
2056
|
+
...X
|
|
2057
|
+
} : X;
|
|
2058
|
+
};
|
|
2059
|
+
let L = q();
|
|
2060
|
+
return () => {
|
|
2061
|
+
const W = q();
|
|
2062
|
+
return V(W, L) ? L : L = W;
|
|
2063
|
+
};
|
|
2064
|
+
}, [
|
|
2065
|
+
o,
|
|
2066
|
+
w
|
|
2067
|
+
]), z = wr.exports.useSyncExternalStore(H(
|
|
2068
|
+
(D) => N(w, (q, L) => {
|
|
2069
|
+
V(q, L) || D();
|
|
2025
2070
|
}),
|
|
2071
|
+
[
|
|
2072
|
+
o,
|
|
2073
|
+
w
|
|
2074
|
+
]
|
|
2075
|
+
), G, G), Pe = !x.current, le = z.data, se = U(le) ? K : le, Oe = z.error, Ue = ge(se), xe = l ? U(le) ? Ue.current : le : se, Ne = (() => Pe && !U(c) ? c : y().isPaused() ? !1 : n ? U(se) ? !1 : t.revalidateIfStale : U(se) || t.revalidateIfStale)(), Ie = !!(w && r && Pe && Ne), mt = U(z.isValidating) ? Ie : z.isValidating, wt = U(z.isLoading) ? Ie : z.isLoading, fe = H(
|
|
2076
|
+
async (D) => {
|
|
2077
|
+
const q = m.current;
|
|
2078
|
+
if (!w || !q || S.current || y().isPaused())
|
|
2079
|
+
return !1;
|
|
2080
|
+
let L, W, X = !0;
|
|
2081
|
+
const Ee = D || {}, me = !b[w] || !Ee.dedupe, ue = () => Yn ? !S.current && w === O.current && x.current : w === O.current, de = {
|
|
2082
|
+
isValidating: !1,
|
|
2083
|
+
isLoading: !1
|
|
2084
|
+
}, $e = () => {
|
|
2085
|
+
P(de);
|
|
2086
|
+
}, Ve = () => {
|
|
2087
|
+
const Z = b[w];
|
|
2088
|
+
Z && Z[1] === W && delete b[w];
|
|
2089
|
+
}, Se = {
|
|
2090
|
+
isValidating: !0
|
|
2091
|
+
};
|
|
2092
|
+
U(M().data) && (Se.isLoading = !0);
|
|
2093
|
+
try {
|
|
2094
|
+
if (me && (P(Se), t.loadingTimeout && U(M().data) && setTimeout(() => {
|
|
2095
|
+
X && ue() && y().onLoadingSlow(w, t);
|
|
2096
|
+
}, t.loadingTimeout), b[w] = [
|
|
2097
|
+
q(T),
|
|
2098
|
+
Zt()
|
|
2099
|
+
]), [L, W] = b[w], L = await L, me && setTimeout(Ve, t.dedupingInterval), !b[w] || b[w][1] !== W)
|
|
2100
|
+
return me && ue() && y().onDiscarded(w), !1;
|
|
2101
|
+
de.error = ie;
|
|
2102
|
+
const Z = h[w];
|
|
2103
|
+
if (!U(Z) && (W <= Z[0] || W <= Z[1] || Z[1] === 0))
|
|
2104
|
+
return $e(), me && ue() && y().onDiscarded(w), !1;
|
|
2105
|
+
const oe = M().data;
|
|
2106
|
+
de.data = a(oe, L) ? oe : L, me && ue() && y().onSuccess(L, w, t);
|
|
2107
|
+
} catch (Z) {
|
|
2108
|
+
Ve();
|
|
2109
|
+
const oe = y(), { shouldRetryOnError: Re } = oe;
|
|
2110
|
+
oe.isPaused() || (de.error = Z, me && ue() && (oe.onError(Z, w, oe), (Re === !0 || ve(Re) && Re(Z)) && A() && oe.onErrorRetry(Z, w, oe, fe, {
|
|
2111
|
+
retryCount: (Ee.retryCount || 0) + 1,
|
|
2112
|
+
dedupe: !0
|
|
2113
|
+
})));
|
|
2114
|
+
}
|
|
2115
|
+
return X = !1, $e(), !0;
|
|
2116
|
+
},
|
|
2117
|
+
[
|
|
2118
|
+
w,
|
|
2119
|
+
o
|
|
2120
|
+
]
|
|
2121
|
+
), qe = H(
|
|
2122
|
+
(...D) => Sr(o, O.current, ...D),
|
|
2026
2123
|
[]
|
|
2027
2124
|
);
|
|
2028
|
-
if (
|
|
2029
|
-
|
|
2030
|
-
}),
|
|
2031
|
-
if (
|
|
2032
|
-
|
|
2033
|
-
|
|
2034
|
-
|
|
2035
|
-
|
|
2036
|
-
|
|
2037
|
-
|
|
2038
|
-
|
|
2039
|
-
|
|
2040
|
-
|
|
2041
|
-
|
|
2042
|
-
|
|
2043
|
-
|
|
2044
|
-
|
|
2045
|
-
|
|
2046
|
-
|
|
2047
|
-
|
|
2048
|
-
|
|
2049
|
-
|
|
2050
|
-
|
|
2051
|
-
|
|
2052
|
-
|
|
2053
|
-
|
|
2054
|
-
|
|
2055
|
-
|
|
2056
|
-
X.current = !0, ve(), ae();
|
|
2057
|
-
};
|
|
2125
|
+
if (Mt(() => {
|
|
2126
|
+
m.current = r, I.current = t, U(le) || (Ue.current = le);
|
|
2127
|
+
}), Mt(() => {
|
|
2128
|
+
if (!w)
|
|
2129
|
+
return;
|
|
2130
|
+
const D = fe.bind(ie, Ht);
|
|
2131
|
+
let q = 0;
|
|
2132
|
+
const W = go(w, _, (X) => {
|
|
2133
|
+
if (X == Xt.FOCUS_EVENT) {
|
|
2134
|
+
const Ee = Date.now();
|
|
2135
|
+
y().revalidateOnFocus && Ee > q && A() && (q = Ee + y().focusThrottleInterval, D());
|
|
2136
|
+
} else if (X == Xt.RECONNECT_EVENT)
|
|
2137
|
+
y().revalidateOnReconnect && A() && D();
|
|
2138
|
+
else if (X == Xt.MUTATE_EVENT)
|
|
2139
|
+
return fe();
|
|
2140
|
+
});
|
|
2141
|
+
return S.current = !1, O.current = w, x.current = !0, P({
|
|
2142
|
+
_k: T
|
|
2143
|
+
}), Ne && (U(se) || Je ? D() : so(D)), () => {
|
|
2144
|
+
S.current = !0, W();
|
|
2145
|
+
};
|
|
2146
|
+
}, [
|
|
2147
|
+
w
|
|
2148
|
+
]), Mt(() => {
|
|
2149
|
+
let D;
|
|
2150
|
+
function q() {
|
|
2151
|
+
const W = ve(d) ? d(se) : d;
|
|
2152
|
+
W && D !== -1 && (D = setTimeout(L, W));
|
|
2058
2153
|
}
|
|
2059
|
-
}, [m, fe]), ft(function() {
|
|
2060
|
-
var B;
|
|
2061
2154
|
function L() {
|
|
2062
|
-
|
|
2063
|
-
$ && B !== -1 && (B = setTimeout(I, $));
|
|
2064
|
-
}
|
|
2065
|
-
function I() {
|
|
2066
|
-
!le.current.error && (o || k().isVisible()) && (l || k().isOnline()) ? fe(Mt).then(L) : L();
|
|
2155
|
+
!M().error && (s || y().isVisible()) && (f || y().isOnline()) ? fe(Ht).then(q) : q();
|
|
2067
2156
|
}
|
|
2068
|
-
return
|
|
2069
|
-
|
|
2157
|
+
return q(), () => {
|
|
2158
|
+
D && (clearTimeout(D), D = -1);
|
|
2070
2159
|
};
|
|
2071
|
-
}, [
|
|
2072
|
-
|
|
2160
|
+
}, [
|
|
2161
|
+
d,
|
|
2162
|
+
s,
|
|
2163
|
+
f,
|
|
2164
|
+
w
|
|
2165
|
+
]), Hr(xe), n && U(se) && w)
|
|
2166
|
+
throw !Yn && Je ? new Error("Fallback data is required when using suspense in SSR.") : (m.current = r, I.current = t, S.current = !1, U(Oe) ? fe(Ht) : Oe);
|
|
2073
2167
|
return {
|
|
2074
|
-
mutate:
|
|
2168
|
+
mutate: qe,
|
|
2075
2169
|
get data() {
|
|
2076
|
-
return
|
|
2170
|
+
return J.data = !0, xe;
|
|
2077
2171
|
},
|
|
2078
2172
|
get error() {
|
|
2079
|
-
return
|
|
2173
|
+
return J.error = !0, Oe;
|
|
2080
2174
|
},
|
|
2081
2175
|
get isValidating() {
|
|
2082
|
-
return
|
|
2176
|
+
return J.isValidating = !0, mt;
|
|
2177
|
+
},
|
|
2178
|
+
get isLoading() {
|
|
2179
|
+
return J.isLoading = !0, wt;
|
|
2083
2180
|
}
|
|
2084
2181
|
};
|
|
2085
|
-
}
|
|
2182
|
+
};
|
|
2183
|
+
var Ze = Ro(To), Tr = { exports: {} }, We = {};
|
|
2086
2184
|
/**
|
|
2087
2185
|
* @license React
|
|
2088
2186
|
* react-jsx-runtime.production.min.js
|
|
@@ -2092,23 +2190,23 @@ var ue = function() {
|
|
|
2092
2190
|
* This source code is licensed under the MIT license found in the
|
|
2093
2191
|
* LICENSE file in the root directory of this source tree.
|
|
2094
2192
|
*/
|
|
2095
|
-
var
|
|
2096
|
-
function
|
|
2097
|
-
if (
|
|
2193
|
+
var Kn;
|
|
2194
|
+
function Co() {
|
|
2195
|
+
if (Kn)
|
|
2098
2196
|
return We;
|
|
2099
|
-
|
|
2100
|
-
var
|
|
2101
|
-
function
|
|
2102
|
-
var
|
|
2103
|
-
|
|
2104
|
-
for (
|
|
2105
|
-
|
|
2197
|
+
Kn = 1;
|
|
2198
|
+
var e = je, r = Symbol.for("react.element"), t = Symbol.for("react.fragment"), o = Object.prototype.hasOwnProperty, a = e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner, n = { key: !0, ref: !0, __self: !0, __source: !0 };
|
|
2199
|
+
function i(c, d, s) {
|
|
2200
|
+
var f, l = {}, _ = null, h = null;
|
|
2201
|
+
s !== void 0 && (_ = "" + s), d.key !== void 0 && (_ = "" + d.key), d.ref !== void 0 && (h = d.ref);
|
|
2202
|
+
for (f in d)
|
|
2203
|
+
o.call(d, f) && !n.hasOwnProperty(f) && (l[f] = d[f]);
|
|
2106
2204
|
if (c && c.defaultProps)
|
|
2107
|
-
for (
|
|
2108
|
-
f
|
|
2109
|
-
return { $$typeof:
|
|
2205
|
+
for (f in d = c.defaultProps, d)
|
|
2206
|
+
l[f] === void 0 && (l[f] = d[f]);
|
|
2207
|
+
return { $$typeof: r, type: c, key: _, ref: h, props: l, _owner: a.current };
|
|
2110
2208
|
}
|
|
2111
|
-
return We.Fragment =
|
|
2209
|
+
return We.Fragment = t, We.jsx = i, We.jsxs = i, We;
|
|
2112
2210
|
}
|
|
2113
2211
|
var Xe = {};
|
|
2114
2212
|
/**
|
|
@@ -2120,87 +2218,87 @@ var Xe = {};
|
|
|
2120
2218
|
* This source code is licensed under the MIT license found in the
|
|
2121
2219
|
* LICENSE file in the root directory of this source tree.
|
|
2122
2220
|
*/
|
|
2123
|
-
var
|
|
2124
|
-
function
|
|
2125
|
-
return
|
|
2126
|
-
var
|
|
2127
|
-
function
|
|
2221
|
+
var Qn;
|
|
2222
|
+
function Oo() {
|
|
2223
|
+
return Qn || (Qn = 1, process.env.NODE_ENV !== "production" && function() {
|
|
2224
|
+
var e = je, r = Symbol.for("react.element"), t = Symbol.for("react.portal"), o = Symbol.for("react.fragment"), a = Symbol.for("react.strict_mode"), n = Symbol.for("react.profiler"), i = Symbol.for("react.provider"), c = Symbol.for("react.context"), d = Symbol.for("react.forward_ref"), s = Symbol.for("react.suspense"), f = Symbol.for("react.suspense_list"), l = Symbol.for("react.memo"), _ = Symbol.for("react.lazy"), h = Symbol.for("react.offscreen"), b = Symbol.iterator, w = "@@iterator";
|
|
2225
|
+
function T(u) {
|
|
2128
2226
|
if (u === null || typeof u != "object")
|
|
2129
2227
|
return null;
|
|
2130
|
-
var p =
|
|
2228
|
+
var p = b && u[b] || u[w];
|
|
2131
2229
|
return typeof p == "function" ? p : null;
|
|
2132
2230
|
}
|
|
2133
|
-
var
|
|
2134
|
-
function
|
|
2231
|
+
var x = e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;
|
|
2232
|
+
function S(u) {
|
|
2135
2233
|
{
|
|
2136
|
-
for (var p = arguments.length,
|
|
2137
|
-
|
|
2138
|
-
|
|
2234
|
+
for (var p = arguments.length, v = new Array(p > 1 ? p - 1 : 0), E = 1; E < p; E++)
|
|
2235
|
+
v[E - 1] = arguments[E];
|
|
2236
|
+
O("error", u, v);
|
|
2139
2237
|
}
|
|
2140
2238
|
}
|
|
2141
|
-
function
|
|
2239
|
+
function O(u, p, v) {
|
|
2142
2240
|
{
|
|
2143
|
-
var
|
|
2144
|
-
|
|
2145
|
-
var
|
|
2241
|
+
var E = x.ReactDebugCurrentFrame, C = E.getStackAddendum();
|
|
2242
|
+
C !== "" && (p += "%s", v = v.concat([C]));
|
|
2243
|
+
var F = v.map(function(g) {
|
|
2146
2244
|
return String(g);
|
|
2147
2245
|
});
|
|
2148
|
-
|
|
2246
|
+
F.unshift("Warning: " + p), Function.prototype.apply.call(console[u], console, F);
|
|
2149
2247
|
}
|
|
2150
2248
|
}
|
|
2151
|
-
var
|
|
2152
|
-
|
|
2153
|
-
function
|
|
2154
|
-
return !!(typeof u == "string" || typeof u == "function" || u ===
|
|
2249
|
+
var m = !1, I = !1, y = !1, A = !1, M = !1, P;
|
|
2250
|
+
P = Symbol.for("react.module.reference");
|
|
2251
|
+
function N(u) {
|
|
2252
|
+
return !!(typeof u == "string" || typeof u == "function" || u === o || u === n || M || u === a || u === s || u === f || A || u === h || m || I || y || typeof u == "object" && u !== null && (u.$$typeof === _ || u.$$typeof === l || u.$$typeof === i || u.$$typeof === c || u.$$typeof === d || u.$$typeof === P || u.getModuleId !== void 0));
|
|
2155
2253
|
}
|
|
2156
|
-
function
|
|
2157
|
-
var
|
|
2158
|
-
if (
|
|
2159
|
-
return
|
|
2160
|
-
var
|
|
2161
|
-
return
|
|
2254
|
+
function J(u, p, v) {
|
|
2255
|
+
var E = u.displayName;
|
|
2256
|
+
if (E)
|
|
2257
|
+
return E;
|
|
2258
|
+
var C = p.displayName || p.name || "";
|
|
2259
|
+
return C !== "" ? v + "(" + C + ")" : v;
|
|
2162
2260
|
}
|
|
2163
|
-
function
|
|
2261
|
+
function K(u) {
|
|
2164
2262
|
return u.displayName || "Context";
|
|
2165
2263
|
}
|
|
2166
|
-
function
|
|
2264
|
+
function V(u) {
|
|
2167
2265
|
if (u == null)
|
|
2168
2266
|
return null;
|
|
2169
|
-
if (typeof u.tag == "number" &&
|
|
2267
|
+
if (typeof u.tag == "number" && S("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."), typeof u == "function")
|
|
2170
2268
|
return u.displayName || u.name || null;
|
|
2171
2269
|
if (typeof u == "string")
|
|
2172
2270
|
return u;
|
|
2173
2271
|
switch (u) {
|
|
2174
|
-
case
|
|
2272
|
+
case o:
|
|
2175
2273
|
return "Fragment";
|
|
2176
|
-
case
|
|
2274
|
+
case t:
|
|
2177
2275
|
return "Portal";
|
|
2178
|
-
case
|
|
2276
|
+
case n:
|
|
2179
2277
|
return "Profiler";
|
|
2180
2278
|
case a:
|
|
2181
2279
|
return "StrictMode";
|
|
2182
|
-
case
|
|
2280
|
+
case s:
|
|
2183
2281
|
return "Suspense";
|
|
2184
|
-
case
|
|
2282
|
+
case f:
|
|
2185
2283
|
return "SuspenseList";
|
|
2186
2284
|
}
|
|
2187
2285
|
if (typeof u == "object")
|
|
2188
2286
|
switch (u.$$typeof) {
|
|
2189
2287
|
case c:
|
|
2190
2288
|
var p = u;
|
|
2191
|
-
return
|
|
2192
|
-
case
|
|
2193
|
-
var
|
|
2194
|
-
return
|
|
2289
|
+
return K(p) + ".Consumer";
|
|
2290
|
+
case i:
|
|
2291
|
+
var v = u;
|
|
2292
|
+
return K(v._context) + ".Provider";
|
|
2195
2293
|
case d:
|
|
2196
|
-
return
|
|
2197
|
-
case
|
|
2198
|
-
var
|
|
2199
|
-
return
|
|
2200
|
-
case
|
|
2201
|
-
var
|
|
2294
|
+
return J(u, u.render, "ForwardRef");
|
|
2295
|
+
case l:
|
|
2296
|
+
var E = u.displayName || null;
|
|
2297
|
+
return E !== null ? E : V(u.type) || "Memo";
|
|
2298
|
+
case _: {
|
|
2299
|
+
var C = u, F = C._payload, g = C._init;
|
|
2202
2300
|
try {
|
|
2203
|
-
return
|
|
2301
|
+
return V(g(F));
|
|
2204
2302
|
} catch {
|
|
2205
2303
|
return null;
|
|
2206
2304
|
}
|
|
@@ -2208,18 +2306,18 @@ function yi() {
|
|
|
2208
2306
|
}
|
|
2209
2307
|
return null;
|
|
2210
2308
|
}
|
|
2211
|
-
var
|
|
2212
|
-
function
|
|
2309
|
+
var G = Object.assign, z = 0, Pe, le, se, Oe, Ue, xe, Ne;
|
|
2310
|
+
function Ie() {
|
|
2213
2311
|
}
|
|
2214
|
-
|
|
2215
|
-
function
|
|
2312
|
+
Ie.__reactDisabledLog = !0;
|
|
2313
|
+
function mt() {
|
|
2216
2314
|
{
|
|
2217
|
-
if (
|
|
2218
|
-
|
|
2315
|
+
if (z === 0) {
|
|
2316
|
+
Pe = console.log, le = console.info, se = console.warn, Oe = console.error, Ue = console.group, xe = console.groupCollapsed, Ne = console.groupEnd;
|
|
2219
2317
|
var u = {
|
|
2220
2318
|
configurable: !0,
|
|
2221
2319
|
enumerable: !0,
|
|
2222
|
-
value:
|
|
2320
|
+
value: Ie,
|
|
2223
2321
|
writable: !0
|
|
2224
2322
|
};
|
|
2225
2323
|
Object.defineProperties(console, {
|
|
@@ -2232,77 +2330,77 @@ function yi() {
|
|
|
2232
2330
|
groupEnd: u
|
|
2233
2331
|
});
|
|
2234
2332
|
}
|
|
2235
|
-
|
|
2333
|
+
z++;
|
|
2236
2334
|
}
|
|
2237
2335
|
}
|
|
2238
|
-
function
|
|
2336
|
+
function wt() {
|
|
2239
2337
|
{
|
|
2240
|
-
if (
|
|
2338
|
+
if (z--, z === 0) {
|
|
2241
2339
|
var u = {
|
|
2242
2340
|
configurable: !0,
|
|
2243
2341
|
enumerable: !0,
|
|
2244
2342
|
writable: !0
|
|
2245
2343
|
};
|
|
2246
2344
|
Object.defineProperties(console, {
|
|
2247
|
-
log:
|
|
2248
|
-
value:
|
|
2345
|
+
log: G({}, u, {
|
|
2346
|
+
value: Pe
|
|
2347
|
+
}),
|
|
2348
|
+
info: G({}, u, {
|
|
2349
|
+
value: le
|
|
2249
2350
|
}),
|
|
2250
|
-
|
|
2251
|
-
value:
|
|
2351
|
+
warn: G({}, u, {
|
|
2352
|
+
value: se
|
|
2252
2353
|
}),
|
|
2253
|
-
|
|
2254
|
-
value:
|
|
2354
|
+
error: G({}, u, {
|
|
2355
|
+
value: Oe
|
|
2255
2356
|
}),
|
|
2256
|
-
|
|
2257
|
-
value:
|
|
2357
|
+
group: G({}, u, {
|
|
2358
|
+
value: Ue
|
|
2258
2359
|
}),
|
|
2259
|
-
|
|
2360
|
+
groupCollapsed: G({}, u, {
|
|
2260
2361
|
value: xe
|
|
2261
2362
|
}),
|
|
2262
|
-
|
|
2263
|
-
value:
|
|
2264
|
-
}),
|
|
2265
|
-
groupEnd: D({}, u, {
|
|
2266
|
-
value: le
|
|
2363
|
+
groupEnd: G({}, u, {
|
|
2364
|
+
value: Ne
|
|
2267
2365
|
})
|
|
2268
2366
|
});
|
|
2269
2367
|
}
|
|
2270
|
-
|
|
2368
|
+
z < 0 && S("disabledDepth fell below zero. This is a bug in React. Please file an issue.");
|
|
2271
2369
|
}
|
|
2272
2370
|
}
|
|
2273
|
-
var
|
|
2274
|
-
function
|
|
2371
|
+
var fe = x.ReactCurrentDispatcher, qe;
|
|
2372
|
+
function D(u, p, v) {
|
|
2275
2373
|
{
|
|
2276
|
-
if (
|
|
2374
|
+
if (qe === void 0)
|
|
2277
2375
|
try {
|
|
2278
2376
|
throw Error();
|
|
2279
|
-
} catch (
|
|
2280
|
-
var
|
|
2281
|
-
|
|
2377
|
+
} catch (C) {
|
|
2378
|
+
var E = C.stack.trim().match(/\n( *(at )?)/);
|
|
2379
|
+
qe = E && E[1] || "";
|
|
2282
2380
|
}
|
|
2283
2381
|
return `
|
|
2284
|
-
` +
|
|
2382
|
+
` + qe + u;
|
|
2285
2383
|
}
|
|
2286
2384
|
}
|
|
2287
|
-
var
|
|
2385
|
+
var q = !1, L;
|
|
2288
2386
|
{
|
|
2289
|
-
var
|
|
2290
|
-
|
|
2387
|
+
var W = typeof WeakMap == "function" ? WeakMap : Map;
|
|
2388
|
+
L = new W();
|
|
2291
2389
|
}
|
|
2292
|
-
function
|
|
2293
|
-
if (!u ||
|
|
2390
|
+
function X(u, p) {
|
|
2391
|
+
if (!u || q)
|
|
2294
2392
|
return "";
|
|
2295
2393
|
{
|
|
2296
|
-
var
|
|
2297
|
-
if (
|
|
2298
|
-
return
|
|
2394
|
+
var v = L.get(u);
|
|
2395
|
+
if (v !== void 0)
|
|
2396
|
+
return v;
|
|
2299
2397
|
}
|
|
2300
|
-
var
|
|
2301
|
-
|
|
2302
|
-
var
|
|
2398
|
+
var E;
|
|
2399
|
+
q = !0;
|
|
2400
|
+
var C = Error.prepareStackTrace;
|
|
2303
2401
|
Error.prepareStackTrace = void 0;
|
|
2304
|
-
var
|
|
2305
|
-
|
|
2402
|
+
var F;
|
|
2403
|
+
F = fe.current, fe.current = null, mt();
|
|
2306
2404
|
try {
|
|
2307
2405
|
if (p) {
|
|
2308
2406
|
var g = function() {
|
|
@@ -2315,250 +2413,250 @@ function yi() {
|
|
|
2315
2413
|
}), typeof Reflect == "object" && Reflect.construct) {
|
|
2316
2414
|
try {
|
|
2317
2415
|
Reflect.construct(g, []);
|
|
2318
|
-
} catch (
|
|
2319
|
-
|
|
2416
|
+
} catch (pe) {
|
|
2417
|
+
E = pe;
|
|
2320
2418
|
}
|
|
2321
2419
|
Reflect.construct(u, [], g);
|
|
2322
2420
|
} else {
|
|
2323
2421
|
try {
|
|
2324
2422
|
g.call();
|
|
2325
|
-
} catch (
|
|
2326
|
-
|
|
2423
|
+
} catch (pe) {
|
|
2424
|
+
E = pe;
|
|
2327
2425
|
}
|
|
2328
2426
|
u.call(g.prototype);
|
|
2329
2427
|
}
|
|
2330
2428
|
} else {
|
|
2331
2429
|
try {
|
|
2332
2430
|
throw Error();
|
|
2333
|
-
} catch (
|
|
2334
|
-
|
|
2431
|
+
} catch (pe) {
|
|
2432
|
+
E = pe;
|
|
2335
2433
|
}
|
|
2336
2434
|
u();
|
|
2337
2435
|
}
|
|
2338
|
-
} catch (
|
|
2339
|
-
if (
|
|
2340
|
-
for (var
|
|
2341
|
-
`),
|
|
2342
|
-
`),
|
|
2343
|
-
|
|
2344
|
-
for (;
|
|
2345
|
-
if (
|
|
2346
|
-
if (
|
|
2436
|
+
} catch (pe) {
|
|
2437
|
+
if (pe && E && typeof pe.stack == "string") {
|
|
2438
|
+
for (var R = pe.stack.split(`
|
|
2439
|
+
`), Q = E.stack.split(`
|
|
2440
|
+
`), $ = R.length - 1, B = Q.length - 1; $ >= 1 && B >= 0 && R[$] !== Q[B]; )
|
|
2441
|
+
B--;
|
|
2442
|
+
for (; $ >= 1 && B >= 0; $--, B--)
|
|
2443
|
+
if (R[$] !== Q[B]) {
|
|
2444
|
+
if ($ !== 1 || B !== 1)
|
|
2347
2445
|
do
|
|
2348
|
-
if (
|
|
2349
|
-
var
|
|
2350
|
-
` +
|
|
2351
|
-
return u.displayName &&
|
|
2446
|
+
if ($--, B--, B < 0 || R[$] !== Q[B]) {
|
|
2447
|
+
var ae = `
|
|
2448
|
+
` + R[$].replace(" at new ", " at ");
|
|
2449
|
+
return u.displayName && ae.includes("<anonymous>") && (ae = ae.replace("<anonymous>", u.displayName)), typeof u == "function" && L.set(u, ae), ae;
|
|
2352
2450
|
}
|
|
2353
|
-
while (
|
|
2451
|
+
while ($ >= 1 && B >= 0);
|
|
2354
2452
|
break;
|
|
2355
2453
|
}
|
|
2356
2454
|
}
|
|
2357
2455
|
} finally {
|
|
2358
|
-
|
|
2456
|
+
q = !1, fe.current = F, wt(), Error.prepareStackTrace = C;
|
|
2359
2457
|
}
|
|
2360
|
-
var
|
|
2361
|
-
return typeof u == "function" &&
|
|
2458
|
+
var De = u ? u.displayName || u.name : "", _n = De ? D(De) : "";
|
|
2459
|
+
return typeof u == "function" && L.set(u, _n), _n;
|
|
2362
2460
|
}
|
|
2363
|
-
function
|
|
2364
|
-
return
|
|
2461
|
+
function Ee(u, p, v) {
|
|
2462
|
+
return X(u, !1);
|
|
2365
2463
|
}
|
|
2366
|
-
function
|
|
2464
|
+
function me(u) {
|
|
2367
2465
|
var p = u.prototype;
|
|
2368
2466
|
return !!(p && p.isReactComponent);
|
|
2369
2467
|
}
|
|
2370
|
-
function
|
|
2468
|
+
function ue(u, p, v) {
|
|
2371
2469
|
if (u == null)
|
|
2372
2470
|
return "";
|
|
2373
2471
|
if (typeof u == "function")
|
|
2374
|
-
return
|
|
2472
|
+
return X(u, me(u));
|
|
2375
2473
|
if (typeof u == "string")
|
|
2376
|
-
return
|
|
2474
|
+
return D(u);
|
|
2377
2475
|
switch (u) {
|
|
2378
|
-
case
|
|
2379
|
-
return
|
|
2380
|
-
case
|
|
2381
|
-
return
|
|
2476
|
+
case s:
|
|
2477
|
+
return D("Suspense");
|
|
2478
|
+
case f:
|
|
2479
|
+
return D("SuspenseList");
|
|
2382
2480
|
}
|
|
2383
2481
|
if (typeof u == "object")
|
|
2384
2482
|
switch (u.$$typeof) {
|
|
2385
2483
|
case d:
|
|
2386
|
-
return
|
|
2387
|
-
case
|
|
2388
|
-
return
|
|
2389
|
-
case
|
|
2390
|
-
var
|
|
2484
|
+
return Ee(u.render);
|
|
2485
|
+
case l:
|
|
2486
|
+
return ue(u.type, p, v);
|
|
2487
|
+
case _: {
|
|
2488
|
+
var E = u, C = E._payload, F = E._init;
|
|
2391
2489
|
try {
|
|
2392
|
-
return
|
|
2490
|
+
return ue(F(C), p, v);
|
|
2393
2491
|
} catch {
|
|
2394
2492
|
}
|
|
2395
2493
|
}
|
|
2396
2494
|
}
|
|
2397
2495
|
return "";
|
|
2398
2496
|
}
|
|
2399
|
-
var
|
|
2400
|
-
function
|
|
2497
|
+
var de = Object.prototype.hasOwnProperty, $e = {}, Ve = x.ReactDebugCurrentFrame;
|
|
2498
|
+
function Se(u) {
|
|
2401
2499
|
if (u) {
|
|
2402
|
-
var p = u._owner,
|
|
2403
|
-
|
|
2500
|
+
var p = u._owner, v = ue(u.type, u._source, p ? p.type : null);
|
|
2501
|
+
Ve.setExtraStackFrame(v);
|
|
2404
2502
|
} else
|
|
2405
|
-
|
|
2503
|
+
Ve.setExtraStackFrame(null);
|
|
2406
2504
|
}
|
|
2407
|
-
function
|
|
2505
|
+
function Z(u, p, v, E, C) {
|
|
2408
2506
|
{
|
|
2409
|
-
var
|
|
2507
|
+
var F = Function.call.bind(de);
|
|
2410
2508
|
for (var g in u)
|
|
2411
|
-
if (
|
|
2412
|
-
var
|
|
2509
|
+
if (F(u, g)) {
|
|
2510
|
+
var R = void 0;
|
|
2413
2511
|
try {
|
|
2414
2512
|
if (typeof u[g] != "function") {
|
|
2415
|
-
var
|
|
2416
|
-
throw
|
|
2513
|
+
var Q = Error((E || "React class") + ": " + v + " type `" + g + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + typeof u[g] + "`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");
|
|
2514
|
+
throw Q.name = "Invariant Violation", Q;
|
|
2417
2515
|
}
|
|
2418
|
-
|
|
2419
|
-
} catch (
|
|
2420
|
-
|
|
2516
|
+
R = u[g](p, g, E, v, null, "SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED");
|
|
2517
|
+
} catch ($) {
|
|
2518
|
+
R = $;
|
|
2421
2519
|
}
|
|
2422
|
-
|
|
2520
|
+
R && !(R instanceof Error) && (Se(C), S("%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).", E || "React class", v, g, typeof R), Se(null)), R instanceof Error && !(R.message in $e) && ($e[R.message] = !0, Se(C), S("Failed %s type: %s", v, R.message), Se(null));
|
|
2423
2521
|
}
|
|
2424
2522
|
}
|
|
2425
2523
|
}
|
|
2426
|
-
var
|
|
2427
|
-
function
|
|
2428
|
-
return
|
|
2524
|
+
var oe = Array.isArray;
|
|
2525
|
+
function Re(u) {
|
|
2526
|
+
return oe(u);
|
|
2429
2527
|
}
|
|
2430
|
-
function
|
|
2528
|
+
function Or(u) {
|
|
2431
2529
|
{
|
|
2432
|
-
var p = typeof Symbol == "function" && Symbol.toStringTag,
|
|
2433
|
-
return
|
|
2530
|
+
var p = typeof Symbol == "function" && Symbol.toStringTag, v = p && u[Symbol.toStringTag] || u.constructor.name || "Object";
|
|
2531
|
+
return v;
|
|
2434
2532
|
}
|
|
2435
2533
|
}
|
|
2436
|
-
function
|
|
2534
|
+
function xr(u) {
|
|
2437
2535
|
try {
|
|
2438
|
-
return
|
|
2536
|
+
return un(u), !1;
|
|
2439
2537
|
} catch {
|
|
2440
2538
|
return !0;
|
|
2441
2539
|
}
|
|
2442
2540
|
}
|
|
2443
|
-
function
|
|
2541
|
+
function un(u) {
|
|
2444
2542
|
return "" + u;
|
|
2445
2543
|
}
|
|
2446
|
-
function
|
|
2447
|
-
if (
|
|
2448
|
-
return
|
|
2544
|
+
function cn(u) {
|
|
2545
|
+
if (xr(u))
|
|
2546
|
+
return S("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.", Or(u)), un(u);
|
|
2449
2547
|
}
|
|
2450
|
-
var
|
|
2548
|
+
var Be = x.ReactCurrentOwner, Fr = {
|
|
2451
2549
|
key: !0,
|
|
2452
2550
|
ref: !0,
|
|
2453
2551
|
__self: !0,
|
|
2454
2552
|
__source: !0
|
|
2455
|
-
},
|
|
2456
|
-
|
|
2457
|
-
function
|
|
2458
|
-
if (
|
|
2553
|
+
}, ln, fn, _t;
|
|
2554
|
+
_t = {};
|
|
2555
|
+
function Dr(u) {
|
|
2556
|
+
if (de.call(u, "ref")) {
|
|
2459
2557
|
var p = Object.getOwnPropertyDescriptor(u, "ref").get;
|
|
2460
2558
|
if (p && p.isReactWarning)
|
|
2461
2559
|
return !1;
|
|
2462
2560
|
}
|
|
2463
2561
|
return u.ref !== void 0;
|
|
2464
2562
|
}
|
|
2465
|
-
function
|
|
2466
|
-
if (
|
|
2563
|
+
function kr(u) {
|
|
2564
|
+
if (de.call(u, "key")) {
|
|
2467
2565
|
var p = Object.getOwnPropertyDescriptor(u, "key").get;
|
|
2468
2566
|
if (p && p.isReactWarning)
|
|
2469
2567
|
return !1;
|
|
2470
2568
|
}
|
|
2471
2569
|
return u.key !== void 0;
|
|
2472
2570
|
}
|
|
2473
|
-
function
|
|
2474
|
-
if (typeof u.ref == "string" &&
|
|
2475
|
-
var
|
|
2476
|
-
|
|
2571
|
+
function Ar(u, p) {
|
|
2572
|
+
if (typeof u.ref == "string" && Be.current && p && Be.current.stateNode !== p) {
|
|
2573
|
+
var v = V(Be.current.type);
|
|
2574
|
+
_t[v] || (S('Component "%s" contains the string ref "%s". Support for string refs will be removed in a future major release. This case cannot be automatically converted to an arrow function. We ask you to manually fix this case by using useRef() or createRef() instead. Learn more about using refs safely here: https://reactjs.org/link/strict-mode-string-ref', V(Be.current.type), u.ref), _t[v] = !0);
|
|
2477
2575
|
}
|
|
2478
2576
|
}
|
|
2479
|
-
function
|
|
2577
|
+
function Lr(u, p) {
|
|
2480
2578
|
{
|
|
2481
|
-
var
|
|
2482
|
-
|
|
2579
|
+
var v = function() {
|
|
2580
|
+
ln || (ln = !0, S("%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)", p));
|
|
2483
2581
|
};
|
|
2484
|
-
|
|
2485
|
-
get:
|
|
2582
|
+
v.isReactWarning = !0, Object.defineProperty(u, "key", {
|
|
2583
|
+
get: v,
|
|
2486
2584
|
configurable: !0
|
|
2487
2585
|
});
|
|
2488
2586
|
}
|
|
2489
2587
|
}
|
|
2490
|
-
function
|
|
2588
|
+
function jr(u, p) {
|
|
2491
2589
|
{
|
|
2492
|
-
var
|
|
2493
|
-
|
|
2590
|
+
var v = function() {
|
|
2591
|
+
fn || (fn = !0, S("%s: `ref` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)", p));
|
|
2494
2592
|
};
|
|
2495
|
-
|
|
2496
|
-
get:
|
|
2593
|
+
v.isReactWarning = !0, Object.defineProperty(u, "ref", {
|
|
2594
|
+
get: v,
|
|
2497
2595
|
configurable: !0
|
|
2498
2596
|
});
|
|
2499
2597
|
}
|
|
2500
2598
|
}
|
|
2501
|
-
var
|
|
2502
|
-
var
|
|
2503
|
-
$$typeof:
|
|
2599
|
+
var Pr = function(u, p, v, E, C, F, g) {
|
|
2600
|
+
var R = {
|
|
2601
|
+
$$typeof: r,
|
|
2504
2602
|
type: u,
|
|
2505
2603
|
key: p,
|
|
2506
|
-
ref:
|
|
2604
|
+
ref: v,
|
|
2507
2605
|
props: g,
|
|
2508
|
-
_owner:
|
|
2606
|
+
_owner: F
|
|
2509
2607
|
};
|
|
2510
|
-
return
|
|
2608
|
+
return R._store = {}, Object.defineProperty(R._store, "validated", {
|
|
2511
2609
|
configurable: !1,
|
|
2512
2610
|
enumerable: !1,
|
|
2513
2611
|
writable: !0,
|
|
2514
2612
|
value: !1
|
|
2515
|
-
}), Object.defineProperty(
|
|
2613
|
+
}), Object.defineProperty(R, "_self", {
|
|
2516
2614
|
configurable: !1,
|
|
2517
2615
|
enumerable: !1,
|
|
2518
2616
|
writable: !1,
|
|
2519
|
-
value:
|
|
2520
|
-
}), Object.defineProperty(
|
|
2617
|
+
value: E
|
|
2618
|
+
}), Object.defineProperty(R, "_source", {
|
|
2521
2619
|
configurable: !1,
|
|
2522
2620
|
enumerable: !1,
|
|
2523
2621
|
writable: !1,
|
|
2524
|
-
value:
|
|
2525
|
-
}), Object.freeze && (Object.freeze(
|
|
2622
|
+
value: C
|
|
2623
|
+
}), Object.freeze && (Object.freeze(R.props), Object.freeze(R)), R;
|
|
2526
2624
|
};
|
|
2527
|
-
function
|
|
2625
|
+
function Ur(u, p, v, E, C) {
|
|
2528
2626
|
{
|
|
2529
|
-
var
|
|
2530
|
-
|
|
2531
|
-
for (
|
|
2532
|
-
|
|
2627
|
+
var F, g = {}, R = null, Q = null;
|
|
2628
|
+
v !== void 0 && (cn(v), R = "" + v), kr(p) && (cn(p.key), R = "" + p.key), Dr(p) && (Q = p.ref, Ar(p, C));
|
|
2629
|
+
for (F in p)
|
|
2630
|
+
de.call(p, F) && !Fr.hasOwnProperty(F) && (g[F] = p[F]);
|
|
2533
2631
|
if (u && u.defaultProps) {
|
|
2534
|
-
var
|
|
2535
|
-
for (
|
|
2536
|
-
g[
|
|
2632
|
+
var $ = u.defaultProps;
|
|
2633
|
+
for (F in $)
|
|
2634
|
+
g[F] === void 0 && (g[F] = $[F]);
|
|
2537
2635
|
}
|
|
2538
|
-
if (
|
|
2539
|
-
var
|
|
2540
|
-
|
|
2636
|
+
if (R || Q) {
|
|
2637
|
+
var B = typeof u == "function" ? u.displayName || u.name || "Unknown" : u;
|
|
2638
|
+
R && Lr(g, B), Q && jr(g, B);
|
|
2541
2639
|
}
|
|
2542
|
-
return
|
|
2640
|
+
return Pr(u, R, Q, C, E, Be.current, g);
|
|
2543
2641
|
}
|
|
2544
2642
|
}
|
|
2545
|
-
var
|
|
2546
|
-
function
|
|
2643
|
+
var yt = x.ReactCurrentOwner, dn = x.ReactDebugCurrentFrame;
|
|
2644
|
+
function Fe(u) {
|
|
2547
2645
|
if (u) {
|
|
2548
|
-
var p = u._owner,
|
|
2549
|
-
|
|
2646
|
+
var p = u._owner, v = ue(u.type, u._source, p ? p.type : null);
|
|
2647
|
+
dn.setExtraStackFrame(v);
|
|
2550
2648
|
} else
|
|
2551
|
-
|
|
2649
|
+
dn.setExtraStackFrame(null);
|
|
2552
2650
|
}
|
|
2553
|
-
var
|
|
2554
|
-
|
|
2555
|
-
function
|
|
2556
|
-
return typeof u == "object" && u !== null && u.$$typeof ===
|
|
2651
|
+
var bt;
|
|
2652
|
+
bt = !1;
|
|
2653
|
+
function Et(u) {
|
|
2654
|
+
return typeof u == "object" && u !== null && u.$$typeof === r;
|
|
2557
2655
|
}
|
|
2558
|
-
function
|
|
2656
|
+
function pn() {
|
|
2559
2657
|
{
|
|
2560
|
-
if (
|
|
2561
|
-
var u =
|
|
2658
|
+
if (yt.current) {
|
|
2659
|
+
var u = V(yt.current.type);
|
|
2562
2660
|
if (u)
|
|
2563
2661
|
return `
|
|
2564
2662
|
|
|
@@ -2567,376 +2665,377 @@ Check the render method of \`` + u + "`.";
|
|
|
2567
2665
|
return "";
|
|
2568
2666
|
}
|
|
2569
2667
|
}
|
|
2570
|
-
function
|
|
2668
|
+
function Nr(u) {
|
|
2571
2669
|
{
|
|
2572
2670
|
if (u !== void 0) {
|
|
2573
|
-
var p = u.fileName.replace(/^.*[\\\/]/, ""),
|
|
2671
|
+
var p = u.fileName.replace(/^.*[\\\/]/, ""), v = u.lineNumber;
|
|
2574
2672
|
return `
|
|
2575
2673
|
|
|
2576
|
-
Check your code at ` + p + ":" +
|
|
2674
|
+
Check your code at ` + p + ":" + v + ".";
|
|
2577
2675
|
}
|
|
2578
2676
|
return "";
|
|
2579
2677
|
}
|
|
2580
2678
|
}
|
|
2581
|
-
var
|
|
2582
|
-
function
|
|
2679
|
+
var hn = {};
|
|
2680
|
+
function Ir(u) {
|
|
2583
2681
|
{
|
|
2584
|
-
var p =
|
|
2682
|
+
var p = pn();
|
|
2585
2683
|
if (!p) {
|
|
2586
|
-
var
|
|
2587
|
-
|
|
2684
|
+
var v = typeof u == "string" ? u : u.displayName || u.name;
|
|
2685
|
+
v && (p = `
|
|
2588
2686
|
|
|
2589
|
-
Check the top-level render call using <` +
|
|
2687
|
+
Check the top-level render call using <` + v + ">.");
|
|
2590
2688
|
}
|
|
2591
2689
|
return p;
|
|
2592
2690
|
}
|
|
2593
2691
|
}
|
|
2594
|
-
function
|
|
2692
|
+
function vn(u, p) {
|
|
2595
2693
|
{
|
|
2596
2694
|
if (!u._store || u._store.validated || u.key != null)
|
|
2597
2695
|
return;
|
|
2598
2696
|
u._store.validated = !0;
|
|
2599
|
-
var
|
|
2600
|
-
if (
|
|
2697
|
+
var v = Ir(p);
|
|
2698
|
+
if (hn[v])
|
|
2601
2699
|
return;
|
|
2602
|
-
|
|
2603
|
-
var
|
|
2604
|
-
u && u._owner && u._owner !==
|
|
2700
|
+
hn[v] = !0;
|
|
2701
|
+
var E = "";
|
|
2702
|
+
u && u._owner && u._owner !== yt.current && (E = " It was passed a child from " + V(u._owner.type) + "."), Fe(u), S('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.', v, E), Fe(null);
|
|
2605
2703
|
}
|
|
2606
2704
|
}
|
|
2607
|
-
function
|
|
2705
|
+
function mn(u, p) {
|
|
2608
2706
|
{
|
|
2609
2707
|
if (typeof u != "object")
|
|
2610
2708
|
return;
|
|
2611
|
-
if (
|
|
2612
|
-
for (var
|
|
2613
|
-
var
|
|
2614
|
-
|
|
2709
|
+
if (Re(u))
|
|
2710
|
+
for (var v = 0; v < u.length; v++) {
|
|
2711
|
+
var E = u[v];
|
|
2712
|
+
Et(E) && vn(E, p);
|
|
2615
2713
|
}
|
|
2616
|
-
else if (
|
|
2714
|
+
else if (Et(u))
|
|
2617
2715
|
u._store && (u._store.validated = !0);
|
|
2618
2716
|
else if (u) {
|
|
2619
|
-
var
|
|
2620
|
-
if (typeof
|
|
2621
|
-
for (var
|
|
2622
|
-
|
|
2717
|
+
var C = T(u);
|
|
2718
|
+
if (typeof C == "function" && C !== u.entries)
|
|
2719
|
+
for (var F = C.call(u), g; !(g = F.next()).done; )
|
|
2720
|
+
Et(g.value) && vn(g.value, p);
|
|
2623
2721
|
}
|
|
2624
2722
|
}
|
|
2625
2723
|
}
|
|
2626
|
-
function
|
|
2724
|
+
function qr(u) {
|
|
2627
2725
|
{
|
|
2628
2726
|
var p = u.type;
|
|
2629
2727
|
if (p == null || typeof p == "string")
|
|
2630
2728
|
return;
|
|
2631
|
-
var
|
|
2729
|
+
var v;
|
|
2632
2730
|
if (typeof p == "function")
|
|
2633
|
-
|
|
2634
|
-
else if (typeof p == "object" && (p.$$typeof === d || p.$$typeof ===
|
|
2635
|
-
|
|
2731
|
+
v = p.propTypes;
|
|
2732
|
+
else if (typeof p == "object" && (p.$$typeof === d || p.$$typeof === l))
|
|
2733
|
+
v = p.propTypes;
|
|
2636
2734
|
else
|
|
2637
2735
|
return;
|
|
2638
|
-
if (
|
|
2639
|
-
var
|
|
2640
|
-
|
|
2641
|
-
} else if (p.PropTypes !== void 0 && !
|
|
2642
|
-
|
|
2643
|
-
var
|
|
2644
|
-
|
|
2736
|
+
if (v) {
|
|
2737
|
+
var E = V(p);
|
|
2738
|
+
Z(v, u.props, "prop", E, u);
|
|
2739
|
+
} else if (p.PropTypes !== void 0 && !bt) {
|
|
2740
|
+
bt = !0;
|
|
2741
|
+
var C = V(p);
|
|
2742
|
+
S("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?", C || "Unknown");
|
|
2645
2743
|
}
|
|
2646
|
-
typeof p.getDefaultProps == "function" && !p.getDefaultProps.isReactClassApproved &&
|
|
2744
|
+
typeof p.getDefaultProps == "function" && !p.getDefaultProps.isReactClassApproved && S("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.");
|
|
2647
2745
|
}
|
|
2648
2746
|
}
|
|
2649
|
-
function
|
|
2747
|
+
function $r(u) {
|
|
2650
2748
|
{
|
|
2651
|
-
for (var p = Object.keys(u.props),
|
|
2652
|
-
var
|
|
2653
|
-
if (
|
|
2654
|
-
|
|
2749
|
+
for (var p = Object.keys(u.props), v = 0; v < p.length; v++) {
|
|
2750
|
+
var E = p[v];
|
|
2751
|
+
if (E !== "children" && E !== "key") {
|
|
2752
|
+
Fe(u), S("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.", E), Fe(null);
|
|
2655
2753
|
break;
|
|
2656
2754
|
}
|
|
2657
2755
|
}
|
|
2658
|
-
u.ref !== null && (
|
|
2756
|
+
u.ref !== null && (Fe(u), S("Invalid attribute `ref` supplied to `React.Fragment`."), Fe(null));
|
|
2659
2757
|
}
|
|
2660
2758
|
}
|
|
2661
|
-
function
|
|
2759
|
+
function wn(u, p, v, E, C, F) {
|
|
2662
2760
|
{
|
|
2663
|
-
var g =
|
|
2761
|
+
var g = N(u);
|
|
2664
2762
|
if (!g) {
|
|
2665
|
-
var
|
|
2666
|
-
(u === void 0 || typeof u == "object" && u !== null && Object.keys(u).length === 0) && (
|
|
2667
|
-
var
|
|
2668
|
-
|
|
2669
|
-
var
|
|
2670
|
-
u === null ?
|
|
2763
|
+
var R = "";
|
|
2764
|
+
(u === void 0 || typeof u == "object" && u !== null && Object.keys(u).length === 0) && (R += " You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");
|
|
2765
|
+
var Q = Nr(C);
|
|
2766
|
+
Q ? R += Q : R += pn();
|
|
2767
|
+
var $;
|
|
2768
|
+
u === null ? $ = "null" : Re(u) ? $ = "array" : u !== void 0 && u.$$typeof === r ? ($ = "<" + (V(u.type) || "Unknown") + " />", R = " Did you accidentally export a JSX literal instead of a component?") : $ = typeof u, S("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s", $, R);
|
|
2671
2769
|
}
|
|
2672
|
-
var
|
|
2673
|
-
if (
|
|
2674
|
-
return
|
|
2770
|
+
var B = Ur(u, p, v, C, F);
|
|
2771
|
+
if (B == null)
|
|
2772
|
+
return B;
|
|
2675
2773
|
if (g) {
|
|
2676
|
-
var
|
|
2677
|
-
if (
|
|
2678
|
-
if (
|
|
2679
|
-
if (
|
|
2680
|
-
for (var
|
|
2681
|
-
|
|
2682
|
-
Object.freeze && Object.freeze(
|
|
2774
|
+
var ae = p.children;
|
|
2775
|
+
if (ae !== void 0)
|
|
2776
|
+
if (E)
|
|
2777
|
+
if (Re(ae)) {
|
|
2778
|
+
for (var De = 0; De < ae.length; De++)
|
|
2779
|
+
mn(ae[De], u);
|
|
2780
|
+
Object.freeze && Object.freeze(ae);
|
|
2683
2781
|
} else
|
|
2684
|
-
|
|
2782
|
+
S("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");
|
|
2685
2783
|
else
|
|
2686
|
-
|
|
2784
|
+
mn(ae, u);
|
|
2687
2785
|
}
|
|
2688
|
-
return u ===
|
|
2786
|
+
return u === o ? $r(B) : qr(B), B;
|
|
2689
2787
|
}
|
|
2690
2788
|
}
|
|
2691
|
-
function
|
|
2692
|
-
return
|
|
2789
|
+
function Vr(u, p, v) {
|
|
2790
|
+
return wn(u, p, v, !0);
|
|
2693
2791
|
}
|
|
2694
|
-
function
|
|
2695
|
-
return
|
|
2792
|
+
function Br(u, p, v) {
|
|
2793
|
+
return wn(u, p, v, !1);
|
|
2696
2794
|
}
|
|
2697
|
-
var
|
|
2698
|
-
Xe.Fragment =
|
|
2795
|
+
var Mr = Br, Wr = Vr;
|
|
2796
|
+
Xe.Fragment = o, Xe.jsx = Mr, Xe.jsxs = Wr;
|
|
2699
2797
|
}()), Xe;
|
|
2700
2798
|
}
|
|
2701
|
-
(function(
|
|
2702
|
-
process.env.NODE_ENV === "production" ?
|
|
2703
|
-
})(
|
|
2704
|
-
const
|
|
2705
|
-
url:
|
|
2706
|
-
children:
|
|
2799
|
+
(function(e) {
|
|
2800
|
+
process.env.NODE_ENV === "production" ? e.exports = Co() : e.exports = Oo();
|
|
2801
|
+
})(Tr);
|
|
2802
|
+
const xo = Tr.exports.jsx, re = Zn(null), Lo = ({
|
|
2803
|
+
url: e = "",
|
|
2804
|
+
children: r
|
|
2707
2805
|
}) => {
|
|
2708
|
-
const
|
|
2709
|
-
const
|
|
2806
|
+
const t = tr(() => {
|
|
2807
|
+
const o = new za.FrappeApp(e);
|
|
2710
2808
|
return {
|
|
2711
|
-
url:
|
|
2712
|
-
app:
|
|
2713
|
-
auth:
|
|
2714
|
-
db:
|
|
2715
|
-
call:
|
|
2716
|
-
file:
|
|
2809
|
+
url: e,
|
|
2810
|
+
app: o,
|
|
2811
|
+
auth: o.auth(),
|
|
2812
|
+
db: o.db(),
|
|
2813
|
+
call: o.call(),
|
|
2814
|
+
file: o.file()
|
|
2717
2815
|
};
|
|
2718
|
-
}, [
|
|
2719
|
-
return /* @__PURE__ */
|
|
2720
|
-
value:
|
|
2721
|
-
children:
|
|
2816
|
+
}, [e]);
|
|
2817
|
+
return /* @__PURE__ */ xo(re.Provider, {
|
|
2818
|
+
value: t,
|
|
2819
|
+
children: r
|
|
2722
2820
|
});
|
|
2723
|
-
},
|
|
2821
|
+
}, jo = (e) => {
|
|
2724
2822
|
const {
|
|
2725
|
-
url:
|
|
2726
|
-
auth:
|
|
2727
|
-
} =
|
|
2728
|
-
data:
|
|
2823
|
+
url: r,
|
|
2824
|
+
auth: t
|
|
2825
|
+
} = ne(re), {
|
|
2826
|
+
data: o,
|
|
2729
2827
|
error: a,
|
|
2730
|
-
isValidating:
|
|
2731
|
-
mutate:
|
|
2732
|
-
} = Ze(`${
|
|
2733
|
-
username:
|
|
2734
|
-
password:
|
|
2735
|
-
}).then((
|
|
2736
|
-
console.log(
|
|
2737
|
-
}), []), d =
|
|
2828
|
+
isValidating: n,
|
|
2829
|
+
mutate: i
|
|
2830
|
+
} = Ze(`${r}/api/method/frappe.auth.get_logged_user`, () => t.getLoggedInUser(), e), c = H(async (s, f) => t.loginWithUsernamePassword({
|
|
2831
|
+
username: s,
|
|
2832
|
+
password: f
|
|
2833
|
+
}).then((l) => {
|
|
2834
|
+
console.log(l), i();
|
|
2835
|
+
}), []), d = H(async () => t.logout().then(() => i(null)), []);
|
|
2738
2836
|
return {
|
|
2739
|
-
currentUser:
|
|
2740
|
-
isValidating:
|
|
2837
|
+
currentUser: o,
|
|
2838
|
+
isValidating: n,
|
|
2741
2839
|
error: a,
|
|
2742
2840
|
login: c,
|
|
2743
2841
|
logout: d,
|
|
2744
|
-
updateCurrentUser:
|
|
2842
|
+
updateCurrentUser: i
|
|
2745
2843
|
};
|
|
2746
|
-
},
|
|
2844
|
+
}, Po = (e, r, t) => {
|
|
2747
2845
|
const {
|
|
2748
|
-
db:
|
|
2749
|
-
} =
|
|
2846
|
+
db: o
|
|
2847
|
+
} = ne(re);
|
|
2750
2848
|
return {
|
|
2751
|
-
...Ze(
|
|
2849
|
+
...Ze(o.getRequestURL(e, r), () => o.getDoc(e, r), t)
|
|
2752
2850
|
};
|
|
2753
|
-
},
|
|
2754
|
-
var
|
|
2755
|
-
let
|
|
2756
|
-
if (
|
|
2757
|
-
const
|
|
2758
|
-
|
|
2851
|
+
}, Fo = (e) => {
|
|
2852
|
+
var t, o, a;
|
|
2853
|
+
let r = "";
|
|
2854
|
+
if (e != null && e.fields && (r += "fields=" + JSON.stringify(e == null ? void 0 : e.fields) + "&"), e != null && e.filters && (r += "filters=" + JSON.stringify(e == null ? void 0 : e.filters) + "&"), e != null && e.orFilters && (r += "or_filters=" + JSON.stringify(e == null ? void 0 : e.orFilters) + "&"), e != null && e.limit_start && (r += "limit_start=" + JSON.stringify(e == null ? void 0 : e.limit_start) + "&"), e != null && e.limit && (r += "limit=" + JSON.stringify(e == null ? void 0 : e.limit) + "&"), e != null && e.orderBy) {
|
|
2855
|
+
const n = `${(t = e.orderBy) == null ? void 0 : t.field} ${(a = (o = e.orderBy) == null ? void 0 : o.order) != null ? a : "asc"}`;
|
|
2856
|
+
r += "order_by=" + n + "&";
|
|
2759
2857
|
}
|
|
2760
|
-
return
|
|
2761
|
-
},
|
|
2858
|
+
return e != null && e.asDict && (r += "as_dict=" + e.asDict), r;
|
|
2859
|
+
}, Uo = (e, r, t) => {
|
|
2762
2860
|
const {
|
|
2763
|
-
db:
|
|
2764
|
-
} =
|
|
2861
|
+
db: o
|
|
2862
|
+
} = ne(re);
|
|
2765
2863
|
return {
|
|
2766
|
-
...Ze(`${
|
|
2864
|
+
...Ze(`${o.getRequestURL(e)}?${Fo(r)}`, () => o.getDocList(e, r), t)
|
|
2767
2865
|
};
|
|
2768
|
-
},
|
|
2866
|
+
}, No = () => {
|
|
2769
2867
|
const {
|
|
2770
|
-
db:
|
|
2771
|
-
} =
|
|
2772
|
-
|
|
2868
|
+
db: e
|
|
2869
|
+
} = ne(re), [r, t] = k(!1), [o, a] = k(null), [n, i] = k(!1), c = H(() => {
|
|
2870
|
+
t(!1), a(null), i(!1);
|
|
2773
2871
|
}, []);
|
|
2774
2872
|
return {
|
|
2775
|
-
createDoc:
|
|
2776
|
-
throw
|
|
2873
|
+
createDoc: H(async (s, f) => (a(null), i(!1), t(!0), e.createDoc(s, f).then((l) => (t(!1), i(!0), l)).catch((l) => {
|
|
2874
|
+
throw t(!1), i(!1), a(l), l;
|
|
2777
2875
|
})), []),
|
|
2778
|
-
loading:
|
|
2779
|
-
error:
|
|
2780
|
-
isCompleted:
|
|
2876
|
+
loading: r,
|
|
2877
|
+
error: o,
|
|
2878
|
+
isCompleted: n,
|
|
2781
2879
|
reset: c
|
|
2782
2880
|
};
|
|
2783
|
-
},
|
|
2881
|
+
}, Io = () => {
|
|
2784
2882
|
const {
|
|
2785
|
-
db:
|
|
2786
|
-
} =
|
|
2787
|
-
|
|
2883
|
+
db: e
|
|
2884
|
+
} = ne(re), [r, t] = k(!1), [o, a] = k(null), [n, i] = k(!1), c = H(() => {
|
|
2885
|
+
t(!1), a(null), i(!1);
|
|
2788
2886
|
}, []);
|
|
2789
2887
|
return {
|
|
2790
|
-
updateDoc:
|
|
2791
|
-
throw
|
|
2888
|
+
updateDoc: H(async (s, f, l) => (a(null), i(!1), t(!0), e.updateDoc(s, f, l).then((_) => (t(!1), i(!0), _)).catch((_) => {
|
|
2889
|
+
throw t(!1), i(!1), a(_), _;
|
|
2792
2890
|
})), []),
|
|
2793
|
-
loading:
|
|
2794
|
-
error:
|
|
2891
|
+
loading: r,
|
|
2892
|
+
error: o,
|
|
2795
2893
|
reset: c,
|
|
2796
|
-
isCompleted:
|
|
2894
|
+
isCompleted: n
|
|
2797
2895
|
};
|
|
2798
|
-
},
|
|
2896
|
+
}, qo = () => {
|
|
2799
2897
|
const {
|
|
2800
|
-
db:
|
|
2801
|
-
} =
|
|
2802
|
-
|
|
2898
|
+
db: e
|
|
2899
|
+
} = ne(re), [r, t] = k(!1), [o, a] = k(null), [n, i] = k(!1), c = H(() => {
|
|
2900
|
+
t(!1), a(null), i(!1);
|
|
2803
2901
|
}, []);
|
|
2804
2902
|
return {
|
|
2805
|
-
deleteDoc:
|
|
2806
|
-
throw
|
|
2903
|
+
deleteDoc: H(async (s, f) => (a(null), i(!1), t(!0), e.deleteDoc(s, f).then((l) => (t(!1), i(!0), l)).catch((l) => {
|
|
2904
|
+
throw t(!1), i(!1), a(l), l;
|
|
2807
2905
|
})), []),
|
|
2808
|
-
loading:
|
|
2809
|
-
error:
|
|
2906
|
+
loading: r,
|
|
2907
|
+
error: o,
|
|
2810
2908
|
reset: c,
|
|
2811
|
-
isCompleted:
|
|
2909
|
+
isCompleted: n
|
|
2812
2910
|
};
|
|
2813
2911
|
};
|
|
2814
|
-
function
|
|
2815
|
-
const
|
|
2816
|
-
for (let
|
|
2817
|
-
|
|
2818
|
-
return
|
|
2912
|
+
function Cr(e) {
|
|
2913
|
+
const r = [];
|
|
2914
|
+
for (let t in e)
|
|
2915
|
+
r.push(encodeURIComponent(t) + "=" + encodeURIComponent(e[t]));
|
|
2916
|
+
return r.join("&");
|
|
2819
2917
|
}
|
|
2820
|
-
const
|
|
2918
|
+
const $o = (e, r, t = !1, o = !1, a) => {
|
|
2821
2919
|
const {
|
|
2822
|
-
url:
|
|
2823
|
-
db:
|
|
2824
|
-
} =
|
|
2920
|
+
url: n,
|
|
2921
|
+
db: i
|
|
2922
|
+
} = ne(re);
|
|
2825
2923
|
return {
|
|
2826
2924
|
...Ze((() => {
|
|
2827
|
-
const
|
|
2828
|
-
|
|
2829
|
-
|
|
2830
|
-
|
|
2925
|
+
const s = Cr({
|
|
2926
|
+
doctype: e,
|
|
2927
|
+
filters: r != null ? r : [],
|
|
2928
|
+
cache: t,
|
|
2929
|
+
debug: o
|
|
2831
2930
|
});
|
|
2832
|
-
return `${
|
|
2833
|
-
})(), () =>
|
|
2931
|
+
return `${n}/api/method/frappe.client.get_count?${s}`;
|
|
2932
|
+
})(), () => i.getCount(e, r, t, o), a)
|
|
2834
2933
|
};
|
|
2835
|
-
},
|
|
2934
|
+
}, Do = (e, r, t, o) => {
|
|
2836
2935
|
const {
|
|
2837
2936
|
call: a
|
|
2838
|
-
} =
|
|
2937
|
+
} = ne(re), n = Cr(r != null ? r : {}), i = `${e}?${n}`;
|
|
2839
2938
|
return {
|
|
2840
|
-
...Ze(
|
|
2939
|
+
...Ze(t != null ? t : i, () => a.get(e, r), o)
|
|
2841
2940
|
};
|
|
2842
|
-
},
|
|
2941
|
+
}, Vo = (e) => {
|
|
2843
2942
|
const {
|
|
2844
|
-
call:
|
|
2845
|
-
} =
|
|
2846
|
-
|
|
2943
|
+
call: r
|
|
2944
|
+
} = ne(re), [t, o] = k(null), [a, n] = k(!1), [i, c] = k(null), [d, s] = k(!1), f = H(() => {
|
|
2945
|
+
o(null), n(!1), c(null), s(!1);
|
|
2847
2946
|
}, []);
|
|
2848
2947
|
return {
|
|
2849
|
-
call:
|
|
2850
|
-
throw
|
|
2948
|
+
call: H(async (_) => (c(null), s(!1), n(!0), o(null), r.post(e, _).then((h) => (o(h), n(!1), s(!0), h)).catch((h) => {
|
|
2949
|
+
throw n(!1), s(!1), c(h), h;
|
|
2851
2950
|
})), []),
|
|
2852
|
-
result:
|
|
2951
|
+
result: t,
|
|
2853
2952
|
loading: a,
|
|
2854
|
-
error:
|
|
2855
|
-
reset:
|
|
2953
|
+
error: i,
|
|
2954
|
+
reset: f,
|
|
2856
2955
|
isCompleted: d
|
|
2857
2956
|
};
|
|
2858
|
-
},
|
|
2957
|
+
}, Bo = (e) => {
|
|
2859
2958
|
const {
|
|
2860
|
-
call:
|
|
2861
|
-
} =
|
|
2862
|
-
|
|
2959
|
+
call: r
|
|
2960
|
+
} = ne(re), [t, o] = k(null), [a, n] = k(!1), [i, c] = k(null), [d, s] = k(!1), f = H(() => {
|
|
2961
|
+
o(null), n(!1), c(null), s(!1);
|
|
2863
2962
|
}, []);
|
|
2864
2963
|
return {
|
|
2865
|
-
call:
|
|
2866
|
-
throw
|
|
2964
|
+
call: H(async (_) => (c(null), s(!1), n(!0), o(null), r.put(e, _).then((h) => (o(h), n(!1), s(!0), h)).catch((h) => {
|
|
2965
|
+
throw n(!1), s(!1), c(h), h;
|
|
2867
2966
|
})), []),
|
|
2868
|
-
result:
|
|
2967
|
+
result: t,
|
|
2869
2968
|
loading: a,
|
|
2870
|
-
error:
|
|
2871
|
-
reset:
|
|
2969
|
+
error: i,
|
|
2970
|
+
reset: f,
|
|
2872
2971
|
isCompleted: d
|
|
2873
2972
|
};
|
|
2874
|
-
},
|
|
2973
|
+
}, Mo = (e) => {
|
|
2875
2974
|
const {
|
|
2876
|
-
call:
|
|
2877
|
-
} =
|
|
2878
|
-
|
|
2975
|
+
call: r
|
|
2976
|
+
} = ne(re), [t, o] = k(null), [a, n] = k(!1), [i, c] = k(null), [d, s] = k(!1), f = H(() => {
|
|
2977
|
+
o(null), n(!1), c(null), s(!1);
|
|
2879
2978
|
}, []);
|
|
2880
2979
|
return {
|
|
2881
|
-
call:
|
|
2882
|
-
throw
|
|
2980
|
+
call: H(async (_) => (c(null), s(!1), n(!0), o(null), r.delete(e, _).then((h) => (o(h), n(!1), s(!0), h)).catch((h) => {
|
|
2981
|
+
throw n(!1), s(!1), c(h), h;
|
|
2883
2982
|
})), []),
|
|
2884
|
-
result:
|
|
2983
|
+
result: t,
|
|
2885
2984
|
loading: a,
|
|
2886
|
-
error:
|
|
2887
|
-
reset:
|
|
2985
|
+
error: i,
|
|
2986
|
+
reset: f,
|
|
2888
2987
|
isCompleted: d
|
|
2889
2988
|
};
|
|
2890
|
-
},
|
|
2989
|
+
}, Wo = () => {
|
|
2891
2990
|
const {
|
|
2892
|
-
file:
|
|
2893
|
-
} =
|
|
2894
|
-
throw console.error(
|
|
2895
|
-
})), []),
|
|
2896
|
-
|
|
2991
|
+
file: e
|
|
2992
|
+
} = ne(re), [r, t] = k(0), [o, a] = k(!1), [n, i] = k(null), [c, d] = k(!1), s = H(async (l, _) => (f(), a(!0), e.uploadFile(l, _, (h, b) => t(Math.round(h / b * 100))).then((h) => (d(!0), t(100), a(!1), h.data.message)).catch((h) => {
|
|
2993
|
+
throw console.error(h), i(h), a(!1), h;
|
|
2994
|
+
})), []), f = H(() => {
|
|
2995
|
+
t(0), a(!1), i(null), d(!1);
|
|
2897
2996
|
}, []);
|
|
2898
2997
|
return {
|
|
2899
|
-
upload:
|
|
2900
|
-
progress:
|
|
2901
|
-
loading:
|
|
2998
|
+
upload: s,
|
|
2999
|
+
progress: r,
|
|
3000
|
+
loading: o,
|
|
2902
3001
|
isCompleted: c,
|
|
2903
|
-
error:
|
|
2904
|
-
reset:
|
|
3002
|
+
error: n,
|
|
3003
|
+
reset: f
|
|
2905
3004
|
};
|
|
2906
|
-
},
|
|
2907
|
-
const
|
|
2908
|
-
return
|
|
2909
|
-
doctype:
|
|
2910
|
-
page_length:
|
|
2911
|
-
txt:
|
|
2912
|
-
filters: JSON.stringify(
|
|
3005
|
+
}, Xo = (e, r, t = [], o = 20, a = 250) => {
|
|
3006
|
+
const n = ko(r, a);
|
|
3007
|
+
return Do("frappe.desk.search.search_link", {
|
|
3008
|
+
doctype: e,
|
|
3009
|
+
page_length: o,
|
|
3010
|
+
txt: n,
|
|
3011
|
+
filters: JSON.stringify(t != null ? t : [])
|
|
2913
3012
|
});
|
|
2914
|
-
},
|
|
2915
|
-
const [
|
|
2916
|
-
return
|
|
3013
|
+
}, ko = (e, r) => {
|
|
3014
|
+
const [t, o] = k(e);
|
|
3015
|
+
return er(() => {
|
|
2917
3016
|
const a = setTimeout(() => {
|
|
2918
|
-
|
|
2919
|
-
},
|
|
3017
|
+
o(e);
|
|
3018
|
+
}, r);
|
|
2920
3019
|
return () => {
|
|
2921
3020
|
clearTimeout(a);
|
|
2922
3021
|
};
|
|
2923
|
-
}, [
|
|
3022
|
+
}, [e, r]), t;
|
|
2924
3023
|
};
|
|
2925
3024
|
export {
|
|
2926
|
-
|
|
2927
|
-
|
|
2928
|
-
|
|
2929
|
-
|
|
2930
|
-
|
|
2931
|
-
|
|
2932
|
-
|
|
2933
|
-
|
|
2934
|
-
|
|
2935
|
-
|
|
2936
|
-
|
|
2937
|
-
|
|
2938
|
-
|
|
2939
|
-
|
|
2940
|
-
|
|
2941
|
-
|
|
3025
|
+
re as FrappeContext,
|
|
3026
|
+
Lo as FrappeProvider,
|
|
3027
|
+
Fo as getDocListQueryString,
|
|
3028
|
+
jo as useFrappeAuth,
|
|
3029
|
+
No as useFrappeCreateDoc,
|
|
3030
|
+
Mo as useFrappeDeleteCall,
|
|
3031
|
+
qo as useFrappeDeleteDoc,
|
|
3032
|
+
Wo as useFrappeFileUpload,
|
|
3033
|
+
Do as useFrappeGetCall,
|
|
3034
|
+
Po as useFrappeGetDoc,
|
|
3035
|
+
$o as useFrappeGetDocCount,
|
|
3036
|
+
Uo as useFrappeGetDocList,
|
|
3037
|
+
Vo as useFrappePostCall,
|
|
3038
|
+
Bo as useFrappePutCall,
|
|
3039
|
+
Io as useFrappeUpdateDoc,
|
|
3040
|
+
Xo as useSearch
|
|
2942
3041
|
};
|