@scalar/api-client 2.2.45 → 2.2.47

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 (359) hide show
  1. package/CHANGELOG.md +51 -0
  2. package/dist/components/AddressBar/AddressBar.vue.d.ts +1 -1
  3. package/dist/components/AddressBar/AddressBar.vue.js +2 -2
  4. package/dist/components/AddressBar/AddressBar.vue2.js +1 -2
  5. package/dist/components/AddressBar/AddressBarHistory.vue.d.ts.map +1 -1
  6. package/dist/components/AddressBar/AddressBarHistory.vue.js +2 -2
  7. package/dist/components/AddressBar/AddressBarHistory.vue2.js +35 -30
  8. package/dist/components/AddressBar/index.d.ts +1 -1
  9. package/dist/components/CodeInput/CodeInput.vue.d.ts +5 -5
  10. package/dist/components/CodeInput/CodeInput.vue.d.ts.map +1 -1
  11. package/dist/components/CodeInput/CodeInput.vue.js +2 -2
  12. package/dist/components/CodeInput/CodeInput.vue2.js +66 -60
  13. package/dist/components/CodeInput/codeVariableWidget.d.ts +5 -5
  14. package/dist/components/CodeInput/codeVariableWidget.d.ts.map +1 -1
  15. package/dist/components/CodeInput/codeVariableWidget.js +2 -3
  16. package/dist/components/CommandPalette/CommandActionForm.vue.d.ts +4 -4
  17. package/dist/components/CommandPalette/CommandActionForm.vue.d.ts.map +1 -1
  18. package/dist/components/CommandPalette/CommandActionForm.vue.js +10 -10
  19. package/dist/components/CommandPalette/CommandActionInput.vue.d.ts +2 -2
  20. package/dist/components/CommandPalette/CommandActionInput.vue.js +1 -1
  21. package/dist/components/CommandPalette/CommandPaletteCollection.vue.d.ts +2 -2
  22. package/dist/components/CommandPalette/CommandPaletteExample.vue.d.ts +2 -2
  23. package/dist/components/CommandPalette/CommandPaletteExample.vue.d.ts.map +1 -1
  24. package/dist/components/CommandPalette/CommandPaletteExample.vue.js +46 -40
  25. package/dist/components/CommandPalette/CommandPaletteImport.vue.d.ts +2 -2
  26. package/dist/components/CommandPalette/CommandPaletteRequest.vue.d.ts +2 -2
  27. package/dist/components/CommandPalette/CommandPaletteServer.vue.d.ts +2 -2
  28. package/dist/components/CommandPalette/CommandPaletteTag.vue.d.ts +2 -2
  29. package/dist/components/CommandPalette/CommandPaletteWorkspace.vue.d.ts +2 -2
  30. package/dist/components/CommandPalette/TheCommandPalette.vue.d.ts +14 -14
  31. package/dist/components/CommandPalette/WatchModeToggle.vue.d.ts +1 -1
  32. package/dist/components/CommandPalette/WatchModeToggle.vue.js +1 -1
  33. package/dist/components/CommandPalette/index.d.ts +1 -1
  34. package/dist/components/ContextBar.vue.d.ts +1 -1
  35. package/dist/components/DataTable/DataTable.vue.d.ts.map +1 -1
  36. package/dist/components/DataTable/DataTableCell.vue.d.ts.map +1 -1
  37. package/dist/components/DataTable/DataTableCheckbox.vue.d.ts +1 -1
  38. package/dist/components/DataTable/DataTableCheckbox.vue.js +6 -6
  39. package/dist/components/DataTable/DataTableInput.vue.d.ts +6 -6
  40. package/dist/components/DataTable/DataTableInput.vue.d.ts.map +1 -1
  41. package/dist/components/DataTable/DataTableInput.vue.js +4 -4
  42. package/dist/components/DataTable/DataTableInput.vue2.js +22 -23
  43. package/dist/components/DataTable/DataTableInputSelect.vue.d.ts +3 -3
  44. package/dist/components/DataTable/DataTableInputSelect.vue.d.ts.map +1 -1
  45. package/dist/components/DataTable/DataTableInputSelect.vue.js +39 -39
  46. package/dist/components/DataTable/DataTableText.vue.d.ts.map +1 -1
  47. package/dist/components/DataTable/index.d.ts +8 -8
  48. package/dist/components/EmptyState.vue.d.ts.map +1 -1
  49. package/dist/components/EmptyState.vue.js +2 -2
  50. package/dist/components/EmptyState.vue2.js +13 -13
  51. package/dist/components/Form/Form.vue.d.ts.map +1 -1
  52. package/dist/components/HelpfulLink.vue.d.ts.map +1 -1
  53. package/dist/components/HttpMethod/HttpMethod.vue.d.ts +1 -1
  54. package/dist/components/HttpMethod/index.d.ts +1 -1
  55. package/dist/components/IconSelector.vue.d.ts +1 -1
  56. package/dist/components/IconSelector.vue.d.ts.map +1 -1
  57. package/dist/components/ImportCollection/DropEventListener.vue.d.ts +1 -1
  58. package/dist/components/ImportCollection/ImportCollectionModal.vue.d.ts +1 -1
  59. package/dist/components/ImportCollection/ImportNowButton.vue.d.ts +1 -1
  60. package/dist/components/ImportCollection/PasteEventListener.vue.d.ts +1 -1
  61. package/dist/components/ImportCollection/UrlQueryParameterChecker.vue.d.ts +1 -1
  62. package/dist/components/ImportCollection/hooks/useUrlPrefetcher.d.ts +2 -2
  63. package/dist/components/ImportCollection/index.d.ts +1 -1
  64. package/dist/components/ImportCurl/ImportCurlModal.vue.d.ts +3 -3
  65. package/dist/components/ScreenReader.vue.d.ts.map +1 -1
  66. package/dist/components/Search/useSearch.d.ts +4 -2
  67. package/dist/components/Search/useSearch.d.ts.map +1 -1
  68. package/dist/components/Search/useSearch.js +63 -56
  69. package/dist/components/Search/useSearch.test.d.ts +2 -0
  70. package/dist/components/Search/useSearch.test.d.ts.map +1 -0
  71. package/dist/components/Server/ServerDropdown.test.d.ts +2 -0
  72. package/dist/components/Server/ServerDropdown.test.d.ts.map +1 -0
  73. package/dist/components/Server/ServerDropdownItem.vue.d.ts +1 -1
  74. package/dist/components/Server/ServerDropdownItem.vue.d.ts.map +1 -1
  75. package/dist/components/Server/ServerDropdownItem.vue.js +1 -1
  76. package/dist/components/Server/ServerDropdownItem.vue2.js +27 -28
  77. package/dist/components/Server/ServerVariablesForm.vue.d.ts +2 -2
  78. package/dist/components/Server/ServerVariablesForm.vue.d.ts.map +1 -1
  79. package/dist/components/Server/ServerVariablesSelect.vue.d.ts +2 -2
  80. package/dist/components/Server/ServerVariablesSelect.vue.d.ts.map +1 -1
  81. package/dist/components/Server/ServerVariablesTextbox.vue.d.ts +2 -2
  82. package/dist/components/Server/ServerVariablesTextbox.vue.d.ts.map +1 -1
  83. package/dist/components/Server/ServerVariablesTextbox.vue.js +9 -9
  84. package/dist/components/Server/index.d.ts +2 -2
  85. package/dist/components/SideNav/SideNav.vue.d.ts.map +1 -1
  86. package/dist/components/SideNav/SideNav.vue.js +19 -19
  87. package/dist/components/SideNav/SideNavLink.vue.d.ts.map +1 -1
  88. package/dist/components/SideNav/SideNavLink.vue.js +11 -11
  89. package/dist/components/SideNav/SideNavRouterLink.vue.d.ts +1 -1
  90. package/dist/components/SideNav/SideNavRouterLink.vue.d.ts.map +1 -1
  91. package/dist/components/SideNav/SideNavRouterLink.vue.js +19 -13
  92. package/dist/components/Sidebar/Actions/DeleteSidebarListElement.vue.d.ts +3 -3
  93. package/dist/components/Sidebar/Actions/DeleteSidebarListElement.vue.d.ts.map +1 -1
  94. package/dist/components/Sidebar/Actions/EditSidebarListCollection.vue.d.ts +2 -2
  95. package/dist/components/Sidebar/Actions/EditSidebarListElement.vue.d.ts +2 -2
  96. package/dist/components/Sidebar/Actions/SidebarListElementForm.vue.d.ts +2 -2
  97. package/dist/components/Sidebar/Actions/SidebarListElementForm.vue.d.ts.map +1 -1
  98. package/dist/components/Sidebar/Sidebar.vue.d.ts.map +1 -1
  99. package/dist/components/Sidebar/Sidebar.vue.js +1 -1
  100. package/dist/components/Sidebar/Sidebar.vue2.js +5 -5
  101. package/dist/components/Sidebar/SidebarButton.vue.d.ts.map +1 -1
  102. package/dist/components/Sidebar/SidebarListElement.vue.d.ts +3 -3
  103. package/dist/components/Sidebar/SidebarListElement.vue.js +1 -1
  104. package/dist/components/Sidebar/SidebarListElement.vue2.js +9 -9
  105. package/dist/components/Sidebar/SidebarListElementActions.vue.d.ts +3 -3
  106. package/dist/components/Sidebar/SidebarListElementActions.vue.d.ts.map +1 -1
  107. package/dist/components/Sidebar/SidebarToggle.vue.d.ts +1 -1
  108. package/dist/components/Sidebar/index.d.ts +1 -1
  109. package/dist/components/TopNav/TopNav.vue.d.ts.map +1 -1
  110. package/dist/components/TopNav/TopNav.vue.js +74 -73
  111. package/dist/components/TopNav/TopNavItem.vue.d.ts +5 -5
  112. package/dist/components/ViewLayout/ViewLayoutCollapse.vue.d.ts.map +1 -1
  113. package/dist/components/ViewLayout/ViewLayoutSection.vue.d.ts.map +1 -1
  114. package/dist/components/ViewLayout/ViewLayoutSection.vue.js +3 -3
  115. package/dist/components/index.d.ts +3 -3
  116. package/dist/hooks/index.d.ts +5 -4
  117. package/dist/hooks/index.d.ts.map +1 -1
  118. package/dist/hooks/index.js +4 -2
  119. package/dist/hooks/useResponseBody.d.ts +18 -0
  120. package/dist/hooks/useResponseBody.d.ts.map +1 -0
  121. package/dist/hooks/useResponseBody.js +28 -0
  122. package/dist/hooks/useResponseBody.test.d.ts +2 -0
  123. package/dist/hooks/useResponseBody.test.d.ts.map +1 -0
  124. package/dist/index.d.ts +4 -4
  125. package/dist/layouts/App/ApiClientApp.vue.d.ts +2 -2
  126. package/dist/layouts/App/create-api-client-app.d.ts +106 -66
  127. package/dist/layouts/App/create-api-client-app.d.ts.map +1 -1
  128. package/dist/layouts/App/create-api-client-app.test.d.ts +2 -0
  129. package/dist/layouts/App/create-api-client-app.test.d.ts.map +1 -0
  130. package/dist/layouts/App/index.d.ts +2 -2
  131. package/dist/layouts/Modal/create-api-client-modal.d.ts +215 -135
  132. package/dist/layouts/Modal/create-api-client-modal.d.ts.map +1 -1
  133. package/dist/layouts/Modal/create-api-client-modal.test.d.ts +2 -0
  134. package/dist/layouts/Modal/create-api-client-modal.test.d.ts.map +1 -0
  135. package/dist/layouts/Modal/index.d.ts +2 -2
  136. package/dist/layouts/Web/create-api-client-web.d.ts +106 -66
  137. package/dist/layouts/Web/create-api-client-web.d.ts.map +1 -1
  138. package/dist/layouts/Web/create-api-client-web.test.d.ts +2 -0
  139. package/dist/layouts/Web/create-api-client-web.test.d.ts.map +1 -0
  140. package/dist/layouts/Web/index.d.ts +2 -2
  141. package/dist/libs/create-client.d.ts +106 -66
  142. package/dist/libs/create-client.d.ts.map +1 -1
  143. package/dist/libs/create-client.js +56 -57
  144. package/dist/libs/env-helpers.test.d.ts +2 -0
  145. package/dist/libs/env-helpers.test.d.ts.map +1 -0
  146. package/dist/libs/environment-parser.d.ts +1 -1
  147. package/dist/libs/event-bus.test.d.ts +2 -0
  148. package/dist/libs/event-bus.test.d.ts.map +1 -0
  149. package/dist/libs/extractAttachmentFilename.test.d.ts +2 -0
  150. package/dist/libs/extractAttachmentFilename.test.d.ts.map +1 -0
  151. package/dist/libs/find-request.test.d.ts +2 -0
  152. package/dist/libs/find-request.test.d.ts.map +1 -0
  153. package/dist/libs/getOpenApiDocumentDetails.d.ts +1 -1
  154. package/dist/libs/getOpenApiDocumentDetails.d.ts.map +1 -1
  155. package/dist/libs/hot-keys.d.ts +1 -1
  156. package/dist/libs/importers/curl.js +1 -1
  157. package/dist/libs/importers/curl.test.d.ts +2 -0
  158. package/dist/libs/importers/curl.test.d.ts.map +1 -0
  159. package/dist/libs/importers/index.d.ts +1 -1
  160. package/dist/libs/index.d.ts +16 -16
  161. package/dist/libs/local-storage.d.ts +1 -1
  162. package/dist/libs/normalize-headers.test.d.ts +2 -0
  163. package/dist/libs/normalize-headers.test.d.ts.map +1 -0
  164. package/dist/libs/parse-curl.test.d.ts +2 -0
  165. package/dist/libs/parse-curl.test.d.ts.map +1 -0
  166. package/dist/libs/send-request/build-request-security.d.ts.map +1 -1
  167. package/dist/libs/send-request/build-request-security.js +13 -12
  168. package/dist/libs/send-request/build-request-security.test.d.ts +2 -0
  169. package/dist/libs/send-request/build-request-security.test.d.ts.map +1 -0
  170. package/dist/libs/send-request/create-fetch-auth.test.d.ts +2 -0
  171. package/dist/libs/send-request/create-fetch-auth.test.d.ts.map +1 -0
  172. package/dist/libs/send-request/create-fetch-body.test.d.ts +2 -0
  173. package/dist/libs/send-request/create-fetch-body.test.d.ts.map +1 -0
  174. package/dist/libs/send-request/create-fetch-headers.test.d.ts +2 -0
  175. package/dist/libs/send-request/create-fetch-headers.test.d.ts.map +1 -0
  176. package/dist/libs/send-request/create-fetch-query-params.test.d.ts +2 -0
  177. package/dist/libs/send-request/create-fetch-query-params.test.d.ts.map +1 -0
  178. package/dist/libs/send-request/create-request-operation.d.ts +4 -4
  179. package/dist/libs/send-request/create-request-operation.d.ts.map +1 -1
  180. package/dist/libs/send-request/create-request-operation.js +55 -51
  181. package/dist/libs/send-request/create-request-operation.test.d.ts +171 -0
  182. package/dist/libs/send-request/create-request-operation.test.d.ts.map +1 -0
  183. package/dist/libs/send-request/decode-buffer.test.d.ts +2 -0
  184. package/dist/libs/send-request/decode-buffer.test.d.ts.map +1 -0
  185. package/dist/libs/send-request/index.d.ts +2 -2
  186. package/dist/libs/send-request/set-request-cookies.d.ts +1 -1
  187. package/dist/libs/send-request/set-request-cookies.d.ts.map +1 -1
  188. package/dist/libs/send-request/set-request-cookies.test.d.ts +2 -0
  189. package/dist/libs/send-request/set-request-cookies.test.d.ts.map +1 -0
  190. package/dist/libs/string-template.test.d.ts +2 -0
  191. package/dist/libs/string-template.test.d.ts.map +1 -0
  192. package/dist/router.d.ts +1 -1
  193. package/dist/routes.d.ts +27 -27
  194. package/dist/routes.js +4 -4
  195. package/dist/routes.test.d.ts +2 -0
  196. package/dist/routes.test.d.ts.map +1 -0
  197. package/dist/store/active-entities.d.ts +10 -6
  198. package/dist/store/active-entities.d.ts.map +1 -1
  199. package/dist/store/collections.d.ts +1 -1
  200. package/dist/store/collections.d.ts.map +1 -1
  201. package/dist/store/collections.js +17 -14
  202. package/dist/store/collections.test.d.ts +2 -0
  203. package/dist/store/collections.test.d.ts.map +1 -0
  204. package/dist/store/events.d.ts +7 -7
  205. package/dist/store/import-spec.d.ts +1 -1
  206. package/dist/store/index.d.ts +2 -2
  207. package/dist/store/request-example.d.ts +52 -52
  208. package/dist/store/request-example.d.ts.map +1 -1
  209. package/dist/store/request.test.d.ts +2 -0
  210. package/dist/store/request.test.d.ts.map +1 -0
  211. package/dist/store/requests.d.ts +1 -1
  212. package/dist/store/router-params.d.ts +1 -1
  213. package/dist/store/store.d.ts +103 -63
  214. package/dist/store/store.d.ts.map +1 -1
  215. package/dist/store/store.js +1 -1
  216. package/dist/store/workspace.d.ts +44 -4
  217. package/dist/store/workspace.d.ts.map +1 -1
  218. package/dist/style.css +1 -1
  219. package/dist/views/Components/CodeSnippet/CodeSnippet.test.d.ts +2 -0
  220. package/dist/views/Components/CodeSnippet/CodeSnippet.test.d.ts.map +1 -0
  221. package/dist/views/Components/CodeSnippet/CodeSnippet.vue.d.ts +13 -0
  222. package/dist/views/Components/CodeSnippet/CodeSnippet.vue.d.ts.map +1 -0
  223. package/dist/views/Components/CodeSnippet/CodeSnippet.vue.js +46 -0
  224. package/dist/views/Components/CodeSnippet/CodeSnippet.vue2.js +4 -0
  225. package/dist/views/Components/CodeSnippet/helpers/convert-to-har-request.d.ts +28 -0
  226. package/dist/views/Components/CodeSnippet/helpers/convert-to-har-request.d.ts.map +1 -0
  227. package/dist/views/Components/CodeSnippet/helpers/convert-to-har-request.js +64 -0
  228. package/dist/views/Components/CodeSnippet/helpers/convert-to-har-request.test.d.ts +2 -0
  229. package/dist/views/Components/CodeSnippet/helpers/convert-to-har-request.test.d.ts.map +1 -0
  230. package/dist/views/Components/CodeSnippet/helpers/get-har-request.d.ts +12 -0
  231. package/dist/views/Components/CodeSnippet/helpers/get-har-request.d.ts.map +1 -0
  232. package/dist/views/Components/CodeSnippet/helpers/get-har-request.js +47 -0
  233. package/dist/views/Components/CodeSnippet/helpers/get-har-request.test.d.ts +2 -0
  234. package/dist/views/Components/CodeSnippet/helpers/get-har-request.test.d.ts.map +1 -0
  235. package/dist/views/Components/CodeSnippet/helpers/get-snippet.d.ts +13 -0
  236. package/dist/views/Components/CodeSnippet/helpers/get-snippet.d.ts.map +1 -0
  237. package/dist/views/Components/CodeSnippet/helpers/get-snippet.js +47 -0
  238. package/dist/views/Components/CodeSnippet/helpers/get-snippet.test.d.ts +2 -0
  239. package/dist/views/Components/CodeSnippet/helpers/get-snippet.test.d.ts.map +1 -0
  240. package/dist/views/Components/CodeSnippet/index.d.ts +5 -0
  241. package/dist/views/Components/CodeSnippet/index.d.ts.map +1 -0
  242. package/dist/views/Components/CodeSnippet/index.js +10 -0
  243. package/dist/views/Cookies/CookieModal.vue.d.ts +3 -3
  244. package/dist/views/Cookies/Cookies.vue.d.ts.map +1 -1
  245. package/dist/views/Cookies/Cookies.vue2.js +77 -70
  246. package/dist/views/Environment/Environment.vue.d.ts.map +1 -1
  247. package/dist/views/Environment/Environment.vue2.js +127 -113
  248. package/dist/views/Environment/EnvironmentColorModal.vue.d.ts +2 -2
  249. package/dist/views/Environment/EnvironmentColors.vue.d.ts +1 -1
  250. package/dist/views/Environment/EnvironmentModal.vue.d.ts +6 -6
  251. package/dist/views/Environment/EnvironmentModal.vue.d.ts.map +1 -1
  252. package/dist/views/Environment/EnvironmentModal.vue.js +1 -1
  253. package/dist/views/Environment/EnvironmentVariableDropdown.vue.d.ts +2 -2
  254. package/dist/views/Request/Request.vue.d.ts +2 -2
  255. package/dist/views/Request/Request.vue.d.ts.map +1 -1
  256. package/dist/views/Request/Request.vue.js +2 -2
  257. package/dist/views/Request/Request.vue2.js +92 -86
  258. package/dist/views/Request/RequestSection/RequestAuth/DeleteRequestAuthModal.vue.d.ts +2 -2
  259. package/dist/views/Request/RequestSection/RequestAuth/OAuthScopesInput.vue.d.ts +1 -1
  260. package/dist/views/Request/RequestSection/RequestAuth/RequestAuth.test.d.ts +2 -0
  261. package/dist/views/Request/RequestSection/RequestAuth/RequestAuth.test.d.ts.map +1 -0
  262. package/dist/views/Request/RequestSection/RequestAuth/RequestAuth.vue.d.ts +1 -1
  263. package/dist/views/Request/RequestSection/RequestAuth/RequestAuth.vue.d.ts.map +1 -1
  264. package/dist/views/Request/RequestSection/RequestAuth/RequestAuth.vue.js +2 -2
  265. package/dist/views/Request/RequestSection/RequestAuth/RequestAuthDataTableInput.vue.d.ts +4 -4
  266. package/dist/views/Request/RequestSection/RequestAuth/RequestAuthDataTableInput.vue.d.ts.map +1 -1
  267. package/dist/views/Request/RequestSection/RequestAuth/index.d.ts +2 -2
  268. package/dist/views/Request/RequestSection/RequestBody.test.d.ts +2 -0
  269. package/dist/views/Request/RequestSection/RequestBody.test.d.ts.map +1 -0
  270. package/dist/views/Request/RequestSection/RequestBody.vue.d.ts.map +1 -1
  271. package/dist/views/Request/RequestSection/RequestBody.vue.js +2 -2
  272. package/dist/views/Request/RequestSection/RequestBody.vue2.js +20 -20
  273. package/dist/views/Request/RequestSection/RequestCodeExample.vue.d.ts +3 -0
  274. package/dist/views/Request/RequestSection/RequestCodeExample.vue.d.ts.map +1 -0
  275. package/dist/views/Request/RequestSection/RequestCodeExample.vue.js +7 -0
  276. package/dist/views/Request/RequestSection/RequestCodeExample.vue2.js +141 -0
  277. package/dist/views/Request/RequestSection/RequestParams.vue.d.ts.map +1 -1
  278. package/dist/views/Request/RequestSection/RequestParams.vue.js +53 -59
  279. package/dist/views/Request/RequestSection/RequestSection.vue.d.ts.map +1 -1
  280. package/dist/views/Request/RequestSection/RequestSection.vue.js +1 -1
  281. package/dist/views/Request/RequestSection/RequestSection.vue2.js +71 -62
  282. package/dist/views/Request/RequestSection/RequestTable.vue.d.ts +8 -8
  283. package/dist/views/Request/RequestSection/RequestTable.vue.js +2 -2
  284. package/dist/views/Request/RequestSection/RequestTable.vue2.js +59 -59
  285. package/dist/views/Request/RequestSection/helpers/filter-security-requirements.d.ts +6 -0
  286. package/dist/views/Request/RequestSection/helpers/filter-security-requirements.d.ts.map +1 -0
  287. package/dist/views/Request/RequestSection/helpers/filter-security-requirements.js +20 -0
  288. package/dist/views/Request/RequestSection/helpers/filter-security-requirements.test.d.ts +2 -0
  289. package/dist/views/Request/RequestSection/helpers/filter-security-requirements.test.d.ts.map +1 -0
  290. package/dist/views/Request/RequestSection/helpers/getting-started.d.ts +6 -0
  291. package/dist/views/Request/RequestSection/helpers/getting-started.d.ts.map +1 -0
  292. package/dist/views/Request/RequestSection/helpers/getting-started.js +17 -0
  293. package/dist/views/Request/RequestSection/helpers/getting-started.test.d.ts +2 -0
  294. package/dist/views/Request/RequestSection/helpers/getting-started.test.d.ts.map +1 -0
  295. package/dist/views/Request/RequestSection/index.d.ts +2 -1
  296. package/dist/views/Request/RequestSection/index.d.ts.map +1 -1
  297. package/dist/views/Request/RequestSection/index.js +4 -2
  298. package/dist/views/Request/RequestSidebar.vue.d.ts +5 -5
  299. package/dist/views/Request/RequestSidebar.vue.d.ts.map +1 -1
  300. package/dist/views/Request/RequestSidebar.vue.js +2 -2
  301. package/dist/views/Request/RequestSidebar.vue2.js +211 -193
  302. package/dist/views/Request/RequestSidebarItem.vue.d.ts +18 -31
  303. package/dist/views/Request/RequestSidebarItem.vue.d.ts.map +1 -1
  304. package/dist/views/Request/RequestSidebarItem.vue.js +1 -1
  305. package/dist/views/Request/RequestSidebarItem.vue2.js +113 -113
  306. package/dist/views/Request/RequestSidebarItemMenu.vue.d.ts +5 -5
  307. package/dist/views/Request/RequestSidebarItemMenu.vue.d.ts.map +1 -1
  308. package/dist/views/Request/RequestSidebarItemMenu.vue.js +1 -1
  309. package/dist/views/Request/RequestSidebarItemMenu.vue2.js +120 -101
  310. package/dist/views/Request/RequestSubpageHeader.test.d.ts +2 -0
  311. package/dist/views/Request/RequestSubpageHeader.test.d.ts.map +1 -0
  312. package/dist/views/Request/RequestSubpageHeader.vue.d.ts +3 -3
  313. package/dist/views/Request/RequestSubpageHeader.vue.js +1 -1
  314. package/dist/views/Request/RequestSubpageHeader.vue2.js +1 -1
  315. package/dist/views/Request/ResponseSection/ResponseBody.vue.d.ts.map +1 -1
  316. package/dist/views/Request/ResponseSection/ResponseBody.vue.js +2 -2
  317. package/dist/views/Request/ResponseSection/ResponseBody.vue2.js +50 -64
  318. package/dist/views/Request/ResponseSection/ResponseBodyPreview.vue.d.ts +3 -3
  319. package/dist/views/Request/ResponseSection/ResponseBodyPreview.vue.d.ts.map +1 -1
  320. package/dist/views/Request/ResponseSection/ResponseBodyPreview.vue.js +1 -1
  321. package/dist/views/Request/ResponseSection/ResponseBodyPreview.vue2.js +27 -27
  322. package/dist/views/Request/ResponseSection/ResponseBodyRaw.vue.d.ts +1 -1
  323. package/dist/views/Request/ResponseSection/ResponseBodyRaw.vue.d.ts.map +1 -1
  324. package/dist/views/Request/ResponseSection/ResponseBodyRaw.vue.js +2 -2
  325. package/dist/views/Request/ResponseSection/ResponseBodyToggle.vue.d.ts +1 -1
  326. package/dist/views/Request/ResponseSection/ResponseBodyVirtual.test.d.ts +2 -0
  327. package/dist/views/Request/ResponseSection/ResponseBodyVirtual.test.d.ts.map +1 -0
  328. package/dist/views/Request/ResponseSection/ResponseBodyVirtual.vue.d.ts +6 -0
  329. package/dist/views/Request/ResponseSection/ResponseBodyVirtual.vue.d.ts.map +1 -1
  330. package/dist/views/Request/ResponseSection/ResponseBodyVirtual.vue.js +38 -19
  331. package/dist/views/Request/ResponseSection/ResponseEmpty.vue2.js +1 -1
  332. package/dist/views/Request/ResponseSection/ResponseSection.vue.d.ts.map +1 -1
  333. package/dist/views/Request/ResponseSection/ResponseSection.vue.js +1 -1
  334. package/dist/views/Request/ResponseSection/ResponseSection.vue2.js +30 -28
  335. package/dist/views/Request/ResponseSection/index.d.ts +1 -1
  336. package/dist/views/Request/components/index.d.ts +1 -1
  337. package/dist/views/Request/consts/index.d.ts +3 -3
  338. package/dist/views/Request/handle-drag.d.ts +2 -2
  339. package/dist/views/Request/libs/auth.d.ts +1 -1
  340. package/dist/views/Request/libs/auth.test.d.ts +2 -0
  341. package/dist/views/Request/libs/auth.test.d.ts.map +1 -0
  342. package/dist/views/Request/libs/index.d.ts +2 -2
  343. package/dist/views/Request/libs/oauth2.d.ts +2 -2
  344. package/dist/views/Request/libs/oauth2.d.ts.map +1 -1
  345. package/dist/views/Request/libs/oauth2.js +7 -7
  346. package/dist/views/Request/libs/oauth2.test.d.ts +2 -0
  347. package/dist/views/Request/libs/oauth2.test.d.ts.map +1 -0
  348. package/dist/views/Request/libs/request.test.d.ts +2 -0
  349. package/dist/views/Request/libs/request.test.d.ts.map +1 -0
  350. package/dist/views/Request/libs/watch-mode.d.ts +2 -2
  351. package/dist/views/Request/libs/watch-mode.test.d.ts +2 -0
  352. package/dist/views/Request/libs/watch-mode.test.d.ts.map +1 -0
  353. package/dist/views/Request/types/sidebar-item.d.ts +2 -2
  354. package/dist/views/Request/types/sidebar-item.d.ts.map +1 -1
  355. package/dist/views/Servers/Servers.vue.d.ts.map +1 -1
  356. package/dist/views/Servers/Servers.vue2.js +73 -63
  357. package/dist/views/Servers/index.d.ts +1 -1
  358. package/dist/views/Settings/components/SettingsAppearance.vue.js +6 -6
  359. package/package.json +21 -15
package/CHANGELOG.md CHANGED
@@ -1,5 +1,56 @@
1
1
  # @scalar/api-client
2
2
 
3
+ ## 2.2.47
4
+
5
+ ### Patch Changes
6
+
7
+ - d028579: fix: only send scopes during certain oauth2 auth calls
8
+ - c5e9597: feat: adds useRequestBody hook"
9
+ - bdddb12: fix: updates request sidebar height responsiveness
10
+ - f500435: chore: stricter TypeScript configuration
11
+ - c5e9597: feat: adds download button in virtual response
12
+ - f9a75af: fix: routing broken on servers and environment page
13
+ - a515167: fix: adds setting apparence button hover
14
+ - 82c8f39: Allow custom value in parameters
15
+ - b2a19ba: fix: updates empty state hotkey style
16
+ - fa59538: fix: make headers take priority over auth
17
+ - 34e6f52: feat: upgrade to stricter tsconfig
18
+ - bdddb12: fix: updates getting started state logic in request sidebar
19
+ - d2165a8: refactor: use more named routes
20
+ - 4de3124: fix: can’t import type array e.g. `['string', 'null']`
21
+ - Updated dependencies [4de3124]
22
+ - Updated dependencies [69da9e0]
23
+ - Updated dependencies [f500435]
24
+ - Updated dependencies [da5cf08]
25
+ - Updated dependencies [b5727ef]
26
+ - Updated dependencies [4de3124]
27
+ - Updated dependencies [f9eee3f]
28
+ - Updated dependencies [34e6f52]
29
+ - Updated dependencies [f2b082a]
30
+ - @scalar/openapi-parser@0.10.6
31
+ - @scalar/components@0.13.23
32
+ - @scalar/draggable@0.1.9
33
+ - @scalar/oas-utils@0.2.104
34
+ - @scalar/types@0.0.32
35
+ - @scalar/snippetz@0.2.12
36
+ - @scalar/import@0.2.24
37
+ - @scalar/use-codemirror@0.11.68
38
+ - @scalar/postman-to-openapi@0.1.27
39
+ - @scalar/themes@0.9.66
40
+ - @scalar/use-hooks@0.1.20
41
+
42
+ ## 2.2.46
43
+
44
+ ### Patch Changes
45
+
46
+ - abc40ce: feat: adds request preview
47
+ - 0b18abe: fix: adds back request in search
48
+ - e4f11d8: fix: removes servers on collection deletion
49
+ - 2969dd0: fix: updates sidenav link active style for lightmode
50
+ - Updated dependencies [abc40ce]
51
+ - @scalar/components@0.13.22
52
+ - @scalar/use-codemirror@0.11.67
53
+
3
54
  ## 2.2.45
4
55
 
5
56
  ### Patch Changes
@@ -1,7 +1,7 @@
1
1
  declare const _default: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {} & {
2
2
  importCurl: (value: string) => any;
3
3
  }, string, import("vue").PublicProps, Readonly<{}> & Readonly<{
4
- onImportCurl?: ((value: string) => any) | undefined;
4
+ onImportCurl?: (value: string) => any;
5
5
  }>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
6
6
  export default _default;
7
7
  //# sourceMappingURL=AddressBar.vue.d.ts.map
@@ -1,7 +1,7 @@
1
1
  import o from "./AddressBar.vue2.js";
2
2
  /* empty css */
3
3
  import r from "../../_virtual/_plugin-vue_export-helper.js";
4
- const f = /* @__PURE__ */ r(o, [["__scopeId", "data-v-2b1591cf"]]);
4
+ const d = /* @__PURE__ */ r(o, [["__scopeId", "data-v-f37ba3d4"]]);
5
5
  export {
6
- f as default
6
+ d as default
7
7
  };
@@ -52,8 +52,7 @@ const ee = ["id"], te = { class: "m-auto flex flex-row items-center" }, le = { c
52
52
  return F[e].backgroundColor;
53
53
  }
54
54
  function p() {
55
- var e;
56
- s.value || (s.value = !0, v.executeRequest.emit({ requestUid: (e = l.value) == null ? void 0 : e.uid }));
55
+ s.value || !l.value || (s.value = !0, v.executeRequest.emit({ requestUid: l.value.uid }));
57
56
  }
58
57
  v.hotKeys.on((e) => {
59
58
  var a;
@@ -1 +1 @@
1
- {"version":3,"file":"AddressBarHistory.vue.d.ts","sourceRoot":"","sources":["../../../src/components/AddressBar/AddressBarHistory.vue"],"names":[],"mappings":"AAiLA,KAAK,WAAW,GAAG;IACjB,qEAAqE;IACrE,MAAM,EAAE,MAAM,CAAA;CACf,CAAC;;AAmQF,wBAOG"}
1
+ {"version":3,"file":"AddressBarHistory.vue.d.ts","sourceRoot":"","sources":["../../../src/components/AddressBar/AddressBarHistory.vue"],"names":[],"mappings":"AA0LA,KAAK,WAAW,GAAG;IACjB,qEAAqE;IACrE,MAAM,EAAE,MAAM,CAAA;CACf,CAAC;;AA0QF,wBAOG"}
@@ -1,7 +1,7 @@
1
1
  import o from "./AddressBarHistory.vue2.js";
2
2
  /* empty css */
3
3
  import r from "../../_virtual/_plugin-vue_export-helper.js";
4
- const a = /* @__PURE__ */ r(o, [["__scopeId", "data-v-f70f1917"]]);
4
+ const f = /* @__PURE__ */ r(o, [["__scopeId", "data-v-3f107c93"]]);
5
5
  export {
6
- a as default
6
+ f as default
7
7
  };
@@ -1,20 +1,21 @@
1
- import { defineComponent as q, ref as C, computed as y, openBlock as n, createBlock as i, unref as e, withCtx as a, createVNode as d, createSlots as S, createElementVNode as l, createCommentVNode as h, normalizeStyle as w, createElementBlock as B, Fragment as H, renderList as V, toDisplayString as c, normalizeClass as z } from "vue";
2
- import { formatMs as L } from "../../libs/formatters.js";
3
- import { useActiveEntities as E } from "../../store/active-entities.js";
4
- import { Listbox as U, ListboxButton as F, ListboxOptions as M, ListboxOption as N } from "@headlessui/vue";
5
- import { ScalarFloating as R, ScalarIcon as $, ScalarFloatingBackdrop as A } from "@scalar/components";
6
- import { httpStatusCodes as I } from "@scalar/oas-utils/helpers";
7
- import { useRouter as O } from "vue-router";
8
- import D from "../HttpMethod/HttpMethod.vue.js";
9
- import { getStatusCodeColor as W } from "./httpStatusCodeColors.js";
1
+ import { defineComponent as C, ref as y, computed as S, openBlock as n, createBlock as i, unref as e, withCtx as a, createVNode as d, createSlots as B, createElementVNode as l, createCommentVNode as h, normalizeStyle as H, createElementBlock as V, Fragment as w, renderList as z, toDisplayString as m, normalizeClass as L } from "vue";
2
+ import { formatMs as E } from "../../libs/formatters.js";
3
+ import { PathId as k } from "../../routes.js";
4
+ import { useActiveEntities as R } from "../../store/active-entities.js";
5
+ import { Listbox as U, ListboxButton as F, ListboxOptions as I, ListboxOption as M } from "@headlessui/vue";
6
+ import { ScalarFloating as N, ScalarIcon as A, ScalarFloatingBackdrop as O } from "@scalar/components";
7
+ import { httpStatusCodes as W } from "@scalar/oas-utils/helpers";
8
+ import { useRouter as D } from "vue-router";
9
+ import P from "../HttpMethod/HttpMethod.vue.js";
10
+ import { getStatusCodeColor as $ } from "./httpStatusCodeColors.js";
10
11
  import { useWorkspace as j } from "../../store/store.js";
11
- const G = { class: "min-w-0" }, J = { class: "min-w-0 truncate text-c-1" }, re = /* @__PURE__ */ q({
12
+ const G = { class: "min-w-0" }, J = { class: "min-w-0 truncate text-c-1" }, le = /* @__PURE__ */ C({
12
13
  __name: "AddressBarHistory",
13
14
  props: {
14
15
  target: {}
15
16
  },
16
17
  setup(K) {
17
- const { activeRequest: p } = E(), { requestHistory: f, requestExampleMutators: k } = j(), v = O(), x = C(f[0]), g = y(
18
+ const { activeRequest: p } = R(), { requestHistory: f, requestExampleMutators: q } = j(), v = D(), x = y(f[0] ?? null), g = S(
18
19
  () => f.filter((o) => {
19
20
  var t;
20
21
  return o.request.requestUid === ((t = p.value) == null ? void 0 : t.uid);
@@ -23,20 +24,24 @@ const G = { class: "min-w-0" }, J = { class: "min-w-0 truncate text-c-1" }, re =
23
24
  function _(o) {
24
25
  var r;
25
26
  const t = v.currentRoute.value.params.workspace;
26
- ((r = p.value) == null ? void 0 : r.uid) !== o.request.requestUid && v.push(
27
- `/workspace/${t}/request/${o.request.requestUid}`
28
- ), k.set({ ...o.request });
27
+ ((r = p.value) == null ? void 0 : r.uid) !== o.request.requestUid && v.push({
28
+ name: "request",
29
+ params: {
30
+ [k.Workspace]: t,
31
+ [k.Request]: o.request.requestUid
32
+ }
33
+ }), q.set({ ...o.request });
29
34
  }
30
35
  return (o, t) => (n(), i(e(U), {
31
36
  modelValue: x.value,
32
37
  "onUpdate:modelValue": t[0] || (t[0] = (r) => x.value = r)
33
38
  }, {
34
39
  default: a(({ open: r }) => [
35
- d(e(R), {
40
+ d(e(N), {
36
41
  offset: 0,
37
42
  resize: "",
38
43
  target: o.target
39
- }, S({
44
+ }, B({
40
45
  default: a(() => {
41
46
  var u;
42
47
  return [
@@ -45,7 +50,7 @@ const G = { class: "min-w-0" }, J = { class: "min-w-0 truncate text-c-1" }, re =
45
50
  class: "addressbar-history-button z-context-plus mr-1 rounded-lg p-1.5 text-c-3 focus:text-c-1"
46
51
  }, {
47
52
  default: a(() => [
48
- d(e($), {
53
+ d(e(A), {
49
54
  icon: "History",
50
55
  size: "sm",
51
56
  thickness: "2.25"
@@ -61,33 +66,33 @@ const G = { class: "min-w-0" }, J = { class: "min-w-0 truncate text-c-1" }, re =
61
66
  r ? {
62
67
  name: "floating",
63
68
  fn: a(({ width: u }) => [
64
- d(e(M), {
69
+ d(e(I), {
65
70
  class: "address-bg-states border-t custom-scroll max-h-[inherit] p-0.75 grid grid-cols-[44px,1fr,repeat(3,auto)] items-center",
66
- style: w({ width: u })
71
+ style: H({ width: u })
67
72
  }, {
68
73
  default: a(() => [
69
- (n(!0), B(H, null, V(g.value, (s, b) => (n(), i(e(N), {
74
+ (n(!0), V(w, null, z(g.value, (s, b) => (n(), i(e(M), {
70
75
  key: s.timestamp,
71
76
  class: "contents font-code text-sm *:rounded-none first:*:rounded-l last:*:rounded-r *:h-8 *:ui-active:bg-b-2 *:flex *:items-center *:cursor-pointer *:px-1.5 text-c-2 font-medium",
72
77
  value: b,
73
- onClick: (m) => _(s)
78
+ onClick: (c) => _(s)
74
79
  }, {
75
80
  default: a(() => {
76
- var m;
81
+ var c;
77
82
  return [
78
- s.response.method ? (n(), i(D, {
83
+ s.response.method ? (n(), i(P, {
79
84
  key: 0,
80
85
  class: "text-[11px]",
81
86
  method: s.response.method
82
87
  }, null, 8, ["method"])) : h("", !0),
83
88
  l("div", G, [
84
- l("div", J, c(s.response.path), 1)
89
+ l("div", J, m(s.response.path), 1)
85
90
  ]),
86
- l("div", null, c(e(L)(s.response.duration)), 1),
91
+ l("div", null, m(e(E)(s.response.duration)), 1),
87
92
  l("div", {
88
- class: z([e(W)(s.response.status).color])
89
- }, c(s.response.status), 3),
90
- l("div", null, c((m = e(I)[s.response.status]) == null ? void 0 : m.name), 1)
93
+ class: L([e($)(s.response.status).color])
94
+ }, m(s.response.status), 3),
95
+ l("div", null, m((c = e(W)[s.response.status]) == null ? void 0 : c.name), 1)
91
96
  ];
92
97
  }),
93
98
  _: 2
@@ -95,7 +100,7 @@ const G = { class: "min-w-0" }, J = { class: "min-w-0 truncate text-c-1" }, re =
95
100
  ]),
96
101
  _: 2
97
102
  }, 1032, ["style"]),
98
- d(e(A), { class: "-top-[--scalar-address-bar-height] rounded-lg" })
103
+ d(e(O), { class: "-top-[--scalar-address-bar-height] rounded-lg" })
99
104
  ]),
100
105
  key: "0"
101
106
  } : void 0
@@ -106,5 +111,5 @@ const G = { class: "min-w-0" }, J = { class: "min-w-0 truncate text-c-1" }, re =
106
111
  }
107
112
  });
108
113
  export {
109
- re as default
114
+ le as default
110
115
  };
@@ -1,2 +1,2 @@
1
- export { default as AddressBar } from './AddressBar.vue.js';
1
+ export { default as AddressBar } from './AddressBar.vue';
2
2
  //# sourceMappingURL=index.d.ts.map
@@ -17,7 +17,7 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
17
17
  disableCloseBrackets?: boolean;
18
18
  enum?: string[];
19
19
  examples?: string[];
20
- type?: string;
20
+ type?: string | string[] | undefined;
21
21
  nullable?: boolean;
22
22
  withVariables?: boolean;
23
23
  importCurl?: boolean;
@@ -47,16 +47,16 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
47
47
  disableCloseBrackets?: boolean;
48
48
  enum?: string[];
49
49
  examples?: string[];
50
- type?: string;
50
+ type?: string | string[] | undefined;
51
51
  nullable?: boolean;
52
52
  withVariables?: boolean;
53
53
  importCurl?: boolean;
54
54
  isCopyable?: boolean;
55
55
  default?: string | number;
56
56
  }> & Readonly<{
57
- onSubmit?: ((v: string) => any) | undefined;
58
- "onUpdate:modelValue"?: ((v: string) => any) | undefined;
59
- onCurl?: ((v: string) => any) | undefined;
57
+ onSubmit?: (v: string) => any;
58
+ "onUpdate:modelValue"?: (v: string) => any;
59
+ onCurl?: (v: string) => any;
60
60
  }>, {
61
61
  disabled: boolean;
62
62
  emitOnBlur: boolean;
@@ -1 +1 @@
1
- {"version":3,"file":"CodeInput.vue.d.ts","sourceRoot":"","sources":["../../../src/components/CodeInput/CodeInput.vue"],"names":[],"mappings":"AAAA,OA+dO,EAGL,KAAK,kBAAkB,EAGxB,MAAM,wBAAwB,CAAA;;kBAkBb,OAAO;eACV,OAAO;gBACN,MAAM,GAAG,MAAM;YACnB,OAAO;iBACF,OAAO;kBACN,OAAO;WACd,OAAO;uBACK,OAAO;eACf,kBAAkB;wBACT,CAAC,CAAC,EAAE,MAAM,KAAK,IAAI;wBACnB,CAAC,CAAC,EAAE,MAAM,KAAK,IAAI;kBACzB,MAAM;eACT,OAAO;mBACH,OAAO;2BACC,OAAO;WACvB,MAAM,EAAE;eACJ,MAAM,EAAE;WACZ,MAAM;eACF,OAAO;oBACF,OAAO;iBACV,OAAO;iBACP,OAAO;cACV,MAAM,GAAG,MAAM;;;;;;;;kBAtBX,OAAO;eACV,OAAO;gBACN,MAAM,GAAG,MAAM;YACnB,OAAO;iBACF,OAAO;kBACN,OAAO;WACd,OAAO;uBACK,OAAO;eACf,kBAAkB;wBACT,CAAC,CAAC,EAAE,MAAM,KAAK,IAAI;wBACnB,CAAC,CAAC,EAAE,MAAM,KAAK,IAAI;kBACzB,MAAM;eACT,OAAO;mBACH,OAAO;2BACC,OAAO;WACvB,MAAM,EAAE;eACJ,MAAM,EAAE;WACZ,MAAM;eACF,OAAO;oBACF,OAAO;iBACV,OAAO;iBACP,OAAO;cACV,MAAM,GAAG,MAAM;;;;;;cArBd,OAAO;gBAGL,OAAO;iBAJN,OAAO;sBAOF,OAAO;kBAMX,OAAO;0BACC,OAAO;cAInB,OAAO;mBACF,OAAO;gBAEV,OAAO;;qBAycM,GAAG;kBACN,GAAG;;AAle9B,wBA8hBC;AAgBD,KAAK,uBAAuB,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IACxC,QAAO;QACN,MAAM,EAAE,CAAC,CAAC;KAEV,CAAA;CACD,CAAC"}
1
+ {"version":3,"file":"CodeInput.vue.d.ts","sourceRoot":"","sources":["../../../src/components/CodeInput/CodeInput.vue"],"names":[],"mappings":"AAAA,OAueO,EAGL,KAAK,kBAAkB,EAGxB,MAAM,wBAAwB,CAAA;;kBAkBb,OAAO;eACV,OAAO;gBACN,MAAM,GAAG,MAAM;YACnB,OAAO;iBACF,OAAO;kBACN,OAAO;WACd,OAAO;uBACK,OAAO;eACf,kBAAkB;wBACT,CAAC,CAAC,EAAE,MAAM,KAAK,IAAI;wBACnB,CAAC,CAAC,EAAE,MAAM,KAAK,IAAI;kBACzB,MAAM;eACT,OAAO;mBACH,OAAO;2BACC,OAAO;WACvB,MAAM,EAAE;eACJ,MAAM,EAAE;WACZ,MAAM,GAAG,MAAM,EAAE,GAAG,SAAS;eACzB,OAAO;oBACF,OAAO;iBACV,OAAO;iBACP,OAAO;cACV,MAAM,GAAG,MAAM;;;;;;;;kBAtBX,OAAO;eACV,OAAO;gBACN,MAAM,GAAG,MAAM;YACnB,OAAO;iBACF,OAAO;kBACN,OAAO;WACd,OAAO;uBACK,OAAO;eACf,kBAAkB;wBACT,CAAC,CAAC,EAAE,MAAM,KAAK,IAAI;wBACnB,CAAC,CAAC,EAAE,MAAM,KAAK,IAAI;kBACzB,MAAM;eACT,OAAO;mBACH,OAAO;2BACC,OAAO;WACvB,MAAM,EAAE;eACJ,MAAM,EAAE;WACZ,MAAM,GAAG,MAAM,EAAE,GAAG,SAAS;eACzB,OAAO;oBACF,OAAO;iBACV,OAAO;iBACP,OAAO;cACV,MAAM,GAAG,MAAM;;;;;;cArBd,OAAO;gBAGL,OAAO;iBAJN,OAAO;sBAOF,OAAO;kBAMX,OAAO;0BACC,OAAO;cAInB,OAAO;mBACF,OAAO;gBAEV,OAAO;;qBAidM,GAAG;kBACN,GAAG;;AA1e9B,wBAuiBC;AAeD,KAAK,uBAAuB,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IACxC,QAAO;QACN,MAAM,EAAE,CAAC,CAAC;KAEV,CAAA;CACD,CAAC"}
@@ -2,7 +2,7 @@ import o from "./CodeInput.vue2.js";
2
2
  /* empty css */
3
3
  /* empty css */
4
4
  import t from "../../_virtual/_plugin-vue_export-helper.js";
5
- const _ = /* @__PURE__ */ t(o, [["__scopeId", "data-v-0766b3e2"]]);
5
+ const e = /* @__PURE__ */ t(o, [["__scopeId", "data-v-d7ef0a30"]]);
6
6
  export {
7
- _ as default
7
+ e as default
8
8
  };
@@ -1,30 +1,30 @@
1
- import { defineComponent as W, useAttrs as J, ref as d, toRef as u, watch as Q, computed as G, openBlock as n, createElementBlock as i, Fragment as H, createElementVNode as w, toDisplayString as X, createBlock as f, mergeProps as Y, unref as a, withKeys as V, withModifiers as $, createVNode as Z, createCommentVNode as c, renderSlot as q } from "vue";
2
- import { useCodeMirror as _, useDropdown as ee, colorPicker as oe } from "@scalar/use-codemirror";
3
- import { nanoid as le } from "nanoid";
1
+ import { defineComponent as Q, useAttrs as G, ref as d, toRef as u, watch as H, computed as $, openBlock as n, createElementBlock as i, Fragment as X, createElementVNode as w, toDisplayString as Y, createBlock as m, mergeProps as Z, unref as a, withKeys as V, withModifiers as q, createVNode as _, createCommentVNode as c, renderSlot as A } from "vue";
2
+ import { useCodeMirror as ee, useDropdown as oe, colorPicker as le } from "@scalar/use-codemirror";
3
+ import { nanoid as te } from "nanoid";
4
4
  import g from "../DataTable/DataTableInputSelect.vue.js";
5
- import { pillPlugin as te, backspaceCommand as ne } from "./codeVariableWidget.js";
6
- import ae from "../../views/Environment/EnvironmentVariableDropdown.vue.js";
7
- import { useClipboard as re } from "@scalar/use-hooks/useClipboard";
8
- import { ScalarIcon as ue } from "@scalar/components";
9
- import { prettyPrintJson as se } from "@scalar/oas-utils/helpers";
10
- import { useActiveEntities as de } from "../../store/active-entities.js";
11
- import { useLayout as ie } from "../../hooks/useLayout.js";
12
- const pe = {
5
+ import { pillPlugin as ne, backspaceCommand as ae } from "./codeVariableWidget.js";
6
+ import re from "../../views/Environment/EnvironmentVariableDropdown.vue.js";
7
+ import { useClipboard as ue } from "@scalar/use-hooks/useClipboard";
8
+ import { ScalarIcon as se } from "@scalar/components";
9
+ import { prettyPrintJson as de } from "@scalar/oas-utils/helpers";
10
+ import { useActiveEntities as ie } from "../../store/active-entities.js";
11
+ import { useLayout as pe } from "../../hooks/useLayout.js";
12
+ const fe = {
13
13
  key: 0,
14
14
  class: "cursor-default flex items-center justify-center px-2 text-c-2"
15
- }, me = ["id"], fe = {
15
+ }, me = ["id"], ce = {
16
16
  key: 0,
17
17
  class: "scalar-code-copy z-context"
18
- }, ce = {
18
+ }, ye = {
19
19
  key: 5,
20
20
  class: "absolute centered-y right-7 text-orange text-xs"
21
- }, ye = {
21
+ }, be = {
22
22
  key: 6,
23
23
  class: "required absolute centered-y right-0 pt-px pr-2 text-xxs text-c-3 bg-b-1 shadow-[-8px_0_4px_var(--scalar-background-1)] opacity-100 duration-150 transition-opacity peer-has-[.cm-focused]:opacity-0 pointer-events-none"
24
- }, be = {
24
+ }, ve = {
25
25
  inheritAttrs: !1
26
- }, De = /* @__PURE__ */ W({
27
- ...be,
26
+ }, Fe = /* @__PURE__ */ Q({
27
+ ...ve,
28
28
  __name: "CodeInput",
29
29
  props: {
30
30
  colorPicker: { type: Boolean, default: !1 },
@@ -54,8 +54,8 @@ const pe = {
54
54
  emits: ["submit", "update:modelValue", "curl"],
55
55
  setup(R, { expose: N, emit: O }) {
56
56
  var F;
57
- const o = R, s = O, B = J(), A = B.id || `id-${le()}`, k = d(!1), y = d(!1), C = d(""), S = d({ left: 0, top: 0 }), m = d(null), { activeEnvVariables: P, activeEnvironment: b, activeWorkspace: I } = de(), { layout: x } = ie(), { copyToClipboard: K } = re();
58
- function M(e) {
57
+ const o = R, s = O, B = G(), I = B.id || `id-${te()}`, k = d(!1), y = d(!1), C = d(""), S = d({ left: 0, top: 0 }), f = d(null), { activeEnvVariables: x, activeEnvironment: b, activeWorkspace: K } = ie(), { layout: P } = pe(), { copyToClipboard: M } = ue();
58
+ function T(e) {
59
59
  var l;
60
60
  return e === o.modelValue ? null : o.importCurl && e.trim().toLowerCase().startsWith("curl") ? (s("curl", e), (l = r.value) == null || l.dispatch({
61
61
  changes: {
@@ -65,31 +65,31 @@ const pe = {
65
65
  }
66
66
  }), null) : o.handleFieldChange ? o.handleFieldChange(e) : s("update:modelValue", e);
67
67
  }
68
- function T(e) {
68
+ function U(e) {
69
69
  return o.handleFieldSubmit ? o.handleFieldSubmit(e) : s("submit", e);
70
70
  }
71
- function U(e) {
72
- k.value = !1, o.emitOnBlur && o.modelValue && T(e);
71
+ function j(e) {
72
+ k.value = !1, o.emitOnBlur && o.modelValue && U(e);
73
73
  }
74
74
  const v = [];
75
- o.colorPicker && v.push(oe), v.push(
76
- te({
75
+ o.colorPicker && v.push(le), v.push(
76
+ ne({
77
77
  environment: b.value,
78
- envVariables: P.value,
79
- workspace: I.value,
80
- isReadOnly: x === "modal"
78
+ envVariables: x.value,
79
+ workspace: K.value,
80
+ isReadOnly: P === "modal"
81
81
  }),
82
- ne
82
+ ae
83
83
  );
84
- const D = d(null), { codeMirror: r } = _({
84
+ const D = d(null), { codeMirror: r } = ee({
85
85
  content: u(
86
86
  () => o.modelValue !== void 0 ? String(o.modelValue) : ""
87
87
  ),
88
88
  onChange: (e) => {
89
- M(e), z();
89
+ T(e), L();
90
90
  },
91
91
  onFocus: () => k.value = !0,
92
- onBlur: (e) => U(e),
92
+ onBlur: (e) => j(e),
93
93
  codeMirrorRef: D,
94
94
  disableTabIndent: u(() => o.disableTabIndent),
95
95
  disableEnter: u(() => o.disableEnter),
@@ -100,15 +100,15 @@ const pe = {
100
100
  extensions: v,
101
101
  placeholder: u(() => o.placeholder)
102
102
  });
103
- (F = r.value) == null || F.focus(), Q(r, () => {
103
+ (F = r.value) == null || F.focus(), H(r, () => {
104
104
  r.value && Object.prototype.hasOwnProperty.call(B, "autofocus") && r.value.focus();
105
105
  });
106
- const { handleDropdownSelect: j, updateDropdownVisibility: z } = ee({
106
+ const { handleDropdownSelect: z, updateDropdownVisibility: L } = oe({
107
107
  codeMirror: r,
108
108
  query: C,
109
109
  showDropdown: y,
110
110
  dropdownPosition: S
111
- }), L = G(() => {
111
+ }), W = $(() => {
112
112
  var e;
113
113
  return o.type === "boolean" || (e = o.type) != null && e.includes("boolean") || o.nullable ? ["true", "false", "null"] : ["true", "false"];
114
114
  });
@@ -120,35 +120,41 @@ const pe = {
120
120
  });
121
121
  const h = (e, l) => {
122
122
  var p, t, E;
123
- y.value && (e === "down" ? (l.preventDefault(), (p = m.value) == null || p.handleArrowKey("down")) : e === "up" ? (l.preventDefault(), (t = m.value) == null || t.handleArrowKey("up")) : e === "enter" && (l.preventDefault(), (E = m.value) == null || E.handleSelect()));
124
- };
123
+ y.value && (e === "down" ? (l.preventDefault(), (p = f.value) == null || p.handleArrowKey("down")) : e === "up" ? (l.preventDefault(), (t = f.value) == null || t.handleArrowKey("up")) : e === "enter" && (l.preventDefault(), (E = f.value) == null || E.handleSelect()));
124
+ }, J = $(() => Array.isArray(o.type) ? (
125
+ // Find the first type, that’s not 'null'
126
+ o.type.find((e) => e !== "null") ?? "string"
127
+ ) : (
128
+ // If it’s not an array, just return the type
129
+ o.type
130
+ ));
125
131
  return (e, l) => {
126
132
  var p;
127
- return n(), i(H, null, [
128
- e.disabled ? (n(), i("div", pe, [
129
- w("span", null, X(e.modelValue), 1)
130
- ])) : o.enum && o.enum.length ? (n(), f(g, {
133
+ return n(), i(X, null, [
134
+ e.disabled ? (n(), i("div", fe, [
135
+ w("span", null, Y(e.modelValue), 1)
136
+ ])) : o.enum && o.enum.length ? (n(), m(g, {
131
137
  key: 1,
132
138
  default: o.default,
133
139
  modelValue: e.modelValue,
134
- type: e.type,
140
+ type: J.value,
135
141
  value: o.enum,
136
142
  "onUpdate:modelValue": l[0] || (l[0] = (t) => s("update:modelValue", t))
137
- }, null, 8, ["default", "modelValue", "type", "value"])) : e.type === "boolean" || (p = e.type) != null && p.includes("boolean") ? (n(), f(g, {
143
+ }, null, 8, ["default", "modelValue", "type", "value"])) : e.type === "boolean" || (p = e.type) != null && p.includes("boolean") ? (n(), m(g, {
138
144
  key: 2,
139
145
  default: o.default,
140
146
  modelValue: e.modelValue,
141
- value: L.value,
147
+ value: W.value,
142
148
  "onUpdate:modelValue": l[1] || (l[1] = (t) => s("update:modelValue", t))
143
- }, null, 8, ["default", "modelValue", "value"])) : o.examples && o.examples.length ? (n(), f(g, {
149
+ }, null, 8, ["default", "modelValue", "value"])) : o.examples && o.examples.length ? (n(), m(g, {
144
150
  key: 3,
145
151
  default: o.default,
146
152
  modelValue: o.modelValue,
147
153
  value: o.examples,
148
154
  "onUpdate:modelValue": l[2] || (l[2] = (t) => s("update:modelValue", t))
149
- }, null, 8, ["default", "modelValue", "value"])) : (n(), i("div", Y({
155
+ }, null, 8, ["default", "modelValue", "value"])) : (n(), i("div", Z({
150
156
  key: 4,
151
- id: a(A)
157
+ id: a(I)
152
158
  }, e.$attrs, {
153
159
  ref_key: "codeMirrorRef",
154
160
  ref: D,
@@ -156,44 +162,44 @@ const pe = {
156
162
  "flow-code-input--error": e.error
157
163
  }],
158
164
  onKeydown: [
159
- l[4] || (l[4] = V($((t) => h("down", t), ["stop"]), ["down"])),
165
+ l[4] || (l[4] = V(q((t) => h("down", t), ["stop"]), ["down"])),
160
166
  l[5] || (l[5] = V((t) => h("enter", t), ["enter"])),
161
- l[6] || (l[6] = V($((t) => h("up", t), ["stop"]), ["up"]))
167
+ l[6] || (l[6] = V(q((t) => h("up", t), ["stop"]), ["up"]))
162
168
  ]
163
169
  }), [
164
- e.isCopyable ? (n(), i("div", fe, [
170
+ e.isCopyable ? (n(), i("div", ce, [
165
171
  w("button", {
166
172
  class: "copy-button",
167
173
  type: "button",
168
- onClick: l[3] || (l[3] = (t) => a(K)(a(se)(e.modelValue)))
174
+ onClick: l[3] || (l[3] = (t) => a(M)(a(de)(e.modelValue)))
169
175
  }, [
170
176
  l[7] || (l[7] = w("span", { class: "sr-only" }, "Copy content", -1)),
171
- Z(a(ue), {
177
+ _(a(se), {
172
178
  icon: "Clipboard",
173
179
  size: "md"
174
180
  })
175
181
  ])
176
182
  ])) : c("", !0)
177
183
  ], 16, me)),
178
- e.$slots.warning ? (n(), i("div", ce, [
179
- q(e.$slots, "warning", {}, void 0, !0)
184
+ e.$slots.warning ? (n(), i("div", ye, [
185
+ A(e.$slots, "warning", {}, void 0, !0)
180
186
  ])) : c("", !0),
181
- q(e.$slots, "icon", {}, void 0, !0),
182
- e.required ? (n(), i("div", ye, " Required ")) : c("", !0),
183
- y.value && e.withVariables && a(x) !== "modal" && a(b) ? (n(), f(ae, {
187
+ A(e.$slots, "icon", {}, void 0, !0),
188
+ e.required ? (n(), i("div", be, " Required ")) : c("", !0),
189
+ y.value && e.withVariables && a(P) !== "modal" && a(b) ? (n(), m(re, {
184
190
  key: 7,
185
191
  ref_key: "dropdownRef",
186
- ref: m,
192
+ ref: f,
187
193
  dropdownPosition: S.value,
188
- envVariables: a(P),
194
+ envVariables: a(x),
189
195
  environment: a(b),
190
196
  query: C.value,
191
- onSelect: a(j)
197
+ onSelect: a(z)
192
198
  }, null, 8, ["dropdownPosition", "envVariables", "environment", "query", "onSelect"])) : c("", !0)
193
199
  ], 64);
194
200
  };
195
201
  }
196
202
  });
197
203
  export {
198
- De as default
204
+ Fe as default
199
205
  };
@@ -1,4 +1,4 @@
1
- import { type EnvVariables } from '../../libs/env-helpers.js';
1
+ import { type EnvVariables } from '../../libs/env-helpers';
2
2
  import type { Environment } from '@scalar/oas-utils/entities/environment';
3
3
  import type { Workspace } from '@scalar/oas-utils/entities/workspace';
4
4
  import { Decoration, type DecorationSet, EditorView, ViewPlugin, type ViewUpdate } from '@scalar/use-codemirror';
@@ -6,10 +6,10 @@ import { Decoration, type DecorationSet, EditorView, ViewPlugin, type ViewUpdate
6
6
  * Styles the active environment variable pill
7
7
  */
8
8
  export declare const pillPlugin: (props: {
9
- environment?: Environment;
10
- envVariables?: EnvVariables;
11
- workspace?: Workspace;
12
- isReadOnly?: boolean;
9
+ environment: Environment | undefined;
10
+ envVariables: EnvVariables | undefined;
11
+ workspace: Workspace | undefined;
12
+ isReadOnly: boolean | undefined;
13
13
  }) => ViewPlugin<{
14
14
  decorations: DecorationSet;
15
15
  update(update: ViewUpdate): void;
@@ -1 +1 @@
1
- {"version":3,"file":"codeVariableWidget.d.ts","sourceRoot":"","sources":["../../../src/components/CodeInput/codeVariableWidget.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,KAAK,YAAY,EAAe,MAAM,oBAAoB,CAAA;AAEnE,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,wCAAwC,CAAA;AACzE,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,sCAAsC,CAAA;AAErE,OAAO,EACL,UAAU,EACV,KAAK,aAAa,EAClB,UAAU,EAEV,UAAU,EACV,KAAK,UAAU,EAEhB,MAAM,wBAAwB,CAAA;AAmI/B;;GAEG;AACH,eAAO,MAAM,UAAU,UAAW;IAChC,WAAW,CAAC,EAAE,WAAW,CAAA;IACzB,YAAY,CAAC,EAAE,YAAY,CAAA;IAC3B,SAAS,CAAC,EAAE,SAAS,CAAA;IACrB,UAAU,CAAC,EAAE,OAAO,CAAA;CACrB;iBAGkB,aAAa;mBAMX,UAAU;2BASF,UAAU;EAkCpC,CAAA;AAEH,eAAO,MAAM,gBAAgB,uCA8B3B,CAAA"}
1
+ {"version":3,"file":"codeVariableWidget.d.ts","sourceRoot":"","sources":["../../../src/components/CodeInput/codeVariableWidget.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,KAAK,YAAY,EAAe,MAAM,oBAAoB,CAAA;AAEnE,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,wCAAwC,CAAA;AACzE,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,sCAAsC,CAAA;AAErE,OAAO,EACL,UAAU,EACV,KAAK,aAAa,EAClB,UAAU,EAEV,UAAU,EACV,KAAK,UAAU,EAEhB,MAAM,wBAAwB,CAAA;AAoI/B;;GAEG;AACH,eAAO,MAAM,UAAU,UAAW;IAChC,WAAW,EAAE,WAAW,GAAG,SAAS,CAAA;IACpC,YAAY,EAAE,YAAY,GAAG,SAAS,CAAA;IACtC,SAAS,EAAE,SAAS,GAAG,SAAS,CAAA;IAChC,UAAU,EAAE,OAAO,GAAG,SAAS,CAAA;CAChC;iBAGkB,aAAa;mBAMX,UAAU;2BASF,UAAU;EAkCpC,CAAA;AAEH,eAAO,MAAM,gBAAgB,uCA8B3B,CAAA"}
@@ -15,7 +15,7 @@ class d extends k {
15
15
  l(this, "envVariables");
16
16
  l(this, "workspace");
17
17
  l(this, "isReadOnly");
18
- this.variableName = e, this.variableName = e, this.environment = o, this.envVariables = i, this.workspace = c, this.isReadOnly = a;
18
+ this.variableName = e, this.variableName = e, this.environment = o, this.envVariables = i, this.workspace = c, this.isReadOnly = a ?? !1;
19
19
  }
20
20
  toDOM() {
21
21
  const e = document.createElement("span");
@@ -35,10 +35,9 @@ class d extends k {
35
35
  {
36
36
  class: "gap-1.5 justify-start font-normal px-1 py-1.5 h-auto transition-colors rounded no-underline text-xxs w-full hover:bg-b-2",
37
37
  variant: "ghost",
38
- // TODO: Use router instead
39
38
  onClick: () => {
40
39
  var r;
41
- return window.location.href = `/workspace/${(r = this.workspace) == null ? void 0 : r.uid}/environment`;
40
+ window.location.href = `/workspace/${(r = this.workspace) == null ? void 0 : r.uid}/environment`;
42
41
  }
43
42
  },
44
43
  {
@@ -1,7 +1,7 @@
1
1
  import { type useLoadingState } from '@scalar/components';
2
2
  type __VLS_Props = {
3
3
  loading?: ReturnType<typeof useLoadingState>;
4
- disabled?: boolean;
4
+ disabled: boolean;
5
5
  };
6
6
  declare function __VLS_template(): {
7
7
  attrs: Partial<{}>;
@@ -19,9 +19,9 @@ declare const __VLS_component: import("vue").DefineComponent<__VLS_Props, {}, {}
19
19
  cancel: () => any;
20
20
  back: (e: KeyboardEvent) => any;
21
21
  }, string, import("vue").PublicProps, Readonly<__VLS_Props> & Readonly<{
22
- onSubmit?: (() => any) | undefined;
23
- onCancel?: (() => any) | undefined;
24
- onBack?: ((e: KeyboardEvent) => any) | undefined;
22
+ onSubmit?: () => any;
23
+ onCancel?: () => any;
24
+ onBack?: (e: KeyboardEvent) => any;
25
25
  }>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, HTMLFormElement>;
26
26
  declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
27
27
  export default _default;
@@ -1 +1 @@
1
- {"version":3,"file":"CommandActionForm.vue.d.ts","sourceRoot":"","sources":["../../../src/components/CommandPalette/CommandActionForm.vue"],"names":[],"mappings":"AAsCA,OAAO,EAAgB,KAAK,eAAe,EAAE,MAAM,oBAAoB,CAAA;AAIvE,KAAK,WAAW,GAAG;IACjB,OAAO,CAAC,EAAE,UAAU,CAAC,OAAO,eAAe,CAAC,CAAA;IAC5C,QAAQ,CAAC,EAAE,OAAO,CAAA;CACnB,CAAC;AAgBF,iBAAS,cAAc;WAwET,OAAO,IAA6B;;yBAVrB,GAAG;yBACH,GAAG;wBACJ,GAAG;;;;EAa9B;AAUD,KAAK,oBAAoB,GAAG,UAAU,CAAC,OAAO,cAAc,CAAC,CAAC;AAC9D,QAAA,MAAM,eAAe;;;;;;;;8FAQnB,CAAC;wBACkB,uBAAuB,CAAC,OAAO,eAAe,EAAE,oBAAoB,CAAC,OAAO,CAAC,CAAC;AAAnG,wBAAoG;AAWpG,KAAK,uBAAuB,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IACxC,QAAO;QACN,MAAM,EAAE,CAAC,CAAC;KAEV,CAAA;CACD,CAAC"}
1
+ {"version":3,"file":"CommandActionForm.vue.d.ts","sourceRoot":"","sources":["../../../src/components/CommandPalette/CommandActionForm.vue"],"names":[],"mappings":"AAAA,OAsCO,EAAgB,KAAK,eAAe,EAAE,MAAM,oBAAoB,CAAA;AAIvE,KAAK,WAAW,GAAG;IACjB,OAAO,CAAC,EAAE,UAAU,CAAC,OAAO,eAAe,CAAC,CAAA;IAC5C,QAAQ,EAAE,OAAO,CAAA;CAClB,CAAC;AAiBF,iBAAS,cAAc;WAwET,OAAO,IAA6B;;yBAVrB,GAAG;yBACH,GAAG;wBACJ,GAAG;;;;EAa9B;AAUD,KAAK,oBAAoB,GAAG,UAAU,CAAC,OAAO,cAAc,CAAC,CAAC;AAC9D,QAAA,MAAM,eAAe;;;;;;;;8FAQnB,CAAC;wBACkB,uBAAuB,CAAC,OAAO,eAAe,EAAE,oBAAoB,CAAC,OAAO,CAAC,CAAC;AAAnG,wBAAoG;AAUpG,KAAK,uBAAuB,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IACxC,QAAO;QACN,MAAM,EAAE,CAAC,CAAC;KAEV,CAAA;CACD,CAAC"}