zudoku 0.0.0-e101786 → 0.0.0-e20b2e4

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 (505) hide show
  1. package/dist/app/entry.server.d.ts +1 -1
  2. package/dist/app/main.d.ts +1 -1
  3. package/dist/app/main.js +18 -8
  4. package/dist/app/main.js.map +1 -1
  5. package/dist/cli/common/output.js.map +1 -1
  6. package/dist/cli/dev/handler.js +7 -2
  7. package/dist/cli/dev/handler.js.map +1 -1
  8. package/dist/config/config.d.ts +1 -0
  9. package/dist/config/loader.js +4 -1
  10. package/dist/config/loader.js.map +1 -1
  11. package/dist/config/validators/common.d.ts +217 -28
  12. package/dist/config/validators/common.js +15 -6
  13. package/dist/config/validators/common.js.map +1 -1
  14. package/dist/config/validators/icon-types.d.ts +1 -1
  15. package/dist/config/validators/validate.d.ts +88 -12
  16. package/dist/lib/authentication/providers/auth0.js +1 -1
  17. package/dist/lib/authentication/providers/auth0.js.map +1 -1
  18. package/dist/lib/authentication/providers/openid.d.ts +1 -1
  19. package/dist/lib/authentication/providers/openid.js +10 -6
  20. package/dist/lib/authentication/providers/openid.js.map +1 -1
  21. package/dist/lib/authentication/state.d.ts +9 -0
  22. package/dist/lib/authentication/state.js +11 -0
  23. package/dist/lib/authentication/state.js.map +1 -1
  24. package/dist/lib/components/AnchorLink.js +5 -2
  25. package/dist/lib/components/AnchorLink.js.map +1 -1
  26. package/dist/lib/components/Autocomplete.d.ts +13 -0
  27. package/dist/lib/components/Autocomplete.js +47 -0
  28. package/dist/lib/components/Autocomplete.js.map +1 -0
  29. package/dist/lib/components/Header.js +4 -4
  30. package/dist/lib/components/Header.js.map +1 -1
  31. package/dist/lib/components/Heading.d.ts +1 -1
  32. package/dist/lib/components/Markdown.d.ts +2 -2
  33. package/dist/lib/components/Markdown.js +3 -1
  34. package/dist/lib/components/Markdown.js.map +1 -1
  35. package/dist/lib/components/PathRenderer.d.ts +11 -0
  36. package/dist/lib/components/PathRenderer.js +28 -0
  37. package/dist/lib/components/PathRenderer.js.map +1 -0
  38. package/dist/lib/components/StatusPage.d.ts +7 -0
  39. package/dist/lib/components/StatusPage.js +71 -0
  40. package/dist/lib/components/StatusPage.js.map +1 -0
  41. package/dist/lib/components/SyntaxHighlight.d.ts +2 -1
  42. package/dist/lib/components/SyntaxHighlight.js +2 -2
  43. package/dist/lib/components/SyntaxHighlight.js.map +1 -1
  44. package/dist/lib/components/ThemeSwitch.js +2 -2
  45. package/dist/lib/components/ThemeSwitch.js.map +1 -1
  46. package/dist/lib/components/cache.d.ts +6 -0
  47. package/dist/lib/components/cache.js +13 -0
  48. package/dist/lib/components/cache.js.map +1 -0
  49. package/dist/lib/components/context/ViewportAnchorContext.js +16 -4
  50. package/dist/lib/components/context/ViewportAnchorContext.js.map +1 -1
  51. package/dist/lib/components/context/ZudokuContext.js +10 -3
  52. package/dist/lib/components/context/ZudokuContext.js.map +1 -1
  53. package/dist/lib/components/index.d.ts +14 -2
  54. package/dist/lib/components/index.js +10 -3
  55. package/dist/lib/components/index.js.map +1 -1
  56. package/dist/lib/components/navigation/Sidebar.js +6 -1
  57. package/dist/lib/components/navigation/Sidebar.js.map +1 -1
  58. package/dist/lib/components/navigation/SidebarCategory.js +17 -15
  59. package/dist/lib/components/navigation/SidebarCategory.js.map +1 -1
  60. package/dist/lib/components/navigation/SidebarItem.js +1 -0
  61. package/dist/lib/components/navigation/SidebarItem.js.map +1 -1
  62. package/dist/lib/core/RouteGuard.d.ts +1 -0
  63. package/dist/lib/core/RouteGuard.js +32 -0
  64. package/dist/lib/core/RouteGuard.js.map +1 -0
  65. package/dist/lib/core/ZudokuContext.d.ts +4 -2
  66. package/dist/lib/core/ZudokuContext.js +9 -7
  67. package/dist/lib/core/ZudokuContext.js.map +1 -1
  68. package/dist/lib/oas/graphql/circular.d.ts +3 -0
  69. package/dist/lib/oas/graphql/circular.js +38 -0
  70. package/dist/lib/oas/graphql/circular.js.map +1 -0
  71. package/dist/lib/oas/graphql/index.d.ts +8 -0
  72. package/dist/lib/oas/graphql/index.js +61 -42
  73. package/dist/lib/oas/graphql/index.js.map +1 -1
  74. package/dist/lib/oas/parser/dereference/index.d.ts +0 -1
  75. package/dist/lib/oas/parser/dereference/index.js +1 -1
  76. package/dist/lib/oas/parser/dereference/index.js.map +1 -1
  77. package/dist/lib/oas/parser/upgrade/index.js +2 -1
  78. package/dist/lib/oas/parser/upgrade/index.js.map +1 -1
  79. package/dist/lib/plugins/markdown/MdxPage.js +8 -2
  80. package/dist/lib/plugins/markdown/MdxPage.js.map +1 -1
  81. package/dist/lib/plugins/markdown/resolver.d.ts +0 -6
  82. package/dist/lib/plugins/markdown/resolver.js +0 -29
  83. package/dist/lib/plugins/markdown/resolver.js.map +1 -1
  84. package/dist/lib/plugins/openapi/ColorizedParam.js +3 -1
  85. package/dist/lib/plugins/openapi/ColorizedParam.js.map +1 -1
  86. package/dist/lib/plugins/openapi/Endpoint.js +6 -7
  87. package/dist/lib/plugins/openapi/Endpoint.js.map +1 -1
  88. package/dist/lib/plugins/openapi/{Route.d.ts → OpenApiRoute.d.ts} +2 -1
  89. package/dist/lib/plugins/openapi/{Route.js → OpenApiRoute.js} +3 -4
  90. package/dist/lib/plugins/openapi/OpenApiRoute.js.map +1 -0
  91. package/dist/lib/plugins/openapi/OperationList.d.ts +4 -1
  92. package/dist/lib/plugins/openapi/OperationList.js +29 -19
  93. package/dist/lib/plugins/openapi/OperationList.js.map +1 -1
  94. package/dist/lib/plugins/openapi/OperationListItem.d.ts +2 -1
  95. package/dist/lib/plugins/openapi/OperationListItem.js +3 -3
  96. package/dist/lib/plugins/openapi/OperationListItem.js.map +1 -1
  97. package/dist/lib/plugins/openapi/ParameterListItem.js +2 -2
  98. package/dist/lib/plugins/openapi/ParameterListItem.js.map +1 -1
  99. package/dist/lib/plugins/openapi/PlaygroundDialogWrapper.d.ts +3 -1
  100. package/dist/lib/plugins/openapi/PlaygroundDialogWrapper.js +8 -3
  101. package/dist/lib/plugins/openapi/PlaygroundDialogWrapper.js.map +1 -1
  102. package/dist/lib/plugins/openapi/RequestBodySidecarBox.d.ts +1 -1
  103. package/dist/lib/plugins/openapi/RequestBodySidecarBox.js +2 -0
  104. package/dist/lib/plugins/openapi/RequestBodySidecarBox.js.map +1 -1
  105. package/dist/lib/plugins/openapi/Sidecar.js +11 -16
  106. package/dist/lib/plugins/openapi/Sidecar.js.map +1 -1
  107. package/dist/lib/plugins/openapi/SidecarBox.js +1 -1
  108. package/dist/lib/plugins/openapi/SidecarBox.js.map +1 -1
  109. package/dist/lib/plugins/openapi/SidecarExamples.js +17 -14
  110. package/dist/lib/plugins/openapi/SidecarExamples.js.map +1 -1
  111. package/dist/lib/plugins/openapi/graphql/gql.d.ts +6 -2
  112. package/dist/lib/plugins/openapi/graphql/gql.js +3 -2
  113. package/dist/lib/plugins/openapi/graphql/gql.js.map +1 -1
  114. package/dist/lib/plugins/openapi/graphql/graphql.d.ts +66 -29
  115. package/dist/lib/plugins/openapi/graphql/graphql.js +33 -15
  116. package/dist/lib/plugins/openapi/graphql/graphql.js.map +1 -1
  117. package/dist/lib/plugins/openapi/index.js +126 -61
  118. package/dist/lib/plugins/openapi/index.js.map +1 -1
  119. package/dist/lib/plugins/openapi/interfaces.d.ts +12 -4
  120. package/dist/lib/plugins/openapi/playground/ExamplesDropdown.d.ts +6 -0
  121. package/dist/lib/plugins/openapi/playground/ExamplesDropdown.js +12 -0
  122. package/dist/lib/plugins/openapi/playground/ExamplesDropdown.js.map +1 -0
  123. package/dist/lib/plugins/openapi/playground/Headers.d.ts +4 -4
  124. package/dist/lib/plugins/openapi/playground/Headers.js +84 -5
  125. package/dist/lib/plugins/openapi/playground/Headers.js.map +1 -1
  126. package/dist/lib/plugins/openapi/playground/ParamsGrid.d.ts +9 -0
  127. package/dist/lib/plugins/openapi/playground/ParamsGrid.js +5 -0
  128. package/dist/lib/plugins/openapi/playground/ParamsGrid.js.map +1 -0
  129. package/dist/lib/plugins/openapi/playground/PathParams.js +3 -11
  130. package/dist/lib/plugins/openapi/playground/PathParams.js.map +1 -1
  131. package/dist/lib/plugins/openapi/playground/Playground.d.ts +22 -1
  132. package/dist/lib/plugins/openapi/playground/Playground.js +61 -56
  133. package/dist/lib/plugins/openapi/playground/Playground.js.map +1 -1
  134. package/dist/lib/plugins/openapi/playground/PlaygroundDialog.js +1 -1
  135. package/dist/lib/plugins/openapi/playground/PlaygroundDialog.js.map +1 -1
  136. package/dist/lib/plugins/openapi/playground/QueryParams.js +20 -29
  137. package/dist/lib/plugins/openapi/playground/QueryParams.js.map +1 -1
  138. package/dist/lib/plugins/openapi/playground/SubmitButton.d.ts +7 -0
  139. package/dist/lib/plugins/openapi/playground/SubmitButton.js +22 -0
  140. package/dist/lib/plugins/openapi/playground/SubmitButton.js.map +1 -0
  141. package/dist/lib/plugins/openapi/playground/result-panel/RequestTab.d.ts +7 -0
  142. package/dist/lib/plugins/openapi/playground/result-panel/RequestTab.js +11 -0
  143. package/dist/lib/plugins/openapi/playground/result-panel/RequestTab.js.map +1 -0
  144. package/dist/lib/plugins/openapi/playground/result-panel/ResponseTab.d.ts +8 -0
  145. package/dist/lib/plugins/openapi/playground/result-panel/ResponseTab.js +95 -0
  146. package/dist/lib/plugins/openapi/playground/result-panel/ResponseTab.js.map +1 -0
  147. package/dist/lib/plugins/openapi/playground/result-panel/ResultPanel.d.ts +7 -0
  148. package/dist/lib/plugins/openapi/playground/result-panel/ResultPanel.js +16 -0
  149. package/dist/lib/plugins/openapi/playground/result-panel/ResultPanel.js.map +1 -0
  150. package/dist/lib/plugins/openapi/playground/result-panel/convertToTypes.d.ts +10 -0
  151. package/dist/lib/plugins/openapi/playground/result-panel/convertToTypes.js +32 -0
  152. package/dist/lib/plugins/openapi/playground/result-panel/convertToTypes.js.map +1 -0
  153. package/dist/lib/plugins/openapi/playground/result-panel/convertToTypes.test.d.ts +1 -0
  154. package/dist/lib/plugins/openapi/playground/result-panel/convertToTypes.test.js +56 -0
  155. package/dist/lib/plugins/openapi/playground/result-panel/convertToTypes.test.js.map +1 -0
  156. package/dist/lib/plugins/openapi/post-processors/removeExtensions.d.ts +2 -1
  157. package/dist/lib/plugins/openapi/post-processors/removeExtensions.js +5 -3
  158. package/dist/lib/plugins/openapi/post-processors/removeExtensions.js.map +1 -1
  159. package/dist/lib/plugins/openapi/post-processors/removeExtensions.test.js +49 -0
  160. package/dist/lib/plugins/openapi/post-processors/removeExtensions.test.js.map +1 -1
  161. package/dist/lib/plugins/openapi/post-processors/removeParameters.d.ts +10 -0
  162. package/dist/lib/plugins/openapi/post-processors/removeParameters.js +66 -0
  163. package/dist/lib/plugins/openapi/post-processors/removeParameters.js.map +1 -0
  164. package/dist/lib/plugins/openapi/post-processors/removeParameters.test.d.ts +1 -0
  165. package/dist/lib/plugins/openapi/post-processors/removeParameters.test.js +131 -0
  166. package/dist/lib/plugins/openapi/post-processors/removeParameters.test.js.map +1 -0
  167. package/dist/lib/plugins/openapi/schema/{SchemaComponents.js → SchemaPropertyItem.js} +10 -8
  168. package/dist/lib/plugins/openapi/schema/SchemaPropertyItem.js.map +1 -0
  169. package/dist/lib/plugins/openapi/schema/SchemaView.js +1 -1
  170. package/dist/lib/plugins/openapi/schema/SchemaView.js.map +1 -1
  171. package/dist/lib/plugins/openapi/schema/utils.d.ts +1 -0
  172. package/dist/lib/plugins/openapi/schema/utils.js +2 -0
  173. package/dist/lib/plugins/openapi/schema/utils.js.map +1 -1
  174. package/dist/lib/ui/Badge.d.ts +1 -1
  175. package/dist/lib/ui/Badge.js +1 -0
  176. package/dist/lib/ui/Badge.js.map +1 -1
  177. package/dist/lib/ui/Command.d.ts +9 -1
  178. package/dist/lib/ui/Command.js +5 -1
  179. package/dist/lib/ui/Command.js.map +1 -1
  180. package/dist/lib/ui/Input.d.ts +1 -2
  181. package/dist/lib/ui/Input.js.map +1 -1
  182. package/dist/lib/ui/Select.js +2 -2
  183. package/dist/lib/ui/Select.js.map +1 -1
  184. package/dist/lib/util/MdxComponents.js +2 -2
  185. package/dist/lib/util/MdxComponents.js.map +1 -1
  186. package/dist/lib/util/joinUrl.d.ts +1 -0
  187. package/dist/lib/util/joinUrl.js +40 -0
  188. package/dist/lib/util/joinUrl.js.map +1 -0
  189. package/dist/lib/util/joinUrl.test.d.ts +1 -0
  190. package/dist/lib/util/joinUrl.test.js +43 -0
  191. package/dist/lib/util/joinUrl.test.js.map +1 -0
  192. package/dist/lib/util/scrollIntoViewIfNeeded.d.ts +1 -0
  193. package/dist/lib/util/scrollIntoViewIfNeeded.js +14 -0
  194. package/dist/lib/util/scrollIntoViewIfNeeded.js.map +1 -0
  195. package/dist/lib/util/useLatest.d.ts +1 -0
  196. package/dist/lib/util/useLatest.js +15 -0
  197. package/dist/lib/util/useLatest.js.map +1 -0
  198. package/dist/lib/util/useScrollToAnchor.d.ts +1 -0
  199. package/dist/lib/util/useScrollToAnchor.js +27 -28
  200. package/dist/lib/util/useScrollToAnchor.js.map +1 -1
  201. package/dist/lib/util/useScrollToTop.js +6 -4
  202. package/dist/lib/util/useScrollToTop.js.map +1 -1
  203. package/dist/vite/build.js +15 -12
  204. package/dist/vite/build.js.map +1 -1
  205. package/dist/vite/config.js +4 -1
  206. package/dist/vite/config.js.map +1 -1
  207. package/dist/vite/config.test.js +5 -1
  208. package/dist/vite/config.test.js.map +1 -1
  209. package/dist/vite/dev-server.js +4 -1
  210. package/dist/vite/dev-server.js.map +1 -1
  211. package/dist/vite/plugin-api.d.ts +1 -1
  212. package/dist/vite/plugin-api.js +153 -98
  213. package/dist/vite/plugin-api.js.map +1 -1
  214. package/dist/vite/plugin-auth.js +4 -1
  215. package/dist/vite/plugin-auth.js.map +1 -1
  216. package/dist/vite/plugin-config.js +2 -1
  217. package/dist/vite/plugin-config.js.map +1 -1
  218. package/dist/vite/plugin-mdx.js +20 -9
  219. package/dist/vite/plugin-mdx.js.map +1 -1
  220. package/dist/vite/plugin-theme-css.js +7 -4
  221. package/dist/vite/plugin-theme-css.js.map +1 -1
  222. package/dist/vite/plugin.js.map +1 -1
  223. package/dist/vite/{prerender.d.ts → prerender/FileWritingResponse.d.ts} +0 -6
  224. package/dist/vite/prerender/FileWritingResponse.js +42 -0
  225. package/dist/vite/prerender/FileWritingResponse.js.map +1 -0
  226. package/dist/vite/prerender/prerender.d.ts +6 -0
  227. package/dist/vite/prerender/prerender.js +101 -0
  228. package/dist/vite/prerender/prerender.js.map +1 -0
  229. package/dist/vite/prerender/worker.d.ts +11 -0
  230. package/dist/vite/prerender/worker.js +21 -0
  231. package/dist/vite/prerender/worker.js.map +1 -0
  232. package/dist/vite/reporter.d.ts +3 -0
  233. package/dist/vite/reporter.js +33 -0
  234. package/dist/vite/reporter.js.map +1 -0
  235. package/dist/zuplo/enrich-with-zuplo.d.ts +5 -0
  236. package/dist/zuplo/enrich-with-zuplo.js +184 -0
  237. package/dist/zuplo/enrich-with-zuplo.js.map +1 -0
  238. package/dist/zuplo/env.d.ts +1 -0
  239. package/dist/zuplo/env.js +3 -0
  240. package/dist/zuplo/env.js.map +1 -1
  241. package/dist/zuplo/policy-types.d.ts +33 -0
  242. package/dist/zuplo/policy-types.js +8 -0
  243. package/dist/zuplo/policy-types.js.map +1 -0
  244. package/dist/zuplo/with-zuplo-processors.d.ts +3 -0
  245. package/dist/zuplo/with-zuplo-processors.js +26 -0
  246. package/dist/zuplo/with-zuplo-processors.js.map +1 -0
  247. package/dist/zuplo/with-zuplo.d.ts +1 -1
  248. package/dist/zuplo/with-zuplo.js +7 -26
  249. package/dist/zuplo/with-zuplo.js.map +1 -1
  250. package/lib/{AuthenticationPlugin-D7G3me8L.js → AuthenticationPlugin-DjnQ5hs7.js} +4 -4
  251. package/lib/{AuthenticationPlugin-D7G3me8L.js.map → AuthenticationPlugin-DjnQ5hs7.js.map} +1 -1
  252. package/lib/{CategoryHeading-CBconmtI.js → CategoryHeading-MYL1u_6K.js} +3 -3
  253. package/lib/{CategoryHeading-CBconmtI.js.map → CategoryHeading-MYL1u_6K.js.map} +1 -1
  254. package/lib/{Markdown-CZDLNOFc.js → Markdown-8mv9nhGd.js} +3391 -3403
  255. package/lib/Markdown-8mv9nhGd.js.map +1 -0
  256. package/lib/{MdxPage-DKMbBROv.js → MdxPage-ZX2oquWw.js} +61 -56
  257. package/lib/MdxPage-ZX2oquWw.js.map +1 -0
  258. package/lib/OpenApiRoute-BP9kzG5k.js +36 -0
  259. package/lib/OpenApiRoute-BP9kzG5k.js.map +1 -0
  260. package/lib/OperationList-c72qPMtm.js +5180 -0
  261. package/lib/OperationList-c72qPMtm.js.map +1 -0
  262. package/lib/Select-NSz0gku6.js +223 -0
  263. package/lib/Select-NSz0gku6.js.map +1 -0
  264. package/lib/{SlotletProvider-pfc9oejW.js → SlotletProvider-D0mFmGJu.js} +53 -53
  265. package/lib/{SlotletProvider-pfc9oejW.js.map → SlotletProvider-D0mFmGJu.js.map} +1 -1
  266. package/lib/{Button-DeAoTouo.js → Spinner-BlzrEEk1.js} +16 -13
  267. package/lib/Spinner-BlzrEEk1.js.map +1 -0
  268. package/lib/{SyntaxHighlight-Bz-lOJtH.js → SyntaxHighlight-B0L4SC_N.js} +390 -383
  269. package/lib/SyntaxHighlight-B0L4SC_N.js.map +1 -0
  270. package/lib/{chunk-D52XG6IA-Dl7HLe6j.js → chunk-SYFQ2XB5-QijJrSf0.js} +409 -411
  271. package/lib/chunk-SYFQ2XB5-QijJrSf0.js.map +1 -0
  272. package/lib/circular-DxaIIlWD.js +15409 -0
  273. package/lib/circular-DxaIIlWD.js.map +1 -0
  274. package/lib/context-rwLGh-6_.js +22 -0
  275. package/lib/{context-h_UkBLvr.js.map → context-rwLGh-6_.js.map} +1 -1
  276. package/lib/{createServer-BznDkeSA.js → createServer-ZDNGmPfQ.js} +3611 -5736
  277. package/lib/createServer-ZDNGmPfQ.js.map +1 -0
  278. package/lib/hook-Dnj3SwPC.js +1455 -0
  279. package/lib/hook-Dnj3SwPC.js.map +1 -0
  280. package/lib/index-B7mqiOei.js +509 -0
  281. package/lib/index-B7mqiOei.js.map +1 -0
  282. package/lib/index-CZjcfK-H.js +2063 -0
  283. package/lib/index-CZjcfK-H.js.map +1 -0
  284. package/lib/{index-LNp6rxyU.js → index-CjJS0l4l.js} +2 -2
  285. package/lib/{index-LNp6rxyU.js.map → index-CjJS0l4l.js.map} +1 -1
  286. package/lib/index-Djenk2Hj.js +36 -0
  287. package/lib/{index-CPNSgwSb.js.map → index-Djenk2Hj.js.map} +1 -1
  288. package/lib/{index-CBXSgjaE.js → index-Dl3Yl0yb.js} +65 -69
  289. package/lib/index-Dl3Yl0yb.js.map +1 -0
  290. package/lib/{index.esm-BSV1C092.js → index.esm-9-TF9KQB.js} +52 -52
  291. package/lib/{index.esm-BSV1C092.js.map → index.esm-9-TF9KQB.js.map} +1 -1
  292. package/lib/index.esm-CrSoEshU.js +1207 -0
  293. package/lib/index.esm-CrSoEshU.js.map +1 -0
  294. package/lib/joinUrl-nLx9pD-Z.js +20 -0
  295. package/lib/joinUrl-nLx9pD-Z.js.map +1 -0
  296. package/lib/{jsx-runtime-Dx-03ztt.js → jsx-runtime-Bdg6XQ1m.js} +135 -135
  297. package/lib/{jsx-runtime-Dx-03ztt.js.map → jsx-runtime-Bdg6XQ1m.js.map} +1 -1
  298. package/lib/mutation-ByGtmi0-.js +208 -0
  299. package/lib/mutation-ByGtmi0-.js.map +1 -0
  300. package/lib/post-processors/removeExtensions.js +7 -7
  301. package/lib/post-processors/removeExtensions.js.map +1 -1
  302. package/lib/post-processors/removeParameters.js +48 -0
  303. package/lib/post-processors/removeParameters.js.map +1 -0
  304. package/lib/{prism-bash.min-DadFsM4Z.js → prism-bash.min-HHIMdNJ_.js} +4 -4
  305. package/lib/{prism-bash.min-DadFsM4Z.js.map → prism-bash.min-HHIMdNJ_.js.map} +1 -1
  306. package/lib/{prism-csharp.min-DUwvItt4.js → prism-csharp.min-bQAo2pmx.js} +33 -33
  307. package/lib/{prism-csharp.min-DUwvItt4.js.map → prism-csharp.min-bQAo2pmx.js.map} +1 -1
  308. package/lib/{prism-java.min-BtgBR4yd.js → prism-java.min-BpvsOuIa.js} +12 -12
  309. package/lib/{prism-java.min-BtgBR4yd.js.map → prism-java.min-BpvsOuIa.js.map} +1 -1
  310. package/lib/{prism-markdown.min-F3U-vPBi.js → prism-markdown.min-C0Qn0m-5.js} +30 -30
  311. package/lib/{prism-markdown.min-F3U-vPBi.js.map → prism-markdown.min-C0Qn0m-5.js.map} +1 -1
  312. package/lib/{prism-ruby.min-DeDXCp1r.js → prism-ruby.min-Dx9KO9ds.js} +16 -16
  313. package/lib/{prism-ruby.min-DeDXCp1r.js.map → prism-ruby.min-Dx9KO9ds.js.map} +1 -1
  314. package/lib/prism-typescript.min-CD7H2IYQ.js.map +1 -1
  315. package/lib/ui/Accordion.js +1 -1
  316. package/lib/ui/ActionButton.js +10 -11
  317. package/lib/ui/ActionButton.js.map +1 -1
  318. package/lib/ui/Alert.js +2 -2
  319. package/lib/ui/AlertDialog.js +1 -1
  320. package/lib/ui/Badge.js +3 -2
  321. package/lib/ui/Badge.js.map +1 -1
  322. package/lib/ui/Breadcrumb.js +1 -1
  323. package/lib/ui/Button.js +2 -2
  324. package/lib/ui/Callout.js +1 -1
  325. package/lib/ui/Card.js +1 -1
  326. package/lib/ui/Carousel.js +3 -3
  327. package/lib/ui/Carousel.js.map +1 -1
  328. package/lib/ui/Checkbox.js +2 -2
  329. package/lib/ui/Command.js +125 -13
  330. package/lib/ui/Command.js.map +1 -1
  331. package/lib/ui/Dialog.js +1 -1
  332. package/lib/ui/Drawer.js +520 -519
  333. package/lib/ui/Drawer.js.map +1 -1
  334. package/lib/ui/DropdownMenu.js +1 -1
  335. package/lib/ui/Form.js +2 -2
  336. package/lib/ui/HoverCard.js +1 -1
  337. package/lib/ui/Input.js +1 -1
  338. package/lib/ui/Input.js.map +1 -1
  339. package/lib/ui/Label.js +2 -2
  340. package/lib/ui/Pagination.js +7 -7
  341. package/lib/ui/Popover.js +1 -1
  342. package/lib/ui/Progress.js +1 -1
  343. package/lib/ui/RadioGroup.js +1 -1
  344. package/lib/ui/ScrollArea.js +1 -1
  345. package/lib/ui/Select.js +3 -3
  346. package/lib/ui/Select.js.map +1 -1
  347. package/lib/ui/Skeleton.js +1 -1
  348. package/lib/ui/Slider.js +1 -1
  349. package/lib/ui/Switch.js +1 -1
  350. package/lib/ui/Tabs.js +1 -1
  351. package/lib/ui/Textarea.js +1 -1
  352. package/lib/ui/Toggle.js +2 -2
  353. package/lib/ui/ToggleGroup.js +1 -1
  354. package/lib/ui/Tooltip.js +1 -1
  355. package/lib/{useExposedProps-DE9lR6MF.js → useExposedProps-Bbf99zic.js} +2 -2
  356. package/lib/{useExposedProps-DE9lR6MF.js.map → useExposedProps-Bbf99zic.js.map} +1 -1
  357. package/lib/useScrollToAnchor-DkVfWsxe.js +286 -0
  358. package/lib/useScrollToAnchor-DkVfWsxe.js.map +1 -0
  359. package/lib/zudoku.auth-auth0.js +8 -10
  360. package/lib/zudoku.auth-auth0.js.map +1 -1
  361. package/lib/zudoku.auth-clerk.js +18 -18
  362. package/lib/zudoku.auth-openid.js +224 -221
  363. package/lib/zudoku.auth-openid.js.map +1 -1
  364. package/lib/zudoku.components.js +828 -940
  365. package/lib/zudoku.components.js.map +1 -1
  366. package/lib/zudoku.plugin-api-catalog.js +18 -19
  367. package/lib/zudoku.plugin-api-catalog.js.map +1 -1
  368. package/lib/zudoku.plugin-api-keys.js +15 -16
  369. package/lib/zudoku.plugin-api-keys.js.map +1 -1
  370. package/lib/zudoku.plugin-custom-pages.js +3 -3
  371. package/lib/zudoku.plugin-markdown.js +23 -44
  372. package/lib/zudoku.plugin-markdown.js.map +1 -1
  373. package/lib/zudoku.plugin-openapi.js +7 -6
  374. package/lib/zudoku.plugin-openapi.js.map +1 -1
  375. package/lib/zudoku.plugin-redirect.js +1 -1
  376. package/lib/zudoku.plugin-search-inkeep.js +9 -9
  377. package/package.json +53 -49
  378. package/src/app/demo-cdn.html +31 -31
  379. package/src/app/entry.server.tsx +1 -1
  380. package/src/app/main.css +52 -51
  381. package/src/app/main.tsx +31 -8
  382. package/src/lib/authentication/providers/auth0.tsx +1 -4
  383. package/src/lib/authentication/providers/openid.tsx +12 -5
  384. package/src/lib/authentication/state.ts +18 -0
  385. package/src/lib/components/AnchorLink.tsx +5 -2
  386. package/src/lib/components/Autocomplete.tsx +113 -0
  387. package/src/lib/components/Header.tsx +4 -4
  388. package/src/lib/components/Markdown.tsx +14 -15
  389. package/src/lib/components/PathRenderer.tsx +61 -0
  390. package/src/lib/components/StatusPage.tsx +91 -0
  391. package/src/lib/components/SyntaxHighlight.tsx +14 -0
  392. package/src/lib/components/ThemeSwitch.tsx +2 -2
  393. package/src/lib/components/cache.ts +15 -0
  394. package/src/lib/components/context/ViewportAnchorContext.tsx +20 -6
  395. package/src/lib/components/context/ZudokuContext.ts +16 -3
  396. package/src/lib/components/index.ts +14 -3
  397. package/src/lib/components/navigation/Sidebar.tsx +7 -1
  398. package/src/lib/components/navigation/SidebarCategory.tsx +46 -43
  399. package/src/lib/components/navigation/SidebarItem.tsx +1 -0
  400. package/src/lib/core/RouteGuard.tsx +39 -0
  401. package/src/lib/core/ZudokuContext.ts +9 -8
  402. package/src/lib/oas/graphql/circular.ts +50 -0
  403. package/src/lib/oas/graphql/index.ts +95 -69
  404. package/src/lib/oas/parser/dereference/index.ts +1 -2
  405. package/src/lib/oas/parser/upgrade/index.ts +2 -1
  406. package/src/lib/plugins/markdown/MdxPage.tsx +9 -1
  407. package/src/lib/plugins/markdown/resolver.ts +0 -33
  408. package/src/lib/plugins/openapi/ColorizedParam.tsx +3 -3
  409. package/src/lib/plugins/openapi/Endpoint.tsx +11 -9
  410. package/src/lib/plugins/openapi/{Route.tsx → OpenApiRoute.tsx} +3 -3
  411. package/src/lib/plugins/openapi/OperationList.tsx +47 -19
  412. package/src/lib/plugins/openapi/OperationListItem.tsx +7 -4
  413. package/src/lib/plugins/openapi/ParameterListItem.tsx +3 -6
  414. package/src/lib/plugins/openapi/PlaygroundDialogWrapper.tsx +11 -1
  415. package/src/lib/plugins/openapi/RequestBodySidecarBox.tsx +2 -0
  416. package/src/lib/plugins/openapi/Sidecar.tsx +27 -34
  417. package/src/lib/plugins/openapi/SidecarBox.tsx +1 -1
  418. package/src/lib/plugins/openapi/SidecarExamples.tsx +24 -24
  419. package/src/lib/plugins/openapi/graphql/gql.ts +12 -4
  420. package/src/lib/plugins/openapi/graphql/graphql.ts +92 -45
  421. package/src/lib/plugins/openapi/index.tsx +163 -78
  422. package/src/lib/plugins/openapi/interfaces.ts +16 -12
  423. package/src/lib/plugins/openapi/playground/ExamplesDropdown.tsx +54 -0
  424. package/src/lib/plugins/openapi/playground/Headers.tsx +165 -36
  425. package/src/lib/plugins/openapi/playground/ParamsGrid.tsx +13 -0
  426. package/src/lib/plugins/openapi/playground/PathParams.tsx +35 -75
  427. package/src/lib/plugins/openapi/playground/Playground.tsx +251 -213
  428. package/src/lib/plugins/openapi/playground/PlaygroundDialog.tsx +6 -3
  429. package/src/lib/plugins/openapi/playground/QueryParams.tsx +84 -114
  430. package/src/lib/plugins/openapi/playground/SubmitButton.tsx +75 -0
  431. package/src/lib/plugins/openapi/playground/result-panel/RequestTab.tsx +73 -0
  432. package/src/lib/plugins/openapi/playground/result-panel/ResponseTab.tsx +210 -0
  433. package/src/lib/plugins/openapi/playground/result-panel/ResultPanel.tsx +101 -0
  434. package/src/lib/plugins/openapi/playground/result-panel/convertToTypes.test.ts +64 -0
  435. package/src/lib/plugins/openapi/playground/result-panel/convertToTypes.ts +36 -0
  436. package/src/lib/plugins/openapi/post-processors/removeExtensions.test.ts +58 -0
  437. package/src/lib/plugins/openapi/post-processors/removeExtensions.ts +7 -4
  438. package/src/lib/plugins/openapi/post-processors/removeParameters.test.ts +148 -0
  439. package/src/lib/plugins/openapi/post-processors/removeParameters.ts +101 -0
  440. package/src/lib/plugins/openapi/schema/{SchemaComponents.tsx → SchemaPropertyItem.tsx} +11 -7
  441. package/src/lib/plugins/openapi/schema/SchemaView.tsx +4 -1
  442. package/src/lib/plugins/openapi/schema/utils.ts +4 -0
  443. package/src/lib/ui/Badge.tsx +1 -0
  444. package/src/lib/ui/Command.tsx +20 -0
  445. package/src/lib/ui/Input.tsx +1 -2
  446. package/src/lib/ui/Select.tsx +1 -1
  447. package/src/lib/util/MdxComponents.tsx +2 -1
  448. package/src/lib/util/joinUrl.test.ts +62 -0
  449. package/src/lib/util/joinUrl.ts +57 -0
  450. package/src/lib/util/scrollIntoViewIfNeeded.ts +18 -0
  451. package/src/lib/util/useLatest.ts +18 -0
  452. package/src/lib/util/useScrollToAnchor.ts +33 -34
  453. package/src/lib/util/useScrollToTop.ts +8 -3
  454. package/dist/lib/plugins/openapi/Route.js.map +0 -1
  455. package/dist/lib/plugins/openapi/playground/EnumSelector.d.ts +0 -8
  456. package/dist/lib/plugins/openapi/playground/EnumSelector.js +0 -21
  457. package/dist/lib/plugins/openapi/playground/EnumSelector.js.map +0 -1
  458. package/dist/lib/plugins/openapi/playground/ResponseTab.d.ts +0 -4
  459. package/dist/lib/plugins/openapi/playground/ResponseTab.js +0 -42
  460. package/dist/lib/plugins/openapi/playground/ResponseTab.js.map +0 -1
  461. package/dist/lib/plugins/openapi/schema/SchemaComponents.js.map +0 -1
  462. package/dist/vite/prerender.js +0 -89
  463. package/dist/vite/prerender.js.map +0 -1
  464. package/lib/AnchorLink-DFZZbmvr.js +0 -34
  465. package/lib/AnchorLink-DFZZbmvr.js.map +0 -1
  466. package/lib/Button-DeAoTouo.js.map +0 -1
  467. package/lib/Command-9x_kZHr4.js +0 -611
  468. package/lib/Command-9x_kZHr4.js.map +0 -1
  469. package/lib/Markdown-CZDLNOFc.js.map +0 -1
  470. package/lib/MdxPage-DKMbBROv.js.map +0 -1
  471. package/lib/OperationList-DFa3DqhW.js +0 -5143
  472. package/lib/OperationList-DFa3DqhW.js.map +0 -1
  473. package/lib/Route-DYwKZ_c_.js +0 -35
  474. package/lib/Route-DYwKZ_c_.js.map +0 -1
  475. package/lib/Select-B_IxRUUC.js +0 -223
  476. package/lib/Select-B_IxRUUC.js.map +0 -1
  477. package/lib/Spinner-DuxJLLNE.js +0 -7
  478. package/lib/Spinner-DuxJLLNE.js.map +0 -1
  479. package/lib/StaggeredRender-DgsamH_G.js +0 -17
  480. package/lib/StaggeredRender-DgsamH_G.js.map +0 -1
  481. package/lib/SyntaxHighlight-Bz-lOJtH.js.map +0 -1
  482. package/lib/ZudokuContext-hmLMUdf2.js +0 -1217
  483. package/lib/ZudokuContext-hmLMUdf2.js.map +0 -1
  484. package/lib/__vite-browser-external-BYRIRx8p.js +0 -9
  485. package/lib/__vite-browser-external-BYRIRx8p.js.map +0 -1
  486. package/lib/chunk-D52XG6IA-Dl7HLe6j.js.map +0 -1
  487. package/lib/context-h_UkBLvr.js +0 -22
  488. package/lib/createServer-BznDkeSA.js.map +0 -1
  489. package/lib/hook-CHq7pFyz.js +0 -227
  490. package/lib/hook-CHq7pFyz.js.map +0 -1
  491. package/lib/index-Bn6Lc9tq.js +0 -9
  492. package/lib/index-Bn6Lc9tq.js.map +0 -1
  493. package/lib/index-CBXSgjaE.js.map +0 -1
  494. package/lib/index-CPNSgwSb.js +0 -36
  495. package/lib/index-PqKef_jH.js +0 -1292
  496. package/lib/index-PqKef_jH.js.map +0 -1
  497. package/lib/index-TaRXY2w1.js +0 -43
  498. package/lib/index-TaRXY2w1.js.map +0 -1
  499. package/lib/index.esm-BnnBRKJX.js +0 -1214
  500. package/lib/index.esm-BnnBRKJX.js.map +0 -1
  501. package/lib/state-CFQsUZUP.js +0 -202
  502. package/lib/state-CFQsUZUP.js.map +0 -1
  503. package/src/lib/plugins/openapi/playground/EnumSelector.tsx +0 -86
  504. package/src/lib/plugins/openapi/playground/ResponseTab.tsx +0 -76
  505. /package/dist/lib/plugins/openapi/schema/{SchemaComponents.d.ts → SchemaPropertyItem.d.ts} +0 -0
@@ -1,20 +1,20 @@
1
- var je = Object.defineProperty;
2
- var Je = (t, e, n) => e in t ? je(t, e, { enumerable: !0, configurable: !0, writable: !0, value: n }) : t[e] = n;
3
- var b = (t, e, n) => Je(t, typeof e != "symbol" ? e + "" : e, n);
4
- import { j as G } from "./jsx-runtime-Dx-03ztt.js";
5
- import { g as Oe } from "./_commonjsHelpers-BkfeUUK-.js";
6
- import { C as ze } from "./ClientOnly-E7hGysn1.js";
7
- import { A as De } from "./AuthenticationPlugin-D7G3me8L.js";
8
- import { u as Ne } from "./ZudokuContext-hmLMUdf2.js";
9
- import { N as Ke } from "./chunk-D52XG6IA-Dl7HLe6j.js";
10
- import { Z as We } from "./invariant-Caa8-XvF.js";
11
- import { u as x } from "./state-CFQsUZUP.js";
12
- var N = { exports: {} }, He = N.exports, ae;
13
- function $e() {
14
- return ae || (ae = 1, function(t) {
1
+ var Je = Object.defineProperty;
2
+ var Oe = (t, e, n) => e in t ? Je(t, e, { enumerable: !0, configurable: !0, writable: !0, value: n }) : t[e] = n;
3
+ var b = (t, e, n) => Oe(t, typeof e != "symbol" ? e + "" : e, n);
4
+ import { j as G } from "./jsx-runtime-Bdg6XQ1m.js";
5
+ import { g as ze } from "./_commonjsHelpers-BkfeUUK-.js";
6
+ import { C as De } from "./ClientOnly-E7hGysn1.js";
7
+ import { j as ae } from "./joinUrl-nLx9pD-Z.js";
8
+ import { A as Ne } from "./AuthenticationPlugin-DjnQ5hs7.js";
9
+ import { a as Ke, u as x } from "./hook-Dnj3SwPC.js";
10
+ import { N as We } from "./chunk-SYFQ2XB5-QijJrSf0.js";
11
+ import { Z as He } from "./invariant-Caa8-XvF.js";
12
+ var N = { exports: {} }, $e = N.exports, se;
13
+ function Fe() {
14
+ return se || (se = 1, function(t) {
15
15
  (function(e, n) {
16
16
  t.exports ? t.exports = n() : e.log = n();
17
- })(He, function() {
17
+ })($e, function() {
18
18
  var e = function() {
19
19
  }, n = "undefined", o = typeof window !== n && typeof window.navigator !== n && /Trident\/|MSIE /.test(window.navigator.userAgent), a = [
20
20
  "trace",
@@ -35,13 +35,13 @@ function $e() {
35
35
  };
36
36
  }
37
37
  }
38
- function p() {
38
+ function h() {
39
39
  console.log && (console.log.apply ? console.log.apply(console, arguments) : Function.prototype.apply.apply(console.log, [console, arguments])), console.trace && console.trace();
40
40
  }
41
41
  function _(l) {
42
- 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
+ return l === "debug" && (l = "log"), typeof console === n ? !1 : l === "trace" && o ? h : console[l] !== void 0 ? c(console, l) : console.log !== void 0 ? c(console, "log") : e;
43
43
  }
44
- function f() {
44
+ function p() {
45
45
  for (var l = this.getLevel(), m = 0; m < a.length; m++) {
46
46
  var u = a[m];
47
47
  this[u] = m < l ? e : this.methodFactory(u, l, this.name);
@@ -51,16 +51,16 @@ function $e() {
51
51
  }
52
52
  function y(l) {
53
53
  return function() {
54
- typeof console !== n && (f.call(this), this[l].apply(this, arguments));
54
+ typeof console !== n && (p.call(this), this[l].apply(this, arguments));
55
55
  };
56
56
  }
57
57
  function T(l, m, u) {
58
58
  return _(l) || y.apply(this, arguments);
59
59
  }
60
- function h(l, m) {
60
+ function f(l, m) {
61
61
  var u = this, O, M, R, v = "loglevel";
62
62
  typeof l == "string" ? v += ":" + l : typeof l == "symbol" && (v = void 0);
63
- function Ce(d) {
63
+ function Le(d) {
64
64
  var g = (a[d] || "silent").toUpperCase();
65
65
  if (!(typeof window === n || !v)) {
66
66
  try {
@@ -92,7 +92,7 @@ function $e() {
92
92
  return u.levels[d] === void 0 && (d = void 0), d;
93
93
  }
94
94
  }
95
- function Le() {
95
+ function je() {
96
96
  if (!(typeof window === n || !v)) {
97
97
  try {
98
98
  window.localStorage.removeItem(v);
@@ -120,30 +120,30 @@ function $e() {
120
120
  }, u.methodFactory = m || T, u.getLevel = function() {
121
121
  return R ?? M ?? O;
122
122
  }, u.setLevel = function(d, g) {
123
- return R = U(d), g !== !1 && Ce(R), f.call(u);
123
+ return R = U(d), g !== !1 && Le(R), p.call(u);
124
124
  }, u.setDefaultLevel = function(d) {
125
125
  M = U(d), re() || u.setLevel(d, !1);
126
126
  }, u.resetLevel = function() {
127
- R = null, Le(), f.call(u);
127
+ R = null, je(), p.call(u);
128
128
  }, u.enableAll = function(d) {
129
129
  u.setLevel(u.levels.TRACE, d);
130
130
  }, u.disableAll = function(d) {
131
131
  u.setLevel(u.levels.SILENT, d);
132
132
  }, u.rebuild = function() {
133
- if (i !== u && (O = U(i.getLevel())), f.call(u), i === u)
133
+ if (i !== u && (O = U(i.getLevel())), p.call(u), i === u)
134
134
  for (var d in r)
135
135
  r[d].rebuild();
136
136
  }, O = U(
137
137
  i ? i.getLevel() : "WARN"
138
138
  );
139
139
  var oe = re();
140
- oe != null && (R = U(oe)), f.call(u);
140
+ oe != null && (R = U(oe)), p.call(u);
141
141
  }
142
- i = new h(), i.getLogger = function(m) {
142
+ i = new f(), i.getLogger = function(m) {
143
143
  if (typeof m != "symbol" && typeof m != "string" || m === "")
144
144
  throw new TypeError("You must supply a name when creating a logger.");
145
145
  var u = r[m];
146
- return u || (u = r[m] = new h(
146
+ return u || (u = r[m] = new f(
147
147
  m,
148
148
  i.methodFactory
149
149
  )), u;
@@ -157,11 +157,11 @@ function $e() {
157
157
  });
158
158
  }(N)), N.exports;
159
159
  }
160
- var Fe = $e();
161
- const se = /* @__PURE__ */ Oe(Fe);
160
+ var Me = Fe();
161
+ const ce = /* @__PURE__ */ ze(Me);
162
162
  let Z;
163
- var D, we;
164
- (typeof navigator > "u" || !((we = (D = navigator.userAgent) == null ? void 0 : D.startsWith) != null && we.call(D, "Mozilla/5.0 "))) && (Z = "oauth4webapi/v2.17.0");
163
+ var D, me;
164
+ (typeof navigator > "u" || !((me = (D = navigator.userAgent) == null ? void 0 : D.startsWith) != null && me.call(D, "Mozilla/5.0 "))) && (Z = "oauth4webapi/v2.17.0");
165
165
  function Q(t, e) {
166
166
  if (t == null)
167
167
  return !1;
@@ -171,19 +171,19 @@ function Q(t, e) {
171
171
  return !1;
172
172
  }
173
173
  }
174
- const W = Symbol(), Me = Symbol(), X = Symbol(), me = Symbol(), qe = Symbol(), Be = Symbol(), Ve = new TextEncoder(), Ge = new TextDecoder();
174
+ const W = Symbol(), qe = Symbol(), X = Symbol(), ge = Symbol(), Be = Symbol(), Ve = Symbol(), Ge = new TextEncoder(), Ze = new TextDecoder();
175
175
  function E(t) {
176
- return typeof t == "string" ? Ve.encode(t) : Ge.decode(t);
176
+ return typeof t == "string" ? Ge.encode(t) : Ze.decode(t);
177
177
  }
178
- const ce = 32768;
179
- function Ze(t) {
178
+ const ue = 32768;
179
+ function Ye(t) {
180
180
  t instanceof ArrayBuffer && (t = new Uint8Array(t));
181
181
  const e = [];
182
- for (let n = 0; n < t.byteLength; n += ce)
183
- e.push(String.fromCharCode.apply(null, t.subarray(n, n + ce)));
182
+ for (let n = 0; n < t.byteLength; n += ue)
183
+ e.push(String.fromCharCode.apply(null, t.subarray(n, n + ue)));
184
184
  return btoa(e.join("")).replace(/=/g, "").replace(/\+/g, "-").replace(/\//g, "_");
185
185
  }
186
- function Ye(t) {
186
+ function Qe(t) {
187
187
  try {
188
188
  const e = atob(t.replace(/-/g, "+").replace(/_/g, "/").replace(/\s/g, "")), n = new Uint8Array(e.length);
189
189
  for (let o = 0; o < e.length; o++)
@@ -194,9 +194,9 @@ function Ye(t) {
194
194
  }
195
195
  }
196
196
  function A(t) {
197
- return typeof t == "string" ? Ye(t) : Ze(t);
197
+ return typeof t == "string" ? Qe(t) : Ye(t);
198
198
  }
199
- class Qe {
199
+ class Xe {
200
200
  constructor(e) {
201
201
  this.cache = /* @__PURE__ */ new Map(), this._cache = /* @__PURE__ */ new Map(), this.maxSize = e;
202
202
  }
@@ -226,26 +226,26 @@ class S extends Error {
226
226
  super(e ?? "operation not supported"), this.name = this.constructor.name, (n = Error.captureStackTrace) == null || n.call(Error, this, this.constructor);
227
227
  }
228
228
  }
229
- class Xe extends Error {
229
+ class et extends Error {
230
230
  constructor(e, n) {
231
231
  var o;
232
232
  super(e, n), this.name = this.constructor.name, (o = Error.captureStackTrace) == null || o.call(Error, this, this.constructor);
233
233
  }
234
234
  }
235
- const s = Xe, ge = new Qe(100);
236
- function ye(t) {
235
+ const s = et, ye = new Xe(100);
236
+ function be(t) {
237
237
  return t instanceof CryptoKey;
238
238
  }
239
- function be(t) {
240
- return ye(t) && t.type === "private";
239
+ function _e(t) {
240
+ return be(t) && t.type === "private";
241
241
  }
242
- function et(t) {
243
- return ye(t) && t.type === "public";
242
+ function tt(t) {
243
+ return be(t) && t.type === "public";
244
244
  }
245
245
  function ee(t) {
246
246
  try {
247
247
  const e = t.headers.get("dpop-nonce");
248
- e && ge.set(new URL(t.url).origin, e);
248
+ e && ye.set(new URL(t.url).origin, e);
249
249
  } catch {
250
250
  }
251
251
  return t;
@@ -267,7 +267,7 @@ function te(t) {
267
267
  throw new TypeError('"options.signal" must return or be an instance of AbortSignal');
268
268
  return t;
269
269
  }
270
- async function tt(t, e) {
270
+ async function nt(t, e) {
271
271
  if (!(t instanceof URL))
272
272
  throw new TypeError('"issuerIdentifier" must be an instance of URL');
273
273
  if (t.protocol !== "https:" && t.protocol !== "http:")
@@ -295,7 +295,7 @@ async function tt(t, e) {
295
295
  function w(t) {
296
296
  return typeof t == "string" && t.length !== 0;
297
297
  }
298
- async function nt(t, e) {
298
+ async function rt(t, e) {
299
299
  if (!(t instanceof URL))
300
300
  throw new TypeError('"expectedIssuer" must be an instance of URL');
301
301
  if (!Q(e, Response))
@@ -320,18 +320,18 @@ async function nt(t, e) {
320
320
  function $() {
321
321
  return A(crypto.getRandomValues(new Uint8Array(32)));
322
322
  }
323
- function rt() {
323
+ function ot() {
324
324
  return $();
325
325
  }
326
- function ot() {
326
+ function it() {
327
327
  return $();
328
328
  }
329
- async function it(t) {
329
+ async function at(t) {
330
330
  if (!w(t))
331
331
  throw new TypeError('"codeVerifier" must be a non-empty string');
332
332
  return A(await crypto.subtle.digest("SHA-256", E(t)));
333
333
  }
334
- function at(t) {
334
+ function st(t) {
335
335
  if (t instanceof CryptoKey)
336
336
  return { key: t };
337
337
  if (!((t == null ? void 0 : t.key) instanceof CryptoKey))
@@ -341,17 +341,17 @@ function at(t) {
341
341
  return {
342
342
  key: t.key,
343
343
  kid: t.kid,
344
- modifyAssertion: t[me]
344
+ modifyAssertion: t[ge]
345
345
  };
346
346
  }
347
- function ue(t) {
347
+ function le(t) {
348
348
  return encodeURIComponent(t).replace(/%20/g, "+");
349
349
  }
350
- function st(t, e) {
351
- const n = ue(t), o = ue(e);
350
+ function ct(t, e) {
351
+ const n = le(t), o = le(e);
352
352
  return `Basic ${btoa(`${n}:${o}`)}`;
353
353
  }
354
- function ct(t) {
354
+ function ut(t) {
355
355
  switch (t.algorithm.hash.name) {
356
356
  case "SHA-256":
357
357
  return "PS256";
@@ -363,7 +363,7 @@ function ct(t) {
363
363
  throw new S("unsupported RsaHashedKeyAlgorithm hash name");
364
364
  }
365
365
  }
366
- function ut(t) {
366
+ function lt(t) {
367
367
  switch (t.algorithm.hash.name) {
368
368
  case "SHA-256":
369
369
  return "RS256";
@@ -375,7 +375,7 @@ function ut(t) {
375
375
  throw new S("unsupported RsaHashedKeyAlgorithm hash name");
376
376
  }
377
377
  }
378
- function lt(t) {
378
+ function dt(t) {
379
379
  switch (t.algorithm.namedCurve) {
380
380
  case "P-256":
381
381
  return "ES256";
@@ -387,14 +387,14 @@ function lt(t) {
387
387
  throw new S("unsupported EcKeyAlgorithm namedCurve");
388
388
  }
389
389
  }
390
- function _e(t) {
390
+ function ve(t) {
391
391
  switch (t.algorithm.name) {
392
392
  case "RSA-PSS":
393
- return ct(t);
394
- case "RSASSA-PKCS1-v1_5":
395
393
  return ut(t);
396
- case "ECDSA":
394
+ case "RSASSA-PKCS1-v1_5":
397
395
  return lt(t);
396
+ case "ECDSA":
397
+ return dt(t);
398
398
  case "Ed25519":
399
399
  case "Ed448":
400
400
  return "EdDSA";
@@ -406,14 +406,14 @@ function L(t) {
406
406
  const e = t == null ? void 0 : t[W];
407
407
  return typeof e == "number" && Number.isFinite(e) ? e : 0;
408
408
  }
409
- function ve(t) {
410
- const e = t == null ? void 0 : t[Me];
409
+ function Se(t) {
410
+ const e = t == null ? void 0 : t[qe];
411
411
  return typeof e == "number" && Number.isFinite(e) && Math.sign(e) !== -1 ? e : 30;
412
412
  }
413
413
  function F() {
414
414
  return Math.floor(Date.now() / 1e3);
415
415
  }
416
- function dt(t, e) {
416
+ function ht(t, e) {
417
417
  const n = F() + L(e);
418
418
  return {
419
419
  jti: $(),
@@ -425,25 +425,25 @@ function dt(t, e) {
425
425
  sub: e.client_id
426
426
  };
427
427
  }
428
- async function ht(t, e, n, o, a) {
429
- const r = { alg: _e(n), kid: o }, i = dt(t, e);
430
- return a == null || a(r, i), Se(r, i, n);
428
+ async function ft(t, e, n, o, a) {
429
+ const r = { alg: ve(n), kid: o }, i = ht(t, e);
430
+ return a == null || a(r, i), Te(r, i, n);
431
431
  }
432
- function I(t) {
432
+ function j(t) {
433
433
  if (typeof t != "object" || t === null)
434
434
  throw new TypeError('"as" must be an object');
435
435
  if (!w(t.issuer))
436
436
  throw new TypeError('"as.issuer" property must be a non-empty string');
437
437
  return !0;
438
438
  }
439
- function j(t) {
439
+ function I(t) {
440
440
  if (typeof t != "object" || t === null)
441
441
  throw new TypeError('"client" must be an object');
442
442
  if (!w(t.client_id))
443
443
  throw new TypeError('"client.client_id" property must be a non-empty string');
444
444
  return !0;
445
445
  }
446
- function le(t) {
446
+ function de(t) {
447
447
  if (!w(t))
448
448
  throw new TypeError('"client.client_secret" property must be a non-empty string');
449
449
  return t;
@@ -452,100 +452,100 @@ function q(t, e) {
452
452
  if (e !== void 0)
453
453
  throw new TypeError(`"options.clientPrivateKey" property must not be provided when ${t} client authentication method is used.`);
454
454
  }
455
- function de(t, e) {
455
+ function he(t, e) {
456
456
  if (e !== void 0)
457
457
  throw new TypeError(`"client.client_secret" property must not be provided when ${t} client authentication method is used.`);
458
458
  }
459
- async function ft(t, e, n, o, a) {
459
+ async function pt(t, e, n, o, a) {
460
460
  switch (n.delete("client_secret"), n.delete("client_assertion_type"), n.delete("client_assertion"), e.token_endpoint_auth_method) {
461
461
  case void 0:
462
462
  case "client_secret_basic": {
463
- q("client_secret_basic", a), o.set("authorization", st(e.client_id, le(e.client_secret)));
463
+ q("client_secret_basic", a), o.set("authorization", ct(e.client_id, de(e.client_secret)));
464
464
  break;
465
465
  }
466
466
  case "client_secret_post": {
467
- q("client_secret_post", a), n.set("client_id", e.client_id), n.set("client_secret", le(e.client_secret));
467
+ q("client_secret_post", a), n.set("client_id", e.client_id), n.set("client_secret", de(e.client_secret));
468
468
  break;
469
469
  }
470
470
  case "private_key_jwt": {
471
- if (de("private_key_jwt", e.client_secret), a === void 0)
471
+ if (he("private_key_jwt", e.client_secret), a === void 0)
472
472
  throw new TypeError('"options.clientPrivateKey" must be provided when "client.token_endpoint_auth_method" is "private_key_jwt"');
473
- const { key: r, kid: i, modifyAssertion: c } = at(a);
474
- if (!be(r))
473
+ const { key: r, kid: i, modifyAssertion: c } = st(a);
474
+ if (!_e(r))
475
475
  throw new TypeError('"options.clientPrivateKey.key" must be a private CryptoKey');
476
- n.set("client_id", e.client_id), n.set("client_assertion_type", "urn:ietf:params:oauth:client-assertion-type:jwt-bearer"), n.set("client_assertion", await ht(t, e, r, i, c));
476
+ n.set("client_id", e.client_id), n.set("client_assertion_type", "urn:ietf:params:oauth:client-assertion-type:jwt-bearer"), n.set("client_assertion", await ft(t, e, r, i, c));
477
477
  break;
478
478
  }
479
479
  case "tls_client_auth":
480
480
  case "self_signed_tls_client_auth":
481
481
  case "none": {
482
- de(e.token_endpoint_auth_method, e.client_secret), q(e.token_endpoint_auth_method, a), n.set("client_id", e.client_id);
482
+ he(e.token_endpoint_auth_method, e.client_secret), q(e.token_endpoint_auth_method, a), n.set("client_id", e.client_id);
483
483
  break;
484
484
  }
485
485
  default:
486
486
  throw new S("unsupported client token_endpoint_auth_method");
487
487
  }
488
488
  }
489
- async function Se(t, e, n) {
489
+ async function Te(t, e, n) {
490
490
  if (!n.usages.includes("sign"))
491
491
  throw new TypeError('CryptoKey instances used for signing assertions must include "sign" in their "usages"');
492
- const o = `${A(E(JSON.stringify(t)))}.${A(E(JSON.stringify(e)))}`, a = A(await crypto.subtle.sign(Ue(n), n, E(o)));
492
+ const o = `${A(E(JSON.stringify(t)))}.${A(E(JSON.stringify(e)))}`, a = A(await crypto.subtle.sign(xe(n), n, E(o)));
493
493
  return `${o}.${a}`;
494
494
  }
495
- async function pt(t, e, n, o, a, r) {
495
+ async function wt(t, e, n, o, a, r) {
496
496
  var T;
497
- const { privateKey: i, publicKey: c, nonce: p = ge.get(n.origin) } = e;
498
- if (!be(i))
497
+ const { privateKey: i, publicKey: c, nonce: h = ye.get(n.origin) } = e;
498
+ if (!_e(i))
499
499
  throw new TypeError('"DPoP.privateKey" must be a private CryptoKey');
500
- if (!et(c))
500
+ if (!tt(c))
501
501
  throw new TypeError('"DPoP.publicKey" must be a public CryptoKey');
502
- if (p !== void 0 && !w(p))
502
+ if (h !== void 0 && !w(h))
503
503
  throw new TypeError('"DPoP.nonce" must be a non-empty string or undefined');
504
504
  if (!c.extractable)
505
505
  throw new TypeError('"DPoP.publicKey.extractable" must be true');
506
- const _ = F() + a, f = {
507
- alg: _e(i),
506
+ const _ = F() + a, p = {
507
+ alg: ve(i),
508
508
  typ: "dpop+jwt",
509
- jwk: await mt(c)
509
+ jwk: await gt(c)
510
510
  }, y = {
511
511
  iat: _,
512
512
  jti: $(),
513
513
  htm: o,
514
- nonce: p,
514
+ nonce: h,
515
515
  htu: `${n.origin}${n.pathname}`,
516
516
  ath: r ? A(await crypto.subtle.digest("SHA-256", E(r))) : void 0
517
517
  };
518
- (T = e[me]) == null || T.call(e, f, y), t.set("dpop", await Se(f, y, i));
518
+ (T = e[ge]) == null || T.call(e, p, y), t.set("dpop", await Te(p, y, i));
519
519
  }
520
520
  let K;
521
- async function wt(t) {
521
+ async function mt(t) {
522
522
  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 };
523
523
  return K.set(t, c), c;
524
524
  }
525
- async function mt(t) {
526
- return K || (K = /* @__PURE__ */ new WeakMap()), K.get(t) || wt(t);
525
+ async function gt(t) {
526
+ return K || (K = /* @__PURE__ */ new WeakMap()), K.get(t) || mt(t);
527
527
  }
528
- function he(t, e, n) {
528
+ function fe(t, e, n) {
529
529
  if (typeof t != "string")
530
530
  throw n ? new TypeError(`"as.mtls_endpoint_aliases.${e}" must be a string`) : new TypeError(`"as.${e}" must be a string`);
531
531
  return new URL(t);
532
532
  }
533
- function Te(t, e, n = !1) {
534
- 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);
533
+ function ke(t, e, n = !1) {
534
+ return n && t.mtls_endpoint_aliases && e in t.mtls_endpoint_aliases ? fe(t.mtls_endpoint_aliases[e], e, n) : fe(t[e], e, n);
535
535
  }
536
- function ke(t, e) {
537
- return !!(t.use_mtls_endpoint_aliases || e != null && e[Be]);
536
+ function Ae(t, e) {
537
+ return !!(t.use_mtls_endpoint_aliases || e != null && e[Ve]);
538
538
  }
539
539
  function Y(t) {
540
540
  const e = t;
541
541
  return typeof e != "object" || Array.isArray(e) || e === null ? !1 : e.error !== void 0;
542
542
  }
543
- async function gt(t, e, n, o, a, r) {
543
+ async function yt(t, e, n, o, a, r) {
544
544
  if (!w(t))
545
545
  throw new TypeError('"accessToken" must be a non-empty string');
546
546
  if (!(n instanceof URL))
547
547
  throw new TypeError('"url" must be an instance of URL');
548
- return o = H(o), (r == null ? void 0 : r.DPoP) === void 0 ? o.set("authorization", `Bearer ${t}`) : (await pt(o, r.DPoP, n, e.toUpperCase(), L({ [W]: r == null ? void 0 : r[W] }), t), o.set("authorization", `DPoP ${t}`)), ((r == null ? void 0 : r[X]) || fetch)(n.href, {
548
+ return o = H(o), (r == null ? void 0 : r.DPoP) === void 0 ? o.set("authorization", `Bearer ${t}`) : (await wt(o, r.DPoP, n, e.toUpperCase(), L({ [W]: r == null ? void 0 : r[W] }), t), o.set("authorization", `DPoP ${t}`)), ((r == null ? void 0 : r[X]) || fetch)(n.href, {
549
549
  body: a,
550
550
  headers: Object.fromEntries(o.entries()),
551
551
  method: e,
@@ -553,16 +553,16 @@ async function gt(t, e, n, o, a, r) {
553
553
  signal: r != null && r.signal ? te(r.signal) : null
554
554
  }).then(ee);
555
555
  }
556
- async function yt(t, e, n, o) {
557
- I(t), j(e);
558
- const a = Te(t, "userinfo_endpoint", ke(e, o)), r = H(o == null ? void 0 : o.headers);
559
- return e.userinfo_signed_response_alg ? r.set("accept", "application/jwt") : (r.set("accept", "application/json"), r.append("accept", "application/jwt")), gt(n, "GET", a, r, null, {
556
+ async function bt(t, e, n, o) {
557
+ j(t), I(e);
558
+ const a = ke(t, "userinfo_endpoint", Ae(e, o)), r = H(o == null ? void 0 : o.headers);
559
+ return e.userinfo_signed_response_alg ? r.set("accept", "application/jwt") : (r.set("accept", "application/json"), r.append("accept", "application/jwt")), yt(n, "GET", a, r, null, {
560
560
  ...o,
561
561
  [W]: L(e)
562
562
  });
563
563
  }
564
- async function bt(t, e, n, o, a, r, i) {
565
- return await ft(t, e, a, r, i == null ? void 0 : i.clientPrivateKey), r.set("content-type", "application/x-www-form-urlencoded;charset=UTF-8"), ((i == null ? void 0 : i[X]) || fetch)(o.href, {
564
+ async function _t(t, e, n, o, a, r, i) {
565
+ return await pt(t, e, a, r, i == null ? void 0 : i.clientPrivateKey), r.set("content-type", "application/x-www-form-urlencoded;charset=UTF-8"), ((i == null ? void 0 : i[X]) || fetch)(o.href, {
566
566
  body: a,
567
567
  headers: Object.fromEntries(r.entries()),
568
568
  method: n,
@@ -570,33 +570,33 @@ async function bt(t, e, n, o, a, r, i) {
570
570
  signal: i != null && i.signal ? te(i.signal) : null
571
571
  }).then(ee);
572
572
  }
573
- async function Ae(t, e, n, o, a) {
574
- const r = Te(t, "token_endpoint", ke(e, a));
573
+ async function Ee(t, e, n, o, a) {
574
+ const r = ke(t, "token_endpoint", Ae(e, a));
575
575
  o.set("grant_type", n);
576
576
  const i = H(a == null ? void 0 : a.headers);
577
- return i.set("accept", "application/json"), bt(t, e, "POST", r, o, i, a);
577
+ return i.set("accept", "application/json"), _t(t, e, "POST", r, o, i, a);
578
578
  }
579
- async function _t(t, e, n, o) {
580
- if (I(t), j(e), !w(n))
579
+ async function vt(t, e, n, o) {
580
+ if (j(t), I(e), !w(n))
581
581
  throw new TypeError('"refreshToken" must be a non-empty string');
582
582
  const a = new URLSearchParams(o == null ? void 0 : o.additionalParameters);
583
- return a.set("refresh_token", n), Ae(t, e, "refresh_token", a, o);
583
+ return a.set("refresh_token", n), Ee(t, e, "refresh_token", a, o);
584
584
  }
585
- const Ee = /* @__PURE__ */ new WeakMap();
586
- function vt(t) {
585
+ const Re = /* @__PURE__ */ new WeakMap();
586
+ function St(t) {
587
587
  if (!t.id_token)
588
588
  return;
589
- const e = Ee.get(t);
589
+ const e = Re.get(t);
590
590
  if (!e)
591
591
  throw new TypeError('"ref" was already garbage collected or did not resolve from the proper sources');
592
592
  return e[0];
593
593
  }
594
- async function Re(t, e, n, o = !1, a = !1) {
595
- if (I(t), j(e), !Q(n, Response))
594
+ async function Pe(t, e, n, o = !1, a = !1) {
595
+ if (j(t), I(e), !Q(n, Response))
596
596
  throw new TypeError('"response" must be an instance of Response');
597
597
  if (n.status !== 200) {
598
598
  let i;
599
- if (i = await Ct(n))
599
+ if (i = await Lt(n))
600
600
  return i;
601
601
  throw new s('"response" is not a conform Token Endpoint response');
602
602
  }
@@ -625,7 +625,7 @@ async function Re(t, e, n, o = !1, a = !1) {
625
625
  if (r.id_token !== void 0 && !w(r.id_token))
626
626
  throw new s('"response" body "id_token" property must be a non-empty string');
627
627
  if (r.id_token) {
628
- const { claims: i, jwt: c } = await jt(r.id_token, Jt.bind(void 0, e.id_token_signed_response_alg, t.id_token_signing_alg_values_supported), xe, L(e), ve(e), e[qe]).then(Pt.bind(void 0, ["aud", "exp", "iat", "iss", "sub"])).then(kt.bind(void 0, t.issuer)).then(Tt.bind(void 0, e.client_id));
628
+ const { claims: i, jwt: c } = await Jt(r.id_token, Ot.bind(void 0, e.id_token_signed_response_alg, t.id_token_signing_alg_values_supported), Ce, L(e), Se(e), e[Be]).then(Ut.bind(void 0, ["aud", "exp", "iat", "iss", "sub"])).then(At.bind(void 0, t.issuer)).then(kt.bind(void 0, e.client_id));
629
629
  if (Array.isArray(i.aud) && i.aud.length !== 1) {
630
630
  if (i.azp === void 0)
631
631
  throw new s('ID Token "aud" (audience) claim includes additional untrusted audiences');
@@ -634,15 +634,15 @@ async function Re(t, e, n, o = !1, a = !1) {
634
634
  }
635
635
  if (i.auth_time !== void 0 && (!Number.isFinite(i.auth_time) || Math.sign(i.auth_time) !== 1))
636
636
  throw new s('ID Token "auth_time" (authentication time) must be a positive number');
637
- Ee.set(r, [i, c]);
637
+ Re.set(r, [i, c]);
638
638
  }
639
639
  }
640
640
  return r;
641
641
  }
642
- async function St(t, e, n) {
643
- return Re(t, e, n);
642
+ async function Tt(t, e, n) {
643
+ return Pe(t, e, n);
644
644
  }
645
- function Tt(t, e) {
645
+ function kt(t, e) {
646
646
  if (Array.isArray(e.claims.aud)) {
647
647
  if (!e.claims.aud.includes(t))
648
648
  throw new s('unexpected JWT "aud" (audience) claim value');
@@ -650,17 +650,17 @@ function Tt(t, e) {
650
650
  throw new s('unexpected JWT "aud" (audience) claim value');
651
651
  return e;
652
652
  }
653
- function kt(t, e) {
653
+ function At(t, e) {
654
654
  if (e.claims.iss !== t)
655
655
  throw new s('unexpected JWT "iss" (issuer) claim value');
656
656
  return e;
657
657
  }
658
- const Pe = /* @__PURE__ */ new WeakSet();
659
- function At(t) {
660
- return Pe.add(t), t;
658
+ const Ue = /* @__PURE__ */ new WeakSet();
659
+ function Et(t) {
660
+ return Ue.add(t), t;
661
661
  }
662
- async function Et(t, e, n, o, a, r) {
663
- if (I(t), j(e), !Pe.has(n))
662
+ async function Rt(t, e, n, o, a, r) {
663
+ if (j(t), I(e), !Ue.has(n))
664
664
  throw new TypeError('"callbackParameters" must be an instance of URLSearchParams obtained from "validateAuthResponse()", or "validateJwtAuthResponse()');
665
665
  if (!w(o))
666
666
  throw new TypeError('"redirectUri" must be a non-empty string');
@@ -670,9 +670,9 @@ async function Et(t, e, n, o, a, r) {
670
670
  if (!i)
671
671
  throw new s('no authorization code in "callbackParameters"');
672
672
  const c = new URLSearchParams(r == null ? void 0 : r.additionalParameters);
673
- return c.set("redirect_uri", o), c.set("code_verifier", a), c.set("code", i), Ae(t, e, "authorization_code", c, r);
673
+ return c.set("redirect_uri", o), c.set("code_verifier", a), c.set("code", i), Ee(t, e, "authorization_code", c, r);
674
674
  }
675
- const Rt = {
675
+ const Pt = {
676
676
  aud: "audience",
677
677
  c_hash: "code hash",
678
678
  client_id: "client id",
@@ -688,33 +688,33 @@ const Rt = {
688
688
  htu: "http uri",
689
689
  cnf: "confirmation"
690
690
  };
691
- function Pt(t, e) {
691
+ function Ut(t, e) {
692
692
  for (const n of t)
693
693
  if (e.claims[n] === void 0)
694
- throw new s(`JWT "${n}" (${Rt[n]}) claim missing`);
694
+ throw new s(`JWT "${n}" (${Pt[n]}) claim missing`);
695
695
  return e;
696
696
  }
697
- const Ut = Symbol(), B = Symbol();
698
- async function xt(t, e, n, o, a) {
699
- const r = await Re(t, e, n);
697
+ const xt = Symbol(), B = Symbol();
698
+ async function Ct(t, e, n, o, a) {
699
+ const r = await Pe(t, e, n);
700
700
  if (Y(r))
701
701
  return r;
702
702
  if (!w(r.id_token))
703
703
  throw new s('"response" body "id_token" property must be a non-empty string');
704
704
  a ?? (a = e.default_max_age ?? B);
705
- const i = vt(r);
705
+ const i = St(r);
706
706
  if ((e.require_auth_time || a !== B) && i.auth_time === void 0)
707
707
  throw new s('ID Token "auth_time" (authentication time) claim missing');
708
708
  if (a !== B) {
709
709
  if (typeof a != "number" || a < 0)
710
710
  throw new TypeError('"maxAge" must be a non-negative number');
711
- const c = F() + L(e), p = ve(e);
712
- if (i.auth_time + a < c - p)
711
+ const c = F() + L(e), h = Se(e);
712
+ if (i.auth_time + a < c - h)
713
713
  throw new s("too much time has elapsed since the last End-User authentication");
714
714
  }
715
715
  switch (o) {
716
716
  case void 0:
717
- case Ut:
717
+ case xt:
718
718
  if (i.nonce !== void 0)
719
719
  throw new s('unexpected ID Token "nonce" claim value');
720
720
  break;
@@ -732,7 +732,7 @@ function ne(t) {
732
732
  if (t.bodyUsed)
733
733
  throw new TypeError('"response" body has been used already');
734
734
  }
735
- async function Ct(t) {
735
+ async function Lt(t) {
736
736
  if (t.status > 399 && t.status < 500) {
737
737
  ne(t);
738
738
  try {
@@ -743,11 +743,11 @@ async function Ct(t) {
743
743
  }
744
744
  }
745
745
  }
746
- function fe(t) {
746
+ function pe(t) {
747
747
  if (typeof t.modulusLength != "number" || t.modulusLength < 2048)
748
748
  throw new s(`${t.name} modulusLength must be at least 2048 bits`);
749
749
  }
750
- function Lt(t) {
750
+ function jt(t) {
751
751
  switch (t) {
752
752
  case "P-256":
753
753
  return "SHA-256";
@@ -759,15 +759,15 @@ function Lt(t) {
759
759
  throw new S();
760
760
  }
761
761
  }
762
- function Ue(t) {
762
+ function xe(t) {
763
763
  switch (t.algorithm.name) {
764
764
  case "ECDSA":
765
765
  return {
766
766
  name: t.algorithm.name,
767
- hash: Lt(t.algorithm.namedCurve)
767
+ hash: jt(t.algorithm.namedCurve)
768
768
  };
769
769
  case "RSA-PSS":
770
- switch (fe(t.algorithm), t.algorithm.hash.name) {
770
+ switch (pe(t.algorithm), t.algorithm.hash.name) {
771
771
  case "SHA-256":
772
772
  case "SHA-384":
773
773
  case "SHA-512":
@@ -779,71 +779,71 @@ function Ue(t) {
779
779
  throw new S();
780
780
  }
781
781
  case "RSASSA-PKCS1-v1_5":
782
- return fe(t.algorithm), t.algorithm.name;
782
+ return pe(t.algorithm), t.algorithm.name;
783
783
  case "Ed448":
784
784
  case "Ed25519":
785
785
  return t.algorithm.name;
786
786
  }
787
787
  throw new S();
788
788
  }
789
- const xe = Symbol();
789
+ const Ce = Symbol();
790
790
  async function It(t, e, n, o) {
791
791
  const a = `${t}.${e}`;
792
- if (!await crypto.subtle.verify(Ue(n), n, o, E(a)))
792
+ if (!await crypto.subtle.verify(xe(n), n, o, E(a)))
793
793
  throw new s("JWT signature verification failed");
794
794
  }
795
- async function jt(t, e, n, o, a, r) {
796
- let { 0: i, 1: c, 2: p, length: _ } = t.split(".");
795
+ async function Jt(t, e, n, o, a, r) {
796
+ let { 0: i, 1: c, 2: h, length: _ } = t.split(".");
797
797
  if (_ === 5)
798
798
  if (r !== void 0)
799
- t = await r(t), { 0: i, 1: c, 2: p, length: _ } = t.split(".");
799
+ t = await r(t), { 0: i, 1: c, 2: h, length: _ } = t.split(".");
800
800
  else
801
801
  throw new S("JWE structure JWTs are not supported");
802
802
  if (_ !== 3)
803
803
  throw new s("Invalid JWT");
804
- let f;
804
+ let p;
805
805
  try {
806
- f = JSON.parse(E(A(i)));
806
+ p = JSON.parse(E(A(i)));
807
807
  } catch (l) {
808
808
  throw new s("failed to parse JWT Header body as base64url encoded JSON", { cause: l });
809
809
  }
810
- if (!C(f))
810
+ if (!C(p))
811
811
  throw new s("JWT Header must be a top level object");
812
- if (e(f), f.crit !== void 0)
812
+ if (e(p), p.crit !== void 0)
813
813
  throw new s('unexpected JWT "crit" header parameter');
814
- const y = A(p);
814
+ const y = A(h);
815
815
  let T;
816
- n !== xe && (T = await n(f), await It(i, c, T, y));
817
- let h;
816
+ n !== Ce && (T = await n(p), await It(i, c, T, y));
817
+ let f;
818
818
  try {
819
- h = JSON.parse(E(A(c)));
819
+ f = JSON.parse(E(A(c)));
820
820
  } catch (l) {
821
821
  throw new s("failed to parse JWT Payload body as base64url encoded JSON", { cause: l });
822
822
  }
823
- if (!C(h))
823
+ if (!C(f))
824
824
  throw new s("JWT Payload must be a top level object");
825
825
  const J = F() + o;
826
- if (h.exp !== void 0) {
827
- if (typeof h.exp != "number")
826
+ if (f.exp !== void 0) {
827
+ if (typeof f.exp != "number")
828
828
  throw new s('unexpected JWT "exp" (expiration time) claim type');
829
- if (h.exp <= J - a)
829
+ if (f.exp <= J - a)
830
830
  throw new s('unexpected JWT "exp" (expiration time) claim value, timestamp is <= now()');
831
831
  }
832
- if (h.iat !== void 0 && typeof h.iat != "number")
832
+ if (f.iat !== void 0 && typeof f.iat != "number")
833
833
  throw new s('unexpected JWT "iat" (issued at) claim type');
834
- if (h.iss !== void 0 && typeof h.iss != "string")
834
+ if (f.iss !== void 0 && typeof f.iss != "string")
835
835
  throw new s('unexpected JWT "iss" (issuer) claim type');
836
- if (h.nbf !== void 0) {
837
- if (typeof h.nbf != "number")
836
+ if (f.nbf !== void 0) {
837
+ if (typeof f.nbf != "number")
838
838
  throw new s('unexpected JWT "nbf" (not before) claim type');
839
- if (h.nbf > J + a)
839
+ if (f.nbf > J + a)
840
840
  throw new s('unexpected JWT "nbf" (not before) claim value, timestamp is > now()');
841
841
  }
842
- if (h.aud !== void 0 && typeof h.aud != "string" && !Array.isArray(h.aud))
842
+ if (f.aud !== void 0 && typeof f.aud != "string" && !Array.isArray(f.aud))
843
843
  throw new s('unexpected JWT "aud" (audience) claim type');
844
- return { header: f, claims: h, signature: y, key: T, jwt: t };
844
+ return { header: p, claims: f, signature: y, key: T, jwt: t };
845
845
  }
846
- function Jt(t, e, n) {
846
+ function Ot(t, e, n) {
847
847
  if (t !== void 0) {
848
848
  if (n.alg !== t)
849
849
  throw new s('unexpected JWT "alg" header parameter');
@@ -863,9 +863,9 @@ function k(t, e) {
863
863
  throw new s(`"${e}" parameter must be provided only once`);
864
864
  return n;
865
865
  }
866
- const Ot = Symbol(), zt = Symbol();
867
- function Dt(t, e, n, o) {
868
- if (I(t), j(e), n instanceof URL && (n = n.searchParams), !(n instanceof URLSearchParams))
866
+ const zt = Symbol(), Dt = Symbol();
867
+ function Nt(t, e, n, o) {
868
+ if (j(t), I(e), n instanceof URL && (n = n.searchParams), !(n instanceof URLSearchParams))
869
869
  throw new TypeError('"parameters" must be an instance of URLSearchParams, or URL');
870
870
  if (k(n, "response"))
871
871
  throw new s('"parameters" contains a JARM response, use validateJwtAuthResponse() instead of validateAuthResponse()');
@@ -876,11 +876,11 @@ function Dt(t, e, n, o) {
876
876
  throw new s('unexpected "iss" (issuer) response parameter value');
877
877
  switch (o) {
878
878
  case void 0:
879
- case zt:
879
+ case Dt:
880
880
  if (r !== void 0)
881
881
  throw new s('unexpected "state" response parameter encountered');
882
882
  break;
883
- case Ot:
883
+ case zt:
884
884
  break;
885
885
  default:
886
886
  if (!w(o))
@@ -897,22 +897,22 @@ function Dt(t, e, n, o) {
897
897
  error_description: k(n, "error_description"),
898
898
  error_uri: k(n, "error_uri")
899
899
  };
900
- const c = k(n, "id_token"), p = k(n, "token");
901
- if (c !== void 0 || p !== void 0)
900
+ const c = k(n, "id_token"), h = k(n, "token");
901
+ if (c !== void 0 || h !== void 0)
902
902
  throw new S("implicit and hybrid flows are not supported");
903
- return At(new URLSearchParams(n));
903
+ return Et(new URLSearchParams(n));
904
904
  }
905
- function Nt({
905
+ function Kt({
906
906
  handleCallback: t
907
907
  }) {
908
- const e = Ne({
908
+ const e = Ke({
909
909
  retry: !1,
910
910
  queryKey: ["oauth-callback"],
911
911
  queryFn: async () => {
912
912
  try {
913
913
  return await t();
914
914
  } catch (n) {
915
- throw new We("Could not validate user", {
915
+ throw new He("Could not validate user", {
916
916
  cause: n,
917
917
  title: "Authentication Error",
918
918
  developerHint: "Check the configuration of your authorization provider and ensure all settings such as the callback URL are configured correctly."
@@ -920,17 +920,17 @@ function Nt({
920
920
  }
921
921
  }
922
922
  });
923
- return /* @__PURE__ */ G.jsx(Ke, { to: e.data });
923
+ return /* @__PURE__ */ G.jsx(We, { to: e.data });
924
924
  }
925
925
  class P extends Error {
926
926
  }
927
- class pe extends P {
927
+ class we extends P {
928
928
  constructor(e, n, o) {
929
929
  super(e, o), this.error = n;
930
930
  }
931
931
  }
932
932
  const V = "code-verifier";
933
- class Kt extends De {
933
+ class Wt extends Ne {
934
934
  constructor(e, n) {
935
935
  super(), this.callbackUrlPath = e, this.handleCallback = n;
936
936
  }
@@ -939,25 +939,26 @@ class Kt extends De {
939
939
  ...super.getRoutes(),
940
940
  {
941
941
  path: this.callbackUrlPath,
942
- element: /* @__PURE__ */ G.jsx(ze, { children: /* @__PURE__ */ G.jsx(Nt, { handleCallback: this.handleCallback }) })
942
+ element: /* @__PURE__ */ G.jsx(De, { children: /* @__PURE__ */ G.jsx(Kt, { handleCallback: this.handleCallback }) })
943
943
  }
944
944
  ];
945
945
  }
946
946
  }
947
- class Wt {
947
+ class Ht {
948
948
  constructor({
949
949
  issuer: e,
950
950
  audience: n,
951
951
  clientId: o,
952
952
  redirectToAfterSignUp: a,
953
953
  redirectToAfterSignIn: r,
954
- redirectToAfterSignOut: i
954
+ redirectToAfterSignOut: i,
955
+ basePath: c
955
956
  }) {
956
957
  b(this, "client");
957
958
  b(this, "issuer");
958
959
  b(this, "authorizationServer");
959
- b(this, "callbackUrlPath", "/oauth/callback");
960
- b(this, "logoutRedirectUrlPath", "/");
960
+ b(this, "callbackUrlPath");
961
+ b(this, "logoutRedirectUrlPath");
961
962
  b(this, "onAuthorizationUrl");
962
963
  b(this, "redirectToAfterSignUp");
963
964
  b(this, "redirectToAfterSignIn");
@@ -984,32 +985,32 @@ class Wt {
984
985
  const e = new URL(window.location.href), n = e.searchParams.get("state"), o = sessionStorage.getItem(V);
985
986
  if (sessionStorage.removeItem(V), !o)
986
987
  throw new P("No code verifier found in state.");
987
- const a = await this.getAuthServer(), r = Dt(
988
+ const a = await this.getAuthServer(), r = Nt(
988
989
  a,
989
990
  this.client,
990
991
  e.searchParams,
991
992
  n ?? void 0
992
993
  );
993
994
  if (Y(r))
994
- throw se.error("Error validating OAuth response", r), new pe(
995
+ throw ce.error("Error validating OAuth response", r), new we(
995
996
  "Error validating OAuth response",
996
997
  r
997
998
  );
998
999
  const i = new URL(e);
999
1000
  i.pathname = this.callbackUrlPath, i.search = "";
1000
- const c = await Et(
1001
+ const c = await Rt(
1001
1002
  a,
1002
1003
  this.client,
1003
1004
  r,
1004
1005
  i.toString(),
1005
1006
  o
1006
- ), p = await xt(
1007
+ ), h = await Ct(
1007
1008
  a,
1008
1009
  this.client,
1009
1010
  c
1010
1011
  );
1011
- this.setTokensFromResponse(p);
1012
- const _ = await this.getAccessToken(), y = await (await yt(
1012
+ this.setTokensFromResponse(h);
1013
+ const _ = await this.getAccessToken(), y = await (await bt(
1013
1014
  a,
1014
1015
  this.client,
1015
1016
  _
@@ -1025,18 +1026,20 @@ class Wt {
1025
1026
  isPending: !1,
1026
1027
  profile: T
1027
1028
  });
1028
- const h = sessionStorage.getItem("redirect-to") ?? "/";
1029
- return sessionStorage.removeItem("redirect-to"), h;
1029
+ const f = sessionStorage.getItem("redirect-to") ?? "/";
1030
+ return sessionStorage.removeItem("redirect-to"), f;
1030
1031
  });
1031
1032
  this.client = {
1032
1033
  client_id: o,
1033
1034
  token_endpoint_auth_method: "none"
1034
- }, this.audience = n, this.issuer = e, this.redirectToAfterSignUp = a ?? "/", this.redirectToAfterSignIn = r ?? "/", this.redirectToAfterSignOut = i ?? "/";
1035
+ }, this.audience = n, this.issuer = e, this.callbackUrlPath = ae(c, "/oauth/callback");
1036
+ const h = ae(c, "/");
1037
+ this.logoutRedirectUrlPath = h, this.redirectToAfterSignUp = a ?? h, this.redirectToAfterSignIn = r ?? h, this.redirectToAfterSignOut = i ?? h;
1035
1038
  }
1036
1039
  async getAuthServer() {
1037
1040
  if (!this.authorizationServer) {
1038
- const e = new URL(this.issuer), n = await tt(e);
1039
- this.authorizationServer = await nt(
1041
+ const e = new URL(this.issuer), n = await nt(e);
1042
+ this.authorizationServer = await rt(
1040
1043
  e,
1041
1044
  n
1042
1045
  );
@@ -1049,7 +1052,7 @@ class Wt {
1049
1052
  */
1050
1053
  setTokensFromResponse(e) {
1051
1054
  if (Y(e))
1052
- throw se.error("Bad Token Response", e), new pe("Bad Token Response", e);
1055
+ throw ce.error("Bad Token Response", e), new we("Bad Token Response", e);
1053
1056
  if (!e.expires_in)
1054
1057
  throw new P("No expires_in in response");
1055
1058
  const n = {
@@ -1078,25 +1081,25 @@ class Wt {
1078
1081
  redirectTo: e,
1079
1082
  isSignUp: n = !1
1080
1083
  }) {
1081
- var _, f;
1084
+ var _, p;
1082
1085
  const o = "S256", a = await this.getAuthServer();
1083
1086
  if (!a.authorization_endpoint)
1084
1087
  throw new P("No authorization endpoint");
1085
- const r = rt(), i = await it(r);
1088
+ const r = ot(), i = await at(r);
1086
1089
  sessionStorage.setItem(V, r);
1087
1090
  const c = new URL(
1088
1091
  a.authorization_endpoint
1089
1092
  );
1090
1093
  sessionStorage.setItem("redirect-to", e);
1091
- const p = new URL(window.location.origin);
1092
- if (p.pathname = this.callbackUrlPath, p.search = "", c.searchParams.set("client_id", this.client.client_id), c.searchParams.set("redirect_uri", p.toString()), c.searchParams.set("response_type", "code"), c.searchParams.set("scope", "openid profile email"), c.searchParams.set("code_challenge", i), c.searchParams.set(
1094
+ const h = new URL(window.location.origin);
1095
+ if (h.pathname = this.callbackUrlPath, h.search = "", c.searchParams.set("client_id", this.client.client_id), c.searchParams.set("redirect_uri", h.toString()), c.searchParams.set("response_type", "code"), c.searchParams.set("scope", "openid profile email"), c.searchParams.set("code_challenge", i), c.searchParams.set(
1093
1096
  "code_challenge_method",
1094
1097
  o
1095
1098
  ), this.audience && c.searchParams.set("audience", this.audience), (_ = this.onAuthorizationUrl) == null || _.call(this, c, {
1096
1099
  isSignIn: !n,
1097
1100
  isSignUp: n
1098
- }), ((f = a.code_challenge_methods_supported) == null ? void 0 : f.includes("S256")) !== !0) {
1099
- const y = ot();
1101
+ }), ((p = a.code_challenge_methods_supported) == null ? void 0 : p.includes("S256")) !== !0) {
1102
+ const y = it();
1100
1103
  c.searchParams.set("state", y);
1101
1104
  }
1102
1105
  location.href = c.href;
@@ -1114,11 +1117,11 @@ class Wt {
1114
1117
  profile: null,
1115
1118
  providerData: null
1116
1119
  }), "";
1117
- const a = await _t(
1120
+ const a = await vt(
1118
1121
  e,
1119
1122
  this.client,
1120
1123
  o.refreshToken
1121
- ), r = await St(
1124
+ ), r = await Tt(
1122
1125
  e,
1123
1126
  this.client,
1124
1127
  a
@@ -1130,12 +1133,12 @@ class Wt {
1130
1133
  return o.accessToken;
1131
1134
  }
1132
1135
  getAuthenticationPlugin() {
1133
- return new Kt(this.callbackUrlPath, this.handleCallback);
1136
+ return new Wt(this.callbackUrlPath, this.handleCallback);
1134
1137
  }
1135
1138
  }
1136
- const Yt = (t) => new Wt(t);
1139
+ const Qt = (t) => new Ht(t);
1137
1140
  export {
1138
- Wt as OpenIDAuthenticationProvider,
1139
- Yt as default
1141
+ Ht as OpenIDAuthenticationProvider,
1142
+ Qt as default
1140
1143
  };
1141
1144
  //# sourceMappingURL=zudoku.auth-openid.js.map