zudoku 0.47.1 → 0.48.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.
Files changed (325) hide show
  1. package/dist/app/ZuploBuildConfig.d.ts +11 -121
  2. package/dist/app/ZuploBuildConfig.js +8 -8
  3. package/dist/app/ZuploBuildConfig.js.map +1 -1
  4. package/dist/app/demo.js +4 -3
  5. package/dist/app/demo.js.map +1 -1
  6. package/dist/app/entry.client.d.ts +0 -2
  7. package/dist/app/entry.client.js +0 -2
  8. package/dist/app/entry.client.js.map +1 -1
  9. package/dist/app/entry.server.d.ts +0 -2
  10. package/dist/app/entry.server.js +0 -2
  11. package/dist/app/entry.server.js.map +1 -1
  12. package/dist/app/env.d.ts +7 -7
  13. package/dist/app/env.js +8 -0
  14. package/dist/app/env.js.map +1 -1
  15. package/dist/app/main.d.ts +1 -0
  16. package/dist/app/main.js +6 -5
  17. package/dist/app/main.js.map +1 -1
  18. package/dist/app/standalone.js +4 -3
  19. package/dist/app/standalone.js.map +1 -1
  20. package/dist/config/loader.js +1 -2
  21. package/dist/config/loader.js.map +1 -1
  22. package/dist/config/validators/BuildSchema.d.ts +20 -44
  23. package/dist/config/validators/BuildSchema.js +3 -14
  24. package/dist/config/validators/BuildSchema.js.map +1 -1
  25. package/dist/config/validators/InputNavigationSchema.d.ts +7217 -0
  26. package/dist/config/validators/InputNavigationSchema.js +74 -0
  27. package/dist/config/validators/InputNavigationSchema.js.map +1 -0
  28. package/dist/config/validators/InputNavigationSchema.test-d.d.ts +1 -0
  29. package/dist/config/validators/InputNavigationSchema.test-d.js +146 -0
  30. package/dist/config/validators/InputNavigationSchema.test-d.js.map +1 -0
  31. package/dist/config/validators/NavigationSchema.d.ts +44 -0
  32. package/dist/config/validators/NavigationSchema.js +95 -0
  33. package/dist/config/validators/NavigationSchema.js.map +1 -0
  34. package/dist/config/validators/icon-types.d.ts +2 -1
  35. package/dist/config/validators/icon-types.js +1775 -1
  36. package/dist/config/validators/icon-types.js.map +1 -1
  37. package/dist/config/validators/validate.d.ts +451 -5666
  38. package/dist/config/validators/validate.js +59 -66
  39. package/dist/config/validators/validate.js.map +1 -1
  40. package/dist/config/validators/validate.test.js +0 -2
  41. package/dist/config/validators/validate.test.js.map +1 -1
  42. package/dist/index.d.ts +1 -1
  43. package/dist/index.js.map +1 -1
  44. package/dist/lib/auth/issuer.js +1 -1
  45. package/dist/lib/auth/issuer.js.map +1 -1
  46. package/dist/lib/auth/issuer.test.js +1 -1
  47. package/dist/lib/auth/issuer.test.js.map +1 -1
  48. package/dist/lib/authentication/components/CallbackHandler.js +1 -1
  49. package/dist/lib/authentication/components/CallbackHandler.js.map +1 -1
  50. package/dist/lib/components/BuildCheck.js +1 -1
  51. package/dist/lib/components/BuildCheck.js.map +1 -1
  52. package/dist/lib/components/Framed.d.ts +7 -0
  53. package/dist/lib/components/Framed.js +26 -0
  54. package/dist/lib/components/Framed.js.map +1 -0
  55. package/dist/lib/components/Header.js +10 -9
  56. package/dist/lib/components/Header.js.map +1 -1
  57. package/dist/lib/components/Heading.d.ts +6 -2
  58. package/dist/lib/components/Heading.js +2 -2
  59. package/dist/lib/components/Heading.js.map +1 -1
  60. package/dist/lib/components/Main.js +4 -4
  61. package/dist/lib/components/Main.js.map +1 -1
  62. package/dist/lib/components/MobileTopNavigation.js +6 -5
  63. package/dist/lib/components/MobileTopNavigation.js.map +1 -1
  64. package/dist/lib/components/PageProgress.d.ts +1 -0
  65. package/dist/lib/components/PageProgress.js +20 -0
  66. package/dist/lib/components/PageProgress.js.map +1 -0
  67. package/dist/lib/components/TopNavigation.d.ts +2 -3
  68. package/dist/lib/components/TopNavigation.js +45 -44
  69. package/dist/lib/components/TopNavigation.js.map +1 -1
  70. package/dist/lib/components/context/ZudokuContext.d.ts +3 -7
  71. package/dist/lib/components/context/ZudokuContext.js +44 -26
  72. package/dist/lib/components/context/ZudokuContext.js.map +1 -1
  73. package/dist/lib/components/navigation/Navigation.d.ts +5 -0
  74. package/dist/lib/components/navigation/Navigation.js +12 -0
  75. package/dist/lib/components/navigation/Navigation.js.map +1 -0
  76. package/dist/lib/components/navigation/{SidebarBadge.d.ts → NavigationBadge.d.ts} +1 -1
  77. package/dist/lib/components/navigation/{SidebarBadge.js → NavigationBadge.js} +2 -2
  78. package/dist/lib/components/navigation/NavigationBadge.js.map +1 -0
  79. package/dist/lib/components/navigation/NavigationCategory.d.ts +5 -0
  80. package/dist/lib/components/navigation/{SidebarCategory.js → NavigationCategory.js} +14 -12
  81. package/dist/lib/components/navigation/NavigationCategory.js.map +1 -0
  82. package/dist/lib/components/navigation/NavigationItem.d.ts +6 -0
  83. package/dist/lib/components/navigation/NavigationItem.js +47 -0
  84. package/dist/lib/components/navigation/NavigationItem.js.map +1 -0
  85. package/dist/lib/components/navigation/{SidebarWrapper.d.ts → NavigationWrapper.d.ts} +1 -1
  86. package/dist/lib/components/navigation/{SidebarWrapper.js → NavigationWrapper.js} +3 -3
  87. package/dist/lib/components/navigation/NavigationWrapper.js.map +1 -0
  88. package/dist/lib/components/navigation/utils.d.ts +7 -9
  89. package/dist/lib/components/navigation/utils.js +17 -17
  90. package/dist/lib/components/navigation/utils.js.map +1 -1
  91. package/dist/lib/core/ZudokuContext.d.ts +6 -8
  92. package/dist/lib/core/ZudokuContext.js +5 -7
  93. package/dist/lib/core/ZudokuContext.js.map +1 -1
  94. package/dist/lib/core/plugins.d.ts +2 -2
  95. package/dist/lib/hooks/useEvent.test.js +5 -3
  96. package/dist/lib/hooks/useEvent.test.js.map +1 -1
  97. package/dist/lib/plugins/api-catalog/Catalog.d.ts +1 -1
  98. package/dist/lib/plugins/api-catalog/index.d.ts +6 -6
  99. package/dist/lib/plugins/api-catalog/index.js +10 -10
  100. package/dist/lib/plugins/api-catalog/index.js.map +1 -1
  101. package/dist/lib/plugins/api-keys/SettingsApiKeys.js +6 -6
  102. package/dist/lib/plugins/api-keys/SettingsApiKeys.js.map +1 -1
  103. package/dist/lib/plugins/custom-pages/index.d.ts +3 -2
  104. package/dist/lib/plugins/custom-pages/index.js +15 -8
  105. package/dist/lib/plugins/custom-pages/index.js.map +1 -1
  106. package/dist/lib/plugins/markdown/MdxPage.js +6 -3
  107. package/dist/lib/plugins/markdown/MdxPage.js.map +1 -1
  108. package/dist/lib/plugins/markdown/index.d.ts +2 -1
  109. package/dist/lib/plugins/markdown/index.js +9 -26
  110. package/dist/lib/plugins/markdown/index.js.map +1 -1
  111. package/dist/lib/plugins/openapi/OperationList.js +1 -1
  112. package/dist/lib/plugins/openapi/OperationList.js.map +1 -1
  113. package/dist/lib/plugins/openapi/OperationListItem.js +1 -1
  114. package/dist/lib/plugins/openapi/OperationListItem.js.map +1 -1
  115. package/dist/lib/plugins/openapi/SchemaList.js +1 -1
  116. package/dist/lib/plugins/openapi/SchemaList.js.map +1 -1
  117. package/dist/lib/plugins/openapi/graphql/gql.d.ts +1 -1
  118. package/dist/lib/plugins/openapi/graphql/gql.js +1 -1
  119. package/dist/lib/plugins/openapi/graphql/gql.js.map +1 -1
  120. package/dist/lib/plugins/openapi/graphql/graphql.d.ts +3 -3
  121. package/dist/lib/plugins/openapi/graphql/graphql.js +2 -2
  122. package/dist/lib/plugins/openapi/graphql/graphql.js.map +1 -1
  123. package/dist/lib/plugins/openapi/index.d.ts +3 -3
  124. package/dist/lib/plugins/openapi/index.js +9 -9
  125. package/dist/lib/plugins/openapi/index.js.map +1 -1
  126. package/dist/lib/plugins/openapi/interfaces.d.ts +3 -3
  127. package/dist/lib/plugins/openapi/schema/SchemaView.js +1 -1
  128. package/dist/lib/plugins/openapi/schema/SchemaView.js.map +1 -1
  129. package/dist/lib/plugins/openapi/util/createNavigationCategory.d.ts +9 -0
  130. package/dist/lib/plugins/openapi/util/{createSidebarCategory.js → createNavigationCategory.js} +5 -4
  131. package/dist/lib/plugins/openapi/util/createNavigationCategory.js.map +1 -0
  132. package/dist/lib/plugins/openapi/util/getRoutes.js +2 -2
  133. package/dist/lib/plugins/openapi/util/getRoutes.js.map +1 -1
  134. package/dist/lib/plugins/openapi/util/methodColorMap.d.ts +1 -1
  135. package/dist/lib/ui/CodeBlock.js +1 -1
  136. package/dist/lib/ui/CodeBlock.js.map +1 -1
  137. package/dist/lib/util/MdxComponents.d.ts +6 -0
  138. package/dist/lib/util/MdxComponents.js +4 -2
  139. package/dist/lib/util/MdxComponents.js.map +1 -1
  140. package/dist/lib/util/useScrollToAnchor.js +3 -3
  141. package/dist/lib/util/useScrollToAnchor.js.map +1 -1
  142. package/dist/vite/api/SchemaManager.d.ts +4 -4
  143. package/dist/vite/api/SchemaManager.js +19 -19
  144. package/dist/vite/api/SchemaManager.js.map +1 -1
  145. package/dist/vite/api/SchemaManager.test.js +4 -4
  146. package/dist/vite/api/SchemaManager.test.js.map +1 -1
  147. package/dist/vite/config.js +1 -0
  148. package/dist/vite/config.js.map +1 -1
  149. package/dist/vite/css/plugin.js +11 -0
  150. package/dist/vite/css/plugin.js.map +1 -1
  151. package/dist/vite/plugin-api.js +8 -8
  152. package/dist/vite/plugin-api.js.map +1 -1
  153. package/dist/vite/plugin-config-reload.js +2 -0
  154. package/dist/vite/plugin-config-reload.js.map +1 -1
  155. package/dist/vite/plugin-custom-pages.js +2 -2
  156. package/dist/vite/plugin-custom-pages.js.map +1 -1
  157. package/dist/vite/plugin-docs.js +61 -59
  158. package/dist/vite/plugin-docs.js.map +1 -1
  159. package/dist/vite/plugin-mdx.js +4 -2
  160. package/dist/vite/plugin-mdx.js.map +1 -1
  161. package/dist/vite/{plugin-sidebar.d.ts → plugin-navigation.d.ts} +1 -1
  162. package/dist/vite/{plugin-sidebar.js → plugin-navigation.js} +20 -19
  163. package/dist/vite/plugin-navigation.js.map +1 -0
  164. package/dist/vite/plugin-theme.d.ts +8 -0
  165. package/dist/vite/plugin-theme.js +223 -0
  166. package/dist/vite/plugin-theme.js.map +1 -0
  167. package/dist/vite/plugin-theme.test.d.ts +1 -0
  168. package/dist/vite/plugin-theme.test.js +270 -0
  169. package/dist/vite/plugin-theme.test.js.map +1 -0
  170. package/dist/vite/plugin.js +4 -6
  171. package/dist/vite/plugin.js.map +1 -1
  172. package/dist/vite/shadcn-registry.d.ts +45 -0
  173. package/dist/vite/shadcn-registry.js +29 -0
  174. package/dist/vite/shadcn-registry.js.map +1 -0
  175. package/lib/Drawer-BzkOKwgC.js.map +1 -1
  176. package/lib/{Markdown-r4buN85T.js → Markdown-DCAIYXF5.js} +885 -840
  177. package/lib/Markdown-DCAIYXF5.js.map +1 -0
  178. package/lib/{MdxPage-DYKsTerz.js → MdxPage-Cf9YXWoC.js} +30 -30
  179. package/lib/MdxPage-Cf9YXWoC.js.map +1 -0
  180. package/lib/OasProvider-JMVTfG6_.js +35 -0
  181. package/lib/OasProvider-JMVTfG6_.js.map +1 -0
  182. package/lib/{OperationList-BCVHtZNK.js → OperationList-m4tFCI4S.js} +8 -8
  183. package/lib/{OperationList-BCVHtZNK.js.map → OperationList-m4tFCI4S.js.map} +1 -1
  184. package/lib/{RouteGuard-B7GVW4oL.js → RouteGuard-gV7nvzi7.js} +2 -2
  185. package/lib/{RouteGuard-B7GVW4oL.js.map → RouteGuard-gV7nvzi7.js.map} +1 -1
  186. package/lib/{SchemaList-1oJKvBxh.js → SchemaList-_wRy4aQ0.js} +20 -20
  187. package/lib/SchemaList-_wRy4aQ0.js.map +1 -0
  188. package/lib/{SchemaView-CTqaB-79.js → SchemaView-CRl_cQYH.js} +13 -13
  189. package/lib/{SchemaView-CTqaB-79.js.map → SchemaView-CRl_cQYH.js.map} +1 -1
  190. package/lib/{SignUp-CRIKdWt9.js → SignUp-B6w5AwHM.js} +2 -2
  191. package/lib/{SignUp-CRIKdWt9.js.map → SignUp-B6w5AwHM.js.map} +1 -1
  192. package/lib/{Slot-B5qSAnwR.js → Slot-BkYrj_uC.js} +4 -4
  193. package/lib/{Slot-B5qSAnwR.js.map → Slot-BkYrj_uC.js.map} +1 -1
  194. package/lib/{SyntaxHighlight-CqKHkyEy.js → SyntaxHighlight-CH9OUJre.js} +2 -2
  195. package/lib/{SyntaxHighlight-CqKHkyEy.js.map → SyntaxHighlight-CH9OUJre.js.map} +1 -1
  196. package/lib/{Toc-lxYQEOzX.js → Toc-DRxqEsFc.js} +2 -2
  197. package/lib/{Toc-lxYQEOzX.js.map → Toc-DRxqEsFc.js.map} +1 -1
  198. package/lib/{circular-ZGGPtwMq.js → circular-wJaV4vh_.js} +2 -2
  199. package/lib/{circular-ZGGPtwMq.js.map → circular-wJaV4vh_.js.map} +1 -1
  200. package/lib/clerk-yAKDC3Qz.js.map +1 -1
  201. package/lib/{createServer-DUBpXfvA.js → createServer-DN5AJLcN.js} +3 -3
  202. package/lib/{createServer-DUBpXfvA.js.map → createServer-DN5AJLcN.js.map} +1 -1
  203. package/lib/{errors-D27ZTQgx.js → errors-D_5vKvUq.js} +10 -10
  204. package/lib/{errors-D27ZTQgx.js.map → errors-D_5vKvUq.js.map} +1 -1
  205. package/lib/hook-CHXroBFt.js +1503 -0
  206. package/lib/hook-CHXroBFt.js.map +1 -0
  207. package/lib/index-CrcNWbel.js.map +1 -1
  208. package/lib/{index-Cucjfk3D.js → index-DJVaRmzI.js} +63 -62
  209. package/lib/index-DJVaRmzI.js.map +1 -0
  210. package/lib/index-QzXzw_ra.js.map +1 -1
  211. package/lib/{mutation-C1XCQTQL.js → mutation-BpcyTgWI.js} +2 -2
  212. package/lib/{mutation-C1XCQTQL.js.map → mutation-BpcyTgWI.js.map} +1 -1
  213. package/lib/ui/CodeBlock.js +7 -7
  214. package/lib/ui/CodeBlock.js.map +1 -1
  215. package/lib/ui/SyntaxHighlight.js +2 -2
  216. package/lib/{useMutation-BKvPttRn.js → useMutation-N4ockVKi.js} +3 -3
  217. package/lib/{useMutation-BKvPttRn.js.map → useMutation-N4ockVKi.js.map} +1 -1
  218. package/lib/zudoku.auth-auth0.js +1 -1
  219. package/lib/zudoku.auth-azureb2c.js +2 -2
  220. package/lib/zudoku.auth-clerk.js +2 -2
  221. package/lib/zudoku.auth-openid.js +2 -2
  222. package/lib/zudoku.components.js +2756 -3423
  223. package/lib/zudoku.components.js.map +1 -1
  224. package/lib/zudoku.hooks.js +2 -2
  225. package/lib/zudoku.plugin-api-catalog.js +44 -44
  226. package/lib/zudoku.plugin-api-catalog.js.map +1 -1
  227. package/lib/zudoku.plugin-api-keys.js +84 -73
  228. package/lib/zudoku.plugin-api-keys.js.map +1 -1
  229. package/lib/zudoku.plugin-custom-pages.js +22 -16
  230. package/lib/zudoku.plugin-custom-pages.js.map +1 -1
  231. package/lib/zudoku.plugin-markdown.js +20 -69
  232. package/lib/zudoku.plugin-markdown.js.map +1 -1
  233. package/lib/zudoku.plugin-openapi.js +5 -5
  234. package/lib/zudoku.plugin-search-pagefind.js +2 -2
  235. package/lib/zudoku.plugins.js.map +1 -1
  236. package/package.json +16 -13
  237. package/src/app/ZuploBuildConfig.ts +8 -8
  238. package/src/app/defaultTheme.css +68 -49
  239. package/src/app/demo.tsx +4 -3
  240. package/src/app/entry.client.tsx +0 -2
  241. package/src/app/entry.server.tsx +0 -2
  242. package/src/app/env.ts +8 -0
  243. package/src/app/main.css +6 -52
  244. package/src/app/main.tsx +7 -5
  245. package/src/app/standalone.tsx +4 -3
  246. package/src/lib/auth/issuer.test.ts +1 -1
  247. package/src/lib/auth/issuer.ts +1 -1
  248. package/src/lib/authentication/components/CallbackHandler.tsx +1 -1
  249. package/src/lib/components/BuildCheck.tsx +1 -1
  250. package/src/lib/components/Framed.tsx +51 -0
  251. package/src/lib/components/Header.tsx +5 -3
  252. package/src/lib/components/Heading.tsx +7 -3
  253. package/src/lib/components/Main.tsx +8 -8
  254. package/src/lib/components/MobileTopNavigation.tsx +16 -11
  255. package/src/lib/components/PageProgress.tsx +28 -0
  256. package/src/lib/components/TopNavigation.tsx +57 -66
  257. package/src/lib/components/context/ZudokuContext.ts +50 -32
  258. package/src/lib/components/navigation/{Sidebar.tsx → Navigation.tsx} +18 -16
  259. package/src/lib/components/navigation/{SidebarBadge.tsx → NavigationBadge.tsx} +1 -1
  260. package/src/lib/components/navigation/{SidebarCategory.tsx → NavigationCategory.tsx} +16 -14
  261. package/src/lib/components/navigation/{SidebarItem.tsx → NavigationItem.tsx} +23 -17
  262. package/src/lib/components/navigation/{SidebarWrapper.tsx → NavigationWrapper.tsx} +2 -2
  263. package/src/lib/components/navigation/utils.ts +27 -28
  264. package/src/lib/core/ZudokuContext.ts +9 -15
  265. package/src/lib/core/plugins.ts +2 -2
  266. package/src/lib/hooks/useEvent.test.tsx +7 -5
  267. package/src/lib/plugins/api-catalog/Catalog.tsx +1 -1
  268. package/src/lib/plugins/api-catalog/index.tsx +19 -19
  269. package/src/lib/plugins/api-keys/SettingsApiKeys.tsx +14 -10
  270. package/src/lib/plugins/custom-pages/index.tsx +20 -11
  271. package/src/lib/plugins/markdown/MdxPage.tsx +6 -3
  272. package/src/lib/plugins/markdown/index.tsx +19 -40
  273. package/src/lib/plugins/openapi/OperationList.tsx +1 -1
  274. package/src/lib/plugins/openapi/OperationListItem.tsx +1 -1
  275. package/src/lib/plugins/openapi/SchemaList.tsx +2 -2
  276. package/src/lib/plugins/openapi/graphql/gql.ts +5 -5
  277. package/src/lib/plugins/openapi/graphql/graphql.ts +6 -6
  278. package/src/lib/plugins/openapi/index.tsx +11 -11
  279. package/src/lib/plugins/openapi/interfaces.ts +3 -3
  280. package/src/lib/plugins/openapi/schema/SchemaView.tsx +1 -1
  281. package/src/lib/plugins/openapi/util/{createSidebarCategory.tsx → createNavigationCategory.tsx} +6 -5
  282. package/src/lib/plugins/openapi/util/getRoutes.tsx +2 -2
  283. package/src/lib/plugins/openapi/util/methodColorMap.tsx +1 -1
  284. package/src/lib/ui/CodeBlock.tsx +1 -1
  285. package/src/lib/util/MdxComponents.tsx +13 -2
  286. package/src/lib/util/useScrollToAnchor.ts +3 -3
  287. package/dist/config/validators/InputSidebarSchema.d.ts +0 -220
  288. package/dist/config/validators/InputSidebarSchema.js +0 -63
  289. package/dist/config/validators/InputSidebarSchema.js.map +0 -1
  290. package/dist/config/validators/SidebarSchema.d.ts +0 -46
  291. package/dist/config/validators/SidebarSchema.js +0 -118
  292. package/dist/config/validators/SidebarSchema.js.map +0 -1
  293. package/dist/lib/components/navigation/Sidebar.d.ts +0 -5
  294. package/dist/lib/components/navigation/Sidebar.js +0 -10
  295. package/dist/lib/components/navigation/Sidebar.js.map +0 -1
  296. package/dist/lib/components/navigation/SidebarBadge.js.map +0 -1
  297. package/dist/lib/components/navigation/SidebarCategory.d.ts +0 -5
  298. package/dist/lib/components/navigation/SidebarCategory.js.map +0 -1
  299. package/dist/lib/components/navigation/SidebarItem.d.ts +0 -6
  300. package/dist/lib/components/navigation/SidebarItem.js +0 -44
  301. package/dist/lib/components/navigation/SidebarItem.js.map +0 -1
  302. package/dist/lib/components/navigation/SidebarWrapper.js.map +0 -1
  303. package/dist/lib/plugins/markdown/resolver.d.ts +0 -32
  304. package/dist/lib/plugins/markdown/resolver.js +0 -46
  305. package/dist/lib/plugins/markdown/resolver.js.map +0 -1
  306. package/dist/lib/plugins/openapi/util/createSidebarCategory.d.ts +0 -9
  307. package/dist/lib/plugins/openapi/util/createSidebarCategory.js.map +0 -1
  308. package/dist/vite/plugin-configure-tailwind.d.ts +0 -2
  309. package/dist/vite/plugin-configure-tailwind.js +0 -38
  310. package/dist/vite/plugin-configure-tailwind.js.map +0 -1
  311. package/dist/vite/plugin-sidebar.js.map +0 -1
  312. package/dist/vite/plugin-theme-css.d.ts +0 -5
  313. package/dist/vite/plugin-theme-css.js +0 -77
  314. package/dist/vite/plugin-theme-css.js.map +0 -1
  315. package/lib/Markdown-r4buN85T.js.map +0 -1
  316. package/lib/MdxPage-DYKsTerz.js.map +0 -1
  317. package/lib/OasProvider-8vNiLpIG.js +0 -33
  318. package/lib/OasProvider-8vNiLpIG.js.map +0 -1
  319. package/lib/SchemaList-1oJKvBxh.js.map +0 -1
  320. package/lib/hook-7wZANGJP.js +0 -1483
  321. package/lib/hook-7wZANGJP.js.map +0 -1
  322. package/lib/index-Cucjfk3D.js.map +0 -1
  323. package/lib/joinPath-B7kNnUX4.js +0 -8
  324. package/lib/joinPath-B7kNnUX4.js.map +0 -1
  325. package/src/lib/plugins/markdown/resolver.ts +0 -59
@@ -4,7 +4,7 @@ import { scrollIntoViewIfNeeded } from "../../util/scrollIntoViewIfNeeded.js";
4
4
  import { useZudoku } from "../context/ZudokuContext.js";
5
5
  import { PoweredByZudoku } from "./PoweredByZudoku.js";
6
6
 
7
- export const SidebarWrapper = ({
7
+ export const NavigationWrapper = ({
8
8
  children,
9
9
  className,
10
10
  }: PropsWithChildren<{
@@ -43,4 +43,4 @@ export const SidebarWrapper = ({
43
43
  );
44
44
  };
45
45
 
46
- SidebarWrapper.displayName = "SidebarWrapper";
46
+ NavigationWrapper.displayName = "NavigationWrapper";
@@ -1,38 +1,38 @@
1
1
  import { cva } from "class-variance-authority";
2
2
  import { useLocation } from "react-router";
3
3
  import type {
4
- SidebarItem,
5
- SidebarItemCategory,
6
- } from "../../../config/validators/SidebarSchema.js";
4
+ NavigationCategory,
5
+ NavigationItem,
6
+ } from "../../../config/validators/NavigationSchema.js";
7
7
  import { joinUrl } from "../../util/joinUrl.js";
8
8
  import { useCurrentNavigation } from "../context/ZudokuContext.js";
9
9
 
10
10
  export type TraverseCallback<T> = (
11
- item: SidebarItem,
12
- parentCategories: SidebarItem[],
11
+ item: NavigationItem,
12
+ parentCategories: NavigationItem[],
13
13
  ) => T | void;
14
14
 
15
- export const traverseSidebar = <T>(
16
- sidebar: SidebarItem[],
15
+ export const traverseNavigation = <T>(
16
+ navigation: NavigationItem[],
17
17
  callback: TraverseCallback<T>,
18
18
  ): T | undefined => {
19
- for (const item of sidebar) {
20
- const result = traverseSidebarItem(item, callback);
19
+ for (const item of navigation) {
20
+ const result = traverseNavigationItem(item, callback);
21
21
  if (result !== undefined) return result;
22
22
  }
23
23
  };
24
24
 
25
- export const traverseSidebarItem = <T>(
26
- item: SidebarItem,
25
+ export const traverseNavigationItem = <T>(
26
+ item: NavigationItem,
27
27
  callback: TraverseCallback<T>,
28
- parentCategories: SidebarItem[] = [],
28
+ parentCategories: NavigationItem[] = [],
29
29
  ): T | undefined => {
30
30
  const result = callback(item, parentCategories);
31
31
  if (result !== undefined) return result;
32
32
 
33
33
  if (item.type === "category") {
34
34
  for (const child of item.items) {
35
- const childResult = traverseSidebarItem(child, callback, [
35
+ const childResult = traverseNavigationItem(child, callback, [
36
36
  ...parentCategories,
37
37
  item,
38
38
  ]);
@@ -43,30 +43,28 @@ export const traverseSidebarItem = <T>(
43
43
 
44
44
  export const useCurrentItem = () => {
45
45
  const location = useLocation();
46
- const nav = useCurrentNavigation();
46
+ const { navigation } = useCurrentNavigation();
47
47
 
48
- const currentSidebar = nav.sidebar;
49
-
50
- return traverseSidebar(currentSidebar, (item) => {
51
- if (item.type === "doc" && joinUrl(item.id) === location.pathname) {
48
+ return traverseNavigation(navigation, (item) => {
49
+ if (item.type === "doc" && joinUrl(item.path) === location.pathname) {
52
50
  return item;
53
51
  }
54
52
  });
55
53
  };
56
54
 
57
- export const useIsCategoryOpen = (category: SidebarItemCategory) => {
55
+ export const useIsCategoryOpen = (category: NavigationCategory) => {
58
56
  const location = useLocation();
59
57
 
60
- return traverseSidebarItem(category, (item) => {
58
+ return traverseNavigationItem(category, (item) => {
61
59
  if (item.type === "category" && item.link) {
62
- const categoryLinkPath = joinUrl(item.link.id);
60
+ const categoryLinkPath = joinUrl(item.link.path);
63
61
  if (categoryLinkPath === location.pathname) {
64
62
  return true;
65
63
  }
66
64
  }
67
65
 
68
66
  if (item.type === "doc") {
69
- const docPath = joinUrl(item.id);
67
+ const docPath = joinUrl(item.path);
70
68
  if (docPath === location.pathname) {
71
69
  return true;
72
70
  }
@@ -79,20 +77,19 @@ export const usePrevNext = (): {
79
77
  next?: { label: string; id: string };
80
78
  } => {
81
79
  const currentId = useLocation().pathname;
82
- const nav = useCurrentNavigation();
83
- const currentSidebar = nav.sidebar;
80
+ const { navigation } = useCurrentNavigation();
84
81
 
85
82
  let prev;
86
83
  let next;
87
84
 
88
85
  let foundCurrent = false;
89
86
 
90
- traverseSidebar(currentSidebar, (item) => {
87
+ traverseNavigation(navigation, (item) => {
91
88
  const itemId =
92
89
  item.type === "doc"
93
- ? joinUrl(item.id)
90
+ ? joinUrl(item.path)
94
91
  : item.type === "category" && item.link
95
- ? joinUrl(item.link.id)
92
+ ? joinUrl(item.link.path)
96
93
  : undefined;
97
94
 
98
95
  if (!itemId) return;
@@ -137,8 +134,10 @@ export const navigationListItem = cva(
137
134
 
138
135
  export const isHiddenItem =
139
136
  (isAuthenticated?: boolean) =>
140
- (item: { display?: "auth" | "anon" | "always" | "hide" }): boolean => {
137
+ (item: NavigationItem): boolean => {
141
138
  if (item.display === "hide") return false;
139
+ if (!item.label) return false;
140
+
142
141
  return (
143
142
  (item.display === "auth" && isAuthenticated) ||
144
143
  (item.display === "anon" && !isAuthenticated) ||
@@ -3,17 +3,14 @@ import { createNanoEvents } from "nanoevents";
3
3
  import type { ReactNode } from "react";
4
4
  import type { Location } from "react-router";
5
5
  import type { BundledTheme, HighlighterCore } from "shiki";
6
- import type { z } from "zod";
7
- import type { SidebarConfig } from "../../config/validators/SidebarSchema.js";
8
- import type {
9
- FooterSchema,
10
- TopNavigationItem,
11
- } from "../../config/validators/validate.js";
6
+ import type { z } from "zod/v4";
7
+ import type { Navigation } from "../../config/validators/NavigationSchema.js";
8
+ import type { FooterSchema } from "../../config/validators/validate.js";
12
9
  import type { AuthenticationPlugin } from "../authentication/authentication.js";
13
10
  import { type AuthState, useAuthState } from "../authentication/state.js";
14
11
  import type { ComponentsContextType } from "../components/context/ComponentsContext.js";
15
12
  import type { SlotType } from "../components/context/SlotProvider.js";
16
- import { joinPath } from "../util/joinPath.js";
13
+ import { joinUrl } from "../util/joinUrl.js";
17
14
  import type { MdxComponentsType } from "../util/MdxComponents.js";
18
15
  import { objectEntries } from "../util/objectEntries.js";
19
16
  import {
@@ -83,8 +80,7 @@ export type ZudokuContextOptions = {
83
80
  metadata?: Metadata;
84
81
  page?: Page;
85
82
  authentication?: AuthenticationPlugin;
86
- topNavigation?: TopNavigationItem[];
87
- sidebars?: SidebarConfig;
83
+ navigation?: Navigation;
88
84
  plugins?: ZudokuPlugin[];
89
85
  slots?: Record<string, SlotType>;
90
86
  /**
@@ -104,8 +100,7 @@ export type ZudokuContextOptions = {
104
100
 
105
101
  export class ZudokuContext {
106
102
  public plugins: NonNullable<ZudokuContextOptions["plugins"]>;
107
- public sidebars: SidebarConfig;
108
- public topNavigation: NonNullable<ZudokuContextOptions["topNavigation"]>;
103
+ public navigation: Navigation;
109
104
  public meta: ZudokuContextOptions["metadata"];
110
105
  public page: ZudokuContextOptions["page"];
111
106
  public readonly authentication?: ZudokuContextOptions["authentication"];
@@ -124,8 +119,7 @@ export class ZudokuContext {
124
119
  this.queryClient = queryClient;
125
120
  this.options = { ...options, protectedRoutes };
126
121
  this.plugins = options.plugins ?? [];
127
- this.topNavigation = options.topNavigation ?? [];
128
- this.sidebars = options.sidebars ?? {};
122
+ this.navigation = options.navigation ?? [];
129
123
  this.navigationPlugins = this.plugins.filter(isNavigationPlugin);
130
124
  this.authentication = this.plugins.find(isAuthenticationPlugin);
131
125
  this.meta = options.metadata;
@@ -178,10 +172,10 @@ export class ZudokuContext {
178
172
  return this.emitter.emit(event, ...data);
179
173
  };
180
174
 
181
- getPluginSidebar = async (path: string) => {
175
+ getPluginNavigation = async (path: string) => {
182
176
  const navigations = await Promise.all(
183
177
  this.navigationPlugins.map((plugin) =>
184
- plugin.getSidebar?.(joinPath(path), this),
178
+ plugin.getNavigation?.(joinUrl(path), this),
185
179
  ),
186
180
  );
187
181
 
@@ -1,7 +1,7 @@
1
1
  import type { LucideIcon } from "lucide-react";
2
2
  import type { ReactElement } from "react";
3
3
  import type { Location, RouteObject } from "react-router";
4
- import type { Sidebar } from "../../config/validators/SidebarSchema.js";
4
+ import type { Navigation } from "../../config/validators/NavigationSchema.js";
5
5
  import type { AuthenticationPlugin } from "../authentication/authentication.js";
6
6
  import type { MdxComponentsType } from "../util/MdxComponents.js";
7
7
  import type {
@@ -23,7 +23,7 @@ export type { AuthenticationPlugin, RouteObject };
23
23
 
24
24
  export interface NavigationPlugin {
25
25
  getRoutes: () => RouteObject[];
26
- getSidebar?: (path: string, context: ZudokuContext) => Promise<Sidebar>;
26
+ getNavigation?: (path: string, context: ZudokuContext) => Promise<Navigation>;
27
27
  getProtectedRoutes?: () => string[];
28
28
  }
29
29
 
@@ -116,11 +116,13 @@ describe("useEvent", () => {
116
116
  describe("types", () => {
117
117
  const { wrapper } = createTestContext();
118
118
 
119
- it("infers event type when no callback is provided", () => {
120
- const hook = renderHook(() => useEvent("location"), { wrapper });
121
- assertType<Parameters<ZudokuEvents["location"]> | undefined>(
122
- hook.result.current,
123
- );
119
+ it("infers event type when no callback is provided", async () => {
120
+ await act(async () => {
121
+ const hook = renderHook(() => useEvent("location"), { wrapper });
122
+ assertType<Parameters<ZudokuEvents["location"]> | undefined>(
123
+ hook.result.current,
124
+ );
125
+ });
124
126
  });
125
127
 
126
128
  it("infers string type from pathname callback", () => {
@@ -13,7 +13,7 @@ export const Catalog = ({
13
13
  filterCatalogItems = (items) => items,
14
14
  label = "API Library",
15
15
  categoryLabel,
16
- }: Omit<ApiCatalogPluginOptions, "navigationId"> & {
16
+ }: Omit<ApiCatalogPluginOptions, "path"> & {
17
17
  categoryLabel?: string;
18
18
  }) => {
19
19
  const auth = useAuthState();
@@ -1,6 +1,6 @@
1
1
  import slugify from "@sindresorhus/slugify";
2
2
  import { matchPath } from "react-router";
3
- import type { SidebarItem } from "../../../config/validators/SidebarSchema.js";
3
+ import type { NavigationItem } from "../../../config/validators/NavigationSchema.js";
4
4
  import type { AuthState } from "../../authentication/state.js";
5
5
  import type { ZudokuPlugin } from "../../core/plugins.js";
6
6
  import { joinUrl } from "../../util/joinUrl.js";
@@ -22,46 +22,46 @@ export type CatalogCategory = {
22
22
  };
23
23
 
24
24
  export type ApiCatalogPluginOptions = {
25
- navigationId: string;
25
+ path: string;
26
26
  label: string;
27
27
  categories?: CatalogCategory[];
28
28
  items: ApiCatalogItem[];
29
- filterCatalogItems?: filterCatalogItems;
29
+ filterCatalogItems?: FilterCatalogItemsFn;
30
30
  };
31
31
 
32
32
  export type CatalogContext<ProviderData = unknown> = {
33
33
  auth: AuthState<ProviderData>;
34
34
  };
35
35
 
36
- export type filterCatalogItems<ProviderData = unknown> = (
36
+ export type FilterCatalogItemsFn<ProviderData = unknown> = (
37
37
  items: ApiCatalogItem[],
38
38
  { auth }: CatalogContext<ProviderData>,
39
39
  ) => ApiCatalogItem[];
40
40
 
41
41
  export const apiCatalogPlugin = ({
42
- navigationId,
42
+ path,
43
43
  items,
44
44
  label,
45
45
  categories = [],
46
46
  filterCatalogItems,
47
47
  }: {
48
- navigationId: string;
48
+ path: string;
49
49
  label: string;
50
50
  categories?: CatalogCategory[];
51
51
  items: ApiCatalogItem[];
52
- filterCatalogItems?: filterCatalogItems;
52
+ filterCatalogItems?: FilterCatalogItemsFn;
53
53
  }): ZudokuPlugin => {
54
54
  const paths = Object.fromEntries(
55
55
  categories.flatMap((category) =>
56
56
  [undefined, ...category.tags].map((tag) => [
57
- joinUrl(navigationId, tag ? getKey(category.label, tag) : undefined),
57
+ joinUrl(path, tag ? getKey(category.label, tag) : undefined),
58
58
  tag,
59
59
  ]),
60
60
  ),
61
61
  );
62
62
 
63
63
  return {
64
- getSidebar: async (currentPath) => {
64
+ getNavigation: async (currentPath) => {
65
65
  const matches = Object.keys(paths).some((path) =>
66
66
  matchPath(path, currentPath),
67
67
  );
@@ -70,13 +70,13 @@ export const apiCatalogPlugin = ({
70
70
  return [];
71
71
  }
72
72
 
73
- const sidebar: SidebarItem[] = categories.map((category) => ({
74
- type: "category" as const,
73
+ const navigation: NavigationItem[] = categories.map((category) => ({
74
+ type: "category",
75
75
  label: category.label,
76
76
  collapsible: false,
77
77
  items: category.tags.map((tag) => ({
78
- type: "doc" as const,
79
- id: joinUrl(navigationId, getKey(category.label, tag)),
78
+ type: "link",
79
+ to: joinUrl(path, getKey(category.label, tag)),
80
80
  label: tag,
81
81
  badge: {
82
82
  label: String(
@@ -84,19 +84,19 @@ export const apiCatalogPlugin = ({
84
84
  api.categories.find((c) => c.tags.includes(tag)),
85
85
  ).length,
86
86
  ),
87
- color: "outline" as const,
87
+ color: "outline",
88
88
  },
89
89
  })),
90
90
  }));
91
91
 
92
- sidebar.unshift({
93
- type: "doc" as const,
94
- id: joinUrl(navigationId),
92
+ navigation.unshift({
93
+ type: "link",
94
+ to: joinUrl(path),
95
95
  label: "Overview",
96
- badge: { label: String(items.length), color: "outline" as const },
96
+ badge: { label: String(items.length), color: "outline" },
97
97
  });
98
98
 
99
- return sidebar;
99
+ return navigation;
100
100
  },
101
101
  getRoutes: () =>
102
102
  Object.entries(paths).map(([path, tag]) => ({
@@ -10,7 +10,7 @@ import {
10
10
  EyeIcon,
11
11
  EyeOffIcon,
12
12
  PencilLineIcon,
13
- RotateCwIcon,
13
+ RefreshCwIcon,
14
14
  TrashIcon,
15
15
  XIcon,
16
16
  } from "lucide-react";
@@ -278,35 +278,39 @@ export const SettingsApiKeys = ({ service }: { service: ApiKeyService }) => {
278
278
  <div className="flex justify-end">
279
279
  {service.updateConsumer && (
280
280
  <Button
281
- size="icon"
282
281
  variant="ghost"
283
282
  onClick={() =>
284
283
  handleStartEdit(consumers.id, consumers.label)
285
284
  }
286
285
  className={cn(
286
+ "flex gap-2",
287
287
  editingConsumerId === consumers.id &&
288
288
  "opacity-0! pointer-events-none",
289
289
  )}
290
290
  disabled={editingConsumerId === consumers.id}
291
291
  >
292
292
  <PencilLineIcon size={16} />
293
+ Edit label
293
294
  </Button>
294
295
  )}
295
296
  {service.rollKey && (
296
297
  <Dialog>
297
298
  <DialogTrigger asChild>
298
299
  <Button
299
- size="icon"
300
300
  title="Roll this key"
301
301
  variant="ghost"
302
302
  disabled={rollKeyMutation.isPending}
303
- className={
304
- rollKeyMutation.isPending
305
- ? "animate-spin"
306
- : undefined
307
- }
303
+ className="flex items-center gap-2"
308
304
  >
309
- <RotateCwIcon size={16} />
305
+ <RefreshCwIcon
306
+ size={16}
307
+ className={
308
+ rollKeyMutation.isPending
309
+ ? "animate-spin"
310
+ : undefined
311
+ }
312
+ />
313
+ Roll key
310
314
  </Button>
311
315
  </DialogTrigger>
312
316
  <DialogContent>
@@ -473,7 +477,7 @@ const RevealApiKey = ({
473
477
  </div>
474
478
  </div>
475
479
  <div className="flex justify-end">
476
- {isExpired && onDeleteKey && (
480
+ {expiresOn && onDeleteKey && (
477
481
  <Dialog>
478
482
  <DialogTrigger asChild>
479
483
  <Button variant="ghost" size="icon">
@@ -1,6 +1,8 @@
1
1
  import { type ComponentType, type ReactNode } from "react";
2
2
  import type { RouteObject } from "react-router";
3
- import type { NavigationPlugin, ZudokuPlugin } from "../../core/plugins.js";
3
+ import type { NavigationItem } from "../../../config/validators/NavigationSchema.js";
4
+ import { traverseNavigation } from "../../components/navigation/utils.js";
5
+ import type { NavigationPlugin } from "../../core/plugins.js";
4
6
  import type { ExposedComponentProps } from "../../util/useExposedProps.js";
5
7
  import { CustomPage } from "./CustomPage.js";
6
8
 
@@ -12,13 +14,20 @@ export type CustomPageConfig = {
12
14
  };
13
15
 
14
16
  export const customPagesPlugin = (
15
- config: CustomPageConfig[],
16
- ): ZudokuPlugin & NavigationPlugin => {
17
- return {
18
- getRoutes: (): RouteObject[] =>
19
- config.map(({ path, ...props }) => ({
20
- path,
21
- element: <CustomPage {...props} />,
22
- })),
23
- };
24
- };
17
+ navigation: NavigationItem[] = [],
18
+ ): NavigationPlugin => ({
19
+ getRoutes: (): RouteObject[] => {
20
+ const customPages: RouteObject[] = [];
21
+
22
+ traverseNavigation(navigation, (item) => {
23
+ if (item.type === "custom-page") {
24
+ customPages.push({
25
+ path: item.path,
26
+ element: <CustomPage {...item} />,
27
+ });
28
+ }
29
+ });
30
+
31
+ return customPages;
32
+ },
33
+ });
@@ -25,12 +25,12 @@ declare global {
25
25
 
26
26
  const MarkdownHeadings = {
27
27
  h2: ({ children, id }) => (
28
- <Heading level={2} id={id} registerSidebarAnchor>
28
+ <Heading level={2} id={id} registerNavigationAnchor>
29
29
  {children}
30
30
  </Heading>
31
31
  ),
32
32
  h3: ({ children, id }) => (
33
- <Heading level={3} id={id} registerSidebarAnchor>
33
+ <Heading level={3} id={id} registerNavigationAnchor>
34
34
  {children}
35
35
  </Heading>
36
36
  ),
@@ -58,7 +58,10 @@ export const MdxPage = ({
58
58
  const pageTitle =
59
59
  tableOfContents.find((item) => item.depth === 1)?.value ?? title;
60
60
  const hidePager =
61
- frontmatter.disablePager ?? defaultOptions?.disablePager ?? false;
61
+ frontmatter.disable_pager ??
62
+ frontmatter.disablePager ??
63
+ defaultOptions?.disablePager ??
64
+ false;
62
65
 
63
66
  const tocEntries =
64
67
  tableOfContents.find((item) => item.depth === 1)?.children ??
@@ -1,10 +1,8 @@
1
1
  import type { Toc } from "@stefanprobst/rehype-extract-toc";
2
2
  import type { MDXProps } from "mdx/types.js";
3
3
  import { type JSX } from "react";
4
- import type { RouteObject } from "react-router";
5
4
  import type { ZudokuDocsConfig } from "../../../config/validators/validate.js";
6
5
  import type { ZudokuPlugin } from "../../core/plugins.js";
7
- import { DocResolver } from "./resolver.js";
8
6
 
9
7
  export interface MarkdownPluginOptions extends ZudokuDocsConfig {
10
8
  fileImports: Record<string, () => Promise<MDXImport>>;
@@ -20,6 +18,7 @@ export type Frontmatter = {
20
18
  category?: string;
21
19
  toc?: boolean;
22
20
  disablePager?: boolean;
21
+ disable_pager?: boolean;
23
22
  };
24
23
 
25
24
  export type MDXImport = {
@@ -30,47 +29,27 @@ export type MDXImport = {
30
29
  };
31
30
 
32
31
  export const markdownPlugin = (
33
- options: MarkdownPluginOptions[],
32
+ options: MarkdownPluginOptions,
34
33
  ): ZudokuPlugin => ({
35
34
  getRoutes: () => {
36
- const routeMap = new Map<string, RouteObject>();
37
- options.forEach(({ fileImports, files, defaultOptions }) =>
38
- Object.entries(fileImports).flatMap(([file, importPromise]) => {
39
- const routePath = DocResolver.resolveRoutePath({
40
- filesGlob: files,
41
- fsPath: file,
42
- });
43
-
44
- if (!routePath) return [];
45
-
46
- if (routeMap.has(routePath)) {
47
- // eslint-disable-next-line no-console
48
- console.warn(
49
- `Duplicate route path found for ${routePath}. Skipping file at '${file}'.`,
50
- );
51
- return [];
52
- }
53
-
54
- const route: RouteObject = {
55
- path: routePath,
56
- lazy: async () => {
57
- const { MdxPage } = await import("./MdxPage.js");
58
- const { default: Component, ...props } = await importPromise();
59
- return {
60
- element: (
61
- <MdxPage
62
- file={file}
63
- mdxComponent={Component}
64
- {...props}
65
- defaultOptions={defaultOptions}
66
- />
67
- ),
68
- };
69
- },
70
- };
71
- routeMap.set(routePath, route);
35
+ return Object.entries(options.fileImports).map(
36
+ ([routePath, importPromise]) => ({
37
+ path: routePath,
38
+ lazy: async () => {
39
+ const { MdxPage } = await import("./MdxPage.js");
40
+ const { default: Component, ...props } = await importPromise();
41
+ return {
42
+ element: (
43
+ <MdxPage
44
+ file={routePath}
45
+ mdxComponent={Component}
46
+ {...props}
47
+ defaultOptions={options.defaultOptions}
48
+ />
49
+ ),
50
+ };
51
+ },
72
52
  }),
73
53
  );
74
- return [...routeMap.values()];
75
54
  },
76
55
  });
@@ -241,7 +241,7 @@ export const OperationList = ({
241
241
  <Heading
242
242
  level={1}
243
243
  id="description"
244
- registerSidebarAnchor
244
+ registerNavigationAnchor
245
245
  className="mb-0"
246
246
  >
247
247
  {schema.tag.name ?? "Other endpoints"}
@@ -53,7 +53,7 @@ export const OperationListItem = ({
53
53
  <Heading
54
54
  level={2}
55
55
  id={operation.slug}
56
- registerSidebarAnchor
56
+ registerNavigationAnchor
57
57
  className="break-all col-span-full"
58
58
  >
59
59
  {operation.summary}
@@ -83,7 +83,7 @@ export function SchemaList() {
83
83
  <Heading
84
84
  level={1}
85
85
  id="schemas"
86
- registerSidebarAnchor
86
+ registerNavigationAnchor
87
87
  className="mb-0"
88
88
  >
89
89
  Schemas
@@ -129,7 +129,7 @@ export function SchemaList() {
129
129
  {schemas.map((schema) => (
130
130
  <Collapsible key={schema.name} className="group" defaultOpen>
131
131
  <Heading
132
- registerSidebarAnchor
132
+ registerNavigationAnchor
133
133
  level={2}
134
134
  className="flex items-center gap-1 justify-between w-fit"
135
135
  id={slugify(schema.name)}
@@ -19,7 +19,7 @@ type Documents = {
19
19
  "\n query OperationsForTag(\n $input: JSON!\n $type: SchemaType!\n $tag: String\n $untagged: Boolean\n ) {\n schema(input: $input, type: $type) {\n servers {\n url\n }\n description\n summary\n title\n url\n version\n tag(slug: $tag, untagged: $untagged) {\n name\n description\n operations {\n slug\n ...OperationsFragment\n }\n next {\n name\n slug\n }\n prev {\n name\n slug\n }\n }\n }\n }\n": typeof types.OperationsForTagDocument;
20
20
  "\n query GetSchemas($input: JSON!, $type: SchemaType!) {\n schema(input: $input, type: $type) {\n title\n description\n summary\n components {\n schemas {\n name\n schema\n extensions\n }\n }\n }\n }\n": typeof types.GetSchemasDocument;
21
21
  "\n query getServerQuery($input: JSON!, $type: SchemaType!) {\n schema(input: $input, type: $type) {\n url\n servers {\n url\n }\n }\n }\n": typeof types.GetServerQueryDocument;
22
- "\n query GetSidebarOperations($input: JSON!, $type: SchemaType!) {\n schema(input: $input, type: $type) {\n tags {\n slug\n name\n extensions\n operations {\n summary\n slug\n method\n operationId\n path\n }\n }\n components {\n schemas {\n __typename\n }\n }\n }\n }\n": typeof types.GetSidebarOperationsDocument;
22
+ "\n query GetNavigationOperations($input: JSON!, $type: SchemaType!) {\n schema(input: $input, type: $type) {\n tags {\n slug\n name\n extensions\n operations {\n summary\n slug\n method\n operationId\n path\n }\n }\n components {\n schemas {\n __typename\n }\n }\n }\n }\n": typeof types.GetNavigationOperationsDocument;
23
23
  };
24
24
  const documents: Documents = {
25
25
  "\n query ServersQuery($input: JSON!, $type: SchemaType!) {\n schema(input: $input, type: $type) {\n url\n servers {\n url\n }\n }\n }\n":
@@ -34,8 +34,8 @@ const documents: Documents = {
34
34
  types.GetSchemasDocument,
35
35
  "\n query getServerQuery($input: JSON!, $type: SchemaType!) {\n schema(input: $input, type: $type) {\n url\n servers {\n url\n }\n }\n }\n":
36
36
  types.GetServerQueryDocument,
37
- "\n query GetSidebarOperations($input: JSON!, $type: SchemaType!) {\n schema(input: $input, type: $type) {\n tags {\n slug\n name\n extensions\n operations {\n summary\n slug\n method\n operationId\n path\n }\n }\n components {\n schemas {\n __typename\n }\n }\n }\n }\n":
38
- types.GetSidebarOperationsDocument,
37
+ "\n query GetNavigationOperations($input: JSON!, $type: SchemaType!) {\n schema(input: $input, type: $type) {\n tags {\n slug\n name\n extensions\n operations {\n summary\n slug\n method\n operationId\n path\n }\n }\n components {\n schemas {\n __typename\n }\n }\n }\n }\n":
38
+ types.GetNavigationOperationsDocument,
39
39
  };
40
40
 
41
41
  /**
@@ -78,8 +78,8 @@ export function graphql(
78
78
  * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.
79
79
  */
80
80
  export function graphql(
81
- source: "\n query GetSidebarOperations($input: JSON!, $type: SchemaType!) {\n schema(input: $input, type: $type) {\n tags {\n slug\n name\n extensions\n operations {\n summary\n slug\n method\n operationId\n path\n }\n }\n components {\n schemas {\n __typename\n }\n }\n }\n }\n",
82
- ): typeof import("./graphql.js").GetSidebarOperationsDocument;
81
+ source: "\n query GetNavigationOperations($input: JSON!, $type: SchemaType!) {\n schema(input: $input, type: $type) {\n tags {\n slug\n name\n extensions\n operations {\n summary\n slug\n method\n operationId\n path\n }\n }\n components {\n schemas {\n __typename\n }\n }\n }\n }\n",
82
+ ): typeof import("./graphql.js").GetNavigationOperationsDocument;
83
83
 
84
84
  export function graphql(source: string) {
85
85
  return (documents as any)[source] ?? {};