zudoku 0.0.0-fd8f8ad → 0.0.0-feda542

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