@scalar/api-client 2.18.0 → 2.18.3
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.
- package/CHANGELOG.md +85 -0
- package/dist/components/AddressBar/AddressBar.vue2.js +52 -52
- package/dist/components/AddressBar/AddressBarHistory.vue2.js +15 -15
- package/dist/components/AddressBar/httpStatusCodeColors.d.ts +0 -33
- package/dist/components/AddressBar/httpStatusCodeColors.d.ts.map +1 -1
- package/dist/components/AddressBar/httpStatusCodeColors.js +0 -1
- package/dist/components/CodeInput/CodeInput.vue2.js +112 -112
- package/dist/components/CommandPalette/CommandActionForm.vue.js +18 -18
- package/dist/components/CommandPalette/CommandPaletteImportCurl.vue2.js +25 -25
- package/dist/components/CommandPalette/TheCommandPalette.vue.d.ts +2 -2
- package/dist/components/CommandPalette/TheCommandPalette.vue.d.ts.map +1 -1
- package/dist/components/CommandPalette/TheCommandPalette.vue.js +2 -4
- package/dist/components/CommandPalette/TheCommandPalette.vue2.js +0 -1
- package/dist/components/CommandPalette/WatchModeToggle.vue.js +14 -14
- package/dist/components/DataTable/DataTable.vue.js +17 -17
- package/dist/components/DataTable/DataTableCell.vue.js +9 -9
- package/dist/components/DataTable/DataTableCheckbox.vue.js +17 -17
- package/dist/components/DataTable/DataTableInput.vue2.js +48 -48
- package/dist/components/DataTable/DataTableInputSelect.vue.js +35 -35
- package/dist/components/DataTable/DataTableText.vue.js +10 -10
- package/dist/components/Form/Form.vue.js +32 -32
- package/dist/components/Form/LabelInput.vue2.js +15 -15
- package/dist/components/HelpfulLink.vue.js +7 -7
- package/dist/components/HttpMethod/HttpMethod.vue2.js +22 -22
- package/dist/components/IconSelector.vue.js +16 -16
- package/dist/components/ImportCollection/ImportCollectionModal.vue.js +50 -50
- package/dist/components/ImportCollection/ImportNowButton.vue.js +23 -23
- package/dist/components/ImportCollection/PrefetchError.vue.js +8 -8
- package/dist/components/ImportCollection/hooks/useUrlPrefetcher.d.ts +0 -7
- package/dist/components/ImportCollection/hooks/useUrlPrefetcher.d.ts.map +1 -1
- package/dist/components/ScalarAsciiArt.vue2.js +16 -16
- package/dist/components/SectionFilter.vue2.js +21 -21
- package/dist/components/SectionFilterButton.vue.js +7 -7
- package/dist/components/Server/ServerDropdown.vue.js +32 -32
- package/dist/components/Server/ServerDropdownItem.vue2.js +39 -39
- package/dist/components/Server/ServerSelector.vue.js +27 -27
- package/dist/components/Server/ServerVariablesForm.vue.js +26 -26
- package/dist/components/Server/ServerVariablesSelect.vue.js +21 -21
- package/dist/components/Server/ServerVariablesTextbox.vue.js +10 -10
- package/dist/components/Server/types.d.ts +2 -1
- package/dist/components/Server/types.d.ts.map +1 -1
- package/dist/components/SideNav/SideNavLink.vue.js +18 -18
- package/dist/components/SideNav/SideNavRouterLink.vue.js +13 -13
- package/dist/components/Sidebar/Actions/DeleteSidebarListElement.vue.js +11 -11
- package/dist/components/Sidebar/Actions/SidebarListElementForm.vue.js +16 -16
- package/dist/components/Sidebar/Sidebar.vue2.js +28 -28
- package/dist/components/Sidebar/SidebarButton.vue.js +12 -12
- package/dist/components/Sidebar/SidebarListElement.vue2.js +34 -34
- package/dist/components/Sidebar/SidebarListElementActions.vue.js +33 -33
- package/dist/components/TopNav/TopNavItem.vue2.js +41 -41
- package/dist/components/ViewLayout/ViewLayoutCollapse.vue.js +43 -43
- package/dist/data/httpHeaders.d.ts +2 -1
- package/dist/data/httpHeaders.d.ts.map +1 -1
- package/dist/hooks/useClientConfig.js +1 -1
- package/dist/hooks/useLayout.js +1 -1
- package/dist/hooks/useSidebar.js +1 -1
- package/dist/layouts/App/create-api-client-app.d.ts.map +1 -1
- package/dist/layouts/Web/create-api-client-web.d.ts.map +1 -1
- package/dist/libs/create-client.d.ts.map +1 -1
- package/dist/plugins/hooks/usePluginManager.d.ts +1 -1
- package/dist/plugins/hooks/usePluginManager.d.ts.map +1 -1
- package/dist/plugins/hooks/usePluginManager.js +5 -5
- package/dist/plugins/index.d.ts +1 -1
- package/dist/plugins/index.d.ts.map +1 -1
- package/dist/plugins/index.js +5 -5
- package/dist/plugins/plugin-manager.d.ts +0 -2
- package/dist/plugins/plugin-manager.d.ts.map +1 -1
- package/dist/routes.d.ts +0 -10
- package/dist/routes.d.ts.map +1 -1
- package/dist/routes.js +0 -1
- package/dist/store/active-entities.js +1 -1
- package/dist/store/security-schemes.d.ts.map +1 -1
- package/dist/store/store.d.ts.map +1 -1
- package/dist/style.css +1 -1
- package/dist/v2/blocks/operation-block/OperationBlock.vue.d.ts.map +1 -1
- package/dist/v2/blocks/operation-block/OperationBlock.vue.js +44 -44
- package/dist/v2/blocks/operation-block/components/Header.vue2.js +20 -20
- package/dist/v2/blocks/operation-block/helpers/build-request-body.d.ts.map +1 -1
- package/dist/v2/blocks/operation-block/helpers/build-request-body.js +14 -14
- package/dist/v2/blocks/operation-block/helpers/get-delimiter.js +0 -2
- package/dist/v2/blocks/operation-code-sample/components/HttpMethod.vue.js +12 -12
- package/dist/v2/blocks/operation-code-sample/components/OperationCodeSample.vue2.js +65 -65
- package/dist/v2/blocks/operation-code-sample/helpers/generate-code-snippet.d.ts +2 -1
- package/dist/v2/blocks/operation-code-sample/helpers/generate-code-snippet.d.ts.map +1 -1
- package/dist/v2/blocks/operation-code-sample/helpers/get-example-from-schema.js +6 -6
- package/dist/v2/blocks/operation-code-sample/helpers/get-resolved-ref-deep.d.ts +4 -3
- package/dist/v2/blocks/operation-code-sample/helpers/get-resolved-ref-deep.d.ts.map +1 -1
- package/dist/v2/blocks/operation-code-sample/helpers/get-resolved-ref-deep.js +9 -7
- package/dist/v2/blocks/operation-code-sample/helpers/operation-to-har/process-body.d.ts.map +1 -1
- package/dist/v2/blocks/operation-code-sample/helpers/operation-to-har/process-body.js +40 -32
- package/dist/v2/blocks/operation-code-sample/helpers/operation-to-har/process-parameters.d.ts +1 -3
- package/dist/v2/blocks/operation-code-sample/helpers/operation-to-har/process-parameters.d.ts.map +1 -1
- package/dist/v2/blocks/operation-code-sample/helpers/operation-to-har/process-parameters.js +0 -1
- package/dist/v2/blocks/request-block/RequestBlock.vue.d.ts.map +1 -1
- package/dist/v2/blocks/request-block/RequestBlock.vue.js +2 -2
- package/dist/v2/blocks/request-block/RequestBlock.vue2.js +144 -149
- package/dist/v2/blocks/request-block/components/RequestBody.vue.d.ts +25 -45
- package/dist/v2/blocks/request-block/components/RequestBody.vue.d.ts.map +1 -1
- package/dist/v2/blocks/request-block/components/RequestBody.vue.js +2 -2
- package/dist/v2/blocks/request-block/components/RequestBody.vue2.js +90 -139
- package/dist/v2/blocks/request-block/components/RequestBodyForm.vue.d.ts +22 -0
- package/dist/v2/blocks/request-block/components/RequestBodyForm.vue.d.ts.map +1 -0
- package/dist/v2/blocks/request-block/components/RequestBodyForm.vue.js +77 -0
- package/dist/v2/blocks/request-block/components/RequestBodyForm.vue2.js +4 -0
- package/dist/v2/blocks/request-block/components/RequestParams.vue.d.ts +4 -4
- package/dist/v2/blocks/request-block/components/RequestParams.vue.d.ts.map +1 -1
- package/dist/v2/blocks/request-block/components/RequestParams.vue.js +34 -34
- package/dist/v2/blocks/request-block/components/RequestTable.vue.d.ts +6 -6
- package/dist/v2/blocks/request-block/components/RequestTable.vue.d.ts.map +1 -1
- package/dist/v2/blocks/request-block/components/RequestTable.vue.js +3 -3
- package/dist/v2/blocks/request-block/components/RequestTable.vue2.js +30 -32
- package/dist/v2/blocks/request-block/components/RequestTableRow.vue.d.ts +2 -2
- package/dist/v2/blocks/request-block/components/RequestTableRow.vue.d.ts.map +1 -1
- package/dist/v2/blocks/request-block/components/RequestTableRow.vue.js +64 -64
- package/dist/v2/blocks/request-block/components/RequestTableTooltip.vue2.js +29 -29
- package/dist/v2/blocks/request-block/helpers/create-parameter-handlers.d.ts +2 -2
- package/dist/v2/blocks/request-block/helpers/create-parameter-handlers.d.ts.map +1 -1
- package/dist/v2/blocks/request-block/helpers/create-parameter-handlers.js +12 -13
- package/dist/v2/blocks/request-block/helpers/get-form-body-rows.d.ts +8 -0
- package/dist/v2/blocks/request-block/helpers/get-form-body-rows.d.ts.map +1 -0
- package/dist/v2/blocks/request-block/helpers/get-form-body-rows.js +9 -0
- package/dist/v2/blocks/request-block/helpers/get-request-body-example.d.ts +3 -1
- package/dist/v2/blocks/request-block/helpers/get-request-body-example.d.ts.map +1 -1
- package/dist/v2/blocks/request-block/helpers/get-request-body-example.js +9 -8
- package/dist/v2/blocks/response-block/ResponseBlock.vue2.js +67 -67
- package/dist/v2/blocks/response-block/components/Headers.vue.js +35 -35
- package/dist/v2/blocks/response-block/components/ResponseBody.vue2.js +24 -24
- package/dist/v2/blocks/response-block/components/ResponseBodyDownload.vue.js +10 -10
- package/dist/v2/blocks/response-block/components/ResponseBodyPreview.vue2.js +24 -24
- package/dist/v2/blocks/response-block/components/ResponseBodyToggle.vue.js +10 -10
- package/dist/v2/blocks/response-block/components/ResponseCookies.vue.js +11 -11
- package/dist/v2/blocks/response-block/components/ResponseEmpty.vue2.js +14 -14
- package/dist/v2/blocks/response-block/components/ResponseLoadingOverlay.vue2.js +11 -11
- package/dist/v2/blocks/response-block/components/ResponseMetaInformation.vue.js +33 -33
- package/dist/v2/blocks/response-block/helpers/media-types.d.ts +3 -6
- package/dist/v2/blocks/response-block/helpers/media-types.d.ts.map +1 -1
- package/dist/v2/blocks/response-block/helpers/media-types.js +0 -1
- package/dist/v2/blocks/scalar-address-bar-block/components/AddressBar.vue2.js +72 -72
- package/dist/v2/blocks/scalar-address-bar-block/components/AddressBarHistory.vue2.js +9 -9
- package/dist/v2/blocks/scalar-address-bar-block/components/httpStatusCodeColors.d.ts +0 -33
- package/dist/v2/blocks/scalar-address-bar-block/components/httpStatusCodeColors.d.ts.map +1 -1
- package/dist/v2/blocks/scalar-address-bar-block/components/httpStatusCodeColors.js +0 -1
- package/dist/v2/blocks/scalar-auth-selector-block/components/AuthSelector.vue.d.ts.map +1 -1
- package/dist/v2/blocks/scalar-auth-selector-block/components/AuthSelector.vue.js +83 -82
- package/dist/v2/blocks/scalar-auth-selector-block/components/DeleteRequestAuthModal.vue.js +10 -10
- package/dist/v2/blocks/scalar-auth-selector-block/components/OAuth2.vue.js +121 -121
- package/dist/v2/blocks/scalar-auth-selector-block/components/OAuthScopesAddModal.vue2.js +13 -13
- package/dist/v2/blocks/scalar-auth-selector-block/components/OAuthScopesInput.vue.js +33 -33
- package/dist/v2/blocks/scalar-auth-selector-block/components/RequestAuthDataTable.vue.d.ts.map +1 -1
- package/dist/v2/blocks/scalar-auth-selector-block/components/RequestAuthDataTable.vue.js +26 -26
- package/dist/v2/blocks/scalar-auth-selector-block/components/RequestAuthDataTableInput.vue.js +26 -26
- package/dist/v2/blocks/scalar-auth-selector-block/components/RequestAuthTab.vue.d.ts +2 -2
- package/dist/v2/blocks/scalar-auth-selector-block/components/RequestAuthTab.vue.d.ts.map +1 -1
- package/dist/v2/blocks/scalar-auth-selector-block/components/RequestAuthTab.vue.js +130 -122
- package/dist/v2/blocks/scalar-auth-selector-block/helpers/oauth.d.ts +0 -21
- package/dist/v2/blocks/scalar-auth-selector-block/helpers/oauth.d.ts.map +1 -1
- package/dist/v2/blocks/scalar-auth-selector-block/helpers/oauth.js +1 -3
- package/dist/v2/components/code-input/CodeInput.vue2.js +93 -93
- package/dist/v2/components/data-table/DataTable.vue.js +17 -17
- package/dist/v2/components/data-table/DataTableCell.vue.js +9 -9
- package/dist/v2/components/data-table/DataTableCheckbox.vue.js +17 -17
- package/dist/v2/components/data-table/DataTableInput.vue2.js +48 -48
- package/dist/v2/components/data-table/DataTableInputSelect.vue.js +35 -35
- package/dist/v2/components/data-table/DataTableText.vue.js +10 -10
- package/dist/v2/components/forms/ConfirmationForm.vue.js +13 -13
- package/dist/v2/components/layout/CollapsibleSection.vue.js +42 -42
- package/dist/v2/components/modals/DeleteModal.vue.js +13 -13
- package/dist/v2/components/resize/Resize.vue2.js +11 -11
- package/dist/v2/components/server/ServerDropdown.vue.js +30 -30
- package/dist/v2/components/server/ServerDropdownItem.vue2.js +27 -27
- package/dist/v2/components/sidebar/Sidebar.vue.js +32 -32
- package/dist/v2/components/sidebar/SidebarMenu.vue.js +20 -20
- package/dist/v2/features/app/App.vue.js +25 -25
- package/dist/v2/features/app/app-events.d.ts.map +1 -1
- package/dist/v2/features/app/app-events.js +55 -61
- package/dist/v2/features/app/components/AppSidebar.vue2.js +97 -97
- package/dist/v2/features/app/components/CreateWorkspaceModal.vue.js +20 -20
- package/dist/v2/features/app/components/DesktopTab.vue2.js +59 -59
- package/dist/v2/features/app/components/DesktopTabs.vue.js +22 -22
- package/dist/v2/features/app/components/SidebarItemMenu.vue.js +6 -6
- package/dist/v2/features/app/components/WebTopNav.vue.js +9 -9
- package/dist/v2/features/app/helpers/create-api-client-app.d.ts +2 -5
- package/dist/v2/features/app/helpers/create-api-client-app.d.ts.map +1 -1
- package/dist/v2/features/app/helpers/create-api-client-app.js +1 -2
- package/dist/v2/features/app/helpers/routes.d.ts +5 -1
- package/dist/v2/features/app/helpers/routes.d.ts.map +1 -1
- package/dist/v2/features/collection/DocumentCollection.vue.js +31 -31
- package/dist/v2/features/collection/WorkspaceCollection.vue.js +17 -17
- package/dist/v2/features/collection/components/Authentication.vue2.js +18 -18
- package/dist/v2/features/collection/components/Cookies.vue.js +10 -10
- package/dist/v2/features/collection/components/Environment.vue.js +10 -10
- package/dist/v2/features/collection/components/Form.vue.js +21 -21
- package/dist/v2/features/collection/components/Overview.vue2.js +25 -25
- package/dist/v2/features/collection/components/Servers.vue.js +37 -37
- package/dist/v2/features/collection/components/Settings.vue.js +22 -22
- package/dist/v2/features/collection/components/Tabs.vue.js +18 -18
- package/dist/v2/features/command-palette/components/CommandActionForm.vue.js +20 -20
- package/dist/v2/features/command-palette/components/CommandActionInput.vue.js +17 -17
- package/dist/v2/features/command-palette/components/TheCommandPalette.vue2.js +68 -68
- package/dist/v2/features/command-palette/components/WatchModeToggle.vue.js +11 -11
- package/dist/v2/features/command-palette/helpers/get-openapi-document-details.d.ts +2 -1
- package/dist/v2/features/command-palette/helpers/get-openapi-document-details.d.ts.map +1 -1
- package/dist/v2/features/command-palette/helpers/get-postman-document-details.d.ts +2 -1
- package/dist/v2/features/command-palette/helpers/get-postman-document-details.d.ts.map +1 -1
- package/dist/v2/features/command-palette/hooks/use-command-palette-state.d.ts +3 -3
- package/dist/v2/features/command-palette/hooks/use-command-palette-state.d.ts.map +1 -1
- package/dist/v2/features/command-palette/hooks/use-command-palette-state.js +0 -1
- package/dist/v2/features/command-palette/types.d.ts +11 -10
- package/dist/v2/features/command-palette/types.d.ts.map +1 -1
- package/dist/v2/features/environments/EnvironmentsList.vue.js +36 -36
- package/dist/v2/features/environments/components/Environment.vue.js +16 -16
- package/dist/v2/features/environments/components/EnvironmentColors.vue.js +37 -37
- package/dist/v2/features/environments/components/EnvironmentCreateModal.vue.js +19 -19
- package/dist/v2/features/environments/components/EnvironmentDeleteModal.vue.js +14 -14
- package/dist/v2/features/environments/components/EnvironmentVariablesDropdown.vue.js +24 -24
- package/dist/v2/features/environments/components/EnvironmentVariablesTable.vue2.js +58 -58
- package/dist/v2/features/global-cookies/components/CookiesTable.vue2.js +23 -23
- package/dist/v2/features/modal/Modal.vue.d.ts +1 -1
- package/dist/v2/features/modal/Modal.vue.d.ts.map +1 -1
- package/dist/v2/features/modal/Modal.vue.js +1 -1
- package/dist/v2/features/modal/Modal.vue2.js +57 -56
- package/dist/v2/features/modal/helpers/create-api-client-modal.d.ts +5 -4
- package/dist/v2/features/modal/helpers/create-api-client-modal.d.ts.map +1 -1
- package/dist/v2/features/modal/hooks/use-workspace-client-modal-events.d.ts.map +1 -1
- package/dist/v2/features/modal/hooks/use-workspace-client-modal-events.js +17 -21
- package/dist/v2/features/operation/Operation.vue.d.ts +5 -1
- package/dist/v2/features/operation/Operation.vue.d.ts.map +1 -1
- package/dist/v2/features/operation/Operation.vue.js +41 -39
- package/dist/v2/features/search/components/SearchButton.vue.js +40 -40
- package/dist/v2/features/search/components/SearchModal.vue2.js +43 -43
- package/dist/v2/features/search/components/SearchResult.vue.js +34 -34
- package/dist/v2/features/search/types.d.ts +5 -4
- package/dist/v2/features/search/types.d.ts.map +1 -1
- package/dist/v2/features/settings/CollectionSettings.vue.js +51 -51
- package/dist/v2/features/settings/DocumentSettings.vue.js +25 -25
- package/dist/v2/features/settings/components/Appearance.vue.js +27 -27
- package/dist/v2/helpers/handle-hotkeys.d.ts +1 -12
- package/dist/v2/helpers/handle-hotkeys.d.ts.map +1 -1
- package/dist/v2/helpers/handle-hotkeys.js +0 -2
- package/dist/v2/helpers/plugins.d.ts +2 -2
- package/dist/v2/helpers/plugins.d.ts.map +1 -1
- package/dist/views/Collection/CollectionNavigation.vue.js +13 -13
- package/dist/views/Collection/components/EnvironmentForm.vue2.js +114 -114
- package/dist/views/Collection/components/MarkdownInput.vue2.js +31 -31
- package/dist/views/Cookies/CookieModal.vue2.js +26 -26
- package/dist/views/Environment/EnvironmentColorModal.vue.js +10 -10
- package/dist/views/Environment/EnvironmentColors.vue.js +56 -56
- package/dist/views/Environment/EnvironmentModal.vue.js +26 -26
- package/dist/views/Environment/EnvironmentVariableDropdown.vue.js +24 -24
- package/dist/views/Request/Request.vue2.js +55 -55
- package/dist/views/Request/RequestSection/RequestAuth/DeleteRequestAuthModal.vue.js +17 -17
- package/dist/views/Request/RequestSection/RequestAuth/OAuth2.vue.js +102 -102
- package/dist/views/Request/RequestSection/RequestAuth/OAuthScopesInput.vue.js +27 -27
- package/dist/views/Request/RequestSection/RequestAuth/RequestAuth.vue.d.ts.map +1 -1
- package/dist/views/Request/RequestSection/RequestAuth/RequestAuth.vue2.js +91 -91
- package/dist/views/Request/RequestSection/RequestAuth/RequestAuthDataTable.vue.d.ts.map +1 -1
- package/dist/views/Request/RequestSection/RequestAuth/RequestAuthDataTable.vue2.js +36 -36
- package/dist/views/Request/RequestSection/RequestAuth/RequestAuthTab.vue.js +101 -101
- package/dist/views/Request/RequestSection/RequestBody.vue2.js +154 -154
- package/dist/views/Request/RequestSection/RequestCodeExample.vue2.js +35 -35
- package/dist/views/Request/RequestSection/RequestParams.vue.js +81 -81
- package/dist/views/Request/RequestSection/RequestPathParams.vue.js +47 -47
- package/dist/views/Request/RequestSection/RequestSection.vue2.js +90 -90
- package/dist/views/Request/RequestSection/RequestTable.vue2.js +111 -111
- package/dist/views/Request/RequestSection/RequestTableTooltip.vue2.js +29 -29
- package/dist/views/Request/RequestSection/index.d.ts +1 -1
- package/dist/views/Request/RequestSection/index.d.ts.map +1 -1
- package/dist/views/Request/RequestSection/index.js +4 -4
- package/dist/views/Request/RequestSidebarItem.vue2.js +149 -149
- package/dist/views/Request/RequestSidebarItemMenu.vue2.js +79 -79
- package/dist/views/Request/RequestSubpageHeader.vue2.js +30 -30
- package/dist/views/Request/ResponseSection/RequestHeaders.vue.js +29 -29
- package/dist/views/Request/ResponseSection/ResponseBody.vue2.js +37 -37
- package/dist/views/Request/ResponseSection/ResponseBodyDownload.vue.js +10 -10
- package/dist/views/Request/ResponseSection/ResponseBodyPreview.vue2.js +24 -24
- package/dist/views/Request/ResponseSection/ResponseBodyToggle.vue.js +10 -10
- package/dist/views/Request/ResponseSection/ResponseCookies.vue.js +16 -16
- package/dist/views/Request/ResponseSection/ResponseEmpty.vue2.js +21 -21
- package/dist/views/Request/ResponseSection/ResponseHeaders.vue.js +30 -30
- package/dist/views/Request/ResponseSection/ResponseMetaInformation.vue.js +37 -37
- package/dist/views/Request/ResponseSection/ResponseSection.vue2.js +61 -61
- package/package.json +24 -24
- package/dist/components/ImportCollection/OpenAppButton.vue.d.ts +0 -6
- package/dist/components/ImportCollection/OpenAppButton.vue.d.ts.map +0 -1
- package/dist/components/ImportCollection/OperationBadge.vue.d.ts +0 -8
- package/dist/components/ImportCollection/OperationBadge.vue.d.ts.map +0 -1
- package/dist/components/ScreenReader.vue.d.ts +0 -20
- package/dist/components/ScreenReader.vue.d.ts.map +0 -1
- package/dist/components/SideNav/WorkspaceProfileIcon.vue.d.ts +0 -9
- package/dist/components/SideNav/WorkspaceProfileIcon.vue.d.ts.map +0 -1
- package/dist/views/Components/RequestBodies/RequestBodies.vue.d.ts +0 -3
- package/dist/views/Components/RequestBodies/RequestBodies.vue.d.ts.map +0 -1
- package/dist/views/Request/RequestSection/types/post-response.d.ts +0 -7
- package/dist/views/Request/RequestSection/types/post-response.d.ts.map +0 -1
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { defineComponent as l, computed as
|
|
1
|
+
import { defineComponent as l, computed as a, createElementBlock as i, openBlock as p, withModifiers as d, createVNode as f, createElementVNode as o, unref as m } from "vue";
|
|
2
2
|
import { ScalarIcon as c } from "@scalar/components";
|
|
3
3
|
import { getMediaTypeConfig as u } from "../consts/mediaTypes.js";
|
|
4
4
|
const x = ["download", "href"], h = /* @__PURE__ */ l({
|
|
@@ -8,15 +8,15 @@ const x = ["download", "href"], h = /* @__PURE__ */ l({
|
|
|
8
8
|
type: {},
|
|
9
9
|
filename: {}
|
|
10
10
|
},
|
|
11
|
-
setup(
|
|
12
|
-
const n =
|
|
13
|
-
const
|
|
14
|
-
return n.filename ? n.filename : `response${
|
|
11
|
+
setup(t) {
|
|
12
|
+
const n = t, r = a(() => {
|
|
13
|
+
const s = u(n.type ?? "")?.extension ?? ".unknown";
|
|
14
|
+
return n.filename ? n.filename : `response${s}`;
|
|
15
15
|
});
|
|
16
|
-
return (
|
|
16
|
+
return (s, e) => (p(), i("a", {
|
|
17
17
|
class: "text-c-3 text-xxs hover:bg-b-3 flex items-center gap-1 rounded px-1.5 py-0.5 no-underline",
|
|
18
18
|
download: `${r.value}`,
|
|
19
|
-
href:
|
|
19
|
+
href: t.href,
|
|
20
20
|
onClick: e[0] || (e[0] = d(() => {
|
|
21
21
|
}, ["stop"]))
|
|
22
22
|
}, [
|
|
@@ -24,9 +24,9 @@ const x = ["download", "href"], h = /* @__PURE__ */ l({
|
|
|
24
24
|
icon: "Download",
|
|
25
25
|
size: "xs"
|
|
26
26
|
}),
|
|
27
|
-
e[1] || (e[1] =
|
|
28
|
-
|
|
29
|
-
|
|
27
|
+
e[1] || (e[1] = o("span", null, [
|
|
28
|
+
o("span", null, "Download"),
|
|
29
|
+
o("span", { class: "sr-only" }, "Response Body")
|
|
30
30
|
], -1))
|
|
31
31
|
], 8, x));
|
|
32
32
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import
|
|
3
|
-
const
|
|
1
|
+
import { defineComponent as u, ref as d, watch as i, createElementBlock as r, createBlock as c, openBlock as l, normalizeClass as n, createElementVNode as s, withCtx as y, createTextVNode as f } from "vue";
|
|
2
|
+
import m from "./ResponseBodyInfo.vue.js";
|
|
3
|
+
const v = ["src"], k = ["src", "type"], w = ["src", "type"], x = ["data", "type"], $ = /* @__PURE__ */ u({
|
|
4
4
|
__name: "ResponseBodyPreview",
|
|
5
5
|
props: {
|
|
6
6
|
src: {},
|
|
@@ -8,51 +8,51 @@ const c = ["src"], k = ["src", "type"], w = ["src", "type"], B = ["data", "type"
|
|
|
8
8
|
mode: {},
|
|
9
9
|
alpha: { type: Boolean, default: !1 }
|
|
10
10
|
},
|
|
11
|
-
setup(
|
|
12
|
-
const
|
|
11
|
+
setup(e) {
|
|
12
|
+
const o = d(!1);
|
|
13
13
|
return i(
|
|
14
|
-
() =>
|
|
15
|
-
() =>
|
|
16
|
-
), (
|
|
14
|
+
() => e.src,
|
|
15
|
+
() => o.value = !1
|
|
16
|
+
), (B, t) => !o.value && e.src ? (l(), r("div", {
|
|
17
17
|
key: 0,
|
|
18
|
-
class:
|
|
18
|
+
class: n(["flex justify-center overflow-auto rounded-b", { "bg-preview p-2": e.alpha }])
|
|
19
19
|
}, [
|
|
20
|
-
e.mode === "image" ? (
|
|
20
|
+
e.mode === "image" ? (l(), r("img", {
|
|
21
21
|
key: 0,
|
|
22
|
-
class:
|
|
22
|
+
class: n(["h-full max-w-full", { rounded: e.alpha }]),
|
|
23
23
|
src: e.src,
|
|
24
|
-
onError:
|
|
25
|
-
}, null, 42,
|
|
24
|
+
onError: t[0] || (t[0] = (a) => o.value = !0)
|
|
25
|
+
}, null, 42, v)) : e.mode === "video" ? (l(), r("video", {
|
|
26
26
|
key: 1,
|
|
27
27
|
autoplay: "",
|
|
28
28
|
controls: "",
|
|
29
29
|
width: "100%",
|
|
30
|
-
onError:
|
|
30
|
+
onError: t[1] || (t[1] = (a) => o.value = !0)
|
|
31
31
|
}, [
|
|
32
|
-
|
|
32
|
+
s("source", {
|
|
33
33
|
src: e.src,
|
|
34
34
|
type: e.type
|
|
35
35
|
}, null, 8, k)
|
|
36
|
-
], 32)) : e.mode === "audio" ? (
|
|
36
|
+
], 32)) : e.mode === "audio" ? (l(), r("audio", {
|
|
37
37
|
key: 2,
|
|
38
38
|
class: "my-12",
|
|
39
39
|
controls: "",
|
|
40
|
-
onError:
|
|
40
|
+
onError: t[2] || (t[2] = (a) => o.value = !0)
|
|
41
41
|
}, [
|
|
42
|
-
|
|
42
|
+
s("source", {
|
|
43
43
|
src: e.src,
|
|
44
44
|
type: e.type
|
|
45
45
|
}, null, 8, w)
|
|
46
|
-
], 32)) : (
|
|
46
|
+
], 32)) : (l(), r("object", {
|
|
47
47
|
key: 3,
|
|
48
48
|
class: "aspect-[4/3] w-full",
|
|
49
49
|
data: e.src,
|
|
50
50
|
type: e.type,
|
|
51
|
-
onError:
|
|
52
|
-
}, null, 40,
|
|
53
|
-
], 2)) : (
|
|
54
|
-
default:
|
|
55
|
-
|
|
51
|
+
onError: t[3] || (t[3] = (a) => o.value = !0)
|
|
52
|
+
}, null, 40, x))
|
|
53
|
+
], 2)) : (l(), c(m, { key: 1 }, {
|
|
54
|
+
default: y(() => [...t[4] || (t[4] = [
|
|
55
|
+
f("Preview unavailable", -1)
|
|
56
56
|
])]),
|
|
57
57
|
_: 1
|
|
58
58
|
}));
|
|
@@ -1,21 +1,21 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
const
|
|
1
|
+
import { defineComponent as d, createElementBlock as a, openBlock as r, createElementVNode as l, withModifiers as n, normalizeClass as u } from "vue";
|
|
2
|
+
const m = { class: "text-c-3 text-xxs -my-1 flex justify-center gap-0.5 rounded p-0.5" }, i = /* @__PURE__ */ d({
|
|
3
3
|
__name: "ResponseBodyToggle",
|
|
4
4
|
props: {
|
|
5
5
|
modelValue: { type: Boolean }
|
|
6
6
|
},
|
|
7
7
|
emits: ["update:modelValue"],
|
|
8
|
-
setup(
|
|
9
|
-
return (
|
|
10
|
-
|
|
11
|
-
class:
|
|
8
|
+
setup(t) {
|
|
9
|
+
return (o, e) => (r(), a("div", m, [
|
|
10
|
+
l("button", {
|
|
11
|
+
class: u(["hover:bg-b-3 rounded px-1", { "bg-b-3 text-c-1 cursor-default": t.modelValue }]),
|
|
12
12
|
type: "button",
|
|
13
|
-
onClick:
|
|
13
|
+
onClick: e[0] || (e[0] = n((s) => o.$emit("update:modelValue", !0), ["stop"]))
|
|
14
14
|
}, " Preview ", 2),
|
|
15
|
-
|
|
16
|
-
class:
|
|
15
|
+
l("button", {
|
|
16
|
+
class: u(["hover:bg-b-3 rounded px-1", { "bg-b-3 text-c-1 cursor-default": !t.modelValue }]),
|
|
17
17
|
type: "button",
|
|
18
|
-
onClick:
|
|
18
|
+
onClick: e[1] || (e[1] = n((s) => o.$emit("update:modelValue", !1), ["stop"]))
|
|
19
19
|
}, " Raw ", 2)
|
|
20
20
|
]));
|
|
21
21
|
}
|
|
@@ -1,37 +1,37 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import
|
|
3
|
-
import
|
|
4
|
-
import
|
|
5
|
-
import
|
|
6
|
-
const
|
|
1
|
+
import { defineComponent as m, createBlock as n, openBlock as e, withCtx as t, createElementBlock as r, Fragment as a, renderList as f, createVNode as c, createTextVNode as u } from "vue";
|
|
2
|
+
import x from "../../../components/DataTable/DataTable.vue.js";
|
|
3
|
+
import k from "../../../components/DataTable/DataTableRow.vue.js";
|
|
4
|
+
import i from "../../../components/DataTable/DataTableText.vue.js";
|
|
5
|
+
import p from "../../../components/ViewLayout/ViewLayoutCollapse.vue.js";
|
|
6
|
+
const _ = {
|
|
7
7
|
key: 1,
|
|
8
8
|
class: "text-c-3 bg-b-1 flex min-h-[65px] items-center justify-center border-t px-4 text-sm"
|
|
9
|
-
}, B = /* @__PURE__ */
|
|
9
|
+
}, B = /* @__PURE__ */ m({
|
|
10
10
|
__name: "ResponseCookies",
|
|
11
11
|
props: {
|
|
12
12
|
cookies: {}
|
|
13
13
|
},
|
|
14
|
-
setup(
|
|
15
|
-
return (
|
|
14
|
+
setup(s) {
|
|
15
|
+
return (d, l) => (e(), n(p, { defaultOpen: !1 }, {
|
|
16
16
|
title: t(() => [...l[0] || (l[0] = [
|
|
17
|
-
|
|
17
|
+
u("Cookies", -1)
|
|
18
18
|
])]),
|
|
19
19
|
default: t(() => [
|
|
20
|
-
(e(),
|
|
21
|
-
s.cookies.length ? (e(),
|
|
20
|
+
(e(), r(a, { key: 0 }, [
|
|
21
|
+
s.cookies.length ? (e(), n(x, {
|
|
22
22
|
key: 0,
|
|
23
23
|
class: "flex-1",
|
|
24
24
|
columns: ["", ""]
|
|
25
25
|
}, {
|
|
26
26
|
default: t(() => [
|
|
27
|
-
(e(!0),
|
|
27
|
+
(e(!0), r(a, null, f(s.cookies, (o) => (e(), n(k, {
|
|
28
28
|
key: o.name
|
|
29
29
|
}, {
|
|
30
30
|
default: t(() => [
|
|
31
|
-
i
|
|
31
|
+
c(i, {
|
|
32
32
|
text: o.name
|
|
33
33
|
}, null, 8, ["text"]),
|
|
34
|
-
i
|
|
34
|
+
c(i, {
|
|
35
35
|
text: o.value
|
|
36
36
|
}, null, 8, ["text"])
|
|
37
37
|
]),
|
|
@@ -39,7 +39,7 @@ const d = {
|
|
|
39
39
|
}, 1024))), 128))
|
|
40
40
|
]),
|
|
41
41
|
_: 1
|
|
42
|
-
})) : (e(),
|
|
42
|
+
})) : (e(), r("div", _, " No cookies "))
|
|
43
43
|
], 64))
|
|
44
44
|
]),
|
|
45
45
|
_: 1
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { defineComponent as w, onMounted as q, onBeforeUnmount as R, createElementBlock as
|
|
2
|
-
import { ScalarHotkey as
|
|
1
|
+
import { defineComponent as w, onMounted as q, onBeforeUnmount as R, createElementBlock as n, openBlock as l, createElementVNode as s, createCommentVNode as m, normalizeClass as y, unref as t, createVNode as i, createTextVNode as c, toDisplayString as h, nextTick as S } from "vue";
|
|
2
|
+
import { ScalarHotkey as d } from "@scalar/components";
|
|
3
3
|
import { useRoute as C, useRouter as N } from "vue-router";
|
|
4
4
|
import B from "../../../assets/computer.ascii.js";
|
|
5
5
|
import V from "../../../components/EmptyState.vue.js";
|
|
@@ -17,13 +17,13 @@ const W = { class: "flex-center relative flex flex-1 flex-col gap-6 p-2 capitali
|
|
|
17
17
|
workspace: {},
|
|
18
18
|
numWorkspaceRequests: {}
|
|
19
19
|
},
|
|
20
|
-
setup(
|
|
21
|
-
const { events: a, requestMutators: x } = K(), g = C(), b = N(), { layout:
|
|
22
|
-
const
|
|
20
|
+
setup(o) {
|
|
21
|
+
const { events: a, requestMutators: x } = K(), g = C(), b = N(), { layout: r } = A(), p = () => {
|
|
22
|
+
const u = o.operation.tags?.length ? { tags: o.operation.tags[0] ? [o.operation.tags[0]] : [] } : {}, e = x.add(u, o.collection.uid);
|
|
23
23
|
e && (b.push({
|
|
24
24
|
name: "request",
|
|
25
25
|
params: {
|
|
26
|
-
workspace:
|
|
26
|
+
workspace: o.workspace.uid,
|
|
27
27
|
request: e.uid
|
|
28
28
|
}
|
|
29
29
|
}), S(() => {
|
|
@@ -31,16 +31,16 @@ const W = { class: "flex-center relative flex flex-1 flex-col gap-6 p-2 capitali
|
|
|
31
31
|
focusAddressBar: new KeyboardEvent("keydown", { key: "l" })
|
|
32
32
|
});
|
|
33
33
|
}));
|
|
34
|
-
}, f = (
|
|
35
|
-
|
|
36
|
-
}, v = "2.18.
|
|
37
|
-
return q(() => a.hotKeys.on(f)), R(() => a.hotKeys.off(f)), (
|
|
34
|
+
}, f = (u) => {
|
|
35
|
+
u?.createNew && g.name === "request" && p();
|
|
36
|
+
}, v = "2.18.3";
|
|
37
|
+
return q(() => a.hotKeys.on(f)), R(() => a.hotKeys.off(f)), (u, e) => (l(), n("div", W, [
|
|
38
38
|
s("div", {
|
|
39
39
|
class: y(["flex h-[calc(100%_-_50px)] flex-col items-center justify-center", {
|
|
40
|
-
"hidden opacity-0": o.numWorkspaceRequests <= 1 && t(
|
|
40
|
+
"hidden opacity-0": o.numWorkspaceRequests <= 1 && t(r) !== "modal"
|
|
41
41
|
}])
|
|
42
42
|
}, [
|
|
43
|
-
t(
|
|
43
|
+
t(r) !== "modal" ? (l(), n("div", $, [
|
|
44
44
|
c(" Scalar App V" + h(t(v)) + " Beta ", 1),
|
|
45
45
|
e[3] || (e[3] = s("div", { class: "mt-2" }, [
|
|
46
46
|
s("a", {
|
|
@@ -54,37 +54,37 @@ const W = { class: "flex-center relative flex flex-1 flex-col gap-6 p-2 capitali
|
|
|
54
54
|
href: "https://www.scalar.com",
|
|
55
55
|
target: "_blank"
|
|
56
56
|
}, " Powered By Scalar.com ", -1)),
|
|
57
|
-
|
|
57
|
+
i(E, {
|
|
58
58
|
art: t(B),
|
|
59
59
|
class: "text-c-3"
|
|
60
60
|
}, null, 8, ["art"])
|
|
61
61
|
], 2),
|
|
62
|
-
t(
|
|
62
|
+
t(r) !== "modal" ? (l(), n("div", {
|
|
63
63
|
key: 0,
|
|
64
64
|
class: y(["hidden h-[calc(100%_-_50px)] items-center justify-center pb-5", {
|
|
65
65
|
"!flex opacity-100": o.numWorkspaceRequests == 1
|
|
66
66
|
}])
|
|
67
67
|
}, [
|
|
68
|
-
|
|
68
|
+
i(V)
|
|
69
69
|
], 2)) : m("", !0),
|
|
70
70
|
s("div", j, [
|
|
71
|
-
t(
|
|
71
|
+
t(r) !== "modal" ? (l(), n("button", {
|
|
72
72
|
key: 0,
|
|
73
73
|
class: "flex items-center gap-1.5",
|
|
74
74
|
type: "button",
|
|
75
75
|
onClick: e[0] || (e[0] = (k) => t(a).commandPalette.emit())
|
|
76
76
|
}, [
|
|
77
77
|
e[5] || (e[5] = c(" Get Started ", -1)),
|
|
78
|
-
|
|
78
|
+
i(t(d), { hotkey: "k" })
|
|
79
79
|
])) : m("", !0),
|
|
80
|
-
t(
|
|
80
|
+
t(r) === "desktop" ? (l(), n("button", {
|
|
81
81
|
key: 1,
|
|
82
82
|
class: "flex items-center gap-1.5",
|
|
83
83
|
type: "button",
|
|
84
|
-
onClick: e[1] || (e[1] = (k) =>
|
|
84
|
+
onClick: e[1] || (e[1] = (k) => p())
|
|
85
85
|
}, [
|
|
86
86
|
e[6] || (e[6] = c(" New Request ", -1)),
|
|
87
|
-
|
|
87
|
+
i(t(d), { hotkey: "N" })
|
|
88
88
|
])) : m("", !0),
|
|
89
89
|
s("button", {
|
|
90
90
|
class: "flex items-center gap-1.5",
|
|
@@ -92,7 +92,7 @@ const W = { class: "flex-center relative flex flex-1 flex-col gap-6 p-2 capitali
|
|
|
92
92
|
onClick: e[2] || (e[2] = (k) => t(a).executeRequest.emit())
|
|
93
93
|
}, [
|
|
94
94
|
e[7] || (e[7] = c(" Send Request ", -1)),
|
|
95
|
-
|
|
95
|
+
i(t(d), { hotkey: "↵" })
|
|
96
96
|
])
|
|
97
97
|
])
|
|
98
98
|
]));
|
|
@@ -1,51 +1,51 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import
|
|
1
|
+
import { defineComponent as y, createBlock as f, openBlock as r, withCtx as e, createElementBlock as s, createVNode as a, unref as u, createTextVNode as n, Fragment as i, renderList as b, toDisplayString as c } from "vue";
|
|
2
|
+
import g from "../../../components/DataTable/DataTable.vue.js";
|
|
3
3
|
import p from "../../../components/DataTable/DataTableRow.vue.js";
|
|
4
|
-
import
|
|
5
|
-
import
|
|
6
|
-
import
|
|
7
|
-
import { httpHeaders as
|
|
8
|
-
import
|
|
9
|
-
const
|
|
4
|
+
import _ from "../../../components/DataTable/DataTableText.vue.js";
|
|
5
|
+
import k from "../../../components/HelpfulLink.vue.js";
|
|
6
|
+
import w from "../../../components/ViewLayout/ViewLayoutCollapse.vue.js";
|
|
7
|
+
import { httpHeaders as h } from "../../../data/httpHeaders.js";
|
|
8
|
+
import x from "../../../components/DataTable/DataTableHeader.vue.js";
|
|
9
|
+
const H = {
|
|
10
10
|
key: 0,
|
|
11
11
|
class: "max-h-[calc(100%-32px)] overflow-y-auto"
|
|
12
|
-
},
|
|
12
|
+
}, C = {
|
|
13
13
|
key: 1,
|
|
14
14
|
class: "text-c-3 bg-b-1 flex min-h-12 items-center justify-center rounded border px-4 text-base"
|
|
15
|
-
}, D = /* @__PURE__ */
|
|
15
|
+
}, D = /* @__PURE__ */ y({
|
|
16
16
|
__name: "ResponseHeaders",
|
|
17
17
|
props: {
|
|
18
18
|
headers: {}
|
|
19
19
|
},
|
|
20
|
-
setup(
|
|
21
|
-
const m = (
|
|
22
|
-
(
|
|
20
|
+
setup(l) {
|
|
21
|
+
const m = (d) => h.find(
|
|
22
|
+
(t) => t.name.toLowerCase() === d.toLowerCase()
|
|
23
23
|
);
|
|
24
|
-
return (
|
|
24
|
+
return (d, t) => (r(), f(w, {
|
|
25
25
|
class: "overflow-auto",
|
|
26
26
|
defaultOpen: !1,
|
|
27
|
-
itemCount:
|
|
27
|
+
itemCount: l.headers.length
|
|
28
28
|
}, {
|
|
29
|
-
title: e(() => [...
|
|
29
|
+
title: e(() => [...t[0] || (t[0] = [
|
|
30
30
|
n("Response Headers", -1)
|
|
31
31
|
])]),
|
|
32
32
|
default: e(() => [
|
|
33
|
-
|
|
34
|
-
a(
|
|
33
|
+
l.headers.length ? (r(), s("div", H, [
|
|
34
|
+
a(g, {
|
|
35
35
|
columns: ["minmax(auto, min-content)", "minmax(50%, 1fr)"],
|
|
36
36
|
scroll: ""
|
|
37
37
|
}, {
|
|
38
38
|
default: e(() => [
|
|
39
39
|
a(p, { class: "sr-only !block" }, {
|
|
40
40
|
default: e(() => [
|
|
41
|
-
a(
|
|
42
|
-
default: e(() => [...
|
|
41
|
+
a(u(x), null, {
|
|
42
|
+
default: e(() => [...t[1] || (t[1] = [
|
|
43
43
|
n("Header Key", -1)
|
|
44
44
|
])]),
|
|
45
45
|
_: 1
|
|
46
46
|
}),
|
|
47
|
-
a(
|
|
48
|
-
default: e(() => [...
|
|
47
|
+
a(u(x), null, {
|
|
48
|
+
default: e(() => [...t[2] || (t[2] = [
|
|
49
49
|
n("Header Value", -1)
|
|
50
50
|
])]),
|
|
51
51
|
_: 1
|
|
@@ -53,29 +53,29 @@ const h = {
|
|
|
53
53
|
]),
|
|
54
54
|
_: 1
|
|
55
55
|
}),
|
|
56
|
-
(
|
|
56
|
+
(r(!0), s(i, null, b(l.headers, (o) => (r(), f(p, {
|
|
57
57
|
key: o.name,
|
|
58
58
|
class: "group/row text-c-1"
|
|
59
59
|
}, {
|
|
60
60
|
default: e(() => [
|
|
61
|
-
a(
|
|
61
|
+
a(_, { class: "bg-b-1 sticky left-0 z-1 max-w-full group-first/row:border-t-0" }, {
|
|
62
62
|
default: e(() => [
|
|
63
|
-
typeof m(o.name)?.url == "string" ? (
|
|
63
|
+
typeof m(o.name)?.url == "string" ? (r(), f(k, {
|
|
64
64
|
key: 0,
|
|
65
65
|
class: "decoration-c-3",
|
|
66
66
|
href: m(o.name).url
|
|
67
67
|
}, {
|
|
68
68
|
default: e(() => [
|
|
69
|
-
n(
|
|
69
|
+
n(c(o.name), 1)
|
|
70
70
|
]),
|
|
71
71
|
_: 2
|
|
72
|
-
}, 1032, ["href"])) : (
|
|
73
|
-
n(
|
|
72
|
+
}, 1032, ["href"])) : (r(), s(i, { key: 1 }, [
|
|
73
|
+
n(c(o.name), 1)
|
|
74
74
|
], 64))
|
|
75
75
|
]),
|
|
76
76
|
_: 2
|
|
77
77
|
}, 1024),
|
|
78
|
-
a(
|
|
78
|
+
a(_, {
|
|
79
79
|
class: "z-0 group-first/row:border-t-0",
|
|
80
80
|
text: o.value
|
|
81
81
|
}, null, 8, ["text"])
|
|
@@ -85,7 +85,7 @@ const h = {
|
|
|
85
85
|
]),
|
|
86
86
|
_: 1
|
|
87
87
|
})
|
|
88
|
-
])) : (
|
|
88
|
+
])) : (r(), s("div", C, " No Headers "))
|
|
89
89
|
]),
|
|
90
90
|
_: 1
|
|
91
91
|
}, 8, ["itemCount"]));
|
|
@@ -1,67 +1,67 @@
|
|
|
1
|
-
import { defineComponent as C, ref as
|
|
1
|
+
import { defineComponent as C, ref as m, computed as x, createElementBlock as a, openBlock as n, toDisplayString as o, unref as d, Fragment as f, createElementVNode as l, createCommentVNode as v, createTextVNode as i, createBlock as S, withCtx as I, normalizeStyle as y } from "vue";
|
|
2
2
|
import { httpStatusCodes as b } from "@scalar/oas-utils/helpers";
|
|
3
3
|
import w from "pretty-bytes";
|
|
4
|
-
import
|
|
4
|
+
import k from "pretty-ms";
|
|
5
5
|
import B from "../../../components/HelpfulLink.vue.js";
|
|
6
6
|
import { useWorkspace as N } from "../../../store/store.js";
|
|
7
|
-
const L = { class: "text-c-1 flex gap-1.5" }, V = { key: 0 },
|
|
7
|
+
const L = { class: "text-c-1 flex gap-1.5" }, V = { key: 0 }, z = { key: 0 }, D = { key: 1 }, W = /* @__PURE__ */ C({
|
|
8
8
|
__name: "ResponseMetaInformation",
|
|
9
9
|
props: {
|
|
10
10
|
response: {}
|
|
11
11
|
},
|
|
12
|
-
setup(
|
|
13
|
-
const h =
|
|
14
|
-
g.requestStatus.on((
|
|
15
|
-
|
|
12
|
+
setup(r) {
|
|
13
|
+
const h = r, { events: g } = N(), u = m(), c = m(0);
|
|
14
|
+
g.requestStatus.on((t) => {
|
|
15
|
+
t === "start" ? u.value = setInterval(() => c.value += 1e3, 1e3) : (clearInterval(u.value), u.value = void 0, c.value = 0);
|
|
16
16
|
});
|
|
17
|
-
const
|
|
18
|
-
const
|
|
19
|
-
|
|
17
|
+
const p = (t) => {
|
|
18
|
+
const e = Number.parseInt(
|
|
19
|
+
t.headers?.["Content-Length"] || t.headers?.["content-length"] || "0",
|
|
20
20
|
10
|
|
21
21
|
);
|
|
22
|
-
return
|
|
23
|
-
}, s =
|
|
24
|
-
const
|
|
25
|
-
if (
|
|
26
|
-
return b[
|
|
22
|
+
return e ? w(e) : void 0;
|
|
23
|
+
}, s = x(() => {
|
|
24
|
+
const t = h.response.status;
|
|
25
|
+
if (t)
|
|
26
|
+
return b[t] ?? void 0;
|
|
27
27
|
});
|
|
28
|
-
return (
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
28
|
+
return (t, e) => (n(), a("div", L, [
|
|
29
|
+
u.value && c.value ? (n(), a("span", V, o(d(k)(c.value)), 1)) : (n(), a(f, { key: 1 }, [
|
|
30
|
+
l("span", null, [
|
|
31
|
+
e[0] || (e[0] = l("span", { class: "sr-only" }, "Response Information, Duration:", -1)),
|
|
32
|
+
i(" " + o(d(k)(r.response.duration)), 1)
|
|
33
33
|
]),
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
])) :
|
|
38
|
-
s.value ? (
|
|
39
|
-
|
|
40
|
-
s.value.url ? (
|
|
34
|
+
p(r.response) ? (n(), a("span", z, [
|
|
35
|
+
e[1] || (e[1] = l("span", { class: "sr-only" }, ", Size:", -1)),
|
|
36
|
+
i(" " + o(p(r.response)), 1)
|
|
37
|
+
])) : v("", !0),
|
|
38
|
+
s.value ? (n(), a(f, { key: 1 }, [
|
|
39
|
+
e[2] || (e[2] = l("span", { class: "sr-only" }, ", Status:", -1)),
|
|
40
|
+
s.value.url ? (n(), S(B, {
|
|
41
41
|
key: 0,
|
|
42
42
|
class: "flex items-center gap-1.5",
|
|
43
43
|
href: s.value.url
|
|
44
44
|
}, {
|
|
45
|
-
default:
|
|
46
|
-
|
|
47
|
-
|
|
45
|
+
default: I(() => [
|
|
46
|
+
i(o(r.response.status) + " " + o(s.value.name) + " ", 1),
|
|
47
|
+
l("span", {
|
|
48
48
|
class: "block h-1.5 w-1.5 rounded-full",
|
|
49
|
-
style:
|
|
49
|
+
style: y({ backgroundColor: s.value.color })
|
|
50
50
|
}, null, 4)
|
|
51
51
|
]),
|
|
52
52
|
_: 1
|
|
53
|
-
}, 8, ["href"])) : (
|
|
54
|
-
|
|
55
|
-
|
|
53
|
+
}, 8, ["href"])) : (n(), a("span", D, [
|
|
54
|
+
i(o(r.response.status) + " " + o(s.value.name) + " ", 1),
|
|
55
|
+
l("span", {
|
|
56
56
|
class: "block h-1.5 w-1.5 rounded-full",
|
|
57
|
-
style:
|
|
57
|
+
style: y({ backgroundColor: s.value.color })
|
|
58
58
|
}, null, 4)
|
|
59
59
|
]))
|
|
60
|
-
], 64)) :
|
|
60
|
+
], 64)) : v("", !0)
|
|
61
61
|
], 64))
|
|
62
62
|
]));
|
|
63
63
|
}
|
|
64
64
|
});
|
|
65
65
|
export {
|
|
66
|
-
|
|
66
|
+
W as default
|
|
67
67
|
};
|