zudoku 0.13.0 → 0.13.1

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 (168) hide show
  1. package/dist/cli/dev/handler.js +2 -2
  2. package/dist/cli/dev/handler.js.map +1 -1
  3. package/dist/config/validators/validate.d.ts +27 -13
  4. package/dist/config/validators/validate.js +3 -1
  5. package/dist/config/validators/validate.js.map +1 -1
  6. package/dist/index.d.ts +1 -1
  7. package/dist/lib/components/Header.js +1 -1
  8. package/dist/lib/components/Header.js.map +1 -1
  9. package/dist/lib/components/MobileTopNavigation.js +2 -1
  10. package/dist/lib/components/MobileTopNavigation.js.map +1 -1
  11. package/dist/lib/components/Search.js +1 -1
  12. package/dist/lib/components/Search.js.map +1 -1
  13. package/dist/lib/components/SlotletProvider.d.ts +6 -2
  14. package/dist/lib/components/SlotletProvider.js +3 -5
  15. package/dist/lib/components/SlotletProvider.js.map +1 -1
  16. package/dist/lib/components/index.d.ts +2 -1
  17. package/dist/lib/components/index.js.map +1 -1
  18. package/dist/lib/plugins/custom-pages/CustomPage.d.ts +2 -0
  19. package/dist/lib/plugins/custom-pages/CustomPage.js +10 -0
  20. package/dist/lib/plugins/custom-pages/CustomPage.js.map +1 -0
  21. package/dist/lib/plugins/custom-pages/index.d.ts +8 -6
  22. package/dist/lib/plugins/custom-pages/index.js +3 -4
  23. package/dist/lib/plugins/custom-pages/index.js.map +1 -1
  24. package/dist/lib/plugins/openapi/Endpoint.js +1 -1
  25. package/dist/lib/plugins/openapi/Endpoint.js.map +1 -1
  26. package/dist/lib/plugins/openapi/OperationList.js +1 -1
  27. package/dist/lib/plugins/openapi/OperationList.js.map +1 -1
  28. package/dist/lib/plugins/openapi/Route.d.ts +1 -1
  29. package/dist/lib/plugins/openapi/Route.js +1 -1
  30. package/dist/lib/plugins/openapi/Route.js.map +1 -1
  31. package/dist/lib/plugins/openapi/Sidecar.js +1 -1
  32. package/dist/lib/plugins/openapi/Sidecar.js.map +1 -1
  33. package/dist/lib/plugins/openapi/client/createMemoryClient.js +1 -1
  34. package/dist/lib/plugins/openapi/client/createMemoryClient.js.map +1 -1
  35. package/dist/lib/plugins/openapi/client/createWorkerClient.js +1 -1
  36. package/dist/lib/plugins/openapi/client/createWorkerClient.js.map +1 -1
  37. package/dist/lib/plugins/openapi/index.js +1 -1
  38. package/dist/lib/plugins/openapi/index.js.map +1 -1
  39. package/dist/lib/ui/Callout.d.ts +36 -35
  40. package/dist/lib/ui/Callout.js.map +1 -1
  41. package/dist/lib/ui/Drawer.d.ts +8 -10
  42. package/dist/lib/ui/Drawer.js.map +1 -1
  43. package/dist/lib/util/useExposedProps.d.ts +2 -0
  44. package/dist/lib/util/useExposedProps.js +8 -0
  45. package/dist/lib/util/useExposedProps.js.map +1 -0
  46. package/dist/vite/dev-server.d.ts +6 -1
  47. package/dist/vite/dev-server.js +4 -2
  48. package/dist/vite/dev-server.js.map +1 -1
  49. package/lib/{AuthenticationPlugin-Bx9FK124.js → AuthenticationPlugin-CbgJ5SAh.js} +3 -3
  50. package/lib/{AuthenticationPlugin-Bx9FK124.js.map → AuthenticationPlugin-CbgJ5SAh.js.map} +1 -1
  51. package/lib/{DeveloperHint-YeWHKvyr.js → DeveloperHint-CiXPc9Xm.js} +2 -2
  52. package/lib/{DeveloperHint-YeWHKvyr.js.map → DeveloperHint-CiXPc9Xm.js.map} +1 -1
  53. package/lib/ErrorPage-B-zoPPVx.js +15 -0
  54. package/lib/{ErrorPage-CsZAN_za.js.map → ErrorPage-B-zoPPVx.js.map} +1 -1
  55. package/lib/Input-QMLhK7Rb.js +2229 -0
  56. package/lib/Input-QMLhK7Rb.js.map +1 -0
  57. package/lib/{Markdown-DapSf3wG.js → Markdown-D6Nze6qq.js} +3281 -5392
  58. package/lib/Markdown-D6Nze6qq.js.map +1 -0
  59. package/lib/{MdxPage-BqBWsXZ1.js → MdxPage-DBhq6-5F.js} +15 -15
  60. package/lib/{MdxPage-BqBWsXZ1.js.map → MdxPage-DBhq6-5F.js.map} +1 -1
  61. package/lib/{OperationList-CYrmxPa8.js → OperationList-Ba24gUd2.js} +50 -51
  62. package/lib/OperationList-Ba24gUd2.js.map +1 -0
  63. package/lib/{Route-Q5mqNQrv.js → Route-DI38nxYt.js} +3 -4
  64. package/lib/Route-DI38nxYt.js.map +1 -0
  65. package/lib/SidebarBadge-B9-VJSQr.js +503 -0
  66. package/lib/SidebarBadge-B9-VJSQr.js.map +1 -0
  67. package/lib/{SlotletProvider-BWwfPzgI.js → SlotletProvider-Cb8mGpBO.js} +42 -44
  68. package/lib/{SlotletProvider-BWwfPzgI.js.map → SlotletProvider-Cb8mGpBO.js.map} +1 -1
  69. package/lib/ZudokuContext-BEmsYQoq.js +1173 -0
  70. package/lib/ZudokuContext-BEmsYQoq.js.map +1 -0
  71. package/lib/assets/{index-B9EWVYfo.js → index-B_Jk_Yzp.js} +968 -938
  72. package/lib/assets/index-B_Jk_Yzp.js.map +1 -0
  73. package/lib/assets/{worker-BP8Uzflt.js → worker-Bf8vjASY.js} +4581 -4300
  74. package/lib/assets/worker-Bf8vjASY.js.map +1 -0
  75. package/lib/cn-BmFQLtkS.js +2279 -0
  76. package/lib/cn-BmFQLtkS.js.map +1 -0
  77. package/lib/{index-BG0g4WW0.js → index-BRCiYFaL.js} +747 -737
  78. package/lib/index-BRCiYFaL.js.map +1 -0
  79. package/lib/{index-CLd8ycZz.js → index-CkwDvuPt.js} +947 -917
  80. package/lib/index-CkwDvuPt.js.map +1 -0
  81. package/lib/{index-LNp6rxyU.js → index-D06ATMgg.js} +2 -2
  82. package/lib/{index-LNp6rxyU.js.map → index-D06ATMgg.js.map} +1 -1
  83. package/lib/{index-BlJ2rj99.js → index-DA74gNq3.js} +1124 -974
  84. package/lib/index-DA74gNq3.js.map +1 -0
  85. package/lib/index-DJqnphbT.js +35 -0
  86. package/lib/{index-Bn6Lc9tq.js.map → index-DJqnphbT.js.map} +1 -1
  87. package/lib/{index-BngPzhKn.js → index-dgcPryXi.js} +3 -3
  88. package/lib/{index-BngPzhKn.js.map → index-dgcPryXi.js.map} +1 -1
  89. package/lib/{index-Dolisrci.js → index-g_JJcuFg.js} +603 -549
  90. package/lib/index-g_JJcuFg.js.map +1 -0
  91. package/lib/router-Oe6YmY6B.js +3024 -0
  92. package/lib/router-Oe6YmY6B.js.map +1 -0
  93. package/lib/state-CsuHT8ZO.js +183 -0
  94. package/lib/state-CsuHT8ZO.js.map +1 -0
  95. package/lib/urql-core-KJnLL26g.js +1455 -0
  96. package/lib/urql-core-KJnLL26g.js.map +1 -0
  97. package/lib/useExposedProps-Csw8oAlt.js +9 -0
  98. package/lib/useExposedProps-Csw8oAlt.js.map +1 -0
  99. package/lib/{utils-ByIc_KIM.js → utils-Chi3p5nE.js} +4 -4
  100. package/lib/utils-Chi3p5nE.js.map +1 -0
  101. package/lib/zudoku.auth-auth0.js +1 -1
  102. package/lib/zudoku.auth-clerk.js +2 -2
  103. package/lib/zudoku.auth-openid.js +363 -350
  104. package/lib/zudoku.auth-openid.js.map +1 -1
  105. package/lib/zudoku.components.js +1695 -1628
  106. package/lib/zudoku.components.js.map +1 -1
  107. package/lib/zudoku.openapi-worker.js +4599 -4317
  108. package/lib/zudoku.openapi-worker.js.map +1 -1
  109. package/lib/zudoku.plugin-api-keys.js +7 -7
  110. package/lib/zudoku.plugin-custom-pages.js +16 -8
  111. package/lib/zudoku.plugin-custom-pages.js.map +1 -1
  112. package/lib/zudoku.plugin-markdown.js +1 -1
  113. package/lib/zudoku.plugin-openapi.js +8 -8
  114. package/lib/zudoku.plugin-redirect.js +1 -1
  115. package/package.json +58 -65
  116. package/src/lib/components/Header.tsx +2 -2
  117. package/src/lib/components/MobileTopNavigation.tsx +4 -0
  118. package/src/lib/components/Search.tsx +1 -1
  119. package/src/lib/components/SlotletProvider.tsx +14 -7
  120. package/src/lib/components/index.ts +1 -1
  121. package/src/lib/plugins/custom-pages/CustomPage.tsx +15 -0
  122. package/src/lib/plugins/custom-pages/index.tsx +11 -9
  123. package/src/lib/plugins/openapi/Endpoint.tsx +1 -1
  124. package/src/lib/plugins/openapi/OperationList.tsx +1 -1
  125. package/src/lib/plugins/openapi/Route.tsx +1 -2
  126. package/src/lib/plugins/openapi/Sidecar.tsx +1 -1
  127. package/src/lib/plugins/openapi/client/createMemoryClient.ts +1 -6
  128. package/src/lib/plugins/openapi/client/createWorkerClient.ts +1 -6
  129. package/src/lib/plugins/openapi/index.tsx +1 -5
  130. package/src/lib/ui/Callout.tsx +7 -6
  131. package/src/lib/ui/Drawer.tsx +38 -36
  132. package/src/lib/util/useExposedProps.tsx +10 -0
  133. package/dist/lib/plugins/openapi/playground/Editor.d.ts +0 -1
  134. package/dist/lib/plugins/openapi/playground/Editor.js +0 -5
  135. package/dist/lib/plugins/openapi/playground/Editor.js.map +0 -1
  136. package/dist/lib/plugins/openapi/util/urql.d.ts +0 -7
  137. package/dist/lib/plugins/openapi/util/urql.js +0 -8
  138. package/dist/lib/plugins/openapi/util/urql.js.map +0 -1
  139. package/lib/CategoryHeading-ovR-zHRq.js +0 -10
  140. package/lib/CategoryHeading-ovR-zHRq.js.map +0 -1
  141. package/lib/ErrorPage-CsZAN_za.js +0 -16
  142. package/lib/Input-CtVUl3eT.js +0 -2198
  143. package/lib/Input-CtVUl3eT.js.map +0 -1
  144. package/lib/Markdown-DapSf3wG.js.map +0 -1
  145. package/lib/OperationList-CYrmxPa8.js.map +0 -1
  146. package/lib/Route-Q5mqNQrv.js.map +0 -1
  147. package/lib/SidebarBadge-Dx7jtnoA.js +0 -498
  148. package/lib/SidebarBadge-Dx7jtnoA.js.map +0 -1
  149. package/lib/ZudokuContext-cr-pTRY1.js +0 -1084
  150. package/lib/ZudokuContext-cr-pTRY1.js.map +0 -1
  151. package/lib/_commonjsHelpers-BkfeUUK-.js +0 -29
  152. package/lib/_commonjsHelpers-BkfeUUK-.js.map +0 -1
  153. package/lib/assets/index-B9EWVYfo.js.map +0 -1
  154. package/lib/assets/worker-BP8Uzflt.js.map +0 -1
  155. package/lib/index-BG0g4WW0.js.map +0 -1
  156. package/lib/index-BlJ2rj99.js.map +0 -1
  157. package/lib/index-Bn6Lc9tq.js +0 -9
  158. package/lib/index-CLd8ycZz.js.map +0 -1
  159. package/lib/index-Dolisrci.js.map +0 -1
  160. package/lib/router-D2p7Olpn.js +0 -2971
  161. package/lib/router-D2p7Olpn.js.map +0 -1
  162. package/lib/state-hNe1dw4B.js +0 -548
  163. package/lib/state-hNe1dw4B.js.map +0 -1
  164. package/lib/urql-YhcsXYy8.js +0 -1591
  165. package/lib/urql-YhcsXYy8.js.map +0 -1
  166. package/lib/utils-ByIc_KIM.js.map +0 -1
  167. package/src/lib/plugins/openapi/playground/Editor.tsx +0 -4
  168. package/src/lib/plugins/openapi/util/urql.ts +0 -8
@@ -1,13 +1,13 @@
1
1
  import { j as e } from "./jsx-runtime-B6kdoens.js";
2
- import { S as x, R as f } from "./SlotletProvider-BWwfPzgI.js";
3
- import { u as g, a as d, I as j, S as v, b as w, c as b, d as k, e as K, f as m } from "./Input-CtVUl3eT.js";
4
- import { a as N, L as u, O as I } from "./index-BG0g4WW0.js";
5
- import { u as h, a as E, b as S } from "./ZudokuContext-cr-pTRY1.js";
6
- import { B as l, m as A } from "./index-Dolisrci.js";
7
- import { D as C } from "./DeveloperHint-YeWHKvyr.js";
2
+ import { S as x, R as f } from "./SlotletProvider-Cb8mGpBO.js";
3
+ import { u as g, a as d, I as j, S as v, b as w, c as b, d as k, e as K, f as m } from "./Input-QMLhK7Rb.js";
4
+ import { a as N, L as u, O as I } from "./index-BRCiYFaL.js";
5
+ import { u as h, a as E, b as S } from "./ZudokuContext-BEmsYQoq.js";
6
+ import { B as l, n as A } from "./index-g_JJcuFg.js";
7
+ import { D as C } from "./DeveloperHint-CiXPc9Xm.js";
8
8
  import { RotateCwIcon as P, TrashIcon as D, EyeOffIcon as R, EyeIcon as q, CheckIcon as O, CopyIcon as z } from "lucide-react";
9
9
  import { useState as p } from "react";
10
- import { a as T } from "./Markdown-DapSf3wG.js";
10
+ import { c as T } from "./cn-BmFQLtkS.js";
11
11
  function c(t, s) {
12
12
  if (t)
13
13
  return;
@@ -1,13 +1,21 @@
1
- import { j as m } from "./jsx-runtime-B6kdoens.js";
2
- import { P as o } from "./Markdown-DapSf3wG.js";
3
- const l = (s) => ({
4
- getRoutes: () => s.map(({ path: e, element: t }) => ({
5
- path: e,
6
- // TODO: we should componentize prose pages
7
- element: /* @__PURE__ */ m.jsx("div", { className: o + " max-w-full", children: t })
1
+ import { j as s } from "./jsx-runtime-B6kdoens.js";
2
+ import n from "react";
3
+ import { c as a } from "./cn-BmFQLtkS.js";
4
+ import { u as c } from "./useExposedProps-Csw8oAlt.js";
5
+ const u = ({
6
+ element: e,
7
+ render: t,
8
+ prose: o = !0
9
+ }) => {
10
+ const r = c(), m = t ? n.createElement(t, r) : e;
11
+ return /* @__PURE__ */ s.jsx("div", { className: a(o && "prose max-w-full"), children: m });
12
+ }, f = (e) => ({
13
+ getRoutes: () => e.map(({ path: t, ...o }) => ({
14
+ path: t,
15
+ element: /* @__PURE__ */ s.jsx(u, { ...o })
8
16
  }))
9
17
  });
10
18
  export {
11
- l as customPagesPlugin
19
+ f as customPagesPlugin
12
20
  };
13
21
  //# sourceMappingURL=zudoku.plugin-custom-pages.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"zudoku.plugin-custom-pages.js","sources":["../src/lib/plugins/custom-pages/index.tsx"],"sourcesContent":["import type { ReactNode } from \"react\";\nimport type { RouteObject } from \"react-router-dom\";\nimport { ProseClasses } from \"../../components/Markdown.js\";\nimport type { DevPortalPlugin, NavigationPlugin } from \"../../core/plugins.js\";\n\ntype CustomPagesConfig = Array<{\n path: string;\n element: ReactNode;\n}>;\n\nexport const customPagesPlugin = (\n config: CustomPagesConfig,\n): DevPortalPlugin & NavigationPlugin => {\n return {\n getRoutes: (): RouteObject[] =>\n config.map(({ path, element }) => ({\n path,\n // TODO: we should componentize prose pages\n element: <div className={ProseClasses + \" max-w-full\"}>{element}</div>,\n })),\n };\n};\n"],"names":["customPagesPlugin","config","path","element","jsx","ProseClasses"],"mappings":";;AAUa,MAAAA,IAAoB,CAC/BC,OAEO;AAAA,EACL,WAAW,MACTA,EAAO,IAAI,CAAC,EAAE,MAAAC,GAAM,SAAAC,SAAe;AAAA,IACjC,MAAAD;AAAA;AAAA,IAEA,SAAUE,gBAAAA,EAAAA,IAAA,OAAA,EAAI,WAAWC,IAAe,eAAgB,UAAQF,GAAA;AAAA,EAAA,EAChE;AAAA;"}
1
+ {"version":3,"file":"zudoku.plugin-custom-pages.js","sources":["../src/lib/plugins/custom-pages/CustomPage.tsx","../src/lib/plugins/custom-pages/index.tsx"],"sourcesContent":["import React from \"react\";\nimport { cn } from \"../../util/cn.js\";\nimport { useExposedProps } from \"../../util/useExposedProps.js\";\nimport type { CustomPageConfig } from \"./index.js\";\n\nexport const CustomPage = ({\n element,\n render,\n prose = true,\n}: Omit<CustomPageConfig, \"path\">) => {\n const slotletProps = useExposedProps();\n const content = render ? React.createElement(render, slotletProps) : element;\n\n return <div className={cn(prose && \"prose max-w-full\")}>{content}</div>;\n};\n","import { type ComponentType, type ReactNode } from \"react\";\nimport type { RouteObject } from \"react-router-dom\";\nimport { type ExposedComponentProps } from \"../../components/SlotletProvider.js\";\nimport type { DevPortalPlugin, NavigationPlugin } from \"../../core/plugins.js\";\nimport { CustomPage } from \"./CustomPage.js\";\n\nexport type CustomPageConfig = {\n path: string;\n prose?: boolean;\n element?: ReactNode;\n render?: ComponentType<ExposedComponentProps>;\n};\n\nexport const customPagesPlugin = (\n config: CustomPageConfig[],\n): DevPortalPlugin & NavigationPlugin => {\n return {\n getRoutes: (): RouteObject[] =>\n config.map(({ path, ...props }) => ({\n path,\n element: <CustomPage {...props} />,\n })),\n };\n};\n"],"names":["CustomPage","element","render","prose","slotletProps","useExposedProps","content","React","cn","customPagesPlugin","config","path","props","jsx"],"mappings":";;;;AAKO,MAAMA,IAAa,CAAC;AAAA,EACzB,SAAAC;AAAA,EACA,QAAAC;AAAA,EACA,OAAAC,IAAQ;AACV,MAAsC;AACpC,QAAMC,IAAeC,KACfC,IAAUJ,IAASK,EAAM,cAAcL,GAAQE,CAAY,IAAIH;AAErE,+BAAQ,OAAI,EAAA,WAAWO,EAAGL,KAAS,kBAAkB,GAAI,UAAQG,EAAA,CAAA;AACnE,GCDaG,IAAoB,CAC/BC,OAEO;AAAA,EACL,WAAW,MACTA,EAAO,IAAI,CAAC,EAAE,MAAAC,GAAM,GAAGC,SAAa;AAAA,IAClC,MAAAD;AAAA,IACA,SAASE,gBAAAA,EAAAA,IAACb,GAAY,EAAA,GAAGY,EAAO,CAAA;AAAA,EAAA,EAChC;AAAA;"}
@@ -6,7 +6,7 @@ const x = (t, e, n) => Object.entries(t).flatMap(([a, p]) => {
6
6
  return s ? {
7
7
  path: s,
8
8
  lazy: async () => {
9
- const { MdxPage: i } = await import("./MdxPage-BqBWsXZ1.js"), { default: m, ...l } = await p();
9
+ const { MdxPage: i } = await import("./MdxPage-DBhq6-5F.js"), { default: m, ...l } = await p();
10
10
  return {
11
11
  element: /* @__PURE__ */ u.jsx(
12
12
  i,
@@ -1,15 +1,15 @@
1
1
  import "./jsx-runtime-B6kdoens.js";
2
- import { o as u } from "./index-BlJ2rj99.js";
3
- import "./urql-YhcsXYy8.js";
4
- import "./ZudokuContext-cr-pTRY1.js";
2
+ import { o as u } from "./index-DA74gNq3.js";
3
+ import "./ZudokuContext-BEmsYQoq.js";
5
4
  import "lucide-react";
6
5
  import "zudoku/openapi-worker";
7
- import "./index-Dolisrci.js";
8
- import "./ErrorPage-CsZAN_za.js";
9
- import "./Markdown-DapSf3wG.js";
6
+ import "./index-g_JJcuFg.js";
7
+ import "./ErrorPage-B-zoPPVx.js";
8
+ import "./Markdown-D6Nze6qq.js";
10
9
  import "./joinPath-B7kNnUX4.js";
11
- import "./router-D2p7Olpn.js";
12
- import "./index-BG0g4WW0.js";
10
+ import "./urql-core-KJnLL26g.js";
11
+ import "./router-Oe6YmY6B.js";
12
+ import "./index-BRCiYFaL.js";
13
13
  export {
14
14
  u as openApiPlugin
15
15
  };
@@ -1,4 +1,4 @@
1
- import { r as o } from "./router-D2p7Olpn.js";
1
+ import { r as o } from "./router-Oe6YmY6B.js";
2
2
  const a = (r) => ({
3
3
  getRoutes: () => r.redirects.map(({ from: e, to: t }) => ({
4
4
  path: e,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "zudoku",
3
- "version": "0.13.0",
3
+ "version": "0.13.1",
4
4
  "type": "module",
5
5
  "homepage": "https://zudoku.dev",
6
6
  "repository": {
@@ -98,54 +98,58 @@
98
98
  }
99
99
  },
100
100
  "dependencies": {
101
- "@envelop/core": "5.0.1",
101
+ "@envelop/core": "5.0.2",
102
102
  "@graphql-typed-document-node/core": "3.2.0",
103
103
  "@hiogawa/vite-plugin-ssr-css": "0.0.1",
104
104
  "@lekoarts/rehype-meta-as-attributes": "3.0.1",
105
105
  "@mdx-js/react": "3.0.1",
106
106
  "@mdx-js/rollup": "3.0.1",
107
- "@monaco-editor/react": "^4.6.0",
108
107
  "@pothos/core": "3.41.0",
109
- "@radix-ui/react-collapsible": "1.1.0",
110
- "@radix-ui/react-dropdown-menu": "^2.1.1",
111
- "@radix-ui/react-select": "2.1.1",
112
- "@radix-ui/react-visually-hidden": "1.1.0",
113
- "@sentry/node": "8.11.0",
108
+ "@radix-ui/react-collapsible": "1.1.1",
109
+ "@radix-ui/react-dialog": "1.1.2",
110
+ "@radix-ui/react-dropdown-menu": "2.1.2",
111
+ "@radix-ui/react-select": "2.1.2",
112
+ "@radix-ui/react-slot": "1.1.0",
113
+ "@radix-ui/react-tabs": "1.1.1",
114
+ "@radix-ui/react-visually-hidden": "1",
115
+ "@sentry/node": "8.34.0",
114
116
  "@sindresorhus/slugify": "2.2.1",
115
117
  "@stefanprobst/rehype-extract-toc": "2.2.0",
116
- "@tailwindcss/typography": "0.5.13",
117
- "@tanstack/react-query": "5.50.1",
118
+ "@tailwindcss/typography": "0.5.15",
119
+ "@tanstack/react-query": "5.59.13",
120
+ "@types/react": "18.3.11",
121
+ "@types/react-dom": "18.3.1",
118
122
  "@vitejs/plugin-react": "4.3.1",
123
+ "@zudoku/httpsnippet": "10.0.9",
119
124
  "@zudoku/react-helmet-async": "2.0.4",
120
- "autoprefixer": "10.4.19",
121
- "chokidar": "^3.6.0",
125
+ "autoprefixer": "10.4.20",
126
+ "chokidar": "3.6.0",
122
127
  "class-variance-authority": "0.7.0",
128
+ "clsx": "2.1.1",
123
129
  "dotenv": "16.4.5",
124
- "express": "4.20.0",
125
- "glob": "^11.0.0",
130
+ "express": "4.21.1",
131
+ "glob": "11.0.0",
126
132
  "graphql": "16.9.0",
127
133
  "graphql-type-json": "0.3.2",
128
- "graphql-yoga": "5.2.0",
129
- "gray-matter": "^4.0.3",
130
- "http-terminator": "^3.2.0",
131
- "loglevel": "^1.9.1",
132
- "lru-cache": "11.0.0",
133
- "lucide-react": "0.438.0",
134
- "mdx": "0.3.1",
134
+ "graphql-yoga": "5.7.0",
135
+ "gray-matter": "4.0.3",
136
+ "http-terminator": "3.2.0",
137
+ "loglevel": "1.9.2",
138
+ "lru-cache": "11.0.1",
139
+ "lucide-react": "0.452.0",
140
+ "oauth4webapi": "2.17.0",
135
141
  "object-hash": "3.0.0",
136
142
  "openapi-types": "12.1.3",
137
- "picocolors": "^1.0.1",
138
- "postcss": "8.4.39",
139
- "posthog-node": "^4.1.1",
140
- "prism-react-renderer": "2.3.1",
143
+ "picocolors": "1.1.0",
144
+ "postcss": "8.4.47",
145
+ "posthog-node": "4.2.1",
146
+ "prism-react-renderer": "2.4.0",
141
147
  "prismjs": "1.29.0",
142
- "react": "18.3.1",
143
- "react-dom": "18.3.1",
144
- "react-error-boundary": "^4.0.13",
145
- "react-hook-form": "^7.52.1",
148
+ "react-error-boundary": "4.0.13",
149
+ "react-hook-form": "7.53.0",
146
150
  "react-is": "18.3.1",
147
151
  "react-markdown": "9.0.1",
148
- "react-router-dom": "6.25.1",
152
+ "react-router-dom": "6.27.0",
149
153
  "rehype-raw": "7.0.0",
150
154
  "rehype-slug": "6.0.0",
151
155
  "remark-comment": "1.0.0",
@@ -154,53 +158,42 @@
154
158
  "remark-frontmatter": "5.0.0",
155
159
  "remark-gfm": "4.0.0",
156
160
  "remark-mdx-frontmatter": "5.0.0",
157
- "rollup": "^4.21.2",
158
- "semver": "7.6.2",
159
- "sitemap": "^8.0.0",
161
+ "rollup": "4.24.0",
162
+ "semver": "7.6.3",
163
+ "sitemap": "8.0.0",
160
164
  "strip-ansi": "7.1.0",
161
- "tailwind-merge": "2.5.2",
162
- "tailwindcss": "3.4.4",
163
- "tsx": "4.19.0",
164
- "ulidx": "^2.3.0",
165
+ "tailwind-merge": "2.5.4",
166
+ "tailwindcss": "3.4.13",
167
+ "tsx": "4.19.1",
168
+ "ulidx": "2.4.1",
165
169
  "unist-util-visit": "5.0.0",
166
170
  "urql": "4.1.0",
167
- "vaul": "0.9.2",
168
- "vite": "5.3.6",
169
- "yaml": "2.5.0",
171
+ "vaul": "1.1.0",
172
+ "vite": "5.4.9",
173
+ "yaml": "2.6.0",
170
174
  "yargs": "17.7.2",
171
175
  "zod": "3.23.8",
172
- "zod-validation-error": "3.3.1",
173
- "zustand": "4.5.5"
176
+ "zod-validation-error": "3.4.0",
177
+ "zustand": "5.0.0"
174
178
  },
175
179
  "devDependencies": {
176
- "@radix-ui/react-dialog": "1.1.1",
177
- "@radix-ui/react-slot": "1.1.0",
178
- "@radix-ui/react-tabs": "1.1.0",
179
- "@types/express": "^4.17.21",
180
- "@types/har-format": "^1.2.15",
180
+ "@types/express": "4.17.21",
181
+ "@types/har-format": "1.2.15",
181
182
  "@types/json-schema": "7.0.15",
182
183
  "@types/mdx": "2.0.13",
183
- "@types/node": "20.12.10",
184
- "@types/object-hash": "^3.0.6",
185
- "@types/react": "18.3.3",
186
- "@types/react-dom": "18.3.0",
184
+ "@types/node": "20.16.11",
185
+ "@types/object-hash": "3.0.6",
187
186
  "@types/react-is": "18.3.0",
188
- "@types/rollup": "^0.54.0",
189
- "@types/semver": "^7.5.8",
190
- "@types/yargs": "^17.0.32",
191
- "@zudoku/httpsnippet": "10.0.9",
192
- "clsx": "2.1.1",
193
- "oauth4webapi": "2.11.1",
194
- "prism-react-renderer": "2.3.1",
195
- "prismjs": "1.29.0",
196
- "react-markdown": "9.0.1",
197
- "react-router-dom": "6.25.1",
198
- "rollup-plugin-visualizer": "^5.12.0",
199
- "typescript": "5.5.3"
187
+ "@types/semver": "7.5.8",
188
+ "@types/yargs": "17.0.33",
189
+ "rollup-plugin-visualizer": "5.12.0",
190
+ "react": "18.3.1",
191
+ "react-dom": "18.3.1",
192
+ "typescript": "5.6.3"
200
193
  },
201
194
  "peerDependencies": {
202
- "react": ">18.0.0",
203
- "react-dom": ">18.0.0"
195
+ "react": ">=18",
196
+ "react-dom": ">=18"
204
197
  },
205
198
  "optionalDependencies": {
206
199
  "@clerk/clerk-js": "5.11.0",
@@ -91,8 +91,8 @@ export const Header = memo(function HeaderInner() {
91
91
  </div>
92
92
  </Link>
93
93
  </div>
94
- <div className="grid grid-cols-2 md:grid-cols-[--sidecar-grid-cols] items-center gap-8">
95
- <div className="w-full justify-center flex">
94
+ <div className="grid grid-cols-1 lg:grid-cols-[--sidecar-grid-cols] items-center gap-8">
95
+ <div className="w-full justify-center hidden lg:flex">
96
96
  <Search />
97
97
  </div>
98
98
 
@@ -10,6 +10,7 @@ import {
10
10
  DrawerTrigger,
11
11
  } from "../ui/Drawer.js";
12
12
  import { useZudoku } from "./context/ZudokuContext.js";
13
+ import { Search } from "./Search.js";
13
14
 
14
15
  export const MobileTopNavigation = () => {
15
16
  const { topNavigation } = useZudoku();
@@ -27,6 +28,9 @@ export const MobileTopNavigation = () => {
27
28
  <VisuallyHidden>
28
29
  <DrawerTitle>Navigation</DrawerTitle>
29
30
  </VisuallyHidden>
31
+ <div className="flex p-4">
32
+ <Search />
33
+ </div>
30
34
  <ul className="flex flex-col items-center gap-4 p-4">
31
35
  {topNavigation.map((item) => (
32
36
  <li key={item.label}>
@@ -39,7 +39,7 @@ export const Search = () => {
39
39
  <button
40
40
  type="button"
41
41
  onClick={() => setIsOpen(true)}
42
- className="flex items-center border border-input hover:bg-accent hover:text-accent-foreground p-4 relative h-8 justify-start rounded-lg bg-background text-sm text-muted-foreground shadow-none w-40 sm:w-72"
42
+ className="flex items-center border border-input hover:bg-accent hover:text-accent-foreground p-4 relative h-8 justify-start rounded-lg bg-background text-sm text-muted-foreground shadow-none w-full sm:w-72"
43
43
  >
44
44
  <div className="flex items-center gap-2 flex-grow">
45
45
  <SearchIcon size={14} />
@@ -5,10 +5,16 @@ import React, {
5
5
  useContext,
6
6
  } from "react";
7
7
  import { isValidElementType } from "react-is";
8
- import { useLocation } from "react-router-dom";
8
+ import {
9
+ type Location,
10
+ type NavigateFunction,
11
+ type SetURLSearchParams,
12
+ } from "react-router-dom";
13
+ import { useExposedProps } from "../util/useExposedProps.js";
14
+
9
15
  export type Slotlets = Record<
10
16
  string,
11
- ReactNode | ReactElement | ComponentType<SlotletComponentProps>
17
+ ReactNode | ReactElement | ComponentType<ExposedComponentProps>
12
18
  >;
13
19
 
14
20
  const SlotletContext = React.createContext<Slotlets | undefined>({});
@@ -27,19 +33,20 @@ export const SlotletProvider = ({
27
33
  );
28
34
  };
29
35
 
30
- export type SlotletComponentProps = {
36
+ export type ExposedComponentProps = {
31
37
  location: Location;
38
+ navigate: NavigateFunction;
39
+ searchParams: URLSearchParams;
40
+ setSearchParams: SetURLSearchParams;
32
41
  };
33
42
 
34
43
  export const Slotlet = ({ name }: { name: string }) => {
35
44
  const context = useContext(SlotletContext);
36
45
  const componentOrElement = context?.[name];
37
- const location = useLocation();
46
+ const slotletProps = useExposedProps();
38
47
 
39
48
  if (isValidElementType(componentOrElement)) {
40
- return React.createElement(componentOrElement, {
41
- location,
42
- });
49
+ return React.createElement(componentOrElement, slotletProps);
43
50
  }
44
51
 
45
52
  return componentOrElement as ReactNode;
@@ -16,7 +16,7 @@ export const useMDXComponents = /*@__PURE__*/ useMDXComponentsImport;
16
16
  export const Callout = /*@__PURE__*/ CalloutImport;
17
17
  export const DevPortal = /*@__PURE__*/ DevPortalImport;
18
18
  export const Layout = /*@__PURE__*/ LayoutImport;
19
- export const Link = /*@__PURE__*/ LinkImport;
19
+ export const Link: typeof LinkImport = /*@__PURE__*/ LinkImport;
20
20
  export const RouterError = /*@__PURE__*/ RouterErrorImport;
21
21
  export const ServerError = /*@__PURE__*/ ServerErrorImport;
22
22
  export const Bootstrap = /*@__PURE__*/ BootstrapImport;
@@ -0,0 +1,15 @@
1
+ import React from "react";
2
+ import { cn } from "../../util/cn.js";
3
+ import { useExposedProps } from "../../util/useExposedProps.js";
4
+ import type { CustomPageConfig } from "./index.js";
5
+
6
+ export const CustomPage = ({
7
+ element,
8
+ render,
9
+ prose = true,
10
+ }: Omit<CustomPageConfig, "path">) => {
11
+ const slotletProps = useExposedProps();
12
+ const content = render ? React.createElement(render, slotletProps) : element;
13
+
14
+ return <div className={cn(prose && "prose max-w-full")}>{content}</div>;
15
+ };
@@ -1,22 +1,24 @@
1
- import type { ReactNode } from "react";
1
+ import { type ComponentType, type ReactNode } from "react";
2
2
  import type { RouteObject } from "react-router-dom";
3
- import { ProseClasses } from "../../components/Markdown.js";
3
+ import { type ExposedComponentProps } from "../../components/SlotletProvider.js";
4
4
  import type { DevPortalPlugin, NavigationPlugin } from "../../core/plugins.js";
5
+ import { CustomPage } from "./CustomPage.js";
5
6
 
6
- type CustomPagesConfig = Array<{
7
+ export type CustomPageConfig = {
7
8
  path: string;
8
- element: ReactNode;
9
- }>;
9
+ prose?: boolean;
10
+ element?: ReactNode;
11
+ render?: ComponentType<ExposedComponentProps>;
12
+ };
10
13
 
11
14
  export const customPagesPlugin = (
12
- config: CustomPagesConfig,
15
+ config: CustomPageConfig[],
13
16
  ): DevPortalPlugin & NavigationPlugin => {
14
17
  return {
15
18
  getRoutes: (): RouteObject[] =>
16
- config.map(({ path, element }) => ({
19
+ config.map(({ path, ...props }) => ({
17
20
  path,
18
- // TODO: we should componentize prose pages
19
- element: <div className={ProseClasses + " max-w-full"}>{element}</div>,
21
+ element: <CustomPage {...props} />,
20
22
  })),
21
23
  };
22
24
  };
@@ -1,12 +1,12 @@
1
1
  import { CheckIcon, CopyIcon } from "lucide-react";
2
2
  import { useState, useTransition } from "react";
3
+ import { useQuery } from "urql";
3
4
  import { useSelectedServerStore } from "../../authentication/state.js";
4
5
  import { InlineCode } from "../../components/InlineCode.js";
5
6
  import { Button } from "../../ui/Button.js";
6
7
  import { useOasConfig } from "./context.js";
7
8
  import { graphql } from "./graphql/index.js";
8
9
  import { SimpleSelect } from "./SimpleSelect.js";
9
- import { useQuery } from "./util/urql.js";
10
10
 
11
11
  const ServersQuery = graphql(/* GraphQL */ `
12
12
  query ServersQuery($input: JSON!, $type: SchemaType!) {
@@ -1,4 +1,5 @@
1
1
  import { ResultOf } from "@graphql-typed-document-node/core";
2
+ import { useQuery } from "urql";
2
3
  import { CategoryHeading } from "../../components/CategoryHeading.js";
3
4
  import { DeveloperHint } from "../../components/DeveloperHint.js";
4
5
  import { ErrorPage } from "../../components/ErrorPage.js";
@@ -12,7 +13,6 @@ import { OperationListItem } from "./OperationListItem.js";
12
13
  import StaggeredRender from "./StaggeredRender.js";
13
14
  import { useOasConfig } from "./context.js";
14
15
  import { graphql } from "./graphql/index.js";
15
- import { useQuery } from "./util/urql.js";
16
16
 
17
17
  export const OperationsFragment = graphql(/* GraphQL */ `
18
18
  fragment OperationsFragment on OperationItem {
@@ -1,9 +1,8 @@
1
1
  import { Outlet } from "react-router-dom";
2
+ import { Provider, Client as UrqlClient } from "urql";
2
3
  import { OasConfigProvider } from "./context.js";
3
4
  import { OasPluginConfig } from "./interfaces.js";
4
5
 
5
- import { Provider, Client as UrqlClient } from "./util/urql.js";
6
-
7
6
  export function OpenApiRoute({
8
7
  config,
9
8
  client,
@@ -1,6 +1,7 @@
1
1
  import { HTTPSnippet } from "@zudoku/httpsnippet";
2
2
  import { Fragment, useMemo, useTransition } from "react";
3
3
  import { useSearchParams } from "react-router-dom";
4
+ import { useQuery } from "urql";
4
5
  import { useSelectedServerStore } from "../../authentication/state.js";
5
6
  import { TextColorMap } from "../../components/navigation/SidebarBadge.js";
6
7
  import { SyntaxHighlight } from "../../components/SyntaxHighlight.js";
@@ -16,7 +17,6 @@ import { ResponsesSidecarBox } from "./ResponsesSidecarBox.js";
16
17
  import * as SidecarBox from "./SidecarBox.js";
17
18
  import { SimpleSelect } from "./SimpleSelect.js";
18
19
  import { generateSchemaExample } from "./util/generateSchemaExample.js";
19
- import { useQuery } from "./util/urql.js";
20
20
 
21
21
  const getConverted = (snippet: HTTPSnippet, option: string) => {
22
22
  let converted;
@@ -1,10 +1,5 @@
1
1
  /* eslint-disable no-console */
2
- import {
3
- cacheExchange,
4
- Client,
5
- fetchExchange,
6
- mapExchange,
7
- } from "../util/urql.js";
2
+ import { cacheExchange, Client, fetchExchange, mapExchange } from "urql";
8
3
  import { createServer } from "./createServer.js";
9
4
  import { CreateClientFunction } from "./interfaces.js";
10
5
 
@@ -1,12 +1,7 @@
1
1
  /* eslint-disable no-console */
2
2
  import { monotonicFactory } from "ulidx";
3
+ import { cacheExchange, Client, fetchExchange, mapExchange } from "urql";
3
4
  import { createWaitForNotify } from "../../../util/createWaitForNotify.js";
4
- import {
5
- cacheExchange,
6
- Client,
7
- fetchExchange,
8
- mapExchange,
9
- } from "../util/urql.js";
10
5
  import { createClient as createMemoryClient } from "./createMemoryClient.js";
11
6
  import { CreateClientFunction } from "./interfaces.js";
12
7
 
@@ -1,11 +1,7 @@
1
1
  import { matchPath, useRouteError, type RouteObject } from "react-router-dom";
2
+ import { Client as UrqlClient, cacheExchange, fetchExchange } from "urql";
2
3
  import { type DevPortalPlugin } from "../../core/plugins.js";
3
4
  import { graphql } from "./graphql/index.js";
4
- import {
5
- Client as UrqlClient,
6
- cacheExchange,
7
- fetchExchange,
8
- } from "./util/urql.js";
9
5
 
10
6
  import { useQuery } from "@tanstack/react-query";
11
7
  import { CirclePlayIcon, LogInIcon } from "lucide-react";
@@ -2,6 +2,7 @@ import {
2
2
  AlertTriangleIcon,
3
3
  InfoIcon,
4
4
  LightbulbIcon,
5
+ type LucideIcon,
5
6
  ShieldAlertIcon,
6
7
  } from "lucide-react";
7
8
  import type { ReactNode } from "react";
@@ -14,7 +15,7 @@ const stylesMap = {
14
15
  iconColor: "text-gray-600 dark:text-zinc-300",
15
16
  titleColor: "text-gray-600 dark:text-zinc-300",
16
17
  textColor: "text-gray-600 dark:text-zinc-300",
17
- Icon: InfoIcon,
18
+ Icon: InfoIcon as LucideIcon,
18
19
  },
19
20
  tip: {
20
21
  border: "border-green-500 dark:border-green-800",
@@ -22,7 +23,7 @@ const stylesMap = {
22
23
  iconColor: "text-green-600 dark:text-green-200",
23
24
  titleColor: "text-green-700 dark:text-green-200",
24
25
  textColor: "text-green-600 dark:text-green-50",
25
- Icon: LightbulbIcon,
26
+ Icon: LightbulbIcon as LucideIcon,
26
27
  },
27
28
  info: {
28
29
  border: "border-blue-400 dark:border-blue-900/60",
@@ -30,7 +31,7 @@ const stylesMap = {
30
31
  iconColor: "text-blue-400 dark:text-blue-200",
31
32
  titleColor: "text-blue-700 dark:text-blue-200",
32
33
  textColor: "text-blue-600 dark:text-blue-100",
33
- Icon: InfoIcon,
34
+ Icon: InfoIcon as LucideIcon,
34
35
  },
35
36
  caution: {
36
37
  border: "border-yellow-400 dark:border-yellow-400/25",
@@ -38,7 +39,7 @@ const stylesMap = {
38
39
  iconColor: "text-yellow-500 dark:text-yellow-300",
39
40
  titleColor: "text-yellow-600 dark:text-yellow-300",
40
41
  textColor: "text-yellow-700 dark:text-yellow-200",
41
- Icon: AlertTriangleIcon,
42
+ Icon: AlertTriangleIcon as LucideIcon,
42
43
  },
43
44
  danger: {
44
45
  border: "border-rose-400 dark:border-rose-800",
@@ -46,9 +47,9 @@ const stylesMap = {
46
47
  iconColor: "text-rose-400 dark:text-rose-300",
47
48
  titleColor: "text-rose-800 dark:text-rose-300",
48
49
  textColor: "text-rose-700 dark:text-rose-100",
49
- Icon: ShieldAlertIcon,
50
+ Icon: ShieldAlertIcon as LucideIcon,
50
51
  },
51
- };
52
+ } as const;
52
53
 
53
54
  type CalloutProps = {
54
55
  type: keyof typeof stylesMap;