zudoku 0.38.0 → 0.39.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 (269) hide show
  1. package/dist/app/entry.server.d.ts +5 -4
  2. package/dist/app/entry.server.js +2 -2
  3. package/dist/app/entry.server.js.map +1 -1
  4. package/dist/app/tailwind.js +14 -0
  5. package/dist/app/tailwind.js.map +1 -1
  6. package/dist/cli/cmds/dev.js +1 -7
  7. package/dist/cli/cmds/dev.js.map +1 -1
  8. package/dist/config/validators/common.d.ts +17 -0
  9. package/dist/config/validators/common.js +1 -0
  10. package/dist/config/validators/common.js.map +1 -1
  11. package/dist/config/validators/validate.d.ts +7 -0
  12. package/dist/lib/components/Bootstrap.d.ts +2 -1
  13. package/dist/lib/components/Bootstrap.js +3 -2
  14. package/dist/lib/components/Bootstrap.js.map +1 -1
  15. package/dist/lib/components/Header.js +2 -2
  16. package/dist/lib/components/Header.js.map +1 -1
  17. package/dist/lib/components/Heading.d.ts +1 -1
  18. package/dist/lib/components/Layout.js +2 -9
  19. package/dist/lib/components/Layout.js.map +1 -1
  20. package/dist/lib/components/Main.js +3 -1
  21. package/dist/lib/components/Main.js.map +1 -1
  22. package/dist/lib/components/MobileTopNavigation.js +6 -3
  23. package/dist/lib/components/MobileTopNavigation.js.map +1 -1
  24. package/dist/lib/components/Pagination.d.ts +10 -0
  25. package/dist/lib/components/Pagination.js +10 -0
  26. package/dist/lib/components/Pagination.js.map +1 -0
  27. package/dist/lib/components/TopNavigation.d.ts +1 -0
  28. package/dist/lib/components/TopNavigation.js +18 -2
  29. package/dist/lib/components/TopNavigation.js.map +1 -1
  30. package/dist/lib/components/Zudoku.js +4 -1
  31. package/dist/lib/components/Zudoku.js.map +1 -1
  32. package/dist/lib/components/context/BypassProtectedRoutesContext.d.ts +1 -0
  33. package/dist/lib/components/context/BypassProtectedRoutesContext.js +3 -0
  34. package/dist/lib/components/context/BypassProtectedRoutesContext.js.map +1 -0
  35. package/dist/lib/components/index.d.ts +2 -1
  36. package/dist/lib/components/navigation/PoweredByZudoku.d.ts +3 -0
  37. package/dist/lib/components/navigation/PoweredByZudoku.js +6 -0
  38. package/dist/lib/components/navigation/PoweredByZudoku.js.map +1 -0
  39. package/dist/lib/components/navigation/SidebarItem.d.ts +1 -0
  40. package/dist/lib/components/navigation/SidebarItem.js +7 -3
  41. package/dist/lib/components/navigation/SidebarItem.js.map +1 -1
  42. package/dist/lib/components/navigation/SidebarWrapper.js +9 -2
  43. package/dist/lib/components/navigation/SidebarWrapper.js.map +1 -1
  44. package/dist/lib/{plugins/markdown → components/navigation}/Toc.js +5 -7
  45. package/dist/lib/components/navigation/Toc.js.map +1 -0
  46. package/dist/lib/components/navigation/ZudokuLogo.d.ts +6 -0
  47. package/dist/lib/components/navigation/ZudokuLogo.js +5 -0
  48. package/dist/lib/components/navigation/ZudokuLogo.js.map +1 -0
  49. package/dist/lib/core/RouteGuard.d.ts +1 -0
  50. package/dist/lib/core/RouteGuard.js +9 -3
  51. package/dist/lib/core/RouteGuard.js.map +1 -1
  52. package/dist/lib/core/ZudokuContext.d.ts +1 -0
  53. package/dist/lib/core/ZudokuContext.js.map +1 -1
  54. package/dist/lib/oas/graphql/index.d.ts +2 -1
  55. package/dist/lib/oas/graphql/index.js +74 -14
  56. package/dist/lib/oas/graphql/index.js.map +1 -1
  57. package/dist/lib/oas/parser/dereference/index.js +2 -0
  58. package/dist/lib/oas/parser/dereference/index.js.map +1 -1
  59. package/dist/lib/oas/parser/index.d.ts +5 -3
  60. package/dist/lib/oas/parser/index.js +0 -22
  61. package/dist/lib/oas/parser/index.js.map +1 -1
  62. package/dist/lib/plugins/api-catalog/index.js +19 -17
  63. package/dist/lib/plugins/api-catalog/index.js.map +1 -1
  64. package/dist/lib/plugins/markdown/MdxPage.js +3 -3
  65. package/dist/lib/plugins/markdown/MdxPage.js.map +1 -1
  66. package/dist/lib/plugins/openapi/ColorizedParam.js +1 -1
  67. package/dist/lib/plugins/openapi/ColorizedParam.js.map +1 -1
  68. package/dist/lib/plugins/openapi/OperationList.d.ts +1 -1
  69. package/dist/lib/plugins/openapi/OperationList.js +28 -8
  70. package/dist/lib/plugins/openapi/OperationList.js.map +1 -1
  71. package/dist/lib/plugins/openapi/OperationListItem.js +1 -1
  72. package/dist/lib/plugins/openapi/OperationListItem.js.map +1 -1
  73. package/dist/lib/plugins/openapi/ParameterListItem.js +2 -1
  74. package/dist/lib/plugins/openapi/ParameterListItem.js.map +1 -1
  75. package/dist/lib/plugins/openapi/SchemaList.d.ts +1 -0
  76. package/dist/lib/plugins/openapi/SchemaList.js +52 -0
  77. package/dist/lib/plugins/openapi/SchemaList.js.map +1 -0
  78. package/dist/lib/plugins/openapi/client/GraphQLClient.d.ts +1 -1
  79. package/dist/lib/plugins/openapi/client/GraphQLClient.js +1 -1
  80. package/dist/lib/plugins/openapi/client/GraphQLClient.js.map +1 -1
  81. package/dist/lib/plugins/openapi/client/useCreateQuery.d.ts +6 -2
  82. package/dist/lib/plugins/openapi/client/useCreateQuery.js +5 -5
  83. package/dist/lib/plugins/openapi/client/useCreateQuery.js.map +1 -1
  84. package/dist/lib/plugins/openapi/components/EnumValues.js +1 -1
  85. package/dist/lib/plugins/openapi/components/EnumValues.js.map +1 -1
  86. package/dist/lib/plugins/openapi/graphql/gql.d.ts +6 -2
  87. package/dist/lib/plugins/openapi/graphql/gql.js +3 -2
  88. package/dist/lib/plugins/openapi/graphql/gql.js.map +1 -1
  89. package/dist/lib/plugins/openapi/graphql/graphql.d.ts +67 -11
  90. package/dist/lib/plugins/openapi/graphql/graphql.js +34 -5
  91. package/dist/lib/plugins/openapi/graphql/graphql.js.map +1 -1
  92. package/dist/lib/plugins/openapi/index.js +12 -0
  93. package/dist/lib/plugins/openapi/index.js.map +1 -1
  94. package/dist/lib/plugins/openapi/schema/LogicalGroup/LogicalGroup.d.ts +1 -2
  95. package/dist/lib/plugins/openapi/schema/LogicalGroup/LogicalGroup.js +2 -2
  96. package/dist/lib/plugins/openapi/schema/LogicalGroup/LogicalGroup.js.map +1 -1
  97. package/dist/lib/plugins/openapi/schema/LogicalGroup/LogicalGroupConnector.d.ts +2 -1
  98. package/dist/lib/plugins/openapi/schema/LogicalGroup/LogicalGroupConnector.js +2 -2
  99. package/dist/lib/plugins/openapi/schema/LogicalGroup/LogicalGroupConnector.js.map +1 -1
  100. package/dist/lib/plugins/openapi/schema/LogicalGroup/LogicalGroupItem.d.ts +0 -1
  101. package/dist/lib/plugins/openapi/schema/LogicalGroup/LogicalGroupItem.js +1 -1
  102. package/dist/lib/plugins/openapi/schema/LogicalGroup/LogicalGroupItem.js.map +1 -1
  103. package/dist/lib/plugins/openapi/schema/SchemaExampleAndDefault.d.ts +4 -0
  104. package/dist/lib/plugins/openapi/schema/SchemaExampleAndDefault.js +12 -0
  105. package/dist/lib/plugins/openapi/schema/SchemaExampleAndDefault.js.map +1 -0
  106. package/dist/lib/plugins/openapi/schema/SchemaPropertyItem.d.ts +2 -4
  107. package/dist/lib/plugins/openapi/schema/SchemaPropertyItem.js +12 -9
  108. package/dist/lib/plugins/openapi/schema/SchemaPropertyItem.js.map +1 -1
  109. package/dist/lib/plugins/openapi/schema/SchemaView.d.ts +1 -2
  110. package/dist/lib/plugins/openapi/schema/SchemaView.js +30 -52
  111. package/dist/lib/plugins/openapi/schema/SchemaView.js.map +1 -1
  112. package/dist/lib/plugins/openapi/schema/utils.d.ts +1 -0
  113. package/dist/lib/plugins/openapi/schema/utils.js +3 -1
  114. package/dist/lib/plugins/openapi/schema/utils.js.map +1 -1
  115. package/dist/lib/plugins/openapi/util/getRoutes.js +9 -3
  116. package/dist/lib/plugins/openapi/util/getRoutes.js.map +1 -1
  117. package/dist/lib/plugins/search-pagefind/PagefindSearch.js +9 -4
  118. package/dist/lib/plugins/search-pagefind/PagefindSearch.js.map +1 -1
  119. package/dist/lib/plugins/search-pagefind/ResultList.d.ts +1 -1
  120. package/dist/lib/plugins/search-pagefind/ResultList.js +6 -12
  121. package/dist/lib/plugins/search-pagefind/ResultList.js.map +1 -1
  122. package/dist/lib/plugins/search-pagefind/index.d.ts +1 -3
  123. package/dist/lib/util/useOnScreen.d.ts +3 -2
  124. package/dist/lib/util/useOnScreen.js +3 -3
  125. package/dist/lib/util/useOnScreen.js.map +1 -1
  126. package/dist/vite/api/schema-codegen.js +2 -2
  127. package/dist/vite/api/schema-codegen.js.map +1 -1
  128. package/dist/vite/api/schema-codegen.test.js +5 -0
  129. package/dist/vite/api/schema-codegen.test.js.map +1 -1
  130. package/dist/vite/build.js +1 -9
  131. package/dist/vite/build.js.map +1 -1
  132. package/dist/vite/plugin-api.js +8 -7
  133. package/dist/vite/plugin-api.js.map +1 -1
  134. package/dist/vite/plugin-search.js +1 -1
  135. package/dist/vite/plugin-search.js.map +1 -1
  136. package/dist/vite/prerender/FileWritingResponse.d.ts +9 -5
  137. package/dist/vite/prerender/FileWritingResponse.js +5 -5
  138. package/dist/vite/prerender/FileWritingResponse.js.map +1 -1
  139. package/dist/vite/prerender/InMemoryResponse.d.ts +16 -0
  140. package/dist/vite/prerender/InMemoryResponse.js +32 -0
  141. package/dist/vite/prerender/InMemoryResponse.js.map +1 -0
  142. package/dist/vite/prerender/PrerenderResponse.d.ts +10 -0
  143. package/dist/vite/prerender/PrerenderResponse.js +2 -0
  144. package/dist/vite/prerender/PrerenderResponse.js.map +1 -0
  145. package/dist/vite/prerender/prerender.d.ts +1 -0
  146. package/dist/vite/prerender/prerender.js +18 -0
  147. package/dist/vite/prerender/prerender.js.map +1 -1
  148. package/dist/vite/prerender/worker.js +36 -8
  149. package/dist/vite/prerender/worker.js.map +1 -1
  150. package/dist/zuplo/with-zuplo.js +4 -0
  151. package/dist/zuplo/with-zuplo.js.map +1 -1
  152. package/lib/{AuthenticationPlugin-Duy_R1TU.js → AuthenticationPlugin-foqdvvkf.js} +2 -2
  153. package/lib/{AuthenticationPlugin-Duy_R1TU.js.map → AuthenticationPlugin-foqdvvkf.js.map} +1 -1
  154. package/lib/{Markdown-DIZ8nBVC.js → Markdown-aF5FdsNi.js} +1339 -1335
  155. package/lib/{Markdown-DIZ8nBVC.js.map → Markdown-aF5FdsNi.js.map} +1 -1
  156. package/lib/MdxPage-JscVnWM8.js +84 -0
  157. package/lib/MdxPage-JscVnWM8.js.map +1 -0
  158. package/lib/{OasProvider-D1A10JeA.js → OasProvider-C7Y53snX.js} +3 -3
  159. package/lib/{OasProvider-D1A10JeA.js.map → OasProvider-C7Y53snX.js.map} +1 -1
  160. package/lib/OperationList-_M8wg22T.js +5066 -0
  161. package/lib/OperationList-_M8wg22T.js.map +1 -0
  162. package/lib/Pagination-DCCvGq0m.js +46 -0
  163. package/lib/Pagination-DCCvGq0m.js.map +1 -0
  164. package/lib/RouteGuard-CqZPoZYJ.js +744 -0
  165. package/lib/RouteGuard-CqZPoZYJ.js.map +1 -0
  166. package/lib/SchemaList-CrKZdUyo.js +148 -0
  167. package/lib/SchemaList-CrKZdUyo.js.map +1 -0
  168. package/lib/SchemaView-B4JHn-BX.js +354 -0
  169. package/lib/SchemaView-B4JHn-BX.js.map +1 -0
  170. package/lib/{Select-fAYcJ0OU.js → Select-DVFRKf1R.js} +3 -3
  171. package/lib/{Select-fAYcJ0OU.js.map → Select-DVFRKf1R.js.map} +1 -1
  172. package/lib/{SlotletProvider-BEwNY8q0.js → SlotletProvider-DXvc0aY6.js} +2 -2
  173. package/lib/{SlotletProvider-BEwNY8q0.js.map → SlotletProvider-DXvc0aY6.js.map} +1 -1
  174. package/lib/Toc-YBsgI72s.js +92 -0
  175. package/lib/Toc-YBsgI72s.js.map +1 -0
  176. package/lib/{createServer-DjgKDpGV.js → createServer-mYvGvmc0.js} +2596 -2502
  177. package/lib/createServer-mYvGvmc0.js.map +1 -0
  178. package/lib/{hook-Cge6LiTK.js → hook-CqpVYDqN.js} +28 -28
  179. package/lib/{hook-Cge6LiTK.js.map → hook-CqpVYDqN.js.map} +1 -1
  180. package/lib/{index-B0y3fTg-.js → index-C8-tlf_X.js} +771 -729
  181. package/lib/index-C8-tlf_X.js.map +1 -0
  182. package/lib/index-D6ktNq4i.js +1863 -0
  183. package/lib/index-D6ktNq4i.js.map +1 -0
  184. package/lib/{mutation-EChriCeF.js → mutation-8LjrN7uz.js} +2 -2
  185. package/lib/{mutation-EChriCeF.js.map → mutation-8LjrN7uz.js.map} +1 -1
  186. package/lib/objectEntries-yMIkr2mI.js +5 -0
  187. package/lib/objectEntries-yMIkr2mI.js.map +1 -0
  188. package/lib/useLatest-hmRS46UF.js +11 -0
  189. package/lib/useLatest-hmRS46UF.js.map +1 -0
  190. package/lib/zudoku.auth-auth0.js +1 -1
  191. package/lib/zudoku.auth-clerk.js +2 -2
  192. package/lib/zudoku.auth-openid.js +2 -2
  193. package/lib/zudoku.components.js +32 -1454
  194. package/lib/zudoku.components.js.map +1 -1
  195. package/lib/zudoku.hooks.js +1 -1
  196. package/lib/zudoku.plugin-api-catalog.js +80 -76
  197. package/lib/zudoku.plugin-api-catalog.js.map +1 -1
  198. package/lib/zudoku.plugin-api-keys.js +3 -3
  199. package/lib/zudoku.plugin-custom-pages.js +1 -1
  200. package/lib/zudoku.plugin-markdown.js +1 -1
  201. package/lib/zudoku.plugin-openapi.js +2 -2
  202. package/lib/zudoku.plugin-search-pagefind.js +132 -137
  203. package/lib/zudoku.plugin-search-pagefind.js.map +1 -1
  204. package/package.json +6 -5
  205. package/src/app/entry.server.tsx +6 -3
  206. package/src/app/tailwind.ts +14 -0
  207. package/src/lib/components/Bootstrap.tsx +13 -6
  208. package/src/lib/components/Header.tsx +2 -2
  209. package/src/lib/components/Layout.tsx +5 -17
  210. package/src/lib/components/Main.tsx +6 -3
  211. package/src/lib/components/MobileTopNavigation.tsx +27 -18
  212. package/src/lib/components/Pagination.tsx +47 -0
  213. package/src/lib/components/TopNavigation.tsx +29 -2
  214. package/src/lib/components/Zudoku.tsx +5 -3
  215. package/src/lib/components/context/BypassProtectedRoutesContext.ts +3 -0
  216. package/src/lib/components/navigation/PoweredByZudoku.tsx +23 -0
  217. package/src/lib/components/navigation/SidebarItem.tsx +10 -4
  218. package/src/lib/components/navigation/SidebarWrapper.tsx +27 -13
  219. package/src/lib/{plugins/markdown → components/navigation}/Toc.tsx +5 -14
  220. package/src/lib/components/navigation/ZudokuLogo.tsx +25 -0
  221. package/src/lib/core/RouteGuard.tsx +26 -4
  222. package/src/lib/core/ZudokuContext.ts +1 -0
  223. package/src/lib/oas/graphql/index.ts +118 -45
  224. package/src/lib/oas/parser/dereference/index.ts +2 -0
  225. package/src/lib/oas/parser/index.ts +7 -29
  226. package/src/lib/plugins/api-catalog/index.tsx +40 -35
  227. package/src/lib/plugins/markdown/MdxPage.tsx +6 -36
  228. package/src/lib/plugins/openapi/ColorizedParam.tsx +1 -1
  229. package/src/lib/plugins/openapi/OperationList.tsx +36 -15
  230. package/src/lib/plugins/openapi/OperationListItem.tsx +7 -2
  231. package/src/lib/plugins/openapi/ParameterListItem.tsx +2 -0
  232. package/src/lib/plugins/openapi/SchemaList.tsx +151 -0
  233. package/src/lib/plugins/openapi/client/GraphQLClient.tsx +1 -1
  234. package/src/lib/plugins/openapi/client/useCreateQuery.ts +12 -5
  235. package/src/lib/plugins/openapi/components/EnumValues.tsx +1 -1
  236. package/src/lib/plugins/openapi/graphql/gql.ts +15 -6
  237. package/src/lib/plugins/openapi/graphql/graphql.ts +104 -15
  238. package/src/lib/plugins/openapi/index.tsx +13 -0
  239. package/src/lib/plugins/openapi/schema/LogicalGroup/LogicalGroup.tsx +1 -8
  240. package/src/lib/plugins/openapi/schema/LogicalGroup/LogicalGroupConnector.tsx +3 -0
  241. package/src/lib/plugins/openapi/schema/LogicalGroup/LogicalGroupItem.tsx +6 -3
  242. package/src/lib/plugins/openapi/schema/SchemaExampleAndDefault.tsx +36 -0
  243. package/src/lib/plugins/openapi/schema/SchemaPropertyItem.tsx +20 -21
  244. package/src/lib/plugins/openapi/schema/SchemaView.tsx +69 -141
  245. package/src/lib/plugins/openapi/schema/utils.ts +7 -1
  246. package/src/lib/plugins/openapi/util/getRoutes.tsx +9 -6
  247. package/src/lib/plugins/search-pagefind/PagefindSearch.tsx +11 -4
  248. package/src/lib/plugins/search-pagefind/ResultList.tsx +5 -16
  249. package/src/lib/plugins/search-pagefind/index.tsx +1 -1
  250. package/src/lib/util/useOnScreen.ts +6 -4
  251. package/dist/cli/dev/pagefind-command.d.ts +0 -3
  252. package/dist/cli/dev/pagefind-command.js +0 -59
  253. package/dist/cli/dev/pagefind-command.js.map +0 -1
  254. package/dist/lib/components/context/PluginSystem.d.ts +0 -1
  255. package/dist/lib/components/context/PluginSystem.js +0 -2
  256. package/dist/lib/components/context/PluginSystem.js.map +0 -1
  257. package/dist/lib/plugins/markdown/Toc.js.map +0 -1
  258. package/lib/MdxPage-JEdbfW-f.js +0 -195
  259. package/lib/MdxPage-JEdbfW-f.js.map +0 -1
  260. package/lib/OperationList-yOmYzMIp.js +0 -5379
  261. package/lib/OperationList-yOmYzMIp.js.map +0 -1
  262. package/lib/createServer-DjgKDpGV.js.map +0 -1
  263. package/lib/index-B0y3fTg-.js.map +0 -1
  264. package/lib/index.esm-CltAN0Tf.js +0 -711
  265. package/lib/index.esm-CltAN0Tf.js.map +0 -1
  266. package/lib/objectEntries-BS7aAgOm.js +0 -12
  267. package/lib/objectEntries-BS7aAgOm.js.map +0 -1
  268. package/src/lib/components/context/PluginSystem.ts +0 -0
  269. /package/dist/lib/{plugins/markdown → components/navigation}/Toc.d.ts +0 -0
@@ -1,6 +1,7 @@
1
1
  import * as Collapsible from "@radix-ui/react-collapsible";
2
2
  import { MinusIcon, PlusIcon, RefreshCcwDotIcon } from "lucide-react";
3
3
  import { useCallback, useState } from "react";
4
+ import { InlineCode } from "../../../components/InlineCode.js";
4
5
  import { Markdown, ProseClasses } from "../../../components/Markdown.js";
5
6
  import type { SchemaObject } from "../../../oas/parser/index.js";
6
7
  import { Button } from "../../../ui/Button.js";
@@ -10,6 +11,7 @@ import { EnumValues } from "../components/EnumValues.js";
10
11
  import { SelectOnClick } from "../components/SelectOnClick.js";
11
12
  import { ParamInfos } from "../ParamInfos.js";
12
13
  import { LogicalGroup } from "./LogicalGroup/LogicalGroup.js";
14
+ import { SchemaExampleAndDefault } from "./SchemaExampleAndDefault.js";
13
15
  import { SchemaView } from "./SchemaView.js";
14
16
  import {
15
17
  hasLogicalGroupings,
@@ -18,13 +20,7 @@ import {
18
20
  LogicalSchemaTypeMap,
19
21
  } from "./utils.js";
20
22
 
21
- export const SchemaLogicalGroup = ({
22
- schema,
23
- level,
24
- }: {
25
- schema: SchemaObject;
26
- level: number;
27
- }) => {
23
+ export const SchemaLogicalGroup = ({ schema }: { schema: SchemaObject }) => {
28
24
  const [isOpen, setIsOpen] = useState(true);
29
25
  const toggleOpen = useCallback(() => setIsOpen((prev) => !prev), []);
30
26
 
@@ -37,31 +33,31 @@ export const SchemaLogicalGroup = ({
37
33
  type={type}
38
34
  isOpen={isOpen}
39
35
  toggleOpen={toggleOpen}
40
- level={level}
41
36
  />
42
37
  );
43
38
  }
44
39
  };
45
40
 
46
41
  const RecursiveIndicator = () => (
47
- <div className="flex items-center gap-1.5 italic text-xs text-muted-foreground font-mono bg-muted px-2 py-0.5 rounded-md">
42
+ <InlineCode
43
+ className="inline-flex items-center gap-1.5 italic text-xs translate-y-0.5"
44
+ selectOnClick={false}
45
+ >
48
46
  <RefreshCcwDotIcon size={13} />
49
47
  <span>circular</span>
50
- </div>
48
+ </InlineCode>
51
49
  );
52
50
 
53
51
  export const SchemaPropertyItem = ({
54
52
  name,
55
53
  schema,
56
54
  group,
57
- level,
58
55
  defaultOpen = false,
59
56
  showCollapseButton = true,
60
57
  }: {
61
58
  name: string;
62
59
  schema: SchemaObject;
63
60
  group: "required" | "optional" | "deprecated";
64
- level: number;
65
61
  defaultOpen?: boolean;
66
62
  showCollapseButton?: boolean;
67
63
  }) => {
@@ -73,9 +69,12 @@ export const SchemaPropertyItem = ({
73
69
  <div className="flex flex-col gap-2.5 justify-between text-sm">
74
70
  <div className="space-x-2">
75
71
  <code>{name}</code>
76
- <ParamInfos schema={schema} />
77
- <RecursiveIndicator />
72
+ <ParamInfos
73
+ schema={schema}
74
+ extraItems={[<RecursiveIndicator key="circular-ref" />]}
75
+ />
78
76
  </div>
77
+ <SchemaExampleAndDefault schema={schema} />
79
78
  </div>
80
79
  </li>
81
80
  );
@@ -94,11 +93,11 @@ export const SchemaPropertyItem = ({
94
93
  group !== "optional" && (
95
94
  <span className="text-primary">required</span>
96
95
  ),
96
+ schema.type === "array" &&
97
+ "items" in schema &&
98
+ isCircularRef(schema.items) && <RecursiveIndicator />,
97
99
  ]}
98
100
  />
99
- {schema.type === "array" &&
100
- "items" in schema &&
101
- isCircularRef(schema.items) && <RecursiveIndicator />}
102
101
  </div>
103
102
  {schema.description && (
104
103
  <Markdown
@@ -110,7 +109,7 @@ export const SchemaPropertyItem = ({
110
109
  <EnumValues values={schema.items.enum} />
111
110
  )}
112
111
  {schema.enum && <EnumValues values={schema.enum} />}
113
-
112
+ <SchemaExampleAndDefault schema={schema} />
114
113
  {(hasLogicalGroupings(schema) || isComplexType(schema)) && (
115
114
  <Collapsible.Root
116
115
  defaultOpen={defaultOpen}
@@ -128,15 +127,15 @@ export const SchemaPropertyItem = ({
128
127
  <Collapsible.Content>
129
128
  <div className="mt-2">
130
129
  {hasLogicalGroupings(schema) ? (
131
- <SchemaLogicalGroup schema={schema} level={level + 1} />
130
+ <SchemaLogicalGroup schema={schema} />
132
131
  ) : schema.type === "object" ? (
133
- <SchemaView schema={schema} level={level + 1} />
132
+ <SchemaView schema={schema} />
134
133
  ) : (
135
134
  schema.type === "array" &&
136
135
  "items" in schema &&
137
136
  typeof schema.items === "object" &&
138
137
  !isCircularRef(schema.items) && (
139
- <SchemaView schema={schema.items} level={level + 1} />
138
+ <SchemaView schema={schema.items} />
140
139
  )
141
140
  )}
142
141
  </div>
@@ -5,11 +5,12 @@ import { cn } from "../../../util/cn.js";
5
5
  import { groupBy } from "../../../util/groupBy.js";
6
6
  import { EnumValues } from "../components/EnumValues.js";
7
7
  import { ParamInfos } from "../ParamInfos.js";
8
+ import { SchemaExampleAndDefault } from "./SchemaExampleAndDefault.js";
8
9
  import {
9
10
  SchemaLogicalGroup,
10
11
  SchemaPropertyItem,
11
12
  } from "./SchemaPropertyItem.js";
12
- import { hasLogicalGroupings } from "./utils.js";
13
+ import { hasLogicalGroupings, isBasicType } from "./utils.js";
13
14
 
14
15
  const renderMarkdown = (content?: string) =>
15
16
  content && (
@@ -19,166 +20,93 @@ const renderMarkdown = (content?: string) =>
19
20
  />
20
21
  );
21
22
 
23
+ const renderBasicSchema = (schema: SchemaObject) => (
24
+ <Card className="p-4 space-y-2">
25
+ <span className="text-sm text-muted-foreground">
26
+ <ParamInfos schema={schema} />
27
+ </span>
28
+ {schema.enum && <EnumValues values={schema.enum} />}
29
+ {renderMarkdown(schema.description)}
30
+ <SchemaExampleAndDefault schema={schema} />
31
+ </Card>
32
+ );
33
+
22
34
  export const SchemaView = ({
23
35
  schema,
24
- level = 0,
25
36
  defaultOpen = false,
26
37
  }: {
27
38
  schema?: SchemaObject | null;
28
- level?: number;
29
39
  defaultOpen?: boolean;
30
40
  }) => {
31
41
  if (!schema || Object.keys(schema).length === 0) {
32
42
  return (
33
43
  <Card className="p-4">
34
44
  <span className="text-sm text-muted-foreground italic">
35
- No response specified
45
+ No schema specified
36
46
  </span>
37
47
  </Card>
38
48
  );
39
49
  }
40
50
 
41
- const renderSchema = (schema: SchemaObject, level: number) => {
42
- if (hasLogicalGroupings(schema)) {
43
- return <SchemaLogicalGroup schema={schema} level={level} />;
44
- }
45
-
46
- if (Array.isArray(schema.type)) {
47
- return (
48
- <Card className="p-4 space-y-2">
49
- <span className="text-sm text-muted-foreground">
50
- <ParamInfos schema={schema} />
51
- </span>
52
- {schema.enum && <EnumValues values={schema.enum} />}
53
- {renderMarkdown(schema.description)}
54
- </Card>
55
- );
56
- }
57
-
58
- if (schema.type === "array" && typeof schema.items === "object") {
59
- const itemsSchema = schema.items as SchemaObject;
60
-
61
- if (itemsSchema.enum) {
62
- return (
63
- <Card className="p-4">
64
- <span className="text-sm text-muted-foreground">
65
- <ParamInfos schema={schema} />
66
- </span>
67
- <EnumValues values={itemsSchema.enum} />
68
- {renderMarkdown(schema.description)}
69
- </Card>
70
- );
71
- }
72
-
73
- if (
74
- typeof itemsSchema.type === "string" &&
75
- ["string", "number", "boolean", "integer"].includes(itemsSchema.type)
76
- ) {
77
- return (
78
- <Card className="p-4">
79
- <span className="text-sm text-muted-foreground">
80
- <ParamInfos schema={schema} />
81
- </span>
82
- {renderMarkdown(schema.description)}
83
- </Card>
84
- );
85
- } else if (itemsSchema.type === "object") {
86
- return (
87
- <Card className="flex flex-col gap-2 bg-border/30 p-4">
88
- <span className="text-sm text-muted-foreground">object[]</span>
89
- {renderSchema(itemsSchema, level + 1)}
90
- </Card>
91
- );
92
- } else {
93
- return renderSchema(itemsSchema, level + 1);
94
- }
95
- }
96
-
97
- if (
98
- schema.type === "object" &&
99
- (!schema.properties || Object.keys(schema.properties).length === 0)
100
- ) {
101
- return (
102
- <Card className="p-4 flex gap-2 items-baseline">
103
- {"name" in schema && <>{schema.name as string}</>}
104
- <span className="text-sm text-muted-foreground">
105
- <ParamInfos schema={schema} />
106
- </span>
107
- {renderMarkdown(schema.description)}
108
- </Card>
109
- );
110
- }
111
-
112
- if (schema.properties) {
113
- const groupedProperties = groupBy(
114
- Object.entries(schema.properties),
115
- ([propertyName, property]) => {
116
- return property.deprecated
117
- ? "deprecated"
118
- : schema.required?.includes(propertyName)
119
- ? "required"
120
- : "optional";
121
- },
122
- );
51
+ if (hasLogicalGroupings(schema)) {
52
+ return <SchemaLogicalGroup schema={schema} />;
53
+ }
123
54
 
124
- const groupNames = ["required", "optional", "deprecated"] as const;
55
+ if (isBasicType(schema.type)) {
56
+ return renderBasicSchema(schema);
57
+ }
125
58
 
126
- return (
127
- <Card className="divide-y overflow-hidden">
128
- {groupNames.map(
129
- (group) =>
130
- groupedProperties[group] && (
131
- <ul key={group} className="divide-y">
132
- {groupedProperties[group].map(([name, schema]) => (
133
- <SchemaPropertyItem
134
- key={name}
135
- name={name}
136
- schema={schema}
137
- group={group}
138
- level={level}
139
- defaultOpen={defaultOpen}
140
- />
141
- ))}
142
- </ul>
143
- ),
144
- )}
145
- </Card>
146
- );
147
- }
59
+ if (schema.type === "array" && typeof schema.items === "object") {
60
+ return renderBasicSchema(schema.items as SchemaObject);
61
+ }
148
62
 
149
- if (
150
- typeof schema.type === "string" &&
151
- ["string", "number", "boolean", "integer", "null"].includes(schema.type)
152
- ) {
153
- return (
154
- <Card className="p-4 space-y-2">
155
- <span className="text-sm text-muted-foreground">
156
- <ParamInfos schema={schema} />
157
- </span>
158
- {schema.enum && <EnumValues values={schema.enum} />}
159
- {renderMarkdown(schema.description)}
160
- </Card>
161
- );
162
- }
63
+ if (schema.type === "object") {
64
+ const groupedProperties = groupBy(
65
+ Object.entries(schema.properties ?? {}),
66
+ ([propertyName, property]) => {
67
+ return property.deprecated
68
+ ? "deprecated"
69
+ : schema.required?.includes(propertyName)
70
+ ? "required"
71
+ : "optional";
72
+ },
73
+ );
74
+ const groupNames = ["required", "optional", "deprecated"] as const;
163
75
 
164
- if (schema.additionalProperties) {
165
- return (
166
- <Card className="my-2">
167
- <CardHeader>
168
- <CardTitle>Additional Properties:</CardTitle>
169
- </CardHeader>
170
- <CardContent>
171
- {renderSchema(
172
- schema.additionalProperties as SchemaObject,
173
- level + 1,
174
- )}
175
- </CardContent>
176
- </Card>
177
- );
178
- }
76
+ return (
77
+ <Card className="divide-y overflow-hidden">
78
+ {groupNames.map(
79
+ (group) =>
80
+ groupedProperties[group] && (
81
+ <ul key={group} className="divide-y">
82
+ {groupedProperties[group].map(([name, schema]) => (
83
+ <SchemaPropertyItem
84
+ key={name}
85
+ name={name}
86
+ schema={schema}
87
+ group={group}
88
+ defaultOpen={defaultOpen}
89
+ />
90
+ ))}
91
+ </ul>
92
+ ),
93
+ )}
94
+ </Card>
95
+ );
96
+ }
179
97
 
180
- return null;
181
- };
98
+ if (schema.additionalProperties) {
99
+ return (
100
+ <Card className="my-2">
101
+ <CardHeader>
102
+ <CardTitle>Additional Properties:</CardTitle>
103
+ </CardHeader>
104
+ <CardContent>
105
+ <SchemaView schema={schema.additionalProperties as SchemaObject} />
106
+ </CardContent>
107
+ </Card>
108
+ );
109
+ }
182
110
 
183
- return renderSchema(schema, level);
111
+ return null;
184
112
  };
@@ -1,8 +1,14 @@
1
1
  import { CIRCULAR_REF } from "../../../oas/graphql/circular.js";
2
2
  import type { SchemaObject } from "../../../oas/parser/index.js";
3
3
 
4
+ export const isBasicType = (
5
+ type: unknown,
6
+ ): type is "string" | "number" | "boolean" | "integer" | "null" =>
7
+ typeof type === "string" &&
8
+ ["string", "number", "boolean", "integer", "null"].includes(type);
9
+
4
10
  export const isComplexType = (value: SchemaObject) =>
5
- value.type === "object" ||
11
+ (value.type === "object" && Object.keys(value.properties ?? {}).length > 0) ||
6
12
  (value.type === "array" &&
7
13
  typeof value.items === "object" &&
8
14
  (!value.items.type || value.items.type === "object"));
@@ -1,4 +1,3 @@
1
- import slugify from "@sindresorhus/slugify";
2
1
  import { redirect, type RouteObject } from "react-router";
3
2
  import { joinUrl } from "../../../util/joinUrl.js";
4
3
  import type { GraphQLClient } from "../client/GraphQLClient.js";
@@ -53,10 +52,7 @@ const createVersionRoutes = (
53
52
  versionPath: string,
54
53
  tagPages: string[],
55
54
  ): RouteObject[] => {
56
- const firstTagRoute = joinUrl(
57
- versionPath,
58
- tagPages[0] ? slugify(tagPages[0]) : UNTAGGED_PATH,
59
- );
55
+ const firstTagRoute = joinUrl(versionPath, tagPages.at(0) ?? UNTAGGED_PATH);
60
56
 
61
57
  return [
62
58
  // Redirect to first tag on the index route
@@ -64,7 +60,7 @@ const createVersionRoutes = (
64
60
  // Create routes for each tag
65
61
  ...tagPages.map((tag) =>
66
62
  createRoute({
67
- path: joinUrl(versionPath, slugify(tag)),
63
+ path: joinUrl(versionPath, tag),
68
64
  tag,
69
65
  }),
70
66
  ),
@@ -73,6 +69,13 @@ const createVersionRoutes = (
73
69
  path: joinUrl(versionPath, UNTAGGED_PATH),
74
70
  untagged: true,
75
71
  }),
72
+ {
73
+ path: joinUrl(versionPath, "~schemas"),
74
+ lazy: async () => {
75
+ const { SchemaList } = await import("../SchemaList.js");
76
+ return { element: <SchemaList /> };
77
+ },
78
+ },
76
79
  ];
77
80
  };
78
81
 
@@ -11,6 +11,7 @@ import {
11
11
  import { DialogTitle } from "zudoku/ui/Dialog.js";
12
12
  import { useAuthState } from "../../authentication/state.js";
13
13
  import { useZudoku } from "../../components/context/ZudokuContext.js";
14
+ import { SEARCH_PROTECTED_SECTION } from "../../core/RouteGuard.js";
14
15
  import { joinUrl } from "../../util/joinUrl.js";
15
16
  import { getResults } from "./get-results.js";
16
17
  import type { PagefindOptions } from "./index.js";
@@ -35,11 +36,14 @@ const importPagefind = (basePath?: string): Promise<Pagefind> =>
35
36
  : import(/* @vite-ignore */ joinUrl(basePath, "/pagefind/pagefind.js"));
36
37
 
37
38
  const usePagefind = (options: PagefindOptions) => {
39
+ const {
40
+ options: { basePath },
41
+ } = useZudoku();
38
42
  const { data: pagefind, ...result } = useQuery<Pagefind>({
39
43
  queryKey: ["pagefind", options.ranking],
40
44
  retry: false,
41
45
  queryFn: async () => {
42
- const pagefind = await importPagefind(options.basePath);
46
+ const pagefind = await importPagefind(basePath);
43
47
  await pagefind.init();
44
48
  await pagefind.options({
45
49
  ranking: {
@@ -82,9 +86,13 @@ export const PagefindSearch = ({
82
86
  const inputRef = useRef<HTMLInputElement>(null);
83
87
 
84
88
  const { data: searchResults } = useQuery({
85
- queryKey: ["pagefind-search", searchTerm],
89
+ queryKey: ["pagefind-search", searchTerm, auth.isAuthenticated],
86
90
  queryFn: async () => {
87
- const search = await pagefind?.search(searchTerm);
91
+ const filters = auth.isAuthenticated
92
+ ? undefined
93
+ : { not: { section: SEARCH_PROTECTED_SECTION } };
94
+
95
+ const search = await pagefind?.search(searchTerm, { filters });
88
96
  if (!search) return [];
89
97
  return getResults({ search, options, auth, context });
90
98
  },
@@ -145,7 +153,6 @@ export const PagefindSearch = ({
145
153
  </div>
146
154
  ) : (
147
155
  <ResultList
148
- basePath={options.basePath}
149
156
  searchResults={searchResults ?? []}
150
157
  searchTerm={searchTerm}
151
158
  onClose={onClose}
@@ -1,5 +1,5 @@
1
1
  import { BracketsIcon, FileTextIcon } from "lucide-react";
2
- import { useCallback, useLayoutEffect, useRef } from "react";
2
+ import { useLayoutEffect, useRef } from "react";
3
3
  import { Link, useNavigate } from "react-router";
4
4
  import { CommandGroup, CommandItem, CommandList } from "zudoku/ui/Command.js";
5
5
  import {
@@ -22,7 +22,6 @@ const sortSubResults = (a: PagefindSubResult, b: PagefindSubResult) => {
22
22
  const hoverClassname = `cursor-pointer border border-transparent data-[selected=true]:border-border`;
23
23
 
24
24
  export const ResultList = ({
25
- basePath,
26
25
  searchResults,
27
26
  searchTerm,
28
27
  onClose,
@@ -37,16 +36,6 @@ export const ResultList = ({
37
36
  const navigate = useNavigate();
38
37
  const commandListRef = useRef<HTMLDivElement | null>(null);
39
38
 
40
- const cleanResultUrl = useCallback(
41
- (url: string) => {
42
- const clean = url.replace(".html", "");
43
- return basePath && clean.startsWith(basePath)
44
- ? clean.slice(basePath.length)
45
- : clean;
46
- },
47
- [basePath],
48
- );
49
-
50
39
  useLayoutEffect(() => {
51
40
  requestIdleCallback(() => {
52
41
  commandListRef.current?.scrollTo({ top: 0 });
@@ -71,11 +60,11 @@ export const ResultList = ({
71
60
  value={`${result.meta.title}-${result.url}`}
72
61
  className={hoverClassname}
73
62
  onSelect={() => {
74
- void navigate(cleanResultUrl(result.url));
63
+ void navigate(result.url);
75
64
  onClose();
76
65
  }}
77
66
  >
78
- <Link to={cleanResultUrl(result.url)}>
67
+ <Link to={result.url}>
79
68
  {result.meta.section === "openapi" ? (
80
69
  <BracketsIcon />
81
70
  ) : (
@@ -94,11 +83,11 @@ export const ResultList = ({
94
83
  value={`sub-${result.meta.title}-${subResult.url}`}
95
84
  className={hoverClassname}
96
85
  onSelect={() => {
97
- void navigate(cleanResultUrl(subResult.url));
86
+ void navigate(subResult.url);
98
87
  onClose();
99
88
  }}
100
89
  >
101
- <Link to={cleanResultUrl(subResult.url)} onClick={onClose}>
90
+ <Link to={subResult.url} onClick={onClose}>
102
91
  <div className="flex flex-col items-start gap-2 ms-2.5 ps-5 border-l border-muted-foreground/50">
103
92
  <span className="font-bold">{subResult.title}</span>
104
93
  <span
@@ -6,7 +6,7 @@ import { PagefindSearch } from "./PagefindSearch.js";
6
6
  export type PagefindOptions = Extract<
7
7
  ZudokuConfig["search"],
8
8
  { type: "pagefind" }
9
- > & { basePath?: string };
9
+ >;
10
10
 
11
11
  export const pagefindSearchPlugin = (
12
12
  options: PagefindOptions,
@@ -1,14 +1,16 @@
1
1
  import { useEffect, useRef, useState } from "react";
2
2
 
3
- export const useOnScreen = ({
3
+ export const useOnScreen = <E extends Element = HTMLElement>({
4
4
  rootMargin = "0px",
5
5
  threshold,
6
+ root,
6
7
  }: {
7
8
  rootMargin?: string;
8
9
  threshold?: number;
10
+ root?: Element | null;
9
11
  } = {}) => {
10
12
  const [isVisible, setIsVisible] = useState(false);
11
- const ref = useRef<HTMLElement | null>(null);
13
+ const ref = useRef<E | null>(null);
12
14
 
13
15
  useEffect(() => {
14
16
  const observer = new IntersectionObserver(
@@ -16,7 +18,7 @@ export const useOnScreen = ({
16
18
  if (!entry) return;
17
19
  setIsVisible(entry.isIntersecting);
18
20
  },
19
- { rootMargin, threshold },
21
+ { rootMargin, threshold, root },
20
22
  );
21
23
 
22
24
  const currentElement = ref.current;
@@ -26,7 +28,7 @@ export const useOnScreen = ({
26
28
  observer.observe(currentElement);
27
29
 
28
30
  return () => observer.unobserve(currentElement);
29
- }, [rootMargin, threshold]);
31
+ }, [root, rootMargin, threshold]);
30
32
 
31
33
  return [ref, isVisible] as const;
32
34
  };
@@ -1,3 +0,0 @@
1
- export declare const pagefindCommand: (argv: {
2
- forceBuild: boolean;
3
- }) => Promise<void>;
@@ -1,59 +0,0 @@
1
- import { glob } from "glob";
2
- import fs from "node:fs/promises";
3
- import path from "node:path";
4
- import colors from "picocolors";
5
- import { runBuild } from "../../vite/build.js";
6
- import { loadZudokuConfig } from "../../vite/config.js";
7
- import { createPagefindIndex } from "../../vite/create-pagefind-index.js";
8
- import { writeLine } from "../../vite/reporter.js";
9
- import { logger } from "../common/logger.js";
10
- const captureOutput = async (fn) => {
11
- const stdout = process.stdout.write;
12
- const stderr = process.stderr.write;
13
- process.stdout.write = () => true;
14
- process.stderr.write = () => true;
15
- try {
16
- return await fn();
17
- }
18
- finally {
19
- process.stdout.write = stdout;
20
- process.stderr.write = stderr;
21
- }
22
- };
23
- export const pagefindCommand = async (argv) => {
24
- const dir = process.cwd();
25
- const dist = path.join(dir, "dist");
26
- const { config } = await loadZudokuConfig({ mode: "production", command: "build" }, dir);
27
- if (config.search?.type !== "pagefind") {
28
- logger.warn(colors.yellow("Search is not configured to use pagefind."));
29
- }
30
- const message = argv.forceBuild
31
- ? "creating build and pagefind index..."
32
- : "building pagefind index...";
33
- writeLine(colors.blue(message));
34
- if (argv.forceBuild) {
35
- await captureOutput(() => runBuild({ dir }));
36
- }
37
- const outputPath = await createPagefindIndex({
38
- dir: dist,
39
- outDir: path.join(process.cwd(), "public"),
40
- });
41
- const successMessage = argv.forceBuild
42
- ? `✓ build created and pagefind index written to ${outputPath}`
43
- : `✓ pagefind index written to ${outputPath}`;
44
- writeLine(colors.blue(successMessage));
45
- // find pagefind directory in dist with glob
46
- const pagefindGlob = await glob("**/pagefind/", {
47
- cwd: dist,
48
- absolute: true,
49
- });
50
- const pagefindDir = pagefindGlob.at(0);
51
- if (!pagefindDir) {
52
- throw new Error(`pagefind directory not found in ${dist}.`);
53
- }
54
- // move from dist to public dir so it can be consumed in dev
55
- const publicDir = path.join(dir, "public/pagefind");
56
- await fs.rm(publicDir, { recursive: true, force: true });
57
- await fs.rename(pagefindDir, publicDir);
58
- };
59
- //# sourceMappingURL=pagefind-command.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"pagefind-command.js","sourceRoot":"","sources":["../../../src/cli/dev/pagefind-command.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,MAAM,MAAM,CAAC;AAC5B,OAAO,EAAE,MAAM,kBAAkB,CAAC;AAClC,OAAO,IAAI,MAAM,WAAW,CAAC;AAC7B,OAAO,MAAM,MAAM,YAAY,CAAC;AAChC,OAAO,EAAE,QAAQ,EAAE,MAAM,qBAAqB,CAAC;AAC/C,OAAO,EAAE,gBAAgB,EAAE,MAAM,sBAAsB,CAAC;AACxD,OAAO,EAAE,mBAAmB,EAAE,MAAM,qCAAqC,CAAC;AAC1E,OAAO,EAAE,SAAS,EAAE,MAAM,wBAAwB,CAAC;AACnD,OAAO,EAAE,MAAM,EAAE,MAAM,qBAAqB,CAAC;AAE7C,MAAM,aAAa,GAAG,KAAK,EAAK,EAAoB,EAAc,EAAE;IAClE,MAAM,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC,KAAK,CAAC;IACpC,MAAM,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC,KAAK,CAAC;IACpC,OAAO,CAAC,MAAM,CAAC,KAAK,GAAG,GAAG,EAAE,CAAC,IAAI,CAAC;IAClC,OAAO,CAAC,MAAM,CAAC,KAAK,GAAG,GAAG,EAAE,CAAC,IAAI,CAAC;IAClC,IAAI,CAAC;QACH,OAAO,MAAM,EAAE,EAAE,CAAC;IACpB,CAAC;YAAS,CAAC;QACT,OAAO,CAAC,MAAM,CAAC,KAAK,GAAG,MAAM,CAAC;QAC9B,OAAO,CAAC,MAAM,CAAC,KAAK,GAAG,MAAM,CAAC;IAChC,CAAC;AACH,CAAC,CAAC;AAEF,MAAM,CAAC,MAAM,eAAe,GAAG,KAAK,EAAE,IAA6B,EAAE,EAAE;IACrE,MAAM,GAAG,GAAG,OAAO,CAAC,GAAG,EAAE,CAAC;IAC1B,MAAM,IAAI,GAAG,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;IAEvC,IAAI,CAAC,WAAW,EAAE,CAAC;QACjB,MAAM,IAAI,KAAK,CAAC,mCAAmC,IAAI,GAAG,CAAC,CAAC;IAC9D,CAAC;IAED,4DAA4D;IAC5D,MAAM,SAAS,GAAG,IAAI,CAAC,IAAI,CAAC,GAAG,EAAE,iBAAiB,CAAC,CAAC;IAEpD,MAAM,EAAE,CAAC,EAAE,CAAC,SAAS,EAAE,EAAE,SAAS,EAAE,IAAI,EAAE,KAAK,EAAE,IAAI,EAAE,CAAC,CAAC;IACzD,MAAM,EAAE,CAAC,MAAM,CAAC,WAAW,EAAE,SAAS,CAAC,CAAC;AAC1C,CAAC,CAAC"}
@@ -1 +0,0 @@
1
- export {};
@@ -1,2 +0,0 @@
1
- export {};
2
- //# sourceMappingURL=PluginSystem.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"PluginSystem.js","sourceRoot":"","sources":["../../../../src/lib/components/context/PluginSystem.ts"],"names":[],"mappings":""}
@@ -1 +0,0 @@
1
- {"version":3,"file":"Toc.js","sourceRoot":"","sources":["../../../../src/lib/plugins/markdown/Toc.tsx"],"names":[],"mappings":";AACA,OAAO,EAAE,YAAY,EAAE,MAAM,cAAc,CAAC;AAC5C,OAAO,EACL,SAAS,EACT,MAAM,EACN,QAAQ,GAGT,MAAM,OAAO,CAAC;AACf,OAAO,EAAE,UAAU,EAAE,MAAM,gCAAgC,CAAC;AAC5D,OAAO,EAAE,iBAAiB,EAAE,MAAM,mDAAmD,CAAC;AACtF,OAAO,EAAE,EAAE,EAAE,MAAM,kBAAkB,CAAC;AAEtC,MAAM,gBAAgB,GAAG,aAAa,CAAC;AAEvC,MAAM,OAAO,GAAG,CAAC,EACf,IAAI,EACJ,QAAQ,EACR,SAAS,EACT,QAAQ,GAKR,EAAE,EAAE;IACJ,OAAO,CACL,cACE,SAAS,EAAE,EAAE,CACX,UAAU,EACV,QAAQ;YACN,CAAC,CAAC,cAAc;YAChB,CAAC,CAAC,4CAA4C,EAChD,SAAS,C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