@scalar/api-client 2.0.63 → 2.1.0

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 (329) hide show
  1. package/CHANGELOG.md +63 -0
  2. package/dist/components/AddressBar/AddressBar.vue.d.ts.map +1 -1
  3. package/dist/components/AddressBar/AddressBar.vue.js +2 -2
  4. package/dist/components/AddressBar/AddressBar.vue2.js +64 -62
  5. package/dist/components/AddressBar/AddressBarHistory.vue.d.ts.map +1 -1
  6. package/dist/components/AddressBar/AddressBarHistory.vue.js +77 -69
  7. package/dist/components/AddressBar/AddressBarServer.vue.d.ts.map +1 -1
  8. package/dist/components/AddressBar/AddressBarServer.vue.js +121 -0
  9. package/dist/components/AddressBar/AddressBarServer.vue2.js +4 -0
  10. package/dist/components/AddressBar/AddressBarServerItem.vue.d.ts +22 -0
  11. package/dist/components/AddressBar/AddressBarServerItem.vue.d.ts.map +1 -0
  12. package/dist/components/AddressBar/AddressBarServerItem.vue.js +57 -0
  13. package/dist/components/AddressBar/AddressBarServerItem.vue2.js +4 -0
  14. package/dist/components/CodeInput/CodeInput.vue.d.ts +1 -6
  15. package/dist/components/CodeInput/CodeInput.vue.d.ts.map +1 -1
  16. package/dist/components/CodeInput/CodeInput.vue.js +2 -2
  17. package/dist/components/CodeInput/CodeInput.vue2.js +87 -82
  18. package/dist/components/CodeInput/codeVariableWidget.d.ts +4 -4
  19. package/dist/components/CodeInput/codeVariableWidget.d.ts.map +1 -1
  20. package/dist/components/CodeInput/codeVariableWidget.js +70 -63
  21. package/dist/components/CommandPalette/CommandActionForm.vue.d.ts +33 -0
  22. package/dist/components/CommandPalette/CommandActionForm.vue.d.ts.map +1 -0
  23. package/dist/components/CommandPalette/CommandActionForm.vue.js +41 -0
  24. package/dist/components/CommandPalette/CommandActionForm.vue2.js +4 -0
  25. package/dist/components/CommandPalette/CommandActionInput.vue.d.ts +20 -0
  26. package/dist/components/CommandPalette/CommandActionInput.vue.d.ts.map +1 -0
  27. package/dist/components/CommandPalette/CommandActionInput.vue.js +42 -0
  28. package/dist/components/CommandPalette/CommandActionInput.vue2.js +4 -0
  29. package/dist/components/CommandPalette/CommandPaletteCollection.vue.d.ts.map +1 -1
  30. package/dist/components/CommandPalette/CommandPaletteCollection.vue.js +33 -56
  31. package/dist/components/CommandPalette/CommandPaletteExample.vue.d.ts.map +1 -1
  32. package/dist/components/CommandPalette/CommandPaletteExample.vue.js +88 -109
  33. package/dist/components/CommandPalette/CommandPaletteImport.vue.d.ts.map +1 -1
  34. package/dist/components/CommandPalette/CommandPaletteImport.vue.js +56 -73
  35. package/dist/components/CommandPalette/CommandPaletteRequest.vue.d.ts +21 -2
  36. package/dist/components/CommandPalette/CommandPaletteRequest.vue.d.ts.map +1 -1
  37. package/dist/components/CommandPalette/CommandPaletteRequest.vue.js +122 -133
  38. package/dist/components/CommandPalette/{CommandPaletteFolder.vue.d.ts → CommandPaletteServer.vue.d.ts} +1 -1
  39. package/dist/components/CommandPalette/CommandPaletteServer.vue.d.ts.map +1 -0
  40. package/dist/components/CommandPalette/CommandPaletteServer.vue.js +92 -0
  41. package/dist/components/CommandPalette/CommandPaletteServer.vue2.js +4 -0
  42. package/dist/components/CommandPalette/CommandPaletteTag.vue.d.ts +7 -0
  43. package/dist/components/CommandPalette/CommandPaletteTag.vue.d.ts.map +1 -0
  44. package/dist/components/CommandPalette/CommandPaletteTag.vue.js +87 -0
  45. package/dist/components/CommandPalette/CommandPaletteTag.vue2.js +4 -0
  46. package/dist/components/CommandPalette/CommandPaletteWorkspace.vue.d.ts.map +1 -1
  47. package/dist/components/CommandPalette/CommandPaletteWorkspace.vue.js +33 -49
  48. package/dist/components/CommandPalette/TheCommandPalette.vue.d.ts +22 -3
  49. package/dist/components/CommandPalette/TheCommandPalette.vue.d.ts.map +1 -1
  50. package/dist/components/CommandPalette/TheCommandPalette.vue.js +3 -3
  51. package/dist/components/CommandPalette/TheCommandPalette.vue2.js +107 -101
  52. package/dist/components/ContextBar.vue.d.ts.map +1 -1
  53. package/dist/components/ContextBar.vue.js +2 -2
  54. package/dist/components/ContextBar.vue2.js +2 -2
  55. package/dist/components/DataTable/DataTable.vue.js +1 -1
  56. package/dist/components/DataTable/DataTableInput.vue.d.ts +1 -1
  57. package/dist/components/DataTable/DataTableInput.vue.d.ts.map +1 -1
  58. package/dist/components/DataTable/DataTableInput.vue.js +2 -2
  59. package/dist/components/DataTable/DataTableInput.vue2.js +13 -13
  60. package/dist/components/DataTable/DataTableInputSelect.vue.d.ts.map +1 -1
  61. package/dist/components/DataTable/DataTableInputSelect.vue.js +39 -40
  62. package/dist/components/DataTable/index.js +12 -12
  63. package/dist/components/EnvironmentSelector/EnvironmentSelector.vue.js +7 -7
  64. package/dist/components/Form/Form.vue.js +1 -1
  65. package/dist/components/HttpMethod/HttpMethod.vue.d.ts +2 -2
  66. package/dist/components/HttpMethod/HttpMethod.vue.d.ts.map +1 -1
  67. package/dist/components/HttpMethod/HttpMethod.vue.js +2 -2
  68. package/dist/components/HttpMethod/HttpMethod.vue2.js +30 -30
  69. package/dist/components/HttpMethod/helpers.d.ts +4 -0
  70. package/dist/components/HttpMethod/helpers.d.ts.map +1 -0
  71. package/dist/components/HttpMethod/helpers.js +5 -0
  72. package/dist/components/HttpMethod/index.d.ts +1 -0
  73. package/dist/components/HttpMethod/index.d.ts.map +1 -1
  74. package/dist/components/HttpMethod/index.js +4 -2
  75. package/dist/components/Search/SearchModal.vue.d.ts.map +1 -1
  76. package/dist/components/Search/SearchModal.vue.js +2 -2
  77. package/dist/components/Search/SearchModal.vue2.js +29 -27
  78. package/dist/components/Search/useSearch.js +35 -35
  79. package/dist/components/SideNav/SideNavLink.vue.js +6 -6
  80. package/dist/components/Sidebar/Actions/DeleteSidebarListElement.vue.d.ts.map +1 -1
  81. package/dist/components/Sidebar/Actions/DeleteSidebarListElement.vue.js +14 -17
  82. package/dist/components/Sidebar/Actions/RenameSidebarListElement.vue.d.ts +22 -0
  83. package/dist/components/Sidebar/Actions/RenameSidebarListElement.vue.d.ts.map +1 -0
  84. package/dist/components/Sidebar/Actions/RenameSidebarListElement.vue.js +29 -0
  85. package/dist/components/Sidebar/Actions/RenameSidebarListElement.vue2.js +4 -0
  86. package/dist/components/Sidebar/Actions/SidebarListElementForm.vue.d.ts.map +1 -1
  87. package/dist/components/Sidebar/Actions/SidebarListElementForm.vue.js +1 -1
  88. package/dist/components/Sidebar/Actions/SidebarListElementForm.vue2.js +38 -35
  89. package/dist/components/Sidebar/Sidebar.vue.d.ts +2 -1
  90. package/dist/components/Sidebar/Sidebar.vue.d.ts.map +1 -1
  91. package/dist/components/Sidebar/Sidebar.vue.js +5 -54
  92. package/dist/components/Sidebar/Sidebar.vue2.js +59 -0
  93. package/dist/components/Sidebar/SidebarButton.vue.d.ts.map +1 -1
  94. package/dist/components/Sidebar/SidebarButton.vue.js +11 -11
  95. package/dist/components/Sidebar/index.js +2 -3
  96. package/dist/components/SubpageHeader.vue.d.ts.map +1 -1
  97. package/dist/components/SubpageHeader.vue.js +3 -3
  98. package/dist/components/SubpageHeader.vue2.js +3 -3
  99. package/dist/components/TopNav/TopNav.vue.d.ts.map +1 -1
  100. package/dist/components/TopNav/TopNav.vue.js +2 -2
  101. package/dist/components/TopNav/TopNav.vue2.js +23 -23
  102. package/dist/components/TopNav/TopNavItem.vue.d.ts.map +1 -1
  103. package/dist/components/TopNav/TopNavItem.vue.js +2 -2
  104. package/dist/components/TopNav/TopNavItem.vue2.js +21 -21
  105. package/dist/components/ViewLayout/ViewLayout.vue.d.ts.map +1 -1
  106. package/dist/components/ViewLayout/ViewLayout.vue.js +7 -7
  107. package/dist/components/ViewLayout/ViewLayoutCollapse.vue.d.ts.map +1 -1
  108. package/dist/components/ViewLayout/ViewLayoutCollapse.vue.js +5 -5
  109. package/dist/components/ViewLayout/ViewLayoutContent.vue.d.ts.map +1 -1
  110. package/dist/components/ViewLayout/ViewLayoutContent.vue.js +4 -4
  111. package/dist/components/ViewLayout/ViewLayoutSection.vue.d.ts.map +1 -1
  112. package/dist/components/ViewLayout/ViewLayoutSection.vue.js +6 -6
  113. package/dist/components/index.js +4 -5
  114. package/dist/index.d.ts +1 -1
  115. package/dist/index.d.ts.map +1 -1
  116. package/dist/index.js +1 -1
  117. package/dist/layouts/App/ApiClientApp.vue.d.ts.map +1 -1
  118. package/dist/layouts/App/ApiClientApp.vue.js +39 -53
  119. package/dist/layouts/App/create-api-client-app.d.ts +2058 -1941
  120. package/dist/layouts/App/create-api-client-app.d.ts.map +1 -1
  121. package/dist/layouts/App/create-api-client-app.js +12 -12
  122. package/dist/layouts/Modal/ApiClientModal.vue.js +1 -1
  123. package/dist/layouts/Modal/ApiClientModal.vue2.js +6 -6
  124. package/dist/layouts/Modal/create-api-client-modal.d.ts +4590 -4356
  125. package/dist/layouts/Modal/create-api-client-modal.d.ts.map +1 -1
  126. package/dist/layouts/Modal/create-api-client-modal.js +18 -23
  127. package/dist/libs/create-client.d.ts +2086 -1972
  128. package/dist/libs/create-client.d.ts.map +1 -1
  129. package/dist/libs/create-client.js +85 -76
  130. package/dist/libs/environment-parser.d.ts +9 -0
  131. package/dist/libs/environment-parser.d.ts.map +1 -0
  132. package/dist/libs/environment-parser.js +17 -0
  133. package/dist/libs/errors.d.ts +21 -0
  134. package/dist/libs/errors.d.ts.map +1 -0
  135. package/dist/libs/errors.js +14 -0
  136. package/dist/libs/event-busses/command-palette-bus.d.ts +1 -1
  137. package/dist/libs/event-busses/command-palette-bus.d.ts.map +1 -1
  138. package/dist/libs/event-busses/hot-keys-bus.d.ts +4 -4
  139. package/dist/libs/event-busses/hot-keys-bus.d.ts.map +1 -1
  140. package/dist/libs/event-busses/hot-keys-bus.js +17 -19
  141. package/dist/libs/index.d.ts +5 -2
  142. package/dist/libs/index.d.ts.map +1 -1
  143. package/dist/libs/index.js +31 -24
  144. package/dist/libs/local-storage.d.ts +3 -3
  145. package/dist/libs/local-storage.d.ts.map +1 -1
  146. package/dist/libs/local-storage.js +24 -12
  147. package/dist/libs/normalize-headers.d.ts +14 -0
  148. package/dist/libs/normalize-headers.d.ts.map +1 -0
  149. package/dist/libs/normalize-headers.js +32 -0
  150. package/dist/libs/send-request.d.ts +28 -0
  151. package/dist/libs/send-request.d.ts.map +1 -0
  152. package/dist/libs/send-request.js +186 -0
  153. package/dist/libs/string-template.d.ts +19 -0
  154. package/dist/libs/string-template.d.ts.map +1 -0
  155. package/dist/libs/string-template.js +30 -0
  156. package/dist/router.d.ts +5 -0
  157. package/dist/router.d.ts.map +1 -1
  158. package/dist/router.js +36 -27
  159. package/dist/store/collections.d.ts +705 -0
  160. package/dist/store/collections.d.ts.map +1 -0
  161. package/dist/store/collections.js +63 -0
  162. package/dist/store/cookies.d.ts +135 -0
  163. package/dist/store/cookies.d.ts.map +1 -0
  164. package/dist/store/cookies.js +29 -0
  165. package/dist/store/environment.d.ts +80 -0
  166. package/dist/store/environment.d.ts.map +1 -0
  167. package/dist/store/environment.js +39 -0
  168. package/dist/store/import-spec.d.ts +8 -0
  169. package/dist/store/import-spec.d.ts.map +1 -0
  170. package/dist/store/import-spec.js +45 -0
  171. package/dist/store/index.d.ts +1 -1
  172. package/dist/store/index.d.ts.map +1 -1
  173. package/dist/store/index.js +1 -1
  174. package/dist/store/request-example.d.ts +1111 -0
  175. package/dist/store/request-example.d.ts.map +1 -0
  176. package/dist/store/request-example.js +47 -0
  177. package/dist/store/requests.d.ts +371 -0
  178. package/dist/store/requests.d.ts.map +1 -0
  179. package/dist/store/requests.js +107 -0
  180. package/dist/store/router-params.d.ts +15 -0
  181. package/dist/store/router-params.d.ts.map +1 -0
  182. package/dist/store/router-params.js +21 -0
  183. package/dist/store/security-schemes.d.ts +616 -0
  184. package/dist/store/security-schemes.d.ts.map +1 -0
  185. package/dist/store/security-schemes.js +68 -0
  186. package/dist/store/servers.d.ts +99 -0
  187. package/dist/store/servers.d.ts.map +1 -0
  188. package/dist/store/servers.js +46 -0
  189. package/dist/store/store-context.d.ts +29 -0
  190. package/dist/store/store-context.d.ts.map +1 -0
  191. package/dist/store/store.d.ts +7504 -0
  192. package/dist/store/store.d.ts.map +1 -0
  193. package/dist/store/store.js +200 -0
  194. package/dist/store/tags.d.ts +169 -0
  195. package/dist/store/tags.d.ts.map +1 -0
  196. package/dist/store/tags.js +57 -0
  197. package/dist/store/workspace.d.ts +93 -7150
  198. package/dist/store/workspace.d.ts.map +1 -1
  199. package/dist/store/workspace.js +49 -543
  200. package/dist/style.css +1 -1
  201. package/dist/views/Cookies/CookieForm.vue.js +2 -2
  202. package/dist/views/Cookies/CookieRaw.vue.d.ts.map +1 -1
  203. package/dist/views/Cookies/CookieRaw.vue.js +10 -10
  204. package/dist/views/Cookies/Cookies.vue.d.ts.map +1 -1
  205. package/dist/views/Cookies/Cookies.vue2.js +29 -32
  206. package/dist/views/Environment/Environment.vue2.js +31 -33
  207. package/dist/views/Environment/EnvironmentVariableDropdown.vue.d.ts +11 -5
  208. package/dist/views/Environment/EnvironmentVariableDropdown.vue.d.ts.map +1 -1
  209. package/dist/views/Environment/EnvironmentVariableDropdown.vue.js +79 -59
  210. package/dist/views/Request/Request.vue.d.ts.map +1 -1
  211. package/dist/views/Request/Request.vue.js +2 -2
  212. package/dist/views/Request/Request.vue2.js +87 -319
  213. package/dist/views/Request/RequestSection/RequestAuth/DeleteRequestAuthModal.vue.d.ts +36 -0
  214. package/dist/views/Request/RequestSection/RequestAuth/DeleteRequestAuthModal.vue.d.ts.map +1 -0
  215. package/dist/views/Request/RequestSection/RequestAuth/DeleteRequestAuthModal.vue.js +59 -0
  216. package/dist/views/Request/RequestSection/RequestAuth/DeleteRequestAuthModal.vue2.js +4 -0
  217. package/dist/views/Request/{components → RequestSection/RequestAuth}/OAuth2.vue.d.ts +3 -1
  218. package/dist/views/Request/RequestSection/RequestAuth/OAuth2.vue.d.ts.map +1 -0
  219. package/dist/views/Request/RequestSection/RequestAuth/OAuth2.vue.js +216 -0
  220. package/dist/views/Request/{components → RequestSection/RequestAuth}/OAuthScopesInput.vue.d.ts +2 -2
  221. package/dist/views/Request/RequestSection/RequestAuth/OAuthScopesInput.vue.d.ts.map +1 -0
  222. package/dist/views/Request/{components → RequestSection/RequestAuth}/OAuthScopesInput.vue.js +3 -3
  223. package/dist/views/Request/RequestSection/RequestAuth/RequestAuth.vue.d.ts.map +1 -0
  224. package/dist/views/Request/RequestSection/RequestAuth/RequestAuth.vue.js +7 -0
  225. package/dist/views/Request/RequestSection/RequestAuth/RequestAuth.vue2.js +183 -0
  226. package/dist/views/Request/RequestSection/RequestAuth/RequestAuthModal.vue.d.ts +30 -0
  227. package/dist/views/Request/RequestSection/RequestAuth/RequestAuthModal.vue.d.ts.map +1 -0
  228. package/dist/views/Request/RequestSection/RequestAuth/RequestExampleAuth.vue.d.ts +3 -0
  229. package/dist/views/Request/RequestSection/RequestAuth/RequestExampleAuth.vue.d.ts.map +1 -0
  230. package/dist/views/Request/RequestSection/RequestAuth/RequestExampleAuth.vue.js +140 -0
  231. package/dist/views/Request/RequestSection/RequestAuth/RequestExampleAuth.vue2.js +4 -0
  232. package/dist/views/Request/RequestSection/RequestAuthDataTableInput.vue.d.ts +1 -1
  233. package/dist/views/Request/RequestSection/RequestBody.vue.d.ts.map +1 -1
  234. package/dist/views/Request/RequestSection/RequestBody.vue.js +167 -186
  235. package/dist/views/Request/RequestSection/RequestParams.vue.d.ts +1 -1
  236. package/dist/views/Request/RequestSection/RequestParams.vue.d.ts.map +1 -1
  237. package/dist/views/Request/RequestSection/RequestParams.vue.js +49 -49
  238. package/dist/views/Request/RequestSection/RequestPathParams.vue.d.ts +1 -1
  239. package/dist/views/Request/RequestSection/RequestPathParams.vue.d.ts.map +1 -1
  240. package/dist/views/Request/RequestSection/RequestPathParams.vue.js +26 -22
  241. package/dist/views/Request/RequestSection/RequestSection.vue.d.ts.map +1 -1
  242. package/dist/views/Request/RequestSection/RequestSection.vue.js +103 -102
  243. package/dist/views/Request/RequestSection/RequestTable.vue.d.ts +5 -5
  244. package/dist/views/Request/RequestSection/RequestTable.vue.d.ts.map +1 -1
  245. package/dist/views/Request/RequestSection/RequestTable.vue.js +1 -1
  246. package/dist/views/Request/RequestSection/RequestTable.vue2.js +1 -1
  247. package/dist/views/Request/RequestSection/RequestTableTooltip.vue.d.ts +1 -1
  248. package/dist/views/Request/RequestSection/RequestTableTooltip.vue.d.ts.map +1 -1
  249. package/dist/views/Request/RequestSidebar.vue.d.ts +30 -0
  250. package/dist/views/Request/RequestSidebar.vue.d.ts.map +1 -0
  251. package/dist/views/Request/RequestSidebar.vue.js +7 -0
  252. package/dist/views/Request/RequestSidebar.vue2.js +179 -0
  253. package/dist/views/Request/RequestSidebarItem.vue.d.ts +6 -7
  254. package/dist/views/Request/RequestSidebarItem.vue.d.ts.map +1 -1
  255. package/dist/views/Request/RequestSidebarItem.vue.js +1 -1
  256. package/dist/views/Request/RequestSidebarItem.vue2.js +283 -254
  257. package/dist/views/Request/RequestSidebarItemMenu.vue.d.ts +3 -5
  258. package/dist/views/Request/RequestSidebarItemMenu.vue.d.ts.map +1 -1
  259. package/dist/views/Request/RequestSidebarItemMenu.vue.js +2 -2
  260. package/dist/views/Request/RequestSidebarItemMenu.vue2.js +9 -7
  261. package/dist/views/Request/RequestSubpageHeader.vue.d.ts +24 -0
  262. package/dist/views/Request/RequestSubpageHeader.vue.d.ts.map +1 -0
  263. package/dist/views/Request/RequestSubpageHeader.vue.js +7 -0
  264. package/dist/views/Request/RequestSubpageHeader.vue2.js +48 -0
  265. package/dist/views/Request/ResponseSection/ResponseBody.vue.d.ts.map +1 -1
  266. package/dist/views/Request/ResponseSection/ResponseBody.vue.js +21 -21
  267. package/dist/views/Request/ResponseSection/ResponseBodyRaw.vue.d.ts.map +1 -1
  268. package/dist/views/Request/ResponseSection/ResponseBodyRaw.vue.js +3 -3
  269. package/dist/views/Request/ResponseSection/ResponseBodyRaw.vue2.js +17 -16
  270. package/dist/views/Request/ResponseSection/ResponseEmpty.vue.d.ts.map +1 -1
  271. package/dist/views/Request/ResponseSection/ResponseEmpty.vue.js +1 -1
  272. package/dist/views/Request/ResponseSection/ResponseEmpty.vue2.js +37 -30
  273. package/dist/views/Request/ResponseSection/ResponseMetaInformation.vue.d.ts +1 -1
  274. package/dist/views/Request/ResponseSection/ResponseMetaInformation.vue.d.ts.map +1 -1
  275. package/dist/views/Request/ResponseSection/ResponseSection.vue.d.ts +1 -1
  276. package/dist/views/Request/ResponseSection/ResponseSection.vue.d.ts.map +1 -1
  277. package/dist/views/Request/ResponseSection/ResponseSection.vue.js +2 -2
  278. package/dist/views/Request/components/WorkspaceDropdown.vue.d.ts.map +1 -1
  279. package/dist/views/Request/components/WorkspaceDropdown.vue.js +69 -90
  280. package/dist/views/Request/components/index.d.ts +0 -1
  281. package/dist/views/Request/components/index.d.ts.map +1 -1
  282. package/dist/views/Request/components/index.js +2 -4
  283. package/dist/views/Request/consts/new-auth-options.d.ts +11 -1
  284. package/dist/views/Request/consts/new-auth-options.d.ts.map +1 -1
  285. package/dist/views/Request/consts/new-auth-options.js +17 -7
  286. package/dist/views/Request/handle-drag.d.ts +8 -0
  287. package/dist/views/Request/handle-drag.d.ts.map +1 -0
  288. package/dist/views/Request/handle-drag.js +56 -0
  289. package/dist/views/Request/libs/auth.d.ts +35 -0
  290. package/dist/views/Request/libs/auth.d.ts.map +1 -0
  291. package/dist/views/Request/libs/auth.js +14 -0
  292. package/dist/views/Request/libs/index.d.ts +1 -0
  293. package/dist/views/Request/libs/index.d.ts.map +1 -1
  294. package/dist/views/Request/libs/index.js +7 -3
  295. package/dist/views/Request/libs/oauth2.d.ts +12 -3
  296. package/dist/views/Request/libs/oauth2.d.ts.map +1 -1
  297. package/dist/views/Request/libs/oauth2.js +42 -27
  298. package/dist/views/Servers/ServerForm.vue.js +22 -22
  299. package/dist/views/Servers/Servers.vue.d.ts.map +1 -1
  300. package/dist/views/Servers/Servers.vue2.js +18 -16
  301. package/package.json +11 -11
  302. package/dist/components/CodeInput/codeDropdownWidget.d.ts +0 -32
  303. package/dist/components/CodeInput/codeDropdownWidget.d.ts.map +0 -1
  304. package/dist/components/CodeInput/codeDropdownWidget.js +0 -121
  305. package/dist/components/CommandPalette/CommandPaletteFolder.vue.d.ts.map +0 -1
  306. package/dist/components/CommandPalette/CommandPaletteFolder.vue.js +0 -106
  307. package/dist/components/CommandPalette/CommandPaletteFolder.vue2.js +0 -4
  308. package/dist/components/Sidebar/Sidebar.vue3.js +0 -5
  309. package/dist/errors.d.ts +0 -5
  310. package/dist/errors.d.ts.map +0 -1
  311. package/dist/errors.js +0 -7
  312. package/dist/libs/normalizeHeaders.d.ts +0 -11
  313. package/dist/libs/normalizeHeaders.d.ts.map +0 -1
  314. package/dist/libs/normalizeHeaders.js +0 -25
  315. package/dist/libs/pathParams.d.ts +0 -10
  316. package/dist/libs/pathParams.d.ts.map +0 -1
  317. package/dist/libs/pathParams.js +0 -36
  318. package/dist/libs/sendRequest.d.ts +0 -14
  319. package/dist/libs/sendRequest.d.ts.map +0 -1
  320. package/dist/libs/sendRequest.js +0 -163
  321. package/dist/views/Request/RequestSection/RequestAuth.vue.d.ts.map +0 -1
  322. package/dist/views/Request/RequestSection/RequestAuth.vue.js +0 -7
  323. package/dist/views/Request/RequestSection/RequestAuth.vue2.js +0 -351
  324. package/dist/views/Request/components/OAuth2.vue.d.ts.map +0 -1
  325. package/dist/views/Request/components/OAuth2.vue.js +0 -208
  326. package/dist/views/Request/components/OAuthScopesInput.vue.d.ts.map +0 -1
  327. /package/dist/views/Request/{components → RequestSection/RequestAuth}/OAuth2.vue2.js +0 -0
  328. /package/dist/views/Request/{components → RequestSection/RequestAuth}/OAuthScopesInput.vue2.js +0 -0
  329. /package/dist/views/Request/RequestSection/{RequestAuth.vue.d.ts → RequestAuth/RequestAuth.vue.d.ts} +0 -0
@@ -0,0 +1,4 @@
1
+ import f from "./CommandActionForm.vue.js";
2
+ export {
3
+ f as default
4
+ };
@@ -0,0 +1,20 @@
1
+ declare const _default: import("vue").DefineComponent<__VLS_TypePropsToOption<{
2
+ modelValue?: string;
3
+ }>, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
4
+ "update:modelValue": (v: string) => void;
5
+ }, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<__VLS_TypePropsToOption<{
6
+ modelValue?: string;
7
+ }>>> & {
8
+ "onUpdate:modelValue"?: ((v: string) => any) | undefined;
9
+ }, {}, {}>;
10
+ export default _default;
11
+ type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
12
+ type __VLS_TypePropsToOption<T> = {
13
+ [K in keyof T]-?: {} extends Pick<T, K> ? {
14
+ type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
15
+ } : {
16
+ type: import('vue').PropType<T[K]>;
17
+ required: true;
18
+ };
19
+ };
20
+ //# sourceMappingURL=CommandActionInput.vue.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"CommandActionInput.vue.d.ts","sourceRoot":"","sources":["../../../src/components/CommandPalette/CommandActionInput.vue"],"names":[],"mappings":";iBA8Ce,MAAM;;;;iBAAN,MAAM;;;;AA+ErB,wBAOG;AAOH,KAAK,sBAAsB,CAAC,CAAC,IAAI,CAAC,SAAS,SAAS,GAAG,KAAK,GAAG,CAAC,CAAC;AAC5D,KAAK,uBAAuB,CAAC,CAAC,IAAI;KAChC,CAAC,IAAI,MAAM,CAAC,CAAC,CAAC,GAAG,EAAE,SAAS,IAAI,CAAC,CAAC,EAAE,CAAC,CAAC,GACpC;QAAE,IAAI,EAAE,OAAO,KAAK,EAAE,QAAQ,CAAC,sBAAsB,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAA;KAAE,GAC9D;QAAE,IAAI,EAAE,OAAO,KAAK,EAAE,QAAQ,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;QAAC,QAAQ,EAAE,IAAI,CAAA;KAAE;CACzD,CAAC"}
@@ -0,0 +1,42 @@
1
+ import { defineComponent as d, ref as c, onMounted as f, nextTick as _, computed as h, openBlock as V, createElementBlock as v, Fragment as y, createElementVNode as r, unref as a, withDirectives as g, mergeProps as k, vModelDynamic as x } from "vue";
2
+ import { nanoid as b } from "nanoid";
3
+ const w = ["for"], A = ["id"], D = /* @__PURE__ */ d({
4
+ inheritAttrs: !1,
5
+ __name: "CommandActionInput",
6
+ props: {
7
+ modelValue: {}
8
+ },
9
+ emits: ["update:modelValue"],
10
+ setup(u, { emit: s }) {
11
+ const i = u, m = s, t = b(), o = c(null);
12
+ f(() => _(() => {
13
+ var e;
14
+ return (e = o.value) == null ? void 0 : e.focus();
15
+ }));
16
+ const n = h({
17
+ get: () => i.modelValue ?? "",
18
+ set: (e) => m("update:modelValue", e)
19
+ });
20
+ return (e, l) => (V(), v(y, null, [
21
+ r("label", {
22
+ class: "absolute w-full h-full opacity-0 cursor-text",
23
+ for: a(t)
24
+ }, null, 8, w),
25
+ g(r("input", k({
26
+ id: a(t),
27
+ ref_key: "input",
28
+ ref: o,
29
+ "onUpdate:modelValue": l[0] || (l[0] = (p) => n.value = p),
30
+ autocomplete: "off",
31
+ class: "border-transparent outline-none w-full pl-8 text-sm min-h-8 py-1.5",
32
+ "data-form-type": "other",
33
+ "data-lpignore": "true"
34
+ }, e.$attrs), null, 16, A), [
35
+ [x, n.value]
36
+ ])
37
+ ], 64));
38
+ }
39
+ });
40
+ export {
41
+ D as default
42
+ };
@@ -0,0 +1,4 @@
1
+ import f from "./CommandActionInput.vue.js";
2
+ export {
3
+ f as default
4
+ };
@@ -1 +1 @@
1
- {"version":3,"file":"CommandPaletteCollection.vue.d.ts","sourceRoot":"","sources":["../../../src/components/CommandPalette/CommandPaletteCollection.vue"],"names":[],"mappings":";;;;;AA8NA,wBAMG"}
1
+ {"version":3,"file":"CommandPaletteCollection.vue.d.ts","sourceRoot":"","sources":["../../../src/components/CommandPalette/CommandPaletteCollection.vue"],"names":[],"mappings":";;;;;AA4JA,wBAMG"}
@@ -1,70 +1,47 @@
1
- import { defineComponent as p, ref as s, onMounted as f, openBlock as h, createElementBlock as _, createElementVNode as o, withDirectives as v, withKeys as x, withModifiers as b, vModelText as w, createVNode as C, unref as g, withCtx as y, createTextVNode as k } from "vue";
2
- import { useWorkspace as N } from "../../store/workspace.js";
3
- import { ScalarButton as M } from "@scalar/components";
4
- import { useToasts as V } from "@scalar/use-toasts";
5
- const B = { class: "flex w-full flex-col gap-3" }, K = { class: "gap-3 rounded bg-b-2 focus-within:bg-b-1 focus-within:shadow-border min-h-20 relative" }, T = /* @__PURE__ */ o("label", {
6
- class: "absolute w-full h-full opacity-0 cursor-text",
7
- for: "collectionanme"
8
- }, null, -1), E = ["onKeydown"], I = { class: "flex" }, P = /* @__PURE__ */ o("div", { class: "flex flex-1 gap-2 max-h-8" }, null, -1), q = /* @__PURE__ */ p({
1
+ import { defineComponent as s, ref as u, openBlock as d, createBlock as p, withCtx as t, createTextVNode as f, createVNode as _ } from "vue";
2
+ import { useToasts as v } from "@scalar/use-toasts";
3
+ import C from "./CommandActionForm.vue.js";
4
+ import b from "./CommandActionInput.vue.js";
5
+ import { useWorkspace as N } from "../../store/store.js";
6
+ const T = /* @__PURE__ */ s({
9
7
  __name: "CommandPaletteCollection",
10
8
  emits: ["close"],
11
- setup(S, { emit: i }) {
12
- const c = i, { activeWorkspace: r, collectionMutators: u } = N(), e = s(""), { toast: d } = V(), l = () => {
9
+ setup(V, { emit: l }) {
10
+ const a = l, { activeWorkspace: n, collectionMutators: r } = N(), e = u(""), { toast: i } = v(), m = () => {
13
11
  if (!e.value) {
14
- d("Please enter a name before creating a collection.", "error");
12
+ i("Please enter a name before creating a collection.", "error");
15
13
  return;
16
14
  }
17
- u.add(
15
+ r.add(
18
16
  {
19
- spec: {
20
- openapi: "3.1.0",
21
- info: {
22
- title: e.value,
23
- version: "0.0.1"
24
- }
17
+ openapi: "3.1.0",
18
+ info: {
19
+ title: e.value,
20
+ version: "0.0.1"
25
21
  }
26
22
  },
27
- r.value.uid
28
- ), c("close");
29
- }, n = s(null);
30
- return f(() => {
31
- var t;
32
- (t = n.value) == null || t.focus();
33
- }), (t, a) => (h(), _("div", B, [
34
- o("div", K, [
35
- T,
36
- v(o("input", {
37
- id: "collectionanme",
38
- ref_key: "collectionInput",
39
- ref: n,
40
- "onUpdate:modelValue": a[0] || (a[0] = (m) => e.value = m),
41
- autocomplete: "off",
42
- class: "border-transparent outline-none w-full pl-8 text-sm min-h-8 py-1.5",
43
- "data-form-type": "other",
44
- "data-lpignore": "true",
23
+ n.value.uid
24
+ ), a("close");
25
+ };
26
+ return (k, o) => (d(), p(C, {
27
+ disabled: !e.value.trim(),
28
+ onSubmit: m
29
+ }, {
30
+ submit: t(() => [
31
+ f("Create Collection")
32
+ ]),
33
+ default: t(() => [
34
+ _(b, {
35
+ modelValue: e.value,
36
+ "onUpdate:modelValue": o[0] || (o[0] = (c) => e.value = c),
45
37
  label: "Collection Name",
46
- placeholder: "Collection Name",
47
- onKeydown: x(b(l, ["prevent"]), ["enter"])
48
- }, null, 40, E), [
49
- [w, e.value]
50
- ])
38
+ placeholder: "Collection Name"
39
+ }, null, 8, ["modelValue"])
51
40
  ]),
52
- o("div", I, [
53
- P,
54
- C(g(M), {
55
- class: "max-h-8 text-xs p-0 px-3",
56
- disabled: !e.value.trim(),
57
- onClick: l
58
- }, {
59
- default: y(() => [
60
- k(" Continue ")
61
- ]),
62
- _: 1
63
- }, 8, ["disabled"])
64
- ])
65
- ]));
41
+ _: 1
42
+ }, 8, ["disabled"]));
66
43
  }
67
44
  });
68
45
  export {
69
- q as default
46
+ T as default
70
47
  };
@@ -1 +1 @@
1
- {"version":3,"file":"CommandPaletteExample.vue.d.ts","sourceRoot":"","sources":["../../../src/components/CommandPalette/CommandPaletteExample.vue"],"names":[],"mappings":";IAgJE,oCAAoC;eACzB,MAAM;;;;IADjB,oCAAoC;eACzB,MAAM;;;;AAoTnB,wBAOG;AAOH,KAAK,sBAAsB,CAAC,CAAC,IAAI,CAAC,SAAS,SAAS,GAAG,KAAK,GAAG,CAAC,CAAC;AAC5D,KAAK,uBAAuB,CAAC,CAAC,IAAI;KAChC,CAAC,IAAI,MAAM,CAAC,CAAC,CAAC,GAAG,EAAE,SAAS,IAAI,CAAC,CAAC,EAAE,CAAC,CAAC,GACpC;QAAE,IAAI,EAAE,OAAO,KAAK,EAAE,QAAQ,CAAC,sBAAsB,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAA;KAAE,GAC9D;QAAE,IAAI,EAAE,OAAO,KAAK,EAAE,QAAQ,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;QAAC,QAAQ,EAAE,IAAI,CAAA;KAAE;CACzD,CAAC"}
1
+ {"version":3,"file":"CommandPaletteExample.vue.d.ts","sourceRoot":"","sources":["../../../src/components/CommandPalette/CommandPaletteExample.vue"],"names":[],"mappings":";IA+HE,oCAAoC;eACzB,MAAM;;;;IADjB,oCAAoC;eACzB,MAAM;;;;AA6QnB,wBAOG;AAOH,KAAK,sBAAsB,CAAC,CAAC,IAAI,CAAC,SAAS,SAAS,GAAG,KAAK,GAAG,CAAC,CAAC;AAC5D,KAAK,uBAAuB,CAAC,CAAC,IAAI;KAChC,CAAC,IAAI,MAAM,CAAC,CAAC,CAAC,GAAG,EAAE,SAAS,IAAI,CAAC,CAAC,EAAE,CAAC,CAAC,GACpC;QAAE,IAAI,EAAE,OAAO,KAAK,EAAE,QAAQ,CAAC,sBAAsB,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAA;KAAE,GAC9D;QAAE,IAAI,EAAE,OAAO,KAAK,EAAE,QAAQ,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;QAAC,QAAQ,EAAE,IAAI,CAAA;KAAE;CACzD,CAAC"}
@@ -1,127 +1,106 @@
1
- import { defineComponent as B, ref as c, onMounted as x, openBlock as m, createElementBlock as h, createElementVNode as a, withDirectives as I, withKeys as R, withModifiers as V, vModelText as q, createVNode as o, unref as s, withCtx as r, Fragment as K, renderList as T, createBlock as W, createTextVNode as d, toDisplayString as v } from "vue";
2
- import _ from "../HttpMethod/HttpMethod.vue.js";
3
- import { useWorkspace as j } from "../../store/workspace.js";
4
- import { ScalarDropdown as z, ScalarDropdownItem as P, ScalarButton as w, ScalarIcon as F } from "@scalar/components";
5
- import { useToasts as H } from "@scalar/use-toasts";
6
- import { useRouter as L } from "vue-router";
7
- const U = { class: "flex w-full flex-col gap-3" }, A = { class: "gap-3 rounded bg-b-2 focus-within:bg-b-1 focus-within:shadow-border min-h-20 relative" }, G = /* @__PURE__ */ a("label", {
8
- class: "absolute w-full h-full opacity-0 cursor-text",
9
- for: "examplename"
10
- }, null, -1), J = ["onKeydown"], O = { class: "flex gap-2" }, Q = { class: "flex flex-1 max-h-8" }, X = { class: "flex items-center gap-2" }, Y = { class: "max-h-40 custom-scroll" }, ne = /* @__PURE__ */ B({
1
+ import { defineComponent as y, ref as p, openBlock as u, createBlock as d, withCtx as a, createVNode as l, unref as e, createElementVNode as f, createElementBlock as D, Fragment as N, renderList as V, createTextVNode as c, toDisplayString as v } from "vue";
2
+ import x from "../HttpMethod/HttpMethod.vue.js";
3
+ import { ScalarDropdown as B, ScalarDropdownItem as R, ScalarButton as W, ScalarIcon as j } from "@scalar/components";
4
+ import { useToasts as z } from "@scalar/use-toasts";
5
+ import { useRouter as I } from "vue-router";
6
+ import M from "./CommandActionForm.vue.js";
7
+ import P from "./CommandActionInput.vue.js";
8
+ import { useWorkspace as T } from "../../store/store.js";
9
+ const F = { class: "flex items-center gap-2" }, H = { class: "max-h-40 custom-scroll" }, Y = /* @__PURE__ */ y({
11
10
  __name: "CommandPaletteExample",
12
11
  props: {
13
12
  metaData: {}
14
13
  },
15
14
  emits: ["close"],
16
- setup(b, { emit: k }) {
17
- const y = b, g = k, { push: C } = L(), {
18
- activeRequest: D,
19
- activeWorkspace: E,
20
- activeWorkspaceRequests: S,
21
- requests: N,
22
- requestExampleMutators: M
23
- } = j(), { toast: $ } = H(), n = c(""), l = c(
15
+ setup(h, { emit: _ }) {
16
+ const b = h, k = _, { push: w } = I(), {
17
+ activeRequest: C,
18
+ activeWorkspace: S,
19
+ activeWorkspaceRequests: E,
20
+ requests: m,
21
+ requestExampleMutators: $
22
+ } = T(), { toast: g } = z(), s = p(""), o = p(
24
23
  // Ensure we pre-select the correct request
25
- N[y.metaData ?? ""] ?? D.value
26
- ), p = (e) => l.value = e, u = c(null);
27
- x(() => {
28
- var e;
29
- return (e = u.value) == null ? void 0 : e.focus();
30
- });
31
- const f = () => {
32
- if (!n.value) {
33
- $("Please enter a name before creating an example.", "error");
24
+ m[b.metaData ?? ""] ?? C.value
25
+ ), i = (r) => o.value = r, q = () => {
26
+ if (!s.value) {
27
+ g("Please enter a name before creating an example.", "error");
34
28
  return;
35
29
  }
36
- const e = M.add(
37
- l.value,
38
- n.value
30
+ const r = $.add(
31
+ o.value,
32
+ s.value
39
33
  );
40
- e && (C(
41
- `/workspace/${E.value.uid}/request/${l.value.uid}/examples/${e.uid}`
42
- ), g("close"));
34
+ r && (w(
35
+ `/workspace/${S.value.uid}/request/${o.value.uid}/examples/${r.uid}`
36
+ ), k("close"));
43
37
  };
44
- return x(() => {
45
- var e;
46
- (e = u.value) == null || e.focus();
47
- }), (e, i) => (m(), h("div", U, [
48
- a("div", A, [
49
- G,
50
- I(a("input", {
51
- id: "examplename",
52
- ref_key: "exampleInput",
53
- ref: u,
54
- "onUpdate:modelValue": i[0] || (i[0] = (t) => n.value = t),
55
- class: "border-transparent outline-none w-full pl-8 text-sm min-h-8 py-1.5",
56
- label: "Example Name",
57
- placeholder: "Example Name",
58
- onKeydown: R(V(f, ["prevent"]), ["enter"])
59
- }, null, 40, J), [
60
- [q, n.value]
61
- ])
62
- ]),
63
- a("div", O, [
64
- a("div", Q, [
65
- o(s(z), {
66
- placement: "bottom",
67
- resize: ""
68
- }, {
69
- items: r(() => [
70
- a("div", Y, [
71
- (m(!0), h(K, null, T(s(S), (t) => (m(), W(s(P), {
72
- key: t.uid,
73
- class: "flex h-7 w-full items-center justify-between px-1 pr-[26px]",
74
- onClick: (Z) => p(t)
75
- }, {
76
- default: r(() => [
77
- d(v(t.summary) + " ", 1),
78
- o(_, {
79
- method: t.method
80
- }, null, 8, ["method"])
81
- ]),
82
- _: 2
83
- }, 1032, ["onClick"]))), 128))
84
- ])
85
- ]),
86
- default: r(() => [
87
- o(s(w), {
88
- class: "justify-between p-2 max-h-8 w-full gap-1 text-xs hover:bg-b-2",
89
- variant: "outlined",
90
- onClick: i[1] || (i[1] = (t) => p(l.value))
38
+ return (r, n) => (u(), d(M, {
39
+ disabled: !s.value.trim(),
40
+ onSubmit: q
41
+ }, {
42
+ options: a(() => [
43
+ l(e(B), {
44
+ placement: "bottom",
45
+ resize: ""
46
+ }, {
47
+ items: a(() => [
48
+ f("div", H, [
49
+ (u(!0), D(N, null, V(e(E), (t) => (u(), d(e(R), {
50
+ key: t,
51
+ class: "flex h-7 w-full items-center justify-between px-1 pr-[26px]",
52
+ onClick: (L) => i(e(m)[t])
91
53
  }, {
92
- default: r(() => [
93
- d(v(l.value.summary) + " ", 1),
94
- a("div", X, [
95
- o(_, {
96
- method: l.value.method
97
- }, null, 8, ["method"]),
98
- o(s(F), {
99
- class: "text-c-3",
100
- icon: "ChevronDown",
101
- size: "xs"
102
- })
103
- ])
54
+ default: a(() => [
55
+ c(v(e(m)[t].summary) + " ", 1),
56
+ l(x, {
57
+ method: e(m)[t].method
58
+ }, null, 8, ["method"])
104
59
  ]),
105
- _: 1
106
- })
107
- ]),
108
- _: 1
109
- })
110
- ]),
111
- o(s(w), {
112
- class: "max-h-8 text-xs p-0 px-3",
113
- disabled: !n.value.trim(),
114
- onClick: f
115
- }, {
116
- default: r(() => [
117
- d(" Create Example ")
60
+ _: 2
61
+ }, 1032, ["onClick"]))), 128))
62
+ ])
63
+ ]),
64
+ default: a(() => [
65
+ l(e(W), {
66
+ class: "justify-between p-2 max-h-8 w-full gap-1 text-xs hover:bg-b-2",
67
+ variant: "outlined",
68
+ onClick: n[1] || (n[1] = (t) => i(o.value))
69
+ }, {
70
+ default: a(() => [
71
+ c(v(o.value.summary) + " ", 1),
72
+ f("div", F, [
73
+ l(x, {
74
+ method: o.value.method
75
+ }, null, 8, ["method"]),
76
+ l(e(j), {
77
+ class: "text-c-3",
78
+ icon: "ChevronDown",
79
+ size: "xs"
80
+ })
81
+ ])
82
+ ]),
83
+ _: 1
84
+ })
118
85
  ]),
119
86
  _: 1
120
- }, 8, ["disabled"])
121
- ])
122
- ]));
87
+ })
88
+ ]),
89
+ submit: a(() => [
90
+ c("Create Example")
91
+ ]),
92
+ default: a(() => [
93
+ l(P, {
94
+ modelValue: s.value,
95
+ "onUpdate:modelValue": n[0] || (n[0] = (t) => s.value = t),
96
+ label: "Example Name",
97
+ placeholder: "Example Name"
98
+ }, null, 8, ["modelValue"])
99
+ ]),
100
+ _: 1
101
+ }, 8, ["disabled"]));
123
102
  }
124
103
  });
125
104
  export {
126
- ne as default
105
+ Y as default
127
106
  };
@@ -1 +1 @@
1
- {"version":3,"file":"CommandPaletteImport.vue.d.ts","sourceRoot":"","sources":["../../../src/components/CommandPalette/CommandPaletteImport.vue"],"names":[],"mappings":";;;;;AA8TA,wBAMG"}
1
+ {"version":3,"file":"CommandPaletteImport.vue.d.ts","sourceRoot":"","sources":["../../../src/components/CommandPalette/CommandPaletteImport.vue"],"names":[],"mappings":";;;;;AAyQA,wBAMG"}
@@ -1,94 +1,77 @@
1
- import { defineComponent as S, ref as d, onMounted as C, openBlock as F, createElementBlock as U, createElementVNode as o, withDirectives as M, withKeys as N, withModifiers as R, vModelText as T, createVNode as c, unref as l, withCtx as f, createTextVNode as h } from "vue";
2
- import { useWorkspace as V } from "../../store/workspace.js";
3
- import { ScalarButton as x, ScalarIcon as A } from "@scalar/components";
4
- import { useToasts as B } from "@scalar/use-toasts";
5
- import { useFileDialog as D } from "../../hooks/useFileDialog.js";
6
- const K = { class: "flex w-full flex-col gap-3" }, L = { class: "gap-3 rounded bg-b-2 focus-within:bg-b-1 focus-within:shadow-border min-h-20 relative" }, P = /* @__PURE__ */ o("label", {
7
- class: "absolute w-full h-full opacity-0 cursor-text",
8
- for: "requestimport"
9
- }, null, -1), q = ["onKeydown"], E = { class: "flex gap-2" }, W = { class: "flex flex-1 gap-2 max-h-8" }, G = /* @__PURE__ */ S({
1
+ import { defineComponent as w, ref as k, openBlock as F, createBlock as y, withCtx as l, createVNode as n, unref as c, createTextVNode as p } from "vue";
2
+ import { ScalarButton as C, ScalarIcon as I } from "@scalar/components";
3
+ import { useToasts as U } from "@scalar/use-toasts";
4
+ import b from "./CommandActionForm.vue.js";
5
+ import V from "./CommandActionInput.vue.js";
6
+ import { useFileDialog as R } from "../../hooks/useFileDialog.js";
7
+ import { useWorkspace as $ } from "../../store/store.js";
8
+ const W = /* @__PURE__ */ w({
10
9
  __name: "CommandPaletteImport",
11
10
  emits: ["close"],
12
- setup($, { emit: g }) {
13
- const i = g, { activeWorkspace: _, importSpecFile: w, importSpecFromUrl: v } = V(), s = d(""), { toast: r } = B(), { open: y } = D({
11
+ setup(A, { emit: u }) {
12
+ const i = u, { activeWorkspace: f, importSpecFile: d, importSpecFromUrl: g } = $(), t = k(""), { toast: r } = U(), { open: _ } = R({
14
13
  onChange: async (e) => {
15
- const t = e == null ? void 0 : e[0];
16
- if (t) {
14
+ const o = e == null ? void 0 : e[0];
15
+ if (o) {
17
16
  const a = new FileReader();
18
- a.onload = async (b) => {
19
- var u;
20
- const k = (u = b.target) == null ? void 0 : u.result;
17
+ a.onload = async (S) => {
18
+ var m;
19
+ const h = (m = S.target) == null ? void 0 : m.result;
21
20
  try {
22
- await w(k, _.value.uid), r("Import successful", "info"), i("close");
23
- } catch (n) {
24
- const I = (n == null ? void 0 : n.message) || "Unknown error";
25
- r(`Import failed: ${I}`, "error");
21
+ await d(h, f.value.uid), r("Import successful", "info"), i("close");
22
+ } catch (s) {
23
+ console.error(s);
24
+ const v = (s == null ? void 0 : s.message) || "Unknown error";
25
+ r(`Import failed: ${v}`, "error");
26
26
  }
27
- }, a.readAsText(t);
27
+ }, a.readAsText(o);
28
28
  }
29
29
  },
30
30
  multiple: !1,
31
31
  accept: ".json,.yaml,.yml"
32
- }), p = async () => {
33
- if (s.value)
32
+ }), x = async () => {
33
+ if (t.value)
34
34
  try {
35
- await v(s.value), r("Import successful", "info"), i("close");
35
+ await g(t.value), r("Import successful", "info"), i("close");
36
36
  } catch (e) {
37
37
  console.error("the error ", e);
38
- const t = (e == null ? void 0 : e.message) || "Unknown error";
39
- r(`Import failed: ${t}`, "error");
38
+ const o = (e == null ? void 0 : e.message) || "Unknown error";
39
+ r(`Import failed: ${o}`, "error");
40
40
  }
41
- }, m = d(null);
42
- return C(() => {
43
- var e;
44
- (e = m.value) == null || e.focus();
45
- }), (e, t) => (F(), U("div", K, [
46
- o("div", L, [
47
- P,
48
- M(o("input", {
49
- id: "requestimport",
50
- ref_key: "importInput",
51
- ref: m,
52
- "onUpdate:modelValue": t[0] || (t[0] = (a) => s.value = a),
53
- class: "border-transparent outline-none w-full pl-8 text-sm min-h-8 py-1.5",
54
- label: "Paste Swagger File URL",
55
- placeholder: "Paste Swagger File URL",
56
- onKeydown: N(R(p, ["prevent"]), ["enter"])
57
- }, null, 40, q), [
58
- [T, s.value]
59
- ])
60
- ]),
61
- o("div", E, [
62
- o("div", W, [
63
- c(l(x), {
64
- class: "p-2 max-h-8 gap-1 text-xs hover:bg-b-2 relative",
65
- variant: "outlined",
66
- onClick: l(y)
67
- }, {
68
- default: f(() => [
69
- h(" JSON, or YAML Files "),
70
- c(l(A), {
71
- class: "text-c-3 -rotate-90",
72
- icon: "ArrowRight",
73
- size: "sm"
74
- })
75
- ]),
76
- _: 1
77
- }, 8, ["onClick"])
78
- ]),
79
- c(l(x), {
80
- class: "max-h-8 text-xs p-0 px-3",
81
- onClick: p
41
+ };
42
+ return (e, o) => (F(), y(b, { onSubmit: x }, {
43
+ options: l(() => [
44
+ n(c(C), {
45
+ class: "p-2 max-h-8 gap-1 text-xs hover:bg-b-2 relative",
46
+ variant: "outlined",
47
+ onClick: c(_)
82
48
  }, {
83
- default: f(() => [
84
- h(" Import Collection ")
49
+ default: l(() => [
50
+ p(" JSON, or YAML Files "),
51
+ n(c(I), {
52
+ class: "text-c-3 -rotate-90",
53
+ icon: "ArrowRight",
54
+ size: "sm"
55
+ })
85
56
  ]),
86
57
  _: 1
87
- })
88
- ])
89
- ]));
58
+ }, 8, ["onClick"])
59
+ ]),
60
+ submit: l(() => [
61
+ p("Import Collection")
62
+ ]),
63
+ default: l(() => [
64
+ n(V, {
65
+ modelValue: t.value,
66
+ "onUpdate:modelValue": o[0] || (o[0] = (a) => t.value = a),
67
+ label: "Paste Swagger File URL",
68
+ placeholder: "Paste Swagger File URL"
69
+ }, null, 8, ["modelValue"])
70
+ ]),
71
+ _: 1
72
+ }));
90
73
  }
91
74
  });
92
75
  export {
93
- G as default
76
+ W as default
94
77
  };
@@ -1,7 +1,26 @@
1
- declare const _default: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
1
+ declare const _default: import("vue").DefineComponent<__VLS_TypePropsToOption<{
2
+ metaData?: {
3
+ itemUid: string;
4
+ parentUid: string;
5
+ };
6
+ }>, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
2
7
  close: () => void;
3
- }, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{}>> & {
8
+ }, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<__VLS_TypePropsToOption<{
9
+ metaData?: {
10
+ itemUid: string;
11
+ parentUid: string;
12
+ };
13
+ }>>> & {
4
14
  onClose?: (() => any) | undefined;
5
15
  }, {}, {}>;
6
16
  export default _default;
17
+ type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
18
+ type __VLS_TypePropsToOption<T> = {
19
+ [K in keyof T]-?: {} extends Pick<T, K> ? {
20
+ type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
21
+ } : {
22
+ type: import('vue').PropType<T[K]>;
23
+ required: true;
24
+ };
25
+ };
7
26
  //# sourceMappingURL=CommandPaletteRequest.vue.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"CommandPaletteRequest.vue.d.ts","sourceRoot":"","sources":["../../../src/components/CommandPalette/CommandPaletteRequest.vue"],"names":[],"mappings":";;;;;AAmiBA,wBAMG"}
1
+ {"version":3,"file":"CommandPaletteRequest.vue.d.ts","sourceRoot":"","sources":["../../../src/components/CommandPalette/CommandPaletteRequest.vue"],"names":[],"mappings":";eAgMa;QACT,OAAO,EAAE,MAAM,CAAA;QACf,SAAS,EAAE,MAAM,CAAA;KAClB;;;;eAHU;QACT,OAAO,EAAE,MAAM,CAAA;QACf,SAAS,EAAE,MAAM,CAAA;KAClB;;;;AAmUH,wBAOG;AAOH,KAAK,sBAAsB,CAAC,CAAC,IAAI,CAAC,SAAS,SAAS,GAAG,KAAK,GAAG,CAAC,CAAC;AAC5D,KAAK,uBAAuB,CAAC,CAAC,IAAI;KAChC,CAAC,IAAI,MAAM,CAAC,CAAC,CAAC,GAAG,EAAE,SAAS,IAAI,CAAC,CAAC,EAAE,CAAC,CAAC,GACpC;QAAE,IAAI,EAAE,OAAO,KAAK,EAAE,QAAQ,CAAC,sBAAsB,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAA;KAAE,GAC9D;QAAE,IAAI,EAAE,OAAO,KAAK,EAAE,QAAQ,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;QAAC,QAAQ,EAAE,IAAI,CAAA;KAAE;CACzD,CAAC"}