zudoku 0.0.0-f3858d6 → 0.0.0-f417aae
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/README.md +121 -0
- package/cli.js +2 -2
- package/dist/app/entry.client.js +2 -2
- package/dist/app/entry.client.js.map +1 -1
- package/dist/app/entry.server.js +0 -3
- package/dist/app/entry.server.js.map +1 -1
- package/dist/app/main.d.ts +0 -1
- package/dist/app/main.js +23 -10
- package/dist/app/main.js.map +1 -1
- package/dist/app/standalone.js.map +1 -1
- package/dist/cli/common/machine-id/lib.js.map +1 -1
- package/dist/cli/common/outdated.js.map +1 -1
- package/dist/cli/common/utils/box.js.map +1 -1
- package/dist/config/validators/InputSidebarSchema.d.ts +21 -6
- package/dist/config/validators/InputSidebarSchema.js +7 -28
- package/dist/config/validators/InputSidebarSchema.js.map +1 -1
- package/dist/config/validators/SidebarSchema.d.ts +1 -1
- package/dist/config/validators/SidebarSchema.js +14 -11
- package/dist/config/validators/SidebarSchema.js.map +1 -1
- package/dist/config/validators/validate.d.ts +117 -95
- package/dist/config/validators/validate.js +23 -8
- package/dist/config/validators/validate.js.map +1 -1
- package/dist/index.d.ts +2 -5
- package/dist/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/dist/lib/authentication/components/CallbackHandler.js +21 -31
- package/dist/lib/authentication/components/CallbackHandler.js.map +1 -1
- package/dist/lib/authentication/hook.d.ts +1 -1
- package/dist/lib/authentication/hook.js +1 -1
- package/dist/lib/authentication/hook.js.map +1 -1
- package/dist/lib/components/Header.js +1 -5
- package/dist/lib/components/Header.js.map +1 -1
- package/dist/lib/components/MobileTopNavigation.js +4 -1
- package/dist/lib/components/MobileTopNavigation.js.map +1 -1
- package/dist/lib/components/Search.js +1 -1
- package/dist/lib/components/Search.js.map +1 -1
- package/dist/lib/components/SlotletProvider.d.ts +6 -2
- package/dist/lib/components/SlotletProvider.js +3 -5
- package/dist/lib/components/SlotletProvider.js.map +1 -1
- package/dist/lib/components/TopNavigation.d.ts +3 -0
- package/dist/lib/components/TopNavigation.js +13 -30
- package/dist/lib/components/TopNavigation.js.map +1 -1
- package/dist/lib/components/context/ZudokuContext.d.ts +11 -4
- package/dist/lib/components/context/ZudokuContext.js +20 -26
- package/dist/lib/components/context/ZudokuContext.js.map +1 -1
- package/dist/lib/components/index.d.ts +17 -8
- package/dist/lib/components/index.js +10 -3
- package/dist/lib/components/index.js.map +1 -1
- package/dist/lib/components/navigation/Sidebar.js +3 -3
- package/dist/lib/components/navigation/Sidebar.js.map +1 -1
- package/dist/lib/components/navigation/SidebarCategory.js +20 -7
- package/dist/lib/components/navigation/SidebarCategory.js.map +1 -1
- package/dist/lib/components/navigation/SidebarItem.js +14 -5
- package/dist/lib/components/navigation/SidebarItem.js.map +1 -1
- package/dist/lib/components/navigation/utils.js +14 -10
- package/dist/lib/components/navigation/utils.js.map +1 -1
- package/dist/lib/core/DevPortalContext.d.ts +7 -3
- package/dist/lib/core/DevPortalContext.js.map +1 -1
- package/dist/lib/core/plugins.d.ts +0 -1
- package/dist/lib/core/plugins.js.map +1 -1
- package/dist/lib/errors/ErrorAlert.d.ts +1 -1
- package/dist/lib/errors/ErrorAlert.js +8 -3
- package/dist/lib/errors/ErrorAlert.js.map +1 -1
- package/dist/lib/plugins/custom-pages/CustomPage.d.ts +2 -0
- package/dist/lib/plugins/custom-pages/CustomPage.js +11 -0
- package/dist/lib/plugins/custom-pages/CustomPage.js.map +1 -0
- package/dist/lib/plugins/custom-pages/index.d.ts +8 -6
- package/dist/lib/plugins/custom-pages/index.js +3 -4
- package/dist/lib/plugins/custom-pages/index.js.map +1 -1
- package/dist/lib/plugins/markdown/MdxPage.js +1 -1
- package/dist/lib/plugins/markdown/MdxPage.js.map +1 -1
- package/dist/lib/plugins/markdown/generateRoutes.d.ts +3 -0
- package/dist/lib/plugins/markdown/generateRoutes.js +21 -0
- package/dist/lib/plugins/markdown/generateRoutes.js.map +1 -0
- package/dist/lib/plugins/markdown/index.d.ts +6 -5
- package/dist/lib/plugins/markdown/index.js +3 -31
- package/dist/lib/plugins/markdown/index.js.map +1 -1
- package/dist/lib/plugins/openapi/Endpoint.js.map +1 -1
- package/dist/lib/plugins/openapi/RequestBodySidecarBox.js.map +1 -1
- package/dist/lib/plugins/openapi/Sidecar.js.map +1 -1
- package/dist/lib/plugins/openapi/client/worker.js.map +1 -1
- package/dist/lib/plugins/openapi/index.js.map +1 -1
- package/dist/lib/plugins/openapi/playground/Playground.js +1 -0
- package/dist/lib/plugins/openapi/playground/Playground.js.map +1 -1
- package/dist/lib/util/invariant.d.ts +9 -0
- package/dist/lib/util/invariant.js +7 -3
- package/dist/lib/util/invariant.js.map +1 -1
- package/dist/lib/util/useExposedProps.d.ts +2 -0
- package/dist/lib/util/useExposedProps.js +8 -0
- package/dist/lib/util/useExposedProps.js.map +1 -0
- package/dist/lib/util/useScrollToAnchor.js.map +1 -1
- package/dist/vite/build.js +2 -7
- package/dist/vite/build.js.map +1 -1
- package/dist/vite/config.js +1 -1
- package/dist/vite/config.js.map +1 -1
- package/dist/vite/dev-server.js +1 -1
- package/dist/vite/dev-server.js.map +1 -1
- package/dist/vite/plugin-config-reload.js.map +1 -1
- package/dist/vite/plugin-docs.js +26 -26
- package/dist/vite/plugin-docs.js.map +1 -1
- package/dist/vite/plugin-mdx.js +17 -0
- package/dist/vite/plugin-mdx.js.map +1 -1
- package/dist/vite/plugin-search.d.ts +3 -0
- package/dist/vite/plugin-search.js +26 -0
- package/dist/vite/plugin-search.js.map +1 -0
- package/dist/vite/plugin-sidebar.js +2 -5
- package/dist/vite/plugin-sidebar.js.map +1 -1
- package/dist/vite/plugin.js +2 -0
- package/dist/vite/plugin.js.map +1 -1
- package/dist/vite/prerender.d.ts +1 -5
- package/dist/vite/prerender.js +5 -6
- package/dist/vite/prerender.js.map +1 -1
- package/lib/{AuthenticationPlugin-Cnqy9csQ.js → AuthenticationPlugin-tBvLKsFg.js} +3 -3
- package/lib/{AuthenticationPlugin-Cnqy9csQ.js.map → AuthenticationPlugin-tBvLKsFg.js.map} +1 -1
- package/lib/{CategoryHeading-C7VfgpFZ.js → CategoryHeading-D2WS6sRI.js} +2 -2
- package/lib/{CategoryHeading-C7VfgpFZ.js.map → CategoryHeading-D2WS6sRI.js.map} +1 -1
- package/lib/ClientOnly-CVN6leDu.js +11 -0
- package/lib/ClientOnly-CVN6leDu.js.map +1 -0
- package/lib/{DeveloperHint-CNyuFROc.js → DeveloperHint-CRiZjqd2.js} +2 -2
- package/lib/{DeveloperHint-CNyuFROc.js.map → DeveloperHint-CRiZjqd2.js.map} +1 -1
- package/lib/{Input-x-t53FyR.js → Input-CO-1DOZa.js} +4 -4
- package/lib/{Input-x-t53FyR.js.map → Input-CO-1DOZa.js.map} +1 -1
- package/lib/{Markdown-C-0TaxoY.js → Markdown-DM4zv3MA.js} +9 -8
- package/lib/{Markdown-C-0TaxoY.js.map → Markdown-DM4zv3MA.js.map} +1 -1
- package/lib/{MdxPage-C5I9c7R1.js → MdxPage-tWI_P8wP.js} +27 -28
- package/lib/MdxPage-tWI_P8wP.js.map +1 -0
- package/lib/{OperationList-qsBOguHS.js → OperationList-Cd3lue0b.js} +11 -12
- package/lib/OperationList-Cd3lue0b.js.map +1 -0
- package/lib/{Route-DlKvXPAO.js → Route-DI0Y0pIV.js} +3 -3
- package/lib/{Route-DlKvXPAO.js.map → Route-DI0Y0pIV.js.map} +1 -1
- package/lib/SlotletProvider-CBqY8mp6.js +241 -0
- package/lib/SlotletProvider-CBqY8mp6.js.map +1 -0
- package/lib/{SidebarBadge-DaA0-bFW.js → Spinner-DFQhPMBl.js} +60 -58
- package/lib/Spinner-DFQhPMBl.js.map +1 -0
- package/lib/{ZudokuContext-DSipF8sq.js → ZudokuContext-DEoP3GGJ.js} +411 -460
- package/lib/ZudokuContext-DEoP3GGJ.js.map +1 -0
- package/lib/_commonjsHelpers-BkfeUUK-.js +29 -0
- package/lib/_commonjsHelpers-BkfeUUK-.js.map +1 -0
- package/lib/assets/{worker-DaFlmuyf.js → worker-Bf8vjASY.js} +2306 -2220
- package/lib/assets/{worker-DaFlmuyf.js.map → worker-Bf8vjASY.js.map} +1 -1
- package/lib/index-Bn6Lc9tq.js +9 -0
- package/lib/{index-DJqnphbT.js.map → index-Bn6Lc9tq.js.map} +1 -1
- package/lib/{index-BIl-R3aH.js → index-Bs9roz8y.js} +690 -669
- package/lib/index-Bs9roz8y.js.map +1 -0
- package/lib/{index-Dssw7Gff.js → index-CBr6BM_4.js} +13 -13
- package/lib/index-CBr6BM_4.js.map +1 -0
- package/lib/{index-SrtqdZ3j.js → index-CRo94sKK.js} +8 -6
- package/lib/{index-SrtqdZ3j.js.map → index-CRo94sKK.js.map} +1 -1
- package/lib/{index-D06ATMgg.js → index-LNp6rxyU.js} +2 -2
- package/lib/{index-D06ATMgg.js.map → index-LNp6rxyU.js.map} +1 -1
- package/lib/{index-CKmSo0py.js → index-UUT9q9f9.js} +3 -3
- package/lib/{index-CKmSo0py.js.map → index-UUT9q9f9.js.map} +1 -1
- package/lib/invariant-Caa8-XvF.js +26 -0
- package/lib/invariant-Caa8-XvF.js.map +1 -0
- package/lib/joinPath-B7kNnUX4.js +8 -0
- package/lib/joinPath-B7kNnUX4.js.map +1 -0
- package/lib/{router-Oe6YmY6B.js → router-BsfSoK2j.js} +3 -3
- package/lib/{router-Oe6YmY6B.js.map → router-BsfSoK2j.js.map} +1 -1
- package/lib/urql-core-KJnLL26g.js.map +1 -1
- package/lib/useExposedProps-B9K-9GTc.js +9 -0
- package/lib/useExposedProps-B9K-9GTc.js.map +1 -0
- package/lib/{AnchorLink-DovtSBJk.js → utils-G5XSiZc9.js} +275 -231
- package/lib/utils-G5XSiZc9.js.map +1 -0
- package/lib/zudoku.auth-clerk.js +1 -1
- package/lib/zudoku.auth-openid.js +477 -483
- package/lib/zudoku.auth-openid.js.map +1 -1
- package/lib/zudoku.components.js +937 -935
- package/lib/zudoku.components.js.map +1 -1
- package/lib/zudoku.openapi-worker.js +2354 -2268
- package/lib/zudoku.openapi-worker.js.map +1 -1
- package/lib/zudoku.plugin-api-keys.js +60 -70
- package/lib/zudoku.plugin-api-keys.js.map +1 -1
- package/lib/zudoku.plugin-custom-pages.js +16 -8
- package/lib/zudoku.plugin-custom-pages.js.map +1 -1
- package/lib/zudoku.plugin-markdown.js +27 -93
- package/lib/zudoku.plugin-markdown.js.map +1 -1
- package/lib/zudoku.plugin-openapi.js +7 -7
- package/lib/zudoku.plugin-redirect.js +1 -1
- package/lib/zudoku.plugin-search-inkeep.js +9 -13
- package/lib/zudoku.plugin-search-inkeep.js.map +1 -1
- package/package.json +1 -1
- package/src/app/entry.client.tsx +2 -4
- package/src/app/entry.server.tsx +0 -4
- package/src/app/main.css +0 -5
- package/src/app/main.tsx +27 -13
- package/src/app/standalone.tsx +1 -1
- package/src/lib/authentication/components/CallbackHandler.tsx +20 -51
- package/src/lib/authentication/hook.ts +1 -1
- package/src/lib/components/Header.tsx +4 -12
- package/src/lib/components/MobileTopNavigation.tsx +9 -3
- package/src/lib/components/Search.tsx +1 -1
- package/src/lib/components/SlotletProvider.tsx +14 -7
- package/src/lib/components/TopNavigation.tsx +37 -58
- package/src/lib/components/context/ZudokuContext.ts +20 -28
- package/src/lib/components/index.ts +13 -4
- package/src/lib/components/navigation/Sidebar.tsx +6 -6
- package/src/lib/components/navigation/SidebarCategory.tsx +37 -27
- package/src/lib/components/navigation/SidebarItem.tsx +19 -18
- package/src/lib/components/navigation/utils.ts +16 -11
- package/src/lib/core/DevPortalContext.ts +7 -3
- package/src/lib/core/plugins.ts +0 -2
- package/src/lib/errors/ErrorAlert.tsx +18 -5
- package/src/lib/plugins/custom-pages/CustomPage.tsx +18 -0
- package/src/lib/plugins/custom-pages/index.tsx +11 -9
- package/src/lib/plugins/markdown/MdxPage.tsx +10 -8
- package/src/lib/plugins/markdown/generateRoutes.tsx +38 -0
- package/src/lib/plugins/markdown/index.tsx +12 -49
- package/src/lib/plugins/openapi/Endpoint.tsx +2 -2
- package/src/lib/plugins/openapi/RequestBodySidecarBox.tsx +1 -1
- package/src/lib/plugins/openapi/Sidecar.tsx +1 -1
- package/src/lib/plugins/openapi/client/worker.ts +2 -2
- package/src/lib/plugins/openapi/index.tsx +1 -1
- package/src/lib/plugins/openapi/playground/Playground.tsx +1 -0
- package/src/lib/util/invariant.ts +15 -3
- package/src/lib/util/useExposedProps.tsx +10 -0
- package/src/lib/util/useScrollToAnchor.ts +1 -1
- package/dist/lib/plugins/markdown/resolver.d.ts +0 -38
- package/dist/lib/plugins/markdown/resolver.js +0 -75
- package/dist/lib/plugins/markdown/resolver.js.map +0 -1
- package/dist/vite/debug.d.ts +0 -1
- package/dist/vite/debug.js +0 -10
- package/dist/vite/debug.js.map +0 -1
- package/lib/AnchorLink-DovtSBJk.js.map +0 -1
- package/lib/ErrorPage-CUz-Zzmx.js +0 -16
- package/lib/ErrorPage-CUz-Zzmx.js.map +0 -1
- package/lib/MdxPage-C5I9c7R1.js.map +0 -1
- package/lib/OperationList-qsBOguHS.js.map +0 -1
- package/lib/SidebarBadge-DaA0-bFW.js.map +0 -1
- package/lib/SlotletProvider-BGEs7yyu.js +0 -240
- package/lib/SlotletProvider-BGEs7yyu.js.map +0 -1
- package/lib/Spinner-3cQDBVGr.js +0 -7
- package/lib/Spinner-3cQDBVGr.js.map +0 -1
- package/lib/ZudokuContext-DSipF8sq.js.map +0 -1
- package/lib/__vite-browser-external-BYRIRx8p.js +0 -9
- package/lib/__vite-browser-external-BYRIRx8p.js.map +0 -1
- package/lib/index-BIl-R3aH.js.map +0 -1
- package/lib/index-DJqnphbT.js +0 -35
- package/lib/index-Dssw7Gff.js.map +0 -1
- package/src/lib/plugins/markdown/resolver.ts +0 -92
|
@@ -1,39 +1,38 @@
|
|
|
1
1
|
import { j as p } from "./jsx-runtime-B6kdoens.js";
|
|
2
|
-
import {
|
|
3
|
-
import { XIcon as cr, EraserIcon as ur, ChevronsUpDownIcon as
|
|
4
|
-
import { createClient as
|
|
5
|
-
import { c as
|
|
6
|
-
import {
|
|
7
|
-
import { a as F, b as
|
|
2
|
+
import { z as ma, A as ha } from "./ZudokuContext-DEoP3GGJ.js";
|
|
3
|
+
import { XIcon as cr, EraserIcon as ur, ChevronsUpDownIcon as ya, LogInIcon as va, CirclePlayIcon as ga } from "lucide-react";
|
|
4
|
+
import { createClient as ba } from "zudoku/openapi-worker";
|
|
5
|
+
import { c as xa, i as ka, u as $a, a as Sa, P as ft, b as vt, B as je, S as wa, V as ja, f as Na } from "./index-CBr6BM_4.js";
|
|
6
|
+
import { C as Ta } from "./CategoryHeading-D2WS6sRI.js";
|
|
7
|
+
import { P as Oa, H as Ca, a as F, b as Pa, S as We, C as Ea } from "./Markdown-DM4zv3MA.js";
|
|
8
|
+
import { j as Ra } from "./joinPath-B7kNnUX4.js";
|
|
8
9
|
import * as P from "react";
|
|
9
|
-
import { useRef as dr, useEffect as pr, useState as fr, useTransition as mr, Fragment as Ze, createContext as
|
|
10
|
-
import { O as hr, C as yr, a as
|
|
11
|
-
import { g as Yt, I as it, C as $e, h as
|
|
10
|
+
import { useRef as dr, useEffect as pr, useState as fr, useTransition as mr, Fragment as Ze, createContext as Aa, useContext as qa, useMemo as Fa } from "react";
|
|
11
|
+
import { O as hr, C as yr, a as Ia, b as vr, D as gr, e as _a, d as La, T as Ua, c as br, R as Ha, I as Ma, P as Ba, f as vn, g as me } from "./Spinner-DFQhPMBl.js";
|
|
12
|
+
import { g as Yt, I as it, C as $e, h as Va, u as za, a as Da, S as gn, b as bn, c as xn, d as kn, f as gt, F as Ja } from "./Input-CO-1DOZa.js";
|
|
12
13
|
import { a as xr } from "./state-CsuHT8ZO.js";
|
|
13
|
-
import {
|
|
14
|
-
import {
|
|
15
|
-
import {
|
|
16
|
-
import {
|
|
17
|
-
|
|
18
|
-
import { c as ni } from "./router-Oe6YmY6B.js";
|
|
19
|
-
var kr = {}, mt = P.createContext(kr), su = mt.Provider;
|
|
14
|
+
import { g as Wa, c as He, a as Ga } from "./_commonjsHelpers-BkfeUUK-.js";
|
|
15
|
+
import { b as Qa, d as Ka } from "./index-CRo94sKK.js";
|
|
16
|
+
import { o as $n, s as _t, t as Ya, a as Xa, c as Za, C as ei, b as ti, f as ni } from "./urql-core-KJnLL26g.js";
|
|
17
|
+
import { b as ri } from "./router-BsfSoK2j.js";
|
|
18
|
+
var kr = {}, mt = P.createContext(kr), uu = mt.Provider;
|
|
20
19
|
mt.Consumer;
|
|
21
20
|
mt.displayName = "UrqlContext";
|
|
22
|
-
var
|
|
21
|
+
var ai = () => {
|
|
23
22
|
var e = P.useContext(mt);
|
|
24
23
|
if (e === kr && process.env.NODE_ENV !== "production") {
|
|
25
24
|
var t = "No client has been specified using urql's Provider. please create a client and add a Provider.";
|
|
26
25
|
throw console.error(t), new Error(t);
|
|
27
26
|
}
|
|
28
27
|
return e;
|
|
29
|
-
},
|
|
28
|
+
}, ii = {
|
|
30
29
|
fetching: !1,
|
|
31
30
|
stale: !1,
|
|
32
31
|
error: void 0,
|
|
33
32
|
data: void 0,
|
|
34
33
|
extensions: void 0,
|
|
35
34
|
operation: void 0
|
|
36
|
-
},
|
|
35
|
+
}, oi = (e, t) => e === t || !(!e || !t || e.key !== t.key), bt = (e, t) => {
|
|
37
36
|
var n = {
|
|
38
37
|
...e,
|
|
39
38
|
...t,
|
|
@@ -46,11 +45,11 @@ var ri = () => {
|
|
|
46
45
|
if (!(i in s))
|
|
47
46
|
return !0;
|
|
48
47
|
for (var r in s)
|
|
49
|
-
if (r === "operation" ? !
|
|
48
|
+
if (r === "operation" ? !oi(a[r], s[r]) : a[r] !== s[r])
|
|
50
49
|
return !0;
|
|
51
50
|
return !1;
|
|
52
51
|
})(e, n) ? n : e;
|
|
53
|
-
},
|
|
52
|
+
}, si = (e, t) => {
|
|
54
53
|
for (var n = 0, a = t.length; n < a; n++)
|
|
55
54
|
if (e[n] !== t[n])
|
|
56
55
|
return !0;
|
|
@@ -59,14 +58,14 @@ var ri = () => {
|
|
|
59
58
|
function Sn(e, t) {
|
|
60
59
|
process.env.NODE_ENV !== "production" && xt && xt.ReactCurrentOwner && xt.ReactCurrentOwner.current ? Promise.resolve(t).then(e) : e(t);
|
|
61
60
|
}
|
|
62
|
-
function
|
|
61
|
+
function li(e, t) {
|
|
63
62
|
var n = P.useRef(void 0);
|
|
64
63
|
return P.useMemo(() => {
|
|
65
|
-
var a =
|
|
64
|
+
var a = Za(e, t);
|
|
66
65
|
return n.current !== void 0 && n.current.key === a.key ? n.current : (n.current = a, a);
|
|
67
66
|
}, [e, t]);
|
|
68
67
|
}
|
|
69
|
-
var
|
|
68
|
+
var ci = (e) => {
|
|
70
69
|
if (!e._react) {
|
|
71
70
|
var t = /* @__PURE__ */ new Set(), n = /* @__PURE__ */ new Map();
|
|
72
71
|
e.operations$ && _t((a) => {
|
|
@@ -82,9 +81,9 @@ var li = (e) => {
|
|
|
82
81
|
};
|
|
83
82
|
}
|
|
84
83
|
return e._react;
|
|
85
|
-
},
|
|
86
|
-
function
|
|
87
|
-
var t =
|
|
84
|
+
}, ui = (e, t) => t && t.suspense !== void 0 ? !!t.suspense : e.suspense;
|
|
85
|
+
function di(e) {
|
|
86
|
+
var t = ai(), n = ci(t), a = ui(t, e.context), s = li(e.query, e.variables), i = P.useMemo(() => {
|
|
88
87
|
if (e.pause)
|
|
89
88
|
return null;
|
|
90
89
|
var d = t.executeQuery(s, {
|
|
@@ -106,7 +105,7 @@ function ui(e) {
|
|
|
106
105
|
} else {
|
|
107
106
|
var v, g = _t((y) => {
|
|
108
107
|
h = y, v && v(h);
|
|
109
|
-
})(
|
|
108
|
+
})(Ya(() => m && !v || !h)(d));
|
|
110
109
|
if (h == null && m) {
|
|
111
110
|
var b = new Promise((y) => {
|
|
112
111
|
v = y;
|
|
@@ -118,8 +117,8 @@ function ui(e) {
|
|
|
118
117
|
return h || {
|
|
119
118
|
fetching: !0
|
|
120
119
|
};
|
|
121
|
-
}, [n, s]), o = [t, s, e.requestPolicy, e.context, e.pause], [l, c] = P.useState(() => [i, bt(
|
|
122
|
-
i !== l[0] &&
|
|
120
|
+
}, [n, s]), o = [t, s, e.requestPolicy, e.context, e.pause], [l, c] = P.useState(() => [i, bt(ii, r(i, a)), o]), u = l[1];
|
|
121
|
+
i !== l[0] && si(l[2], o) && c([i, u = bt(l[1], r(i, a)), o]), P.useEffect(() => {
|
|
123
122
|
var d = l[0], m = l[2][1], h = !1, v = (b) => {
|
|
124
123
|
h = !0, Sn(c, (y) => {
|
|
125
124
|
var x = bt(y[1], b);
|
|
@@ -127,7 +126,7 @@ function ui(e) {
|
|
|
127
126
|
});
|
|
128
127
|
};
|
|
129
128
|
if (d) {
|
|
130
|
-
var g = _t(v)(
|
|
129
|
+
var g = _t(v)(Xa(() => {
|
|
131
130
|
v({
|
|
132
131
|
fetching: !1
|
|
133
132
|
});
|
|
@@ -154,7 +153,7 @@ function ui(e) {
|
|
|
154
153
|
}, [t, n, s, a, e.requestPolicy, e.context, e.pause]);
|
|
155
154
|
return [u, f];
|
|
156
155
|
}
|
|
157
|
-
const
|
|
156
|
+
const pi = {
|
|
158
157
|
kind: "Document",
|
|
159
158
|
definitions: [
|
|
160
159
|
{
|
|
@@ -299,7 +298,7 @@ const di = {
|
|
|
299
298
|
}
|
|
300
299
|
}
|
|
301
300
|
]
|
|
302
|
-
},
|
|
301
|
+
}, fi = {
|
|
303
302
|
kind: "Document",
|
|
304
303
|
definitions: [
|
|
305
304
|
{
|
|
@@ -375,7 +374,7 @@ const di = {
|
|
|
375
374
|
}
|
|
376
375
|
}
|
|
377
376
|
]
|
|
378
|
-
},
|
|
377
|
+
}, mi = {
|
|
379
378
|
kind: "Document",
|
|
380
379
|
definitions: [
|
|
381
380
|
{
|
|
@@ -619,7 +618,7 @@ const di = {
|
|
|
619
618
|
}
|
|
620
619
|
}
|
|
621
620
|
]
|
|
622
|
-
},
|
|
621
|
+
}, hi = {
|
|
623
622
|
kind: "Document",
|
|
624
623
|
definitions: [
|
|
625
624
|
{
|
|
@@ -695,7 +694,7 @@ const di = {
|
|
|
695
694
|
}
|
|
696
695
|
}
|
|
697
696
|
]
|
|
698
|
-
},
|
|
697
|
+
}, yi = {
|
|
699
698
|
kind: "Document",
|
|
700
699
|
definitions: [
|
|
701
700
|
{
|
|
@@ -811,17 +810,25 @@ const di = {
|
|
|
811
810
|
}
|
|
812
811
|
}
|
|
813
812
|
]
|
|
814
|
-
},
|
|
815
|
-
"\n query ServersQuery($input: JSON!, $type: SchemaType!) {\n schema(input: $input, type: $type) {\n url\n servers {\n url\n }\n }\n }\n":
|
|
816
|
-
"\n fragment OperationsFragment on OperationItem {\n slug\n summary\n method\n description\n operationId\n contentTypes\n path\n parameters {\n name\n in\n description\n required\n schema\n style\n examples {\n name\n description\n externalValue\n value\n summary\n }\n }\n requestBody {\n content {\n mediaType\n encoding {\n name\n }\n schema\n }\n description\n required\n }\n responses {\n statusCode\n links\n description\n content {\n mediaType\n encoding {\n name\n }\n schema\n }\n }\n }\n":
|
|
817
|
-
"\n query AllOperations($input: JSON!, $type: SchemaType!) {\n schema(input: $input, type: $type) {\n description\n title\n url\n version\n tags {\n name\n description\n operations {\n slug\n ...OperationsFragment\n }\n }\n }\n }\n":
|
|
818
|
-
"\n query getServerQuery($input: JSON!, $type: SchemaType!) {\n schema(input: $input, type: $type) {\n url\n servers {\n url\n }\n }\n }\n":
|
|
819
|
-
"\n query GetCategories($input: JSON!, $type: SchemaType!) {\n schema(input: $input, type: $type) {\n tags {\n __typename\n name\n operations {\n __typename\n slug\n deprecated\n method\n summary\n operationId\n path\n }\n }\n }\n }\n":
|
|
813
|
+
}, vi = {
|
|
814
|
+
"\n query ServersQuery($input: JSON!, $type: SchemaType!) {\n schema(input: $input, type: $type) {\n url\n servers {\n url\n }\n }\n }\n": fi,
|
|
815
|
+
"\n fragment OperationsFragment on OperationItem {\n slug\n summary\n method\n description\n operationId\n contentTypes\n path\n parameters {\n name\n in\n description\n required\n schema\n style\n examples {\n name\n description\n externalValue\n value\n summary\n }\n }\n requestBody {\n content {\n mediaType\n encoding {\n name\n }\n schema\n }\n description\n required\n }\n responses {\n statusCode\n links\n description\n content {\n mediaType\n encoding {\n name\n }\n schema\n }\n }\n }\n": pi,
|
|
816
|
+
"\n query AllOperations($input: JSON!, $type: SchemaType!) {\n schema(input: $input, type: $type) {\n description\n title\n url\n version\n tags {\n name\n description\n operations {\n slug\n ...OperationsFragment\n }\n }\n }\n }\n": mi,
|
|
817
|
+
"\n query getServerQuery($input: JSON!, $type: SchemaType!) {\n schema(input: $input, type: $type) {\n url\n servers {\n url\n }\n }\n }\n": hi,
|
|
818
|
+
"\n query GetCategories($input: JSON!, $type: SchemaType!) {\n schema(input: $input, type: $type) {\n tags {\n __typename\n name\n operations {\n __typename\n slug\n deprecated\n method\n summary\n operationId\n path\n }\n }\n }\n }\n": yi
|
|
820
819
|
};
|
|
821
820
|
function $r(e) {
|
|
822
|
-
return
|
|
821
|
+
return vi[e] ?? {};
|
|
823
822
|
}
|
|
824
|
-
const
|
|
823
|
+
const gi = ({
|
|
824
|
+
title: e = "An error occurred",
|
|
825
|
+
message: t,
|
|
826
|
+
category: n
|
|
827
|
+
}) => /* @__PURE__ */ p.jsxs("div", { className: Oa + " h-full pt-[--padding-content-top]", children: [
|
|
828
|
+
n && /* @__PURE__ */ p.jsx(Ta, { children: n }),
|
|
829
|
+
e && /* @__PURE__ */ p.jsx(Ca, { level: 1, className: "flex gap-3.5 items-center", children: e }),
|
|
830
|
+
/* @__PURE__ */ p.jsx("p", { children: t })
|
|
831
|
+
] }), bi = La, xi = Ua, ki = _a, Sr = P.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ p.jsx(
|
|
825
832
|
hr,
|
|
826
833
|
{
|
|
827
834
|
ref: n,
|
|
@@ -833,7 +840,7 @@ const vi = Ia, gi = _a, bi = Fa, Sr = P.forwardRef(({ className: e, ...t }, n) =
|
|
|
833
840
|
}
|
|
834
841
|
));
|
|
835
842
|
Sr.displayName = hr.displayName;
|
|
836
|
-
const wr = P.forwardRef(({ className: e, children: t, ...n }, a) => /* @__PURE__ */ p.jsxs(
|
|
843
|
+
const wr = P.forwardRef(({ className: e, children: t, ...n }, a) => /* @__PURE__ */ p.jsxs(ki, { children: [
|
|
837
844
|
/* @__PURE__ */ p.jsx(Sr, {}),
|
|
838
845
|
/* @__PURE__ */ p.jsxs(
|
|
839
846
|
yr,
|
|
@@ -846,7 +853,7 @@ const wr = P.forwardRef(({ className: e, children: t, ...n }, a) => /* @__PURE__
|
|
|
846
853
|
...n,
|
|
847
854
|
children: [
|
|
848
855
|
t,
|
|
849
|
-
/* @__PURE__ */ p.jsxs(
|
|
856
|
+
/* @__PURE__ */ p.jsxs(Ia, { className: "absolute right-4 top-4 rounded-sm opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none data-[state=open]:bg-accent data-[state=open]:text-muted-foreground", children: [
|
|
850
857
|
/* @__PURE__ */ p.jsx(cr, { className: "h-4 w-4" }),
|
|
851
858
|
/* @__PURE__ */ p.jsx("span", { className: "sr-only", children: "Close" })
|
|
852
859
|
] })
|
|
@@ -867,7 +874,7 @@ const jr = P.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ p.jsx(
|
|
|
867
874
|
}
|
|
868
875
|
));
|
|
869
876
|
jr.displayName = vr.displayName;
|
|
870
|
-
const
|
|
877
|
+
const $i = P.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ p.jsx(
|
|
871
878
|
gr,
|
|
872
879
|
{
|
|
873
880
|
ref: n,
|
|
@@ -875,7 +882,7 @@ const xi = P.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ p.jsx(
|
|
|
875
882
|
...t
|
|
876
883
|
}
|
|
877
884
|
));
|
|
878
|
-
|
|
885
|
+
$i.displayName = gr.displayName;
|
|
879
886
|
const ot = P.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ p.jsx(
|
|
880
887
|
"div",
|
|
881
888
|
{
|
|
@@ -906,7 +913,7 @@ const Tr = P.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ p.jsx(
|
|
|
906
913
|
}
|
|
907
914
|
));
|
|
908
915
|
Tr.displayName = "CardTitle";
|
|
909
|
-
const
|
|
916
|
+
const Si = P.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ p.jsx(
|
|
910
917
|
"p",
|
|
911
918
|
{
|
|
912
919
|
ref: n,
|
|
@@ -914,10 +921,10 @@ const ki = P.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ p.jsx(
|
|
|
914
921
|
...t
|
|
915
922
|
}
|
|
916
923
|
));
|
|
917
|
-
|
|
924
|
+
Si.displayName = "CardDescription";
|
|
918
925
|
const Or = P.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ p.jsx("div", { ref: n, className: F("p-6 pt-0", e), ...t }));
|
|
919
926
|
Or.displayName = "CardContent";
|
|
920
|
-
const
|
|
927
|
+
const wi = P.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ p.jsx(
|
|
921
928
|
"div",
|
|
922
929
|
{
|
|
923
930
|
ref: n,
|
|
@@ -925,10 +932,10 @@ const $i = P.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ p.jsx(
|
|
|
925
932
|
...t
|
|
926
933
|
}
|
|
927
934
|
));
|
|
928
|
-
|
|
929
|
-
var Xt = "Tabs", [
|
|
935
|
+
wi.displayName = "CardFooter";
|
|
936
|
+
var Xt = "Tabs", [ji, du] = xa(Xt, [
|
|
930
937
|
br
|
|
931
|
-
]), Cr = br(), [
|
|
938
|
+
]), Cr = br(), [Ni, Zt] = ji(Xt), Pr = P.forwardRef(
|
|
932
939
|
(e, t) => {
|
|
933
940
|
const {
|
|
934
941
|
__scopeTabs: n,
|
|
@@ -939,16 +946,16 @@ var Xt = "Tabs", [Si, lu] = ka(Xt, [
|
|
|
939
946
|
dir: o,
|
|
940
947
|
activationMode: l = "automatic",
|
|
941
948
|
...c
|
|
942
|
-
} = e, u =
|
|
949
|
+
} = e, u = ka(o), [f, d] = $a({
|
|
943
950
|
prop: a,
|
|
944
951
|
onChange: s,
|
|
945
952
|
defaultProp: i
|
|
946
953
|
});
|
|
947
954
|
return /* @__PURE__ */ p.jsx(
|
|
948
|
-
|
|
955
|
+
Ni,
|
|
949
956
|
{
|
|
950
957
|
scope: n,
|
|
951
|
-
baseId:
|
|
958
|
+
baseId: Sa(),
|
|
952
959
|
value: f,
|
|
953
960
|
onValueChange: d,
|
|
954
961
|
orientation: r,
|
|
@@ -972,7 +979,7 @@ var Er = "TabsList", Rr = P.forwardRef(
|
|
|
972
979
|
(e, t) => {
|
|
973
980
|
const { __scopeTabs: n, loop: a = !0, ...s } = e, i = Zt(Er, n), r = Cr(n);
|
|
974
981
|
return /* @__PURE__ */ p.jsx(
|
|
975
|
-
|
|
982
|
+
Ha,
|
|
976
983
|
{
|
|
977
984
|
asChild: !0,
|
|
978
985
|
...r,
|
|
@@ -997,7 +1004,7 @@ var Ar = "TabsTrigger", qr = P.forwardRef(
|
|
|
997
1004
|
(e, t) => {
|
|
998
1005
|
const { __scopeTabs: n, value: a, disabled: s = !1, ...i } = e, r = Zt(Ar, n), o = Cr(n), l = _r(r.baseId, a), c = Lr(r.baseId, a), u = a === r.value;
|
|
999
1006
|
return /* @__PURE__ */ p.jsx(
|
|
1000
|
-
|
|
1007
|
+
Ma,
|
|
1001
1008
|
{
|
|
1002
1009
|
asChild: !0,
|
|
1003
1010
|
...o,
|
|
@@ -1039,7 +1046,7 @@ var Fr = "TabsContent", Ir = P.forwardRef(
|
|
|
1039
1046
|
return P.useEffect(() => {
|
|
1040
1047
|
const d = requestAnimationFrame(() => f.current = !1);
|
|
1041
1048
|
return () => cancelAnimationFrame(d);
|
|
1042
|
-
}, []), /* @__PURE__ */ p.jsx(
|
|
1049
|
+
}, []), /* @__PURE__ */ p.jsx(Ba, { present: s || u, children: ({ present: d }) => /* @__PURE__ */ p.jsx(
|
|
1043
1050
|
ft.div,
|
|
1044
1051
|
{
|
|
1045
1052
|
"data-state": u ? "active" : "inactive",
|
|
@@ -1106,12 +1113,12 @@ const Ce = P.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ p.jsx(
|
|
|
1106
1113
|
Ce.displayName = nn.displayName;
|
|
1107
1114
|
const kt = (e) => Math.abs(
|
|
1108
1115
|
isNaN(parseInt(e)) ? e.toLowerCase().charCodeAt(0) - 96 : isNaN(parseInt(e)) ? 0 : parseInt(e)
|
|
1109
|
-
), $t = (e) => e.length > 1 ? parseInt(e.split("").reduce((t, n) => `${kt(t) + kt(n)}`)) : kt(e),
|
|
1116
|
+
), $t = (e) => e.length > 1 ? parseInt(e.split("").reduce((t, n) => `${kt(t) + kt(n)}`)) : kt(e), Ti = (e, t = {}) => {
|
|
1110
1117
|
const n = (3 * $t(e) + 2 * $t(e) + $t(e)) % 360, { saturation: a = 75, lightness: s = 60 } = t;
|
|
1111
1118
|
return `${n}deg ${a}% ${s}%`;
|
|
1112
|
-
}, St = "data-linked-param",
|
|
1113
|
-
const [t] =
|
|
1114
|
-
return
|
|
1119
|
+
}, St = "data-linked-param", Oi = (e) => {
|
|
1120
|
+
const [t] = Pa();
|
|
1121
|
+
return Ti(
|
|
1115
1122
|
e,
|
|
1116
1123
|
t ? void 0 : { saturation: 85, lightness: 50 }
|
|
1117
1124
|
);
|
|
@@ -1124,7 +1131,7 @@ const kt = (e) => Math.abs(
|
|
|
1124
1131
|
children: i,
|
|
1125
1132
|
onClick: r
|
|
1126
1133
|
}) => {
|
|
1127
|
-
const o = dr(null), l = e.replace(/[{}]/g, ""), c = s == null ? void 0 : s.replace(/[{}]/g, ""), u =
|
|
1134
|
+
const o = dr(null), l = e.replace(/[{}]/g, ""), c = s == null ? void 0 : s.replace(/[{}]/g, ""), u = Oi(l), f = `hsl(${u} / ${a})`, d = `hsl(${u} / ${n})`;
|
|
1128
1135
|
return pr(() => {
|
|
1129
1136
|
if (!c || !o.current) return;
|
|
1130
1137
|
const m = () => {
|
|
@@ -1159,7 +1166,7 @@ const kt = (e) => Math.abs(
|
|
|
1159
1166
|
]
|
|
1160
1167
|
}
|
|
1161
1168
|
);
|
|
1162
|
-
},
|
|
1169
|
+
}, Ci = (e, t, n) => {
|
|
1163
1170
|
const a = t.replace(/(:\w+|\{\w+})/g, (i) => {
|
|
1164
1171
|
var l;
|
|
1165
1172
|
const r = i.replace(/[:{}]/g, "");
|
|
@@ -1171,7 +1178,7 @@ const kt = (e) => Math.abs(
|
|
|
1171
1178
|
return n.queryParams.filter((i) => i.active).forEach((i) => {
|
|
1172
1179
|
s.searchParams.set(i.name, i.value);
|
|
1173
1180
|
}), s;
|
|
1174
|
-
},
|
|
1181
|
+
}, Pi = ({
|
|
1175
1182
|
control: e,
|
|
1176
1183
|
register: t
|
|
1177
1184
|
}) => {
|
|
@@ -1232,7 +1239,7 @@ const kt = (e) => Math.abs(
|
|
|
1232
1239
|
}
|
|
1233
1240
|
) })
|
|
1234
1241
|
] });
|
|
1235
|
-
},
|
|
1242
|
+
}, Ei = ({
|
|
1236
1243
|
control: e
|
|
1237
1244
|
}) => {
|
|
1238
1245
|
const { fields: t } = Yt({
|
|
@@ -1304,9 +1311,9 @@ const kt = (e) => Math.abs(
|
|
|
1304
1311
|
)
|
|
1305
1312
|
] }) })
|
|
1306
1313
|
] }, n.id)) }) });
|
|
1307
|
-
},
|
|
1314
|
+
}, Ri = (e, t) => {
|
|
1308
1315
|
const n = P.forwardRef(({ className: a, asChild: s, ...i }, r) => {
|
|
1309
|
-
const o = s ?
|
|
1316
|
+
const o = s ? wa : e;
|
|
1310
1317
|
return P.createElement(o, {
|
|
1311
1318
|
...i,
|
|
1312
1319
|
ref: r,
|
|
@@ -1314,17 +1321,17 @@ const kt = (e) => Math.abs(
|
|
|
1314
1321
|
});
|
|
1315
1322
|
});
|
|
1316
1323
|
return n.displayName = `VariantComponent(${e})`, n;
|
|
1317
|
-
},
|
|
1324
|
+
}, Ai = Ri(
|
|
1318
1325
|
"input",
|
|
1319
1326
|
"px-2 bg-transparent h-6 font-mono text-xs m-2"
|
|
1320
|
-
),
|
|
1327
|
+
), qi = ({
|
|
1321
1328
|
control: e,
|
|
1322
1329
|
queryParams: t
|
|
1323
1330
|
}) => {
|
|
1324
1331
|
const { fields: n } = Yt({
|
|
1325
1332
|
control: e,
|
|
1326
1333
|
name: "queryParams"
|
|
1327
|
-
}), a =
|
|
1334
|
+
}), a = Va(), s = t.map((o) => !!o.isRequired), r = a.watch("identity") !== et;
|
|
1328
1335
|
return /* @__PURE__ */ p.jsx("div", { className: "", children: /* @__PURE__ */ p.jsx("table", { className: "w-full [&_td]:border [&_td]:p-1.5 [&_td]:px-2", children: /* @__PURE__ */ p.jsx("tbody", { children: n.filter(
|
|
1329
1336
|
// TODO remove this hack for Accu or make it more generic
|
|
1330
1337
|
(o) => !(r && o.name === "apikey")
|
|
@@ -1349,7 +1356,7 @@ const kt = (e) => Math.abs(
|
|
|
1349
1356
|
$e,
|
|
1350
1357
|
{
|
|
1351
1358
|
control: e,
|
|
1352
|
-
render: ({ field: c }) => /* @__PURE__ */ p.jsx(
|
|
1359
|
+
render: ({ field: c }) => /* @__PURE__ */ p.jsx(Ai, { asChild: !0, children: /* @__PURE__ */ p.jsxs(
|
|
1353
1360
|
"label",
|
|
1354
1361
|
{
|
|
1355
1362
|
className: "flex items-center cursor-pointer",
|
|
@@ -1408,7 +1415,7 @@ const kt = (e) => Math.abs(
|
|
|
1408
1415
|
)
|
|
1409
1416
|
] }) })
|
|
1410
1417
|
] }, o.id)) }) }) });
|
|
1411
|
-
},
|
|
1418
|
+
}, Hr = ({
|
|
1412
1419
|
value: e,
|
|
1413
1420
|
onChange: t,
|
|
1414
1421
|
className: n,
|
|
@@ -1435,10 +1442,10 @@ const kt = (e) => Math.abs(
|
|
|
1435
1442
|
!s && "hidden",
|
|
1436
1443
|
"row-start-1 col-start-1 self-center justify-self-end relative end-2 pointer-events-none"
|
|
1437
1444
|
),
|
|
1438
|
-
children: /* @__PURE__ */ p.jsx(
|
|
1445
|
+
children: /* @__PURE__ */ p.jsx(ya, { size: 14 })
|
|
1439
1446
|
}
|
|
1440
1447
|
)
|
|
1441
|
-
] }),
|
|
1448
|
+
] }), Fi = (e) => {
|
|
1442
1449
|
var n;
|
|
1443
1450
|
return (n = Object.entries({
|
|
1444
1451
|
"application/json": "json",
|
|
@@ -1451,25 +1458,25 @@ const kt = (e) => Math.abs(
|
|
|
1451
1458
|
}).find(
|
|
1452
1459
|
([a]) => e.includes(a)
|
|
1453
1460
|
)) == null ? void 0 : n[1];
|
|
1454
|
-
},
|
|
1461
|
+
}, Ii = (e) => {
|
|
1455
1462
|
const t = e.get("Content-Type") || "";
|
|
1456
|
-
return
|
|
1457
|
-
},
|
|
1463
|
+
return Fi(t);
|
|
1464
|
+
}, _i = (e) => {
|
|
1458
1465
|
try {
|
|
1459
1466
|
return JSON.stringify(JSON.parse(e), null, 2);
|
|
1460
1467
|
} catch {
|
|
1461
1468
|
return null;
|
|
1462
1469
|
}
|
|
1463
|
-
},
|
|
1470
|
+
}, Li = ({
|
|
1464
1471
|
body: e = "",
|
|
1465
1472
|
headers: t
|
|
1466
1473
|
}) => {
|
|
1467
|
-
const n =
|
|
1474
|
+
const n = Ii(t), a = _i(e), s = a || e, [i, r] = fr(
|
|
1468
1475
|
a ? "formatted" : "raw"
|
|
1469
1476
|
);
|
|
1470
1477
|
return /* @__PURE__ */ p.jsxs("div", { className: "flex flex-col gap-2", children: [
|
|
1471
1478
|
/* @__PURE__ */ p.jsx(ot, { className: "shadow-none", children: /* @__PURE__ */ p.jsx(
|
|
1472
|
-
|
|
1479
|
+
We,
|
|
1473
1480
|
{
|
|
1474
1481
|
language: i === "raw" ? a ? "plain" : n : "json",
|
|
1475
1482
|
noBackground: !0,
|
|
@@ -1478,7 +1485,7 @@ const kt = (e) => Math.abs(
|
|
|
1478
1485
|
}
|
|
1479
1486
|
) }),
|
|
1480
1487
|
a && /* @__PURE__ */ p.jsx("div", { className: "flex justify-end", children: /* @__PURE__ */ p.jsx(
|
|
1481
|
-
|
|
1488
|
+
Hr,
|
|
1482
1489
|
{
|
|
1483
1490
|
value: i,
|
|
1484
1491
|
onChange: (o) => r(o.target.value),
|
|
@@ -1489,7 +1496,7 @@ const kt = (e) => Math.abs(
|
|
|
1489
1496
|
}
|
|
1490
1497
|
) })
|
|
1491
1498
|
] });
|
|
1492
|
-
}, et = "__none",
|
|
1499
|
+
}, et = "__none", Ui = {
|
|
1493
1500
|
200: "OK",
|
|
1494
1501
|
201: "Created",
|
|
1495
1502
|
202: "Accepted",
|
|
@@ -1500,7 +1507,7 @@ const kt = (e) => Math.abs(
|
|
|
1500
1507
|
404: "Not Found",
|
|
1501
1508
|
405: "Method Not Allowed",
|
|
1502
1509
|
500: "Internal Server Error"
|
|
1503
|
-
},
|
|
1510
|
+
}, Hi = ({
|
|
1504
1511
|
server: e,
|
|
1505
1512
|
servers: t,
|
|
1506
1513
|
url: n,
|
|
@@ -1511,21 +1518,21 @@ const kt = (e) => Math.abs(
|
|
|
1511
1518
|
defaultBody: o = ""
|
|
1512
1519
|
}) => {
|
|
1513
1520
|
var A, M;
|
|
1514
|
-
const { selectedServer: l, setSelectedServer: c } = xr(), [, u] = mr(), { register: f, control: d, handleSubmit: m, watch: h, setValue: v, ...g } =
|
|
1521
|
+
const { selectedServer: l, setSelectedServer: c } = xr(), [, u] = mr(), { register: f, control: d, handleSubmit: m, watch: h, setValue: v, ...g } = za({
|
|
1515
1522
|
defaultValues: {
|
|
1516
1523
|
body: o,
|
|
1517
|
-
queryParams: i.map((
|
|
1518
|
-
name:
|
|
1519
|
-
value:
|
|
1520
|
-
active:
|
|
1524
|
+
queryParams: i.map((k) => ({
|
|
1525
|
+
name: k.name,
|
|
1526
|
+
value: k.defaultValue ?? "",
|
|
1527
|
+
active: k.defaultActive ?? !1
|
|
1521
1528
|
})),
|
|
1522
|
-
pathParams: r.map((
|
|
1523
|
-
name:
|
|
1524
|
-
value:
|
|
1529
|
+
pathParams: r.map((k) => ({
|
|
1530
|
+
name: k.name,
|
|
1531
|
+
value: k.defaultValue ?? ""
|
|
1525
1532
|
})),
|
|
1526
|
-
headers: s.map((
|
|
1527
|
-
name:
|
|
1528
|
-
value:
|
|
1533
|
+
headers: s.map((k) => ({
|
|
1534
|
+
name: k.name,
|
|
1535
|
+
value: k.defaultValue ?? ""
|
|
1529
1536
|
})),
|
|
1530
1537
|
identity: et
|
|
1531
1538
|
}
|
|
@@ -1533,19 +1540,20 @@ const kt = (e) => Math.abs(
|
|
|
1533
1540
|
pr(() => {
|
|
1534
1541
|
var L;
|
|
1535
1542
|
if (x.current) return;
|
|
1536
|
-
const
|
|
1537
|
-
|
|
1543
|
+
const k = (L = y.data) == null ? void 0 : L.at(0);
|
|
1544
|
+
k && (v("identity", k.id), x.current = !0);
|
|
1538
1545
|
}, [v, y.data]);
|
|
1539
|
-
const
|
|
1540
|
-
mutationFn: async (
|
|
1541
|
-
var
|
|
1542
|
-
const L =
|
|
1546
|
+
const $ = Da({
|
|
1547
|
+
mutationFn: async (k) => {
|
|
1548
|
+
var B, D;
|
|
1549
|
+
const L = Ci(l ?? e, n, k), I = performance.now(), z = new Request(L, {
|
|
1543
1550
|
method: a.toUpperCase(),
|
|
1544
1551
|
headers: Object.fromEntries(
|
|
1545
|
-
|
|
1546
|
-
)
|
|
1552
|
+
k.headers.filter((_) => _.name).map((_) => [_.name, _.value])
|
|
1553
|
+
),
|
|
1554
|
+
body: k.body ? k.body : void 0
|
|
1547
1555
|
});
|
|
1548
|
-
|
|
1556
|
+
k.identity !== et && ((D = (B = y.data) == null ? void 0 : B.find((_) => _.id === k.identity)) == null || D.authorizeRequest(z));
|
|
1549
1557
|
try {
|
|
1550
1558
|
const _ = await fetch(z, {
|
|
1551
1559
|
signal: AbortSignal.timeout(5e3)
|
|
@@ -1563,47 +1571,47 @@ const kt = (e) => Math.abs(
|
|
|
1563
1571
|
) : _;
|
|
1564
1572
|
}
|
|
1565
1573
|
}
|
|
1566
|
-
}), S = n.split("/").map((
|
|
1574
|
+
}), S = n.split("/").map((k, L, I) => {
|
|
1567
1575
|
var he;
|
|
1568
|
-
const z =
|
|
1576
|
+
const z = k.startsWith("{") && k.endsWith("}") || k.startsWith(":"), B = k.replace(/[:{}]/g, ""), D = (he = b.pathParams.find((pe) => pe.name === B)) == null ? void 0 : he.value, _ = D ? /* @__PURE__ */ p.jsx(rn, { backgroundOpacity: "25%", name: k, slug: k, children: encodeURIComponent(D) }) : /* @__PURE__ */ p.jsx(
|
|
1569
1577
|
"span",
|
|
1570
1578
|
{
|
|
1571
1579
|
className: "underline decoration-wavy decoration-red-500",
|
|
1572
|
-
title: `Missing value for path parameter \`${
|
|
1573
|
-
children:
|
|
1580
|
+
title: `Missing value for path parameter \`${B}\``,
|
|
1581
|
+
children: k
|
|
1574
1582
|
}
|
|
1575
1583
|
);
|
|
1576
1584
|
return (
|
|
1577
1585
|
// eslint-disable-next-line react/no-array-index-key
|
|
1578
1586
|
/* @__PURE__ */ p.jsxs(Ze, { children: [
|
|
1579
|
-
z ? _ :
|
|
1587
|
+
z ? _ : k,
|
|
1580
1588
|
L < I.length - 1 && "/",
|
|
1581
1589
|
/* @__PURE__ */ p.jsx("wbr", {})
|
|
1582
|
-
] },
|
|
1590
|
+
] }, k + L)
|
|
1583
1591
|
);
|
|
1584
|
-
}), j = Array.from(((A =
|
|
1585
|
-
|
|
1592
|
+
}), j = Array.from(((A = $.data) == null ? void 0 : A.headers.entries()) ?? []), R = b.queryParams.filter((k) => k.active).map((k, L, I) => /* @__PURE__ */ p.jsxs(Ze, { children: [
|
|
1593
|
+
k.name,
|
|
1586
1594
|
"=",
|
|
1587
|
-
encodeURIComponent(
|
|
1595
|
+
encodeURIComponent(k.value).replaceAll("%20", "+"),
|
|
1588
1596
|
L < I.length - 1 && "&",
|
|
1589
1597
|
/* @__PURE__ */ p.jsx("wbr", {})
|
|
1590
|
-
] },
|
|
1591
|
-
|
|
1598
|
+
] }, k.name)), E = /* @__PURE__ */ p.jsx("div", { className: "inline-block opacity-50 hover:opacity-100 transition", children: t && t.length > 1 ? /* @__PURE__ */ p.jsxs(
|
|
1599
|
+
gn,
|
|
1592
1600
|
{
|
|
1593
|
-
onValueChange: (
|
|
1601
|
+
onValueChange: (k) => {
|
|
1594
1602
|
u(() => {
|
|
1595
|
-
c(
|
|
1603
|
+
c(k);
|
|
1596
1604
|
});
|
|
1597
1605
|
},
|
|
1598
1606
|
value: l,
|
|
1599
1607
|
children: [
|
|
1600
|
-
/* @__PURE__ */ p.jsx(
|
|
1601
|
-
/* @__PURE__ */ p.jsx(
|
|
1608
|
+
/* @__PURE__ */ p.jsx(bn, { className: "p-0 border-none flex-row-reverse bg-transparent text-xs gap-0.5 h-auto", children: /* @__PURE__ */ p.jsx(xn, {}) }),
|
|
1609
|
+
/* @__PURE__ */ p.jsx(kn, { children: t.map((k) => /* @__PURE__ */ p.jsx(gt, { value: k, children: k.replace(/^https?:\/\//, "") }, k)) })
|
|
1602
1610
|
]
|
|
1603
1611
|
}
|
|
1604
1612
|
) : /* @__PURE__ */ p.jsx("span", { children: e.replace(/^https?:\/\//, "") }) });
|
|
1605
1613
|
return /* @__PURE__ */ p.jsx(
|
|
1606
|
-
|
|
1614
|
+
Ja,
|
|
1607
1615
|
{
|
|
1608
1616
|
register: f,
|
|
1609
1617
|
control: d,
|
|
@@ -1611,7 +1619,7 @@ const kt = (e) => Math.abs(
|
|
|
1611
1619
|
watch: h,
|
|
1612
1620
|
setValue: v,
|
|
1613
1621
|
...g,
|
|
1614
|
-
children: /* @__PURE__ */ p.jsx("form", { onSubmit: m((
|
|
1622
|
+
children: /* @__PURE__ */ p.jsx("form", { onSubmit: m((k) => $.mutateAsync(k)), children: /* @__PURE__ */ p.jsxs("div", { className: "grid grid-cols-[8fr_7fr] text-sm h-full", children: [
|
|
1615
1623
|
/* @__PURE__ */ p.jsxs("div", { className: "flex flex-col gap-4 p-8 bg-muted/50 after:bg-muted-foreground/20 relative after:absolute after:w-px after:inset-0 after:left-auto", children: [
|
|
1616
1624
|
/* @__PURE__ */ p.jsxs("div", { className: "flex gap-2 items-stretch", children: [
|
|
1617
1625
|
/* @__PURE__ */ p.jsxs("div", { className: "flex flex-1 items-center w-full border rounded-md", children: [
|
|
@@ -1652,31 +1660,31 @@ const kt = (e) => Math.abs(
|
|
|
1652
1660
|
/* @__PURE__ */ p.jsxs("div", { className: "flex gap-2 items-center", children: [
|
|
1653
1661
|
"Auth:",
|
|
1654
1662
|
/* @__PURE__ */ p.jsxs(
|
|
1655
|
-
|
|
1663
|
+
gn,
|
|
1656
1664
|
{
|
|
1657
|
-
onValueChange: (
|
|
1665
|
+
onValueChange: (k) => v("identity", k),
|
|
1658
1666
|
value: b.identity,
|
|
1659
1667
|
defaultValue: b.identity,
|
|
1660
1668
|
children: [
|
|
1661
|
-
/* @__PURE__ */ p.jsx(
|
|
1662
|
-
/* @__PURE__ */ p.jsxs(
|
|
1669
|
+
/* @__PURE__ */ p.jsx(bn, { className: "w-[180px] flex", children: y.isPending ? /* @__PURE__ */ p.jsx(vn, {}) : /* @__PURE__ */ p.jsx(xn, {}) }),
|
|
1670
|
+
/* @__PURE__ */ p.jsxs(kn, { align: "center", children: [
|
|
1663
1671
|
/* @__PURE__ */ p.jsx(gt, { value: et, children: "None" }),
|
|
1664
|
-
(M = y.data) == null ? void 0 : M.map((
|
|
1672
|
+
(M = y.data) == null ? void 0 : M.map((k) => /* @__PURE__ */ p.jsx(gt, { value: k.id, children: k.label }, k.id))
|
|
1665
1673
|
] })
|
|
1666
1674
|
]
|
|
1667
1675
|
}
|
|
1668
1676
|
)
|
|
1669
1677
|
] })
|
|
1670
1678
|
] }),
|
|
1671
|
-
/* @__PURE__ */ p.jsx(Ce, { value: "headers", children: /* @__PURE__ */ p.jsx(
|
|
1679
|
+
/* @__PURE__ */ p.jsx(Ce, { value: "headers", children: /* @__PURE__ */ p.jsx(Pi, { control: d, register: f }) }),
|
|
1672
1680
|
/* @__PURE__ */ p.jsxs(Ce, { value: "parameters", children: [
|
|
1673
1681
|
r.length > 0 && /* @__PURE__ */ p.jsxs("div", { className: "flex flex-col gap-4 my-4", children: [
|
|
1674
1682
|
/* @__PURE__ */ p.jsx("span", { className: "font-semibold", children: "Path Parameters" }),
|
|
1675
|
-
/* @__PURE__ */ p.jsx(
|
|
1683
|
+
/* @__PURE__ */ p.jsx(Ei, { control: d })
|
|
1676
1684
|
] }),
|
|
1677
1685
|
i.length > 0 && /* @__PURE__ */ p.jsxs("div", { className: "flex flex-col gap-4 my-4", children: [
|
|
1678
1686
|
/* @__PURE__ */ p.jsx("span", { className: "font-semibold", children: "Query Parameters" }),
|
|
1679
|
-
/* @__PURE__ */ p.jsx(
|
|
1687
|
+
/* @__PURE__ */ p.jsx(qi, { control: d, queryParams: i })
|
|
1680
1688
|
] })
|
|
1681
1689
|
] }),
|
|
1682
1690
|
/* @__PURE__ */ p.jsx(Ce, { value: "body", children: /* @__PURE__ */ p.jsx(
|
|
@@ -1690,32 +1698,32 @@ const kt = (e) => Math.abs(
|
|
|
1690
1698
|
}
|
|
1691
1699
|
)
|
|
1692
1700
|
] }),
|
|
1693
|
-
/* @__PURE__ */ p.jsx("div", { className: "min-w-0 p-8 bg-muted/70", children:
|
|
1694
|
-
b.pathParams.some((
|
|
1701
|
+
/* @__PURE__ */ p.jsx("div", { className: "min-w-0 p-8 bg-muted/70", children: $.error ? /* @__PURE__ */ p.jsxs("div", { className: "flex flex-col gap-2", children: [
|
|
1702
|
+
b.pathParams.some((k) => k.value === "") && /* @__PURE__ */ p.jsx(Ea, { type: "caution", children: "Some path parameters are missing values. Please fill them in to ensure the request is sent correctly." }),
|
|
1695
1703
|
/* @__PURE__ */ p.jsxs(ot, { children: [
|
|
1696
1704
|
/* @__PURE__ */ p.jsx(Nr, { children: /* @__PURE__ */ p.jsx(Tr, { children: "Request failed" }) }),
|
|
1697
1705
|
/* @__PURE__ */ p.jsxs(Or, { children: [
|
|
1698
1706
|
"Error:",
|
|
1699
1707
|
" ",
|
|
1700
|
-
|
|
1708
|
+
$.error.message || String($.error) || "Unexpected error"
|
|
1701
1709
|
] })
|
|
1702
1710
|
] })
|
|
1703
|
-
] }) :
|
|
1711
|
+
] }) : $.data ? /* @__PURE__ */ p.jsxs("div", { className: "flex flex-col gap-2", children: [
|
|
1704
1712
|
/* @__PURE__ */ p.jsx("div", { className: "flex gap-2", children: /* @__PURE__ */ p.jsxs("div", { className: "flex text-xs gap-6", children: [
|
|
1705
1713
|
/* @__PURE__ */ p.jsxs("div", { children: [
|
|
1706
1714
|
"Status: ",
|
|
1707
|
-
|
|
1715
|
+
$.data.status,
|
|
1708
1716
|
" ",
|
|
1709
|
-
|
|
1717
|
+
Ui[$.data.status] ?? ""
|
|
1710
1718
|
] }),
|
|
1711
1719
|
/* @__PURE__ */ p.jsxs("div", { children: [
|
|
1712
1720
|
"Time: ",
|
|
1713
|
-
|
|
1721
|
+
$.data.time.toFixed(0),
|
|
1714
1722
|
"ms"
|
|
1715
1723
|
] }),
|
|
1716
1724
|
/* @__PURE__ */ p.jsxs("div", { children: [
|
|
1717
1725
|
"Size: ",
|
|
1718
|
-
|
|
1726
|
+
$.data.size,
|
|
1719
1727
|
" B"
|
|
1720
1728
|
] })
|
|
1721
1729
|
] }) }),
|
|
@@ -1725,10 +1733,10 @@ const kt = (e) => Math.abs(
|
|
|
1725
1733
|
/* @__PURE__ */ p.jsx(Oe, { value: "headers", children: j.length ? `Headers (${j.length})` : "No headers" })
|
|
1726
1734
|
] }),
|
|
1727
1735
|
/* @__PURE__ */ p.jsx(Ce, { value: "response", children: /* @__PURE__ */ p.jsx(
|
|
1728
|
-
|
|
1736
|
+
Li,
|
|
1729
1737
|
{
|
|
1730
|
-
headers:
|
|
1731
|
-
body:
|
|
1738
|
+
headers: $.data.headers,
|
|
1739
|
+
body: $.data.body
|
|
1732
1740
|
}
|
|
1733
1741
|
) }),
|
|
1734
1742
|
/* @__PURE__ */ p.jsx(Ce, { value: "headers", children: /* @__PURE__ */ p.jsxs(
|
|
@@ -1738,19 +1746,19 @@ const kt = (e) => Math.abs(
|
|
|
1738
1746
|
children: [
|
|
1739
1747
|
/* @__PURE__ */ p.jsx("div", { className: "font-semibold", children: "Key" }),
|
|
1740
1748
|
/* @__PURE__ */ p.jsx("div", { className: "font-semibold", children: "Value" }),
|
|
1741
|
-
j.map(([
|
|
1742
|
-
/* @__PURE__ */ p.jsx("div", { children:
|
|
1749
|
+
j.map(([k, L]) => /* @__PURE__ */ p.jsxs(Ze, { children: [
|
|
1750
|
+
/* @__PURE__ */ p.jsx("div", { children: k }),
|
|
1743
1751
|
/* @__PURE__ */ p.jsx("div", { className: "break-words", children: L })
|
|
1744
|
-
] },
|
|
1752
|
+
] }, k))
|
|
1745
1753
|
]
|
|
1746
1754
|
}
|
|
1747
1755
|
) })
|
|
1748
1756
|
] })
|
|
1749
|
-
] }) : /* @__PURE__ */ p.jsx("div", { className: "grid place-items-center h-full", children: /* @__PURE__ */ p.jsx("span", { className: "text-[16px] font-semibold text-muted-foreground", children:
|
|
1757
|
+
] }) : /* @__PURE__ */ p.jsx("div", { className: "grid place-items-center h-full", children: /* @__PURE__ */ p.jsx("span", { className: "text-[16px] font-semibold text-muted-foreground", children: $.isPending ? /* @__PURE__ */ p.jsx(vn, {}) : "Send a request first to see the response here" }) }) })
|
|
1750
1758
|
] }) })
|
|
1751
1759
|
}
|
|
1752
1760
|
);
|
|
1753
|
-
},
|
|
1761
|
+
}, Mi = ({
|
|
1754
1762
|
className: e,
|
|
1755
1763
|
size: t = 16
|
|
1756
1764
|
}) => /* @__PURE__ */ p.jsx(
|
|
@@ -1771,12 +1779,12 @@ const kt = (e) => Math.abs(
|
|
|
1771
1779
|
}
|
|
1772
1780
|
)
|
|
1773
1781
|
}
|
|
1774
|
-
),
|
|
1782
|
+
), Mr = (e) => {
|
|
1775
1783
|
const [t, n] = fr(!1);
|
|
1776
|
-
return /* @__PURE__ */ p.jsxs(
|
|
1777
|
-
/* @__PURE__ */ p.jsx(
|
|
1784
|
+
return /* @__PURE__ */ p.jsxs(bi, { onOpenChange: (a) => n(a), children: [
|
|
1785
|
+
/* @__PURE__ */ p.jsx(xi, { asChild: !0, children: e.children ?? /* @__PURE__ */ p.jsxs("button", { className: "flex gap-1 items-center px-2 py-1 rounded-md bg-primary/80 hover:bg-primary transition text-primary-foreground text-xs", children: [
|
|
1778
1786
|
"Test",
|
|
1779
|
-
/* @__PURE__ */ p.jsx(
|
|
1787
|
+
/* @__PURE__ */ p.jsx(Mi, { className: "", size: 14 })
|
|
1780
1788
|
] }) }),
|
|
1781
1789
|
/* @__PURE__ */ p.jsxs(
|
|
1782
1790
|
wr,
|
|
@@ -1784,8 +1792,8 @@ const kt = (e) => Math.abs(
|
|
|
1784
1792
|
className: "max-w-screen-xl w-full h-5/6 overflow-auto p-0",
|
|
1785
1793
|
"aria-describedby": void 0,
|
|
1786
1794
|
children: [
|
|
1787
|
-
/* @__PURE__ */ p.jsx(
|
|
1788
|
-
t && /* @__PURE__ */ p.jsx(
|
|
1795
|
+
/* @__PURE__ */ p.jsx(ja, { children: /* @__PURE__ */ p.jsx(jr, { children: "Playground" }) }),
|
|
1796
|
+
t && /* @__PURE__ */ p.jsx(Hi, { ...e })
|
|
1789
1797
|
]
|
|
1790
1798
|
}
|
|
1791
1799
|
)
|
|
@@ -1816,16 +1824,16 @@ var jn = (e, t) => {
|
|
|
1816
1824
|
this.postProcessors = [...this.postProcessors, n];
|
|
1817
1825
|
}, this.indentationCharacter = e || Nn, this.lineJoin = t ?? Tn;
|
|
1818
1826
|
}
|
|
1819
|
-
},
|
|
1827
|
+
}, Bi = function(e) {
|
|
1820
1828
|
return Object.prototype.toString.call(e) === "[object RegExp]";
|
|
1821
|
-
},
|
|
1829
|
+
}, Vi = function(e) {
|
|
1822
1830
|
var t = typeof e;
|
|
1823
1831
|
return e !== null && (t === "object" || t === "function");
|
|
1824
1832
|
}, an = {};
|
|
1825
1833
|
Object.defineProperty(an, "__esModule", { value: !0 });
|
|
1826
1834
|
an.default = (e) => Object.getOwnPropertySymbols(e).filter((t) => Object.prototype.propertyIsEnumerable.call(e, t));
|
|
1827
|
-
const
|
|
1828
|
-
var
|
|
1835
|
+
const zi = Bi, Di = Vi, Ji = an.default;
|
|
1836
|
+
var Wi = (e, t, n) => {
|
|
1829
1837
|
const a = [];
|
|
1830
1838
|
return function s(i, r, o) {
|
|
1831
1839
|
r = r || {}, r.indent = r.indent || " ", o = o || "";
|
|
@@ -1852,7 +1860,7 @@ var Ji = (e, t, n) => {
|
|
|
1852
1860
|
};
|
|
1853
1861
|
if (a.indexOf(i) !== -1)
|
|
1854
1862
|
return '"[Circular]"';
|
|
1855
|
-
if (i == null || typeof i == "number" || typeof i == "boolean" || typeof i == "function" || typeof i == "symbol" ||
|
|
1863
|
+
if (i == null || typeof i == "number" || typeof i == "boolean" || typeof i == "function" || typeof i == "symbol" || zi(i))
|
|
1856
1864
|
return String(i);
|
|
1857
1865
|
if (i instanceof Date)
|
|
1858
1866
|
return `new Date('${i.toISOString()}')`;
|
|
@@ -1867,8 +1875,8 @@ var Ji = (e, t, n) => {
|
|
|
1867
1875
|
}).join("") + l.pad + "]";
|
|
1868
1876
|
return a.pop(), c(u);
|
|
1869
1877
|
}
|
|
1870
|
-
if (
|
|
1871
|
-
let u = Object.keys(i).concat(
|
|
1878
|
+
if (Di(i)) {
|
|
1879
|
+
let u = Object.keys(i).concat(Ji(i));
|
|
1872
1880
|
if (r.filter && (u = u.filter((d) => r.filter(i, d))), u.length === 0)
|
|
1873
1881
|
return "{}";
|
|
1874
1882
|
a.push(i);
|
|
@@ -1883,13 +1891,13 @@ var Ji = (e, t, n) => {
|
|
|
1883
1891
|
` ? "\\n" : "\\r"), r.singleQuotes === !1 ? (i = i.replace(/"/g, '\\"'), `"${i}"`) : (i = i.replace(/\\?'/g, "\\'"), `'${i}'`);
|
|
1884
1892
|
}(e, t, n);
|
|
1885
1893
|
};
|
|
1886
|
-
const Y = /* @__PURE__ */
|
|
1894
|
+
const Y = /* @__PURE__ */ Wa(Wi);
|
|
1887
1895
|
function ze(e, t = {}) {
|
|
1888
1896
|
const { delimiter: n = '"', escapeChar: a = "\\", escapeNewlines: s = !0 } = t;
|
|
1889
1897
|
return [...e.toString()].map((r) => r === "\b" ? `${a}b` : r === " " ? `${a}t` : r === `
|
|
1890
1898
|
` ? s ? `${a}n` : r : r === "\f" ? `${a}f` : r === "\r" ? s ? `${a}r` : r : r === a ? a + a : r === n ? a + n : r < " " || r > "~" ? JSON.stringify(r).slice(1, -1) : r).join("");
|
|
1891
1899
|
}
|
|
1892
|
-
var
|
|
1900
|
+
var De = (e) => ze(e, { delimiter: "'" }), G = (e) => ze(e, { delimiter: '"' }), Gi = {
|
|
1893
1901
|
info: {
|
|
1894
1902
|
key: "libcurl",
|
|
1895
1903
|
title: "Libcurl",
|
|
@@ -1905,7 +1913,7 @@ var Je = (e) => ze(e, { delimiter: "'" }), G = (e) => ze(e, { delimiter: '"' }),
|
|
|
1905
1913
|
i(`headers = curl_slist_append(headers, "${c}: ${G(n[c])}");`);
|
|
1906
1914
|
}), i("curl_easy_setopt(hnd, CURLOPT_HTTPHEADER, headers);")), a.cookie && (r(), i(`curl_easy_setopt(hnd, CURLOPT_COOKIE, "${a.cookie}");`)), s.text && (r(), i(`curl_easy_setopt(hnd, CURLOPT_POSTFIELDS, ${JSON.stringify(s.text)});`)), r(), i("CURLcode ret = curl_easy_perform(hnd);"), o();
|
|
1907
1915
|
}
|
|
1908
|
-
},
|
|
1916
|
+
}, Qi = {
|
|
1909
1917
|
info: {
|
|
1910
1918
|
key: "c",
|
|
1911
1919
|
title: "C",
|
|
@@ -1913,19 +1921,19 @@ var Je = (e) => ze(e, { delimiter: "'" }), G = (e) => ze(e, { delimiter: '"' }),
|
|
|
1913
1921
|
cli: "c"
|
|
1914
1922
|
},
|
|
1915
1923
|
clientsById: {
|
|
1916
|
-
libcurl:
|
|
1924
|
+
libcurl: Gi
|
|
1917
1925
|
}
|
|
1918
1926
|
}, Z = (e, t) => Object.keys(e).find((n) => n.toLowerCase() === t.toLowerCase()), de = (e, t) => {
|
|
1919
1927
|
const n = Z(e, t);
|
|
1920
1928
|
if (n)
|
|
1921
1929
|
return e[n];
|
|
1922
|
-
}, ht = (e, t) => !!Z(e, t),
|
|
1930
|
+
}, ht = (e, t) => !!Z(e, t), Ki = (e) => ["application/json", "application/x-json", "text/json", "text/x-json", "+json"].some(
|
|
1923
1931
|
(t) => e.indexOf(t) > -1
|
|
1924
1932
|
), On = class {
|
|
1925
1933
|
constructor(e) {
|
|
1926
1934
|
this.name = "", this.toString = () => `:${this.name}`, this.name = e;
|
|
1927
1935
|
}
|
|
1928
|
-
},
|
|
1936
|
+
}, Yi = class {
|
|
1929
1937
|
constructor(e) {
|
|
1930
1938
|
this.path = "", this.toString = () => `(clojure.java.io/file "${this.path}")`, this.path = e;
|
|
1931
1939
|
}
|
|
@@ -1962,7 +1970,7 @@ ${n}`);
|
|
|
1962
1970
|
default:
|
|
1963
1971
|
return e.toString();
|
|
1964
1972
|
}
|
|
1965
|
-
},
|
|
1973
|
+
}, Xi = {
|
|
1966
1974
|
info: {
|
|
1967
1975
|
key: "clj_http",
|
|
1968
1976
|
title: "clj-http",
|
|
@@ -2004,7 +2012,7 @@ ${n}`);
|
|
|
2004
2012
|
if (n.params) {
|
|
2005
2013
|
c.multipart = n.params.map((f) => f.fileName && !f.value ? {
|
|
2006
2014
|
name: f.name,
|
|
2007
|
-
content: new
|
|
2015
|
+
content: new Yi(f.fileName)
|
|
2008
2016
|
} : {
|
|
2009
2017
|
name: f.name,
|
|
2010
2018
|
content: f.value
|
|
@@ -2033,16 +2041,16 @@ ${n}`);
|
|
|
2033
2041
|
}
|
|
2034
2042
|
return o();
|
|
2035
2043
|
}
|
|
2036
|
-
},
|
|
2044
|
+
}, Zi = {
|
|
2037
2045
|
info: {
|
|
2038
2046
|
key: "clojure",
|
|
2039
2047
|
title: "Clojure",
|
|
2040
2048
|
default: "clj_http"
|
|
2041
2049
|
},
|
|
2042
2050
|
clientsById: {
|
|
2043
|
-
clj_http:
|
|
2051
|
+
clj_http: Xi
|
|
2044
2052
|
}
|
|
2045
|
-
},
|
|
2053
|
+
}, eo = (e) => {
|
|
2046
2054
|
let t = de(e, "accept-encoding");
|
|
2047
2055
|
if (!t)
|
|
2048
2056
|
return [];
|
|
@@ -2059,7 +2067,7 @@ ${n}`);
|
|
|
2059
2067
|
}
|
|
2060
2068
|
});
|
|
2061
2069
|
}), a;
|
|
2062
|
-
},
|
|
2070
|
+
}, to = {
|
|
2063
2071
|
info: {
|
|
2064
2072
|
key: "httpclient",
|
|
2065
2073
|
title: "HttpClient",
|
|
@@ -2075,7 +2083,7 @@ ${n}`);
|
|
|
2075
2083
|
}, { push: r, join: o } = new O({ indent: i.indent });
|
|
2076
2084
|
r("using System.Net.Http.Headers;");
|
|
2077
2085
|
let l = "";
|
|
2078
|
-
const c = !!e.cookie, u =
|
|
2086
|
+
const c = !!e.cookie, u = eo(e);
|
|
2079
2087
|
(c || u.length) && (l = "clientHandler", r("var clientHandler = new HttpClientHandler"), r("{"), c && r("UseCookies = false,", 1), u.length && r(`AutomaticDecompression = ${u.join(" | ")},`, 1), r("};")), r(`var client = new HttpClient(${l});`), r("var request = new HttpRequestMessage"), r("{");
|
|
2080
2088
|
const f = ["GET", "POST", "PUT", "DELETE", "PATCH", "HEAD", "OPTIONS", "TRACE"];
|
|
2081
2089
|
n = n.toUpperCase(), n && f.includes(n) ? n = `HttpMethod.${n[0]}${n.substring(1).toLowerCase()}` : n = `new HttpMethod("${n}")`, r(`Method = ${n},`, 1), r(`RequestUri = new Uri("${a}"),`, 1);
|
|
@@ -2112,10 +2120,10 @@ ${n}`);
|
|
|
2112
2120
|
return r("};"), r("using (var response = await client.SendAsync(request))"), r("{"), r("response.EnsureSuccessStatusCode();", 1), r("var body = await response.Content.ReadAsStringAsync();", 1), r("Console.WriteLine(body);", 1), r("}"), o();
|
|
2113
2121
|
}
|
|
2114
2122
|
};
|
|
2115
|
-
function
|
|
2123
|
+
function no(e) {
|
|
2116
2124
|
return e[0].toUpperCase() + e.slice(1).toLowerCase();
|
|
2117
2125
|
}
|
|
2118
|
-
var
|
|
2126
|
+
var ro = {
|
|
2119
2127
|
info: {
|
|
2120
2128
|
key: "restsharp",
|
|
2121
2129
|
title: "RestSharp",
|
|
@@ -2165,11 +2173,11 @@ var to = {
|
|
|
2165
2173
|
if (!s.text) break;
|
|
2166
2174
|
r(`request.AddStringBody("${s.text}", "${s.mimeType}");`);
|
|
2167
2175
|
}
|
|
2168
|
-
return r(`var response = await client.${
|
|
2176
|
+
return r(`var response = await client.${no(e)}Async(request);
|
|
2169
2177
|
`), r(`Console.WriteLine("{0}", response.Content);
|
|
2170
2178
|
`), o();
|
|
2171
2179
|
}
|
|
2172
|
-
},
|
|
2180
|
+
}, ao = {
|
|
2173
2181
|
info: {
|
|
2174
2182
|
key: "csharp",
|
|
2175
2183
|
title: "C#",
|
|
@@ -2177,10 +2185,10 @@ var to = {
|
|
|
2177
2185
|
cli: "dotnet"
|
|
2178
2186
|
},
|
|
2179
2187
|
clientsById: {
|
|
2180
|
-
httpclient:
|
|
2181
|
-
restsharp:
|
|
2188
|
+
httpclient: to,
|
|
2189
|
+
restsharp: ro
|
|
2182
2190
|
}
|
|
2183
|
-
},
|
|
2191
|
+
}, io = {
|
|
2184
2192
|
info: {
|
|
2185
2193
|
key: "native",
|
|
2186
2194
|
title: "NewRequest",
|
|
@@ -2198,7 +2206,7 @@ var to = {
|
|
|
2198
2206
|
r(`req.Header.Add("${y}", "${G(n[y])}")`, m);
|
|
2199
2207
|
}), i()), r(`res, ${d} := ${b}.Do(req)`, m), h(), u && (i(), r("defer res.Body.Close()", m), r(`body, ${d} := io.ReadAll(res.Body)`, m), h()), i(), u && r("fmt.Println(string(body))", m), l && (i(), r("}")), o();
|
|
2200
2208
|
}
|
|
2201
|
-
},
|
|
2209
|
+
}, oo = {
|
|
2202
2210
|
info: {
|
|
2203
2211
|
key: "go",
|
|
2204
2212
|
title: "Go",
|
|
@@ -2206,10 +2214,10 @@ var to = {
|
|
|
2206
2214
|
cli: "go"
|
|
2207
2215
|
},
|
|
2208
2216
|
clientsById: {
|
|
2209
|
-
native:
|
|
2217
|
+
native: io
|
|
2210
2218
|
}
|
|
2211
2219
|
}, Pn = `\r
|
|
2212
|
-
`,
|
|
2220
|
+
`, so = {
|
|
2213
2221
|
info: {
|
|
2214
2222
|
key: "http1.1",
|
|
2215
2223
|
title: "HTTP/1.1",
|
|
@@ -2237,16 +2245,16 @@ var to = {
|
|
|
2237
2245
|
const m = u(), h = i.text || "";
|
|
2238
2246
|
return `${m}${Pn}${h}`;
|
|
2239
2247
|
}
|
|
2240
|
-
},
|
|
2248
|
+
}, lo = {
|
|
2241
2249
|
info: {
|
|
2242
2250
|
key: "http",
|
|
2243
2251
|
title: "HTTP",
|
|
2244
2252
|
default: "http1.1"
|
|
2245
2253
|
},
|
|
2246
2254
|
clientsById: {
|
|
2247
|
-
"http1.1":
|
|
2255
|
+
"http1.1": so
|
|
2248
2256
|
}
|
|
2249
|
-
},
|
|
2257
|
+
}, co = {
|
|
2250
2258
|
info: {
|
|
2251
2259
|
key: "asynchttp",
|
|
2252
2260
|
title: "AsyncHttp",
|
|
@@ -2263,7 +2271,7 @@ var to = {
|
|
|
2263
2271
|
o(`.setHeader("${c}", "${G(t[c])}")`, 1);
|
|
2264
2272
|
}), n.text && o(`.setBody(${JSON.stringify(n.text)})`, 1), o(".execute()", 1), o(".toCompletableFuture()", 1), o(".thenAccept(System.out::println)", 1), o(".join();", 1), r(), o("client.close();"), l();
|
|
2265
2273
|
}
|
|
2266
|
-
},
|
|
2274
|
+
}, uo = {
|
|
2267
2275
|
info: {
|
|
2268
2276
|
key: "nethttp",
|
|
2269
2277
|
title: "java.net.http",
|
|
@@ -2285,7 +2293,7 @@ var to = {
|
|
|
2285
2293
|
"HttpResponse<String> response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());"
|
|
2286
2294
|
), r("System.out.println(response.body());"), o();
|
|
2287
2295
|
}
|
|
2288
|
-
},
|
|
2296
|
+
}, po = {
|
|
2289
2297
|
info: {
|
|
2290
2298
|
key: "okhttp",
|
|
2291
2299
|
title: "OkHttp",
|
|
@@ -2302,7 +2310,7 @@ var to = {
|
|
|
2302
2310
|
r(`.addHeader("${f}", "${G(a[f])}")`, 1);
|
|
2303
2311
|
}), r(".build();", 1), o(), r("Response response = client.newCall(request).execute();"), l();
|
|
2304
2312
|
}
|
|
2305
|
-
},
|
|
2313
|
+
}, fo = {
|
|
2306
2314
|
info: {
|
|
2307
2315
|
key: "unirest",
|
|
2308
2316
|
title: "Unirest",
|
|
@@ -2319,19 +2327,19 @@ var to = {
|
|
|
2319
2327
|
o(`.header("${c}", "${G(t[c])}")`, 1);
|
|
2320
2328
|
}), n.text && o(`.body(${JSON.stringify(n.text)})`, 1), o(".asString();", 1), r();
|
|
2321
2329
|
}
|
|
2322
|
-
},
|
|
2330
|
+
}, mo = {
|
|
2323
2331
|
info: {
|
|
2324
2332
|
key: "java",
|
|
2325
2333
|
title: "Java",
|
|
2326
2334
|
default: "unirest"
|
|
2327
2335
|
},
|
|
2328
2336
|
clientsById: {
|
|
2329
|
-
asynchttp:
|
|
2330
|
-
nethttp:
|
|
2331
|
-
okhttp:
|
|
2332
|
-
unirest:
|
|
2337
|
+
asynchttp: co,
|
|
2338
|
+
nethttp: uo,
|
|
2339
|
+
okhttp: po,
|
|
2340
|
+
unirest: fo
|
|
2333
2341
|
}
|
|
2334
|
-
},
|
|
2342
|
+
}, ho = {
|
|
2335
2343
|
info: {
|
|
2336
2344
|
key: "axios",
|
|
2337
2345
|
title: "Axios",
|
|
@@ -2375,7 +2383,7 @@ var to = {
|
|
|
2375
2383
|
}).replace('"[form]"', "form");
|
|
2376
2384
|
return l(`const options = ${d};`), o(), l("axios"), l(".request(options)", 1), l(".then(function (response) {", 1), l("console.log(response.data);", 2), l("})", 1), l(".catch(function (error) {", 1), l("console.error(error);", 2), l("});", 1), c();
|
|
2377
2385
|
}
|
|
2378
|
-
},
|
|
2386
|
+
}, yo = {
|
|
2379
2387
|
info: {
|
|
2380
2388
|
key: "fetch",
|
|
2381
2389
|
title: "fetch",
|
|
@@ -2428,7 +2436,7 @@ var to = {
|
|
|
2428
2436
|
})};`
|
|
2429
2437
|
), r(), n.params && n.mimeType === "multipart/form-data" && (l("options.body = form;"), r()), l(`fetch('${a}', options)`), l(".then(response => response.json())", 1), l(".then(response => console.log(response))", 1), l(".catch(err => console.error(err));", 1), o();
|
|
2430
2438
|
}
|
|
2431
|
-
},
|
|
2439
|
+
}, vo = {
|
|
2432
2440
|
info: {
|
|
2433
2441
|
key: "jquery",
|
|
2434
2442
|
title: "jQuery",
|
|
@@ -2472,7 +2480,7 @@ var to = {
|
|
|
2472
2480
|
const u = Y(c, { indent: i.indent }).replace("'[form]'", "form");
|
|
2473
2481
|
return o(`const settings = ${u};`), r(), o("$.ajax(settings).done(function (response) {"), o("console.log(response);", 1), o("});"), l();
|
|
2474
2482
|
}
|
|
2475
|
-
},
|
|
2483
|
+
}, go = {
|
|
2476
2484
|
info: {
|
|
2477
2485
|
key: "xhr",
|
|
2478
2486
|
title: "XMLHttpRequest",
|
|
@@ -2510,22 +2518,22 @@ var to = {
|
|
|
2510
2518
|
o(`const data = ${e.text ? `'${e.text}'` : "null"};`), r();
|
|
2511
2519
|
}
|
|
2512
2520
|
return o("const xhr = new XMLHttpRequest();"), i.cors && o("xhr.withCredentials = true;"), r(), o("xhr.addEventListener('readystatechange', function () {"), o("if (this.readyState === this.DONE) {", 1), o("console.log(this.responseText);", 2), o("}", 1), o("});"), r(), o(`xhr.open('${n}', '${a}');`), Object.keys(t).forEach((u) => {
|
|
2513
|
-
o(`xhr.setRequestHeader('${u}', '${
|
|
2521
|
+
o(`xhr.setRequestHeader('${u}', '${De(t[u])}');`);
|
|
2514
2522
|
}), r(), o("xhr.send(data);"), l();
|
|
2515
2523
|
}
|
|
2516
|
-
},
|
|
2524
|
+
}, bo = {
|
|
2517
2525
|
info: {
|
|
2518
2526
|
key: "javascript",
|
|
2519
2527
|
title: "JavaScript",
|
|
2520
2528
|
default: "xhr"
|
|
2521
2529
|
},
|
|
2522
2530
|
clientsById: {
|
|
2523
|
-
xhr:
|
|
2524
|
-
axios:
|
|
2525
|
-
fetch:
|
|
2526
|
-
jquery:
|
|
2531
|
+
xhr: go,
|
|
2532
|
+
axios: ho,
|
|
2533
|
+
fetch: yo,
|
|
2534
|
+
jquery: vo
|
|
2527
2535
|
}
|
|
2528
|
-
},
|
|
2536
|
+
}, xo = {
|
|
2529
2537
|
info: {
|
|
2530
2538
|
key: "native",
|
|
2531
2539
|
title: "Native JSON",
|
|
@@ -2559,16 +2567,16 @@ var to = {
|
|
|
2559
2567
|
}
|
|
2560
2568
|
return typeof a > "u" || a === "" ? "No JSON body" : JSON.stringify(a, null, n.indent);
|
|
2561
2569
|
}
|
|
2562
|
-
},
|
|
2570
|
+
}, ko = {
|
|
2563
2571
|
info: {
|
|
2564
2572
|
key: "json",
|
|
2565
2573
|
title: "JSON",
|
|
2566
2574
|
default: "native"
|
|
2567
2575
|
},
|
|
2568
2576
|
clientsById: {
|
|
2569
|
-
native:
|
|
2577
|
+
native: xo
|
|
2570
2578
|
}
|
|
2571
|
-
},
|
|
2579
|
+
}, $o = {
|
|
2572
2580
|
info: {
|
|
2573
2581
|
key: "okhttp",
|
|
2574
2582
|
title: "OkHttp",
|
|
@@ -2585,16 +2593,16 @@ var to = {
|
|
|
2585
2593
|
l(`.addHeader("${f}", "${G(a[f])}")`, 1);
|
|
2586
2594
|
}), l(".build()", 1), r(), l("val response = client.newCall(request).execute()"), o();
|
|
2587
2595
|
}
|
|
2588
|
-
},
|
|
2596
|
+
}, So = {
|
|
2589
2597
|
info: {
|
|
2590
2598
|
key: "kotlin",
|
|
2591
2599
|
title: "Kotlin",
|
|
2592
2600
|
default: "okhttp"
|
|
2593
2601
|
},
|
|
2594
2602
|
clientsById: {
|
|
2595
|
-
okhttp:
|
|
2603
|
+
okhttp: $o
|
|
2596
2604
|
}
|
|
2597
|
-
},
|
|
2605
|
+
}, wo = {
|
|
2598
2606
|
info: {
|
|
2599
2607
|
key: "axios",
|
|
2600
2608
|
title: "Axios",
|
|
@@ -2628,7 +2636,7 @@ var to = {
|
|
|
2628
2636
|
const f = Y(u, { indent: " ", inlineCharacterLimit: 80 });
|
|
2629
2637
|
return l(`const options = ${f};`), r(), l("axios"), l(".request(options)", 1), l(".then(function (response) {", 1), l("console.log(response.data);", 2), l("})", 1), l(".catch(function (error) {", 1), l("console.error(error);", 2), l("});", 1), o();
|
|
2630
2638
|
}
|
|
2631
|
-
},
|
|
2639
|
+
}, jo = {
|
|
2632
2640
|
info: {
|
|
2633
2641
|
key: "fetch",
|
|
2634
2642
|
title: "Fetch",
|
|
@@ -2688,7 +2696,7 @@ var to = {
|
|
|
2688
2696
|
});
|
|
2689
2697
|
return c(`const options = ${h};`), l(), o && f("const fs = require('fs');"), n.params && n.mimeType === "multipart/form-data" && (c("options.body = formData;"), l()), c("fetch(url, options)"), c(".then(res => res.json())", 1), c(".then(json => console.log(json))", 1), c(".catch(err => console.error('error:' + err));", 1), u().replace(/'encodedParams'/, "encodedParams").replace(/"fs\.createReadStream\(\\"(.+)\\"\)"/, 'fs.createReadStream("$1")');
|
|
2690
2698
|
}
|
|
2691
|
-
},
|
|
2699
|
+
}, No = {
|
|
2692
2700
|
info: {
|
|
2693
2701
|
key: "native",
|
|
2694
2702
|
title: "HTTP",
|
|
@@ -2727,7 +2735,7 @@ var to = {
|
|
|
2727
2735
|
}
|
|
2728
2736
|
return l("req.end();"), o();
|
|
2729
2737
|
}
|
|
2730
|
-
},
|
|
2738
|
+
}, To = {
|
|
2731
2739
|
info: {
|
|
2732
2740
|
key: "request",
|
|
2733
2741
|
title: "Request",
|
|
@@ -2780,7 +2788,7 @@ var to = {
|
|
|
2780
2788
|
c(`jar.setCookie(request.cookie('${encodeURIComponent(v)}=${encodeURIComponent(g)}'), '${t}');`);
|
|
2781
2789
|
}), u(), m((v) => v.replace(/'JAR'/, "jar"))), l && d("const fs = require('fs');"), c(`const options = ${Y(h, { indent: " ", inlineCharacterLimit: 80 })};`), u(), c("request(options, function (error, response, body) {"), c("if (error) throw new Error(error);", 1), u(), c("console.log(body);", 1), c("});"), f();
|
|
2782
2790
|
}
|
|
2783
|
-
},
|
|
2791
|
+
}, Oo = {
|
|
2784
2792
|
info: {
|
|
2785
2793
|
key: "unirest",
|
|
2786
2794
|
title: "Unirest",
|
|
@@ -2821,7 +2829,7 @@ var to = {
|
|
|
2821
2829
|
}
|
|
2822
2830
|
return l && m("const fs = require('fs');"), d("req.end(function (res) {"), d("if (res.error) throw new Error(res.error);", 1), u(), d("console.log(res.body);", 1), d("});"), f();
|
|
2823
2831
|
}
|
|
2824
|
-
},
|
|
2832
|
+
}, Co = {
|
|
2825
2833
|
info: {
|
|
2826
2834
|
key: "node",
|
|
2827
2835
|
title: "Node.js",
|
|
@@ -2829,27 +2837,27 @@ var to = {
|
|
|
2829
2837
|
cli: "node %s"
|
|
2830
2838
|
},
|
|
2831
2839
|
clientsById: {
|
|
2832
|
-
native:
|
|
2833
|
-
request:
|
|
2834
|
-
unirest:
|
|
2835
|
-
axios:
|
|
2836
|
-
fetch:
|
|
2840
|
+
native: No,
|
|
2841
|
+
request: To,
|
|
2842
|
+
unirest: Oo,
|
|
2843
|
+
axios: wo,
|
|
2844
|
+
fetch: jo
|
|
2837
2845
|
}
|
|
2838
2846
|
}, wt = (e, t, n, a) => {
|
|
2839
|
-
const s = `${e} *${t} = `, i =
|
|
2847
|
+
const s = `${e} *${t} = `, i = Ht(n, a ? s.length : void 0);
|
|
2840
2848
|
return `${s}${i};`;
|
|
2841
|
-
},
|
|
2849
|
+
}, Ht = (e, t) => {
|
|
2842
2850
|
const n = t === void 0 ? ", " : `,
|
|
2843
2851
|
${" ".repeat(t)}`;
|
|
2844
2852
|
switch (Object.prototype.toString.call(e)) {
|
|
2845
2853
|
case "[object Number]":
|
|
2846
2854
|
return `@${e}`;
|
|
2847
2855
|
case "[object Array]":
|
|
2848
|
-
return `@[ ${e.map((s) =>
|
|
2856
|
+
return `@[ ${e.map((s) => Ht(s)).join(n)} ]`;
|
|
2849
2857
|
case "[object Object]": {
|
|
2850
2858
|
const a = [];
|
|
2851
2859
|
return Object.keys(e).forEach((s) => {
|
|
2852
|
-
a.push(`@"${s}": ${
|
|
2860
|
+
a.push(`@"${s}": ${Ht(e[s])}`);
|
|
2853
2861
|
}), `@{ ${a.join(n)} }`;
|
|
2854
2862
|
}
|
|
2855
2863
|
case "[object Boolean]":
|
|
@@ -2857,7 +2865,7 @@ var to = {
|
|
|
2857
2865
|
default:
|
|
2858
2866
|
return e == null ? "" : `@"${e.toString().replace(/"/g, '\\"')}"`;
|
|
2859
2867
|
}
|
|
2860
|
-
},
|
|
2868
|
+
}, Po = {
|
|
2861
2869
|
info: {
|
|
2862
2870
|
key: "nsurlsession",
|
|
2863
2871
|
title: "NSURLSession",
|
|
@@ -2914,16 +2922,16 @@ var to = {
|
|
|
2914
2922
|
2
|
|
2915
2923
|
), r(' NSLog(@"%@", httpResponse);', 2), r(" }", 1), r(" }];"), r("[dataTask resume];"), o();
|
|
2916
2924
|
}
|
|
2917
|
-
},
|
|
2925
|
+
}, Eo = {
|
|
2918
2926
|
info: {
|
|
2919
2927
|
key: "objc",
|
|
2920
2928
|
title: "Objective-C",
|
|
2921
2929
|
default: "nsurlsession"
|
|
2922
2930
|
},
|
|
2923
2931
|
clientsById: {
|
|
2924
|
-
nsurlsession:
|
|
2932
|
+
nsurlsession: Po
|
|
2925
2933
|
}
|
|
2926
|
-
},
|
|
2934
|
+
}, Ro = {
|
|
2927
2935
|
info: {
|
|
2928
2936
|
key: "cohttp",
|
|
2929
2937
|
title: "CoHTTP",
|
|
@@ -2949,14 +2957,14 @@ var to = {
|
|
|
2949
2957
|
const f = u.length ? "~headers " : "", d = n.text ? "~body " : "", m = r.includes(a.toLowerCase()) ? `\`${a.toUpperCase()}` : `(Code.method_of_string "${a}")`;
|
|
2950
2958
|
return o(`Client.call ${f}${d}${m} uri`), o(">>= fun (res, body_stream) ->"), o("(* Do stuff with the result *)", 1), c();
|
|
2951
2959
|
}
|
|
2952
|
-
},
|
|
2960
|
+
}, Ao = {
|
|
2953
2961
|
info: {
|
|
2954
2962
|
key: "ocaml",
|
|
2955
2963
|
title: "OCaml",
|
|
2956
2964
|
default: "cohttp"
|
|
2957
2965
|
},
|
|
2958
2966
|
clientsById: {
|
|
2959
|
-
cohttp:
|
|
2967
|
+
cohttp: Ro
|
|
2960
2968
|
}
|
|
2961
2969
|
}, q = (e, t, n) => {
|
|
2962
2970
|
switch (n = n || "", t = t || "", Object.prototype.toString.call(e)) {
|
|
@@ -3017,7 +3025,7 @@ ${n}]`;
|
|
|
3017
3025
|
"UNLOCK",
|
|
3018
3026
|
"UPDATE",
|
|
3019
3027
|
"VERSION_CONTROL"
|
|
3020
|
-
],
|
|
3028
|
+
], qo = {
|
|
3021
3029
|
info: {
|
|
3022
3030
|
key: "curl",
|
|
3023
3031
|
title: "cURL",
|
|
@@ -3089,13 +3097,13 @@ ${c}` });
|
|
|
3089
3097
|
y.forEach(({ value: j, name: R, escape: E }) => {
|
|
3090
3098
|
j != null && x.push(`${R} => ${E ? JSON.stringify(j) : j},`);
|
|
3091
3099
|
});
|
|
3092
|
-
const
|
|
3093
|
-
|
|
3100
|
+
const $ = i.map((j) => `${encodeURIComponent(j.name)}=${encodeURIComponent(j.value)}`);
|
|
3101
|
+
$.length && x.push(`CURLOPT_COOKIE => "${$.join("; ")}",`);
|
|
3094
3102
|
const S = Object.keys(r).sort().map((j) => `"${j}: ${G(r[j])}"`);
|
|
3095
3103
|
return S.length && (x.push("CURLOPT_HTTPHEADER => ["), x.push(S.join(`,
|
|
3096
3104
|
${c}${c}`), 1), x.push("],")), v(x.join(), 1), v("]);"), g(), v("$response = curl_exec($curl);"), v("$err = curl_error($curl);"), g(), v("curl_close($curl);"), g(), v("if ($err) {"), v(f ? 'echo array_flip(get_defined_constants(true)["curl"])[$err];' : 'echo "cURL Error #:" . $err;', 1), v("} else {"), v("echo $response;", 1), v("}"), !d && l && (g(), v("?>")), b();
|
|
3097
3105
|
}
|
|
3098
|
-
},
|
|
3106
|
+
}, Fo = {
|
|
3099
3107
|
info: {
|
|
3100
3108
|
key: "guzzle",
|
|
3101
3109
|
title: "Guzzle",
|
|
@@ -3141,12 +3149,12 @@ ${c}${c}`), 1), x.push("],")), v(x.join(), 1), v("]);"), g(), v("$response = cur
|
|
|
3141
3149
|
e.text && f(`'body' => ${q(e.text)},`, 1);
|
|
3142
3150
|
}
|
|
3143
3151
|
const m = Object.keys(s).sort().map(function(g) {
|
|
3144
|
-
return `${r.indent}${r.indent}'${g}' => '${
|
|
3152
|
+
return `${r.indent}${r.indent}'${g}' => '${De(s[g])}',`;
|
|
3145
3153
|
}), h = a.map((g) => `${encodeURIComponent(g.name)}=${encodeURIComponent(g.value)}`).join("; ");
|
|
3146
|
-
return h.length && m.push(`${r.indent}${r.indent}'cookie' => '${
|
|
3154
|
+
return h.length && m.push(`${r.indent}${r.indent}'cookie' => '${De(h)}',`), m.length && (f("'headers' => [", 1), f(m.join(`
|
|
3147
3155
|
`)), f("],", 1)), o("$client = new \\GuzzleHttp\\Client();"), l(), u.length ? (o(`$response = $client->request('${n}', '${t}', [`), o(d()), o("]);")) : o(`$response = $client->request('${n}', '${t}');`), l(), o("echo $response->getBody();"), !r.noTags && r.closingTag && (l(), o("?>")), c();
|
|
3148
3156
|
}
|
|
3149
|
-
},
|
|
3157
|
+
}, Io = {
|
|
3150
3158
|
info: {
|
|
3151
3159
|
key: "http1",
|
|
3152
3160
|
title: "HTTP v1",
|
|
@@ -3168,7 +3176,7 @@ ${c}${c}`), 1), x.push("],")), v(x.join(), 1), v("]);"), g(), v("$response = cur
|
|
|
3168
3176
|
}
|
|
3169
3177
|
return f("try {"), f("$response = $request->send();", 1), d(), f("echo $response->getBody();", 1), f("} catch (HttpException $ex) {"), f("echo $ex;", 1), f("}"), !c && o && (d(), f("?>")), m();
|
|
3170
3178
|
}
|
|
3171
|
-
},
|
|
3179
|
+
}, _o = {
|
|
3172
3180
|
info: {
|
|
3173
3181
|
key: "http2",
|
|
3174
3182
|
title: "HTTP v2",
|
|
@@ -3188,22 +3196,22 @@ ${c}${c}`), 1), x.push("],")), v(x.join(), 1), v("]);"), g(), v("$response = cur
|
|
|
3188
3196
|
if (!e.params)
|
|
3189
3197
|
break;
|
|
3190
3198
|
const g = [], b = {};
|
|
3191
|
-
e.params.forEach(({ name:
|
|
3199
|
+
e.params.forEach(({ name: $, fileName: S, value: j, contentType: R }) => {
|
|
3192
3200
|
if (S) {
|
|
3193
3201
|
g.push({
|
|
3194
|
-
name:
|
|
3202
|
+
name: $,
|
|
3195
3203
|
type: R,
|
|
3196
3204
|
file: S,
|
|
3197
3205
|
data: j
|
|
3198
3206
|
});
|
|
3199
3207
|
return;
|
|
3200
3208
|
}
|
|
3201
|
-
j && (b[
|
|
3209
|
+
j && (b[$] = j);
|
|
3202
3210
|
});
|
|
3203
3211
|
const y = Object.keys(b).length ? q(b, l) : "null", x = g.length ? q(g, l) : "null";
|
|
3204
3212
|
if (f("$body = new http\\Message\\Body;"), f(`$body->addForm(${y}, ${x});`), ht(t, "content-type") && (v = de(t, "content-type")) != null && v.indexOf("boundary")) {
|
|
3205
|
-
const
|
|
3206
|
-
|
|
3213
|
+
const $ = Z(t, "content-type");
|
|
3214
|
+
$ && delete t[$];
|
|
3207
3215
|
}
|
|
3208
3216
|
d(), h = !0;
|
|
3209
3217
|
break;
|
|
@@ -3216,7 +3224,7 @@ ${c}${c}`), 1), x.push("],")), v(x.join(), 1), v("]);"), g(), v("$response = cur
|
|
|
3216
3224
|
}
|
|
3217
3225
|
return f(`$request->setRequestUrl(${q(i)});`), f(`$request->setRequestMethod(${q(n)});`), h && (f("$request->setBody($body);"), d()), Object.keys(a).length && (f(`$request->setQuery(new http\\QueryString(${q(a, l)}));`), d()), Object.keys(t).length && (f(`$request->setHeaders(${q(t, l)});`), d()), Object.keys(s).length && (d(), f(`$client->setCookies(${q(s, l)});`), d()), f("$client->enqueue($request)->send();"), f("$response = $client->getResponse();"), d(), f("echo $response->getBody();"), !c && o && (d(), f("?>")), m();
|
|
3218
3226
|
}
|
|
3219
|
-
},
|
|
3227
|
+
}, Lo = {
|
|
3220
3228
|
info: {
|
|
3221
3229
|
key: "php",
|
|
3222
3230
|
title: "PHP",
|
|
@@ -3224,10 +3232,10 @@ ${c}${c}`), 1), x.push("],")), v(x.join(), 1), v("]);"), g(), v("$response = cur
|
|
|
3224
3232
|
cli: "php %s"
|
|
3225
3233
|
},
|
|
3226
3234
|
clientsById: {
|
|
3227
|
-
curl:
|
|
3228
|
-
guzzle:
|
|
3229
|
-
http1:
|
|
3230
|
-
http2:
|
|
3235
|
+
curl: qo,
|
|
3236
|
+
guzzle: Fo,
|
|
3237
|
+
http1: Io,
|
|
3238
|
+
http2: _o
|
|
3231
3239
|
}
|
|
3232
3240
|
}, zr = (e) => ({ method: n, headersObj: a, cookies: s, uriObj: i, fullUrl: r, postData: o, allHeaders: l }) => {
|
|
3233
3241
|
const { push: c, join: u } = new O();
|
|
@@ -3241,7 +3249,7 @@ ${c}${c}`), 1), x.push("],")), v(x.join(), 1), v("]);"), g(), v("$response = cur
|
|
|
3241
3249
|
}), d.push("-WebSession $session")), o.text && (d.push(
|
|
3242
3250
|
`-ContentType '${ze(de(l, "content-type"), { delimiter: "'", escapeChar: "`" })}'`
|
|
3243
3251
|
), d.push(`-Body '${o.text}'`)), c(`$response = ${e} -Uri '${r}' -Method ${n} ${d.join(" ")}`.trim()), u();
|
|
3244
|
-
},
|
|
3252
|
+
}, Uo = {
|
|
3245
3253
|
info: {
|
|
3246
3254
|
key: "restmethod",
|
|
3247
3255
|
title: "Invoke-RestMethod",
|
|
@@ -3250,7 +3258,7 @@ ${c}${c}`), 1), x.push("],")), v(x.join(), 1), v("]);"), g(), v("$response = cur
|
|
|
3250
3258
|
extname: ".ps1"
|
|
3251
3259
|
},
|
|
3252
3260
|
convert: zr("Invoke-RestMethod")
|
|
3253
|
-
},
|
|
3261
|
+
}, Ho = {
|
|
3254
3262
|
info: {
|
|
3255
3263
|
key: "webrequest",
|
|
3256
3264
|
title: "Invoke-WebRequest",
|
|
@@ -3259,15 +3267,15 @@ ${c}${c}`), 1), x.push("],")), v(x.join(), 1), v("]);"), g(), v("$response = cur
|
|
|
3259
3267
|
extname: ".ps1"
|
|
3260
3268
|
},
|
|
3261
3269
|
convert: zr("Invoke-WebRequest")
|
|
3262
|
-
},
|
|
3270
|
+
}, Mo = {
|
|
3263
3271
|
info: {
|
|
3264
3272
|
key: "powershell",
|
|
3265
3273
|
title: "Powershell",
|
|
3266
3274
|
default: "webrequest"
|
|
3267
3275
|
},
|
|
3268
3276
|
clientsById: {
|
|
3269
|
-
webrequest:
|
|
3270
|
-
restmethod:
|
|
3277
|
+
webrequest: Ho,
|
|
3278
|
+
restmethod: Uo
|
|
3271
3279
|
}
|
|
3272
3280
|
};
|
|
3273
3281
|
function Rn(e, t, n, a, s) {
|
|
@@ -3299,7 +3307,7 @@ var Ee = (e, t, n) => {
|
|
|
3299
3307
|
default:
|
|
3300
3308
|
return e == null ? "" : `"${e.toString().replace(/"/g, '\\"')}"`;
|
|
3301
3309
|
}
|
|
3302
|
-
},
|
|
3310
|
+
}, Bo = ["HEAD", "GET", "POST", "PUT", "PATCH", "DELETE", "OPTIONS"], Vo = {
|
|
3303
3311
|
info: {
|
|
3304
3312
|
key: "requests",
|
|
3305
3313
|
title: "Requests",
|
|
@@ -3362,10 +3370,10 @@ var Ee = (e, t, n) => {
|
|
|
3362
3370
|
r(y !== g ? `"${x}": "${G(u[x])}",` : `"${x}": "${G(u[x])}"`, 1), y += 1;
|
|
3363
3371
|
}), r("}"), o();
|
|
3364
3372
|
}
|
|
3365
|
-
let b =
|
|
3373
|
+
let b = Bo.includes(a) ? `response = requests.${a.toLowerCase()}(url` : `response = requests.request("${a}", url`;
|
|
3366
3374
|
return h && (v ? b += ", json=payload" : b += ", data=payload"), m && (b += ", files=files"), g > 0 && (b += ", headers=headers"), b += ")", r(b), o(), r("print(response.text)"), l();
|
|
3367
3375
|
}
|
|
3368
|
-
},
|
|
3376
|
+
}, zo = {
|
|
3369
3377
|
info: {
|
|
3370
3378
|
key: "python",
|
|
3371
3379
|
title: "Python",
|
|
@@ -3373,9 +3381,9 @@ var Ee = (e, t, n) => {
|
|
|
3373
3381
|
cli: "python3 %s"
|
|
3374
3382
|
},
|
|
3375
3383
|
clientsById: {
|
|
3376
|
-
requests:
|
|
3384
|
+
requests: Vo
|
|
3377
3385
|
}
|
|
3378
|
-
},
|
|
3386
|
+
}, Do = {
|
|
3379
3387
|
info: {
|
|
3380
3388
|
key: "httr",
|
|
3381
3389
|
title: "httr",
|
|
@@ -3408,22 +3416,22 @@ var Ee = (e, t, n) => {
|
|
|
3408
3416
|
r('encode <- "raw"'), o();
|
|
3409
3417
|
break;
|
|
3410
3418
|
}
|
|
3411
|
-
const d = de(s, "cookie"), m = de(s, "accept"), h = d ? `set_cookies(\`${String(d).replace(/;/g, '", `').replace(/` /g, "`").replace(/[=]/g, '` = "')}")` : void 0, v = m ? `accept("${G(m)}")` : void 0, g = `content_type("${G(a.mimeType)}")`, b = Object.entries(s).filter(([S]) => !["cookie", "accept", "content-type"].includes(S.toLowerCase())).map(([S, j]) => `'${S}' = '${
|
|
3419
|
+
const d = de(s, "cookie"), m = de(s, "accept"), h = d ? `set_cookies(\`${String(d).replace(/;/g, '", `').replace(/` /g, "`").replace(/[=]/g, '` = "')}")` : void 0, v = m ? `accept("${G(m)}")` : void 0, g = `content_type("${G(a.mimeType)}")`, b = Object.entries(s).filter(([S]) => !["cookie", "accept", "content-type"].includes(S.toLowerCase())).map(([S, j]) => `'${S}' = '${De(j)}'`).join(", "), y = b ? `add_headers(${b})` : void 0;
|
|
3412
3420
|
let x = `response <- VERB("${i}", url`;
|
|
3413
3421
|
f && (x += ", body = payload"), n.length && (x += ", query = queryString");
|
|
3414
|
-
const
|
|
3415
|
-
return
|
|
3422
|
+
const $ = [y, g, v, h].filter((S) => !!S).join(", ");
|
|
3423
|
+
return $ && (x += `, ${$}`), (a.text || a.jsonObj || a.params) && (x += ", encode = encode"), x += ")", r(x), o(), r('content(response, "text")'), l();
|
|
3416
3424
|
}
|
|
3417
|
-
},
|
|
3425
|
+
}, Jo = {
|
|
3418
3426
|
info: {
|
|
3419
3427
|
key: "r",
|
|
3420
3428
|
title: "R",
|
|
3421
3429
|
default: "httr"
|
|
3422
3430
|
},
|
|
3423
3431
|
clientsById: {
|
|
3424
|
-
httr:
|
|
3432
|
+
httr: Do
|
|
3425
3433
|
}
|
|
3426
|
-
},
|
|
3434
|
+
}, Wo = {
|
|
3427
3435
|
info: {
|
|
3428
3436
|
key: "native",
|
|
3429
3437
|
title: "net::http",
|
|
@@ -3451,19 +3459,19 @@ var Ee = (e, t, n) => {
|
|
|
3451
3459
|
c.includes(l) || (i(`class Net::HTTP::${u} < Net::HTTPRequest`), i(` METHOD = '${l.toUpperCase()}'`), i(` REQUEST_HAS_BODY = '${a.text ? "true" : "false"}'`), i(" RESPONSE_HAS_BODY = true"), i("end"), r()), i(`url = URI("${n}")`), r(), i("http = Net::HTTP.new(url.host, url.port)"), e.protocol === "https:" && i("http.use_ssl = true"), r(), i(`request = Net::HTTP::${u}.new(url)`);
|
|
3452
3460
|
const f = Object.keys(s);
|
|
3453
3461
|
return f.length && f.forEach((d) => {
|
|
3454
|
-
i(`request["${d}"] = '${
|
|
3462
|
+
i(`request["${d}"] = '${De(s[d])}'`);
|
|
3455
3463
|
}), a.text && i(`request.body = ${JSON.stringify(a.text)}`), r(), i("response = http.request(request)"), i("puts response.read_body"), o();
|
|
3456
3464
|
}
|
|
3457
|
-
},
|
|
3465
|
+
}, Go = {
|
|
3458
3466
|
info: {
|
|
3459
3467
|
key: "ruby",
|
|
3460
3468
|
title: "Ruby",
|
|
3461
3469
|
default: "native"
|
|
3462
3470
|
},
|
|
3463
3471
|
clientsById: {
|
|
3464
|
-
native:
|
|
3472
|
+
native: Wo
|
|
3465
3473
|
}
|
|
3466
|
-
}, K = (e = "") => /^[a-z0-9-_/.@%^=:]+$/i.test(e) ? e : `'${e.replace(/'/g, "'\\''")}'`,
|
|
3474
|
+
}, K = (e = "") => /^[a-z0-9-_/.@%^=:]+$/i.test(e) ? e : `'${e.replace(/'/g, "'\\''")}'`, Qo = (e) => e.replace(/\r/g, "\\r").replace(/\n/g, "\\n"), Ko = {
|
|
3467
3475
|
"http1.0": "0",
|
|
3468
3476
|
"url ": "",
|
|
3469
3477
|
cookie: "b",
|
|
@@ -3473,13 +3481,13 @@ var Ee = (e, t, n) => {
|
|
|
3473
3481
|
header: "H",
|
|
3474
3482
|
insecure: "k",
|
|
3475
3483
|
request: "X"
|
|
3476
|
-
},
|
|
3484
|
+
}, Yo = (e) => (t) => {
|
|
3477
3485
|
if (e) {
|
|
3478
|
-
const n =
|
|
3486
|
+
const n = Ko[t];
|
|
3479
3487
|
return n ? `-${n}` : "";
|
|
3480
3488
|
}
|
|
3481
3489
|
return `--${t}`;
|
|
3482
|
-
},
|
|
3490
|
+
}, Xo = {
|
|
3483
3491
|
info: {
|
|
3484
3492
|
key: "curl",
|
|
3485
3493
|
title: "cURL",
|
|
@@ -3493,7 +3501,7 @@ var Ee = (e, t, n) => {
|
|
|
3493
3501
|
...typeof o == "string" ? { indent: o } : {},
|
|
3494
3502
|
join: o !== !1 ? ` \\
|
|
3495
3503
|
${o}` : " "
|
|
3496
|
-
}), h =
|
|
3504
|
+
}), h = Yo(l);
|
|
3497
3505
|
let v = K(e);
|
|
3498
3506
|
if (d(`curl ${h("request")} ${t}`), u && (v = unescape(v), d(h("globoff"))), d(`${h("url ")}${v}`), n === "HTTP/1.0" && d(h("http1.0")), de(s, "accept-encoding") && d("--compressed"), i.mimeType === "multipart/form-data") {
|
|
3499
3507
|
const b = Z(a, "content-type");
|
|
@@ -3517,7 +3525,7 @@ ${o}` : " "
|
|
|
3517
3525
|
break;
|
|
3518
3526
|
case "application/x-www-form-urlencoded":
|
|
3519
3527
|
i.params ? i.params.forEach((y) => {
|
|
3520
|
-
const x = y.name,
|
|
3528
|
+
const x = y.name, $ = encodeURIComponent(y.name), S = $ !== x, j = S ? $ : x, R = c ? "--data-binary" : S ? "--data-urlencode" : h("data");
|
|
3521
3529
|
d(`${R} ${K(`${j}=${y.value}`)}`);
|
|
3522
3530
|
}) : d(`${c ? "--data-binary" : h("data")} ${K(i.text)}`);
|
|
3523
3531
|
break;
|
|
@@ -3525,7 +3533,7 @@ ${o}` : " "
|
|
|
3525
3533
|
if (!i.text)
|
|
3526
3534
|
break;
|
|
3527
3535
|
let b = !1;
|
|
3528
|
-
if (
|
|
3536
|
+
if (Ki(i.mimeType) && i.text.length > 20)
|
|
3529
3537
|
try {
|
|
3530
3538
|
const y = JSON.parse(i.text);
|
|
3531
3539
|
b = !0, i.text.indexOf("'") > 0 ? d(
|
|
@@ -3547,7 +3555,7 @@ ${JSON.stringify(y, null, f)}
|
|
|
3547
3555
|
}
|
|
3548
3556
|
return m();
|
|
3549
3557
|
}
|
|
3550
|
-
},
|
|
3558
|
+
}, Zo = {
|
|
3551
3559
|
info: {
|
|
3552
3560
|
key: "httpie",
|
|
3553
3561
|
title: "HTTPie",
|
|
@@ -3596,7 +3604,7 @@ ${o.indent}` : " "
|
|
|
3596
3604
|
}
|
|
3597
3605
|
return c();
|
|
3598
3606
|
}
|
|
3599
|
-
},
|
|
3607
|
+
}, es = {
|
|
3600
3608
|
info: {
|
|
3601
3609
|
key: "wget",
|
|
3602
3610
|
title: "Wget",
|
|
@@ -3618,9 +3626,9 @@ ${i.indent}` : " "
|
|
|
3618
3626
|
return i.verbose ? r(`wget ${i.short ? "-v" : "--verbose"}`) : r(`wget ${i.short ? "-q" : "--quiet"}`), r(`--method ${K(e)}`), Object.keys(n).forEach((l) => {
|
|
3619
3627
|
const c = `${l}: ${n[l]}`;
|
|
3620
3628
|
r(`--header ${K(c)}`);
|
|
3621
|
-
}), t.text && r(`--body-data ${
|
|
3629
|
+
}), t.text && r(`--body-data ${Qo(K(t.text))}`), r(i.short ? "-O" : "--output-document"), r(`- ${K(a)}`), o();
|
|
3622
3630
|
}
|
|
3623
|
-
},
|
|
3631
|
+
}, ts = {
|
|
3624
3632
|
info: {
|
|
3625
3633
|
key: "shell",
|
|
3626
3634
|
title: "Shell",
|
|
@@ -3628,9 +3636,9 @@ ${i.indent}` : " "
|
|
|
3628
3636
|
cli: "%s"
|
|
3629
3637
|
},
|
|
3630
3638
|
clientsById: {
|
|
3631
|
-
curl:
|
|
3632
|
-
httpie:
|
|
3633
|
-
wget:
|
|
3639
|
+
curl: Xo,
|
|
3640
|
+
httpie: Zo,
|
|
3641
|
+
wget: es
|
|
3634
3642
|
}
|
|
3635
3643
|
}, An = (e, t) => t.repeat(e), qn = (e, t, n, a) => {
|
|
3636
3644
|
const s = An(a, n), i = An(a - 1, n), r = t ? `,
|
|
@@ -3665,7 +3673,7 @@ ${i}]` : `[${e.join(r)}]`;
|
|
|
3665
3673
|
default:
|
|
3666
3674
|
return e == null ? "nil" : `"${e.toString().replace(/"/g, '\\"')}"`;
|
|
3667
3675
|
}
|
|
3668
|
-
},
|
|
3676
|
+
}, ns = {
|
|
3669
3677
|
info: {
|
|
3670
3678
|
key: "urlsession",
|
|
3671
3679
|
title: "URLSession",
|
|
@@ -3716,47 +3724,47 @@ ${i}]` : `[${e.join(r)}]`;
|
|
|
3716
3724
|
}
|
|
3717
3725
|
}), o("]"), o("components.queryItems = components.queryItems.map { $0 + queryItems } ?? queryItems"), l(), o("var request = URLRequest(url: components.url!)")), o(`request.httpMethod = "${s}"`), o(`request.timeoutInterval = ${r.timeout}`), Object.keys(e).length && o(`request.allHTTPHeaderFields = ${st(e, r)}`), u && o("request.httpBody = postData"), l(), o("let (data, _) = try await URLSession.shared.data(for: request)"), o("print(String(decoding: data, as: UTF8.self))"), c();
|
|
3718
3726
|
}
|
|
3719
|
-
},
|
|
3727
|
+
}, rs = {
|
|
3720
3728
|
info: {
|
|
3721
3729
|
key: "swift",
|
|
3722
3730
|
title: "Swift",
|
|
3723
3731
|
default: "urlsession"
|
|
3724
3732
|
},
|
|
3725
3733
|
clientsById: {
|
|
3726
|
-
urlsession:
|
|
3727
|
-
}
|
|
3728
|
-
},
|
|
3729
|
-
c:
|
|
3730
|
-
clojure:
|
|
3731
|
-
csharp:
|
|
3732
|
-
go:
|
|
3733
|
-
http:
|
|
3734
|
-
java:
|
|
3735
|
-
javascript:
|
|
3736
|
-
json:
|
|
3737
|
-
kotlin:
|
|
3738
|
-
node:
|
|
3739
|
-
objc:
|
|
3740
|
-
ocaml:
|
|
3741
|
-
php:
|
|
3742
|
-
powershell:
|
|
3743
|
-
python:
|
|
3744
|
-
r:
|
|
3745
|
-
ruby:
|
|
3746
|
-
shell:
|
|
3747
|
-
swift:
|
|
3734
|
+
urlsession: ns
|
|
3735
|
+
}
|
|
3736
|
+
}, as = {
|
|
3737
|
+
c: Qi,
|
|
3738
|
+
clojure: Zi,
|
|
3739
|
+
csharp: ao,
|
|
3740
|
+
go: oo,
|
|
3741
|
+
http: lo,
|
|
3742
|
+
java: mo,
|
|
3743
|
+
javascript: bo,
|
|
3744
|
+
json: ko,
|
|
3745
|
+
kotlin: So,
|
|
3746
|
+
node: Co,
|
|
3747
|
+
objc: Eo,
|
|
3748
|
+
ocaml: Ao,
|
|
3749
|
+
php: Lo,
|
|
3750
|
+
powershell: Mo,
|
|
3751
|
+
python: zo,
|
|
3752
|
+
r: Jo,
|
|
3753
|
+
ruby: Go,
|
|
3754
|
+
shell: ts,
|
|
3755
|
+
swift: rs
|
|
3748
3756
|
}, lt = { exports: {} };
|
|
3749
3757
|
/*! https://mths.be/punycode v1.4.1 by @mathias */
|
|
3750
3758
|
lt.exports;
|
|
3751
3759
|
(function(e, t) {
|
|
3752
3760
|
(function(n) {
|
|
3753
|
-
var a = t && !t.nodeType && t, s = e && !e.nodeType && e, i = typeof
|
|
3761
|
+
var a = t && !t.nodeType && t, s = e && !e.nodeType && e, i = typeof He == "object" && He;
|
|
3754
3762
|
(i.global === i || i.window === i || i.self === i) && (n = i);
|
|
3755
3763
|
var r, o = 2147483647, l = 36, c = 1, u = 26, f = 38, d = 700, m = 72, h = 128, v = "-", g = /^xn--/, b = /[^\x20-\x7E]/, y = /[\x2E\u3002\uFF0E\uFF61]/g, x = {
|
|
3756
3764
|
overflow: "Overflow: input needs wider integers to process",
|
|
3757
3765
|
"not-basic": "Illegal input >= 0x80 (not a basic code point)",
|
|
3758
3766
|
"invalid-input": "Invalid input"
|
|
3759
|
-
},
|
|
3767
|
+
}, $ = l - c, S = Math.floor, j = String.fromCharCode, R;
|
|
3760
3768
|
function E(w) {
|
|
3761
3769
|
throw new RangeError(x[w]);
|
|
3762
3770
|
}
|
|
@@ -3768,12 +3776,12 @@ lt.exports;
|
|
|
3768
3776
|
function M(w, N) {
|
|
3769
3777
|
var C = w.split("@"), U = "";
|
|
3770
3778
|
C.length > 1 && (U = C[0] + "@", w = C[1]), w = w.replace(y, ".");
|
|
3771
|
-
var
|
|
3779
|
+
var V = w.split("."), te = A(V, N).join(".");
|
|
3772
3780
|
return U + te;
|
|
3773
3781
|
}
|
|
3774
|
-
function
|
|
3775
|
-
for (var N = [], C = 0, U = w.length,
|
|
3776
|
-
|
|
3782
|
+
function k(w) {
|
|
3783
|
+
for (var N = [], C = 0, U = w.length, V, te; C < U; )
|
|
3784
|
+
V = w.charCodeAt(C++), V >= 55296 && V <= 56319 && C < U ? (te = w.charCodeAt(C++), (te & 64512) == 56320 ? N.push(((V & 1023) << 10) + (te & 1023) + 65536) : (N.push(V), C--)) : N.push(V);
|
|
3777
3785
|
return N;
|
|
3778
3786
|
}
|
|
3779
3787
|
function L(w) {
|
|
@@ -3788,28 +3796,28 @@ lt.exports;
|
|
|
3788
3796
|
function z(w, N) {
|
|
3789
3797
|
return w + 22 + 75 * (w < 26) - ((N != 0) << 5);
|
|
3790
3798
|
}
|
|
3791
|
-
function
|
|
3799
|
+
function B(w, N, C) {
|
|
3792
3800
|
var U = 0;
|
|
3793
|
-
for (w = C ? S(w / d) : w >> 1, w += S(w / N); w >
|
|
3794
|
-
w = S(w /
|
|
3795
|
-
return S(U + (
|
|
3801
|
+
for (w = C ? S(w / d) : w >> 1, w += S(w / N); w > $ * u >> 1; U += l)
|
|
3802
|
+
w = S(w / $);
|
|
3803
|
+
return S(U + ($ + 1) * w / (w + f));
|
|
3796
3804
|
}
|
|
3797
|
-
function
|
|
3798
|
-
var N = [], C = w.length, U,
|
|
3805
|
+
function D(w) {
|
|
3806
|
+
var N = [], C = w.length, U, V = 0, te = h, Q = m, ne, ae, se, fe, X, re, ie, ye, xe;
|
|
3799
3807
|
for (ne = w.lastIndexOf(v), ne < 0 && (ne = 0), ae = 0; ae < ne; ++ae)
|
|
3800
3808
|
w.charCodeAt(ae) >= 128 && E("not-basic"), N.push(w.charCodeAt(ae));
|
|
3801
3809
|
for (se = ne > 0 ? ne + 1 : 0; se < C; ) {
|
|
3802
|
-
for (fe =
|
|
3810
|
+
for (fe = V, X = 1, re = l; se >= C && E("invalid-input"), ie = I(w.charCodeAt(se++)), (ie >= l || ie > S((o - V) / X)) && E("overflow"), V += ie * X, ye = re <= Q ? c : re >= Q + u ? u : re - Q, !(ie < ye); re += l)
|
|
3803
3811
|
xe = l - ye, X > S(o / xe) && E("overflow"), X *= xe;
|
|
3804
|
-
U = N.length + 1, Q =
|
|
3812
|
+
U = N.length + 1, Q = B(V - fe, U, fe == 0), S(V / U) > o - te && E("overflow"), te += S(V / U), V %= U, N.splice(V++, 0, te);
|
|
3805
3813
|
}
|
|
3806
3814
|
return L(N);
|
|
3807
3815
|
}
|
|
3808
3816
|
function _(w) {
|
|
3809
|
-
var N, C, U,
|
|
3810
|
-
for (w =
|
|
3817
|
+
var N, C, U, V, te, Q, ne, ae, se, fe, X, re = [], ie, ye, xe, yt;
|
|
3818
|
+
for (w = k(w), ie = w.length, N = h, C = 0, te = m, Q = 0; Q < ie; ++Q)
|
|
3811
3819
|
X = w[Q], X < 128 && re.push(j(X));
|
|
3812
|
-
for (U =
|
|
3820
|
+
for (U = V = re.length, V && re.push(v); U < ie; ) {
|
|
3813
3821
|
for (ne = o, Q = 0; Q < ie; ++Q)
|
|
3814
3822
|
X = w[Q], X >= N && X < ne && (ne = X);
|
|
3815
3823
|
for (ye = U + 1, ne - N > S((o - C) / ye) && E("overflow"), C += (ne - N) * ye, N = ne, Q = 0; Q < ie; ++Q)
|
|
@@ -3818,7 +3826,7 @@ lt.exports;
|
|
|
3818
3826
|
yt = ae - fe, xe = l - fe, re.push(
|
|
3819
3827
|
j(z(fe + yt % xe, 0))
|
|
3820
3828
|
), ae = S(yt / xe);
|
|
3821
|
-
re.push(j(z(ae, 0))), te =
|
|
3829
|
+
re.push(j(z(ae, 0))), te = B(C, ye, U == V), C = 0, ++U;
|
|
3822
3830
|
}
|
|
3823
3831
|
++C, ++N;
|
|
3824
3832
|
}
|
|
@@ -3826,7 +3834,7 @@ lt.exports;
|
|
|
3826
3834
|
}
|
|
3827
3835
|
function he(w) {
|
|
3828
3836
|
return M(w, function(N) {
|
|
3829
|
-
return g.test(N) ?
|
|
3837
|
+
return g.test(N) ? D(N.slice(4).toLowerCase()) : N;
|
|
3830
3838
|
});
|
|
3831
3839
|
}
|
|
3832
3840
|
function pe(w) {
|
|
@@ -3849,10 +3857,10 @@ lt.exports;
|
|
|
3849
3857
|
* @type Object
|
|
3850
3858
|
*/
|
|
3851
3859
|
ucs2: {
|
|
3852
|
-
decode:
|
|
3860
|
+
decode: k,
|
|
3853
3861
|
encode: L
|
|
3854
3862
|
},
|
|
3855
|
-
decode:
|
|
3863
|
+
decode: D,
|
|
3856
3864
|
encode: _,
|
|
3857
3865
|
toASCII: pe,
|
|
3858
3866
|
toUnicode: he
|
|
@@ -3864,9 +3872,9 @@ lt.exports;
|
|
|
3864
3872
|
r.hasOwnProperty(R) && (a[R] = r[R]);
|
|
3865
3873
|
else
|
|
3866
3874
|
n.punycode = r;
|
|
3867
|
-
})(
|
|
3875
|
+
})(He);
|
|
3868
3876
|
})(lt, lt.exports);
|
|
3869
|
-
var
|
|
3877
|
+
var is = lt.exports, os = Error, ss = EvalError, ls = RangeError, cs = ReferenceError, Dr = SyntaxError, Ge = TypeError, us = URIError, ds = function() {
|
|
3870
3878
|
if (typeof Symbol != "function" || typeof Object.getOwnPropertySymbols != "function")
|
|
3871
3879
|
return !1;
|
|
3872
3880
|
if (typeof Symbol.iterator == "symbol")
|
|
@@ -3889,32 +3897,32 @@ var rs = lt.exports, as = Error, is = EvalError, os = RangeError, ss = Reference
|
|
|
3889
3897
|
return !1;
|
|
3890
3898
|
}
|
|
3891
3899
|
return !0;
|
|
3892
|
-
}, In = typeof Symbol < "u" && Symbol,
|
|
3893
|
-
return typeof In != "function" || typeof Symbol != "function" || typeof In("foo") != "symbol" || typeof Symbol("bar") != "symbol" ? !1 :
|
|
3900
|
+
}, In = typeof Symbol < "u" && Symbol, ps = ds, fs = function() {
|
|
3901
|
+
return typeof In != "function" || typeof Symbol != "function" || typeof In("foo") != "symbol" || typeof Symbol("bar") != "symbol" ? !1 : ps();
|
|
3894
3902
|
}, jt = {
|
|
3895
3903
|
__proto__: null,
|
|
3896
3904
|
foo: {}
|
|
3897
|
-
},
|
|
3898
|
-
return { __proto__: jt }.foo === jt.foo && !(jt instanceof
|
|
3899
|
-
},
|
|
3905
|
+
}, ms = Object, hs = function() {
|
|
3906
|
+
return { __proto__: jt }.foo === jt.foo && !(jt instanceof ms);
|
|
3907
|
+
}, ys = "Function.prototype.bind called on incompatible ", vs = Object.prototype.toString, gs = Math.max, bs = "[object Function]", _n = function(t, n) {
|
|
3900
3908
|
for (var a = [], s = 0; s < t.length; s += 1)
|
|
3901
3909
|
a[s] = t[s];
|
|
3902
3910
|
for (var i = 0; i < n.length; i += 1)
|
|
3903
3911
|
a[i + t.length] = n[i];
|
|
3904
3912
|
return a;
|
|
3905
|
-
},
|
|
3913
|
+
}, xs = function(t, n) {
|
|
3906
3914
|
for (var a = [], s = n, i = 0; s < t.length; s += 1, i += 1)
|
|
3907
3915
|
a[i] = t[s];
|
|
3908
3916
|
return a;
|
|
3909
|
-
},
|
|
3917
|
+
}, ks = function(e, t) {
|
|
3910
3918
|
for (var n = "", a = 0; a < e.length; a += 1)
|
|
3911
3919
|
n += e[a], a + 1 < e.length && (n += t);
|
|
3912
3920
|
return n;
|
|
3913
|
-
},
|
|
3921
|
+
}, $s = function(t) {
|
|
3914
3922
|
var n = this;
|
|
3915
|
-
if (typeof n != "function" ||
|
|
3916
|
-
throw new TypeError(
|
|
3917
|
-
for (var a =
|
|
3923
|
+
if (typeof n != "function" || vs.apply(n) !== bs)
|
|
3924
|
+
throw new TypeError(ys + n);
|
|
3925
|
+
for (var a = xs(arguments, 1), s, i = function() {
|
|
3918
3926
|
if (this instanceof s) {
|
|
3919
3927
|
var u = n.apply(
|
|
3920
3928
|
this,
|
|
@@ -3926,17 +3934,17 @@ var rs = lt.exports, as = Error, is = EvalError, os = RangeError, ss = Reference
|
|
|
3926
3934
|
t,
|
|
3927
3935
|
_n(a, arguments)
|
|
3928
3936
|
);
|
|
3929
|
-
}, r =
|
|
3937
|
+
}, r = gs(0, n.length - a.length), o = [], l = 0; l < r; l++)
|
|
3930
3938
|
o[l] = "$" + l;
|
|
3931
|
-
if (s = Function("binder", "return function (" +
|
|
3939
|
+
if (s = Function("binder", "return function (" + ks(o, ",") + "){ return binder.apply(this,arguments); }")(i), n.prototype) {
|
|
3932
3940
|
var c = function() {
|
|
3933
3941
|
};
|
|
3934
3942
|
c.prototype = n.prototype, s.prototype = new c(), c.prototype = null;
|
|
3935
3943
|
}
|
|
3936
3944
|
return s;
|
|
3937
|
-
},
|
|
3945
|
+
}, Ss = $s, on = Function.prototype.bind || Ss, ws = Function.prototype.call, js = Object.prototype.hasOwnProperty, Ns = on, Ts = Ns.call(ws, js), T, Os = os, Cs = ss, Ps = ls, Es = cs, qe = Dr, Re = Ge, Rs = us, Jr = Function, Nt = function(e) {
|
|
3938
3946
|
try {
|
|
3939
|
-
return
|
|
3947
|
+
return Jr('"use strict"; return (' + e + ").constructor;")();
|
|
3940
3948
|
} catch {
|
|
3941
3949
|
}
|
|
3942
3950
|
}, Se = Object.getOwnPropertyDescriptor;
|
|
@@ -3948,7 +3956,7 @@ if (Se)
|
|
|
3948
3956
|
}
|
|
3949
3957
|
var Tt = function() {
|
|
3950
3958
|
throw new Re();
|
|
3951
|
-
},
|
|
3959
|
+
}, As = Se ? function() {
|
|
3952
3960
|
try {
|
|
3953
3961
|
return arguments.callee, Tt;
|
|
3954
3962
|
} catch {
|
|
@@ -3958,14 +3966,14 @@ var Tt = function() {
|
|
|
3958
3966
|
return Tt;
|
|
3959
3967
|
}
|
|
3960
3968
|
}
|
|
3961
|
-
}() : Tt, Ne =
|
|
3969
|
+
}() : Tt, Ne = fs(), qs = hs(), W = Object.getPrototypeOf || (qs ? function(e) {
|
|
3962
3970
|
return e.__proto__;
|
|
3963
|
-
} : null), Pe = {},
|
|
3971
|
+
} : null), Pe = {}, Fs = typeof Uint8Array > "u" || !W ? T : W(Uint8Array), we = {
|
|
3964
3972
|
__proto__: null,
|
|
3965
3973
|
"%AggregateError%": typeof AggregateError > "u" ? T : AggregateError,
|
|
3966
3974
|
"%Array%": Array,
|
|
3967
3975
|
"%ArrayBuffer%": typeof ArrayBuffer > "u" ? T : ArrayBuffer,
|
|
3968
|
-
"%ArrayIteratorPrototype%": Ne &&
|
|
3976
|
+
"%ArrayIteratorPrototype%": Ne && W ? W([][Symbol.iterator]()) : T,
|
|
3969
3977
|
"%AsyncFromSyncIteratorPrototype%": T,
|
|
3970
3978
|
"%AsyncFunction%": Pe,
|
|
3971
3979
|
"%AsyncGenerator%": Pe,
|
|
@@ -3982,24 +3990,24 @@ var Tt = function() {
|
|
|
3982
3990
|
"%decodeURIComponent%": decodeURIComponent,
|
|
3983
3991
|
"%encodeURI%": encodeURI,
|
|
3984
3992
|
"%encodeURIComponent%": encodeURIComponent,
|
|
3985
|
-
"%Error%":
|
|
3993
|
+
"%Error%": Os,
|
|
3986
3994
|
"%eval%": eval,
|
|
3987
3995
|
// eslint-disable-line no-eval
|
|
3988
|
-
"%EvalError%":
|
|
3996
|
+
"%EvalError%": Cs,
|
|
3989
3997
|
"%Float32Array%": typeof Float32Array > "u" ? T : Float32Array,
|
|
3990
3998
|
"%Float64Array%": typeof Float64Array > "u" ? T : Float64Array,
|
|
3991
3999
|
"%FinalizationRegistry%": typeof FinalizationRegistry > "u" ? T : FinalizationRegistry,
|
|
3992
|
-
"%Function%":
|
|
4000
|
+
"%Function%": Jr,
|
|
3993
4001
|
"%GeneratorFunction%": Pe,
|
|
3994
4002
|
"%Int8Array%": typeof Int8Array > "u" ? T : Int8Array,
|
|
3995
4003
|
"%Int16Array%": typeof Int16Array > "u" ? T : Int16Array,
|
|
3996
4004
|
"%Int32Array%": typeof Int32Array > "u" ? T : Int32Array,
|
|
3997
4005
|
"%isFinite%": isFinite,
|
|
3998
4006
|
"%isNaN%": isNaN,
|
|
3999
|
-
"%IteratorPrototype%": Ne &&
|
|
4007
|
+
"%IteratorPrototype%": Ne && W ? W(W([][Symbol.iterator]())) : T,
|
|
4000
4008
|
"%JSON%": typeof JSON == "object" ? JSON : T,
|
|
4001
4009
|
"%Map%": typeof Map > "u" ? T : Map,
|
|
4002
|
-
"%MapIteratorPrototype%": typeof Map > "u" || !Ne || !
|
|
4010
|
+
"%MapIteratorPrototype%": typeof Map > "u" || !Ne || !W ? T : W((/* @__PURE__ */ new Map())[Symbol.iterator]()),
|
|
4003
4011
|
"%Math%": Math,
|
|
4004
4012
|
"%Number%": Number,
|
|
4005
4013
|
"%Object%": Object,
|
|
@@ -4007,37 +4015,37 @@ var Tt = function() {
|
|
|
4007
4015
|
"%parseInt%": parseInt,
|
|
4008
4016
|
"%Promise%": typeof Promise > "u" ? T : Promise,
|
|
4009
4017
|
"%Proxy%": typeof Proxy > "u" ? T : Proxy,
|
|
4010
|
-
"%RangeError%":
|
|
4011
|
-
"%ReferenceError%":
|
|
4018
|
+
"%RangeError%": Ps,
|
|
4019
|
+
"%ReferenceError%": Es,
|
|
4012
4020
|
"%Reflect%": typeof Reflect > "u" ? T : Reflect,
|
|
4013
4021
|
"%RegExp%": RegExp,
|
|
4014
4022
|
"%Set%": typeof Set > "u" ? T : Set,
|
|
4015
|
-
"%SetIteratorPrototype%": typeof Set > "u" || !Ne || !
|
|
4023
|
+
"%SetIteratorPrototype%": typeof Set > "u" || !Ne || !W ? T : W((/* @__PURE__ */ new Set())[Symbol.iterator]()),
|
|
4016
4024
|
"%SharedArrayBuffer%": typeof SharedArrayBuffer > "u" ? T : SharedArrayBuffer,
|
|
4017
4025
|
"%String%": String,
|
|
4018
|
-
"%StringIteratorPrototype%": Ne &&
|
|
4026
|
+
"%StringIteratorPrototype%": Ne && W ? W(""[Symbol.iterator]()) : T,
|
|
4019
4027
|
"%Symbol%": Ne ? Symbol : T,
|
|
4020
4028
|
"%SyntaxError%": qe,
|
|
4021
|
-
"%ThrowTypeError%":
|
|
4022
|
-
"%TypedArray%":
|
|
4029
|
+
"%ThrowTypeError%": As,
|
|
4030
|
+
"%TypedArray%": Fs,
|
|
4023
4031
|
"%TypeError%": Re,
|
|
4024
4032
|
"%Uint8Array%": typeof Uint8Array > "u" ? T : Uint8Array,
|
|
4025
4033
|
"%Uint8ClampedArray%": typeof Uint8ClampedArray > "u" ? T : Uint8ClampedArray,
|
|
4026
4034
|
"%Uint16Array%": typeof Uint16Array > "u" ? T : Uint16Array,
|
|
4027
4035
|
"%Uint32Array%": typeof Uint32Array > "u" ? T : Uint32Array,
|
|
4028
|
-
"%URIError%":
|
|
4036
|
+
"%URIError%": Rs,
|
|
4029
4037
|
"%WeakMap%": typeof WeakMap > "u" ? T : WeakMap,
|
|
4030
4038
|
"%WeakRef%": typeof WeakRef > "u" ? T : WeakRef,
|
|
4031
4039
|
"%WeakSet%": typeof WeakSet > "u" ? T : WeakSet
|
|
4032
4040
|
};
|
|
4033
|
-
if (
|
|
4041
|
+
if (W)
|
|
4034
4042
|
try {
|
|
4035
4043
|
null.error;
|
|
4036
4044
|
} catch (e) {
|
|
4037
|
-
var
|
|
4038
|
-
we["%Error.prototype%"] =
|
|
4045
|
+
var Is = W(W(e));
|
|
4046
|
+
we["%Error.prototype%"] = Is;
|
|
4039
4047
|
}
|
|
4040
|
-
var
|
|
4048
|
+
var _s = function e(t) {
|
|
4041
4049
|
var n;
|
|
4042
4050
|
if (t === "%AsyncFunction%")
|
|
4043
4051
|
n = Nt("async function () {}");
|
|
@@ -4050,7 +4058,7 @@ var Fs = function e(t) {
|
|
|
4050
4058
|
a && (n = a.prototype);
|
|
4051
4059
|
} else if (t === "%AsyncIteratorPrototype%") {
|
|
4052
4060
|
var s = e("%AsyncGenerator%");
|
|
4053
|
-
s &&
|
|
4061
|
+
s && W && (n = W(s.prototype));
|
|
4054
4062
|
}
|
|
4055
4063
|
return we[t] = n, n;
|
|
4056
4064
|
}, Ln = {
|
|
@@ -4106,21 +4114,21 @@ var Fs = function e(t) {
|
|
|
4106
4114
|
"%URIErrorPrototype%": ["URIError", "prototype"],
|
|
4107
4115
|
"%WeakMapPrototype%": ["WeakMap", "prototype"],
|
|
4108
4116
|
"%WeakSetPrototype%": ["WeakSet", "prototype"]
|
|
4109
|
-
}, Qe = on, ct =
|
|
4117
|
+
}, Qe = on, ct = Ts, Ls = Qe.call(Function.call, Array.prototype.concat), Us = Qe.call(Function.apply, Array.prototype.splice), Un = Qe.call(Function.call, String.prototype.replace), ut = Qe.call(Function.call, String.prototype.slice), Hs = Qe.call(Function.call, RegExp.prototype.exec), Ms = /[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g, Bs = /\\(\\)?/g, Vs = function(t) {
|
|
4110
4118
|
var n = ut(t, 0, 1), a = ut(t, -1);
|
|
4111
4119
|
if (n === "%" && a !== "%")
|
|
4112
4120
|
throw new qe("invalid intrinsic syntax, expected closing `%`");
|
|
4113
4121
|
if (a === "%" && n !== "%")
|
|
4114
4122
|
throw new qe("invalid intrinsic syntax, expected opening `%`");
|
|
4115
4123
|
var s = [];
|
|
4116
|
-
return Un(t,
|
|
4117
|
-
s[s.length] = o ? Un(l,
|
|
4124
|
+
return Un(t, Ms, function(i, r, o, l) {
|
|
4125
|
+
s[s.length] = o ? Un(l, Bs, "$1") : r || i;
|
|
4118
4126
|
}), s;
|
|
4119
|
-
},
|
|
4127
|
+
}, zs = function(t, n) {
|
|
4120
4128
|
var a = t, s;
|
|
4121
4129
|
if (ct(Ln, a) && (s = Ln[a], a = "%" + s[0] + "%"), ct(we, a)) {
|
|
4122
4130
|
var i = we[a];
|
|
4123
|
-
if (i === Pe && (i =
|
|
4131
|
+
if (i === Pe && (i = _s(a)), typeof i > "u" && !n)
|
|
4124
4132
|
throw new Re("intrinsic " + t + " exists, but is not available. Please file an issue!");
|
|
4125
4133
|
return {
|
|
4126
4134
|
alias: s,
|
|
@@ -4134,10 +4142,10 @@ var Fs = function e(t) {
|
|
|
4134
4142
|
throw new Re("intrinsic name must be a non-empty string");
|
|
4135
4143
|
if (arguments.length > 1 && typeof n != "boolean")
|
|
4136
4144
|
throw new Re('"allowMissing" argument must be a boolean');
|
|
4137
|
-
if (
|
|
4145
|
+
if (Hs(/^%?[^%]*%?$/, t) === null)
|
|
4138
4146
|
throw new qe("`%` may not be present anywhere but at the beginning and end of the intrinsic name");
|
|
4139
|
-
var a =
|
|
4140
|
-
c && (s = c[0],
|
|
4147
|
+
var a = Vs(t), s = a.length > 0 ? a[0] : "", i = zs("%" + s + "%", n), r = i.name, o = i.value, l = !1, c = i.alias;
|
|
4148
|
+
c && (s = c[0], Us(a, Ls([0, 1], c)));
|
|
4141
4149
|
for (var u = 1, f = !0; u < a.length; u += 1) {
|
|
4142
4150
|
var d = a[u], m = ut(d, 0, 1), h = ut(d, -1);
|
|
4143
4151
|
if ((m === '"' || m === "'" || m === "`" || h === '"' || h === "'" || h === "`") && m !== h)
|
|
@@ -4159,10 +4167,10 @@ var Fs = function e(t) {
|
|
|
4159
4167
|
}
|
|
4160
4168
|
}
|
|
4161
4169
|
return o;
|
|
4162
|
-
},
|
|
4170
|
+
}, Wr = { exports: {} }, Ot, Hn;
|
|
4163
4171
|
function sn() {
|
|
4164
|
-
if (
|
|
4165
|
-
|
|
4172
|
+
if (Hn) return Ot;
|
|
4173
|
+
Hn = 1;
|
|
4166
4174
|
var e = _e, t = e("%Object.defineProperty%", !0) || !1;
|
|
4167
4175
|
if (t)
|
|
4168
4176
|
try {
|
|
@@ -4172,14 +4180,14 @@ function sn() {
|
|
|
4172
4180
|
}
|
|
4173
4181
|
return Ot = t, Ot;
|
|
4174
4182
|
}
|
|
4175
|
-
var
|
|
4183
|
+
var Ds = _e, nt = Ds("%Object.getOwnPropertyDescriptor%", !0);
|
|
4176
4184
|
if (nt)
|
|
4177
4185
|
try {
|
|
4178
4186
|
nt([], "length");
|
|
4179
4187
|
} catch {
|
|
4180
4188
|
nt = null;
|
|
4181
4189
|
}
|
|
4182
|
-
var Gr = nt,
|
|
4190
|
+
var Gr = nt, Mn = sn(), Js = Dr, Te = Ge, Bn = Gr, Ws = function(t, n, a) {
|
|
4183
4191
|
if (!t || typeof t != "object" && typeof t != "function")
|
|
4184
4192
|
throw new Te("`obj` must be an object or a function`");
|
|
4185
4193
|
if (typeof n != "string" && typeof n != "symbol")
|
|
@@ -4193,8 +4201,8 @@ var Gr = nt, Hn = sn(), zs = Jr, Te = Ge, Bn = Gr, Js = function(t, n, a) {
|
|
|
4193
4201
|
if (arguments.length > 6 && typeof arguments[6] != "boolean")
|
|
4194
4202
|
throw new Te("`loose`, if provided, must be a boolean");
|
|
4195
4203
|
var s = arguments.length > 3 ? arguments[3] : null, i = arguments.length > 4 ? arguments[4] : null, r = arguments.length > 5 ? arguments[5] : null, o = arguments.length > 6 ? arguments[6] : !1, l = !!Bn && Bn(t, n);
|
|
4196
|
-
if (
|
|
4197
|
-
|
|
4204
|
+
if (Mn)
|
|
4205
|
+
Mn(t, n, {
|
|
4198
4206
|
configurable: r === null && l ? l.configurable : !r,
|
|
4199
4207
|
enumerable: s === null && l ? l.enumerable : !s,
|
|
4200
4208
|
value: a,
|
|
@@ -4203,30 +4211,30 @@ var Gr = nt, Hn = sn(), zs = Jr, Te = Ge, Bn = Gr, Js = function(t, n, a) {
|
|
|
4203
4211
|
else if (o || !s && !i && !r)
|
|
4204
4212
|
t[n] = a;
|
|
4205
4213
|
else
|
|
4206
|
-
throw new
|
|
4207
|
-
},
|
|
4208
|
-
return !!
|
|
4214
|
+
throw new Js("This environment does not support defining a property as non-configurable, non-writable, or non-enumerable.");
|
|
4215
|
+
}, Mt = sn(), Qr = function() {
|
|
4216
|
+
return !!Mt;
|
|
4209
4217
|
};
|
|
4210
4218
|
Qr.hasArrayLengthDefineBug = function() {
|
|
4211
|
-
if (!
|
|
4219
|
+
if (!Mt)
|
|
4212
4220
|
return null;
|
|
4213
4221
|
try {
|
|
4214
|
-
return
|
|
4222
|
+
return Mt([], "length", { value: 1 }).length !== 1;
|
|
4215
4223
|
} catch {
|
|
4216
4224
|
return !0;
|
|
4217
4225
|
}
|
|
4218
4226
|
};
|
|
4219
|
-
var
|
|
4227
|
+
var Gs = Qr, Qs = _e, Vn = Ws, Ks = Gs(), zn = Gr, Dn = Ge, Ys = Qs("%Math.floor%"), Xs = function(t, n) {
|
|
4220
4228
|
if (typeof t != "function")
|
|
4221
|
-
throw new
|
|
4222
|
-
if (typeof n != "number" || n < 0 || n > 4294967295 ||
|
|
4223
|
-
throw new
|
|
4229
|
+
throw new Dn("`fn` is not a function");
|
|
4230
|
+
if (typeof n != "number" || n < 0 || n > 4294967295 || Ys(n) !== n)
|
|
4231
|
+
throw new Dn("`length` must be a positive 32-bit integer");
|
|
4224
4232
|
var a = arguments.length > 2 && !!arguments[2], s = !0, i = !0;
|
|
4225
4233
|
if ("length" in t && zn) {
|
|
4226
4234
|
var r = zn(t, "length");
|
|
4227
4235
|
r && !r.configurable && (s = !1), r && !r.writable && (i = !1);
|
|
4228
4236
|
}
|
|
4229
|
-
return (s || i || !a) && (
|
|
4237
|
+
return (s || i || !a) && (Ks ? Vn(
|
|
4230
4238
|
/** @type {Parameters<define>[0]} */
|
|
4231
4239
|
t,
|
|
4232
4240
|
"length",
|
|
@@ -4241,7 +4249,7 @@ var Ws = Qr, Ds = _e, Vn = Js, Gs = Ws(), zn = Gr, Jn = Ge, Qs = Ds("%Math.floor
|
|
|
4241
4249
|
)), t;
|
|
4242
4250
|
};
|
|
4243
4251
|
(function(e) {
|
|
4244
|
-
var t = on, n = _e, a =
|
|
4252
|
+
var t = on, n = _e, a = Xs, s = Ge, i = n("%Function.prototype.apply%"), r = n("%Function.prototype.call%"), o = n("%Reflect.apply%", !0) || t.call(r, i), l = sn(), c = n("%Math.max%");
|
|
4245
4253
|
e.exports = function(d) {
|
|
4246
4254
|
if (typeof d != "function")
|
|
4247
4255
|
throw new s("a function is required");
|
|
@@ -4256,13 +4264,16 @@ var Ws = Qr, Ds = _e, Vn = Js, Gs = Ws(), zn = Gr, Jn = Ge, Qs = Ds("%Math.floor
|
|
|
4256
4264
|
return o(t, i, arguments);
|
|
4257
4265
|
};
|
|
4258
4266
|
l ? l(e.exports, "apply", { value: u }) : e.exports.apply = u;
|
|
4259
|
-
})(
|
|
4260
|
-
var
|
|
4267
|
+
})(Wr);
|
|
4268
|
+
var Zs = Wr.exports, Kr = _e, Yr = Zs, el = Yr(Kr("String.prototype.indexOf")), tl = function(t, n) {
|
|
4261
4269
|
var a = Kr(t, !!n);
|
|
4262
|
-
return typeof a == "function" &&
|
|
4270
|
+
return typeof a == "function" && el(t, ".prototype.") > -1 ? Yr(a) : a;
|
|
4263
4271
|
};
|
|
4264
|
-
const
|
|
4265
|
-
|
|
4272
|
+
const nl = {}, rl = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
4273
|
+
__proto__: null,
|
|
4274
|
+
default: nl
|
|
4275
|
+
}, Symbol.toStringTag, { value: "Module" })), al = /* @__PURE__ */ Ga(rl);
|
|
4276
|
+
var ln = typeof Map == "function" && Map.prototype, Ct = Object.getOwnPropertyDescriptor && ln ? Object.getOwnPropertyDescriptor(Map.prototype, "size") : null, dt = ln && Ct && typeof Ct.get == "function" ? Ct.get : null, Jn = ln && Map.prototype.forEach, cn = typeof Set == "function" && Set.prototype, Pt = Object.getOwnPropertyDescriptor && cn ? Object.getOwnPropertyDescriptor(Set.prototype, "size") : null, pt = cn && Pt && typeof Pt.get == "function" ? Pt.get : null, Wn = cn && Set.prototype.forEach, il = typeof WeakMap == "function" && WeakMap.prototype, Me = il ? WeakMap.prototype.has : null, ol = typeof WeakSet == "function" && WeakSet.prototype, Be = ol ? WeakSet.prototype.has : null, sl = typeof WeakRef == "function" && WeakRef.prototype, Gn = sl ? WeakRef.prototype.deref : null, ll = Boolean.prototype.valueOf, cl = Object.prototype.toString, ul = Function.prototype.toString, dl = String.prototype.match, un = String.prototype.slice, ge = String.prototype.replace, pl = String.prototype.toUpperCase, Qn = String.prototype.toLowerCase, Xr = RegExp.prototype.test, Kn = Array.prototype.concat, ue = Array.prototype.join, fl = Array.prototype.slice, Yn = Math.floor, Bt = typeof BigInt == "function" ? BigInt.prototype.valueOf : null, Et = Object.getOwnPropertySymbols, Vt = typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? Symbol.prototype.toString : null, Fe = typeof Symbol == "function" && typeof Symbol.iterator == "object", ee = typeof Symbol == "function" && Symbol.toStringTag && (typeof Symbol.toStringTag === Fe || !0) ? Symbol.toStringTag : null, Zr = Object.prototype.propertyIsEnumerable, Xn = (typeof Reflect == "function" ? Reflect.getPrototypeOf : Object.getPrototypeOf) || ([].__proto__ === Array.prototype ? function(e) {
|
|
4266
4277
|
return e.__proto__;
|
|
4267
4278
|
} : null);
|
|
4268
4279
|
function Zn(e, t) {
|
|
@@ -4278,7 +4289,7 @@ function Zn(e, t) {
|
|
|
4278
4289
|
}
|
|
4279
4290
|
return ge.call(t, n, "$&_");
|
|
4280
4291
|
}
|
|
4281
|
-
var zt =
|
|
4292
|
+
var zt = al, er = zt.custom, tr = ta(er) ? er : null, ml = function e(t, n, a, s) {
|
|
4282
4293
|
var i = n || {};
|
|
4283
4294
|
if (ve(i, "quoteStyle") && i.quoteStyle !== "single" && i.quoteStyle !== "double")
|
|
4284
4295
|
throw new TypeError('option "quoteStyle" must be "single" or "double"');
|
|
@@ -4312,43 +4323,43 @@ var zt = el, er = zt.custom, tr = ta(er) ? er : null, ul = function e(t, n, a, s
|
|
|
4312
4323
|
}
|
|
4313
4324
|
var u = typeof i.depth > "u" ? 5 : i.depth;
|
|
4314
4325
|
if (typeof a > "u" && (a = 0), a >= u && u > 0 && typeof t == "object")
|
|
4315
|
-
return
|
|
4316
|
-
var f =
|
|
4326
|
+
return Dt(t) ? "[Array]" : "[Object]";
|
|
4327
|
+
var f = Rl(i, a);
|
|
4317
4328
|
if (typeof s > "u")
|
|
4318
4329
|
s = [];
|
|
4319
4330
|
else if (na(s, t) >= 0)
|
|
4320
4331
|
return "[Circular]";
|
|
4321
|
-
function d(I, z,
|
|
4322
|
-
if (z && (s =
|
|
4323
|
-
var
|
|
4332
|
+
function d(I, z, B) {
|
|
4333
|
+
if (z && (s = fl.call(s), s.push(z)), B) {
|
|
4334
|
+
var D = {
|
|
4324
4335
|
depth: i.depth
|
|
4325
4336
|
};
|
|
4326
|
-
return ve(i, "quoteStyle") && (
|
|
4337
|
+
return ve(i, "quoteStyle") && (D.quoteStyle = i.quoteStyle), e(I, D, a + 1, s);
|
|
4327
4338
|
}
|
|
4328
4339
|
return e(I, i, a + 1, s);
|
|
4329
4340
|
}
|
|
4330
4341
|
if (typeof t == "function" && !nr(t)) {
|
|
4331
|
-
var m =
|
|
4342
|
+
var m = Sl(t), h = Ke(t, d);
|
|
4332
4343
|
return "[Function" + (m ? ": " + m : " (anonymous)") + "]" + (h.length > 0 ? " { " + ue.call(h, ", ") + " }" : "");
|
|
4333
4344
|
}
|
|
4334
4345
|
if (ta(t)) {
|
|
4335
4346
|
var v = Fe ? ge.call(String(t), /^(Symbol\(.*\))_[^)]*$/, "$1") : Vt.call(t);
|
|
4336
4347
|
return typeof t == "object" && !Fe ? Ue(v) : v;
|
|
4337
4348
|
}
|
|
4338
|
-
if (
|
|
4349
|
+
if (Cl(t)) {
|
|
4339
4350
|
for (var g = "<" + Qn.call(String(t.nodeName)), b = t.attributes || [], y = 0; y < b.length; y++)
|
|
4340
|
-
g += " " + b[y].name + "=" + ea(
|
|
4351
|
+
g += " " + b[y].name + "=" + ea(hl(b[y].value), "double", i);
|
|
4341
4352
|
return g += ">", t.childNodes && t.childNodes.length && (g += "..."), g += "</" + Qn.call(String(t.nodeName)) + ">", g;
|
|
4342
4353
|
}
|
|
4343
|
-
if (
|
|
4354
|
+
if (Dt(t)) {
|
|
4344
4355
|
if (t.length === 0)
|
|
4345
4356
|
return "[]";
|
|
4346
4357
|
var x = Ke(t, d);
|
|
4347
|
-
return f && !
|
|
4358
|
+
return f && !El(x) ? "[" + Jt(x, f) + "]" : "[ " + ue.call(x, ", ") + " ]";
|
|
4348
4359
|
}
|
|
4349
|
-
if (
|
|
4350
|
-
var
|
|
4351
|
-
return !("cause" in Error.prototype) && "cause" in t && !Zr.call(t, "cause") ? "{ [" + String(t) + "] " + ue.call(Kn.call("[cause]: " + d(t.cause),
|
|
4360
|
+
if (vl(t)) {
|
|
4361
|
+
var $ = Ke(t, d);
|
|
4362
|
+
return !("cause" in Error.prototype) && "cause" in t && !Zr.call(t, "cause") ? "{ [" + String(t) + "] " + ue.call(Kn.call("[cause]: " + d(t.cause), $), ", ") + " }" : $.length === 0 ? "[" + String(t) + "]" : "{ [" + String(t) + "] " + ue.call($, ", ") + " }";
|
|
4352
4363
|
}
|
|
4353
4364
|
if (typeof t == "object" && r) {
|
|
4354
4365
|
if (tr && typeof t[tr] == "function" && zt)
|
|
@@ -4356,39 +4367,39 @@ var zt = el, er = zt.custom, tr = ta(er) ? er : null, ul = function e(t, n, a, s
|
|
|
4356
4367
|
if (r !== "symbol" && typeof t.inspect == "function")
|
|
4357
4368
|
return t.inspect();
|
|
4358
4369
|
}
|
|
4359
|
-
if (
|
|
4370
|
+
if (wl(t)) {
|
|
4360
4371
|
var S = [];
|
|
4361
|
-
return
|
|
4372
|
+
return Jn && Jn.call(t, function(I, z) {
|
|
4362
4373
|
S.push(d(z, t, !0) + " => " + d(I, t));
|
|
4363
4374
|
}), rr("Map", dt.call(t), S, f);
|
|
4364
4375
|
}
|
|
4365
|
-
if (
|
|
4376
|
+
if (Tl(t)) {
|
|
4366
4377
|
var j = [];
|
|
4367
|
-
return
|
|
4378
|
+
return Wn && Wn.call(t, function(I) {
|
|
4368
4379
|
j.push(d(I, t));
|
|
4369
4380
|
}), rr("Set", pt.call(t), j, f);
|
|
4370
4381
|
}
|
|
4371
|
-
if (
|
|
4382
|
+
if (jl(t))
|
|
4372
4383
|
return Rt("WeakMap");
|
|
4373
|
-
if (
|
|
4384
|
+
if (Ol(t))
|
|
4374
4385
|
return Rt("WeakSet");
|
|
4375
|
-
if (
|
|
4386
|
+
if (Nl(t))
|
|
4376
4387
|
return Rt("WeakRef");
|
|
4377
|
-
if (
|
|
4388
|
+
if (bl(t))
|
|
4378
4389
|
return Ue(d(Number(t)));
|
|
4379
|
-
if (
|
|
4390
|
+
if (kl(t))
|
|
4380
4391
|
return Ue(d(Bt.call(t)));
|
|
4381
|
-
if (
|
|
4382
|
-
return Ue(
|
|
4383
|
-
if (
|
|
4392
|
+
if (xl(t))
|
|
4393
|
+
return Ue(ll.call(t));
|
|
4394
|
+
if (gl(t))
|
|
4384
4395
|
return Ue(d(String(t)));
|
|
4385
4396
|
if (typeof window < "u" && t === window)
|
|
4386
4397
|
return "{ [object Window] }";
|
|
4387
|
-
if (typeof globalThis < "u" && t === globalThis || typeof
|
|
4398
|
+
if (typeof globalThis < "u" && t === globalThis || typeof He < "u" && t === He)
|
|
4388
4399
|
return "{ [object globalThis] }";
|
|
4389
|
-
if (!
|
|
4390
|
-
var R = Ke(t, d), E = Xn ? Xn(t) === Object.prototype : t instanceof Object || t.constructor === Object, A = t instanceof Object ? "" : "null prototype", M = !E && ee && Object(t) === t && ee in t ? un.call(be(t), 8, -1) : A ? "Object" : "",
|
|
4391
|
-
return R.length === 0 ? L + "{}" : f ? L + "{" +
|
|
4400
|
+
if (!yl(t) && !nr(t)) {
|
|
4401
|
+
var R = Ke(t, d), E = Xn ? Xn(t) === Object.prototype : t instanceof Object || t.constructor === Object, A = t instanceof Object ? "" : "null prototype", M = !E && ee && Object(t) === t && ee in t ? un.call(be(t), 8, -1) : A ? "Object" : "", k = E || typeof t.constructor != "function" ? "" : t.constructor.name ? t.constructor.name + " " : "", L = k + (M || A ? "[" + ue.call(Kn.call([], M || [], A || []), ": ") + "] " : "");
|
|
4402
|
+
return R.length === 0 ? L + "{}" : f ? L + "{" + Jt(R, f) + "}" : L + "{ " + ue.call(R, ", ") + " }";
|
|
4392
4403
|
}
|
|
4393
4404
|
return String(t);
|
|
4394
4405
|
};
|
|
@@ -4396,28 +4407,28 @@ function ea(e, t, n) {
|
|
|
4396
4407
|
var a = (n.quoteStyle || t) === "double" ? '"' : "'";
|
|
4397
4408
|
return a + e + a;
|
|
4398
4409
|
}
|
|
4399
|
-
function
|
|
4410
|
+
function hl(e) {
|
|
4400
4411
|
return ge.call(String(e), /"/g, """);
|
|
4401
4412
|
}
|
|
4402
|
-
function
|
|
4413
|
+
function Dt(e) {
|
|
4403
4414
|
return be(e) === "[object Array]" && (!ee || !(typeof e == "object" && ee in e));
|
|
4404
4415
|
}
|
|
4405
|
-
function
|
|
4416
|
+
function yl(e) {
|
|
4406
4417
|
return be(e) === "[object Date]" && (!ee || !(typeof e == "object" && ee in e));
|
|
4407
4418
|
}
|
|
4408
4419
|
function nr(e) {
|
|
4409
4420
|
return be(e) === "[object RegExp]" && (!ee || !(typeof e == "object" && ee in e));
|
|
4410
4421
|
}
|
|
4411
|
-
function
|
|
4422
|
+
function vl(e) {
|
|
4412
4423
|
return be(e) === "[object Error]" && (!ee || !(typeof e == "object" && ee in e));
|
|
4413
4424
|
}
|
|
4414
|
-
function
|
|
4425
|
+
function gl(e) {
|
|
4415
4426
|
return be(e) === "[object String]" && (!ee || !(typeof e == "object" && ee in e));
|
|
4416
4427
|
}
|
|
4417
|
-
function
|
|
4428
|
+
function bl(e) {
|
|
4418
4429
|
return be(e) === "[object Number]" && (!ee || !(typeof e == "object" && ee in e));
|
|
4419
4430
|
}
|
|
4420
|
-
function
|
|
4431
|
+
function xl(e) {
|
|
4421
4432
|
return be(e) === "[object Boolean]" && (!ee || !(typeof e == "object" && ee in e));
|
|
4422
4433
|
}
|
|
4423
4434
|
function ta(e) {
|
|
@@ -4433,7 +4444,7 @@ function ta(e) {
|
|
|
4433
4444
|
}
|
|
4434
4445
|
return !1;
|
|
4435
4446
|
}
|
|
4436
|
-
function
|
|
4447
|
+
function kl(e) {
|
|
4437
4448
|
if (!e || typeof e != "object" || !Bt)
|
|
4438
4449
|
return !1;
|
|
4439
4450
|
try {
|
|
@@ -4442,19 +4453,19 @@ function vl(e) {
|
|
|
4442
4453
|
}
|
|
4443
4454
|
return !1;
|
|
4444
4455
|
}
|
|
4445
|
-
var
|
|
4456
|
+
var $l = Object.prototype.hasOwnProperty || function(e) {
|
|
4446
4457
|
return e in this;
|
|
4447
4458
|
};
|
|
4448
4459
|
function ve(e, t) {
|
|
4449
|
-
return
|
|
4460
|
+
return $l.call(e, t);
|
|
4450
4461
|
}
|
|
4451
4462
|
function be(e) {
|
|
4452
|
-
return
|
|
4463
|
+
return cl.call(e);
|
|
4453
4464
|
}
|
|
4454
|
-
function
|
|
4465
|
+
function Sl(e) {
|
|
4455
4466
|
if (e.name)
|
|
4456
4467
|
return e.name;
|
|
4457
|
-
var t =
|
|
4468
|
+
var t = dl.call(ul.call(e), /^function\s*([\w$]+)/);
|
|
4458
4469
|
return t ? t[1] : null;
|
|
4459
4470
|
}
|
|
4460
4471
|
function na(e, t) {
|
|
@@ -4465,7 +4476,7 @@ function na(e, t) {
|
|
|
4465
4476
|
return n;
|
|
4466
4477
|
return -1;
|
|
4467
4478
|
}
|
|
4468
|
-
function
|
|
4479
|
+
function wl(e) {
|
|
4469
4480
|
if (!dt || !e || typeof e != "object")
|
|
4470
4481
|
return !1;
|
|
4471
4482
|
try {
|
|
@@ -4480,11 +4491,11 @@ function xl(e) {
|
|
|
4480
4491
|
}
|
|
4481
4492
|
return !1;
|
|
4482
4493
|
}
|
|
4483
|
-
function
|
|
4484
|
-
if (!
|
|
4494
|
+
function jl(e) {
|
|
4495
|
+
if (!Me || !e || typeof e != "object")
|
|
4485
4496
|
return !1;
|
|
4486
4497
|
try {
|
|
4487
|
-
|
|
4498
|
+
Me.call(e, Me);
|
|
4488
4499
|
try {
|
|
4489
4500
|
Be.call(e, Be);
|
|
4490
4501
|
} catch {
|
|
@@ -4495,7 +4506,7 @@ function kl(e) {
|
|
|
4495
4506
|
}
|
|
4496
4507
|
return !1;
|
|
4497
4508
|
}
|
|
4498
|
-
function
|
|
4509
|
+
function Nl(e) {
|
|
4499
4510
|
if (!Gn || !e || typeof e != "object")
|
|
4500
4511
|
return !1;
|
|
4501
4512
|
try {
|
|
@@ -4504,7 +4515,7 @@ function $l(e) {
|
|
|
4504
4515
|
}
|
|
4505
4516
|
return !1;
|
|
4506
4517
|
}
|
|
4507
|
-
function
|
|
4518
|
+
function Tl(e) {
|
|
4508
4519
|
if (!pt || !e || typeof e != "object")
|
|
4509
4520
|
return !1;
|
|
4510
4521
|
try {
|
|
@@ -4519,13 +4530,13 @@ function Sl(e) {
|
|
|
4519
4530
|
}
|
|
4520
4531
|
return !1;
|
|
4521
4532
|
}
|
|
4522
|
-
function
|
|
4533
|
+
function Ol(e) {
|
|
4523
4534
|
if (!Be || !e || typeof e != "object")
|
|
4524
4535
|
return !1;
|
|
4525
4536
|
try {
|
|
4526
4537
|
Be.call(e, Be);
|
|
4527
4538
|
try {
|
|
4528
|
-
|
|
4539
|
+
Me.call(e, Me);
|
|
4529
4540
|
} catch {
|
|
4530
4541
|
return !0;
|
|
4531
4542
|
}
|
|
@@ -4534,7 +4545,7 @@ function wl(e) {
|
|
|
4534
4545
|
}
|
|
4535
4546
|
return !1;
|
|
4536
4547
|
}
|
|
4537
|
-
function
|
|
4548
|
+
function Cl(e) {
|
|
4538
4549
|
return !e || typeof e != "object" ? !1 : typeof HTMLElement < "u" && e instanceof HTMLElement ? !0 : typeof e.nodeName == "string" && typeof e.getAttribute == "function";
|
|
4539
4550
|
}
|
|
4540
4551
|
function ra(e, t) {
|
|
@@ -4542,10 +4553,10 @@ function ra(e, t) {
|
|
|
4542
4553
|
var n = e.length - t.maxStringLength, a = "... " + n + " more character" + (n > 1 ? "s" : "");
|
|
4543
4554
|
return ra(un.call(e, 0, t.maxStringLength), t) + a;
|
|
4544
4555
|
}
|
|
4545
|
-
var s = ge.call(ge.call(e, /(['\\])/g, "\\$1"), /[\x00-\x1f]/g,
|
|
4556
|
+
var s = ge.call(ge.call(e, /(['\\])/g, "\\$1"), /[\x00-\x1f]/g, Pl);
|
|
4546
4557
|
return ea(s, "single", t);
|
|
4547
4558
|
}
|
|
4548
|
-
function
|
|
4559
|
+
function Pl(e) {
|
|
4549
4560
|
var t = e.charCodeAt(0), n = {
|
|
4550
4561
|
8: "b",
|
|
4551
4562
|
9: "t",
|
|
@@ -4553,7 +4564,7 @@ function Nl(e) {
|
|
|
4553
4564
|
12: "f",
|
|
4554
4565
|
13: "r"
|
|
4555
4566
|
}[t];
|
|
4556
|
-
return n ? "\\" + n : "\\x" + (t < 16 ? "0" : "") +
|
|
4567
|
+
return n ? "\\" + n : "\\x" + (t < 16 ? "0" : "") + pl.call(t.toString(16));
|
|
4557
4568
|
}
|
|
4558
4569
|
function Ue(e) {
|
|
4559
4570
|
return "Object(" + e + ")";
|
|
@@ -4562,17 +4573,17 @@ function Rt(e) {
|
|
|
4562
4573
|
return e + " { ? }";
|
|
4563
4574
|
}
|
|
4564
4575
|
function rr(e, t, n, a) {
|
|
4565
|
-
var s = a ?
|
|
4576
|
+
var s = a ? Jt(n, a) : ue.call(n, ", ");
|
|
4566
4577
|
return e + " (" + t + ") {" + s + "}";
|
|
4567
4578
|
}
|
|
4568
|
-
function
|
|
4579
|
+
function El(e) {
|
|
4569
4580
|
for (var t = 0; t < e.length; t++)
|
|
4570
4581
|
if (na(e[t], `
|
|
4571
4582
|
`) >= 0)
|
|
4572
4583
|
return !1;
|
|
4573
4584
|
return !0;
|
|
4574
4585
|
}
|
|
4575
|
-
function
|
|
4586
|
+
function Rl(e, t) {
|
|
4576
4587
|
var n;
|
|
4577
4588
|
if (e.indent === " ")
|
|
4578
4589
|
n = " ";
|
|
@@ -4585,7 +4596,7 @@ function Ol(e, t) {
|
|
|
4585
4596
|
prev: ue.call(Array(t + 1), n)
|
|
4586
4597
|
};
|
|
4587
4598
|
}
|
|
4588
|
-
function
|
|
4599
|
+
function Jt(e, t) {
|
|
4589
4600
|
if (e.length === 0)
|
|
4590
4601
|
return "";
|
|
4591
4602
|
var n = `
|
|
@@ -4594,7 +4605,7 @@ function Wt(e, t) {
|
|
|
4594
4605
|
` + t.prev;
|
|
4595
4606
|
}
|
|
4596
4607
|
function Ke(e, t) {
|
|
4597
|
-
var n =
|
|
4608
|
+
var n = Dt(e), a = [];
|
|
4598
4609
|
if (n) {
|
|
4599
4610
|
a.length = e.length;
|
|
4600
4611
|
for (var s = 0; s < e.length; s++)
|
|
@@ -4613,15 +4624,15 @@ function Ke(e, t) {
|
|
|
4613
4624
|
Zr.call(e, i[c]) && a.push("[" + t(i[c]) + "]: " + t(e[i[c]], e));
|
|
4614
4625
|
return a;
|
|
4615
4626
|
}
|
|
4616
|
-
var aa = _e, Le =
|
|
4627
|
+
var aa = _e, Le = tl, Al = ml, ql = Ge, Ye = aa("%WeakMap%", !0), Xe = aa("%Map%", !0), Fl = Le("WeakMap.prototype.get", !0), Il = Le("WeakMap.prototype.set", !0), _l = Le("WeakMap.prototype.has", !0), Ll = Le("Map.prototype.get", !0), Ul = Le("Map.prototype.set", !0), Hl = Le("Map.prototype.has", !0), dn = function(e, t) {
|
|
4617
4628
|
for (var n = e, a; (a = n.next) !== null; n = a)
|
|
4618
4629
|
if (a.key === t)
|
|
4619
4630
|
return n.next = a.next, a.next = /** @type {NonNullable<typeof list.next>} */
|
|
4620
4631
|
e.next, e.next = a, a;
|
|
4621
|
-
},
|
|
4632
|
+
}, Ml = function(e, t) {
|
|
4622
4633
|
var n = dn(e, t);
|
|
4623
4634
|
return n && n.value;
|
|
4624
|
-
},
|
|
4635
|
+
}, Bl = function(e, t, n) {
|
|
4625
4636
|
var a = dn(e, t);
|
|
4626
4637
|
a ? a.value = n : e.next = /** @type {import('.').ListNode<typeof value>} */
|
|
4627
4638
|
{
|
|
@@ -4630,48 +4641,48 @@ var aa = _e, Le = Zs, Cl = ul, Pl = Ge, Ye = aa("%WeakMap%", !0), Xe = aa("%Map%
|
|
|
4630
4641
|
next: e.next,
|
|
4631
4642
|
value: n
|
|
4632
4643
|
};
|
|
4633
|
-
},
|
|
4644
|
+
}, Vl = function(e, t) {
|
|
4634
4645
|
return !!dn(e, t);
|
|
4635
|
-
},
|
|
4646
|
+
}, zl = function() {
|
|
4636
4647
|
var t, n, a, s = {
|
|
4637
4648
|
assert: function(i) {
|
|
4638
4649
|
if (!s.has(i))
|
|
4639
|
-
throw new
|
|
4650
|
+
throw new ql("Side channel does not contain " + Al(i));
|
|
4640
4651
|
},
|
|
4641
4652
|
get: function(i) {
|
|
4642
4653
|
if (Ye && i && (typeof i == "object" || typeof i == "function")) {
|
|
4643
4654
|
if (t)
|
|
4644
|
-
return
|
|
4655
|
+
return Fl(t, i);
|
|
4645
4656
|
} else if (Xe) {
|
|
4646
4657
|
if (n)
|
|
4647
|
-
return
|
|
4658
|
+
return Ll(n, i);
|
|
4648
4659
|
} else if (a)
|
|
4649
|
-
return
|
|
4660
|
+
return Ml(a, i);
|
|
4650
4661
|
},
|
|
4651
4662
|
has: function(i) {
|
|
4652
4663
|
if (Ye && i && (typeof i == "object" || typeof i == "function")) {
|
|
4653
4664
|
if (t)
|
|
4654
|
-
return
|
|
4665
|
+
return _l(t, i);
|
|
4655
4666
|
} else if (Xe) {
|
|
4656
4667
|
if (n)
|
|
4657
|
-
return
|
|
4668
|
+
return Hl(n, i);
|
|
4658
4669
|
} else if (a)
|
|
4659
|
-
return
|
|
4670
|
+
return Vl(a, i);
|
|
4660
4671
|
return !1;
|
|
4661
4672
|
},
|
|
4662
4673
|
set: function(i, r) {
|
|
4663
|
-
Ye && i && (typeof i == "object" || typeof i == "function") ? (t || (t = new Ye()),
|
|
4674
|
+
Ye && i && (typeof i == "object" || typeof i == "function") ? (t || (t = new Ye()), Il(t, i, r)) : Xe ? (n || (n = new Xe()), Ul(n, i, r)) : (a || (a = { key: {}, next: null }), Bl(a, i, r));
|
|
4664
4675
|
}
|
|
4665
4676
|
};
|
|
4666
4677
|
return s;
|
|
4667
|
-
},
|
|
4678
|
+
}, Dl = String.prototype.replace, Jl = /%20/g, At = {
|
|
4668
4679
|
RFC1738: "RFC1738",
|
|
4669
4680
|
RFC3986: "RFC3986"
|
|
4670
4681
|
}, pn = {
|
|
4671
4682
|
default: At.RFC3986,
|
|
4672
4683
|
formatters: {
|
|
4673
4684
|
RFC1738: function(e) {
|
|
4674
|
-
return
|
|
4685
|
+
return Dl.call(e, Jl, "+");
|
|
4675
4686
|
},
|
|
4676
4687
|
RFC3986: function(e) {
|
|
4677
4688
|
return String(e);
|
|
@@ -4679,11 +4690,11 @@ var aa = _e, Le = Zs, Cl = ul, Pl = Ge, Ye = aa("%WeakMap%", !0), Xe = aa("%Map%
|
|
|
4679
4690
|
},
|
|
4680
4691
|
RFC1738: At.RFC1738,
|
|
4681
4692
|
RFC3986: At.RFC3986
|
|
4682
|
-
},
|
|
4693
|
+
}, Wl = pn, qt = Object.prototype.hasOwnProperty, ke = Array.isArray, le = function() {
|
|
4683
4694
|
for (var e = [], t = 0; t < 256; ++t)
|
|
4684
4695
|
e.push("%" + ((t < 16 ? "0" : "") + t.toString(16)).toUpperCase());
|
|
4685
4696
|
return e;
|
|
4686
|
-
}(),
|
|
4697
|
+
}(), Gl = function(t) {
|
|
4687
4698
|
for (; t.length > 1; ) {
|
|
4688
4699
|
var n = t.pop(), a = n.obj[n.prop];
|
|
4689
4700
|
if (ke(a)) {
|
|
@@ -4696,7 +4707,7 @@ var aa = _e, Le = Zs, Cl = ul, Pl = Ge, Ye = aa("%WeakMap%", !0), Xe = aa("%Map%
|
|
|
4696
4707
|
for (var a = n && n.plainObjects ? /* @__PURE__ */ Object.create(null) : {}, s = 0; s < t.length; ++s)
|
|
4697
4708
|
typeof t[s] < "u" && (a[s] = t[s]);
|
|
4698
4709
|
return a;
|
|
4699
|
-
},
|
|
4710
|
+
}, Ql = function e(t, n, a) {
|
|
4700
4711
|
if (!n)
|
|
4701
4712
|
return t;
|
|
4702
4713
|
if (typeof n != "object") {
|
|
@@ -4721,11 +4732,11 @@ var aa = _e, Le = Zs, Cl = ul, Pl = Ge, Ye = aa("%WeakMap%", !0), Xe = aa("%Map%
|
|
|
4721
4732
|
var o = n[r];
|
|
4722
4733
|
return qt.call(i, r) ? i[r] = e(i[r], o, a) : i[r] = o, i;
|
|
4723
4734
|
}, s);
|
|
4724
|
-
},
|
|
4735
|
+
}, Kl = function(t, n) {
|
|
4725
4736
|
return Object.keys(n).reduce(function(a, s) {
|
|
4726
4737
|
return a[s] = n[s], a;
|
|
4727
4738
|
}, t);
|
|
4728
|
-
},
|
|
4739
|
+
}, Yl = function(e, t, n) {
|
|
4729
4740
|
var a = e.replace(/\+/g, " ");
|
|
4730
4741
|
if (n === "iso-8859-1")
|
|
4731
4742
|
return a.replace(/%[0-9a-f]{2}/gi, unescape);
|
|
@@ -4734,7 +4745,7 @@ var aa = _e, Le = Zs, Cl = ul, Pl = Ge, Ye = aa("%WeakMap%", !0), Xe = aa("%Map%
|
|
|
4734
4745
|
} catch {
|
|
4735
4746
|
return a;
|
|
4736
4747
|
}
|
|
4737
|
-
}, Ft = 1024,
|
|
4748
|
+
}, Ft = 1024, Xl = function(t, n, a, s, i) {
|
|
4738
4749
|
if (t.length === 0)
|
|
4739
4750
|
return t;
|
|
4740
4751
|
var r = t;
|
|
@@ -4745,7 +4756,7 @@ var aa = _e, Le = Zs, Cl = ul, Pl = Ge, Ye = aa("%WeakMap%", !0), Xe = aa("%Map%
|
|
|
4745
4756
|
for (var o = "", l = 0; l < r.length; l += Ft) {
|
|
4746
4757
|
for (var c = r.length >= Ft ? r.slice(l, l + Ft) : r, u = [], f = 0; f < c.length; ++f) {
|
|
4747
4758
|
var d = c.charCodeAt(f);
|
|
4748
|
-
if (d === 45 || d === 46 || d === 95 || d === 126 || d >= 48 && d <= 57 || d >= 65 && d <= 90 || d >= 97 && d <= 122 || i ===
|
|
4759
|
+
if (d === 45 || d === 46 || d === 95 || d === 126 || d >= 48 && d <= 57 || d >= 65 && d <= 90 || d >= 97 && d <= 122 || i === Wl.RFC1738 && (d === 40 || d === 41)) {
|
|
4749
4760
|
u[u.length] = c.charAt(f);
|
|
4750
4761
|
continue;
|
|
4751
4762
|
}
|
|
@@ -4766,20 +4777,20 @@ var aa = _e, Le = Zs, Cl = ul, Pl = Ge, Ye = aa("%WeakMap%", !0), Xe = aa("%Map%
|
|
|
4766
4777
|
o += u.join("");
|
|
4767
4778
|
}
|
|
4768
4779
|
return o;
|
|
4769
|
-
},
|
|
4780
|
+
}, Zl = function(t) {
|
|
4770
4781
|
for (var n = [{ obj: { o: t }, prop: "o" }], a = [], s = 0; s < n.length; ++s)
|
|
4771
4782
|
for (var i = n[s], r = i.obj[i.prop], o = Object.keys(r), l = 0; l < o.length; ++l) {
|
|
4772
4783
|
var c = o[l], u = r[c];
|
|
4773
4784
|
typeof u == "object" && u !== null && a.indexOf(u) === -1 && (n.push({ obj: r, prop: c }), a.push(u));
|
|
4774
4785
|
}
|
|
4775
|
-
return
|
|
4776
|
-
},
|
|
4786
|
+
return Gl(n), t;
|
|
4787
|
+
}, ec = function(t) {
|
|
4777
4788
|
return Object.prototype.toString.call(t) === "[object RegExp]";
|
|
4778
|
-
},
|
|
4789
|
+
}, tc = function(t) {
|
|
4779
4790
|
return !t || typeof t != "object" ? !1 : !!(t.constructor && t.constructor.isBuffer && t.constructor.isBuffer(t));
|
|
4780
|
-
},
|
|
4791
|
+
}, nc = function(t, n) {
|
|
4781
4792
|
return [].concat(t, n);
|
|
4782
|
-
},
|
|
4793
|
+
}, rc = function(t, n) {
|
|
4783
4794
|
if (ke(t)) {
|
|
4784
4795
|
for (var a = [], s = 0; s < t.length; s += 1)
|
|
4785
4796
|
a.push(n(t[s]));
|
|
@@ -4788,16 +4799,16 @@ var aa = _e, Le = Zs, Cl = ul, Pl = Ge, Ye = aa("%WeakMap%", !0), Xe = aa("%Map%
|
|
|
4788
4799
|
return n(t);
|
|
4789
4800
|
}, oa = {
|
|
4790
4801
|
arrayToObject: ia,
|
|
4791
|
-
assign:
|
|
4792
|
-
combine:
|
|
4793
|
-
compact:
|
|
4794
|
-
decode:
|
|
4795
|
-
encode:
|
|
4796
|
-
isBuffer:
|
|
4797
|
-
isRegExp:
|
|
4798
|
-
maybeMap:
|
|
4799
|
-
merge:
|
|
4800
|
-
}, sa =
|
|
4802
|
+
assign: Kl,
|
|
4803
|
+
combine: nc,
|
|
4804
|
+
compact: Zl,
|
|
4805
|
+
decode: Yl,
|
|
4806
|
+
encode: Xl,
|
|
4807
|
+
isBuffer: tc,
|
|
4808
|
+
isRegExp: ec,
|
|
4809
|
+
maybeMap: rc,
|
|
4810
|
+
merge: Ql
|
|
4811
|
+
}, sa = zl, rt = oa, Ve = pn, ac = Object.prototype.hasOwnProperty, la = {
|
|
4801
4812
|
brackets: function(t) {
|
|
4802
4813
|
return t + "[]";
|
|
4803
4814
|
},
|
|
@@ -4808,9 +4819,9 @@ var aa = _e, Le = Zs, Cl = ul, Pl = Ge, Ye = aa("%WeakMap%", !0), Xe = aa("%Map%
|
|
|
4808
4819
|
repeat: function(t) {
|
|
4809
4820
|
return t;
|
|
4810
4821
|
}
|
|
4811
|
-
}, ce = Array.isArray,
|
|
4812
|
-
|
|
4813
|
-
},
|
|
4822
|
+
}, ce = Array.isArray, ic = Array.prototype.push, ca = function(e, t) {
|
|
4823
|
+
ic.apply(e, ce(t) ? t : [t]);
|
|
4824
|
+
}, oc = Date.prototype.toISOString, ar = Ve.default, J = {
|
|
4814
4825
|
addQueryPrefix: !1,
|
|
4815
4826
|
allowDots: !1,
|
|
4816
4827
|
allowEmptyArrays: !1,
|
|
@@ -4827,33 +4838,33 @@ var aa = _e, Le = Zs, Cl = ul, Pl = Ge, Ye = aa("%WeakMap%", !0), Xe = aa("%Map%
|
|
|
4827
4838
|
// deprecated
|
|
4828
4839
|
indices: !1,
|
|
4829
4840
|
serializeDate: function(t) {
|
|
4830
|
-
return
|
|
4841
|
+
return oc.call(t);
|
|
4831
4842
|
},
|
|
4832
4843
|
skipNulls: !1,
|
|
4833
4844
|
strictNullHandling: !1
|
|
4834
|
-
},
|
|
4845
|
+
}, sc = function(t) {
|
|
4835
4846
|
return typeof t == "string" || typeof t == "number" || typeof t == "boolean" || typeof t == "symbol" || typeof t == "bigint";
|
|
4836
|
-
}, It = {},
|
|
4837
|
-
for (var x = t,
|
|
4838
|
-
var R =
|
|
4847
|
+
}, It = {}, lc = function e(t, n, a, s, i, r, o, l, c, u, f, d, m, h, v, g, b, y) {
|
|
4848
|
+
for (var x = t, $ = y, S = 0, j = !1; ($ = $.get(It)) !== void 0 && !j; ) {
|
|
4849
|
+
var R = $.get(t);
|
|
4839
4850
|
if (S += 1, typeof R < "u") {
|
|
4840
4851
|
if (R === S)
|
|
4841
4852
|
throw new RangeError("Cyclic object value");
|
|
4842
4853
|
j = !0;
|
|
4843
4854
|
}
|
|
4844
|
-
typeof
|
|
4855
|
+
typeof $.get(It) > "u" && (S = 0);
|
|
4845
4856
|
}
|
|
4846
4857
|
if (typeof u == "function" ? x = u(n, x) : x instanceof Date ? x = m(x) : a === "comma" && ce(x) && (x = rt.maybeMap(x, function(w) {
|
|
4847
4858
|
return w instanceof Date ? m(w) : w;
|
|
4848
4859
|
})), x === null) {
|
|
4849
4860
|
if (r)
|
|
4850
|
-
return c && !g ? c(n,
|
|
4861
|
+
return c && !g ? c(n, J.encoder, b, "key", h) : n;
|
|
4851
4862
|
x = "";
|
|
4852
4863
|
}
|
|
4853
|
-
if (
|
|
4864
|
+
if (sc(x) || rt.isBuffer(x)) {
|
|
4854
4865
|
if (c) {
|
|
4855
|
-
var E = g ? n : c(n,
|
|
4856
|
-
return [v(E) + "=" + v(c(x,
|
|
4866
|
+
var E = g ? n : c(n, J.encoder, b, "key", h);
|
|
4867
|
+
return [v(E) + "=" + v(c(x, J.encoder, b, "value", h))];
|
|
4857
4868
|
}
|
|
4858
4869
|
return [v(n) + "=" + v(String(x))];
|
|
4859
4870
|
}
|
|
@@ -4866,20 +4877,20 @@ var aa = _e, Le = Zs, Cl = ul, Pl = Ge, Ye = aa("%WeakMap%", !0), Xe = aa("%Map%
|
|
|
4866
4877
|
else if (ce(u))
|
|
4867
4878
|
M = u;
|
|
4868
4879
|
else {
|
|
4869
|
-
var
|
|
4870
|
-
M = f ?
|
|
4880
|
+
var k = Object.keys(x);
|
|
4881
|
+
M = f ? k.sort(f) : k;
|
|
4871
4882
|
}
|
|
4872
4883
|
var L = l ? n.replace(/\./g, "%2E") : n, I = s && ce(x) && x.length === 1 ? L + "[]" : L;
|
|
4873
4884
|
if (i && ce(x) && x.length === 0)
|
|
4874
4885
|
return I + "[]";
|
|
4875
4886
|
for (var z = 0; z < M.length; ++z) {
|
|
4876
|
-
var
|
|
4877
|
-
if (!(o &&
|
|
4878
|
-
var _ = d && l ?
|
|
4887
|
+
var B = M[z], D = typeof B == "object" && typeof B.value < "u" ? B.value : x[B];
|
|
4888
|
+
if (!(o && D === null)) {
|
|
4889
|
+
var _ = d && l ? B.replace(/\./g, "%2E") : B, he = ce(x) ? typeof a == "function" ? a(I, _) : I : I + (d ? "." + _ : "[" + _ + "]");
|
|
4879
4890
|
y.set(t, S);
|
|
4880
4891
|
var pe = sa();
|
|
4881
4892
|
pe.set(It, y), ca(A, e(
|
|
4882
|
-
|
|
4893
|
+
D,
|
|
4883
4894
|
he,
|
|
4884
4895
|
a,
|
|
4885
4896
|
s,
|
|
@@ -4901,53 +4912,53 @@ var aa = _e, Le = Zs, Cl = ul, Pl = Ge, Ye = aa("%WeakMap%", !0), Xe = aa("%Map%
|
|
|
4901
4912
|
}
|
|
4902
4913
|
}
|
|
4903
4914
|
return A;
|
|
4904
|
-
},
|
|
4915
|
+
}, cc = function(t) {
|
|
4905
4916
|
if (!t)
|
|
4906
|
-
return
|
|
4917
|
+
return J;
|
|
4907
4918
|
if (typeof t.allowEmptyArrays < "u" && typeof t.allowEmptyArrays != "boolean")
|
|
4908
4919
|
throw new TypeError("`allowEmptyArrays` option can only be `true` or `false`, when provided");
|
|
4909
4920
|
if (typeof t.encodeDotInKeys < "u" && typeof t.encodeDotInKeys != "boolean")
|
|
4910
4921
|
throw new TypeError("`encodeDotInKeys` option can only be `true` or `false`, when provided");
|
|
4911
4922
|
if (t.encoder !== null && typeof t.encoder < "u" && typeof t.encoder != "function")
|
|
4912
4923
|
throw new TypeError("Encoder has to be a function.");
|
|
4913
|
-
var n = t.charset ||
|
|
4924
|
+
var n = t.charset || J.charset;
|
|
4914
4925
|
if (typeof t.charset < "u" && t.charset !== "utf-8" && t.charset !== "iso-8859-1")
|
|
4915
4926
|
throw new TypeError("The charset option must be either utf-8, iso-8859-1, or undefined");
|
|
4916
4927
|
var a = Ve.default;
|
|
4917
4928
|
if (typeof t.format < "u") {
|
|
4918
|
-
if (!
|
|
4929
|
+
if (!ac.call(Ve.formatters, t.format))
|
|
4919
4930
|
throw new TypeError("Unknown format option provided.");
|
|
4920
4931
|
a = t.format;
|
|
4921
4932
|
}
|
|
4922
|
-
var s = Ve.formatters[a], i =
|
|
4933
|
+
var s = Ve.formatters[a], i = J.filter;
|
|
4923
4934
|
(typeof t.filter == "function" || ce(t.filter)) && (i = t.filter);
|
|
4924
4935
|
var r;
|
|
4925
|
-
if (t.arrayFormat in la ? r = t.arrayFormat : "indices" in t ? r = t.indices ? "indices" : "repeat" : r =
|
|
4936
|
+
if (t.arrayFormat in la ? r = t.arrayFormat : "indices" in t ? r = t.indices ? "indices" : "repeat" : r = J.arrayFormat, "commaRoundTrip" in t && typeof t.commaRoundTrip != "boolean")
|
|
4926
4937
|
throw new TypeError("`commaRoundTrip` must be a boolean, or absent");
|
|
4927
|
-
var o = typeof t.allowDots > "u" ? t.encodeDotInKeys === !0 ? !0 :
|
|
4938
|
+
var o = typeof t.allowDots > "u" ? t.encodeDotInKeys === !0 ? !0 : J.allowDots : !!t.allowDots;
|
|
4928
4939
|
return {
|
|
4929
|
-
addQueryPrefix: typeof t.addQueryPrefix == "boolean" ? t.addQueryPrefix :
|
|
4940
|
+
addQueryPrefix: typeof t.addQueryPrefix == "boolean" ? t.addQueryPrefix : J.addQueryPrefix,
|
|
4930
4941
|
allowDots: o,
|
|
4931
|
-
allowEmptyArrays: typeof t.allowEmptyArrays == "boolean" ? !!t.allowEmptyArrays :
|
|
4942
|
+
allowEmptyArrays: typeof t.allowEmptyArrays == "boolean" ? !!t.allowEmptyArrays : J.allowEmptyArrays,
|
|
4932
4943
|
arrayFormat: r,
|
|
4933
4944
|
charset: n,
|
|
4934
|
-
charsetSentinel: typeof t.charsetSentinel == "boolean" ? t.charsetSentinel :
|
|
4945
|
+
charsetSentinel: typeof t.charsetSentinel == "boolean" ? t.charsetSentinel : J.charsetSentinel,
|
|
4935
4946
|
commaRoundTrip: t.commaRoundTrip,
|
|
4936
|
-
delimiter: typeof t.delimiter > "u" ?
|
|
4937
|
-
encode: typeof t.encode == "boolean" ? t.encode :
|
|
4938
|
-
encodeDotInKeys: typeof t.encodeDotInKeys == "boolean" ? t.encodeDotInKeys :
|
|
4939
|
-
encoder: typeof t.encoder == "function" ? t.encoder :
|
|
4940
|
-
encodeValuesOnly: typeof t.encodeValuesOnly == "boolean" ? t.encodeValuesOnly :
|
|
4947
|
+
delimiter: typeof t.delimiter > "u" ? J.delimiter : t.delimiter,
|
|
4948
|
+
encode: typeof t.encode == "boolean" ? t.encode : J.encode,
|
|
4949
|
+
encodeDotInKeys: typeof t.encodeDotInKeys == "boolean" ? t.encodeDotInKeys : J.encodeDotInKeys,
|
|
4950
|
+
encoder: typeof t.encoder == "function" ? t.encoder : J.encoder,
|
|
4951
|
+
encodeValuesOnly: typeof t.encodeValuesOnly == "boolean" ? t.encodeValuesOnly : J.encodeValuesOnly,
|
|
4941
4952
|
filter: i,
|
|
4942
4953
|
format: a,
|
|
4943
4954
|
formatter: s,
|
|
4944
|
-
serializeDate: typeof t.serializeDate == "function" ? t.serializeDate :
|
|
4945
|
-
skipNulls: typeof t.skipNulls == "boolean" ? t.skipNulls :
|
|
4955
|
+
serializeDate: typeof t.serializeDate == "function" ? t.serializeDate : J.serializeDate,
|
|
4956
|
+
skipNulls: typeof t.skipNulls == "boolean" ? t.skipNulls : J.skipNulls,
|
|
4946
4957
|
sort: typeof t.sort == "function" ? t.sort : null,
|
|
4947
|
-
strictNullHandling: typeof t.strictNullHandling == "boolean" ? t.strictNullHandling :
|
|
4958
|
+
strictNullHandling: typeof t.strictNullHandling == "boolean" ? t.strictNullHandling : J.strictNullHandling
|
|
4948
4959
|
};
|
|
4949
|
-
},
|
|
4950
|
-
var n = e, a =
|
|
4960
|
+
}, uc = function(e, t) {
|
|
4961
|
+
var n = e, a = cc(t), s, i;
|
|
4951
4962
|
typeof a.filter == "function" ? (i = a.filter, n = i("", n)) : ce(a.filter) && (i = a.filter, s = i);
|
|
4952
4963
|
var r = [];
|
|
4953
4964
|
if (typeof n != "object" || n === null)
|
|
@@ -4956,7 +4967,7 @@ var aa = _e, Le = Zs, Cl = ul, Pl = Ge, Ye = aa("%WeakMap%", !0), Xe = aa("%Map%
|
|
|
4956
4967
|
s || (s = Object.keys(n)), a.sort && s.sort(a.sort);
|
|
4957
4968
|
for (var c = sa(), u = 0; u < s.length; ++u) {
|
|
4958
4969
|
var f = s[u];
|
|
4959
|
-
a.skipNulls && n[f] === null || ca(r,
|
|
4970
|
+
a.skipNulls && n[f] === null || ca(r, lc(
|
|
4960
4971
|
n[f],
|
|
4961
4972
|
f,
|
|
4962
4973
|
o,
|
|
@@ -4979,7 +4990,7 @@ var aa = _e, Le = Zs, Cl = ul, Pl = Ge, Ye = aa("%WeakMap%", !0), Xe = aa("%Map%
|
|
|
4979
4990
|
}
|
|
4980
4991
|
var d = r.join(a.delimiter), m = a.addQueryPrefix === !0 ? "?" : "";
|
|
4981
4992
|
return a.charsetSentinel && (a.charset === "iso-8859-1" ? m += "utf8=%26%2310003%3B&" : m += "utf8=%E2%9C%93&"), d.length > 0 ? m + d : "";
|
|
4982
|
-
}, Ie = oa,
|
|
4993
|
+
}, Ie = oa, Wt = Object.prototype.hasOwnProperty, dc = Array.isArray, H = {
|
|
4983
4994
|
allowDots: !1,
|
|
4984
4995
|
allowEmptyArrays: !1,
|
|
4985
4996
|
allowPrototypes: !1,
|
|
@@ -4998,36 +5009,39 @@ var aa = _e, Le = Zs, Cl = ul, Pl = Ge, Ye = aa("%WeakMap%", !0), Xe = aa("%Map%
|
|
|
4998
5009
|
parameterLimit: 1e3,
|
|
4999
5010
|
parseArrays: !0,
|
|
5000
5011
|
plainObjects: !1,
|
|
5012
|
+
strictDepth: !1,
|
|
5001
5013
|
strictNullHandling: !1
|
|
5002
|
-
},
|
|
5014
|
+
}, pc = function(e) {
|
|
5003
5015
|
return e.replace(/&#(\d+);/g, function(t, n) {
|
|
5004
5016
|
return String.fromCharCode(parseInt(n, 10));
|
|
5005
5017
|
});
|
|
5006
5018
|
}, ua = function(e, t) {
|
|
5007
5019
|
return e && typeof e == "string" && t.comma && e.indexOf(",") > -1 ? e.split(",") : e;
|
|
5008
|
-
},
|
|
5009
|
-
var a = { __proto__: null }, s = n.ignoreQueryPrefix ? t.replace(/^\?/, "") : t
|
|
5020
|
+
}, fc = "utf8=%26%2310003%3B", mc = "utf8=%E2%9C%93", hc = function(t, n) {
|
|
5021
|
+
var a = { __proto__: null }, s = n.ignoreQueryPrefix ? t.replace(/^\?/, "") : t;
|
|
5022
|
+
s = s.replace(/%5B/gi, "[").replace(/%5D/gi, "]");
|
|
5023
|
+
var i = n.parameterLimit === 1 / 0 ? void 0 : n.parameterLimit, r = s.split(n.delimiter, i), o = -1, l, c = n.charset;
|
|
5010
5024
|
if (n.charsetSentinel)
|
|
5011
5025
|
for (l = 0; l < r.length; ++l)
|
|
5012
|
-
r[l].indexOf("utf8=") === 0 && (r[l] ===
|
|
5026
|
+
r[l].indexOf("utf8=") === 0 && (r[l] === mc ? c = "utf-8" : r[l] === fc && (c = "iso-8859-1"), o = l, l = r.length);
|
|
5013
5027
|
for (l = 0; l < r.length; ++l)
|
|
5014
5028
|
if (l !== o) {
|
|
5015
5029
|
var u = r[l], f = u.indexOf("]="), d = f === -1 ? u.indexOf("=") : f + 1, m, h;
|
|
5016
|
-
d === -1 ? (m = n.decoder(u,
|
|
5030
|
+
d === -1 ? (m = n.decoder(u, H.decoder, c, "key"), h = n.strictNullHandling ? null : "") : (m = n.decoder(u.slice(0, d), H.decoder, c, "key"), h = Ie.maybeMap(
|
|
5017
5031
|
ua(u.slice(d + 1), n),
|
|
5018
5032
|
function(g) {
|
|
5019
|
-
return n.decoder(g,
|
|
5033
|
+
return n.decoder(g, H.decoder, c, "value");
|
|
5020
5034
|
}
|
|
5021
|
-
)), h && n.interpretNumericEntities && c === "iso-8859-1" && (h =
|
|
5022
|
-
var v =
|
|
5035
|
+
)), h && n.interpretNumericEntities && c === "iso-8859-1" && (h = pc(h)), u.indexOf("[]=") > -1 && (h = dc(h) ? [h] : h);
|
|
5036
|
+
var v = Wt.call(a, m);
|
|
5023
5037
|
v && n.duplicates === "combine" ? a[m] = Ie.combine(a[m], h) : (!v || n.duplicates === "last") && (a[m] = h);
|
|
5024
5038
|
}
|
|
5025
5039
|
return a;
|
|
5026
|
-
},
|
|
5040
|
+
}, yc = function(e, t, n, a) {
|
|
5027
5041
|
for (var s = a ? t : ua(t, n), i = e.length - 1; i >= 0; --i) {
|
|
5028
5042
|
var r, o = e[i];
|
|
5029
5043
|
if (o === "[]" && n.parseArrays)
|
|
5030
|
-
r = n.allowEmptyArrays && s === "" ? [] : [].concat(s);
|
|
5044
|
+
r = n.allowEmptyArrays && (s === "" || n.strictNullHandling && s === null) ? [] : [].concat(s);
|
|
5031
5045
|
else {
|
|
5032
5046
|
r = n.plainObjects ? /* @__PURE__ */ Object.create(null) : {};
|
|
5033
5047
|
var l = o.charAt(0) === "[" && o.charAt(o.length - 1) === "]" ? o.slice(1, -1) : o, c = n.decodeDotInKeys ? l.replace(/%2E/g, ".") : l, u = parseInt(c, 10);
|
|
@@ -5036,24 +5050,29 @@ var aa = _e, Le = Zs, Cl = ul, Pl = Ge, Ye = aa("%WeakMap%", !0), Xe = aa("%Map%
|
|
|
5036
5050
|
s = r;
|
|
5037
5051
|
}
|
|
5038
5052
|
return s;
|
|
5039
|
-
},
|
|
5053
|
+
}, vc = function(t, n, a, s) {
|
|
5040
5054
|
if (t) {
|
|
5041
5055
|
var i = a.allowDots ? t.replace(/\.([^.[]+)/g, "[$1]") : t, r = /(\[[^[\]]*])/, o = /(\[[^[\]]*])/g, l = a.depth > 0 && r.exec(i), c = l ? i.slice(0, l.index) : i, u = [];
|
|
5042
5056
|
if (c) {
|
|
5043
|
-
if (!a.plainObjects &&
|
|
5057
|
+
if (!a.plainObjects && Wt.call(Object.prototype, c) && !a.allowPrototypes)
|
|
5044
5058
|
return;
|
|
5045
5059
|
u.push(c);
|
|
5046
5060
|
}
|
|
5047
5061
|
for (var f = 0; a.depth > 0 && (l = o.exec(i)) !== null && f < a.depth; ) {
|
|
5048
|
-
if (f += 1, !a.plainObjects &&
|
|
5062
|
+
if (f += 1, !a.plainObjects && Wt.call(Object.prototype, l[1].slice(1, -1)) && !a.allowPrototypes)
|
|
5049
5063
|
return;
|
|
5050
5064
|
u.push(l[1]);
|
|
5051
5065
|
}
|
|
5052
|
-
|
|
5066
|
+
if (l) {
|
|
5067
|
+
if (a.strictDepth === !0)
|
|
5068
|
+
throw new RangeError("Input depth exceeded depth option of " + a.depth + " and strictDepth is true");
|
|
5069
|
+
u.push("[" + i.slice(l.index) + "]");
|
|
5070
|
+
}
|
|
5071
|
+
return yc(u, n, a, s);
|
|
5053
5072
|
}
|
|
5054
|
-
},
|
|
5073
|
+
}, gc = function(t) {
|
|
5055
5074
|
if (!t)
|
|
5056
|
-
return
|
|
5075
|
+
return H;
|
|
5057
5076
|
if (typeof t.allowEmptyArrays < "u" && typeof t.allowEmptyArrays != "boolean")
|
|
5058
5077
|
throw new TypeError("`allowEmptyArrays` option can only be `true` or `false`, when provided");
|
|
5059
5078
|
if (typeof t.decodeDotInKeys < "u" && typeof t.decodeDotInKeys != "boolean")
|
|
@@ -5062,50 +5081,51 @@ var aa = _e, Le = Zs, Cl = ul, Pl = Ge, Ye = aa("%WeakMap%", !0), Xe = aa("%Map%
|
|
|
5062
5081
|
throw new TypeError("Decoder has to be a function.");
|
|
5063
5082
|
if (typeof t.charset < "u" && t.charset !== "utf-8" && t.charset !== "iso-8859-1")
|
|
5064
5083
|
throw new TypeError("The charset option must be either utf-8, iso-8859-1, or undefined");
|
|
5065
|
-
var n = typeof t.charset > "u" ?
|
|
5084
|
+
var n = typeof t.charset > "u" ? H.charset : t.charset, a = typeof t.duplicates > "u" ? H.duplicates : t.duplicates;
|
|
5066
5085
|
if (a !== "combine" && a !== "first" && a !== "last")
|
|
5067
5086
|
throw new TypeError("The duplicates option must be either combine, first, or last");
|
|
5068
|
-
var s = typeof t.allowDots > "u" ? t.decodeDotInKeys === !0 ? !0 :
|
|
5087
|
+
var s = typeof t.allowDots > "u" ? t.decodeDotInKeys === !0 ? !0 : H.allowDots : !!t.allowDots;
|
|
5069
5088
|
return {
|
|
5070
5089
|
allowDots: s,
|
|
5071
|
-
allowEmptyArrays: typeof t.allowEmptyArrays == "boolean" ? !!t.allowEmptyArrays :
|
|
5072
|
-
allowPrototypes: typeof t.allowPrototypes == "boolean" ? t.allowPrototypes :
|
|
5073
|
-
allowSparse: typeof t.allowSparse == "boolean" ? t.allowSparse :
|
|
5074
|
-
arrayLimit: typeof t.arrayLimit == "number" ? t.arrayLimit :
|
|
5090
|
+
allowEmptyArrays: typeof t.allowEmptyArrays == "boolean" ? !!t.allowEmptyArrays : H.allowEmptyArrays,
|
|
5091
|
+
allowPrototypes: typeof t.allowPrototypes == "boolean" ? t.allowPrototypes : H.allowPrototypes,
|
|
5092
|
+
allowSparse: typeof t.allowSparse == "boolean" ? t.allowSparse : H.allowSparse,
|
|
5093
|
+
arrayLimit: typeof t.arrayLimit == "number" ? t.arrayLimit : H.arrayLimit,
|
|
5075
5094
|
charset: n,
|
|
5076
|
-
charsetSentinel: typeof t.charsetSentinel == "boolean" ? t.charsetSentinel :
|
|
5077
|
-
comma: typeof t.comma == "boolean" ? t.comma :
|
|
5078
|
-
decodeDotInKeys: typeof t.decodeDotInKeys == "boolean" ? t.decodeDotInKeys :
|
|
5079
|
-
decoder: typeof t.decoder == "function" ? t.decoder :
|
|
5080
|
-
delimiter: typeof t.delimiter == "string" || Ie.isRegExp(t.delimiter) ? t.delimiter :
|
|
5095
|
+
charsetSentinel: typeof t.charsetSentinel == "boolean" ? t.charsetSentinel : H.charsetSentinel,
|
|
5096
|
+
comma: typeof t.comma == "boolean" ? t.comma : H.comma,
|
|
5097
|
+
decodeDotInKeys: typeof t.decodeDotInKeys == "boolean" ? t.decodeDotInKeys : H.decodeDotInKeys,
|
|
5098
|
+
decoder: typeof t.decoder == "function" ? t.decoder : H.decoder,
|
|
5099
|
+
delimiter: typeof t.delimiter == "string" || Ie.isRegExp(t.delimiter) ? t.delimiter : H.delimiter,
|
|
5081
5100
|
// eslint-disable-next-line no-implicit-coercion, no-extra-parens
|
|
5082
|
-
depth: typeof t.depth == "number" || t.depth === !1 ? +t.depth :
|
|
5101
|
+
depth: typeof t.depth == "number" || t.depth === !1 ? +t.depth : H.depth,
|
|
5083
5102
|
duplicates: a,
|
|
5084
5103
|
ignoreQueryPrefix: t.ignoreQueryPrefix === !0,
|
|
5085
|
-
interpretNumericEntities: typeof t.interpretNumericEntities == "boolean" ? t.interpretNumericEntities :
|
|
5086
|
-
parameterLimit: typeof t.parameterLimit == "number" ? t.parameterLimit :
|
|
5104
|
+
interpretNumericEntities: typeof t.interpretNumericEntities == "boolean" ? t.interpretNumericEntities : H.interpretNumericEntities,
|
|
5105
|
+
parameterLimit: typeof t.parameterLimit == "number" ? t.parameterLimit : H.parameterLimit,
|
|
5087
5106
|
parseArrays: t.parseArrays !== !1,
|
|
5088
|
-
plainObjects: typeof t.plainObjects == "boolean" ? t.plainObjects :
|
|
5089
|
-
|
|
5107
|
+
plainObjects: typeof t.plainObjects == "boolean" ? t.plainObjects : H.plainObjects,
|
|
5108
|
+
strictDepth: typeof t.strictDepth == "boolean" ? !!t.strictDepth : H.strictDepth,
|
|
5109
|
+
strictNullHandling: typeof t.strictNullHandling == "boolean" ? t.strictNullHandling : H.strictNullHandling
|
|
5090
5110
|
};
|
|
5091
|
-
},
|
|
5092
|
-
var n =
|
|
5111
|
+
}, bc = function(e, t) {
|
|
5112
|
+
var n = gc(t);
|
|
5093
5113
|
if (e === "" || e === null || typeof e > "u")
|
|
5094
5114
|
return n.plainObjects ? /* @__PURE__ */ Object.create(null) : {};
|
|
5095
|
-
for (var a = typeof e == "string" ?
|
|
5096
|
-
var o = i[r], l =
|
|
5115
|
+
for (var a = typeof e == "string" ? hc(e, n) : e, s = n.plainObjects ? /* @__PURE__ */ Object.create(null) : {}, i = Object.keys(a), r = 0; r < i.length; ++r) {
|
|
5116
|
+
var o = i[r], l = vc(o, a[o], n, typeof e == "string");
|
|
5097
5117
|
s = Ie.merge(s, l, n);
|
|
5098
5118
|
}
|
|
5099
5119
|
return n.allowSparse === !0 ? s : Ie.compact(s);
|
|
5100
|
-
},
|
|
5101
|
-
formats:
|
|
5102
|
-
parse:
|
|
5103
|
-
stringify:
|
|
5104
|
-
},
|
|
5120
|
+
}, xc = uc, kc = bc, $c = pn, at = {
|
|
5121
|
+
formats: $c,
|
|
5122
|
+
parse: kc,
|
|
5123
|
+
stringify: xc
|
|
5124
|
+
}, Sc = is;
|
|
5105
5125
|
function oe() {
|
|
5106
5126
|
this.protocol = null, this.slashes = null, this.auth = null, this.host = null, this.port = null, this.hostname = null, this.hash = null, this.search = null, this.query = null, this.pathname = null, this.path = null, this.href = null;
|
|
5107
5127
|
}
|
|
5108
|
-
var
|
|
5128
|
+
var wc = /^([a-z0-9.+-]+:)/i, jc = /:[0-9]*$/, Nc = /^(\/\/?(?!\/)[^?\s]*)(\?[^\s]*)?$/, Tc = [
|
|
5109
5129
|
"<",
|
|
5110
5130
|
">",
|
|
5111
5131
|
'"',
|
|
@@ -5115,14 +5135,14 @@ var xc = /^([a-z0-9.+-]+:)/i, kc = /:[0-9]*$/, $c = /^(\/\/?(?!\/)[^?\s]*)(\?[^\
|
|
|
5115
5135
|
`
|
|
5116
5136
|
`,
|
|
5117
5137
|
" "
|
|
5118
|
-
],
|
|
5138
|
+
], Oc = [
|
|
5119
5139
|
"{",
|
|
5120
5140
|
"}",
|
|
5121
5141
|
"|",
|
|
5122
5142
|
"\\",
|
|
5123
5143
|
"^",
|
|
5124
5144
|
"`"
|
|
5125
|
-
].concat(
|
|
5145
|
+
].concat(Tc), Gt = ["'"].concat(Oc), ir = [
|
|
5126
5146
|
"%",
|
|
5127
5147
|
"/",
|
|
5128
5148
|
"?",
|
|
@@ -5132,7 +5152,7 @@ var xc = /^([a-z0-9.+-]+:)/i, kc = /:[0-9]*$/, $c = /^(\/\/?(?!\/)[^?\s]*)(\?[^\
|
|
|
5132
5152
|
"/",
|
|
5133
5153
|
"?",
|
|
5134
5154
|
"#"
|
|
5135
|
-
],
|
|
5155
|
+
], Cc = 255, sr = /^[+a-z0-9A-Z_-]{0,63}$/, Pc = /^([+a-z0-9A-Z_-]{0,63})(.*)$/, Ec = {
|
|
5136
5156
|
javascript: !0,
|
|
5137
5157
|
"javascript:": !0
|
|
5138
5158
|
}, Qt = {
|
|
@@ -5163,11 +5183,11 @@ oe.prototype.parse = function(e, t, n) {
|
|
|
5163
5183
|
i[0] = i[0].replace(r, "/"), e = i.join(s);
|
|
5164
5184
|
var o = e;
|
|
5165
5185
|
if (o = o.trim(), !n && e.split("#").length === 1) {
|
|
5166
|
-
var l =
|
|
5186
|
+
var l = Nc.exec(o);
|
|
5167
5187
|
if (l)
|
|
5168
5188
|
return this.path = o, this.href = o, this.pathname = l[1], l[2] ? (this.search = l[2], t ? this.query = Kt.parse(this.search.substr(1)) : this.query = this.search.substr(1)) : t && (this.search = "", this.query = {}), this;
|
|
5169
5189
|
}
|
|
5170
|
-
var c =
|
|
5190
|
+
var c = wc.exec(o);
|
|
5171
5191
|
if (c) {
|
|
5172
5192
|
c = c[0];
|
|
5173
5193
|
var u = c.toLowerCase();
|
|
@@ -5192,22 +5212,22 @@ oe.prototype.parse = function(e, t, n) {
|
|
|
5192
5212
|
var b = this.hostname[0] === "[" && this.hostname[this.hostname.length - 1] === "]";
|
|
5193
5213
|
if (!b)
|
|
5194
5214
|
for (var y = this.hostname.split(/\./), m = 0, x = y.length; m < x; m++) {
|
|
5195
|
-
var
|
|
5196
|
-
if (
|
|
5197
|
-
for (var S = "", j = 0, R =
|
|
5198
|
-
|
|
5215
|
+
var $ = y[m];
|
|
5216
|
+
if ($ && !$.match(sr)) {
|
|
5217
|
+
for (var S = "", j = 0, R = $.length; j < R; j++)
|
|
5218
|
+
$.charCodeAt(j) > 127 ? S += "x" : S += $[j];
|
|
5199
5219
|
if (!S.match(sr)) {
|
|
5200
|
-
var E = y.slice(0, m), A = y.slice(m + 1), M =
|
|
5220
|
+
var E = y.slice(0, m), A = y.slice(m + 1), M = $.match(Pc);
|
|
5201
5221
|
M && (E.push(M[1]), A.unshift(M[2])), A.length && (o = "/" + A.join(".") + o), this.hostname = E.join(".");
|
|
5202
5222
|
break;
|
|
5203
5223
|
}
|
|
5204
5224
|
}
|
|
5205
5225
|
}
|
|
5206
|
-
this.hostname.length >
|
|
5207
|
-
var
|
|
5208
|
-
this.host = L +
|
|
5226
|
+
this.hostname.length > Cc ? this.hostname = "" : this.hostname = this.hostname.toLowerCase(), b || (this.hostname = Sc.toASCII(this.hostname));
|
|
5227
|
+
var k = this.port ? ":" + this.port : "", L = this.hostname || "";
|
|
5228
|
+
this.host = L + k, this.href += this.host, b && (this.hostname = this.hostname.substr(1, this.hostname.length - 2), o[0] !== "/" && (o = "/" + o));
|
|
5209
5229
|
}
|
|
5210
|
-
if (!
|
|
5230
|
+
if (!Ec[u])
|
|
5211
5231
|
for (var m = 0, x = Gt.length; m < x; m++) {
|
|
5212
5232
|
var I = Gt[m];
|
|
5213
5233
|
if (o.indexOf(I) !== -1) {
|
|
@@ -5215,16 +5235,16 @@ oe.prototype.parse = function(e, t, n) {
|
|
|
5215
5235
|
z === I && (z = escape(I)), o = o.split(I).join(z);
|
|
5216
5236
|
}
|
|
5217
5237
|
}
|
|
5218
|
-
var
|
|
5219
|
-
|
|
5220
|
-
var
|
|
5221
|
-
if (
|
|
5222
|
-
var
|
|
5223
|
-
this.path =
|
|
5238
|
+
var B = o.indexOf("#");
|
|
5239
|
+
B !== -1 && (this.hash = o.substr(B), o = o.slice(0, B));
|
|
5240
|
+
var D = o.indexOf("?");
|
|
5241
|
+
if (D !== -1 ? (this.search = o.substr(D), this.query = o.substr(D + 1), t && (this.query = Kt.parse(this.query)), o = o.slice(0, D)) : t && (this.search = "", this.query = {}), o && (this.pathname = o), Ae[u] && this.hostname && !this.pathname && (this.pathname = "/"), this.pathname || this.search) {
|
|
5242
|
+
var k = this.pathname || "", _ = this.search || "";
|
|
5243
|
+
this.path = k + _;
|
|
5224
5244
|
}
|
|
5225
5245
|
return this.href = this.format(), this;
|
|
5226
5246
|
};
|
|
5227
|
-
function
|
|
5247
|
+
function Rc(e) {
|
|
5228
5248
|
return typeof e == "string" && (e = fn(e)), e instanceof oe ? e.format() : oe.prototype.format.call(e);
|
|
5229
5249
|
}
|
|
5230
5250
|
oe.prototype.format = function() {
|
|
@@ -5281,13 +5301,13 @@ oe.prototype.resolveObject = function(e) {
|
|
|
5281
5301
|
}
|
|
5282
5302
|
return n.slashes = n.slashes || e.slashes, n.href = n.format(), n;
|
|
5283
5303
|
}
|
|
5284
|
-
var h = n.pathname && n.pathname.charAt(0) === "/", v = e.host || e.pathname && e.pathname.charAt(0) === "/", g = v || h || n.host && e.pathname, b = g, y = n.pathname && n.pathname.split("/") || [], x = e.pathname && e.pathname.split("/") || [],
|
|
5285
|
-
if (
|
|
5304
|
+
var h = n.pathname && n.pathname.charAt(0) === "/", v = e.host || e.pathname && e.pathname.charAt(0) === "/", g = v || h || n.host && e.pathname, b = g, y = n.pathname && n.pathname.split("/") || [], x = e.pathname && e.pathname.split("/") || [], $ = n.protocol && !Ae[n.protocol];
|
|
5305
|
+
if ($ && (n.hostname = "", n.port = null, n.host && (y[0] === "" ? y[0] = n.host : y.unshift(n.host)), n.host = "", e.protocol && (e.hostname = null, e.port = null, e.host && (x[0] === "" ? x[0] = e.host : x.unshift(e.host)), e.host = null), g = g && (x[0] === "" || y[0] === "")), v)
|
|
5286
5306
|
n.host = e.host || e.host === "" ? e.host : n.host, n.hostname = e.hostname || e.hostname === "" ? e.hostname : n.hostname, n.search = e.search, n.query = e.query, y = x;
|
|
5287
5307
|
else if (x.length)
|
|
5288
5308
|
y || (y = []), y.pop(), y = y.concat(x), n.search = e.search, n.query = e.query;
|
|
5289
5309
|
else if (e.search != null) {
|
|
5290
|
-
if (
|
|
5310
|
+
if ($) {
|
|
5291
5311
|
n.host = y.shift(), n.hostname = n.host;
|
|
5292
5312
|
var S = n.host && n.host.indexOf("@") > 0 ? n.host.split("@") : !1;
|
|
5293
5313
|
S && (n.auth = S.shift(), n.hostname = S.shift(), n.host = n.hostname);
|
|
@@ -5303,7 +5323,7 @@ oe.prototype.resolveObject = function(e) {
|
|
|
5303
5323
|
y.unshift("..");
|
|
5304
5324
|
g && y[0] !== "" && (!y[0] || y[0].charAt(0) !== "/") && y.unshift(""), R && y.join("/").substr(-1) !== "/" && y.push("");
|
|
5305
5325
|
var M = y[0] === "" || y[0] && y[0].charAt(0) === "/";
|
|
5306
|
-
if (
|
|
5326
|
+
if ($) {
|
|
5307
5327
|
n.hostname = M ? "" : y.length ? y.shift() : "", n.host = n.hostname;
|
|
5308
5328
|
var S = n.host && n.host.indexOf("@") > 0 ? n.host.split("@") : !1;
|
|
5309
5329
|
S && (n.auth = S.shift(), n.hostname = S.shift(), n.host = n.hostname);
|
|
@@ -5311,15 +5331,15 @@ oe.prototype.resolveObject = function(e) {
|
|
|
5311
5331
|
return g = g || n.host && y.length, g && !M && y.unshift(""), y.length > 0 ? n.pathname = y.join("/") : (n.pathname = null, n.path = null), (n.pathname !== null || n.search !== null) && (n.path = (n.pathname ? n.pathname : "") + (n.search ? n.search : "")), n.auth = e.auth || n.auth, n.slashes = n.slashes || e.slashes, n.href = n.format(), n;
|
|
5312
5332
|
};
|
|
5313
5333
|
oe.prototype.parseHost = function() {
|
|
5314
|
-
var e = this.host, t =
|
|
5334
|
+
var e = this.host, t = jc.exec(e);
|
|
5315
5335
|
t && (t = t[0], t !== ":" && (this.port = t.substr(1)), e = e.substr(0, e.length - t.length)), e && (this.hostname = e);
|
|
5316
5336
|
};
|
|
5317
|
-
var
|
|
5337
|
+
var Ac = fn, lr = Rc, qc = (e) => typeof e == "object" && "log" in e && typeof e.log == "object" && "entries" in e.log && Array.isArray(e.log.entries), Fc = class {
|
|
5318
5338
|
constructor(e, t = {}) {
|
|
5319
5339
|
this.initCalled = !1, this.entries = [], this.requests = [], this.options = {}, this.options = {
|
|
5320
5340
|
harIsAlreadyEncoded: !1,
|
|
5321
5341
|
...t
|
|
5322
|
-
}, this.requests = [],
|
|
5342
|
+
}, this.requests = [], qc(e) ? this.entries = e.log.entries : this.entries = [
|
|
5323
5343
|
{
|
|
5324
5344
|
request: e
|
|
5325
5345
|
}
|
|
@@ -5379,10 +5399,10 @@ var Cc = fn, lr = Oc, Pc = (e) => typeof e == "object" && "log" in e && typeof e
|
|
|
5379
5399
|
case "multipart/alternative":
|
|
5380
5400
|
if (n.postData.text = "", n.postData.mimeType = "multipart/form-data", (f = n.postData) != null && f.params) {
|
|
5381
5401
|
const m = "---011000010111000001101001", h = `${m}--`, v = `\r
|
|
5382
|
-
`, g = (
|
|
5402
|
+
`, g = ($) => $.replace(/\n/g, "%0A").replace(/\r/g, "%0D").replace(/"/g, "%22"), b = ($) => $.replace(/\r?\n|\r/g, `\r
|
|
5383
5403
|
`), y = [`--${m}`];
|
|
5384
|
-
(d = n.postData) == null || d.params.forEach((
|
|
5385
|
-
const j =
|
|
5404
|
+
(d = n.postData) == null || d.params.forEach(($, S) => {
|
|
5405
|
+
const j = $.name, R = $.value || "", E = $.fileName || null, A = $.contentType || "application/octet-stream";
|
|
5386
5406
|
E ? (y.push(
|
|
5387
5407
|
`Content-Disposition: form-data; name="${g(b(j))}"; filename="${E}"`
|
|
5388
5408
|
), y.push(`Content-Type: ${A}`)) : y.push(`Content-Disposition: form-data; name="${g(b(j))}"`), y.push(""), y.push(b(R)), S !== n.postData.params.length - 1 && y.push(`--${m}`);
|
|
@@ -5409,7 +5429,7 @@ var Cc = fn, lr = Oc, Pc = (e) => typeof e == "object" && "log" in e && typeof e
|
|
|
5409
5429
|
const s = {
|
|
5410
5430
|
...n.allHeaders,
|
|
5411
5431
|
...n.headersObj
|
|
5412
|
-
}, i =
|
|
5432
|
+
}, i = Ac(n.url, !0, !0);
|
|
5413
5433
|
n.queryObj = {
|
|
5414
5434
|
...n.queryObj,
|
|
5415
5435
|
...i.query
|
|
@@ -5444,21 +5464,21 @@ var Cc = fn, lr = Oc, Pc = (e) => typeof e == "object" && "log" in e && typeof e
|
|
|
5444
5464
|
}
|
|
5445
5465
|
convert(e, t, n) {
|
|
5446
5466
|
this.initCalled || this.init(), !n && t && (n = t);
|
|
5447
|
-
const a =
|
|
5467
|
+
const a = as[e];
|
|
5448
5468
|
if (!a)
|
|
5449
5469
|
return !1;
|
|
5450
5470
|
const { convert: s } = a.clientsById[t || a.info.default];
|
|
5451
5471
|
return this.requests.map((r) => s(r, n));
|
|
5452
5472
|
}
|
|
5453
5473
|
};
|
|
5454
|
-
const da =
|
|
5474
|
+
const da = Aa(
|
|
5455
5475
|
void 0
|
|
5456
|
-
),
|
|
5457
|
-
const e =
|
|
5476
|
+
), pu = da.Provider, Ic = () => {
|
|
5477
|
+
const e = qa(da);
|
|
5458
5478
|
if (!e)
|
|
5459
5479
|
throw new Error("useOasConfig must be used within a OasConfigProvider");
|
|
5460
5480
|
return e.config;
|
|
5461
|
-
},
|
|
5481
|
+
}, _c = ({
|
|
5462
5482
|
server: e,
|
|
5463
5483
|
servers: t,
|
|
5464
5484
|
operation: n
|
|
@@ -5476,7 +5496,7 @@ const da = Ea(
|
|
|
5476
5496
|
isRequired: c.required ?? !1
|
|
5477
5497
|
})), i = (l = n.parameters) == null ? void 0 : l.filter((c) => c.in === "path").map((c) => ({ name: c.name }));
|
|
5478
5498
|
return /* @__PURE__ */ p.jsx(
|
|
5479
|
-
|
|
5499
|
+
Mr,
|
|
5480
5500
|
{
|
|
5481
5501
|
server: e,
|
|
5482
5502
|
servers: t,
|
|
@@ -5520,42 +5540,42 @@ const da = Ea(
|
|
|
5520
5540
|
),
|
|
5521
5541
|
children: e
|
|
5522
5542
|
}
|
|
5523
|
-
),
|
|
5524
|
-
function
|
|
5543
|
+
), Lc = (e) => typeof e == "object" && e !== null && !Array.isArray(e), Je = (e, t) => e.example !== void 0 ? e.example : e.default !== void 0 ? e.default : e.examples && Lc(e.examples) ? Object.values(e.examples)[0] : Uc(e);
|
|
5544
|
+
function Uc(e, t) {
|
|
5525
5545
|
const n = Object.entries(e.properties ?? {}).concat(
|
|
5526
5546
|
Object.entries(e.additionalProperties ?? {})
|
|
5527
5547
|
);
|
|
5528
5548
|
if (e.type === "object" && n.length > 0) {
|
|
5529
5549
|
const a = {};
|
|
5530
5550
|
return n.forEach(([s, i]) => {
|
|
5531
|
-
const r =
|
|
5551
|
+
const r = Je(i);
|
|
5532
5552
|
r !== void 0 && (a[s] = r);
|
|
5533
5553
|
}), a;
|
|
5534
5554
|
} else if (e.type === "array" && e.items) {
|
|
5535
|
-
const a =
|
|
5555
|
+
const a = Je(e.items);
|
|
5536
5556
|
return a !== void 0 ? [a] : [];
|
|
5537
5557
|
}
|
|
5538
5558
|
}
|
|
5539
|
-
const
|
|
5559
|
+
const Hc = ({ content: e }) => {
|
|
5540
5560
|
var t;
|
|
5541
5561
|
return e.length ? /* @__PURE__ */ p.jsx(p.Fragment, { children: /* @__PURE__ */ p.jsxs(mn, { children: [
|
|
5542
5562
|
/* @__PURE__ */ p.jsx(hn, { className: "text-xs flex justify-between items-center", children: /* @__PURE__ */ p.jsx("span", { className: "font-mono", children: "Request Body Example" }) }),
|
|
5543
5563
|
/* @__PURE__ */ p.jsx(yn, { className: "p-0", children: /* @__PURE__ */ p.jsx(
|
|
5544
|
-
|
|
5564
|
+
We,
|
|
5545
5565
|
{
|
|
5546
5566
|
language: "json",
|
|
5547
5567
|
noBackground: !0,
|
|
5548
5568
|
copyable: !0,
|
|
5549
5569
|
className: "text-xs max-h-[450px] p-2",
|
|
5550
5570
|
code: JSON.stringify(
|
|
5551
|
-
(t = e.at(0)) != null && t.schema ?
|
|
5571
|
+
(t = e.at(0)) != null && t.schema ? Je(e[0].schema) : "",
|
|
5552
5572
|
null,
|
|
5553
5573
|
2
|
|
5554
5574
|
)
|
|
5555
5575
|
}
|
|
5556
5576
|
) })
|
|
5557
5577
|
] }) }) : null;
|
|
5558
|
-
},
|
|
5578
|
+
}, Mc = ({
|
|
5559
5579
|
responses: e,
|
|
5560
5580
|
selectedResponse: t,
|
|
5561
5581
|
onSelectResponse: n
|
|
@@ -5589,12 +5609,12 @@ const Ic = ({ content: e }) => {
|
|
|
5589
5609
|
const i = (o = (r = s.content) == null ? void 0 : r[0]) == null ? void 0 : o.schema;
|
|
5590
5610
|
return /* @__PURE__ */ p.jsxs(nn, { value: s.statusCode, children: [
|
|
5591
5611
|
/* @__PURE__ */ p.jsx(yn, { className: "p-0", children: i ? /* @__PURE__ */ p.jsx(
|
|
5592
|
-
|
|
5612
|
+
We,
|
|
5593
5613
|
{
|
|
5594
5614
|
language: "json",
|
|
5595
5615
|
noBackground: !0,
|
|
5596
5616
|
className: "text-xs max-h-[450px] p-2",
|
|
5597
|
-
code: JSON.stringify(
|
|
5617
|
+
code: JSON.stringify(Je(i), null, 2)
|
|
5598
5618
|
}
|
|
5599
5619
|
) : /* @__PURE__ */ p.jsx("span", { className: "text-muted-foreground font-mono italic text-xs", children: "Empty Response" }) }),
|
|
5600
5620
|
/* @__PURE__ */ p.jsx(pa, { className: "flex justify-end text-xs", children: s.description })
|
|
@@ -5603,7 +5623,7 @@ const Ic = ({ content: e }) => {
|
|
|
5603
5623
|
]
|
|
5604
5624
|
}
|
|
5605
5625
|
) });
|
|
5606
|
-
},
|
|
5626
|
+
}, Bc = (e, t) => {
|
|
5607
5627
|
let n;
|
|
5608
5628
|
switch (t) {
|
|
5609
5629
|
case "shell":
|
|
@@ -5656,7 +5676,7 @@ const Ic = ({ content: e }) => {
|
|
|
5656
5676
|
}
|
|
5657
5677
|
}
|
|
5658
5678
|
`
|
|
5659
|
-
),
|
|
5679
|
+
), Vc = { suspense: !0 }, zc = {
|
|
5660
5680
|
get: me.green,
|
|
5661
5681
|
post: me.blue,
|
|
5662
5682
|
put: me.yellow,
|
|
@@ -5665,17 +5685,17 @@ const Ic = ({ content: e }) => {
|
|
|
5665
5685
|
options: me.indigo,
|
|
5666
5686
|
head: me.gray,
|
|
5667
5687
|
trace: me.gray
|
|
5668
|
-
},
|
|
5688
|
+
}, fu = ({
|
|
5669
5689
|
operation: e,
|
|
5670
5690
|
selectedResponse: t,
|
|
5671
5691
|
onSelectResponse: n
|
|
5672
5692
|
}) => {
|
|
5673
5693
|
var h, v, g;
|
|
5674
|
-
const a =
|
|
5694
|
+
const a = Ic(), [s] = di({
|
|
5675
5695
|
query: fa,
|
|
5676
5696
|
variables: a,
|
|
5677
|
-
context:
|
|
5678
|
-
}), i =
|
|
5697
|
+
context: Vc
|
|
5698
|
+
}), i = zc[e.method.toLocaleLowerCase()] ?? me.gray, [r, o] = Qa(), [, l] = mr(), c = r.get("lang") ?? "shell", u = (h = e.requestBody) == null ? void 0 : h.content, f = e.path.split("/").map((b, y, x) => {
|
|
5679
5699
|
const S = b.startsWith("{") && b.endsWith("}") || b.startsWith(":") ? b.replace(/[:{}]/g, "") : void 0;
|
|
5680
5700
|
return (
|
|
5681
5701
|
// eslint-disable-next-line react/no-array-index-key
|
|
@@ -5693,11 +5713,11 @@ const Ic = ({ content: e }) => {
|
|
|
5693
5713
|
/* @__PURE__ */ p.jsx("wbr", {})
|
|
5694
5714
|
] }, b + y)
|
|
5695
5715
|
);
|
|
5696
|
-
}), { selectedServer: d } = xr(), m =
|
|
5697
|
-
var x,
|
|
5698
|
-
const b = (x = u == null ? void 0 : u[0]) != null && x.schema ?
|
|
5716
|
+
}), { selectedServer: d } = xr(), m = Fa(() => {
|
|
5717
|
+
var x, $;
|
|
5718
|
+
const b = (x = u == null ? void 0 : u[0]) != null && x.schema ? Je(u[0].schema) : void 0, y = new Fc({
|
|
5699
5719
|
method: e.method.toLocaleUpperCase(),
|
|
5700
|
-
url: (d ?? ((
|
|
5720
|
+
url: (d ?? (($ = s.data) == null ? void 0 : $.schema.url) ?? "") + e.path.replaceAll("{", ":").replaceAll("}", ""),
|
|
5701
5721
|
postData: b ? {
|
|
5702
5722
|
text: JSON.stringify(b, null, 2),
|
|
5703
5723
|
mimeType: "application/json"
|
|
@@ -5709,7 +5729,7 @@ const Ic = ({ content: e }) => {
|
|
|
5709
5729
|
headersSize: 0,
|
|
5710
5730
|
bodySize: 0
|
|
5711
5731
|
});
|
|
5712
|
-
return
|
|
5732
|
+
return Bc(y, c);
|
|
5713
5733
|
}, [
|
|
5714
5734
|
d,
|
|
5715
5735
|
c,
|
|
@@ -5726,7 +5746,7 @@ const Ic = ({ content: e }) => {
|
|
|
5726
5746
|
f
|
|
5727
5747
|
] }),
|
|
5728
5748
|
/* @__PURE__ */ p.jsx(
|
|
5729
|
-
|
|
5749
|
+
_c,
|
|
5730
5750
|
{
|
|
5731
5751
|
server: ((v = s.data) == null ? void 0 : v.schema.url) ?? "",
|
|
5732
5752
|
servers: ((g = s.data) == null ? void 0 : g.schema.servers.map((b) => b.url)) ?? [],
|
|
@@ -5735,7 +5755,7 @@ const Ic = ({ content: e }) => {
|
|
|
5735
5755
|
)
|
|
5736
5756
|
] }),
|
|
5737
5757
|
/* @__PURE__ */ p.jsx(yn, { className: "max-h-[480px] p-0", children: /* @__PURE__ */ p.jsx(
|
|
5738
|
-
|
|
5758
|
+
We,
|
|
5739
5759
|
{
|
|
5740
5760
|
language: c,
|
|
5741
5761
|
noBackground: !0,
|
|
@@ -5746,7 +5766,7 @@ const Ic = ({ content: e }) => {
|
|
|
5746
5766
|
/* @__PURE__ */ p.jsxs(pa, { className: "flex items-center text-xs gap-2 justify-end py-1", children: [
|
|
5747
5767
|
/* @__PURE__ */ p.jsx("span", { children: "Show example in" }),
|
|
5748
5768
|
/* @__PURE__ */ p.jsx(
|
|
5749
|
-
|
|
5769
|
+
Hr,
|
|
5750
5770
|
{
|
|
5751
5771
|
className: "self-start max-w-[150px]",
|
|
5752
5772
|
value: c,
|
|
@@ -5772,9 +5792,9 @@ const Ic = ({ content: e }) => {
|
|
|
5772
5792
|
)
|
|
5773
5793
|
] })
|
|
5774
5794
|
] }),
|
|
5775
|
-
u && /* @__PURE__ */ p.jsx(
|
|
5795
|
+
u && /* @__PURE__ */ p.jsx(Hc, { content: u }),
|
|
5776
5796
|
e.responses.length > 0 && /* @__PURE__ */ p.jsx(
|
|
5777
|
-
|
|
5797
|
+
Mc,
|
|
5778
5798
|
{
|
|
5779
5799
|
selectedResponse: t,
|
|
5780
5800
|
onSelectResponse: n,
|
|
@@ -5782,7 +5802,7 @@ const Ic = ({ content: e }) => {
|
|
|
5782
5802
|
}
|
|
5783
5803
|
)
|
|
5784
5804
|
] });
|
|
5785
|
-
},
|
|
5805
|
+
}, Dc = $r(`
|
|
5786
5806
|
query GetCategories($input: JSON!, $type: SchemaType!) {
|
|
5787
5807
|
schema(input: $input, type: $type) {
|
|
5788
5808
|
tags {
|
|
@@ -5800,10 +5820,10 @@ const Ic = ({ content: e }) => {
|
|
|
5800
5820
|
}
|
|
5801
5821
|
}
|
|
5802
5822
|
}
|
|
5803
|
-
`),
|
|
5804
|
-
const e =
|
|
5805
|
-
return /* @__PURE__ */ p.jsx(
|
|
5806
|
-
},
|
|
5823
|
+
`), Jc = () => {
|
|
5824
|
+
const e = Ka(), t = e instanceof Error ? /* @__PURE__ */ p.jsx(We, { code: e.message }) : "An unknown error occurred";
|
|
5825
|
+
return /* @__PURE__ */ p.jsx(gi, { category: "Error", title: "An error occurred", message: t });
|
|
5826
|
+
}, Wc = {
|
|
5807
5827
|
get: "green",
|
|
5808
5828
|
post: "blue",
|
|
5809
5829
|
put: "yellow",
|
|
@@ -5811,11 +5831,11 @@ const Ic = ({ content: e }) => {
|
|
|
5811
5831
|
patch: "purple",
|
|
5812
5832
|
options: "gray",
|
|
5813
5833
|
head: "gray"
|
|
5814
|
-
},
|
|
5815
|
-
const t =
|
|
5834
|
+
}, mu = (e) => {
|
|
5835
|
+
const t = Ra(e.navigationId ?? "/reference"), n = e.server ? new ei({
|
|
5816
5836
|
url: e.server,
|
|
5817
|
-
exchanges: [
|
|
5818
|
-
}) :
|
|
5837
|
+
exchanges: [ti, ni]
|
|
5838
|
+
}) : ba({ useMemoryClient: e.inMemory ?? !1 });
|
|
5819
5839
|
return {
|
|
5820
5840
|
getHead: () => {
|
|
5821
5841
|
if (e.type === "url" && !e.skipPreload)
|
|
@@ -5840,7 +5860,7 @@ const Ic = ({ content: e }) => {
|
|
|
5840
5860
|
...o
|
|
5841
5861
|
}) => {
|
|
5842
5862
|
var u;
|
|
5843
|
-
const l =
|
|
5863
|
+
const l = Na(), c = ha({
|
|
5844
5864
|
queryFn: async () => (await n.query(fa, {
|
|
5845
5865
|
type: e.type,
|
|
5846
5866
|
input: e.input
|
|
@@ -5856,11 +5876,11 @@ const Ic = ({ content: e }) => {
|
|
|
5856
5876
|
onClick: l.login,
|
|
5857
5877
|
children: [
|
|
5858
5878
|
"Login to open in Playground ",
|
|
5859
|
-
/* @__PURE__ */ p.jsx(
|
|
5879
|
+
/* @__PURE__ */ p.jsx(va, { size: 16 })
|
|
5860
5880
|
]
|
|
5861
5881
|
}
|
|
5862
5882
|
) : /* @__PURE__ */ p.jsx(
|
|
5863
|
-
|
|
5883
|
+
Mr,
|
|
5864
5884
|
{
|
|
5865
5885
|
url: r ?? "/",
|
|
5866
5886
|
method: i ?? "get",
|
|
@@ -5868,16 +5888,16 @@ const Ic = ({ content: e }) => {
|
|
|
5868
5888
|
...o,
|
|
5869
5889
|
children: /* @__PURE__ */ p.jsxs(je, { className: "gap-2 items-center", variant: "outline", children: [
|
|
5870
5890
|
"Open in Playground ",
|
|
5871
|
-
/* @__PURE__ */ p.jsx(
|
|
5891
|
+
/* @__PURE__ */ p.jsx(ga, { size: 16 })
|
|
5872
5892
|
] })
|
|
5873
5893
|
}
|
|
5874
5894
|
);
|
|
5875
5895
|
}
|
|
5876
5896
|
}),
|
|
5877
5897
|
getSidebar: async (a) => {
|
|
5878
|
-
if (!
|
|
5898
|
+
if (!ri({ path: t, end: !1 }, a))
|
|
5879
5899
|
return [];
|
|
5880
|
-
const { data: s } = await n.query(
|
|
5900
|
+
const { data: s } = await n.query(Dc, {
|
|
5881
5901
|
input: e.input,
|
|
5882
5902
|
type: e.type
|
|
5883
5903
|
});
|
|
@@ -5893,7 +5913,7 @@ const Ic = ({ content: e }) => {
|
|
|
5893
5913
|
href: `#${o.slug}`,
|
|
5894
5914
|
badge: {
|
|
5895
5915
|
label: o.method,
|
|
5896
|
-
color:
|
|
5916
|
+
color: Wc[o.method.toLowerCase()]
|
|
5897
5917
|
}
|
|
5898
5918
|
}))
|
|
5899
5919
|
}));
|
|
@@ -5906,12 +5926,12 @@ const Ic = ({ content: e }) => {
|
|
|
5906
5926
|
getRoutes: () => [
|
|
5907
5927
|
{
|
|
5908
5928
|
async lazy() {
|
|
5909
|
-
const { OpenApiRoute: a } = await import("./Route-
|
|
5929
|
+
const { OpenApiRoute: a } = await import("./Route-DI0Y0pIV.js");
|
|
5910
5930
|
return {
|
|
5911
5931
|
element: /* @__PURE__ */ p.jsx(a, { client: n, config: e })
|
|
5912
5932
|
};
|
|
5913
5933
|
},
|
|
5914
|
-
errorElement: /* @__PURE__ */ p.jsx(
|
|
5934
|
+
errorElement: /* @__PURE__ */ p.jsx(Jc, {}),
|
|
5915
5935
|
children: [
|
|
5916
5936
|
{
|
|
5917
5937
|
path: t,
|
|
@@ -5919,7 +5939,7 @@ const Ic = ({ content: e }) => {
|
|
|
5919
5939
|
{
|
|
5920
5940
|
index: !0,
|
|
5921
5941
|
async lazy() {
|
|
5922
|
-
const { OperationList: a } = await import("./OperationList-
|
|
5942
|
+
const { OperationList: a } = await import("./OperationList-Cd3lue0b.js");
|
|
5923
5943
|
return { element: /* @__PURE__ */ p.jsx(a, {}) };
|
|
5924
5944
|
}
|
|
5925
5945
|
}
|
|
@@ -5932,21 +5952,22 @@ const Ic = ({ content: e }) => {
|
|
|
5932
5952
|
};
|
|
5933
5953
|
export {
|
|
5934
5954
|
rn as C,
|
|
5935
|
-
|
|
5936
|
-
|
|
5955
|
+
gi as E,
|
|
5956
|
+
pu as O,
|
|
5957
|
+
Hr as S,
|
|
5937
5958
|
wn as T,
|
|
5938
|
-
|
|
5959
|
+
Ic as a,
|
|
5939
5960
|
ot as b,
|
|
5940
5961
|
Nr as c,
|
|
5941
5962
|
Tr as d,
|
|
5942
5963
|
Or as e,
|
|
5943
|
-
|
|
5964
|
+
uu as f,
|
|
5944
5965
|
$r as g,
|
|
5945
5966
|
Lt as h,
|
|
5946
5967
|
Oe as i,
|
|
5947
5968
|
Ce as j,
|
|
5948
|
-
|
|
5949
|
-
|
|
5950
|
-
|
|
5969
|
+
fu as k,
|
|
5970
|
+
mu as o,
|
|
5971
|
+
di as u
|
|
5951
5972
|
};
|
|
5952
|
-
//# sourceMappingURL=index-
|
|
5973
|
+
//# sourceMappingURL=index-Bs9roz8y.js.map
|