zudoku 0.25.0 → 0.25.2

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.
Files changed (86) hide show
  1. package/dist/config/validators/InputSidebarSchema.d.ts +15 -0
  2. package/dist/config/validators/InputSidebarSchema.js +1 -0
  3. package/dist/config/validators/InputSidebarSchema.js.map +1 -1
  4. package/dist/config/validators/common.d.ts +45 -34
  5. package/dist/config/validators/common.js +2 -1
  6. package/dist/config/validators/common.js.map +1 -1
  7. package/dist/config/validators/validate.d.ts +19 -14
  8. package/dist/lib/authentication/components/SignOut.js +1 -1
  9. package/dist/lib/authentication/components/SignOut.js.map +1 -1
  10. package/dist/lib/authentication/providers/clerk.js +29 -6
  11. package/dist/lib/authentication/providers/clerk.js.map +1 -1
  12. package/dist/lib/authentication/providers/openid.js +1 -1
  13. package/dist/lib/authentication/providers/openid.js.map +1 -1
  14. package/dist/lib/components/navigation/SidebarBadge.d.ts +11 -1
  15. package/dist/lib/components/navigation/SidebarBadge.js +11 -2
  16. package/dist/lib/components/navigation/SidebarBadge.js.map +1 -1
  17. package/dist/lib/components/navigation/SidebarCategory.js +2 -2
  18. package/dist/lib/components/navigation/SidebarCategory.js.map +1 -1
  19. package/dist/lib/components/navigation/SidebarWrapper.js +1 -1
  20. package/dist/lib/components/navigation/SidebarWrapper.js.map +1 -1
  21. package/dist/lib/oas/graphql/index.js +16 -3
  22. package/dist/lib/oas/graphql/index.js.map +1 -1
  23. package/dist/lib/oas/parser/upgrade/index.js +17 -3
  24. package/dist/lib/oas/parser/upgrade/index.js.map +1 -1
  25. package/dist/lib/plugins/openapi/CollapsibleCode.js +1 -1
  26. package/dist/lib/plugins/openapi/Endpoint.d.ts +1 -1
  27. package/dist/lib/plugins/openapi/Endpoint.js +2 -0
  28. package/dist/lib/plugins/openapi/Endpoint.js.map +1 -1
  29. package/dist/lib/plugins/openapi/ExampleDisplay.d.ts +12 -0
  30. package/dist/lib/plugins/openapi/ExampleDisplay.js +78 -0
  31. package/dist/lib/plugins/openapi/ExampleDisplay.js.map +1 -0
  32. package/dist/lib/plugins/openapi/OperationListItem.js +1 -1
  33. package/dist/lib/plugins/openapi/OperationListItem.js.map +1 -1
  34. package/dist/lib/plugins/openapi/ParameterListItem.js +1 -1
  35. package/dist/lib/plugins/openapi/ParameterListItem.js.map +1 -1
  36. package/dist/lib/plugins/openapi/RequestBodySidecarBox.d.ts +2 -4
  37. package/dist/lib/plugins/openapi/RequestBodySidecarBox.js +6 -13
  38. package/dist/lib/plugins/openapi/RequestBodySidecarBox.js.map +1 -1
  39. package/dist/lib/plugins/openapi/ResponsesSidecarBox.js +11 -13
  40. package/dist/lib/plugins/openapi/ResponsesSidecarBox.js.map +1 -1
  41. package/dist/lib/plugins/openapi/Sidecar.js +1 -1
  42. package/dist/lib/plugins/openapi/Sidecar.js.map +1 -1
  43. package/dist/lib/plugins/openapi/index.js +1 -0
  44. package/dist/lib/plugins/openapi/index.js.map +1 -1
  45. package/dist/vite/build.js +10 -8
  46. package/dist/vite/build.js.map +1 -1
  47. package/dist/vite/config.js +10 -0
  48. package/dist/vite/config.js.map +1 -1
  49. package/lib/{AuthenticationPlugin-DVLEc6cm.js → AuthenticationPlugin-D7G3me8L.js} +16 -16
  50. package/lib/AuthenticationPlugin-D7G3me8L.js.map +1 -0
  51. package/lib/{OperationList-c6V_vcgz.js → OperationList-BLdHAQ39.js} +1594 -1525
  52. package/lib/OperationList-BLdHAQ39.js.map +1 -0
  53. package/lib/assets/{worker-DV9Ecqy9.js → worker-Cbp2r2BQ.js} +26 -14
  54. package/lib/assets/{worker-DV9Ecqy9.js.map → worker-Cbp2r2BQ.js.map} +1 -1
  55. package/lib/{createServer-C4C0OO0m.js → createServer-Bf5_6o6G.js} +796 -784
  56. package/lib/{createServer-C4C0OO0m.js.map → createServer-Bf5_6o6G.js.map} +1 -1
  57. package/lib/{index-DkwDHnit.js → index-BNx95gkf.js} +5 -4
  58. package/lib/{index-DkwDHnit.js.map → index-BNx95gkf.js.map} +1 -1
  59. package/lib/zudoku.auth-clerk.js +80 -52
  60. package/lib/zudoku.auth-clerk.js.map +1 -1
  61. package/lib/zudoku.auth-openid.js +37 -37
  62. package/lib/zudoku.auth-openid.js.map +1 -1
  63. package/lib/zudoku.components.js +89 -85
  64. package/lib/zudoku.components.js.map +1 -1
  65. package/lib/zudoku.openapi-worker.js +1 -1
  66. package/lib/zudoku.plugin-openapi.js +1 -1
  67. package/package.json +4 -4
  68. package/src/lib/authentication/components/SignOut.tsx +2 -1
  69. package/src/lib/authentication/providers/clerk.tsx +38 -7
  70. package/src/lib/authentication/providers/openid.tsx +1 -1
  71. package/src/lib/components/navigation/SidebarBadge.tsx +13 -1
  72. package/src/lib/components/navigation/SidebarCategory.tsx +3 -7
  73. package/src/lib/components/navigation/SidebarWrapper.tsx +1 -0
  74. package/src/lib/oas/graphql/index.ts +16 -7
  75. package/src/lib/oas/parser/upgrade/index.ts +19 -4
  76. package/src/lib/plugins/openapi/CollapsibleCode.tsx +1 -1
  77. package/src/lib/plugins/openapi/Endpoint.tsx +2 -0
  78. package/src/lib/plugins/openapi/ExampleDisplay.tsx +163 -0
  79. package/src/lib/plugins/openapi/OperationListItem.tsx +5 -3
  80. package/src/lib/plugins/openapi/ParameterListItem.tsx +1 -1
  81. package/src/lib/plugins/openapi/RequestBodySidecarBox.tsx +11 -37
  82. package/src/lib/plugins/openapi/ResponsesSidecarBox.tsx +49 -63
  83. package/src/lib/plugins/openapi/Sidecar.tsx +2 -4
  84. package/src/lib/plugins/openapi/index.tsx +1 -0
  85. package/lib/AuthenticationPlugin-DVLEc6cm.js.map +0 -1
  86. package/lib/OperationList-c6V_vcgz.js.map +0 -1
@@ -22,7 +22,7 @@ import { Button as vt } from "./ui/Button.js";
22
22
  import { Callout as jt } from "./ui/Callout.js";
23
23
  import { S as He } from "./Spinner-DuxJLLNE.js";
24
24
  import { u as ge, a as wt, V as kt, M as Ct } from "./Markdown-CZDLNOFc.js";
25
- import { S as Le, l as Ke, Q as Nt, n as w, m as we, o as ke, p as M, q as Pt, r as St, t as Dt, v as Ot, w as Ce, x as Ne, y as Mt, h as Pe, z as Se, A as At, e as Et, B as $e, C as It, j as q, a as T, D as Ze, E as Qt, u as Tt, Z as qt } from "./ZudokuContext-hmLMUdf2.js";
25
+ import { S as Le, l as Ke, Q as Nt, n as w, m as we, o as ke, p as M, q as Pt, r as St, t as Dt, v as Ot, w as Ce, x as Ne, y as Mt, h as Pe, z as Se, A as At, e as It, B as $e, C as Et, j as q, a as T, D as Ze, E as Qt, u as Tt, Z as qt } from "./ZudokuContext-hmLMUdf2.js";
26
26
  import * as $ from "react";
27
27
  import Rt, { StrictMode as Ve, useState as Q, useEffect as R, useRef as me, useCallback as Ft, Suspense as pe, memo as Ue, forwardRef as Bt, createContext as We, Component as zt, createElement as De, useMemo as se, useContext as Ht, Fragment as Lt } from "react";
28
28
  import * as Kt from "react-dom";
@@ -270,20 +270,20 @@ function xs(e, { pages: t, pageParams: s }) {
270
270
  var n;
271
271
  return t.length > 0 ? (n = e.getPreviousPageParam) == null ? void 0 : n.call(e, t[0], t, s[0], s) : void 0;
272
272
  }
273
- var y, A, E, F, B, I, z, H, Re, ys = (Re = class {
273
+ var y, A, I, F, B, E, z, H, Re, ys = (Re = class {
274
274
  constructor(e = {}) {
275
275
  C(this, y);
276
276
  C(this, A);
277
- C(this, E);
277
+ C(this, I);
278
278
  C(this, F);
279
279
  C(this, B);
280
- C(this, I);
280
+ C(this, E);
281
281
  C(this, z);
282
282
  C(this, H);
283
- b(this, y, e.queryCache || new ms()), b(this, A, e.mutationCache || new ps()), b(this, E, e.defaultOptions || {}), b(this, F, /* @__PURE__ */ new Map()), b(this, B, /* @__PURE__ */ new Map()), b(this, I, 0);
283
+ b(this, y, e.queryCache || new ms()), b(this, A, e.mutationCache || new ps()), b(this, I, e.defaultOptions || {}), b(this, F, /* @__PURE__ */ new Map()), b(this, B, /* @__PURE__ */ new Map()), b(this, E, 0);
284
284
  }
285
285
  mount() {
286
- Y(this, I)._++, c(this, I) === 1 && (b(this, z, Ot.subscribe(async (e) => {
286
+ Y(this, E)._++, c(this, E) === 1 && (b(this, z, Ot.subscribe(async (e) => {
287
287
  e && (await this.resumePausedMutations(), c(this, y).onFocus());
288
288
  })), b(this, H, Ce.subscribe(async (e) => {
289
289
  e && (await this.resumePausedMutations(), c(this, y).onOnline());
@@ -291,7 +291,7 @@ var y, A, E, F, B, I, z, H, Re, ys = (Re = class {
291
291
  }
292
292
  unmount() {
293
293
  var e, t;
294
- Y(this, I)._--, c(this, I) === 0 && ((e = c(this, z)) == null || e.call(this), b(this, z, void 0), (t = c(this, H)) == null || t.call(this), b(this, H, void 0));
294
+ Y(this, E)._--, c(this, E) === 0 && ((e = c(this, z)) == null || e.call(this), b(this, z, void 0), (t = c(this, H)) == null || t.call(this), b(this, H, void 0));
295
295
  }
296
296
  isFetching(e) {
297
297
  return c(this, y).findAll({ ...e, fetchStatus: "fetching" }).length;
@@ -419,10 +419,10 @@ var y, A, E, F, B, I, z, H, Re, ys = (Re = class {
419
419
  return c(this, A);
420
420
  }
421
421
  getDefaultOptions() {
422
- return c(this, E);
422
+ return c(this, I);
423
423
  }
424
424
  setDefaultOptions(e) {
425
- b(this, E, e);
425
+ b(this, I, e);
426
426
  }
427
427
  setQueryDefaults(e, t) {
428
428
  c(this, F).set(Pe(e), {
@@ -453,7 +453,7 @@ var y, A, E, F, B, I, z, H, Re, ys = (Re = class {
453
453
  if (e._defaulted)
454
454
  return e;
455
455
  const t = {
456
- ...c(this, E).queries,
456
+ ...c(this, I).queries,
457
457
  ...this.getQueryDefaults(e.queryKey),
458
458
  ...e,
459
459
  _defaulted: !0
@@ -465,7 +465,7 @@ var y, A, E, F, B, I, z, H, Re, ys = (Re = class {
465
465
  }
466
466
  defaultMutationOptions(e) {
467
467
  return e != null && e._defaulted ? e : {
468
- ...c(this, E).mutations,
468
+ ...c(this, I).mutations,
469
469
  ...(e == null ? void 0 : e.mutationKey) && this.getMutationDefaults(e.mutationKey),
470
470
  ...e,
471
471
  _defaulted: !0
@@ -474,7 +474,7 @@ var y, A, E, F, B, I, z, H, Re, ys = (Re = class {
474
474
  clear() {
475
475
  c(this, y).clear(), c(this, A).clear();
476
476
  }
477
- }, y = new WeakMap(), A = new WeakMap(), E = new WeakMap(), F = new WeakMap(), B = new WeakMap(), I = new WeakMap(), z = new WeakMap(), H = new WeakMap(), Re);
477
+ }, y = new WeakMap(), A = new WeakMap(), I = new WeakMap(), F = new WeakMap(), B = new WeakMap(), E = new WeakMap(), z = new WeakMap(), H = new WeakMap(), Re);
478
478
  function bs(e) {
479
479
  return e;
480
480
  }
@@ -536,7 +536,7 @@ var vs = ({
536
536
  state: s,
537
537
  queryClient: n
538
538
  }) => {
539
- const a = Et(n), [i, o] = $.useState(), d = $.useRef(t);
539
+ const a = It(n), [i, o] = $.useState(), d = $.useRef(t);
540
540
  return d.current = t, $.useMemo(() => {
541
541
  if (s) {
542
542
  if (typeof s != "object")
@@ -592,9 +592,9 @@ const ks = new ys({
592
592
  queryClient: s,
593
593
  helmetContext: n
594
594
  }) => /* @__PURE__ */ r.jsx(Ve, { children: /* @__PURE__ */ r.jsx($e, { client: s, children: /* @__PURE__ */ r.jsx(Fe, { context: n, children: /* @__PURE__ */ r.jsx(gt, { router: e, context: t }) }) }) });
595
- var Z = { exports: {} }, Ps = Z.exports, Ee;
595
+ var Z = { exports: {} }, Ps = Z.exports, Ie;
596
596
  function Ss() {
597
- return Ee || (Ee = 1, function(e, t) {
597
+ return Ie || (Ie = 1, function(e, t) {
598
598
  (function(s, n) {
599
599
  n(t, Rt);
600
600
  })(Ps, function(s, n) {
@@ -640,26 +640,35 @@ const Os = {
640
640
  purple: "bg-purple-400 dark:bg-purple-600",
641
641
  indigo: "bg-indigo-400 dark:bg-indigo-600",
642
642
  gray: "bg-gray-400 dark:bg-gray-600"
643
+ }, Ms = {
644
+ green: "text-green-500 dark:text-green-600",
645
+ blue: "text-sky-400 dark:text-sky-600",
646
+ yellow: "text-yellow-400 dark:text-yellow-600",
647
+ red: "text-red-400 dark:text-red-600",
648
+ purple: "text-purple-400 dark:text-purple-600",
649
+ indigo: "text-indigo-400 dark:text-indigo-600",
650
+ gray: "text-gray-400 dark:text-gray-600"
643
651
  }, ae = ({
644
652
  color: e,
645
653
  label: t,
646
- className: s
654
+ className: s,
655
+ invert: n
647
656
  }) => /* @__PURE__ */ r.jsx(
648
657
  "span",
649
658
  {
650
659
  className: O(
651
660
  "mt-0.5 flex items-center duration-200 transition-opacity text-center uppercase font-mono text-[0.65rem] font-bold rounded text-background dark:text-zinc-50 h-4 px-1",
652
- Os[e],
661
+ n ? Ms[e] : Os[e],
653
662
  s
654
663
  ),
655
664
  children: t
656
665
  }
657
- ), Ms = ({
666
+ ), As = ({
658
667
  category: e,
659
668
  onRequestClose: t
660
669
  }) => {
661
670
  var h, p;
662
- const s = It(e), [n, a] = Q(!1), i = e.collapsible ?? !0, o = e.collapsed ?? !0, d = !!(!i || !o || s), [u, l] = Q(d), f = mt(((h = e.link) == null ? void 0 : h.id) ?? "");
671
+ const s = Et(e), [n, a] = Q(!1), i = e.collapsible ?? !0, o = e.collapsed ?? !0, d = !!(!i || !o || s), [u, l] = Q(d), f = mt(((h = e.link) == null ? void 0 : h.id) ?? "");
663
672
  R(() => {
664
673
  s && l(!0);
665
674
  }, [s]);
@@ -697,7 +706,7 @@ const Os = {
697
706
  className: V({
698
707
  isActive: !1,
699
708
  className: [
700
- "text-start",
709
+ "text-start font-medium",
701
710
  i ? "cursor-pointer" : "cursor-default hover:bg-transparent"
702
711
  ]
703
712
  }),
@@ -744,22 +753,16 @@ const Os = {
744
753
  className: O(
745
754
  // CollapsibleContent class is used to animate and it should only be applied when the user has triggered the toggle
746
755
  n && "CollapsibleContent",
747
- "ms-6 my-1"
756
+ "my-1"
748
757
  ),
749
- children: /* @__PURE__ */ r.jsx(
750
- "ul",
758
+ children: /* @__PURE__ */ r.jsx("ul", { className: "relative", children: e.items.map((x) => /* @__PURE__ */ r.jsx(
759
+ ce,
751
760
  {
752
- className: "relative after:absolute after:-left-[--padding-nav-item] after:translate-x-[1.5px] after:top-0 after:bottom-0 after:w-px after:bg-border",
753
- children: e.items.map((x) => /* @__PURE__ */ r.jsx(
754
- ce,
755
- {
756
- onRequestClose: t,
757
- item: x
758
- },
759
- ("id" in x ? x.id : "") + ("href" in x ? x.href : "") + x.label
760
- ))
761
- }
762
- )
761
+ onRequestClose: t,
762
+ item: x
763
+ },
764
+ ("id" in x ? x.id : "") + ("href" in x ? x.href : "") + x.label
765
+ )) })
763
766
  }
764
767
  )
765
768
  ]
@@ -790,7 +793,7 @@ const Os = {
790
793
  const { activeAnchor: s } = ge(), [n] = pt();
791
794
  switch (e.type) {
792
795
  case "category":
793
- return /* @__PURE__ */ r.jsx(Ms, { category: e, onRequestClose: t });
796
+ return /* @__PURE__ */ r.jsx(As, { category: e, onRequestClose: t });
794
797
  case "doc":
795
798
  return /* @__PURE__ */ r.jsxs(
796
799
  te,
@@ -850,7 +853,7 @@ const Os = {
850
853
  }
851
854
  );
852
855
  }
853
- }, As = (e, t = { block: "center" }) => {
856
+ }, Is = (e, t = { block: "center" }) => {
854
857
  if (!e) return;
855
858
  const s = e.getBoundingClientRect();
856
859
  s.top >= 0 && s.left >= 0 && s.bottom <= (window.innerHeight || document.documentElement.clientHeight) && s.right <= (window.innerWidth || document.documentElement.clientWidth) || e.scrollIntoView(t);
@@ -860,7 +863,7 @@ const Os = {
860
863
  if (!e.hash) return;
861
864
  const s = decodeURIComponent(e.hash.split("/")[0].slice(1)), n = () => {
862
865
  const a = document.getElementById(s), i = document.querySelector(`[${et}="${s}"]`);
863
- return a ? (a.scrollIntoView(), As(i), requestIdleCallback(() => t(s)), !0) : !1;
866
+ return a ? (a.scrollIntoView(), Is(i), requestIdleCallback(() => t(s)), !0) : !1;
864
867
  };
865
868
  if (!n()) {
866
869
  const a = new MutationObserver((i, o) => {
@@ -869,13 +872,13 @@ const Os = {
869
872
  return a.observe(document.body, { childList: !0, subtree: !0 }), () => a.disconnect();
870
873
  }
871
874
  }, [e.hash, t]);
872
- }, Is = () => {
875
+ }, Qs = () => {
873
876
  const e = ue(), t = me(e.pathname);
874
877
  R(() => {
875
878
  t.current !== e.pathname && (window.scrollTo(0, 0), t.current = e.pathname);
876
879
  }, [e.pathname]);
877
880
  };
878
- function Qs({
881
+ function Ts({
879
882
  className: e,
880
883
  ...t
881
884
  }) {
@@ -887,17 +890,17 @@ function Qs({
887
890
  }
888
891
  );
889
892
  }
890
- const Ts = (e) => "getProfileMenuItems" in e && typeof e.getProfileMenuItems == "function", qs = (e) => "getRoutes" in e && typeof e.getRoutes == "function", Rs = (e) => "renderSearch" in e && typeof e.renderSearch == "function", Fs = (e) => "initialize" in e && typeof e.initialize == "function", Bs = (e) => "getHead" in e && typeof e.getHead == "function", zs = (e) => "getMdxComponents" in e && typeof e.getMdxComponents == "function", Hs = (e) => "getIdentities" in e && typeof e.getIdentities == "function", Ie = {
893
+ const qs = (e) => "getProfileMenuItems" in e && typeof e.getProfileMenuItems == "function", Rs = (e) => "getRoutes" in e && typeof e.getRoutes == "function", Fs = (e) => "renderSearch" in e && typeof e.renderSearch == "function", Bs = (e) => "initialize" in e && typeof e.initialize == "function", zs = (e) => "getHead" in e && typeof e.getHead == "function", Hs = (e) => "getMdxComponents" in e && typeof e.getMdxComponents == "function", Ls = (e) => "getIdentities" in e && typeof e.getIdentities == "function", Ee = {
891
894
  info: "bg-blue-500",
892
895
  note: "bg-gray-500",
893
896
  tip: "bg-green-600",
894
897
  caution: "bg-orange-500",
895
898
  danger: "bg-rose-500"
896
- }, Ls = () => {
899
+ }, Ks = () => {
897
900
  const { page: e } = T(), [t, s] = Q(!0);
898
901
  if (!(e != null && e.banner) || !t)
899
902
  return /* @__PURE__ */ r.jsx("style", { children: ":root { --banner-height: 0px; }" });
900
- const n = e.banner.color && e.banner.color in Ie ? Ie[e.banner.color] : e.banner.color ? void 0 : "bg-primary", a = n ? {} : { backgroundColor: e.banner.color };
903
+ const n = e.banner.color && e.banner.color in Ee ? Ee[e.banner.color] : e.banner.color ? void 0 : "bg-primary", a = n ? {} : { backgroundColor: e.banner.color };
901
904
  return /* @__PURE__ */ r.jsxs(
902
905
  "div",
903
906
  {
@@ -932,7 +935,7 @@ const Ts = (e) => "getProfileMenuItems" in e && typeof e.getProfileMenuItems ==
932
935
  window.removeEventListener("keydown", o);
933
936
  };
934
937
  }, [s, n]);
935
- const i = t.plugins.find(Rs);
938
+ const i = t.plugins.find(Fs);
936
939
  return i ? /* @__PURE__ */ r.jsxs("div", { className: e, children: [
937
940
  /* @__PURE__ */ r.jsxs(
938
941
  "button",
@@ -966,7 +969,7 @@ const Ts = (e) => "getProfileMenuItems" in e && typeof e.getProfileMenuItems ==
966
969
  children: /* @__PURE__ */ r.jsx(s, { size: 18 })
967
970
  }
968
971
  ) });
969
- }, rt = (e) => (t) => t.display === "auth" && e || t.display === "anon" && !e || !t.display || t.display === "always", Ks = () => {
972
+ }, rt = (e) => (t) => t.display === "auth" && e || t.display === "anon" && !e || !t.display || t.display === "always", $s = () => {
970
973
  const { topNavigation: e } = T(), { isAuthenticated: t } = U();
971
974
  return e.length <= 1 ? /* @__PURE__ */ r.jsx("style", { children: ":root { --top-nav-height: 0px; }" }) : /* @__PURE__ */ r.jsx(pe, { children: /* @__PURE__ */ r.jsx("nav", { className: "hidden lg:block text-sm px-12 h-[--top-nav-height]", children: /* @__PURE__ */ r.jsx("ul", { className: "flex flex-row items-center gap-8", children: e.filter(rt(t)).map((s) => /* @__PURE__ */ r.jsx("li", { children: /* @__PURE__ */ r.jsx(nt, { ...s }) }, s.id)) }) }) });
972
975
  }, nt = ({
@@ -997,7 +1000,7 @@ const Ts = (e) => "getProfileMenuItems" in e && typeof e.getProfileMenuItems ==
997
1000
  }
998
1001
  )
999
1002
  );
1000
- }, $s = () => {
1003
+ }, Zs = () => {
1001
1004
  const { topNavigation: e } = T(), { isAuthenticated: t } = U(), [s, n] = Q(!1);
1002
1005
  return /* @__PURE__ */ r.jsxs(
1003
1006
  _e,
@@ -1035,9 +1038,9 @@ const Ts = (e) => "getProfileMenuItems" in e && typeof e.getProfileMenuItems ==
1035
1038
  e.icon && /* @__PURE__ */ r.jsx(e.icon, { size: 16, strokeWidth: 1, absoluteStrokeWidth: !0 }),
1036
1039
  e.label
1037
1040
  ] }, e.label) }), at = Ue(function() {
1038
- const t = U(), { isAuthenticated: s, profile: n, isAuthEnabled: a } = U(), i = T(), { page: o, plugins: d } = i, u = d.filter((l) => Ts(l)).flatMap((l) => l.getProfileMenuItems(i)).sort((l) => l.weight ?? 0);
1041
+ const t = U(), { isAuthenticated: s, profile: n, isAuthEnabled: a } = U(), i = T(), { page: o, plugins: d } = i, u = d.filter((l) => qs(l)).flatMap((l) => l.getProfileMenuItems(i)).sort((l) => l.weight ?? 0);
1039
1042
  return /* @__PURE__ */ r.jsxs("header", { className: "sticky lg:top-0 z-10 bg-background/80 backdrop-blur w-full", children: [
1040
- /* @__PURE__ */ r.jsx(Ls, {}),
1043
+ /* @__PURE__ */ r.jsx(Ks, {}),
1041
1044
  /* @__PURE__ */ r.jsx("div", { className: "border-b", children: /* @__PURE__ */ r.jsxs("div", { className: "max-w-screen-2xl border-l border-r mx-auto grid grid-cols-[1fr_auto] lg:grid-cols-[calc(var(--side-nav-width))_1fr] lg:gap-12 items-center px-4 lg:px-12 h-[--top-header-height]", children: [
1042
1045
  /* @__PURE__ */ r.jsx("div", { className: "flex", children: /* @__PURE__ */ r.jsx(fe, { to: "/", children: /* @__PURE__ */ r.jsxs("div", { className: "flex items-center gap-3.5", children: [
1043
1046
  (o == null ? void 0 : o.logo) && /* @__PURE__ */ r.jsxs(r.Fragment, { children: [
@@ -1072,13 +1075,13 @@ const Ts = (e) => "getProfileMenuItems" in e && typeof e.getProfileMenuItems ==
1072
1075
  ] }) }) }),
1073
1076
  /* @__PURE__ */ r.jsxs("div", { className: "grid grid-cols-1 lg:grid-cols-[--sidecar-grid-cols] items-center gap-8", children: [
1074
1077
  /* @__PURE__ */ r.jsx("div", { className: "w-full justify-center hidden lg:flex", children: /* @__PURE__ */ r.jsx(tt, {}) }),
1075
- /* @__PURE__ */ r.jsx($s, {}),
1078
+ /* @__PURE__ */ r.jsx(Zs, {}),
1076
1079
  /* @__PURE__ */ r.jsxs("div", { className: "hidden lg:flex items-center justify-self-end text-sm gap-2", children: [
1077
1080
  /* @__PURE__ */ r.jsx(D, { name: "head-navigation-start" }),
1078
1081
  a && /* @__PURE__ */ r.jsx(
1079
1082
  xe,
1080
1083
  {
1081
- fallback: /* @__PURE__ */ r.jsx(Qs, { className: "rounded h-5 w-24 mr-4" }),
1084
+ fallback: /* @__PURE__ */ r.jsx(Ts, { className: "rounded h-5 w-24 mr-4" }),
1082
1085
  children: s ? Object.values(u).length > 0 && /* @__PURE__ */ r.jsxs(rs, { modal: !1, children: [
1083
1086
  /* @__PURE__ */ r.jsx(ns, { asChild: !0, children: /* @__PURE__ */ r.jsx(le, { variant: "ghost", children: n != null && n.name ? `${n.name}` : "My Account" }) }),
1084
1087
  /* @__PURE__ */ r.jsxs(as, { className: "w-56", children: [
@@ -1107,7 +1110,7 @@ const Ts = (e) => "getProfileMenuItems" in e && typeof e.getProfileMenuItems ==
1107
1110
  ] }) }),
1108
1111
  /* @__PURE__ */ r.jsx("div", { className: "border-b", children: /* @__PURE__ */ r.jsxs("div", { className: "max-w-screen-2xl mx-auto border-l border-r", children: [
1109
1112
  /* @__PURE__ */ r.jsx(D, { name: "top-navigation-before" }),
1110
- /* @__PURE__ */ r.jsx(Ks, {}),
1113
+ /* @__PURE__ */ r.jsx($s, {}),
1111
1114
  /* @__PURE__ */ r.jsx(D, { name: "top-navigation-after" })
1112
1115
  ] }) })
1113
1116
  ] });
@@ -1119,6 +1122,7 @@ const Ts = (e) => "getProfileMenuItems" in e && typeof e.getProfileMenuItems ==
1119
1122
  "scrollbar peer hidden lg:flex flex-col fixed text-sm overflow-y-auto shrink-0 border-r pr-10",
1120
1123
  "-mx-[--padding-nav-item] pb-20 pt-[--padding-content-top]",
1121
1124
  "w-[--side-nav-width] h-[calc(100%-var(--header-height))] scroll-pt-2 gap-2",
1125
+ !s && "border-r-0",
1122
1126
  t
1123
1127
  ),
1124
1128
  ref: n,
@@ -1126,7 +1130,7 @@ const Ts = (e) => "getProfileMenuItems" in e && typeof e.getProfileMenuItems ==
1126
1130
  }
1127
1131
  ));
1128
1132
  it.displayName = "SidebarWrapper";
1129
- const Zs = ({
1133
+ const Vs = ({
1130
1134
  onRequestClose: e
1131
1135
  }) => {
1132
1136
  const t = me(null), s = Ze();
@@ -1162,9 +1166,9 @@ const Zs = ({
1162
1166
  }
1163
1167
  )
1164
1168
  ] });
1165
- }, Qe = () => /* @__PURE__ */ r.jsx("main", { className: "grid h-[calc(100vh-var(--header-height))] place-items-center", children: /* @__PURE__ */ r.jsx(He, {}) }), Vs = ({ children: e }) => {
1169
+ }, Qe = () => /* @__PURE__ */ r.jsx("main", { className: "grid h-[calc(100vh-var(--header-height))] place-items-center", children: /* @__PURE__ */ r.jsx(He, {}) }), Us = ({ children: e }) => {
1166
1170
  const t = ue(), { setActiveAnchor: s } = ge(), { meta: n, authentication: a } = T();
1167
- Es(), Is();
1171
+ Es(), Qs();
1168
1172
  const i = me(t.pathname);
1169
1173
  R(() => {
1170
1174
  var f;
@@ -1192,7 +1196,7 @@ const Zs = ({
1192
1196
  open: u,
1193
1197
  onOpenChange: (f) => l(f),
1194
1198
  children: [
1195
- /* @__PURE__ */ r.jsx(Zs, { onRequestClose: () => l(!1) }),
1199
+ /* @__PURE__ */ r.jsx(Vs, { onRequestClose: () => l(!1) }),
1196
1200
  /* @__PURE__ */ r.jsx(
1197
1201
  "div",
1198
1202
  {
@@ -1227,11 +1231,11 @@ const Zs = ({
1227
1231
  }
1228
1232
  ) }) })
1229
1233
  ] });
1230
- }, Us = We(null), ie = {
1234
+ }, Ws = We(null), ie = {
1231
1235
  didCatch: !1,
1232
1236
  error: null
1233
1237
  };
1234
- class Ws extends zt {
1238
+ class _s extends zt {
1235
1239
  constructor(t) {
1236
1240
  super(t), this.resetErrorBoundary = this.resetErrorBoundary.bind(this), this.state = ie;
1237
1241
  }
@@ -1264,7 +1268,7 @@ class Ws extends zt {
1264
1268
  } = this.state, {
1265
1269
  resetKeys: a
1266
1270
  } = this.props;
1267
- if (n && s.error !== null && _s(t.resetKeys, a)) {
1271
+ if (n && s.error !== null && Xs(t.resetKeys, a)) {
1268
1272
  var i, o;
1269
1273
  (i = (o = this.props).onReset) === null || i === void 0 || i.call(o, {
1270
1274
  next: a,
@@ -1298,7 +1302,7 @@ class Ws extends zt {
1298
1302
  else
1299
1303
  throw o;
1300
1304
  }
1301
- return De(Us.Provider, {
1305
+ return De(Ws.Provider, {
1302
1306
  value: {
1303
1307
  didCatch: i,
1304
1308
  error: o,
@@ -1307,11 +1311,11 @@ class Ws extends zt {
1307
1311
  }, d);
1308
1312
  }
1309
1313
  }
1310
- function _s() {
1314
+ function Xs() {
1311
1315
  let e = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : [], t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : [];
1312
1316
  return e.length !== t.length || e.some((s, n) => !Object.is(s, t[n]));
1313
1317
  }
1314
- class Xs {
1318
+ class Ys {
1315
1319
  constructor(t) {
1316
1320
  k(this, "plugins");
1317
1321
  k(this, "sidebars");
@@ -1322,14 +1326,14 @@ class Xs {
1322
1326
  k(this, "navigationPlugins");
1323
1327
  k(this, "initialize", async () => {
1324
1328
  await Promise.all(
1325
- this.plugins.filter(Fs).map((t) => {
1329
+ this.plugins.filter(Bs).map((t) => {
1326
1330
  var s;
1327
1331
  return (s = t.initialize) == null ? void 0 : s.call(t, this);
1328
1332
  })
1329
1333
  );
1330
1334
  });
1331
1335
  k(this, "getApiIdentities", async () => (await Promise.all(
1332
- this.plugins.filter(Hs).map((s) => s.getIdentities(this))
1336
+ this.plugins.filter(Ls).map((s) => s.getIdentities(this))
1333
1337
  )).flat());
1334
1338
  k(this, "getPluginSidebar", async (t) => (await Promise.all(
1335
1339
  this.navigationPlugins.map(
@@ -1345,17 +1349,17 @@ class Xs {
1345
1349
  const s = await this.authentication.getAccessToken();
1346
1350
  return t.headers.set("Authorization", `Bearer ${s}`), t;
1347
1351
  });
1348
- this.plugins = t.plugins ?? [], this.topNavigation = t.topNavigation ?? [], this.sidebars = t.sidebars ?? {}, this.navigationPlugins = this.plugins.filter(qs), this.authentication = t.authentication, this.meta = t.metadata, this.page = t.page;
1352
+ this.plugins = t.plugins ?? [], this.topNavigation = t.topNavigation ?? [], this.sidebars = t.sidebars ?? {}, this.navigationPlugins = this.plugins.filter(Rs), this.authentication = t.authentication, this.meta = t.metadata, this.page = t.page;
1349
1353
  }
1350
1354
  }
1351
- function Ys({ error: e, resetErrorBoundary: t }) {
1355
+ function Js({ error: e, resetErrorBoundary: t }) {
1352
1356
  return /* @__PURE__ */ r.jsx(ze, { error: e });
1353
1357
  }
1354
1358
  const G = globalThis;
1355
1359
  (!G.requestIdleCallback || !G.cancelIdleCallback) && (G.requestIdleCallback = (e) => setTimeout(e, 1), G.cancelIdleCallback = clearTimeout);
1356
1360
  const ot = {
1357
1361
  Header: at
1358
- }, Js = We(ot), Gs = Js.Provider, er = ({
1362
+ }, Gs = We(ot), er = Gs.Provider, tr = ({
1359
1363
  children: e,
1360
1364
  context: t
1361
1365
  }) => (Tt({
@@ -1370,7 +1374,7 @@ const ot = {
1370
1374
  ), n = se(() => {
1371
1375
  var x;
1372
1376
  return {
1373
- ...(t.plugins ?? []).filter(zs).flatMap(
1377
+ ...(t.plugins ?? []).filter(Hs).flatMap(
1374
1378
  (m) => m.getMdxComponents ? [m.getMdxComponents()] : []
1375
1379
  ).reduce(
1376
1380
  (m, N) => ({ ...m, ...N }),
@@ -1386,36 +1390,36 @@ const ot = {
1386
1390
  R(() => {
1387
1391
  i || o(!0);
1388
1392
  }, [i, u.location]);
1389
- const [l] = Q(() => new Xs(t)), f = (h = t.plugins) == null ? void 0 : h.filter(Bs).map((p, x) => {
1393
+ const [l] = Q(() => new Ys(t)), f = (h = t.plugins) == null ? void 0 : h.filter(zs).map((p, x) => {
1390
1394
  var m;
1391
1395
  return /* @__PURE__ */ r.jsx(Lt, { children: (m = p.getHead) == null ? void 0 : m.call(p) }, x);
1392
1396
  });
1393
1397
  return /* @__PURE__ */ r.jsxs(r.Fragment, { children: [
1394
1398
  /* @__PURE__ */ r.jsx(de, { children: f }),
1395
- /* @__PURE__ */ r.jsx(oe.Provider, { value: d, children: /* @__PURE__ */ r.jsx(er, { context: l, children: /* @__PURE__ */ r.jsx(ts, { components: n, children: /* @__PURE__ */ r.jsx(fs, { attribute: "class", disableTransitionOnChange: !0, children: /* @__PURE__ */ r.jsx(Gs, { value: s, children: /* @__PURE__ */ r.jsx(yt, { slotlets: t.slotlets, children: /* @__PURE__ */ r.jsx(kt, { children: e ?? /* @__PURE__ */ r.jsx(Be, {}) }) }) }) }) }) }) })
1399
+ /* @__PURE__ */ r.jsx(oe.Provider, { value: d, children: /* @__PURE__ */ r.jsx(tr, { context: l, children: /* @__PURE__ */ r.jsx(ts, { components: n, children: /* @__PURE__ */ r.jsx(fs, { attribute: "class", disableTransitionOnChange: !0, children: /* @__PURE__ */ r.jsx(er, { value: s, children: /* @__PURE__ */ r.jsx(yt, { slotlets: t.slotlets, children: /* @__PURE__ */ r.jsx(kt, { children: e ?? /* @__PURE__ */ r.jsx(Be, {}) }) }) }) }) }) }) })
1396
1400
  ] });
1397
1401
  }
1398
1402
  );
1399
1403
  lt.displayName = "ZudokoInner";
1400
- const ct = (e) => /* @__PURE__ */ r.jsx(Ws, { FallbackComponent: Ys, children: /* @__PURE__ */ r.jsx(lt, { ...e }) });
1404
+ const ct = (e) => /* @__PURE__ */ r.jsx(_s, { FallbackComponent: Js, children: /* @__PURE__ */ r.jsx(lt, { ...e }) });
1401
1405
  ct.displayName = "Zudoku";
1402
- const Nr = ss, Pr = Vs, Sr = bt, Dr = js, Or = Cs, Mr = Ns, Ar = de, Er = T, Ir = U, Qr = ct, Tr = jt, qr = Ct, Rr = He, Fr = xe, Br = vt, zr = fe;
1406
+ const Pr = ss, Sr = Us, Dr = bt, Or = js, Mr = Cs, Ar = Ns, Ir = de, Er = T, Qr = U, Tr = ct, qr = jt, Rr = Ct, Fr = He, Br = xe, zr = vt, Hr = fe;
1403
1407
  export {
1404
- Or as Bootstrap,
1405
- Mr as BootstrapStatic,
1406
- Br as Button,
1407
- Tr as Callout,
1408
- Fr as ClientOnly,
1409
- Ar as Head,
1410
- Pr as Layout,
1411
- zr as Link,
1412
- qr as Markdown,
1413
- Sr as RouterError,
1414
- Dr as ServerError,
1415
- Rr as Spinner,
1416
- Qr as Zudoku,
1417
- Ir as useAuth,
1418
- Nr as useMDXComponents,
1408
+ Mr as Bootstrap,
1409
+ Ar as BootstrapStatic,
1410
+ zr as Button,
1411
+ qr as Callout,
1412
+ Br as ClientOnly,
1413
+ Ir as Head,
1414
+ Sr as Layout,
1415
+ Hr as Link,
1416
+ Rr as Markdown,
1417
+ Dr as RouterError,
1418
+ Or as ServerError,
1419
+ Fr as Spinner,
1420
+ Tr as Zudoku,
1421
+ Qr as useAuth,
1422
+ Pr as useMDXComponents,
1419
1423
  Er as useZudoku
1420
1424
  };
1421
1425
  //# sourceMappingURL=zudoku.components.js.map