frappe-react-sdk 1.3.9 → 1.3.10
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 +341 -343
- package/dist/frappe-react-sdk.umd.js +11 -11
- package/dist/lib/index.d.ts +3 -3
- package/package.json +1 -1
|
@@ -18,7 +18,7 @@ var B = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : ty
|
|
|
18
18
|
});
|
|
19
19
|
}
|
|
20
20
|
return new (t || (t = Promise))(function(i, o) {
|
|
21
|
-
function
|
|
21
|
+
function c(h) {
|
|
22
22
|
try {
|
|
23
23
|
a(r.next(h));
|
|
24
24
|
} catch (f) {
|
|
@@ -33,7 +33,7 @@ var B = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : ty
|
|
|
33
33
|
}
|
|
34
34
|
}
|
|
35
35
|
function a(h) {
|
|
36
|
-
h.done ? i(h.value) : s(h.value).then(
|
|
36
|
+
h.done ? i(h.value) : s(h.value).then(c, l);
|
|
37
37
|
}
|
|
38
38
|
a((r = r.apply(n, e || [])).next());
|
|
39
39
|
});
|
|
@@ -43,10 +43,10 @@ var B = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : ty
|
|
|
43
43
|
throw i[1];
|
|
44
44
|
return i[1];
|
|
45
45
|
}, trys: [], ops: [] }, r, s, i, o;
|
|
46
|
-
return o = { next:
|
|
46
|
+
return o = { next: c(0), throw: c(1), return: c(2) }, typeof Symbol == "function" && (o[Symbol.iterator] = function() {
|
|
47
47
|
return this;
|
|
48
48
|
}), o;
|
|
49
|
-
function
|
|
49
|
+
function c(a) {
|
|
50
50
|
return function(h) {
|
|
51
51
|
return l([a, h]);
|
|
52
52
|
};
|
|
@@ -171,7 +171,7 @@ var ht = {}, z = B && B.__assign || function() {
|
|
|
171
171
|
});
|
|
172
172
|
}
|
|
173
173
|
return new (t || (t = Promise))(function(i, o) {
|
|
174
|
-
function
|
|
174
|
+
function c(h) {
|
|
175
175
|
try {
|
|
176
176
|
a(r.next(h));
|
|
177
177
|
} catch (f) {
|
|
@@ -186,7 +186,7 @@ var ht = {}, z = B && B.__assign || function() {
|
|
|
186
186
|
}
|
|
187
187
|
}
|
|
188
188
|
function a(h) {
|
|
189
|
-
h.done ? i(h.value) : s(h.value).then(
|
|
189
|
+
h.done ? i(h.value) : s(h.value).then(c, l);
|
|
190
190
|
}
|
|
191
191
|
a((r = r.apply(n, e || [])).next());
|
|
192
192
|
});
|
|
@@ -196,10 +196,10 @@ var ht = {}, z = B && B.__assign || function() {
|
|
|
196
196
|
throw i[1];
|
|
197
197
|
return i[1];
|
|
198
198
|
}, trys: [], ops: [] }, r, s, i, o;
|
|
199
|
-
return o = { next:
|
|
199
|
+
return o = { next: c(0), throw: c(1), return: c(2) }, typeof Symbol == "function" && (o[Symbol.iterator] = function() {
|
|
200
200
|
return this;
|
|
201
201
|
}), o;
|
|
202
|
-
function
|
|
202
|
+
function c(a) {
|
|
203
203
|
return function(h) {
|
|
204
204
|
return l([a, h]);
|
|
205
205
|
};
|
|
@@ -275,12 +275,12 @@ var ri = function() {
|
|
|
275
275
|
}, n.prototype.getDocList = function(e, t) {
|
|
276
276
|
var r;
|
|
277
277
|
return Fe(this, void 0, void 0, function() {
|
|
278
|
-
var s, i, o,
|
|
278
|
+
var s, i, o, c, l, a, h, f, p, m, g;
|
|
279
279
|
return Ue(this, function(b) {
|
|
280
|
-
return s = {}, t && (i = t.fields, o = t.filters,
|
|
280
|
+
return s = {}, t && (i = t.fields, o = t.filters, c = t.orFilters, l = t.orderBy, a = t.limit, h = t.limit_start, f = t.groupBy, p = t.asDict, m = p === void 0 ? !0 : p, g = l ? "".concat(String(l == null ? void 0 : l.field), " ").concat((r = l == null ? void 0 : l.order) !== null && r !== void 0 ? r : "asc") : "", s = {
|
|
281
281
|
fields: i ? JSON.stringify(i) : void 0,
|
|
282
282
|
filters: o ? JSON.stringify(o) : void 0,
|
|
283
|
-
or_filters:
|
|
283
|
+
or_filters: c ? JSON.stringify(c) : void 0,
|
|
284
284
|
order_by: g,
|
|
285
285
|
group_by: f,
|
|
286
286
|
limit: a,
|
|
@@ -300,8 +300,8 @@ var ri = function() {
|
|
|
300
300
|
return [2, this.axios.post("/api/resource/".concat(e), z({}, t)).then(function(s) {
|
|
301
301
|
return s.data.data;
|
|
302
302
|
}).catch(function(s) {
|
|
303
|
-
var i, o,
|
|
304
|
-
throw z(z({}, s.response.data), { httpStatus: s.response.status, httpStatusText: s.response.statusText, message: (i = s.response.data.message) !== null && i !== void 0 ? i : "There was an error while creating the document.", exception: (
|
|
303
|
+
var i, o, c;
|
|
304
|
+
throw z(z({}, s.response.data), { httpStatus: s.response.status, httpStatusText: s.response.statusText, message: (i = s.response.data.message) !== null && i !== void 0 ? i : "There was an error while creating the document.", exception: (c = (o = s.response.data.exception) !== null && o !== void 0 ? o : s.response.data.exc_type) !== null && c !== void 0 ? c : "" });
|
|
305
305
|
})];
|
|
306
306
|
});
|
|
307
307
|
});
|
|
@@ -311,8 +311,8 @@ var ri = function() {
|
|
|
311
311
|
return [2, this.axios.put("/api/resource/".concat(e, "/").concat(t), z({}, r)).then(function(i) {
|
|
312
312
|
return i.data.data;
|
|
313
313
|
}).catch(function(i) {
|
|
314
|
-
var o,
|
|
315
|
-
throw z(z({}, i.response.data), { httpStatus: i.response.status, httpStatusText: i.response.statusText, message: (o = i.response.data.message) !== null && o !== void 0 ? o : "There was an error while updating the document.", exception: (l = (
|
|
314
|
+
var o, c, l;
|
|
315
|
+
throw z(z({}, i.response.data), { httpStatus: i.response.status, httpStatusText: i.response.statusText, message: (o = i.response.data.message) !== null && o !== void 0 ? o : "There was an error while updating the document.", exception: (l = (c = i.response.data.exception) !== null && c !== void 0 ? c : i.response.data.exc_type) !== null && l !== void 0 ? l : "" });
|
|
316
316
|
})];
|
|
317
317
|
});
|
|
318
318
|
});
|
|
@@ -334,11 +334,11 @@ var ri = function() {
|
|
|
334
334
|
return i = {
|
|
335
335
|
doctype: e,
|
|
336
336
|
filters: []
|
|
337
|
-
}, r && (i.cache = r), s && (i.debug = s), t && (i.filters = t ? JSON.stringify(t) : void 0), [2, this.axios.get("/api/method/frappe.client.get_count", { params: i }).then(function(
|
|
338
|
-
return
|
|
339
|
-
}).catch(function(
|
|
337
|
+
}, r && (i.cache = r), s && (i.debug = s), t && (i.filters = t ? JSON.stringify(t) : void 0), [2, this.axios.get("/api/method/frappe.client.get_count", { params: i }).then(function(c) {
|
|
338
|
+
return c.data.message;
|
|
339
|
+
}).catch(function(c) {
|
|
340
340
|
var l, a;
|
|
341
|
-
throw z(z({},
|
|
341
|
+
throw z(z({}, c.response.data), { httpStatus: c.response.status, httpStatusText: c.response.statusText, message: "There was an error while getting the count.", exception: (a = (l = c.response.data.exception) !== null && l !== void 0 ? l : c.response.data.exc_type) !== null && a !== void 0 ? a : "" });
|
|
342
342
|
})];
|
|
343
343
|
});
|
|
344
344
|
});
|
|
@@ -378,7 +378,7 @@ var dt = {}, Ft = B && B.__assign || function() {
|
|
|
378
378
|
});
|
|
379
379
|
}
|
|
380
380
|
return new (t || (t = Promise))(function(i, o) {
|
|
381
|
-
function
|
|
381
|
+
function c(h) {
|
|
382
382
|
try {
|
|
383
383
|
a(r.next(h));
|
|
384
384
|
} catch (f) {
|
|
@@ -393,7 +393,7 @@ var dt = {}, Ft = B && B.__assign || function() {
|
|
|
393
393
|
}
|
|
394
394
|
}
|
|
395
395
|
function a(h) {
|
|
396
|
-
h.done ? i(h.value) : s(h.value).then(
|
|
396
|
+
h.done ? i(h.value) : s(h.value).then(c, l);
|
|
397
397
|
}
|
|
398
398
|
a((r = r.apply(n, e || [])).next());
|
|
399
399
|
});
|
|
@@ -403,10 +403,10 @@ var dt = {}, Ft = B && B.__assign || function() {
|
|
|
403
403
|
throw i[1];
|
|
404
404
|
return i[1];
|
|
405
405
|
}, trys: [], ops: [] }, r, s, i, o;
|
|
406
|
-
return o = { next:
|
|
406
|
+
return o = { next: c(0), throw: c(1), return: c(2) }, typeof Symbol == "function" && (o[Symbol.iterator] = function() {
|
|
407
407
|
return this;
|
|
408
408
|
}), o;
|
|
409
|
-
function
|
|
409
|
+
function c(a) {
|
|
410
410
|
return function(h) {
|
|
411
411
|
return l([a, h]);
|
|
412
412
|
};
|
|
@@ -470,9 +470,9 @@ var oi = function() {
|
|
|
470
470
|
}
|
|
471
471
|
return n.prototype.uploadFile = function(e, t, r, s) {
|
|
472
472
|
return s === void 0 && (s = "upload_file"), si(this, void 0, void 0, function() {
|
|
473
|
-
var i, o,
|
|
473
|
+
var i, o, c, l, a, h, f, p;
|
|
474
474
|
return ii(this, function(m) {
|
|
475
|
-
return i = new FormData(), e && i.append("file", e, e.name), o = t.isPrivate,
|
|
475
|
+
return i = new FormData(), e && i.append("file", e, e.name), o = t.isPrivate, c = t.folder, l = t.file_url, a = t.doctype, h = t.docname, f = t.fieldname, p = t.otherData, o && i.append("is_private", "1"), c && i.append("folder", c), l && i.append("file_url", l), a && h && (i.append("doctype", a), i.append("docname", h), f && i.append("fieldname", f)), p && Object.keys(p).forEach(function(g) {
|
|
476
476
|
var b = p[g];
|
|
477
477
|
i.append(g, b);
|
|
478
478
|
}), [2, this.axios.post("/api/method/".concat(s), i, {
|
|
@@ -678,8 +678,8 @@ function ss() {
|
|
|
678
678
|
ir = 1;
|
|
679
679
|
var n = ns;
|
|
680
680
|
return Kt = function(t, r, s, i, o) {
|
|
681
|
-
var
|
|
682
|
-
return n(
|
|
681
|
+
var c = new Error(t);
|
|
682
|
+
return n(c, r, s, i, o);
|
|
683
683
|
}, Kt;
|
|
684
684
|
}
|
|
685
685
|
var Gt, or;
|
|
@@ -707,9 +707,9 @@ function xi() {
|
|
|
707
707
|
var n = ae;
|
|
708
708
|
return Xt = n.isStandardBrowserEnv() ? function() {
|
|
709
709
|
return {
|
|
710
|
-
write: function(r, s, i, o,
|
|
710
|
+
write: function(r, s, i, o, c, l) {
|
|
711
711
|
var a = [];
|
|
712
|
-
a.push(r + "=" + encodeURIComponent(s)), n.isNumber(i) && a.push("expires=" + new Date(i).toGMTString()), n.isString(o) && a.push("path=" + o), n.isString(
|
|
712
|
+
a.push(r + "=" + encodeURIComponent(s)), n.isNumber(i) && a.push("expires=" + new Date(i).toGMTString()), n.isString(o) && a.push("path=" + o), n.isString(c) && a.push("domain=" + c), l === !0 && a.push("secure"), document.cookie = a.join("; ");
|
|
713
713
|
},
|
|
714
714
|
read: function(r) {
|
|
715
715
|
var s = document.cookie.match(new RegExp("(^|;\\s*)(" + r + ")=([^;]*)"));
|
|
@@ -778,10 +778,10 @@ function ki() {
|
|
|
778
778
|
"user-agent"
|
|
779
779
|
];
|
|
780
780
|
return tn = function(r) {
|
|
781
|
-
var s = {}, i, o,
|
|
781
|
+
var s = {}, i, o, c;
|
|
782
782
|
return r && n.forEach(r.split(`
|
|
783
783
|
`), function(a) {
|
|
784
|
-
if (
|
|
784
|
+
if (c = a.indexOf(":"), i = n.trim(a.substr(0, c)).toLowerCase(), o = n.trim(a.substr(c + 1)), i) {
|
|
785
785
|
if (s[i] && e.indexOf(i) >= 0)
|
|
786
786
|
return;
|
|
787
787
|
i === "set-cookie" ? s[i] = (s[i] ? s[i] : []).concat([o]) : s[i] = s[i] ? s[i] + ", " + o : o;
|
|
@@ -798,8 +798,8 @@ function Li() {
|
|
|
798
798
|
return nn = n.isStandardBrowserEnv() ? function() {
|
|
799
799
|
var t = /(msie|trident)/i.test(navigator.userAgent), r = document.createElement("a"), s;
|
|
800
800
|
function i(o) {
|
|
801
|
-
var
|
|
802
|
-
return t && (r.setAttribute("href",
|
|
801
|
+
var c = o;
|
|
802
|
+
return t && (r.setAttribute("href", c), c = r.href), r.setAttribute("href", c), {
|
|
803
803
|
href: r.href,
|
|
804
804
|
protocol: r.protocol ? r.protocol.replace(/:$/, "") : "",
|
|
805
805
|
host: r.host,
|
|
@@ -810,8 +810,8 @@ function Li() {
|
|
|
810
810
|
pathname: r.pathname.charAt(0) === "/" ? r.pathname : "/" + r.pathname
|
|
811
811
|
};
|
|
812
812
|
}
|
|
813
|
-
return s = i(window.location.href), function(
|
|
814
|
-
var l = n.isString(
|
|
813
|
+
return s = i(window.location.href), function(c) {
|
|
814
|
+
var l = n.isString(c) ? i(c) : c;
|
|
815
815
|
return l.protocol === s.protocol && l.host === s.host;
|
|
816
816
|
};
|
|
817
817
|
}() : function() {
|
|
@@ -837,7 +837,7 @@ function vr() {
|
|
|
837
837
|
if (pr)
|
|
838
838
|
return sn;
|
|
839
839
|
pr = 1;
|
|
840
|
-
var n = ae, e = Oi(), t = xi(), r = ts, s = Di(), i = ki(), o = Li(),
|
|
840
|
+
var n = ae, e = Oi(), t = xi(), r = ts, s = Di(), i = ki(), o = Li(), c = ss(), l = rs, a = qt();
|
|
841
841
|
return sn = function(f) {
|
|
842
842
|
return new Promise(function(m, g) {
|
|
843
843
|
var b = f.data, E = f.headers, _ = f.responseType, S;
|
|
@@ -872,12 +872,12 @@ function vr() {
|
|
|
872
872
|
if ("onloadend" in y ? y.onloadend = D : y.onreadystatechange = function() {
|
|
873
873
|
!y || y.readyState !== 4 || y.status === 0 && !(y.responseURL && y.responseURL.indexOf("file:") === 0) || setTimeout(D);
|
|
874
874
|
}, y.onabort = function() {
|
|
875
|
-
!y || (g(
|
|
875
|
+
!y || (g(c("Request aborted", f, "ECONNABORTED", y)), y = null);
|
|
876
876
|
}, y.onerror = function() {
|
|
877
|
-
g(
|
|
877
|
+
g(c("Network Error", f, null, y)), y = null;
|
|
878
878
|
}, y.ontimeout = function() {
|
|
879
879
|
var Q = f.timeout ? "timeout of " + f.timeout + "ms exceeded" : "timeout exceeded", ne = f.transitional || l;
|
|
880
|
-
f.timeoutErrorMessage && (Q = f.timeoutErrorMessage), g(
|
|
880
|
+
f.timeoutErrorMessage && (Q = f.timeoutErrorMessage), g(c(
|
|
881
881
|
Q,
|
|
882
882
|
f,
|
|
883
883
|
ne.clarifyTimeoutError ? "ETIMEDOUT" : "ECONNABORTED",
|
|
@@ -1017,7 +1017,7 @@ var Wi = function(e) {
|
|
|
1017
1017
|
if (!ue.isUndefined(t[h]))
|
|
1018
1018
|
return s(void 0, t[h]);
|
|
1019
1019
|
}
|
|
1020
|
-
function
|
|
1020
|
+
function c(h) {
|
|
1021
1021
|
if (ue.isUndefined(t[h])) {
|
|
1022
1022
|
if (!ue.isUndefined(e[h]))
|
|
1023
1023
|
return s(void 0, e[h]);
|
|
@@ -1034,28 +1034,28 @@ var Wi = function(e) {
|
|
|
1034
1034
|
url: o,
|
|
1035
1035
|
method: o,
|
|
1036
1036
|
data: o,
|
|
1037
|
-
baseURL:
|
|
1038
|
-
transformRequest:
|
|
1039
|
-
transformResponse:
|
|
1040
|
-
paramsSerializer:
|
|
1041
|
-
timeout:
|
|
1042
|
-
timeoutMessage:
|
|
1043
|
-
withCredentials:
|
|
1044
|
-
adapter:
|
|
1045
|
-
responseType:
|
|
1046
|
-
xsrfCookieName:
|
|
1047
|
-
xsrfHeaderName:
|
|
1048
|
-
onUploadProgress:
|
|
1049
|
-
onDownloadProgress:
|
|
1050
|
-
decompress:
|
|
1051
|
-
maxContentLength:
|
|
1052
|
-
maxBodyLength:
|
|
1053
|
-
transport:
|
|
1054
|
-
httpAgent:
|
|
1055
|
-
httpsAgent:
|
|
1056
|
-
cancelToken:
|
|
1057
|
-
socketPath:
|
|
1058
|
-
responseEncoding:
|
|
1037
|
+
baseURL: c,
|
|
1038
|
+
transformRequest: c,
|
|
1039
|
+
transformResponse: c,
|
|
1040
|
+
paramsSerializer: c,
|
|
1041
|
+
timeout: c,
|
|
1042
|
+
timeoutMessage: c,
|
|
1043
|
+
withCredentials: c,
|
|
1044
|
+
adapter: c,
|
|
1045
|
+
responseType: c,
|
|
1046
|
+
xsrfCookieName: c,
|
|
1047
|
+
xsrfHeaderName: c,
|
|
1048
|
+
onUploadProgress: c,
|
|
1049
|
+
onDownloadProgress: c,
|
|
1050
|
+
decompress: c,
|
|
1051
|
+
maxContentLength: c,
|
|
1052
|
+
maxBodyLength: c,
|
|
1053
|
+
transport: c,
|
|
1054
|
+
httpAgent: c,
|
|
1055
|
+
httpsAgent: c,
|
|
1056
|
+
cancelToken: c,
|
|
1057
|
+
socketPath: c,
|
|
1058
|
+
responseEncoding: c,
|
|
1059
1059
|
validateStatus: l
|
|
1060
1060
|
};
|
|
1061
1061
|
return ue.forEach(Object.keys(e).concat(Object.keys(t)), function(f) {
|
|
@@ -1079,7 +1079,7 @@ Vn.transitional = function(e, t, r) {
|
|
|
1079
1079
|
function s(i, o) {
|
|
1080
1080
|
return "[Axios v" + Hi + "] Transitional option '" + i + "'" + o + (r ? ". " + r : "");
|
|
1081
1081
|
}
|
|
1082
|
-
return function(i, o,
|
|
1082
|
+
return function(i, o, c) {
|
|
1083
1083
|
if (e === !1)
|
|
1084
1084
|
throw new Error(s(o, " has been removed" + (t ? " in " + t : "")));
|
|
1085
1085
|
return t && !wr[o] && (wr[o] = !0, console.warn(
|
|
@@ -1087,7 +1087,7 @@ Vn.transitional = function(e, t, r) {
|
|
|
1087
1087
|
o,
|
|
1088
1088
|
" has been deprecated since v" + t + " and will be removed in the near future"
|
|
1089
1089
|
)
|
|
1090
|
-
)), e ? e(i, o,
|
|
1090
|
+
)), e ? e(i, o, c) : !0;
|
|
1091
1091
|
};
|
|
1092
1092
|
};
|
|
1093
1093
|
function Ji(n, e, t) {
|
|
@@ -1096,7 +1096,7 @@ function Ji(n, e, t) {
|
|
|
1096
1096
|
for (var r = Object.keys(n), s = r.length; s-- > 0; ) {
|
|
1097
1097
|
var i = r[s], o = e[i];
|
|
1098
1098
|
if (o) {
|
|
1099
|
-
var
|
|
1099
|
+
var c = n[i], l = c === void 0 || o(c, i, n);
|
|
1100
1100
|
if (l !== !0)
|
|
1101
1101
|
throw new TypeError("option " + i + " must be " + l);
|
|
1102
1102
|
continue;
|
|
@@ -1131,12 +1131,12 @@ pt.prototype.request = function(e, t) {
|
|
|
1131
1131
|
this.interceptors.response.forEach(function(m) {
|
|
1132
1132
|
o.push(m.fulfilled, m.rejected);
|
|
1133
1133
|
});
|
|
1134
|
-
var
|
|
1134
|
+
var c;
|
|
1135
1135
|
if (!i) {
|
|
1136
1136
|
var l = [Rr, void 0];
|
|
1137
|
-
for (Array.prototype.unshift.apply(l, s), l = l.concat(o),
|
|
1138
|
-
|
|
1139
|
-
return
|
|
1137
|
+
for (Array.prototype.unshift.apply(l, s), l = l.concat(o), c = Promise.resolve(t); l.length; )
|
|
1138
|
+
c = c.then(l.shift(), l.shift());
|
|
1139
|
+
return c;
|
|
1140
1140
|
}
|
|
1141
1141
|
for (var a = t; s.length; ) {
|
|
1142
1142
|
var h = s.shift(), f = s.shift();
|
|
@@ -1148,13 +1148,13 @@ pt.prototype.request = function(e, t) {
|
|
|
1148
1148
|
}
|
|
1149
1149
|
}
|
|
1150
1150
|
try {
|
|
1151
|
-
|
|
1151
|
+
c = Rr(a);
|
|
1152
1152
|
} catch (p) {
|
|
1153
1153
|
return Promise.reject(p);
|
|
1154
1154
|
}
|
|
1155
1155
|
for (; o.length; )
|
|
1156
|
-
|
|
1157
|
-
return
|
|
1156
|
+
c = c.then(o.shift(), o.shift());
|
|
1157
|
+
return c;
|
|
1158
1158
|
};
|
|
1159
1159
|
pt.prototype.getUri = function(e) {
|
|
1160
1160
|
return e = Vt(this.defaults, e), zi(e.url, e.params, e.paramsSerializer).replace(/^\?/, "");
|
|
@@ -1193,18 +1193,18 @@ function Gi() {
|
|
|
1193
1193
|
var s = this;
|
|
1194
1194
|
this.promise.then(function(i) {
|
|
1195
1195
|
if (!!s._listeners) {
|
|
1196
|
-
var o,
|
|
1197
|
-
for (o = 0; o <
|
|
1196
|
+
var o, c = s._listeners.length;
|
|
1197
|
+
for (o = 0; o < c; o++)
|
|
1198
1198
|
s._listeners[o](i);
|
|
1199
1199
|
s._listeners = null;
|
|
1200
1200
|
}
|
|
1201
1201
|
}), this.promise.then = function(i) {
|
|
1202
|
-
var o,
|
|
1202
|
+
var o, c = new Promise(function(l) {
|
|
1203
1203
|
s.subscribe(l), o = l;
|
|
1204
1204
|
}).then(i);
|
|
1205
|
-
return
|
|
1205
|
+
return c.cancel = function() {
|
|
1206
1206
|
s.unsubscribe(o);
|
|
1207
|
-
},
|
|
1207
|
+
}, c;
|
|
1208
1208
|
}, t(function(o) {
|
|
1209
1209
|
s.reason || (s.reason = new n(o), r(s.reason));
|
|
1210
1210
|
});
|
|
@@ -1300,9 +1300,9 @@ function so() {
|
|
|
1300
1300
|
return rt;
|
|
1301
1301
|
Cr = 1, Object.defineProperty(rt, "__esModule", { value: !0 }), rt.FrappeApp = void 0;
|
|
1302
1302
|
var n = hs(), e = ft, t = ht, r = dt, s = Ke, i = function() {
|
|
1303
|
-
function o(
|
|
1303
|
+
function o(c, l, a) {
|
|
1304
1304
|
var h, f;
|
|
1305
|
-
this.url =
|
|
1305
|
+
this.url = c, this.name = a != null ? a : "FrappeApp", this.useToken = (h = l == null ? void 0 : l.useToken) !== null && h !== void 0 ? h : !1, this.token = l == null ? void 0 : l.token, this.tokenType = (f = l == null ? void 0 : l.type) !== null && f !== void 0 ? f : "Bearer", this.axios = (0, s.getAxiosClient)(this.url, this.useToken, this.token, this.tokenType);
|
|
1306
1306
|
}
|
|
1307
1307
|
return o.prototype.auth = function() {
|
|
1308
1308
|
return new n.FrappeAuth(this.url, this.axios, this.useToken, this.token, this.tokenType);
|
|
@@ -1332,7 +1332,7 @@ var jt = {}, ye = B && B.__assign || function() {
|
|
|
1332
1332
|
});
|
|
1333
1333
|
}
|
|
1334
1334
|
return new (t || (t = Promise))(function(i, o) {
|
|
1335
|
-
function
|
|
1335
|
+
function c(h) {
|
|
1336
1336
|
try {
|
|
1337
1337
|
a(r.next(h));
|
|
1338
1338
|
} catch (f) {
|
|
@@ -1347,7 +1347,7 @@ var jt = {}, ye = B && B.__assign || function() {
|
|
|
1347
1347
|
}
|
|
1348
1348
|
}
|
|
1349
1349
|
function a(h) {
|
|
1350
|
-
h.done ? i(h.value) : s(h.value).then(
|
|
1350
|
+
h.done ? i(h.value) : s(h.value).then(c, l);
|
|
1351
1351
|
}
|
|
1352
1352
|
a((r = r.apply(n, e || [])).next());
|
|
1353
1353
|
});
|
|
@@ -1357,10 +1357,10 @@ var jt = {}, ye = B && B.__assign || function() {
|
|
|
1357
1357
|
throw i[1];
|
|
1358
1358
|
return i[1];
|
|
1359
1359
|
}, trys: [], ops: [] }, r, s, i, o;
|
|
1360
|
-
return o = { next:
|
|
1360
|
+
return o = { next: c(0), throw: c(1), return: c(2) }, typeof Symbol == "function" && (o[Symbol.iterator] = function() {
|
|
1361
1361
|
return this;
|
|
1362
1362
|
}), o;
|
|
1363
|
-
function
|
|
1363
|
+
function c(a) {
|
|
1364
1364
|
return function(h) {
|
|
1365
1365
|
return l([a, h]);
|
|
1366
1366
|
};
|
|
@@ -1424,17 +1424,18 @@ var io = function() {
|
|
|
1424
1424
|
}
|
|
1425
1425
|
return n.prototype.loginWithUsernamePassword = function(e) {
|
|
1426
1426
|
return Rt(this, void 0, void 0, function() {
|
|
1427
|
-
|
|
1428
|
-
|
|
1429
|
-
|
|
1430
|
-
|
|
1431
|
-
|
|
1432
|
-
|
|
1433
|
-
|
|
1434
|
-
|
|
1435
|
-
|
|
1436
|
-
|
|
1437
|
-
|
|
1427
|
+
return St(this, function(t) {
|
|
1428
|
+
return [2, this.axios.post("/api/method/login", {
|
|
1429
|
+
usr: e.username,
|
|
1430
|
+
pwd: e.password,
|
|
1431
|
+
otp: e.otp,
|
|
1432
|
+
tmp_id: e.tmp_id,
|
|
1433
|
+
device: e.device
|
|
1434
|
+
}).then(function(r) {
|
|
1435
|
+
return r.data;
|
|
1436
|
+
}).catch(function(r) {
|
|
1437
|
+
var s, i;
|
|
1438
|
+
throw ye(ye({}, r.response.data), { httpStatus: r.response.status, httpStatusText: r.response.statusText, message: (s = r.response.data.message) !== null && s !== void 0 ? s : "There was an error while logging in", exception: (i = r.response.data.exception) !== null && i !== void 0 ? i : "" });
|
|
1438
1439
|
})];
|
|
1439
1440
|
});
|
|
1440
1441
|
});
|
|
@@ -1480,10 +1481,10 @@ function hs() {
|
|
|
1480
1481
|
return Ar || (Ar = 1, function(n) {
|
|
1481
1482
|
var e = B && B.__createBinding || (Object.create ? function(r, s, i, o) {
|
|
1482
1483
|
o === void 0 && (o = i);
|
|
1483
|
-
var
|
|
1484
|
-
(!
|
|
1484
|
+
var c = Object.getOwnPropertyDescriptor(s, i);
|
|
1485
|
+
(!c || ("get" in c ? !s.__esModule : c.writable || c.configurable)) && (c = { enumerable: !0, get: function() {
|
|
1485
1486
|
return s[i];
|
|
1486
|
-
} }), Object.defineProperty(r, o,
|
|
1487
|
+
} }), Object.defineProperty(r, o, c);
|
|
1487
1488
|
} : function(r, s, i, o) {
|
|
1488
1489
|
o === void 0 && (o = i), r[o] = s[i];
|
|
1489
1490
|
}), t = B && B.__exportStar || function(r, s) {
|
|
@@ -1513,7 +1514,7 @@ function ao() {
|
|
|
1513
1514
|
return f === p && (f !== 0 || 1 / f === 1 / p) || f !== f && p !== p;
|
|
1514
1515
|
}
|
|
1515
1516
|
var t = typeof Object.is == "function" ? Object.is : e, r = n.useState, s = n.useEffect, i = n.useLayoutEffect, o = n.useDebugValue;
|
|
1516
|
-
function
|
|
1517
|
+
function c(f, p) {
|
|
1517
1518
|
var m = p(), g = r({ inst: { value: m, getSnapshot: p } }), b = g[0].inst, E = g[1];
|
|
1518
1519
|
return i(function() {
|
|
1519
1520
|
b.value = m, b.getSnapshot = p, l(b) && E({ inst: b });
|
|
@@ -1536,7 +1537,7 @@ function ao() {
|
|
|
1536
1537
|
function a(f, p) {
|
|
1537
1538
|
return p();
|
|
1538
1539
|
}
|
|
1539
|
-
var h = typeof window > "u" || typeof window.document > "u" || typeof window.document.createElement > "u" ? a :
|
|
1540
|
+
var h = typeof window > "u" || typeof window.document > "u" || typeof window.document.createElement > "u" ? a : c;
|
|
1540
1541
|
return dn.useSyncExternalStore = n.useSyncExternalStore !== void 0 ? n.useSyncExternalStore : h, dn;
|
|
1541
1542
|
}
|
|
1542
1543
|
var pn = {};
|
|
@@ -1574,7 +1575,7 @@ function uo() {
|
|
|
1574
1575
|
function s(k, y) {
|
|
1575
1576
|
return k === y && (k !== 0 || 1 / k === 1 / y) || k !== k && y !== y;
|
|
1576
1577
|
}
|
|
1577
|
-
var i = typeof Object.is == "function" ? Object.is : s, o = n.useState,
|
|
1578
|
+
var i = typeof Object.is == "function" ? Object.is : s, o = n.useState, c = n.useEffect, l = n.useLayoutEffect, a = n.useDebugValue, h = !1, f = !1;
|
|
1578
1579
|
function p(k, y, M) {
|
|
1579
1580
|
h || n.startTransition !== void 0 && (h = !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."));
|
|
1580
1581
|
var T = y();
|
|
@@ -1592,7 +1593,7 @@ function uo() {
|
|
|
1592
1593
|
j.value = T, j.getSnapshot = y, m(j) && L({
|
|
1593
1594
|
inst: j
|
|
1594
1595
|
});
|
|
1595
|
-
}, [k, T, y]),
|
|
1596
|
+
}, [k, T, y]), c(function() {
|
|
1596
1597
|
m(j) && L({
|
|
1597
1598
|
inst: j
|
|
1598
1599
|
});
|
|
@@ -1724,9 +1725,9 @@ async function gs(...n) {
|
|
|
1724
1725
|
revalidate: s
|
|
1725
1726
|
} : s || {});
|
|
1726
1727
|
let o = i.populateCache;
|
|
1727
|
-
const
|
|
1728
|
+
const c = i.rollbackOnError;
|
|
1728
1729
|
let l = i.optimisticData;
|
|
1729
|
-
const a = i.revalidate !== !1, h = (m) => typeof
|
|
1730
|
+
const a = i.revalidate !== !1, h = (m) => typeof c == "function" ? c(m) : c !== !1, f = i.throwOnError;
|
|
1730
1731
|
if (Oe(t)) {
|
|
1731
1732
|
const m = t, g = [], b = e.keys();
|
|
1732
1733
|
for (const E of b)
|
|
@@ -1805,7 +1806,7 @@ const Pr = (n, e) => {
|
|
|
1805
1806
|
if (!Te.has(n)) {
|
|
1806
1807
|
const t = De(go, e), r = {}, s = gs.bind(oe, n);
|
|
1807
1808
|
let i = Ae;
|
|
1808
|
-
const o = {},
|
|
1809
|
+
const o = {}, c = (h, f) => {
|
|
1809
1810
|
const p = o[h] || [];
|
|
1810
1811
|
return o[h] = p, p.push(f), () => p.splice(p.indexOf(f), 1);
|
|
1811
1812
|
}, l = (h, f, p) => {
|
|
@@ -1822,7 +1823,7 @@ const Pr = (n, e) => {
|
|
|
1822
1823
|
{},
|
|
1823
1824
|
s,
|
|
1824
1825
|
l,
|
|
1825
|
-
|
|
1826
|
+
c
|
|
1826
1827
|
]), !lt)) {
|
|
1827
1828
|
const h = t.initFocus(setTimeout.bind(oe, Pr.bind(oe, r, vs))), f = t.initReconnect(setTimeout.bind(oe, Pr.bind(oe, r, ys)));
|
|
1828
1829
|
i = () => {
|
|
@@ -1842,8 +1843,8 @@ const Pr = (n, e) => {
|
|
|
1842
1843
|
Te.get(n)[4]
|
|
1843
1844
|
];
|
|
1844
1845
|
}, Ro = (n, e, t, r, s) => {
|
|
1845
|
-
const i = t.errorRetryCount, o = s.retryCount,
|
|
1846
|
-
!C(i) && o > i || setTimeout(r,
|
|
1846
|
+
const i = t.errorRetryCount, o = s.retryCount, c = ~~((Math.random() + 0.5) * (1 << (o < 8 ? o : 8))) * t.errorRetryInterval;
|
|
1847
|
+
!C(i) && o > i || setTimeout(r, c, s);
|
|
1847
1848
|
}, So = (n, e) => ct(n) == ct(e), [_s, To] = Eo(/* @__PURE__ */ new Map()), Oo = De(
|
|
1848
1849
|
{
|
|
1849
1850
|
onLoadingSlow: Ae,
|
|
@@ -1884,18 +1885,18 @@ const Pr = (n, e) => {
|
|
|
1884
1885
|
null,
|
|
1885
1886
|
(n[1] === null ? n[2] : n[1]) || {}
|
|
1886
1887
|
], No = () => De(Oo, ee(Co)), Po = (n) => (e, t, r) => n(e, t && ((...i) => {
|
|
1887
|
-
const [o] = $n(e), [, , ,
|
|
1888
|
+
const [o] = $n(e), [, , , c] = Te.get(_s);
|
|
1888
1889
|
if (o.startsWith(Ao))
|
|
1889
1890
|
return t(...i);
|
|
1890
|
-
const l =
|
|
1891
|
-
return C(l) ? t(...i) : (delete
|
|
1891
|
+
const l = c[o];
|
|
1892
|
+
return C(l) ? t(...i) : (delete c[o], l);
|
|
1892
1893
|
}), r), Bo = Do.concat(Po), Fo = (n) => function(...t) {
|
|
1893
|
-
const r = No(), [s, i, o] = Lo(t),
|
|
1894
|
+
const r = No(), [s, i, o] = Lo(t), c = xo(r, o);
|
|
1894
1895
|
let l = n;
|
|
1895
|
-
const { use: a } =
|
|
1896
|
+
const { use: a } = c, h = (a || []).concat(Bo);
|
|
1896
1897
|
for (let f = h.length; f--; )
|
|
1897
1898
|
l = h[f](l);
|
|
1898
|
-
return l(s, i ||
|
|
1899
|
+
return l(s, i || c.fetcher || null, c);
|
|
1899
1900
|
}, Uo = (n, e, t) => {
|
|
1900
1901
|
const r = e[n] || (e[n] = []);
|
|
1901
1902
|
return r.push(t), () => {
|
|
@@ -1917,7 +1918,7 @@ const Br = qe.use || ((n) => {
|
|
|
1917
1918
|
}), _n = {
|
|
1918
1919
|
dedupe: !0
|
|
1919
1920
|
}, qo = (n, e, t) => {
|
|
1920
|
-
const { cache: r, compare: s, suspense: i, fallbackData: o, revalidateOnMount:
|
|
1921
|
+
const { cache: r, compare: s, suspense: i, fallbackData: o, revalidateOnMount: c, revalidateIfStale: l, refreshInterval: a, refreshWhenHidden: h, refreshWhenOffline: f, keepPreviousData: p } = t, [m, g, b, E] = Te.get(r), [_, S] = $n(n), k = Be(!1), y = Be(!1), M = Be(_), T = Be(e), V = Be(t), D = () => V.current, j = () => D().isVisible() && D().isOnline(), [L, Q, ne, G] = ps(r, _), F = Be({}).current, Le = C(o) ? t.fallback[_] : o, Qe = (N, U) => {
|
|
1921
1922
|
for (const X in F) {
|
|
1922
1923
|
const I = X;
|
|
1923
1924
|
if (I === "data") {
|
|
@@ -1928,7 +1929,7 @@ const Br = qe.use || ((n) => {
|
|
|
1928
1929
|
}
|
|
1929
1930
|
return !0;
|
|
1930
1931
|
}, Ze = Kr(() => {
|
|
1931
|
-
const N = (() => !_ || !e ? !1 : C(
|
|
1932
|
+
const N = (() => !_ || !e ? !1 : C(c) ? D().isPaused() || i ? !1 : C(l) ? !0 : l : c)(), U = (J) => {
|
|
1932
1933
|
const de = De(J);
|
|
1933
1934
|
return delete de._k, N ? {
|
|
1934
1935
|
isValidating: !0,
|
|
@@ -1955,7 +1956,7 @@ const Br = qe.use || ((n) => {
|
|
|
1955
1956
|
r,
|
|
1956
1957
|
_
|
|
1957
1958
|
]
|
|
1958
|
-
), Ze[0], Ze[1]), et = !k.current, yt = m[_] && m[_].length > 0, we = be.data, Ee = C(we) ? Le : we, Ne = be.error, mt = Be(Ee), Ie = p ? C(we) ? mt.current : we : Ee, Ve = (() => yt && !C(Ne) ? !1 : et && !C(
|
|
1959
|
+
), Ze[0], Ze[1]), et = !k.current, yt = m[_] && m[_].length > 0, we = be.data, Ee = C(we) ? Le : we, Ne = be.error, mt = Be(Ee), Ie = p ? C(we) ? mt.current : we : Ee, Ve = (() => yt && !C(Ne) ? !1 : et && !C(c) ? c : D().isPaused() ? !1 : i ? C(Ee) ? !1 : l : C(Ee) || l)(), je = !!(_ && e && et && Ve), $e = C(be.isValidating) ? je : be.isValidating, tt = C(be.isLoading) ? je : be.isLoading, ve = $(
|
|
1959
1960
|
async (N) => {
|
|
1960
1961
|
const U = T.current;
|
|
1961
1962
|
if (!_ || !U || y.current || D().isPaused())
|
|
@@ -2118,11 +2119,11 @@ const qr = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/", u
|
|
|
2118
2119
|
for (let n = 0; n < qr.length; n++)
|
|
2119
2120
|
ut[qr.charCodeAt(n)] = n;
|
|
2120
2121
|
const Vo = (n) => {
|
|
2121
|
-
let e = n.length * 0.75, t = n.length, r, s = 0, i, o,
|
|
2122
|
+
let e = n.length * 0.75, t = n.length, r, s = 0, i, o, c, l;
|
|
2122
2123
|
n[n.length - 1] === "=" && (e--, n[n.length - 2] === "=" && e--);
|
|
2123
2124
|
const a = new ArrayBuffer(e), h = new Uint8Array(a);
|
|
2124
2125
|
for (r = 0; r < t; r += 4)
|
|
2125
|
-
i = ut[n.charCodeAt(r)], o = ut[n.charCodeAt(r + 1)],
|
|
2126
|
+
i = ut[n.charCodeAt(r)], o = ut[n.charCodeAt(r + 1)], c = ut[n.charCodeAt(r + 2)], l = ut[n.charCodeAt(r + 3)], h[s++] = i << 2 | o >> 4, h[s++] = (o & 15) << 4 | c >> 2, h[s++] = (c & 3) << 6 | l & 63;
|
|
2126
2127
|
return a;
|
|
2127
2128
|
}, jo = typeof ArrayBuffer == "function", Wn = (n, e) => {
|
|
2128
2129
|
if (typeof n != "string")
|
|
@@ -2158,8 +2159,8 @@ const Vo = (n) => {
|
|
|
2158
2159
|
const t = n.length, r = new Array(t);
|
|
2159
2160
|
let s = 0;
|
|
2160
2161
|
n.forEach((i, o) => {
|
|
2161
|
-
Mn(i, !1, (
|
|
2162
|
-
r[o] =
|
|
2162
|
+
Mn(i, !1, (c) => {
|
|
2163
|
+
r[o] = c, ++s === t && e(r.join(Ts));
|
|
2163
2164
|
});
|
|
2164
2165
|
});
|
|
2165
2166
|
}, Wo = (n, e) => {
|
|
@@ -2211,7 +2212,7 @@ function Jo(n, e) {
|
|
|
2211
2212
|
const t = [];
|
|
2212
2213
|
let r = 0, s = -1, i = !1;
|
|
2213
2214
|
return new TransformStream({
|
|
2214
|
-
transform(o,
|
|
2215
|
+
transform(o, c) {
|
|
2215
2216
|
for (t.push(o); ; ) {
|
|
2216
2217
|
if (r === 0) {
|
|
2217
2218
|
if (xt(t) < 1)
|
|
@@ -2228,7 +2229,7 @@ function Jo(n, e) {
|
|
|
2228
2229
|
break;
|
|
2229
2230
|
const l = Ct(t, 8), a = new DataView(l.buffer, l.byteOffset, l.length), h = a.getUint32(0);
|
|
2230
2231
|
if (h > Math.pow(2, 53 - 32) - 1) {
|
|
2231
|
-
|
|
2232
|
+
c.enqueue(An);
|
|
2232
2233
|
break;
|
|
2233
2234
|
}
|
|
2234
2235
|
s = h * Math.pow(2, 32) + a.getUint32(4), r = 3;
|
|
@@ -2236,10 +2237,10 @@ function Jo(n, e) {
|
|
|
2236
2237
|
if (xt(t) < s)
|
|
2237
2238
|
break;
|
|
2238
2239
|
const l = Ct(t, s);
|
|
2239
|
-
|
|
2240
|
+
c.enqueue(Wn(i ? l : wn.decode(l), e)), r = 0;
|
|
2240
2241
|
}
|
|
2241
2242
|
if (s === 0 || s > n) {
|
|
2242
|
-
|
|
2243
|
+
c.enqueue(An);
|
|
2243
2244
|
break;
|
|
2244
2245
|
}
|
|
2245
2246
|
}
|
|
@@ -2646,9 +2647,9 @@ class ca extends Hn {
|
|
|
2646
2647
|
const t = Jo(Number.MAX_SAFE_INTEGER, this.socket.binaryType), r = e.readable.pipeThrough(t).getReader(), s = Ho();
|
|
2647
2648
|
s.readable.pipeTo(e.writable), this.writer = s.writable.getWriter();
|
|
2648
2649
|
const i = () => {
|
|
2649
|
-
r.read().then(({ done:
|
|
2650
|
-
|
|
2651
|
-
}).catch((
|
|
2650
|
+
r.read().then(({ done: c, value: l }) => {
|
|
2651
|
+
c || (this.onPacket(l), i());
|
|
2652
|
+
}).catch((c) => {
|
|
2652
2653
|
});
|
|
2653
2654
|
};
|
|
2654
2655
|
i();
|
|
@@ -2799,7 +2800,7 @@ class Ce extends K {
|
|
|
2799
2800
|
const p = new Error("probe error: " + f);
|
|
2800
2801
|
p.transport = t.name, i(), this.emitReserved("upgradeError", p);
|
|
2801
2802
|
};
|
|
2802
|
-
function
|
|
2803
|
+
function c() {
|
|
2803
2804
|
o("transport closed");
|
|
2804
2805
|
}
|
|
2805
2806
|
function l() {
|
|
@@ -2809,9 +2810,9 @@ class Ce extends K {
|
|
|
2809
2810
|
t && f.name !== t.name && i();
|
|
2810
2811
|
}
|
|
2811
2812
|
const h = () => {
|
|
2812
|
-
t.removeListener("open", s), t.removeListener("error", o), t.removeListener("close",
|
|
2813
|
+
t.removeListener("open", s), t.removeListener("error", o), t.removeListener("close", c), this.off("close", l), this.off("upgrading", a);
|
|
2813
2814
|
};
|
|
2814
|
-
t.once("open", s), t.once("error", o), t.once("close",
|
|
2815
|
+
t.once("open", s), t.once("error", o), t.once("close", c), this.once("close", l), this.once("upgrading", a), this.upgrades.indexOf("webtransport") !== -1 && e !== "webtransport" ? this.setTimeoutFn(() => {
|
|
2815
2816
|
r || t.open();
|
|
2816
2817
|
}, 200) : t.open();
|
|
2817
2818
|
}
|
|
@@ -3190,8 +3191,8 @@ class Ns extends K {
|
|
|
3190
3191
|
data: t
|
|
3191
3192
|
};
|
|
3192
3193
|
if (r.options = {}, r.options.compress = this.flags.compress !== !1, typeof t[t.length - 1] == "function") {
|
|
3193
|
-
const o = this.ids++,
|
|
3194
|
-
this._registerAckCallback(o,
|
|
3194
|
+
const o = this.ids++, c = t.pop();
|
|
3195
|
+
this._registerAckCallback(o, c), r.id = o;
|
|
3195
3196
|
}
|
|
3196
3197
|
const s = this.io.engine && this.io.engine.transport && this.io.engine.transport.writable;
|
|
3197
3198
|
return this.flags.volatile && (!s || !this.connected) || (this.connected ? (this.notifyOutgoingListeners(r), this.packet(r)) : this.sendBuffer.push(r)), this.flags = {}, this;
|
|
@@ -3216,7 +3217,7 @@ class Ns extends K {
|
|
|
3216
3217
|
emitWithAck(e, ...t) {
|
|
3217
3218
|
const r = this.flags.timeout !== void 0 || this._opts.ackTimeout !== void 0;
|
|
3218
3219
|
return new Promise((s, i) => {
|
|
3219
|
-
t.push((o,
|
|
3220
|
+
t.push((o, c) => r ? o ? i(o) : s(c) : s(o)), this.emit(e, ...t);
|
|
3220
3221
|
});
|
|
3221
3222
|
}
|
|
3222
3223
|
_addToQueue(e) {
|
|
@@ -3453,13 +3454,13 @@ class Pn extends K {
|
|
|
3453
3454
|
this._readyState = "opening", this.skipReconnect = !1;
|
|
3454
3455
|
const s = pe(t, "open", function() {
|
|
3455
3456
|
r.onopen(), e && e();
|
|
3456
|
-
}), i = (
|
|
3457
|
-
this.cleanup(), this._readyState = "closed", this.emitReserved("error",
|
|
3457
|
+
}), i = (c) => {
|
|
3458
|
+
this.cleanup(), this._readyState = "closed", this.emitReserved("error", c), e ? e(c) : this.maybeReconnectOnOpen();
|
|
3458
3459
|
}, o = pe(t, "error", i);
|
|
3459
3460
|
if (this._timeout !== !1) {
|
|
3460
|
-
const
|
|
3461
|
+
const c = this._timeout, l = this.setTimeoutFn(() => {
|
|
3461
3462
|
s(), i(new Error("timeout")), t.close();
|
|
3462
|
-
},
|
|
3463
|
+
}, c);
|
|
3463
3464
|
this.opts.autoUnref && l.unref(), this.subs.push(() => {
|
|
3464
3465
|
this.clearTimeoutFn(l);
|
|
3465
3466
|
});
|
|
@@ -3547,9 +3548,9 @@ class Pn extends K {
|
|
|
3547
3548
|
const it = {};
|
|
3548
3549
|
function Bt(n, e) {
|
|
3549
3550
|
typeof n == "object" && (e = n, n = void 0), e = e || {};
|
|
3550
|
-
const t = va(n, e.path || "/socket.io"), r = t.source, s = t.id, i = t.path, o = it[s] && i in it[s].nsps,
|
|
3551
|
+
const t = va(n, e.path || "/socket.io"), r = t.source, s = t.id, i = t.path, o = it[s] && i in it[s].nsps, c = e.forceNew || e["force new connection"] || e.multiplex === !1 || o;
|
|
3551
3552
|
let l;
|
|
3552
|
-
return
|
|
3553
|
+
return c ? l = new Pn(r, e) : (it[s] || (it[s] = new Pn(r, e)), l = it[s]), t.query && !e.query && (e.query = t.queryKey), l.socket(t.path, e);
|
|
3553
3554
|
}
|
|
3554
3555
|
Object.assign(Bt, {
|
|
3555
3556
|
Manager: Pn,
|
|
@@ -3568,8 +3569,8 @@ class Ca {
|
|
|
3568
3569
|
xe(this, "socket");
|
|
3569
3570
|
var i, o;
|
|
3570
3571
|
if (this.socket_port = r != null ? r : "9000", this.host = (i = window.location) == null ? void 0 : i.hostname, this.port = (o = window.location) != null && o.port ? `:${this.socket_port}` : "", this.protocol = this.port ? "http" : "https", e) {
|
|
3571
|
-
let
|
|
3572
|
-
|
|
3572
|
+
let c = new URL(e);
|
|
3573
|
+
c.port = "", r ? (c.port = r, this.url = c.toString()) : this.url = c.toString();
|
|
3573
3574
|
} else
|
|
3574
3575
|
this.url = `${this.protocol}://${this.host}${this.port}/`;
|
|
3575
3576
|
t && (this.url = `${this.url}${t}`), this.site_name = t, this.socket = Bt(`${this.url}`, {
|
|
@@ -3597,15 +3598,15 @@ function Aa() {
|
|
|
3597
3598
|
return ot;
|
|
3598
3599
|
Jr = 1;
|
|
3599
3600
|
var n = qe, e = Symbol.for("react.element"), t = Symbol.for("react.fragment"), r = Object.prototype.hasOwnProperty, s = n.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner, i = { key: !0, ref: !0, __self: !0, __source: !0 };
|
|
3600
|
-
function o(
|
|
3601
|
+
function o(c, l, a) {
|
|
3601
3602
|
var h, f = {}, p = null, m = null;
|
|
3602
3603
|
a !== void 0 && (p = "" + a), l.key !== void 0 && (p = "" + l.key), l.ref !== void 0 && (m = l.ref);
|
|
3603
3604
|
for (h in l)
|
|
3604
3605
|
r.call(l, h) && !i.hasOwnProperty(h) && (f[h] = l[h]);
|
|
3605
|
-
if (
|
|
3606
|
-
for (h in l =
|
|
3606
|
+
if (c && c.defaultProps)
|
|
3607
|
+
for (h in l = c.defaultProps, l)
|
|
3607
3608
|
f[h] === void 0 && (f[h] = l[h]);
|
|
3608
|
-
return { $$typeof: e, type:
|
|
3609
|
+
return { $$typeof: e, type: c, key: p, ref: m, props: f, _owner: s.current };
|
|
3609
3610
|
}
|
|
3610
3611
|
return ot.Fragment = t, ot.jsx = o, ot.jsxs = o, ot;
|
|
3611
3612
|
}
|
|
@@ -3622,54 +3623,54 @@ var at = {};
|
|
|
3622
3623
|
var Yr;
|
|
3623
3624
|
function Da() {
|
|
3624
3625
|
return Yr || (Yr = 1, process.env.NODE_ENV !== "production" && function() {
|
|
3625
|
-
var n = qe, e = Symbol.for("react.element"), t = Symbol.for("react.portal"), r = Symbol.for("react.fragment"), s = Symbol.for("react.strict_mode"), i = Symbol.for("react.profiler"), o = Symbol.for("react.provider"),
|
|
3626
|
-
function E(
|
|
3627
|
-
if (
|
|
3626
|
+
var n = qe, e = Symbol.for("react.element"), t = Symbol.for("react.portal"), r = Symbol.for("react.fragment"), s = Symbol.for("react.strict_mode"), i = Symbol.for("react.profiler"), o = Symbol.for("react.provider"), c = Symbol.for("react.context"), l = Symbol.for("react.forward_ref"), a = Symbol.for("react.suspense"), h = Symbol.for("react.suspense_list"), f = Symbol.for("react.memo"), p = Symbol.for("react.lazy"), m = Symbol.for("react.offscreen"), g = Symbol.iterator, b = "@@iterator";
|
|
3627
|
+
function E(u) {
|
|
3628
|
+
if (u === null || typeof u != "object")
|
|
3628
3629
|
return null;
|
|
3629
|
-
var d = g &&
|
|
3630
|
+
var d = g && u[g] || u[b];
|
|
3630
3631
|
return typeof d == "function" ? d : null;
|
|
3631
3632
|
}
|
|
3632
3633
|
var _ = n.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;
|
|
3633
|
-
function S(
|
|
3634
|
+
function S(u) {
|
|
3634
3635
|
{
|
|
3635
3636
|
for (var d = arguments.length, v = new Array(d > 1 ? d - 1 : 0), w = 1; w < d; w++)
|
|
3636
3637
|
v[w - 1] = arguments[w];
|
|
3637
|
-
k("error",
|
|
3638
|
+
k("error", u, v);
|
|
3638
3639
|
}
|
|
3639
3640
|
}
|
|
3640
|
-
function k(
|
|
3641
|
+
function k(u, d, v) {
|
|
3641
3642
|
{
|
|
3642
3643
|
var w = _.ReactDebugCurrentFrame, A = w.getStackAddendum();
|
|
3643
3644
|
A !== "" && (d += "%s", v = v.concat([A]));
|
|
3644
3645
|
var q = v.map(function(x) {
|
|
3645
3646
|
return String(x);
|
|
3646
3647
|
});
|
|
3647
|
-
q.unshift("Warning: " + d), Function.prototype.apply.call(console[
|
|
3648
|
+
q.unshift("Warning: " + d), Function.prototype.apply.call(console[u], console, q);
|
|
3648
3649
|
}
|
|
3649
3650
|
}
|
|
3650
3651
|
var y = !1, M = !1, T = !1, V = !1, D = !1, j;
|
|
3651
3652
|
j = Symbol.for("react.module.reference");
|
|
3652
|
-
function L(
|
|
3653
|
-
return !!(typeof
|
|
3653
|
+
function L(u) {
|
|
3654
|
+
return !!(typeof u == "string" || typeof u == "function" || u === r || u === i || D || u === s || u === a || u === h || V || u === m || y || M || T || typeof u == "object" && u !== null && (u.$$typeof === p || u.$$typeof === f || u.$$typeof === o || u.$$typeof === c || u.$$typeof === l || u.$$typeof === j || u.getModuleId !== void 0));
|
|
3654
3655
|
}
|
|
3655
|
-
function Q(
|
|
3656
|
-
var w =
|
|
3656
|
+
function Q(u, d, v) {
|
|
3657
|
+
var w = u.displayName;
|
|
3657
3658
|
if (w)
|
|
3658
3659
|
return w;
|
|
3659
3660
|
var A = d.displayName || d.name || "";
|
|
3660
3661
|
return A !== "" ? v + "(" + A + ")" : v;
|
|
3661
3662
|
}
|
|
3662
|
-
function ne(
|
|
3663
|
-
return
|
|
3663
|
+
function ne(u) {
|
|
3664
|
+
return u.displayName || "Context";
|
|
3664
3665
|
}
|
|
3665
|
-
function G(
|
|
3666
|
-
if (
|
|
3666
|
+
function G(u) {
|
|
3667
|
+
if (u == null)
|
|
3667
3668
|
return null;
|
|
3668
|
-
if (typeof
|
|
3669
|
-
return
|
|
3670
|
-
if (typeof
|
|
3671
|
-
return
|
|
3672
|
-
switch (
|
|
3669
|
+
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")
|
|
3670
|
+
return u.displayName || u.name || null;
|
|
3671
|
+
if (typeof u == "string")
|
|
3672
|
+
return u;
|
|
3673
|
+
switch (u) {
|
|
3673
3674
|
case r:
|
|
3674
3675
|
return "Fragment";
|
|
3675
3676
|
case t:
|
|
@@ -3683,21 +3684,21 @@ function Da() {
|
|
|
3683
3684
|
case h:
|
|
3684
3685
|
return "SuspenseList";
|
|
3685
3686
|
}
|
|
3686
|
-
if (typeof
|
|
3687
|
-
switch (
|
|
3688
|
-
case
|
|
3689
|
-
var d =
|
|
3687
|
+
if (typeof u == "object")
|
|
3688
|
+
switch (u.$$typeof) {
|
|
3689
|
+
case c:
|
|
3690
|
+
var d = u;
|
|
3690
3691
|
return ne(d) + ".Consumer";
|
|
3691
3692
|
case o:
|
|
3692
|
-
var v =
|
|
3693
|
+
var v = u;
|
|
3693
3694
|
return ne(v._context) + ".Provider";
|
|
3694
3695
|
case l:
|
|
3695
|
-
return Q(
|
|
3696
|
+
return Q(u, u.render, "ForwardRef");
|
|
3696
3697
|
case f:
|
|
3697
|
-
var w =
|
|
3698
|
-
return w !== null ? w : G(
|
|
3698
|
+
var w = u.displayName || null;
|
|
3699
|
+
return w !== null ? w : G(u.type) || "Memo";
|
|
3699
3700
|
case p: {
|
|
3700
|
-
var A =
|
|
3701
|
+
var A = u, q = A._payload, x = A._init;
|
|
3701
3702
|
try {
|
|
3702
3703
|
return G(x(q));
|
|
3703
3704
|
} catch {
|
|
@@ -3715,20 +3716,20 @@ function Da() {
|
|
|
3715
3716
|
{
|
|
3716
3717
|
if (Le === 0) {
|
|
3717
3718
|
Qe = console.log, Ze = console.info, be = console.warn, et = console.error, yt = console.group, we = console.groupCollapsed, Ee = console.groupEnd;
|
|
3718
|
-
var
|
|
3719
|
+
var u = {
|
|
3719
3720
|
configurable: !0,
|
|
3720
3721
|
enumerable: !0,
|
|
3721
3722
|
value: Ne,
|
|
3722
3723
|
writable: !0
|
|
3723
3724
|
};
|
|
3724
3725
|
Object.defineProperties(console, {
|
|
3725
|
-
info:
|
|
3726
|
-
log:
|
|
3727
|
-
warn:
|
|
3728
|
-
error:
|
|
3729
|
-
group:
|
|
3730
|
-
groupCollapsed:
|
|
3731
|
-
groupEnd:
|
|
3726
|
+
info: u,
|
|
3727
|
+
log: u,
|
|
3728
|
+
warn: u,
|
|
3729
|
+
error: u,
|
|
3730
|
+
group: u,
|
|
3731
|
+
groupCollapsed: u,
|
|
3732
|
+
groupEnd: u
|
|
3732
3733
|
});
|
|
3733
3734
|
}
|
|
3734
3735
|
Le++;
|
|
@@ -3737,31 +3738,31 @@ function Da() {
|
|
|
3737
3738
|
function Ie() {
|
|
3738
3739
|
{
|
|
3739
3740
|
if (Le--, Le === 0) {
|
|
3740
|
-
var
|
|
3741
|
+
var u = {
|
|
3741
3742
|
configurable: !0,
|
|
3742
3743
|
enumerable: !0,
|
|
3743
3744
|
writable: !0
|
|
3744
3745
|
};
|
|
3745
3746
|
Object.defineProperties(console, {
|
|
3746
|
-
log: F({},
|
|
3747
|
+
log: F({}, u, {
|
|
3747
3748
|
value: Qe
|
|
3748
3749
|
}),
|
|
3749
|
-
info: F({},
|
|
3750
|
+
info: F({}, u, {
|
|
3750
3751
|
value: Ze
|
|
3751
3752
|
}),
|
|
3752
|
-
warn: F({},
|
|
3753
|
+
warn: F({}, u, {
|
|
3753
3754
|
value: be
|
|
3754
3755
|
}),
|
|
3755
|
-
error: F({},
|
|
3756
|
+
error: F({}, u, {
|
|
3756
3757
|
value: et
|
|
3757
3758
|
}),
|
|
3758
|
-
group: F({},
|
|
3759
|
+
group: F({}, u, {
|
|
3759
3760
|
value: yt
|
|
3760
3761
|
}),
|
|
3761
|
-
groupCollapsed: F({},
|
|
3762
|
+
groupCollapsed: F({}, u, {
|
|
3762
3763
|
value: we
|
|
3763
3764
|
}),
|
|
3764
|
-
groupEnd: F({},
|
|
3765
|
+
groupEnd: F({}, u, {
|
|
3765
3766
|
value: Ee
|
|
3766
3767
|
})
|
|
3767
3768
|
});
|
|
@@ -3770,7 +3771,7 @@ function Da() {
|
|
|
3770
3771
|
}
|
|
3771
3772
|
}
|
|
3772
3773
|
var Ve = _.ReactCurrentDispatcher, je;
|
|
3773
|
-
function $e(
|
|
3774
|
+
function $e(u, d, v) {
|
|
3774
3775
|
{
|
|
3775
3776
|
if (je === void 0)
|
|
3776
3777
|
try {
|
|
@@ -3780,7 +3781,7 @@ function Da() {
|
|
|
3780
3781
|
je = w && w[1] || "";
|
|
3781
3782
|
}
|
|
3782
3783
|
return `
|
|
3783
|
-
` + je +
|
|
3784
|
+
` + je + u;
|
|
3784
3785
|
}
|
|
3785
3786
|
}
|
|
3786
3787
|
var tt = !1, ve;
|
|
@@ -3788,11 +3789,11 @@ function Da() {
|
|
|
3788
3789
|
var gt = typeof WeakMap == "function" ? WeakMap : Map;
|
|
3789
3790
|
ve = new gt();
|
|
3790
3791
|
}
|
|
3791
|
-
function N(
|
|
3792
|
-
if (!
|
|
3792
|
+
function N(u, d) {
|
|
3793
|
+
if (!u || tt)
|
|
3793
3794
|
return "";
|
|
3794
3795
|
{
|
|
3795
|
-
var v = ve.get(
|
|
3796
|
+
var v = ve.get(u);
|
|
3796
3797
|
if (v !== void 0)
|
|
3797
3798
|
return v;
|
|
3798
3799
|
}
|
|
@@ -3817,14 +3818,14 @@ function Da() {
|
|
|
3817
3818
|
} catch (Se) {
|
|
3818
3819
|
w = Se;
|
|
3819
3820
|
}
|
|
3820
|
-
Reflect.construct(
|
|
3821
|
+
Reflect.construct(u, [], x);
|
|
3821
3822
|
} else {
|
|
3822
3823
|
try {
|
|
3823
3824
|
x.call();
|
|
3824
3825
|
} catch (Se) {
|
|
3825
3826
|
w = Se;
|
|
3826
3827
|
}
|
|
3827
|
-
|
|
3828
|
+
u.call(x.prototype);
|
|
3828
3829
|
}
|
|
3829
3830
|
} else {
|
|
3830
3831
|
try {
|
|
@@ -3832,7 +3833,7 @@ function Da() {
|
|
|
3832
3833
|
} catch (Se) {
|
|
3833
3834
|
w = Se;
|
|
3834
3835
|
}
|
|
3835
|
-
|
|
3836
|
+
u();
|
|
3836
3837
|
}
|
|
3837
3838
|
} catch (Se) {
|
|
3838
3839
|
if (Se && w && typeof Se.stack == "string") {
|
|
@@ -3847,7 +3848,7 @@ function Da() {
|
|
|
3847
3848
|
if (W--, Y--, Y < 0 || R[W] !== se[Y]) {
|
|
3848
3849
|
var le = `
|
|
3849
3850
|
` + R[W].replace(" at new ", " at ");
|
|
3850
|
-
return
|
|
3851
|
+
return u.displayName && le.includes("<anonymous>") && (le = le.replace("<anonymous>", u.displayName)), typeof u == "function" && ve.set(u, le), le;
|
|
3851
3852
|
}
|
|
3852
3853
|
while (W >= 1 && Y >= 0);
|
|
3853
3854
|
break;
|
|
@@ -3856,37 +3857,37 @@ function Da() {
|
|
|
3856
3857
|
} finally {
|
|
3857
3858
|
tt = !1, Ve.current = q, Ie(), Error.prepareStackTrace = A;
|
|
3858
3859
|
}
|
|
3859
|
-
var Je =
|
|
3860
|
-
return typeof
|
|
3860
|
+
var Je = u ? u.displayName || u.name : "", rr = Je ? $e(Je) : "";
|
|
3861
|
+
return typeof u == "function" && ve.set(u, rr), rr;
|
|
3861
3862
|
}
|
|
3862
|
-
function U(
|
|
3863
|
-
return N(
|
|
3863
|
+
function U(u, d, v) {
|
|
3864
|
+
return N(u, !1);
|
|
3864
3865
|
}
|
|
3865
|
-
function X(
|
|
3866
|
-
var d =
|
|
3866
|
+
function X(u) {
|
|
3867
|
+
var d = u.prototype;
|
|
3867
3868
|
return !!(d && d.isReactComponent);
|
|
3868
3869
|
}
|
|
3869
|
-
function I(
|
|
3870
|
-
if (
|
|
3870
|
+
function I(u, d, v) {
|
|
3871
|
+
if (u == null)
|
|
3871
3872
|
return "";
|
|
3872
|
-
if (typeof
|
|
3873
|
-
return N(
|
|
3874
|
-
if (typeof
|
|
3875
|
-
return $e(
|
|
3876
|
-
switch (
|
|
3873
|
+
if (typeof u == "function")
|
|
3874
|
+
return N(u, X(u));
|
|
3875
|
+
if (typeof u == "string")
|
|
3876
|
+
return $e(u);
|
|
3877
|
+
switch (u) {
|
|
3877
3878
|
case a:
|
|
3878
3879
|
return $e("Suspense");
|
|
3879
3880
|
case h:
|
|
3880
3881
|
return $e("SuspenseList");
|
|
3881
3882
|
}
|
|
3882
|
-
if (typeof
|
|
3883
|
-
switch (
|
|
3883
|
+
if (typeof u == "object")
|
|
3884
|
+
switch (u.$$typeof) {
|
|
3884
3885
|
case l:
|
|
3885
|
-
return U(
|
|
3886
|
+
return U(u.render);
|
|
3886
3887
|
case f:
|
|
3887
|
-
return I(
|
|
3888
|
+
return I(u.type, d, v);
|
|
3888
3889
|
case p: {
|
|
3889
|
-
var w =
|
|
3890
|
+
var w = u, A = w._payload, q = w._init;
|
|
3890
3891
|
try {
|
|
3891
3892
|
return I(q(A), d, v);
|
|
3892
3893
|
} catch {
|
|
@@ -3896,25 +3897,25 @@ function Da() {
|
|
|
3896
3897
|
return "";
|
|
3897
3898
|
}
|
|
3898
3899
|
var re = Object.prototype.hasOwnProperty, Re = {}, H = _.ReactDebugCurrentFrame;
|
|
3899
|
-
function J(
|
|
3900
|
-
if (
|
|
3901
|
-
var d =
|
|
3900
|
+
function J(u) {
|
|
3901
|
+
if (u) {
|
|
3902
|
+
var d = u._owner, v = I(u.type, u._source, d ? d.type : null);
|
|
3902
3903
|
H.setExtraStackFrame(v);
|
|
3903
3904
|
} else
|
|
3904
3905
|
H.setExtraStackFrame(null);
|
|
3905
3906
|
}
|
|
3906
|
-
function de(
|
|
3907
|
+
function de(u, d, v, w, A) {
|
|
3907
3908
|
{
|
|
3908
3909
|
var q = Function.call.bind(re);
|
|
3909
|
-
for (var x in
|
|
3910
|
-
if (q(
|
|
3910
|
+
for (var x in u)
|
|
3911
|
+
if (q(u, x)) {
|
|
3911
3912
|
var R = void 0;
|
|
3912
3913
|
try {
|
|
3913
|
-
if (typeof
|
|
3914
|
-
var se = Error((w || "React class") + ": " + v + " type `" + x + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + typeof
|
|
3914
|
+
if (typeof u[x] != "function") {
|
|
3915
|
+
var se = Error((w || "React class") + ": " + v + " type `" + x + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + typeof u[x] + "`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");
|
|
3915
3916
|
throw se.name = "Invariant Violation", se;
|
|
3916
3917
|
}
|
|
3917
|
-
R =
|
|
3918
|
+
R = u[x](d, x, w, v, null, "SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED");
|
|
3918
3919
|
} catch (W) {
|
|
3919
3920
|
R = W;
|
|
3920
3921
|
}
|
|
@@ -3923,28 +3924,28 @@ function Da() {
|
|
|
3923
3924
|
}
|
|
3924
3925
|
}
|
|
3925
3926
|
var _t = Array.isArray;
|
|
3926
|
-
function Me(
|
|
3927
|
-
return _t(
|
|
3927
|
+
function Me(u) {
|
|
3928
|
+
return _t(u);
|
|
3928
3929
|
}
|
|
3929
|
-
function bt(
|
|
3930
|
+
function bt(u) {
|
|
3930
3931
|
{
|
|
3931
|
-
var d = typeof Symbol == "function" && Symbol.toStringTag, v = d &&
|
|
3932
|
+
var d = typeof Symbol == "function" && Symbol.toStringTag, v = d && u[Symbol.toStringTag] || u.constructor.name || "Object";
|
|
3932
3933
|
return v;
|
|
3933
3934
|
}
|
|
3934
3935
|
}
|
|
3935
|
-
function ie(
|
|
3936
|
+
function ie(u) {
|
|
3936
3937
|
try {
|
|
3937
|
-
return ce(
|
|
3938
|
+
return ce(u), !1;
|
|
3938
3939
|
} catch {
|
|
3939
3940
|
return !0;
|
|
3940
3941
|
}
|
|
3941
3942
|
}
|
|
3942
|
-
function ce(
|
|
3943
|
-
return "" +
|
|
3943
|
+
function ce(u) {
|
|
3944
|
+
return "" + u;
|
|
3944
3945
|
}
|
|
3945
|
-
function We(
|
|
3946
|
-
if (ie(
|
|
3947
|
-
return S("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.", bt(
|
|
3946
|
+
function We(u) {
|
|
3947
|
+
if (ie(u))
|
|
3948
|
+
return S("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.", bt(u)), ce(u);
|
|
3948
3949
|
}
|
|
3949
3950
|
var Pe = _.ReactCurrentOwner, nt = {
|
|
3950
3951
|
key: !0,
|
|
@@ -3953,54 +3954,54 @@ function Da() {
|
|
|
3953
3954
|
__source: !0
|
|
3954
3955
|
}, Kn, Gn, Wt;
|
|
3955
3956
|
Wt = {};
|
|
3956
|
-
function Us(
|
|
3957
|
-
if (re.call(
|
|
3958
|
-
var d = Object.getOwnPropertyDescriptor(
|
|
3957
|
+
function Us(u) {
|
|
3958
|
+
if (re.call(u, "ref")) {
|
|
3959
|
+
var d = Object.getOwnPropertyDescriptor(u, "ref").get;
|
|
3959
3960
|
if (d && d.isReactWarning)
|
|
3960
3961
|
return !1;
|
|
3961
3962
|
}
|
|
3962
|
-
return
|
|
3963
|
+
return u.ref !== void 0;
|
|
3963
3964
|
}
|
|
3964
|
-
function qs(
|
|
3965
|
-
if (re.call(
|
|
3966
|
-
var d = Object.getOwnPropertyDescriptor(
|
|
3965
|
+
function qs(u) {
|
|
3966
|
+
if (re.call(u, "key")) {
|
|
3967
|
+
var d = Object.getOwnPropertyDescriptor(u, "key").get;
|
|
3967
3968
|
if (d && d.isReactWarning)
|
|
3968
3969
|
return !1;
|
|
3969
3970
|
}
|
|
3970
|
-
return
|
|
3971
|
+
return u.key !== void 0;
|
|
3971
3972
|
}
|
|
3972
|
-
function Is(
|
|
3973
|
-
if (typeof
|
|
3973
|
+
function Is(u, d) {
|
|
3974
|
+
if (typeof u.ref == "string" && Pe.current && d && Pe.current.stateNode !== d) {
|
|
3974
3975
|
var v = G(Pe.current.type);
|
|
3975
|
-
Wt[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', G(Pe.current.type),
|
|
3976
|
+
Wt[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', G(Pe.current.type), u.ref), Wt[v] = !0);
|
|
3976
3977
|
}
|
|
3977
3978
|
}
|
|
3978
|
-
function Vs(
|
|
3979
|
+
function Vs(u, d) {
|
|
3979
3980
|
{
|
|
3980
3981
|
var v = function() {
|
|
3981
3982
|
Kn || (Kn = !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)", d));
|
|
3982
3983
|
};
|
|
3983
|
-
v.isReactWarning = !0, Object.defineProperty(
|
|
3984
|
+
v.isReactWarning = !0, Object.defineProperty(u, "key", {
|
|
3984
3985
|
get: v,
|
|
3985
3986
|
configurable: !0
|
|
3986
3987
|
});
|
|
3987
3988
|
}
|
|
3988
3989
|
}
|
|
3989
|
-
function js(
|
|
3990
|
+
function js(u, d) {
|
|
3990
3991
|
{
|
|
3991
3992
|
var v = function() {
|
|
3992
3993
|
Gn || (Gn = !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)", d));
|
|
3993
3994
|
};
|
|
3994
|
-
v.isReactWarning = !0, Object.defineProperty(
|
|
3995
|
+
v.isReactWarning = !0, Object.defineProperty(u, "ref", {
|
|
3995
3996
|
get: v,
|
|
3996
3997
|
configurable: !0
|
|
3997
3998
|
});
|
|
3998
3999
|
}
|
|
3999
4000
|
}
|
|
4000
|
-
var $s = function(
|
|
4001
|
+
var $s = function(u, d, v, w, A, q, x) {
|
|
4001
4002
|
var R = {
|
|
4002
4003
|
$$typeof: e,
|
|
4003
|
-
type:
|
|
4004
|
+
type: u,
|
|
4004
4005
|
key: d,
|
|
4005
4006
|
ref: v,
|
|
4006
4007
|
props: x,
|
|
@@ -4023,53 +4024,53 @@ function Da() {
|
|
|
4023
4024
|
value: A
|
|
4024
4025
|
}), Object.freeze && (Object.freeze(R.props), Object.freeze(R)), R;
|
|
4025
4026
|
};
|
|
4026
|
-
function Ms(
|
|
4027
|
+
function Ms(u, d, v, w, A) {
|
|
4027
4028
|
{
|
|
4028
4029
|
var q, x = {}, R = null, se = null;
|
|
4029
4030
|
v !== void 0 && (We(v), R = "" + v), qs(d) && (We(d.key), R = "" + d.key), Us(d) && (se = d.ref, Is(d, A));
|
|
4030
4031
|
for (q in d)
|
|
4031
4032
|
re.call(d, q) && !nt.hasOwnProperty(q) && (x[q] = d[q]);
|
|
4032
|
-
if (
|
|
4033
|
-
var W =
|
|
4033
|
+
if (u && u.defaultProps) {
|
|
4034
|
+
var W = u.defaultProps;
|
|
4034
4035
|
for (q in W)
|
|
4035
4036
|
x[q] === void 0 && (x[q] = W[q]);
|
|
4036
4037
|
}
|
|
4037
4038
|
if (R || se) {
|
|
4038
|
-
var Y = typeof
|
|
4039
|
+
var Y = typeof u == "function" ? u.displayName || u.name || "Unknown" : u;
|
|
4039
4040
|
R && Vs(x, Y), se && js(x, Y);
|
|
4040
4041
|
}
|
|
4041
|
-
return $s(
|
|
4042
|
+
return $s(u, R, se, A, w, Pe.current, x);
|
|
4042
4043
|
}
|
|
4043
4044
|
}
|
|
4044
4045
|
var Ht = _.ReactCurrentOwner, Xn = _.ReactDebugCurrentFrame;
|
|
4045
|
-
function He(
|
|
4046
|
-
if (
|
|
4047
|
-
var d =
|
|
4046
|
+
function He(u) {
|
|
4047
|
+
if (u) {
|
|
4048
|
+
var d = u._owner, v = I(u.type, u._source, d ? d.type : null);
|
|
4048
4049
|
Xn.setExtraStackFrame(v);
|
|
4049
4050
|
} else
|
|
4050
4051
|
Xn.setExtraStackFrame(null);
|
|
4051
4052
|
}
|
|
4052
4053
|
var Jt;
|
|
4053
4054
|
Jt = !1;
|
|
4054
|
-
function Yt(
|
|
4055
|
-
return typeof
|
|
4055
|
+
function Yt(u) {
|
|
4056
|
+
return typeof u == "object" && u !== null && u.$$typeof === e;
|
|
4056
4057
|
}
|
|
4057
4058
|
function Qn() {
|
|
4058
4059
|
{
|
|
4059
4060
|
if (Ht.current) {
|
|
4060
|
-
var
|
|
4061
|
-
if (
|
|
4061
|
+
var u = G(Ht.current.type);
|
|
4062
|
+
if (u)
|
|
4062
4063
|
return `
|
|
4063
4064
|
|
|
4064
|
-
Check the render method of \`` +
|
|
4065
|
+
Check the render method of \`` + u + "`.";
|
|
4065
4066
|
}
|
|
4066
4067
|
return "";
|
|
4067
4068
|
}
|
|
4068
4069
|
}
|
|
4069
|
-
function Ws(
|
|
4070
|
+
function Ws(u) {
|
|
4070
4071
|
{
|
|
4071
|
-
if (
|
|
4072
|
-
var d =
|
|
4072
|
+
if (u !== void 0) {
|
|
4073
|
+
var d = u.fileName.replace(/^.*[\\\/]/, ""), v = u.lineNumber;
|
|
4073
4074
|
return `
|
|
4074
4075
|
|
|
4075
4076
|
Check your code at ` + d + ":" + v + ".";
|
|
@@ -4078,11 +4079,11 @@ Check your code at ` + d + ":" + v + ".";
|
|
|
4078
4079
|
}
|
|
4079
4080
|
}
|
|
4080
4081
|
var Zn = {};
|
|
4081
|
-
function Hs(
|
|
4082
|
+
function Hs(u) {
|
|
4082
4083
|
{
|
|
4083
4084
|
var d = Qn();
|
|
4084
4085
|
if (!d) {
|
|
4085
|
-
var v = typeof
|
|
4086
|
+
var v = typeof u == "string" ? u : u.displayName || u.name;
|
|
4086
4087
|
v && (d = `
|
|
4087
4088
|
|
|
4088
4089
|
Check the top-level render call using <` + v + ">.");
|
|
@@ -4090,41 +4091,41 @@ Check the top-level render call using <` + v + ">.");
|
|
|
4090
4091
|
return d;
|
|
4091
4092
|
}
|
|
4092
4093
|
}
|
|
4093
|
-
function er(
|
|
4094
|
+
function er(u, d) {
|
|
4094
4095
|
{
|
|
4095
|
-
if (!
|
|
4096
|
+
if (!u._store || u._store.validated || u.key != null)
|
|
4096
4097
|
return;
|
|
4097
|
-
|
|
4098
|
+
u._store.validated = !0;
|
|
4098
4099
|
var v = Hs(d);
|
|
4099
4100
|
if (Zn[v])
|
|
4100
4101
|
return;
|
|
4101
4102
|
Zn[v] = !0;
|
|
4102
4103
|
var w = "";
|
|
4103
|
-
|
|
4104
|
+
u && u._owner && u._owner !== Ht.current && (w = " It was passed a child from " + G(u._owner.type) + "."), He(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, w), He(null);
|
|
4104
4105
|
}
|
|
4105
4106
|
}
|
|
4106
|
-
function tr(
|
|
4107
|
+
function tr(u, d) {
|
|
4107
4108
|
{
|
|
4108
|
-
if (typeof
|
|
4109
|
+
if (typeof u != "object")
|
|
4109
4110
|
return;
|
|
4110
|
-
if (Me(
|
|
4111
|
-
for (var v = 0; v <
|
|
4112
|
-
var w =
|
|
4111
|
+
if (Me(u))
|
|
4112
|
+
for (var v = 0; v < u.length; v++) {
|
|
4113
|
+
var w = u[v];
|
|
4113
4114
|
Yt(w) && er(w, d);
|
|
4114
4115
|
}
|
|
4115
|
-
else if (Yt(
|
|
4116
|
-
|
|
4117
|
-
else if (
|
|
4118
|
-
var A = E(
|
|
4119
|
-
if (typeof A == "function" && A !==
|
|
4120
|
-
for (var q = A.call(
|
|
4116
|
+
else if (Yt(u))
|
|
4117
|
+
u._store && (u._store.validated = !0);
|
|
4118
|
+
else if (u) {
|
|
4119
|
+
var A = E(u);
|
|
4120
|
+
if (typeof A == "function" && A !== u.entries)
|
|
4121
|
+
for (var q = A.call(u), x; !(x = q.next()).done; )
|
|
4121
4122
|
Yt(x.value) && er(x.value, d);
|
|
4122
4123
|
}
|
|
4123
4124
|
}
|
|
4124
4125
|
}
|
|
4125
|
-
function Js(
|
|
4126
|
+
function Js(u) {
|
|
4126
4127
|
{
|
|
4127
|
-
var d =
|
|
4128
|
+
var d = u.type;
|
|
4128
4129
|
if (d == null || typeof d == "string")
|
|
4129
4130
|
return;
|
|
4130
4131
|
var v;
|
|
@@ -4136,7 +4137,7 @@ Check the top-level render call using <` + v + ">.");
|
|
|
4136
4137
|
return;
|
|
4137
4138
|
if (v) {
|
|
4138
4139
|
var w = G(d);
|
|
4139
|
-
de(v,
|
|
4140
|
+
de(v, u.props, "prop", w, u);
|
|
4140
4141
|
} else if (d.PropTypes !== void 0 && !Jt) {
|
|
4141
4142
|
Jt = !0;
|
|
4142
4143
|
var A = G(d);
|
|
@@ -4145,30 +4146,30 @@ Check the top-level render call using <` + v + ">.");
|
|
|
4145
4146
|
typeof d.getDefaultProps == "function" && !d.getDefaultProps.isReactClassApproved && S("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.");
|
|
4146
4147
|
}
|
|
4147
4148
|
}
|
|
4148
|
-
function Ys(
|
|
4149
|
+
function Ys(u) {
|
|
4149
4150
|
{
|
|
4150
|
-
for (var d = Object.keys(
|
|
4151
|
+
for (var d = Object.keys(u.props), v = 0; v < d.length; v++) {
|
|
4151
4152
|
var w = d[v];
|
|
4152
4153
|
if (w !== "children" && w !== "key") {
|
|
4153
|
-
He(
|
|
4154
|
+
He(u), S("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.", w), He(null);
|
|
4154
4155
|
break;
|
|
4155
4156
|
}
|
|
4156
4157
|
}
|
|
4157
|
-
|
|
4158
|
+
u.ref !== null && (He(u), S("Invalid attribute `ref` supplied to `React.Fragment`."), He(null));
|
|
4158
4159
|
}
|
|
4159
4160
|
}
|
|
4160
|
-
function nr(
|
|
4161
|
+
function nr(u, d, v, w, A, q) {
|
|
4161
4162
|
{
|
|
4162
|
-
var x = L(
|
|
4163
|
+
var x = L(u);
|
|
4163
4164
|
if (!x) {
|
|
4164
4165
|
var R = "";
|
|
4165
|
-
(
|
|
4166
|
+
(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.");
|
|
4166
4167
|
var se = Ws(A);
|
|
4167
4168
|
se ? R += se : R += Qn();
|
|
4168
4169
|
var W;
|
|
4169
|
-
|
|
4170
|
+
u === null ? W = "null" : Me(u) ? W = "array" : u !== void 0 && u.$$typeof === e ? (W = "<" + (G(u.type) || "Unknown") + " />", R = " Did you accidentally export a JSX literal instead of a component?") : W = 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", W, R);
|
|
4170
4171
|
}
|
|
4171
|
-
var Y = Ms(
|
|
4172
|
+
var Y = Ms(u, d, v, A, q);
|
|
4172
4173
|
if (Y == null)
|
|
4173
4174
|
return Y;
|
|
4174
4175
|
if (x) {
|
|
@@ -4177,21 +4178,21 @@ Check the top-level render call using <` + v + ">.");
|
|
|
4177
4178
|
if (w)
|
|
4178
4179
|
if (Me(le)) {
|
|
4179
4180
|
for (var Je = 0; Je < le.length; Je++)
|
|
4180
|
-
tr(le[Je],
|
|
4181
|
+
tr(le[Je], u);
|
|
4181
4182
|
Object.freeze && Object.freeze(le);
|
|
4182
4183
|
} else
|
|
4183
4184
|
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.");
|
|
4184
4185
|
else
|
|
4185
|
-
tr(le,
|
|
4186
|
+
tr(le, u);
|
|
4186
4187
|
}
|
|
4187
|
-
return
|
|
4188
|
+
return u === r ? Ys(Y) : Js(Y), Y;
|
|
4188
4189
|
}
|
|
4189
4190
|
}
|
|
4190
|
-
function zs(
|
|
4191
|
-
return nr(
|
|
4191
|
+
function zs(u, d, v) {
|
|
4192
|
+
return nr(u, d, v, !0);
|
|
4192
4193
|
}
|
|
4193
|
-
function Ks(
|
|
4194
|
-
return nr(
|
|
4194
|
+
function Ks(u, d, v) {
|
|
4195
|
+
return nr(u, d, v, !1);
|
|
4195
4196
|
}
|
|
4196
4197
|
var Gs = Ks, Xs = zs;
|
|
4197
4198
|
at.Fragment = r, at.jsx = Gs, at.jsxs = Xs;
|
|
@@ -4209,15 +4210,15 @@ const ka = Ps.exports.jsx, te = zr(null), Ua = ({
|
|
|
4209
4210
|
children: i
|
|
4210
4211
|
}) => {
|
|
4211
4212
|
const o = Kr(() => {
|
|
4212
|
-
const
|
|
4213
|
+
const c = new oo.FrappeApp(n, e);
|
|
4213
4214
|
return {
|
|
4214
4215
|
url: n,
|
|
4215
4216
|
tokenParams: e,
|
|
4216
|
-
app:
|
|
4217
|
-
auth:
|
|
4218
|
-
db:
|
|
4219
|
-
call:
|
|
4220
|
-
file:
|
|
4217
|
+
app: c,
|
|
4218
|
+
auth: c.auth(),
|
|
4219
|
+
db: c.db(),
|
|
4220
|
+
call: c.call(),
|
|
4221
|
+
file: c.file(),
|
|
4221
4222
|
socket: s ? new Ca(n, r, t, e).socket : void 0,
|
|
4222
4223
|
enableSocket: s,
|
|
4223
4224
|
socketPort: t
|
|
@@ -4244,7 +4245,7 @@ const ka = Ps.exports.jsx, te = zr(null), Ua = ({
|
|
|
4244
4245
|
r && r.useToken ? i(null) : o();
|
|
4245
4246
|
}, []);
|
|
4246
4247
|
const {
|
|
4247
|
-
data:
|
|
4248
|
+
data: c,
|
|
4248
4249
|
error: l,
|
|
4249
4250
|
isLoading: a,
|
|
4250
4251
|
isValidating: h,
|
|
@@ -4256,13 +4257,10 @@ const ka = Ps.exports.jsx, te = zr(null), Ua = ({
|
|
|
4256
4257
|
shouldRetryOnError: !1,
|
|
4257
4258
|
revalidateOnFocus: !1,
|
|
4258
4259
|
...n
|
|
4259
|
-
}), p = $(async (g, b) => t.
|
|
4260
|
-
username: g,
|
|
4261
|
-
password: b
|
|
4262
|
-
}).then((E) => (o(), E)), []), m = $(async () => t.logout().then(() => f(null)).then(() => i(null)), []);
|
|
4260
|
+
}), p = $(async (g) => t.loginWithUsernamePassword(g).then((b) => (o(), b)), []), m = $(async () => t.logout().then(() => f(null)).then(() => i(null)), []);
|
|
4263
4261
|
return {
|
|
4264
4262
|
isLoading: s === void 0 || a,
|
|
4265
|
-
currentUser:
|
|
4263
|
+
currentUser: c,
|
|
4266
4264
|
isValidating: h,
|
|
4267
4265
|
error: l,
|
|
4268
4266
|
login: p,
|
|
@@ -4300,7 +4298,7 @@ const ka = Ps.exports.jsx, te = zr(null), Ua = ({
|
|
|
4300
4298
|
}, ja = () => {
|
|
4301
4299
|
const {
|
|
4302
4300
|
db: n
|
|
4303
|
-
} = ee(te), [e, t] = P(!1), [r, s] = P(null), [i, o] = P(!1),
|
|
4301
|
+
} = ee(te), [e, t] = P(!1), [r, s] = P(null), [i, o] = P(!1), c = $(() => {
|
|
4304
4302
|
t(!1), s(null), o(!1);
|
|
4305
4303
|
}, []);
|
|
4306
4304
|
return {
|
|
@@ -4310,12 +4308,12 @@ const ka = Ps.exports.jsx, te = zr(null), Ua = ({
|
|
|
4310
4308
|
loading: e,
|
|
4311
4309
|
error: r,
|
|
4312
4310
|
isCompleted: i,
|
|
4313
|
-
reset:
|
|
4311
|
+
reset: c
|
|
4314
4312
|
};
|
|
4315
4313
|
}, $a = () => {
|
|
4316
4314
|
const {
|
|
4317
4315
|
db: n
|
|
4318
|
-
} = ee(te), [e, t] = P(!1), [r, s] = P(null), [i, o] = P(!1),
|
|
4316
|
+
} = ee(te), [e, t] = P(!1), [r, s] = P(null), [i, o] = P(!1), c = $(() => {
|
|
4319
4317
|
t(!1), s(null), o(!1);
|
|
4320
4318
|
}, []);
|
|
4321
4319
|
return {
|
|
@@ -4324,13 +4322,13 @@ const ka = Ps.exports.jsx, te = zr(null), Ua = ({
|
|
|
4324
4322
|
})), []),
|
|
4325
4323
|
loading: e,
|
|
4326
4324
|
error: r,
|
|
4327
|
-
reset:
|
|
4325
|
+
reset: c,
|
|
4328
4326
|
isCompleted: i
|
|
4329
4327
|
};
|
|
4330
4328
|
}, Ma = () => {
|
|
4331
4329
|
const {
|
|
4332
4330
|
db: n
|
|
4333
|
-
} = ee(te), [e, t] = P(!1), [r, s] = P(null), [i, o] = P(!1),
|
|
4331
|
+
} = ee(te), [e, t] = P(!1), [r, s] = P(null), [i, o] = P(!1), c = $(() => {
|
|
4334
4332
|
t(!1), s(null), o(!1);
|
|
4335
4333
|
}, []);
|
|
4336
4334
|
return {
|
|
@@ -4339,7 +4337,7 @@ const ka = Ps.exports.jsx, te = zr(null), Ua = ({
|
|
|
4339
4337
|
})), []),
|
|
4340
4338
|
loading: e,
|
|
4341
4339
|
error: r,
|
|
4342
|
-
reset:
|
|
4340
|
+
reset: c,
|
|
4343
4341
|
isCompleted: i
|
|
4344
4342
|
};
|
|
4345
4343
|
};
|
|
@@ -4352,7 +4350,7 @@ function Fs(n) {
|
|
|
4352
4350
|
const Wa = (n, e, t = !1, r = !1, s, i) => {
|
|
4353
4351
|
const {
|
|
4354
4352
|
url: o,
|
|
4355
|
-
db:
|
|
4353
|
+
db: c
|
|
4356
4354
|
} = ee(te);
|
|
4357
4355
|
return {
|
|
4358
4356
|
...vt(s === void 0 ? (() => {
|
|
@@ -4367,7 +4365,7 @@ const Wa = (n, e, t = !1, r = !1, s, i) => {
|
|
|
4367
4365
|
debug: r
|
|
4368
4366
|
});
|
|
4369
4367
|
return `${o}/api/method/frappe.client.get_count?${h}`;
|
|
4370
|
-
})() : s, () =>
|
|
4368
|
+
})() : s, () => c.getCount(n, e, t, r), i)
|
|
4371
4369
|
};
|
|
4372
4370
|
}, Na = (n, e, t, r) => {
|
|
4373
4371
|
const {
|
|
@@ -4379,12 +4377,12 @@ const Wa = (n, e, t = !1, r = !1, s, i) => {
|
|
|
4379
4377
|
}, Ha = (n) => {
|
|
4380
4378
|
const {
|
|
4381
4379
|
call: e
|
|
4382
|
-
} = ee(te), [t, r] = P(null), [s, i] = P(!1), [o,
|
|
4383
|
-
r(null), i(!1),
|
|
4380
|
+
} = ee(te), [t, r] = P(null), [s, i] = P(!1), [o, c] = P(null), [l, a] = P(!1), h = $(() => {
|
|
4381
|
+
r(null), i(!1), c(null), a(!1);
|
|
4384
4382
|
}, []);
|
|
4385
4383
|
return {
|
|
4386
|
-
call: $(async (p) => (
|
|
4387
|
-
throw i(!1), a(!1),
|
|
4384
|
+
call: $(async (p) => (c(null), a(!1), i(!0), r(null), e.post(n, p).then((m) => (r(m), i(!1), a(!0), m)).catch((m) => {
|
|
4385
|
+
throw i(!1), a(!1), c(m), m;
|
|
4388
4386
|
})), []),
|
|
4389
4387
|
result: t,
|
|
4390
4388
|
loading: s,
|
|
@@ -4395,12 +4393,12 @@ const Wa = (n, e, t = !1, r = !1, s, i) => {
|
|
|
4395
4393
|
}, Ja = (n) => {
|
|
4396
4394
|
const {
|
|
4397
4395
|
call: e
|
|
4398
|
-
} = ee(te), [t, r] = P(null), [s, i] = P(!1), [o,
|
|
4399
|
-
r(null), i(!1),
|
|
4396
|
+
} = ee(te), [t, r] = P(null), [s, i] = P(!1), [o, c] = P(null), [l, a] = P(!1), h = $(() => {
|
|
4397
|
+
r(null), i(!1), c(null), a(!1);
|
|
4400
4398
|
}, []);
|
|
4401
4399
|
return {
|
|
4402
|
-
call: $(async (p) => (
|
|
4403
|
-
throw i(!1), a(!1),
|
|
4400
|
+
call: $(async (p) => (c(null), a(!1), i(!0), r(null), e.put(n, p).then((m) => (r(m), i(!1), a(!0), m)).catch((m) => {
|
|
4401
|
+
throw i(!1), a(!1), c(m), m;
|
|
4404
4402
|
})), []),
|
|
4405
4403
|
result: t,
|
|
4406
4404
|
loading: s,
|
|
@@ -4411,12 +4409,12 @@ const Wa = (n, e, t = !1, r = !1, s, i) => {
|
|
|
4411
4409
|
}, Ya = (n) => {
|
|
4412
4410
|
const {
|
|
4413
4411
|
call: e
|
|
4414
|
-
} = ee(te), [t, r] = P(null), [s, i] = P(!1), [o,
|
|
4415
|
-
r(null), i(!1),
|
|
4412
|
+
} = ee(te), [t, r] = P(null), [s, i] = P(!1), [o, c] = P(null), [l, a] = P(!1), h = $(() => {
|
|
4413
|
+
r(null), i(!1), c(null), a(!1);
|
|
4416
4414
|
}, []);
|
|
4417
4415
|
return {
|
|
4418
|
-
call: $(async (p) => (
|
|
4419
|
-
throw i(!1), a(!1),
|
|
4416
|
+
call: $(async (p) => (c(null), a(!1), i(!0), r(null), e.delete(n, p).then((m) => (r(m), i(!1), a(!0), m)).catch((m) => {
|
|
4417
|
+
throw i(!1), a(!1), c(m), m;
|
|
4420
4418
|
})), []),
|
|
4421
4419
|
result: t,
|
|
4422
4420
|
loading: s,
|
|
@@ -4427,7 +4425,7 @@ const Wa = (n, e, t = !1, r = !1, s, i) => {
|
|
|
4427
4425
|
}, za = () => {
|
|
4428
4426
|
const {
|
|
4429
4427
|
file: n
|
|
4430
|
-
} = ee(te), [e, t] = P(0), [r, s] = P(!1), [i, o] = P(null), [
|
|
4428
|
+
} = ee(te), [e, t] = P(0), [r, s] = P(!1), [i, o] = P(null), [c, l] = P(!1), a = $(async (f, p, m) => (h(), s(!0), n.uploadFile(f, p, (g, b) => t(Math.round(g / b * 100)), m).then((g) => (l(!0), t(100), s(!1), g.data.message)).catch((g) => {
|
|
4431
4429
|
throw console.error(g), o(g), s(!1), g;
|
|
4432
4430
|
})), []), h = $(() => {
|
|
4433
4431
|
t(0), s(!1), o(null), l(!1);
|
|
@@ -4436,7 +4434,7 @@ const Wa = (n, e, t = !1, r = !1, s, i) => {
|
|
|
4436
4434
|
upload: a,
|
|
4437
4435
|
progress: e,
|
|
4438
4436
|
loading: r,
|
|
4439
|
-
isCompleted:
|
|
4437
|
+
isCompleted: c,
|
|
4440
4438
|
error: i,
|
|
4441
4439
|
reset: h
|
|
4442
4440
|
};
|
|
@@ -4476,7 +4474,7 @@ const Wa = (n, e, t = !1, r = !1, s, i) => {
|
|
|
4476
4474
|
Ge(() => (s === void 0 && console.warn("Socket is not enabled. Please enable socket in FrappeProvider."), s == null || s.emit("doc_subscribe", n, e), r && (s == null || s.emit("doc_open", n, e)), () => {
|
|
4477
4475
|
s == null || s.emit("doc_unsubscribe", n, e), r && (s == null || s.emit("doc_close", n, e));
|
|
4478
4476
|
}), [n, e, r]), Bn("doc_update", t);
|
|
4479
|
-
const
|
|
4477
|
+
const c = $(() => {
|
|
4480
4478
|
s == null || s.emit("doc_open", n, e);
|
|
4481
4479
|
}, [n, e]), l = $(() => {
|
|
4482
4480
|
s == null || s.emit("doc_close", n, e);
|
|
@@ -4485,7 +4483,7 @@ const Wa = (n, e, t = !1, r = !1, s, i) => {
|
|
|
4485
4483
|
}, [n, e]);
|
|
4486
4484
|
return Bn("doc_viewers", a), {
|
|
4487
4485
|
viewers: i,
|
|
4488
|
-
emitDocOpen:
|
|
4486
|
+
emitDocOpen: c,
|
|
4489
4487
|
emitDocClose: l
|
|
4490
4488
|
};
|
|
4491
4489
|
}, Xa = (n, e) => {
|