zudoku 0.0.0-fed343e → 0.0.0-feda542

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 (1394) hide show
  1. package/README.md +121 -0
  2. package/cli.js +5 -2
  3. package/client.d.ts +7 -0
  4. package/dist/app/demo.js +1 -4
  5. package/dist/app/demo.js.map +1 -1
  6. package/dist/app/entry.client.d.ts +6 -0
  7. package/dist/app/entry.client.js +17 -3
  8. package/dist/app/entry.client.js.map +1 -1
  9. package/dist/app/entry.server.d.ts +9 -6
  10. package/dist/app/entry.server.js +21 -14
  11. package/dist/app/entry.server.js.map +1 -1
  12. package/dist/app/main.d.ts +3 -2
  13. package/dist/app/main.js +34 -38
  14. package/dist/app/main.js.map +1 -1
  15. package/dist/app/sentry.d.ts +3 -0
  16. package/dist/app/sentry.js +19 -0
  17. package/dist/app/sentry.js.map +1 -0
  18. package/dist/app/standalone.js +1 -4
  19. package/dist/app/standalone.js.map +1 -1
  20. package/dist/app/tailwind.d.ts +2 -1
  21. package/dist/app/tailwind.js +80 -48
  22. package/dist/app/tailwind.js.map +1 -1
  23. package/dist/cli/build/handler.d.ts +1 -3
  24. package/dist/cli/build/handler.js +9 -1
  25. package/dist/cli/build/handler.js.map +1 -1
  26. package/dist/cli/cli.js +6 -4
  27. package/dist/cli/cli.js.map +1 -1
  28. package/dist/cli/cmds/build.d.ts +11 -3
  29. package/dist/cli/cmds/build.js +21 -13
  30. package/dist/cli/cmds/build.js.map +1 -1
  31. package/dist/cli/cmds/dev.d.ts +1 -1
  32. package/dist/cli/cmds/dev.js +5 -0
  33. package/dist/cli/cmds/dev.js.map +1 -1
  34. package/dist/cli/cmds/preview.d.ts +16 -0
  35. package/dist/cli/cmds/preview.js +25 -0
  36. package/dist/cli/cmds/preview.js.map +1 -0
  37. package/dist/cli/common/logger.js +9 -0
  38. package/dist/cli/common/logger.js.map +1 -1
  39. package/dist/cli/common/machine-id/lib.js.map +1 -1
  40. package/dist/cli/common/outdated.js +2 -1
  41. package/dist/cli/common/outdated.js.map +1 -1
  42. package/dist/cli/common/output.js.map +1 -1
  43. package/dist/cli/common/utils/box.js.map +1 -1
  44. package/dist/cli/common/utils/ports.d.ts +1 -1
  45. package/dist/cli/common/utils/ports.js +16 -15
  46. package/dist/cli/common/utils/ports.js.map +1 -1
  47. package/dist/cli/dev/handler.d.ts +1 -0
  48. package/dist/cli/dev/handler.js +16 -13
  49. package/dist/cli/dev/handler.js.map +1 -1
  50. package/dist/cli/preview/handler.d.ts +3 -0
  51. package/dist/cli/preview/handler.js +35 -0
  52. package/dist/cli/preview/handler.js.map +1 -0
  53. package/dist/codegen.d.ts +3 -0
  54. package/dist/codegen.js +45 -0
  55. package/dist/codegen.js.map +1 -0
  56. package/dist/config/common.d.ts +10 -0
  57. package/dist/config/common.js +2 -0
  58. package/dist/config/common.js.map +1 -0
  59. package/dist/config/config.d.ts +20 -20
  60. package/dist/config/loader.d.ts +21 -0
  61. package/dist/config/loader.js +149 -0
  62. package/dist/config/loader.js.map +1 -0
  63. package/dist/config/validators/BuildSchema.d.ts +59 -0
  64. package/dist/config/validators/BuildSchema.js +31 -0
  65. package/dist/config/validators/BuildSchema.js.map +1 -0
  66. package/dist/config/validators/InputSidebarSchema.d.ts +63 -31
  67. package/dist/config/validators/InputSidebarSchema.js +17 -28
  68. package/dist/config/validators/InputSidebarSchema.js.map +1 -1
  69. package/dist/config/validators/SidebarSchema.d.ts +24 -1
  70. package/dist/config/validators/SidebarSchema.js +80 -44
  71. package/dist/config/validators/SidebarSchema.js.map +1 -1
  72. package/dist/config/validators/common.d.ts +7670 -0
  73. package/dist/config/validators/common.js +402 -0
  74. package/dist/config/validators/common.js.map +1 -0
  75. package/dist/config/validators/icon-types.d.ts +1 -0
  76. package/dist/config/validators/icon-types.js +2 -0
  77. package/dist/config/validators/icon-types.js.map +1 -0
  78. package/dist/config/validators/validate.d.ts +1965 -443
  79. package/dist/config/validators/validate.js +14 -210
  80. package/dist/config/validators/validate.js.map +1 -1
  81. package/dist/index.d.ts +7 -2
  82. package/dist/index.js +2 -1
  83. package/dist/index.js.map +1 -1
  84. package/dist/lib/MissingIcon.d.ts +2 -0
  85. package/dist/lib/MissingIcon.js +7 -0
  86. package/dist/lib/MissingIcon.js.map +1 -0
  87. package/dist/lib/authentication/AuthenticationPlugin.d.ts +4 -2
  88. package/dist/lib/authentication/AuthenticationPlugin.js +3 -0
  89. package/dist/lib/authentication/AuthenticationPlugin.js.map +1 -1
  90. package/dist/lib/authentication/authentication.d.ts +4 -3
  91. package/dist/lib/authentication/components/CallbackHandler.js +21 -31
  92. package/dist/lib/authentication/components/CallbackHandler.js.map +1 -1
  93. package/dist/lib/authentication/components/SignIn.js +1 -1
  94. package/dist/lib/authentication/components/SignIn.js.map +1 -1
  95. package/dist/lib/authentication/components/SignOut.js +2 -2
  96. package/dist/lib/authentication/components/SignOut.js.map +1 -1
  97. package/dist/lib/authentication/hook.d.ts +6 -4
  98. package/dist/lib/authentication/hook.js +12 -4
  99. package/dist/lib/authentication/hook.js.map +1 -1
  100. package/dist/lib/authentication/providers/auth0.d.ts +2 -2
  101. package/dist/lib/authentication/providers/auth0.js +14 -12
  102. package/dist/lib/authentication/providers/auth0.js.map +1 -1
  103. package/dist/lib/authentication/providers/clerk.d.ts +2 -2
  104. package/dist/lib/authentication/providers/clerk.js +54 -12
  105. package/dist/lib/authentication/providers/clerk.js.map +1 -1
  106. package/dist/lib/authentication/providers/openid.d.ts +12 -4
  107. package/dist/lib/authentication/providers/openid.js +54 -44
  108. package/dist/lib/authentication/providers/openid.js.map +1 -1
  109. package/dist/lib/authentication/providers/supabase.d.ts +4 -0
  110. package/dist/lib/authentication/providers/supabase.js +117 -0
  111. package/dist/lib/authentication/providers/supabase.js.map +1 -0
  112. package/dist/lib/authentication/state.d.ts +23 -3
  113. package/dist/lib/authentication/state.js +34 -2
  114. package/dist/lib/authentication/state.js.map +1 -1
  115. package/dist/lib/authentication/use-broadcast/shared.d.ts +48 -0
  116. package/dist/lib/authentication/use-broadcast/shared.js +243 -0
  117. package/dist/lib/authentication/use-broadcast/shared.js.map +1 -0
  118. package/dist/lib/authentication/use-broadcast/useBroadcast.d.ts +24 -0
  119. package/dist/lib/authentication/use-broadcast/useBroadcast.js +106 -0
  120. package/dist/lib/authentication/use-broadcast/useBroadcast.js.map +1 -0
  121. package/dist/lib/components/AnchorLink.d.ts +2 -2
  122. package/dist/lib/components/AnchorLink.js +9 -5
  123. package/dist/lib/components/AnchorLink.js.map +1 -1
  124. package/dist/lib/components/Autocomplete.d.ts +13 -0
  125. package/dist/lib/components/Autocomplete.js +47 -0
  126. package/dist/lib/components/Autocomplete.js.map +1 -0
  127. package/dist/lib/components/Banner.js +7 -1
  128. package/dist/lib/components/Banner.js.map +1 -1
  129. package/dist/lib/components/Bootstrap.d.ts +5 -3
  130. package/dist/lib/components/Bootstrap.js +13 -6
  131. package/dist/lib/components/Bootstrap.js.map +1 -1
  132. package/dist/lib/components/ClientOnly.d.ts +4 -2
  133. package/dist/lib/components/ClientOnly.js +1 -1
  134. package/dist/lib/components/ClientOnly.js.map +1 -1
  135. package/dist/lib/components/DeveloperHint.js +2 -1
  136. package/dist/lib/components/DeveloperHint.js.map +1 -1
  137. package/dist/lib/components/ErrorPage.js +1 -2
  138. package/dist/lib/components/ErrorPage.js.map +1 -1
  139. package/dist/lib/components/Footer.d.ts +1 -0
  140. package/dist/lib/components/Footer.js +32 -0
  141. package/dist/lib/components/Footer.js.map +1 -0
  142. package/dist/lib/components/Header.js +22 -11
  143. package/dist/lib/components/Header.js.map +1 -1
  144. package/dist/lib/components/Heading.d.ts +4 -4
  145. package/dist/lib/components/Heading.js +1 -1
  146. package/dist/lib/components/Heading.js.map +1 -1
  147. package/dist/lib/components/InlineCode.d.ts +3 -1
  148. package/dist/lib/components/InlineCode.js +2 -1
  149. package/dist/lib/components/InlineCode.js.map +1 -1
  150. package/dist/lib/components/Layout.js +9 -20
  151. package/dist/lib/components/Layout.js.map +1 -1
  152. package/dist/lib/components/Main.d.ts +2 -0
  153. package/dist/lib/components/Main.js +17 -0
  154. package/dist/lib/components/Main.js.map +1 -0
  155. package/dist/lib/components/Markdown.d.ts +2 -2
  156. package/dist/lib/components/Markdown.js +4 -2
  157. package/dist/lib/components/Markdown.js.map +1 -1
  158. package/dist/lib/components/MobileTopNavigation.js +13 -7
  159. package/dist/lib/components/MobileTopNavigation.js.map +1 -1
  160. package/dist/lib/components/NotFoundPage.js +1 -1
  161. package/dist/lib/components/NotFoundPage.js.map +1 -1
  162. package/dist/lib/components/Pagination.d.ts +11 -0
  163. package/dist/lib/components/Pagination.js +10 -0
  164. package/dist/lib/components/Pagination.js.map +1 -0
  165. package/dist/lib/components/PathRenderer.d.ts +11 -0
  166. package/dist/lib/components/PathRenderer.js +28 -0
  167. package/dist/lib/components/PathRenderer.js.map +1 -0
  168. package/dist/lib/components/ReactMarkdown.d.ts +29 -0
  169. package/dist/lib/components/ReactMarkdown.js +182 -0
  170. package/dist/lib/components/ReactMarkdown.js.map +1 -0
  171. package/dist/lib/components/Search.d.ts +3 -1
  172. package/dist/lib/components/Search.js +9 -3
  173. package/dist/lib/components/Search.js.map +1 -1
  174. package/dist/lib/components/SlotletProvider.d.ts +11 -3
  175. package/dist/lib/components/SlotletProvider.js +4 -2
  176. package/dist/lib/components/SlotletProvider.js.map +1 -1
  177. package/dist/lib/components/StatusPage.d.ts +7 -0
  178. package/dist/lib/components/StatusPage.js +71 -0
  179. package/dist/lib/components/StatusPage.js.map +1 -0
  180. package/dist/lib/components/ThemeSwitch.d.ts +1 -0
  181. package/dist/lib/components/ThemeSwitch.js +16 -0
  182. package/dist/lib/components/ThemeSwitch.js.map +1 -0
  183. package/dist/lib/components/TopNavigation.d.ts +6 -0
  184. package/dist/lib/components/TopNavigation.js +61 -8
  185. package/dist/lib/components/TopNavigation.js.map +1 -1
  186. package/dist/lib/components/{DevPortal.d.ts → Zudoku.d.ts} +3 -3
  187. package/dist/lib/components/{DevPortal.js → Zudoku.js} +24 -18
  188. package/dist/lib/components/Zudoku.js.map +1 -0
  189. package/dist/lib/components/cache.d.ts +13 -0
  190. package/dist/lib/components/cache.js +20 -0
  191. package/dist/lib/components/cache.js.map +1 -0
  192. package/dist/lib/components/context/BypassProtectedRoutesContext.d.ts +1 -0
  193. package/dist/lib/components/context/BypassProtectedRoutesContext.js +3 -0
  194. package/dist/lib/components/context/BypassProtectedRoutesContext.js.map +1 -0
  195. package/dist/lib/components/context/RouterEventsEmitter.d.ts +1 -0
  196. package/dist/lib/components/context/RouterEventsEmitter.js +17 -0
  197. package/dist/lib/components/context/RouterEventsEmitter.js.map +1 -0
  198. package/dist/lib/components/context/ViewportAnchorContext.d.ts +2 -4
  199. package/dist/lib/components/context/ViewportAnchorContext.js +21 -14
  200. package/dist/lib/components/context/ViewportAnchorContext.js.map +1 -1
  201. package/dist/lib/components/context/ZudokuContext.d.ts +10 -14
  202. package/dist/lib/components/context/ZudokuContext.js +41 -27
  203. package/dist/lib/components/context/ZudokuContext.js.map +1 -1
  204. package/dist/lib/components/context/ZudokuProvider.d.ts +2 -2
  205. package/dist/lib/components/context/ZudokuProvider.js.map +1 -1
  206. package/dist/lib/components/index.d.ts +54 -16
  207. package/dist/lib/components/index.js +25 -6
  208. package/dist/lib/components/index.js.map +1 -1
  209. package/dist/lib/components/navigation/PoweredByZudoku.d.ts +3 -0
  210. package/dist/lib/components/navigation/PoweredByZudoku.js +6 -0
  211. package/dist/lib/components/navigation/PoweredByZudoku.js.map +1 -0
  212. package/dist/lib/components/navigation/Sidebar.d.ts +5 -1
  213. package/dist/lib/components/navigation/Sidebar.js +3 -7
  214. package/dist/lib/components/navigation/Sidebar.js.map +1 -1
  215. package/dist/lib/components/navigation/SidebarBadge.d.ts +6 -3
  216. package/dist/lib/components/navigation/SidebarBadge.js +13 -11
  217. package/dist/lib/components/navigation/SidebarBadge.js.map +1 -1
  218. package/dist/lib/components/navigation/SidebarCategory.d.ts +3 -3
  219. package/dist/lib/components/navigation/SidebarCategory.js +27 -13
  220. package/dist/lib/components/navigation/SidebarCategory.js.map +1 -1
  221. package/dist/lib/components/navigation/SidebarItem.d.ts +3 -4
  222. package/dist/lib/components/navigation/SidebarItem.js +23 -16
  223. package/dist/lib/components/navigation/SidebarItem.js.map +1 -1
  224. package/dist/lib/components/navigation/SidebarWrapper.d.ts +7 -6
  225. package/dist/lib/components/navigation/SidebarWrapper.js +18 -3
  226. package/dist/lib/components/navigation/SidebarWrapper.js.map +1 -1
  227. package/dist/lib/{plugins/markdown → components/navigation}/Toc.js +5 -7
  228. package/dist/lib/components/navigation/Toc.js.map +1 -0
  229. package/dist/lib/components/navigation/ZudokuLogo.d.ts +6 -0
  230. package/dist/lib/components/navigation/ZudokuLogo.js +5 -0
  231. package/dist/lib/components/navigation/ZudokuLogo.js.map +1 -0
  232. package/dist/lib/components/navigation/utils.js +11 -15
  233. package/dist/lib/components/navigation/utils.js.map +1 -1
  234. package/dist/lib/core/RouteGuard.d.ts +2 -0
  235. package/dist/lib/core/RouteGuard.js +52 -0
  236. package/dist/lib/core/RouteGuard.js.map +1 -0
  237. package/dist/lib/core/ZudokuContext.d.ts +99 -0
  238. package/dist/lib/core/ZudokuContext.js +69 -0
  239. package/dist/lib/core/ZudokuContext.js.map +1 -0
  240. package/dist/lib/core/plugins.d.ts +32 -17
  241. package/dist/lib/core/plugins.js +3 -0
  242. package/dist/lib/core/plugins.js.map +1 -1
  243. package/dist/lib/errors/ErrorAlert.d.ts +1 -1
  244. package/dist/lib/errors/ErrorAlert.js +13 -3
  245. package/dist/lib/errors/ErrorAlert.js.map +1 -1
  246. package/dist/lib/errors/RouterError.js +1 -1
  247. package/dist/lib/errors/RouterError.js.map +1 -1
  248. package/dist/lib/hooks/index.d.ts +3 -0
  249. package/dist/lib/hooks/index.js +5 -0
  250. package/dist/lib/hooks/index.js.map +1 -0
  251. package/dist/lib/hooks/useEvent.d.ts +11 -0
  252. package/dist/lib/hooks/useEvent.js +19 -0
  253. package/dist/lib/hooks/useEvent.js.map +1 -0
  254. package/dist/lib/hooks/useEvent.test.js +100 -0
  255. package/dist/lib/hooks/useEvent.test.js.map +1 -0
  256. package/dist/lib/icons.d.ts +1 -0
  257. package/dist/lib/icons.js +1 -0
  258. package/dist/lib/icons.js.map +1 -1
  259. package/dist/lib/oas/graphql/circular.d.ts +3 -0
  260. package/dist/lib/oas/graphql/circular.js +38 -0
  261. package/dist/lib/oas/graphql/circular.js.map +1 -0
  262. package/dist/lib/oas/graphql/index.d.ts +26 -1
  263. package/dist/lib/oas/graphql/index.js +229 -74
  264. package/dist/lib/oas/graphql/index.js.map +1 -1
  265. package/dist/lib/oas/parser/dereference/index.js +8 -3
  266. package/dist/lib/oas/parser/dereference/index.js.map +1 -1
  267. package/dist/lib/oas/parser/index.d.ts +6 -3
  268. package/dist/lib/oas/parser/index.js +0 -22
  269. package/dist/lib/oas/parser/index.js.map +1 -1
  270. package/dist/lib/oas/parser/upgrade/index.d.ts +2 -2
  271. package/dist/lib/oas/parser/upgrade/index.js +21 -21
  272. package/dist/lib/oas/parser/upgrade/index.js.map +1 -1
  273. package/dist/lib/plugins/api-catalog/Catalog.d.ts +4 -0
  274. package/dist/lib/plugins/api-catalog/Catalog.js +26 -0
  275. package/dist/lib/plugins/api-catalog/Catalog.js.map +1 -0
  276. package/dist/lib/plugins/api-catalog/index.d.ts +31 -0
  277. package/dist/lib/plugins/api-catalog/index.js +46 -0
  278. package/dist/lib/plugins/api-catalog/index.js.map +1 -0
  279. package/dist/lib/plugins/api-keys/CreateApiKey.js +9 -5
  280. package/dist/lib/plugins/api-keys/CreateApiKey.js.map +1 -1
  281. package/dist/lib/plugins/api-keys/ProtectedRoute.js +1 -1
  282. package/dist/lib/plugins/api-keys/ProtectedRoute.js.map +1 -1
  283. package/dist/lib/plugins/api-keys/SettingsApiKeys.js +1 -1
  284. package/dist/lib/plugins/api-keys/SettingsApiKeys.js.map +1 -1
  285. package/dist/lib/plugins/api-keys/index.d.ts +10 -9
  286. package/dist/lib/plugins/api-keys/index.js +4 -0
  287. package/dist/lib/plugins/api-keys/index.js.map +1 -1
  288. package/dist/lib/plugins/custom-pages/CustomPage.d.ts +2 -0
  289. package/dist/lib/plugins/custom-pages/CustomPage.js +11 -0
  290. package/dist/lib/plugins/custom-pages/CustomPage.js.map +1 -0
  291. package/dist/lib/plugins/custom-pages/index.d.ts +10 -0
  292. package/dist/lib/plugins/custom-pages/index.js +11 -0
  293. package/dist/lib/plugins/custom-pages/index.js.map +1 -0
  294. package/dist/lib/plugins/markdown/MdxPage.d.ts +10 -2
  295. package/dist/lib/plugins/markdown/MdxPage.js +18 -5
  296. package/dist/lib/plugins/markdown/MdxPage.js.map +1 -1
  297. package/dist/lib/plugins/markdown/index.d.ts +8 -6
  298. package/dist/lib/plugins/markdown/index.js +31 -3
  299. package/dist/lib/plugins/markdown/index.js.map +1 -1
  300. package/dist/lib/plugins/markdown/resolver.d.ts +32 -0
  301. package/dist/lib/plugins/markdown/resolver.js +46 -0
  302. package/dist/lib/plugins/markdown/resolver.js.map +1 -0
  303. package/dist/lib/plugins/openapi/CollapsibleCode.d.ts +5 -0
  304. package/dist/lib/plugins/openapi/CollapsibleCode.js +25 -0
  305. package/dist/lib/plugins/openapi/CollapsibleCode.js.map +1 -0
  306. package/dist/lib/plugins/openapi/ColorizedParam.d.ts +10 -2
  307. package/dist/lib/plugins/openapi/ColorizedParam.js +29 -14
  308. package/dist/lib/plugins/openapi/ColorizedParam.js.map +1 -1
  309. package/dist/lib/plugins/openapi/Endpoint.d.ts +1 -3
  310. package/dist/lib/plugins/openapi/Endpoint.js +43 -8
  311. package/dist/lib/plugins/openapi/Endpoint.js.map +1 -1
  312. package/dist/lib/plugins/openapi/OasProvider.d.ts +8 -0
  313. package/dist/lib/plugins/openapi/OasProvider.js +29 -0
  314. package/dist/lib/plugins/openapi/OasProvider.js.map +1 -0
  315. package/dist/lib/plugins/openapi/OperationList.d.ts +6 -3
  316. package/dist/lib/plugins/openapi/OperationList.js +105 -27
  317. package/dist/lib/plugins/openapi/OperationList.js.map +1 -1
  318. package/dist/lib/plugins/openapi/OperationListItem.d.ts +5 -3
  319. package/dist/lib/plugins/openapi/OperationListItem.js +10 -5
  320. package/dist/lib/plugins/openapi/OperationListItem.js.map +1 -1
  321. package/dist/lib/plugins/openapi/ParamInfos.d.ts +6 -0
  322. package/dist/lib/plugins/openapi/ParamInfos.js +42 -0
  323. package/dist/lib/plugins/openapi/ParamInfos.js.map +1 -0
  324. package/dist/lib/plugins/openapi/ParameterList.d.ts +2 -1
  325. package/dist/lib/plugins/openapi/ParameterList.js +3 -2
  326. package/dist/lib/plugins/openapi/ParameterList.js.map +1 -1
  327. package/dist/lib/plugins/openapi/ParameterListItem.js +12 -1
  328. package/dist/lib/plugins/openapi/ParameterListItem.js.map +1 -1
  329. package/dist/lib/plugins/openapi/PlaygroundDialogWrapper.d.ts +5 -2
  330. package/dist/lib/plugins/openapi/PlaygroundDialogWrapper.js +12 -3
  331. package/dist/lib/plugins/openapi/PlaygroundDialogWrapper.js.map +1 -1
  332. package/dist/lib/plugins/openapi/RequestBodySidecarBox.d.ts +3 -4
  333. package/dist/lib/plugins/openapi/RequestBodySidecarBox.js +5 -9
  334. package/dist/lib/plugins/openapi/RequestBodySidecarBox.js.map +1 -1
  335. package/dist/lib/plugins/openapi/ResponsesSidecarBox.js +7 -6
  336. package/dist/lib/plugins/openapi/ResponsesSidecarBox.js.map +1 -1
  337. package/dist/lib/plugins/openapi/SchemaList.d.ts +1 -0
  338. package/dist/lib/plugins/openapi/SchemaList.js +52 -0
  339. package/dist/lib/plugins/openapi/SchemaList.js.map +1 -0
  340. package/dist/lib/plugins/openapi/Sidecar.d.ts +1 -1
  341. package/dist/lib/plugins/openapi/Sidecar.js +90 -60
  342. package/dist/lib/plugins/openapi/Sidecar.js.map +1 -1
  343. package/dist/lib/plugins/openapi/SidecarBox.js +4 -4
  344. package/dist/lib/plugins/openapi/SidecarBox.js.map +1 -1
  345. package/dist/lib/plugins/openapi/SidecarExamples.d.ts +9 -0
  346. package/dist/lib/plugins/openapi/SidecarExamples.js +68 -0
  347. package/dist/lib/plugins/openapi/SidecarExamples.js.map +1 -0
  348. package/dist/lib/plugins/openapi/SimpleSelect.d.ts +2 -1
  349. package/dist/lib/plugins/openapi/SimpleSelect.js +1 -1
  350. package/dist/lib/plugins/openapi/SimpleSelect.js.map +1 -1
  351. package/dist/lib/plugins/openapi/client/GraphQLClient.d.ts +8 -0
  352. package/dist/lib/plugins/openapi/client/GraphQLClient.js +43 -0
  353. package/dist/lib/plugins/openapi/client/GraphQLClient.js.map +1 -0
  354. package/dist/lib/plugins/openapi/client/GraphQLContext.d.ts +7 -0
  355. package/dist/lib/plugins/openapi/client/GraphQLContext.js +5 -0
  356. package/dist/lib/plugins/openapi/client/GraphQLContext.js.map +1 -0
  357. package/dist/lib/plugins/openapi/client/createServer.d.ts +3 -1
  358. package/dist/lib/plugins/openapi/client/createServer.js +5 -2
  359. package/dist/lib/plugins/openapi/client/createServer.js.map +1 -1
  360. package/dist/lib/plugins/openapi/client/useCreateQuery.d.ts +9 -0
  361. package/dist/lib/plugins/openapi/client/useCreateQuery.js +14 -0
  362. package/dist/lib/plugins/openapi/client/useCreateQuery.js.map +1 -0
  363. package/dist/lib/plugins/openapi/components/EnumValues.d.ts +5 -0
  364. package/dist/lib/plugins/openapi/components/EnumValues.js +15 -0
  365. package/dist/lib/plugins/openapi/components/EnumValues.js.map +1 -0
  366. package/dist/lib/plugins/openapi/components/SelectOnClick.d.ts +5 -0
  367. package/dist/lib/plugins/openapi/components/SelectOnClick.js +16 -0
  368. package/dist/lib/plugins/openapi/components/SelectOnClick.js.map +1 -0
  369. package/dist/lib/plugins/openapi/context.d.ts +3 -3
  370. package/dist/lib/plugins/openapi/graphql/fragment-masking.d.ts +3 -3
  371. package/dist/lib/plugins/openapi/graphql/fragment-masking.js +3 -4
  372. package/dist/lib/plugins/openapi/graphql/fragment-masking.js.map +1 -1
  373. package/dist/lib/plugins/openapi/graphql/gql.d.ts +11 -41
  374. package/dist/lib/plugins/openapi/graphql/gql.js +8 -14
  375. package/dist/lib/plugins/openapi/graphql/gql.js.map +1 -1
  376. package/dist/lib/plugins/openapi/graphql/graphql.d.ts +168 -26
  377. package/dist/lib/plugins/openapi/graphql/graphql.js +238 -575
  378. package/dist/lib/plugins/openapi/graphql/graphql.js.map +1 -1
  379. package/dist/lib/plugins/openapi/index.d.ts +11 -7
  380. package/dist/lib/plugins/openapi/index.js +72 -104
  381. package/dist/lib/plugins/openapi/index.js.map +1 -1
  382. package/dist/lib/plugins/openapi/interfaces.d.ts +59 -3
  383. package/dist/lib/plugins/openapi/playground/ExamplesDropdown.d.ts +6 -0
  384. package/dist/lib/plugins/openapi/playground/ExamplesDropdown.js +8 -0
  385. package/dist/lib/plugins/openapi/playground/ExamplesDropdown.js.map +1 -0
  386. package/dist/lib/plugins/openapi/playground/Headers.d.ts +4 -4
  387. package/dist/lib/plugins/openapi/playground/Headers.js +84 -5
  388. package/dist/lib/plugins/openapi/playground/Headers.js.map +1 -1
  389. package/dist/lib/plugins/openapi/playground/IdentityDialog.d.ts +11 -0
  390. package/dist/lib/plugins/openapi/playground/IdentityDialog.js +14 -0
  391. package/dist/lib/plugins/openapi/playground/IdentityDialog.js.map +1 -0
  392. package/dist/lib/plugins/openapi/playground/IdentitySelector.d.ts +7 -0
  393. package/dist/lib/plugins/openapi/playground/IdentitySelector.js +10 -0
  394. package/dist/lib/plugins/openapi/playground/IdentitySelector.js.map +1 -0
  395. package/dist/lib/plugins/openapi/playground/ParamsGrid.d.ts +9 -0
  396. package/dist/lib/plugins/openapi/playground/ParamsGrid.js +5 -0
  397. package/dist/lib/plugins/openapi/playground/ParamsGrid.js.map +1 -0
  398. package/dist/lib/plugins/openapi/playground/PathParams.d.ts +3 -2
  399. package/dist/lib/plugins/openapi/playground/PathParams.js +5 -7
  400. package/dist/lib/plugins/openapi/playground/PathParams.js.map +1 -1
  401. package/dist/lib/plugins/openapi/playground/Playground.d.ts +38 -2
  402. package/dist/lib/plugins/openapi/playground/Playground.js +134 -63
  403. package/dist/lib/plugins/openapi/playground/Playground.js.map +1 -1
  404. package/dist/lib/plugins/openapi/playground/PlaygroundDialog.js +2 -2
  405. package/dist/lib/plugins/openapi/playground/PlaygroundDialog.js.map +1 -1
  406. package/dist/lib/plugins/openapi/playground/QueryParams.js +24 -18
  407. package/dist/lib/plugins/openapi/playground/QueryParams.js.map +1 -1
  408. package/dist/lib/plugins/openapi/playground/RequestLoginDialog.d.ts +7 -0
  409. package/dist/lib/plugins/openapi/playground/RequestLoginDialog.js +8 -0
  410. package/dist/lib/plugins/openapi/playground/RequestLoginDialog.js.map +1 -0
  411. package/dist/lib/plugins/openapi/playground/SubmitButton.d.ts +7 -0
  412. package/dist/lib/plugins/openapi/playground/SubmitButton.js +22 -0
  413. package/dist/lib/plugins/openapi/playground/SubmitButton.js.map +1 -0
  414. package/dist/lib/plugins/openapi/playground/createUrl.js +3 -1
  415. package/dist/lib/plugins/openapi/playground/createUrl.js.map +1 -1
  416. package/dist/lib/plugins/openapi/playground/rememberedIdentity.d.ts +17 -0
  417. package/dist/lib/plugins/openapi/playground/rememberedIdentity.js +11 -0
  418. package/dist/lib/plugins/openapi/playground/rememberedIdentity.js.map +1 -0
  419. package/dist/lib/plugins/openapi/playground/result-panel/RequestTab.d.ts +7 -0
  420. package/dist/lib/plugins/openapi/playground/result-panel/RequestTab.js +11 -0
  421. package/dist/lib/plugins/openapi/playground/result-panel/RequestTab.js.map +1 -0
  422. package/dist/lib/plugins/openapi/playground/result-panel/ResponseTab.d.ts +8 -0
  423. package/dist/lib/plugins/openapi/playground/result-panel/ResponseTab.js +101 -0
  424. package/dist/lib/plugins/openapi/playground/result-panel/ResponseTab.js.map +1 -0
  425. package/dist/lib/plugins/openapi/playground/result-panel/ResultPanel.d.ts +9 -0
  426. package/dist/lib/plugins/openapi/playground/result-panel/ResultPanel.js +17 -0
  427. package/dist/lib/plugins/openapi/playground/result-panel/ResultPanel.js.map +1 -0
  428. package/dist/lib/plugins/openapi/playground/result-panel/convertToTypes.d.ts +10 -0
  429. package/dist/lib/plugins/openapi/playground/result-panel/convertToTypes.js +32 -0
  430. package/dist/lib/plugins/openapi/playground/result-panel/convertToTypes.js.map +1 -0
  431. package/dist/lib/plugins/openapi/playground/result-panel/convertToTypes.test.js +56 -0
  432. package/dist/lib/plugins/openapi/playground/result-panel/convertToTypes.test.js.map +1 -0
  433. package/dist/lib/plugins/openapi/processors/removeExtensions.d.ts +7 -0
  434. package/dist/lib/plugins/openapi/processors/removeExtensions.js +16 -0
  435. package/dist/lib/plugins/openapi/processors/removeExtensions.js.map +1 -0
  436. package/dist/lib/plugins/openapi/processors/removeExtensions.test.d.ts +1 -0
  437. package/dist/lib/plugins/openapi/processors/removeExtensions.test.js +174 -0
  438. package/dist/lib/plugins/openapi/processors/removeExtensions.test.js.map +1 -0
  439. package/dist/lib/plugins/openapi/processors/removeParameters.d.ts +10 -0
  440. package/dist/lib/plugins/openapi/processors/removeParameters.js +66 -0
  441. package/dist/lib/plugins/openapi/processors/removeParameters.js.map +1 -0
  442. package/dist/lib/plugins/openapi/processors/removeParameters.test.d.ts +1 -0
  443. package/dist/lib/plugins/openapi/processors/removeParameters.test.js +131 -0
  444. package/dist/lib/plugins/openapi/processors/removeParameters.test.js.map +1 -0
  445. package/dist/lib/plugins/openapi/processors/removePaths.d.ts +11 -0
  446. package/dist/lib/plugins/openapi/processors/removePaths.js +33 -0
  447. package/dist/lib/plugins/openapi/processors/removePaths.js.map +1 -0
  448. package/dist/lib/plugins/openapi/processors/removePaths.test.d.ts +1 -0
  449. package/dist/lib/plugins/openapi/processors/removePaths.test.js +104 -0
  450. package/dist/lib/plugins/openapi/processors/removePaths.test.js.map +1 -0
  451. package/dist/lib/plugins/openapi/processors/traverse.d.ts +1 -0
  452. package/dist/lib/plugins/openapi/processors/traverse.js +2 -0
  453. package/dist/lib/plugins/openapi/processors/traverse.js.map +1 -0
  454. package/dist/lib/plugins/openapi/schema/LogicalGroup/LogicalGroup.d.ts +1 -2
  455. package/dist/lib/plugins/openapi/schema/LogicalGroup/LogicalGroup.js +2 -2
  456. package/dist/lib/plugins/openapi/schema/LogicalGroup/LogicalGroup.js.map +1 -1
  457. package/dist/lib/plugins/openapi/schema/LogicalGroup/LogicalGroupConnector.d.ts +2 -1
  458. package/dist/lib/plugins/openapi/schema/LogicalGroup/LogicalGroupConnector.js +2 -2
  459. package/dist/lib/plugins/openapi/schema/LogicalGroup/LogicalGroupConnector.js.map +1 -1
  460. package/dist/lib/plugins/openapi/schema/LogicalGroup/LogicalGroupItem.d.ts +0 -1
  461. package/dist/lib/plugins/openapi/schema/LogicalGroup/LogicalGroupItem.js +1 -1
  462. package/dist/lib/plugins/openapi/schema/LogicalGroup/LogicalGroupItem.js.map +1 -1
  463. package/dist/lib/plugins/openapi/schema/SchemaExampleAndDefault.d.ts +4 -0
  464. package/dist/lib/plugins/openapi/schema/SchemaExampleAndDefault.js +12 -0
  465. package/dist/lib/plugins/openapi/schema/SchemaExampleAndDefault.js.map +1 -0
  466. package/dist/lib/plugins/openapi/schema/{SchemaComponents.d.ts → SchemaPropertyItem.d.ts} +2 -4
  467. package/dist/lib/plugins/openapi/schema/SchemaPropertyItem.js +42 -0
  468. package/dist/lib/plugins/openapi/schema/SchemaPropertyItem.js.map +1 -0
  469. package/dist/lib/plugins/openapi/schema/SchemaView.d.ts +1 -2
  470. package/dist/lib/plugins/openapi/schema/SchemaView.js +34 -48
  471. package/dist/lib/plugins/openapi/schema/SchemaView.js.map +1 -1
  472. package/dist/lib/plugins/openapi/schema/utils.d.ts +2 -0
  473. package/dist/lib/plugins/openapi/schema/utils.js +5 -1
  474. package/dist/lib/plugins/openapi/schema/utils.js.map +1 -1
  475. package/dist/lib/plugins/openapi/state.d.ts +25 -0
  476. package/dist/lib/plugins/openapi/state.js +18 -0
  477. package/dist/lib/plugins/openapi/state.js.map +1 -0
  478. package/dist/lib/plugins/openapi/util/createSidebarCategory.d.ts +9 -0
  479. package/dist/lib/plugins/openapi/util/createSidebarCategory.js +23 -0
  480. package/dist/lib/plugins/openapi/util/createSidebarCategory.js.map +1 -0
  481. package/dist/lib/plugins/openapi/util/generateSchemaExample.d.ts +0 -1
  482. package/dist/lib/plugins/openapi/util/generateSchemaExample.js +36 -39
  483. package/dist/lib/plugins/openapi/util/generateSchemaExample.js.map +1 -1
  484. package/dist/lib/plugins/openapi/util/getRoutes.d.ts +10 -0
  485. package/dist/lib/plugins/openapi/util/getRoutes.js +80 -0
  486. package/dist/lib/plugins/openapi/util/getRoutes.js.map +1 -0
  487. package/dist/lib/plugins/openapi/util/methodColorMap.d.ts +2 -0
  488. package/dist/lib/plugins/openapi/util/methodColorMap.js +10 -0
  489. package/dist/lib/plugins/openapi/util/methodColorMap.js.map +1 -0
  490. package/dist/lib/plugins/openapi/util/methodToColor.d.ts +20 -0
  491. package/dist/lib/plugins/openapi/util/methodToColor.js +24 -0
  492. package/dist/lib/plugins/openapi/util/methodToColor.js.map +1 -0
  493. package/dist/lib/plugins/openapi/util/sanitizeMarkdownForMetatag.d.ts +1 -0
  494. package/dist/lib/plugins/openapi/util/sanitizeMarkdownForMetatag.js +27 -0
  495. package/dist/lib/plugins/openapi/util/sanitizeMarkdownForMetatag.js.map +1 -0
  496. package/dist/lib/plugins/redirect/index.d.ts +4 -7
  497. package/dist/lib/plugins/redirect/index.js +2 -2
  498. package/dist/lib/plugins/redirect/index.js.map +1 -1
  499. package/dist/lib/plugins/search-inkeep/index.d.ts +24 -5
  500. package/dist/lib/plugins/search-inkeep/index.js +41 -5
  501. package/dist/lib/plugins/search-inkeep/index.js.map +1 -1
  502. package/dist/lib/plugins/search-inkeep/inkeep.d.ts +3 -4
  503. package/dist/lib/plugins/search-inkeep/inkeep.js.map +1 -1
  504. package/dist/lib/plugins/search-pagefind/PagefindSearch.d.ts +6 -0
  505. package/dist/lib/plugins/search-pagefind/PagefindSearch.js +80 -0
  506. package/dist/lib/plugins/search-pagefind/PagefindSearch.js.map +1 -0
  507. package/dist/lib/plugins/search-pagefind/ResultList.d.ts +8 -0
  508. package/dist/lib/plugins/search-pagefind/ResultList.js +32 -0
  509. package/dist/lib/plugins/search-pagefind/ResultList.js.map +1 -0
  510. package/dist/lib/plugins/search-pagefind/get-results.d.ts +10 -0
  511. package/dist/lib/plugins/search-pagefind/get-results.js +42 -0
  512. package/dist/lib/plugins/search-pagefind/get-results.js.map +1 -0
  513. package/dist/lib/plugins/search-pagefind/index.d.ts +6 -0
  514. package/dist/lib/plugins/search-pagefind/index.js +9 -0
  515. package/dist/lib/plugins/search-pagefind/index.js.map +1 -0
  516. package/dist/lib/plugins/search-pagefind/types.d.ts +85 -0
  517. package/dist/lib/plugins/search-pagefind/types.js +2 -0
  518. package/dist/lib/plugins/search-pagefind/types.js.map +1 -0
  519. package/dist/lib/ui/Accordion.d.ts +7 -0
  520. package/dist/lib/ui/Accordion.js +14 -0
  521. package/dist/lib/ui/Accordion.js.map +1 -0
  522. package/dist/lib/ui/ActionButton.d.ts +4 -0
  523. package/dist/lib/ui/ActionButton.js +10 -0
  524. package/dist/lib/ui/ActionButton.js.map +1 -0
  525. package/dist/lib/ui/Alert.d.ts +8 -0
  526. package/dist/lib/ui/Alert.js +23 -0
  527. package/dist/lib/ui/Alert.js.map +1 -0
  528. package/dist/lib/ui/AlertDialog.d.ts +20 -0
  529. package/dist/lib/ui/AlertDialog.js +27 -0
  530. package/dist/lib/ui/AlertDialog.js.map +1 -0
  531. package/dist/lib/ui/AspectRatio.d.ts +3 -0
  532. package/dist/lib/ui/AspectRatio.js +4 -0
  533. package/dist/lib/ui/AspectRatio.js.map +1 -0
  534. package/dist/lib/ui/Badge.d.ts +9 -0
  535. package/dist/lib/ui/Badge.js +22 -0
  536. package/dist/lib/ui/Badge.js.map +1 -0
  537. package/dist/lib/ui/Breadcrumb.d.ts +19 -0
  538. package/dist/lib/ui/Breadcrumb.js +24 -0
  539. package/dist/lib/ui/Breadcrumb.js.map +1 -0
  540. package/dist/lib/ui/Button.d.ts +3 -4
  541. package/dist/lib/ui/Button.js +2 -1
  542. package/dist/lib/ui/Button.js.map +1 -1
  543. package/dist/lib/ui/Callout.d.ts +38 -36
  544. package/dist/lib/ui/Callout.js +3 -2
  545. package/dist/lib/ui/Callout.js.map +1 -1
  546. package/dist/lib/ui/Card.js +1 -1
  547. package/dist/lib/ui/Card.js.map +1 -1
  548. package/dist/lib/ui/Carousel.d.ts +18 -0
  549. package/dist/lib/ui/Carousel.js +99 -0
  550. package/dist/lib/ui/Carousel.js.map +1 -0
  551. package/dist/lib/ui/Checkbox.d.ts +4 -0
  552. package/dist/lib/ui/Checkbox.js +9 -0
  553. package/dist/lib/ui/Checkbox.js.map +1 -0
  554. package/dist/lib/ui/Collapsible.d.ts +5 -0
  555. package/dist/lib/ui/Collapsible.js +6 -0
  556. package/dist/lib/ui/Collapsible.js.map +1 -0
  557. package/dist/lib/ui/Command.d.ts +94 -0
  558. package/dist/lib/ui/Command.js +35 -0
  559. package/dist/lib/ui/Command.js.map +1 -0
  560. package/dist/lib/{components → ui}/Dialog.js +2 -2
  561. package/dist/lib/ui/Dialog.js.map +1 -0
  562. package/dist/lib/ui/Drawer.d.ts +8 -10
  563. package/dist/lib/ui/Drawer.js.map +1 -1
  564. package/dist/lib/ui/Form.d.ts +23 -0
  565. package/dist/lib/ui/Form.js +63 -0
  566. package/dist/lib/ui/Form.js.map +1 -0
  567. package/dist/lib/ui/HoverCard.d.ts +6 -0
  568. package/dist/lib/ui/HoverCard.js +10 -0
  569. package/dist/lib/ui/HoverCard.js.map +1 -0
  570. package/dist/lib/ui/Input.d.ts +1 -2
  571. package/dist/lib/ui/Input.js.map +1 -1
  572. package/dist/lib/ui/Label.d.ts +5 -0
  573. package/dist/lib/ui/Label.js +10 -0
  574. package/dist/lib/ui/Label.js.map +1 -0
  575. package/dist/lib/ui/Pagination.d.ts +28 -0
  576. package/dist/lib/ui/Pagination.js +24 -0
  577. package/dist/lib/ui/Pagination.js.map +1 -0
  578. package/dist/lib/ui/Popover.d.ts +6 -0
  579. package/dist/lib/ui/Popover.js +10 -0
  580. package/dist/lib/ui/Popover.js.map +1 -0
  581. package/dist/lib/ui/Progress.d.ts +4 -0
  582. package/dist/lib/ui/Progress.js +8 -0
  583. package/dist/lib/ui/Progress.js.map +1 -0
  584. package/dist/lib/ui/RadioGroup.d.ts +5 -0
  585. package/dist/lib/ui/RadioGroup.js +15 -0
  586. package/dist/lib/ui/RadioGroup.js.map +1 -0
  587. package/dist/lib/ui/ScrollArea.d.ts +5 -0
  588. package/dist/lib/ui/ScrollArea.js +12 -0
  589. package/dist/lib/ui/ScrollArea.js.map +1 -0
  590. package/dist/lib/{components → ui}/Select.js +3 -3
  591. package/dist/lib/ui/Select.js.map +1 -0
  592. package/dist/lib/ui/Skeleton.d.ts +2 -0
  593. package/dist/lib/ui/Skeleton.js +7 -0
  594. package/dist/lib/ui/Skeleton.js.map +1 -0
  595. package/dist/lib/ui/Slider.d.ts +4 -0
  596. package/dist/lib/ui/Slider.js +8 -0
  597. package/dist/lib/ui/Slider.js.map +1 -0
  598. package/dist/lib/ui/Stepper.d.ts +3 -0
  599. package/dist/lib/ui/Stepper.js +7 -0
  600. package/dist/lib/ui/Stepper.js.map +1 -0
  601. package/dist/lib/ui/Switch.d.ts +4 -0
  602. package/dist/lib/ui/Switch.js +8 -0
  603. package/dist/lib/ui/Switch.js.map +1 -0
  604. package/dist/lib/ui/SyntaxHighlight.d.ts +15 -0
  605. package/dist/lib/ui/SyntaxHighlight.js +62 -0
  606. package/dist/lib/ui/SyntaxHighlight.js.map +1 -0
  607. package/dist/lib/ui/Textarea.d.ts +4 -0
  608. package/dist/lib/ui/Textarea.js +9 -0
  609. package/dist/lib/ui/Textarea.js.map +1 -0
  610. package/dist/lib/ui/Toggle.d.ts +12 -0
  611. package/dist/lib/ui/Toggle.js +26 -0
  612. package/dist/lib/ui/Toggle.js.map +1 -0
  613. package/dist/lib/ui/ToggleGroup.d.ts +12 -0
  614. package/dist/lib/ui/ToggleGroup.js +21 -0
  615. package/dist/lib/ui/ToggleGroup.js.map +1 -0
  616. package/dist/lib/ui/Tooltip.d.ts +7 -0
  617. package/dist/lib/ui/Tooltip.js +11 -0
  618. package/dist/lib/ui/Tooltip.js.map +1 -0
  619. package/dist/lib/ui/util.d.ts +2 -0
  620. package/dist/lib/ui/util.js +3 -0
  621. package/dist/lib/ui/util.js.map +1 -0
  622. package/dist/lib/util/MdxComponents.d.ts +24 -21
  623. package/dist/lib/util/MdxComponents.js +10 -7
  624. package/dist/lib/util/MdxComponents.js.map +1 -1
  625. package/dist/lib/util/createVariantComponent.d.ts +2 -2
  626. package/dist/lib/util/detectOS.d.ts +1 -0
  627. package/dist/lib/util/detectOS.js +11 -0
  628. package/dist/lib/util/detectOS.js.map +1 -0
  629. package/dist/lib/util/invariant.d.ts +9 -0
  630. package/dist/lib/util/invariant.js +7 -3
  631. package/dist/lib/util/invariant.js.map +1 -1
  632. package/dist/lib/util/joinPath.d.ts +3 -0
  633. package/dist/lib/util/joinPath.js +3 -0
  634. package/dist/lib/util/joinPath.js.map +1 -1
  635. package/dist/lib/util/joinUrl.d.ts +1 -0
  636. package/dist/lib/util/joinUrl.js +40 -0
  637. package/dist/lib/util/joinUrl.js.map +1 -0
  638. package/dist/lib/util/joinUrl.test.d.ts +1 -0
  639. package/dist/lib/util/joinUrl.test.js +43 -0
  640. package/dist/lib/util/joinUrl.test.js.map +1 -0
  641. package/dist/lib/util/scrollIntoViewIfNeeded.d.ts +1 -0
  642. package/dist/lib/util/scrollIntoViewIfNeeded.js +14 -0
  643. package/dist/lib/util/scrollIntoViewIfNeeded.js.map +1 -0
  644. package/dist/lib/util/traverse.d.ts +3 -0
  645. package/dist/lib/util/traverse.js +22 -0
  646. package/dist/lib/util/traverse.js.map +1 -0
  647. package/dist/lib/util/types.d.ts +7 -0
  648. package/dist/lib/util/types.js +2 -0
  649. package/dist/lib/util/types.js.map +1 -0
  650. package/dist/lib/util/useExposedProps.d.ts +2 -0
  651. package/dist/lib/util/useExposedProps.js +9 -0
  652. package/dist/lib/util/useExposedProps.js.map +1 -0
  653. package/dist/lib/util/useIsomorphicLayoutEffect.d.ts +3 -0
  654. package/dist/lib/util/useIsomorphicLayoutEffect.js +4 -0
  655. package/dist/lib/util/useIsomorphicLayoutEffect.js.map +1 -0
  656. package/dist/lib/util/useLatest.d.ts +1 -0
  657. package/dist/lib/util/useLatest.js +15 -0
  658. package/dist/lib/util/useLatest.js.map +1 -0
  659. package/dist/lib/util/useOnScreen.d.ts +5 -0
  660. package/dist/lib/util/useOnScreen.js +19 -0
  661. package/dist/lib/util/useOnScreen.js.map +1 -0
  662. package/dist/lib/util/useScrollToAnchor.d.ts +1 -0
  663. package/dist/lib/util/useScrollToAnchor.js +42 -37
  664. package/dist/lib/util/useScrollToAnchor.js.map +1 -1
  665. package/dist/lib/util/useScrollToTop.js +7 -5
  666. package/dist/lib/util/useScrollToTop.js.map +1 -1
  667. package/dist/vite/api/schema-codegen.d.ts +12 -0
  668. package/dist/vite/api/schema-codegen.js +85 -0
  669. package/dist/vite/api/schema-codegen.js.map +1 -0
  670. package/dist/vite/api/schema-codegen.test.d.ts +1 -0
  671. package/dist/vite/api/schema-codegen.test.js +313 -0
  672. package/dist/vite/api/schema-codegen.test.js.map +1 -0
  673. package/dist/vite/build.js +47 -13
  674. package/dist/vite/build.js.map +1 -1
  675. package/dist/vite/config.d.ts +8 -15
  676. package/dist/vite/config.js +133 -118
  677. package/dist/vite/config.js.map +1 -1
  678. package/dist/vite/config.test.js +11 -5
  679. package/dist/vite/config.test.js.map +1 -1
  680. package/dist/vite/create-pagefind-index.d.ts +4 -0
  681. package/dist/vite/create-pagefind-index.js +12 -0
  682. package/dist/vite/create-pagefind-index.js.map +1 -0
  683. package/dist/vite/css/collect.d.ts +2 -0
  684. package/dist/vite/css/collect.js +27 -0
  685. package/dist/vite/css/collect.js.map +1 -0
  686. package/dist/vite/css/plugin.d.ts +5 -0
  687. package/dist/vite/css/plugin.js +79 -0
  688. package/dist/vite/css/plugin.js.map +1 -0
  689. package/dist/vite/debug.d.ts +1 -0
  690. package/dist/vite/debug.js +10 -0
  691. package/dist/vite/debug.js.map +1 -0
  692. package/dist/vite/dev-server.d.ts +12 -3
  693. package/dist/vite/dev-server.js +79 -25
  694. package/dist/vite/dev-server.js.map +1 -1
  695. package/dist/vite/error-handler.d.ts +1 -1
  696. package/dist/vite/error-handler.js +1 -1
  697. package/dist/vite/error-handler.js.map +1 -1
  698. package/dist/vite/html.js +0 -2
  699. package/dist/vite/html.js.map +1 -1
  700. package/dist/vite/output.d.ts +113 -0
  701. package/dist/vite/output.js +60 -0
  702. package/dist/vite/output.js.map +1 -0
  703. package/dist/vite/plugin-api-keys.d.ts +2 -2
  704. package/dist/vite/plugin-api-keys.js +5 -5
  705. package/dist/vite/plugin-api-keys.js.map +1 -1
  706. package/dist/vite/plugin-api.d.ts +2 -2
  707. package/dist/vite/plugin-api.js +223 -35
  708. package/dist/vite/plugin-api.js.map +1 -1
  709. package/dist/vite/plugin-auth.d.ts +2 -2
  710. package/dist/vite/plugin-auth.js +7 -4
  711. package/dist/vite/plugin-auth.js.map +1 -1
  712. package/dist/vite/plugin-component.d.ts +2 -2
  713. package/dist/vite/plugin-component.js +22 -13
  714. package/dist/vite/plugin-component.js.map +1 -1
  715. package/dist/vite/plugin-config-reload.d.ts +4 -4
  716. package/dist/vite/plugin-config-reload.js +18 -8
  717. package/dist/vite/plugin-config-reload.js.map +1 -1
  718. package/dist/vite/plugin-config.d.ts +2 -3
  719. package/dist/vite/plugin-config.js +26 -3
  720. package/dist/vite/plugin-config.js.map +1 -1
  721. package/dist/vite/plugin-custom-pages.d.ts +4 -0
  722. package/dist/vite/plugin-custom-pages.js +30 -0
  723. package/dist/vite/plugin-custom-pages.js.map +1 -0
  724. package/dist/vite/plugin-docs.d.ts +3 -3
  725. package/dist/vite/plugin-docs.js +57 -27
  726. package/dist/vite/plugin-docs.js.map +1 -1
  727. package/dist/vite/plugin-docs.test.js +15 -23
  728. package/dist/vite/plugin-docs.test.js.map +1 -1
  729. package/dist/vite/plugin-frontmatter.d.ts +3 -0
  730. package/dist/vite/plugin-frontmatter.js +34 -0
  731. package/dist/vite/plugin-frontmatter.js.map +1 -0
  732. package/dist/vite/plugin-mdx.d.ts +2 -8
  733. package/dist/vite/plugin-mdx.js +97 -7
  734. package/dist/vite/plugin-mdx.js.map +1 -1
  735. package/dist/vite/plugin-redirect.d.ts +2 -2
  736. package/dist/vite/plugin-redirect.js +3 -3
  737. package/dist/vite/plugin-redirect.js.map +1 -1
  738. package/dist/vite/plugin-search.d.ts +3 -0
  739. package/dist/vite/plugin-search.js +30 -0
  740. package/dist/vite/plugin-search.js.map +1 -0
  741. package/dist/vite/plugin-sidebar.d.ts +2 -2
  742. package/dist/vite/plugin-sidebar.js +30 -7
  743. package/dist/vite/plugin-sidebar.js.map +1 -1
  744. package/dist/vite/{plugin-custom-css.d.ts → plugin-theme-css.d.ts} +3 -3
  745. package/dist/vite/plugin-theme-css.js +117 -0
  746. package/dist/vite/plugin-theme-css.js.map +1 -0
  747. package/dist/vite/plugin.d.ts +2 -3
  748. package/dist/vite/plugin.js +13 -7
  749. package/dist/vite/plugin.js.map +1 -1
  750. package/dist/vite/prerender/FileWritingResponse.d.ts +25 -0
  751. package/dist/vite/prerender/FileWritingResponse.js +51 -0
  752. package/dist/vite/prerender/FileWritingResponse.js.map +1 -0
  753. package/dist/vite/prerender/InMemoryResponse.d.ts +16 -0
  754. package/dist/vite/prerender/InMemoryResponse.js +32 -0
  755. package/dist/vite/prerender/InMemoryResponse.js.map +1 -0
  756. package/dist/vite/prerender/PrerenderResponse.d.ts +10 -0
  757. package/dist/vite/prerender/PrerenderResponse.js +2 -0
  758. package/dist/vite/prerender/PrerenderResponse.js.map +1 -0
  759. package/dist/vite/prerender/prerender.d.ts +15 -0
  760. package/dist/vite/prerender/prerender.js +109 -0
  761. package/dist/vite/prerender/prerender.js.map +1 -0
  762. package/dist/vite/prerender/worker.d.ts +13 -0
  763. package/dist/vite/prerender/worker.js +59 -0
  764. package/dist/vite/prerender/worker.js.map +1 -0
  765. package/dist/vite/remarkStaticGeneration.d.ts +3 -0
  766. package/dist/vite/remarkStaticGeneration.js +125 -0
  767. package/dist/vite/remarkStaticGeneration.js.map +1 -0
  768. package/dist/vite/reporter.d.ts +3 -0
  769. package/dist/vite/reporter.js +33 -0
  770. package/dist/vite/reporter.js.map +1 -0
  771. package/dist/vite/sitemap.d.ts +1 -1
  772. package/dist/vite/sitemap.js +2 -1
  773. package/dist/vite/sitemap.js.map +1 -1
  774. package/dist/zuplo/enrich-with-zuplo.d.ts +5 -0
  775. package/dist/zuplo/enrich-with-zuplo.js +184 -0
  776. package/dist/zuplo/enrich-with-zuplo.js.map +1 -0
  777. package/dist/zuplo/env.d.ts +7 -0
  778. package/dist/zuplo/env.js +12 -0
  779. package/dist/zuplo/env.js.map +1 -0
  780. package/dist/zuplo/policy-types.d.ts +33 -0
  781. package/dist/zuplo/policy-types.js +8 -0
  782. package/dist/zuplo/policy-types.js.map +1 -0
  783. package/dist/zuplo/with-zuplo-processors.d.ts +3 -0
  784. package/dist/zuplo/with-zuplo-processors.js +26 -0
  785. package/dist/zuplo/with-zuplo-processors.js.map +1 -0
  786. package/dist/zuplo/with-zuplo.d.ts +3 -0
  787. package/dist/zuplo/with-zuplo.js +13 -0
  788. package/dist/zuplo/with-zuplo.js.map +1 -0
  789. package/lib/AuthenticationPlugin-foqdvvkf.js +58 -0
  790. package/lib/AuthenticationPlugin-foqdvvkf.js.map +1 -0
  791. package/lib/Button-Fp19CMUr.js +49 -0
  792. package/lib/Button-Fp19CMUr.js.map +1 -0
  793. package/lib/Callout-Boqdgl-z.js +230 -0
  794. package/lib/Callout-Boqdgl-z.js.map +1 -0
  795. package/lib/CategoryHeading-DpB47wvk.js +10 -0
  796. package/lib/{CategoryHeading-XnFqN2lJ.js.map → CategoryHeading-DpB47wvk.js.map} +1 -1
  797. package/lib/ClientOnly-E7hGysn1.js +11 -0
  798. package/lib/ClientOnly-E7hGysn1.js.map +1 -0
  799. package/lib/Dialog-sbgekbjb.js +98 -0
  800. package/lib/Dialog-sbgekbjb.js.map +1 -0
  801. package/lib/Drawer-kDAfOq_2.js +1133 -0
  802. package/lib/Drawer-kDAfOq_2.js.map +1 -0
  803. package/lib/Markdown-CKXePgqR.js +16962 -0
  804. package/lib/Markdown-CKXePgqR.js.map +1 -0
  805. package/lib/MdxPage-DzpRK-fu.js +85 -0
  806. package/lib/MdxPage-DzpRK-fu.js.map +1 -0
  807. package/lib/OasProvider-Dw2mP5VZ.js +34 -0
  808. package/lib/OasProvider-Dw2mP5VZ.js.map +1 -0
  809. package/lib/OperationList-Cr_NA4e2.js +5069 -0
  810. package/lib/OperationList-Cr_NA4e2.js.map +1 -0
  811. package/lib/Pagination-DT6eKg_U.js +48 -0
  812. package/lib/Pagination-DT6eKg_U.js.map +1 -0
  813. package/lib/RouteGuard-CqZPoZYJ.js +744 -0
  814. package/lib/RouteGuard-CqZPoZYJ.js.map +1 -0
  815. package/lib/SchemaList-DNvUJgwI.js +148 -0
  816. package/lib/SchemaList-DNvUJgwI.js.map +1 -0
  817. package/lib/SchemaView-Cxh_msLc.js +357 -0
  818. package/lib/SchemaView-Cxh_msLc.js.map +1 -0
  819. package/lib/Select-DVFRKf1R.js +223 -0
  820. package/lib/Select-DVFRKf1R.js.map +1 -0
  821. package/lib/SlotletProvider-BV1xrg-l.js +338 -0
  822. package/lib/SlotletProvider-BV1xrg-l.js.map +1 -0
  823. package/lib/{Spinner-3cQDBVGr.js → Spinner-CE68iCm0.js} +2 -2
  824. package/lib/{Spinner-3cQDBVGr.js.map → Spinner-CE68iCm0.js.map} +1 -1
  825. package/lib/SyntaxHighlight-BEoSoPEo.js +2890 -0
  826. package/lib/SyntaxHighlight-BEoSoPEo.js.map +1 -0
  827. package/lib/Toc-D40bDl5J.js +92 -0
  828. package/lib/Toc-D40bDl5J.js.map +1 -0
  829. package/lib/chunk-HA7DTUK3-C4gP41vD.js +1821 -0
  830. package/lib/chunk-HA7DTUK3-C4gP41vD.js.map +1 -0
  831. package/lib/circular-ByJI6Mci.js +15877 -0
  832. package/lib/circular-ByJI6Mci.js.map +1 -0
  833. package/lib/cn-qaFjX9_3.js +2279 -0
  834. package/lib/cn-qaFjX9_3.js.map +1 -0
  835. package/lib/context-DLCwaMXN.js +22 -0
  836. package/lib/context-DLCwaMXN.js.map +1 -0
  837. package/lib/createServer-Cq73y9Kv.js +12454 -0
  838. package/lib/createServer-Cq73y9Kv.js.map +1 -0
  839. package/lib/hook-CqpVYDqN.js +1483 -0
  840. package/lib/hook-CqpVYDqN.js.map +1 -0
  841. package/lib/index-Bn6Lc9tq.js +9 -0
  842. package/lib/index-Bn6Lc9tq.js.map +1 -0
  843. package/lib/index-CN3TIw7H.js +2009 -0
  844. package/lib/index-CN3TIw7H.js.map +1 -0
  845. package/lib/index-CPNSgwSb.js +36 -0
  846. package/lib/index-CPNSgwSb.js.map +1 -0
  847. package/lib/{index-CLd8ycZz.js → index-Dl3Yl0yb.js} +1056 -1009
  848. package/lib/index-Dl3Yl0yb.js.map +1 -0
  849. package/lib/index-DwT-v3zK.js +86 -0
  850. package/lib/index-DwT-v3zK.js.map +1 -0
  851. package/lib/index-LNp6rxyU.js +2094 -0
  852. package/lib/index-LNp6rxyU.js.map +1 -0
  853. package/lib/index-dQecW8K5.js +2227 -0
  854. package/lib/index-dQecW8K5.js.map +1 -0
  855. package/lib/index-gQD2h1wX.js +447 -0
  856. package/lib/index-gQD2h1wX.js.map +1 -0
  857. package/lib/index.esm--gIChbWs.js +1207 -0
  858. package/lib/index.esm--gIChbWs.js.map +1 -0
  859. package/lib/invariant-Caa8-XvF.js +26 -0
  860. package/lib/invariant-Caa8-XvF.js.map +1 -0
  861. package/lib/jsx-runtime-CYK1ROHF.js +446 -0
  862. package/lib/jsx-runtime-CYK1ROHF.js.map +1 -0
  863. package/lib/mutation-8LjrN7uz.js +208 -0
  864. package/lib/mutation-8LjrN7uz.js.map +1 -0
  865. package/lib/objectEntries-yMIkr2mI.js +5 -0
  866. package/lib/objectEntries-yMIkr2mI.js.map +1 -0
  867. package/lib/{prism-bash.min-DadFsM4Z.js → prism-bash.min-HHIMdNJ_.js} +4 -4
  868. package/lib/{prism-bash.min-DadFsM4Z.js.map → prism-bash.min-HHIMdNJ_.js.map} +1 -1
  869. package/lib/prism-csharp.min-bQAo2pmx.js +63 -0
  870. package/lib/{prism-csharp.min-Yizuc34Y.js.map → prism-csharp.min-bQAo2pmx.js.map} +1 -1
  871. package/lib/prism-java.min-BpvsOuIa.js +35 -0
  872. package/lib/{prism-java.min-d5iT_mOd.js.map → prism-java.min-BpvsOuIa.js.map} +1 -1
  873. package/lib/prism-javascript.min-CEqHqgbm.js.map +1 -1
  874. package/lib/prism-json.min-B1GJqK1k.js.map +1 -1
  875. package/lib/prism-jsstacktrace.min-BfobCF2F.js +2 -0
  876. package/lib/prism-jsstacktrace.min-BfobCF2F.js.map +1 -0
  877. package/lib/{prism-markdown.min-F3U-vPBi.js → prism-markdown.min-C0Qn0m-5.js} +30 -30
  878. package/lib/{prism-markdown.min-F3U-vPBi.js.map → prism-markdown.min-C0Qn0m-5.js.map} +1 -1
  879. package/lib/prism-markup-BNGj0Tvm.js.map +1 -1
  880. package/lib/prism-objectivec.min-BXSWqpJJ.js.map +1 -1
  881. package/lib/prism-ruby.min-Dx9KO9ds.js +38 -0
  882. package/lib/{prism-ruby.min-C7LwcKyz.js.map → prism-ruby.min-Dx9KO9ds.js.map} +1 -1
  883. package/lib/prism-typescript.min-CD7H2IYQ.js +34 -0
  884. package/lib/{prism-typescript.min-oSVeWCAd.js.map → prism-typescript.min-CD7H2IYQ.js.map} +1 -1
  885. package/lib/processors/removeExtensions.js +11 -0
  886. package/lib/processors/removeExtensions.js.map +1 -0
  887. package/lib/processors/removeParameters.js +48 -0
  888. package/lib/processors/removeParameters.js.map +1 -0
  889. package/lib/processors/removePaths.js +28 -0
  890. package/lib/processors/removePaths.js.map +1 -0
  891. package/lib/processors/traverse.js +15 -0
  892. package/lib/processors/traverse.js.map +1 -0
  893. package/lib/ui/Accordion.js +47 -0
  894. package/lib/ui/Accordion.js.map +1 -0
  895. package/lib/ui/ActionButton.js +25 -0
  896. package/lib/ui/ActionButton.js.map +1 -0
  897. package/lib/ui/Alert.js +51 -0
  898. package/lib/ui/Alert.js.map +1 -0
  899. package/lib/ui/AlertDialog.js +114 -0
  900. package/lib/ui/AlertDialog.js.map +1 -0
  901. package/lib/ui/AspectRatio.js +6 -0
  902. package/lib/ui/AspectRatio.js.map +1 -0
  903. package/lib/ui/Badge.js +28 -0
  904. package/lib/ui/Badge.js.map +1 -0
  905. package/lib/ui/Breadcrumb.js +94 -0
  906. package/lib/ui/Breadcrumb.js.map +1 -0
  907. package/lib/ui/Button.js +50 -0
  908. package/lib/ui/Button.js.map +1 -0
  909. package/lib/ui/Callout.js +96 -0
  910. package/lib/ui/Callout.js.map +1 -0
  911. package/lib/ui/Card.js +62 -0
  912. package/lib/ui/Card.js.map +1 -0
  913. package/lib/ui/Carousel.js +1416 -0
  914. package/lib/ui/Carousel.js.map +1 -0
  915. package/lib/ui/Checkbox.js +29 -0
  916. package/lib/ui/Checkbox.js.map +1 -0
  917. package/lib/ui/Collapsible.js +8 -0
  918. package/lib/ui/Collapsible.js.map +1 -0
  919. package/lib/ui/Command.js +156 -0
  920. package/lib/ui/Command.js.map +1 -0
  921. package/lib/ui/Dialog.js +101 -0
  922. package/lib/ui/Dialog.js.map +1 -0
  923. package/lib/ui/Drawer.js +17 -0
  924. package/lib/ui/Drawer.js.map +1 -0
  925. package/lib/ui/DropdownMenu.js +145 -0
  926. package/lib/ui/DropdownMenu.js.map +1 -0
  927. package/lib/ui/Form.js +95 -0
  928. package/lib/ui/Form.js.map +1 -0
  929. package/lib/ui/HoverCard.js +24 -0
  930. package/lib/ui/HoverCard.js.map +1 -0
  931. package/lib/ui/Input.js +22 -0
  932. package/lib/ui/Input.js.map +1 -0
  933. package/lib/ui/Label.js +20 -0
  934. package/lib/ui/Label.js.map +1 -0
  935. package/lib/ui/Pagination.js +106 -0
  936. package/lib/ui/Pagination.js.map +1 -0
  937. package/lib/ui/Popover.js +24 -0
  938. package/lib/ui/Popover.js.map +1 -0
  939. package/lib/ui/Progress.js +27 -0
  940. package/lib/ui/Progress.js.map +1 -0
  941. package/lib/ui/RadioGroup.js +32 -0
  942. package/lib/ui/RadioGroup.js.map +1 -0
  943. package/lib/ui/ScrollArea.js +39 -0
  944. package/lib/ui/ScrollArea.js.map +1 -0
  945. package/lib/ui/Select.js +122 -0
  946. package/lib/ui/Select.js.map +1 -0
  947. package/lib/ui/Skeleton.js +18 -0
  948. package/lib/ui/Skeleton.js.map +1 -0
  949. package/lib/ui/Slider.js +24 -0
  950. package/lib/ui/Slider.js.map +1 -0
  951. package/lib/ui/Stepper.js +6 -0
  952. package/lib/ui/Stepper.js.map +1 -0
  953. package/lib/ui/Switch.js +28 -0
  954. package/lib/ui/Switch.js.map +1 -0
  955. package/lib/ui/SyntaxHighlight.js +11 -0
  956. package/lib/ui/SyntaxHighlight.js.map +1 -0
  957. package/lib/ui/Tabs.js +47 -0
  958. package/lib/ui/Tabs.js.map +1 -0
  959. package/lib/ui/Textarea.js +21 -0
  960. package/lib/ui/Textarea.js.map +1 -0
  961. package/lib/ui/Toggle.js +38 -0
  962. package/lib/ui/Toggle.js.map +1 -0
  963. package/lib/ui/ToggleGroup.js +42 -0
  964. package/lib/ui/ToggleGroup.js.map +1 -0
  965. package/lib/ui/Tooltip.js +24 -0
  966. package/lib/ui/Tooltip.js.map +1 -0
  967. package/lib/ui/util.js +6 -0
  968. package/lib/ui/util.js.map +1 -0
  969. package/lib/useExposedProps-B9qXJedG.js +9 -0
  970. package/lib/useExposedProps-B9qXJedG.js.map +1 -0
  971. package/lib/useLatest-hmRS46UF.js +11 -0
  972. package/lib/useLatest-hmRS46UF.js.map +1 -0
  973. package/lib/zudoku.auth-auth0.js +30 -25
  974. package/lib/zudoku.auth-auth0.js.map +1 -1
  975. package/lib/zudoku.auth-clerk.js +101 -55
  976. package/lib/zudoku.auth-clerk.js.map +1 -1
  977. package/lib/zudoku.auth-openid.js +636 -665
  978. package/lib/zudoku.auth-openid.js.map +1 -1
  979. package/lib/zudoku.components.js +32 -3360
  980. package/lib/zudoku.components.js.map +1 -1
  981. package/lib/zudoku.hooks.js +19 -0
  982. package/lib/zudoku.hooks.js.map +1 -0
  983. package/lib/zudoku.icons.js +10 -0
  984. package/lib/zudoku.icons.js.map +1 -1
  985. package/lib/zudoku.plugin-api-catalog.js +117 -0
  986. package/lib/zudoku.plugin-api-catalog.js.map +1 -0
  987. package/lib/zudoku.plugin-api-keys.js +104 -108
  988. package/lib/zudoku.plugin-api-keys.js.map +1 -1
  989. package/lib/zudoku.plugin-custom-pages.js +22 -0
  990. package/lib/zudoku.plugin-custom-pages.js.map +1 -0
  991. package/lib/zudoku.plugin-markdown.js +73 -24
  992. package/lib/zudoku.plugin-markdown.js.map +1 -1
  993. package/lib/zudoku.plugin-openapi.js +7 -12
  994. package/lib/zudoku.plugin-openapi.js.map +1 -1
  995. package/lib/zudoku.plugin-redirect.js +2 -2
  996. package/lib/zudoku.plugin-redirect.js.map +1 -1
  997. package/lib/zudoku.plugin-search-inkeep.js +53 -28
  998. package/lib/zudoku.plugin-search-inkeep.js.map +1 -1
  999. package/lib/zudoku.plugin-search-pagefind.js +233 -0
  1000. package/lib/zudoku.plugin-search-pagefind.js.map +1 -0
  1001. package/lib/zudoku.plugins.js +14 -0
  1002. package/lib/zudoku.plugins.js.map +1 -0
  1003. package/package.json +180 -100
  1004. package/src/app/demo-cdn.html +31 -31
  1005. package/src/app/demo.tsx +1 -5
  1006. package/src/app/entry.client.tsx +28 -3
  1007. package/src/app/entry.server.tsx +81 -60
  1008. package/src/app/main.css +105 -41
  1009. package/src/app/main.tsx +55 -44
  1010. package/src/app/sentry.ts +24 -0
  1011. package/src/app/standalone.tsx +2 -6
  1012. package/src/app/tailwind.ts +83 -48
  1013. package/src/lib/MissingIcon.tsx +22 -0
  1014. package/src/lib/authentication/AuthenticationPlugin.tsx +4 -1
  1015. package/src/lib/authentication/authentication.ts +5 -3
  1016. package/src/lib/authentication/components/CallbackHandler.tsx +20 -51
  1017. package/src/lib/authentication/components/SignIn.tsx +1 -1
  1018. package/src/lib/authentication/components/SignOut.tsx +3 -2
  1019. package/src/lib/authentication/hook.ts +13 -4
  1020. package/src/lib/authentication/providers/auth0.tsx +20 -16
  1021. package/src/lib/authentication/providers/clerk.tsx +70 -15
  1022. package/src/lib/authentication/providers/openid.tsx +72 -55
  1023. package/src/lib/authentication/providers/supabase.tsx +157 -0
  1024. package/src/lib/authentication/state.ts +56 -8
  1025. package/{LICENSE.md → src/lib/authentication/use-broadcast/LICENSE.md} +2 -2
  1026. package/src/lib/authentication/use-broadcast/shared.ts +372 -0
  1027. package/src/lib/authentication/use-broadcast/useBroadcast.ts +146 -0
  1028. package/src/lib/components/AnchorLink.tsx +13 -8
  1029. package/src/lib/components/Autocomplete.tsx +113 -0
  1030. package/src/lib/components/Banner.tsx +13 -2
  1031. package/src/lib/components/Bootstrap.tsx +43 -16
  1032. package/src/lib/components/ClientOnly.tsx +6 -3
  1033. package/src/lib/components/DeveloperHint.tsx +6 -1
  1034. package/src/lib/components/ErrorPage.tsx +0 -2
  1035. package/src/lib/components/Footer.tsx +139 -0
  1036. package/src/lib/components/Header.tsx +104 -51
  1037. package/src/lib/components/Heading.tsx +13 -13
  1038. package/src/lib/components/InlineCode.tsx +15 -8
  1039. package/src/lib/components/Layout.tsx +34 -54
  1040. package/src/lib/components/Main.tsx +50 -0
  1041. package/src/lib/components/Markdown.tsx +15 -16
  1042. package/src/lib/components/MobileTopNavigation.tsx +42 -28
  1043. package/src/lib/components/NotFoundPage.tsx +1 -1
  1044. package/src/lib/components/Pagination.tsx +50 -0
  1045. package/src/lib/components/PathRenderer.tsx +61 -0
  1046. package/src/lib/components/ReactMarkdown.license.txt +21 -0
  1047. package/src/lib/components/ReactMarkdown.tsx +264 -0
  1048. package/src/lib/components/Search.tsx +18 -7
  1049. package/src/lib/components/SlotletProvider.tsx +29 -4
  1050. package/src/lib/components/StatusPage.tsx +91 -0
  1051. package/src/lib/components/ThemeSwitch.tsx +46 -0
  1052. package/src/lib/components/TopNavigation.tsx +107 -25
  1053. package/src/lib/components/Zudoku.tsx +121 -0
  1054. package/src/lib/components/cache.ts +23 -0
  1055. package/src/lib/components/context/BypassProtectedRoutesContext.ts +3 -0
  1056. package/src/lib/components/context/RouterEventsEmitter.tsx +19 -0
  1057. package/src/lib/components/context/ViewportAnchorContext.tsx +26 -21
  1058. package/src/lib/components/context/ZudokuContext.ts +54 -29
  1059. package/src/lib/components/context/ZudokuProvider.tsx +2 -2
  1060. package/src/lib/components/index.ts +31 -6
  1061. package/src/lib/components/navigation/PoweredByZudoku.tsx +23 -0
  1062. package/src/lib/components/navigation/Sidebar.tsx +38 -29
  1063. package/src/lib/components/navigation/SidebarBadge.tsx +17 -12
  1064. package/src/lib/components/navigation/SidebarCategory.tsx +61 -52
  1065. package/src/lib/components/navigation/SidebarItem.tsx +38 -50
  1066. package/src/lib/components/navigation/SidebarWrapper.tsx +42 -22
  1067. package/src/lib/{plugins/markdown → components/navigation}/Toc.tsx +5 -14
  1068. package/src/lib/components/navigation/ZudokuLogo.tsx +25 -0
  1069. package/src/lib/components/navigation/utils.ts +12 -17
  1070. package/src/lib/core/RouteGuard.tsx +96 -0
  1071. package/src/lib/core/ZudokuContext.ts +180 -0
  1072. package/src/lib/core/plugins.ts +46 -22
  1073. package/src/lib/errors/ErrorAlert.tsx +36 -15
  1074. package/src/lib/errors/RouterError.tsx +1 -1
  1075. package/src/lib/hooks/index.ts +5 -0
  1076. package/src/lib/hooks/useEvent.test.tsx +149 -0
  1077. package/src/lib/hooks/useEvent.ts +41 -0
  1078. package/src/lib/icons.ts +1 -0
  1079. package/src/lib/oas/graphql/circular.ts +50 -0
  1080. package/src/lib/oas/graphql/index.ts +321 -115
  1081. package/src/lib/oas/parser/dereference/index.ts +10 -4
  1082. package/src/lib/oas/parser/index.ts +8 -29
  1083. package/src/lib/oas/parser/upgrade/index.ts +24 -29
  1084. package/src/lib/plugins/api-catalog/Catalog.tsx +73 -0
  1085. package/src/lib/plugins/api-catalog/index.tsx +115 -0
  1086. package/src/lib/plugins/api-keys/CreateApiKey.tsx +10 -6
  1087. package/src/lib/plugins/api-keys/ProtectedRoute.tsx +1 -1
  1088. package/src/lib/plugins/api-keys/SettingsApiKeys.tsx +1 -1
  1089. package/src/lib/plugins/api-keys/index.tsx +16 -10
  1090. package/src/lib/plugins/custom-pages/CustomPage.tsx +18 -0
  1091. package/src/lib/plugins/custom-pages/index.tsx +24 -0
  1092. package/src/lib/plugins/markdown/MdxPage.tsx +54 -50
  1093. package/src/lib/plugins/markdown/index.tsx +53 -11
  1094. package/src/lib/plugins/markdown/resolver.ts +57 -0
  1095. package/src/lib/plugins/openapi/CollapsibleCode.tsx +83 -0
  1096. package/src/lib/plugins/openapi/ColorizedParam.tsx +49 -23
  1097. package/src/lib/plugins/openapi/Endpoint.tsx +83 -22
  1098. package/src/lib/plugins/openapi/OasProvider.tsx +51 -0
  1099. package/src/lib/plugins/openapi/OperationList.tsx +231 -71
  1100. package/src/lib/plugins/openapi/OperationListItem.tsx +136 -88
  1101. package/src/lib/plugins/openapi/ParamInfos.tsx +87 -0
  1102. package/src/lib/plugins/openapi/ParameterList.tsx +4 -0
  1103. package/src/lib/plugins/openapi/ParameterListItem.tsx +48 -31
  1104. package/src/lib/plugins/openapi/PlaygroundDialogWrapper.tsx +24 -2
  1105. package/src/lib/plugins/openapi/RequestBodySidecarBox.tsx +15 -33
  1106. package/src/lib/plugins/openapi/ResponsesSidecarBox.tsx +46 -58
  1107. package/src/lib/plugins/openapi/SchemaList.tsx +151 -0
  1108. package/src/lib/plugins/openapi/Sidecar.tsx +155 -106
  1109. package/src/lib/plugins/openapi/SidecarBox.tsx +4 -16
  1110. package/src/lib/plugins/openapi/SidecarExamples.tsx +162 -0
  1111. package/src/lib/plugins/openapi/SimpleSelect.tsx +11 -3
  1112. package/src/lib/plugins/openapi/client/GraphQLClient.tsx +65 -0
  1113. package/src/lib/plugins/openapi/client/GraphQLContext.tsx +16 -0
  1114. package/src/lib/plugins/openapi/client/createServer.ts +8 -2
  1115. package/src/lib/plugins/openapi/client/useCreateQuery.ts +26 -0
  1116. package/src/lib/plugins/openapi/components/EnumValues.tsx +58 -0
  1117. package/src/lib/plugins/openapi/components/SelectOnClick.tsx +29 -0
  1118. package/src/lib/plugins/openapi/context.tsx +2 -2
  1119. package/src/lib/plugins/openapi/graphql/fragment-masking.ts +11 -18
  1120. package/src/lib/plugins/openapi/graphql/gql.ts +46 -30
  1121. package/src/lib/plugins/openapi/graphql/graphql.ts +413 -597
  1122. package/src/lib/plugins/openapi/index.tsx +110 -138
  1123. package/src/lib/plugins/openapi/interfaces.ts +60 -3
  1124. package/src/lib/plugins/openapi/playground/ExamplesDropdown.tsx +52 -0
  1125. package/src/lib/plugins/openapi/playground/Headers.tsx +165 -36
  1126. package/src/lib/plugins/openapi/playground/IdentityDialog.tsx +74 -0
  1127. package/src/lib/plugins/openapi/playground/IdentitySelector.tsx +54 -0
  1128. package/src/lib/plugins/openapi/playground/ParamsGrid.tsx +13 -0
  1129. package/src/lib/plugins/openapi/playground/PathParams.tsx +39 -64
  1130. package/src/lib/plugins/openapi/playground/Playground.tsx +395 -220
  1131. package/src/lib/plugins/openapi/playground/PlaygroundDialog.tsx +7 -4
  1132. package/src/lib/plugins/openapi/playground/QueryParams.tsx +86 -88
  1133. package/src/lib/plugins/openapi/playground/RequestLoginDialog.tsx +51 -0
  1134. package/src/lib/plugins/openapi/playground/SubmitButton.tsx +75 -0
  1135. package/src/lib/plugins/openapi/playground/createUrl.ts +6 -1
  1136. package/src/lib/plugins/openapi/playground/rememberedIdentity.ts +26 -0
  1137. package/src/lib/plugins/openapi/playground/result-panel/RequestTab.tsx +73 -0
  1138. package/src/lib/plugins/openapi/playground/result-panel/ResponseTab.tsx +230 -0
  1139. package/src/lib/plugins/openapi/playground/result-panel/ResultPanel.tsx +123 -0
  1140. package/src/lib/plugins/openapi/playground/result-panel/convertToTypes.test.ts +64 -0
  1141. package/src/lib/plugins/openapi/playground/result-panel/convertToTypes.ts +36 -0
  1142. package/src/lib/plugins/openapi/processors/removeExtensions.test.ts +202 -0
  1143. package/src/lib/plugins/openapi/processors/removeExtensions.ts +27 -0
  1144. package/src/lib/plugins/openapi/processors/removeParameters.test.ts +148 -0
  1145. package/src/lib/plugins/openapi/processors/removeParameters.ts +101 -0
  1146. package/src/lib/plugins/openapi/processors/removePaths.test.ts +126 -0
  1147. package/src/lib/plugins/openapi/processors/removePaths.ts +55 -0
  1148. package/src/lib/plugins/openapi/processors/traverse.ts +1 -0
  1149. package/src/lib/plugins/openapi/schema/LogicalGroup/LogicalGroup.tsx +1 -8
  1150. package/src/lib/plugins/openapi/schema/LogicalGroup/LogicalGroupConnector.tsx +3 -0
  1151. package/src/lib/plugins/openapi/schema/LogicalGroup/LogicalGroupItem.tsx +6 -3
  1152. package/src/lib/plugins/openapi/schema/SchemaExampleAndDefault.tsx +36 -0
  1153. package/src/lib/plugins/openapi/schema/SchemaPropertyItem.tsx +148 -0
  1154. package/src/lib/plugins/openapi/schema/SchemaView.tsx +88 -136
  1155. package/src/lib/plugins/openapi/schema/utils.ts +11 -1
  1156. package/src/lib/plugins/openapi/state.ts +36 -0
  1157. package/src/lib/plugins/openapi/util/createSidebarCategory.tsx +37 -0
  1158. package/src/lib/plugins/openapi/util/generateSchemaExample.ts +44 -43
  1159. package/src/lib/plugins/openapi/util/getRoutes.tsx +126 -0
  1160. package/src/lib/plugins/openapi/util/methodColorMap.tsx +11 -0
  1161. package/src/lib/plugins/openapi/util/methodToColor.ts +27 -0
  1162. package/src/lib/plugins/openapi/util/sanitizeMarkdownForMetatag.tsx +32 -0
  1163. package/src/lib/plugins/redirect/index.tsx +6 -10
  1164. package/src/lib/plugins/search-inkeep/index.tsx +80 -25
  1165. package/src/lib/plugins/search-inkeep/inkeep.ts +3 -9
  1166. package/src/lib/plugins/search-pagefind/PagefindSearch.tsx +164 -0
  1167. package/src/lib/plugins/search-pagefind/ResultList.tsx +105 -0
  1168. package/src/lib/plugins/search-pagefind/get-results.tsx +75 -0
  1169. package/src/lib/plugins/search-pagefind/index.tsx +21 -0
  1170. package/src/lib/plugins/search-pagefind/types.ts +118 -0
  1171. package/src/lib/ui/Accordion.tsx +56 -0
  1172. package/src/lib/ui/ActionButton.tsx +28 -0
  1173. package/src/lib/ui/{Note.tsx → Alert.tsx} +11 -10
  1174. package/src/lib/ui/AlertDialog.tsx +139 -0
  1175. package/src/lib/ui/AspectRatio.tsx +5 -0
  1176. package/src/lib/ui/Badge.tsx +37 -0
  1177. package/src/lib/ui/Breadcrumb.tsx +115 -0
  1178. package/src/lib/ui/Button.tsx +5 -3
  1179. package/src/lib/ui/Callout.tsx +36 -16
  1180. package/src/lib/ui/Card.tsx +1 -1
  1181. package/src/lib/ui/Carousel.tsx +260 -0
  1182. package/src/lib/ui/Checkbox.tsx +29 -0
  1183. package/src/lib/ui/Collapsible.tsx +9 -0
  1184. package/src/lib/ui/Command.tsx +193 -0
  1185. package/src/lib/{components → ui}/Dialog.tsx +4 -3
  1186. package/src/lib/ui/Drawer.tsx +38 -36
  1187. package/src/lib/ui/Form.tsx +177 -0
  1188. package/src/lib/ui/HoverCard.tsx +27 -0
  1189. package/src/lib/ui/Input.tsx +1 -2
  1190. package/src/lib/ui/Label.tsx +24 -0
  1191. package/src/lib/ui/Pagination.tsx +117 -0
  1192. package/src/lib/ui/Popover.tsx +29 -0
  1193. package/src/lib/ui/Progress.tsx +26 -0
  1194. package/src/lib/ui/RadioGroup.tsx +42 -0
  1195. package/src/lib/ui/ScrollArea.tsx +46 -0
  1196. package/src/lib/{components → ui}/Select.tsx +2 -2
  1197. package/src/lib/ui/Skeleton.tsx +15 -0
  1198. package/src/lib/ui/Slider.tsx +26 -0
  1199. package/src/lib/ui/Stepper.tsx +8 -0
  1200. package/src/lib/ui/Switch.tsx +27 -0
  1201. package/src/lib/ui/SyntaxHighlight.tsx +186 -0
  1202. package/src/lib/ui/Textarea.tsx +23 -0
  1203. package/src/lib/ui/Toggle.tsx +43 -0
  1204. package/src/lib/ui/ToggleGroup.tsx +59 -0
  1205. package/src/lib/ui/Tooltip.tsx +28 -0
  1206. package/src/lib/ui/util.tsx +3 -0
  1207. package/src/lib/util/MdxComponents.tsx +12 -12
  1208. package/src/lib/util/createVariantComponent.tsx +2 -2
  1209. package/src/lib/util/detectOS.ts +9 -0
  1210. package/src/lib/util/invariant.ts +15 -3
  1211. package/src/lib/util/joinPath.tsx +3 -0
  1212. package/src/lib/util/joinUrl.test.ts +62 -0
  1213. package/src/lib/util/joinUrl.ts +57 -0
  1214. package/src/lib/util/scrollIntoViewIfNeeded.ts +18 -0
  1215. package/src/lib/util/traverse.ts +31 -0
  1216. package/src/lib/util/types.ts +7 -0
  1217. package/src/lib/util/useExposedProps.tsx +16 -0
  1218. package/src/lib/util/useIsomorphicLayoutEffect.ts +5 -0
  1219. package/src/lib/util/useLatest.ts +18 -0
  1220. package/src/lib/util/useOnScreen.ts +34 -0
  1221. package/src/lib/util/useScrollToAnchor.ts +48 -39
  1222. package/src/lib/util/useScrollToTop.ts +9 -4
  1223. package/dist/internal.d.ts +0 -1
  1224. package/dist/internal.js +0 -2
  1225. package/dist/internal.js.map +0 -1
  1226. package/dist/lib/components/DevPortal.js.map +0 -1
  1227. package/dist/lib/components/Dialog.js.map +0 -1
  1228. package/dist/lib/components/Select.js.map +0 -1
  1229. package/dist/lib/components/SyntaxHighlight.d.ts +0 -11
  1230. package/dist/lib/components/SyntaxHighlight.js +0 -50
  1231. package/dist/lib/components/SyntaxHighlight.js.map +0 -1
  1232. package/dist/lib/components/context/PluginSystem.js +0 -2
  1233. package/dist/lib/components/context/PluginSystem.js.map +0 -1
  1234. package/dist/lib/components/context/ThemeContext.d.ts +0 -2
  1235. package/dist/lib/components/context/ThemeContext.js +0 -7
  1236. package/dist/lib/components/context/ThemeContext.js.map +0 -1
  1237. package/dist/lib/components/context/ThemeProvider.d.ts +0 -4
  1238. package/dist/lib/components/context/ThemeProvider.js +0 -23
  1239. package/dist/lib/components/context/ThemeProvider.js.map +0 -1
  1240. package/dist/lib/core/DevPortalContext.d.ts +0 -78
  1241. package/dist/lib/core/DevPortalContext.js +0 -49
  1242. package/dist/lib/core/DevPortalContext.js.map +0 -1
  1243. package/dist/lib/plugins/custom-page/index.d.ts +0 -8
  1244. package/dist/lib/plugins/custom-page/index.js +0 -12
  1245. package/dist/lib/plugins/custom-page/index.js.map +0 -1
  1246. package/dist/lib/plugins/markdown/Toc.js.map +0 -1
  1247. package/dist/lib/plugins/markdown/generateRoutes.d.ts +0 -3
  1248. package/dist/lib/plugins/markdown/generateRoutes.js +0 -19
  1249. package/dist/lib/plugins/markdown/generateRoutes.js.map +0 -1
  1250. package/dist/lib/plugins/openapi/Route.d.ts +0 -6
  1251. package/dist/lib/plugins/openapi/Route.js +0 -8
  1252. package/dist/lib/plugins/openapi/Route.js.map +0 -1
  1253. package/dist/lib/plugins/openapi/client/createMemoryClient.d.ts +0 -12
  1254. package/dist/lib/plugins/openapi/client/createMemoryClient.js +0 -46
  1255. package/dist/lib/plugins/openapi/client/createMemoryClient.js.map +0 -1
  1256. package/dist/lib/plugins/openapi/client/createWorkerClient.d.ts +0 -10
  1257. package/dist/lib/plugins/openapi/client/createWorkerClient.js +0 -61
  1258. package/dist/lib/plugins/openapi/client/createWorkerClient.js.map +0 -1
  1259. package/dist/lib/plugins/openapi/client/interfaces.d.ts +0 -4
  1260. package/dist/lib/plugins/openapi/client/interfaces.js +0 -2
  1261. package/dist/lib/plugins/openapi/client/interfaces.js.map +0 -1
  1262. package/dist/lib/plugins/openapi/client/worker.js +0 -20
  1263. package/dist/lib/plugins/openapi/client/worker.js.map +0 -1
  1264. package/dist/lib/plugins/openapi/playground/Editor.d.ts +0 -1
  1265. package/dist/lib/plugins/openapi/playground/Editor.js +0 -5
  1266. package/dist/lib/plugins/openapi/playground/Editor.js.map +0 -1
  1267. package/dist/lib/plugins/openapi/playground/ResponseTab.d.ts +0 -4
  1268. package/dist/lib/plugins/openapi/playground/ResponseTab.js +0 -42
  1269. package/dist/lib/plugins/openapi/playground/ResponseTab.js.map +0 -1
  1270. package/dist/lib/plugins/openapi/schema/SchemaComponents.js +0 -28
  1271. package/dist/lib/plugins/openapi/schema/SchemaComponents.js.map +0 -1
  1272. package/dist/lib/plugins/openapi/util/urql.d.ts +0 -7
  1273. package/dist/lib/plugins/openapi/util/urql.js +0 -8
  1274. package/dist/lib/plugins/openapi/util/urql.js.map +0 -1
  1275. package/dist/lib/plugins/openapi-worker.d.ts +0 -1
  1276. package/dist/lib/plugins/openapi-worker.js +0 -2
  1277. package/dist/lib/plugins/openapi-worker.js.map +0 -1
  1278. package/dist/lib/plugins/search-inkeep/InkeepCustomTrigger.d.ts +0 -2
  1279. package/dist/lib/plugins/search-inkeep/InkeepCustomTrigger.js +0 -3
  1280. package/dist/lib/plugins/search-inkeep/InkeepCustomTrigger.js.map +0 -1
  1281. package/dist/lib/themeToggle.d.ts +0 -1
  1282. package/dist/lib/themeToggle.js +0 -7
  1283. package/dist/lib/themeToggle.js.map +0 -1
  1284. package/dist/lib/ui/Note.d.ts +0 -8
  1285. package/dist/lib/ui/Note.js +0 -23
  1286. package/dist/lib/ui/Note.js.map +0 -1
  1287. package/dist/lib/util/createWaitForNotify.d.ts +0 -1
  1288. package/dist/lib/util/createWaitForNotify.js +0 -15
  1289. package/dist/lib/util/createWaitForNotify.js.map +0 -1
  1290. package/dist/lib/util/slugify.d.ts +0 -2
  1291. package/dist/lib/util/slugify.js +0 -3
  1292. package/dist/lib/util/slugify.js.map +0 -1
  1293. package/dist/vite/plugin-custom-css.js +0 -55
  1294. package/dist/vite/plugin-custom-css.js.map +0 -1
  1295. package/dist/vite/plugin-html-transform.d.ts +0 -2
  1296. package/dist/vite/plugin-html-transform.js +0 -15
  1297. package/dist/vite/plugin-html-transform.js.map +0 -1
  1298. package/dist/vite/plugin-icons.d.ts +0 -3
  1299. package/dist/vite/plugin-icons.js +0 -47
  1300. package/dist/vite/plugin-icons.js.map +0 -1
  1301. package/dist/vite/prerender.d.ts +0 -17
  1302. package/dist/vite/prerender.js +0 -87
  1303. package/dist/vite/prerender.js.map +0 -1
  1304. package/lib/AuthenticationPlugin-Bx9FK124.js +0 -55
  1305. package/lib/AuthenticationPlugin-Bx9FK124.js.map +0 -1
  1306. package/lib/CategoryHeading-XnFqN2lJ.js +0 -10
  1307. package/lib/DeveloperHint-FBb2uXJe.js +0 -16
  1308. package/lib/DeveloperHint-FBb2uXJe.js.map +0 -1
  1309. package/lib/ErrorPage-knunPbKI.js +0 -18
  1310. package/lib/ErrorPage-knunPbKI.js.map +0 -1
  1311. package/lib/InkeepCustomTrigger-CE5-K5ex.js +0 -6
  1312. package/lib/InkeepCustomTrigger-CE5-K5ex.js.map +0 -1
  1313. package/lib/Input-BEDZAKw0.js +0 -2198
  1314. package/lib/Input-BEDZAKw0.js.map +0 -1
  1315. package/lib/Markdown-B4aR03g6.js +0 -20279
  1316. package/lib/Markdown-B4aR03g6.js.map +0 -1
  1317. package/lib/MdxPage-BZyQsH8Z.js +0 -172
  1318. package/lib/MdxPage-BZyQsH8Z.js.map +0 -1
  1319. package/lib/OperationList-2NeWEM0u.js +0 -560
  1320. package/lib/OperationList-2NeWEM0u.js.map +0 -1
  1321. package/lib/Route-BZPewmrN.js +0 -14
  1322. package/lib/Route-BZPewmrN.js.map +0 -1
  1323. package/lib/SidebarBadge-COz0hgfa.js +0 -498
  1324. package/lib/SidebarBadge-COz0hgfa.js.map +0 -1
  1325. package/lib/SlotletProvider-DJMaOUDs.js +0 -238
  1326. package/lib/SlotletProvider-DJMaOUDs.js.map +0 -1
  1327. package/lib/ZudokuContext-cr-pTRY1.js +0 -1084
  1328. package/lib/ZudokuContext-cr-pTRY1.js.map +0 -1
  1329. package/lib/assets/index-B9EWVYfo.js +0 -4790
  1330. package/lib/assets/index-B9EWVYfo.js.map +0 -1
  1331. package/lib/assets/worker-BvD7B6MG.js +0 -15839
  1332. package/lib/assets/worker-BvD7B6MG.js.map +0 -1
  1333. package/lib/index-1EDgIO6b.js +0 -124
  1334. package/lib/index-1EDgIO6b.js.map +0 -1
  1335. package/lib/index-BG0g4WW0.js +0 -1771
  1336. package/lib/index-BG0g4WW0.js.map +0 -1
  1337. package/lib/index-CLd8ycZz.js.map +0 -1
  1338. package/lib/index-Dv2KZuEw.js +0 -5685
  1339. package/lib/index-Dv2KZuEw.js.map +0 -1
  1340. package/lib/index-Zezcv0xb.js +0 -2814
  1341. package/lib/index-Zezcv0xb.js.map +0 -1
  1342. package/lib/joinPath-B7kNnUX4.js +0 -8
  1343. package/lib/joinPath-B7kNnUX4.js.map +0 -1
  1344. package/lib/jsx-runtime-B6kdoens.js +0 -635
  1345. package/lib/jsx-runtime-B6kdoens.js.map +0 -1
  1346. package/lib/prism-csharp.min-Yizuc34Y.js +0 -35
  1347. package/lib/prism-java.min-d5iT_mOd.js +0 -7
  1348. package/lib/prism-markup-templating-DZrrEs0A.js +0 -62
  1349. package/lib/prism-markup-templating-DZrrEs0A.js.map +0 -1
  1350. package/lib/prism-php.min-o7FpoMP_.js +0 -11
  1351. package/lib/prism-php.min-o7FpoMP_.js.map +0 -1
  1352. package/lib/prism-ruby.min-C7LwcKyz.js +0 -10
  1353. package/lib/prism-typescript.min-oSVeWCAd.js +0 -6
  1354. package/lib/router-D2p7Olpn.js +0 -2971
  1355. package/lib/router-D2p7Olpn.js.map +0 -1
  1356. package/lib/slugify-DbLhpSPt.js +0 -28
  1357. package/lib/slugify-DbLhpSPt.js.map +0 -1
  1358. package/lib/state-lIwt9isb.js +0 -288
  1359. package/lib/state-lIwt9isb.js.map +0 -1
  1360. package/lib/urql-YhcsXYy8.js +0 -1591
  1361. package/lib/urql-YhcsXYy8.js.map +0 -1
  1362. package/lib/utils-ByIc_KIM.js +0 -749
  1363. package/lib/utils-ByIc_KIM.js.map +0 -1
  1364. package/lib/zudoku.openapi-worker.js +0 -16053
  1365. package/lib/zudoku.openapi-worker.js.map +0 -1
  1366. package/lib/zudoku.plugin-custom-page.js +0 -13
  1367. package/lib/zudoku.plugin-custom-page.js.map +0 -1
  1368. package/src/lib/components/DevPortal.tsx +0 -111
  1369. package/src/lib/components/SyntaxHighlight.tsx +0 -122
  1370. package/src/lib/components/context/PluginSystem.ts +0 -0
  1371. package/src/lib/components/context/ThemeContext.tsx +0 -8
  1372. package/src/lib/components/context/ThemeProvider.tsx +0 -27
  1373. package/src/lib/core/DevPortalContext.ts +0 -135
  1374. package/src/lib/plugins/custom-page/index.tsx +0 -22
  1375. package/src/lib/plugins/markdown/generateRoutes.tsx +0 -35
  1376. package/src/lib/plugins/openapi/Route.tsx +0 -21
  1377. package/src/lib/plugins/openapi/client/createMemoryClient.ts +0 -56
  1378. package/src/lib/plugins/openapi/client/createWorkerClient.ts +0 -80
  1379. package/src/lib/plugins/openapi/client/interfaces.ts +0 -5
  1380. package/src/lib/plugins/openapi/client/worker.ts +0 -30
  1381. package/src/lib/plugins/openapi/playground/Editor.tsx +0 -4
  1382. package/src/lib/plugins/openapi/playground/ResponseTab.tsx +0 -77
  1383. package/src/lib/plugins/openapi/schema/SchemaComponents.tsx +0 -126
  1384. package/src/lib/plugins/openapi/util/urql.ts +0 -8
  1385. package/src/lib/plugins/openapi-worker.ts +0 -1
  1386. package/src/lib/plugins/search-inkeep/InkeepCustomTrigger.tsx +0 -3
  1387. package/src/lib/themeToggle.ts +0 -7
  1388. package/src/lib/util/createWaitForNotify.ts +0 -18
  1389. package/src/lib/util/slugify.ts +0 -3
  1390. /package/dist/lib/{plugins/markdown → components/navigation}/Toc.d.ts +0 -0
  1391. /package/dist/lib/{components/context/PluginSystem.d.ts → hooks/useEvent.test.d.ts} +0 -0
  1392. /package/dist/lib/plugins/openapi/{client/worker.d.ts → playground/result-panel/convertToTypes.test.d.ts} +0 -0
  1393. /package/dist/lib/{components → ui}/Dialog.d.ts +0 -0
  1394. /package/dist/lib/{components → ui}/Select.d.ts +0 -0
@@ -1,168 +1,167 @@
1
- var Ue = Object.defineProperty;
2
- var Le = (t, e, r) => e in t ? Ue(t, e, { enumerable: !0, configurable: !0, writable: !0, value: r }) : t[e] = r;
3
- var _ = (t, e, r) => Le(t, typeof e != "symbol" ? e + "" : e, r);
4
- import { j as E } from "./jsx-runtime-B6kdoens.js";
5
- import { c as Ce, g as Ie } from "./_commonjsHelpers-BkfeUUK-.js";
6
- import { A as je } from "./AuthenticationPlugin-Bx9FK124.js";
7
- import { useState as Je, useRef as Oe, useEffect as Ne } from "react";
8
- import { D as ze } from "./DeveloperHint-FBb2uXJe.js";
9
- import { E as De } from "./ErrorPage-knunPbKI.js";
10
- import { S as Ke } from "./Spinner-3cQDBVGr.js";
11
- import { S as We } from "./Markdown-B4aR03g6.js";
12
- import { a as He } from "./index-BG0g4WW0.js";
13
- import { u as z } from "./state-lIwt9isb.js";
14
- var fe = { exports: {} };
15
- (function(t) {
16
- (function(e, r) {
17
- t.exports ? t.exports = r() : e.log = r();
18
- })(Ce, function() {
19
- var e = function() {
20
- }, r = "undefined", o = typeof window !== r && typeof window.navigator !== r && /Trident\/|MSIE /.test(window.navigator.userAgent), s = [
21
- "trace",
22
- "debug",
23
- "info",
24
- "warn",
25
- "error"
26
- ], n = {}, i = null;
27
- function u(l, w) {
28
- var c = l[w];
29
- if (typeof c.bind == "function")
30
- return c.bind(l);
31
- try {
32
- return Function.prototype.bind.call(c, l);
33
- } catch {
1
+ var Le = Object.defineProperty;
2
+ var xe = (t, e, n) => e in t ? Le(t, e, { enumerable: !0, configurable: !0, writable: !0, value: n }) : t[e] = n;
3
+ var b = (t, e, n) => xe(t, typeof e != "symbol" ? e + "" : e, n);
4
+ import { j as B } from "./jsx-runtime-CYK1ROHF.js";
5
+ import { g as Ce } from "./_commonjsHelpers-BkfeUUK-.js";
6
+ import { C as Ie } from "./ClientOnly-E7hGysn1.js";
7
+ import { d as je, f as ie, u as x } from "./hook-CqpVYDqN.js";
8
+ import { A as Je } from "./AuthenticationPlugin-foqdvvkf.js";
9
+ import { N as Oe } from "./chunk-HA7DTUK3-C4gP41vD.js";
10
+ import { Z as ze } from "./invariant-Caa8-XvF.js";
11
+ var D = { exports: {} }, De = D.exports, ae;
12
+ function Ne() {
13
+ return ae || (ae = 1, function(t) {
14
+ (function(e, n) {
15
+ t.exports ? t.exports = n() : e.log = n();
16
+ })(De, function() {
17
+ var e = function() {
18
+ }, n = "undefined", o = typeof window !== n && typeof window.navigator !== n && /Trident\/|MSIE /.test(window.navigator.userAgent), a = [
19
+ "trace",
20
+ "debug",
21
+ "info",
22
+ "warn",
23
+ "error"
24
+ ], r = {}, i = null;
25
+ function c(l, m) {
26
+ var u = l[m];
27
+ if (typeof u.bind == "function")
28
+ return u.bind(l);
29
+ try {
30
+ return Function.prototype.bind.call(u, l);
31
+ } catch {
32
+ return function() {
33
+ return Function.prototype.apply.apply(u, [l, arguments]);
34
+ };
35
+ }
36
+ }
37
+ function p() {
38
+ console.log && (console.log.apply ? console.log.apply(console, arguments) : Function.prototype.apply.apply(console.log, [console, arguments])), console.trace && console.trace();
39
+ }
40
+ function w(l) {
41
+ return l === "debug" && (l = "log"), typeof console === n ? !1 : l === "trace" && o ? p : console[l] !== void 0 ? c(console, l) : console.log !== void 0 ? c(console, "log") : e;
42
+ }
43
+ function f() {
44
+ for (var l = this.getLevel(), m = 0; m < a.length; m++) {
45
+ var u = a[m];
46
+ this[u] = m < l ? e : this.methodFactory(u, l, this.name);
47
+ }
48
+ if (this.log = this.debug, typeof console === n && l < this.levels.SILENT)
49
+ return "No console available for logging";
50
+ }
51
+ function v(l) {
34
52
  return function() {
35
- return Function.prototype.apply.apply(c, [l, arguments]);
53
+ typeof console !== n && (f.call(this), this[l].apply(this, arguments));
36
54
  };
37
55
  }
38
- }
39
- function f() {
40
- console.log && (console.log.apply ? console.log.apply(console, arguments) : Function.prototype.apply.apply(console.log, [console, arguments])), console.trace && console.trace();
41
- }
42
- function m(l) {
43
- return l === "debug" && (l = "log"), typeof console === r ? !1 : l === "trace" && o ? f : console[l] !== void 0 ? u(console, l) : console.log !== void 0 ? u(console, "log") : e;
44
- }
45
- function y() {
46
- for (var l = this.getLevel(), w = 0; w < s.length; w++) {
47
- var c = s[w];
48
- this[c] = w < l ? e : this.methodFactory(c, l, this.name);
56
+ function _(l, m, u) {
57
+ return w(l) || v.apply(this, arguments);
49
58
  }
50
- if (this.log = this.debug, typeof console === r && l < this.levels.SILENT)
51
- return "No console available for logging";
52
- }
53
- function b(l) {
54
- return function() {
55
- typeof console !== r && (y.call(this), this[l].apply(this, arguments));
56
- };
57
- }
58
- function h(l, w, c) {
59
- return m(l) || b.apply(this, arguments);
60
- }
61
- function R(l, w) {
62
- var c = this, O, B, x, v = "loglevel";
63
- typeof l == "string" ? v += ":" + l : typeof l == "symbol" && (v = void 0);
64
- function Re(d) {
65
- var g = (s[d] || "silent").toUpperCase();
66
- if (!(typeof window === r || !v)) {
67
- try {
68
- window.localStorage[v] = g;
69
- return;
70
- } catch {
71
- }
72
- try {
73
- window.document.cookie = encodeURIComponent(v) + "=" + g + ";";
74
- } catch {
59
+ function h(l, m) {
60
+ var u = this, J, $, U, S = "loglevel";
61
+ typeof l == "string" ? S += ":" + l : typeof l == "symbol" && (S = void 0);
62
+ function Re(d) {
63
+ var y = (a[d] || "silent").toUpperCase();
64
+ if (!(typeof window === n || !S)) {
65
+ try {
66
+ window.localStorage[S] = y;
67
+ return;
68
+ } catch {
69
+ }
70
+ try {
71
+ window.document.cookie = encodeURIComponent(S) + "=" + y + ";";
72
+ } catch {
73
+ }
75
74
  }
76
75
  }
77
- }
78
- function ne() {
79
- var d;
80
- if (!(typeof window === r || !v)) {
81
- try {
82
- d = window.localStorage[v];
83
- } catch {
84
- }
85
- if (typeof d === r)
76
+ function ne() {
77
+ var d;
78
+ if (!(typeof window === n || !S)) {
86
79
  try {
87
- var g = window.document.cookie, N = encodeURIComponent(v), ie = g.indexOf(N + "=");
88
- ie !== -1 && (d = /^([^;]+)/.exec(
89
- g.slice(ie + N.length + 1)
90
- )[1]);
80
+ d = window.localStorage[S];
91
81
  } catch {
92
82
  }
93
- return c.levels[d] === void 0 && (d = void 0), d;
94
- }
95
- }
96
- function Pe() {
97
- if (!(typeof window === r || !v)) {
98
- try {
99
- window.localStorage.removeItem(v);
100
- } catch {
83
+ if (typeof d === n)
84
+ try {
85
+ var y = window.document.cookie, O = encodeURIComponent(S), oe = y.indexOf(O + "=");
86
+ oe !== -1 && (d = /^([^;]+)/.exec(
87
+ y.slice(oe + O.length + 1)
88
+ )[1]);
89
+ } catch {
90
+ }
91
+ return u.levels[d] === void 0 && (d = void 0), d;
101
92
  }
102
- try {
103
- window.document.cookie = encodeURIComponent(v) + "=; expires=Thu, 01 Jan 1970 00:00:00 UTC";
104
- } catch {
93
+ }
94
+ function Pe() {
95
+ if (!(typeof window === n || !S)) {
96
+ try {
97
+ window.localStorage.removeItem(S);
98
+ } catch {
99
+ }
100
+ try {
101
+ window.document.cookie = encodeURIComponent(S) + "=; expires=Thu, 01 Jan 1970 00:00:00 UTC";
102
+ } catch {
103
+ }
105
104
  }
106
105
  }
106
+ function L(d) {
107
+ var y = d;
108
+ if (typeof y == "string" && u.levels[y.toUpperCase()] !== void 0 && (y = u.levels[y.toUpperCase()]), typeof y == "number" && y >= 0 && y <= u.levels.SILENT)
109
+ return y;
110
+ throw new TypeError("log.setLevel() called with invalid level: " + d);
111
+ }
112
+ u.name = l, u.levels = {
113
+ TRACE: 0,
114
+ DEBUG: 1,
115
+ INFO: 2,
116
+ WARN: 3,
117
+ ERROR: 4,
118
+ SILENT: 5
119
+ }, u.methodFactory = m || _, u.getLevel = function() {
120
+ return U ?? $ ?? J;
121
+ }, u.setLevel = function(d, y) {
122
+ return U = L(d), y !== !1 && Re(U), f.call(u);
123
+ }, u.setDefaultLevel = function(d) {
124
+ $ = L(d), ne() || u.setLevel(d, !1);
125
+ }, u.resetLevel = function() {
126
+ U = null, Pe(), f.call(u);
127
+ }, u.enableAll = function(d) {
128
+ u.setLevel(u.levels.TRACE, d);
129
+ }, u.disableAll = function(d) {
130
+ u.setLevel(u.levels.SILENT, d);
131
+ }, u.rebuild = function() {
132
+ if (i !== u && (J = L(i.getLevel())), f.call(u), i === u)
133
+ for (var d in r)
134
+ r[d].rebuild();
135
+ }, J = L(
136
+ i ? i.getLevel() : "WARN"
137
+ );
138
+ var re = ne();
139
+ re != null && (U = L(re)), f.call(u);
107
140
  }
108
- function L(d) {
109
- var g = d;
110
- if (typeof g == "string" && c.levels[g.toUpperCase()] !== void 0 && (g = c.levels[g.toUpperCase()]), typeof g == "number" && g >= 0 && g <= c.levels.SILENT)
111
- return g;
112
- throw new TypeError("log.setLevel() called with invalid level: " + d);
113
- }
114
- c.name = l, c.levels = {
115
- TRACE: 0,
116
- DEBUG: 1,
117
- INFO: 2,
118
- WARN: 3,
119
- ERROR: 4,
120
- SILENT: 5
121
- }, c.methodFactory = w || h, c.getLevel = function() {
122
- return x ?? B ?? O;
123
- }, c.setLevel = function(d, g) {
124
- return x = L(d), g !== !1 && Re(x), y.call(c);
125
- }, c.setDefaultLevel = function(d) {
126
- B = L(d), ne() || c.setLevel(d, !1);
127
- }, c.resetLevel = function() {
128
- x = null, Pe(), y.call(c);
129
- }, c.enableAll = function(d) {
130
- c.setLevel(c.levels.TRACE, d);
131
- }, c.disableAll = function(d) {
132
- c.setLevel(c.levels.SILENT, d);
133
- }, c.rebuild = function() {
134
- if (i !== c && (O = L(i.getLevel())), y.call(c), i === c)
135
- for (var d in n)
136
- n[d].rebuild();
137
- }, O = L(
138
- i ? i.getLevel() : "WARN"
139
- );
140
- var oe = ne();
141
- oe != null && (x = L(oe)), y.call(c);
142
- }
143
- i = new R(), i.getLogger = function(w) {
144
- if (typeof w != "symbol" && typeof w != "string" || w === "")
145
- throw new TypeError("You must supply a name when creating a logger.");
146
- var c = n[w];
147
- return c || (c = n[w] = new R(
148
- w,
149
- i.methodFactory
150
- )), c;
151
- };
152
- var P = typeof window !== r ? window.log : void 0;
153
- return i.noConflict = function() {
154
- return typeof window !== r && window.log === i && (window.log = P), i;
155
- }, i.getLoggers = function() {
156
- return n;
157
- }, i.default = i, i;
158
- });
159
- })(fe);
160
- var $e = fe.exports;
161
- const K = /* @__PURE__ */ Ie($e);
162
- let Y;
163
- var D, he;
164
- (typeof navigator > "u" || !((he = (D = navigator.userAgent) == null ? void 0 : D.startsWith) != null && he.call(D, "Mozilla/5.0 "))) && (Y = "oauth4webapi/v2.11.1");
165
- function Q(t, e) {
141
+ i = new h(), i.getLogger = function(m) {
142
+ if (typeof m != "symbol" && typeof m != "string" || m === "")
143
+ throw new TypeError("You must supply a name when creating a logger.");
144
+ var u = r[m];
145
+ return u || (u = r[m] = new h(
146
+ m,
147
+ i.methodFactory
148
+ )), u;
149
+ };
150
+ var P = typeof window !== n ? window.log : void 0;
151
+ return i.noConflict = function() {
152
+ return typeof window !== n && window.log === i && (window.log = P), i;
153
+ }, i.getLoggers = function() {
154
+ return r;
155
+ }, i.default = i, i;
156
+ });
157
+ }(D)), D.exports;
158
+ }
159
+ var We = Ne();
160
+ const se = /* @__PURE__ */ Ce(We);
161
+ let V;
162
+ var z, we;
163
+ (typeof navigator > "u" || !((we = (z = navigator.userAgent) == null ? void 0 : z.startsWith) != null && we.call(z, "Mozilla/5.0 "))) && (V = "oauth4webapi/v2.17.0");
164
+ function Y(t, e) {
166
165
  if (t == null)
167
166
  return !1;
168
167
  try {
@@ -171,81 +170,81 @@ function Q(t, e) {
171
170
  return !1;
172
171
  }
173
172
  }
174
- const H = Symbol(), Fe = Symbol(), X = Symbol(), Me = new TextEncoder(), Be = new TextDecoder();
175
- function A(t) {
176
- return typeof t == "string" ? Me.encode(t) : Be.decode(t);
173
+ const W = Symbol(), Ke = Symbol(), Z = Symbol(), He = Symbol(), $e = Symbol(), Fe = Symbol(), Me = new TextEncoder(), qe = new TextDecoder();
174
+ function E(t) {
175
+ return typeof t == "string" ? Me.encode(t) : qe.decode(t);
177
176
  }
178
- const se = 32768;
179
- function qe(t) {
177
+ const ce = 32768;
178
+ function Be(t) {
180
179
  t instanceof ArrayBuffer && (t = new Uint8Array(t));
181
180
  const e = [];
182
- for (let r = 0; r < t.byteLength; r += se)
183
- e.push(String.fromCharCode.apply(null, t.subarray(r, r + se)));
181
+ for (let n = 0; n < t.byteLength; n += ce)
182
+ e.push(String.fromCharCode.apply(null, t.subarray(n, n + ce)));
184
183
  return btoa(e.join("")).replace(/=/g, "").replace(/\+/g, "-").replace(/\//g, "_");
185
184
  }
186
- function Ge(t) {
185
+ function Ve(t) {
187
186
  try {
188
- const e = atob(t.replace(/-/g, "+").replace(/_/g, "/").replace(/\s/g, "")), r = new Uint8Array(e.length);
187
+ const e = atob(t.replace(/-/g, "+").replace(/_/g, "/").replace(/\s/g, "")), n = new Uint8Array(e.length);
189
188
  for (let o = 0; o < e.length; o++)
190
- r[o] = e.charCodeAt(o);
191
- return r;
189
+ n[o] = e.charCodeAt(o);
190
+ return n;
192
191
  } catch (e) {
193
- throw new a("The input to be decoded is not correctly encoded.", { cause: e });
192
+ throw new s("The input to be decoded is not correctly encoded.", { cause: e });
194
193
  }
195
194
  }
196
195
  function k(t) {
197
- return typeof t == "string" ? Ge(t) : qe(t);
196
+ return typeof t == "string" ? Ve(t) : Be(t);
198
197
  }
199
- class Ve {
198
+ class Ge {
200
199
  constructor(e) {
201
200
  this.cache = /* @__PURE__ */ new Map(), this._cache = /* @__PURE__ */ new Map(), this.maxSize = e;
202
201
  }
203
202
  get(e) {
204
- let r = this.cache.get(e);
205
- if (r)
206
- return r;
207
- if (r = this._cache.get(e))
208
- return this.update(e, r), r;
203
+ let n = this.cache.get(e);
204
+ if (n)
205
+ return n;
206
+ if (n = this._cache.get(e))
207
+ return this.update(e, n), n;
209
208
  }
210
209
  has(e) {
211
210
  return this.cache.has(e) || this._cache.has(e);
212
211
  }
213
- set(e, r) {
214
- return this.cache.has(e) ? this.cache.set(e, r) : this.update(e, r), this;
212
+ set(e, n) {
213
+ return this.cache.has(e) ? this.cache.set(e, n) : this.update(e, n), this;
215
214
  }
216
215
  delete(e) {
217
216
  return this.cache.has(e) ? this.cache.delete(e) : this._cache.has(e) ? this._cache.delete(e) : !1;
218
217
  }
219
- update(e, r) {
220
- this.cache.set(e, r), this.cache.size >= this.maxSize && (this._cache = this.cache, this.cache = /* @__PURE__ */ new Map());
218
+ update(e, n) {
219
+ this.cache.set(e, n), this.cache.size >= this.maxSize && (this._cache = this.cache, this.cache = /* @__PURE__ */ new Map());
221
220
  }
222
221
  }
223
- class S extends Error {
222
+ class T extends Error {
224
223
  constructor(e) {
225
- var r;
226
- super(e ?? "operation not supported"), this.name = this.constructor.name, (r = Error.captureStackTrace) == null || r.call(Error, this, this.constructor);
224
+ var n;
225
+ super(e ?? "operation not supported"), this.name = this.constructor.name, (n = Error.captureStackTrace) == null || n.call(Error, this, this.constructor);
227
226
  }
228
227
  }
229
228
  class Ye extends Error {
230
- constructor(e, r) {
229
+ constructor(e, n) {
231
230
  var o;
232
- super(e, r), this.name = this.constructor.name, (o = Error.captureStackTrace) == null || o.call(Error, this, this.constructor);
231
+ super(e, n), this.name = this.constructor.name, (o = Error.captureStackTrace) == null || o.call(Error, this, this.constructor);
233
232
  }
234
233
  }
235
- const a = Ye, pe = new Ve(100);
236
- function we(t) {
234
+ const s = Ye, ge = new Ge(100);
235
+ function me(t) {
237
236
  return t instanceof CryptoKey;
238
237
  }
239
- function ge(t) {
240
- return we(t) && t.type === "private";
241
- }
242
238
  function Ze(t) {
243
- return we(t) && t.type === "public";
239
+ return me(t) && t.type === "private";
240
+ }
241
+ function Qe(t) {
242
+ return me(t) && t.type === "public";
244
243
  }
245
- function ee(t) {
244
+ function Q(t) {
246
245
  try {
247
246
  const e = t.headers.get("dpop-nonce");
248
- e && pe.set(new URL(t.url).origin, e);
247
+ e && ge.set(new URL(t.url).origin, e);
249
248
  } catch {
250
249
  }
251
250
  return t;
@@ -253,101 +252,92 @@ function ee(t) {
253
252
  function C(t) {
254
253
  return !(t === null || typeof t != "object" || Array.isArray(t));
255
254
  }
256
- function $(t) {
257
- Q(t, Headers) && (t = Object.fromEntries(t.entries()));
255
+ function K(t) {
256
+ Y(t, Headers) && (t = Object.fromEntries(t.entries()));
258
257
  const e = new Headers(t);
259
- if (Y && !e.has("user-agent") && e.set("user-agent", Y), e.has("authorization"))
258
+ if (V && !e.has("user-agent") && e.set("user-agent", V), e.has("authorization"))
260
259
  throw new TypeError('"options.headers" must not include the "authorization" header name');
261
260
  if (e.has("dpop"))
262
261
  throw new TypeError('"options.headers" must not include the "dpop" header name');
263
262
  return e;
264
263
  }
265
- function te(t) {
264
+ function Xe(t) {
266
265
  if (typeof t == "function" && (t = t()), !(t instanceof AbortSignal))
267
266
  throw new TypeError('"options.signal" must return or be an instance of AbortSignal');
268
267
  return t;
269
268
  }
270
- async function Qe(t, e) {
269
+ async function et(t, e) {
271
270
  if (!(t instanceof URL))
272
271
  throw new TypeError('"issuerIdentifier" must be an instance of URL');
273
272
  if (t.protocol !== "https:" && t.protocol !== "http:")
274
273
  throw new TypeError('"issuer.protocol" must be "https:" or "http:"');
275
- const r = new URL(t.href);
274
+ const n = new URL(t.href);
276
275
  switch (e == null ? void 0 : e.algorithm) {
277
276
  case void 0:
278
277
  case "oidc":
279
- r.pathname = `${r.pathname}/.well-known/openid-configuration`.replace("//", "/");
278
+ n.pathname = `${n.pathname}/.well-known/openid-configuration`.replace("//", "/");
280
279
  break;
281
280
  case "oauth2":
282
- r.pathname === "/" ? r.pathname = ".well-known/oauth-authorization-server" : r.pathname = `.well-known/oauth-authorization-server/${r.pathname}`.replace("//", "/");
281
+ n.pathname === "/" ? n.pathname = ".well-known/oauth-authorization-server" : n.pathname = `.well-known/oauth-authorization-server/${n.pathname}`.replace("//", "/");
283
282
  break;
284
283
  default:
285
284
  throw new TypeError('"options.algorithm" must be "oidc" (default), or "oauth2"');
286
285
  }
287
- const o = $(e == null ? void 0 : e.headers);
288
- return o.set("accept", "application/json"), ((e == null ? void 0 : e[X]) || fetch)(r.href, {
286
+ const o = K(e == null ? void 0 : e.headers);
287
+ return o.set("accept", "application/json"), ((e == null ? void 0 : e[Z]) || fetch)(n.href, {
289
288
  headers: Object.fromEntries(o.entries()),
290
289
  method: "GET",
291
290
  redirect: "manual",
292
- signal: e != null && e.signal ? te(e.signal) : null
293
- }).then(ee);
291
+ signal: null
292
+ }).then(Q);
294
293
  }
295
- function p(t) {
294
+ function g(t) {
296
295
  return typeof t == "string" && t.length !== 0;
297
296
  }
298
- async function Xe(t, e) {
297
+ async function tt(t, e) {
299
298
  if (!(t instanceof URL))
300
299
  throw new TypeError('"expectedIssuer" must be an instance of URL');
301
- if (!Q(e, Response))
300
+ if (!Y(e, Response))
302
301
  throw new TypeError('"response" must be an instance of Response');
303
302
  if (e.status !== 200)
304
- throw new a('"response" is not a conform Authorization Server Metadata response');
305
- re(e);
306
- let r;
303
+ throw new s('"response" is not a conform Authorization Server Metadata response');
304
+ te(e);
305
+ let n;
307
306
  try {
308
- r = await e.json();
307
+ n = await e.json();
309
308
  } catch (o) {
310
- throw new a('failed to parse "response" body as JSON', { cause: o });
309
+ throw new s('failed to parse "response" body as JSON', { cause: o });
311
310
  }
312
- if (!C(r))
313
- throw new a('"response" body must be a top level object');
314
- if (!p(r.issuer))
315
- throw new a('"response" body "issuer" property must be a non-empty string');
316
- if (new URL(r.issuer).href !== t.href)
317
- throw new a('"response" body "issuer" does not match "expectedIssuer"');
318
- return r;
311
+ if (!C(n))
312
+ throw new s('"response" body must be a top level object');
313
+ if (!g(n.issuer))
314
+ throw new s('"response" body "issuer" property must be a non-empty string');
315
+ if (new URL(n.issuer).href !== t.href)
316
+ throw new s('"response" body "issuer" does not match "expectedIssuer"');
317
+ return n;
319
318
  }
320
- function F() {
319
+ function X() {
321
320
  return k(crypto.getRandomValues(new Uint8Array(32)));
322
321
  }
323
- function et() {
324
- return F();
322
+ function nt() {
323
+ return X();
325
324
  }
326
- function tt() {
327
- return F();
325
+ function rt() {
326
+ return X();
328
327
  }
329
- async function rt(t) {
330
- if (!p(t))
328
+ async function ot(t) {
329
+ if (!g(t))
331
330
  throw new TypeError('"codeVerifier" must be a non-empty string');
332
- return k(await crypto.subtle.digest("SHA-256", A(t)));
333
- }
334
- function nt(t) {
335
- if (t instanceof CryptoKey)
336
- return { key: t };
337
- if (!((t == null ? void 0 : t.key) instanceof CryptoKey))
338
- return {};
339
- if (t.kid !== void 0 && !p(t.kid))
340
- throw new TypeError('"kid" must be a non-empty string');
341
- return { key: t.key, kid: t.kid };
342
- }
343
- function ae(t) {
331
+ return k(await crypto.subtle.digest("SHA-256", E(t)));
332
+ }
333
+ function ue(t) {
344
334
  return encodeURIComponent(t).replace(/%20/g, "+");
345
335
  }
346
- function ot(t, e) {
347
- const r = ae(t), o = ae(e);
348
- return `Basic ${btoa(`${r}:${o}`)}`;
336
+ function it(t, e) {
337
+ const n = ue(t), o = ue(e);
338
+ return `Basic ${btoa(`${n}:${o}`)}`;
349
339
  }
350
- function it(t) {
340
+ function at(t) {
351
341
  switch (t.algorithm.hash.name) {
352
342
  case "SHA-256":
353
343
  return "PS256";
@@ -356,7 +346,7 @@ function it(t) {
356
346
  case "SHA-512":
357
347
  return "PS512";
358
348
  default:
359
- throw new S("unsupported RsaHashedKeyAlgorithm hash name");
349
+ throw new T("unsupported RsaHashedKeyAlgorithm hash name");
360
350
  }
361
351
  }
362
352
  function st(t) {
@@ -368,10 +358,10 @@ function st(t) {
368
358
  case "SHA-512":
369
359
  return "RS512";
370
360
  default:
371
- throw new S("unsupported RsaHashedKeyAlgorithm hash name");
361
+ throw new T("unsupported RsaHashedKeyAlgorithm hash name");
372
362
  }
373
363
  }
374
- function at(t) {
364
+ function ct(t) {
375
365
  switch (t.algorithm.namedCurve) {
376
366
  case "P-256":
377
367
  return "ES256";
@@ -380,201 +370,176 @@ function at(t) {
380
370
  case "P-521":
381
371
  return "ES512";
382
372
  default:
383
- throw new S("unsupported EcKeyAlgorithm namedCurve");
373
+ throw new T("unsupported EcKeyAlgorithm namedCurve");
384
374
  }
385
375
  }
386
- function me(t) {
376
+ function ut(t) {
387
377
  switch (t.algorithm.name) {
388
378
  case "RSA-PSS":
389
- return it(t);
379
+ return at(t);
390
380
  case "RSASSA-PKCS1-v1_5":
391
381
  return st(t);
392
382
  case "ECDSA":
393
- return at(t);
383
+ return ct(t);
394
384
  case "Ed25519":
395
385
  case "Ed448":
396
386
  return "EdDSA";
397
387
  default:
398
- throw new S("unsupported CryptoKey algorithm name");
388
+ throw new T("unsupported CryptoKey algorithm name");
399
389
  }
400
390
  }
401
- function I(t) {
402
- const e = t == null ? void 0 : t[H];
391
+ function H(t) {
392
+ const e = t == null ? void 0 : t[W];
403
393
  return typeof e == "number" && Number.isFinite(e) ? e : 0;
404
394
  }
405
395
  function ye(t) {
406
- const e = t == null ? void 0 : t[Fe];
396
+ const e = t == null ? void 0 : t[Ke];
407
397
  return typeof e == "number" && Number.isFinite(e) && Math.sign(e) !== -1 ? e : 30;
408
398
  }
409
- function M() {
399
+ function ee() {
410
400
  return Math.floor(Date.now() / 1e3);
411
401
  }
412
- function ct(t, e) {
413
- const r = M() + I(e);
414
- return {
415
- jti: F(),
416
- aud: [t.issuer, t.token_endpoint],
417
- exp: r + 60,
418
- iat: r,
419
- nbf: r,
420
- iss: e.client_id,
421
- sub: e.client_id
422
- };
423
- }
424
- async function ut(t, e, r, o) {
425
- return be({
426
- alg: me(r),
427
- kid: o
428
- }, ct(t, e), r);
429
- }
430
- function j(t) {
402
+ function I(t) {
431
403
  if (typeof t != "object" || t === null)
432
404
  throw new TypeError('"as" must be an object');
433
- if (!p(t.issuer))
405
+ if (!g(t.issuer))
434
406
  throw new TypeError('"as.issuer" property must be a non-empty string');
435
407
  return !0;
436
408
  }
437
- function J(t) {
409
+ function j(t) {
438
410
  if (typeof t != "object" || t === null)
439
411
  throw new TypeError('"client" must be an object');
440
- if (!p(t.client_id))
412
+ if (!g(t.client_id))
441
413
  throw new TypeError('"client.client_id" property must be a non-empty string');
442
414
  return !0;
443
415
  }
444
- function ce(t) {
445
- if (!p(t))
416
+ function le(t) {
417
+ if (!g(t))
446
418
  throw new TypeError('"client.client_secret" property must be a non-empty string');
447
419
  return t;
448
420
  }
449
- function q(t, e) {
450
- if (e !== void 0)
451
- throw new TypeError(`"options.clientPrivateKey" property must not be provided when ${t} client authentication method is used.`);
452
- }
453
- function ue(t, e) {
421
+ function de(t, e) {
454
422
  if (e !== void 0)
455
423
  throw new TypeError(`"client.client_secret" property must not be provided when ${t} client authentication method is used.`);
456
424
  }
457
- async function lt(t, e, r, o, s) {
458
- switch (r.delete("client_secret"), r.delete("client_assertion_type"), r.delete("client_assertion"), e.token_endpoint_auth_method) {
425
+ async function lt(t, e, n, o, a) {
426
+ switch (n.delete("client_secret"), n.delete("client_assertion_type"), n.delete("client_assertion"), e.token_endpoint_auth_method) {
459
427
  case void 0:
460
428
  case "client_secret_basic": {
461
- q("client_secret_basic", s), o.set("authorization", ot(e.client_id, ce(e.client_secret)));
429
+ o.set("authorization", it(e.client_id, le(e.client_secret)));
462
430
  break;
463
431
  }
464
432
  case "client_secret_post": {
465
- q("client_secret_post", s), r.set("client_id", e.client_id), r.set("client_secret", ce(e.client_secret));
466
- break;
467
- }
468
- case "private_key_jwt": {
469
- if (ue("private_key_jwt", e.client_secret), s === void 0)
470
- throw new TypeError('"options.clientPrivateKey" must be provided when "client.token_endpoint_auth_method" is "private_key_jwt"');
471
- const { key: n, kid: i } = nt(s);
472
- if (!ge(n))
473
- throw new TypeError('"options.clientPrivateKey.key" must be a private CryptoKey');
474
- r.set("client_id", e.client_id), r.set("client_assertion_type", "urn:ietf:params:oauth:client-assertion-type:jwt-bearer"), r.set("client_assertion", await ut(t, e, n, i));
433
+ n.set("client_id", e.client_id), n.set("client_secret", le(e.client_secret));
475
434
  break;
476
435
  }
436
+ case "private_key_jwt":
437
+ throw de("private_key_jwt", e.client_secret), new TypeError('"options.clientPrivateKey" must be provided when "client.token_endpoint_auth_method" is "private_key_jwt"');
477
438
  case "tls_client_auth":
478
439
  case "self_signed_tls_client_auth":
479
440
  case "none": {
480
- ue(e.token_endpoint_auth_method, e.client_secret), q(e.token_endpoint_auth_method, s), r.set("client_id", e.client_id);
441
+ de(e.token_endpoint_auth_method, e.client_secret), e.token_endpoint_auth_method, n.set("client_id", e.client_id);
481
442
  break;
482
443
  }
483
444
  default:
484
- throw new S("unsupported client token_endpoint_auth_method");
445
+ throw new T("unsupported client token_endpoint_auth_method");
485
446
  }
486
447
  }
487
- async function be(t, e, r) {
488
- if (!r.usages.includes("sign"))
448
+ async function dt(t, e, n) {
449
+ if (!n.usages.includes("sign"))
489
450
  throw new TypeError('CryptoKey instances used for signing assertions must include "sign" in their "usages"');
490
- const o = `${k(A(JSON.stringify(t)))}.${k(A(JSON.stringify(e)))}`, s = k(await crypto.subtle.sign(Ee(r), r, A(o)));
491
- return `${o}.${s}`;
451
+ const o = `${k(E(JSON.stringify(t)))}.${k(E(JSON.stringify(e)))}`, a = k(await crypto.subtle.sign(ke(n), n, E(o)));
452
+ return `${o}.${a}`;
492
453
  }
493
- async function dt(t, e, r, o, s, n) {
494
- const { privateKey: i, publicKey: u, nonce: f = pe.get(r.origin) } = e;
495
- if (!ge(i))
454
+ async function ht(t, e, n, o, a, r) {
455
+ var _;
456
+ const { privateKey: i, publicKey: c, nonce: p = ge.get(n.origin) } = e;
457
+ if (!Ze(i))
496
458
  throw new TypeError('"DPoP.privateKey" must be a private CryptoKey');
497
- if (!Ze(u))
459
+ if (!Qe(c))
498
460
  throw new TypeError('"DPoP.publicKey" must be a public CryptoKey');
499
- if (f !== void 0 && !p(f))
461
+ if (p !== void 0 && !g(p))
500
462
  throw new TypeError('"DPoP.nonce" must be a non-empty string or undefined');
501
- if (!u.extractable)
463
+ if (!c.extractable)
502
464
  throw new TypeError('"DPoP.publicKey.extractable" must be true');
503
- const m = M() + s, y = await be({
504
- alg: me(i),
465
+ const w = ee() + a, f = {
466
+ alg: ut(i),
505
467
  typ: "dpop+jwt",
506
- jwk: await ft(u)
507
- }, {
508
- iat: m,
509
- jti: F(),
468
+ jwk: await pt(c)
469
+ }, v = {
470
+ iat: w,
471
+ jti: X(),
510
472
  htm: o,
511
- nonce: f,
512
- htu: `${r.origin}${r.pathname}`,
513
- ath: n ? k(await crypto.subtle.digest("SHA-256", A(n))) : void 0
514
- }, i);
515
- t.set("dpop", y);
516
- }
517
- let W;
518
- async function ht(t) {
519
- const { kty: e, e: r, n: o, x: s, y: n, crv: i } = await crypto.subtle.exportKey("jwk", t), u = { kty: e, e: r, n: o, x: s, y: n, crv: i };
520
- return W.set(t, u), u;
473
+ nonce: p,
474
+ htu: `${n.origin}${n.pathname}`,
475
+ ath: r ? k(await crypto.subtle.digest("SHA-256", E(r))) : void 0
476
+ };
477
+ (_ = e[He]) == null || _.call(e, f, v), t.set("dpop", await dt(f, v, i));
521
478
  }
479
+ let N;
522
480
  async function ft(t) {
523
- return W || (W = /* @__PURE__ */ new WeakMap()), W.get(t) || ht(t);
481
+ const { kty: e, e: n, n: o, x: a, y: r, crv: i } = await crypto.subtle.exportKey("jwk", t), c = { kty: e, e: n, n: o, x: a, y: r, crv: i };
482
+ return N.set(t, c), c;
483
+ }
484
+ async function pt(t) {
485
+ return N || (N = /* @__PURE__ */ new WeakMap()), N.get(t) || ft(t);
524
486
  }
525
- function pt(t, e, r) {
487
+ function he(t, e, n) {
526
488
  if (typeof t != "string")
527
- throw new TypeError(`"as.${e}" must be a string`);
489
+ throw n ? new TypeError(`"as.mtls_endpoint_aliases.${e}" must be a string`) : new TypeError(`"as.${e}" must be a string`);
528
490
  return new URL(t);
529
491
  }
530
- function _e(t, e, r) {
531
- return pt(t[e], e);
492
+ function be(t, e, n = !1) {
493
+ return n && t.mtls_endpoint_aliases && e in t.mtls_endpoint_aliases ? he(t.mtls_endpoint_aliases[e], e, n) : he(t[e], e, n);
532
494
  }
533
- function Z(t) {
495
+ function _e(t, e) {
496
+ return !!(t.use_mtls_endpoint_aliases || e != null && e[Fe]);
497
+ }
498
+ function G(t) {
534
499
  const e = t;
535
500
  return typeof e != "object" || Array.isArray(e) || e === null ? !1 : e.error !== void 0;
536
501
  }
537
- async function wt(t, e, r, o, s, n) {
538
- if (!p(t))
502
+ async function wt(t, e, n, o, a, r) {
503
+ if (!g(t))
539
504
  throw new TypeError('"accessToken" must be a non-empty string');
540
- if (!(r instanceof URL))
505
+ if (!(n instanceof URL))
541
506
  throw new TypeError('"url" must be an instance of URL');
542
- return o = $(o), (n == null ? void 0 : n.DPoP) === void 0 ? o.set("authorization", `Bearer ${t}`) : (await dt(o, n.DPoP, r, "GET", I({ [H]: n == null ? void 0 : n[H] }), t), o.set("authorization", `DPoP ${t}`)), ((n == null ? void 0 : n[X]) || fetch)(r.href, {
543
- body: s,
507
+ return o = K(o), (r == null ? void 0 : r.DPoP) === void 0 ? o.set("authorization", `Bearer ${t}`) : (await ht(o, r.DPoP, n, e.toUpperCase(), H({ [W]: r == null ? void 0 : r[W] }), t), o.set("authorization", `DPoP ${t}`)), ((r == null ? void 0 : r[Z]) || fetch)(n.href, {
508
+ body: a,
544
509
  headers: Object.fromEntries(o.entries()),
545
510
  method: e,
546
511
  redirect: "manual",
547
- signal: n != null && n.signal ? te(n.signal) : null
548
- }).then(ee);
512
+ signal: r != null && r.signal ? Xe(r.signal) : null
513
+ }).then(Q);
549
514
  }
550
- async function gt(t, e, r, o) {
551
- j(t), J(e);
552
- const s = _e(t, "userinfo_endpoint"), n = $(o == null ? void 0 : o.headers);
553
- return e.userinfo_signed_response_alg ? n.set("accept", "application/jwt") : (n.set("accept", "application/json"), n.append("accept", "application/jwt")), wt(r, "GET", s, n, null, {
515
+ async function gt(t, e, n, o) {
516
+ I(t), j(e);
517
+ const a = be(t, "userinfo_endpoint", _e(e, o)), r = K(o == null ? void 0 : o.headers);
518
+ return e.userinfo_signed_response_alg ? r.set("accept", "application/jwt") : (r.set("accept", "application/json"), r.append("accept", "application/jwt")), wt(n, "GET", a, r, null, {
554
519
  ...o,
555
- [H]: I(e)
520
+ [W]: H(e)
556
521
  });
557
522
  }
558
- async function mt(t, e, r, o, s, n, i) {
559
- return await lt(t, e, s, n, i == null ? void 0 : i.clientPrivateKey), n.set("content-type", "application/x-www-form-urlencoded;charset=UTF-8"), ((i == null ? void 0 : i[X]) || fetch)(o.href, {
560
- body: s,
561
- headers: Object.fromEntries(n.entries()),
562
- method: r,
523
+ async function mt(t, e, n, o, a, r, i) {
524
+ return await lt(t, e, a, r), r.set("content-type", "application/x-www-form-urlencoded;charset=UTF-8"), ((i == null ? void 0 : i[Z]) || fetch)(o.href, {
525
+ body: a,
526
+ headers: Object.fromEntries(r.entries()),
527
+ method: n,
563
528
  redirect: "manual",
564
- signal: i != null && i.signal ? te(i.signal) : null
565
- }).then(ee);
529
+ signal: null
530
+ }).then(Q);
566
531
  }
567
- async function ve(t, e, r, o, s) {
568
- const n = _e(t, "token_endpoint");
569
- o.set("grant_type", r);
570
- const i = $(s == null ? void 0 : s.headers);
571
- return i.set("accept", "application/json"), mt(t, e, "POST", n, o, i, s);
532
+ async function ve(t, e, n, o, a) {
533
+ const r = be(t, "token_endpoint", _e(e, a));
534
+ o.set("grant_type", n);
535
+ const i = K(a == null ? void 0 : a.headers);
536
+ return i.set("accept", "application/json"), mt(t, e, "POST", r, o, i, a);
572
537
  }
573
- async function yt(t, e, r, o) {
574
- if (j(t), J(e), !p(r))
538
+ async function yt(t, e, n, o) {
539
+ if (I(t), j(e), !g(n))
575
540
  throw new TypeError('"refreshToken" must be a non-empty string');
576
- const s = new URLSearchParams(o == null ? void 0 : o.additionalParameters);
577
- return s.set("refresh_token", r), ve(t, e, "refresh_token", s, o);
541
+ const a = new URLSearchParams(o == null ? void 0 : o.additionalParameters);
542
+ return a.set("refresh_token", n), ve(t, e, "refresh_token", a, o);
578
543
  }
579
544
  const Se = /* @__PURE__ */ new WeakMap();
580
545
  function bt(t) {
@@ -583,86 +548,90 @@ function bt(t) {
583
548
  const e = Se.get(t);
584
549
  if (!e)
585
550
  throw new TypeError('"ref" was already garbage collected or did not resolve from the proper sources');
586
- return e;
551
+ return e[0];
587
552
  }
588
- async function Te(t, e, r, o = !1, s = !1) {
589
- if (j(t), J(e), !Q(r, Response))
553
+ async function Te(t, e, n, o = !1, a = !1) {
554
+ if (I(t), j(e), !Y(n, Response))
590
555
  throw new TypeError('"response" must be an instance of Response');
591
- if (r.status !== 200) {
556
+ if (n.status !== 200) {
592
557
  let i;
593
- if (i = await xt(r))
558
+ if (i = await Ut(n))
594
559
  return i;
595
- throw new a('"response" is not a conform Token Endpoint response');
560
+ throw new s('"response" is not a conform Token Endpoint response');
596
561
  }
597
- re(r);
598
- let n;
562
+ te(n);
563
+ let r;
599
564
  try {
600
- n = await r.json();
565
+ r = await n.json();
601
566
  } catch (i) {
602
- throw new a('failed to parse "response" body as JSON', { cause: i });
567
+ throw new s('failed to parse "response" body as JSON', { cause: i });
603
568
  }
604
- if (!C(n))
605
- throw new a('"response" body must be a top level object');
606
- if (!p(n.access_token))
607
- throw new a('"response" body "access_token" property must be a non-empty string');
608
- if (!p(n.token_type))
609
- throw new a('"response" body "token_type" property must be a non-empty string');
610
- if (n.token_type = n.token_type.toLowerCase(), n.token_type !== "dpop" && n.token_type !== "bearer")
611
- throw new S("unsupported `token_type` value");
612
- if (n.expires_in !== void 0 && (typeof n.expires_in != "number" || n.expires_in <= 0))
613
- throw new a('"response" body "expires_in" property must be a positive number');
614
- if (!s && n.refresh_token !== void 0 && !p(n.refresh_token))
615
- throw new a('"response" body "refresh_token" property must be a non-empty string');
616
- if (n.scope !== void 0 && typeof n.scope != "string")
617
- throw new a('"response" body "scope" property must be a string');
569
+ if (!C(r))
570
+ throw new s('"response" body must be a top level object');
571
+ if (!g(r.access_token))
572
+ throw new s('"response" body "access_token" property must be a non-empty string');
573
+ if (!g(r.token_type))
574
+ throw new s('"response" body "token_type" property must be a non-empty string');
575
+ if (r.token_type = r.token_type.toLowerCase(), r.token_type !== "dpop" && r.token_type !== "bearer")
576
+ throw new T("unsupported `token_type` value");
577
+ if (r.expires_in !== void 0 && (typeof r.expires_in != "number" || r.expires_in <= 0))
578
+ throw new s('"response" body "expires_in" property must be a positive number');
579
+ if (!a && r.refresh_token !== void 0 && !g(r.refresh_token))
580
+ throw new s('"response" body "refresh_token" property must be a non-empty string');
581
+ if (r.scope !== void 0 && typeof r.scope != "string")
582
+ throw new s('"response" body "scope" property must be a string');
618
583
  if (!o) {
619
- if (n.id_token !== void 0 && !p(n.id_token))
620
- throw new a('"response" body "id_token" property must be a non-empty string');
621
- if (n.id_token) {
622
- const { claims: i } = await Lt(n.id_token, Ct.bind(void 0, e.id_token_signed_response_alg, t.id_token_signing_alg_values_supported), Ae, I(e), ye(e)).then(At.bind(void 0, ["aud", "exp", "iat", "iss", "sub"])).then(St.bind(void 0, t.issuer)).then(vt.bind(void 0, e.client_id));
623
- if (Array.isArray(i.aud) && i.aud.length !== 1 && i.azp !== e.client_id)
624
- throw new a('unexpected ID Token "azp" (authorized party) claim value');
584
+ if (r.id_token !== void 0 && !g(r.id_token))
585
+ throw new s('"response" body "id_token" property must be a non-empty string');
586
+ if (r.id_token) {
587
+ const { claims: i, jwt: c } = await Ct(r.id_token, It.bind(void 0, e.id_token_signed_response_alg, t.id_token_signing_alg_values_supported), Ee, H(e), ye(e), e[$e]).then(Et.bind(void 0, ["aud", "exp", "iat", "iss", "sub"])).then(St.bind(void 0, t.issuer)).then(vt.bind(void 0, e.client_id));
588
+ if (Array.isArray(i.aud) && i.aud.length !== 1) {
589
+ if (i.azp === void 0)
590
+ throw new s('ID Token "aud" (audience) claim includes additional untrusted audiences');
591
+ if (i.azp !== e.client_id)
592
+ throw new s('unexpected ID Token "azp" (authorized party) claim value');
593
+ }
625
594
  if (i.auth_time !== void 0 && (!Number.isFinite(i.auth_time) || Math.sign(i.auth_time) !== 1))
626
- throw new a('ID Token "auth_time" (authentication time) must be a positive number');
627
- Se.set(n, i);
595
+ throw new s('ID Token "auth_time" (authentication time) must be a positive number');
596
+ Se.set(r, [i, c]);
628
597
  }
629
598
  }
630
- return n;
599
+ return r;
631
600
  }
632
- async function _t(t, e, r) {
633
- return Te(t, e, r);
601
+ async function _t(t, e, n) {
602
+ return Te(t, e, n);
634
603
  }
635
604
  function vt(t, e) {
636
605
  if (Array.isArray(e.claims.aud)) {
637
606
  if (!e.claims.aud.includes(t))
638
- throw new a('unexpected JWT "aud" (audience) claim value');
607
+ throw new s('unexpected JWT "aud" (audience) claim value');
639
608
  } else if (e.claims.aud !== t)
640
- throw new a('unexpected JWT "aud" (audience) claim value');
609
+ throw new s('unexpected JWT "aud" (audience) claim value');
641
610
  return e;
642
611
  }
643
612
  function St(t, e) {
644
613
  if (e.claims.iss !== t)
645
- throw new a('unexpected JWT "iss" (issuer) claim value');
614
+ throw new s('unexpected JWT "iss" (issuer) claim value');
646
615
  return e;
647
616
  }
648
- const ke = /* @__PURE__ */ new WeakSet();
617
+ const Ae = /* @__PURE__ */ new WeakSet();
649
618
  function Tt(t) {
650
- return ke.add(t), t;
619
+ return Ae.add(t), t;
651
620
  }
652
- async function kt(t, e, r, o, s, n) {
653
- if (j(t), J(e), !ke.has(r))
621
+ async function At(t, e, n, o, a, r) {
622
+ if (I(t), j(e), !Ae.has(n))
654
623
  throw new TypeError('"callbackParameters" must be an instance of URLSearchParams obtained from "validateAuthResponse()", or "validateJwtAuthResponse()');
655
- if (!p(o))
624
+ if (!g(o))
656
625
  throw new TypeError('"redirectUri" must be a non-empty string');
657
- if (!p(s))
626
+ if (!g(a))
658
627
  throw new TypeError('"codeVerifier" must be a non-empty string');
659
- const i = T(r, "code");
628
+ const i = A(n, "code");
660
629
  if (!i)
661
- throw new a('no authorization code in "callbackParameters"');
662
- const u = new URLSearchParams(n == null ? void 0 : n.additionalParameters);
663
- return u.set("redirect_uri", o), u.set("code_verifier", s), u.set("code", i), ve(t, e, "authorization_code", u, n);
630
+ throw new s('no authorization code in "callbackParameters"');
631
+ const c = new URLSearchParams(r == null ? void 0 : r.additionalParameters);
632
+ return c.set("redirect_uri", o), c.set("code_verifier", a), c.set("code", i), ve(t, e, "authorization_code", c, r);
664
633
  }
665
- const Et = {
634
+ const kt = {
666
635
  aud: "audience",
667
636
  c_hash: "code hash",
668
637
  client_id: "client id",
@@ -678,53 +647,53 @@ const Et = {
678
647
  htu: "http uri",
679
648
  cnf: "confirmation"
680
649
  };
681
- function At(t, e) {
682
- for (const r of t)
683
- if (e.claims[r] === void 0)
684
- throw new a(`JWT "${r}" (${Et[r]}) claim missing`);
650
+ function Et(t, e) {
651
+ for (const n of t)
652
+ if (e.claims[n] === void 0)
653
+ throw new s(`JWT "${n}" (${kt[n]}) claim missing`);
685
654
  return e;
686
655
  }
687
- const Rt = Symbol(), G = Symbol();
688
- async function Pt(t, e, r, o, s) {
689
- const n = await Te(t, e, r);
690
- if (Z(n))
691
- return n;
692
- if (!p(n.id_token))
693
- throw new a('"response" body "id_token" property must be a non-empty string');
694
- s ?? (s = e.default_max_age ?? G);
695
- const i = bt(n);
696
- if ((e.require_auth_time || s !== G) && i.auth_time === void 0)
697
- throw new a('ID Token "auth_time" (authentication time) claim missing');
698
- if (s !== G) {
699
- if (typeof s != "number" || s < 0)
656
+ const Rt = Symbol(), F = Symbol();
657
+ async function Pt(t, e, n, o, a) {
658
+ const r = await Te(t, e, n);
659
+ if (G(r))
660
+ return r;
661
+ if (!g(r.id_token))
662
+ throw new s('"response" body "id_token" property must be a non-empty string');
663
+ a ?? (a = e.default_max_age ?? F);
664
+ const i = bt(r);
665
+ if ((e.require_auth_time || a !== F) && i.auth_time === void 0)
666
+ throw new s('ID Token "auth_time" (authentication time) claim missing');
667
+ if (a !== F) {
668
+ if (typeof a != "number" || a < 0)
700
669
  throw new TypeError('"maxAge" must be a non-negative number');
701
- const u = M() + I(e), f = ye(e);
702
- if (i.auth_time + s < u - f)
703
- throw new a("too much time has elapsed since the last End-User authentication");
670
+ const c = ee() + H(e), p = ye(e);
671
+ if (i.auth_time + a < c - p)
672
+ throw new s("too much time has elapsed since the last End-User authentication");
704
673
  }
705
674
  switch (o) {
706
675
  case void 0:
707
676
  case Rt:
708
677
  if (i.nonce !== void 0)
709
- throw new a('unexpected ID Token "nonce" claim value');
678
+ throw new s('unexpected ID Token "nonce" claim value');
710
679
  break;
711
680
  default:
712
- if (!p(o))
681
+ if (!g(o))
713
682
  throw new TypeError('"expectedNonce" must be a non-empty string');
714
683
  if (i.nonce === void 0)
715
- throw new a('ID Token "nonce" claim missing');
684
+ throw new s('ID Token "nonce" claim missing');
716
685
  if (i.nonce !== o)
717
- throw new a('unexpected ID Token "nonce" claim value');
686
+ throw new s('unexpected ID Token "nonce" claim value');
718
687
  }
719
- return n;
688
+ return r;
720
689
  }
721
- function re(t) {
690
+ function te(t) {
722
691
  if (t.bodyUsed)
723
692
  throw new TypeError('"response" body has been used already');
724
693
  }
725
- async function xt(t) {
694
+ async function Ut(t) {
726
695
  if (t.status > 399 && t.status < 500) {
727
- re(t);
696
+ te(t);
728
697
  try {
729
698
  const e = await t.json();
730
699
  if (C(e) && typeof e.error == "string" && e.error.length)
@@ -733,11 +702,11 @@ async function xt(t) {
733
702
  }
734
703
  }
735
704
  }
736
- function le(t) {
705
+ function fe(t) {
737
706
  if (typeof t.modulusLength != "number" || t.modulusLength < 2048)
738
- throw new a(`${t.name} modulusLength must be at least 2048 bits`);
707
+ throw new s(`${t.name} modulusLength must be at least 2048 bits`);
739
708
  }
740
- function Ut(t) {
709
+ function Lt(t) {
741
710
  switch (t) {
742
711
  case "P-256":
743
712
  return "SHA-256";
@@ -746,18 +715,18 @@ function Ut(t) {
746
715
  case "P-521":
747
716
  return "SHA-512";
748
717
  default:
749
- throw new S();
718
+ throw new T();
750
719
  }
751
720
  }
752
- function Ee(t) {
721
+ function ke(t) {
753
722
  switch (t.algorithm.name) {
754
723
  case "ECDSA":
755
724
  return {
756
725
  name: t.algorithm.name,
757
- hash: Ut(t.algorithm.namedCurve)
726
+ hash: Lt(t.algorithm.namedCurve)
758
727
  };
759
728
  case "RSA-PSS":
760
- switch (le(t.algorithm), t.algorithm.hash.name) {
729
+ switch (fe(t.algorithm), t.algorithm.hash.name) {
761
730
  case "SHA-256":
762
731
  case "SHA-384":
763
732
  case "SHA-512":
@@ -766,271 +735,281 @@ function Ee(t) {
766
735
  saltLength: parseInt(t.algorithm.hash.name.slice(-3), 10) >> 3
767
736
  };
768
737
  default:
769
- throw new S();
738
+ throw new T();
770
739
  }
771
740
  case "RSASSA-PKCS1-v1_5":
772
- return le(t.algorithm), t.algorithm.name;
741
+ return fe(t.algorithm), t.algorithm.name;
773
742
  case "Ed448":
774
743
  case "Ed25519":
775
744
  return t.algorithm.name;
776
745
  }
777
- throw new S();
778
- }
779
- const Ae = Symbol();
780
- async function Lt(t, e, r, o, s) {
781
- const { 0: n, 1: i, 2: u, length: f } = t.split(".");
782
- if (f === 5)
783
- throw new S("JWE structure JWTs are not supported");
784
- if (f !== 3)
785
- throw new a("Invalid JWT");
786
- let m;
746
+ throw new T();
747
+ }
748
+ const Ee = Symbol();
749
+ async function xt(t, e, n, o) {
750
+ const a = `${t}.${e}`;
751
+ if (!await crypto.subtle.verify(ke(n), n, o, E(a)))
752
+ throw new s("JWT signature verification failed");
753
+ }
754
+ async function Ct(t, e, n, o, a, r) {
755
+ let { 0: i, 1: c, 2: p, length: w } = t.split(".");
756
+ if (w === 5)
757
+ if (r !== void 0)
758
+ t = await r(t), { 0: i, 1: c, 2: p, length: w } = t.split(".");
759
+ else
760
+ throw new T("JWE structure JWTs are not supported");
761
+ if (w !== 3)
762
+ throw new s("Invalid JWT");
763
+ let f;
787
764
  try {
788
- m = JSON.parse(A(k(n)));
789
- } catch (P) {
790
- throw new a("failed to parse JWT Header body as base64url encoded JSON", { cause: P });
791
- }
792
- if (!C(m))
793
- throw new a("JWT Header must be a top level object");
794
- if (e(m), m.crit !== void 0)
795
- throw new a('unexpected JWT "crit" header parameter');
796
- const y = k(u);
797
- let b;
798
- if (r !== Ae) {
799
- b = await r(m);
800
- const P = `${n}.${i}`;
801
- if (!await crypto.subtle.verify(Ee(b), b, y, A(P)))
802
- throw new a("JWT signature verification failed");
765
+ f = JSON.parse(E(k(i)));
766
+ } catch (l) {
767
+ throw new s("failed to parse JWT Header body as base64url encoded JSON", { cause: l });
803
768
  }
769
+ if (!C(f))
770
+ throw new s("JWT Header must be a top level object");
771
+ if (e(f), f.crit !== void 0)
772
+ throw new s('unexpected JWT "crit" header parameter');
773
+ const v = k(p);
774
+ let _;
775
+ n !== Ee && (_ = await n(f), await xt(i, c, _, v));
804
776
  let h;
805
777
  try {
806
- h = JSON.parse(A(k(i)));
807
- } catch (P) {
808
- throw new a("failed to parse JWT Payload body as base64url encoded JSON", { cause: P });
778
+ h = JSON.parse(E(k(c)));
779
+ } catch (l) {
780
+ throw new s("failed to parse JWT Payload body as base64url encoded JSON", { cause: l });
809
781
  }
810
782
  if (!C(h))
811
- throw new a("JWT Payload must be a top level object");
812
- const R = M() + o;
783
+ throw new s("JWT Payload must be a top level object");
784
+ const P = ee() + o;
813
785
  if (h.exp !== void 0) {
814
786
  if (typeof h.exp != "number")
815
- throw new a('unexpected JWT "exp" (expiration time) claim type');
816
- if (h.exp <= R - s)
817
- throw new a('unexpected JWT "exp" (expiration time) claim value, timestamp is <= now()');
787
+ throw new s('unexpected JWT "exp" (expiration time) claim type');
788
+ if (h.exp <= P - a)
789
+ throw new s('unexpected JWT "exp" (expiration time) claim value, timestamp is <= now()');
818
790
  }
819
791
  if (h.iat !== void 0 && typeof h.iat != "number")
820
- throw new a('unexpected JWT "iat" (issued at) claim type');
792
+ throw new s('unexpected JWT "iat" (issued at) claim type');
821
793
  if (h.iss !== void 0 && typeof h.iss != "string")
822
- throw new a('unexpected JWT "iss" (issuer) claim type');
794
+ throw new s('unexpected JWT "iss" (issuer) claim type');
823
795
  if (h.nbf !== void 0) {
824
796
  if (typeof h.nbf != "number")
825
- throw new a('unexpected JWT "nbf" (not before) claim type');
826
- if (h.nbf > R + s)
827
- throw new a('unexpected JWT "nbf" (not before) claim value, timestamp is > now()');
797
+ throw new s('unexpected JWT "nbf" (not before) claim type');
798
+ if (h.nbf > P + a)
799
+ throw new s('unexpected JWT "nbf" (not before) claim value, timestamp is > now()');
828
800
  }
829
801
  if (h.aud !== void 0 && typeof h.aud != "string" && !Array.isArray(h.aud))
830
- throw new a('unexpected JWT "aud" (audience) claim type');
831
- return { header: m, claims: h, signature: y, key: b };
802
+ throw new s('unexpected JWT "aud" (audience) claim type');
803
+ return { header: f, claims: h, signature: v, key: _, jwt: t };
832
804
  }
833
- function Ct(t, e, r) {
805
+ function It(t, e, n) {
834
806
  if (t !== void 0) {
835
- if (r.alg !== t)
836
- throw new a('unexpected JWT "alg" header parameter');
807
+ if (n.alg !== t)
808
+ throw new s('unexpected JWT "alg" header parameter');
837
809
  return;
838
810
  }
839
811
  if (Array.isArray(e)) {
840
- if (!e.includes(r.alg))
841
- throw new a('unexpected JWT "alg" header parameter');
812
+ if (!e.includes(n.alg))
813
+ throw new s('unexpected JWT "alg" header parameter');
842
814
  return;
843
815
  }
844
- if (r.alg !== "RS256")
845
- throw new a('unexpected JWT "alg" header parameter');
816
+ if (n.alg !== "RS256")
817
+ throw new s('unexpected JWT "alg" header parameter');
846
818
  }
847
- function T(t, e) {
848
- const { 0: r, length: o } = t.getAll(e);
819
+ function A(t, e) {
820
+ const { 0: n, length: o } = t.getAll(e);
849
821
  if (o > 1)
850
- throw new a(`"${e}" parameter must be provided only once`);
851
- return r;
822
+ throw new s(`"${e}" parameter must be provided only once`);
823
+ return n;
852
824
  }
853
- const It = Symbol(), jt = Symbol();
854
- function Jt(t, e, r, o) {
855
- if (j(t), J(e), r instanceof URL && (r = r.searchParams), !(r instanceof URLSearchParams))
825
+ const jt = Symbol(), Jt = Symbol();
826
+ function Ot(t, e, n, o) {
827
+ if (I(t), j(e), n instanceof URL && (n = n.searchParams), !(n instanceof URLSearchParams))
856
828
  throw new TypeError('"parameters" must be an instance of URLSearchParams, or URL');
857
- if (T(r, "response"))
858
- throw new a('"parameters" contains a JARM response, use validateJwtAuthResponse() instead of validateAuthResponse()');
859
- const s = T(r, "iss"), n = T(r, "state");
860
- if (!s && t.authorization_response_iss_parameter_supported)
861
- throw new a('response parameter "iss" (issuer) missing');
862
- if (s && s !== t.issuer)
863
- throw new a('unexpected "iss" (issuer) response parameter value');
829
+ if (A(n, "response"))
830
+ throw new s('"parameters" contains a JARM response, use validateJwtAuthResponse() instead of validateAuthResponse()');
831
+ const a = A(n, "iss"), r = A(n, "state");
832
+ if (!a && t.authorization_response_iss_parameter_supported)
833
+ throw new s('response parameter "iss" (issuer) missing');
834
+ if (a && a !== t.issuer)
835
+ throw new s('unexpected "iss" (issuer) response parameter value');
864
836
  switch (o) {
865
837
  case void 0:
866
- case jt:
867
- if (n !== void 0)
868
- throw new a('unexpected "state" response parameter encountered');
838
+ case Jt:
839
+ if (r !== void 0)
840
+ throw new s('unexpected "state" response parameter encountered');
869
841
  break;
870
- case It:
842
+ case jt:
871
843
  break;
872
844
  default:
873
- if (!p(o))
874
- throw new a('"expectedState" must be a non-empty string');
875
- if (n === void 0)
876
- throw new a('response parameter "state" missing');
877
- if (n !== o)
878
- throw new a('unexpected "state" response parameter value');
845
+ if (!g(o))
846
+ throw new s('"expectedState" must be a non-empty string');
847
+ if (r === void 0)
848
+ throw new s('response parameter "state" missing');
849
+ if (r !== o)
850
+ throw new s('unexpected "state" response parameter value');
879
851
  }
880
- const i = T(r, "error");
852
+ const i = A(n, "error");
881
853
  if (i)
882
854
  return {
883
855
  error: i,
884
- error_description: T(r, "error_description"),
885
- error_uri: T(r, "error_uri")
856
+ error_description: A(n, "error_description"),
857
+ error_uri: A(n, "error_uri")
886
858
  };
887
- const u = T(r, "id_token"), f = T(r, "token");
888
- if (u !== void 0 || f !== void 0)
889
- throw new S("implicit and hybrid flows are not supported");
890
- return Tt(new URLSearchParams(r));
859
+ const c = A(n, "id_token"), p = A(n, "token");
860
+ if (c !== void 0 || p !== void 0)
861
+ throw new T("implicit and hybrid flows are not supported");
862
+ return Tt(new URLSearchParams(n));
891
863
  }
892
- function Ot({
864
+ function zt({
893
865
  handleCallback: t
894
866
  }) {
895
- const [e, r] = Je(null), o = He(), s = Oe(!1);
896
- return Ne(() => {
897
- s.current || (s.current = !0, t().then((n) => {
898
- o(n);
899
- }).catch((n) => {
900
- K.error(n), r(n);
901
- }));
902
- }, [o, t]), e ? /* @__PURE__ */ E.jsx(
903
- De,
904
- {
905
- category: "Error",
906
- title: "Authentication Error",
907
- message: /* @__PURE__ */ E.jsxs(E.Fragment, { children: [
908
- /* @__PURE__ */ E.jsx(ze, { className: "mb-4", children: "Check the configuration of your authorization provider and ensure all settings such as the callback URL are configured correctly." }),
909
- "An error occurred while authorizing the user.",
910
- /* @__PURE__ */ E.jsx(We, { code: e.toString(), language: "plain" })
911
- ] })
867
+ const e = je({
868
+ retry: !1,
869
+ queryKey: ["oauth-callback"],
870
+ queryFn: async () => {
871
+ try {
872
+ return await t();
873
+ } catch (n) {
874
+ throw new ze("Could not validate user", {
875
+ cause: n,
876
+ title: "Authentication Error",
877
+ developerHint: "Check the configuration of your authorization provider and ensure all settings such as the callback URL are configured correctly."
878
+ });
879
+ }
912
880
  }
913
- ) : /* @__PURE__ */ E.jsx("div", { className: "grid h-full place-items-center", children: /* @__PURE__ */ E.jsx(Ke, {}) });
881
+ });
882
+ return /* @__PURE__ */ B.jsx(Oe, { to: e.data });
914
883
  }
915
- class U extends Error {
884
+ class R extends Error {
916
885
  }
917
- class de extends U {
918
- constructor(e, r, o) {
919
- super(e, o), this.error = r;
886
+ class pe extends R {
887
+ constructor(e, n, o) {
888
+ super(e, o), this.error = n;
920
889
  }
921
890
  }
922
- const V = "code-verifier";
923
- class Nt extends je {
924
- constructor(e, r) {
925
- super(), this.callbackUrlPath = e, this.handleCallback = r;
891
+ const M = "code-verifier", q = "oauth-state";
892
+ class Dt extends Je {
893
+ constructor(e, n) {
894
+ super(), this.callbackUrlPath = e, this.handleCallback = n;
926
895
  }
927
896
  getRoutes() {
928
897
  return [
929
898
  ...super.getRoutes(),
930
899
  {
931
900
  path: this.callbackUrlPath,
932
- element: /* @__PURE__ */ E.jsx(Ot, { handleCallback: this.handleCallback })
901
+ element: /* @__PURE__ */ B.jsx(Ie, { children: /* @__PURE__ */ B.jsx(zt, { handleCallback: this.handleCallback }) })
933
902
  }
934
903
  ];
935
904
  }
936
905
  }
937
- class zt {
906
+ class Nt {
938
907
  constructor({
939
908
  issuer: e,
940
- audience: r,
909
+ audience: n,
941
910
  clientId: o,
942
- redirectToAfterSignUp: s,
943
- redirectToAfterSignIn: n,
944
- redirectToAfterSignOut: i
911
+ redirectToAfterSignUp: a,
912
+ redirectToAfterSignIn: r,
913
+ redirectToAfterSignOut: i,
914
+ basePath: c,
915
+ scopes: p
945
916
  }) {
946
- _(this, "client");
947
- _(this, "issuer");
948
- _(this, "authorizationServer");
949
- _(this, "callbackUrlPath", "/oauth/callback");
950
- _(this, "logoutRedirectUrlPath", "/");
951
- _(this, "onAuthorizationUrl");
952
- _(this, "redirectToAfterSignUp");
953
- _(this, "redirectToAfterSignIn");
954
- _(this, "redirectToAfterSignOut");
955
- _(this, "audience");
956
- _(this, "signOut", async () => {
957
- z.setState({
917
+ b(this, "client");
918
+ b(this, "issuer");
919
+ b(this, "authorizationServer");
920
+ b(this, "callbackUrlPath");
921
+ b(this, "logoutRedirectUrlPath");
922
+ b(this, "onAuthorizationUrl");
923
+ b(this, "redirectToAfterSignUp");
924
+ b(this, "redirectToAfterSignIn");
925
+ b(this, "redirectToAfterSignOut");
926
+ b(this, "audience");
927
+ b(this, "scopes");
928
+ b(this, "signRequest", async (e) => {
929
+ const n = await this.getAccessToken();
930
+ return e.headers.set("Authorization", `Bearer ${n}`), e;
931
+ });
932
+ b(this, "signOut", async () => {
933
+ x.setState({
958
934
  isAuthenticated: !1,
959
935
  isPending: !1,
960
- profile: void 0
961
- }), sessionStorage.clear();
962
- const e = await this.getAuthServer(), r = new URL(
936
+ profile: void 0,
937
+ providerData: void 0
938
+ });
939
+ const e = await this.getAuthServer(), n = new URL(
963
940
  window.location.origin + this.redirectToAfterSignOut
964
941
  );
965
- r.pathname = this.logoutRedirectUrlPath;
942
+ n.pathname = this.logoutRedirectUrlPath;
966
943
  let o;
967
944
  e.end_session_endpoint ? (o = new URL(e.end_session_endpoint), o.searchParams.set(
968
945
  "post_logout_redirect_uri",
969
- r.toString()
970
- )) : o = r;
946
+ n.toString()
947
+ )) : o = n;
971
948
  });
972
- _(this, "handleCallback", async () => {
973
- const e = new URL(window.location.href), r = e.searchParams.get("state"), o = sessionStorage.getItem(V);
974
- if (sessionStorage.removeItem(V), !o)
975
- throw new U("No code verifier found in state.");
976
- const s = await this.getAuthServer(), n = Jt(
977
- s,
949
+ b(this, "handleCallback", async () => {
950
+ const e = new URL(window.location.href), n = e.searchParams.get("state"), o = sessionStorage.getItem(q);
951
+ if (sessionStorage.removeItem(q), n !== o)
952
+ throw new R("Invalid state parameter");
953
+ const a = sessionStorage.getItem(M);
954
+ if (sessionStorage.removeItem(M), !a)
955
+ throw new R("No code verifier found in state.");
956
+ const r = await this.getAuthServer(), i = Ot(
957
+ r,
978
958
  this.client,
979
959
  e.searchParams,
980
- r ?? void 0
960
+ n ?? void 0
981
961
  );
982
- if (Z(n))
983
- throw K.error("Error validating OAuth response", n), new de(
962
+ if (G(i))
963
+ throw se.error("Error validating OAuth response", i), new pe(
984
964
  "Error validating OAuth response",
985
- n
965
+ i
986
966
  );
987
- const i = new URL(e);
988
- i.pathname = this.redirectToAfterSignIn, i.search = "";
989
- const u = await kt(
990
- s,
967
+ const c = new URL(e);
968
+ c.pathname = this.callbackUrlPath, c.search = "";
969
+ const p = await At(
970
+ r,
991
971
  this.client,
992
- n,
993
- i.toString(),
994
- o
995
- ), f = await Pt(
996
- s,
972
+ i,
973
+ c.toString(),
974
+ a
975
+ ), w = await Pt(
976
+ r,
997
977
  this.client,
998
- u
978
+ p
999
979
  );
1000
- this.setTokensFromResponse(f);
1001
- const m = await this.getAccessToken(), b = await (await gt(
1002
- s,
980
+ this.setTokensFromResponse(w);
981
+ const f = await this.getAccessToken(), _ = await (await gt(
982
+ r,
1003
983
  this.client,
1004
- m
984
+ f
1005
985
  )).json(), h = {
1006
- sub: b.sub,
1007
- email: b.email,
1008
- name: b.name,
1009
- emailVerified: b.email_verified ?? !1,
1010
- pictureUrl: b.picture
986
+ sub: _.sub,
987
+ email: _.email,
988
+ name: _.name,
989
+ emailVerified: _.email_verified ?? !1,
990
+ pictureUrl: _.picture
1011
991
  };
1012
- z.setState({
992
+ x.setState({
1013
993
  isAuthenticated: !0,
1014
994
  isPending: !1,
1015
995
  profile: h
1016
- }), sessionStorage.setItem(
1017
- "profile-state",
1018
- JSON.stringify(z.getState().profile)
1019
- );
1020
- const R = sessionStorage.getItem("redirect-to") ?? "/";
1021
- return sessionStorage.removeItem("redirect-to"), R;
996
+ });
997
+ const P = sessionStorage.getItem("redirect-to") ?? "/";
998
+ return sessionStorage.removeItem("redirect-to"), P;
1022
999
  });
1023
1000
  this.client = {
1024
1001
  client_id: o,
1025
1002
  token_endpoint_auth_method: "none"
1026
- }, this.audience = r, this.issuer = e, this.redirectToAfterSignUp = s ?? "/", this.redirectToAfterSignIn = n ?? "/", this.redirectToAfterSignOut = i ?? "/";
1003
+ }, this.audience = n, this.issuer = e, this.callbackUrlPath = ie(c, "/oauth/callback"), this.scopes = p ?? ["openid", "profile", "email"];
1004
+ const w = ie(c, "/");
1005
+ this.logoutRedirectUrlPath = w, this.redirectToAfterSignUp = a ?? w, this.redirectToAfterSignIn = r ?? w, this.redirectToAfterSignOut = i ?? w;
1027
1006
  }
1028
1007
  async getAuthServer() {
1029
1008
  if (!this.authorizationServer) {
1030
- const e = new URL(this.issuer), r = await Qe(e);
1031
- this.authorizationServer = await Xe(
1009
+ const e = new URL(this.issuer), n = await et(e);
1010
+ this.authorizationServer = await tt(
1032
1011
  e,
1033
- r
1012
+ n
1034
1013
  );
1035
1014
  }
1036
1015
  return this.authorizationServer;
@@ -1040,17 +1019,20 @@ class zt {
1040
1019
  * @param response
1041
1020
  */
1042
1021
  setTokensFromResponse(e) {
1043
- if (Z(e))
1044
- throw K.error("Bad Token Response", e), new de("Bad Token Response", e);
1022
+ if (G(e))
1023
+ throw se.error("Bad Token Response", e), new pe("Bad Token Response", e);
1045
1024
  if (!e.expires_in)
1046
- throw new U("No expires_in in response");
1047
- const r = {
1025
+ throw new R("No expires_in in response");
1026
+ const n = {
1048
1027
  accessToken: e.access_token,
1049
1028
  refreshToken: e.refresh_token,
1029
+ idToken: e.id_token,
1050
1030
  expiresOn: new Date(Date.now() + e.expires_in * 1e3),
1051
1031
  tokenType: e.token_type
1052
1032
  };
1053
- sessionStorage.setItem("token-state", JSON.stringify(r));
1033
+ x.setState({
1034
+ providerData: n
1035
+ });
1054
1036
  }
1055
1037
  async signUp({ redirectTo: e } = {}) {
1056
1038
  return this.authorize({
@@ -1065,75 +1047,64 @@ class zt {
1065
1047
  }
1066
1048
  async authorize({
1067
1049
  redirectTo: e,
1068
- isSignUp: r = !1
1050
+ isSignUp: n = !1
1069
1051
  }) {
1070
- var m, y;
1071
- const o = "S256", s = await this.getAuthServer();
1072
- if (!s.authorization_endpoint)
1073
- throw new U("No authorization endpoint");
1074
- const n = et(), i = await rt(n);
1075
- sessionStorage.setItem(V, n);
1076
- const u = new URL(
1077
- s.authorization_endpoint
1078
- );
1079
- sessionStorage.setItem("redirect-to", e);
1080
- const f = new URL(window.location.origin);
1081
- if (f.pathname = this.callbackUrlPath, f.search = "", u.searchParams.set("client_id", this.client.client_id), u.searchParams.set("redirect_uri", f.toString()), u.searchParams.set("response_type", "code"), u.searchParams.set("scope", "openid profile email"), u.searchParams.set("code_challenge", i), u.searchParams.set(
1052
+ var v;
1053
+ const o = "S256", a = await this.getAuthServer();
1054
+ if (!a.authorization_endpoint)
1055
+ throw new R("No authorization endpoint");
1056
+ const r = nt(), i = await ot(r);
1057
+ sessionStorage.setItem(M, r);
1058
+ const c = new URL(
1059
+ a.authorization_endpoint
1060
+ ), p = e.startsWith(window.location.origin) ? e.slice(window.location.origin.length) : e;
1061
+ sessionStorage.setItem("redirect-to", p);
1062
+ const w = new URL(window.location.origin);
1063
+ w.pathname = this.callbackUrlPath, w.search = "", c.searchParams.set("client_id", this.client.client_id), c.searchParams.set("redirect_uri", w.toString()), c.searchParams.set("response_type", "code"), c.searchParams.set("scope", this.scopes.join(" ")), c.searchParams.set("code_challenge", i), c.searchParams.set(
1082
1064
  "code_challenge_method",
1083
1065
  o
1084
- ), this.audience && u.searchParams.set("audience", this.audience), (m = this.onAuthorizationUrl) == null || m.call(this, u, {
1085
- isSignIn: !r,
1086
- isSignUp: r
1087
- }), ((y = s.code_challenge_methods_supported) == null ? void 0 : y.includes("S256")) !== !0) {
1088
- const b = tt();
1089
- u.searchParams.set("state", b);
1090
- }
1091
- location.href = u.href;
1066
+ ), this.audience && c.searchParams.set("audience", this.audience), (v = this.onAuthorizationUrl) == null || v.call(this, c, {
1067
+ isSignIn: !n,
1068
+ isSignUp: n
1069
+ });
1070
+ const f = rt();
1071
+ sessionStorage.setItem(q, f), c.searchParams.set("state", f), location.href = c.href;
1092
1072
  }
1093
1073
  async getAccessToken() {
1094
- const e = await this.getAuthServer(), r = sessionStorage.getItem("token-state");
1095
- if (!r)
1096
- throw new U("User is not authenticated");
1097
- const o = JSON.parse(r);
1098
- if (o.expiresOn < /* @__PURE__ */ new Date()) {
1074
+ const e = await this.getAuthServer(), { providerData: n } = x.getState();
1075
+ if (!n)
1076
+ throw new R("User is not authenticated");
1077
+ const o = n;
1078
+ if (new Date(o.expiresOn) < /* @__PURE__ */ new Date()) {
1099
1079
  if (!o.refreshToken)
1100
- return await this.signIn(), "";
1101
- const s = await yt(
1080
+ return x.setState({
1081
+ isAuthenticated: !1,
1082
+ isPending: !1,
1083
+ profile: null,
1084
+ providerData: null
1085
+ }), "";
1086
+ const a = await yt(
1102
1087
  e,
1103
1088
  this.client,
1104
1089
  o.refreshToken
1105
- ), n = await _t(
1090
+ ), r = await _t(
1106
1091
  e,
1107
1092
  this.client,
1108
- s
1093
+ a
1109
1094
  );
1110
- if (!n.access_token)
1111
- throw new U("No access token in response");
1112
- return this.setTokensFromResponse(n), n.access_token.toString();
1095
+ if (!r.access_token)
1096
+ throw new R("No access token in response");
1097
+ return this.setTokensFromResponse(r), r.access_token.toString();
1113
1098
  } else
1114
1099
  return o.accessToken;
1115
1100
  }
1116
- pageLoad() {
1117
- const e = sessionStorage.getItem("profile-state");
1118
- if (e)
1119
- try {
1120
- const r = JSON.parse(e);
1121
- z.setState({
1122
- isAuthenticated: !0,
1123
- isPending: !1,
1124
- profile: r
1125
- });
1126
- } catch (r) {
1127
- K.error("Error parsing auth state", r);
1128
- }
1129
- }
1130
1101
  getAuthenticationPlugin() {
1131
- return new Nt(this.callbackUrlPath, this.handleCallback);
1102
+ return new Dt(this.callbackUrlPath, this.handleCallback);
1132
1103
  }
1133
1104
  }
1134
- const Yt = (t) => new zt(t);
1105
+ const Vt = (t) => new Nt(t);
1135
1106
  export {
1136
- zt as OpenIDAuthenticationProvider,
1137
- Yt as default
1107
+ Nt as OpenIDAuthenticationProvider,
1108
+ Vt as default
1138
1109
  };
1139
1110
  //# sourceMappingURL=zudoku.auth-openid.js.map