zudoku 0.0.0-f01b653 → 0.0.0-f06d326

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 (936) hide show
  1. package/README.md +1 -1
  2. package/cli.js +3 -0
  3. package/dist/app/demo.js +0 -1
  4. package/dist/app/demo.js.map +1 -1
  5. package/dist/app/entry.client.d.ts +5 -0
  6. package/dist/app/entry.client.js +1 -0
  7. package/dist/app/entry.client.js.map +1 -1
  8. package/dist/app/entry.server.d.ts +5 -4
  9. package/dist/app/entry.server.js +11 -7
  10. package/dist/app/entry.server.js.map +1 -1
  11. package/dist/app/main.d.ts +1 -1
  12. package/dist/app/main.js +21 -9
  13. package/dist/app/main.js.map +1 -1
  14. package/dist/app/standalone.js +0 -1
  15. package/dist/app/standalone.js.map +1 -1
  16. package/dist/app/tailwind.js +20 -0
  17. package/dist/app/tailwind.js.map +1 -1
  18. package/dist/cli/build/handler.d.ts +1 -3
  19. package/dist/cli/build/handler.js +7 -0
  20. package/dist/cli/build/handler.js.map +1 -1
  21. package/dist/cli/cli.js +5 -0
  22. package/dist/cli/cli.js.map +1 -1
  23. package/dist/cli/cmds/build.d.ts +11 -3
  24. package/dist/cli/cmds/build.js +20 -13
  25. package/dist/cli/cmds/build.js.map +1 -1
  26. package/dist/cli/cmds/dev.d.ts +1 -1
  27. package/dist/cli/cmds/dev.js +12 -1
  28. package/dist/cli/cmds/dev.js.map +1 -1
  29. package/dist/cli/cmds/preview.d.ts +16 -0
  30. package/dist/cli/cmds/preview.js +25 -0
  31. package/dist/cli/cmds/preview.js.map +1 -0
  32. package/dist/cli/common/output.js.map +1 -1
  33. package/dist/cli/common/utils/ports.d.ts +1 -1
  34. package/dist/cli/common/utils/ports.js +16 -15
  35. package/dist/cli/common/utils/ports.js.map +1 -1
  36. package/dist/cli/dev/handler.d.ts +1 -0
  37. package/dist/cli/dev/handler.js +14 -12
  38. package/dist/cli/dev/handler.js.map +1 -1
  39. package/dist/cli/dev/pagefind-command.d.ts +3 -0
  40. package/dist/cli/dev/pagefind-command.js +59 -0
  41. package/dist/cli/dev/pagefind-command.js.map +1 -0
  42. package/dist/cli/preview/handler.d.ts +3 -0
  43. package/dist/cli/preview/handler.js +35 -0
  44. package/dist/cli/preview/handler.js.map +1 -0
  45. package/dist/config/common.d.ts +5 -3
  46. package/dist/config/config.d.ts +16 -15
  47. package/dist/config/loader.d.ts +6 -6
  48. package/dist/config/loader.js +20 -25
  49. package/dist/config/loader.js.map +1 -1
  50. package/dist/config/validators/InputSidebarSchema.d.ts +32 -17
  51. package/dist/config/validators/InputSidebarSchema.js +11 -1
  52. package/dist/config/validators/InputSidebarSchema.js.map +1 -1
  53. package/dist/config/validators/common.d.ts +2472 -534
  54. package/dist/config/validators/common.js +106 -18
  55. package/dist/config/validators/common.js.map +1 -1
  56. package/dist/config/validators/icon-types.d.ts +1 -1
  57. package/dist/config/validators/validate.d.ts +979 -254
  58. package/dist/index.d.ts +1 -0
  59. package/dist/index.js +1 -0
  60. package/dist/index.js.map +1 -1
  61. package/dist/lib/MissingIcon.d.ts +2 -0
  62. package/dist/lib/MissingIcon.js +7 -0
  63. package/dist/lib/MissingIcon.js.map +1 -0
  64. package/dist/lib/authentication/authentication.d.ts +1 -0
  65. package/dist/lib/authentication/components/SignOut.js +1 -1
  66. package/dist/lib/authentication/components/SignOut.js.map +1 -1
  67. package/dist/lib/authentication/hook.d.ts +1 -0
  68. package/dist/lib/authentication/hook.js +11 -1
  69. package/dist/lib/authentication/hook.js.map +1 -1
  70. package/dist/lib/authentication/providers/auth0.d.ts +2 -2
  71. package/dist/lib/authentication/providers/auth0.js +2 -1
  72. package/dist/lib/authentication/providers/auth0.js.map +1 -1
  73. package/dist/lib/authentication/providers/clerk.d.ts +2 -2
  74. package/dist/lib/authentication/providers/clerk.js +54 -12
  75. package/dist/lib/authentication/providers/clerk.js.map +1 -1
  76. package/dist/lib/authentication/providers/openid.d.ts +12 -3
  77. package/dist/lib/authentication/providers/openid.js +37 -17
  78. package/dist/lib/authentication/providers/openid.js.map +1 -1
  79. package/dist/lib/authentication/providers/supabase.d.ts +4 -0
  80. package/dist/lib/authentication/providers/supabase.js +117 -0
  81. package/dist/lib/authentication/providers/supabase.js.map +1 -0
  82. package/dist/lib/authentication/state.d.ts +0 -17
  83. package/dist/lib/authentication/state.js +9 -7
  84. package/dist/lib/authentication/state.js.map +1 -1
  85. package/dist/lib/components/AnchorLink.d.ts +2 -2
  86. package/dist/lib/components/AnchorLink.js +9 -5
  87. package/dist/lib/components/AnchorLink.js.map +1 -1
  88. package/dist/lib/components/Autocomplete.d.ts +13 -0
  89. package/dist/lib/components/Autocomplete.js +47 -0
  90. package/dist/lib/components/Autocomplete.js.map +1 -0
  91. package/dist/lib/components/Banner.js +1 -1
  92. package/dist/lib/components/Banner.js.map +1 -1
  93. package/dist/lib/components/Header.js +15 -15
  94. package/dist/lib/components/Header.js.map +1 -1
  95. package/dist/lib/components/Heading.d.ts +2 -2
  96. package/dist/lib/components/InlineCode.d.ts +2 -1
  97. package/dist/lib/components/InlineCode.js +2 -9
  98. package/dist/lib/components/InlineCode.js.map +1 -1
  99. package/dist/lib/components/Layout.js +7 -29
  100. package/dist/lib/components/Layout.js.map +1 -1
  101. package/dist/lib/components/Main.d.ts +2 -0
  102. package/dist/lib/components/Main.js +17 -0
  103. package/dist/lib/components/Main.js.map +1 -0
  104. package/dist/lib/components/Markdown.d.ts +2 -2
  105. package/dist/lib/components/Markdown.js +3 -1
  106. package/dist/lib/components/Markdown.js.map +1 -1
  107. package/dist/lib/components/MobileTopNavigation.js +1 -1
  108. package/dist/lib/components/MobileTopNavigation.js.map +1 -1
  109. package/dist/lib/components/Pagination.d.ts +10 -0
  110. package/dist/lib/components/Pagination.js +10 -0
  111. package/dist/lib/components/Pagination.js.map +1 -0
  112. package/dist/lib/components/PathRenderer.d.ts +11 -0
  113. package/dist/lib/components/PathRenderer.js +28 -0
  114. package/dist/lib/components/PathRenderer.js.map +1 -0
  115. package/dist/lib/components/StatusPage.d.ts +7 -0
  116. package/dist/lib/components/StatusPage.js +71 -0
  117. package/dist/lib/components/StatusPage.js.map +1 -0
  118. package/dist/lib/components/ThemeSwitch.js +8 -5
  119. package/dist/lib/components/ThemeSwitch.js.map +1 -1
  120. package/dist/lib/components/TopNavigation.d.ts +2 -2
  121. package/dist/lib/components/TopNavigation.js +29 -15
  122. package/dist/lib/components/TopNavigation.js.map +1 -1
  123. package/dist/lib/components/Zudoku.d.ts +1 -1
  124. package/dist/lib/components/Zudoku.js +12 -8
  125. package/dist/lib/components/Zudoku.js.map +1 -1
  126. package/dist/lib/components/cache.d.ts +13 -0
  127. package/dist/lib/components/cache.js +20 -0
  128. package/dist/lib/components/cache.js.map +1 -0
  129. package/dist/lib/components/context/RouterEventsEmitter.d.ts +1 -0
  130. package/dist/lib/components/context/RouterEventsEmitter.js +17 -0
  131. package/dist/lib/components/context/RouterEventsEmitter.js.map +1 -0
  132. package/dist/lib/components/context/ViewportAnchorContext.d.ts +2 -4
  133. package/dist/lib/components/context/ViewportAnchorContext.js +21 -14
  134. package/dist/lib/components/context/ViewportAnchorContext.js.map +1 -1
  135. package/dist/lib/components/context/ZudokuContext.d.ts +2 -2
  136. package/dist/lib/components/context/ZudokuContext.js +21 -8
  137. package/dist/lib/components/context/ZudokuContext.js.map +1 -1
  138. package/dist/lib/components/index.d.ts +32 -13
  139. package/dist/lib/components/index.js +16 -3
  140. package/dist/lib/components/index.js.map +1 -1
  141. package/dist/lib/components/navigation/Sidebar.d.ts +3 -1
  142. package/dist/lib/components/navigation/Sidebar.js +8 -5
  143. package/dist/lib/components/navigation/Sidebar.js.map +1 -1
  144. package/dist/lib/components/navigation/SidebarBadge.d.ts +6 -3
  145. package/dist/lib/components/navigation/SidebarBadge.js +13 -11
  146. package/dist/lib/components/navigation/SidebarBadge.js.map +1 -1
  147. package/dist/lib/components/navigation/SidebarCategory.d.ts +2 -2
  148. package/dist/lib/components/navigation/SidebarCategory.js +25 -19
  149. package/dist/lib/components/navigation/SidebarCategory.js.map +1 -1
  150. package/dist/lib/components/navigation/SidebarItem.d.ts +1 -0
  151. package/dist/lib/components/navigation/SidebarItem.js +17 -10
  152. package/dist/lib/components/navigation/SidebarItem.js.map +1 -1
  153. package/dist/lib/components/navigation/SidebarWrapper.d.ts +8 -6
  154. package/dist/lib/components/navigation/SidebarWrapper.js +1 -2
  155. package/dist/lib/components/navigation/SidebarWrapper.js.map +1 -1
  156. package/dist/lib/{plugins/markdown → components/navigation}/Toc.js +5 -7
  157. package/dist/lib/components/navigation/Toc.js.map +1 -0
  158. package/dist/lib/core/RouteGuard.d.ts +1 -0
  159. package/dist/lib/core/RouteGuard.js +46 -0
  160. package/dist/lib/core/RouteGuard.js.map +1 -0
  161. package/dist/lib/core/ZudokuContext.d.ts +32 -7
  162. package/dist/lib/core/ZudokuContext.js +37 -12
  163. package/dist/lib/core/ZudokuContext.js.map +1 -1
  164. package/dist/lib/core/plugins.d.ts +17 -7
  165. package/dist/lib/core/plugins.js +3 -0
  166. package/dist/lib/core/plugins.js.map +1 -1
  167. package/dist/lib/errors/ErrorAlert.js +6 -1
  168. package/dist/lib/errors/ErrorAlert.js.map +1 -1
  169. package/dist/lib/hooks/index.d.ts +3 -0
  170. package/dist/lib/hooks/index.js +5 -0
  171. package/dist/lib/hooks/index.js.map +1 -0
  172. package/dist/lib/hooks/useEvent.d.ts +11 -0
  173. package/dist/lib/hooks/useEvent.js +19 -0
  174. package/dist/lib/hooks/useEvent.js.map +1 -0
  175. package/dist/lib/hooks/useEvent.test.d.ts +1 -0
  176. package/dist/lib/hooks/useEvent.test.js +100 -0
  177. package/dist/lib/hooks/useEvent.test.js.map +1 -0
  178. package/dist/lib/icons.d.ts +1 -0
  179. package/dist/lib/icons.js +1 -0
  180. package/dist/lib/icons.js.map +1 -1
  181. package/dist/lib/oas/graphql/circular.d.ts +3 -0
  182. package/dist/lib/oas/graphql/circular.js +38 -0
  183. package/dist/lib/oas/graphql/circular.js.map +1 -0
  184. package/dist/lib/oas/graphql/index.d.ts +25 -1
  185. package/dist/lib/oas/graphql/index.js +209 -65
  186. package/dist/lib/oas/graphql/index.js.map +1 -1
  187. package/dist/lib/oas/parser/dereference/index.js +8 -3
  188. package/dist/lib/oas/parser/dereference/index.js.map +1 -1
  189. package/dist/lib/oas/parser/index.d.ts +5 -3
  190. package/dist/lib/oas/parser/index.js +0 -22
  191. package/dist/lib/oas/parser/index.js.map +1 -1
  192. package/dist/lib/oas/parser/upgrade/index.js +19 -4
  193. package/dist/lib/oas/parser/upgrade/index.js.map +1 -1
  194. package/dist/lib/plugins/api-catalog/Catalog.d.ts +3 -5
  195. package/dist/lib/plugins/api-catalog/Catalog.js +23 -26
  196. package/dist/lib/plugins/api-catalog/Catalog.js.map +1 -1
  197. package/dist/lib/plugins/api-catalog/index.d.ts +9 -1
  198. package/dist/lib/plugins/api-catalog/index.js +37 -8
  199. package/dist/lib/plugins/api-catalog/index.js.map +1 -1
  200. package/dist/lib/plugins/api-keys/CreateApiKey.js +7 -3
  201. package/dist/lib/plugins/api-keys/CreateApiKey.js.map +1 -1
  202. package/dist/lib/plugins/api-keys/index.d.ts +1 -0
  203. package/dist/lib/plugins/api-keys/index.js +1 -0
  204. package/dist/lib/plugins/api-keys/index.js.map +1 -1
  205. package/dist/lib/plugins/markdown/MdxPage.d.ts +1 -1
  206. package/dist/lib/plugins/markdown/MdxPage.js +3 -3
  207. package/dist/lib/plugins/markdown/MdxPage.js.map +1 -1
  208. package/dist/lib/plugins/markdown/resolver.d.ts +0 -6
  209. package/dist/lib/plugins/markdown/resolver.js +0 -29
  210. package/dist/lib/plugins/markdown/resolver.js.map +1 -1
  211. package/dist/lib/plugins/openapi/CollapsibleCode.js +2 -1
  212. package/dist/lib/plugins/openapi/CollapsibleCode.js.map +1 -1
  213. package/dist/lib/plugins/openapi/ColorizedParam.d.ts +10 -2
  214. package/dist/lib/plugins/openapi/ColorizedParam.js +18 -7
  215. package/dist/lib/plugins/openapi/ColorizedParam.js.map +1 -1
  216. package/dist/lib/plugins/openapi/Endpoint.d.ts +1 -1
  217. package/dist/lib/plugins/openapi/Endpoint.js +8 -7
  218. package/dist/lib/plugins/openapi/Endpoint.js.map +1 -1
  219. package/dist/lib/plugins/openapi/OasProvider.d.ts +8 -0
  220. package/dist/lib/plugins/openapi/OasProvider.js +29 -0
  221. package/dist/lib/plugins/openapi/OasProvider.js.map +1 -0
  222. package/dist/lib/plugins/openapi/OperationList.d.ts +5 -2
  223. package/dist/lib/plugins/openapi/OperationList.js +85 -51
  224. package/dist/lib/plugins/openapi/OperationList.js.map +1 -1
  225. package/dist/lib/plugins/openapi/OperationListItem.d.ts +5 -3
  226. package/dist/lib/plugins/openapi/OperationListItem.js +10 -5
  227. package/dist/lib/plugins/openapi/OperationListItem.js.map +1 -1
  228. package/dist/lib/plugins/openapi/ParamInfos.d.ts +6 -0
  229. package/dist/lib/plugins/openapi/ParamInfos.js +42 -0
  230. package/dist/lib/plugins/openapi/ParamInfos.js.map +1 -0
  231. package/dist/lib/plugins/openapi/ParameterList.d.ts +2 -1
  232. package/dist/lib/plugins/openapi/ParameterList.js +3 -2
  233. package/dist/lib/plugins/openapi/ParameterList.js.map +1 -1
  234. package/dist/lib/plugins/openapi/ParameterListItem.js +8 -3
  235. package/dist/lib/plugins/openapi/ParameterListItem.js.map +1 -1
  236. package/dist/lib/plugins/openapi/PlaygroundDialogWrapper.d.ts +4 -2
  237. package/dist/lib/plugins/openapi/PlaygroundDialogWrapper.js +12 -3
  238. package/dist/lib/plugins/openapi/PlaygroundDialogWrapper.js.map +1 -1
  239. package/dist/lib/plugins/openapi/RequestBodySidecarBox.d.ts +3 -4
  240. package/dist/lib/plugins/openapi/RequestBodySidecarBox.js +5 -13
  241. package/dist/lib/plugins/openapi/RequestBodySidecarBox.js.map +1 -1
  242. package/dist/lib/plugins/openapi/ResponsesSidecarBox.js +7 -13
  243. package/dist/lib/plugins/openapi/ResponsesSidecarBox.js.map +1 -1
  244. package/dist/lib/plugins/openapi/SchemaList.d.ts +1 -0
  245. package/dist/lib/plugins/openapi/SchemaList.js +52 -0
  246. package/dist/lib/plugins/openapi/SchemaList.js.map +1 -0
  247. package/dist/lib/plugins/openapi/Sidecar.js +53 -36
  248. package/dist/lib/plugins/openapi/Sidecar.js.map +1 -1
  249. package/dist/lib/plugins/openapi/SidecarBox.js +4 -4
  250. package/dist/lib/plugins/openapi/SidecarBox.js.map +1 -1
  251. package/dist/lib/plugins/openapi/SidecarExamples.d.ts +9 -0
  252. package/dist/lib/plugins/openapi/SidecarExamples.js +68 -0
  253. package/dist/lib/plugins/openapi/SidecarExamples.js.map +1 -0
  254. package/dist/lib/plugins/openapi/SimpleSelect.js +1 -1
  255. package/dist/lib/plugins/openapi/SimpleSelect.js.map +1 -1
  256. package/dist/lib/plugins/openapi/client/GraphQLClient.d.ts +2 -2
  257. package/dist/lib/plugins/openapi/client/GraphQLClient.js +23 -94
  258. package/dist/lib/plugins/openapi/client/GraphQLClient.js.map +1 -1
  259. package/dist/lib/plugins/openapi/client/createServer.d.ts +2 -1
  260. package/dist/lib/plugins/openapi/client/createServer.js +5 -2
  261. package/dist/lib/plugins/openapi/client/createServer.js.map +1 -1
  262. package/dist/lib/plugins/openapi/client/useCreateQuery.d.ts +6 -2
  263. package/dist/lib/plugins/openapi/client/useCreateQuery.js +6 -7
  264. package/dist/lib/plugins/openapi/client/useCreateQuery.js.map +1 -1
  265. package/dist/lib/plugins/openapi/components/EnumValues.d.ts +5 -0
  266. package/dist/lib/plugins/openapi/components/EnumValues.js +15 -0
  267. package/dist/lib/plugins/openapi/components/EnumValues.js.map +1 -0
  268. package/dist/lib/plugins/openapi/components/SelectOnClick.d.ts +5 -0
  269. package/dist/lib/plugins/openapi/components/SelectOnClick.js +16 -0
  270. package/dist/lib/plugins/openapi/components/SelectOnClick.js.map +1 -0
  271. package/dist/lib/plugins/openapi/context.d.ts +3 -3
  272. package/dist/lib/plugins/openapi/graphql/gql.d.ts +11 -3
  273. package/dist/lib/plugins/openapi/graphql/gql.js +5 -14
  274. package/dist/lib/plugins/openapi/graphql/gql.js.map +1 -1
  275. package/dist/lib/plugins/openapi/graphql/graphql.d.ts +112 -22
  276. package/dist/lib/plugins/openapi/graphql/graphql.js +54 -11
  277. package/dist/lib/plugins/openapi/graphql/graphql.js.map +1 -1
  278. package/dist/lib/plugins/openapi/index.d.ts +10 -6
  279. package/dist/lib/plugins/openapi/index.js +63 -82
  280. package/dist/lib/plugins/openapi/index.js.map +1 -1
  281. package/dist/lib/plugins/openapi/interfaces.d.ts +56 -3
  282. package/dist/lib/plugins/openapi/playground/ExamplesDropdown.d.ts +6 -0
  283. package/dist/lib/plugins/openapi/playground/ExamplesDropdown.js +8 -0
  284. package/dist/lib/plugins/openapi/playground/ExamplesDropdown.js.map +1 -0
  285. package/dist/lib/plugins/openapi/playground/Headers.d.ts +4 -4
  286. package/dist/lib/plugins/openapi/playground/Headers.js +84 -5
  287. package/dist/lib/plugins/openapi/playground/Headers.js.map +1 -1
  288. package/dist/lib/plugins/openapi/playground/IdentityDialog.d.ts +11 -0
  289. package/dist/lib/plugins/openapi/playground/IdentityDialog.js +14 -0
  290. package/dist/lib/plugins/openapi/playground/IdentityDialog.js.map +1 -0
  291. package/dist/lib/plugins/openapi/playground/IdentitySelector.d.ts +7 -0
  292. package/dist/lib/plugins/openapi/playground/IdentitySelector.js +10 -0
  293. package/dist/lib/plugins/openapi/playground/IdentitySelector.js.map +1 -0
  294. package/dist/lib/plugins/openapi/playground/ParamsGrid.d.ts +9 -0
  295. package/dist/lib/plugins/openapi/playground/ParamsGrid.js +5 -0
  296. package/dist/lib/plugins/openapi/playground/ParamsGrid.js.map +1 -0
  297. package/dist/lib/plugins/openapi/playground/PathParams.d.ts +3 -2
  298. package/dist/lib/plugins/openapi/playground/PathParams.js +5 -7
  299. package/dist/lib/plugins/openapi/playground/PathParams.js.map +1 -1
  300. package/dist/lib/plugins/openapi/playground/Playground.d.ts +37 -2
  301. package/dist/lib/plugins/openapi/playground/Playground.js +131 -69
  302. package/dist/lib/plugins/openapi/playground/Playground.js.map +1 -1
  303. package/dist/lib/plugins/openapi/playground/PlaygroundDialog.js +1 -1
  304. package/dist/lib/plugins/openapi/playground/PlaygroundDialog.js.map +1 -1
  305. package/dist/lib/plugins/openapi/playground/QueryParams.js +24 -18
  306. package/dist/lib/plugins/openapi/playground/QueryParams.js.map +1 -1
  307. package/dist/lib/plugins/openapi/playground/RequestLoginDialog.d.ts +7 -0
  308. package/dist/lib/plugins/openapi/playground/RequestLoginDialog.js +8 -0
  309. package/dist/lib/plugins/openapi/playground/RequestLoginDialog.js.map +1 -0
  310. package/dist/lib/plugins/openapi/playground/SubmitButton.d.ts +7 -0
  311. package/dist/lib/plugins/openapi/playground/SubmitButton.js +22 -0
  312. package/dist/lib/plugins/openapi/playground/SubmitButton.js.map +1 -0
  313. package/dist/lib/plugins/openapi/playground/rememberedIdentity.d.ts +17 -0
  314. package/dist/lib/plugins/openapi/playground/rememberedIdentity.js +11 -0
  315. package/dist/lib/plugins/openapi/playground/rememberedIdentity.js.map +1 -0
  316. package/dist/lib/plugins/openapi/playground/result-panel/RequestTab.d.ts +7 -0
  317. package/dist/lib/plugins/openapi/playground/result-panel/RequestTab.js +11 -0
  318. package/dist/lib/plugins/openapi/playground/result-panel/RequestTab.js.map +1 -0
  319. package/dist/lib/plugins/openapi/playground/result-panel/ResponseTab.d.ts +8 -0
  320. package/dist/lib/plugins/openapi/playground/result-panel/ResponseTab.js +101 -0
  321. package/dist/lib/plugins/openapi/playground/result-panel/ResponseTab.js.map +1 -0
  322. package/dist/lib/plugins/openapi/playground/result-panel/ResultPanel.d.ts +9 -0
  323. package/dist/lib/plugins/openapi/playground/result-panel/ResultPanel.js +17 -0
  324. package/dist/lib/plugins/openapi/playground/result-panel/ResultPanel.js.map +1 -0
  325. package/dist/lib/plugins/openapi/playground/result-panel/convertToTypes.d.ts +10 -0
  326. package/dist/lib/plugins/openapi/playground/result-panel/convertToTypes.js +32 -0
  327. package/dist/lib/plugins/openapi/playground/result-panel/convertToTypes.js.map +1 -0
  328. package/dist/lib/plugins/openapi/playground/result-panel/convertToTypes.test.d.ts +1 -0
  329. package/dist/lib/plugins/openapi/playground/result-panel/convertToTypes.test.js +56 -0
  330. package/dist/lib/plugins/openapi/playground/result-panel/convertToTypes.test.js.map +1 -0
  331. package/dist/lib/plugins/openapi/post-processors/removeExtensions.d.ts +2 -1
  332. package/dist/lib/plugins/openapi/post-processors/removeExtensions.js +5 -3
  333. package/dist/lib/plugins/openapi/post-processors/removeExtensions.js.map +1 -1
  334. package/dist/lib/plugins/openapi/post-processors/removeExtensions.test.js +49 -0
  335. package/dist/lib/plugins/openapi/post-processors/removeExtensions.test.js.map +1 -1
  336. package/dist/lib/plugins/openapi/post-processors/removeParameters.d.ts +10 -0
  337. package/dist/lib/plugins/openapi/post-processors/removeParameters.js +66 -0
  338. package/dist/lib/plugins/openapi/post-processors/removeParameters.js.map +1 -0
  339. package/dist/lib/plugins/openapi/post-processors/removeParameters.test.d.ts +1 -0
  340. package/dist/lib/plugins/openapi/post-processors/removeParameters.test.js +131 -0
  341. package/dist/lib/plugins/openapi/post-processors/removeParameters.test.js.map +1 -0
  342. package/dist/lib/plugins/openapi/schema/SchemaPropertyItem.js +39 -0
  343. package/dist/lib/plugins/openapi/schema/SchemaPropertyItem.js.map +1 -0
  344. package/dist/lib/plugins/openapi/schema/SchemaView.js +14 -7
  345. package/dist/lib/plugins/openapi/schema/SchemaView.js.map +1 -1
  346. package/dist/lib/plugins/openapi/schema/utils.d.ts +1 -0
  347. package/dist/lib/plugins/openapi/schema/utils.js +2 -0
  348. package/dist/lib/plugins/openapi/schema/utils.js.map +1 -1
  349. package/dist/lib/plugins/openapi/state.d.ts +25 -0
  350. package/dist/lib/plugins/openapi/state.js +18 -0
  351. package/dist/lib/plugins/openapi/state.js.map +1 -0
  352. package/dist/lib/plugins/openapi/util/createSidebarCategory.d.ts +9 -0
  353. package/dist/lib/plugins/openapi/util/createSidebarCategory.js +23 -0
  354. package/dist/lib/plugins/openapi/util/createSidebarCategory.js.map +1 -0
  355. package/dist/lib/plugins/openapi/util/generateSchemaExample.js +19 -11
  356. package/dist/lib/plugins/openapi/util/generateSchemaExample.js.map +1 -1
  357. package/dist/lib/plugins/openapi/util/getRoutes.d.ts +10 -0
  358. package/dist/lib/plugins/openapi/util/getRoutes.js +80 -0
  359. package/dist/lib/plugins/openapi/util/getRoutes.js.map +1 -0
  360. package/dist/lib/plugins/openapi/util/methodColorMap.d.ts +2 -0
  361. package/dist/lib/plugins/openapi/util/methodColorMap.js +10 -0
  362. package/dist/lib/plugins/openapi/util/methodColorMap.js.map +1 -0
  363. package/dist/lib/plugins/openapi/util/methodToColor.d.ts +20 -0
  364. package/dist/lib/plugins/openapi/util/methodToColor.js +24 -0
  365. package/dist/lib/plugins/openapi/util/methodToColor.js.map +1 -0
  366. package/dist/lib/plugins/openapi/util/sanitizeMarkdownForMetatag.d.ts +1 -0
  367. package/dist/lib/plugins/openapi/util/sanitizeMarkdownForMetatag.js +27 -0
  368. package/dist/lib/plugins/openapi/util/sanitizeMarkdownForMetatag.js.map +1 -0
  369. package/dist/lib/plugins/search-inkeep/index.js +21 -7
  370. package/dist/lib/plugins/search-inkeep/index.js.map +1 -1
  371. package/dist/lib/plugins/search-pagefind/PagefindSearch.d.ts +6 -0
  372. package/dist/lib/plugins/search-pagefind/PagefindSearch.js +75 -0
  373. package/dist/lib/plugins/search-pagefind/PagefindSearch.js.map +1 -0
  374. package/dist/lib/plugins/search-pagefind/ResultList.d.ts +8 -0
  375. package/dist/lib/plugins/search-pagefind/ResultList.js +38 -0
  376. package/dist/lib/plugins/search-pagefind/ResultList.js.map +1 -0
  377. package/dist/lib/plugins/search-pagefind/get-results.d.ts +10 -0
  378. package/dist/lib/plugins/search-pagefind/get-results.js +42 -0
  379. package/dist/lib/plugins/search-pagefind/get-results.js.map +1 -0
  380. package/dist/lib/plugins/search-pagefind/index.d.ts +8 -0
  381. package/dist/lib/plugins/search-pagefind/index.js +9 -0
  382. package/dist/lib/plugins/search-pagefind/index.js.map +1 -0
  383. package/dist/lib/plugins/search-pagefind/types.d.ts +85 -0
  384. package/dist/lib/plugins/search-pagefind/types.js +2 -0
  385. package/dist/lib/plugins/search-pagefind/types.js.map +1 -0
  386. package/dist/lib/ui/Badge.d.ts +1 -1
  387. package/dist/lib/ui/Badge.js +2 -1
  388. package/dist/lib/ui/Badge.js.map +1 -1
  389. package/dist/lib/ui/Button.d.ts +2 -2
  390. package/dist/lib/ui/Button.js +2 -1
  391. package/dist/lib/ui/Button.js.map +1 -1
  392. package/dist/lib/ui/Callout.d.ts +2 -1
  393. package/dist/lib/ui/Callout.js +3 -2
  394. package/dist/lib/ui/Callout.js.map +1 -1
  395. package/dist/lib/ui/Card.js +1 -1
  396. package/dist/lib/ui/Card.js.map +1 -1
  397. package/dist/lib/ui/Checkbox.js +1 -1
  398. package/dist/lib/ui/Checkbox.js.map +1 -1
  399. package/dist/lib/ui/Command.d.ts +16 -2
  400. package/dist/lib/ui/Command.js +7 -3
  401. package/dist/lib/ui/Command.js.map +1 -1
  402. package/dist/lib/ui/Input.d.ts +1 -2
  403. package/dist/lib/ui/Input.js.map +1 -1
  404. package/dist/lib/ui/Select.js +3 -3
  405. package/dist/lib/ui/Select.js.map +1 -1
  406. package/dist/lib/ui/Stepper.d.ts +3 -0
  407. package/dist/lib/ui/Stepper.js +7 -0
  408. package/dist/lib/ui/Stepper.js.map +1 -0
  409. package/dist/lib/ui/SyntaxHighlight.d.ts +15 -0
  410. package/dist/lib/ui/SyntaxHighlight.js +62 -0
  411. package/dist/lib/ui/SyntaxHighlight.js.map +1 -0
  412. package/dist/lib/ui/util.d.ts +2 -0
  413. package/dist/lib/ui/util.js +3 -0
  414. package/dist/lib/ui/util.js.map +1 -0
  415. package/dist/lib/util/MdxComponents.d.ts +5 -2
  416. package/dist/lib/util/MdxComponents.js +8 -5
  417. package/dist/lib/util/MdxComponents.js.map +1 -1
  418. package/dist/lib/util/joinPath.d.ts +3 -0
  419. package/dist/lib/util/joinPath.js +3 -0
  420. package/dist/lib/util/joinPath.js.map +1 -1
  421. package/dist/lib/util/joinUrl.d.ts +1 -0
  422. package/dist/lib/util/joinUrl.js +40 -0
  423. package/dist/lib/util/joinUrl.js.map +1 -0
  424. package/dist/lib/util/joinUrl.test.d.ts +1 -0
  425. package/dist/lib/util/joinUrl.test.js +43 -0
  426. package/dist/lib/util/joinUrl.test.js.map +1 -0
  427. package/dist/lib/util/scrollIntoViewIfNeeded.d.ts +1 -0
  428. package/dist/lib/util/scrollIntoViewIfNeeded.js +14 -0
  429. package/dist/lib/util/scrollIntoViewIfNeeded.js.map +1 -0
  430. package/dist/lib/util/traverse.d.ts +3 -2
  431. package/dist/lib/util/traverse.js +9 -5
  432. package/dist/lib/util/traverse.js.map +1 -1
  433. package/dist/lib/util/types.d.ts +7 -0
  434. package/dist/lib/util/types.js +2 -0
  435. package/dist/lib/util/types.js.map +1 -0
  436. package/dist/lib/util/useLatest.d.ts +1 -0
  437. package/dist/lib/util/useLatest.js +15 -0
  438. package/dist/lib/util/useLatest.js.map +1 -0
  439. package/dist/lib/util/useOnScreen.d.ts +3 -2
  440. package/dist/lib/util/useOnScreen.js +3 -3
  441. package/dist/lib/util/useOnScreen.js.map +1 -1
  442. package/dist/lib/util/useScrollToAnchor.d.ts +1 -0
  443. package/dist/lib/util/useScrollToAnchor.js +41 -36
  444. package/dist/lib/util/useScrollToAnchor.js.map +1 -1
  445. package/dist/lib/util/useScrollToTop.js +6 -4
  446. package/dist/lib/util/useScrollToTop.js.map +1 -1
  447. package/dist/vite/api/schema-codegen.d.ts +12 -0
  448. package/dist/vite/api/schema-codegen.js +81 -0
  449. package/dist/vite/api/schema-codegen.js.map +1 -0
  450. package/dist/vite/api/schema-codegen.test.d.ts +1 -0
  451. package/dist/vite/api/schema-codegen.test.js +313 -0
  452. package/dist/vite/api/schema-codegen.test.js.map +1 -0
  453. package/dist/vite/build.js +46 -25
  454. package/dist/vite/build.js.map +1 -1
  455. package/dist/vite/config.d.ts +2 -5
  456. package/dist/vite/config.js +63 -64
  457. package/dist/vite/config.js.map +1 -1
  458. package/dist/vite/config.test.js +5 -1
  459. package/dist/vite/config.test.js.map +1 -1
  460. package/dist/vite/create-pagefind-index.d.ts +4 -0
  461. package/dist/vite/create-pagefind-index.js +12 -0
  462. package/dist/vite/create-pagefind-index.js.map +1 -0
  463. package/dist/vite/css/plugin.d.ts +2 -2
  464. package/dist/vite/css/plugin.js.map +1 -1
  465. package/dist/vite/dev-server.d.ts +5 -2
  466. package/dist/vite/dev-server.js +49 -12
  467. package/dist/vite/dev-server.js.map +1 -1
  468. package/dist/vite/error-handler.d.ts +1 -1
  469. package/dist/vite/error-handler.js +1 -1
  470. package/dist/vite/error-handler.js.map +1 -1
  471. package/dist/vite/output.d.ts +14 -2
  472. package/dist/vite/output.js +12 -14
  473. package/dist/vite/output.js.map +1 -1
  474. package/dist/vite/plugin-api-keys.d.ts +2 -2
  475. package/dist/vite/plugin-api-keys.js +5 -5
  476. package/dist/vite/plugin-api-keys.js.map +1 -1
  477. package/dist/vite/plugin-api.d.ts +2 -2
  478. package/dist/vite/plugin-api.js +179 -59
  479. package/dist/vite/plugin-api.js.map +1 -1
  480. package/dist/vite/plugin-auth.d.ts +2 -2
  481. package/dist/vite/plugin-auth.js +7 -4
  482. package/dist/vite/plugin-auth.js.map +1 -1
  483. package/dist/vite/plugin-component.d.ts +2 -2
  484. package/dist/vite/plugin-component.js +7 -3
  485. package/dist/vite/plugin-component.js.map +1 -1
  486. package/dist/vite/plugin-config-reload.d.ts +4 -3
  487. package/dist/vite/plugin-config-reload.js +11 -5
  488. package/dist/vite/plugin-config-reload.js.map +1 -1
  489. package/dist/vite/plugin-config.d.ts +2 -2
  490. package/dist/vite/plugin-config.js +9 -5
  491. package/dist/vite/plugin-config.js.map +1 -1
  492. package/dist/vite/plugin-custom-pages.d.ts +2 -2
  493. package/dist/vite/plugin-custom-pages.js +3 -3
  494. package/dist/vite/plugin-custom-pages.js.map +1 -1
  495. package/dist/vite/plugin-docs.d.ts +3 -3
  496. package/dist/vite/plugin-docs.js +23 -6
  497. package/dist/vite/plugin-docs.js.map +1 -1
  498. package/dist/vite/plugin-frontmatter.d.ts +2 -2
  499. package/dist/vite/plugin-frontmatter.js +5 -4
  500. package/dist/vite/plugin-frontmatter.js.map +1 -1
  501. package/dist/vite/plugin-mdx.d.ts +2 -2
  502. package/dist/vite/plugin-mdx.js +34 -18
  503. package/dist/vite/plugin-mdx.js.map +1 -1
  504. package/dist/vite/plugin-redirect.d.ts +2 -2
  505. package/dist/vite/plugin-redirect.js +3 -3
  506. package/dist/vite/plugin-redirect.js.map +1 -1
  507. package/dist/vite/plugin-search.d.ts +2 -2
  508. package/dist/vite/plugin-search.js +5 -1
  509. package/dist/vite/plugin-search.js.map +1 -1
  510. package/dist/vite/plugin-sidebar.d.ts +2 -2
  511. package/dist/vite/plugin-sidebar.js +13 -4
  512. package/dist/vite/plugin-sidebar.js.map +1 -1
  513. package/dist/vite/plugin-theme-css.d.ts +2 -2
  514. package/dist/vite/plugin-theme-css.js +57 -2
  515. package/dist/vite/plugin-theme-css.js.map +1 -1
  516. package/dist/vite/plugin.d.ts +2 -2
  517. package/dist/vite/plugin.js.map +1 -1
  518. package/dist/vite/{prerender.d.ts → prerender/FileWritingResponse.d.ts} +8 -9
  519. package/dist/vite/prerender/FileWritingResponse.js +51 -0
  520. package/dist/vite/prerender/FileWritingResponse.js.map +1 -0
  521. package/dist/vite/prerender/prerender.d.ts +14 -0
  522. package/dist/vite/prerender/prerender.js +90 -0
  523. package/dist/vite/prerender/prerender.js.map +1 -0
  524. package/dist/vite/prerender/worker.d.ts +13 -0
  525. package/dist/vite/prerender/worker.js +31 -0
  526. package/dist/vite/prerender/worker.js.map +1 -0
  527. package/dist/vite/reporter.d.ts +3 -0
  528. package/dist/vite/reporter.js +33 -0
  529. package/dist/vite/reporter.js.map +1 -0
  530. package/dist/vite/sitemap.js +2 -1
  531. package/dist/vite/sitemap.js.map +1 -1
  532. package/dist/zuplo/enrich-with-zuplo.d.ts +5 -0
  533. package/dist/zuplo/enrich-with-zuplo.js +184 -0
  534. package/dist/zuplo/enrich-with-zuplo.js.map +1 -0
  535. package/dist/zuplo/env.d.ts +1 -0
  536. package/dist/zuplo/env.js +3 -0
  537. package/dist/zuplo/env.js.map +1 -1
  538. package/dist/zuplo/policy-types.d.ts +33 -0
  539. package/dist/zuplo/policy-types.js +8 -0
  540. package/dist/zuplo/policy-types.js.map +1 -0
  541. package/dist/zuplo/with-zuplo-processors.d.ts +3 -0
  542. package/dist/zuplo/with-zuplo-processors.js +26 -0
  543. package/dist/zuplo/with-zuplo-processors.js.map +1 -0
  544. package/dist/zuplo/with-zuplo.d.ts +1 -1
  545. package/dist/zuplo/with-zuplo.js +7 -26
  546. package/dist/zuplo/with-zuplo.js.map +1 -1
  547. package/lib/AuthenticationPlugin-foqdvvkf.js +58 -0
  548. package/lib/AuthenticationPlugin-foqdvvkf.js.map +1 -0
  549. package/lib/{Button-DeAoTouo.js → Button-Fp19CMUr.js} +14 -13
  550. package/lib/Button-Fp19CMUr.js.map +1 -0
  551. package/lib/Callout-D5frCCJ0.js +229 -0
  552. package/lib/Callout-D5frCCJ0.js.map +1 -0
  553. package/lib/{CategoryHeading-CBconmtI.js → CategoryHeading-DpB47wvk.js} +2 -2
  554. package/lib/{CategoryHeading-CBconmtI.js.map → CategoryHeading-DpB47wvk.js.map} +1 -1
  555. package/lib/Dialog-Dv6WG8RN.js +98 -0
  556. package/lib/{Dialog-Bxv1yEIg.js.map → Dialog-Dv6WG8RN.js.map} +1 -1
  557. package/lib/Drawer-kDAfOq_2.js +1133 -0
  558. package/lib/Drawer-kDAfOq_2.js.map +1 -0
  559. package/lib/{Markdown-CZDLNOFc.js → Markdown-D-vLL3rw.js} +8177 -6419
  560. package/lib/Markdown-D-vLL3rw.js.map +1 -0
  561. package/lib/MdxPage-BY6tJN4Q.js +83 -0
  562. package/lib/MdxPage-BY6tJN4Q.js.map +1 -0
  563. package/lib/OasProvider-5ej8C_s6.js +34 -0
  564. package/lib/OasProvider-5ej8C_s6.js.map +1 -0
  565. package/lib/OperationList-CHuBrSD5.js +5060 -0
  566. package/lib/OperationList-CHuBrSD5.js.map +1 -0
  567. package/lib/Pagination-DALsKi79.js +46 -0
  568. package/lib/Pagination-DALsKi79.js.map +1 -0
  569. package/lib/SchemaList-BH1kPaT4.js +148 -0
  570. package/lib/SchemaList-BH1kPaT4.js.map +1 -0
  571. package/lib/SchemaView-6_qdGR_9.js +356 -0
  572. package/lib/SchemaView-6_qdGR_9.js.map +1 -0
  573. package/lib/{Select-Bb_Hqc70.js → Select-DVFRKf1R.js} +52 -52
  574. package/lib/Select-DVFRKf1R.js.map +1 -0
  575. package/lib/SlotletProvider-BPQNhW3Y.js +338 -0
  576. package/lib/SlotletProvider-BPQNhW3Y.js.map +1 -0
  577. package/lib/{Spinner-DuxJLLNE.js → Spinner-CE68iCm0.js} +2 -2
  578. package/lib/{Spinner-DuxJLLNE.js.map → Spinner-CE68iCm0.js.map} +1 -1
  579. package/lib/{SyntaxHighlight-Bz-lOJtH.js → SyntaxHighlight-BEoSoPEo.js} +551 -640
  580. package/lib/SyntaxHighlight-BEoSoPEo.js.map +1 -0
  581. package/lib/Toc-COKWpWOX.js +92 -0
  582. package/lib/Toc-COKWpWOX.js.map +1 -0
  583. package/lib/chunk-HA7DTUK3-C4gP41vD.js +1821 -0
  584. package/lib/chunk-HA7DTUK3-C4gP41vD.js.map +1 -0
  585. package/lib/circular-ByJI6Mci.js +15877 -0
  586. package/lib/circular-ByJI6Mci.js.map +1 -0
  587. package/lib/cn-qaFjX9_3.js.map +1 -1
  588. package/lib/{context-h_UkBLvr.js → context-DLCwaMXN.js} +2 -2
  589. package/lib/context-DLCwaMXN.js.map +1 -0
  590. package/lib/createServer-mMau3eV_.js +12428 -0
  591. package/lib/createServer-mMau3eV_.js.map +1 -0
  592. package/lib/hook-CqpVYDqN.js +1483 -0
  593. package/lib/hook-CqpVYDqN.js.map +1 -0
  594. package/lib/index-CFrxHpoy.js +2514 -0
  595. package/lib/index-CFrxHpoy.js.map +1 -0
  596. package/lib/index-DGMVODgw.js +2226 -0
  597. package/lib/index-DGMVODgw.js.map +1 -0
  598. package/lib/{index-CBXSgjaE.js → index-Dl3Yl0yb.js} +65 -69
  599. package/lib/index-Dl3Yl0yb.js.map +1 -0
  600. package/lib/index-DwT-v3zK.js +86 -0
  601. package/lib/index-DwT-v3zK.js.map +1 -0
  602. package/lib/index-gQD2h1wX.js +447 -0
  603. package/lib/index-gQD2h1wX.js.map +1 -0
  604. package/lib/index.esm--gIChbWs.js +1207 -0
  605. package/lib/index.esm--gIChbWs.js.map +1 -0
  606. package/lib/{jsx-runtime-Dx-03ztt.js → jsx-runtime-CYK1ROHF.js} +95 -95
  607. package/lib/{jsx-runtime-Dx-03ztt.js.map → jsx-runtime-CYK1ROHF.js.map} +1 -1
  608. package/lib/{hook-DMHiUaIV.js → mutation-8LjrN7uz.js} +39 -58
  609. package/lib/mutation-8LjrN7uz.js.map +1 -0
  610. package/lib/objectEntries-BS7aAgOm.js +12 -0
  611. package/lib/objectEntries-BS7aAgOm.js.map +1 -0
  612. package/lib/post-processors/removeExtensions.js +7 -7
  613. package/lib/post-processors/removeExtensions.js.map +1 -1
  614. package/lib/post-processors/removeParameters.js +48 -0
  615. package/lib/post-processors/removeParameters.js.map +1 -0
  616. package/lib/post-processors/traverse.js +11 -8
  617. package/lib/post-processors/traverse.js.map +1 -1
  618. package/lib/{prism-bash.min-DadFsM4Z.js → prism-bash.min-HHIMdNJ_.js} +4 -4
  619. package/lib/{prism-bash.min-DadFsM4Z.js.map → prism-bash.min-HHIMdNJ_.js.map} +1 -1
  620. package/lib/{prism-csharp.min-DUwvItt4.js → prism-csharp.min-bQAo2pmx.js} +33 -33
  621. package/lib/{prism-csharp.min-DUwvItt4.js.map → prism-csharp.min-bQAo2pmx.js.map} +1 -1
  622. package/lib/{prism-java.min-BtgBR4yd.js → prism-java.min-BpvsOuIa.js} +12 -12
  623. package/lib/{prism-java.min-BtgBR4yd.js.map → prism-java.min-BpvsOuIa.js.map} +1 -1
  624. package/lib/prism-javascript.min-CEqHqgbm.js.map +1 -1
  625. package/lib/prism-json.min-B1GJqK1k.js.map +1 -1
  626. package/lib/prism-jsstacktrace.min-BfobCF2F.js +2 -0
  627. package/lib/prism-jsstacktrace.min-BfobCF2F.js.map +1 -0
  628. package/lib/{prism-markdown.min-F3U-vPBi.js → prism-markdown.min-C0Qn0m-5.js} +30 -30
  629. package/lib/{prism-markdown.min-F3U-vPBi.js.map → prism-markdown.min-C0Qn0m-5.js.map} +1 -1
  630. package/lib/prism-markup-BNGj0Tvm.js.map +1 -1
  631. package/lib/prism-objectivec.min-BXSWqpJJ.js.map +1 -1
  632. package/lib/{prism-ruby.min-DeDXCp1r.js → prism-ruby.min-Dx9KO9ds.js} +16 -16
  633. package/lib/{prism-ruby.min-DeDXCp1r.js.map → prism-ruby.min-Dx9KO9ds.js.map} +1 -1
  634. package/lib/prism-typescript.min-CD7H2IYQ.js.map +1 -1
  635. package/lib/ui/Accordion.js +1 -1
  636. package/lib/ui/ActionButton.js +3 -3
  637. package/lib/ui/Alert.js +1 -1
  638. package/lib/ui/AlertDialog.js +1 -1
  639. package/lib/ui/Badge.js +3 -2
  640. package/lib/ui/Badge.js.map +1 -1
  641. package/lib/ui/Breadcrumb.js +4 -4
  642. package/lib/ui/Button.js +13 -12
  643. package/lib/ui/Button.js.map +1 -1
  644. package/lib/ui/Callout.js +39 -21
  645. package/lib/ui/Callout.js.map +1 -1
  646. package/lib/ui/Card.js +8 -8
  647. package/lib/ui/Card.js.map +1 -1
  648. package/lib/ui/Carousel.js +3 -3
  649. package/lib/ui/Carousel.js.map +1 -1
  650. package/lib/ui/Checkbox.js +14 -13
  651. package/lib/ui/Checkbox.js.map +1 -1
  652. package/lib/ui/Command.js +114 -511
  653. package/lib/ui/Command.js.map +1 -1
  654. package/lib/ui/Dialog.js +1 -1
  655. package/lib/ui/Drawer.js +14 -1150
  656. package/lib/ui/Drawer.js.map +1 -1
  657. package/lib/ui/DropdownMenu.js +1 -1
  658. package/lib/ui/Form.js +5 -5
  659. package/lib/ui/HoverCard.js +1 -1
  660. package/lib/ui/Input.js +1 -1
  661. package/lib/ui/Input.js.map +1 -1
  662. package/lib/ui/Label.js +1 -1
  663. package/lib/ui/Pagination.js +4 -4
  664. package/lib/ui/Popover.js +1 -1
  665. package/lib/ui/Progress.js +1 -1
  666. package/lib/ui/RadioGroup.js +1 -1
  667. package/lib/ui/ScrollArea.js +1 -1
  668. package/lib/ui/Select.js +4 -4
  669. package/lib/ui/Select.js.map +1 -1
  670. package/lib/ui/Skeleton.js +1 -1
  671. package/lib/ui/Slider.js +1 -1
  672. package/lib/ui/Stepper.js +6 -0
  673. package/lib/ui/Stepper.js.map +1 -0
  674. package/lib/ui/Switch.js +1 -1
  675. package/lib/ui/SyntaxHighlight.js +11 -0
  676. package/lib/ui/SyntaxHighlight.js.map +1 -0
  677. package/lib/ui/Tabs.js +1 -1
  678. package/lib/ui/Textarea.js +1 -1
  679. package/lib/ui/Toggle.js +1 -1
  680. package/lib/ui/ToggleGroup.js +1 -1
  681. package/lib/ui/Tooltip.js +1 -1
  682. package/lib/ui/util.js +6 -0
  683. package/lib/ui/util.js.map +1 -0
  684. package/lib/{useExposedProps-DE9lR6MF.js → useExposedProps-B9qXJedG.js} +2 -2
  685. package/lib/{useExposedProps-DE9lR6MF.js.map → useExposedProps-B9qXJedG.js.map} +1 -1
  686. package/lib/zudoku.auth-auth0.js +19 -20
  687. package/lib/zudoku.auth-auth0.js.map +1 -1
  688. package/lib/zudoku.auth-clerk.js +101 -55
  689. package/lib/zudoku.auth-clerk.js.map +1 -1
  690. package/lib/zudoku.auth-openid.js +349 -378
  691. package/lib/zudoku.auth-openid.js.map +1 -1
  692. package/lib/zudoku.components.js +31 -1395
  693. package/lib/zudoku.components.js.map +1 -1
  694. package/lib/zudoku.hooks.js +19 -0
  695. package/lib/zudoku.hooks.js.map +1 -0
  696. package/lib/zudoku.icons.js +10 -0
  697. package/lib/zudoku.icons.js.map +1 -1
  698. package/lib/zudoku.plugin-api-catalog.js +107 -109
  699. package/lib/zudoku.plugin-api-catalog.js.map +1 -1
  700. package/lib/zudoku.plugin-api-keys.js +108 -106
  701. package/lib/zudoku.plugin-api-keys.js.map +1 -1
  702. package/lib/zudoku.plugin-custom-pages.js +3 -3
  703. package/lib/zudoku.plugin-markdown.js +23 -44
  704. package/lib/zudoku.plugin-markdown.js.map +1 -1
  705. package/lib/zudoku.plugin-openapi.js +6 -6
  706. package/lib/zudoku.plugin-openapi.js.map +1 -1
  707. package/lib/zudoku.plugin-redirect.js +1 -1
  708. package/lib/zudoku.plugin-search-inkeep.js +34 -26
  709. package/lib/zudoku.plugin-search-inkeep.js.map +1 -1
  710. package/lib/zudoku.plugin-search-pagefind.js +238 -0
  711. package/lib/zudoku.plugin-search-pagefind.js.map +1 -0
  712. package/lib/zudoku.plugins.js +14 -0
  713. package/lib/zudoku.plugins.js.map +1 -0
  714. package/package.json +102 -79
  715. package/src/app/demo-cdn.html +31 -31
  716. package/src/app/demo.tsx +0 -1
  717. package/src/app/entry.client.tsx +8 -0
  718. package/src/app/entry.server.tsx +18 -11
  719. package/src/app/main.css +94 -39
  720. package/src/app/main.tsx +34 -9
  721. package/src/app/standalone.tsx +0 -1
  722. package/src/app/tailwind.ts +20 -0
  723. package/src/lib/MissingIcon.tsx +22 -0
  724. package/src/lib/authentication/authentication.ts +2 -0
  725. package/src/lib/authentication/components/SignOut.tsx +2 -1
  726. package/src/lib/authentication/hook.ts +12 -1
  727. package/src/lib/authentication/providers/auth0.tsx +4 -6
  728. package/src/lib/authentication/providers/clerk.tsx +70 -15
  729. package/src/lib/authentication/providers/openid.tsx +55 -25
  730. package/src/lib/authentication/providers/supabase.tsx +157 -0
  731. package/src/lib/authentication/state.ts +9 -19
  732. package/src/lib/components/AnchorLink.tsx +13 -8
  733. package/src/lib/components/Autocomplete.tsx +113 -0
  734. package/src/lib/components/Banner.tsx +1 -0
  735. package/src/lib/components/Header.tsx +22 -14
  736. package/src/lib/components/Heading.tsx +1 -1
  737. package/src/lib/components/InlineCode.tsx +13 -16
  738. package/src/lib/components/Layout.tsx +20 -67
  739. package/src/lib/components/Main.tsx +49 -0
  740. package/src/lib/components/Markdown.tsx +14 -15
  741. package/src/lib/components/MobileTopNavigation.tsx +1 -1
  742. package/src/lib/components/Pagination.tsx +47 -0
  743. package/src/lib/components/PathRenderer.tsx +61 -0
  744. package/src/lib/components/StatusPage.tsx +91 -0
  745. package/src/lib/components/ThemeSwitch.tsx +29 -9
  746. package/src/lib/components/TopNavigation.tsx +52 -25
  747. package/src/lib/components/Zudoku.tsx +18 -7
  748. package/src/lib/components/cache.ts +23 -0
  749. package/src/lib/components/context/RouterEventsEmitter.tsx +19 -0
  750. package/src/lib/components/context/ViewportAnchorContext.tsx +26 -21
  751. package/src/lib/components/context/ZudokuContext.ts +31 -9
  752. package/src/lib/components/index.ts +21 -4
  753. package/src/lib/components/navigation/Sidebar.tsx +14 -10
  754. package/src/lib/components/navigation/SidebarBadge.tsx +17 -12
  755. package/src/lib/components/navigation/SidebarCategory.tsx +54 -52
  756. package/src/lib/components/navigation/SidebarItem.tsx +22 -28
  757. package/src/lib/components/navigation/SidebarWrapper.tsx +13 -14
  758. package/src/lib/{plugins/markdown → components/navigation}/Toc.tsx +5 -14
  759. package/src/lib/core/RouteGuard.tsx +74 -0
  760. package/src/lib/core/ZudokuContext.ts +66 -20
  761. package/src/lib/core/plugins.ts +29 -7
  762. package/src/lib/errors/ErrorAlert.tsx +24 -17
  763. package/src/lib/hooks/index.ts +5 -0
  764. package/src/lib/hooks/useEvent.test.tsx +149 -0
  765. package/src/lib/hooks/useEvent.ts +41 -0
  766. package/src/lib/icons.ts +1 -0
  767. package/src/lib/oas/graphql/circular.ts +50 -0
  768. package/src/lib/oas/graphql/index.ts +291 -100
  769. package/src/lib/oas/parser/dereference/index.ts +10 -4
  770. package/src/lib/oas/parser/index.ts +7 -29
  771. package/src/lib/oas/parser/upgrade/index.ts +21 -5
  772. package/src/lib/plugins/api-catalog/Catalog.tsx +62 -110
  773. package/src/lib/plugins/api-catalog/index.tsx +69 -9
  774. package/src/lib/plugins/api-keys/CreateApiKey.tsx +7 -3
  775. package/src/lib/plugins/api-keys/index.tsx +3 -0
  776. package/src/lib/plugins/markdown/MdxPage.tsx +14 -39
  777. package/src/lib/plugins/markdown/resolver.ts +0 -33
  778. package/src/lib/plugins/openapi/CollapsibleCode.tsx +10 -7
  779. package/src/lib/plugins/openapi/ColorizedParam.tsx +29 -12
  780. package/src/lib/plugins/openapi/Endpoint.tsx +14 -12
  781. package/src/lib/plugins/openapi/OasProvider.tsx +51 -0
  782. package/src/lib/plugins/openapi/OperationList.tsx +207 -89
  783. package/src/lib/plugins/openapi/OperationListItem.tsx +131 -88
  784. package/src/lib/plugins/openapi/ParamInfos.tsx +87 -0
  785. package/src/lib/plugins/openapi/ParameterList.tsx +4 -0
  786. package/src/lib/plugins/openapi/ParameterListItem.tsx +33 -24
  787. package/src/lib/plugins/openapi/PlaygroundDialogWrapper.tsx +21 -2
  788. package/src/lib/plugins/openapi/RequestBodySidecarBox.tsx +15 -38
  789. package/src/lib/plugins/openapi/ResponsesSidecarBox.tsx +46 -63
  790. package/src/lib/plugins/openapi/SchemaList.tsx +151 -0
  791. package/src/lib/plugins/openapi/Sidecar.tsx +84 -64
  792. package/src/lib/plugins/openapi/SidecarBox.tsx +4 -16
  793. package/src/lib/plugins/openapi/SidecarExamples.tsx +162 -0
  794. package/src/lib/plugins/openapi/SimpleSelect.tsx +1 -1
  795. package/src/lib/plugins/openapi/client/GraphQLClient.tsx +29 -121
  796. package/src/lib/plugins/openapi/client/createServer.ts +6 -2
  797. package/src/lib/plugins/openapi/client/useCreateQuery.ts +13 -8
  798. package/src/lib/plugins/openapi/components/EnumValues.tsx +58 -0
  799. package/src/lib/plugins/openapi/components/SelectOnClick.tsx +29 -0
  800. package/src/lib/plugins/openapi/context.tsx +2 -2
  801. package/src/lib/plugins/openapi/graphql/gql.ts +36 -11
  802. package/src/lib/plugins/openapi/graphql/graphql.ts +170 -37
  803. package/src/lib/plugins/openapi/index.tsx +99 -98
  804. package/src/lib/plugins/openapi/interfaces.ts +57 -3
  805. package/src/lib/plugins/openapi/playground/ExamplesDropdown.tsx +52 -0
  806. package/src/lib/plugins/openapi/playground/Headers.tsx +165 -36
  807. package/src/lib/plugins/openapi/playground/IdentityDialog.tsx +74 -0
  808. package/src/lib/plugins/openapi/playground/IdentitySelector.tsx +54 -0
  809. package/src/lib/plugins/openapi/playground/ParamsGrid.tsx +13 -0
  810. package/src/lib/plugins/openapi/playground/PathParams.tsx +39 -65
  811. package/src/lib/plugins/openapi/playground/Playground.tsx +384 -244
  812. package/src/lib/plugins/openapi/playground/PlaygroundDialog.tsx +6 -3
  813. package/src/lib/plugins/openapi/playground/QueryParams.tsx +86 -88
  814. package/src/lib/plugins/openapi/playground/RequestLoginDialog.tsx +51 -0
  815. package/src/lib/plugins/openapi/playground/SubmitButton.tsx +75 -0
  816. package/src/lib/plugins/openapi/playground/rememberedIdentity.ts +26 -0
  817. package/src/lib/plugins/openapi/playground/result-panel/RequestTab.tsx +73 -0
  818. package/src/lib/plugins/openapi/playground/result-panel/ResponseTab.tsx +230 -0
  819. package/src/lib/plugins/openapi/playground/result-panel/ResultPanel.tsx +123 -0
  820. package/src/lib/plugins/openapi/playground/result-panel/convertToTypes.test.ts +64 -0
  821. package/src/lib/plugins/openapi/playground/result-panel/convertToTypes.ts +36 -0
  822. package/src/lib/plugins/openapi/post-processors/removeExtensions.test.ts +58 -0
  823. package/src/lib/plugins/openapi/post-processors/removeExtensions.ts +7 -4
  824. package/src/lib/plugins/openapi/post-processors/removeParameters.test.ts +148 -0
  825. package/src/lib/plugins/openapi/post-processors/removeParameters.ts +101 -0
  826. package/src/lib/plugins/openapi/schema/{SchemaComponents.tsx → SchemaPropertyItem.tsx} +52 -29
  827. package/src/lib/plugins/openapi/schema/SchemaView.tsx +52 -36
  828. package/src/lib/plugins/openapi/schema/utils.ts +4 -0
  829. package/src/lib/plugins/openapi/state.ts +36 -0
  830. package/src/lib/plugins/openapi/util/createSidebarCategory.tsx +37 -0
  831. package/src/lib/plugins/openapi/util/generateSchemaExample.ts +26 -11
  832. package/src/lib/plugins/openapi/util/getRoutes.tsx +126 -0
  833. package/src/lib/plugins/openapi/util/methodColorMap.tsx +11 -0
  834. package/src/lib/plugins/openapi/util/methodToColor.ts +27 -0
  835. package/src/lib/plugins/openapi/util/sanitizeMarkdownForMetatag.tsx +32 -0
  836. package/src/lib/plugins/search-inkeep/index.tsx +27 -8
  837. package/src/lib/plugins/search-pagefind/PagefindSearch.tsx +157 -0
  838. package/src/lib/plugins/search-pagefind/ResultList.tsx +116 -0
  839. package/src/lib/plugins/search-pagefind/get-results.tsx +75 -0
  840. package/src/lib/plugins/search-pagefind/index.tsx +21 -0
  841. package/src/lib/plugins/search-pagefind/types.ts +118 -0
  842. package/src/lib/ui/Badge.tsx +2 -1
  843. package/src/lib/ui/Button.tsx +4 -2
  844. package/src/lib/ui/Callout.tsx +28 -10
  845. package/src/lib/ui/Card.tsx +1 -1
  846. package/src/lib/ui/Checkbox.tsx +2 -1
  847. package/src/lib/ui/Command.tsx +45 -3
  848. package/src/lib/ui/Input.tsx +1 -2
  849. package/src/lib/ui/Select.tsx +2 -2
  850. package/src/lib/ui/Stepper.tsx +8 -0
  851. package/src/lib/ui/SyntaxHighlight.tsx +186 -0
  852. package/src/lib/ui/util.tsx +3 -0
  853. package/src/lib/util/MdxComponents.tsx +9 -5
  854. package/src/lib/util/joinPath.tsx +3 -0
  855. package/src/lib/util/joinUrl.test.ts +62 -0
  856. package/src/lib/util/joinUrl.ts +57 -0
  857. package/src/lib/util/scrollIntoViewIfNeeded.ts +18 -0
  858. package/src/lib/util/traverse.ts +15 -9
  859. package/src/lib/util/types.ts +7 -0
  860. package/src/lib/util/useLatest.ts +18 -0
  861. package/src/lib/util/useOnScreen.ts +6 -4
  862. package/src/lib/util/useScrollToAnchor.ts +47 -38
  863. package/src/lib/util/useScrollToTop.ts +8 -3
  864. package/dist/lib/components/SyntaxHighlight.d.ts +0 -11
  865. package/dist/lib/components/SyntaxHighlight.js +0 -53
  866. package/dist/lib/components/SyntaxHighlight.js.map +0 -1
  867. package/dist/lib/plugins/markdown/Toc.js.map +0 -1
  868. package/dist/lib/plugins/openapi/Route.d.ts +0 -6
  869. package/dist/lib/plugins/openapi/Route.js +0 -6
  870. package/dist/lib/plugins/openapi/Route.js.map +0 -1
  871. package/dist/lib/plugins/openapi/client/worker.d.ts +0 -4
  872. package/dist/lib/plugins/openapi/client/worker.js +0 -29
  873. package/dist/lib/plugins/openapi/client/worker.js.map +0 -1
  874. package/dist/lib/plugins/openapi/playground/ResponseTab.d.ts +0 -4
  875. package/dist/lib/plugins/openapi/playground/ResponseTab.js +0 -42
  876. package/dist/lib/plugins/openapi/playground/ResponseTab.js.map +0 -1
  877. package/dist/lib/plugins/openapi/schema/SchemaComponents.js +0 -28
  878. package/dist/lib/plugins/openapi/schema/SchemaComponents.js.map +0 -1
  879. package/dist/lib/plugins/openapi-worker.d.ts +0 -1
  880. package/dist/lib/plugins/openapi-worker.js +0 -8
  881. package/dist/lib/plugins/openapi-worker.js.map +0 -1
  882. package/dist/vite/prerender.js +0 -89
  883. package/dist/vite/prerender.js.map +0 -1
  884. package/lib/AnchorLink-DFZZbmvr.js +0 -34
  885. package/lib/AnchorLink-DFZZbmvr.js.map +0 -1
  886. package/lib/AuthenticationPlugin-DQy635W9.js +0 -58
  887. package/lib/AuthenticationPlugin-DQy635W9.js.map +0 -1
  888. package/lib/Button-DeAoTouo.js.map +0 -1
  889. package/lib/Dialog-Bxv1yEIg.js +0 -67
  890. package/lib/Markdown-CZDLNOFc.js.map +0 -1
  891. package/lib/MdxPage-CBa4X6L5.js +0 -188
  892. package/lib/MdxPage-CBa4X6L5.js.map +0 -1
  893. package/lib/OperationList-Bj-6EKhp.js +0 -4889
  894. package/lib/OperationList-Bj-6EKhp.js.map +0 -1
  895. package/lib/Route-C9cYcP-j.js +0 -11
  896. package/lib/Route-C9cYcP-j.js.map +0 -1
  897. package/lib/Select-Bb_Hqc70.js.map +0 -1
  898. package/lib/SidebarBadge-Bm793GDY.js +0 -51
  899. package/lib/SidebarBadge-Bm793GDY.js.map +0 -1
  900. package/lib/SlotletProvider-pfc9oejW.js +0 -221
  901. package/lib/SlotletProvider-pfc9oejW.js.map +0 -1
  902. package/lib/SyntaxHighlight-Bz-lOJtH.js.map +0 -1
  903. package/lib/__vite-browser-external-BYRIRx8p.js +0 -9
  904. package/lib/__vite-browser-external-BYRIRx8p.js.map +0 -1
  905. package/lib/assets/index-C7jnHK4b.js +0 -4841
  906. package/lib/assets/index-C7jnHK4b.js.map +0 -1
  907. package/lib/assets/worker-BmEAZjUP.js +0 -18527
  908. package/lib/assets/worker-BmEAZjUP.js.map +0 -1
  909. package/lib/chunk-D52XG6IA-Dl7HLe6j.js +0 -1823
  910. package/lib/chunk-D52XG6IA-Dl7HLe6j.js.map +0 -1
  911. package/lib/context-h_UkBLvr.js.map +0 -1
  912. package/lib/createServer-BVFp6Bl3.js +0 -15628
  913. package/lib/createServer-BVFp6Bl3.js.map +0 -1
  914. package/lib/hook-DMHiUaIV.js.map +0 -1
  915. package/lib/index-B6rTMjdI.js +0 -1279
  916. package/lib/index-B6rTMjdI.js.map +0 -1
  917. package/lib/index-CBXSgjaE.js.map +0 -1
  918. package/lib/index.esm-BSV1C092.js +0 -692
  919. package/lib/index.esm-BSV1C092.js.map +0 -1
  920. package/lib/index.esm-BnnBRKJX.js +0 -1214
  921. package/lib/index.esm-BnnBRKJX.js.map +0 -1
  922. package/lib/object_hash-BNWPnMN9.js +0 -787
  923. package/lib/object_hash-BNWPnMN9.js.map +0 -1
  924. package/lib/state-CFQsUZUP.js +0 -202
  925. package/lib/state-CFQsUZUP.js.map +0 -1
  926. package/lib/utils-R0j3Raw1.js +0 -1217
  927. package/lib/utils-R0j3Raw1.js.map +0 -1
  928. package/lib/zudoku.openapi-worker.js +0 -15
  929. package/lib/zudoku.openapi-worker.js.map +0 -1
  930. package/src/lib/components/SyntaxHighlight.tsx +0 -157
  931. package/src/lib/plugins/openapi/Route.tsx +0 -19
  932. package/src/lib/plugins/openapi/client/worker.ts +0 -44
  933. package/src/lib/plugins/openapi/playground/ResponseTab.tsx +0 -76
  934. package/src/lib/plugins/openapi-worker.ts +0 -11
  935. /package/dist/lib/{plugins/markdown → components/navigation}/Toc.d.ts +0 -0
  936. /package/dist/lib/plugins/openapi/schema/{SchemaComponents.d.ts → SchemaPropertyItem.d.ts} +0 -0
@@ -1,19 +1,19 @@
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 we } from "./jsx-runtime-Dx-03ztt.js";
5
- import { g as Oe } from "./_commonjsHelpers-BkfeUUK-.js";
6
- import { A as ze } from "./AuthenticationPlugin-DQy635W9.js";
7
- import { g as De } from "./utils-R0j3Raw1.js";
8
- import { N as Ne } from "./chunk-D52XG6IA-Dl7HLe6j.js";
9
- import { Z as Ke } from "./invariant-Caa8-XvF.js";
10
- import { u as L } from "./state-CFQsUZUP.js";
11
- var N = { exports: {} }, We = N.exports, ie;
12
- function He() {
13
- return ie || (ie = 1, function(t) {
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
14
  (function(e, n) {
15
15
  t.exports ? t.exports = n() : e.log = n();
16
- })(We, function() {
16
+ })(De, function() {
17
17
  var e = function() {
18
18
  }, n = "undefined", o = typeof window !== n && typeof window.navigator !== n && /Trident\/|MSIE /.test(window.navigator.userAgent), a = [
19
19
  "trace",
@@ -22,8 +22,8 @@ function He() {
22
22
  "warn",
23
23
  "error"
24
24
  ], r = {}, i = null;
25
- function c(l, g) {
26
- var u = l[g];
25
+ function c(l, m) {
26
+ var u = l[m];
27
27
  if (typeof u.bind == "function")
28
28
  return u.bind(l);
29
29
  try {
@@ -37,76 +37,76 @@ function He() {
37
37
  function p() {
38
38
  console.log && (console.log.apply ? console.log.apply(console, arguments) : Function.prototype.apply.apply(console.log, [console, arguments])), console.trace && console.trace();
39
39
  }
40
- function _(l) {
40
+ function w(l) {
41
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
42
  }
43
43
  function f() {
44
- for (var l = this.getLevel(), g = 0; g < a.length; g++) {
45
- var u = a[g];
46
- this[u] = g < l ? e : this.methodFactory(u, l, this.name);
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
47
  }
48
48
  if (this.log = this.debug, typeof console === n && l < this.levels.SILENT)
49
49
  return "No console available for logging";
50
50
  }
51
- function y(l) {
51
+ function v(l) {
52
52
  return function() {
53
53
  typeof console !== n && (f.call(this), this[l].apply(this, arguments));
54
54
  };
55
55
  }
56
- function T(l, g, u) {
57
- return _(l) || y.apply(this, arguments);
56
+ function _(l, m, u) {
57
+ return w(l) || v.apply(this, arguments);
58
58
  }
59
- function h(l, g) {
60
- var u = this, O, M, R, v = "loglevel";
61
- typeof l == "string" ? v += ":" + l : typeof l == "symbol" && (v = void 0);
62
- function xe(d) {
63
- var m = (a[d] || "silent").toUpperCase();
64
- if (!(typeof window === n || !v)) {
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
65
  try {
66
- window.localStorage[v] = m;
66
+ window.localStorage[S] = y;
67
67
  return;
68
68
  } catch {
69
69
  }
70
70
  try {
71
- window.document.cookie = encodeURIComponent(v) + "=" + m + ";";
71
+ window.document.cookie = encodeURIComponent(S) + "=" + y + ";";
72
72
  } catch {
73
73
  }
74
74
  }
75
75
  }
76
76
  function ne() {
77
77
  var d;
78
- if (!(typeof window === n || !v)) {
78
+ if (!(typeof window === n || !S)) {
79
79
  try {
80
- d = window.localStorage[v];
80
+ d = window.localStorage[S];
81
81
  } catch {
82
82
  }
83
83
  if (typeof d === n)
84
84
  try {
85
- var m = window.document.cookie, z = encodeURIComponent(v), oe = m.indexOf(z + "=");
85
+ var y = window.document.cookie, O = encodeURIComponent(S), oe = y.indexOf(O + "=");
86
86
  oe !== -1 && (d = /^([^;]+)/.exec(
87
- m.slice(oe + z.length + 1)
87
+ y.slice(oe + O.length + 1)
88
88
  )[1]);
89
89
  } catch {
90
90
  }
91
91
  return u.levels[d] === void 0 && (d = void 0), d;
92
92
  }
93
93
  }
94
- function Ce() {
95
- if (!(typeof window === n || !v)) {
94
+ function Pe() {
95
+ if (!(typeof window === n || !S)) {
96
96
  try {
97
- window.localStorage.removeItem(v);
97
+ window.localStorage.removeItem(S);
98
98
  } catch {
99
99
  }
100
100
  try {
101
- window.document.cookie = encodeURIComponent(v) + "=; expires=Thu, 01 Jan 1970 00:00:00 UTC";
101
+ window.document.cookie = encodeURIComponent(S) + "=; expires=Thu, 01 Jan 1970 00:00:00 UTC";
102
102
  } catch {
103
103
  }
104
104
  }
105
105
  }
106
- function U(d) {
107
- var m = d;
108
- if (typeof m == "string" && u.levels[m.toUpperCase()] !== void 0 && (m = u.levels[m.toUpperCase()]), typeof m == "number" && m >= 0 && m <= u.levels.SILENT)
109
- return m;
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
110
  throw new TypeError("log.setLevel() called with invalid level: " + d);
111
111
  }
112
112
  u.name = l, u.levels = {
@@ -116,51 +116,51 @@ function He() {
116
116
  WARN: 3,
117
117
  ERROR: 4,
118
118
  SILENT: 5
119
- }, u.methodFactory = g || T, u.getLevel = function() {
120
- return R ?? M ?? O;
121
- }, u.setLevel = function(d, m) {
122
- return R = U(d), m !== !1 && xe(R), f.call(u);
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
123
  }, u.setDefaultLevel = function(d) {
124
- M = U(d), ne() || u.setLevel(d, !1);
124
+ $ = L(d), ne() || u.setLevel(d, !1);
125
125
  }, u.resetLevel = function() {
126
- R = null, Ce(), f.call(u);
126
+ U = null, Pe(), f.call(u);
127
127
  }, u.enableAll = function(d) {
128
128
  u.setLevel(u.levels.TRACE, d);
129
129
  }, u.disableAll = function(d) {
130
130
  u.setLevel(u.levels.SILENT, d);
131
131
  }, u.rebuild = function() {
132
- if (i !== u && (O = U(i.getLevel())), f.call(u), i === u)
132
+ if (i !== u && (J = L(i.getLevel())), f.call(u), i === u)
133
133
  for (var d in r)
134
134
  r[d].rebuild();
135
- }, O = U(
135
+ }, J = L(
136
136
  i ? i.getLevel() : "WARN"
137
137
  );
138
138
  var re = ne();
139
- re != null && (R = U(re)), f.call(u);
139
+ re != null && (U = L(re)), f.call(u);
140
140
  }
141
- i = new h(), i.getLogger = function(g) {
142
- if (typeof g != "symbol" && typeof g != "string" || g === "")
141
+ i = new h(), i.getLogger = function(m) {
142
+ if (typeof m != "symbol" && typeof m != "string" || m === "")
143
143
  throw new TypeError("You must supply a name when creating a logger.");
144
- var u = r[g];
145
- return u || (u = r[g] = new h(
146
- g,
144
+ var u = r[m];
145
+ return u || (u = r[m] = new h(
146
+ m,
147
147
  i.methodFactory
148
148
  )), u;
149
149
  };
150
- var J = typeof window !== n ? window.log : void 0;
150
+ var P = typeof window !== n ? window.log : void 0;
151
151
  return i.noConflict = function() {
152
- return typeof window !== n && window.log === i && (window.log = J), i;
152
+ return typeof window !== n && window.log === i && (window.log = P), i;
153
153
  }, i.getLoggers = function() {
154
154
  return r;
155
155
  }, i.default = i, i;
156
156
  });
157
- }(N)), N.exports;
157
+ }(D)), D.exports;
158
158
  }
159
- var $e = He();
160
- const ae = /* @__PURE__ */ Oe($e);
161
- let G;
162
- var D, pe;
163
- (typeof navigator > "u" || !((pe = (D = navigator.userAgent) == null ? void 0 : D.startsWith) != null && pe.call(D, "Mozilla/5.0 "))) && (G = "oauth4webapi/v2.17.0");
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
164
  function Y(t, e) {
165
165
  if (t == null)
166
166
  return !1;
@@ -170,19 +170,19 @@ function Y(t, e) {
170
170
  return !1;
171
171
  }
172
172
  }
173
- const W = Symbol(), Fe = Symbol(), Q = Symbol(), ge = Symbol(), Me = Symbol(), qe = Symbol(), Be = new TextEncoder(), Ve = new TextDecoder();
173
+ const W = Symbol(), Ke = Symbol(), Z = Symbol(), He = Symbol(), $e = Symbol(), Fe = Symbol(), Me = new TextEncoder(), qe = new TextDecoder();
174
174
  function E(t) {
175
- return typeof t == "string" ? Be.encode(t) : Ve.decode(t);
175
+ return typeof t == "string" ? Me.encode(t) : qe.decode(t);
176
176
  }
177
- const se = 32768;
178
- function Ge(t) {
177
+ const ce = 32768;
178
+ function Be(t) {
179
179
  t instanceof ArrayBuffer && (t = new Uint8Array(t));
180
180
  const e = [];
181
- for (let n = 0; n < t.byteLength; n += se)
182
- e.push(String.fromCharCode.apply(null, t.subarray(n, n + se)));
181
+ for (let n = 0; n < t.byteLength; n += ce)
182
+ e.push(String.fromCharCode.apply(null, t.subarray(n, n + ce)));
183
183
  return btoa(e.join("")).replace(/=/g, "").replace(/\+/g, "-").replace(/\//g, "_");
184
184
  }
185
- function Ze(t) {
185
+ function Ve(t) {
186
186
  try {
187
187
  const e = atob(t.replace(/-/g, "+").replace(/_/g, "/").replace(/\s/g, "")), n = new Uint8Array(e.length);
188
188
  for (let o = 0; o < e.length; o++)
@@ -192,10 +192,10 @@ function Ze(t) {
192
192
  throw new s("The input to be decoded is not correctly encoded.", { cause: e });
193
193
  }
194
194
  }
195
- function A(t) {
196
- return typeof t == "string" ? Ze(t) : Ge(t);
195
+ function k(t) {
196
+ return typeof t == "string" ? Ve(t) : Be(t);
197
197
  }
198
- class Ye {
198
+ class Ge {
199
199
  constructor(e) {
200
200
  this.cache = /* @__PURE__ */ new Map(), this._cache = /* @__PURE__ */ new Map(), this.maxSize = e;
201
201
  }
@@ -219,49 +219,49 @@ class Ye {
219
219
  this.cache.set(e, n), this.cache.size >= this.maxSize && (this._cache = this.cache, this.cache = /* @__PURE__ */ new Map());
220
220
  }
221
221
  }
222
- class S extends Error {
222
+ class T extends Error {
223
223
  constructor(e) {
224
224
  var n;
225
225
  super(e ?? "operation not supported"), this.name = this.constructor.name, (n = Error.captureStackTrace) == null || n.call(Error, this, this.constructor);
226
226
  }
227
227
  }
228
- class Qe extends Error {
228
+ class Ye extends Error {
229
229
  constructor(e, n) {
230
230
  var o;
231
231
  super(e, n), this.name = this.constructor.name, (o = Error.captureStackTrace) == null || o.call(Error, this, this.constructor);
232
232
  }
233
233
  }
234
- const s = Qe, me = new Ye(100);
235
- function ye(t) {
234
+ const s = Ye, ge = new Ge(100);
235
+ function me(t) {
236
236
  return t instanceof CryptoKey;
237
237
  }
238
- function be(t) {
239
- return ye(t) && t.type === "private";
238
+ function Ze(t) {
239
+ return me(t) && t.type === "private";
240
240
  }
241
- function Xe(t) {
242
- return ye(t) && t.type === "public";
241
+ function Qe(t) {
242
+ return me(t) && t.type === "public";
243
243
  }
244
- function X(t) {
244
+ function Q(t) {
245
245
  try {
246
246
  const e = t.headers.get("dpop-nonce");
247
- e && me.set(new URL(t.url).origin, e);
247
+ e && ge.set(new URL(t.url).origin, e);
248
248
  } catch {
249
249
  }
250
250
  return t;
251
251
  }
252
- function x(t) {
252
+ function C(t) {
253
253
  return !(t === null || typeof t != "object" || Array.isArray(t));
254
254
  }
255
- function H(t) {
255
+ function K(t) {
256
256
  Y(t, Headers) && (t = Object.fromEntries(t.entries()));
257
257
  const e = new Headers(t);
258
- if (G && !e.has("user-agent") && e.set("user-agent", G), e.has("authorization"))
258
+ if (V && !e.has("user-agent") && e.set("user-agent", V), e.has("authorization"))
259
259
  throw new TypeError('"options.headers" must not include the "authorization" header name');
260
260
  if (e.has("dpop"))
261
261
  throw new TypeError('"options.headers" must not include the "dpop" header name');
262
262
  return e;
263
263
  }
264
- function ee(t) {
264
+ function Xe(t) {
265
265
  if (typeof t == "function" && (t = t()), !(t instanceof AbortSignal))
266
266
  throw new TypeError('"options.signal" must return or be an instance of AbortSignal');
267
267
  return t;
@@ -283,15 +283,15 @@ async function et(t, e) {
283
283
  default:
284
284
  throw new TypeError('"options.algorithm" must be "oidc" (default), or "oauth2"');
285
285
  }
286
- const o = H(e == null ? void 0 : e.headers);
287
- return o.set("accept", "application/json"), ((e == null ? void 0 : e[Q]) || fetch)(n.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, {
288
288
  headers: Object.fromEntries(o.entries()),
289
289
  method: "GET",
290
290
  redirect: "manual",
291
- signal: e != null && e.signal ? ee(e.signal) : null
292
- }).then(X);
291
+ signal: null
292
+ }).then(Q);
293
293
  }
294
- function w(t) {
294
+ function g(t) {
295
295
  return typeof t == "string" && t.length !== 0;
296
296
  }
297
297
  async function tt(t, e) {
@@ -308,49 +308,36 @@ async function tt(t, e) {
308
308
  } catch (o) {
309
309
  throw new s('failed to parse "response" body as JSON', { cause: o });
310
310
  }
311
- if (!x(n))
311
+ if (!C(n))
312
312
  throw new s('"response" body must be a top level object');
313
- if (!w(n.issuer))
313
+ if (!g(n.issuer))
314
314
  throw new s('"response" body "issuer" property must be a non-empty string');
315
315
  if (new URL(n.issuer).href !== t.href)
316
316
  throw new s('"response" body "issuer" does not match "expectedIssuer"');
317
317
  return n;
318
318
  }
319
- function $() {
320
- return A(crypto.getRandomValues(new Uint8Array(32)));
319
+ function X() {
320
+ return k(crypto.getRandomValues(new Uint8Array(32)));
321
321
  }
322
322
  function nt() {
323
- return $();
323
+ return X();
324
324
  }
325
325
  function rt() {
326
- return $();
326
+ return X();
327
327
  }
328
328
  async function ot(t) {
329
- if (!w(t))
329
+ if (!g(t))
330
330
  throw new TypeError('"codeVerifier" must be a non-empty string');
331
- return A(await crypto.subtle.digest("SHA-256", E(t)));
332
- }
333
- function it(t) {
334
- if (t instanceof CryptoKey)
335
- return { key: t };
336
- if (!((t == null ? void 0 : t.key) instanceof CryptoKey))
337
- return {};
338
- if (t.kid !== void 0 && !w(t.kid))
339
- throw new TypeError('"kid" must be a non-empty string');
340
- return {
341
- key: t.key,
342
- kid: t.kid,
343
- modifyAssertion: t[ge]
344
- };
331
+ return k(await crypto.subtle.digest("SHA-256", E(t)));
345
332
  }
346
- function ce(t) {
333
+ function ue(t) {
347
334
  return encodeURIComponent(t).replace(/%20/g, "+");
348
335
  }
349
- function at(t, e) {
350
- const n = ce(t), o = ce(e);
336
+ function it(t, e) {
337
+ const n = ue(t), o = ue(e);
351
338
  return `Basic ${btoa(`${n}:${o}`)}`;
352
339
  }
353
- function st(t) {
340
+ function at(t) {
354
341
  switch (t.algorithm.hash.name) {
355
342
  case "SHA-256":
356
343
  return "PS256";
@@ -359,10 +346,10 @@ function st(t) {
359
346
  case "SHA-512":
360
347
  return "PS512";
361
348
  default:
362
- throw new S("unsupported RsaHashedKeyAlgorithm hash name");
349
+ throw new T("unsupported RsaHashedKeyAlgorithm hash name");
363
350
  }
364
351
  }
365
- function ct(t) {
352
+ function st(t) {
366
353
  switch (t.algorithm.hash.name) {
367
354
  case "SHA-256":
368
355
  return "RS256";
@@ -371,10 +358,10 @@ function ct(t) {
371
358
  case "SHA-512":
372
359
  return "RS512";
373
360
  default:
374
- throw new S("unsupported RsaHashedKeyAlgorithm hash name");
361
+ throw new T("unsupported RsaHashedKeyAlgorithm hash name");
375
362
  }
376
363
  }
377
- function ut(t) {
364
+ function ct(t) {
378
365
  switch (t.algorithm.namedCurve) {
379
366
  case "P-256":
380
367
  return "ES256";
@@ -383,219 +370,192 @@ function ut(t) {
383
370
  case "P-521":
384
371
  return "ES512";
385
372
  default:
386
- throw new S("unsupported EcKeyAlgorithm namedCurve");
373
+ throw new T("unsupported EcKeyAlgorithm namedCurve");
387
374
  }
388
375
  }
389
- function _e(t) {
376
+ function ut(t) {
390
377
  switch (t.algorithm.name) {
391
378
  case "RSA-PSS":
392
- return st(t);
379
+ return at(t);
393
380
  case "RSASSA-PKCS1-v1_5":
394
- return ct(t);
381
+ return st(t);
395
382
  case "ECDSA":
396
- return ut(t);
383
+ return ct(t);
397
384
  case "Ed25519":
398
385
  case "Ed448":
399
386
  return "EdDSA";
400
387
  default:
401
- throw new S("unsupported CryptoKey algorithm name");
388
+ throw new T("unsupported CryptoKey algorithm name");
402
389
  }
403
390
  }
404
- function C(t) {
391
+ function H(t) {
405
392
  const e = t == null ? void 0 : t[W];
406
393
  return typeof e == "number" && Number.isFinite(e) ? e : 0;
407
394
  }
408
- function ve(t) {
409
- const e = t == null ? void 0 : t[Fe];
395
+ function ye(t) {
396
+ const e = t == null ? void 0 : t[Ke];
410
397
  return typeof e == "number" && Number.isFinite(e) && Math.sign(e) !== -1 ? e : 30;
411
398
  }
412
- function F() {
399
+ function ee() {
413
400
  return Math.floor(Date.now() / 1e3);
414
401
  }
415
- function lt(t, e) {
416
- const n = F() + C(e);
417
- return {
418
- jti: $(),
419
- aud: [t.issuer, t.token_endpoint],
420
- exp: n + 60,
421
- iat: n,
422
- nbf: n,
423
- iss: e.client_id,
424
- sub: e.client_id
425
- };
426
- }
427
- async function dt(t, e, n, o, a) {
428
- const r = { alg: _e(n), kid: o }, i = lt(t, e);
429
- return a == null || a(r, i), Se(r, i, n);
430
- }
431
402
  function I(t) {
432
403
  if (typeof t != "object" || t === null)
433
404
  throw new TypeError('"as" must be an object');
434
- if (!w(t.issuer))
405
+ if (!g(t.issuer))
435
406
  throw new TypeError('"as.issuer" property must be a non-empty string');
436
407
  return !0;
437
408
  }
438
409
  function j(t) {
439
410
  if (typeof t != "object" || t === null)
440
411
  throw new TypeError('"client" must be an object');
441
- if (!w(t.client_id))
412
+ if (!g(t.client_id))
442
413
  throw new TypeError('"client.client_id" property must be a non-empty string');
443
414
  return !0;
444
415
  }
445
- function ue(t) {
446
- if (!w(t))
416
+ function le(t) {
417
+ if (!g(t))
447
418
  throw new TypeError('"client.client_secret" property must be a non-empty string');
448
419
  return t;
449
420
  }
450
- function q(t, e) {
451
- if (e !== void 0)
452
- throw new TypeError(`"options.clientPrivateKey" property must not be provided when ${t} client authentication method is used.`);
453
- }
454
- function le(t, e) {
421
+ function de(t, e) {
455
422
  if (e !== void 0)
456
423
  throw new TypeError(`"client.client_secret" property must not be provided when ${t} client authentication method is used.`);
457
424
  }
458
- async function ht(t, e, n, o, a) {
425
+ async function lt(t, e, n, o, a) {
459
426
  switch (n.delete("client_secret"), n.delete("client_assertion_type"), n.delete("client_assertion"), e.token_endpoint_auth_method) {
460
427
  case void 0:
461
428
  case "client_secret_basic": {
462
- q("client_secret_basic", a), o.set("authorization", at(e.client_id, ue(e.client_secret)));
429
+ o.set("authorization", it(e.client_id, le(e.client_secret)));
463
430
  break;
464
431
  }
465
432
  case "client_secret_post": {
466
- q("client_secret_post", a), n.set("client_id", e.client_id), n.set("client_secret", ue(e.client_secret));
467
- break;
468
- }
469
- case "private_key_jwt": {
470
- if (le("private_key_jwt", e.client_secret), a === void 0)
471
- throw new TypeError('"options.clientPrivateKey" must be provided when "client.token_endpoint_auth_method" is "private_key_jwt"');
472
- const { key: r, kid: i, modifyAssertion: c } = it(a);
473
- if (!be(r))
474
- throw new TypeError('"options.clientPrivateKey.key" must be a private CryptoKey');
475
- 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 dt(t, e, r, i, c));
433
+ n.set("client_id", e.client_id), n.set("client_secret", le(e.client_secret));
476
434
  break;
477
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"');
478
438
  case "tls_client_auth":
479
439
  case "self_signed_tls_client_auth":
480
440
  case "none": {
481
- le(e.token_endpoint_auth_method, e.client_secret), q(e.token_endpoint_auth_method, a), n.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);
482
442
  break;
483
443
  }
484
444
  default:
485
- throw new S("unsupported client token_endpoint_auth_method");
445
+ throw new T("unsupported client token_endpoint_auth_method");
486
446
  }
487
447
  }
488
- async function Se(t, e, n) {
448
+ async function dt(t, e, n) {
489
449
  if (!n.usages.includes("sign"))
490
450
  throw new TypeError('CryptoKey instances used for signing assertions must include "sign" in their "usages"');
491
- const o = `${A(E(JSON.stringify(t)))}.${A(E(JSON.stringify(e)))}`, a = A(await crypto.subtle.sign(Ue(n), n, E(o)));
451
+ const o = `${k(E(JSON.stringify(t)))}.${k(E(JSON.stringify(e)))}`, a = k(await crypto.subtle.sign(ke(n), n, E(o)));
492
452
  return `${o}.${a}`;
493
453
  }
494
- async function ft(t, e, n, o, a, r) {
495
- var T;
496
- const { privateKey: i, publicKey: c, nonce: p = me.get(n.origin) } = e;
497
- if (!be(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))
498
458
  throw new TypeError('"DPoP.privateKey" must be a private CryptoKey');
499
- if (!Xe(c))
459
+ if (!Qe(c))
500
460
  throw new TypeError('"DPoP.publicKey" must be a public CryptoKey');
501
- if (p !== void 0 && !w(p))
461
+ if (p !== void 0 && !g(p))
502
462
  throw new TypeError('"DPoP.nonce" must be a non-empty string or undefined');
503
463
  if (!c.extractable)
504
464
  throw new TypeError('"DPoP.publicKey.extractable" must be true');
505
- const _ = F() + a, f = {
506
- alg: _e(i),
465
+ const w = ee() + a, f = {
466
+ alg: ut(i),
507
467
  typ: "dpop+jwt",
508
- jwk: await wt(c)
509
- }, y = {
510
- iat: _,
511
- jti: $(),
468
+ jwk: await pt(c)
469
+ }, v = {
470
+ iat: w,
471
+ jti: X(),
512
472
  htm: o,
513
473
  nonce: p,
514
474
  htu: `${n.origin}${n.pathname}`,
515
- ath: r ? A(await crypto.subtle.digest("SHA-256", E(r))) : void 0
475
+ ath: r ? k(await crypto.subtle.digest("SHA-256", E(r))) : void 0
516
476
  };
517
- (T = e[ge]) == null || T.call(e, f, y), t.set("dpop", await Se(f, y, i));
477
+ (_ = e[He]) == null || _.call(e, f, v), t.set("dpop", await dt(f, v, i));
518
478
  }
519
- let K;
520
- async function pt(t) {
479
+ let N;
480
+ async function ft(t) {
521
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 };
522
- return K.set(t, c), c;
482
+ return N.set(t, c), c;
523
483
  }
524
- async function wt(t) {
525
- return K || (K = /* @__PURE__ */ new WeakMap()), K.get(t) || pt(t);
484
+ async function pt(t) {
485
+ return N || (N = /* @__PURE__ */ new WeakMap()), N.get(t) || ft(t);
526
486
  }
527
- function de(t, e, n) {
487
+ function he(t, e, n) {
528
488
  if (typeof t != "string")
529
489
  throw n ? new TypeError(`"as.mtls_endpoint_aliases.${e}" must be a string`) : new TypeError(`"as.${e}" must be a string`);
530
490
  return new URL(t);
531
491
  }
532
- function Te(t, e, n = !1) {
533
- return n && t.mtls_endpoint_aliases && e in t.mtls_endpoint_aliases ? de(t.mtls_endpoint_aliases[e], e, n) : de(t[e], e, n);
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);
534
494
  }
535
- function ke(t, e) {
536
- return !!(t.use_mtls_endpoint_aliases || e != null && e[qe]);
495
+ function _e(t, e) {
496
+ return !!(t.use_mtls_endpoint_aliases || e != null && e[Fe]);
537
497
  }
538
- function Z(t) {
498
+ function G(t) {
539
499
  const e = t;
540
500
  return typeof e != "object" || Array.isArray(e) || e === null ? !1 : e.error !== void 0;
541
501
  }
542
- async function gt(t, e, n, o, a, r) {
543
- if (!w(t))
502
+ async function wt(t, e, n, o, a, r) {
503
+ if (!g(t))
544
504
  throw new TypeError('"accessToken" must be a non-empty string');
545
505
  if (!(n instanceof URL))
546
506
  throw new TypeError('"url" must be an instance of URL');
547
- return o = H(o), (r == null ? void 0 : r.DPoP) === void 0 ? o.set("authorization", `Bearer ${t}`) : (await ft(o, r.DPoP, n, e.toUpperCase(), C({ [W]: r == null ? void 0 : r[W] }), t), o.set("authorization", `DPoP ${t}`)), ((r == null ? void 0 : r[Q]) || fetch)(n.href, {
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, {
548
508
  body: a,
549
509
  headers: Object.fromEntries(o.entries()),
550
510
  method: e,
551
511
  redirect: "manual",
552
- signal: r != null && r.signal ? ee(r.signal) : null
553
- }).then(X);
512
+ signal: r != null && r.signal ? Xe(r.signal) : null
513
+ }).then(Q);
554
514
  }
555
- async function mt(t, e, n, o) {
515
+ async function gt(t, e, n, o) {
556
516
  I(t), j(e);
557
- const a = Te(t, "userinfo_endpoint", ke(e, o)), r = H(o == null ? void 0 : o.headers);
558
- 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, {
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, {
559
519
  ...o,
560
- [W]: C(e)
520
+ [W]: H(e)
561
521
  });
562
522
  }
563
- async function yt(t, e, n, o, a, r, i) {
564
- return await ht(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[Q]) || fetch)(o.href, {
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, {
565
525
  body: a,
566
526
  headers: Object.fromEntries(r.entries()),
567
527
  method: n,
568
528
  redirect: "manual",
569
- signal: i != null && i.signal ? ee(i.signal) : null
570
- }).then(X);
529
+ signal: null
530
+ }).then(Q);
571
531
  }
572
- async function Ae(t, e, n, o, a) {
573
- const r = Te(t, "token_endpoint", ke(e, a));
532
+ async function ve(t, e, n, o, a) {
533
+ const r = be(t, "token_endpoint", _e(e, a));
574
534
  o.set("grant_type", n);
575
- const i = H(a == null ? void 0 : a.headers);
576
- return i.set("accept", "application/json"), yt(t, e, "POST", r, o, i, a);
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);
577
537
  }
578
- async function bt(t, e, n, o) {
579
- if (I(t), j(e), !w(n))
538
+ async function yt(t, e, n, o) {
539
+ if (I(t), j(e), !g(n))
580
540
  throw new TypeError('"refreshToken" must be a non-empty string');
581
541
  const a = new URLSearchParams(o == null ? void 0 : o.additionalParameters);
582
- return a.set("refresh_token", n), Ae(t, e, "refresh_token", a, o);
542
+ return a.set("refresh_token", n), ve(t, e, "refresh_token", a, o);
583
543
  }
584
- const Ee = /* @__PURE__ */ new WeakMap();
585
- function _t(t) {
544
+ const Se = /* @__PURE__ */ new WeakMap();
545
+ function bt(t) {
586
546
  if (!t.id_token)
587
547
  return;
588
- const e = Ee.get(t);
548
+ const e = Se.get(t);
589
549
  if (!e)
590
550
  throw new TypeError('"ref" was already garbage collected or did not resolve from the proper sources');
591
551
  return e[0];
592
552
  }
593
- async function Re(t, e, n, o = !1, a = !1) {
553
+ async function Te(t, e, n, o = !1, a = !1) {
594
554
  if (I(t), j(e), !Y(n, Response))
595
555
  throw new TypeError('"response" must be an instance of Response');
596
556
  if (n.status !== 200) {
597
557
  let i;
598
- if (i = await Lt(n))
558
+ if (i = await Ut(n))
599
559
  return i;
600
560
  throw new s('"response" is not a conform Token Endpoint response');
601
561
  }
@@ -606,25 +566,25 @@ async function Re(t, e, n, o = !1, a = !1) {
606
566
  } catch (i) {
607
567
  throw new s('failed to parse "response" body as JSON', { cause: i });
608
568
  }
609
- if (!x(r))
569
+ if (!C(r))
610
570
  throw new s('"response" body must be a top level object');
611
- if (!w(r.access_token))
571
+ if (!g(r.access_token))
612
572
  throw new s('"response" body "access_token" property must be a non-empty string');
613
- if (!w(r.token_type))
573
+ if (!g(r.token_type))
614
574
  throw new s('"response" body "token_type" property must be a non-empty string');
615
575
  if (r.token_type = r.token_type.toLowerCase(), r.token_type !== "dpop" && r.token_type !== "bearer")
616
- throw new S("unsupported `token_type` value");
576
+ throw new T("unsupported `token_type` value");
617
577
  if (r.expires_in !== void 0 && (typeof r.expires_in != "number" || r.expires_in <= 0))
618
578
  throw new s('"response" body "expires_in" property must be a positive number');
619
- if (!a && r.refresh_token !== void 0 && !w(r.refresh_token))
579
+ if (!a && r.refresh_token !== void 0 && !g(r.refresh_token))
620
580
  throw new s('"response" body "refresh_token" property must be a non-empty string');
621
581
  if (r.scope !== void 0 && typeof r.scope != "string")
622
582
  throw new s('"response" body "scope" property must be a string');
623
583
  if (!o) {
624
- if (r.id_token !== void 0 && !w(r.id_token))
584
+ if (r.id_token !== void 0 && !g(r.id_token))
625
585
  throw new s('"response" body "id_token" property must be a non-empty string');
626
586
  if (r.id_token) {
627
- const { claims: i, jwt: c } = await It(r.id_token, jt.bind(void 0, e.id_token_signed_response_alg, t.id_token_signing_alg_values_supported), Le, C(e), ve(e), e[Me]).then(Rt.bind(void 0, ["aud", "exp", "iat", "iss", "sub"])).then(Tt.bind(void 0, t.issuer)).then(St.bind(void 0, e.client_id));
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));
628
588
  if (Array.isArray(i.aud) && i.aud.length !== 1) {
629
589
  if (i.azp === void 0)
630
590
  throw new s('ID Token "aud" (audience) claim includes additional untrusted audiences');
@@ -633,15 +593,15 @@ async function Re(t, e, n, o = !1, a = !1) {
633
593
  }
634
594
  if (i.auth_time !== void 0 && (!Number.isFinite(i.auth_time) || Math.sign(i.auth_time) !== 1))
635
595
  throw new s('ID Token "auth_time" (authentication time) must be a positive number');
636
- Ee.set(r, [i, c]);
596
+ Se.set(r, [i, c]);
637
597
  }
638
598
  }
639
599
  return r;
640
600
  }
641
- async function vt(t, e, n) {
642
- return Re(t, e, n);
601
+ async function _t(t, e, n) {
602
+ return Te(t, e, n);
643
603
  }
644
- function St(t, e) {
604
+ function vt(t, e) {
645
605
  if (Array.isArray(e.claims.aud)) {
646
606
  if (!e.claims.aud.includes(t))
647
607
  throw new s('unexpected JWT "aud" (audience) claim value');
@@ -649,29 +609,29 @@ function St(t, e) {
649
609
  throw new s('unexpected JWT "aud" (audience) claim value');
650
610
  return e;
651
611
  }
652
- function Tt(t, e) {
612
+ function St(t, e) {
653
613
  if (e.claims.iss !== t)
654
614
  throw new s('unexpected JWT "iss" (issuer) claim value');
655
615
  return e;
656
616
  }
657
- const Pe = /* @__PURE__ */ new WeakSet();
658
- function kt(t) {
659
- return Pe.add(t), t;
617
+ const Ae = /* @__PURE__ */ new WeakSet();
618
+ function Tt(t) {
619
+ return Ae.add(t), t;
660
620
  }
661
621
  async function At(t, e, n, o, a, r) {
662
- if (I(t), j(e), !Pe.has(n))
622
+ if (I(t), j(e), !Ae.has(n))
663
623
  throw new TypeError('"callbackParameters" must be an instance of URLSearchParams obtained from "validateAuthResponse()", or "validateJwtAuthResponse()');
664
- if (!w(o))
624
+ if (!g(o))
665
625
  throw new TypeError('"redirectUri" must be a non-empty string');
666
- if (!w(a))
626
+ if (!g(a))
667
627
  throw new TypeError('"codeVerifier" must be a non-empty string');
668
- const i = k(n, "code");
628
+ const i = A(n, "code");
669
629
  if (!i)
670
630
  throw new s('no authorization code in "callbackParameters"');
671
631
  const c = new URLSearchParams(r == null ? void 0 : r.additionalParameters);
672
- return c.set("redirect_uri", o), c.set("code_verifier", a), c.set("code", i), Ae(t, e, "authorization_code", c, r);
632
+ return c.set("redirect_uri", o), c.set("code_verifier", a), c.set("code", i), ve(t, e, "authorization_code", c, r);
673
633
  }
674
- const Et = {
634
+ const kt = {
675
635
  aud: "audience",
676
636
  c_hash: "code hash",
677
637
  client_id: "client id",
@@ -687,38 +647,38 @@ const Et = {
687
647
  htu: "http uri",
688
648
  cnf: "confirmation"
689
649
  };
690
- function Rt(t, e) {
650
+ function Et(t, e) {
691
651
  for (const n of t)
692
652
  if (e.claims[n] === void 0)
693
- throw new s(`JWT "${n}" (${Et[n]}) claim missing`);
653
+ throw new s(`JWT "${n}" (${kt[n]}) claim missing`);
694
654
  return e;
695
655
  }
696
- const Pt = Symbol(), B = Symbol();
697
- async function Ut(t, e, n, o, a) {
698
- const r = await Re(t, e, n);
699
- if (Z(r))
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))
700
660
  return r;
701
- if (!w(r.id_token))
661
+ if (!g(r.id_token))
702
662
  throw new s('"response" body "id_token" property must be a non-empty string');
703
- a ?? (a = e.default_max_age ?? B);
704
- const i = _t(r);
705
- if ((e.require_auth_time || a !== B) && i.auth_time === void 0)
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)
706
666
  throw new s('ID Token "auth_time" (authentication time) claim missing');
707
- if (a !== B) {
667
+ if (a !== F) {
708
668
  if (typeof a != "number" || a < 0)
709
669
  throw new TypeError('"maxAge" must be a non-negative number');
710
- const c = F() + C(e), p = ve(e);
670
+ const c = ee() + H(e), p = ye(e);
711
671
  if (i.auth_time + a < c - p)
712
672
  throw new s("too much time has elapsed since the last End-User authentication");
713
673
  }
714
674
  switch (o) {
715
675
  case void 0:
716
- case Pt:
676
+ case Rt:
717
677
  if (i.nonce !== void 0)
718
678
  throw new s('unexpected ID Token "nonce" claim value');
719
679
  break;
720
680
  default:
721
- if (!w(o))
681
+ if (!g(o))
722
682
  throw new TypeError('"expectedNonce" must be a non-empty string');
723
683
  if (i.nonce === void 0)
724
684
  throw new s('ID Token "nonce" claim missing');
@@ -731,22 +691,22 @@ function te(t) {
731
691
  if (t.bodyUsed)
732
692
  throw new TypeError('"response" body has been used already');
733
693
  }
734
- async function Lt(t) {
694
+ async function Ut(t) {
735
695
  if (t.status > 399 && t.status < 500) {
736
696
  te(t);
737
697
  try {
738
698
  const e = await t.json();
739
- if (x(e) && typeof e.error == "string" && e.error.length)
699
+ if (C(e) && typeof e.error == "string" && e.error.length)
740
700
  return e.error_description !== void 0 && typeof e.error_description != "string" && delete e.error_description, e.error_uri !== void 0 && typeof e.error_uri != "string" && delete e.error_uri, e.algs !== void 0 && typeof e.algs != "string" && delete e.algs, e.scope !== void 0 && typeof e.scope != "string" && delete e.scope, e;
741
701
  } catch {
742
702
  }
743
703
  }
744
704
  }
745
- function he(t) {
705
+ function fe(t) {
746
706
  if (typeof t.modulusLength != "number" || t.modulusLength < 2048)
747
707
  throw new s(`${t.name} modulusLength must be at least 2048 bits`);
748
708
  }
749
- function xt(t) {
709
+ function Lt(t) {
750
710
  switch (t) {
751
711
  case "P-256":
752
712
  return "SHA-256";
@@ -755,18 +715,18 @@ function xt(t) {
755
715
  case "P-521":
756
716
  return "SHA-512";
757
717
  default:
758
- throw new S();
718
+ throw new T();
759
719
  }
760
720
  }
761
- function Ue(t) {
721
+ function ke(t) {
762
722
  switch (t.algorithm.name) {
763
723
  case "ECDSA":
764
724
  return {
765
725
  name: t.algorithm.name,
766
- hash: xt(t.algorithm.namedCurve)
726
+ hash: Lt(t.algorithm.namedCurve)
767
727
  };
768
728
  case "RSA-PSS":
769
- switch (he(t.algorithm), t.algorithm.hash.name) {
729
+ switch (fe(t.algorithm), t.algorithm.hash.name) {
770
730
  case "SHA-256":
771
731
  case "SHA-384":
772
732
  case "SHA-512":
@@ -775,57 +735,57 @@ function Ue(t) {
775
735
  saltLength: parseInt(t.algorithm.hash.name.slice(-3), 10) >> 3
776
736
  };
777
737
  default:
778
- throw new S();
738
+ throw new T();
779
739
  }
780
740
  case "RSASSA-PKCS1-v1_5":
781
- return he(t.algorithm), t.algorithm.name;
741
+ return fe(t.algorithm), t.algorithm.name;
782
742
  case "Ed448":
783
743
  case "Ed25519":
784
744
  return t.algorithm.name;
785
745
  }
786
- throw new S();
746
+ throw new T();
787
747
  }
788
- const Le = Symbol();
789
- async function Ct(t, e, n, o) {
748
+ const Ee = Symbol();
749
+ async function xt(t, e, n, o) {
790
750
  const a = `${t}.${e}`;
791
- if (!await crypto.subtle.verify(Ue(n), n, o, E(a)))
751
+ if (!await crypto.subtle.verify(ke(n), n, o, E(a)))
792
752
  throw new s("JWT signature verification failed");
793
753
  }
794
- async function It(t, e, n, o, a, r) {
795
- let { 0: i, 1: c, 2: p, length: _ } = t.split(".");
796
- if (_ === 5)
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)
797
757
  if (r !== void 0)
798
- t = await r(t), { 0: i, 1: c, 2: p, length: _ } = t.split(".");
758
+ t = await r(t), { 0: i, 1: c, 2: p, length: w } = t.split(".");
799
759
  else
800
- throw new S("JWE structure JWTs are not supported");
801
- if (_ !== 3)
760
+ throw new T("JWE structure JWTs are not supported");
761
+ if (w !== 3)
802
762
  throw new s("Invalid JWT");
803
763
  let f;
804
764
  try {
805
- f = JSON.parse(E(A(i)));
765
+ f = JSON.parse(E(k(i)));
806
766
  } catch (l) {
807
767
  throw new s("failed to parse JWT Header body as base64url encoded JSON", { cause: l });
808
768
  }
809
- if (!x(f))
769
+ if (!C(f))
810
770
  throw new s("JWT Header must be a top level object");
811
771
  if (e(f), f.crit !== void 0)
812
772
  throw new s('unexpected JWT "crit" header parameter');
813
- const y = A(p);
814
- let T;
815
- n !== Le && (T = await n(f), await Ct(i, c, T, y));
773
+ const v = k(p);
774
+ let _;
775
+ n !== Ee && (_ = await n(f), await xt(i, c, _, v));
816
776
  let h;
817
777
  try {
818
- h = JSON.parse(E(A(c)));
778
+ h = JSON.parse(E(k(c)));
819
779
  } catch (l) {
820
780
  throw new s("failed to parse JWT Payload body as base64url encoded JSON", { cause: l });
821
781
  }
822
- if (!x(h))
782
+ if (!C(h))
823
783
  throw new s("JWT Payload must be a top level object");
824
- const J = F() + o;
784
+ const P = ee() + o;
825
785
  if (h.exp !== void 0) {
826
786
  if (typeof h.exp != "number")
827
787
  throw new s('unexpected JWT "exp" (expiration time) claim type');
828
- if (h.exp <= J - a)
788
+ if (h.exp <= P - a)
829
789
  throw new s('unexpected JWT "exp" (expiration time) claim value, timestamp is <= now()');
830
790
  }
831
791
  if (h.iat !== void 0 && typeof h.iat != "number")
@@ -835,14 +795,14 @@ async function It(t, e, n, o, a, r) {
835
795
  if (h.nbf !== void 0) {
836
796
  if (typeof h.nbf != "number")
837
797
  throw new s('unexpected JWT "nbf" (not before) claim type');
838
- if (h.nbf > J + a)
798
+ if (h.nbf > P + a)
839
799
  throw new s('unexpected JWT "nbf" (not before) claim value, timestamp is > now()');
840
800
  }
841
801
  if (h.aud !== void 0 && typeof h.aud != "string" && !Array.isArray(h.aud))
842
802
  throw new s('unexpected JWT "aud" (audience) claim type');
843
- return { header: f, claims: h, signature: y, key: T, jwt: t };
803
+ return { header: f, claims: h, signature: v, key: _, jwt: t };
844
804
  }
845
- function jt(t, e, n) {
805
+ function It(t, e, n) {
846
806
  if (t !== void 0) {
847
807
  if (n.alg !== t)
848
808
  throw new s('unexpected JWT "alg" header parameter');
@@ -856,62 +816,62 @@ function jt(t, e, n) {
856
816
  if (n.alg !== "RS256")
857
817
  throw new s('unexpected JWT "alg" header parameter');
858
818
  }
859
- function k(t, e) {
819
+ function A(t, e) {
860
820
  const { 0: n, length: o } = t.getAll(e);
861
821
  if (o > 1)
862
822
  throw new s(`"${e}" parameter must be provided only once`);
863
823
  return n;
864
824
  }
865
- const Jt = Symbol(), Ot = Symbol();
866
- function zt(t, e, n, o) {
825
+ const jt = Symbol(), Jt = Symbol();
826
+ function Ot(t, e, n, o) {
867
827
  if (I(t), j(e), n instanceof URL && (n = n.searchParams), !(n instanceof URLSearchParams))
868
828
  throw new TypeError('"parameters" must be an instance of URLSearchParams, or URL');
869
- if (k(n, "response"))
829
+ if (A(n, "response"))
870
830
  throw new s('"parameters" contains a JARM response, use validateJwtAuthResponse() instead of validateAuthResponse()');
871
- const a = k(n, "iss"), r = k(n, "state");
831
+ const a = A(n, "iss"), r = A(n, "state");
872
832
  if (!a && t.authorization_response_iss_parameter_supported)
873
833
  throw new s('response parameter "iss" (issuer) missing');
874
834
  if (a && a !== t.issuer)
875
835
  throw new s('unexpected "iss" (issuer) response parameter value');
876
836
  switch (o) {
877
837
  case void 0:
878
- case Ot:
838
+ case Jt:
879
839
  if (r !== void 0)
880
840
  throw new s('unexpected "state" response parameter encountered');
881
841
  break;
882
- case Jt:
842
+ case jt:
883
843
  break;
884
844
  default:
885
- if (!w(o))
845
+ if (!g(o))
886
846
  throw new s('"expectedState" must be a non-empty string');
887
847
  if (r === void 0)
888
848
  throw new s('response parameter "state" missing');
889
849
  if (r !== o)
890
850
  throw new s('unexpected "state" response parameter value');
891
851
  }
892
- const i = k(n, "error");
852
+ const i = A(n, "error");
893
853
  if (i)
894
854
  return {
895
855
  error: i,
896
- error_description: k(n, "error_description"),
897
- error_uri: k(n, "error_uri")
856
+ error_description: A(n, "error_description"),
857
+ error_uri: A(n, "error_uri")
898
858
  };
899
- const c = k(n, "id_token"), p = k(n, "token");
859
+ const c = A(n, "id_token"), p = A(n, "token");
900
860
  if (c !== void 0 || p !== void 0)
901
- throw new S("implicit and hybrid flows are not supported");
902
- return kt(new URLSearchParams(n));
861
+ throw new T("implicit and hybrid flows are not supported");
862
+ return Tt(new URLSearchParams(n));
903
863
  }
904
- function Dt({
864
+ function zt({
905
865
  handleCallback: t
906
866
  }) {
907
- const e = De({
867
+ const e = je({
908
868
  retry: !1,
909
869
  queryKey: ["oauth-callback"],
910
870
  queryFn: async () => {
911
871
  try {
912
872
  return await t();
913
873
  } catch (n) {
914
- throw new Ke("Could not validate user", {
874
+ throw new ze("Could not validate user", {
915
875
  cause: n,
916
876
  title: "Authentication Error",
917
877
  developerHint: "Check the configuration of your authorization provider and ensure all settings such as the callback URL are configured correctly."
@@ -919,17 +879,17 @@ function Dt({
919
879
  }
920
880
  }
921
881
  });
922
- return /* @__PURE__ */ we.jsx(Ne, { to: e.data });
882
+ return /* @__PURE__ */ B.jsx(Oe, { to: e.data });
923
883
  }
924
- class P extends Error {
884
+ class R extends Error {
925
885
  }
926
- class fe extends P {
886
+ class pe extends R {
927
887
  constructor(e, n, o) {
928
888
  super(e, o), this.error = n;
929
889
  }
930
890
  }
931
- const V = "code-verifier";
932
- class Nt extends ze {
891
+ const M = "code-verifier", q = "oauth-state";
892
+ class Dt extends Je {
933
893
  constructor(e, n) {
934
894
  super(), this.callbackUrlPath = e, this.handleCallback = n;
935
895
  }
@@ -938,32 +898,39 @@ class Nt extends ze {
938
898
  ...super.getRoutes(),
939
899
  {
940
900
  path: this.callbackUrlPath,
941
- element: /* @__PURE__ */ we.jsx(Dt, { handleCallback: this.handleCallback })
901
+ element: /* @__PURE__ */ B.jsx(Ie, { children: /* @__PURE__ */ B.jsx(zt, { handleCallback: this.handleCallback }) })
942
902
  }
943
903
  ];
944
904
  }
945
905
  }
946
- class Kt {
906
+ class Nt {
947
907
  constructor({
948
908
  issuer: e,
949
909
  audience: n,
950
910
  clientId: o,
951
911
  redirectToAfterSignUp: a,
952
912
  redirectToAfterSignIn: r,
953
- redirectToAfterSignOut: i
913
+ redirectToAfterSignOut: i,
914
+ basePath: c,
915
+ scopes: p
954
916
  }) {
955
917
  b(this, "client");
956
918
  b(this, "issuer");
957
919
  b(this, "authorizationServer");
958
- b(this, "callbackUrlPath", "/oauth/callback");
959
- b(this, "logoutRedirectUrlPath", "/");
920
+ b(this, "callbackUrlPath");
921
+ b(this, "logoutRedirectUrlPath");
960
922
  b(this, "onAuthorizationUrl");
961
923
  b(this, "redirectToAfterSignUp");
962
924
  b(this, "redirectToAfterSignIn");
963
925
  b(this, "redirectToAfterSignOut");
964
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
+ });
965
932
  b(this, "signOut", async () => {
966
- L.setState({
933
+ x.setState({
967
934
  isAuthenticated: !1,
968
935
  isPending: !1,
969
936
  profile: void 0,
@@ -980,57 +947,62 @@ class Kt {
980
947
  )) : o = n;
981
948
  });
982
949
  b(this, "handleCallback", async () => {
983
- const e = new URL(window.location.href), n = e.searchParams.get("state"), o = sessionStorage.getItem(V);
984
- if (sessionStorage.removeItem(V), !o)
985
- throw new P("No code verifier found in state.");
986
- const a = await this.getAuthServer(), r = zt(
987
- a,
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,
988
958
  this.client,
989
959
  e.searchParams,
990
960
  n ?? void 0
991
961
  );
992
- if (Z(r))
993
- throw ae.error("Error validating OAuth response", r), new fe(
962
+ if (G(i))
963
+ throw se.error("Error validating OAuth response", i), new pe(
994
964
  "Error validating OAuth response",
995
- r
965
+ i
996
966
  );
997
- const i = new URL(e);
998
- i.pathname = this.redirectToAfterSignIn, i.search = "";
999
- const c = await At(
1000
- a,
967
+ const c = new URL(e);
968
+ c.pathname = this.callbackUrlPath, c.search = "";
969
+ const p = await At(
970
+ r,
1001
971
  this.client,
972
+ i,
973
+ c.toString(),
974
+ a
975
+ ), w = await Pt(
1002
976
  r,
1003
- i.toString(),
1004
- o
1005
- ), p = await Ut(
1006
- a,
1007
977
  this.client,
1008
- c
978
+ p
1009
979
  );
1010
- this.setTokensFromResponse(p);
1011
- const _ = await this.getAccessToken(), y = await (await mt(
1012
- a,
980
+ this.setTokensFromResponse(w);
981
+ const f = await this.getAccessToken(), _ = await (await gt(
982
+ r,
1013
983
  this.client,
1014
- _
1015
- )).json(), T = {
1016
- sub: y.sub,
1017
- email: y.email,
1018
- name: y.name,
1019
- emailVerified: y.email_verified ?? !1,
1020
- pictureUrl: y.picture
984
+ f
985
+ )).json(), h = {
986
+ sub: _.sub,
987
+ email: _.email,
988
+ name: _.name,
989
+ emailVerified: _.email_verified ?? !1,
990
+ pictureUrl: _.picture
1021
991
  };
1022
- L.setState({
992
+ x.setState({
1023
993
  isAuthenticated: !0,
1024
994
  isPending: !1,
1025
- profile: T
995
+ profile: h
1026
996
  });
1027
- const h = sessionStorage.getItem("redirect-to") ?? "/";
1028
- return sessionStorage.removeItem("redirect-to"), h;
997
+ const P = sessionStorage.getItem("redirect-to") ?? "/";
998
+ return sessionStorage.removeItem("redirect-to"), P;
1029
999
  });
1030
1000
  this.client = {
1031
1001
  client_id: o,
1032
1002
  token_endpoint_auth_method: "none"
1033
- }, this.audience = n, this.issuer = e, this.redirectToAfterSignUp = a ?? "/", this.redirectToAfterSignIn = r ?? "/", 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;
1034
1006
  }
1035
1007
  async getAuthServer() {
1036
1008
  if (!this.authorizationServer) {
@@ -1047,17 +1019,18 @@ class Kt {
1047
1019
  * @param response
1048
1020
  */
1049
1021
  setTokensFromResponse(e) {
1050
- if (Z(e))
1051
- throw ae.error("Bad Token Response", e), new fe("Bad Token Response", e);
1022
+ if (G(e))
1023
+ throw se.error("Bad Token Response", e), new pe("Bad Token Response", e);
1052
1024
  if (!e.expires_in)
1053
- throw new P("No expires_in in response");
1025
+ throw new R("No expires_in in response");
1054
1026
  const n = {
1055
1027
  accessToken: e.access_token,
1056
1028
  refreshToken: e.refresh_token,
1029
+ idToken: e.id_token,
1057
1030
  expiresOn: new Date(Date.now() + e.expires_in * 1e3),
1058
1031
  tokenType: e.token_type
1059
1032
  };
1060
- L.setState({
1033
+ x.setState({
1061
1034
  providerData: n
1062
1035
  });
1063
1036
  }
@@ -1076,64 +1049,62 @@ class Kt {
1076
1049
  redirectTo: e,
1077
1050
  isSignUp: n = !1
1078
1051
  }) {
1079
- var _, f;
1052
+ var v;
1080
1053
  const o = "S256", a = await this.getAuthServer();
1081
1054
  if (!a.authorization_endpoint)
1082
- throw new P("No authorization endpoint");
1055
+ throw new R("No authorization endpoint");
1083
1056
  const r = nt(), i = await ot(r);
1084
- sessionStorage.setItem(V, r);
1057
+ sessionStorage.setItem(M, r);
1085
1058
  const c = new URL(
1086
1059
  a.authorization_endpoint
1087
- );
1088
- sessionStorage.setItem("redirect-to", e);
1089
- const p = new URL(window.location.origin);
1090
- 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(
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(
1091
1064
  "code_challenge_method",
1092
1065
  o
1093
- ), this.audience && c.searchParams.set("audience", this.audience), (_ = this.onAuthorizationUrl) == null || _.call(this, c, {
1066
+ ), this.audience && c.searchParams.set("audience", this.audience), (v = this.onAuthorizationUrl) == null || v.call(this, c, {
1094
1067
  isSignIn: !n,
1095
1068
  isSignUp: n
1096
- }), ((f = a.code_challenge_methods_supported) == null ? void 0 : f.includes("S256")) !== !0) {
1097
- const y = rt();
1098
- c.searchParams.set("state", y);
1099
- }
1100
- location.href = c.href;
1069
+ });
1070
+ const f = rt();
1071
+ sessionStorage.setItem(q, f), c.searchParams.set("state", f), location.href = c.href;
1101
1072
  }
1102
1073
  async getAccessToken() {
1103
- const e = await this.getAuthServer(), { providerData: n } = L.getState();
1074
+ const e = await this.getAuthServer(), { providerData: n } = x.getState();
1104
1075
  if (!n)
1105
- throw new P("User is not authenticated");
1076
+ throw new R("User is not authenticated");
1106
1077
  const o = n;
1107
1078
  if (new Date(o.expiresOn) < /* @__PURE__ */ new Date()) {
1108
1079
  if (!o.refreshToken)
1109
- return L.setState({
1080
+ return x.setState({
1110
1081
  isAuthenticated: !1,
1111
1082
  isPending: !1,
1112
1083
  profile: null,
1113
1084
  providerData: null
1114
1085
  }), "";
1115
- const a = await bt(
1086
+ const a = await yt(
1116
1087
  e,
1117
1088
  this.client,
1118
1089
  o.refreshToken
1119
- ), r = await vt(
1090
+ ), r = await _t(
1120
1091
  e,
1121
1092
  this.client,
1122
1093
  a
1123
1094
  );
1124
1095
  if (!r.access_token)
1125
- throw new P("No access token in response");
1096
+ throw new R("No access token in response");
1126
1097
  return this.setTokensFromResponse(r), r.access_token.toString();
1127
1098
  } else
1128
1099
  return o.accessToken;
1129
1100
  }
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 Gt = (t) => new Kt(t);
1105
+ const Vt = (t) => new Nt(t);
1135
1106
  export {
1136
- Kt as OpenIDAuthenticationProvider,
1137
- Gt as default
1107
+ Nt as OpenIDAuthenticationProvider,
1108
+ Vt as default
1138
1109
  };
1139
1110
  //# sourceMappingURL=zudoku.auth-openid.js.map