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