@scalar/api-client 2.9.1 → 2.10.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 (341) hide show
  1. package/CHANGELOG.md +25 -0
  2. package/README.md +2 -2
  3. package/dist/libs/send-request/build-request-security.d.ts.map +1 -1
  4. package/dist/libs/send-request/build-request-security.js +1 -1
  5. package/dist/libs/send-request/create-fetch-query-params.d.ts.map +1 -1
  6. package/dist/style.css +1 -1
  7. package/dist/v2/blocks/operation-block/OperationBlock.vue.d.ts +89 -0
  8. package/dist/v2/blocks/operation-block/OperationBlock.vue.d.ts.map +1 -0
  9. package/dist/v2/blocks/operation-block/OperationBlock.vue.js +129 -0
  10. package/dist/v2/blocks/operation-block/OperationBlock.vue2.js +4 -0
  11. package/dist/v2/{features/operation → blocks/operation-block}/components/Header.vue.d.ts +8 -27
  12. package/dist/v2/blocks/operation-block/components/Header.vue.d.ts.map +1 -0
  13. package/dist/v2/blocks/operation-block/components/Header.vue.js +7 -0
  14. package/dist/v2/blocks/operation-block/components/Header.vue2.js +93 -0
  15. package/dist/v2/blocks/operation-block/index.d.ts +2 -0
  16. package/dist/v2/blocks/operation-block/index.d.ts.map +1 -0
  17. package/dist/v2/blocks/operation-block/index.js +4 -0
  18. package/dist/v2/blocks/scalar-address-bar-block/components/AddressBar.vue.d.ts +8 -24
  19. package/dist/v2/blocks/scalar-address-bar-block/components/AddressBar.vue.d.ts.map +1 -1
  20. package/dist/v2/blocks/scalar-address-bar-block/components/AddressBar.vue.js +2 -2
  21. package/dist/v2/blocks/scalar-address-bar-block/components/AddressBar.vue2.js +60 -59
  22. package/dist/v2/blocks/scalar-auth-selector-block/components/AuthSelector.vue.d.ts +7 -28
  23. package/dist/v2/blocks/scalar-auth-selector-block/components/AuthSelector.vue.d.ts.map +1 -1
  24. package/dist/v2/blocks/scalar-auth-selector-block/components/AuthSelector.vue.js +1 -1
  25. package/dist/v2/blocks/scalar-auth-selector-block/components/AuthSelector.vue2.js +97 -87
  26. package/dist/v2/blocks/scalar-auth-selector-block/components/RequestAuthDataTable.vue.d.ts +7 -17
  27. package/dist/v2/blocks/scalar-auth-selector-block/components/RequestAuthDataTable.vue.d.ts.map +1 -1
  28. package/dist/v2/blocks/scalar-auth-selector-block/components/RequestAuthDataTable.vue.js +1 -1
  29. package/dist/v2/blocks/scalar-auth-selector-block/components/RequestAuthDataTable.vue2.js +46 -41
  30. package/dist/v2/blocks/scalar-auth-selector-block/components/RequestAuthTab.vue.d.ts +1 -1
  31. package/dist/v2/blocks/scalar-auth-selector-block/components/RequestAuthTab.vue.d.ts.map +1 -1
  32. package/dist/v2/blocks/scalar-auth-selector-block/components/RequestAuthTab.vue.js +4 -5
  33. package/dist/v2/blocks/scalar-auth-selector-block/helpers/oauth.d.ts.map +1 -1
  34. package/dist/v2/blocks/scalar-auth-selector-block/helpers/oauth.js +47 -45
  35. package/dist/v2/blocks/scalar-auth-selector-block/helpers/security-scheme.d.ts +5 -5
  36. package/dist/v2/blocks/scalar-auth-selector-block/helpers/security-scheme.d.ts.map +1 -1
  37. package/dist/v2/blocks/scalar-auth-selector-block/helpers/security-scheme.js +7 -7
  38. package/dist/v2/blocks/scalar-operation-block/components/OperationBlock.vue.d.ts +6 -9
  39. package/dist/v2/blocks/scalar-operation-block/components/OperationBlock.vue.d.ts.map +1 -1
  40. package/dist/v2/blocks/scalar-operation-block/components/OperationBlock.vue.js +2 -2
  41. package/dist/v2/blocks/scalar-operation-block/components/OperationBlock.vue2.js +255 -206
  42. package/dist/v2/blocks/scalar-operation-block/components/OperationBody.vue.d.ts +30 -25
  43. package/dist/v2/blocks/scalar-operation-block/components/OperationBody.vue.d.ts.map +1 -1
  44. package/dist/v2/blocks/scalar-operation-block/components/OperationBody.vue.js +2 -2
  45. package/dist/v2/blocks/scalar-operation-block/components/OperationBody.vue2.js +140 -97
  46. package/dist/v2/blocks/scalar-operation-block/components/OperationParams.vue.d.ts +1 -0
  47. package/dist/v2/blocks/scalar-operation-block/components/OperationParams.vue.d.ts.map +1 -1
  48. package/dist/v2/blocks/scalar-operation-block/components/OperationParams.vue.js +31 -29
  49. package/dist/v2/blocks/scalar-operation-block/components/OperationTable.vue.d.ts +1 -0
  50. package/dist/v2/blocks/scalar-operation-block/components/OperationTable.vue.d.ts.map +1 -1
  51. package/dist/v2/blocks/scalar-operation-block/components/OperationTable.vue.js +2 -2
  52. package/dist/v2/blocks/scalar-operation-block/components/OperationTable.vue2.js +32 -29
  53. package/dist/v2/blocks/scalar-operation-block/components/OperationTableRow.vue.d.ts.map +1 -1
  54. package/dist/v2/blocks/scalar-operation-block/components/OperationTableRow.vue.js +56 -51
  55. package/dist/v2/blocks/scalar-response-block/components/ResponseBlock.vue.d.ts +2 -4
  56. package/dist/v2/blocks/scalar-response-block/components/ResponseBlock.vue.d.ts.map +1 -1
  57. package/dist/v2/blocks/scalar-response-block/components/ResponseBlock.vue.js +3 -3
  58. package/dist/v2/blocks/scalar-response-block/components/ResponseBlock.vue2.js +39 -38
  59. package/dist/v2/components/sidebar/Sidebar.vue.d.ts.map +1 -1
  60. package/dist/v2/components/sidebar/Sidebar.vue.js +43 -42
  61. package/dist/v2/features/app/App.vue.d.ts.map +1 -1
  62. package/dist/v2/features/app/App.vue.js +62 -49
  63. package/dist/v2/features/app/components/AppSidebar.vue.d.ts +1 -1
  64. package/dist/v2/features/app/components/AppSidebar.vue.js +2 -2
  65. package/dist/v2/features/app/helpers/routes.d.ts +5 -1
  66. package/dist/v2/features/app/helpers/routes.d.ts.map +1 -1
  67. package/dist/v2/features/app/helpers/routes.js +1 -1
  68. package/dist/v2/features/collection/DocumentCollection.vue2.js +27 -24
  69. package/dist/v2/features/collection/WorkspaceCollection.vue2.js +15 -12
  70. package/dist/v2/features/collection/components/Authentication.vue.d.ts +4 -25
  71. package/dist/v2/features/collection/components/Authentication.vue.d.ts.map +1 -1
  72. package/dist/v2/features/collection/components/Authentication.vue.js +1 -1
  73. package/dist/v2/features/collection/components/Authentication.vue2.js +27 -28
  74. package/dist/v2/features/collection/components/Environment.vue2.js +3 -0
  75. package/dist/v2/features/collection/components/Overview.vue2.js +24 -21
  76. package/dist/v2/features/operation/Operation.vue.d.ts +10 -77
  77. package/dist/v2/features/operation/Operation.vue.d.ts.map +1 -1
  78. package/dist/v2/features/operation/Operation.vue.js +56 -114
  79. package/dist/v2/hooks/use-workspace-client-events.d.ts.map +1 -1
  80. package/dist/v2/hooks/use-workspace-client-events.js +131 -18
  81. package/dist/views/Request/ResponseSection/ResponseEmpty.vue2.js +1 -1
  82. package/dist/views/Request/libs/oauth2.d.ts.map +1 -1
  83. package/dist/views/Request/libs/oauth2.js +8 -6
  84. package/package.json +17 -17
  85. package/dist/components/CodeInput/CodeInput.test.d.ts +0 -2
  86. package/dist/components/CodeInput/CodeInput.test.d.ts.map +0 -1
  87. package/dist/components/ImportCollection/utils/get-openapi-version.test.d.ts +0 -2
  88. package/dist/components/ImportCollection/utils/get-openapi-version.test.d.ts.map +0 -1
  89. package/dist/components/ImportCollection/utils/is-document.test.d.ts +0 -2
  90. package/dist/components/ImportCollection/utils/is-document.test.d.ts.map +0 -1
  91. package/dist/components/ImportCollection/utils/is-url.test.d.ts +0 -2
  92. package/dist/components/ImportCollection/utils/is-url.test.d.ts.map +0 -1
  93. package/dist/components/Search/useSearch.test.d.ts +0 -2
  94. package/dist/components/Search/useSearch.test.d.ts.map +0 -1
  95. package/dist/components/Server/ServerDropdown.test.d.ts +0 -2
  96. package/dist/components/Server/ServerDropdown.test.d.ts.map +0 -1
  97. package/dist/components/ViewLayout/ViewLayoutSection.test.d.ts +0 -2
  98. package/dist/components/ViewLayout/ViewLayoutSection.test.d.ts.map +0 -1
  99. package/dist/hooks/useResponseBody.test.d.ts +0 -2
  100. package/dist/hooks/useResponseBody.test.d.ts.map +0 -1
  101. package/dist/hooks/useSidebar.test.d.ts +0 -2
  102. package/dist/hooks/useSidebar.test.d.ts.map +0 -1
  103. package/dist/layouts/App/create-api-client-app.test.d.ts +0 -2
  104. package/dist/layouts/App/create-api-client-app.test.d.ts.map +0 -1
  105. package/dist/layouts/Modal/create-api-client-modal.test.d.ts +0 -2
  106. package/dist/layouts/Modal/create-api-client-modal.test.d.ts.map +0 -1
  107. package/dist/layouts/Web/create-api-client-web.test.d.ts +0 -2
  108. package/dist/layouts/Web/create-api-client-web.test.d.ts.map +0 -1
  109. package/dist/libs/create-client.test.d.ts +0 -2
  110. package/dist/libs/create-client.test.d.ts.map +0 -1
  111. package/dist/libs/env-helpers.test.d.ts +0 -2
  112. package/dist/libs/env-helpers.test.d.ts.map +0 -1
  113. package/dist/libs/event-bus.test.d.ts +0 -2
  114. package/dist/libs/event-bus.test.d.ts.map +0 -1
  115. package/dist/libs/extractAttachmentFilename.test.d.ts +0 -2
  116. package/dist/libs/extractAttachmentFilename.test.d.ts.map +0 -1
  117. package/dist/libs/find-request.test.d.ts +0 -2
  118. package/dist/libs/find-request.test.d.ts.map +0 -1
  119. package/dist/libs/get-request-uid-by-path-method.test.d.ts +0 -2
  120. package/dist/libs/get-request-uid-by-path-method.test.d.ts.map +0 -1
  121. package/dist/libs/hot-keys.test.d.ts +0 -2
  122. package/dist/libs/hot-keys.test.d.ts.map +0 -1
  123. package/dist/libs/importers/curl.test.d.ts +0 -2
  124. package/dist/libs/importers/curl.test.d.ts.map +0 -1
  125. package/dist/libs/normalize-headers.test.d.ts +0 -2
  126. package/dist/libs/normalize-headers.test.d.ts.map +0 -1
  127. package/dist/libs/parse-curl.test.d.ts +0 -2
  128. package/dist/libs/parse-curl.test.d.ts.map +0 -1
  129. package/dist/libs/send-request/build-request-security.test.d.ts +0 -2
  130. package/dist/libs/send-request/build-request-security.test.d.ts.map +0 -1
  131. package/dist/libs/send-request/create-fetch-auth.test.d.ts +0 -2
  132. package/dist/libs/send-request/create-fetch-auth.test.d.ts.map +0 -1
  133. package/dist/libs/send-request/create-fetch-body.test.d.ts +0 -2
  134. package/dist/libs/send-request/create-fetch-body.test.d.ts.map +0 -1
  135. package/dist/libs/send-request/create-fetch-headers.test.d.ts +0 -2
  136. package/dist/libs/send-request/create-fetch-headers.test.d.ts.map +0 -1
  137. package/dist/libs/send-request/create-fetch-query-params.test.d.ts +0 -2
  138. package/dist/libs/send-request/create-fetch-query-params.test.d.ts.map +0 -1
  139. package/dist/libs/send-request/create-request-operation.test.d.ts +0 -191
  140. package/dist/libs/send-request/create-request-operation.test.d.ts.map +0 -1
  141. package/dist/libs/send-request/decode-buffer.test.d.ts +0 -2
  142. package/dist/libs/send-request/decode-buffer.test.d.ts.map +0 -1
  143. package/dist/libs/send-request/set-request-cookies.test.d.ts +0 -2
  144. package/dist/libs/send-request/set-request-cookies.test.d.ts.map +0 -1
  145. package/dist/libs/string-template.test.d.ts +0 -2
  146. package/dist/libs/string-template.test.d.ts.map +0 -1
  147. package/dist/libs/validate-parameters.test.d.ts +0 -2
  148. package/dist/libs/validate-parameters.test.d.ts.map +0 -1
  149. package/dist/plugins/plugin-manager.test.d.ts +0 -2
  150. package/dist/plugins/plugin-manager.test.d.ts.map +0 -1
  151. package/dist/routes.test.d.ts +0 -2
  152. package/dist/routes.test.d.ts.map +0 -1
  153. package/dist/store/collections.test.d.ts +0 -2
  154. package/dist/store/collections.test.d.ts.map +0 -1
  155. package/dist/store/request.test.d.ts +0 -2
  156. package/dist/store/request.test.d.ts.map +0 -1
  157. package/dist/v2/blocks/operation-code-sample/components/ExamplePicker.test.d.ts +0 -2
  158. package/dist/v2/blocks/operation-code-sample/components/ExamplePicker.test.d.ts.map +0 -1
  159. package/dist/v2/blocks/operation-code-sample/components/HttpMethod.test.d.ts +0 -2
  160. package/dist/v2/blocks/operation-code-sample/components/HttpMethod.test.d.ts.map +0 -1
  161. package/dist/v2/blocks/operation-code-sample/components/OperationCodeSample.test.d.ts +0 -2
  162. package/dist/v2/blocks/operation-code-sample/components/OperationCodeSample.test.d.ts.map +0 -1
  163. package/dist/v2/blocks/operation-code-sample/helpers/find-client.test.d.ts +0 -2
  164. package/dist/v2/blocks/operation-code-sample/helpers/find-client.test.d.ts.map +0 -1
  165. package/dist/v2/blocks/operation-code-sample/helpers/generate-client-options.test.d.ts +0 -2
  166. package/dist/v2/blocks/operation-code-sample/helpers/generate-client-options.test.d.ts.map +0 -1
  167. package/dist/v2/blocks/operation-code-sample/helpers/generate-code-snippet.test.d.ts +0 -2
  168. package/dist/v2/blocks/operation-code-sample/helpers/generate-code-snippet.test.d.ts.map +0 -1
  169. package/dist/v2/blocks/operation-code-sample/helpers/get-example-from-schema.test.d.ts +0 -2
  170. package/dist/v2/blocks/operation-code-sample/helpers/get-example-from-schema.test.d.ts.map +0 -1
  171. package/dist/v2/blocks/operation-code-sample/helpers/get-resolved-ref-deep.test.d.ts +0 -2
  172. package/dist/v2/blocks/operation-code-sample/helpers/get-resolved-ref-deep.test.d.ts.map +0 -1
  173. package/dist/v2/blocks/operation-code-sample/helpers/get-secrets.test.d.ts +0 -2
  174. package/dist/v2/blocks/operation-code-sample/helpers/get-secrets.test.d.ts.map +0 -1
  175. package/dist/v2/blocks/operation-code-sample/helpers/operation-to-har/get-example-value.test.d.ts +0 -2
  176. package/dist/v2/blocks/operation-code-sample/helpers/operation-to-har/get-example-value.test.d.ts.map +0 -1
  177. package/dist/v2/blocks/operation-code-sample/helpers/operation-to-har/operation-to-har.test.d.ts +0 -2
  178. package/dist/v2/blocks/operation-code-sample/helpers/operation-to-har/operation-to-har.test.d.ts.map +0 -1
  179. package/dist/v2/blocks/operation-code-sample/helpers/operation-to-har/process-body.test.d.ts +0 -2
  180. package/dist/v2/blocks/operation-code-sample/helpers/operation-to-har/process-body.test.d.ts.map +0 -1
  181. package/dist/v2/blocks/operation-code-sample/helpers/operation-to-har/process-parameters.test.d.ts +0 -2
  182. package/dist/v2/blocks/operation-code-sample/helpers/operation-to-har/process-parameters.test.d.ts.map +0 -1
  183. package/dist/v2/blocks/operation-code-sample/helpers/operation-to-har/process-security-schemes.test.d.ts +0 -2
  184. package/dist/v2/blocks/operation-code-sample/helpers/operation-to-har/process-security-schemes.test.d.ts.map +0 -1
  185. package/dist/v2/blocks/operation-code-sample/helpers/operation-to-har/process-server-url.test.d.ts +0 -2
  186. package/dist/v2/blocks/operation-code-sample/helpers/operation-to-har/process-server-url.test.d.ts.map +0 -1
  187. package/dist/v2/blocks/scalar-address-bar-block/components/AddressBar.test.d.ts +0 -2
  188. package/dist/v2/blocks/scalar-address-bar-block/components/AddressBar.test.d.ts.map +0 -1
  189. package/dist/v2/blocks/scalar-address-bar-block/components/AddressBarHistory.test.d.ts +0 -2
  190. package/dist/v2/blocks/scalar-address-bar-block/components/AddressBarHistory.test.d.ts.map +0 -1
  191. package/dist/v2/blocks/scalar-auth-selector-block/components/AuthSelector.test.d.ts +0 -2
  192. package/dist/v2/blocks/scalar-auth-selector-block/components/AuthSelector.test.d.ts.map +0 -1
  193. package/dist/v2/blocks/scalar-auth-selector-block/components/DeleteRequestAuthModal.test.d.ts +0 -2
  194. package/dist/v2/blocks/scalar-auth-selector-block/components/DeleteRequestAuthModal.test.d.ts.map +0 -1
  195. package/dist/v2/blocks/scalar-auth-selector-block/components/OAuth2.test.d.ts +0 -2
  196. package/dist/v2/blocks/scalar-auth-selector-block/components/OAuth2.test.d.ts.map +0 -1
  197. package/dist/v2/blocks/scalar-auth-selector-block/components/OAuthScopesInput.test.d.ts +0 -2
  198. package/dist/v2/blocks/scalar-auth-selector-block/components/OAuthScopesInput.test.d.ts.map +0 -1
  199. package/dist/v2/blocks/scalar-auth-selector-block/components/RequestAuthDataTable.test.d.ts +0 -2
  200. package/dist/v2/blocks/scalar-auth-selector-block/components/RequestAuthDataTable.test.d.ts.map +0 -1
  201. package/dist/v2/blocks/scalar-auth-selector-block/components/RequestAuthTab.test.d.ts +0 -2
  202. package/dist/v2/blocks/scalar-auth-selector-block/components/RequestAuthTab.test.d.ts.map +0 -1
  203. package/dist/v2/blocks/scalar-auth-selector-block/helpers/oauth.test.d.ts +0 -2
  204. package/dist/v2/blocks/scalar-auth-selector-block/helpers/oauth.test.d.ts.map +0 -1
  205. package/dist/v2/blocks/scalar-auth-selector-block/helpers/security-scheme.test.d.ts +0 -2
  206. package/dist/v2/blocks/scalar-auth-selector-block/helpers/security-scheme.test.d.ts.map +0 -1
  207. package/dist/v2/blocks/scalar-operation-block/components/OperationBlock.test.d.ts +0 -2
  208. package/dist/v2/blocks/scalar-operation-block/components/OperationBlock.test.d.ts.map +0 -1
  209. package/dist/v2/blocks/scalar-operation-block/components/OperationParams.test.d.ts +0 -2
  210. package/dist/v2/blocks/scalar-operation-block/components/OperationParams.test.d.ts.map +0 -1
  211. package/dist/v2/blocks/scalar-operation-block/components/OperationTable.test.d.ts +0 -2
  212. package/dist/v2/blocks/scalar-operation-block/components/OperationTable.test.d.ts.map +0 -1
  213. package/dist/v2/blocks/scalar-operation-block/components/OperationTableRow.test.d.ts +0 -2
  214. package/dist/v2/blocks/scalar-operation-block/components/OperationTableRow.test.d.ts.map +0 -1
  215. package/dist/v2/blocks/scalar-operation-block/components/OperationTableTooltip.test.d.ts +0 -2
  216. package/dist/v2/blocks/scalar-operation-block/components/OperationTableTooltip.test.d.ts.map +0 -1
  217. package/dist/v2/blocks/scalar-operation-block/helpers/file.test.d.ts +0 -2
  218. package/dist/v2/blocks/scalar-operation-block/helpers/file.test.d.ts.map +0 -1
  219. package/dist/v2/blocks/scalar-operation-block/helpers/get-parameter-content.test.d.ts +0 -2
  220. package/dist/v2/blocks/scalar-operation-block/helpers/get-parameter-content.test.d.ts.map +0 -1
  221. package/dist/v2/blocks/scalar-operation-block/helpers/get-parameter-example.test.d.ts +0 -2
  222. package/dist/v2/blocks/scalar-operation-block/helpers/get-parameter-example.test.d.ts.map +0 -1
  223. package/dist/v2/blocks/scalar-operation-block/helpers/get-parameter-schema.test.d.ts +0 -2
  224. package/dist/v2/blocks/scalar-operation-block/helpers/get-parameter-schema.test.d.ts.map +0 -1
  225. package/dist/v2/blocks/scalar-operation-block/helpers/group-by.test.d.ts +0 -2
  226. package/dist/v2/blocks/scalar-operation-block/helpers/group-by.test.d.ts.map +0 -1
  227. package/dist/v2/blocks/scalar-operation-block/helpers/validate-parameter.test.d.ts +0 -2
  228. package/dist/v2/blocks/scalar-operation-block/helpers/validate-parameter.test.d.ts.map +0 -1
  229. package/dist/v2/blocks/scalar-response-block/components/Headers.test.d.ts +0 -2
  230. package/dist/v2/blocks/scalar-response-block/components/Headers.test.d.ts.map +0 -1
  231. package/dist/v2/blocks/scalar-response-block/components/ResponseBlock.test.d.ts +0 -2
  232. package/dist/v2/blocks/scalar-response-block/components/ResponseBlock.test.d.ts.map +0 -1
  233. package/dist/v2/blocks/scalar-response-block/components/ResponseBodyDownload.test.d.ts +0 -2
  234. package/dist/v2/blocks/scalar-response-block/components/ResponseBodyDownload.test.d.ts.map +0 -1
  235. package/dist/v2/blocks/scalar-response-block/components/ResponseBodyPreview.test.d.ts +0 -2
  236. package/dist/v2/blocks/scalar-response-block/components/ResponseBodyPreview.test.d.ts.map +0 -1
  237. package/dist/v2/blocks/scalar-response-block/components/ResponseBodyStreaming.test.d.ts +0 -2
  238. package/dist/v2/blocks/scalar-response-block/components/ResponseBodyStreaming.test.d.ts.map +0 -1
  239. package/dist/v2/blocks/scalar-response-block/components/ResponseCookies.test.d.ts +0 -2
  240. package/dist/v2/blocks/scalar-response-block/components/ResponseCookies.test.d.ts.map +0 -1
  241. package/dist/v2/blocks/scalar-response-block/helpers/extract-filename.test.d.ts +0 -2
  242. package/dist/v2/blocks/scalar-response-block/helpers/extract-filename.test.d.ts.map +0 -1
  243. package/dist/v2/blocks/scalar-response-block/helpers/get-content-length.test.d.ts +0 -2
  244. package/dist/v2/blocks/scalar-response-block/helpers/get-content-length.test.d.ts.map +0 -1
  245. package/dist/v2/blocks/scalar-response-block/helpers/media-types.test.d.ts +0 -2
  246. package/dist/v2/blocks/scalar-response-block/helpers/media-types.test.d.ts.map +0 -1
  247. package/dist/v2/blocks/scalar-response-block/helpers/process-response-body.test.d.ts +0 -2
  248. package/dist/v2/blocks/scalar-response-block/helpers/process-response-body.test.d.ts.map +0 -1
  249. package/dist/v2/components/code-input/CodeInput.test.d.ts +0 -2
  250. package/dist/v2/components/code-input/CodeInput.test.d.ts.map +0 -1
  251. package/dist/v2/components/code-input/code-variable-widget.test.d.ts +0 -2
  252. package/dist/v2/components/code-input/code-variable-widget.test.d.ts.map +0 -1
  253. package/dist/v2/components/server/ServerDropdown.test.d.ts +0 -2
  254. package/dist/v2/components/server/ServerDropdown.test.d.ts.map +0 -1
  255. package/dist/v2/components/server/ServerDropdownItem.test.d.ts +0 -2
  256. package/dist/v2/components/server/ServerDropdownItem.test.d.ts.map +0 -1
  257. package/dist/v2/features/app/App.test.d.ts +0 -2
  258. package/dist/v2/features/app/App.test.d.ts.map +0 -1
  259. package/dist/v2/features/collection/DocumentCollection.test.d.ts +0 -2
  260. package/dist/v2/features/collection/DocumentCollection.test.d.ts.map +0 -1
  261. package/dist/v2/features/collection/components/Authentication.test.d.ts +0 -2
  262. package/dist/v2/features/collection/components/Authentication.test.d.ts.map +0 -1
  263. package/dist/v2/features/collection/components/Environment.test.d.ts +0 -2
  264. package/dist/v2/features/collection/components/Environment.test.d.ts.map +0 -1
  265. package/dist/v2/features/collection/components/LabelInput.test.d.ts +0 -2
  266. package/dist/v2/features/collection/components/LabelInput.test.d.ts.map +0 -1
  267. package/dist/v2/features/collection/components/Overview.test.d.ts +0 -2
  268. package/dist/v2/features/collection/components/Overview.test.d.ts.map +0 -1
  269. package/dist/v2/features/collection/components/Servers.test.d.ts +0 -2
  270. package/dist/v2/features/collection/components/Servers.test.d.ts.map +0 -1
  271. package/dist/v2/features/collection/components/Settings.test.d.ts +0 -2
  272. package/dist/v2/features/collection/components/Settings.test.d.ts.map +0 -1
  273. package/dist/v2/features/collection/components/Tabs.test.d.ts +0 -2
  274. package/dist/v2/features/collection/components/Tabs.test.d.ts.map +0 -1
  275. package/dist/v2/features/environments/EnvironmentsList.test.d.ts +0 -2
  276. package/dist/v2/features/environments/EnvironmentsList.test.d.ts.map +0 -1
  277. package/dist/v2/features/environments/components/Environment.test.d.ts +0 -2
  278. package/dist/v2/features/environments/components/Environment.test.d.ts.map +0 -1
  279. package/dist/v2/features/environments/components/EnvironmentColors.test.d.ts +0 -2
  280. package/dist/v2/features/environments/components/EnvironmentColors.test.d.ts.map +0 -1
  281. package/dist/v2/features/environments/components/EnvironmentVariablesTable.test.d.ts +0 -2
  282. package/dist/v2/features/environments/components/EnvironmentVariablesTable.test.d.ts.map +0 -1
  283. package/dist/v2/features/global-cookies/components/CookiesTable.test.d.ts +0 -2
  284. package/dist/v2/features/global-cookies/components/CookiesTable.test.d.ts.map +0 -1
  285. package/dist/v2/features/global-cookies/components/GlobalCookies.test.d.ts +0 -2
  286. package/dist/v2/features/global-cookies/components/GlobalCookies.test.d.ts.map +0 -1
  287. package/dist/v2/features/operation/Operation.test.d.ts +0 -2
  288. package/dist/v2/features/operation/Operation.test.d.ts.map +0 -1
  289. package/dist/v2/features/operation/components/Header.test.d.ts +0 -2
  290. package/dist/v2/features/operation/components/Header.test.d.ts.map +0 -1
  291. package/dist/v2/features/operation/components/Header.vue.d.ts.map +0 -1
  292. package/dist/v2/features/operation/components/Header.vue.js +0 -7
  293. package/dist/v2/features/operation/components/Header.vue2.js +0 -97
  294. package/dist/v2/features/settings/Settings.test.d.ts +0 -2
  295. package/dist/v2/features/settings/Settings.test.d.ts.map +0 -1
  296. package/dist/v2/hooks/use-document-watcher.test.d.ts +0 -2
  297. package/dist/v2/hooks/use-document-watcher.test.d.ts.map +0 -1
  298. package/dist/views/Components/CodeSnippet/CodeSnippet.test.d.ts +0 -2
  299. package/dist/views/Components/CodeSnippet/CodeSnippet.test.d.ts.map +0 -1
  300. package/dist/views/Components/CodeSnippet/helpers/convert-to-har-request.test.d.ts +0 -2
  301. package/dist/views/Components/CodeSnippet/helpers/convert-to-har-request.test.d.ts.map +0 -1
  302. package/dist/views/Components/CodeSnippet/helpers/get-har-request.test.d.ts +0 -2
  303. package/dist/views/Components/CodeSnippet/helpers/get-har-request.test.d.ts.map +0 -1
  304. package/dist/views/Components/CodeSnippet/helpers/get-snippet.test.d.ts +0 -2
  305. package/dist/views/Components/CodeSnippet/helpers/get-snippet.test.d.ts.map +0 -1
  306. package/dist/views/Request/RequestRoot.test.d.ts +0 -2
  307. package/dist/views/Request/RequestRoot.test.d.ts.map +0 -1
  308. package/dist/views/Request/RequestSection/RequestAuth/RequestAuth.test.d.ts +0 -2
  309. package/dist/views/Request/RequestSection/RequestAuth/RequestAuth.test.d.ts.map +0 -1
  310. package/dist/views/Request/RequestSection/RequestAuth/helpers/restore-auth-from-local-storage.test.d.ts +0 -2
  311. package/dist/views/Request/RequestSection/RequestAuth/helpers/restore-auth-from-local-storage.test.d.ts.map +0 -1
  312. package/dist/views/Request/RequestSection/RequestBody.test.d.ts +0 -2
  313. package/dist/views/Request/RequestSection/RequestBody.test.d.ts.map +0 -1
  314. package/dist/views/Request/RequestSection/RequestCodeExample.test.d.ts +0 -2
  315. package/dist/views/Request/RequestSection/RequestCodeExample.test.d.ts.map +0 -1
  316. package/dist/views/Request/RequestSection/RequestSection.test.d.ts +0 -2
  317. package/dist/views/Request/RequestSection/RequestSection.test.d.ts.map +0 -1
  318. package/dist/views/Request/RequestSection/helpers/filter-security-requirements.test.d.ts +0 -2
  319. package/dist/views/Request/RequestSection/helpers/filter-security-requirements.test.d.ts.map +0 -1
  320. package/dist/views/Request/RequestSection/helpers/getting-started.test.d.ts +0 -2
  321. package/dist/views/Request/RequestSection/helpers/getting-started.test.d.ts.map +0 -1
  322. package/dist/views/Request/RequestSection/helpers/update-scheme.test.d.ts +0 -2
  323. package/dist/views/Request/RequestSection/helpers/update-scheme.test.d.ts.map +0 -1
  324. package/dist/views/Request/RequestSubpageHeader.test.d.ts +0 -2
  325. package/dist/views/Request/RequestSubpageHeader.test.d.ts.map +0 -1
  326. package/dist/views/Request/ResponseSection/ResponseBodyVirtual.test.d.ts +0 -2
  327. package/dist/views/Request/ResponseSection/ResponseBodyVirtual.test.d.ts.map +0 -1
  328. package/dist/views/Request/ResponseSection/ResponseSection.test.d.ts +0 -2
  329. package/dist/views/Request/ResponseSection/ResponseSection.test.d.ts.map +0 -1
  330. package/dist/views/Request/consts/mediaTypes.test.d.ts +0 -2
  331. package/dist/views/Request/consts/mediaTypes.test.d.ts.map +0 -1
  332. package/dist/views/Request/libs/auth.test.d.ts +0 -2
  333. package/dist/views/Request/libs/auth.test.d.ts.map +0 -1
  334. package/dist/views/Request/libs/oauth2.test.d.ts +0 -2
  335. package/dist/views/Request/libs/oauth2.test.d.ts.map +0 -1
  336. package/dist/views/Request/libs/request.test.d.ts +0 -2
  337. package/dist/views/Request/libs/request.test.d.ts.map +0 -1
  338. package/dist/views/Request/libs/watch-mode.test.d.ts +0 -2
  339. package/dist/views/Request/libs/watch-mode.test.d.ts.map +0 -1
  340. package/dist/vitest.setup.d.ts +0 -34
  341. package/dist/vitest.setup.d.ts.map +0 -1
@@ -1,240 +1,289 @@
1
- import { defineComponent as E, ref as T, computed as b, useId as K, watch as N, resolveComponent as H, createBlock as V, openBlock as s, withCtx as S, withDirectives as m, createElementBlock as v, createVNode as i, unref as l, vShow as y, Fragment as I, renderList as P, createCommentVNode as R, resolveDynamicComponent as Q, createElementVNode as F, toDisplayString as L } from "vue";
2
- import { canMethodHaveBody as A, REGEX as C } from "@scalar/oas-utils/helpers";
3
- import { getResolvedRef as h } from "@scalar/workspace-store/helpers/get-resolved-ref";
4
- import $ from "../../../../components/SectionFilter.vue.js";
5
- import j from "../../../../components/ViewLayout/ViewLayoutSection.vue.js";
6
- import z from "./OperationBody.vue.js";
7
- import f from "./OperationParams.vue.js";
8
- import { groupBy as G } from "../helpers/group-by.js";
9
- import M from "../../scalar-auth-selector-block/components/AuthSelector.vue.js";
10
- const X = { class: "group pointer-events-none flex flex-1 items-center gap-1 lg:pr-24" }, J = ["for"], W = ["id", "placeholder", "value"], Y = {
1
+ import { defineComponent as E, computed as f, ref as C, useId as S, watch as O, createBlock as V, openBlock as i, withCtx as k, withDirectives as d, createElementBlock as B, createVNode as u, unref as v, vShow as y, Fragment as U, renderList as H, createCommentVNode as w, resolveDynamicComponent as I, createElementVNode as N, toDisplayString as P } from "vue";
2
+ import { ScalarErrorBoundary as Q } from "@scalar/components";
3
+ import { canMethodHaveBody as q, REGEX as R } from "@scalar/oas-utils/helpers";
4
+ import { getResolvedRef as g } from "@scalar/workspace-store/helpers/get-resolved-ref";
5
+ import F from "../../../../components/SectionFilter.vue.js";
6
+ import L from "../../../../components/ViewLayout/ViewLayoutSection.vue.js";
7
+ import M from "./OperationBody.vue.js";
8
+ import b from "./OperationParams.vue.js";
9
+ import { groupBy as $ } from "../helpers/group-by.js";
10
+ import j from "../../scalar-auth-selector-block/components/AuthSelector.vue.js";
11
+ const z = { class: "group pointer-events-none flex flex-1 items-center gap-1 lg:pr-24" }, G = ["for"], X = ["id", "placeholder", "value"], J = {
11
12
  key: 2,
12
13
  class: "text-c-1 flex h-8 items-center"
13
- }, le = /* @__PURE__ */ E({
14
+ }, re = /* @__PURE__ */ E({
14
15
  __name: "OperationBlock",
15
16
  props: {
16
17
  method: {},
17
18
  path: {},
18
19
  operation: {},
20
+ authMeta: { default: () => ({ type: "document" }) },
19
21
  exampleKey: {},
20
- selectedContentType: {},
21
22
  securitySchemes: {},
22
23
  selectedSecurity: {},
23
24
  security: {},
24
25
  server: {},
25
26
  layout: {},
26
27
  plugins: {},
28
+ eventBus: {},
27
29
  environment: {},
28
30
  envVariables: {}
29
31
  },
30
- emits: ["operation:update:requestName", "auth:delete", "auth:update:securityScheme", "auth:update:selectedScopes", "auth:update:selectedSecurity", "parameters:add", "parameters:update", "parameters:delete", "parameters:deleteAll", "requestBody:update:contentType", "requestBody:update:value", "requestBody:add:formRow", "requestBody:update:formRow"],
31
- setup(o, { emit: g }) {
32
- const a = g, d = G(
33
- o.operation.parameters?.map((r) => h(r)) ?? [],
34
- "in"
35
- ), w = [
32
+ setup(l) {
33
+ const o = f(() => ({
34
+ method: l.method,
35
+ path: l.path,
36
+ exampleKey: l.exampleKey
37
+ })), m = f(
38
+ () => $(l.operation.parameters?.map((e) => g(e)) ?? [], "in")
39
+ ), T = [
36
40
  "Auth",
37
41
  "Variables",
38
42
  "Cookies",
39
43
  "Headers",
40
44
  "Query",
41
45
  "Body"
42
- ], u = T("All"), B = b(() => {
43
- const r = /* @__PURE__ */ new Set(["All", ...w]);
44
- return d.path?.length || r.delete("Variables"), A(o.method) || r.delete("Body"), q.value && r.delete("Auth"), [...r];
45
- }), n = b(
46
+ ], s = C("All"), A = f(() => {
47
+ const e = /* @__PURE__ */ new Set(["All", ...T]);
48
+ return m.value.path?.length || e.delete("Variables"), q(l.method) || e.delete("Body"), K.value && e.delete("Auth"), [...e];
49
+ }), n = f(
46
50
  () => Object.fromEntries(
47
- B.value.map((r) => [r, K()])
51
+ A.value.map((e) => [e, S()])
48
52
  )
49
53
  );
50
- N(
51
- () => o.method,
52
- (r) => {
53
- u.value === "Body" && !A(r) && (u.value = "All");
54
+ O(
55
+ () => l.method,
56
+ (e) => {
57
+ s.value === "Body" && !q(e) && (s.value = "All");
54
58
  }
55
59
  );
56
- const q = b(
57
- () => o.layout === "modal" && !o.operation.security && !Object.keys(o.securitySchemes ?? {}).length
58
- ), D = () => o.operation.summary ? o.operation.summary : o.path.replace(C.PROTOCOL, "") ? o.path.replace(C.PROTOCOL, "") : "Request Name", p = (r) => u.value === "All" || u.value === r, k = K();
59
- return (r, e) => {
60
- const O = H("ScalarErrorBoundary");
61
- return s(), V(j, {
62
- "aria-label": `Request: ${r.operation.summary}`
63
- }, {
64
- title: S(() => [
65
- F("div", X, [
66
- r.layout !== "modal" ? (s(), v("label", {
67
- key: 0,
68
- class: "pointer-events-auto absolute top-0 left-0 h-full w-full cursor-text opacity-0",
69
- for: l(k)
70
- }, null, 8, J)) : R("", !0),
71
- r.layout !== "modal" ? (s(), v("input", {
72
- key: 1,
73
- id: l(k),
74
- class: "text-c-1 group-hover-input pointer-events-auto relative z-10 -ml-0.5 h-8 w-full rounded pl-1.25 has-[:focus-visible]:outline md:-ml-1.25",
75
- placeholder: D(),
76
- value: r.operation.summary,
77
- onInput: e[0] || (e[0] = (t) => a("operation:update:requestName", {
78
- name: t.target.value
79
- }))
80
- }, null, 40, W)) : (s(), v("span", Y, L(r.operation.summary), 1))
81
- ]),
82
- i($, {
83
- modelValue: u.value,
84
- "onUpdate:modelValue": e[1] || (e[1] = (t) => u.value = t),
85
- filterIds: n.value,
86
- filters: B.value
87
- }, null, 8, ["modelValue", "filterIds", "filters"])
88
- ]),
89
- default: S(() => [
90
- m(i(l(M), {
91
- id: n.value.Auth,
92
- envVariables: r.envVariables,
93
- environment: r.environment,
94
- layout: "client",
95
- security: r.security,
96
- securitySchemes: r.securitySchemes,
97
- selectedSecurity: r.selectedSecurity,
98
- server: r.server,
99
- title: "Authorization",
100
- onDeleteOperationAuth: e[2] || (e[2] = (t) => a("auth:delete", t)),
101
- "onUpdate:securityScheme": e[3] || (e[3] = (t) => a("auth:update:securityScheme", t)),
102
- "onUpdate:selectedScopes": e[4] || (e[4] = (t) => a("auth:update:selectedScopes", t)),
103
- "onUpdate:selectedSecurity": e[5] || (e[5] = (t) => a("auth:update:selectedSecurity", t))
104
- }, null, 8, ["id", "envVariables", "environment", "security", "securitySchemes", "selectedSecurity", "server"]), [
105
- [y, p("Auth") && !q.value]
106
- ]),
107
- m(i(f, {
108
- id: n.value.Variables,
109
- envVariables: r.envVariables,
110
- environment: r.environment,
111
- exampleKey: r.exampleKey,
112
- parameters: l(d).path ?? [],
113
- title: "Variables",
114
- onAdd: e[6] || (e[6] = (t) => a("parameters:add", {
115
- type: "path",
116
- payload: t
117
- })),
118
- onDelete: e[7] || (e[7] = (t) => a("parameters:delete", {
119
- type: "path",
120
- ...t
121
- })),
122
- onDeleteAll: e[8] || (e[8] = () => a("parameters:deleteAll", {
123
- type: "path"
124
- })),
125
- onUpdate: e[9] || (e[9] = (t) => a("parameters:update", {
126
- type: "path",
127
- ...t
128
- }))
129
- }, null, 8, ["id", "envVariables", "environment", "exampleKey", "parameters"]), [
130
- [y, p("Variables") && l(d).path?.length]
131
- ]),
132
- m(i(f, {
133
- id: n.value.Cookies,
134
- envVariables: r.envVariables,
135
- environment: r.environment,
136
- exampleKey: r.exampleKey,
137
- parameters: l(d).cookie ?? [],
138
- title: "Cookies",
139
- onAdd: e[10] || (e[10] = (t) => a("parameters:add", {
140
- type: "cookie",
141
- payload: t
142
- })),
143
- onDelete: e[11] || (e[11] = (t) => a("parameters:delete", {
144
- type: "cookie",
145
- ...t
146
- })),
147
- onDeleteAll: e[12] || (e[12] = () => a("parameters:deleteAll", {
148
- type: "cookie"
149
- })),
150
- onUpdate: e[13] || (e[13] = (t) => a("parameters:update", {
151
- type: "cookie",
152
- ...t
153
- }))
154
- }, null, 8, ["id", "envVariables", "environment", "exampleKey", "parameters"]), [
155
- [y, p("Cookies")]
156
- ]),
157
- m(i(f, {
158
- id: n.value.Headers,
159
- envVariables: r.envVariables,
160
- environment: r.environment,
161
- exampleKey: r.exampleKey,
162
- parameters: l(d).header ?? [],
163
- title: "Headers",
164
- onAdd: e[14] || (e[14] = (t) => a("parameters:add", {
165
- type: "header",
166
- payload: t
167
- })),
168
- onDelete: e[15] || (e[15] = (t) => a("parameters:delete", {
169
- type: "header",
170
- ...t
171
- })),
172
- onDeleteAll: e[16] || (e[16] = () => a("parameters:deleteAll", {
173
- type: "header"
174
- })),
175
- onUpdate: e[17] || (e[17] = (t) => a("parameters:update", {
176
- type: "header",
177
- ...t
178
- }))
179
- }, null, 8, ["id", "envVariables", "environment", "exampleKey", "parameters"]), [
180
- [y, p("Headers")]
181
- ]),
182
- m(i(f, {
183
- id: n.value.Query,
184
- envVariables: r.envVariables,
185
- environment: r.environment,
186
- exampleKey: r.exampleKey,
187
- parameters: l(d).query ?? [],
188
- title: "Query Parameters",
189
- onAdd: e[18] || (e[18] = (t) => a("parameters:add", {
190
- type: "query",
191
- payload: t
192
- })),
193
- onDelete: e[19] || (e[19] = (t) => a("parameters:delete", {
194
- type: "query",
195
- ...t
196
- })),
197
- onDeleteAll: e[20] || (e[20] = () => a("parameters:deleteAll", {
198
- type: "query"
199
- })),
200
- onUpdate: e[21] || (e[21] = (t) => a("parameters:update", {
201
- type: "query",
202
- ...t
60
+ const K = f(
61
+ () => l.layout === "modal" && !l.operation.security && !Object.keys(l.securitySchemes ?? {}).length
62
+ ), D = () => l.operation.summary ? l.operation.summary : l.path.replace(R.PROTOCOL, "") ? l.path.replace(R.PROTOCOL, "") : "Request Name", p = (e) => s.value === "All" || s.value === e, h = S();
63
+ return (e, a) => (i(), V(L, {
64
+ "aria-label": `Request: ${e.operation.summary}`
65
+ }, {
66
+ title: k(() => [
67
+ N("div", z, [
68
+ e.layout !== "modal" ? (i(), B("label", {
69
+ key: 0,
70
+ class: "pointer-events-auto absolute top-0 left-0 h-full w-full cursor-text opacity-0",
71
+ for: v(h)
72
+ }, null, 8, G)) : w("", !0),
73
+ e.layout !== "modal" ? (i(), B("input", {
74
+ key: 1,
75
+ id: v(h),
76
+ class: "text-c-1 group-hover-input pointer-events-auto relative z-10 -ml-0.5 h-8 w-full rounded pl-1.25 has-[:focus-visible]:outline md:-ml-1.25",
77
+ placeholder: D(),
78
+ value: e.operation.summary,
79
+ onInput: a[0] || (a[0] = (t) => e.eventBus.emit("operation:update:summary", {
80
+ meta: o.value,
81
+ payload: {
82
+ summary: t.target.value
83
+ }
203
84
  }))
204
- }, null, 8, ["id", "envVariables", "environment", "exampleKey", "parameters"]), [
205
- [y, p("Query")]
206
- ]),
207
- m(i(z, {
208
- id: n.value.Body,
209
- envVariables: r.envVariables,
210
- environment: r.environment,
211
- exampleKey: r.exampleKey,
212
- requestBody: l(h)(r.operation.requestBody),
213
- selectedContentType: r.selectedContentType ?? "other",
214
- title: "Request Body",
215
- "onAdd:formRow": e[22] || (e[22] = (t) => a("requestBody:add:formRow", t)),
216
- "onUpdate:contentType": e[23] || (e[23] = (t) => a("requestBody:update:contentType", t)),
217
- "onUpdate:formRow": e[24] || (e[24] = (t) => a("requestBody:update:formRow", t)),
218
- "onUpdate:value": e[25] || (e[25] = (t) => a("requestBody:update:value", t))
219
- }, null, 8, ["id", "envVariables", "environment", "exampleKey", "requestBody", "selectedContentType"]), [
220
- [y, p("Body") && l(A)(r.method)]
221
- ]),
222
- (s(!0), v(I, null, P(r.plugins, (t, U) => (s(), V(O, { key: U }, {
223
- default: S(() => [
224
- t?.components?.request ? (s(), V(Q(t.components.request), {
225
- key: 0,
226
- operation: r.operation,
227
- selectedExample: r.exampleKey
228
- }, null, 8, ["operation", "selectedExample"])) : R("", !0)
229
- ]),
230
- _: 2
231
- }, 1024))), 128))
85
+ }, null, 40, X)) : (i(), B("span", J, P(e.operation.summary), 1))
86
+ ]),
87
+ u(F, {
88
+ modelValue: s.value,
89
+ "onUpdate:modelValue": a[1] || (a[1] = (t) => s.value = t),
90
+ filterIds: n.value,
91
+ filters: A.value
92
+ }, null, 8, ["modelValue", "filterIds", "filters"])
93
+ ]),
94
+ default: k(() => [
95
+ d(u(v(j), {
96
+ id: n.value.Auth,
97
+ envVariables: e.envVariables,
98
+ environment: e.environment,
99
+ layout: "client",
100
+ security: e.security,
101
+ securitySchemes: e.securitySchemes,
102
+ selectedSecurity: e.selectedSecurity,
103
+ server: e.server,
104
+ title: "Authorization",
105
+ meta: e.authMeta,
106
+ eventBus: e.eventBus
107
+ }, null, 8, ["id", "envVariables", "environment", "security", "securitySchemes", "selectedSecurity", "server", "meta", "eventBus"]), [
108
+ [y, p("Auth") && !K.value]
109
+ ]),
110
+ d(u(b, {
111
+ id: n.value.Variables,
112
+ envVariables: e.envVariables,
113
+ environment: e.environment,
114
+ exampleKey: e.exampleKey,
115
+ parameters: m.value.path ?? [],
116
+ title: "Variables",
117
+ "show-add-row-placeholder": !1,
118
+ onDelete: a[2] || (a[2] = ({ index: t }) => e.eventBus.emit("operation:delete:parameter", {
119
+ type: "path",
120
+ index: t,
121
+ meta: o.value
122
+ })),
123
+ onDeleteAll: a[3] || (a[3] = () => e.eventBus.emit("operation:delete-all:parameters", {
124
+ type: "path",
125
+ meta: o.value
126
+ })),
127
+ onUpdate: a[4] || (a[4] = ({ index: t, payload: r }) => e.eventBus.emit("operation:update:parameter", {
128
+ type: "path",
129
+ index: t,
130
+ payload: r,
131
+ meta: o.value
132
+ }))
133
+ }, null, 8, ["id", "envVariables", "environment", "exampleKey", "parameters"]), [
134
+ [y, p("Variables") && m.value.path?.length]
135
+ ]),
136
+ d(u(b, {
137
+ id: n.value.Cookies,
138
+ envVariables: e.envVariables,
139
+ environment: e.environment,
140
+ exampleKey: e.exampleKey,
141
+ parameters: m.value.cookie ?? [],
142
+ title: "Cookies",
143
+ "show-add-row-placeholder": !0,
144
+ onAdd: a[5] || (a[5] = ({ key: t, value: r }) => e.eventBus.emit("operation:add:parameter", {
145
+ type: "cookie",
146
+ payload: { key: t ?? "", value: r ?? "", isEnabled: !0 },
147
+ meta: o.value
148
+ })),
149
+ onDelete: a[6] || (a[6] = ({ index: t }) => e.eventBus.emit("operation:delete:parameter", {
150
+ type: "cookie",
151
+ index: t,
152
+ meta: o.value
153
+ })),
154
+ onDeleteAll: a[7] || (a[7] = () => e.eventBus.emit("operation:delete-all:parameters", {
155
+ type: "cookie",
156
+ meta: o.value
157
+ })),
158
+ onUpdate: a[8] || (a[8] = ({ index: t, payload: r }) => e.eventBus.emit("operation:update:parameter", {
159
+ type: "cookie",
160
+ index: t,
161
+ payload: r,
162
+ meta: o.value
163
+ }))
164
+ }, null, 8, ["id", "envVariables", "environment", "exampleKey", "parameters"]), [
165
+ [y, p("Cookies")]
232
166
  ]),
233
- _: 1
234
- }, 8, ["aria-label"]);
235
- };
167
+ d(u(b, {
168
+ id: n.value.Headers,
169
+ envVariables: e.envVariables,
170
+ environment: e.environment,
171
+ exampleKey: e.exampleKey,
172
+ parameters: m.value.header ?? [],
173
+ title: "Headers",
174
+ onAdd: a[9] || (a[9] = ({ key: t, value: r }) => e.eventBus.emit("operation:add:parameter", {
175
+ type: "header",
176
+ payload: { key: t ?? "", value: r ?? "", isEnabled: !0 },
177
+ meta: o.value
178
+ })),
179
+ onDelete: a[10] || (a[10] = ({ index: t }) => e.eventBus.emit("operation:delete:parameter", {
180
+ type: "header",
181
+ index: t,
182
+ meta: o.value
183
+ })),
184
+ onDeleteAll: a[11] || (a[11] = () => e.eventBus.emit("operation:delete-all:parameters", {
185
+ type: "header",
186
+ meta: o.value
187
+ })),
188
+ onUpdate: a[12] || (a[12] = ({ index: t, payload: r }) => e.eventBus.emit("operation:update:parameter", {
189
+ type: "header",
190
+ index: t,
191
+ payload: r,
192
+ meta: o.value
193
+ }))
194
+ }, null, 8, ["id", "envVariables", "environment", "exampleKey", "parameters"]), [
195
+ [y, p("Headers")]
196
+ ]),
197
+ d(u(b, {
198
+ id: n.value.Query,
199
+ envVariables: e.envVariables,
200
+ environment: e.environment,
201
+ exampleKey: e.exampleKey,
202
+ parameters: m.value.query ?? [],
203
+ title: "Query Parameters",
204
+ onAdd: a[13] || (a[13] = ({ key: t, value: r }) => e.eventBus.emit("operation:add:parameter", {
205
+ type: "query",
206
+ payload: { key: t ?? "", value: r ?? "", isEnabled: !0 },
207
+ meta: o.value
208
+ })),
209
+ onDelete: a[14] || (a[14] = ({ index: t }) => e.eventBus.emit("operation:delete:parameter", {
210
+ type: "query",
211
+ index: t,
212
+ meta: o.value
213
+ })),
214
+ onDeleteAll: a[15] || (a[15] = () => e.eventBus.emit("operation:delete-all:parameters", {
215
+ type: "query",
216
+ meta: o.value
217
+ })),
218
+ onUpdate: a[16] || (a[16] = ({ index: t, payload: r }) => e.eventBus.emit("operation:update:parameter", {
219
+ type: "query",
220
+ index: t,
221
+ payload: r,
222
+ meta: o.value
223
+ }))
224
+ }, null, 8, ["id", "envVariables", "environment", "exampleKey", "parameters"]), [
225
+ [y, p("Query")]
226
+ ]),
227
+ d(u(M, {
228
+ id: n.value.Body,
229
+ envVariables: e.envVariables,
230
+ environment: e.environment,
231
+ exampleKey: e.exampleKey,
232
+ requestBody: v(g)(e.operation.requestBody),
233
+ title: "Request Body",
234
+ "onAdd:formRow": a[17] || (a[17] = (t) => e.eventBus.emit("operation:add:requestBody:formRow", {
235
+ contentType: t.contentType,
236
+ meta: o.value,
237
+ payload: {
238
+ key: t.data.key,
239
+ value: t.data.value
240
+ }
241
+ })),
242
+ "onUpdate:contentType": a[18] || (a[18] = (t) => e.eventBus.emit("operation:update:requestBody:contentType", {
243
+ payload: {
244
+ contentType: t.value
245
+ },
246
+ meta: o.value
247
+ })),
248
+ "onUpdate:formRow": a[19] || (a[19] = (t) => e.eventBus.emit("operation:update:requestBody:formRow", {
249
+ contentType: t.contentType,
250
+ meta: o.value,
251
+ index: t.index,
252
+ payload: {
253
+ key: t.data.key,
254
+ value: t.data.value
255
+ }
256
+ })),
257
+ "onDelete:fromRow": a[20] || (a[20] = (t) => e.eventBus.emit("operation:delete:requestBody:formRow", {
258
+ contentType: t.contentType,
259
+ index: t.index,
260
+ meta: o.value
261
+ })),
262
+ "onUpdate:value": a[21] || (a[21] = (t) => e.eventBus.emit("operation:update:requestBody:value", {
263
+ contentType: t.contentType,
264
+ payload: {
265
+ value: t.value
266
+ },
267
+ meta: o.value
268
+ }))
269
+ }, null, 8, ["id", "envVariables", "environment", "exampleKey", "requestBody"]), [
270
+ [y, p("Body") && v(q)(e.method)]
271
+ ]),
272
+ (i(!0), B(U, null, H(e.plugins, (t, r) => (i(), V(v(Q), { key: r }, {
273
+ default: k(() => [
274
+ t?.components?.request ? (i(), V(I(t.components.request), {
275
+ key: 0,
276
+ operation: e.operation,
277
+ selectedExample: e.exampleKey
278
+ }, null, 8, ["operation", "selectedExample"])) : w("", !0)
279
+ ]),
280
+ _: 2
281
+ }, 1024))), 128))
282
+ ]),
283
+ _: 1
284
+ }, 8, ["aria-label"]));
236
285
  }
237
286
  });
238
287
  export {
239
- le as default
288
+ re as default
240
289
  };
@@ -4,8 +4,6 @@ import type { EnvVariable } from '../../../../store/active-entities.js';
4
4
  type __VLS_Props = {
5
5
  /** Request body */
6
6
  requestBody?: RequestBodyObject;
7
- /** Currently selected content type for the current operation */
8
- selectedContentType: keyof typeof contentTypes | (string & {});
9
7
  /** Currently selected example key for the current operation */
10
8
  exampleKey: string;
11
9
  /** Display title */
@@ -14,34 +12,32 @@ type __VLS_Props = {
14
12
  environment: Environment;
15
13
  envVariables: EnvVariable[];
16
14
  };
17
- declare const contentTypes: {
18
- readonly 'multipart/form-data': "Multipart Form";
19
- readonly 'application/x-www-form-urlencoded': "Form URL Encoded";
20
- readonly 'application/octet-stream': "Binary File";
21
- readonly 'application/json': "JSON";
22
- readonly 'application/xml': "XML";
23
- readonly 'application/yaml': "YAML";
24
- readonly 'application/edn': "EDN";
25
- readonly other: "Other";
26
- readonly none: "None";
27
- };
28
15
  declare const _default: import("vue").DefineComponent<__VLS_Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {} & {
29
16
  "update:contentType": (payload: {
30
17
  value: string;
31
18
  }) => any;
32
19
  "update:value": (payload: {
33
20
  value?: string | File;
21
+ contentType: string;
22
+ }) => any;
23
+ "add:formRow": (payload: {
24
+ data: Partial<{
25
+ key: string;
26
+ value?: string | File;
27
+ }>;
28
+ contentType: string;
34
29
  }) => any;
35
- "add:formRow": (payload: Partial<{
36
- key: string;
37
- value?: string | File;
38
- }>) => any;
39
30
  "update:formRow": (payload: {
40
31
  index: number;
41
- payload: Partial<{
32
+ data: Partial<{
42
33
  key: string;
43
- value?: string | File;
34
+ value: string | File | null;
44
35
  }>;
36
+ contentType: string;
37
+ }) => any;
38
+ "delete:fromRow": (payload: {
39
+ index: number;
40
+ contentType: string;
45
41
  }) => any;
46
42
  }, string, import("vue").PublicProps, Readonly<__VLS_Props> & Readonly<{
47
43
  "onUpdate:contentType"?: ((payload: {
@@ -49,17 +45,26 @@ declare const _default: import("vue").DefineComponent<__VLS_Props, {}, {}, {}, {
49
45
  }) => any) | undefined;
50
46
  "onUpdate:value"?: ((payload: {
51
47
  value?: string | File;
48
+ contentType: string;
49
+ }) => any) | undefined;
50
+ "onAdd:formRow"?: ((payload: {
51
+ data: Partial<{
52
+ key: string;
53
+ value?: string | File;
54
+ }>;
55
+ contentType: string;
52
56
  }) => any) | undefined;
53
- "onAdd:formRow"?: ((payload: Partial<{
54
- key: string;
55
- value?: string | File;
56
- }>) => any) | undefined;
57
57
  "onUpdate:formRow"?: ((payload: {
58
58
  index: number;
59
- payload: Partial<{
59
+ data: Partial<{
60
60
  key: string;
61
- value?: string | File;
61
+ value: string | File | null;
62
62
  }>;
63
+ contentType: string;
64
+ }) => any) | undefined;
65
+ "onDelete:fromRow"?: ((payload: {
66
+ index: number;
67
+ contentType: string;
63
68
  }) => any) | undefined;
64
69
  }>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
65
70
  export default _default;
@@ -1 +1 @@
1
- {"version":3,"file":"OperationBody.vue.d.ts","sourceRoot":"","sources":["../../../../../src/v2/blocks/scalar-operation-block/components/OperationBody.vue"],"names":[],"mappings":"AA6PA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,wCAAwC,CAAA;AACzE,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,8DAA8D,CAAA;AAUrG,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,yBAAyB,CAAA;AAK1D,KAAK,WAAW,GAAG;IACjB,mBAAmB;IACnB,WAAW,CAAC,EAAE,iBAAiB,CAAA;IAC/B,gEAAgE;IAChE,mBAAmB,EAAE,MAAM,OAAO,YAAY,GAAG,CAAC,MAAM,GAAG,EAAE,CAAC,CAAA;IAC9D,+DAA+D;IAC/D,UAAU,EAAE,MAAM,CAAA;IAClB,oBAAoB;IACpB,KAAK,EAAE,MAAM,CAAA;IAEb,4CAA4C;IAC5C,WAAW,EAAE,WAAW,CAAA;IACxB,YAAY,EAAE,WAAW,EAAE,CAAA;CAC5B,CAAC;AAoCF,QAAA,MAAM,YAAY;;;;;;;;;;CAUR,CAAA;;;eAnCoC,MAAM;;;gBAEX,MAAM,GAAG,IAAI;;;aAI1B,MAAM;gBAAU,MAAM,GAAG,IAAI;;;eAK5C,MAAM;iBACJ,OAAO,CAAC;YAAE,GAAG,EAAE,MAAM,CAAC;YAAC,KAAK,CAAC,EAAE,MAAM,GAAG,IAAI,CAAA;SAAE,CAAC;;;;eAZhB,MAAM;;;gBAEX,MAAM,GAAG,IAAI;;;aAI1B,MAAM;gBAAU,MAAM,GAAG,IAAI;;;eAK5C,MAAM;iBACJ,OAAO,CAAC;YAAE,GAAG,EAAE,MAAM,CAAC;YAAC,KAAK,CAAC,EAAE,MAAM,GAAG,IAAI,CAAA;SAAE,CAAC;;;AA+c9D,wBAOG"}
1
+ {"version":3,"file":"OperationBody.vue.d.ts","sourceRoot":"","sources":["../../../../../src/v2/blocks/scalar-operation-block/components/OperationBody.vue"],"names":[],"mappings":"AA2VA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,wCAAwC,CAAA;AAEzE,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,8DAA8D,CAAA;AAUrG,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,yBAAyB,CAAA;AAK1D,KAAK,WAAW,GAAG;IACf,mBAAmB;IACnB,WAAW,CAAC,EAAE,iBAAiB,CAAA;IAC/B,+DAA+D;IAC/D,UAAU,EAAE,MAAM,CAAA;IAClB,oBAAoB;IACpB,KAAK,EAAE,MAAM,CAAA;IAEb,4CAA4C;IAC5C,WAAW,EAAE,WAAW,CAAA;IACxB,YAAY,EAAE,WAAW,EAAE,CAAA;CAC5B,CAAC;;;eAK0C,MAAM;;;gBAI7B,MAAM,GAAG,IAAI;qBAAe,MAAM;;;cAM7C,OAAO,CAAC;YAAE,GAAG,EAAE,MAAM,CAAC;YAAC,KAAK,CAAC,EAAE,MAAM,GAAG,IAAI,CAAA;SAAE,CAAC;qBACxC,MAAM;;;eAMZ,MAAM;cACP,OAAO,CAAC;YAAE,GAAG,EAAE,MAAM,CAAC;YAAC,KAAK,EAAE,MAAM,GAAG,IAAI,GAAG,IAAI,CAAA;SAAE,CAAC;qBAC9C,MAAM;;;eAGiB,MAAM;qBAAe,MAAM;;;;eAtBvB,MAAM;;;gBAI7B,MAAM,GAAG,IAAI;qBAAe,MAAM;;;cAM7C,OAAO,CAAC;YAAE,GAAG,EAAE,MAAM,CAAC;YAAC,KAAK,CAAC,EAAE,MAAM,GAAG,IAAI,CAAA;SAAE,CAAC;qBACxC,MAAM;;;eAMZ,MAAM;cACP,OAAO,CAAC;YAAE,GAAG,EAAE,MAAM,CAAC;YAAC,KAAK,EAAE,MAAM,GAAG,IAAI,GAAG,IAAI,CAAA;SAAE,CAAC;qBAC9C,MAAM;;;eAGiB,MAAM;qBAAe,MAAM;;;AA0jBrE,wBAOG"}
@@ -1,7 +1,7 @@
1
1
  import o from "./OperationBody.vue2.js";
2
2
  /* empty css */
3
3
  import t from "../../../../_virtual/_plugin-vue_export-helper.js";
4
- const p = /* @__PURE__ */ t(o, [["__scopeId", "data-v-ff76e2a1"]]);
4
+ const f = /* @__PURE__ */ t(o, [["__scopeId", "data-v-caf58516"]]);
5
5
  export {
6
- p as default
6
+ f as default
7
7
  };