apiuikit 2.1.0 → 2.2.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/{CodeSamples-GTPVAAJ5.js → CodeSamples-BxUKzCvO.js} +1 -1
- package/dist/{CodeSamples-5FoT0ZpU.cjs → CodeSamples-C9DFITYX.cjs} +1 -1
- package/dist/{LogoExtension-DuIqK_Wj.js → LogoExtension-DZ4kFXRU.js} +1 -1
- package/dist/{LogoExtension-CbdKkZJ6.cjs → LogoExtension-z_uLvzXh.cjs} +1 -1
- package/dist/apiuikit.cjs.js +1 -1
- package/dist/apiuikit.es.js +1 -1
- package/dist/{index-D8Euqzmz.js → index-B3fyC_vS.js} +1 -1
- package/dist/{index-CT7jUAdL.js → index-BGwEEF4U.js} +411 -399
- package/dist/{index-DRBkON8k.js → index-CfMaEll2.js} +1 -1
- package/dist/{index-BNwl4VfM.cjs → index-DI1pJDDr.cjs} +1 -1
- package/dist/{index-CpdbrwV-.cjs → index-Db1Uh19l.cjs} +1 -1
- package/dist/{index-0u301gJq.cjs → index-DhjNPCD8.cjs} +27 -27
- package/dist/{protoToJsonSchema-DcX8BXD3.cjs → protoToJsonSchema-BCcfO1xm.cjs} +1 -1
- package/dist/{protoToJsonSchema-CpU-wRjQ.js → protoToJsonSchema-DSskBSDK.js} +1 -1
- package/dist/{protobufSchemaParser-C0ip1oHD.cjs → protobufSchemaParser-Brl5Ve-k.cjs} +1 -1
- package/dist/{protobufSchemaParser-ZdCXJyvr.js → protobufSchemaParser-Cz0UkK1s.js} +2 -2
- package/package.json +1 -1
|
@@ -2,7 +2,7 @@ var cl = Object.defineProperty;
|
|
|
2
2
|
var dl = (e, t, n) => t in e ? cl(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n;
|
|
3
3
|
var ie = (e, t, n) => dl(e, typeof t != "symbol" ? t + "" : t, n);
|
|
4
4
|
import { jsxs as g, jsx as a, Fragment as U } from "react/jsx-runtime";
|
|
5
|
-
import ul, { Component as fl, useContext as Zt, createContext as pl, useState as P, useEffect as K, useMemo as X, useId as
|
|
5
|
+
import ul, { Component as fl, useContext as Zt, createContext as pl, useState as P, useEffect as K, useMemo as X, useId as nt, useRef as ge, useLayoutEffect as Mo, useCallback as Os, useSyncExternalStore as hl, Suspense as Fn, lazy as Xt, forwardRef as ml, Fragment as Ro } from "react";
|
|
6
6
|
import { createPortal as kt } from "react-dom";
|
|
7
7
|
import Lo from "isomorphic-dompurify";
|
|
8
8
|
const Kr = [
|
|
@@ -395,11 +395,11 @@ function Vl(e) {
|
|
|
395
395
|
}
|
|
396
396
|
const Jl = [];
|
|
397
397
|
function zo(e, t, n = vt, r = Jl) {
|
|
398
|
-
var
|
|
399
|
-
const [s, o] = P(null), [i, l] = P(null), c = X(() => Yt(t), [t]), d = ((
|
|
400
|
-
if (typeof
|
|
401
|
-
if (typeof
|
|
402
|
-
}, [
|
|
398
|
+
var T, M, j, L, G, Q, A, w, I, D;
|
|
399
|
+
const [s, o] = P(null), [i, l] = P(null), c = X(() => Yt(t), [t]), d = ((T = n.expand) == null ? void 0 : T.schemas) === !0, u = (j = (M = n.theme) == null ? void 0 : M.depthColors) != null && j.length ? n.theme.depthColors : Kr, f = ((L = n.show) == null ? void 0 : L.extensions) !== !1, p = ((G = n.show) == null ? void 0 : G.codeSamples) !== !1, h = ((Q = n.show) == null ? void 0 : Q.tryIt) === !0, m = n.topOffset, x = typeof m == "number" && Number.isFinite(m) ? Math.max(0, m) : 0, b = ((A = n.sidePanel) == null ? void 0 : A.containment) ?? "viewport", N = (w = n.sidePanel) == null ? void 0 : w.topOffset, E = typeof N == "number" && Number.isFinite(N) ? Math.max(0, N) : x, v = (I = n.markdown) == null ? void 0 : I.url, C = X(() => {
|
|
400
|
+
if (typeof v == "function") return v;
|
|
401
|
+
if (typeof v == "string") return () => v;
|
|
402
|
+
}, [v]), F = X(() => Fo(r), [r]), H = Vl(((D = n.theme) == null ? void 0 : D.mode) === "system"), S = X(
|
|
403
403
|
() => zl(n.theme, H),
|
|
404
404
|
[n.theme, H]
|
|
405
405
|
), k = X(
|
|
@@ -421,7 +421,7 @@ function zo(e, t, n = vt, r = Jl) {
|
|
|
421
421
|
showExtensions: f,
|
|
422
422
|
showCodeSamples: p,
|
|
423
423
|
showTryIt: h,
|
|
424
|
-
markdownUrl:
|
|
424
|
+
markdownUrl: C,
|
|
425
425
|
plugins: r,
|
|
426
426
|
pluginSlotRegistry: F,
|
|
427
427
|
config: n,
|
|
@@ -441,7 +441,7 @@ function zo(e, t, n = vt, r = Jl) {
|
|
|
441
441
|
f,
|
|
442
442
|
p,
|
|
443
443
|
h,
|
|
444
|
-
|
|
444
|
+
C,
|
|
445
445
|
r,
|
|
446
446
|
F,
|
|
447
447
|
n,
|
|
@@ -548,14 +548,14 @@ function ht({
|
|
|
548
548
|
variant: l
|
|
549
549
|
}) {
|
|
550
550
|
var x;
|
|
551
|
-
const c =
|
|
552
|
-
var
|
|
551
|
+
const c = nt(), d = ge([]), u = t ?? (i ? "" : ((x = e[0]) == null ? void 0 : x.id) ?? ""), f = e.some((b) => !!b.icon), p = t ? e.findIndex((b) => b.id === t) : -1, h = p >= 0 ? p : 0, m = (b, N) => {
|
|
552
|
+
var C;
|
|
553
553
|
if (e.length === 0) return;
|
|
554
554
|
const E = (F) => (F + e.length) % e.length;
|
|
555
|
-
let
|
|
556
|
-
if (b.key === "ArrowRight" && (b.preventDefault(),
|
|
557
|
-
const F = e[
|
|
558
|
-
n(F.id), (
|
|
555
|
+
let v = N;
|
|
556
|
+
if (b.key === "ArrowRight" && (b.preventDefault(), v = E(N + 1)), b.key === "ArrowLeft" && (b.preventDefault(), v = E(N - 1)), b.key === "Home" && (b.preventDefault(), v = 0), b.key === "End" && (b.preventDefault(), v = e.length - 1), v !== N) {
|
|
557
|
+
const F = e[v];
|
|
558
|
+
n(F.id), (C = d.current[v]) == null || C.focus();
|
|
559
559
|
}
|
|
560
560
|
};
|
|
561
561
|
return e.length ? /* @__PURE__ */ g("div", { children: [
|
|
@@ -583,22 +583,22 @@ function ht({
|
|
|
583
583
|
className: "inline-flex h-9.5 w-77.5 items-center gap-1 rounded-lg bg-neutral-100 p-1",
|
|
584
584
|
role: "tablist",
|
|
585
585
|
"aria-label": r,
|
|
586
|
-
children: e.map((b,
|
|
586
|
+
children: e.map((b, N) => {
|
|
587
587
|
const E = b.id === t;
|
|
588
588
|
return /* @__PURE__ */ a(
|
|
589
589
|
"button",
|
|
590
590
|
{
|
|
591
|
-
ref: (
|
|
592
|
-
d.current[
|
|
591
|
+
ref: (v) => {
|
|
592
|
+
d.current[N] = v;
|
|
593
593
|
},
|
|
594
594
|
id: wn(o, b.id),
|
|
595
595
|
type: "button",
|
|
596
596
|
role: "tab",
|
|
597
|
-
tabIndex:
|
|
597
|
+
tabIndex: N === h ? 0 : -1,
|
|
598
598
|
"aria-selected": E,
|
|
599
599
|
"aria-controls": kn(o, b.id),
|
|
600
600
|
onClick: () => n(b.id),
|
|
601
|
-
onKeyDown: (
|
|
601
|
+
onKeyDown: (v) => m(v, N),
|
|
602
602
|
className: lt(
|
|
603
603
|
"h-full flex-1 cursor-pointer rounded-md text-sm font-medium transition-colors",
|
|
604
604
|
E ? "bg-surface text-foreground shadow-sm" : "text-foreground-muted hover:text-foreground-secondary"
|
|
@@ -615,28 +615,28 @@ function ht({
|
|
|
615
615
|
className: "border-b border-border",
|
|
616
616
|
role: "tablist",
|
|
617
617
|
"aria-label": r,
|
|
618
|
-
children: /* @__PURE__ */ a("div", { className: "flex flex-wrap gap-6", children: e.map((b,
|
|
619
|
-
const E = b.id === t,
|
|
618
|
+
children: /* @__PURE__ */ a("div", { className: "flex flex-wrap gap-6", children: e.map((b, N) => {
|
|
619
|
+
const E = b.id === t, v = b.icon;
|
|
620
620
|
return /* @__PURE__ */ a(
|
|
621
621
|
"button",
|
|
622
622
|
{
|
|
623
|
-
ref: (
|
|
624
|
-
d.current[
|
|
623
|
+
ref: (C) => {
|
|
624
|
+
d.current[N] = C;
|
|
625
625
|
},
|
|
626
626
|
id: wn(o, b.id),
|
|
627
627
|
type: "button",
|
|
628
628
|
role: "tab",
|
|
629
|
-
tabIndex:
|
|
629
|
+
tabIndex: N === h ? 0 : -1,
|
|
630
630
|
"aria-selected": E,
|
|
631
631
|
"aria-controls": kn(o, b.id),
|
|
632
632
|
onClick: () => n(b.id),
|
|
633
|
-
onKeyDown: (
|
|
633
|
+
onKeyDown: (C) => m(C, N),
|
|
634
634
|
className: lt(
|
|
635
635
|
"cursor-pointer border-b-2 px-1 py-3 text-sm font-semibold transition-colors",
|
|
636
636
|
E ? "border-primary-500 text-primary-600" : "border-transparent text-foreground-muted hover:text-foreground"
|
|
637
637
|
),
|
|
638
638
|
children: /* @__PURE__ */ g("span", { className: "inline-flex items-center gap-2", children: [
|
|
639
|
-
|
|
639
|
+
v ? /* @__PURE__ */ a(v, { className: "h-4 w-4 shrink-0" }) : null,
|
|
640
640
|
/* @__PURE__ */ a("span", { children: b.name })
|
|
641
641
|
] })
|
|
642
642
|
},
|
|
@@ -650,26 +650,26 @@ function ht({
|
|
|
650
650
|
className: "relative z-0 flex divide-x divide-border rounded-lg shadow",
|
|
651
651
|
role: "tablist",
|
|
652
652
|
"aria-label": r,
|
|
653
|
-
children: e.map((b,
|
|
653
|
+
children: e.map((b, N) => {
|
|
654
654
|
const E = b.id === t;
|
|
655
655
|
return /* @__PURE__ */ g(
|
|
656
656
|
"button",
|
|
657
657
|
{
|
|
658
|
-
ref: (
|
|
659
|
-
d.current[
|
|
658
|
+
ref: (v) => {
|
|
659
|
+
d.current[N] = v;
|
|
660
660
|
},
|
|
661
661
|
id: wn(o, b.id),
|
|
662
662
|
type: "button",
|
|
663
663
|
role: "tab",
|
|
664
|
-
tabIndex:
|
|
664
|
+
tabIndex: N === h ? 0 : -1,
|
|
665
665
|
"aria-selected": E,
|
|
666
666
|
"aria-controls": kn(o, b.id),
|
|
667
667
|
onClick: () => n(b.id),
|
|
668
|
-
onKeyDown: (
|
|
668
|
+
onKeyDown: (v) => m(v, N),
|
|
669
669
|
className: lt(
|
|
670
670
|
E ? "text-foreground" : "text-foreground-muted hover:text-foreground-secondary",
|
|
671
|
-
|
|
672
|
-
|
|
671
|
+
N === 0 ? "rounded-l-lg" : "",
|
|
672
|
+
N === e.length - 1 ? "rounded-r-lg" : "",
|
|
673
673
|
"group relative min-w-0 flex-1 cursor-pointer overflow-hidden bg-surface px-4 py-4 text-center text-sm font-medium hover:bg-neutral-50 focus:z-10"
|
|
674
674
|
),
|
|
675
675
|
children: [
|
|
@@ -844,29 +844,29 @@ function nc(e) {
|
|
|
844
844
|
(n, r) => n.type === "text" ? /* @__PURE__ */ a("span", { children: n.value }, r) : /* @__PURE__ */ a("span", { className: `font-semibold ${Tn[t++ % Tn.length]}`, children: `{${n.value}}` }, r)
|
|
845
845
|
);
|
|
846
846
|
}
|
|
847
|
-
function
|
|
848
|
-
const { portalHost: i } = $e(), [l, c] = P(null), [d, u] = P({ top: 0, left: 0, placement: "top" }), [f, p] = P(!1), [h, m] = P(null), x = ge(null), b =
|
|
847
|
+
function et({ address: e, parameters: t, className: n = "text-xs", truncate: r = !1, peek: s = !1, padded: o = !0 }) {
|
|
848
|
+
const { portalHost: i } = $e(), [l, c] = P(null), [d, u] = P({ top: 0, left: 0, placement: "top" }), [f, p] = P(!1), [h, m] = P(null), x = ge(null), b = nt(), N = tc(e);
|
|
849
849
|
let E = 0;
|
|
850
850
|
K(() => {
|
|
851
851
|
if (!r) return;
|
|
852
852
|
const y = x.current;
|
|
853
853
|
if (!y) return;
|
|
854
|
-
const
|
|
855
|
-
|
|
856
|
-
const M = new ResizeObserver(
|
|
854
|
+
const T = () => p(y.scrollWidth > y.clientWidth);
|
|
855
|
+
T();
|
|
856
|
+
const M = new ResizeObserver(T);
|
|
857
857
|
return M.observe(y), () => M.disconnect();
|
|
858
858
|
}, [r, e]);
|
|
859
|
-
const
|
|
860
|
-
u(gr(
|
|
861
|
-
},
|
|
862
|
-
if (y.type === "text") return /* @__PURE__ */ a("span", { children: y.value },
|
|
863
|
-
const M = t == null ? void 0 : t[y.value], j = Tn[E++ % Tn.length], L = l ===
|
|
859
|
+
const v = (y, T) => {
|
|
860
|
+
u(gr(T)), c(y);
|
|
861
|
+
}, C = () => c(null), F = (y) => m(gr(y, { align: "end", width: Ps })), H = () => m(null), S = N.map((y, T) => {
|
|
862
|
+
if (y.type === "text") return /* @__PURE__ */ a("span", { children: y.value }, T);
|
|
863
|
+
const M = t == null ? void 0 : t[y.value], j = Tn[E++ % Tn.length], L = l === T, G = !!M && (M.description || M.type || M.default || M.enum && M.enum.length > 0 || M.examples && M.examples.length > 0), Q = `channel-address-tooltip-${T}`, A = G && L ? Q : void 0;
|
|
864
864
|
return /* @__PURE__ */ g(
|
|
865
865
|
"span",
|
|
866
866
|
{
|
|
867
867
|
className: "inline-block",
|
|
868
|
-
onMouseEnter: (w) => G &&
|
|
869
|
-
onMouseLeave:
|
|
868
|
+
onMouseEnter: (w) => G && v(T, w.currentTarget),
|
|
869
|
+
onMouseLeave: C,
|
|
870
870
|
children: [
|
|
871
871
|
/* @__PURE__ */ a(
|
|
872
872
|
"span",
|
|
@@ -876,10 +876,10 @@ function ot({ address: e, parameters: t, className: n = "text-xs", truncate: r =
|
|
|
876
876
|
tabIndex: G ? 0 : void 0,
|
|
877
877
|
"aria-expanded": G ? L : void 0,
|
|
878
878
|
"aria-describedby": A,
|
|
879
|
-
onFocus: (w) => G &&
|
|
880
|
-
onBlur:
|
|
879
|
+
onFocus: (w) => G && v(T, w.currentTarget),
|
|
880
|
+
onBlur: C,
|
|
881
881
|
onKeyDown: (w) => {
|
|
882
|
-
G && ((w.key === "Enter" || w.key === " ") && (w.preventDefault(),
|
|
882
|
+
G && ((w.key === "Enter" || w.key === " ") && (w.preventDefault(), v(T, w.currentTarget)), w.key === "Escape" && (w.preventDefault(), C(), w.currentTarget.blur()));
|
|
883
883
|
},
|
|
884
884
|
children: `{${y.value}}`
|
|
885
885
|
}
|
|
@@ -912,7 +912,7 @@ function ot({ address: e, parameters: t, className: n = "text-xs", truncate: r =
|
|
|
912
912
|
)
|
|
913
913
|
]
|
|
914
914
|
},
|
|
915
|
-
|
|
915
|
+
T
|
|
916
916
|
);
|
|
917
917
|
}), k = o ? "px-2 py-1 " : "";
|
|
918
918
|
return r ? /* @__PURE__ */ g("code", { className: `${k}rounded text-foreground-secondary flex items-center min-w-0 ${n}`, children: [
|
|
@@ -944,7 +944,7 @@ function ot({ address: e, parameters: t, className: n = "text-xs", truncate: r =
|
|
|
944
944
|
role: "tooltip",
|
|
945
945
|
style: { top: h.top, left: h.left, width: Ps },
|
|
946
946
|
className: `fixed z-[60] rounded-lg border border-border bg-surface px-3 py-2 shadow-lg pointer-events-none ${h.placement === "top" ? "-translate-y-full" : ""}`,
|
|
947
|
-
children: /* @__PURE__ */ a("code", { className: "block break-all font-mono text-xs leading-relaxed text-foreground-secondary", children: nc(
|
|
947
|
+
children: /* @__PURE__ */ a("code", { className: "block break-all font-mono text-xs leading-relaxed text-foreground-secondary", children: nc(N) })
|
|
948
948
|
}
|
|
949
949
|
),
|
|
950
950
|
i
|
|
@@ -955,7 +955,7 @@ const rc = {
|
|
|
955
955
|
sm: "px-2.5 py-1 rounded-md text-xs",
|
|
956
956
|
xs: "px-1.5 py-0.5 rounded text-[10px]"
|
|
957
957
|
};
|
|
958
|
-
function
|
|
958
|
+
function ot({ method: e, size: t = "sm", className: n = "" }) {
|
|
959
959
|
return e ? /* @__PURE__ */ a(
|
|
960
960
|
"span",
|
|
961
961
|
{
|
|
@@ -1005,16 +1005,16 @@ function fc({
|
|
|
1005
1005
|
onItemSelect: r,
|
|
1006
1006
|
selectedItem: s
|
|
1007
1007
|
}) {
|
|
1008
|
-
const [o, i] = P(!1), [l, c] = P(!1), d = o || l, { rootElement: u, portalHost: f, topOffset: p = 0 } = $e(), h = ge(null), m = ge(null), [x, b] = P(null), [
|
|
1008
|
+
const [o, i] = P(!1), [l, c] = P(!1), d = o || l, { rootElement: u, portalHost: f, topOffset: p = 0 } = $e(), h = ge(null), m = ge(null), [x, b] = P(null), [N, E] = P(null), v = X(
|
|
1009
1009
|
() => e.filter((z) => z.items.length > 0),
|
|
1010
1010
|
[e]
|
|
1011
|
-
),
|
|
1012
|
-
() =>
|
|
1013
|
-
[
|
|
1011
|
+
), C = X(
|
|
1012
|
+
() => v.filter((z) => z.isTab === !1 || z.id === t),
|
|
1013
|
+
[v, t]
|
|
1014
1014
|
), F = X(
|
|
1015
|
-
() =>
|
|
1016
|
-
[
|
|
1017
|
-
), [H, S] = P(null), k = ge(null), y = ge(null),
|
|
1015
|
+
() => v.filter((z) => z.showInPopover !== !1),
|
|
1016
|
+
[v]
|
|
1017
|
+
), [H, S] = P(null), k = ge(null), y = ge(null), T = Os((z, $) => {
|
|
1018
1018
|
S({ section: z, key: $ }), k.current = { section: z, key: $ }, y.current && clearTimeout(y.current), y.current = setTimeout(() => {
|
|
1019
1019
|
k.current = null;
|
|
1020
1020
|
}, 600);
|
|
@@ -1054,19 +1054,19 @@ function fc({
|
|
|
1054
1054
|
);
|
|
1055
1055
|
return $.forEach((te) => ee.observe(te.el)), () => ee.disconnect();
|
|
1056
1056
|
}, [e]);
|
|
1057
|
-
const M = (H == null ? void 0 : H.section) ?? t, j = H ?? s, L = br(u, !0), G = typeof window > "u" ? 0 : window.innerWidth, Q = typeof window > "u" ? 0 : window.innerHeight, A = !!L && L.bottom > p && L.top < Q, w = Math.max((L == null ? void 0 : L.top) ?? p, p),
|
|
1057
|
+
const M = (H == null ? void 0 : H.section) ?? t, j = H ?? s, L = br(u, !0), G = typeof window > "u" ? 0 : window.innerWidth, Q = typeof window > "u" ? 0 : window.innerHeight, A = !!L && L.bottom > p && L.top < Q, w = Math.max((L == null ? void 0 : L.top) ?? p, p), I = Math.min((L == null ? void 0 : L.bottom) ?? Q, Q), D = Math.max(0, I - w), J = (w + I) / 2, [Y, ve] = P(null);
|
|
1058
1058
|
Mo(() => {
|
|
1059
|
-
if (!
|
|
1059
|
+
if (!N || !u) return;
|
|
1060
1060
|
const z = () => {
|
|
1061
|
-
const se =
|
|
1061
|
+
const se = N.getBoundingClientRect().left - u.getBoundingClientRect().left;
|
|
1062
1062
|
ve((ne) => ne === se ? ne : se);
|
|
1063
1063
|
};
|
|
1064
1064
|
z();
|
|
1065
1065
|
const $ = new ResizeObserver(z);
|
|
1066
|
-
return $.observe(
|
|
1066
|
+
return $.observe(N), $.observe(u), window.addEventListener("resize", z), () => {
|
|
1067
1067
|
$.disconnect(), window.removeEventListener("resize", z);
|
|
1068
1068
|
};
|
|
1069
|
-
}, [
|
|
1069
|
+
}, [N, u]);
|
|
1070
1070
|
const xe = Y === null ? null : ((L == null ? void 0 : L.left) ?? 0) + Y, fe = ((L == null ? void 0 : L.left) ?? 0) + cc, ue = xe !== null ? Math.max(fe, xe - js - dc) : fe, ae = xe !== null ? xe - fe >= js + uc : !!L && L.width >= 1024, B = !!L && !ae, q = {
|
|
1071
1071
|
opacity: A ? 1 : 0,
|
|
1072
1072
|
pointerEvents: A ? "auto" : "none",
|
|
@@ -1136,7 +1136,7 @@ function fc({
|
|
|
1136
1136
|
"button",
|
|
1137
1137
|
{
|
|
1138
1138
|
onClick: () => {
|
|
1139
|
-
pe(z),
|
|
1139
|
+
pe(z), T(z.id, ""), B && i(!1);
|
|
1140
1140
|
},
|
|
1141
1141
|
className: `group flex w-full items-center gap-2 rounded-md px-2 py-2 text-left transition-colors ${$ ? "bg-primary-50" : "hover:bg-neutral-50"}`,
|
|
1142
1142
|
children: [
|
|
@@ -1169,7 +1169,7 @@ function fc({
|
|
|
1169
1169
|
"button",
|
|
1170
1170
|
{
|
|
1171
1171
|
onClick: () => {
|
|
1172
|
-
pe(z, z.targetId(ee)), r(z.id, te),
|
|
1172
|
+
pe(z, z.targetId(ee)), r(z.id, te), T(z.id, te), B && i(!1);
|
|
1173
1173
|
},
|
|
1174
1174
|
className: `flex w-full items-center gap-2 rounded-md px-2 py-0.5 text-left text-xs transition-colors ${he ? "bg-primary-50 font-medium text-primary-700" : $ ? "text-foreground-secondary hover:bg-primary-50 hover:text-foreground" : "text-foreground-muted hover:bg-neutral-50 hover:text-foreground-secondary"}`,
|
|
1175
1175
|
children: z.renderItem(ee, { isSelected: he, isSectionActive: $ })
|
|
@@ -1177,12 +1177,12 @@ function fc({
|
|
|
1177
1177
|
) }, te);
|
|
1178
1178
|
}) })
|
|
1179
1179
|
] }, z.id);
|
|
1180
|
-
}), [F, M, j, B, pe, r,
|
|
1180
|
+
}), [F, M, j, B, pe, r, T]), me = ac(D, C.length), Ue = X(() => {
|
|
1181
1181
|
const z = lc(
|
|
1182
|
-
|
|
1182
|
+
C.map(($) => $.items.length),
|
|
1183
1183
|
me
|
|
1184
1184
|
);
|
|
1185
|
-
return
|
|
1185
|
+
return C.map(($, se) => {
|
|
1186
1186
|
const ne = M === $.id, ee = $.items.length, te = z[se];
|
|
1187
1187
|
let he = -1;
|
|
1188
1188
|
if ((j == null ? void 0 : j.section) === $.id) {
|
|
@@ -1207,7 +1207,7 @@ function fc({
|
|
|
1207
1207
|
)) })
|
|
1208
1208
|
] }, $.id);
|
|
1209
1209
|
});
|
|
1210
|
-
}, [
|
|
1210
|
+
}, [C, M, j, me]);
|
|
1211
1211
|
return /* @__PURE__ */ g(U, { children: [
|
|
1212
1212
|
/* @__PURE__ */ a("div", { ref: E, "aria-hidden": "true", className: `w-full ${Xr}`, style: { height: 0 } }),
|
|
1213
1213
|
!B && /* @__PURE__ */ a(
|
|
@@ -1444,7 +1444,7 @@ function hc({
|
|
|
1444
1444
|
var x;
|
|
1445
1445
|
const m = p(h);
|
|
1446
1446
|
return m != null && m.address ? /* @__PURE__ */ a(
|
|
1447
|
-
|
|
1447
|
+
et,
|
|
1448
1448
|
{
|
|
1449
1449
|
address: m.address,
|
|
1450
1450
|
parameters: m.parameters,
|
|
@@ -1453,7 +1453,7 @@ function hc({
|
|
|
1453
1453
|
className: "text-xs bg-transparent"
|
|
1454
1454
|
}
|
|
1455
1455
|
) : /* @__PURE__ */ g(U, { children: [
|
|
1456
|
-
/* @__PURE__ */ a(
|
|
1456
|
+
/* @__PURE__ */ a(ot, { method: (x = e[h]) == null ? void 0 : x.action, size: "xs", className: "shrink-0" }),
|
|
1457
1457
|
/* @__PURE__ */ a("span", { className: "truncate", children: h })
|
|
1458
1458
|
] });
|
|
1459
1459
|
}
|
|
@@ -1584,8 +1584,8 @@ function bc({
|
|
|
1584
1584
|
itemKey: (m) => m.key,
|
|
1585
1585
|
targetId: (m) => `endpoint-${m.key}`,
|
|
1586
1586
|
renderItem: (m) => /* @__PURE__ */ g(U, { children: [
|
|
1587
|
-
/* @__PURE__ */ a(
|
|
1588
|
-
/* @__PURE__ */ a(
|
|
1587
|
+
/* @__PURE__ */ a(ot, { method: m.method, size: "xs", className: "shrink-0" }),
|
|
1588
|
+
/* @__PURE__ */ a(et, { address: m.path, className: "text-[10px] bg-transparent p-0" })
|
|
1589
1589
|
] })
|
|
1590
1590
|
},
|
|
1591
1591
|
{
|
|
@@ -1596,7 +1596,7 @@ function bc({
|
|
|
1596
1596
|
itemKey: (m) => m.key,
|
|
1597
1597
|
targetId: (m) => `webhook-${m.key}`,
|
|
1598
1598
|
renderItem: (m) => /* @__PURE__ */ g(U, { children: [
|
|
1599
|
-
/* @__PURE__ */ a(
|
|
1599
|
+
/* @__PURE__ */ a(ot, { method: m.method, size: "xs", className: "shrink-0" }),
|
|
1600
1600
|
/* @__PURE__ */ a("span", { className: "truncate", children: m.path })
|
|
1601
1601
|
] })
|
|
1602
1602
|
},
|
|
@@ -1645,13 +1645,13 @@ function qo({
|
|
|
1645
1645
|
c(!1), u(-1);
|
|
1646
1646
|
};
|
|
1647
1647
|
K(() => (s == null || s(l), () => s == null ? void 0 : s(!1)), [l, s]);
|
|
1648
|
-
const
|
|
1648
|
+
const N = ge(!1), E = ge(!1);
|
|
1649
1649
|
K(() => {
|
|
1650
1650
|
if (!m) return;
|
|
1651
1651
|
const k = () => {
|
|
1652
|
-
|
|
1652
|
+
N.current = !0;
|
|
1653
1653
|
}, y = () => {
|
|
1654
|
-
|
|
1654
|
+
N.current = !1;
|
|
1655
1655
|
};
|
|
1656
1656
|
return m.addEventListener("mouseenter", k), m.addEventListener("mouseleave", y), () => {
|
|
1657
1657
|
m.removeEventListener("mouseenter", k), m.removeEventListener("mouseleave", y);
|
|
@@ -1665,7 +1665,7 @@ function qo({
|
|
|
1665
1665
|
}, [m]), K(() => {
|
|
1666
1666
|
if (!m) return;
|
|
1667
1667
|
const k = (y) => {
|
|
1668
|
-
!(y.metaKey || y.ctrlKey) || y.key.toLowerCase() !== "k" || !(m.contains(document.activeElement) ||
|
|
1668
|
+
!(y.metaKey || y.ctrlKey) || y.key.toLowerCase() !== "k" || !(m.contains(document.activeElement) || N.current || E.current) || (y.preventDefault(), c(!0));
|
|
1669
1669
|
};
|
|
1670
1670
|
return document.addEventListener("keydown", k), () => document.removeEventListener("keydown", k);
|
|
1671
1671
|
}, [m]), K(() => {
|
|
@@ -1696,14 +1696,14 @@ function qo({
|
|
|
1696
1696
|
var k;
|
|
1697
1697
|
d < 0 || (k = document.getElementById(p(d))) == null || k.scrollIntoView({ block: "nearest" });
|
|
1698
1698
|
}, [d]);
|
|
1699
|
-
const
|
|
1699
|
+
const v = l && e.trim().length > 0, C = (k) => {
|
|
1700
1700
|
b(), r(k);
|
|
1701
1701
|
}, F = (k) => {
|
|
1702
1702
|
if (k.key === "Escape") {
|
|
1703
1703
|
k.preventDefault(), b();
|
|
1704
1704
|
return;
|
|
1705
1705
|
}
|
|
1706
|
-
if (
|
|
1706
|
+
if (v) {
|
|
1707
1707
|
if (k.key === "ArrowDown") {
|
|
1708
1708
|
k.preventDefault(), u(
|
|
1709
1709
|
(y) => n.length === 0 ? -1 : Math.min(y + 1, n.length - 1)
|
|
@@ -1725,11 +1725,11 @@ function qo({
|
|
|
1725
1725
|
return;
|
|
1726
1726
|
}
|
|
1727
1727
|
if ((k.key === "Enter" || k.key === " ") && d >= 0 && n[d]) {
|
|
1728
|
-
k.preventDefault(),
|
|
1728
|
+
k.preventDefault(), C(n[d]);
|
|
1729
1729
|
return;
|
|
1730
1730
|
}
|
|
1731
1731
|
}
|
|
1732
|
-
}, H =
|
|
1732
|
+
}, H = v ? `${n.length} result${n.length === 1 ? "" : "s"} found` : "", S = typeof navigator < "u" && /Mac|iPod|iPhone|iPad/.test(navigator.userAgent);
|
|
1733
1733
|
return /* @__PURE__ */ g(U, { children: [
|
|
1734
1734
|
/* @__PURE__ */ a(
|
|
1735
1735
|
"button",
|
|
@@ -1771,7 +1771,7 @@ function qo({
|
|
|
1771
1771
|
"aria-label": "Search document",
|
|
1772
1772
|
role: "combobox",
|
|
1773
1773
|
"aria-haspopup": "listbox",
|
|
1774
|
-
"aria-expanded":
|
|
1774
|
+
"aria-expanded": v,
|
|
1775
1775
|
"aria-controls": f,
|
|
1776
1776
|
"aria-autocomplete": "list",
|
|
1777
1777
|
"aria-activedescendant": d >= 0 ? p(d) : void 0,
|
|
@@ -1779,7 +1779,7 @@ function qo({
|
|
|
1779
1779
|
}
|
|
1780
1780
|
) }),
|
|
1781
1781
|
/* @__PURE__ */ a("div", { "aria-live": "polite", className: "sr-only", children: H }),
|
|
1782
|
-
|
|
1782
|
+
v && /* @__PURE__ */ a(
|
|
1783
1783
|
"div",
|
|
1784
1784
|
{
|
|
1785
1785
|
id: f,
|
|
@@ -1792,7 +1792,7 @@ function qo({
|
|
|
1792
1792
|
type: "button",
|
|
1793
1793
|
role: "option",
|
|
1794
1794
|
"aria-selected": d === y,
|
|
1795
|
-
onClick: () =>
|
|
1795
|
+
onClick: () => C(k),
|
|
1796
1796
|
className: "w-full text-left px-4 py-3 hover:bg-neutral-50 " + (d === y ? "bg-neutral-100" : ""),
|
|
1797
1797
|
children: [
|
|
1798
1798
|
/* @__PURE__ */ a("div", { className: "text-sm font-semibold text-foreground", children: k.name }),
|
|
@@ -2560,52 +2560,52 @@ function Wc(e, t, n, { location: r = V.location, distance: s = V.distance, thres
|
|
|
2560
2560
|
if (t.length > 32) throw new Error(Ic(32));
|
|
2561
2561
|
const u = t.length, f = e.length, p = Math.max(0, Math.min(r, f));
|
|
2562
2562
|
let h = o, m = p;
|
|
2563
|
-
const x = (y,
|
|
2563
|
+
const x = (y, T) => {
|
|
2564
2564
|
const M = y / u;
|
|
2565
2565
|
if (d) return M;
|
|
2566
|
-
const j = Math.abs(p -
|
|
2566
|
+
const j = Math.abs(p - T);
|
|
2567
2567
|
return s ? M + j / s : j ? 1 : M;
|
|
2568
|
-
}, b = l > 1 || c,
|
|
2568
|
+
}, b = l > 1 || c, N = b ? Array(f) : [];
|
|
2569
2569
|
let E;
|
|
2570
2570
|
for (; (E = e.indexOf(t, m)) > -1; ) {
|
|
2571
2571
|
const y = x(0, E);
|
|
2572
2572
|
if (h = Math.min(y, h), m = E + u, b) {
|
|
2573
|
-
let
|
|
2574
|
-
for (;
|
|
2575
|
-
|
|
2573
|
+
let T = 0;
|
|
2574
|
+
for (; T < u; )
|
|
2575
|
+
N[E + T] = 1, T += 1;
|
|
2576
2576
|
}
|
|
2577
2577
|
}
|
|
2578
2578
|
m = -1;
|
|
2579
|
-
let
|
|
2579
|
+
let v = [], C = 1, F = 0, H = u + f;
|
|
2580
2580
|
const S = 1 << u - 1;
|
|
2581
2581
|
for (let y = 0; y < u; y += 1) {
|
|
2582
|
-
let
|
|
2583
|
-
for (;
|
|
2584
|
-
x(y, p + M) <= h ?
|
|
2582
|
+
let T = 0, M = H;
|
|
2583
|
+
for (; T < M; )
|
|
2584
|
+
x(y, p + M) <= h ? T = M : H = M, M = Math.floor((H - T) / 2 + T);
|
|
2585
2585
|
H = M;
|
|
2586
2586
|
let j = Math.max(1, p - M + 1);
|
|
2587
2587
|
const L = i ? f : Math.min(p + M, f) + u, G = Array(L + 2);
|
|
2588
2588
|
G[L + 1] = (1 << y) - 1;
|
|
2589
2589
|
for (let Q = L; Q >= j; Q -= 1) {
|
|
2590
2590
|
const A = Q - 1, w = n[e[A]];
|
|
2591
|
-
if (G[Q] = (G[Q + 1] << 1 | 1) & w, y && (G[Q] |= (
|
|
2592
|
-
if (h =
|
|
2591
|
+
if (G[Q] = (G[Q + 1] << 1 | 1) & w, y && (G[Q] |= (v[Q + 1] | v[Q]) << 1 | 1 | v[Q + 1]), G[Q] & S && (C = x(y, A), C <= h)) {
|
|
2592
|
+
if (h = C, m = A, F = y, m <= p) break;
|
|
2593
2593
|
j = Math.max(1, 2 * p - m);
|
|
2594
2594
|
}
|
|
2595
2595
|
}
|
|
2596
2596
|
if (x(y + 1, p) > h) break;
|
|
2597
|
-
|
|
2597
|
+
v = G;
|
|
2598
2598
|
}
|
|
2599
2599
|
if (b && m >= 0) {
|
|
2600
2600
|
const y = Math.min(f - 1, m + u - 1 + F);
|
|
2601
|
-
for (let
|
|
2601
|
+
for (let T = m; T <= y; T += 1) n[e[T]] && (N[T] = 1);
|
|
2602
2602
|
}
|
|
2603
2603
|
const k = {
|
|
2604
2604
|
isMatch: m >= 0,
|
|
2605
|
-
score: Math.max(1e-3,
|
|
2605
|
+
score: Math.max(1e-3, C)
|
|
2606
2606
|
};
|
|
2607
2607
|
if (b) {
|
|
2608
|
-
const y = Uc(
|
|
2608
|
+
const y = Uc(N, l);
|
|
2609
2609
|
y.length ? c && (k.indices = y) : k.isMatch = !1;
|
|
2610
2610
|
}
|
|
2611
2611
|
return k;
|
|
@@ -2689,7 +2689,7 @@ var rs = class {
|
|
|
2689
2689
|
const { location: s, distance: o, threshold: i, findAllMatches: l, minMatchCharLength: c, ignoreLocation: d } = this.options, u = [];
|
|
2690
2690
|
let f = 0, p = !1;
|
|
2691
2691
|
this.chunks.forEach(({ pattern: m, alphabet: x, startIndex: b }) => {
|
|
2692
|
-
const { isMatch:
|
|
2692
|
+
const { isMatch: N, score: E, indices: v } = Wc(e, m, x, {
|
|
2693
2693
|
location: s + b,
|
|
2694
2694
|
distance: o,
|
|
2695
2695
|
threshold: i,
|
|
@@ -2698,7 +2698,7 @@ var rs = class {
|
|
|
2698
2698
|
includeMatches: r,
|
|
2699
2699
|
ignoreLocation: d
|
|
2700
2700
|
});
|
|
2701
|
-
|
|
2701
|
+
N && (p = !0), f += E, N && v && u.push(...v);
|
|
2702
2702
|
});
|
|
2703
2703
|
const h = {
|
|
2704
2704
|
isMatch: p,
|
|
@@ -2942,9 +2942,9 @@ var qc = class {
|
|
|
2942
2942
|
const f = t[d];
|
|
2943
2943
|
i.length = 0, o = 0, c = !1;
|
|
2944
2944
|
for (let p = 0, h = f.length; p < h; p += 1) {
|
|
2945
|
-
const m = f[p], { isMatch: x, indices: b, score:
|
|
2945
|
+
const m = f[p], { isMatch: x, indices: b, score: N } = m.search(e);
|
|
2946
2946
|
if (x)
|
|
2947
|
-
o += 1, l +=
|
|
2947
|
+
o += 1, l += N, Jc(m.type) && (c = !0), n && (Vc.has(m.type) ? i.push(...b) : i.push(b));
|
|
2948
2948
|
else {
|
|
2949
2949
|
l = 0, o = 0, i.length = 0, c = !1;
|
|
2950
2950
|
break;
|
|
@@ -3350,10 +3350,10 @@ var at = class {
|
|
|
3350
3350
|
if (!("children" in l)) {
|
|
3351
3351
|
const { keyId: h, searcher: m } = l;
|
|
3352
3352
|
let x;
|
|
3353
|
-
return h === null ? (x = [], n.forEach((b,
|
|
3353
|
+
return h === null ? (x = [], n.forEach((b, N) => {
|
|
3354
3354
|
x.push(...this._findMatches({
|
|
3355
3355
|
key: b,
|
|
3356
|
-
value: c[
|
|
3356
|
+
value: c[N],
|
|
3357
3357
|
searcher: m
|
|
3358
3358
|
}));
|
|
3359
3359
|
})) : x = this._findMatches({
|
|
@@ -3601,37 +3601,37 @@ function pi({
|
|
|
3601
3601
|
}, [x, b] = P(() => {
|
|
3602
3602
|
const w = {};
|
|
3603
3603
|
return d && (o != null && o.key) && (w[d] = o.key), w;
|
|
3604
|
-
}),
|
|
3604
|
+
}), N = e.some((w) => w.id === u) ? u : c, E = {};
|
|
3605
3605
|
for (const w of r)
|
|
3606
3606
|
E[w.id] = w.visible ? x[w.id] ?? null : null;
|
|
3607
|
-
const
|
|
3607
|
+
const v = (w, I) => b((D) => ({ ...D, [w]: I })), [C, F] = P(null), [H, S] = P(null), [k, y] = P(null), T = (w) => {
|
|
3608
3608
|
n(w.tab) ? m(w.tab) : w.tab === "servers" && h("servers");
|
|
3609
|
-
const
|
|
3609
|
+
const I = {};
|
|
3610
3610
|
for (const D of r)
|
|
3611
|
-
|
|
3612
|
-
b(
|
|
3611
|
+
I[D.id] = D.id === w.tab ? w.key : null;
|
|
3612
|
+
b(I), F(w.focusSection ?? null), S(
|
|
3613
3613
|
w.tab === "schemas" && w.schemaFocusTokens ? { tokens: w.schemaFocusTokens, id: w.targetId } : null
|
|
3614
3614
|
), w.tab === "schemas" && rr(), y({ targetId: w.targetId, query: s, highlight: w.tab !== "schemas" });
|
|
3615
|
-
}, M = (w,
|
|
3615
|
+
}, M = (w, I) => {
|
|
3616
3616
|
m(w), b((D) => {
|
|
3617
3617
|
const J = { ...D };
|
|
3618
3618
|
for (const Y of r)
|
|
3619
|
-
Y.id !== "servers" && (J[Y.id] = Y.id === w ?
|
|
3619
|
+
Y.id !== "servers" && (J[Y.id] = Y.id === w ? I : null);
|
|
3620
3620
|
return J;
|
|
3621
3621
|
});
|
|
3622
3622
|
}, j = (w) => {
|
|
3623
3623
|
h("servers");
|
|
3624
|
-
const
|
|
3624
|
+
const I = {};
|
|
3625
3625
|
for (const D of r)
|
|
3626
|
-
|
|
3627
|
-
b(
|
|
3626
|
+
I[D.id] = D.id === "servers" ? w : null;
|
|
3627
|
+
b(I);
|
|
3628
3628
|
}, L = (w) => {
|
|
3629
3629
|
n(w) && m(w);
|
|
3630
3630
|
}, G = X(
|
|
3631
3631
|
() => {
|
|
3632
3632
|
for (const w of r) {
|
|
3633
|
-
const
|
|
3634
|
-
if (
|
|
3633
|
+
const I = E[w.id];
|
|
3634
|
+
if (I) return { tab: w.id, key: I };
|
|
3635
3635
|
}
|
|
3636
3636
|
return null;
|
|
3637
3637
|
},
|
|
@@ -3639,34 +3639,34 @@ function pi({
|
|
|
3639
3639
|
[...r.map((w) => E[w.id])]
|
|
3640
3640
|
);
|
|
3641
3641
|
Vs(k, [
|
|
3642
|
-
|
|
3643
|
-
|
|
3642
|
+
N,
|
|
3643
|
+
C,
|
|
3644
3644
|
H,
|
|
3645
3645
|
...r.map((w) => E[w.id])
|
|
3646
3646
|
]);
|
|
3647
3647
|
const [Q] = P(
|
|
3648
3648
|
() => d && (o != null && o.key) && l ? { targetId: l(d, o.key), query: "", highlight: !1 } : null
|
|
3649
3649
|
);
|
|
3650
|
-
return Vs(Q, [
|
|
3650
|
+
return Vs(Q, [N]), K(() => {
|
|
3651
3651
|
i == null || i(
|
|
3652
|
-
G ? { tab: G.tab, key: G.key } : { tab:
|
|
3652
|
+
G ? { tab: G.tab, key: G.key } : { tab: N, key: null }
|
|
3653
3653
|
);
|
|
3654
|
-
}, [
|
|
3654
|
+
}, [N, G]), K(() => {
|
|
3655
3655
|
s.trim() || (y(null), rr());
|
|
3656
3656
|
}, [s]), K(() => rr, []), {
|
|
3657
|
-
effectiveTab:
|
|
3657
|
+
effectiveTab: N,
|
|
3658
3658
|
focusTab: m,
|
|
3659
3659
|
/** What the sidebar nav should show as active: the focused section, falling back to the content tab. */
|
|
3660
|
-
navActiveSection: p ??
|
|
3660
|
+
navActiveSection: p ?? N,
|
|
3661
3661
|
/** Per-section selections, clamped to visible sections. */
|
|
3662
3662
|
selected: E,
|
|
3663
|
-
setSelectedKey:
|
|
3663
|
+
setSelectedKey: v,
|
|
3664
3664
|
selectedNavItem: G,
|
|
3665
|
-
handleSearchSelect:
|
|
3665
|
+
handleSearchSelect: T,
|
|
3666
3666
|
handleNavItemSelect: M,
|
|
3667
3667
|
handleNavServerSelect: j,
|
|
3668
3668
|
handleContentTabChange: L,
|
|
3669
|
-
focusSection:
|
|
3669
|
+
focusSection: C,
|
|
3670
3670
|
schemaFocusTarget: H
|
|
3671
3671
|
};
|
|
3672
3672
|
}
|
|
@@ -3932,7 +3932,7 @@ function yt(e, t, n, r) {
|
|
|
3932
3932
|
let _n = null, sr = null;
|
|
3933
3933
|
const _r = /* @__PURE__ */ new Set();
|
|
3934
3934
|
function $d() {
|
|
3935
|
-
return sr || (sr = import("./protoToJsonSchema-
|
|
3935
|
+
return sr || (sr = import("./protoToJsonSchema-DSskBSDK.js").then((e) => {
|
|
3936
3936
|
_n = e.protoToJsonSchema, _r.forEach((t) => t());
|
|
3937
3937
|
})), sr;
|
|
3938
3938
|
}
|
|
@@ -4336,9 +4336,9 @@ function wi(e, t, n, r, s, o) {
|
|
|
4336
4336
|
const f = n.responses ?? {};
|
|
4337
4337
|
for (const [h, m] of Object.entries(f)) {
|
|
4338
4338
|
const x = [ye(4, `${h}${m.description ? `: ${R(m.description)}` : ""}`)];
|
|
4339
|
-
for (const [b,
|
|
4339
|
+
for (const [b, N] of Object.entries(m.content ?? {}))
|
|
4340
4340
|
x.push(
|
|
4341
|
-
[`**Body** (\`${R(b)}\`)`, Mn("body",
|
|
4341
|
+
[`**Body** (\`${R(b)}\`)`, Mn("body", N.schema, r)].join(
|
|
4342
4342
|
`
|
|
4343
4343
|
|
|
4344
4344
|
`
|
|
@@ -4445,7 +4445,7 @@ function Ni(e) {
|
|
|
4445
4445
|
const Ai = {
|
|
4446
4446
|
"x-x": () => import("./XExtension-GyRtdHLL.js"),
|
|
4447
4447
|
"x-linkedin": () => import("./LinkedInExtension-BL-4T9tt.js")
|
|
4448
|
-
}, Vd = () => import("./LogoExtension-
|
|
4448
|
+
}, Vd = () => import("./LogoExtension-DZ4kFXRU.js");
|
|
4449
4449
|
function ls() {
|
|
4450
4450
|
return {
|
|
4451
4451
|
async: !1,
|
|
@@ -4853,22 +4853,22 @@ ${u}` : u;
|
|
|
4853
4853
|
break;
|
|
4854
4854
|
d = t[0], e = e.substring(d.length);
|
|
4855
4855
|
let f = t[2].split(`
|
|
4856
|
-
`, 1)[0].replace(this.rules.other.listReplaceTabs, (
|
|
4856
|
+
`, 1)[0].replace(this.rules.other.listReplaceTabs, (N) => " ".repeat(3 * N.length)), p = e.split(`
|
|
4857
4857
|
`, 1)[0], h = !f.trim(), m = 0;
|
|
4858
4858
|
if (this.options.pedantic ? (m = 2, u = f.trimStart()) : h ? m = t[1].length + 1 : (m = t[2].search(this.rules.other.nonSpaceChar), m = m > 4 ? 1 : m, u = f.slice(m), m += t[1].length), h && this.rules.other.blankLine.test(p) && (d += p + `
|
|
4859
4859
|
`, e = e.substring(p.length + 1), c = !0), !c) {
|
|
4860
|
-
const
|
|
4860
|
+
const N = this.rules.other.nextBulletRegex(m), E = this.rules.other.hrRegex(m), v = this.rules.other.fencesBeginRegex(m), C = this.rules.other.headingBeginRegex(m), F = this.rules.other.htmlBeginRegex(m);
|
|
4861
4861
|
for (; e; ) {
|
|
4862
4862
|
const H = e.split(`
|
|
4863
4863
|
`, 1)[0];
|
|
4864
4864
|
let S;
|
|
4865
|
-
if (p = H, this.options.pedantic ? (p = p.replace(this.rules.other.listReplaceNesting, " "), S = p) : S = p.replace(this.rules.other.tabCharGlobal, " "),
|
|
4865
|
+
if (p = H, this.options.pedantic ? (p = p.replace(this.rules.other.listReplaceNesting, " "), S = p) : S = p.replace(this.rules.other.tabCharGlobal, " "), v.test(p) || C.test(p) || F.test(p) || N.test(p) || E.test(p))
|
|
4866
4866
|
break;
|
|
4867
4867
|
if (S.search(this.rules.other.nonSpaceChar) >= m || !p.trim())
|
|
4868
4868
|
u += `
|
|
4869
4869
|
` + S.slice(m);
|
|
4870
4870
|
else {
|
|
4871
|
-
if (h || f.replace(this.rules.other.tabCharGlobal, " ").search(this.rules.other.nonSpaceChar) >= 4 ||
|
|
4871
|
+
if (h || f.replace(this.rules.other.tabCharGlobal, " ").search(this.rules.other.nonSpaceChar) >= 4 || v.test(f) || C.test(f) || E.test(f))
|
|
4872
4872
|
break;
|
|
4873
4873
|
u += `
|
|
4874
4874
|
` + p;
|
|
@@ -6105,7 +6105,7 @@ class lo {
|
|
|
6105
6105
|
function Fi(e) {
|
|
6106
6106
|
return e.replace(/&/g, "&").replace(/</g, "<").replace(/>/g, ">").replace(/"/g, """).replace(/'/g, "'");
|
|
6107
6107
|
}
|
|
6108
|
-
function
|
|
6108
|
+
function st(e, ...t) {
|
|
6109
6109
|
const n = /* @__PURE__ */ Object.create(null);
|
|
6110
6110
|
for (const r in e)
|
|
6111
6111
|
n[r] = e[r];
|
|
@@ -6336,7 +6336,7 @@ const Uu = /\b\B/, Ui = "[a-zA-Z]\\w*", xs = "[a-zA-Z_]\\w*", Wi = "\\b\\d+(\\.\
|
|
|
6336
6336
|
/.*\b/,
|
|
6337
6337
|
e.binary,
|
|
6338
6338
|
/\b.*/
|
|
6339
|
-
)),
|
|
6339
|
+
)), st({
|
|
6340
6340
|
scope: "meta",
|
|
6341
6341
|
begin: t,
|
|
6342
6342
|
end: /$/,
|
|
@@ -6364,7 +6364,7 @@ const Uu = /\b\B/, Ui = "[a-zA-Z]\\w*", xs = "[a-zA-Z_]\\w*", Wi = "\\b\\d+(\\.\
|
|
|
6364
6364
|
}, Ju = {
|
|
6365
6365
|
begin: /\b(a|an|the|are|I'm|isn't|don't|doesn't|won't|but|just|should|pretty|simply|enough|gonna|going|wtf|so|such|will|you|your|they|like|more)\b/
|
|
6366
6366
|
}, Yn = function(e, t, n = {}) {
|
|
6367
|
-
const r =
|
|
6367
|
+
const r = st(
|
|
6368
6368
|
{
|
|
6369
6369
|
scope: "comment",
|
|
6370
6370
|
begin: e,
|
|
@@ -6719,7 +6719,7 @@ function vf(e) {
|
|
|
6719
6719
|
}
|
|
6720
6720
|
if (e.compilerExtensions || (e.compilerExtensions = []), e.contains && e.contains.includes("self"))
|
|
6721
6721
|
throw new Error("ERR: contains `self` is not supported at the top-level of a language. See documentation.");
|
|
6722
|
-
return e.classNameAliases =
|
|
6722
|
+
return e.classNameAliases = st(e.classNameAliases || {}), o(
|
|
6723
6723
|
/** @type Mode */
|
|
6724
6724
|
e
|
|
6725
6725
|
);
|
|
@@ -6729,8 +6729,8 @@ function Zi(e) {
|
|
|
6729
6729
|
}
|
|
6730
6730
|
function Nf(e) {
|
|
6731
6731
|
return e.variants && !e.cachedVariants && (e.cachedVariants = e.variants.map(function(t) {
|
|
6732
|
-
return
|
|
6733
|
-
})), e.cachedVariants ? e.cachedVariants : Zi(e) ?
|
|
6732
|
+
return st(e, { variants: null }, t);
|
|
6733
|
+
})), e.cachedVariants ? e.cachedVariants : Zi(e) ? st(e, { starts: e.starts ? st(e.starts) : null }) : Object.isFrozen(e) ? st(e) : e;
|
|
6734
6734
|
}
|
|
6735
6735
|
var Af = "11.12.0";
|
|
6736
6736
|
class Sf extends Error {
|
|
@@ -6738,7 +6738,7 @@ class Sf extends Error {
|
|
|
6738
6738
|
super(t), this.name = "HTMLInjectionError", this.html = n;
|
|
6739
6739
|
}
|
|
6740
6740
|
}
|
|
6741
|
-
const or = Fi, ho =
|
|
6741
|
+
const or = Fi, ho = st, mo = Symbol("nomatch"), Ef = 7, Xi = function(e) {
|
|
6742
6742
|
const t = /* @__PURE__ */ Object.create(null), n = /* @__PURE__ */ Object.create(null), r = [];
|
|
6743
6743
|
let s = !0;
|
|
6744
6744
|
const o = "Could not find the language '{}', did you forget to load/include a language module?", i = { disableAutodetect: !0, name: "Plain text", contains: [] };
|
|
@@ -6760,26 +6760,26 @@ const or = Fi, ho = rt, mo = Symbol("nomatch"), Ef = 7, Xi = function(e) {
|
|
|
6760
6760
|
function d(A) {
|
|
6761
6761
|
let w = A.className + " ";
|
|
6762
6762
|
w += A.parentNode ? A.parentNode.className : "";
|
|
6763
|
-
const
|
|
6764
|
-
if (
|
|
6765
|
-
const D = k(
|
|
6766
|
-
return D || (po(o.replace("{}",
|
|
6763
|
+
const I = l.languageDetectRe.exec(w);
|
|
6764
|
+
if (I) {
|
|
6765
|
+
const D = k(I[1]);
|
|
6766
|
+
return D || (po(o.replace("{}", I[1])), po("Falling back to no-highlight mode for this block.", A)), D ? I[1] : "no-highlight";
|
|
6767
6767
|
}
|
|
6768
6768
|
return w.split(/\s+/).find((D) => c(D) || k(D));
|
|
6769
6769
|
}
|
|
6770
|
-
function u(A, w,
|
|
6770
|
+
function u(A, w, I) {
|
|
6771
6771
|
let D = "", J = "";
|
|
6772
|
-
typeof w == "object" ? (D = A,
|
|
6773
|
-
https://github.com/highlightjs/highlight.js/issues/2277`), J = A, D = w),
|
|
6772
|
+
typeof w == "object" ? (D = A, I = w.ignoreIllegals, J = w.language) : (bt("10.7.0", "highlight(lang, code, ...args) has been deprecated."), bt("10.7.0", `Please use highlight(code, options) instead.
|
|
6773
|
+
https://github.com/highlightjs/highlight.js/issues/2277`), J = A, D = w), I === void 0 && (I = !0);
|
|
6774
6774
|
const Y = {
|
|
6775
6775
|
code: D,
|
|
6776
6776
|
language: J
|
|
6777
6777
|
};
|
|
6778
6778
|
G("before:highlight", Y);
|
|
6779
|
-
const ve = Y.result ? Y.result : f(Y.language, Y.code,
|
|
6779
|
+
const ve = Y.result ? Y.result : f(Y.language, Y.code, I);
|
|
6780
6780
|
return ve.code = Y.code, G("after:highlight", ve), ve;
|
|
6781
6781
|
}
|
|
6782
|
-
function f(A, w,
|
|
6782
|
+
function f(A, w, I, D) {
|
|
6783
6783
|
const J = /* @__PURE__ */ Object.create(null);
|
|
6784
6784
|
function Y(O, _) {
|
|
6785
6785
|
return O.keywords[_];
|
|
@@ -6901,7 +6901,7 @@ https://github.com/highlightjs/highlight.js/issues/2277`), J = A, D = w), T ===
|
|
|
6901
6901
|
}
|
|
6902
6902
|
if (pe = _, _.type === "begin")
|
|
6903
6903
|
return le(_);
|
|
6904
|
-
if (_.type === "illegal" && !
|
|
6904
|
+
if (_.type === "illegal" && !I) {
|
|
6905
6905
|
const re = new Error('Illegal lexeme "' + W + '" for mode "' + ($.scope || "<unnamed>") + '"');
|
|
6906
6906
|
throw re.mode = $, re;
|
|
6907
6907
|
} else if (_.type === "end") {
|
|
@@ -6986,10 +6986,10 @@ https://github.com/highlightjs/highlight.js/issues/2277`), J = A, D = w), T ===
|
|
|
6986
6986
|
}
|
|
6987
6987
|
function h(A, w) {
|
|
6988
6988
|
w = w || l.languages || Object.keys(t);
|
|
6989
|
-
const
|
|
6989
|
+
const I = p(A), D = w.filter(k).filter(T).map(
|
|
6990
6990
|
(fe) => f(fe, A, !1)
|
|
6991
6991
|
);
|
|
6992
|
-
D.unshift(
|
|
6992
|
+
D.unshift(I);
|
|
6993
6993
|
const J = D.sort((fe, ue) => {
|
|
6994
6994
|
if (fe.relevance !== ue.relevance) return ue.relevance - fe.relevance;
|
|
6995
6995
|
if (fe.language && ue.language) {
|
|
@@ -7002,17 +7002,17 @@ https://github.com/highlightjs/highlight.js/issues/2277`), J = A, D = w), T ===
|
|
|
7002
7002
|
}), [Y, ve] = J, xe = Y;
|
|
7003
7003
|
return xe.secondBest = ve, xe;
|
|
7004
7004
|
}
|
|
7005
|
-
function m(A, w,
|
|
7006
|
-
const D = w && n[w] ||
|
|
7005
|
+
function m(A, w, I) {
|
|
7006
|
+
const D = w && n[w] || I;
|
|
7007
7007
|
A.classList.add("hljs"), A.classList.add(`language-${D}`);
|
|
7008
7008
|
}
|
|
7009
7009
|
function x(A) {
|
|
7010
7010
|
let w = null;
|
|
7011
|
-
const
|
|
7012
|
-
if (c(
|
|
7011
|
+
const I = d(A);
|
|
7012
|
+
if (c(I)) return;
|
|
7013
7013
|
if (G(
|
|
7014
7014
|
"before:highlightElement",
|
|
7015
|
-
{ el: A, language:
|
|
7015
|
+
{ el: A, language: I }
|
|
7016
7016
|
), A.dataset.highlighted) {
|
|
7017
7017
|
console.log("Element previously highlighted. To highlight again, first unset `dataset.highlighted`.", A);
|
|
7018
7018
|
return;
|
|
@@ -7023,8 +7023,8 @@ https://github.com/highlightjs/highlight.js/issues/2277`), J = A, D = w), T ===
|
|
|
7023
7023
|
A.innerHTML
|
|
7024
7024
|
);
|
|
7025
7025
|
w = A;
|
|
7026
|
-
const D = w.textContent, J =
|
|
7027
|
-
A.innerHTML = J.value, A.dataset.highlighted = "yes", m(A,
|
|
7026
|
+
const D = w.textContent, J = I ? u(D, { language: I, ignoreIllegals: !0 }) : h(D);
|
|
7027
|
+
A.innerHTML = J.value, A.dataset.highlighted = "yes", m(A, I, J.language), A.result = {
|
|
7028
7028
|
language: J.language,
|
|
7029
7029
|
// TODO: remove with version 11.0
|
|
7030
7030
|
re: J.relevance,
|
|
@@ -7037,35 +7037,35 @@ https://github.com/highlightjs/highlight.js/issues/2277`), J = A, D = w), T ===
|
|
|
7037
7037
|
function b(A) {
|
|
7038
7038
|
l = ho(l, A);
|
|
7039
7039
|
}
|
|
7040
|
-
const
|
|
7041
|
-
|
|
7040
|
+
const N = () => {
|
|
7041
|
+
C(), bt("10.6.0", "initHighlighting() deprecated. Use highlightAll() now.");
|
|
7042
7042
|
};
|
|
7043
7043
|
function E() {
|
|
7044
|
-
|
|
7044
|
+
C(), bt("10.6.0", "initHighlightingOnLoad() deprecated. Use highlightAll() now.");
|
|
7045
7045
|
}
|
|
7046
|
-
let
|
|
7047
|
-
function
|
|
7046
|
+
let v = !1;
|
|
7047
|
+
function C() {
|
|
7048
7048
|
function A() {
|
|
7049
|
-
|
|
7049
|
+
C();
|
|
7050
7050
|
}
|
|
7051
7051
|
if (document.readyState === "loading") {
|
|
7052
|
-
|
|
7052
|
+
v || window.addEventListener("DOMContentLoaded", A, !1), v = !0;
|
|
7053
7053
|
return;
|
|
7054
7054
|
}
|
|
7055
7055
|
document.querySelectorAll(l.cssSelector).forEach(x);
|
|
7056
7056
|
}
|
|
7057
7057
|
function F(A, w) {
|
|
7058
|
-
let
|
|
7058
|
+
let I = null;
|
|
7059
7059
|
try {
|
|
7060
|
-
|
|
7060
|
+
I = w(e);
|
|
7061
7061
|
} catch (D) {
|
|
7062
7062
|
if (dt("Language definition for '{}' could not be registered.".replace("{}", A)), s)
|
|
7063
7063
|
dt(D);
|
|
7064
7064
|
else
|
|
7065
7065
|
throw D;
|
|
7066
|
-
|
|
7066
|
+
I = i;
|
|
7067
7067
|
}
|
|
7068
|
-
|
|
7068
|
+
I.name || (I.name = A), t[A] = I, I.rawDefinition = w.bind(null, e), I.aliases && y(I.aliases, { languageName: A });
|
|
7069
7069
|
}
|
|
7070
7070
|
function H(A) {
|
|
7071
7071
|
delete t[A];
|
|
@@ -7079,11 +7079,11 @@ https://github.com/highlightjs/highlight.js/issues/2277`), J = A, D = w), T ===
|
|
|
7079
7079
|
return A = (A || "").toLowerCase(), t[A] || t[n[A]];
|
|
7080
7080
|
}
|
|
7081
7081
|
function y(A, { languageName: w }) {
|
|
7082
|
-
typeof A == "string" && (A = [A]), A.forEach((
|
|
7083
|
-
n[
|
|
7082
|
+
typeof A == "string" && (A = [A]), A.forEach((I) => {
|
|
7083
|
+
n[I.toLowerCase()] = w;
|
|
7084
7084
|
});
|
|
7085
7085
|
}
|
|
7086
|
-
function
|
|
7086
|
+
function T(A) {
|
|
7087
7087
|
const w = k(A);
|
|
7088
7088
|
return w && !w.disableAutodetect;
|
|
7089
7089
|
}
|
|
@@ -7106,9 +7106,9 @@ https://github.com/highlightjs/highlight.js/issues/2277`), J = A, D = w), T ===
|
|
|
7106
7106
|
w !== -1 && r.splice(w, 1);
|
|
7107
7107
|
}
|
|
7108
7108
|
function G(A, w) {
|
|
7109
|
-
const
|
|
7109
|
+
const I = A;
|
|
7110
7110
|
r.forEach(function(D) {
|
|
7111
|
-
D[
|
|
7111
|
+
D[I] && D[I](w);
|
|
7112
7112
|
});
|
|
7113
7113
|
}
|
|
7114
7114
|
function Q(A) {
|
|
@@ -7117,19 +7117,19 @@ https://github.com/highlightjs/highlight.js/issues/2277`), J = A, D = w), T ===
|
|
|
7117
7117
|
Object.assign(e, {
|
|
7118
7118
|
highlight: u,
|
|
7119
7119
|
highlightAuto: h,
|
|
7120
|
-
highlightAll:
|
|
7120
|
+
highlightAll: C,
|
|
7121
7121
|
highlightElement: x,
|
|
7122
7122
|
// TODO: Remove with v12 API
|
|
7123
7123
|
highlightBlock: Q,
|
|
7124
7124
|
configure: b,
|
|
7125
|
-
initHighlighting:
|
|
7125
|
+
initHighlighting: N,
|
|
7126
7126
|
initHighlightingOnLoad: E,
|
|
7127
7127
|
registerLanguage: F,
|
|
7128
7128
|
unregisterLanguage: H,
|
|
7129
7129
|
listLanguages: S,
|
|
7130
7130
|
getLanguage: k,
|
|
7131
7131
|
registerAliases: y,
|
|
7132
|
-
autoDetection:
|
|
7132
|
+
autoDetection: T,
|
|
7133
7133
|
inherit: ho,
|
|
7134
7134
|
addPlugin: j,
|
|
7135
7135
|
removePlugin: L
|
|
@@ -7365,8 +7365,8 @@ function Of(e) {
|
|
|
7365
7365
|
x,
|
|
7366
7366
|
o,
|
|
7367
7367
|
i
|
|
7368
|
-
],
|
|
7369
|
-
return
|
|
7368
|
+
], N = [...b];
|
|
7369
|
+
return N.pop(), N.push(l), h.contains = N, {
|
|
7370
7370
|
name: "YAML",
|
|
7371
7371
|
case_insensitive: !0,
|
|
7372
7372
|
aliases: ["yml"],
|
|
@@ -7493,7 +7493,7 @@ function _f(e) {
|
|
|
7493
7493
|
], b = [
|
|
7494
7494
|
"true",
|
|
7495
7495
|
"false"
|
|
7496
|
-
],
|
|
7496
|
+
], N = { match: /(\/[a-z._-]+)+/ }, E = [
|
|
7497
7497
|
"break",
|
|
7498
7498
|
"cd",
|
|
7499
7499
|
"continue",
|
|
@@ -7512,7 +7512,7 @@ function _f(e) {
|
|
|
7512
7512
|
"trap",
|
|
7513
7513
|
"umask",
|
|
7514
7514
|
"unset"
|
|
7515
|
-
],
|
|
7515
|
+
], v = [
|
|
7516
7516
|
"alias",
|
|
7517
7517
|
"bind",
|
|
7518
7518
|
"builtin",
|
|
@@ -7535,7 +7535,7 @@ function _f(e) {
|
|
|
7535
7535
|
"typeset",
|
|
7536
7536
|
"ulimit",
|
|
7537
7537
|
"unalias"
|
|
7538
|
-
],
|
|
7538
|
+
], C = [
|
|
7539
7539
|
"autoload",
|
|
7540
7540
|
"bg",
|
|
7541
7541
|
"bindkey",
|
|
@@ -7721,11 +7721,11 @@ function _f(e) {
|
|
|
7721
7721
|
literal: b,
|
|
7722
7722
|
built_in: [
|
|
7723
7723
|
...E,
|
|
7724
|
-
...
|
|
7724
|
+
...v,
|
|
7725
7725
|
// Shell modifiers
|
|
7726
7726
|
"set",
|
|
7727
7727
|
"shopt",
|
|
7728
|
-
...
|
|
7728
|
+
...C,
|
|
7729
7729
|
...F
|
|
7730
7730
|
]
|
|
7731
7731
|
},
|
|
@@ -7738,7 +7738,7 @@ function _f(e) {
|
|
|
7738
7738
|
f,
|
|
7739
7739
|
o,
|
|
7740
7740
|
i,
|
|
7741
|
-
|
|
7741
|
+
N,
|
|
7742
7742
|
l,
|
|
7743
7743
|
c,
|
|
7744
7744
|
d,
|
|
@@ -7895,9 +7895,9 @@ const go = "[A-Za-z$_][0-9A-Za-z$_]*", Mf = [
|
|
|
7895
7895
|
Qi
|
|
7896
7896
|
);
|
|
7897
7897
|
function Bf(e) {
|
|
7898
|
-
const t = e.regex, n = (
|
|
7899
|
-
const J = "</" +
|
|
7900
|
-
return
|
|
7898
|
+
const t = e.regex, n = (I, { after: D }) => {
|
|
7899
|
+
const J = "</" + I[0].slice(1);
|
|
7900
|
+
return I.input.indexOf(J, D) !== -1;
|
|
7901
7901
|
}, r = go, s = {
|
|
7902
7902
|
begin: "<>",
|
|
7903
7903
|
end: "</>"
|
|
@@ -7908,8 +7908,8 @@ function Bf(e) {
|
|
|
7908
7908
|
* @param {RegExpMatchArray} match
|
|
7909
7909
|
* @param {CallbackResponse} response
|
|
7910
7910
|
*/
|
|
7911
|
-
isTrulyOpeningTag: (
|
|
7912
|
-
const J =
|
|
7911
|
+
isTrulyOpeningTag: (I, D) => {
|
|
7912
|
+
const J = I[0].length + I.index, Y = I.input[J];
|
|
7913
7913
|
if (
|
|
7914
7914
|
// HTML should not include another raw `<` inside a tag
|
|
7915
7915
|
// nested type?
|
|
@@ -7921,9 +7921,9 @@ function Bf(e) {
|
|
|
7921
7921
|
D.ignoreMatch();
|
|
7922
7922
|
return;
|
|
7923
7923
|
}
|
|
7924
|
-
Y === ">" && (n(
|
|
7924
|
+
Y === ">" && (n(I, { after: J }) || D.ignoreMatch());
|
|
7925
7925
|
let ve;
|
|
7926
|
-
const xe =
|
|
7926
|
+
const xe = I.input.substring(J);
|
|
7927
7927
|
if (ve = xe.match(/^\s*=/)) {
|
|
7928
7928
|
D.ignoreMatch();
|
|
7929
7929
|
return;
|
|
@@ -8052,7 +8052,7 @@ function Bf(e) {
|
|
|
8052
8052
|
e.C_BLOCK_COMMENT_MODE,
|
|
8053
8053
|
e.C_LINE_COMMENT_MODE
|
|
8054
8054
|
]
|
|
8055
|
-
},
|
|
8055
|
+
}, v = [
|
|
8056
8056
|
e.APOS_STRING_MODE,
|
|
8057
8057
|
e.QUOTE_STRING_MODE,
|
|
8058
8058
|
h,
|
|
@@ -8066,7 +8066,7 @@ function Bf(e) {
|
|
|
8066
8066
|
// See https://github.com/highlightjs/highlight.js/issues/3288
|
|
8067
8067
|
// hljs.REGEXP_MODE
|
|
8068
8068
|
];
|
|
8069
|
-
p.contains =
|
|
8069
|
+
p.contains = v.concat({
|
|
8070
8070
|
// we need to pair up {} inside our subst to prevent
|
|
8071
8071
|
// it from ending too early by matching another }
|
|
8072
8072
|
begin: /\{/,
|
|
@@ -8074,15 +8074,15 @@ function Bf(e) {
|
|
|
8074
8074
|
keywords: l,
|
|
8075
8075
|
contains: [
|
|
8076
8076
|
"self"
|
|
8077
|
-
].concat(
|
|
8077
|
+
].concat(v)
|
|
8078
8078
|
});
|
|
8079
|
-
const
|
|
8079
|
+
const C = [].concat(E, p.contains), F = C.concat([
|
|
8080
8080
|
// eat recursive parens in sub expressions
|
|
8081
8081
|
{
|
|
8082
8082
|
begin: /(\s*)\(/,
|
|
8083
8083
|
end: /\)/,
|
|
8084
8084
|
keywords: l,
|
|
8085
|
-
contains: ["self"].concat(
|
|
8085
|
+
contains: ["self"].concat(C)
|
|
8086
8086
|
}
|
|
8087
8087
|
]), H = {
|
|
8088
8088
|
className: "params",
|
|
@@ -8156,7 +8156,7 @@ function Bf(e) {
|
|
|
8156
8156
|
className: "meta",
|
|
8157
8157
|
relevance: 10,
|
|
8158
8158
|
begin: /^\s*['"]use (strict|asm)['"]/
|
|
8159
|
-
},
|
|
8159
|
+
}, T = {
|
|
8160
8160
|
variants: [
|
|
8161
8161
|
{
|
|
8162
8162
|
match: [
|
|
@@ -8186,8 +8186,8 @@ function Bf(e) {
|
|
|
8186
8186
|
match: /\b[A-Z][A-Z_0-9]+\b/,
|
|
8187
8187
|
className: "variable.constant"
|
|
8188
8188
|
};
|
|
8189
|
-
function j(
|
|
8190
|
-
return t.concat("(?!",
|
|
8189
|
+
function j(I) {
|
|
8190
|
+
return t.concat("(?!", I.join("|"), ")");
|
|
8191
8191
|
}
|
|
8192
8192
|
const L = {
|
|
8193
8193
|
match: t.concat(
|
|
@@ -8197,7 +8197,7 @@ function Bf(e) {
|
|
|
8197
8197
|
"super",
|
|
8198
8198
|
"import",
|
|
8199
8199
|
"await"
|
|
8200
|
-
].map((
|
|
8200
|
+
].map((I) => `${I}\\s*\\(`)),
|
|
8201
8201
|
r,
|
|
8202
8202
|
t.lookahead(/\s*\(/)
|
|
8203
8203
|
),
|
|
@@ -8356,7 +8356,7 @@ function Bf(e) {
|
|
|
8356
8356
|
}
|
|
8357
8357
|
]
|
|
8358
8358
|
},
|
|
8359
|
-
|
|
8359
|
+
T,
|
|
8360
8360
|
{
|
|
8361
8361
|
// prevent this from getting swallowed up by function
|
|
8362
8362
|
// since they appear "function like"
|
|
@@ -8696,7 +8696,7 @@ function jf(e) {
|
|
|
8696
8696
|
endsWithParent: !0
|
|
8697
8697
|
}
|
|
8698
8698
|
]
|
|
8699
|
-
},
|
|
8699
|
+
}, N = {
|
|
8700
8700
|
className: "params",
|
|
8701
8701
|
variants: [
|
|
8702
8702
|
// Exclude params in functions without params
|
|
@@ -8763,7 +8763,7 @@ function jf(e) {
|
|
|
8763
8763
|
1: "keyword",
|
|
8764
8764
|
3: "title.function"
|
|
8765
8765
|
},
|
|
8766
|
-
contains: [
|
|
8766
|
+
contains: [N]
|
|
8767
8767
|
},
|
|
8768
8768
|
{
|
|
8769
8769
|
variants: [
|
|
@@ -8798,7 +8798,7 @@ function jf(e) {
|
|
|
8798
8798
|
end: /(?=#)|$/,
|
|
8799
8799
|
contains: [
|
|
8800
8800
|
x,
|
|
8801
|
-
|
|
8801
|
+
N,
|
|
8802
8802
|
f
|
|
8803
8803
|
]
|
|
8804
8804
|
}
|
|
@@ -9106,7 +9106,7 @@ function Ns({
|
|
|
9106
9106
|
language: n = "json",
|
|
9107
9107
|
collapsedMaxHeight: r = qf
|
|
9108
9108
|
}) {
|
|
9109
|
-
const [s, o] = P("idle"), i = ge(void 0), [l, c] = P(!1), [d, u] = P(!1), [f, p] = P(0), h = ge(null), m = ge(null), x =
|
|
9109
|
+
const [s, o] = P("idle"), i = ge(void 0), [l, c] = P(!1), [d, u] = P(!1), [f, p] = P(0), h = ge(null), m = ge(null), x = nt();
|
|
9110
9110
|
K(() => () => clearTimeout(i.current), []), K(() => {
|
|
9111
9111
|
const S = m.current;
|
|
9112
9112
|
if (!S) return;
|
|
@@ -9121,7 +9121,7 @@ function Ns({
|
|
|
9121
9121
|
rp(e).then((S) => {
|
|
9122
9122
|
o(S ? "copied" : "error"), clearTimeout(i.current), i.current = setTimeout(() => o("idle"), Qf);
|
|
9123
9123
|
});
|
|
9124
|
-
}, E = Fe.getLanguage(n) ? Fe.highlight(e, { language: n }).value : null,
|
|
9124
|
+
}, E = Fe.getLanguage(n) ? Fe.highlight(e, { language: n }).value : null, v = s === "copied" ? "Copied" : s === "error" ? "Copy failed" : "Copy to clipboard", C = d && !l, F = e.replace(/\n+$/, "").split(`
|
|
9125
9125
|
`).length, H = () => {
|
|
9126
9126
|
var S, k;
|
|
9127
9127
|
l && (((S = h.current) == null ? void 0 : S.getBoundingClientRect().top) ?? 0) < 0 && ((k = h.current) == null || k.scrollIntoView({ block: "nearest" })), c((y) => !y);
|
|
@@ -9132,8 +9132,8 @@ function Ns({
|
|
|
9132
9132
|
{
|
|
9133
9133
|
type: "button",
|
|
9134
9134
|
onClick: b,
|
|
9135
|
-
"aria-label":
|
|
9136
|
-
title:
|
|
9135
|
+
"aria-label": v,
|
|
9136
|
+
title: v,
|
|
9137
9137
|
className: "absolute top-2 right-2 z-10 p-1 rounded text-foreground-muted hover:text-foreground-secondary hover:bg-neutral-100 transition-colors",
|
|
9138
9138
|
children: s === "copied" ? /* @__PURE__ */ a(ti, { className: "w-4 h-4 text-green-600" }) : /* @__PURE__ */ a(ei, { className: `w-4 h-4 ${s === "error" ? "text-red-500" : ""}` })
|
|
9139
9139
|
}
|
|
@@ -9159,7 +9159,7 @@ function Ns({
|
|
|
9159
9159
|
"div",
|
|
9160
9160
|
{
|
|
9161
9161
|
"aria-hidden": "true",
|
|
9162
|
-
className: `pointer-events-none absolute inset-x-0 bottom-0 h-16 rounded-b transition-opacity duration-300 ease-in-out ${
|
|
9162
|
+
className: `pointer-events-none absolute inset-x-0 bottom-0 h-16 rounded-b transition-opacity duration-300 ease-in-out ${C ? "opacity-100" : "opacity-0"}`,
|
|
9163
9163
|
style: { background: `linear-gradient(to bottom, transparent, ${tp})` }
|
|
9164
9164
|
}
|
|
9165
9165
|
)
|
|
@@ -9256,7 +9256,7 @@ ${t}` : t;
|
|
|
9256
9256
|
"required",
|
|
9257
9257
|
"description",
|
|
9258
9258
|
"items"
|
|
9259
|
-
]),
|
|
9259
|
+
]), rt = (e, t, n, r) => {
|
|
9260
9260
|
if (e === t) return e;
|
|
9261
9261
|
const s = { ...e };
|
|
9262
9262
|
if (t.description && (s.description = jn(
|
|
@@ -9269,18 +9269,18 @@ ${t}` : t;
|
|
|
9269
9269
|
for (const [o, i] of Object.entries(t.properties)) {
|
|
9270
9270
|
if (!Z(i)) continue;
|
|
9271
9271
|
const l = s.properties[o];
|
|
9272
|
-
Z(l) ? s.properties[o] =
|
|
9272
|
+
Z(l) ? s.properties[o] = rt(l, i) : s.properties[o] = i;
|
|
9273
9273
|
}
|
|
9274
9274
|
}
|
|
9275
9275
|
if (t.items)
|
|
9276
9276
|
if (Array.isArray(t.items))
|
|
9277
9277
|
Array.isArray(s.items) ? s.items = t.items.map((o, i) => {
|
|
9278
9278
|
const l = s.items[i];
|
|
9279
|
-
return Z(o) && Z(l) ?
|
|
9279
|
+
return Z(o) && Z(l) ? rt(l, o) : Z(o) ? o : l;
|
|
9280
9280
|
}) : s.items = t.items;
|
|
9281
9281
|
else {
|
|
9282
9282
|
const o = ft(t), i = ft(s);
|
|
9283
|
-
o && i ? s.items =
|
|
9283
|
+
o && i ? s.items = rt(i, o) : o && (s.items = t.items);
|
|
9284
9284
|
}
|
|
9285
9285
|
if (t.patternProperties && Z(t.patternProperties)) {
|
|
9286
9286
|
const o = {
|
|
@@ -9292,7 +9292,7 @@ ${t}` : t;
|
|
|
9292
9292
|
continue;
|
|
9293
9293
|
}
|
|
9294
9294
|
const c = o[i];
|
|
9295
|
-
Z(c) ? o[i] =
|
|
9295
|
+
Z(c) ? o[i] = rt(
|
|
9296
9296
|
c,
|
|
9297
9297
|
l
|
|
9298
9298
|
) : o[i] = l;
|
|
@@ -9302,13 +9302,13 @@ ${t}` : t;
|
|
|
9302
9302
|
if (t.propertyNames !== void 0)
|
|
9303
9303
|
if (Z(t.propertyNames)) {
|
|
9304
9304
|
const o = s.propertyNames;
|
|
9305
|
-
s.propertyNames = Z(o) ?
|
|
9305
|
+
s.propertyNames = Z(o) ? rt(o, t.propertyNames) : t.propertyNames;
|
|
9306
9306
|
} else
|
|
9307
9307
|
s.propertyNames = t.propertyNames;
|
|
9308
9308
|
if (t.additionalProperties !== void 0)
|
|
9309
9309
|
if (Z(t.additionalProperties)) {
|
|
9310
9310
|
const o = s.additionalProperties;
|
|
9311
|
-
s.additionalProperties = Z(o) ?
|
|
9311
|
+
s.additionalProperties = Z(o) ? rt(o, t.additionalProperties) : t.additionalProperties;
|
|
9312
9312
|
} else
|
|
9313
9313
|
s.additionalProperties = t.additionalProperties;
|
|
9314
9314
|
for (const [o, i] of Object.entries(t))
|
|
@@ -9356,7 +9356,7 @@ ${t}` : t;
|
|
|
9356
9356
|
const m = { if: h.if };
|
|
9357
9357
|
h.then !== void 0 && (m.then = h.then), h.else !== void 0 && (m.else = h.else), o.push(m);
|
|
9358
9358
|
}
|
|
9359
|
-
o.push(...ca(h)), i =
|
|
9359
|
+
o.push(...ca(h)), i = rt(i, h, t, n);
|
|
9360
9360
|
}
|
|
9361
9361
|
if (e.if !== void 0) {
|
|
9362
9362
|
const u = { if: e.if };
|
|
@@ -9364,7 +9364,7 @@ ${t}` : t;
|
|
|
9364
9364
|
}
|
|
9365
9365
|
const l = { ...e };
|
|
9366
9366
|
delete l.allOf;
|
|
9367
|
-
const c = Object.keys(l).length > 0 ?
|
|
9367
|
+
const c = Object.keys(l).length > 0 ? rt(i, l, t, n) : i, d = xo(c, t, n, r);
|
|
9368
9368
|
if (o.length === 1) {
|
|
9369
9369
|
const u = o[0];
|
|
9370
9370
|
d.if = u.if, u.then !== void 0 && (d.then = u.then), u.else !== void 0 && (d.else = u.else);
|
|
@@ -9827,13 +9827,13 @@ function Ce({
|
|
|
9827
9827
|
showBorder: p = !0
|
|
9828
9828
|
}) {
|
|
9829
9829
|
const { depthColors: h } = $e(), m = Gr(n, h), x = r && xp(r, s), b = d ? Ap : "";
|
|
9830
|
-
let
|
|
9830
|
+
let N = "", E = t;
|
|
9831
9831
|
if (t.endsWith("[]")) {
|
|
9832
|
-
const
|
|
9833
|
-
|
|
9832
|
+
const v = t.slice(0, -2), C = v.lastIndexOf(".");
|
|
9833
|
+
C >= 0 ? (N = v.slice(0, C + 1), E = `${v.slice(C + 1)}[]`) : E = t;
|
|
9834
9834
|
} else {
|
|
9835
|
-
const
|
|
9836
|
-
F >= 0 && (
|
|
9835
|
+
const v = t.lastIndexOf("."), C = t.lastIndexOf("[]"), F = Math.max(v, C);
|
|
9836
|
+
F >= 0 && (N = t.slice(0, F + (t[F] === "." ? 1 : 2)), E = t.slice(F + (t[F] === "." ? 1 : 2)));
|
|
9837
9837
|
}
|
|
9838
9838
|
return p = p && !u, /* @__PURE__ */ g(
|
|
9839
9839
|
"div",
|
|
@@ -9844,7 +9844,7 @@ function Ce({
|
|
|
9844
9844
|
/* @__PURE__ */ g("div", { className: "flex items-center gap-2 min-h-[24px]", children: [
|
|
9845
9845
|
/* @__PURE__ */ g("span", { className: "text-xs font-mono flex-1 min-w-0 flex items-center", children: [
|
|
9846
9846
|
/* @__PURE__ */ g("span", { className: "truncate min-w-0", children: [
|
|
9847
|
-
|
|
9847
|
+
N && /* @__PURE__ */ a("span", { className: "text-foreground-muted", children: N }),
|
|
9848
9848
|
/* @__PURE__ */ a("span", { className: "font-semibold", style: { color: m }, children: E })
|
|
9849
9849
|
] }),
|
|
9850
9850
|
l && /* @__PURE__ */ a("span", { className: "shrink-0 text-red-500 ml-2 text-[10px]", children: "required" }),
|
|
@@ -9872,13 +9872,13 @@ function Ce({
|
|
|
9872
9872
|
),
|
|
9873
9873
|
c && c.split(`
|
|
9874
9874
|
|
|
9875
|
-
`).map((
|
|
9875
|
+
`).map((v, C) => /* @__PURE__ */ a(
|
|
9876
9876
|
"p",
|
|
9877
9877
|
{
|
|
9878
9878
|
className: `text-xs text-foreground-muted mt-1 ${b} leading-relaxed`,
|
|
9879
|
-
children:
|
|
9879
|
+
children: v
|
|
9880
9880
|
},
|
|
9881
|
-
|
|
9881
|
+
C
|
|
9882
9882
|
)),
|
|
9883
9883
|
d && /* @__PURE__ */ a(Np, { depth: n, expanded: u, onToggle: f })
|
|
9884
9884
|
]
|
|
@@ -9939,15 +9939,15 @@ function je({
|
|
|
9939
9939
|
focusId: f = null
|
|
9940
9940
|
}) {
|
|
9941
9941
|
var ae;
|
|
9942
|
-
const p = Ep(l), h = u != null, x = h && u.length === 0 ? f ?? void 0 : void 0, [b,
|
|
9943
|
-
E !== c && (
|
|
9944
|
-
h &&
|
|
9942
|
+
const p = Ep(l), h = u != null, x = h && u.length === 0 ? f ?? void 0 : void 0, [b, N] = P(c || h), [E, v] = P(c);
|
|
9943
|
+
E !== c && (v(c), N(c || h)), K(() => {
|
|
9944
|
+
h && N(!0);
|
|
9945
9945
|
}, [h]);
|
|
9946
|
-
const [
|
|
9946
|
+
const [C, F] = P(0), H = (ae = u == null ? void 0 : u[0]) == null ? void 0 : ae.match(/^(?:oneOf|anyOf)\[(\d+)\]$/), S = H ? Number(H[1]) : -1;
|
|
9947
9947
|
K(() => {
|
|
9948
9948
|
S >= 0 && F(S);
|
|
9949
9949
|
}, [S]);
|
|
9950
|
-
const k = Wn(), { schema: y, refLabel:
|
|
9950
|
+
const k = Wn(), { schema: y, refLabel: T, circular: M } = X(() => {
|
|
9951
9951
|
if (d.objects.has(e) || typeof e.$ref == "string" && d.refs.has(e.$ref))
|
|
9952
9952
|
return {
|
|
9953
9953
|
schema: e,
|
|
@@ -10045,7 +10045,7 @@ function je({
|
|
|
10045
10045
|
elseContent: le !== null ? A(le, t) : void 0
|
|
10046
10046
|
}
|
|
10047
10047
|
);
|
|
10048
|
-
},
|
|
10048
|
+
}, I = () => {
|
|
10049
10049
|
const B = ca(y);
|
|
10050
10050
|
return B.length === 0 ? null : /* @__PURE__ */ a(U, { children: B.map((q, de) => /* @__PURE__ */ a("div", { children: w(q) }, de)) });
|
|
10051
10051
|
};
|
|
@@ -10056,7 +10056,7 @@ function je({
|
|
|
10056
10056
|
id: x,
|
|
10057
10057
|
path: t,
|
|
10058
10058
|
depth: n,
|
|
10059
|
-
typeLabelOverride: `↩ ${e.$ref ??
|
|
10059
|
+
typeLabelOverride: `↩ ${e.$ref ?? T ?? "circular"}`,
|
|
10060
10060
|
expandable: !1,
|
|
10061
10061
|
expanded: !1,
|
|
10062
10062
|
onToggle: () => {
|
|
@@ -10067,7 +10067,7 @@ function je({
|
|
|
10067
10067
|
const B = /* @__PURE__ */ g(U, { children: [
|
|
10068
10068
|
Te(y) && Q(),
|
|
10069
10069
|
_e(y) && w(y),
|
|
10070
|
-
Me(y) &&
|
|
10070
|
+
Me(y) && I()
|
|
10071
10071
|
] });
|
|
10072
10072
|
return i ? B : /* @__PURE__ */ g(U, { children: [
|
|
10073
10073
|
/* @__PURE__ */ a(
|
|
@@ -10077,12 +10077,12 @@ function je({
|
|
|
10077
10077
|
path: t,
|
|
10078
10078
|
depth: n,
|
|
10079
10079
|
schema: y,
|
|
10080
|
-
refLabel:
|
|
10080
|
+
refLabel: T,
|
|
10081
10081
|
required: r,
|
|
10082
10082
|
description: y.description,
|
|
10083
10083
|
expandable: !0,
|
|
10084
10084
|
expanded: b,
|
|
10085
|
-
onToggle: () =>
|
|
10085
|
+
onToggle: () => N((q) => !q)
|
|
10086
10086
|
}
|
|
10087
10087
|
),
|
|
10088
10088
|
b && /* @__PURE__ */ a(ct, { depth: n, lineVariant: l, children: B })
|
|
@@ -10092,7 +10092,7 @@ function je({
|
|
|
10092
10092
|
if (Y) {
|
|
10093
10093
|
const B = Y.map(
|
|
10094
10094
|
(z, $) => typeof z.title == "string" ? z.title : `case ${$ + 1}`
|
|
10095
|
-
), q = i ? 1 : n + 1, de = Y[
|
|
10095
|
+
), q = i ? 1 : n + 1, de = Y[C], le = Ze(de, o, s), be = le.circular ? le.schema : Se(le.schema, o, s), we = !le.circular && De(be), pe = u && S === C ? u.slice(1) : null, Oe = we ? /* @__PURE__ */ a(mn, { schema: be, showBorder: !1 }) : /* @__PURE__ */ a(
|
|
10096
10096
|
je,
|
|
10097
10097
|
{
|
|
10098
10098
|
schema: de,
|
|
@@ -10107,14 +10107,14 @@ function je({
|
|
|
10107
10107
|
focusTokens: pe,
|
|
10108
10108
|
focusId: f
|
|
10109
10109
|
},
|
|
10110
|
-
|
|
10110
|
+
C
|
|
10111
10111
|
), me = /* @__PURE__ */ a(
|
|
10112
10112
|
kp,
|
|
10113
10113
|
{
|
|
10114
10114
|
variant: ve,
|
|
10115
10115
|
caseCount: Y.length,
|
|
10116
10116
|
caseLabels: B,
|
|
10117
|
-
selectedCase:
|
|
10117
|
+
selectedCase: C,
|
|
10118
10118
|
onSelectCase: F,
|
|
10119
10119
|
children: Oe
|
|
10120
10120
|
}
|
|
@@ -10122,7 +10122,7 @@ function je({
|
|
|
10122
10122
|
me,
|
|
10123
10123
|
Te(y) && Q(),
|
|
10124
10124
|
_e(y) && w(y),
|
|
10125
|
-
Me(y) &&
|
|
10125
|
+
Me(y) && I()
|
|
10126
10126
|
] });
|
|
10127
10127
|
return i ? Ue : /* @__PURE__ */ g(U, { children: [
|
|
10128
10128
|
/* @__PURE__ */ a(
|
|
@@ -10132,12 +10132,12 @@ function je({
|
|
|
10132
10132
|
path: t,
|
|
10133
10133
|
depth: n,
|
|
10134
10134
|
schema: y,
|
|
10135
|
-
refLabel:
|
|
10135
|
+
refLabel: T,
|
|
10136
10136
|
required: r,
|
|
10137
10137
|
description: y.description,
|
|
10138
10138
|
expandable: !0,
|
|
10139
10139
|
expanded: b,
|
|
10140
|
-
onToggle: () =>
|
|
10140
|
+
onToggle: () => N((z) => !z)
|
|
10141
10141
|
}
|
|
10142
10142
|
),
|
|
10143
10143
|
b && /* @__PURE__ */ a(ct, { depth: n, lineVariant: l, children: Ue })
|
|
@@ -10223,7 +10223,7 @@ function je({
|
|
|
10223
10223
|
) }),
|
|
10224
10224
|
Te(y) && Q(),
|
|
10225
10225
|
_e(y) && w(y),
|
|
10226
|
-
Me(y) &&
|
|
10226
|
+
Me(y) && I()
|
|
10227
10227
|
] });
|
|
10228
10228
|
};
|
|
10229
10229
|
if (rn(L) || Qn(L))
|
|
@@ -10235,12 +10235,12 @@ function je({
|
|
|
10235
10235
|
path: t,
|
|
10236
10236
|
depth: n,
|
|
10237
10237
|
schema: y,
|
|
10238
|
-
refLabel:
|
|
10238
|
+
refLabel: T,
|
|
10239
10239
|
required: r,
|
|
10240
10240
|
description: y.description,
|
|
10241
10241
|
expandable: !0,
|
|
10242
10242
|
expanded: b,
|
|
10243
|
-
onToggle: () =>
|
|
10243
|
+
onToggle: () => N((B) => !B)
|
|
10244
10244
|
}
|
|
10245
10245
|
),
|
|
10246
10246
|
b && /* @__PURE__ */ a(ct, { depth: n, lineVariant: l, children: fe(n + 1) })
|
|
@@ -10324,7 +10324,7 @@ function je({
|
|
|
10324
10324
|
be && /* @__PURE__ */ a(gn, { label: "Contains at least one:", children: typeof le == "boolean" ? /* @__PURE__ */ a("span", { className: "inline-flex items-center rounded-md bg-neutral-100 px-2 py-1 text-xs font-medium text-foreground-secondary", children: le ? "any item" : "impossible constraint" }) : xe(le, `${t}[contains]`, _) }),
|
|
10325
10325
|
Te(y) && Q(),
|
|
10326
10326
|
_e(y) && w(y),
|
|
10327
|
-
Me(y) &&
|
|
10327
|
+
Me(y) && I()
|
|
10328
10328
|
] });
|
|
10329
10329
|
return te && !Te(y) && !_e(y) && !Me(y) ? /* @__PURE__ */ a(
|
|
10330
10330
|
Ce,
|
|
@@ -10334,7 +10334,7 @@ function je({
|
|
|
10334
10334
|
depth: n,
|
|
10335
10335
|
schema: y,
|
|
10336
10336
|
itemSchema: se,
|
|
10337
|
-
refLabel:
|
|
10337
|
+
refLabel: T,
|
|
10338
10338
|
required: r,
|
|
10339
10339
|
description: jn(
|
|
10340
10340
|
y.description,
|
|
@@ -10354,7 +10354,7 @@ function je({
|
|
|
10354
10354
|
depth: n,
|
|
10355
10355
|
schema: y,
|
|
10356
10356
|
itemSchema: se,
|
|
10357
|
-
refLabel:
|
|
10357
|
+
refLabel: T,
|
|
10358
10358
|
required: r,
|
|
10359
10359
|
description: jn(
|
|
10360
10360
|
y.description,
|
|
@@ -10362,13 +10362,13 @@ function je({
|
|
|
10362
10362
|
),
|
|
10363
10363
|
expandable: !0,
|
|
10364
10364
|
expanded: b,
|
|
10365
|
-
onToggle: () =>
|
|
10365
|
+
onToggle: () => N((_) => !_)
|
|
10366
10366
|
}
|
|
10367
10367
|
),
|
|
10368
10368
|
b && /* @__PURE__ */ g(ct, { depth: n, lineVariant: l, children: [
|
|
10369
10369
|
Te(y) && Q(),
|
|
10370
10370
|
_e(y) && w(y),
|
|
10371
|
-
Me(y) &&
|
|
10371
|
+
Me(y) && I()
|
|
10372
10372
|
] })
|
|
10373
10373
|
] }) : i ? Oe ? O(n + 1) : null : /* @__PURE__ */ g(U, { children: [
|
|
10374
10374
|
/* @__PURE__ */ a(
|
|
@@ -10379,12 +10379,12 @@ function je({
|
|
|
10379
10379
|
depth: n,
|
|
10380
10380
|
schema: y,
|
|
10381
10381
|
itemSchema: se,
|
|
10382
|
-
refLabel:
|
|
10382
|
+
refLabel: T,
|
|
10383
10383
|
required: r,
|
|
10384
10384
|
description: y.description,
|
|
10385
10385
|
expandable: q || pe || be || Te(y) || _e(y) || Me(y),
|
|
10386
10386
|
expanded: b,
|
|
10387
|
-
onToggle: () =>
|
|
10387
|
+
onToggle: () => N((_) => !_)
|
|
10388
10388
|
}
|
|
10389
10389
|
),
|
|
10390
10390
|
b && /* @__PURE__ */ a(ct, { depth: n, lineVariant: l, children: O(n + 1) })
|
|
@@ -10394,7 +10394,7 @@ function je({
|
|
|
10394
10394
|
const B = /* @__PURE__ */ g(U, { children: [
|
|
10395
10395
|
Te(y) && Q(),
|
|
10396
10396
|
_e(y) && w(y),
|
|
10397
|
-
Me(y) &&
|
|
10397
|
+
Me(y) && I()
|
|
10398
10398
|
] });
|
|
10399
10399
|
return i ? B : /* @__PURE__ */ g(U, { children: [
|
|
10400
10400
|
/* @__PURE__ */ a(
|
|
@@ -10404,12 +10404,12 @@ function je({
|
|
|
10404
10404
|
path: t,
|
|
10405
10405
|
depth: n,
|
|
10406
10406
|
schema: y,
|
|
10407
|
-
refLabel:
|
|
10407
|
+
refLabel: T,
|
|
10408
10408
|
required: r,
|
|
10409
10409
|
description: y.description,
|
|
10410
10410
|
expandable: !0,
|
|
10411
10411
|
expanded: b,
|
|
10412
|
-
onToggle: () =>
|
|
10412
|
+
onToggle: () => N((q) => !q)
|
|
10413
10413
|
}
|
|
10414
10414
|
),
|
|
10415
10415
|
b && /* @__PURE__ */ a(ct, { depth: n, lineVariant: l, children: B })
|
|
@@ -10422,7 +10422,7 @@ function je({
|
|
|
10422
10422
|
path: t,
|
|
10423
10423
|
depth: n,
|
|
10424
10424
|
schema: y,
|
|
10425
|
-
refLabel:
|
|
10425
|
+
refLabel: T,
|
|
10426
10426
|
required: r,
|
|
10427
10427
|
description: y.description,
|
|
10428
10428
|
expandable: !1,
|
|
@@ -10802,7 +10802,7 @@ function va({ address: e, variables: t, children: n }) {
|
|
|
10802
10802
|
/* @__PURE__ */ g("div", { className: "border border-dotted border-black p-2 rounded-lg bg-surface", children: [
|
|
10803
10803
|
/* @__PURE__ */ a(Ip, { className: "inline-block mr-1 -mt-1 h-6 text-foreground-muted" }),
|
|
10804
10804
|
e && /* @__PURE__ */ a(
|
|
10805
|
-
|
|
10805
|
+
et,
|
|
10806
10806
|
{
|
|
10807
10807
|
address: e,
|
|
10808
10808
|
parameters: t,
|
|
@@ -10833,7 +10833,7 @@ function sn({
|
|
|
10833
10833
|
ariaLabelledBy: s,
|
|
10834
10834
|
className: o = ""
|
|
10835
10835
|
}) {
|
|
10836
|
-
const [i, l] = P(n), c =
|
|
10836
|
+
const [i, l] = P(n), c = nt();
|
|
10837
10837
|
return K(() => {
|
|
10838
10838
|
r && l(!0);
|
|
10839
10839
|
}, [r]), /* @__PURE__ */ g("div", { className: `rounded-lg border border-border overflow-hidden ${o}`, children: [
|
|
@@ -11139,7 +11139,7 @@ function Bp({
|
|
|
11139
11139
|
serverKey: l,
|
|
11140
11140
|
focusSection: c = null
|
|
11141
11141
|
}) {
|
|
11142
|
-
const d = s, u =
|
|
11142
|
+
const d = s, u = nt();
|
|
11143
11143
|
return /* @__PURE__ */ g("div", { children: [
|
|
11144
11144
|
/* @__PURE__ */ a(va, { address: e, variables: d, children: /* @__PURE__ */ a("div", { className: "mt-2", children: r && r.map((f, p) => {
|
|
11145
11145
|
const h = f, m = h.externalDocs;
|
|
@@ -11230,8 +11230,8 @@ function $a({ servers: e, selectedServer: t, onSelectServer: n, focusSection: r
|
|
|
11230
11230
|
const Ca = ml(function({ isOpen: t, side: n, onClose: r, title: s, headerActions: o, children: i, width: l = "w-[50rem]" }, c) {
|
|
11231
11231
|
K(() => {
|
|
11232
11232
|
if (!t) return;
|
|
11233
|
-
const E = (
|
|
11234
|
-
|
|
11233
|
+
const E = (v) => {
|
|
11234
|
+
v.key === "Escape" && r();
|
|
11235
11235
|
};
|
|
11236
11236
|
return document.addEventListener("keydown", E), () => document.removeEventListener("keydown", E);
|
|
11237
11237
|
}, [t, r]);
|
|
@@ -11247,16 +11247,16 @@ const Ca = ml(function({ isOpen: t, side: n, onClose: r, title: s, headerActions
|
|
|
11247
11247
|
if (E)
|
|
11248
11248
|
return Uo(E);
|
|
11249
11249
|
}, [x, t, f, p]);
|
|
11250
|
-
const b = br(p, x),
|
|
11250
|
+
const b = br(p, x), N = (() => {
|
|
11251
11251
|
if (!x) return { position: "fixed", inset: 0 };
|
|
11252
11252
|
if (!b) return { position: "fixed", inset: 0 };
|
|
11253
|
-
const E = Math.max(m, b.top),
|
|
11253
|
+
const E = Math.max(m, b.top), v = Math.max(0, b.left), C = Math.min(window.innerHeight, b.bottom), F = Math.min(window.innerWidth, b.right);
|
|
11254
11254
|
return {
|
|
11255
11255
|
position: "fixed",
|
|
11256
11256
|
top: E,
|
|
11257
|
-
left:
|
|
11258
|
-
width: Math.max(0, F -
|
|
11259
|
-
height: Math.max(0,
|
|
11257
|
+
left: v,
|
|
11258
|
+
width: Math.max(0, F - v),
|
|
11259
|
+
height: Math.max(0, C - E)
|
|
11260
11260
|
};
|
|
11261
11261
|
})();
|
|
11262
11262
|
return f ? kt(
|
|
@@ -11264,7 +11264,7 @@ const Ca = ml(function({ isOpen: t, side: n, onClose: r, title: s, headerActions
|
|
|
11264
11264
|
"div",
|
|
11265
11265
|
{
|
|
11266
11266
|
className: "z-50 overflow-hidden",
|
|
11267
|
-
style: { ...
|
|
11267
|
+
style: { ...N, pointerEvents: t ? "auto" : "none" },
|
|
11268
11268
|
children: [
|
|
11269
11269
|
/* @__PURE__ */ a(
|
|
11270
11270
|
"div",
|
|
@@ -11355,7 +11355,7 @@ function jp({ requestMessages: e, reply: t, isSend: n, operationId: r }) {
|
|
|
11355
11355
|
" ",
|
|
11356
11356
|
/* @__PURE__ */ a("span", { className: "inline-flex items-center px-1.5 py-0.5 rounded text-xs font-semibold bg-surface border border-border text-foreground-secondary", children: c.location })
|
|
11357
11357
|
] }) : (l == null ? void 0 : l.address) && /* @__PURE__ */ a(
|
|
11358
|
-
|
|
11358
|
+
et,
|
|
11359
11359
|
{
|
|
11360
11360
|
address: l.address,
|
|
11361
11361
|
parameters: l.parameters,
|
|
@@ -11441,7 +11441,7 @@ function Gp(e, t) {
|
|
|
11441
11441
|
}
|
|
11442
11442
|
return r;
|
|
11443
11443
|
}
|
|
11444
|
-
function
|
|
11444
|
+
function tt(e, t) {
|
|
11445
11445
|
let n = t;
|
|
11446
11446
|
for (let r = 0; Kp(n); r++) {
|
|
11447
11447
|
if (r >= $o) throw new Error(`Exceeded max $ref depth (${$o}) resolving "${n.$ref}" — possible cycle`);
|
|
@@ -11480,7 +11480,7 @@ function Zp(e) {
|
|
|
11480
11480
|
}
|
|
11481
11481
|
function Dr(e, t, n = 0) {
|
|
11482
11482
|
if (n > Vp) return;
|
|
11483
|
-
const r =
|
|
11483
|
+
const r = tt(e, t);
|
|
11484
11484
|
if (!r || typeof r != "object") return;
|
|
11485
11485
|
const s = r;
|
|
11486
11486
|
if (s.examples && s.examples.length > 0) return s.examples[0];
|
|
@@ -11521,7 +11521,7 @@ function Yp(e) {
|
|
|
11521
11521
|
function Ut(e, t, n = 0) {
|
|
11522
11522
|
if (n >= Xp || t === null || typeof t != "object") return t;
|
|
11523
11523
|
if (Array.isArray(t)) return t.map((s) => Ut(e, s, n + 1));
|
|
11524
|
-
if (Yp(t)) return Ut(e,
|
|
11524
|
+
if (Yp(t)) return Ut(e, tt(e, t), n + 1);
|
|
11525
11525
|
const r = {};
|
|
11526
11526
|
for (const [s, o] of Object.entries(t)) r[s] = Ut(e, o, n + 1);
|
|
11527
11527
|
return r;
|
|
@@ -11556,7 +11556,7 @@ function Co(e) {
|
|
|
11556
11556
|
};
|
|
11557
11557
|
}
|
|
11558
11558
|
function To(e, t) {
|
|
11559
|
-
return t != null && t.length ? t.map((n) =>
|
|
11559
|
+
return t != null && t.length ? t.map((n) => tt(e, n)).filter((n) => !!(n != null && n.type)) : [];
|
|
11560
11560
|
}
|
|
11561
11561
|
const Qp = {
|
|
11562
11562
|
"kafka-secure": "kafka",
|
|
@@ -11573,14 +11573,14 @@ function th(e) {
|
|
|
11573
11573
|
}
|
|
11574
11574
|
function nh(e, t) {
|
|
11575
11575
|
return t && t.length > 0 ? t.map((n) => {
|
|
11576
|
-
const r =
|
|
11576
|
+
const r = tt(e, n);
|
|
11577
11577
|
if (r)
|
|
11578
11578
|
return {
|
|
11579
11579
|
name: eh(n) ? th(n.$ref) : "",
|
|
11580
11580
|
server: r
|
|
11581
11581
|
};
|
|
11582
11582
|
}).filter((n) => !!n) : Object.entries(e.servers ?? {}).map(([n, r]) => {
|
|
11583
|
-
const s =
|
|
11583
|
+
const s = tt(e, r);
|
|
11584
11584
|
return s ? {
|
|
11585
11585
|
name: n,
|
|
11586
11586
|
server: s
|
|
@@ -11589,9 +11589,9 @@ function nh(e, t) {
|
|
|
11589
11589
|
}
|
|
11590
11590
|
function Oa(e, t) {
|
|
11591
11591
|
var o;
|
|
11592
|
-
const n = (o = e.operations) == null ? void 0 : o[t], r = n &&
|
|
11592
|
+
const n = (o = e.operations) == null ? void 0 : o[t], r = n && tt(e, n);
|
|
11593
11593
|
if (!r) throw new zp(t);
|
|
11594
|
-
const s =
|
|
11594
|
+
const s = tt(e, r.channel);
|
|
11595
11595
|
if (!s) throw new Up(t);
|
|
11596
11596
|
return {
|
|
11597
11597
|
operation: r,
|
|
@@ -11616,7 +11616,7 @@ function rh(e, t, n) {
|
|
|
11616
11616
|
}
|
|
11617
11617
|
}
|
|
11618
11618
|
function sh(e, t, n) {
|
|
11619
|
-
var M, j, L, G, Q, A, w,
|
|
11619
|
+
var M, j, L, G, Q, A, w, I, D, J, Y, ve, xe, fe;
|
|
11620
11620
|
const { operation: r, channel: s } = Oa(e, t), { servers: o, matchedServer: i, eligible: l } = _a(e, s, r, n);
|
|
11621
11621
|
if (!l) throw new Wp(t, n);
|
|
11622
11622
|
const c = [];
|
|
@@ -11632,7 +11632,7 @@ function sh(e, t, n) {
|
|
|
11632
11632
|
h = h.replace(`{${ue}}`, B.value), B.isPlaceholder && c.push(`channel parameter "${ue}"`);
|
|
11633
11633
|
}
|
|
11634
11634
|
n === "kafka" && f && (h = f);
|
|
11635
|
-
const m = (w = i ?? o[0]) == null ? void 0 : w.server, x = m ? `${m.protocol}://${m.host}${m.pathname ?? ""}` : "", b = (m == null ? void 0 : m.host) ?? "",
|
|
11635
|
+
const m = (w = i ?? o[0]) == null ? void 0 : w.server, x = m ? `${m.protocol}://${m.host}${m.pathname ?? ""}` : "", b = (m == null ? void 0 : m.host) ?? "", N = To(e, m == null ? void 0 : m.security), E = o.map(({ name: ue, server: ae }) => ({
|
|
11636
11636
|
name: ue,
|
|
11637
11637
|
host: ae.host,
|
|
11638
11638
|
protocol: ae.protocol,
|
|
@@ -11640,23 +11640,23 @@ function sh(e, t, n) {
|
|
|
11640
11640
|
url: `${ae.protocol}://${ae.host}${ae.pathname ?? ""}`,
|
|
11641
11641
|
description: ae.description,
|
|
11642
11642
|
security: To(e, ae.security)
|
|
11643
|
-
})),
|
|
11643
|
+
})), v = r.messages !== void 0 ? tt(e, r.messages[0]) : tt(e, Object.values(s.messages ?? {})[0]), C = (I = v == null ? void 0 : v.examples) == null ? void 0 : I[0];
|
|
11644
11644
|
let F, H;
|
|
11645
|
-
if (
|
|
11646
|
-
F =
|
|
11647
|
-
else if ((
|
|
11648
|
-
if (H = Dr(e,
|
|
11645
|
+
if (C)
|
|
11646
|
+
F = C.name, H = C.payload;
|
|
11647
|
+
else if ((v == null ? void 0 : v.payload) !== void 0) {
|
|
11648
|
+
if (H = Dr(e, v.payload), H === void 0) throw new Eo(t);
|
|
11649
11649
|
c.push("message payload (no explicit example — generated from its schema)");
|
|
11650
11650
|
} else throw new Eo(t);
|
|
11651
|
-
const S = (
|
|
11652
|
-
let
|
|
11651
|
+
const S = (v == null ? void 0 : v.payload) !== void 0 ? Ut(e, v.payload) : void 0, k = (v == null ? void 0 : v.headers) !== void 0 ? Ut(e, v.headers) : void 0, y = r.action === "send" ? "send" : "receive";
|
|
11652
|
+
let T;
|
|
11653
11653
|
if (n === "kafka") {
|
|
11654
|
-
const ue = (J = (D =
|
|
11654
|
+
const ue = (J = (D = v == null ? void 0 : v.bindings) == null ? void 0 : D.kafka) == null ? void 0 : J.key, ae = ue ? xn(ue, "kafka message key") : void 0;
|
|
11655
11655
|
ae != null && ae.isPlaceholder && c.push("kafka message key");
|
|
11656
11656
|
const B = xn((ve = (Y = r.bindings) == null ? void 0 : Y.kafka) == null ? void 0 : ve.clientId, "kafka clientId");
|
|
11657
11657
|
B.isPlaceholder && c.push("kafka clientId");
|
|
11658
11658
|
let q;
|
|
11659
|
-
y === "receive" && (q = xn((fe = (xe = r.bindings) == null ? void 0 : xe.kafka) == null ? void 0 : fe.groupId, "kafka consumer group id"), q.isPlaceholder && c.push("kafka consumer group id")),
|
|
11659
|
+
y === "receive" && (q = xn((fe = (xe = r.bindings) == null ? void 0 : xe.kafka) == null ? void 0 : fe.groupId, "kafka consumer group id"), q.isPlaceholder && c.push("kafka consumer group id")), T = {
|
|
11660
11660
|
key: ae == null ? void 0 : ae.value,
|
|
11661
11661
|
groupId: q == null ? void 0 : q.value,
|
|
11662
11662
|
clientId: B.value
|
|
@@ -11678,17 +11678,17 @@ function sh(e, t, n) {
|
|
|
11678
11678
|
message: {
|
|
11679
11679
|
name: F,
|
|
11680
11680
|
payload: H,
|
|
11681
|
-
title: (
|
|
11682
|
-
summary:
|
|
11683
|
-
description:
|
|
11684
|
-
contentType:
|
|
11681
|
+
title: (v == null ? void 0 : v.title) ?? (v == null ? void 0 : v.name),
|
|
11682
|
+
summary: v == null ? void 0 : v.summary,
|
|
11683
|
+
description: v == null ? void 0 : v.description,
|
|
11684
|
+
contentType: v == null ? void 0 : v.contentType,
|
|
11685
11685
|
payloadSchema: S,
|
|
11686
11686
|
headersSchema: k
|
|
11687
11687
|
},
|
|
11688
11688
|
placeholders: c,
|
|
11689
11689
|
info: e.info,
|
|
11690
|
-
security:
|
|
11691
|
-
...
|
|
11690
|
+
security: N,
|
|
11691
|
+
...T ? { kafka: T } : {}
|
|
11692
11692
|
};
|
|
11693
11693
|
}
|
|
11694
11694
|
function oh(e) {
|
|
@@ -12387,7 +12387,7 @@ async function Th(e) {
|
|
|
12387
12387
|
Fe.registerLanguage(e, n.default);
|
|
12388
12388
|
}
|
|
12389
12389
|
function Ih({ operationId: e }) {
|
|
12390
|
-
const { document: t, showCodeSamples: n } = Ke(), r =
|
|
12390
|
+
const { document: t, showCodeSamples: n } = Ke(), r = nt(), s = X(
|
|
12391
12391
|
() => e ? Ah(t, e) : [],
|
|
12392
12392
|
[t, e]
|
|
12393
12393
|
), o = X(
|
|
@@ -12434,7 +12434,7 @@ function La({
|
|
|
12434
12434
|
}) {
|
|
12435
12435
|
const s = Kd(e), [o, i] = P(Ft), [l, c] = P(
|
|
12436
12436
|
() => /* @__PURE__ */ new Set([Ft])
|
|
12437
|
-
), d =
|
|
12437
|
+
), d = nt(), u = X(
|
|
12438
12438
|
() => new Map(s.map((b) => [b.id, b])),
|
|
12439
12439
|
[s]
|
|
12440
12440
|
), f = n && s.length > 0, p = f ? u.get(o) : void 0, h = (p == null ? void 0 : p.id) ?? Ft, m = [
|
|
@@ -12442,7 +12442,7 @@ function La({
|
|
|
12442
12442
|
...s.map((b) => ({ id: b.id, name: b.label }))
|
|
12443
12443
|
], x = (b) => {
|
|
12444
12444
|
c(
|
|
12445
|
-
(
|
|
12445
|
+
(N) => N.has(b) ? N : /* @__PURE__ */ new Set([...N, b])
|
|
12446
12446
|
), i(b);
|
|
12447
12447
|
};
|
|
12448
12448
|
return f ? /* @__PURE__ */ g(U, { children: [
|
|
@@ -12464,13 +12464,13 @@ function La({
|
|
|
12464
12464
|
tabs: m,
|
|
12465
12465
|
current: h,
|
|
12466
12466
|
idPrefix: d,
|
|
12467
|
-
renderPanel: (b,
|
|
12468
|
-
if (!
|
|
12467
|
+
renderPanel: (b, N) => {
|
|
12468
|
+
if (!N && !l.has(b.id)) return null;
|
|
12469
12469
|
if (b.id === Ft) return r;
|
|
12470
12470
|
const E = u.get(b.id);
|
|
12471
12471
|
if (!E) return null;
|
|
12472
|
-
const
|
|
12473
|
-
return /* @__PURE__ */ a(Gn, { label: `${e}:${E.pluginName}`, children: /* @__PURE__ */ a(
|
|
12472
|
+
const v = E.Component;
|
|
12473
|
+
return /* @__PURE__ */ a(Gn, { label: `${e}:${E.pluginName}`, children: /* @__PURE__ */ a(v, { ...t }) });
|
|
12474
12474
|
}
|
|
12475
12475
|
}
|
|
12476
12476
|
)
|
|
@@ -12478,7 +12478,7 @@ function La({
|
|
|
12478
12478
|
}
|
|
12479
12479
|
function Pa({ op: e, id: t, focusSection: n = null }) {
|
|
12480
12480
|
var x;
|
|
12481
|
-
const { document: r } = wl(), s =
|
|
12481
|
+
const { document: r } = wl(), s = nt(), o = e.messages ?? [], i = e.tags ?? [], l = e.bindings, c = e.traits, d = e.reply, u = e.externalDocs, f = e.security, p = l ?? (Array.isArray(c) ? (x = c.find((b) => b.bindings)) == null ? void 0 : x.bindings : void 0), h = e.action === Cn.SEND, m = /* @__PURE__ */ a("div", { className: "flex flex-col gap-2", children: o.map((b, N) => /* @__PURE__ */ a(Ta, { message: b, messageId: b.name, i: N }, N)) });
|
|
12482
12482
|
return /* @__PURE__ */ a("div", { className: "flex flex-col gap-6", id: `operation-${t}-detail`, children: /* @__PURE__ */ a(
|
|
12483
12483
|
La,
|
|
12484
12484
|
{
|
|
@@ -12534,13 +12534,13 @@ function Pa({ op: e, id: t, focusSection: n = null }) {
|
|
|
12534
12534
|
)
|
|
12535
12535
|
] }),
|
|
12536
12536
|
p && Object.entries(p).map(
|
|
12537
|
-
([b,
|
|
12537
|
+
([b, N]) => N ? /* @__PURE__ */ g("div", { id: `operation-${t}-bindings-${b}`, children: [
|
|
12538
12538
|
/* @__PURE__ */ a("p", { className: "text-xs font-medium text-foreground-muted uppercase tracking-wider mb-1", children: "Operation configuration" }),
|
|
12539
12539
|
/* @__PURE__ */ a(
|
|
12540
12540
|
Ea,
|
|
12541
12541
|
{
|
|
12542
12542
|
protocol: b,
|
|
12543
|
-
bindings:
|
|
12543
|
+
bindings: N,
|
|
12544
12544
|
focused: n === `binding:${b}`
|
|
12545
12545
|
}
|
|
12546
12546
|
)
|
|
@@ -12568,13 +12568,13 @@ function Pa({ op: e, id: t, focusSection: n = null }) {
|
|
|
12568
12568
|
] }),
|
|
12569
12569
|
i.length > 0 && /* @__PURE__ */ g("div", { children: [
|
|
12570
12570
|
/* @__PURE__ */ a("p", { className: "text-xs font-medium text-foreground-muted uppercase tracking-wider mb-2", children: "Tags" }),
|
|
12571
|
-
/* @__PURE__ */ a("div", { className: "flex flex-wrap gap-1.5", children: i.map((b,
|
|
12571
|
+
/* @__PURE__ */ a("div", { className: "flex flex-wrap gap-1.5", children: i.map((b, N) => /* @__PURE__ */ a(
|
|
12572
12572
|
"span",
|
|
12573
12573
|
{
|
|
12574
12574
|
className: "inline-flex items-center px-2 py-0.5 rounded text-xs bg-neutral-100 text-foreground-secondary",
|
|
12575
12575
|
children: b.name
|
|
12576
12576
|
},
|
|
12577
|
-
|
|
12577
|
+
N
|
|
12578
12578
|
)) })
|
|
12579
12579
|
] })
|
|
12580
12580
|
] })
|
|
@@ -12589,9 +12589,9 @@ const Oh = Xt(
|
|
|
12589
12589
|
function Ba({ op: e, operationKey: t }) {
|
|
12590
12590
|
const n = e.channel;
|
|
12591
12591
|
return n != null && n.address ? /* @__PURE__ */ g("div", { className: "flex items-center gap-2 min-w-0", children: [
|
|
12592
|
-
/* @__PURE__ */ a(
|
|
12592
|
+
/* @__PURE__ */ a(ot, { method: e.action }),
|
|
12593
12593
|
/* @__PURE__ */ a("div", { className: "min-w-0 flex-1 overflow-hidden", children: /* @__PURE__ */ a(
|
|
12594
|
-
|
|
12594
|
+
et,
|
|
12595
12595
|
{
|
|
12596
12596
|
address: n.address,
|
|
12597
12597
|
parameters: n.parameters,
|
|
@@ -12610,8 +12610,8 @@ function Da({ operations: e, selectedKey: t = null, onSelectKey: n, focusSection
|
|
|
12610
12610
|
if (!Object.keys(e).length)
|
|
12611
12611
|
return null;
|
|
12612
12612
|
const i = t ? e[t] : null, l = Object.keys(e).map((u) => {
|
|
12613
|
-
var v;
|
|
12614
|
-
const f = e[u], p = f.channel, h = p == null ? void 0 : p.address, m = p == null ? void 0 : p.parameters, x = ((
|
|
12613
|
+
var E, v;
|
|
12614
|
+
const f = e[u], p = f.channel, h = p == null ? void 0 : p.address, m = p == null ? void 0 : p.parameters, x = ((E = f.action) == null ? void 0 : E.toUpperCase()) ?? "", b = ((v = f.title) == null ? void 0 : v.trim()) || void 0, N = t === u;
|
|
12615
12615
|
return /* @__PURE__ */ g(
|
|
12616
12616
|
"tr",
|
|
12617
12617
|
{
|
|
@@ -12619,15 +12619,27 @@ function Da({ operations: e, selectedKey: t = null, onSelectKey: n, focusSection
|
|
|
12619
12619
|
onClick: () => o(u),
|
|
12620
12620
|
role: "button",
|
|
12621
12621
|
tabIndex: 0,
|
|
12622
|
-
"aria-label": `${x || "Operation"} ${h ?? u}`,
|
|
12623
|
-
"aria-current":
|
|
12624
|
-
onKeyDown: (
|
|
12625
|
-
|
|
12622
|
+
"aria-label": `${x || "Operation"} ${b ?? h ?? u}`,
|
|
12623
|
+
"aria-current": N ? "true" : void 0,
|
|
12624
|
+
onKeyDown: (C) => {
|
|
12625
|
+
C.key !== "Enter" && C.key !== " " || (C.preventDefault(), o(u));
|
|
12626
12626
|
},
|
|
12627
|
-
className: `cursor-pointer hover:bg-neutral-50 ${
|
|
12627
|
+
className: `cursor-pointer hover:bg-neutral-50 ${N ? "bg-neutral-50" : ""}`,
|
|
12628
12628
|
children: [
|
|
12629
|
-
/* @__PURE__ */ a("td", { className: "px-6 py-4 max-w-0 w-full", children:
|
|
12630
|
-
|
|
12629
|
+
/* @__PURE__ */ a("td", { className: "px-6 py-4 max-w-0 w-full", children: b ? /* @__PURE__ */ g("div", { className: "min-w-0", children: [
|
|
12630
|
+
/* @__PURE__ */ a("div", { className: "truncate text-sm font-medium text-foreground", children: b }),
|
|
12631
|
+
h && /* @__PURE__ */ a(
|
|
12632
|
+
et,
|
|
12633
|
+
{
|
|
12634
|
+
address: h,
|
|
12635
|
+
parameters: m,
|
|
12636
|
+
truncate: !0,
|
|
12637
|
+
padded: !1,
|
|
12638
|
+
className: "text-xs text-foreground-muted mt-0.5"
|
|
12639
|
+
}
|
|
12640
|
+
)
|
|
12641
|
+
] }) : h && /* @__PURE__ */ a(et, { address: h, parameters: m, truncate: !0 }) }),
|
|
12642
|
+
/* @__PURE__ */ a("td", { className: "px-6 py-4 w-32", children: /* @__PURE__ */ a(ot, { method: f.action, className: "w-24" }) })
|
|
12631
12643
|
]
|
|
12632
12644
|
},
|
|
12633
12645
|
u
|
|
@@ -12755,21 +12767,21 @@ const _h = (e) => e === "operations" || e === "messages" || e === "schemas", Mh
|
|
|
12755
12767
|
}
|
|
12756
12768
|
};
|
|
12757
12769
|
function Rh({ asyncapi: e, config: t, plugins: n, initialLocation: r, onLocationChange: s }) {
|
|
12758
|
-
var A, w,
|
|
12770
|
+
var A, w, I, D;
|
|
12759
12771
|
const o = t.show ?? {}, [i, l] = P(!1), [c, d] = P(!1), u = o.search !== !1 || o.copyMarkdown !== !1, f = o.info !== !1 && ta(e.info), p = (n == null ? void 0 : n.some((J) => !!J.slots["asyncapi.document.topbar"])) ?? !1, h = u || f || p, m = [
|
|
12760
12772
|
...o.operations !== !1 ? [{ id: "operations", name: "Operations", icon: Hn }] : [],
|
|
12761
12773
|
...o.messages !== !1 ? [{ id: "messages", name: "Messages", icon: Yo }] : [],
|
|
12762
12774
|
...o.schemas !== !1 ? [{ id: "schemas", name: "Schemas", icon: qr }] : []
|
|
12763
|
-
], { query: x, setQuery: b, results:
|
|
12775
|
+
], { query: x, setQuery: b, results: N } = hd(e, { threshold: 0.3, limit: 20 }), {
|
|
12764
12776
|
effectiveTab: E,
|
|
12765
|
-
focusTab:
|
|
12766
|
-
navActiveSection:
|
|
12777
|
+
focusTab: v,
|
|
12778
|
+
navActiveSection: C,
|
|
12767
12779
|
selected: F,
|
|
12768
12780
|
setSelectedKey: H,
|
|
12769
12781
|
selectedNavItem: S,
|
|
12770
12782
|
handleSearchSelect: k,
|
|
12771
12783
|
handleNavItemSelect: y,
|
|
12772
|
-
handleNavServerSelect:
|
|
12784
|
+
handleNavServerSelect: T,
|
|
12773
12785
|
handleContentTabChange: M,
|
|
12774
12786
|
focusSection: j,
|
|
12775
12787
|
schemaFocusTarget: L
|
|
@@ -12823,7 +12835,7 @@ function Rh({ asyncapi: e, config: t, plugins: n, initialLocation: r, onLocation
|
|
|
12823
12835
|
{
|
|
12824
12836
|
query: x,
|
|
12825
12837
|
onQueryChange: b,
|
|
12826
|
-
results:
|
|
12838
|
+
results: N,
|
|
12827
12839
|
onSelectResult: k,
|
|
12828
12840
|
onOpenChange: l
|
|
12829
12841
|
}
|
|
@@ -12854,15 +12866,15 @@ function Rh({ asyncapi: e, config: t, plugins: n, initialLocation: r, onLocation
|
|
|
12854
12866
|
hc,
|
|
12855
12867
|
{
|
|
12856
12868
|
operations: o.operations !== !1 ? e.operations : void 0,
|
|
12857
|
-
messages: o.messages !== !1 ? (
|
|
12869
|
+
messages: o.messages !== !1 ? (I = e.components) == null ? void 0 : I.messages : void 0,
|
|
12858
12870
|
schemas: o.schemas !== !1 ? (D = e.components) == null ? void 0 : D.schemas : void 0,
|
|
12859
12871
|
servers: o.servers !== !1 ? e.servers : void 0,
|
|
12860
12872
|
hasInfo: o.info !== !1,
|
|
12861
12873
|
sidebarConfig: t.sidebar,
|
|
12862
|
-
activeTab:
|
|
12863
|
-
onTabChange:
|
|
12874
|
+
activeTab: C,
|
|
12875
|
+
onTabChange: v,
|
|
12864
12876
|
onItemSelect: y,
|
|
12865
|
-
onSelectServer:
|
|
12877
|
+
onSelectServer: T,
|
|
12866
12878
|
selectedItem: S
|
|
12867
12879
|
}
|
|
12868
12880
|
)
|
|
@@ -13157,7 +13169,7 @@ function Kh({
|
|
|
13157
13169
|
sn,
|
|
13158
13170
|
{
|
|
13159
13171
|
trigger: /* @__PURE__ */ g("span", { className: "flex items-center gap-2 text-xs font-normal min-w-0", children: [
|
|
13160
|
-
/* @__PURE__ */ a(
|
|
13172
|
+
/* @__PURE__ */ a(ot, { method: l, size: "xs", className: "shrink-0" }),
|
|
13161
13173
|
/* @__PURE__ */ a("span", { className: "font-medium text-foreground-secondary shrink-0", children: o }),
|
|
13162
13174
|
/* @__PURE__ */ a("code", { className: "font-mono text-foreground-muted truncate", children: Fh(i) })
|
|
13163
13175
|
] }),
|
|
@@ -13178,7 +13190,7 @@ function Kh({
|
|
|
13178
13190
|
] });
|
|
13179
13191
|
}
|
|
13180
13192
|
const Gh = Xt(
|
|
13181
|
-
() => import("./CodeSamples-
|
|
13193
|
+
() => import("./CodeSamples-BxUKzCvO.js").then(({ CodeSamples: e }) => ({ default: e }))
|
|
13182
13194
|
);
|
|
13183
13195
|
function Vh(e) {
|
|
13184
13196
|
return e.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/([A-Z]+)([A-Z][a-z])/g, "$1 $2");
|
|
@@ -13220,10 +13232,10 @@ function Zh({
|
|
|
13220
13232
|
isOperationKnown: n
|
|
13221
13233
|
}) {
|
|
13222
13234
|
var H, S;
|
|
13223
|
-
const r = Object.keys(e), [s, o] = P(r[0]), i = e[s], l = Object.keys((i == null ? void 0 : i.content) ?? {}), [c, d] = P(l[0]), u = c ? (H = i == null ? void 0 : i.content) == null ? void 0 : H[c] : void 0, f = (i == null ? void 0 : i.headers) ?? {}, p = (i == null ? void 0 : i.links) ?? {}, [h, m] = P("body"), x = l.length > 0 && !!u, b = Object.keys(f).length > 0,
|
|
13235
|
+
const r = Object.keys(e), [s, o] = P(r[0]), i = e[s], l = Object.keys((i == null ? void 0 : i.content) ?? {}), [c, d] = P(l[0]), u = c ? (H = i == null ? void 0 : i.content) == null ? void 0 : H[c] : void 0, f = (i == null ? void 0 : i.headers) ?? {}, p = (i == null ? void 0 : i.links) ?? {}, [h, m] = P("body"), x = l.length > 0 && !!u, b = Object.keys(f).length > 0, N = Object.keys(p).length > 0, E = [
|
|
13224
13236
|
...x ? [{ id: "body", name: "Body" }] : [],
|
|
13225
13237
|
...b ? [{ id: "headers", name: "Headers" }] : []
|
|
13226
|
-
],
|
|
13238
|
+
], v = E.length > 1, C = E.some((k) => k.id === h) ? h : (S = E[0]) == null ? void 0 : S.id, F = E.length > 0;
|
|
13227
13239
|
return K(() => {
|
|
13228
13240
|
d(Object.keys((i == null ? void 0 : i.content) ?? {})[0]), m("body");
|
|
13229
13241
|
}, [s]), /* @__PURE__ */ g("div", { children: [
|
|
@@ -13240,15 +13252,15 @@ function Zh({
|
|
|
13240
13252
|
)) }),
|
|
13241
13253
|
(i == null ? void 0 : i.description) && /* @__PURE__ */ a("p", { className: "text-sm text-foreground-secondary mb-3", children: i.description }),
|
|
13242
13254
|
F ? /* @__PURE__ */ g(U, { children: [
|
|
13243
|
-
|
|
13255
|
+
v && /* @__PURE__ */ a(
|
|
13244
13256
|
ht,
|
|
13245
13257
|
{
|
|
13246
13258
|
tabs: E,
|
|
13247
|
-
current:
|
|
13259
|
+
current: C,
|
|
13248
13260
|
onChange: (k) => m(k)
|
|
13249
13261
|
}
|
|
13250
13262
|
),
|
|
13251
|
-
/* @__PURE__ */ a("div", { className:
|
|
13263
|
+
/* @__PURE__ */ a("div", { className: v ? "mt-4" : void 0, children: C === "headers" ? /* @__PURE__ */ a(
|
|
13252
13264
|
Et,
|
|
13253
13265
|
{
|
|
13254
13266
|
schema: Yh(f),
|
|
@@ -13276,7 +13288,7 @@ function Zh({
|
|
|
13276
13288
|
"body"
|
|
13277
13289
|
) })
|
|
13278
13290
|
] }) : /* @__PURE__ */ a("p", { className: "text-xs text-foreground-muted italic", children: "No response body." }),
|
|
13279
|
-
|
|
13291
|
+
N && /* @__PURE__ */ a(
|
|
13280
13292
|
Uh,
|
|
13281
13293
|
{
|
|
13282
13294
|
links: p,
|
|
@@ -13400,15 +13412,15 @@ function tm({
|
|
|
13400
13412
|
...h ? ["callbacks"] : []
|
|
13401
13413
|
], [x, b] = P(m[0] ?? "request");
|
|
13402
13414
|
if (m.length === 0) return null;
|
|
13403
|
-
const
|
|
13415
|
+
const N = m.includes(x) ? x : m[0];
|
|
13404
13416
|
return /* @__PURE__ */ g("div", { className: c ? "flex-1 flex flex-col min-h-0" : void 0, children: [
|
|
13405
13417
|
/* @__PURE__ */ a("div", { className: "flex items-end gap-0.5 -ml-2", role: "tablist", "aria-label": "Operation exchange", children: m.map((E) => /* @__PURE__ */ a(
|
|
13406
13418
|
"button",
|
|
13407
13419
|
{
|
|
13408
13420
|
role: "tab",
|
|
13409
|
-
"aria-selected":
|
|
13421
|
+
"aria-selected": N === E,
|
|
13410
13422
|
onClick: () => b(E),
|
|
13411
|
-
className: `px-3 py-1.5 text-sm font-medium rounded-t-md transition-colors capitalize ${
|
|
13423
|
+
className: `px-3 py-1.5 text-sm font-medium rounded-t-md transition-colors capitalize ${N === E ? "bg-neutral-100 text-foreground border border-b-0 border-border" : "text-foreground-muted hover:text-foreground-secondary"}`,
|
|
13412
13424
|
children: E
|
|
13413
13425
|
},
|
|
13414
13426
|
E
|
|
@@ -13418,7 +13430,7 @@ function tm({
|
|
|
13418
13430
|
{
|
|
13419
13431
|
className: `-mx-5 px-5 py-4 bg-neutral-100 border-t border-border min-h-32 ${c ? "flex-1 -mb-4" : ""}`,
|
|
13420
13432
|
children: [
|
|
13421
|
-
|
|
13433
|
+
N === "request" && /* @__PURE__ */ a(
|
|
13422
13434
|
qh,
|
|
13423
13435
|
{
|
|
13424
13436
|
label: e,
|
|
@@ -13427,7 +13439,7 @@ function tm({
|
|
|
13427
13439
|
requestBodyDescription: r
|
|
13428
13440
|
}
|
|
13429
13441
|
),
|
|
13430
|
-
|
|
13442
|
+
N === "response" && /* @__PURE__ */ a(
|
|
13431
13443
|
Zh,
|
|
13432
13444
|
{
|
|
13433
13445
|
responses: s,
|
|
@@ -13435,7 +13447,7 @@ function tm({
|
|
|
13435
13447
|
isOperationKnown: u
|
|
13436
13448
|
}
|
|
13437
13449
|
),
|
|
13438
|
-
|
|
13450
|
+
N === "callbacks" && o && /* @__PURE__ */ a(
|
|
13439
13451
|
Kh,
|
|
13440
13452
|
{
|
|
13441
13453
|
callbacks: o,
|
|
@@ -13462,15 +13474,15 @@ function Ts({
|
|
|
13462
13474
|
isOperationKnown: c,
|
|
13463
13475
|
depth: d = 0
|
|
13464
13476
|
}) {
|
|
13465
|
-
var
|
|
13466
|
-
const { document: u } = kl(), f = (n.parameters ?? []).filter((S) => S.in !== "query" && S.in !== "path"), p = n.security ?? o ?? [], h = n.responses ?? {}, m = ((
|
|
13477
|
+
var v, C, F, H;
|
|
13478
|
+
const { document: u } = kl(), f = (n.parameters ?? []).filter((S) => S.in !== "query" && S.in !== "path"), p = n.security ?? o ?? [], h = n.responses ?? {}, m = ((v = n.requestBody) == null ? void 0 : v.content) ?? {}, x = n.operationId ? Vh(n.operationId) : `${e.toUpperCase()} ${t}`, b = /* @__PURE__ */ new Map();
|
|
13467
13479
|
for (const S of p)
|
|
13468
13480
|
for (const [k, y] of Object.entries(S)) {
|
|
13469
13481
|
if (y.length === 0) continue;
|
|
13470
|
-
const
|
|
13471
|
-
b.set(k, Array.from(/* @__PURE__ */ new Set([...
|
|
13482
|
+
const T = b.get(k) ?? [];
|
|
13483
|
+
b.set(k, Array.from(/* @__PURE__ */ new Set([...T, ...y])));
|
|
13472
13484
|
}
|
|
13473
|
-
const
|
|
13485
|
+
const N = Array.from(new Set(p.flatMap((S) => Object.keys(S)))).map((S) => {
|
|
13474
13486
|
const k = i == null ? void 0 : i[S];
|
|
13475
13487
|
if (!k) return null;
|
|
13476
13488
|
const y = b.get(S);
|
|
@@ -13488,7 +13500,7 @@ function Ts({
|
|
|
13488
13500
|
context: { document: u, method: e, path: t },
|
|
13489
13501
|
enabled: E,
|
|
13490
13502
|
children: /* @__PURE__ */ g(U, { children: [
|
|
13491
|
-
(n.deprecated || ((
|
|
13503
|
+
(n.deprecated || ((C = n.externalDocs) == null ? void 0 : C.url)) && /* @__PURE__ */ g("div", { className: "flex items-center gap-2", children: [
|
|
13492
13504
|
n.deprecated && /* @__PURE__ */ a("span", { className: "inline-flex items-center px-2 py-0.5 rounded text-xs font-medium bg-amber-100 text-amber-800", children: "Deprecated" }),
|
|
13493
13505
|
((F = n.externalDocs) == null ? void 0 : F.url) && qe(n.externalDocs.url) && /* @__PURE__ */ g(
|
|
13494
13506
|
"a",
|
|
@@ -13521,15 +13533,15 @@ function Ts({
|
|
|
13521
13533
|
/* @__PURE__ */ a(Vn, { name: "openapi.operation.reference.supplementary", context: { document: u, method: e, path: t } }),
|
|
13522
13534
|
p.length > 0 && /* @__PURE__ */ g("div", { id: `${s}-${r}-security`, children: [
|
|
13523
13535
|
/* @__PURE__ */ a("p", { className: "text-xs font-medium text-foreground-muted uppercase tracking-wider mb-2", children: "Authorization" }),
|
|
13524
|
-
|
|
13536
|
+
N.length > 0 && /* @__PURE__ */ a(
|
|
13525
13537
|
sn,
|
|
13526
13538
|
{
|
|
13527
13539
|
className: "mt-3",
|
|
13528
13540
|
trigger: /* @__PURE__ */ g("span", { className: "flex items-center gap-2 text-xs font-normal text-foreground-muted", children: [
|
|
13529
13541
|
/* @__PURE__ */ a(ka, { className: "h-4 w-4 text-foreground-muted" }),
|
|
13530
|
-
/* @__PURE__ */ a("span", { className: "bg-neutral-100 border border-border rounded-full px-2 py-0.5", children:
|
|
13542
|
+
/* @__PURE__ */ a("span", { className: "bg-neutral-100 border border-border rounded-full px-2 py-0.5", children: N.length })
|
|
13531
13543
|
] }),
|
|
13532
|
-
children: /* @__PURE__ */ a("div", { className: "px-4 py-2 border-t border-border", children: /* @__PURE__ */ a($s, { securities:
|
|
13544
|
+
children: /* @__PURE__ */ a("div", { className: "px-4 py-2 border-t border-border", children: /* @__PURE__ */ a($s, { securities: N }) })
|
|
13533
13545
|
}
|
|
13534
13546
|
)
|
|
13535
13547
|
] }),
|
|
@@ -13557,7 +13569,7 @@ function Ts({
|
|
|
13557
13569
|
}
|
|
13558
13570
|
const Oo = 320;
|
|
13559
13571
|
function rm({ parameters: e }) {
|
|
13560
|
-
const { portalHost: t } = $e(), [n, r] = P(!1), [s, o] = P({ top: 0, left: 0, placement: "bottom" }), i = ge(null), l = ge(null), c =
|
|
13572
|
+
const { portalHost: t } = $e(), [n, r] = P(!1), [s, o] = P({ top: 0, left: 0, placement: "bottom" }), i = ge(null), l = ge(null), c = nt();
|
|
13561
13573
|
return K(() => {
|
|
13562
13574
|
if (!n) return;
|
|
13563
13575
|
const d = i.current;
|
|
@@ -13682,9 +13694,9 @@ function Xa({
|
|
|
13682
13694
|
parameters: n
|
|
13683
13695
|
}) {
|
|
13684
13696
|
return /* @__PURE__ */ g("div", { className: "flex items-center gap-2 min-w-0", children: [
|
|
13685
|
-
/* @__PURE__ */ a(
|
|
13697
|
+
/* @__PURE__ */ a(ot, { method: e }),
|
|
13686
13698
|
/* @__PURE__ */ a("div", { className: "min-w-0 flex-1 overflow-hidden", children: /* @__PURE__ */ a(
|
|
13687
|
-
|
|
13699
|
+
et,
|
|
13688
13700
|
{
|
|
13689
13701
|
address: t,
|
|
13690
13702
|
parameters: Za(n),
|
|
@@ -13717,10 +13729,10 @@ function Dn({
|
|
|
13717
13729
|
}) {
|
|
13718
13730
|
var H;
|
|
13719
13731
|
const c = (S) => s == null ? void 0 : s(S), d = X(() => Nt(e), [e]), u = X(() => {
|
|
13720
|
-
var k, y,
|
|
13732
|
+
var k, y, T;
|
|
13721
13733
|
const S = /* @__PURE__ */ new Map();
|
|
13722
13734
|
for (const M of d) {
|
|
13723
|
-
const j = ((
|
|
13735
|
+
const j = ((T = (y = (k = e[M.path]) == null ? void 0 : k[M.method]) == null ? void 0 : y.tags) == null ? void 0 : T[0]) || "Other", L = S.get(j) ?? [];
|
|
13724
13736
|
L.push(M), S.set(j, L);
|
|
13725
13737
|
}
|
|
13726
13738
|
return Array.from(S, ([M, j]) => ({ label: M, items: j }));
|
|
@@ -13737,15 +13749,15 @@ function Dn({
|
|
|
13737
13749
|
const m = X(() => {
|
|
13738
13750
|
var k, y;
|
|
13739
13751
|
const S = /* @__PURE__ */ new Map();
|
|
13740
|
-
for (const { key:
|
|
13752
|
+
for (const { key: T, method: M, path: j } of d) {
|
|
13741
13753
|
const L = (y = (k = e[j]) == null ? void 0 : k[M]) == null ? void 0 : y.operationId;
|
|
13742
|
-
L && S.set(L,
|
|
13754
|
+
L && S.set(L, T);
|
|
13743
13755
|
}
|
|
13744
13756
|
return S;
|
|
13745
13757
|
}, [d, e]);
|
|
13746
13758
|
if (d.length === 0)
|
|
13747
13759
|
return null;
|
|
13748
|
-
const x = r ? d.find((S) => S.key === r) : null, b = x ? (H = e[x.path]) == null ? void 0 : H[x.method] : null,
|
|
13760
|
+
const x = r ? d.find((S) => S.key === r) : null, b = x ? (H = e[x.path]) == null ? void 0 : H[x.method] : null, N = ({ key: S, method: k, path: y }, T) => {
|
|
13749
13761
|
var L;
|
|
13750
13762
|
const M = r === S, j = yr(e[y], (L = e[y]) == null ? void 0 : L[k]);
|
|
13751
13763
|
return /* @__PURE__ */ g(
|
|
@@ -13754,17 +13766,17 @@ function Dn({
|
|
|
13754
13766
|
id: `${i}-${S}`,
|
|
13755
13767
|
onClick: () => c(S),
|
|
13756
13768
|
role: "button",
|
|
13757
|
-
tabIndex:
|
|
13758
|
-
"aria-hidden": !
|
|
13769
|
+
tabIndex: T ? 0 : -1,
|
|
13770
|
+
"aria-hidden": !T,
|
|
13759
13771
|
"aria-label": `${k.toUpperCase()} ${y}`,
|
|
13760
13772
|
"aria-current": M ? "true" : void 0,
|
|
13761
13773
|
onKeyDown: (G) => {
|
|
13762
13774
|
G.key !== "Enter" && G.key !== " " || (G.preventDefault(), c(S));
|
|
13763
13775
|
},
|
|
13764
|
-
className: `group transition-[opacity,visibility] duration-300 ease-in-out ${
|
|
13776
|
+
className: `group transition-[opacity,visibility] duration-300 ease-in-out ${T ? `cursor-pointer opacity-100 visible ${M ? "bg-neutral-50" : ""}` : "pointer-events-none invisible opacity-0"}`,
|
|
13765
13777
|
children: [
|
|
13766
|
-
/* @__PURE__ */ a("td", { className: `px-6 max-w-0 w-full group-hover:bg-neutral-50 transition-[padding] duration-300 ease-in-out ${
|
|
13767
|
-
|
|
13778
|
+
/* @__PURE__ */ a("td", { className: `px-6 max-w-0 w-full group-hover:bg-neutral-50 transition-[padding] duration-300 ease-in-out ${T ? "py-2" : "py-0"}`, children: /* @__PURE__ */ a("div", { className: `overflow-hidden transition-[max-height] duration-300 ease-in-out ${T ? "max-h-12" : "max-h-0"}`, children: /* @__PURE__ */ a(
|
|
13779
|
+
et,
|
|
13768
13780
|
{
|
|
13769
13781
|
address: y,
|
|
13770
13782
|
parameters: Za(j),
|
|
@@ -13772,28 +13784,28 @@ function Dn({
|
|
|
13772
13784
|
className: "text-xs"
|
|
13773
13785
|
}
|
|
13774
13786
|
) }) }),
|
|
13775
|
-
/* @__PURE__ */ a("td", { className: `px-6 w-28 group-hover:bg-neutral-50 transition-[padding] duration-300 ease-in-out ${
|
|
13787
|
+
/* @__PURE__ */ a("td", { className: `px-6 w-28 group-hover:bg-neutral-50 transition-[padding] duration-300 ease-in-out ${T ? "py-2" : "py-0"}`, children: /* @__PURE__ */ a("div", { className: `overflow-hidden transition-[max-height] duration-300 ease-in-out ${T ? "max-h-12" : "max-h-0"}`, children: /* @__PURE__ */ a(ot, { method: k, className: "w-20" }) }) })
|
|
13776
13788
|
]
|
|
13777
13789
|
},
|
|
13778
13790
|
S
|
|
13779
13791
|
);
|
|
13780
13792
|
}, E = u.map(({ label: S, items: k }, y) => {
|
|
13781
|
-
const
|
|
13793
|
+
const T = !f.has(S), M = `${i}-group-${y}-${S.toLowerCase().replace(/[^a-z0-9]+/g, "-")}`;
|
|
13782
13794
|
return /* @__PURE__ */ g(Ro, { children: [
|
|
13783
13795
|
/* @__PURE__ */ a("tbody", { className: "border-y border-border first:border-t-0", children: /* @__PURE__ */ a("tr", { className: "bg-neutral-50/70", children: /* @__PURE__ */ a("th", { colSpan: 2, scope: "rowgroup", className: "p-0 text-left", children: /* @__PURE__ */ g(
|
|
13784
13796
|
"button",
|
|
13785
13797
|
{
|
|
13786
13798
|
type: "button",
|
|
13787
13799
|
"aria-label": `${S} endpoints (${k.length})`,
|
|
13788
|
-
"aria-expanded":
|
|
13800
|
+
"aria-expanded": T,
|
|
13789
13801
|
"aria-controls": M,
|
|
13790
13802
|
onClick: () => p((j) => {
|
|
13791
13803
|
const L = new Set(j);
|
|
13792
|
-
return
|
|
13804
|
+
return T ? L.add(S) : L.delete(S), L;
|
|
13793
13805
|
}),
|
|
13794
13806
|
className: "group/header flex w-full items-center gap-3 px-6 py-3.5 text-left hover:bg-neutral-100/80 transition-colors",
|
|
13795
13807
|
children: [
|
|
13796
|
-
/* @__PURE__ */ a("span", { className: "flex h-6 w-6 shrink-0 items-center justify-center rounded-md border border-border bg-surface text-foreground-muted shadow-sm transition-colors group-hover/header:border-neutral-300 group-hover/header:text-foreground-secondary", children:
|
|
13808
|
+
/* @__PURE__ */ a("span", { className: "flex h-6 w-6 shrink-0 items-center justify-center rounded-md border border-border bg-surface text-foreground-muted shadow-sm transition-colors group-hover/header:border-neutral-300 group-hover/header:text-foreground-secondary", children: T ? /* @__PURE__ */ a(Tt, { className: "h-2.5 w-2.5" }) : /* @__PURE__ */ a(Na, { className: "h-2.5 w-2.5" }) }),
|
|
13797
13809
|
/* @__PURE__ */ a("span", { className: "min-w-0 flex-1 truncate text-sm font-semibold tracking-wide text-foreground-secondary", children: S }),
|
|
13798
13810
|
/* @__PURE__ */ a("span", { className: "inline-flex min-w-6 items-center justify-center rounded-full bg-neutral-200/70 px-2 py-0.5 text-xs font-medium tabular-nums text-foreground-muted", children: k.length })
|
|
13799
13811
|
]
|
|
@@ -13803,13 +13815,13 @@ function Dn({
|
|
|
13803
13815
|
"tbody",
|
|
13804
13816
|
{
|
|
13805
13817
|
id: M,
|
|
13806
|
-
"aria-hidden": !
|
|
13807
|
-
className: `bg-surface ${
|
|
13808
|
-
children: k.map((j) =>
|
|
13818
|
+
"aria-hidden": !T,
|
|
13819
|
+
className: `bg-surface ${T ? "divide-y divide-border" : ""}`,
|
|
13820
|
+
children: k.map((j) => N(j, T))
|
|
13809
13821
|
}
|
|
13810
13822
|
)
|
|
13811
13823
|
] }, S);
|
|
13812
|
-
}),
|
|
13824
|
+
}), v = yr(x ? e[x.path] : void 0, b), C = x ? /* @__PURE__ */ a(Xa, { method: x.method, path: x.path, parameters: v }) : r;
|
|
13813
13825
|
return /* @__PURE__ */ g(U, { children: [
|
|
13814
13826
|
/* @__PURE__ */ a("div", { className: "flex justify-center w-full", children: /* @__PURE__ */ a(Be, { content: /* @__PURE__ */ g("div", { children: [
|
|
13815
13827
|
/* @__PURE__ */ a("div", { className: "mb-3 flex justify-end", children: /* @__PURE__ */ g("label", { className: "flex cursor-pointer items-center gap-2 text-xs text-foreground-secondary", children: [
|
|
@@ -13845,14 +13857,14 @@ function Dn({
|
|
|
13845
13857
|
isOpen: !!x,
|
|
13846
13858
|
side: "right",
|
|
13847
13859
|
onClose: () => c(null),
|
|
13848
|
-
title:
|
|
13860
|
+
title: C,
|
|
13849
13861
|
headerActions: x && /* @__PURE__ */ a(Ya, { method: x.method, path: x.path }),
|
|
13850
13862
|
children: x && b && /* @__PURE__ */ a(
|
|
13851
13863
|
Ts,
|
|
13852
13864
|
{
|
|
13853
13865
|
method: x.method,
|
|
13854
13866
|
path: x.path,
|
|
13855
|
-
op: { ...b, parameters:
|
|
13867
|
+
op: { ...b, parameters: v },
|
|
13856
13868
|
id: x.key,
|
|
13857
13869
|
idPrefix: i,
|
|
13858
13870
|
globalSecurity: t,
|
|
@@ -13882,19 +13894,19 @@ const im = (e) => e === "endpoints" || e === "webhooks" || e === "schemas", am =
|
|
|
13882
13894
|
}
|
|
13883
13895
|
};
|
|
13884
13896
|
function lm({ openapi: e, config: t, plugins: n, initialLocation: r, onLocationChange: s }) {
|
|
13885
|
-
var w,
|
|
13897
|
+
var w, I, D, J;
|
|
13886
13898
|
const o = t.show ?? {}, [i, l] = P(!1), [c, d] = P(!1), u = o.search !== !1 || o.copyMarkdown !== !1, f = o.info !== !1 && ta(e.info), p = (n == null ? void 0 : n.some((Y) => !!Y.slots["openapi.document.topbar"])) ?? !1, h = u || f || p, m = e.webhooks ?? {}, x = Object.keys(m).length > 0, b = [
|
|
13887
13899
|
...o.endpoints !== !1 ? [{ id: "endpoints", name: "Endpoints", icon: Hn }] : [],
|
|
13888
13900
|
...x && o.webhooks !== !1 ? [{ id: "webhooks", name: "Webhooks", icon: es }] : [],
|
|
13889
13901
|
...o.schemas !== !1 ? [{ id: "schemas", name: "Schemas", icon: qr }] : []
|
|
13890
|
-
], { query:
|
|
13891
|
-
effectiveTab:
|
|
13902
|
+
], { query: N, setQuery: E, results: v } = Bh(e, { threshold: 0.3, limit: 20 }), {
|
|
13903
|
+
effectiveTab: C,
|
|
13892
13904
|
focusTab: F,
|
|
13893
13905
|
navActiveSection: H,
|
|
13894
13906
|
selected: S,
|
|
13895
13907
|
setSelectedKey: k,
|
|
13896
13908
|
selectedNavItem: y,
|
|
13897
|
-
handleSearchSelect:
|
|
13909
|
+
handleSearchSelect: T,
|
|
13898
13910
|
handleNavItemSelect: M,
|
|
13899
13911
|
handleNavServerSelect: j,
|
|
13900
13912
|
handleContentTabChange: L,
|
|
@@ -13909,11 +13921,11 @@ function lm({ openapi: e, config: t, plugins: n, initialLocation: r, onLocationC
|
|
|
13909
13921
|
{ id: "schemas", visible: o.schemas !== !1 },
|
|
13910
13922
|
{ id: "servers", visible: o.servers !== !1 }
|
|
13911
13923
|
],
|
|
13912
|
-
searchQuery:
|
|
13924
|
+
searchQuery: N,
|
|
13913
13925
|
initialLocation: r,
|
|
13914
13926
|
onLocationChange: s,
|
|
13915
13927
|
getTargetId: am
|
|
13916
|
-
}), Q = (e.servers ?? []).map((Y) => Y.url), A =
|
|
13928
|
+
}), Q = (e.servers ?? []).map((Y) => Y.url), A = C === "endpoints" ? /* @__PURE__ */ a(
|
|
13917
13929
|
Dn,
|
|
13918
13930
|
{
|
|
13919
13931
|
paths: e.paths ?? {},
|
|
@@ -13922,18 +13934,18 @@ function lm({ openapi: e, config: t, plugins: n, initialLocation: r, onLocationC
|
|
|
13922
13934
|
selectedKey: S.endpoints,
|
|
13923
13935
|
onSelectKey: (Y) => k("endpoints", Y)
|
|
13924
13936
|
}
|
|
13925
|
-
) :
|
|
13937
|
+
) : C === "webhooks" ? /* @__PURE__ */ a(
|
|
13926
13938
|
Dn,
|
|
13927
13939
|
{
|
|
13928
13940
|
paths: m,
|
|
13929
13941
|
security: e.security,
|
|
13930
|
-
securitySchemes: (
|
|
13942
|
+
securitySchemes: (I = e.components) == null ? void 0 : I.securitySchemes,
|
|
13931
13943
|
selectedKey: S.webhooks,
|
|
13932
13944
|
onSelectKey: (Y) => k("webhooks", Y),
|
|
13933
13945
|
columnLabel: "Webhook",
|
|
13934
13946
|
idPrefix: "webhook"
|
|
13935
13947
|
}
|
|
13936
|
-
) :
|
|
13948
|
+
) : C === "schemas" ? /* @__PURE__ */ a(
|
|
13937
13949
|
Cs,
|
|
13938
13950
|
{
|
|
13939
13951
|
schemas: ((D = e.components) == null ? void 0 : D.schemas) ?? {},
|
|
@@ -13952,10 +13964,10 @@ function lm({ openapi: e, config: t, plugins: n, initialLocation: r, onLocationC
|
|
|
13952
13964
|
o.search !== !1 && /* @__PURE__ */ a(
|
|
13953
13965
|
qo,
|
|
13954
13966
|
{
|
|
13955
|
-
query:
|
|
13967
|
+
query: N,
|
|
13956
13968
|
onQueryChange: E,
|
|
13957
|
-
results:
|
|
13958
|
-
onSelectResult:
|
|
13969
|
+
results: v,
|
|
13970
|
+
onSelectResult: T,
|
|
13959
13971
|
onOpenChange: l
|
|
13960
13972
|
}
|
|
13961
13973
|
),
|
|
@@ -13986,8 +13998,8 @@ function lm({ openapi: e, config: t, plugins: n, initialLocation: r, onLocationC
|
|
|
13986
13998
|
onSelectServer: (Y) => k("servers", Y)
|
|
13987
13999
|
}
|
|
13988
14000
|
) }),
|
|
13989
|
-
/* @__PURE__ */ a(Wo, { tabs: b, current:
|
|
13990
|
-
|
|
14001
|
+
/* @__PURE__ */ a(Wo, { tabs: b, current: C, onChange: L }),
|
|
14002
|
+
C && /* @__PURE__ */ a("div", { id: `panel-${C}`, role: "tabpanel", "aria-labelledby": `tab-${C}`, children: A }),
|
|
13991
14003
|
o.sidebar !== !1 && /* @__PURE__ */ a(
|
|
13992
14004
|
bc,
|
|
13993
14005
|
{
|
|
@@ -14184,7 +14196,7 @@ function xm(e) {
|
|
|
14184
14196
|
}
|
|
14185
14197
|
async function wm() {
|
|
14186
14198
|
try {
|
|
14187
|
-
const e = await import("./index-
|
|
14199
|
+
const e = await import("./index-CfMaEll2.js").then((n) => n.i), t = e.default ?? e;
|
|
14188
14200
|
if (typeof t != "function")
|
|
14189
14201
|
throw new Error("Unexpected export shape from '@asyncapi/parser/browser'.");
|
|
14190
14202
|
return t;
|
|
@@ -14198,7 +14210,7 @@ async function el(e) {
|
|
|
14198
14210
|
try {
|
|
14199
14211
|
const t = await wm(), n = new t();
|
|
14200
14212
|
bm(n);
|
|
14201
|
-
const { registerProtobufSchemaParser: r } = await import("./protobufSchemaParser-
|
|
14213
|
+
const { registerProtobufSchemaParser: r } = await import("./protobufSchemaParser-Cz0UkK1s.js");
|
|
14202
14214
|
r(n);
|
|
14203
14215
|
const { document: s, diagnostics: o } = await n.parse(e);
|
|
14204
14216
|
return {
|
|
@@ -14263,7 +14275,7 @@ function qm({
|
|
|
14263
14275
|
}
|
|
14264
14276
|
async function vm() {
|
|
14265
14277
|
try {
|
|
14266
|
-
return await import("./index-
|
|
14278
|
+
return await import("./index-B3fyC_vS.js");
|
|
14267
14279
|
} catch (e) {
|
|
14268
14280
|
throw console.error("[apiuikit] Failed to load '@scalar/openapi-parser':", e), new Error(
|
|
14269
14281
|
"[apiuikit] The parsed entry requires '@scalar/openapi-parser'. Install it (`npm i @scalar/openapi-parser`), or use the `OpenAPI` component with a pre-resolved document instead."
|
|
@@ -14559,8 +14571,8 @@ function il({
|
|
|
14559
14571
|
var m, x;
|
|
14560
14572
|
const h = /* @__PURE__ */ new Set();
|
|
14561
14573
|
for (const b of Nt(r)) {
|
|
14562
|
-
const
|
|
14563
|
-
|
|
14574
|
+
const N = (x = (m = r[b.path]) == null ? void 0 : m[b.method]) == null ? void 0 : x.operationId;
|
|
14575
|
+
N && h.add(N);
|
|
14564
14576
|
}
|
|
14565
14577
|
return h;
|
|
14566
14578
|
}, [r]);
|