zudoku 0.35.5 → 0.36.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/app/entry.server.js +5 -1
- package/dist/app/entry.server.js.map +1 -1
- package/dist/config/validators/common.d.ts +176 -176
- package/dist/config/validators/common.js +8 -6
- package/dist/config/validators/common.js.map +1 -1
- package/dist/config/validators/validate.d.ts +63 -63
- package/dist/lib/authentication/providers/openid.js +11 -7
- package/dist/lib/authentication/providers/openid.js.map +1 -1
- package/dist/lib/components/AnchorLink.js +3 -2
- package/dist/lib/components/AnchorLink.js.map +1 -1
- package/dist/lib/components/Layout.js +3 -14
- package/dist/lib/components/Layout.js.map +1 -1
- package/dist/lib/components/Zudoku.js +3 -1
- package/dist/lib/components/Zudoku.js.map +1 -1
- package/dist/lib/components/cache.d.ts +7 -0
- package/dist/lib/components/cache.js +7 -0
- package/dist/lib/components/cache.js.map +1 -1
- package/dist/lib/components/context/ViewportAnchorContext.js +3 -6
- package/dist/lib/components/context/ViewportAnchorContext.js.map +1 -1
- package/dist/lib/components/context/ZudokuContext.d.ts +1 -1
- package/dist/lib/components/context/ZudokuContext.js +4 -3
- package/dist/lib/components/context/ZudokuContext.js.map +1 -1
- package/dist/lib/components/navigation/SidebarItem.js +3 -2
- package/dist/lib/components/navigation/SidebarItem.js.map +1 -1
- package/dist/lib/core/ZudokuContext.d.ts +8 -6
- package/dist/lib/core/ZudokuContext.js +4 -2
- package/dist/lib/core/ZudokuContext.js.map +1 -1
- package/dist/lib/core/plugins.d.ts +3 -3
- package/dist/lib/hooks/useEvent.test.js +1 -1
- package/dist/lib/hooks/useEvent.test.js.map +1 -1
- package/dist/lib/oas/graphql/index.d.ts +16 -4
- package/dist/lib/oas/graphql/index.js +59 -43
- package/dist/lib/oas/graphql/index.js.map +1 -1
- package/dist/lib/plugins/openapi/OperationList.js +19 -5
- package/dist/lib/plugins/openapi/OperationList.js.map +1 -1
- package/dist/lib/plugins/openapi/OperationListItem.js +1 -1
- package/dist/lib/plugins/openapi/OperationListItem.js.map +1 -1
- package/dist/lib/plugins/openapi/Sidecar.js +2 -2
- package/dist/lib/plugins/openapi/Sidecar.js.map +1 -1
- package/dist/lib/plugins/openapi/client/useCreateQuery.d.ts +1 -1
- package/dist/lib/plugins/openapi/client/useCreateQuery.js +2 -1
- package/dist/lib/plugins/openapi/client/useCreateQuery.js.map +1 -1
- package/dist/lib/plugins/openapi/graphql/gql.d.ts +4 -4
- package/dist/lib/plugins/openapi/graphql/gql.js +3 -3
- package/dist/lib/plugins/openapi/graphql/gql.js.map +1 -1
- package/dist/lib/plugins/openapi/graphql/graphql.d.ts +34 -45
- package/dist/lib/plugins/openapi/graphql/graphql.js +20 -30
- package/dist/lib/plugins/openapi/graphql/graphql.js.map +1 -1
- package/dist/lib/plugins/openapi/index.d.ts +5 -10
- package/dist/lib/plugins/openapi/index.js +29 -60
- package/dist/lib/plugins/openapi/index.js.map +1 -1
- package/dist/lib/plugins/openapi/interfaces.d.ts +3 -1
- package/dist/lib/plugins/openapi/util/createSidebarCategory.js +5 -7
- package/dist/lib/plugins/openapi/util/createSidebarCategory.js.map +1 -1
- package/dist/lib/util/traverse.js +2 -2
- package/dist/lib/util/traverse.js.map +1 -1
- package/dist/lib/util/useScrollToAnchor.js +2 -0
- package/dist/lib/util/useScrollToAnchor.js.map +1 -1
- package/dist/vite/api/schema-codegen.js +19 -4
- package/dist/vite/api/schema-codegen.js.map +1 -1
- package/dist/vite/api/schema-codegen.test.js +61 -0
- package/dist/vite/api/schema-codegen.test.js.map +1 -1
- package/dist/vite/plugin-api.js +3 -11
- package/dist/vite/plugin-api.js.map +1 -1
- package/lib/{AuthenticationPlugin-4ip08maU.js → AuthenticationPlugin-Cr6xjOJD.js} +2 -2
- package/lib/{AuthenticationPlugin-4ip08maU.js.map → AuthenticationPlugin-Cr6xjOJD.js.map} +1 -1
- package/lib/{Markdown-hBN9vkm5.js → Markdown-BlioIqkZ.js} +313 -311
- package/lib/Markdown-BlioIqkZ.js.map +1 -0
- package/lib/{MdxPage-UCWwxhzC.js → MdxPage-7XnN9J9R.js} +3 -3
- package/lib/{MdxPage-UCWwxhzC.js.map → MdxPage-7XnN9J9R.js.map} +1 -1
- package/lib/{OasProvider-CJ8KOnsH.js → OasProvider-BaRRMSsD.js} +3 -3
- package/lib/{OasProvider-CJ8KOnsH.js.map → OasProvider-BaRRMSsD.js.map} +1 -1
- package/lib/{OperationList-C4rpJdcE.js → OperationList-BjL1hzSx.js} +988 -961
- package/lib/OperationList-BjL1hzSx.js.map +1 -0
- package/lib/{SlotletProvider-D-XPr1Wg.js → SlotletProvider-CXb3wQiR.js} +2 -2
- package/lib/{SlotletProvider-D-XPr1Wg.js.map → SlotletProvider-CXb3wQiR.js.map} +1 -1
- package/lib/{circular-v7K6lDDh.js → circular-ByJI6Mci.js} +4887 -4419
- package/lib/circular-ByJI6Mci.js.map +1 -0
- package/lib/{createServer-BEFAOb-x.js → createServer-DjgKDpGV.js} +3887 -4291
- package/lib/createServer-DjgKDpGV.js.map +1 -0
- package/lib/{hook-CfCFKZ-2.js → hook-Bo80UX00.js} +75 -74
- package/lib/hook-Bo80UX00.js.map +1 -0
- package/lib/{index-Dowg8c_k.js → index-D5m8_oyY.js} +612 -650
- package/lib/index-D5m8_oyY.js.map +1 -0
- package/lib/post-processors/traverse.js +2 -2
- package/lib/post-processors/traverse.js.map +1 -1
- package/lib/zudoku.auth-auth0.js +1 -1
- package/lib/zudoku.auth-clerk.js +2 -2
- package/lib/zudoku.auth-openid.js +283 -282
- package/lib/zudoku.auth-openid.js.map +1 -1
- package/lib/zudoku.components.js +395 -397
- package/lib/zudoku.components.js.map +1 -1
- package/lib/zudoku.hooks.js +1 -1
- package/lib/zudoku.plugin-api-catalog.js +2 -2
- package/lib/zudoku.plugin-api-keys.js +2 -2
- package/lib/zudoku.plugin-custom-pages.js +1 -1
- package/lib/zudoku.plugin-markdown.js +1 -1
- package/lib/zudoku.plugin-openapi.js +4 -5
- package/lib/zudoku.plugin-openapi.js.map +1 -1
- package/lib/zudoku.plugins.js.map +1 -1
- package/package.json +5 -5
- package/src/app/entry.server.tsx +7 -1
- package/src/lib/authentication/providers/openid.tsx +12 -9
- package/src/lib/components/AnchorLink.tsx +4 -2
- package/src/lib/components/Layout.tsx +3 -16
- package/src/lib/components/Zudoku.tsx +5 -1
- package/src/lib/components/cache.ts +8 -0
- package/src/lib/components/context/ViewportAnchorContext.tsx +3 -6
- package/src/lib/components/context/ZudokuContext.ts +5 -4
- package/src/lib/components/navigation/SidebarItem.tsx +3 -2
- package/src/lib/core/ZudokuContext.ts +11 -8
- package/src/lib/core/plugins.ts +4 -4
- package/src/lib/hooks/useEvent.test.tsx +1 -1
- package/src/lib/oas/graphql/index.ts +116 -76
- package/src/lib/plugins/openapi/OperationList.tsx +31 -37
- package/src/lib/plugins/openapi/OperationListItem.tsx +1 -1
- package/src/lib/plugins/openapi/Sidecar.tsx +2 -2
- package/src/lib/plugins/openapi/client/useCreateQuery.ts +2 -1
- package/src/lib/plugins/openapi/graphql/gql.ts +17 -17
- package/src/lib/plugins/openapi/graphql/graphql.ts +62 -79
- package/src/lib/plugins/openapi/index.tsx +40 -84
- package/src/lib/plugins/openapi/interfaces.ts +4 -1
- package/src/lib/plugins/openapi/util/createSidebarCategory.tsx +5 -7
- package/src/lib/util/traverse.ts +2 -2
- package/src/lib/util/useScrollToAnchor.ts +2 -0
- package/lib/Markdown-hBN9vkm5.js.map +0 -1
- package/lib/OperationList-C4rpJdcE.js.map +0 -1
- package/lib/circular-v7K6lDDh.js.map +0 -1
- package/lib/createServer-BEFAOb-x.js.map +0 -1
- package/lib/hook-CfCFKZ-2.js.map +0 -1
- package/lib/index-Dowg8c_k.js.map +0 -1
|
@@ -1,64 +1,64 @@
|
|
|
1
|
-
var
|
|
2
|
-
var
|
|
1
|
+
var Dt = Object.defineProperty;
|
|
2
|
+
var et = (t) => {
|
|
3
3
|
throw TypeError(t);
|
|
4
4
|
};
|
|
5
|
-
var
|
|
6
|
-
var
|
|
7
|
-
var
|
|
5
|
+
var Vt = (t, s, n) => s in t ? Dt(t, s, { enumerable: !0, configurable: !0, writable: !0, value: n }) : t[s] = n;
|
|
6
|
+
var G = (t, s, n) => Vt(t, typeof s != "symbol" ? s + "" : s, n), Ft = (t, s, n) => s.has(t) || et("Cannot " + n);
|
|
7
|
+
var ue = (t, s, n) => (Ft(t, s, "read from private field"), n ? n.call(t) : s.get(t)), pe = (t, s, n) => s.has(t) ? et("Cannot add the same private member more than once") : s instanceof WeakSet ? s.add(t) : s.set(t, n);
|
|
8
8
|
import { j as e } from "./jsx-runtime-CYK1ROHF.js";
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
11
|
-
import {
|
|
12
|
-
import {
|
|
13
|
-
import {
|
|
14
|
-
import {
|
|
15
|
-
import {
|
|
16
|
-
import { VisuallyHidden as ns } from "@radix-ui/react-visually-hidden";
|
|
9
|
+
import { ChevronRightIcon as U, CheckIcon as zt, DotIcon as Ht, Check as Mt, XIcon as Bt, Circle as _t, ChevronDownIcon as Gt, InfoIcon as tt, LogInIcon as Jt, CirclePlayIcon as Ut } from "lucide-react";
|
|
10
|
+
import { r as Qt, m as st } from "./chunk-HA7DTUK3-ZGg2W6yV.js";
|
|
11
|
+
import { h as Wt, p as Zt, i as Xt, k as Kt, l as Yt, e as es } from "./hook-Bo80UX00.js";
|
|
12
|
+
import { Button as Q } from "./ui/Button.js";
|
|
13
|
+
import { j as A } from "./joinUrl-10po2Jdj.js";
|
|
14
|
+
import { Z as ts } from "./invariant-Caa8-XvF.js";
|
|
15
|
+
import { VisuallyHidden as ss } from "@radix-ui/react-visually-hidden";
|
|
17
16
|
import * as y from "react";
|
|
18
|
-
import { Fragment as O, useRef as
|
|
19
|
-
import { D as ke, a as
|
|
20
|
-
import { S as
|
|
21
|
-
import { b as
|
|
22
|
-
import { c as
|
|
23
|
-
import { c as
|
|
24
|
-
import { Tabs as
|
|
25
|
-
import { u as
|
|
26
|
-
import { z as
|
|
27
|
-
import { B as L, S as
|
|
28
|
-
import * as
|
|
29
|
-
import * as
|
|
30
|
-
import * as
|
|
31
|
-
import { PopoverAnchor as
|
|
32
|
-
import { T as
|
|
33
|
-
import { g as
|
|
34
|
-
import { Input as
|
|
35
|
-
import { Slot as
|
|
36
|
-
import * as
|
|
37
|
-
import * as
|
|
38
|
-
import { Callout as
|
|
39
|
-
import { Card as
|
|
40
|
-
import { Collapsible as
|
|
41
|
-
import { d as
|
|
42
|
-
import * as
|
|
43
|
-
import { S as
|
|
44
|
-
|
|
45
|
-
|
|
17
|
+
import { Fragment as O, useRef as B, useEffect as ne, useState as k, useCallback as ns, useTransition as as } from "react";
|
|
18
|
+
import { D as ke, a as Ie, b as Re, d as xt, e as ft, f as rs } from "./Dialog-sbgekbjb.js";
|
|
19
|
+
import { S as je, a as ve, b as be, c as Ne, e as J, u as os } from "./Select-FAYHOYTy.js";
|
|
20
|
+
import { b as Oe, u as qe, C as q, a as is, F as ls } from "./index.esm--gIChbWs.js";
|
|
21
|
+
import { c as gt } from "./index-CPNSgwSb.js";
|
|
22
|
+
import { c as u } from "./cn-qaFjX9_3.js";
|
|
23
|
+
import { Tabs as yt, TabsList as jt, TabsTrigger as F, TabsContent as z } from "./ui/Tabs.js";
|
|
24
|
+
import { u as ds, o as cs } from "./objectEntries-BS7aAgOm.js";
|
|
25
|
+
import { z as ms } from "./index-DwT-v3zK.js";
|
|
26
|
+
import { B as L, S as us } from "./Spinner-C6n4eOvh.js";
|
|
27
|
+
import * as v from "@radix-ui/react-dropdown-menu";
|
|
28
|
+
import * as we from "@radix-ui/react-checkbox";
|
|
29
|
+
import * as ae from "@radix-ui/react-popover";
|
|
30
|
+
import { PopoverAnchor as ps } from "@radix-ui/react-popover";
|
|
31
|
+
import { T as hs } from "./index-gQD2h1wX.js";
|
|
32
|
+
import { g as xs, h as fs, C as gs, b as ys, f as js } from "./Callout-B2vsR09t.js";
|
|
33
|
+
import { Input as Le } from "./ui/Input.js";
|
|
34
|
+
import { Slot as vs } from "@radix-ui/react-slot";
|
|
35
|
+
import * as vt from "@radix-ui/react-label";
|
|
36
|
+
import * as W from "@radix-ui/react-radio-group";
|
|
37
|
+
import { Callout as bs } from "./ui/Callout.js";
|
|
38
|
+
import { Card as bt, CardHeader as Ns, CardTitle as ws, CardContent as Cs } from "./ui/Card.js";
|
|
39
|
+
import { Collapsible as nt, CollapsibleTrigger as at, CollapsibleContent as rt } from "./ui/Collapsible.js";
|
|
40
|
+
import { d as Ss } from "./useQuery-CQUwWR9i.js";
|
|
41
|
+
import * as Ae from "@radix-ui/react-collapsible";
|
|
42
|
+
import { S as Ts } from "./SyntaxHighlight-BEoSoPEo.js";
|
|
43
|
+
import { s as ot } from "./index-LNp6rxyU.js";
|
|
44
|
+
let he;
|
|
45
|
+
const $s = (t) => {
|
|
46
46
|
var s;
|
|
47
47
|
if ((s = t.errors) != null && s[0])
|
|
48
|
-
throw new
|
|
48
|
+
throw new ts(t.errors[0].message, {
|
|
49
49
|
developerHint: "Check your configuration value `apis.type` and `apis.input` in the Zudoku config."
|
|
50
50
|
});
|
|
51
51
|
};
|
|
52
|
-
var
|
|
53
|
-
class
|
|
52
|
+
var ie, le;
|
|
53
|
+
class Ps {
|
|
54
54
|
constructor(s) {
|
|
55
|
-
|
|
55
|
+
pe(this, ie, async () => (he || (he = import("./createServer-DjgKDpGV.js").then(
|
|
56
56
|
(s) => s.createServer(this.config)
|
|
57
|
-
)),
|
|
58
|
-
|
|
59
|
-
|
|
57
|
+
)), he));
|
|
58
|
+
pe(this, le, async (s) => this.config.server ? fetch(this.config.server, s) : (await ue(this, ie).call(this)).fetch("http://localhost/graphql", s));
|
|
59
|
+
G(this, "fetch", async (s, ...[n]) => {
|
|
60
60
|
var l;
|
|
61
|
-
const a = (l = s.match(/query (\w+)/)) == null ? void 0 : l[1], r = await
|
|
61
|
+
const a = (l = s.match(/query (\w+)/)) == null ? void 0 : l[1], r = await ue(this, le).call(this, {
|
|
62
62
|
method: "POST",
|
|
63
63
|
body: JSON.stringify({ query: s, variables: n, operationName: a }),
|
|
64
64
|
headers: { "Content-Type": "application/json" }
|
|
@@ -66,23 +66,25 @@ class Is {
|
|
|
66
66
|
if (!r.ok)
|
|
67
67
|
throw new Error("Network response was not ok");
|
|
68
68
|
const i = await r.json();
|
|
69
|
-
return
|
|
69
|
+
return $s(i), i.data;
|
|
70
70
|
});
|
|
71
71
|
this.config = s;
|
|
72
72
|
}
|
|
73
73
|
}
|
|
74
|
-
|
|
75
|
-
class
|
|
74
|
+
ie = new WeakMap(), le = new WeakMap();
|
|
75
|
+
class _ extends String {
|
|
76
76
|
constructor(n, a) {
|
|
77
77
|
super(n);
|
|
78
|
-
|
|
78
|
+
G(this, "__apiType");
|
|
79
|
+
G(this, "value");
|
|
80
|
+
G(this, "__meta__");
|
|
79
81
|
this.value = n, this.__meta__ = a;
|
|
80
82
|
}
|
|
81
83
|
toString() {
|
|
82
84
|
return this.value;
|
|
83
85
|
}
|
|
84
86
|
}
|
|
85
|
-
const
|
|
87
|
+
const ks = new _(
|
|
86
88
|
`
|
|
87
89
|
fragment OperationsFragment on OperationItem {
|
|
88
90
|
slug
|
|
@@ -150,7 +152,7 @@ const Rs = new J(
|
|
|
150
152
|
}
|
|
151
153
|
`,
|
|
152
154
|
{ fragmentName: "OperationsFragment" }
|
|
153
|
-
),
|
|
155
|
+
), Is = new _(`
|
|
154
156
|
query ServersQuery($input: JSON!, $type: SchemaType!) {
|
|
155
157
|
schema(input: $input, type: $type) {
|
|
156
158
|
url
|
|
@@ -159,8 +161,14 @@ const Rs = new J(
|
|
|
159
161
|
}
|
|
160
162
|
}
|
|
161
163
|
}
|
|
162
|
-
`),
|
|
163
|
-
query
|
|
164
|
+
`), Rs = new _(`
|
|
165
|
+
query SchemaWarmup($input: JSON!, $type: SchemaType!) {
|
|
166
|
+
schema(input: $input, type: $type) {
|
|
167
|
+
openapi
|
|
168
|
+
}
|
|
169
|
+
}
|
|
170
|
+
`), Os = new _(`
|
|
171
|
+
query OperationsForTag($input: JSON!, $type: SchemaType!, $tag: String, $untagged: Boolean) {
|
|
164
172
|
schema(input: $input, type: $type) {
|
|
165
173
|
servers {
|
|
166
174
|
url
|
|
@@ -243,7 +251,7 @@ const Rs = new J(
|
|
|
243
251
|
schema
|
|
244
252
|
}
|
|
245
253
|
}
|
|
246
|
-
}`),
|
|
254
|
+
}`), qs = new _(`
|
|
247
255
|
query getServerQuery($input: JSON!, $type: SchemaType!) {
|
|
248
256
|
schema(input: $input, type: $type) {
|
|
249
257
|
url
|
|
@@ -252,51 +260,35 @@ const Rs = new J(
|
|
|
252
260
|
}
|
|
253
261
|
}
|
|
254
262
|
}
|
|
255
|
-
`), Ls = new
|
|
256
|
-
query
|
|
263
|
+
`), Ls = new _(`
|
|
264
|
+
query GetSidebarOperations($input: JSON!, $type: SchemaType!) {
|
|
257
265
|
schema(input: $input, type: $type) {
|
|
258
|
-
url
|
|
259
266
|
tags {
|
|
260
|
-
name
|
|
261
|
-
}
|
|
262
|
-
}
|
|
263
|
-
}
|
|
264
|
-
`), qs = new J(`
|
|
265
|
-
query GetOperations($input: JSON!, $type: SchemaType!, $tag: String) {
|
|
266
|
-
schema(input: $input, type: $type) {
|
|
267
|
-
operations(tag: $tag) {
|
|
268
267
|
slug
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
268
|
+
name
|
|
269
|
+
extensions
|
|
270
|
+
operations {
|
|
271
|
+
summary
|
|
272
|
+
slug
|
|
273
|
+
method
|
|
274
|
+
operationId
|
|
275
|
+
path
|
|
276
276
|
}
|
|
277
277
|
}
|
|
278
|
-
untagged: operations(untagged: true) {
|
|
279
|
-
slug
|
|
280
|
-
deprecated
|
|
281
|
-
method
|
|
282
|
-
summary
|
|
283
|
-
operationId
|
|
284
|
-
path
|
|
285
|
-
}
|
|
286
278
|
}
|
|
287
279
|
}
|
|
288
|
-
`),
|
|
289
|
-
"\n query ServersQuery($input: JSON!, $type: SchemaType!) {\n schema(input: $input, type: $type) {\n url\n servers {\n url\n }\n }\n }\n":
|
|
290
|
-
"\n fragment OperationsFragment on OperationItem {\n slug\n summary\n method\n description\n operationId\n contentTypes\n path\n deprecated\n extensions\n parameters {\n name\n in\n description\n required\n schema\n style\n explode\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 examples {\n name\n description\n externalValue\n value\n summary\n }\n schema\n }\n description\n required\n }\n responses {\n statusCode\n links\n description\n content {\n examples {\n name\n description\n externalValue\n value\n summary\n }\n mediaType\n encoding {\n name\n }\n schema\n }\n }\n }\n":
|
|
291
|
-
"\n query
|
|
292
|
-
"\n query
|
|
293
|
-
"\n query
|
|
294
|
-
"\n query
|
|
280
|
+
`), As = {
|
|
281
|
+
"\n query ServersQuery($input: JSON!, $type: SchemaType!) {\n schema(input: $input, type: $type) {\n url\n servers {\n url\n }\n }\n }\n": Is,
|
|
282
|
+
"\n fragment OperationsFragment on OperationItem {\n slug\n summary\n method\n description\n operationId\n contentTypes\n path\n deprecated\n extensions\n parameters {\n name\n in\n description\n required\n schema\n style\n explode\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 examples {\n name\n description\n externalValue\n value\n summary\n }\n schema\n }\n description\n required\n }\n responses {\n statusCode\n links\n description\n content {\n examples {\n name\n description\n externalValue\n value\n summary\n }\n mediaType\n encoding {\n name\n }\n schema\n }\n }\n }\n": ks,
|
|
283
|
+
"\n query SchemaWarmup($input: JSON!, $type: SchemaType!) {\n schema(input: $input, type: $type) {\n openapi\n }\n }\n": Rs,
|
|
284
|
+
"\n query OperationsForTag(\n $input: JSON!\n $type: SchemaType!\n $tag: String\n $untagged: Boolean\n ) {\n schema(input: $input, type: $type) {\n servers {\n url\n }\n description\n summary\n title\n url\n version\n tags(name: $tag) {\n name\n description\n }\n operations(tag: $tag, untagged: $untagged) {\n slug\n ...OperationsFragment\n }\n }\n }\n": Os,
|
|
285
|
+
"\n query getServerQuery($input: JSON!, $type: SchemaType!) {\n schema(input: $input, type: $type) {\n url\n servers {\n url\n }\n }\n }\n": qs,
|
|
286
|
+
"\n query GetSidebarOperations($input: JSON!, $type: SchemaType!) {\n schema(input: $input, type: $type) {\n tags {\n slug\n name\n extensions\n operations {\n summary\n slug\n method\n operationId\n path\n }\n }\n }\n }\n": Ls
|
|
295
287
|
};
|
|
296
|
-
function
|
|
297
|
-
return
|
|
288
|
+
function Es(t) {
|
|
289
|
+
return As[t] ?? {};
|
|
298
290
|
}
|
|
299
|
-
const
|
|
291
|
+
const Ds = gt(
|
|
300
292
|
"relative w-full rounded-lg border p-4 [&>svg~*]:pl-7 [&>svg+div]:translate-y-[-3px] [&>svg]:absolute [&>svg]:left-4 [&>svg]:top-4 [&>svg]:text-foreground",
|
|
301
293
|
{
|
|
302
294
|
variants: {
|
|
@@ -309,34 +301,34 @@ const Es = yt(
|
|
|
309
301
|
variant: "default"
|
|
310
302
|
}
|
|
311
303
|
}
|
|
312
|
-
),
|
|
304
|
+
), Ce = y.forwardRef(({ className: t, variant: s, ...n }, a) => /* @__PURE__ */ e.jsx(
|
|
313
305
|
"div",
|
|
314
306
|
{
|
|
315
307
|
ref: a,
|
|
316
308
|
role: "alert",
|
|
317
|
-
className:
|
|
309
|
+
className: u(Ds({ variant: s }), t),
|
|
318
310
|
...n
|
|
319
311
|
}
|
|
320
312
|
));
|
|
321
|
-
|
|
322
|
-
const
|
|
313
|
+
Ce.displayName = "Alert";
|
|
314
|
+
const Se = y.forwardRef(({ className: t, ...s }, n) => /* @__PURE__ */ e.jsx(
|
|
323
315
|
"h5",
|
|
324
316
|
{
|
|
325
317
|
ref: n,
|
|
326
|
-
className:
|
|
318
|
+
className: u("mb-1 font-medium leading-none tracking-tight", t),
|
|
327
319
|
...s
|
|
328
320
|
}
|
|
329
321
|
));
|
|
330
|
-
|
|
331
|
-
const
|
|
322
|
+
Se.displayName = "AlertTitle";
|
|
323
|
+
const Te = y.forwardRef(({ className: t, ...s }, n) => /* @__PURE__ */ e.jsx(
|
|
332
324
|
"div",
|
|
333
325
|
{
|
|
334
326
|
ref: n,
|
|
335
|
-
className:
|
|
327
|
+
className: u("text-sm [&_p]:leading-relaxed", t),
|
|
336
328
|
...s
|
|
337
329
|
}
|
|
338
330
|
));
|
|
339
|
-
|
|
331
|
+
Te.displayName = "AlertDescription";
|
|
340
332
|
const Vs = ({
|
|
341
333
|
path: t,
|
|
342
334
|
renderParam: s
|
|
@@ -345,15 +337,15 @@ const Vs = ({
|
|
|
345
337
|
return t.split("/").map((a, r, i) => {
|
|
346
338
|
const l = Array.from(a.matchAll(/{([^}]+)}/g)), m = [];
|
|
347
339
|
let d = 0;
|
|
348
|
-
return l.forEach((
|
|
349
|
-
const [
|
|
340
|
+
return l.forEach((h) => {
|
|
341
|
+
const [x, w] = h;
|
|
350
342
|
if (!w) return;
|
|
351
|
-
const
|
|
352
|
-
|
|
353
|
-
/* @__PURE__ */ e.jsx(O, { children: a.slice(d,
|
|
343
|
+
const j = h.index;
|
|
344
|
+
j > d && m.push(
|
|
345
|
+
/* @__PURE__ */ e.jsx(O, { children: a.slice(d, j) }, `text-${d}-${j}`)
|
|
354
346
|
), m.push(
|
|
355
|
-
/* @__PURE__ */ e.jsx(O, { children: s({ name: w, originalValue:
|
|
356
|
-
), d =
|
|
347
|
+
/* @__PURE__ */ e.jsx(O, { children: s({ name: w, originalValue: x, index: n++ }) }, `param-${w}`)
|
|
348
|
+
), d = j + x.length;
|
|
357
349
|
}), d < a.length && m.push(
|
|
358
350
|
/* @__PURE__ */ e.jsx(O, { children: a.slice(d) }, `text-${d}-${a.length}`)
|
|
359
351
|
), // eslint-disable-next-line react/no-array-index-key
|
|
@@ -363,11 +355,11 @@ const Vs = ({
|
|
|
363
355
|
/* @__PURE__ */ e.jsx("wbr", {})
|
|
364
356
|
] }, `${a}-${r}`);
|
|
365
357
|
});
|
|
366
|
-
},
|
|
358
|
+
}, Nt = y.forwardRef(
|
|
367
359
|
({ className: t, ...s }, n) => /* @__PURE__ */ e.jsx(
|
|
368
360
|
"textarea",
|
|
369
361
|
{
|
|
370
|
-
className:
|
|
362
|
+
className: u(
|
|
371
363
|
"flex min-h-[80px] w-full rounded-md border border-input bg-background px-3 py-2 text-base ring-offset-background placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 md:text-sm",
|
|
372
364
|
t
|
|
373
365
|
),
|
|
@@ -376,25 +368,25 @@ const Vs = ({
|
|
|
376
368
|
}
|
|
377
369
|
)
|
|
378
370
|
);
|
|
379
|
-
|
|
380
|
-
const
|
|
371
|
+
Nt.displayName = "Textarea";
|
|
372
|
+
const xe = (t) => Math.abs(
|
|
381
373
|
isNaN(parseInt(t)) ? t.toLowerCase().charCodeAt(0) - 96 : isNaN(parseInt(t)) ? 0 : parseInt(t)
|
|
382
|
-
),
|
|
383
|
-
const n = (3 *
|
|
374
|
+
), fe = (t) => t.length > 1 ? parseInt(t.split("").reduce((s, n) => `${xe(s) + xe(n)}`)) : xe(t), it = (t, s = {}) => {
|
|
375
|
+
const n = (3 * fe(t) + 2 * fe(t) + fe(t)) % 360, { saturation: a = 75, lightness: r = 60 } = s;
|
|
384
376
|
return `${n}deg ${a}% ${r}%`;
|
|
385
|
-
},
|
|
386
|
-
const { resolvedTheme: s } =
|
|
377
|
+
}, ge = "data-linked-param", Fs = (t) => {
|
|
378
|
+
const { resolvedTheme: s } = ms();
|
|
387
379
|
return {
|
|
388
|
-
text:
|
|
380
|
+
text: it(
|
|
389
381
|
t,
|
|
390
382
|
s === "light" ? { saturation: 95, lightness: 38 } : {}
|
|
391
383
|
),
|
|
392
|
-
background:
|
|
384
|
+
background: it(
|
|
393
385
|
t,
|
|
394
386
|
s === "light" ? { saturation: 85, lightness: 40 } : {}
|
|
395
387
|
)
|
|
396
388
|
};
|
|
397
|
-
},
|
|
389
|
+
}, wt = ({
|
|
398
390
|
name: t,
|
|
399
391
|
className: s,
|
|
400
392
|
slug: n,
|
|
@@ -402,26 +394,26 @@ const ye = (t) => Math.abs(
|
|
|
402
394
|
children: r,
|
|
403
395
|
onClick: i
|
|
404
396
|
}) => {
|
|
405
|
-
const l =
|
|
406
|
-
return
|
|
397
|
+
const l = B(null), m = n == null ? void 0 : n.replace(/[{}]/g, ""), d = t.replace(/[{}]/g, ""), { text: h, background: x } = Fs(d), w = `hsl(${h} / 100%)`, j = `hsl(${x} / 10%)`, p = `hsl(${x} / 50%)`;
|
|
398
|
+
return ne(() => {
|
|
407
399
|
if (!m || !l.current) return;
|
|
408
|
-
const
|
|
409
|
-
document.querySelectorAll(`[${
|
|
410
|
-
|
|
400
|
+
const f = () => {
|
|
401
|
+
document.querySelectorAll(`[${ge}="${m}"]`).forEach((b) => {
|
|
402
|
+
b instanceof HTMLElement && (b.dataset.active = "true");
|
|
411
403
|
});
|
|
412
|
-
},
|
|
413
|
-
document.querySelectorAll(`[${
|
|
414
|
-
|
|
404
|
+
}, c = () => {
|
|
405
|
+
document.querySelectorAll(`[${ge}="${m}"]`).forEach((b) => {
|
|
406
|
+
b instanceof HTMLElement && (b.dataset.active = "false");
|
|
415
407
|
});
|
|
416
|
-
},
|
|
417
|
-
return
|
|
418
|
-
|
|
408
|
+
}, g = l.current;
|
|
409
|
+
return g.addEventListener("mouseenter", f), g.addEventListener("mouseleave", c), () => {
|
|
410
|
+
g.removeEventListener("mouseenter", f), g.removeEventListener("mouseleave", c);
|
|
419
411
|
};
|
|
420
412
|
}, [m]), /* @__PURE__ */ e.jsx(
|
|
421
413
|
"span",
|
|
422
414
|
{
|
|
423
|
-
[
|
|
424
|
-
className:
|
|
415
|
+
[ge]: m,
|
|
416
|
+
className: u(
|
|
425
417
|
// This may not contain (inline-)flex or (inline-)block otherwise it breaks the browser's full text search
|
|
426
418
|
"relative rounded transition-all duration-100 rounded-lg",
|
|
427
419
|
"border border-[--border-color] p-0.5 text-[--param-color] bg-[--background-color]",
|
|
@@ -434,8 +426,8 @@ const ye = (t) => Math.abs(
|
|
|
434
426
|
onClick: i,
|
|
435
427
|
style: {
|
|
436
428
|
"--param-color": w,
|
|
437
|
-
"--border-color":
|
|
438
|
-
"--background-color":
|
|
429
|
+
"--border-color": p,
|
|
430
|
+
"--background-color": j
|
|
439
431
|
},
|
|
440
432
|
children: r ?? t
|
|
441
433
|
}
|
|
@@ -444,7 +436,7 @@ const ye = (t) => Math.abs(
|
|
|
444
436
|
const a = s.replace(/(:\w+|\{\w+})/g, (i) => {
|
|
445
437
|
var d;
|
|
446
438
|
const l = i.replace(/[:{}]/g, "");
|
|
447
|
-
return ((d = n.pathParams.find((
|
|
439
|
+
return ((d = n.pathParams.find((h) => h.name === l)) == null ? void 0 : d.value) ?? i;
|
|
448
440
|
}), r = new URL(
|
|
449
441
|
a.replace(/^\//, ""),
|
|
450
442
|
t.endsWith("/") ? t : `${t}/`
|
|
@@ -452,11 +444,11 @@ const ye = (t) => Math.abs(
|
|
|
452
444
|
return n.queryParams.filter((i) => i.active).forEach((i) => {
|
|
453
445
|
r.searchParams.set(i.name, i.value);
|
|
454
446
|
}), r;
|
|
455
|
-
},
|
|
456
|
-
|
|
447
|
+
}, Ct = v.Root, St = v.Trigger, Hs = v.Group, Ms = y.forwardRef(({ className: t, inset: s, children: n, ...a }, r) => /* @__PURE__ */ e.jsxs(
|
|
448
|
+
v.SubTrigger,
|
|
457
449
|
{
|
|
458
450
|
ref: r,
|
|
459
|
-
className:
|
|
451
|
+
className: u(
|
|
460
452
|
"flex cursor-default select-none items-center rounded-sm px-2 py-1.5 text-sm outline-none focus:bg-accent data-[state=open]:bg-accent",
|
|
461
453
|
s && "pl-8",
|
|
462
454
|
t
|
|
@@ -464,29 +456,29 @@ const ye = (t) => Math.abs(
|
|
|
464
456
|
...a,
|
|
465
457
|
children: [
|
|
466
458
|
n,
|
|
467
|
-
/* @__PURE__ */ e.jsx(
|
|
459
|
+
/* @__PURE__ */ e.jsx(U, { className: "ml-auto h-4 w-4" })
|
|
468
460
|
]
|
|
469
461
|
}
|
|
470
462
|
));
|
|
471
|
-
Ms.displayName =
|
|
463
|
+
Ms.displayName = v.SubTrigger.displayName;
|
|
472
464
|
const Bs = y.forwardRef(({ className: t, ...s }, n) => /* @__PURE__ */ e.jsx(
|
|
473
|
-
|
|
465
|
+
v.SubContent,
|
|
474
466
|
{
|
|
475
467
|
ref: n,
|
|
476
|
-
className:
|
|
468
|
+
className: u(
|
|
477
469
|
"z-50 min-w-[8rem] overflow-hidden rounded-md border bg-popover p-1 text-popover-foreground shadow-lg data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",
|
|
478
470
|
t
|
|
479
471
|
),
|
|
480
472
|
...s
|
|
481
473
|
}
|
|
482
474
|
));
|
|
483
|
-
Bs.displayName =
|
|
484
|
-
const
|
|
485
|
-
|
|
475
|
+
Bs.displayName = v.SubContent.displayName;
|
|
476
|
+
const Ee = y.forwardRef(({ className: t, sideOffset: s = 4, ...n }, a) => /* @__PURE__ */ e.jsx(v.Portal, { children: /* @__PURE__ */ e.jsx(
|
|
477
|
+
v.Content,
|
|
486
478
|
{
|
|
487
479
|
ref: a,
|
|
488
480
|
sideOffset: s,
|
|
489
|
-
className:
|
|
481
|
+
className: u(
|
|
490
482
|
"z-50 min-w-[8rem] overflow-hidden rounded-md border bg-popover p-1 text-popover-foreground shadow-md",
|
|
491
483
|
"data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",
|
|
492
484
|
t
|
|
@@ -494,12 +486,12 @@ const Ve = y.forwardRef(({ className: t, sideOffset: s = 4, ...n }, a) => /* @__
|
|
|
494
486
|
...n
|
|
495
487
|
}
|
|
496
488
|
) }));
|
|
497
|
-
|
|
498
|
-
const
|
|
499
|
-
|
|
489
|
+
Ee.displayName = v.Content.displayName;
|
|
490
|
+
const De = y.forwardRef(({ className: t, inset: s, ...n }, a) => /* @__PURE__ */ e.jsx(
|
|
491
|
+
v.Item,
|
|
500
492
|
{
|
|
501
493
|
ref: a,
|
|
502
|
-
className:
|
|
494
|
+
className: u(
|
|
503
495
|
"relative flex cursor-default select-none items-center rounded-sm px-2 py-1.5 text-sm outline-none transition-colors focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",
|
|
504
496
|
s && "pl-8",
|
|
505
497
|
t
|
|
@@ -507,45 +499,45 @@ const Fe = y.forwardRef(({ className: t, inset: s, ...n }, a) => /* @__PURE__ */
|
|
|
507
499
|
...n
|
|
508
500
|
}
|
|
509
501
|
));
|
|
510
|
-
|
|
511
|
-
const
|
|
512
|
-
|
|
502
|
+
De.displayName = v.Item.displayName;
|
|
503
|
+
const _s = y.forwardRef(({ className: t, children: s, checked: n, ...a }, r) => /* @__PURE__ */ e.jsxs(
|
|
504
|
+
v.CheckboxItem,
|
|
513
505
|
{
|
|
514
506
|
ref: r,
|
|
515
|
-
className:
|
|
507
|
+
className: u(
|
|
516
508
|
"relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-none transition-colors focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",
|
|
517
509
|
t
|
|
518
510
|
),
|
|
519
511
|
checked: n,
|
|
520
512
|
...a,
|
|
521
513
|
children: [
|
|
522
|
-
/* @__PURE__ */ e.jsx("span", { className: "absolute left-2 flex h-3.5 w-3.5 items-center justify-center", children: /* @__PURE__ */ e.jsx(
|
|
514
|
+
/* @__PURE__ */ e.jsx("span", { className: "absolute left-2 flex h-3.5 w-3.5 items-center justify-center", children: /* @__PURE__ */ e.jsx(v.ItemIndicator, { children: /* @__PURE__ */ e.jsx(zt, { className: "h-4 w-4" }) }) }),
|
|
523
515
|
s
|
|
524
516
|
]
|
|
525
517
|
}
|
|
526
518
|
));
|
|
527
|
-
|
|
528
|
-
const
|
|
529
|
-
|
|
519
|
+
_s.displayName = v.CheckboxItem.displayName;
|
|
520
|
+
const Gs = y.forwardRef(({ className: t, children: s, ...n }, a) => /* @__PURE__ */ e.jsxs(
|
|
521
|
+
v.RadioItem,
|
|
530
522
|
{
|
|
531
523
|
ref: a,
|
|
532
|
-
className:
|
|
524
|
+
className: u(
|
|
533
525
|
"relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-none transition-colors focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",
|
|
534
526
|
t
|
|
535
527
|
),
|
|
536
528
|
...n,
|
|
537
529
|
children: [
|
|
538
|
-
/* @__PURE__ */ e.jsx("span", { className: "absolute left-2 flex h-3.5 w-3.5 items-center justify-center", children: /* @__PURE__ */ e.jsx(
|
|
530
|
+
/* @__PURE__ */ e.jsx("span", { className: "absolute left-2 flex h-3.5 w-3.5 items-center justify-center", children: /* @__PURE__ */ e.jsx(v.ItemIndicator, { children: /* @__PURE__ */ e.jsx(Ht, { className: "h-4 w-4 fill-current" }) }) }),
|
|
539
531
|
s
|
|
540
532
|
]
|
|
541
533
|
}
|
|
542
534
|
));
|
|
543
|
-
|
|
544
|
-
const
|
|
545
|
-
|
|
535
|
+
Gs.displayName = v.RadioItem.displayName;
|
|
536
|
+
const Tt = y.forwardRef(({ className: t, inset: s, ...n }, a) => /* @__PURE__ */ e.jsx(
|
|
537
|
+
v.Label,
|
|
546
538
|
{
|
|
547
539
|
ref: a,
|
|
548
|
-
className:
|
|
540
|
+
className: u(
|
|
549
541
|
"px-2 py-1.5 text-sm font-semibold",
|
|
550
542
|
s && "pl-8",
|
|
551
543
|
t
|
|
@@ -553,28 +545,28 @@ const Pt = y.forwardRef(({ className: t, inset: s, ...n }, a) => /* @__PURE__ */
|
|
|
553
545
|
...n
|
|
554
546
|
}
|
|
555
547
|
));
|
|
556
|
-
|
|
557
|
-
const
|
|
558
|
-
|
|
548
|
+
Tt.displayName = v.Label.displayName;
|
|
549
|
+
const $t = y.forwardRef(({ className: t, ...s }, n) => /* @__PURE__ */ e.jsx(
|
|
550
|
+
v.Separator,
|
|
559
551
|
{
|
|
560
552
|
ref: n,
|
|
561
|
-
className:
|
|
553
|
+
className: u("-mx-1 my-1 h-px bg-muted", t),
|
|
562
554
|
...s
|
|
563
555
|
}
|
|
564
556
|
));
|
|
565
|
-
|
|
566
|
-
const
|
|
557
|
+
$t.displayName = v.Separator.displayName;
|
|
558
|
+
const Js = ({
|
|
567
559
|
examples: t,
|
|
568
560
|
onSelect: s
|
|
569
|
-
}) => /* @__PURE__ */ e.jsxs(
|
|
570
|
-
/* @__PURE__ */ e.jsx(
|
|
571
|
-
/* @__PURE__ */ e.jsx(
|
|
561
|
+
}) => /* @__PURE__ */ e.jsxs(Ct, { children: [
|
|
562
|
+
/* @__PURE__ */ e.jsx(St, { asChild: !0, children: /* @__PURE__ */ e.jsx(L, { variant: "outline", children: "Use Example" }) }),
|
|
563
|
+
/* @__PURE__ */ e.jsx(Ee, { className: "max-w-72", children: t.map((n) => {
|
|
572
564
|
var a;
|
|
573
565
|
return /* @__PURE__ */ e.jsxs("div", { children: [
|
|
574
|
-
/* @__PURE__ */ e.jsx(
|
|
575
|
-
/* @__PURE__ */ e.jsx(
|
|
566
|
+
/* @__PURE__ */ e.jsx(Tt, { children: n.mediaType }),
|
|
567
|
+
/* @__PURE__ */ e.jsx($t, {}),
|
|
576
568
|
/* @__PURE__ */ e.jsx(Hs, { children: (a = n.examples) == null ? void 0 : a.map((r) => /* @__PURE__ */ e.jsx(
|
|
577
|
-
|
|
569
|
+
De,
|
|
578
570
|
{
|
|
579
571
|
onSelect: () => s(r, n.mediaType),
|
|
580
572
|
children: /* @__PURE__ */ e.jsx(
|
|
@@ -590,32 +582,32 @@ const Us = ({
|
|
|
590
582
|
)) })
|
|
591
583
|
] }, n.mediaType);
|
|
592
584
|
}) })
|
|
593
|
-
] }),
|
|
585
|
+
] }), Z = y.forwardRef(({ className: t, ...s }, n) => /* @__PURE__ */ e.jsx(
|
|
594
586
|
"div",
|
|
595
587
|
{
|
|
596
588
|
ref: n,
|
|
597
|
-
className:
|
|
589
|
+
className: u(
|
|
598
590
|
"rounded-xl border bg-card text-card-foreground shadow-sm",
|
|
599
591
|
t
|
|
600
592
|
),
|
|
601
593
|
...s
|
|
602
594
|
}
|
|
603
595
|
));
|
|
604
|
-
|
|
605
|
-
const
|
|
596
|
+
Z.displayName = "Card";
|
|
597
|
+
const Us = y.forwardRef(({ className: t, ...s }, n) => /* @__PURE__ */ e.jsx(
|
|
606
598
|
"div",
|
|
607
599
|
{
|
|
608
600
|
ref: n,
|
|
609
|
-
className:
|
|
601
|
+
className: u("flex flex-col space-y-1.5 p-6", t),
|
|
610
602
|
...s
|
|
611
603
|
}
|
|
612
604
|
));
|
|
613
|
-
|
|
605
|
+
Us.displayName = "CardHeader";
|
|
614
606
|
const Qs = y.forwardRef(({ className: t, ...s }, n) => /* @__PURE__ */ e.jsx(
|
|
615
607
|
"h3",
|
|
616
608
|
{
|
|
617
609
|
ref: n,
|
|
618
|
-
className:
|
|
610
|
+
className: u("font-semibold leading-none tracking-tight", t),
|
|
619
611
|
...s
|
|
620
612
|
}
|
|
621
613
|
));
|
|
@@ -624,56 +616,56 @@ const Ws = y.forwardRef(({ className: t, ...s }, n) => /* @__PURE__ */ e.jsx(
|
|
|
624
616
|
"p",
|
|
625
617
|
{
|
|
626
618
|
ref: n,
|
|
627
|
-
className:
|
|
619
|
+
className: u("text-sm text-muted-foreground", t),
|
|
628
620
|
...s
|
|
629
621
|
}
|
|
630
622
|
));
|
|
631
623
|
Ws.displayName = "CardDescription";
|
|
632
|
-
const Zs = y.forwardRef(({ className: t, ...s }, n) => /* @__PURE__ */ e.jsx("div", { ref: n, className:
|
|
624
|
+
const Zs = y.forwardRef(({ className: t, ...s }, n) => /* @__PURE__ */ e.jsx("div", { ref: n, className: u("p-6 pt-0", t), ...s }));
|
|
633
625
|
Zs.displayName = "CardContent";
|
|
634
626
|
const Xs = y.forwardRef(({ className: t, ...s }, n) => /* @__PURE__ */ e.jsx(
|
|
635
627
|
"div",
|
|
636
628
|
{
|
|
637
629
|
ref: n,
|
|
638
|
-
className:
|
|
630
|
+
className: u("flex items-center p-6 pt-0", t),
|
|
639
631
|
...s
|
|
640
632
|
}
|
|
641
633
|
));
|
|
642
634
|
Xs.displayName = "CardFooter";
|
|
643
|
-
const
|
|
644
|
-
|
|
635
|
+
const de = y.forwardRef(({ className: t, ...s }, n) => /* @__PURE__ */ e.jsx(
|
|
636
|
+
we.Root,
|
|
645
637
|
{
|
|
646
638
|
ref: n,
|
|
647
|
-
className:
|
|
639
|
+
className: u(
|
|
648
640
|
"peer h-4 w-4 shrink-0 rounded-[min(6px,var(--radius)-4px)] ring-offset-background focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 data-[state=checked]:text-primary",
|
|
649
641
|
"border border-primary data-[state=checked]:bg-primary data-[state=checked]:text-primary-foreground data-[state=checked]:border-primary",
|
|
650
642
|
t
|
|
651
643
|
),
|
|
652
644
|
...s,
|
|
653
645
|
children: /* @__PURE__ */ e.jsx(
|
|
654
|
-
|
|
646
|
+
we.Indicator,
|
|
655
647
|
{
|
|
656
|
-
className:
|
|
657
|
-
children: /* @__PURE__ */ e.jsx(
|
|
648
|
+
className: u("flex items-center justify-center text-current"),
|
|
649
|
+
children: /* @__PURE__ */ e.jsx(Mt, { className: "h-4 w-4" })
|
|
658
650
|
}
|
|
659
651
|
)
|
|
660
652
|
}
|
|
661
653
|
));
|
|
662
|
-
|
|
663
|
-
const Ks =
|
|
664
|
-
|
|
654
|
+
de.displayName = we.Root.displayName;
|
|
655
|
+
const Ks = ae.Root, Pt = y.forwardRef(({ className: t, align: s = "center", sideOffset: n = 4, ...a }, r) => /* @__PURE__ */ e.jsx(ae.Portal, { children: /* @__PURE__ */ e.jsx(
|
|
656
|
+
ae.Content,
|
|
665
657
|
{
|
|
666
658
|
ref: r,
|
|
667
659
|
align: s,
|
|
668
660
|
sideOffset: n,
|
|
669
|
-
className:
|
|
661
|
+
className: u(
|
|
670
662
|
"z-50 w-72 rounded-md border bg-popover p-4 text-popover-foreground shadow-md outline-none data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",
|
|
671
663
|
t
|
|
672
664
|
),
|
|
673
665
|
...a
|
|
674
666
|
}
|
|
675
667
|
) }));
|
|
676
|
-
|
|
668
|
+
Pt.displayName = ae.Content.displayName;
|
|
677
669
|
const Ys = ({
|
|
678
670
|
value: t,
|
|
679
671
|
options: s,
|
|
@@ -683,74 +675,74 @@ const Ys = ({
|
|
|
683
675
|
onEnterPress: i,
|
|
684
676
|
ref: l
|
|
685
677
|
}) => {
|
|
686
|
-
const [m, d] =
|
|
678
|
+
const [m, d] = k(!1), [h, x] = k(!1), w = hs((p) => p.filtered.count), j = B(null);
|
|
687
679
|
return /* @__PURE__ */ e.jsxs(Ks, { open: m, children: [
|
|
688
|
-
/* @__PURE__ */ e.jsx(
|
|
680
|
+
/* @__PURE__ */ e.jsx(ps, { children: /* @__PURE__ */ e.jsx(
|
|
689
681
|
fs,
|
|
690
682
|
{
|
|
691
|
-
ref: (
|
|
692
|
-
|
|
683
|
+
ref: (p) => {
|
|
684
|
+
j.current = p, typeof l == "function" ? l(p) : l && (l.current = p);
|
|
693
685
|
},
|
|
694
686
|
value: t,
|
|
695
687
|
placeholder: r,
|
|
696
|
-
className:
|
|
688
|
+
className: u("h-9 bg-transparent", a),
|
|
697
689
|
onFocus: () => d(!0),
|
|
698
690
|
onBlur: () => {
|
|
699
|
-
|
|
691
|
+
h || d(!1);
|
|
700
692
|
},
|
|
701
|
-
onKeyDown: (
|
|
702
|
-
var
|
|
703
|
-
|
|
693
|
+
onKeyDown: (p) => {
|
|
694
|
+
var f;
|
|
695
|
+
p.key === "Enter" && (d(!1), (f = j.current) == null || f.blur(), i == null || i(p));
|
|
704
696
|
},
|
|
705
|
-
onValueChange: (
|
|
697
|
+
onValueChange: (p) => n(p)
|
|
706
698
|
}
|
|
707
699
|
) }),
|
|
708
700
|
/* @__PURE__ */ e.jsx(
|
|
709
|
-
|
|
701
|
+
Pt,
|
|
710
702
|
{
|
|
711
|
-
onMouseEnter: () =>
|
|
712
|
-
onMouseLeave: () =>
|
|
713
|
-
onOpenAutoFocus: (
|
|
714
|
-
className:
|
|
703
|
+
onMouseEnter: () => x(!0),
|
|
704
|
+
onMouseLeave: () => x(!1),
|
|
705
|
+
onOpenAutoFocus: (p) => p.preventDefault(),
|
|
706
|
+
className: u("p-0 w-[--radix-popover-trigger-width]", {
|
|
715
707
|
"border-0": w === 0
|
|
716
708
|
}),
|
|
717
709
|
align: "start",
|
|
718
710
|
side: "bottom",
|
|
719
|
-
onWheel: (
|
|
720
|
-
|
|
711
|
+
onWheel: (p) => {
|
|
712
|
+
p.stopPropagation();
|
|
721
713
|
},
|
|
722
|
-
onTouchMove: (
|
|
723
|
-
|
|
714
|
+
onTouchMove: (p) => {
|
|
715
|
+
p.stopPropagation();
|
|
724
716
|
},
|
|
725
|
-
children: /* @__PURE__ */ e.jsx(
|
|
726
|
-
|
|
717
|
+
children: /* @__PURE__ */ e.jsx(gs, { className: "max-h-[140px]", children: s.map((p) => /* @__PURE__ */ e.jsx(
|
|
718
|
+
ys,
|
|
727
719
|
{
|
|
728
|
-
value:
|
|
729
|
-
onSelect: (
|
|
730
|
-
n(
|
|
720
|
+
value: p,
|
|
721
|
+
onSelect: (f) => {
|
|
722
|
+
n(f), d(!1);
|
|
731
723
|
},
|
|
732
724
|
className: "cursor-pointer",
|
|
733
|
-
children:
|
|
725
|
+
children: p
|
|
734
726
|
},
|
|
735
|
-
|
|
727
|
+
p
|
|
736
728
|
)) })
|
|
737
729
|
}
|
|
738
730
|
)
|
|
739
731
|
] });
|
|
740
|
-
},
|
|
732
|
+
}, re = ({ shouldFilter: t, ...s }) => /* @__PURE__ */ e.jsx(xs, { className: "bg-transparent", shouldFilter: t, children: /* @__PURE__ */ e.jsx(Ys, { ...s }) }), Ve = (t, s) => {
|
|
741
733
|
const n = y.forwardRef(({ className: a, asChild: r, ...i }, l) => {
|
|
742
|
-
const m = r ?
|
|
734
|
+
const m = r ? vs : t;
|
|
743
735
|
return y.createElement(m, {
|
|
744
736
|
...i,
|
|
745
737
|
ref: l,
|
|
746
|
-
className: typeof s == "function" ? s({ className: a }) :
|
|
738
|
+
className: typeof s == "function" ? s({ className: a }) : u(s, a)
|
|
747
739
|
});
|
|
748
740
|
});
|
|
749
741
|
return n.displayName = `VariantComponent(${t})`, n;
|
|
750
|
-
},
|
|
742
|
+
}, Fe = Ve(
|
|
751
743
|
"div",
|
|
752
744
|
"grid grid-cols-[2fr_3fr] gap-2 items-center"
|
|
753
|
-
),
|
|
745
|
+
), ze = Ve(
|
|
754
746
|
"div",
|
|
755
747
|
"group hover:bg-accent px-3 grid col-span-full grid-cols-subgrid"
|
|
756
748
|
), en = Object.freeze([
|
|
@@ -784,66 +776,66 @@ const Ys = ({
|
|
|
784
776
|
control: t,
|
|
785
777
|
headers: s
|
|
786
778
|
}) => {
|
|
787
|
-
const { fields: n, append: a, remove: r } =
|
|
779
|
+
const { fields: n, append: a, remove: r } = Oe({
|
|
788
780
|
control: t,
|
|
789
781
|
name: "headers"
|
|
790
|
-
}), { setValue: i, watch: l } = qe(), m =
|
|
782
|
+
}), { setValue: i, watch: l } = qe(), m = B([]), d = B([]), h = l("headers"), x = ns(() => {
|
|
791
783
|
a({ name: "", value: "", active: !1 });
|
|
792
784
|
}, [a]);
|
|
793
|
-
|
|
794
|
-
|
|
795
|
-
}, [
|
|
796
|
-
const w = (
|
|
797
|
-
var
|
|
798
|
-
(
|
|
799
|
-
},
|
|
800
|
-
|
|
801
|
-
var
|
|
802
|
-
return (
|
|
785
|
+
ne(() => {
|
|
786
|
+
h.length === 0 && x();
|
|
787
|
+
}, [h, x]);
|
|
788
|
+
const w = (f) => {
|
|
789
|
+
var c;
|
|
790
|
+
(c = m.current[f]) == null || c.focus();
|
|
791
|
+
}, j = (f) => {
|
|
792
|
+
x(), requestAnimationFrame(() => {
|
|
793
|
+
var c;
|
|
794
|
+
return (c = d.current[f + 1]) == null ? void 0 : c.focus();
|
|
803
795
|
});
|
|
804
|
-
},
|
|
796
|
+
}, p = s.filter((f) => !h.some((c) => c.name === f.name)).map(({ name: f }) => f);
|
|
805
797
|
return /* @__PURE__ */ e.jsxs("div", { className: "flex flex-col gap-2", children: [
|
|
806
|
-
/* @__PURE__ */ e.jsx(
|
|
807
|
-
const
|
|
808
|
-
(
|
|
798
|
+
/* @__PURE__ */ e.jsx(Z, { className: "overflow-hidden", children: /* @__PURE__ */ e.jsx(Fe, { children: n.map((f, c) => {
|
|
799
|
+
const g = s.find(
|
|
800
|
+
(b) => b.name === l(`headers.${c}.name`)
|
|
809
801
|
);
|
|
810
|
-
return /* @__PURE__ */ e.jsxs(
|
|
802
|
+
return /* @__PURE__ */ e.jsxs(ze, { children: [
|
|
811
803
|
/* @__PURE__ */ e.jsxs("div", { className: "flex items-center gap-2 ", children: [
|
|
812
804
|
/* @__PURE__ */ e.jsx(
|
|
813
|
-
|
|
805
|
+
q,
|
|
814
806
|
{
|
|
815
807
|
control: t,
|
|
816
|
-
name: `headers.${
|
|
817
|
-
render: ({ field:
|
|
818
|
-
|
|
808
|
+
name: `headers.${c}.active`,
|
|
809
|
+
render: ({ field: b }) => /* @__PURE__ */ e.jsx(
|
|
810
|
+
de,
|
|
819
811
|
{
|
|
820
|
-
id: `headers.${
|
|
821
|
-
checked:
|
|
812
|
+
id: `headers.${c}.active`,
|
|
813
|
+
checked: b.value,
|
|
822
814
|
onCheckedChange: ($) => {
|
|
823
|
-
|
|
815
|
+
b.onChange($);
|
|
824
816
|
}
|
|
825
817
|
}
|
|
826
818
|
)
|
|
827
819
|
}
|
|
828
820
|
),
|
|
829
821
|
/* @__PURE__ */ e.jsx(
|
|
830
|
-
|
|
822
|
+
q,
|
|
831
823
|
{
|
|
832
824
|
control: t,
|
|
833
|
-
name: `headers.${
|
|
834
|
-
render: ({ field:
|
|
835
|
-
|
|
825
|
+
name: `headers.${c}.name`,
|
|
826
|
+
render: ({ field: b }) => /* @__PURE__ */ e.jsx(
|
|
827
|
+
re,
|
|
836
828
|
{
|
|
837
|
-
...
|
|
829
|
+
...b,
|
|
838
830
|
placeholder: "Name",
|
|
839
831
|
className: "border-0 shadow-none bg-transparent text-xs font-mono",
|
|
840
|
-
options: [...
|
|
841
|
-
onEnterPress: () => w(
|
|
832
|
+
options: [...p, ...en],
|
|
833
|
+
onEnterPress: () => w(c),
|
|
842
834
|
onChange: ($) => {
|
|
843
|
-
|
|
835
|
+
b.onChange($), i(`headers.${c}.active`, !0);
|
|
844
836
|
},
|
|
845
837
|
ref: ($) => {
|
|
846
|
-
d.current[
|
|
838
|
+
d.current[c] = $;
|
|
847
839
|
}
|
|
848
840
|
}
|
|
849
841
|
)
|
|
@@ -852,32 +844,32 @@ const Ys = ({
|
|
|
852
844
|
] }),
|
|
853
845
|
/* @__PURE__ */ e.jsxs("div", { className: "flex items-center gap-2", children: [
|
|
854
846
|
/* @__PURE__ */ e.jsx(
|
|
855
|
-
|
|
847
|
+
q,
|
|
856
848
|
{
|
|
857
849
|
control: t,
|
|
858
|
-
name: `headers.${
|
|
859
|
-
render: ({ field:
|
|
860
|
-
|
|
850
|
+
name: `headers.${c}.value`,
|
|
851
|
+
render: ({ field: b }) => (g == null ? void 0 : g.enum) && g.enum.length > 0 ? /* @__PURE__ */ e.jsx(
|
|
852
|
+
re,
|
|
861
853
|
{
|
|
862
854
|
shouldFilter: !1,
|
|
863
|
-
value:
|
|
864
|
-
options:
|
|
855
|
+
value: b.value,
|
|
856
|
+
options: g.enum ?? [],
|
|
865
857
|
onChange: (T) => {
|
|
866
|
-
|
|
858
|
+
b.onChange(T), i(`headers.${c}.active`, !0);
|
|
867
859
|
},
|
|
868
860
|
className: "font-mono text-xs border-0"
|
|
869
861
|
}
|
|
870
862
|
) : /* @__PURE__ */ e.jsx(
|
|
871
|
-
|
|
863
|
+
Le,
|
|
872
864
|
{
|
|
873
865
|
placeholder: "Value",
|
|
874
866
|
className: "w-full border-0 shadow-none text-xs font-mono focus-visible:ring-0",
|
|
875
|
-
...
|
|
867
|
+
...b,
|
|
876
868
|
ref: (T) => {
|
|
877
|
-
m.current[
|
|
869
|
+
m.current[c] = T;
|
|
878
870
|
},
|
|
879
871
|
onKeyDown: (T) => {
|
|
880
|
-
T.key === "Enter" && T.currentTarget.value.trim() &&
|
|
872
|
+
T.key === "Enter" && T.currentTarget.value.trim() && j(c);
|
|
881
873
|
},
|
|
882
874
|
autoComplete: "off"
|
|
883
875
|
}
|
|
@@ -885,94 +877,94 @@ const Ys = ({
|
|
|
885
877
|
}
|
|
886
878
|
),
|
|
887
879
|
/* @__PURE__ */ e.jsx(
|
|
888
|
-
|
|
880
|
+
Q,
|
|
889
881
|
{
|
|
890
882
|
size: "icon",
|
|
891
883
|
variant: "ghost",
|
|
892
884
|
className: "text-muted-foreground opacity-0 group-hover:opacity-100 rounded-full w-8 h-7",
|
|
893
|
-
onClick: () => r(
|
|
885
|
+
onClick: () => r(c),
|
|
894
886
|
type: "button",
|
|
895
|
-
children: /* @__PURE__ */ e.jsx(
|
|
887
|
+
children: /* @__PURE__ */ e.jsx(Bt, { size: 16 })
|
|
896
888
|
}
|
|
897
889
|
)
|
|
898
890
|
] })
|
|
899
|
-
] },
|
|
891
|
+
] }, f.id);
|
|
900
892
|
}) }) }),
|
|
901
893
|
/* @__PURE__ */ e.jsx("div", { className: "text-end", children: /* @__PURE__ */ e.jsx(
|
|
902
|
-
|
|
894
|
+
Q,
|
|
903
895
|
{
|
|
904
896
|
className: "",
|
|
905
|
-
onClick:
|
|
897
|
+
onClick: x,
|
|
906
898
|
type: "button",
|
|
907
899
|
variant: "secondary",
|
|
908
900
|
children: "Add header"
|
|
909
901
|
}
|
|
910
902
|
) })
|
|
911
903
|
] });
|
|
912
|
-
}, sn =
|
|
904
|
+
}, sn = gt(
|
|
913
905
|
"text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70"
|
|
914
|
-
),
|
|
915
|
-
|
|
906
|
+
), H = y.forwardRef(({ className: t, ...s }, n) => /* @__PURE__ */ e.jsx(
|
|
907
|
+
vt.Root,
|
|
916
908
|
{
|
|
917
909
|
ref: n,
|
|
918
|
-
className:
|
|
910
|
+
className: u(sn(), t),
|
|
919
911
|
...s
|
|
920
912
|
}
|
|
921
913
|
));
|
|
922
|
-
|
|
923
|
-
const
|
|
924
|
-
|
|
914
|
+
H.displayName = vt.Root.displayName;
|
|
915
|
+
const He = y.forwardRef(({ className: t, ...s }, n) => /* @__PURE__ */ e.jsx(
|
|
916
|
+
W.Root,
|
|
925
917
|
{
|
|
926
|
-
className:
|
|
918
|
+
className: u("grid gap-2", t),
|
|
927
919
|
...s,
|
|
928
920
|
ref: n
|
|
929
921
|
}
|
|
930
922
|
));
|
|
931
|
-
|
|
932
|
-
const
|
|
933
|
-
|
|
923
|
+
He.displayName = W.Root.displayName;
|
|
924
|
+
const oe = y.forwardRef(({ className: t, ...s }, n) => /* @__PURE__ */ e.jsx(
|
|
925
|
+
W.Item,
|
|
934
926
|
{
|
|
935
927
|
ref: n,
|
|
936
|
-
className:
|
|
928
|
+
className: u(
|
|
937
929
|
"aspect-square h-4 w-4 rounded-full border border-primary text-primary ring-offset-background focus:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50",
|
|
938
930
|
t
|
|
939
931
|
),
|
|
940
932
|
...s,
|
|
941
|
-
children: /* @__PURE__ */ e.jsx(
|
|
933
|
+
children: /* @__PURE__ */ e.jsx(W.Indicator, { className: "flex items-center justify-center", children: /* @__PURE__ */ e.jsx(_t, { className: "h-2.5 w-2.5 fill-current text-current" }) })
|
|
942
934
|
}
|
|
943
935
|
));
|
|
944
|
-
|
|
936
|
+
oe.displayName = W.Item.displayName;
|
|
945
937
|
const kt = ({
|
|
946
938
|
identities: t,
|
|
947
939
|
setValue: s,
|
|
948
940
|
value: n
|
|
949
|
-
}) => /* @__PURE__ */ e.jsx(
|
|
950
|
-
|
|
941
|
+
}) => /* @__PURE__ */ e.jsx(Z, { className: "w-full overflow-hidden", children: /* @__PURE__ */ e.jsxs(
|
|
942
|
+
He,
|
|
951
943
|
{
|
|
952
944
|
onValueChange: (a) => s(a),
|
|
953
945
|
value: n,
|
|
954
|
-
defaultValue:
|
|
946
|
+
defaultValue: M,
|
|
955
947
|
className: "gap-0",
|
|
956
948
|
disabled: (t == null ? void 0 : t.length) === 0,
|
|
957
949
|
children: [
|
|
958
950
|
/* @__PURE__ */ e.jsxs(
|
|
959
|
-
|
|
951
|
+
H,
|
|
960
952
|
{
|
|
961
953
|
className: "h-12 border-b items-center flex p-4 cursor-pointer hover:bg-accent",
|
|
962
954
|
htmlFor: "none",
|
|
963
955
|
children: [
|
|
964
|
-
/* @__PURE__ */ e.jsx(
|
|
965
|
-
/* @__PURE__ */ e.jsx(
|
|
956
|
+
/* @__PURE__ */ e.jsx(oe, { value: M, id: "none", children: "None" }),
|
|
957
|
+
/* @__PURE__ */ e.jsx(H, { htmlFor: "none", className: "ml-2", children: "None" })
|
|
966
958
|
]
|
|
967
959
|
}
|
|
968
960
|
),
|
|
969
961
|
t == null ? void 0 : t.map((a) => /* @__PURE__ */ e.jsxs(
|
|
970
|
-
|
|
962
|
+
H,
|
|
971
963
|
{
|
|
972
964
|
className: "h-12 border-b items-center flex p-4 cursor-pointer hover:bg-accent",
|
|
973
965
|
children: [
|
|
974
|
-
/* @__PURE__ */ e.jsx(
|
|
975
|
-
/* @__PURE__ */ e.jsx(
|
|
966
|
+
/* @__PURE__ */ e.jsx(oe, { value: a.id, id: a.id, children: a.label }),
|
|
967
|
+
/* @__PURE__ */ e.jsx(H, { htmlFor: a.id, className: "ml-2", children: a.label })
|
|
976
968
|
]
|
|
977
969
|
},
|
|
978
970
|
a.id
|
|
@@ -985,10 +977,10 @@ const kt = ({
|
|
|
985
977
|
open: n,
|
|
986
978
|
onOpenChange: a
|
|
987
979
|
}) => {
|
|
988
|
-
const [r, i] =
|
|
989
|
-
return /* @__PURE__ */ e.jsx(ke, { open: n, onOpenChange: a, children: /* @__PURE__ */ e.jsxs(
|
|
990
|
-
/* @__PURE__ */ e.jsx(
|
|
991
|
-
/* @__PURE__ */ e.jsx(
|
|
980
|
+
const [r, i] = k(void 0), [l, m] = k(!1);
|
|
981
|
+
return /* @__PURE__ */ e.jsx(ke, { open: n, onOpenChange: a, children: /* @__PURE__ */ e.jsxs(Ie, { children: [
|
|
982
|
+
/* @__PURE__ */ e.jsx(Re, { children: "Select an auth identity" }),
|
|
983
|
+
/* @__PURE__ */ e.jsx(xt, { children: "Please select an identity for this request." }),
|
|
992
984
|
/* @__PURE__ */ e.jsx("div", { className: "max-h-80 overflow-auto", children: /* @__PURE__ */ e.jsx(
|
|
993
985
|
kt,
|
|
994
986
|
{
|
|
@@ -1000,7 +992,7 @@ const kt = ({
|
|
|
1000
992
|
/* @__PURE__ */ e.jsxs(ft, { className: "flex flex-col gap-2", children: [
|
|
1001
993
|
/* @__PURE__ */ e.jsxs("div", { className: "flex items-center gap-2", children: [
|
|
1002
994
|
/* @__PURE__ */ e.jsx(
|
|
1003
|
-
|
|
995
|
+
de,
|
|
1004
996
|
{
|
|
1005
997
|
id: "remember",
|
|
1006
998
|
checked: l,
|
|
@@ -1009,7 +1001,7 @@ const kt = ({
|
|
|
1009
1001
|
)
|
|
1010
1002
|
}
|
|
1011
1003
|
),
|
|
1012
|
-
/* @__PURE__ */ e.jsx(
|
|
1004
|
+
/* @__PURE__ */ e.jsx(H, { htmlFor: "remember", children: "Remember my choice" })
|
|
1013
1005
|
] }),
|
|
1014
1006
|
/* @__PURE__ */ e.jsx(
|
|
1015
1007
|
L,
|
|
@@ -1024,20 +1016,20 @@ const kt = ({
|
|
|
1024
1016
|
control: t,
|
|
1025
1017
|
url: s
|
|
1026
1018
|
}) => {
|
|
1027
|
-
const { fields: n } =
|
|
1019
|
+
const { fields: n } = Oe({
|
|
1028
1020
|
control: t,
|
|
1029
1021
|
name: "pathParams"
|
|
1030
1022
|
}), a = [...n].sort(
|
|
1031
1023
|
(r, i) => s.indexOf(`{${r.name}}`) - s.indexOf(`{${i.name}}`)
|
|
1032
1024
|
);
|
|
1033
|
-
return /* @__PURE__ */ e.jsx(
|
|
1025
|
+
return /* @__PURE__ */ e.jsx(Z, { className: "rounded-lg", children: /* @__PURE__ */ e.jsx(Fe, { children: a.map((r, i) => /* @__PURE__ */ e.jsxs(ze, { children: [
|
|
1034
1026
|
/* @__PURE__ */ e.jsx(
|
|
1035
|
-
|
|
1027
|
+
q,
|
|
1036
1028
|
{
|
|
1037
1029
|
control: t,
|
|
1038
1030
|
name: `pathParams.${i}.name`,
|
|
1039
1031
|
render: () => /* @__PURE__ */ e.jsx("div", { className: "flex items-center", children: /* @__PURE__ */ e.jsx(
|
|
1040
|
-
|
|
1032
|
+
wt,
|
|
1041
1033
|
{
|
|
1042
1034
|
slug: r.name,
|
|
1043
1035
|
name: r.name,
|
|
@@ -1047,12 +1039,12 @@ const kt = ({
|
|
|
1047
1039
|
}
|
|
1048
1040
|
),
|
|
1049
1041
|
/* @__PURE__ */ e.jsx("div", { className: "flex justify-between items-center", children: /* @__PURE__ */ e.jsx(
|
|
1050
|
-
|
|
1042
|
+
q,
|
|
1051
1043
|
{
|
|
1052
1044
|
control: t,
|
|
1053
1045
|
name: `pathParams.${i}.value`,
|
|
1054
1046
|
render: ({ field: l }) => /* @__PURE__ */ e.jsx(
|
|
1055
|
-
|
|
1047
|
+
Le,
|
|
1056
1048
|
{
|
|
1057
1049
|
...l,
|
|
1058
1050
|
required: !0,
|
|
@@ -1063,30 +1055,30 @@ const kt = ({
|
|
|
1063
1055
|
}
|
|
1064
1056
|
) })
|
|
1065
1057
|
] }, r.id)) }) });
|
|
1066
|
-
}, rn =
|
|
1058
|
+
}, rn = Ve(
|
|
1067
1059
|
"input",
|
|
1068
1060
|
"px-2 bg-transparent h-6 font-mono text-xs m-2"
|
|
1069
1061
|
), on = ({
|
|
1070
1062
|
control: t,
|
|
1071
1063
|
queryParams: s
|
|
1072
1064
|
}) => {
|
|
1073
|
-
const { fields: n } =
|
|
1065
|
+
const { fields: n } = Oe({
|
|
1074
1066
|
control: t,
|
|
1075
1067
|
name: "queryParams"
|
|
1076
1068
|
}), a = qe(), r = s.map((i) => !!i.isRequired);
|
|
1077
|
-
return /* @__PURE__ */ e.jsx(
|
|
1069
|
+
return /* @__PURE__ */ e.jsx(Z, { className: "rounded-lg", children: /* @__PURE__ */ e.jsx("div", { className: "w-full ", children: /* @__PURE__ */ e.jsx(Fe, { children: n.map((i, l) => {
|
|
1078
1070
|
const m = s.find(
|
|
1079
1071
|
(d) => d.name === a.watch(`queryParams.${l}.name`)
|
|
1080
1072
|
);
|
|
1081
|
-
return /* @__PURE__ */ e.jsxs(
|
|
1073
|
+
return /* @__PURE__ */ e.jsxs(ze, { children: [
|
|
1082
1074
|
/* @__PURE__ */ e.jsxs("div", { className: "flex items-center gap-2", children: [
|
|
1083
1075
|
/* @__PURE__ */ e.jsx(
|
|
1084
|
-
|
|
1076
|
+
q,
|
|
1085
1077
|
{
|
|
1086
1078
|
control: t,
|
|
1087
1079
|
name: `queryParams.${l}.active`,
|
|
1088
1080
|
render: ({ field: d }) => /* @__PURE__ */ e.jsx(
|
|
1089
|
-
|
|
1081
|
+
de,
|
|
1090
1082
|
{
|
|
1091
1083
|
id: `queryParams.${l}.active`,
|
|
1092
1084
|
className: "mr-2",
|
|
@@ -1097,7 +1089,7 @@ const kt = ({
|
|
|
1097
1089
|
}
|
|
1098
1090
|
),
|
|
1099
1091
|
/* @__PURE__ */ e.jsx(
|
|
1100
|
-
|
|
1092
|
+
q,
|
|
1101
1093
|
{
|
|
1102
1094
|
control: t,
|
|
1103
1095
|
render: ({ field: d }) => r[l] ? /* @__PURE__ */ e.jsx(rn, { asChild: !0, children: /* @__PURE__ */ e.jsxs(
|
|
@@ -1112,12 +1104,12 @@ const kt = ({
|
|
|
1112
1104
|
]
|
|
1113
1105
|
}
|
|
1114
1106
|
) }) : /* @__PURE__ */ e.jsx(
|
|
1115
|
-
|
|
1107
|
+
re,
|
|
1116
1108
|
{
|
|
1117
1109
|
value: d.value,
|
|
1118
|
-
options: s.map((
|
|
1119
|
-
onChange: (
|
|
1120
|
-
d.onChange(
|
|
1110
|
+
options: s.map((h) => h.name),
|
|
1111
|
+
onChange: (h) => {
|
|
1112
|
+
d.onChange(h);
|
|
1121
1113
|
},
|
|
1122
1114
|
className: "border-0 font-mono text-xs bg-transparent hover:bg-transparent"
|
|
1123
1115
|
}
|
|
@@ -1127,25 +1119,25 @@ const kt = ({
|
|
|
1127
1119
|
)
|
|
1128
1120
|
] }, i.id),
|
|
1129
1121
|
/* @__PURE__ */ e.jsx("div", { className: "flex justify-between items-center", children: /* @__PURE__ */ e.jsx(
|
|
1130
|
-
|
|
1122
|
+
q,
|
|
1131
1123
|
{
|
|
1132
1124
|
control: t,
|
|
1133
1125
|
render: ({ field: d }) => (m == null ? void 0 : m.enum) && m.enum.length > 0 ? /* @__PURE__ */ e.jsx(
|
|
1134
|
-
|
|
1126
|
+
re,
|
|
1135
1127
|
{
|
|
1136
1128
|
value: d.value,
|
|
1137
1129
|
options: m.enum ?? [],
|
|
1138
|
-
onChange: (
|
|
1139
|
-
d.onChange(
|
|
1130
|
+
onChange: (x) => {
|
|
1131
|
+
d.onChange(x), a.setValue(`queryParams.${l}.active`, !0);
|
|
1140
1132
|
},
|
|
1141
1133
|
className: "font-mono text-xs border-0 ring-1 ring-ring"
|
|
1142
1134
|
}
|
|
1143
1135
|
) : /* @__PURE__ */ e.jsx(
|
|
1144
|
-
|
|
1136
|
+
Le,
|
|
1145
1137
|
{
|
|
1146
1138
|
...d,
|
|
1147
|
-
onChange: (
|
|
1148
|
-
d.onChange(
|
|
1139
|
+
onChange: (x) => {
|
|
1140
|
+
d.onChange(x.target.value), x.target.value.length > 0 && a.setValue(`queryParams.${l}.active`, !0);
|
|
1149
1141
|
},
|
|
1150
1142
|
placeholder: "Enter value",
|
|
1151
1143
|
className: "w-full border-0 shadow-none focus-visible:ring-0 text-xs font-mono"
|
|
@@ -1156,8 +1148,8 @@ const kt = ({
|
|
|
1156
1148
|
) })
|
|
1157
1149
|
] }, i.id);
|
|
1158
1150
|
}) }) }) });
|
|
1159
|
-
}, ln =
|
|
1160
|
-
|
|
1151
|
+
}, ln = Wt()(
|
|
1152
|
+
Zt(
|
|
1161
1153
|
(t, s) => ({
|
|
1162
1154
|
rememberedIdentity: null,
|
|
1163
1155
|
setRememberedIdentity: (n) => t({ rememberedIdentity: n }),
|
|
@@ -1167,7 +1159,7 @@ const kt = ({
|
|
|
1167
1159
|
}),
|
|
1168
1160
|
{
|
|
1169
1161
|
name: "identity-storage",
|
|
1170
|
-
storage:
|
|
1162
|
+
storage: Xt(() => sessionStorage)
|
|
1171
1163
|
}
|
|
1172
1164
|
)
|
|
1173
1165
|
), dn = ({
|
|
@@ -1175,9 +1167,9 @@ const kt = ({
|
|
|
1175
1167
|
setOpen: s,
|
|
1176
1168
|
onSignUp: n,
|
|
1177
1169
|
onLogin: a
|
|
1178
|
-
}) => /* @__PURE__ */ e.jsx(ke, { open: t, onOpenChange: s, children: /* @__PURE__ */ e.jsxs(
|
|
1179
|
-
/* @__PURE__ */ e.jsx(
|
|
1180
|
-
/* @__PURE__ */ e.jsx(
|
|
1170
|
+
}) => /* @__PURE__ */ e.jsx(ke, { open: t, onOpenChange: s, children: /* @__PURE__ */ e.jsxs(Ie, { children: [
|
|
1171
|
+
/* @__PURE__ */ e.jsx(Re, { children: "Welcome to the Playground!" }),
|
|
1172
|
+
/* @__PURE__ */ e.jsx(xt, { children: "The Playground is a tool for developers to test and explore our APIs. To use the Playground, you need to login." }),
|
|
1181
1173
|
/* @__PURE__ */ e.jsxs(ft, { className: "flex gap-2 sm:justify-between", children: [
|
|
1182
1174
|
/* @__PURE__ */ e.jsx(L, { type: "button", variant: "ghost", onClick: () => s(!1), children: "Skip" }),
|
|
1183
1175
|
/* @__PURE__ */ e.jsxs("div", { className: "flex gap-2", children: [
|
|
@@ -1185,7 +1177,7 @@ const kt = ({
|
|
|
1185
1177
|
a && /* @__PURE__ */ e.jsx(L, { type: "button", variant: "default", onClick: a, children: "Login" })
|
|
1186
1178
|
] })
|
|
1187
1179
|
] })
|
|
1188
|
-
] }) }),
|
|
1180
|
+
] }) }), I = {
|
|
1189
1181
|
green: "text-green-600",
|
|
1190
1182
|
blue: "text-sky-600",
|
|
1191
1183
|
yellow: "text-yellow-600",
|
|
@@ -1194,47 +1186,47 @@ const kt = ({
|
|
|
1194
1186
|
indigo: "text-indigo-600",
|
|
1195
1187
|
gray: "text-gray-600"
|
|
1196
1188
|
}, cn = {
|
|
1197
|
-
get:
|
|
1198
|
-
post:
|
|
1199
|
-
put:
|
|
1200
|
-
delete:
|
|
1201
|
-
patch:
|
|
1202
|
-
options:
|
|
1203
|
-
head:
|
|
1204
|
-
trace:
|
|
1205
|
-
}, mn = (t) => cn[t.toLocaleLowerCase()] ??
|
|
1189
|
+
get: I.green,
|
|
1190
|
+
post: I.blue,
|
|
1191
|
+
put: I.yellow,
|
|
1192
|
+
delete: I.red,
|
|
1193
|
+
patch: I.purple,
|
|
1194
|
+
options: I.indigo,
|
|
1195
|
+
head: I.gray,
|
|
1196
|
+
trace: I.gray
|
|
1197
|
+
}, mn = (t) => cn[t.toLocaleLowerCase()] ?? I.gray, un = ({
|
|
1206
1198
|
method: t,
|
|
1207
1199
|
url: s,
|
|
1208
1200
|
headers: n,
|
|
1209
1201
|
body: a
|
|
1210
1202
|
}) => /* @__PURE__ */ e.jsxs("div", { className: "flex flex-col gap-2 font-mono text-xs", children: [
|
|
1211
1203
|
/* @__PURE__ */ e.jsxs("div", { className: "gap-2 p-2 bg-muted rounded-md", children: [
|
|
1212
|
-
/* @__PURE__ */ e.jsx("span", { className:
|
|
1204
|
+
/* @__PURE__ */ e.jsx("span", { className: u(mn(t), "font-semibold"), children: t }),
|
|
1213
1205
|
" ",
|
|
1214
1206
|
/* @__PURE__ */ e.jsx("span", { className: "break-all", children: s }),
|
|
1215
1207
|
" ",
|
|
1216
1208
|
/* @__PURE__ */ e.jsx("span", { className: "text-muted-foreground", children: "HTTP/1.1" })
|
|
1217
1209
|
] }),
|
|
1218
1210
|
/* @__PURE__ */ e.jsxs("div", { className: "mx-1.5 flex flex-col gap-3", children: [
|
|
1219
|
-
/* @__PURE__ */ e.jsxs(
|
|
1220
|
-
/* @__PURE__ */ e.jsxs(
|
|
1221
|
-
/* @__PURE__ */ e.jsx(
|
|
1211
|
+
/* @__PURE__ */ e.jsxs(nt, { defaultOpen: !0, children: [
|
|
1212
|
+
/* @__PURE__ */ e.jsxs(at, { className: "flex items-center gap-2 hover:text-primary group", children: [
|
|
1213
|
+
/* @__PURE__ */ e.jsx(U, { className: "h-4 w-4 transition-transform duration-200 group-data-[state=open]:rotate-[90deg]" }),
|
|
1222
1214
|
/* @__PURE__ */ e.jsx("span", { className: "font-semibold", children: "Headers" })
|
|
1223
1215
|
] }),
|
|
1224
|
-
/* @__PURE__ */ e.jsx(
|
|
1216
|
+
/* @__PURE__ */ e.jsx(rt, { children: /* @__PURE__ */ e.jsx("div", { className: "grid grid-cols-[auto,1fr] gap-x-8 gap-y-1 pl-1.5 pt-2", children: n.map(([r, i]) => /* @__PURE__ */ e.jsxs(O, { children: [
|
|
1225
1217
|
/* @__PURE__ */ e.jsx("div", { className: "text-primary", children: r }),
|
|
1226
1218
|
/* @__PURE__ */ e.jsx("div", { className: "break-all", children: i })
|
|
1227
1219
|
] }, r)) }) })
|
|
1228
1220
|
] }),
|
|
1229
|
-
/* @__PURE__ */ e.jsxs(
|
|
1230
|
-
/* @__PURE__ */ e.jsxs(
|
|
1231
|
-
/* @__PURE__ */ e.jsx(
|
|
1221
|
+
/* @__PURE__ */ e.jsxs(nt, { defaultOpen: !0, children: [
|
|
1222
|
+
/* @__PURE__ */ e.jsxs(at, { className: "flex items-center gap-2 hover:text-primary group", children: [
|
|
1223
|
+
/* @__PURE__ */ e.jsx(U, { className: "h-4 w-4 transition-transform duration-200 group-data-[state=open]:rotate-[90deg]" }),
|
|
1232
1224
|
/* @__PURE__ */ e.jsx("span", { className: "font-semibold", children: "Body" })
|
|
1233
1225
|
] }),
|
|
1234
|
-
/* @__PURE__ */ e.jsx(
|
|
1226
|
+
/* @__PURE__ */ e.jsx(rt, { children: /* @__PURE__ */ e.jsx("div", { className: "pl-0 pt-2", children: /* @__PURE__ */ e.jsx(
|
|
1235
1227
|
"div",
|
|
1236
1228
|
{
|
|
1237
|
-
className:
|
|
1229
|
+
className: u(
|
|
1238
1230
|
"whitespace-pre-wrap break-all bg-muted p-2 rounded-md",
|
|
1239
1231
|
!a && "text-muted-foreground"
|
|
1240
1232
|
),
|
|
@@ -1243,27 +1235,27 @@ const kt = ({
|
|
|
1243
1235
|
) }) })
|
|
1244
1236
|
] })
|
|
1245
1237
|
] })
|
|
1246
|
-
] }),
|
|
1247
|
-
function
|
|
1238
|
+
] }), lt = Ae.Root, dt = Ae.CollapsibleTrigger, ct = Ae.CollapsibleContent;
|
|
1239
|
+
function Me(t) {
|
|
1248
1240
|
if (t === null) return "null";
|
|
1249
1241
|
if (Array.isArray(t)) {
|
|
1250
1242
|
if (t.length === 0) return "any[]";
|
|
1251
1243
|
const s = t[0];
|
|
1252
|
-
return s === void 0 ? "any[]" : `${
|
|
1244
|
+
return s === void 0 ? "any[]" : `${Me(s)}[]`;
|
|
1253
1245
|
}
|
|
1254
1246
|
return typeof t == "object" ? pn(t) : typeof t;
|
|
1255
1247
|
}
|
|
1256
1248
|
function pn(t, s = "") {
|
|
1257
1249
|
const n = ["{"];
|
|
1258
1250
|
for (const [a, r] of Object.entries(t)) {
|
|
1259
|
-
const i =
|
|
1251
|
+
const i = Me(r);
|
|
1260
1252
|
n.push(` ${a}: ${i};`);
|
|
1261
1253
|
}
|
|
1262
1254
|
return n.push("}"), n.join(`
|
|
1263
1255
|
`);
|
|
1264
1256
|
}
|
|
1265
1257
|
function hn(t) {
|
|
1266
|
-
return { lines: [`type GeneratedType = ${
|
|
1258
|
+
return { lines: [`type GeneratedType = ${Me(t)};`] };
|
|
1267
1259
|
}
|
|
1268
1260
|
const xn = {
|
|
1269
1261
|
200: "OK",
|
|
@@ -1276,12 +1268,12 @@ const xn = {
|
|
|
1276
1268
|
404: "Not Found",
|
|
1277
1269
|
405: "Method Not Allowed",
|
|
1278
1270
|
500: "Internal Server Error"
|
|
1279
|
-
},
|
|
1271
|
+
}, mt = (t) => {
|
|
1280
1272
|
const s = Math.floor(Math.log(t) / Math.log(1e3));
|
|
1281
1273
|
return `${(t / Math.pow(1e3, s)).toFixed(
|
|
1282
1274
|
s ? 2 : 0
|
|
1283
1275
|
)} ${s ? `${"kMGTPEZY"[s - 1]}B` : "B"}`;
|
|
1284
|
-
},
|
|
1276
|
+
}, fn = (t) => {
|
|
1285
1277
|
var n;
|
|
1286
1278
|
return (n = Object.entries({
|
|
1287
1279
|
"application/json": "json",
|
|
@@ -1294,10 +1286,10 @@ const xn = {
|
|
|
1294
1286
|
}).find(
|
|
1295
1287
|
([a]) => t.includes(a)
|
|
1296
1288
|
)) == null ? void 0 : n[1];
|
|
1297
|
-
},
|
|
1289
|
+
}, gn = (t) => {
|
|
1298
1290
|
var n;
|
|
1299
1291
|
const s = ((n = t.find(([a, r]) => a === "Content-Type")) == null ? void 0 : n[1]) || "";
|
|
1300
|
-
return
|
|
1292
|
+
return fn(s);
|
|
1301
1293
|
}, yn = (t) => {
|
|
1302
1294
|
try {
|
|
1303
1295
|
return JSON.stringify(JSON.parse(t), null, 2);
|
|
@@ -1318,7 +1310,7 @@ const xn = {
|
|
|
1318
1310
|
const r = s.indexOf(n.toLowerCase()), i = s.indexOf(a.toLowerCase());
|
|
1319
1311
|
return r === i ? 0 : r === -1 ? 1 : i === -1 ? -1 : r - i;
|
|
1320
1312
|
});
|
|
1321
|
-
},
|
|
1313
|
+
}, ut = 64e3, vn = ({
|
|
1322
1314
|
body: t = "",
|
|
1323
1315
|
headers: s,
|
|
1324
1316
|
status: n,
|
|
@@ -1326,54 +1318,54 @@ const xn = {
|
|
|
1326
1318
|
size: r,
|
|
1327
1319
|
url: i
|
|
1328
1320
|
}) => {
|
|
1329
|
-
var
|
|
1330
|
-
const l =
|
|
1321
|
+
var f;
|
|
1322
|
+
const l = gn(s), m = yn(t), d = m || t, [h, x] = k(
|
|
1331
1323
|
m ? "formatted" : "raw"
|
|
1332
|
-
), w =
|
|
1324
|
+
), w = Ss({
|
|
1333
1325
|
queryKey: ["types", d],
|
|
1334
1326
|
queryFn: async () => hn(JSON.parse(d)),
|
|
1335
|
-
enabled:
|
|
1336
|
-
}),
|
|
1327
|
+
enabled: h === "types"
|
|
1328
|
+
}), j = jn([...s]), p = r > ut;
|
|
1337
1329
|
return /* @__PURE__ */ e.jsxs("div", { className: "flex flex-col gap-2 h-full overflow-auto max-h-[calc(100vh-220px)] ", children: [
|
|
1338
|
-
/* @__PURE__ */ e.jsxs(
|
|
1339
|
-
/* @__PURE__ */ e.jsxs(
|
|
1340
|
-
/* @__PURE__ */ e.jsx(
|
|
1330
|
+
/* @__PURE__ */ e.jsxs(lt, { defaultOpen: !0, children: [
|
|
1331
|
+
/* @__PURE__ */ e.jsxs(dt, { className: "flex items-center gap-2 hover:text-primary group", children: [
|
|
1332
|
+
/* @__PURE__ */ e.jsx(U, { className: "h-4 w-4 transition-transform duration-200 group-data-[state=open]:rotate-[90deg]" }),
|
|
1341
1333
|
/* @__PURE__ */ e.jsx("span", { className: "font-semibold", children: "Headers" })
|
|
1342
1334
|
] }),
|
|
1343
|
-
/* @__PURE__ */ e.jsx(
|
|
1344
|
-
|
|
1345
|
-
/* @__PURE__ */ e.jsx("div", { className: "text-primary whitespace-pre", children:
|
|
1346
|
-
/* @__PURE__ */ e.jsx("div", { className: "break-all", children:
|
|
1347
|
-
] },
|
|
1348
|
-
|
|
1349
|
-
/* @__PURE__ */ e.jsxs(
|
|
1350
|
-
/* @__PURE__ */ e.jsx(
|
|
1335
|
+
/* @__PURE__ */ e.jsx(ct, { children: /* @__PURE__ */ e.jsxs("div", { className: "grid grid-cols-[auto,1fr] gap-x-8 gap-y-1 pl-1.5 pt-2 font-mono text-xs", children: [
|
|
1336
|
+
j.slice(0, 5).map(([c, g]) => /* @__PURE__ */ e.jsxs(O, { children: [
|
|
1337
|
+
/* @__PURE__ */ e.jsx("div", { className: "text-primary whitespace-pre", children: c }),
|
|
1338
|
+
/* @__PURE__ */ e.jsx("div", { className: "break-all", children: g })
|
|
1339
|
+
] }, c)),
|
|
1340
|
+
j.length > 5 && /* @__PURE__ */ e.jsxs(lt, { className: "col-span-full grid-cols-subgrid grid", children: [
|
|
1341
|
+
/* @__PURE__ */ e.jsxs(dt, { className: "col-span-2 text-xs text-muted-foreground hover:text-primary flex items-center gap-1 py-1", children: [
|
|
1342
|
+
/* @__PURE__ */ e.jsx(U, { className: "h-3 w-3 transition-transform duration-200 group-data-[state=open]:rotate-[90deg]" }),
|
|
1351
1343
|
"Show ",
|
|
1352
|
-
|
|
1344
|
+
j.length - 5,
|
|
1353
1345
|
" more headers"
|
|
1354
1346
|
] }),
|
|
1355
|
-
/* @__PURE__ */ e.jsx(
|
|
1356
|
-
/* @__PURE__ */ e.jsx("div", { className: "text-primary whitespace-pre", children:
|
|
1357
|
-
/* @__PURE__ */ e.jsx("div", { className: "break-all", children:
|
|
1358
|
-
] },
|
|
1347
|
+
/* @__PURE__ */ e.jsx(ct, { className: "col-span-full grid grid-cols-subgrid gap-x-8 gap-y-1 ", children: j.slice(5).map(([c, g]) => /* @__PURE__ */ e.jsxs(O, { children: [
|
|
1348
|
+
/* @__PURE__ */ e.jsx("div", { className: "text-primary whitespace-pre", children: c }),
|
|
1349
|
+
/* @__PURE__ */ e.jsx("div", { className: "break-all", children: g })
|
|
1350
|
+
] }, c)) })
|
|
1359
1351
|
] })
|
|
1360
1352
|
] }) })
|
|
1361
1353
|
] }),
|
|
1362
|
-
/* @__PURE__ */ e.jsxs(
|
|
1363
|
-
|
|
1354
|
+
/* @__PURE__ */ e.jsxs(bt, { className: "shadow-none", children: [
|
|
1355
|
+
p && /* @__PURE__ */ e.jsxs(js, { type: "info", className: "my-0 p-2", children: [
|
|
1364
1356
|
"Code highlight is disabled for responses larger than",
|
|
1365
1357
|
" ",
|
|
1366
|
-
ut
|
|
1358
|
+
mt(ut)
|
|
1367
1359
|
] }),
|
|
1368
1360
|
/* @__PURE__ */ e.jsx(
|
|
1369
|
-
|
|
1361
|
+
Ts,
|
|
1370
1362
|
{
|
|
1371
|
-
language:
|
|
1363
|
+
language: h === "types" ? "typescript" : h === "raw" ? m ? "plain" : l : "json",
|
|
1372
1364
|
showCopy: "always",
|
|
1373
|
-
disabled:
|
|
1365
|
+
disabled: p,
|
|
1374
1366
|
noBackground: !0,
|
|
1375
1367
|
className: "overflow-x-auto p-4 text-xs max-h-[calc(83.333vh-180px)]",
|
|
1376
|
-
code: (
|
|
1368
|
+
code: (h === "raw" ? t : h === "types" ? (f = w.data) == null ? void 0 : f.lines.join(`
|
|
1377
1369
|
`) : d) ?? ""
|
|
1378
1370
|
}
|
|
1379
1371
|
)
|
|
@@ -1396,20 +1388,20 @@ const xn = {
|
|
|
1396
1388
|
/* @__PURE__ */ e.jsxs("div", { children: [
|
|
1397
1389
|
/* @__PURE__ */ e.jsx("span", { className: "text-muted-foreground", children: "Size" }),
|
|
1398
1390
|
" ",
|
|
1399
|
-
|
|
1391
|
+
mt(r)
|
|
1400
1392
|
] })
|
|
1401
1393
|
] }),
|
|
1402
1394
|
m && /* @__PURE__ */ e.jsx("div", { children: /* @__PURE__ */ e.jsxs(
|
|
1403
|
-
|
|
1395
|
+
je,
|
|
1404
1396
|
{
|
|
1405
|
-
value:
|
|
1406
|
-
onValueChange: (
|
|
1397
|
+
value: h,
|
|
1398
|
+
onValueChange: (c) => x(c),
|
|
1407
1399
|
children: [
|
|
1408
|
-
/* @__PURE__ */ e.jsx(
|
|
1409
|
-
/* @__PURE__ */ e.jsxs(
|
|
1410
|
-
/* @__PURE__ */ e.jsx(
|
|
1411
|
-
/* @__PURE__ */ e.jsx(
|
|
1412
|
-
/* @__PURE__ */ e.jsx(
|
|
1400
|
+
/* @__PURE__ */ e.jsx(ve, { className: "min-w-32", children: /* @__PURE__ */ e.jsx(be, { placeholder: "View" }) }),
|
|
1401
|
+
/* @__PURE__ */ e.jsxs(Ne, { children: [
|
|
1402
|
+
/* @__PURE__ */ e.jsx(J, { value: "formatted", children: "Formatted" }),
|
|
1403
|
+
/* @__PURE__ */ e.jsx(J, { value: "raw", children: "Raw" }),
|
|
1404
|
+
/* @__PURE__ */ e.jsx(J, { value: "types", children: "Types" })
|
|
1413
1405
|
] })
|
|
1414
1406
|
]
|
|
1415
1407
|
}
|
|
@@ -1425,24 +1417,24 @@ const xn = {
|
|
|
1425
1417
|
var i;
|
|
1426
1418
|
const r = ((((i = t.data) == null ? void 0 : i.status) ?? 0) / 100).toFixed(0);
|
|
1427
1419
|
return /* @__PURE__ */ e.jsx("div", { className: "min-w-0 p-4 bg-muted/50", children: t.error ? /* @__PURE__ */ e.jsxs("div", { className: "flex flex-col gap-2", children: [
|
|
1428
|
-
s && /* @__PURE__ */ e.jsx(
|
|
1429
|
-
/* @__PURE__ */ e.jsxs(
|
|
1430
|
-
/* @__PURE__ */ e.jsx(
|
|
1431
|
-
/* @__PURE__ */ e.jsxs(
|
|
1420
|
+
s && /* @__PURE__ */ e.jsx(bs, { type: "caution", children: "Some path parameters are missing values. Please fill them in to ensure the request is sent correctly." }),
|
|
1421
|
+
/* @__PURE__ */ e.jsxs(bt, { children: [
|
|
1422
|
+
/* @__PURE__ */ e.jsx(Ns, { children: /* @__PURE__ */ e.jsx(ws, { children: "Request failed" }) }),
|
|
1423
|
+
/* @__PURE__ */ e.jsxs(Cs, { children: [
|
|
1432
1424
|
"Error:",
|
|
1433
1425
|
" ",
|
|
1434
1426
|
t.error.message || String(t.error) || "Unexpected error"
|
|
1435
1427
|
] })
|
|
1436
1428
|
] })
|
|
1437
|
-
] }) : t.data ? /* @__PURE__ */ e.jsxs(
|
|
1438
|
-
/* @__PURE__ */ e.jsxs(
|
|
1439
|
-
/* @__PURE__ */ e.jsx(
|
|
1440
|
-
/* @__PURE__ */ e.jsxs(
|
|
1429
|
+
] }) : t.data ? /* @__PURE__ */ e.jsxs(yt, { defaultValue: "response", children: [
|
|
1430
|
+
/* @__PURE__ */ e.jsxs(jt, { children: [
|
|
1431
|
+
/* @__PURE__ */ e.jsx(F, { value: "request", children: "Request" }),
|
|
1432
|
+
/* @__PURE__ */ e.jsxs(F, { value: "response", children: [
|
|
1441
1433
|
"Response",
|
|
1442
1434
|
/* @__PURE__ */ e.jsxs(
|
|
1443
1435
|
"span",
|
|
1444
1436
|
{
|
|
1445
|
-
className:
|
|
1437
|
+
className: u(
|
|
1446
1438
|
"text-xs font-mono ml-1",
|
|
1447
1439
|
r === "2" && "text-green-500",
|
|
1448
1440
|
r === "3" && "text-blue-500",
|
|
@@ -1458,8 +1450,8 @@ const xn = {
|
|
|
1458
1450
|
)
|
|
1459
1451
|
] })
|
|
1460
1452
|
] }),
|
|
1461
|
-
/* @__PURE__ */ e.jsx(
|
|
1462
|
-
/* @__PURE__ */ e.jsx(
|
|
1453
|
+
/* @__PURE__ */ e.jsx(z, { value: "request", children: /* @__PURE__ */ e.jsx(un, { ...t.data.request }) }),
|
|
1454
|
+
/* @__PURE__ */ e.jsx(z, { value: "response", children: /* @__PURE__ */ e.jsx(
|
|
1463
1455
|
vn,
|
|
1464
1456
|
{
|
|
1465
1457
|
status: t.data.status,
|
|
@@ -1471,18 +1463,18 @@ const xn = {
|
|
|
1471
1463
|
}
|
|
1472
1464
|
) })
|
|
1473
1465
|
] }) : /* @__PURE__ */ e.jsx("div", { className: "grid place-items-center h-full", children: t.isPending ? /* @__PURE__ */ e.jsxs("div", { className: "flex flex-col gap-2 items-center mt-20", children: [
|
|
1474
|
-
/* @__PURE__ */ e.jsx(
|
|
1466
|
+
/* @__PURE__ */ e.jsx(us, { size: 20 }),
|
|
1475
1467
|
/* @__PURE__ */ e.jsxs(
|
|
1476
1468
|
"div",
|
|
1477
1469
|
{
|
|
1478
|
-
className:
|
|
1470
|
+
className: u(
|
|
1479
1471
|
"opacity-0 pointer-events-none transition-opacity h-20 text-sm text-muted-foreground duration-300 flex flex-col gap-2 items-center",
|
|
1480
1472
|
n && "opacity-100 pointer-events-auto"
|
|
1481
1473
|
),
|
|
1482
1474
|
children: [
|
|
1483
1475
|
"Looks like the request is taking longer than expected.",
|
|
1484
1476
|
/* @__PURE__ */ e.jsx(
|
|
1485
|
-
|
|
1477
|
+
Q,
|
|
1486
1478
|
{
|
|
1487
1479
|
onClick: a,
|
|
1488
1480
|
size: "sm",
|
|
@@ -1500,7 +1492,7 @@ const xn = {
|
|
|
1500
1492
|
formRef: s,
|
|
1501
1493
|
disabled: n
|
|
1502
1494
|
}) => {
|
|
1503
|
-
const { setValue: a } = qe(), [r, i] =
|
|
1495
|
+
const { setValue: a } = qe(), [r, i] = k();
|
|
1504
1496
|
return t.length === 0 ? /* @__PURE__ */ e.jsx(L, { disabled: n, children: "Send" }) : /* @__PURE__ */ e.jsxs("div", { className: "flex", children: [
|
|
1505
1497
|
/* @__PURE__ */ e.jsx(
|
|
1506
1498
|
L,
|
|
@@ -1514,19 +1506,19 @@ const xn = {
|
|
|
1514
1506
|
children: "Send"
|
|
1515
1507
|
}
|
|
1516
1508
|
),
|
|
1517
|
-
/* @__PURE__ */ e.jsxs(
|
|
1518
|
-
/* @__PURE__ */ e.jsx(
|
|
1509
|
+
/* @__PURE__ */ e.jsxs(Ct, { children: [
|
|
1510
|
+
/* @__PURE__ */ e.jsx(St, { asChild: !0, children: /* @__PURE__ */ e.jsx(
|
|
1519
1511
|
L,
|
|
1520
1512
|
{
|
|
1521
1513
|
disabled: n,
|
|
1522
1514
|
className: "rounded-l-none border-l border-border/40 inset-shadow-sm w-6",
|
|
1523
1515
|
size: "icon",
|
|
1524
|
-
children: /* @__PURE__ */ e.jsx(
|
|
1516
|
+
children: /* @__PURE__ */ e.jsx(Gt, { className: "w-4 h-4" })
|
|
1525
1517
|
}
|
|
1526
1518
|
) }),
|
|
1527
|
-
/* @__PURE__ */ e.jsx(
|
|
1519
|
+
/* @__PURE__ */ e.jsx(He, { value: r, children: /* @__PURE__ */ e.jsx(Ee, { className: "w-56", align: "end", alignOffset: -150, children: [{ id: M, label: "None" }, ...t].map(
|
|
1528
1520
|
(l) => /* @__PURE__ */ e.jsxs(
|
|
1529
|
-
|
|
1521
|
+
De,
|
|
1530
1522
|
{
|
|
1531
1523
|
onClick: () => {
|
|
1532
1524
|
var m;
|
|
@@ -1535,7 +1527,7 @@ const xn = {
|
|
|
1535
1527
|
onMouseEnter: () => i(l.id),
|
|
1536
1528
|
onMouseLeave: () => i(void 0),
|
|
1537
1529
|
children: [
|
|
1538
|
-
/* @__PURE__ */ e.jsx(
|
|
1530
|
+
/* @__PURE__ */ e.jsx(oe, { value: l.id, className: "mr-2" }),
|
|
1539
1531
|
l.label
|
|
1540
1532
|
]
|
|
1541
1533
|
},
|
|
@@ -1544,7 +1536,7 @@ const xn = {
|
|
|
1544
1536
|
) }) })
|
|
1545
1537
|
] })
|
|
1546
1538
|
] });
|
|
1547
|
-
},
|
|
1539
|
+
}, M = "__none", ye = {
|
|
1548
1540
|
Plain: "text/plain",
|
|
1549
1541
|
JSON: "application/json",
|
|
1550
1542
|
XML: "application/xml",
|
|
@@ -1560,14 +1552,14 @@ const xn = {
|
|
|
1560
1552
|
pathParams: l = [],
|
|
1561
1553
|
defaultBody: m = "",
|
|
1562
1554
|
examples: d,
|
|
1563
|
-
requiresLogin:
|
|
1564
|
-
onLogin:
|
|
1555
|
+
requiresLogin: h = !1,
|
|
1556
|
+
onLogin: x,
|
|
1565
1557
|
onSignUp: w
|
|
1566
1558
|
}) => {
|
|
1567
|
-
var
|
|
1568
|
-
const { selectedServer:
|
|
1559
|
+
var We, Ze;
|
|
1560
|
+
const { selectedServer: j, setSelectedServer: p } = Kt(
|
|
1569
1561
|
s.map((o) => ({ url: o }))
|
|
1570
|
-
), [
|
|
1562
|
+
), [f, c] = k(!1), g = Yt(), { setRememberedIdentity: b, getRememberedIdentity: $ } = ln(), [, T] = as(), [X, K] = k(!1), [Rt, Y] = k(!1), ee = B(void 0), Be = ds(b), { register: _e, control: te, handleSubmit: Ge, watch: Je, setValue: E, ...ce } = is({
|
|
1571
1563
|
defaultValues: {
|
|
1572
1564
|
body: m,
|
|
1573
1565
|
bodyContentType: "JSON",
|
|
@@ -1600,47 +1592,47 @@ const xn = {
|
|
|
1600
1592
|
}
|
|
1601
1593
|
]),
|
|
1602
1594
|
identity: $(
|
|
1603
|
-
((
|
|
1595
|
+
((We = g.data) == null ? void 0 : We.map((o) => o.id)) ?? []
|
|
1604
1596
|
)
|
|
1605
1597
|
}
|
|
1606
|
-
}), C =
|
|
1607
|
-
|
|
1608
|
-
C.identity &&
|
|
1609
|
-
}, [
|
|
1610
|
-
const
|
|
1598
|
+
}), C = Je(), Ue = B(null);
|
|
1599
|
+
ne(() => {
|
|
1600
|
+
C.identity && Be.current(C.identity);
|
|
1601
|
+
}, [Be, C.identity]);
|
|
1602
|
+
const me = os({
|
|
1611
1603
|
mutationFn: async (o) => {
|
|
1612
|
-
var
|
|
1613
|
-
const S = performance.now(),
|
|
1604
|
+
var Xe, Ke;
|
|
1605
|
+
const S = performance.now(), R = !o.headers.some(
|
|
1614
1606
|
(N) => N.active && N.name.toLowerCase() === "content-type"
|
|
1615
|
-
),
|
|
1607
|
+
), D = Object.fromEntries([
|
|
1616
1608
|
...o.headers.filter((N) => N.name && N.active).map((N) => [N.name, N.value]),
|
|
1617
|
-
...
|
|
1609
|
+
...R ? [["content-type", ye[o.bodyContentType]]] : []
|
|
1618
1610
|
]), P = new Request(
|
|
1619
|
-
zs(t ??
|
|
1611
|
+
zs(t ?? j, n, o),
|
|
1620
1612
|
{
|
|
1621
1613
|
method: a.toUpperCase(),
|
|
1622
|
-
headers:
|
|
1614
|
+
headers: D,
|
|
1623
1615
|
body: o.body ? o.body : void 0
|
|
1624
1616
|
}
|
|
1625
1617
|
);
|
|
1626
|
-
o.identity !==
|
|
1627
|
-
const
|
|
1628
|
-
() =>
|
|
1618
|
+
o.identity !== M && await ((Ke = (Xe = g.data) == null ? void 0 : Xe.find((N) => N.id === o.identity)) == null ? void 0 : Ke.authorizeRequest(P));
|
|
1619
|
+
const V = setTimeout(
|
|
1620
|
+
() => Y(!0),
|
|
1629
1621
|
3210
|
|
1630
1622
|
);
|
|
1631
|
-
|
|
1623
|
+
ee.current = new AbortController();
|
|
1632
1624
|
try {
|
|
1633
1625
|
const N = await fetch(P, {
|
|
1634
|
-
signal:
|
|
1626
|
+
signal: ee.current.signal
|
|
1635
1627
|
});
|
|
1636
|
-
clearTimeout(
|
|
1637
|
-
const
|
|
1628
|
+
clearTimeout(V), Y(!1);
|
|
1629
|
+
const At = performance.now() - S, Ye = await N.text(), Et = new URL(P.url);
|
|
1638
1630
|
return {
|
|
1639
1631
|
status: N.status,
|
|
1640
1632
|
headers: Array.from(N.headers.entries()),
|
|
1641
|
-
size:
|
|
1642
|
-
body:
|
|
1643
|
-
time:
|
|
1633
|
+
size: Ye.length,
|
|
1634
|
+
body: Ye,
|
|
1635
|
+
time: At,
|
|
1644
1636
|
request: {
|
|
1645
1637
|
method: P.method.toUpperCase(),
|
|
1646
1638
|
url: P.url,
|
|
@@ -1653,96 +1645,96 @@ const xn = {
|
|
|
1653
1645
|
}
|
|
1654
1646
|
};
|
|
1655
1647
|
} catch (N) {
|
|
1656
|
-
throw clearTimeout(
|
|
1648
|
+
throw clearTimeout(V), Y(!1), N instanceof TypeError ? new Error(
|
|
1657
1649
|
"The request failed, possibly due to network issues or CORS policy."
|
|
1658
1650
|
) : N;
|
|
1659
1651
|
}
|
|
1660
1652
|
}
|
|
1661
1653
|
});
|
|
1662
|
-
|
|
1654
|
+
ne(() => () => {
|
|
1663
1655
|
var o;
|
|
1664
|
-
(o =
|
|
1656
|
+
(o = ee.current) == null || o.abort();
|
|
1665
1657
|
}, []);
|
|
1666
|
-
const
|
|
1658
|
+
const Ot = /* @__PURE__ */ e.jsx(
|
|
1667
1659
|
Vs,
|
|
1668
1660
|
{
|
|
1669
1661
|
path: n,
|
|
1670
|
-
renderParam: ({ name: o, originalValue: S, index:
|
|
1662
|
+
renderParam: ({ name: o, originalValue: S, index: R }) => {
|
|
1671
1663
|
var P;
|
|
1672
|
-
const
|
|
1673
|
-
(
|
|
1664
|
+
const D = (P = C.pathParams.find(
|
|
1665
|
+
(V) => V.name === o
|
|
1674
1666
|
)) == null ? void 0 : P.value;
|
|
1675
1667
|
return /* @__PURE__ */ e.jsx(
|
|
1676
|
-
|
|
1668
|
+
wt,
|
|
1677
1669
|
{
|
|
1678
1670
|
name: o,
|
|
1679
1671
|
backgroundOpacity: "0",
|
|
1680
1672
|
slug: o,
|
|
1681
|
-
onClick: () =>
|
|
1682
|
-
children:
|
|
1673
|
+
onClick: () => ce.setFocus(`pathParams.${R}.value`),
|
|
1674
|
+
children: D || S
|
|
1683
1675
|
}
|
|
1684
1676
|
);
|
|
1685
1677
|
}
|
|
1686
1678
|
}
|
|
1687
|
-
),
|
|
1679
|
+
), Qe = C.queryParams.filter((o) => o.active).map((o, S, R) => /* @__PURE__ */ e.jsxs(O, { children: [
|
|
1688
1680
|
o.name,
|
|
1689
1681
|
"=",
|
|
1690
1682
|
encodeURIComponent(o.value).replaceAll("%20", "+"),
|
|
1691
|
-
S <
|
|
1683
|
+
S < R.length - 1 && "&",
|
|
1692
1684
|
/* @__PURE__ */ e.jsx("wbr", {})
|
|
1693
|
-
] }, o.name)),
|
|
1694
|
-
|
|
1685
|
+
] }, o.name)), qt = /* @__PURE__ */ e.jsx("div", { className: "inline-block opacity-50 hover:opacity-100 transition", children: t ? /* @__PURE__ */ e.jsx("span", { children: t.replace(/^https?:\/\//, "").replace(/\/$/, "") }) : s.length > 1 && /* @__PURE__ */ e.jsxs(
|
|
1686
|
+
je,
|
|
1695
1687
|
{
|
|
1696
1688
|
onValueChange: (o) => {
|
|
1697
|
-
T(() =>
|
|
1689
|
+
T(() => p(o));
|
|
1698
1690
|
},
|
|
1699
|
-
value:
|
|
1700
|
-
defaultValue:
|
|
1691
|
+
value: j,
|
|
1692
|
+
defaultValue: j,
|
|
1701
1693
|
children: [
|
|
1702
|
-
/* @__PURE__ */ e.jsx(
|
|
1703
|
-
/* @__PURE__ */ e.jsx(
|
|
1694
|
+
/* @__PURE__ */ e.jsx(ve, { className: "p-0 border-none flex-row-reverse bg-transparent text-xs gap-0.5 h-auto translate-y-[4px]", children: /* @__PURE__ */ e.jsx(be, {}) }),
|
|
1695
|
+
/* @__PURE__ */ e.jsx(Ne, { children: s.map((o) => /* @__PURE__ */ e.jsx(J, { value: o, children: o.replace(/^https?:\/\//, "").replace(/\/$/, "") }, o)) })
|
|
1704
1696
|
]
|
|
1705
1697
|
}
|
|
1706
|
-
) }),
|
|
1698
|
+
) }), Lt = h && !X, se = ["POST", "PUT", "PATCH", "DELETE"].includes(
|
|
1707
1699
|
a.toUpperCase()
|
|
1708
1700
|
);
|
|
1709
1701
|
return /* @__PURE__ */ e.jsx(
|
|
1710
|
-
|
|
1702
|
+
ls,
|
|
1711
1703
|
{
|
|
1712
|
-
register:
|
|
1713
|
-
control:
|
|
1714
|
-
handleSubmit:
|
|
1715
|
-
watch:
|
|
1704
|
+
register: _e,
|
|
1705
|
+
control: te,
|
|
1706
|
+
handleSubmit: Ge,
|
|
1707
|
+
watch: Je,
|
|
1716
1708
|
setValue: E,
|
|
1717
|
-
...
|
|
1709
|
+
...ce,
|
|
1718
1710
|
children: /* @__PURE__ */ e.jsxs(
|
|
1719
1711
|
"form",
|
|
1720
1712
|
{
|
|
1721
|
-
onSubmit:
|
|
1713
|
+
onSubmit: Ge((o) => {
|
|
1722
1714
|
var S;
|
|
1723
|
-
((S =
|
|
1715
|
+
((S = g.data) == null ? void 0 : S.length) === 0 || o.identity ? me.mutate(o) : c(!0);
|
|
1724
1716
|
}),
|
|
1725
|
-
ref:
|
|
1717
|
+
ref: Ue,
|
|
1726
1718
|
className: "relative",
|
|
1727
1719
|
children: [
|
|
1728
1720
|
/* @__PURE__ */ e.jsx(
|
|
1729
1721
|
nn,
|
|
1730
1722
|
{
|
|
1731
|
-
identities:
|
|
1732
|
-
open:
|
|
1733
|
-
onOpenChange:
|
|
1723
|
+
identities: g.data ?? [],
|
|
1724
|
+
open: f,
|
|
1725
|
+
onOpenChange: c,
|
|
1734
1726
|
onSubmit: ({ rememberedIdentity: o, identity: S }) => {
|
|
1735
|
-
o && E("identity", S ??
|
|
1727
|
+
o && E("identity", S ?? M), c(!1), me.mutate({ ...C, identity: S });
|
|
1736
1728
|
}
|
|
1737
1729
|
}
|
|
1738
1730
|
),
|
|
1739
1731
|
/* @__PURE__ */ e.jsx(
|
|
1740
1732
|
dn,
|
|
1741
1733
|
{
|
|
1742
|
-
open:
|
|
1743
|
-
setOpen: (o) =>
|
|
1734
|
+
open: Lt,
|
|
1735
|
+
setOpen: (o) => K(!o),
|
|
1744
1736
|
onSignUp: w,
|
|
1745
|
-
onLogin:
|
|
1737
|
+
onLogin: x
|
|
1746
1738
|
}
|
|
1747
1739
|
),
|
|
1748
1740
|
/* @__PURE__ */ e.jsxs("div", { className: "grid grid-cols-2 text-sm h-full", children: [
|
|
@@ -1751,74 +1743,74 @@ const xn = {
|
|
|
1751
1743
|
/* @__PURE__ */ e.jsxs("div", { className: "flex flex-1 items-center w-full border rounded-md", children: [
|
|
1752
1744
|
/* @__PURE__ */ e.jsx("div", { className: "border-r p-2 bg-muted rounded-l-md self-stretch font-semibold font-mono flex items-center", children: a.toUpperCase() }),
|
|
1753
1745
|
/* @__PURE__ */ e.jsxs("div", { className: "items-center px-2 py-0.5 font-mono text-xs break-all leading-6", children: [
|
|
1754
|
-
|
|
1755
|
-
|
|
1756
|
-
|
|
1757
|
-
|
|
1746
|
+
qt,
|
|
1747
|
+
Ot,
|
|
1748
|
+
Qe.length > 0 ? "?" : "",
|
|
1749
|
+
Qe
|
|
1758
1750
|
] })
|
|
1759
1751
|
] }),
|
|
1760
1752
|
/* @__PURE__ */ e.jsx(
|
|
1761
1753
|
Nn,
|
|
1762
1754
|
{
|
|
1763
|
-
identities:
|
|
1764
|
-
formRef:
|
|
1765
|
-
disabled:
|
|
1755
|
+
identities: g.data ?? [],
|
|
1756
|
+
formRef: Ue,
|
|
1757
|
+
disabled: g.isLoading || ce.formState.isSubmitting
|
|
1766
1758
|
}
|
|
1767
1759
|
)
|
|
1768
1760
|
] }),
|
|
1769
|
-
/* @__PURE__ */ e.jsxs(
|
|
1770
|
-
/* @__PURE__ */ e.jsx("div", { className: "flex flex-wrap gap-1 justify-between", children: /* @__PURE__ */ e.jsxs(
|
|
1771
|
-
/* @__PURE__ */ e.jsxs(
|
|
1761
|
+
/* @__PURE__ */ e.jsxs(yt, { defaultValue: "parameters", children: [
|
|
1762
|
+
/* @__PURE__ */ e.jsx("div", { className: "flex flex-wrap gap-1 justify-between", children: /* @__PURE__ */ e.jsxs(jt, { children: [
|
|
1763
|
+
/* @__PURE__ */ e.jsxs(F, { value: "parameters", children: [
|
|
1772
1764
|
"Parameters",
|
|
1773
1765
|
(C.pathParams.some((o) => o.value !== "") || C.queryParams.some((o) => o.active)) && /* @__PURE__ */ e.jsx("div", { className: "w-2 h-2 rounded-full bg-blue-400 ml-2" })
|
|
1774
1766
|
] }),
|
|
1775
|
-
/* @__PURE__ */ e.jsxs(
|
|
1767
|
+
/* @__PURE__ */ e.jsxs(F, { value: "headers", children: [
|
|
1776
1768
|
"Headers",
|
|
1777
1769
|
C.headers.filter((o) => o.active).length > 0 && /* @__PURE__ */ e.jsx("div", { className: "w-2 h-2 rounded-full bg-blue-400 ml-2" })
|
|
1778
1770
|
] }),
|
|
1779
|
-
/* @__PURE__ */ e.jsxs(
|
|
1771
|
+
/* @__PURE__ */ e.jsxs(F, { value: "auth", children: [
|
|
1780
1772
|
"Auth",
|
|
1781
|
-
C.identity !==
|
|
1773
|
+
C.identity !== M && /* @__PURE__ */ e.jsx("div", { className: "w-2 h-2 rounded-full bg-blue-400 ml-2" })
|
|
1782
1774
|
] }),
|
|
1783
|
-
/* @__PURE__ */ e.jsxs(
|
|
1775
|
+
/* @__PURE__ */ e.jsxs(F, { value: "body", children: [
|
|
1784
1776
|
"Body",
|
|
1785
1777
|
C.body && /* @__PURE__ */ e.jsx("div", { className: "w-2 h-2 rounded-full bg-blue-400 ml-2" })
|
|
1786
1778
|
] })
|
|
1787
1779
|
] }) }),
|
|
1788
|
-
/* @__PURE__ */ e.jsx(
|
|
1789
|
-
/* @__PURE__ */ e.jsxs(
|
|
1780
|
+
/* @__PURE__ */ e.jsx(z, { value: "headers", children: /* @__PURE__ */ e.jsx(tn, { control: te, headers: r }) }),
|
|
1781
|
+
/* @__PURE__ */ e.jsxs(z, { value: "parameters", children: [
|
|
1790
1782
|
l.length > 0 && /* @__PURE__ */ e.jsxs("div", { className: "flex flex-col gap-4 my-4", children: [
|
|
1791
1783
|
/* @__PURE__ */ e.jsx("span", { className: "font-semibold", children: "Path Parameters" }),
|
|
1792
|
-
/* @__PURE__ */ e.jsx(an, { url: n, control:
|
|
1784
|
+
/* @__PURE__ */ e.jsx(an, { url: n, control: te })
|
|
1793
1785
|
] }),
|
|
1794
1786
|
/* @__PURE__ */ e.jsxs("div", { className: "flex flex-col gap-4 my-4", children: [
|
|
1795
1787
|
/* @__PURE__ */ e.jsx("span", { className: "font-semibold", children: "Query Parameters" }),
|
|
1796
|
-
/* @__PURE__ */ e.jsx(on, { control:
|
|
1788
|
+
/* @__PURE__ */ e.jsx(on, { control: te, queryParams: i })
|
|
1797
1789
|
] })
|
|
1798
1790
|
] }),
|
|
1799
|
-
/* @__PURE__ */ e.jsxs(
|
|
1791
|
+
/* @__PURE__ */ e.jsxs(z, { value: "body", children: [
|
|
1800
1792
|
!["POST", "PUT", "PATCH", "DELETE"].includes(
|
|
1801
1793
|
a.toUpperCase()
|
|
1802
|
-
) && /* @__PURE__ */ e.jsxs(
|
|
1803
|
-
/* @__PURE__ */ e.jsx(
|
|
1804
|
-
/* @__PURE__ */ e.jsx(
|
|
1805
|
-
/* @__PURE__ */ e.jsx(
|
|
1794
|
+
) && /* @__PURE__ */ e.jsxs(Ce, { className: "mb-2", children: [
|
|
1795
|
+
/* @__PURE__ */ e.jsx(tt, { className: "w-4 h-4" }),
|
|
1796
|
+
/* @__PURE__ */ e.jsx(Se, { children: "Body" }),
|
|
1797
|
+
/* @__PURE__ */ e.jsx(Te, { children: "Body is only supported for POST, PUT, PATCH, and DELETE requests" })
|
|
1806
1798
|
] }),
|
|
1807
1799
|
/* @__PURE__ */ e.jsx(
|
|
1808
|
-
|
|
1800
|
+
Nt,
|
|
1809
1801
|
{
|
|
1810
|
-
...
|
|
1811
|
-
className:
|
|
1802
|
+
..._e("body"),
|
|
1803
|
+
className: u(
|
|
1812
1804
|
"border w-full rounded-lg bg-muted/40 p-2 h-64 font-mono text-[13px]",
|
|
1813
|
-
!
|
|
1805
|
+
!se && "h-20 bg-muted"
|
|
1814
1806
|
),
|
|
1815
|
-
placeholder:
|
|
1816
|
-
disabled: !
|
|
1807
|
+
placeholder: se ? void 0 : "This request does not support a body",
|
|
1808
|
+
disabled: !se
|
|
1817
1809
|
}
|
|
1818
1810
|
),
|
|
1819
|
-
|
|
1811
|
+
se && /* @__PURE__ */ e.jsxs("div", { className: "flex items-center gap-2 mt-2 justify-between", children: [
|
|
1820
1812
|
/* @__PURE__ */ e.jsxs(
|
|
1821
|
-
|
|
1813
|
+
je,
|
|
1822
1814
|
{
|
|
1823
1815
|
value: C.bodyContentType,
|
|
1824
1816
|
onValueChange: (o) => E(
|
|
@@ -1826,41 +1818,41 @@ const xn = {
|
|
|
1826
1818
|
o
|
|
1827
1819
|
),
|
|
1828
1820
|
children: [
|
|
1829
|
-
/* @__PURE__ */ e.jsx(
|
|
1830
|
-
/* @__PURE__ */ e.jsx(
|
|
1821
|
+
/* @__PURE__ */ e.jsx(ve, { className: "w-[100px]", children: /* @__PURE__ */ e.jsx(be, {}) }),
|
|
1822
|
+
/* @__PURE__ */ e.jsx(Ne, { children: Object.keys(ye).map((o) => /* @__PURE__ */ e.jsx(J, { value: o, children: o }, o)) })
|
|
1831
1823
|
]
|
|
1832
1824
|
}
|
|
1833
1825
|
),
|
|
1834
1826
|
d && d.length > 0 && /* @__PURE__ */ e.jsx(
|
|
1835
|
-
|
|
1827
|
+
Js,
|
|
1836
1828
|
{
|
|
1837
1829
|
examples: d,
|
|
1838
1830
|
onSelect: (o, S) => {
|
|
1839
|
-
var
|
|
1831
|
+
var D;
|
|
1840
1832
|
E(
|
|
1841
1833
|
"body",
|
|
1842
1834
|
JSON.stringify(o.value, null, 2)
|
|
1843
1835
|
);
|
|
1844
|
-
const
|
|
1845
|
-
([P,
|
|
1846
|
-
)) == null ? void 0 :
|
|
1847
|
-
|
|
1836
|
+
const R = (D = cs(ye).find(
|
|
1837
|
+
([P, V]) => V === S
|
|
1838
|
+
)) == null ? void 0 : D[0];
|
|
1839
|
+
R && E("bodyContentType", R);
|
|
1848
1840
|
}
|
|
1849
1841
|
}
|
|
1850
1842
|
)
|
|
1851
1843
|
] })
|
|
1852
1844
|
] }),
|
|
1853
|
-
/* @__PURE__ */ e.jsx(
|
|
1854
|
-
((
|
|
1855
|
-
/* @__PURE__ */ e.jsx(
|
|
1856
|
-
/* @__PURE__ */ e.jsx(
|
|
1857
|
-
/* @__PURE__ */ e.jsx(
|
|
1845
|
+
/* @__PURE__ */ e.jsx(z, { value: "auth", children: /* @__PURE__ */ e.jsxs("div", { className: "flex flex-col gap-4 my-4", children: [
|
|
1846
|
+
((Ze = g.data) == null ? void 0 : Ze.length) === 0 && /* @__PURE__ */ e.jsxs(Ce, { children: [
|
|
1847
|
+
/* @__PURE__ */ e.jsx(tt, { className: "w-4 h-4" }),
|
|
1848
|
+
/* @__PURE__ */ e.jsx(Se, { children: "Authentication" }),
|
|
1849
|
+
/* @__PURE__ */ e.jsx(Te, { children: "No identities found. Please create an identity first." })
|
|
1858
1850
|
] }),
|
|
1859
1851
|
/* @__PURE__ */ e.jsx("div", { className: "flex flex-col items-center gap-2", children: /* @__PURE__ */ e.jsx(
|
|
1860
1852
|
kt,
|
|
1861
1853
|
{
|
|
1862
1854
|
value: C.identity,
|
|
1863
|
-
identities:
|
|
1855
|
+
identities: g.data ?? [],
|
|
1864
1856
|
setValue: (o) => E("identity", o)
|
|
1865
1857
|
}
|
|
1866
1858
|
) })
|
|
@@ -1870,16 +1862,16 @@ const xn = {
|
|
|
1870
1862
|
/* @__PURE__ */ e.jsx(
|
|
1871
1863
|
bn,
|
|
1872
1864
|
{
|
|
1873
|
-
queryMutation:
|
|
1865
|
+
queryMutation: me,
|
|
1874
1866
|
showPathParamsWarning: C.pathParams.some(
|
|
1875
1867
|
(o) => o.value === ""
|
|
1876
1868
|
),
|
|
1877
|
-
showLongRunningWarning:
|
|
1869
|
+
showLongRunningWarning: Rt,
|
|
1878
1870
|
onCancel: () => {
|
|
1879
1871
|
var o;
|
|
1880
|
-
(o =
|
|
1872
|
+
(o = ee.current) == null || o.abort(
|
|
1881
1873
|
"Request cancelled by the user"
|
|
1882
|
-
),
|
|
1874
|
+
), Y(!1);
|
|
1883
1875
|
}
|
|
1884
1876
|
}
|
|
1885
1877
|
)
|
|
@@ -1911,9 +1903,9 @@ const xn = {
|
|
|
1911
1903
|
)
|
|
1912
1904
|
}
|
|
1913
1905
|
), Sn = (t) => {
|
|
1914
|
-
const [s, n] =
|
|
1906
|
+
const [s, n] = k(!1);
|
|
1915
1907
|
return /* @__PURE__ */ e.jsxs(ke, { onOpenChange: (a) => n(a), children: [
|
|
1916
|
-
/* @__PURE__ */ e.jsx(
|
|
1908
|
+
/* @__PURE__ */ e.jsx(rs, { asChild: !0, children: t.children ?? /* @__PURE__ */ e.jsxs(
|
|
1917
1909
|
"button",
|
|
1918
1910
|
{
|
|
1919
1911
|
type: "button",
|
|
@@ -1925,12 +1917,12 @@ const xn = {
|
|
|
1925
1917
|
}
|
|
1926
1918
|
) }),
|
|
1927
1919
|
/* @__PURE__ */ e.jsxs(
|
|
1928
|
-
|
|
1920
|
+
Ie,
|
|
1929
1921
|
{
|
|
1930
1922
|
className: "max-w-screen-xl w-full h-5/6 overflow-hidden p-0",
|
|
1931
1923
|
"aria-describedby": void 0,
|
|
1932
1924
|
children: [
|
|
1933
|
-
/* @__PURE__ */ e.jsx(
|
|
1925
|
+
/* @__PURE__ */ e.jsx(ss, { children: /* @__PURE__ */ e.jsx(Re, { children: "Playground" }) }),
|
|
1934
1926
|
s && /* @__PURE__ */ e.jsx(wn, { ...t })
|
|
1935
1927
|
]
|
|
1936
1928
|
}
|
|
@@ -1944,7 +1936,7 @@ const xn = {
|
|
|
1944
1936
|
patch: "purple",
|
|
1945
1937
|
options: "gray",
|
|
1946
1938
|
head: "gray"
|
|
1947
|
-
},
|
|
1939
|
+
}, pt = ({
|
|
1948
1940
|
label: t,
|
|
1949
1941
|
path: s,
|
|
1950
1942
|
operations: n,
|
|
@@ -1964,18 +1956,16 @@ const xn = {
|
|
|
1964
1956
|
type: "link",
|
|
1965
1957
|
label: i.summary ?? i.path,
|
|
1966
1958
|
href: `${s}#${i.slug}`,
|
|
1967
|
-
|
|
1968
|
-
|
|
1969
|
-
|
|
1970
|
-
|
|
1971
|
-
invert: !0
|
|
1972
|
-
}
|
|
1959
|
+
badge: {
|
|
1960
|
+
label: i.method,
|
|
1961
|
+
color: Tn[i.method.toLowerCase()],
|
|
1962
|
+
invert: !0
|
|
1973
1963
|
}
|
|
1974
1964
|
}))
|
|
1975
|
-
}),
|
|
1965
|
+
}), ht = (t) => ({
|
|
1976
1966
|
path: t.routePath,
|
|
1977
1967
|
async lazy() {
|
|
1978
|
-
const { OasProvider: s } = await import("./OasProvider-
|
|
1968
|
+
const { OasProvider: s } = await import("./OasProvider-BaRRMSsD.js");
|
|
1979
1969
|
return {
|
|
1980
1970
|
element: /* @__PURE__ */ e.jsx(
|
|
1981
1971
|
s,
|
|
@@ -1989,38 +1979,38 @@ const xn = {
|
|
|
1989
1979
|
};
|
|
1990
1980
|
},
|
|
1991
1981
|
children: t.routes
|
|
1992
|
-
}),
|
|
1982
|
+
}), $e = ({
|
|
1993
1983
|
path: t,
|
|
1994
1984
|
tag: s,
|
|
1995
1985
|
untagged: n
|
|
1996
1986
|
}) => ({
|
|
1997
1987
|
path: t,
|
|
1998
1988
|
async lazy() {
|
|
1999
|
-
const { OperationList: a } = await import("./OperationList-
|
|
1989
|
+
const { OperationList: a } = await import("./OperationList-BjL1hzSx.js");
|
|
2000
1990
|
return { element: /* @__PURE__ */ e.jsx(a, { tag: s, untagged: n }) };
|
|
2001
1991
|
}
|
|
2002
1992
|
}), $n = (t, s) => {
|
|
2003
|
-
const n =
|
|
1993
|
+
const n = A(
|
|
2004
1994
|
t,
|
|
2005
|
-
s[0] ?
|
|
1995
|
+
s[0] ? ot(s[0]) : Pe
|
|
2006
1996
|
);
|
|
2007
1997
|
return [
|
|
2008
1998
|
// Redirect to first tag on the index route
|
|
2009
|
-
{ index: !0, loader: () =>
|
|
1999
|
+
{ index: !0, loader: () => Qt(n) },
|
|
2010
2000
|
// Create routes for each tag
|
|
2011
2001
|
...s.map(
|
|
2012
|
-
(a) =>
|
|
2013
|
-
path:
|
|
2002
|
+
(a) => $e({
|
|
2003
|
+
path: A(t, ot(a)),
|
|
2014
2004
|
tag: a
|
|
2015
2005
|
})
|
|
2016
2006
|
),
|
|
2017
2007
|
// Category without tagged operations
|
|
2018
|
-
|
|
2019
|
-
path:
|
|
2008
|
+
$e({
|
|
2009
|
+
path: A(t, Pe),
|
|
2020
2010
|
untagged: !0
|
|
2021
2011
|
})
|
|
2022
2012
|
];
|
|
2023
|
-
},
|
|
2013
|
+
}, It = (t) => t.type === "file" ? Object.keys(t.input) : [], Pn = ({
|
|
2024
2014
|
basePath: t,
|
|
2025
2015
|
config: s,
|
|
2026
2016
|
client: n
|
|
@@ -2028,18 +2018,18 @@ const xn = {
|
|
|
2028
2018
|
const a = s.tagPages;
|
|
2029
2019
|
if (!a)
|
|
2030
2020
|
return [
|
|
2031
|
-
|
|
2021
|
+
ht({
|
|
2032
2022
|
basePath: t,
|
|
2033
2023
|
routePath: t,
|
|
2034
|
-
routes: [
|
|
2024
|
+
routes: [$e({ path: t + "/:tag?" })],
|
|
2035
2025
|
client: n,
|
|
2036
2026
|
config: s
|
|
2037
2027
|
})
|
|
2038
2028
|
];
|
|
2039
|
-
const r =
|
|
2029
|
+
const r = It(s);
|
|
2040
2030
|
return (r.length > 1 ? [void 0, ...r] : [void 0]).map((l) => {
|
|
2041
|
-
const m =
|
|
2042
|
-
return
|
|
2031
|
+
const m = A(t, l);
|
|
2032
|
+
return ht({
|
|
2043
2033
|
basePath: t,
|
|
2044
2034
|
version: l,
|
|
2045
2035
|
routePath: m,
|
|
@@ -2048,41 +2038,25 @@ const xn = {
|
|
|
2048
2038
|
config: s
|
|
2049
2039
|
});
|
|
2050
2040
|
});
|
|
2051
|
-
},
|
|
2052
|
-
query
|
|
2041
|
+
}, kn = Es(`
|
|
2042
|
+
query GetSidebarOperations($input: JSON!, $type: SchemaType!) {
|
|
2053
2043
|
schema(input: $input, type: $type) {
|
|
2054
|
-
url
|
|
2055
2044
|
tags {
|
|
2056
|
-
name
|
|
2057
|
-
}
|
|
2058
|
-
}
|
|
2059
|
-
}
|
|
2060
|
-
`), Rn = wt(`
|
|
2061
|
-
query GetOperations($input: JSON!, $type: SchemaType!, $tag: String) {
|
|
2062
|
-
schema(input: $input, type: $type) {
|
|
2063
|
-
operations(tag: $tag) {
|
|
2064
2045
|
slug
|
|
2065
|
-
|
|
2066
|
-
|
|
2067
|
-
|
|
2068
|
-
|
|
2069
|
-
|
|
2070
|
-
|
|
2071
|
-
|
|
2046
|
+
name
|
|
2047
|
+
extensions
|
|
2048
|
+
operations {
|
|
2049
|
+
summary
|
|
2050
|
+
slug
|
|
2051
|
+
method
|
|
2052
|
+
operationId
|
|
2053
|
+
path
|
|
2072
2054
|
}
|
|
2073
2055
|
}
|
|
2074
|
-
untagged: operations(untagged: true) {
|
|
2075
|
-
slug
|
|
2076
|
-
deprecated
|
|
2077
|
-
method
|
|
2078
|
-
summary
|
|
2079
|
-
operationId
|
|
2080
|
-
path
|
|
2081
|
-
}
|
|
2082
2056
|
}
|
|
2083
2057
|
}
|
|
2084
|
-
`),
|
|
2085
|
-
const s =
|
|
2058
|
+
`), Pe = "~endpoints", oa = (t) => {
|
|
2059
|
+
const s = A(t.navigationId ?? "/reference"), n = new Ps(t);
|
|
2086
2060
|
return {
|
|
2087
2061
|
getHead: () => {
|
|
2088
2062
|
if (t.type === "url" && !t.skipPreload)
|
|
@@ -2107,18 +2081,18 @@ const xn = {
|
|
|
2107
2081
|
children: m,
|
|
2108
2082
|
...d
|
|
2109
2083
|
}) => {
|
|
2110
|
-
const
|
|
2084
|
+
const h = es();
|
|
2111
2085
|
if (!r)
|
|
2112
2086
|
throw new Error("Server is required");
|
|
2113
|
-
return a && !
|
|
2114
|
-
|
|
2087
|
+
return a && !h.isAuthenticated ? /* @__PURE__ */ e.jsxs(
|
|
2088
|
+
Q,
|
|
2115
2089
|
{
|
|
2116
2090
|
className: "gap-2 items-center",
|
|
2117
2091
|
variant: "outline",
|
|
2118
|
-
onClick:
|
|
2092
|
+
onClick: h.login,
|
|
2119
2093
|
children: [
|
|
2120
2094
|
"Login to open in Playground ",
|
|
2121
|
-
/* @__PURE__ */ e.jsx(
|
|
2095
|
+
/* @__PURE__ */ e.jsx(Jt, { size: 16 })
|
|
2122
2096
|
]
|
|
2123
2097
|
}
|
|
2124
2098
|
) : /* @__PURE__ */ e.jsx(
|
|
@@ -2128,60 +2102,48 @@ const xn = {
|
|
|
2128
2102
|
method: i ?? "get",
|
|
2129
2103
|
server: r,
|
|
2130
2104
|
...d,
|
|
2131
|
-
children: /* @__PURE__ */ e.jsx(
|
|
2105
|
+
children: /* @__PURE__ */ e.jsx(Q, { className: "gap-2 items-center", variant: "outline", children: m ?? /* @__PURE__ */ e.jsxs(e.Fragment, { children: [
|
|
2132
2106
|
"Open in Playground ",
|
|
2133
|
-
/* @__PURE__ */ e.jsx(
|
|
2107
|
+
/* @__PURE__ */ e.jsx(Ut, { size: 16 })
|
|
2134
2108
|
] }) })
|
|
2135
2109
|
}
|
|
2136
2110
|
);
|
|
2137
2111
|
}
|
|
2138
2112
|
}),
|
|
2139
|
-
getSidebar: async (a) => {
|
|
2140
|
-
var
|
|
2141
|
-
if (!
|
|
2113
|
+
getSidebar: async (a, r) => {
|
|
2114
|
+
var l, m;
|
|
2115
|
+
if (!st({ path: s, end: !1 }, a))
|
|
2142
2116
|
return [];
|
|
2143
|
-
const
|
|
2117
|
+
const i = st(
|
|
2144
2118
|
{ path: `${s}/:version?/:tag`, end: !0 },
|
|
2145
2119
|
a
|
|
2146
2120
|
);
|
|
2147
2121
|
try {
|
|
2148
|
-
const
|
|
2149
|
-
|
|
2150
|
-
|
|
2151
|
-
|
|
2152
|
-
|
|
2153
|
-
|
|
2154
|
-
|
|
2155
|
-
|
|
2156
|
-
|
|
2157
|
-
|
|
2158
|
-
|
|
2159
|
-
|
|
2160
|
-
|
|
2161
|
-
ae(f.name)
|
|
2162
|
-
), T = u.schema.operations.filter(
|
|
2163
|
-
(K) => {
|
|
2164
|
-
var Y, ee;
|
|
2165
|
-
return ((Y = K.tags) == null ? void 0 : Y.length) !== 0 && ((ee = K.tags) == null ? void 0 : ee.map((D) => D.name).includes(f.name));
|
|
2166
|
-
}
|
|
2167
|
-
);
|
|
2168
|
-
return c != null && c.loadTags && T.length === 0 ? [] : ht({
|
|
2169
|
-
label: f.name,
|
|
2170
|
-
path: $,
|
|
2171
|
-
operations: (r == null ? void 0 : r.params.tag) !== _ || c != null && c.loadTags ? T : [],
|
|
2172
|
-
collapsible: w,
|
|
2173
|
-
collapsed: v
|
|
2122
|
+
const d = i == null ? void 0 : i.params.version, h = d ?? It(t).at(0), { type: x } = t, w = x === "file" ? t.input[h] : t.input, j = await r.queryClient.ensureQueryData({
|
|
2123
|
+
queryKey: ["sidebar-operations-query", w],
|
|
2124
|
+
queryFn: () => n.fetch(kn, { type: x, input: w })
|
|
2125
|
+
}), p = j.schema.tags.flatMap((c) => {
|
|
2126
|
+
var T, X, K;
|
|
2127
|
+
if (!c.name || c.operations.length === 0) return [];
|
|
2128
|
+
const g = A(s, d, c.slug), b = ((T = c.extensions) == null ? void 0 : T["x-zudoku-collapsed"]) ?? !((X = t.options) != null && X.expandAllTags), $ = ((K = c.extensions) == null ? void 0 : K["x-zudoku-collapsible"]) ?? !0;
|
|
2129
|
+
return pt({
|
|
2130
|
+
label: c.name,
|
|
2131
|
+
path: g,
|
|
2132
|
+
operations: c.operations,
|
|
2133
|
+
collapsed: b,
|
|
2134
|
+
collapsible: $
|
|
2174
2135
|
});
|
|
2175
|
-
})
|
|
2176
|
-
|
|
2177
|
-
|
|
2136
|
+
}), f = (l = j.schema.tags.find(
|
|
2137
|
+
(c) => !c.name
|
|
2138
|
+
)) == null ? void 0 : l.operations;
|
|
2139
|
+
return f && p.push(
|
|
2140
|
+
pt({
|
|
2178
2141
|
label: "Other endpoints",
|
|
2179
|
-
path:
|
|
2180
|
-
operations:
|
|
2181
|
-
|
|
2182
|
-
collapsed: v
|
|
2142
|
+
path: A(s, d, Pe),
|
|
2143
|
+
operations: f,
|
|
2144
|
+
collapsed: !((m = t.options) != null && m.expandAllTags)
|
|
2183
2145
|
})
|
|
2184
|
-
),
|
|
2146
|
+
), p;
|
|
2185
2147
|
} catch {
|
|
2186
2148
|
return [];
|
|
2187
2149
|
}
|
|
@@ -2190,16 +2152,16 @@ const xn = {
|
|
|
2190
2152
|
};
|
|
2191
2153
|
};
|
|
2192
2154
|
export {
|
|
2193
|
-
|
|
2155
|
+
wt as C,
|
|
2194
2156
|
Sn as P,
|
|
2195
|
-
|
|
2196
|
-
|
|
2197
|
-
|
|
2198
|
-
|
|
2199
|
-
|
|
2157
|
+
Pe as U,
|
|
2158
|
+
Es as a,
|
|
2159
|
+
lt as b,
|
|
2160
|
+
ct as c,
|
|
2161
|
+
dt as d,
|
|
2200
2162
|
Vs as e,
|
|
2201
|
-
|
|
2163
|
+
It as g,
|
|
2202
2164
|
mn as m,
|
|
2203
|
-
|
|
2165
|
+
oa as o
|
|
2204
2166
|
};
|
|
2205
|
-
//# sourceMappingURL=index-
|
|
2167
|
+
//# sourceMappingURL=index-D5m8_oyY.js.map
|