@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,6 +1,6 @@
|
|
|
1
|
-
import { defineComponent as k, computed as
|
|
2
|
-
import { ScalarButton as
|
|
3
|
-
import { ScalarIconPencil as
|
|
1
|
+
import { defineComponent as k, computed as x, ref as y, useTemplateRef as w, createElementBlock as i, openBlock as t, createElementVNode as o, createBlock as m, createCommentVNode as h, unref as n, withCtx as v, createVNode as r, Fragment as f, nextTick as B } from "vue";
|
|
2
|
+
import { ScalarButton as b, ScalarMarkdown as C } from "@scalar/components";
|
|
3
|
+
import { ScalarIconPencil as g } from "@scalar/icons";
|
|
4
4
|
import I from "../../../components/code-input/CodeInput.vue.js";
|
|
5
5
|
const S = { class: "flex flex-col gap-2" }, V = { class: "flex items-center justify-between gap-2 pl-1.5" }, z = { class: "has-[:focus-visible]:bg-b-1 group rounded-lg" }, N = {
|
|
6
6
|
key: 1,
|
|
@@ -22,25 +22,25 @@ const S = { class: "flex flex-col gap-2" }, V = { class: "flex items-center just
|
|
|
22
22
|
plugins: {},
|
|
23
23
|
collectionType: {}
|
|
24
24
|
},
|
|
25
|
-
setup(
|
|
26
|
-
const u =
|
|
27
|
-
() =>
|
|
28
|
-
), a =
|
|
29
|
-
a.value =
|
|
25
|
+
setup(d) {
|
|
26
|
+
const u = x(
|
|
27
|
+
() => d.document?.info?.description ?? ""
|
|
28
|
+
), a = y("preview"), p = w("codeInputRef"), l = async (c) => {
|
|
29
|
+
a.value = c, c === "edit" && (await B(), p.value?.focus());
|
|
30
30
|
};
|
|
31
|
-
return (
|
|
31
|
+
return (c, e) => (t(), i("div", S, [
|
|
32
32
|
o("div", V, [
|
|
33
33
|
e[6] || (e[6] = o("h3", { class: "font-bold" }, "Description", -1)),
|
|
34
|
-
a.value === "preview" ? (t(),
|
|
34
|
+
a.value === "preview" ? (t(), m(n(b), {
|
|
35
35
|
key: 0,
|
|
36
36
|
class: "text-c-2 hover:text-c-1 flex items-center gap-2",
|
|
37
37
|
size: "sm",
|
|
38
38
|
type: "button",
|
|
39
39
|
variant: "outlined",
|
|
40
|
-
onClick: e[0] || (e[0] = (
|
|
40
|
+
onClick: e[0] || (e[0] = (s) => l("edit"))
|
|
41
41
|
}, {
|
|
42
|
-
default:
|
|
43
|
-
|
|
42
|
+
default: v(() => [
|
|
43
|
+
r(n(g), {
|
|
44
44
|
size: "sm",
|
|
45
45
|
thickness: "1.5"
|
|
46
46
|
}),
|
|
@@ -50,24 +50,24 @@ const S = { class: "flex flex-col gap-2" }, V = { class: "flex items-center just
|
|
|
50
50
|
})) : h("", !0)
|
|
51
51
|
]),
|
|
52
52
|
o("div", z, [
|
|
53
|
-
a.value === "preview" ? (t(), i(
|
|
54
|
-
u.value.trim().length ? (t(), i(
|
|
55
|
-
|
|
53
|
+
a.value === "preview" ? (t(), i(f, { key: 0 }, [
|
|
54
|
+
u.value.trim().length ? (t(), i(f, { key: 0 }, [
|
|
55
|
+
r(n(C), {
|
|
56
56
|
class: "flex-1 rounded border border-transparent p-1.5 hover:border-(--scalar-background-3)",
|
|
57
57
|
value: u.value,
|
|
58
58
|
withImages: "",
|
|
59
|
-
onDblclick: e[1] || (e[1] = (
|
|
59
|
+
onDblclick: e[1] || (e[1] = (s) => l("edit"))
|
|
60
60
|
}, null, 8, ["value"]),
|
|
61
61
|
e[7] || (e[7] = o("div", { class: "brightness-lifted bg-b-1 absolute inset-0 -z-1 hidden rounded group-hover:block group-has-[:focus-visible]:hidden" }, null, -1))
|
|
62
62
|
], 64)) : (t(), i("div", N, [
|
|
63
|
-
|
|
63
|
+
r(n(b), {
|
|
64
64
|
class: "hover:bg-b-2 hover:text-c-1 text-c-2 flex items-center gap-2",
|
|
65
65
|
size: "sm",
|
|
66
66
|
variant: "ghost",
|
|
67
|
-
onClick: e[2] || (e[2] = (
|
|
67
|
+
onClick: e[2] || (e[2] = (s) => l("edit"))
|
|
68
68
|
}, {
|
|
69
|
-
default:
|
|
70
|
-
|
|
69
|
+
default: v(() => [
|
|
70
|
+
r(n(g), {
|
|
71
71
|
size: "sm",
|
|
72
72
|
thickness: "1.5"
|
|
73
73
|
}),
|
|
@@ -76,16 +76,16 @@ const S = { class: "flex flex-col gap-2" }, V = { class: "flex items-center just
|
|
|
76
76
|
_: 1
|
|
77
77
|
})
|
|
78
78
|
]))
|
|
79
|
-
], 64)) : (t(),
|
|
79
|
+
], 64)) : (t(), m(n(I), {
|
|
80
80
|
key: 1,
|
|
81
81
|
ref_key: "codeInputRef",
|
|
82
82
|
ref: p,
|
|
83
83
|
class: "border px-0.5 py-0",
|
|
84
84
|
environment: void 0,
|
|
85
|
-
layout:
|
|
85
|
+
layout: d.layout,
|
|
86
86
|
modelValue: u.value,
|
|
87
|
-
onBlur: e[3] || (e[3] = (
|
|
88
|
-
"onUpdate:modelValue": e[4] || (e[4] = (
|
|
87
|
+
onBlur: e[3] || (e[3] = (s) => l("preview")),
|
|
88
|
+
"onUpdate:modelValue": e[4] || (e[4] = (s) => d.eventBus.emit("document:update:info", { description: s }))
|
|
89
89
|
}, null, 8, ["layout", "modelValue"]))
|
|
90
90
|
])
|
|
91
91
|
]));
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { defineComponent as M, ref as A, computed as x, createElementBlock as u, openBlock as c, Fragment as S, createElementVNode as
|
|
1
|
+
import { defineComponent as M, ref as A, computed as x, createElementBlock as u, openBlock as c, Fragment as S, createElementVNode as s, createVNode as o, createTextVNode as g, renderList as I, createBlock as y, unref as r, toDisplayString as T, withCtx as f, createCommentVNode as V } from "vue";
|
|
2
2
|
import { useModal as P, ScalarMarkdown as z, ScalarButton as k, ScalarModal as L } from "@scalar/components";
|
|
3
3
|
import { debounce as O } from "@scalar/helpers/general/debounce";
|
|
4
4
|
import { ScalarIconTrash as R, ScalarIconPlus as j } from "@scalar/icons";
|
|
@@ -25,10 +25,10 @@ const Y = { class: "flex flex-col gap-4" }, q = { class: "flex flex-col gap-4" }
|
|
|
25
25
|
plugins: {},
|
|
26
26
|
collectionType: {}
|
|
27
27
|
},
|
|
28
|
-
setup(
|
|
28
|
+
setup(l) {
|
|
29
29
|
const v = P(), n = A(-1), _ = x(
|
|
30
|
-
() =>
|
|
31
|
-
), $ = x(() =>
|
|
30
|
+
() => l.document?.servers?.[n.value]
|
|
31
|
+
), $ = x(() => l.document?.servers ?? []), B = [
|
|
32
32
|
{
|
|
33
33
|
label: "URL",
|
|
34
34
|
key: "url",
|
|
@@ -44,91 +44,91 @@ const Y = { class: "flex flex-col gap-4" }, q = { class: "flex flex-col gap-4" }
|
|
|
44
44
|
}, p = () => {
|
|
45
45
|
v.hide(), n.value = -1;
|
|
46
46
|
}, N = () => {
|
|
47
|
-
n.value < 0 || (
|
|
48
|
-
}, { execute: h } = O({ delay: 328, maxWait: 1e3 }), U = (t, e,
|
|
47
|
+
n.value < 0 || (l.eventBus.emit("server:delete:server", { index: n.value }), p());
|
|
48
|
+
}, { execute: h } = O({ delay: 328, maxWait: 1e3 }), U = (t, e, a) => h(
|
|
49
49
|
`${t}-${e}`,
|
|
50
|
-
() =>
|
|
50
|
+
() => l.eventBus.emit("server:update:server", {
|
|
51
51
|
index: t,
|
|
52
|
-
server: { [e]:
|
|
52
|
+
server: { [e]: a }
|
|
53
53
|
})
|
|
54
|
-
), C = (t, e,
|
|
54
|
+
), C = (t, e, a) => h(
|
|
55
55
|
`${t}-${e}`,
|
|
56
|
-
() =>
|
|
56
|
+
() => l.eventBus.emit("server:update:variables", {
|
|
57
57
|
index: t,
|
|
58
58
|
key: e,
|
|
59
|
-
value:
|
|
59
|
+
value: a
|
|
60
60
|
})
|
|
61
|
-
), D = () =>
|
|
61
|
+
), D = () => l.eventBus.emit("server:add:server"), b = (t, e = 0) => t?.description || `Server ${e + 1}`;
|
|
62
62
|
return (t, e) => (c(), u(S, null, [
|
|
63
|
-
|
|
64
|
-
e[1] || (e[1] =
|
|
65
|
-
|
|
66
|
-
|
|
63
|
+
s("div", Y, [
|
|
64
|
+
e[1] || (e[1] = s("div", { class: "flex flex-col gap-2" }, [
|
|
65
|
+
s("h3", { class: "font-bold" }, "Servers"),
|
|
66
|
+
s("p", { class: "text-sm" }, [
|
|
67
67
|
g(" Add different base URLs for your API. You can use "),
|
|
68
|
-
|
|
68
|
+
s("code", { class: "font-code text-c-2" }, "{variables}"),
|
|
69
69
|
g(" for dynamic parts. ")
|
|
70
70
|
])
|
|
71
71
|
], -1)),
|
|
72
|
-
|
|
73
|
-
(c(!0), u(S, null, I($.value, (
|
|
72
|
+
s("div", q, [
|
|
73
|
+
(c(!0), u(S, null, I($.value, (a, d) => (c(), u("div", {
|
|
74
74
|
key: d,
|
|
75
75
|
class: "rounded-lg border"
|
|
76
76
|
}, [
|
|
77
|
-
|
|
78
|
-
|
|
77
|
+
s("div", G, [
|
|
78
|
+
a.description ? (c(), y(r(z), {
|
|
79
79
|
key: 0,
|
|
80
80
|
class: "self-center",
|
|
81
|
-
value:
|
|
82
|
-
}, null, 8, ["value"])) : (c(), u("span", H, T(b(
|
|
83
|
-
|
|
81
|
+
value: a.description
|
|
82
|
+
}, null, 8, ["value"])) : (c(), u("span", H, T(b(a, d)), 1)),
|
|
83
|
+
o(r(k), {
|
|
84
84
|
class: "hover:bg-b-3 hover:text-c-1 h-fit p-1.25",
|
|
85
85
|
"data-testid": "delete-server-button",
|
|
86
86
|
variant: "ghost",
|
|
87
87
|
onClick: (i) => w(d)
|
|
88
88
|
}, {
|
|
89
89
|
default: f(() => [
|
|
90
|
-
|
|
90
|
+
o(r(R), { class: "size-3.5" })
|
|
91
91
|
]),
|
|
92
92
|
_: 1
|
|
93
93
|
}, 8, ["onClick"])
|
|
94
94
|
]),
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
data:
|
|
98
|
-
environment:
|
|
95
|
+
s("div", J, [
|
|
96
|
+
o(F, {
|
|
97
|
+
data: a,
|
|
98
|
+
environment: l.environment,
|
|
99
99
|
onUpdate: (i, m) => U(d, i, m),
|
|
100
100
|
options: B
|
|
101
101
|
}, null, 8, ["data", "environment", "onUpdate"]),
|
|
102
|
-
|
|
102
|
+
a.variables ? (c(), y(r(W), {
|
|
103
103
|
key: 0,
|
|
104
|
-
variables:
|
|
104
|
+
variables: a.variables,
|
|
105
105
|
"onUpdate:variable": (i, m) => C(d, i, m)
|
|
106
106
|
}, null, 8, ["variables", "onUpdate:variable"])) : V("", !0)
|
|
107
107
|
])
|
|
108
108
|
]))), 128))
|
|
109
109
|
]),
|
|
110
|
-
|
|
111
|
-
|
|
110
|
+
s("div", K, [
|
|
111
|
+
o(r(k), {
|
|
112
112
|
class: "hover:bg-b-2 hover:text-c-1 flex items-center gap-2",
|
|
113
113
|
size: "sm",
|
|
114
114
|
variant: "ghost",
|
|
115
115
|
onClick: D
|
|
116
116
|
}, {
|
|
117
117
|
default: f(() => [
|
|
118
|
-
|
|
119
|
-
e[0] || (e[0] =
|
|
118
|
+
o(r(j)),
|
|
119
|
+
e[0] || (e[0] = s("span", null, "Add Server", -1))
|
|
120
120
|
]),
|
|
121
121
|
_: 1
|
|
122
122
|
})
|
|
123
123
|
])
|
|
124
124
|
]),
|
|
125
|
-
|
|
125
|
+
o(r(L), {
|
|
126
126
|
size: "xxs",
|
|
127
127
|
state: r(v),
|
|
128
128
|
title: `Delete ${b(_.value, n.value)}`
|
|
129
129
|
}, {
|
|
130
130
|
default: f(() => [
|
|
131
|
-
|
|
131
|
+
o(E, {
|
|
132
132
|
variableName: "Server",
|
|
133
133
|
warningMessage: "Are you sure you want to delete this server? This action cannot be undone.",
|
|
134
134
|
onClose: p,
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { defineComponent as
|
|
1
|
+
import { defineComponent as s, createBlock as o, openBlock as c, unref as a } from "vue";
|
|
2
2
|
import { useRouter as i } from "vue-router";
|
|
3
|
-
import
|
|
4
|
-
import
|
|
5
|
-
const
|
|
3
|
+
import h from "../../settings/DocumentSettings.vue.js";
|
|
4
|
+
import k from "../../settings/CollectionSettings.vue.js";
|
|
5
|
+
const y = /* @__PURE__ */ s({
|
|
6
6
|
__name: "Settings",
|
|
7
7
|
props: {
|
|
8
8
|
documentSlug: {},
|
|
@@ -19,32 +19,32 @@ const U = /* @__PURE__ */ u({
|
|
|
19
19
|
plugins: {},
|
|
20
20
|
collectionType: {}
|
|
21
21
|
},
|
|
22
|
-
setup(
|
|
23
|
-
const
|
|
24
|
-
|
|
25
|
-
},
|
|
26
|
-
|
|
27
|
-
}, m = (
|
|
28
|
-
|
|
29
|
-
}, d = (
|
|
30
|
-
|
|
31
|
-
}, l = i(),
|
|
32
|
-
|
|
22
|
+
setup(e) {
|
|
23
|
+
const n = (t) => {
|
|
24
|
+
e.eventBus.emit("document:update:watch-mode", t);
|
|
25
|
+
}, r = (t) => {
|
|
26
|
+
e.eventBus.emit("workspace:update:theme", t);
|
|
27
|
+
}, m = (t) => {
|
|
28
|
+
e.eventBus.emit("workspace:update:active-proxy", t);
|
|
29
|
+
}, d = (t) => {
|
|
30
|
+
e.eventBus.emit("workspace:update:color-mode", t);
|
|
31
|
+
}, l = i(), u = () => {
|
|
32
|
+
e.workspaceStore.deleteDocument(e.documentSlug), l.push({
|
|
33
33
|
name: "workspace.environment",
|
|
34
34
|
params: {
|
|
35
|
-
workspaceSlug:
|
|
35
|
+
workspaceSlug: e.activeWorkspace.id
|
|
36
36
|
}
|
|
37
37
|
});
|
|
38
38
|
};
|
|
39
|
-
return (
|
|
39
|
+
return (t, p) => e.collectionType === "document" ? (c(), o(a(h), {
|
|
40
40
|
key: 0,
|
|
41
41
|
documentUrl: e.document?.["x-scalar-original-source-url"],
|
|
42
42
|
isDraftDocument: e.documentSlug === "drafts",
|
|
43
43
|
title: e.document?.info.title ?? "",
|
|
44
44
|
watchMode: e.document?.["x-scalar-watch-mode"] ?? !0,
|
|
45
|
-
"onDelete:document":
|
|
46
|
-
"onUpdate:watchMode":
|
|
47
|
-
}, null, 8, ["documentUrl", "isDraftDocument", "title", "watchMode"])) : (
|
|
45
|
+
"onDelete:document": u,
|
|
46
|
+
"onUpdate:watchMode": n
|
|
47
|
+
}, null, 8, ["documentUrl", "isDraftDocument", "title", "watchMode"])) : (c(), o(a(k), {
|
|
48
48
|
key: 1,
|
|
49
49
|
activeProxyUrl: e.workspaceStore.workspace["x-scalar-active-proxy"],
|
|
50
50
|
activeThemeId: e.workspaceStore.workspace["x-scalar-theme"] ?? "default",
|
|
@@ -52,10 +52,10 @@ const U = /* @__PURE__ */ u({
|
|
|
52
52
|
customProxyUrl: e.workspaceStore.config["x-scalar-reference-config"].settings.proxyUrl,
|
|
53
53
|
"onUpdate:colorMode": d,
|
|
54
54
|
"onUpdate:proxyUrl": m,
|
|
55
|
-
"onUpdate:themeId":
|
|
55
|
+
"onUpdate:themeId": r
|
|
56
56
|
}, null, 8, ["activeProxyUrl", "activeThemeId", "colorMode", "customProxyUrl"]));
|
|
57
57
|
}
|
|
58
58
|
});
|
|
59
59
|
export {
|
|
60
|
-
|
|
60
|
+
y as default
|
|
61
61
|
};
|
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import { RouterLink as
|
|
3
|
-
const
|
|
1
|
+
import { defineComponent as a, computed as m, createElementBlock as n, openBlock as t, Fragment as p, renderList as u, createBlock as d, unref as f, withCtx as x, createElementVNode as r, normalizeClass as h, toDisplayString as k, capitalize as v } from "vue";
|
|
2
|
+
import { RouterLink as _ } from "vue-router";
|
|
3
|
+
const b = { class: "flex w-full gap-2 border-b pl-1.5 md:ml-1.5 md:pl-0" }, w = ["href", "onClick"], z = /* @__PURE__ */ a({
|
|
4
4
|
__name: "Tabs",
|
|
5
5
|
props: {
|
|
6
6
|
type: {}
|
|
7
7
|
},
|
|
8
|
-
setup(
|
|
9
|
-
const s =
|
|
10
|
-
() =>
|
|
8
|
+
setup(o) {
|
|
9
|
+
const s = m(
|
|
10
|
+
() => o.type === "workspace" ? ["environment", "cookies", "settings"] : [
|
|
11
11
|
"overview",
|
|
12
12
|
"servers",
|
|
13
13
|
"authentication",
|
|
@@ -16,25 +16,25 @@ const w = { class: "flex w-full gap-2 border-b pl-1.5 md:ml-1.5 md:pl-0" }, g =
|
|
|
16
16
|
"settings"
|
|
17
17
|
]
|
|
18
18
|
);
|
|
19
|
-
return (
|
|
20
|
-
(t(!0),
|
|
19
|
+
return (g, y) => (t(), n("div", b, [
|
|
20
|
+
(t(!0), n(p, null, u(s.value, (e) => (t(), d(f(_), {
|
|
21
21
|
key: e,
|
|
22
22
|
custom: "",
|
|
23
|
-
to: { name: `${
|
|
23
|
+
to: { name: `${o.type}.${e}` }
|
|
24
24
|
}, {
|
|
25
|
-
default: x(({ isActive:
|
|
26
|
-
|
|
25
|
+
default: x(({ isActive: c, href: i, navigate: l }) => [
|
|
26
|
+
r("a", {
|
|
27
27
|
class: "-ml-2 flex h-10 cursor-pointer items-center px-2 text-center text-sm font-medium whitespace-nowrap no-underline -outline-offset-1 has-[:focus-visible]:outline",
|
|
28
|
-
href:
|
|
29
|
-
onClick:
|
|
28
|
+
href: i,
|
|
29
|
+
onClick: l
|
|
30
30
|
}, [
|
|
31
|
-
|
|
32
|
-
class:
|
|
31
|
+
r("span", {
|
|
32
|
+
class: h([
|
|
33
33
|
"flex-center hover:text-c-1 h-full border-b",
|
|
34
|
-
|
|
34
|
+
c ? "text-c-1 border-c-1" : "text-c-2 hover:text-c-1 border-transparent"
|
|
35
35
|
])
|
|
36
|
-
}, v(
|
|
37
|
-
], 8,
|
|
36
|
+
}, k(v(e)), 3)
|
|
37
|
+
], 8, w)
|
|
38
38
|
]),
|
|
39
39
|
_: 2
|
|
40
40
|
}, 1032, ["to"]))), 128))
|
|
@@ -1,40 +1,40 @@
|
|
|
1
|
-
import { defineComponent as f, createElementBlock as u, openBlock as
|
|
1
|
+
import { defineComponent as f, createElementBlock as u, openBlock as c, withModifiers as a, withKeys as p, createElementVNode as s, normalizeProps as x, guardReactiveProps as b, unref as d, renderSlot as l, createVNode as h, withCtx as v, createTextVNode as w } from "vue";
|
|
2
2
|
import { useBindCx as B, ScalarButton as C } from "@scalar/components";
|
|
3
|
-
const y = { class: "flex gap-2" }, S = { class: "flex max-h-8 flex-1" },
|
|
3
|
+
const y = { class: "flex gap-2" }, S = { class: "flex max-h-8 flex-1" }, g = {
|
|
4
4
|
name: "CommandActionForm"
|
|
5
|
-
},
|
|
6
|
-
...
|
|
5
|
+
}, V = /* @__PURE__ */ f({
|
|
6
|
+
...g,
|
|
7
7
|
props: {
|
|
8
8
|
loader: {},
|
|
9
9
|
disabled: { type: Boolean, default: !1 }
|
|
10
10
|
},
|
|
11
11
|
emits: ["submit", "cancel", "back"],
|
|
12
|
-
setup(
|
|
12
|
+
setup(t, { emit: i }) {
|
|
13
13
|
const n = i, { cx: r } = B(), m = () => {
|
|
14
|
-
|
|
14
|
+
t.disabled || n("submit");
|
|
15
15
|
};
|
|
16
|
-
return (
|
|
16
|
+
return (o, e) => (c(), u("form", {
|
|
17
17
|
class: "flex w-full flex-col gap-3",
|
|
18
|
-
onKeydown:
|
|
18
|
+
onKeydown: e[0] || (e[0] = p(a(() => {
|
|
19
19
|
}, ["stop"]), ["enter"])),
|
|
20
|
-
onSubmit:
|
|
20
|
+
onSubmit: a(m, ["prevent", "stop"])
|
|
21
21
|
}, [
|
|
22
|
-
|
|
23
|
-
|
|
22
|
+
s("div", x(b(d(r)("relative flex min-h-20 flex-col rounded"))), [
|
|
23
|
+
l(o.$slots, "default")
|
|
24
24
|
], 16),
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
25
|
+
s("div", y, [
|
|
26
|
+
s("div", S, [
|
|
27
|
+
l(o.$slots, "options")
|
|
28
28
|
]),
|
|
29
|
-
h(
|
|
29
|
+
h(d(C), {
|
|
30
30
|
class: "max-h-8 px-3 text-xs",
|
|
31
|
-
disabled:
|
|
32
|
-
loader:
|
|
31
|
+
disabled: t.disabled,
|
|
32
|
+
loader: t.loader,
|
|
33
33
|
type: "submit"
|
|
34
34
|
}, {
|
|
35
35
|
default: v(() => [
|
|
36
|
-
|
|
37
|
-
|
|
36
|
+
l(o.$slots, "submit", {}, () => [
|
|
37
|
+
e[1] || (e[1] = w("Continue", -1))
|
|
38
38
|
])
|
|
39
39
|
]),
|
|
40
40
|
_: 3
|
|
@@ -44,5 +44,5 @@ const y = { class: "flex gap-2" }, S = { class: "flex max-h-8 flex-1" }, _ = {
|
|
|
44
44
|
}
|
|
45
45
|
});
|
|
46
46
|
export {
|
|
47
|
-
|
|
47
|
+
V as default
|
|
48
48
|
};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { defineComponent as c, ref as
|
|
2
|
-
const
|
|
1
|
+
import { defineComponent as c, ref as m, computed as p, onMounted as f, nextTick as h, withDirectives as b, createElementBlock as g, openBlock as v, mergeProps as w, withKeys as u, vModelText as x } from "vue";
|
|
2
|
+
const y = ["placeholder"], E = {
|
|
3
3
|
name: "CommandActionInput"
|
|
4
|
-
},
|
|
4
|
+
}, k = /* @__PURE__ */ c({
|
|
5
5
|
...E,
|
|
6
6
|
inheritAttrs: !1,
|
|
7
7
|
props: {
|
|
@@ -10,43 +10,43 @@ const x = ["placeholder"], E = {
|
|
|
10
10
|
autofocus: { type: Boolean, default: !0 }
|
|
11
11
|
},
|
|
12
12
|
emits: ["update:modelValue", "delete"],
|
|
13
|
-
setup(
|
|
14
|
-
const a =
|
|
15
|
-
get: () =>
|
|
13
|
+
setup(o, { emit: d }) {
|
|
14
|
+
const a = d, r = m(null), n = p({
|
|
15
|
+
get: () => o.modelValue ?? "",
|
|
16
16
|
set: (e) => a("update:modelValue", e)
|
|
17
17
|
});
|
|
18
18
|
f(() => {
|
|
19
19
|
h(() => {
|
|
20
|
-
|
|
20
|
+
o.autofocus && r.value?.focus();
|
|
21
21
|
});
|
|
22
22
|
});
|
|
23
|
-
const
|
|
23
|
+
const s = (e) => {
|
|
24
24
|
if (e.shiftKey || !e.target)
|
|
25
25
|
return;
|
|
26
26
|
e.preventDefault();
|
|
27
|
-
const t = e.target,
|
|
28
|
-
t.form?.dispatchEvent(
|
|
27
|
+
const t = e.target, l = new Event("submit", { cancelable: !0 });
|
|
28
|
+
t.form?.dispatchEvent(l);
|
|
29
29
|
}, i = (e) => {
|
|
30
|
-
|
|
30
|
+
n.value === "" && (e.preventDefault(), e.stopPropagation(), a("delete", e));
|
|
31
31
|
};
|
|
32
32
|
return (e, t) => b((v(), g("textarea", w({
|
|
33
33
|
id: "command-action-input",
|
|
34
34
|
ref_key: "input",
|
|
35
35
|
ref: r,
|
|
36
|
-
"onUpdate:modelValue": t[0] || (t[0] = (
|
|
36
|
+
"onUpdate:modelValue": t[0] || (t[0] = (l) => n.value = l),
|
|
37
37
|
class: "min-h-8 w-full flex-1 resize-none border border-transparent py-1.5 pl-8.5 text-sm outline-none focus:border-b-1",
|
|
38
|
-
placeholder:
|
|
38
|
+
placeholder: o.placeholder ?? "",
|
|
39
39
|
wrap: "hard"
|
|
40
40
|
}, e.$attrs, {
|
|
41
41
|
onKeydown: [
|
|
42
42
|
u(i, ["delete"]),
|
|
43
|
-
u(
|
|
43
|
+
u(s, ["enter"])
|
|
44
44
|
]
|
|
45
|
-
}), null, 16,
|
|
46
|
-
[
|
|
45
|
+
}), null, 16, y)), [
|
|
46
|
+
[x, n.value]
|
|
47
47
|
]);
|
|
48
48
|
}
|
|
49
49
|
});
|
|
50
50
|
export {
|
|
51
|
-
|
|
51
|
+
k as default
|
|
52
52
|
};
|