@scalar/api-client 2.38.1 → 2.38.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 +17 -0
- package/dist/AddressBar-CX8xiYoe.js +302 -0
- package/dist/AddressBar-CX8xiYoe.js.map +1 -0
- package/dist/App-BpNPKHmM.js +533 -0
- package/dist/App-BpNPKHmM.js.map +1 -0
- package/dist/App-Ckirvnv1.js +2510 -0
- package/dist/App-Ckirvnv1.js.map +1 -0
- package/dist/CodeInput-BN7uw3Bh.js +694 -0
- package/dist/CodeInput-BN7uw3Bh.js.map +1 -0
- package/dist/CodeSnippet-D7Heh1nd.js +218 -0
- package/dist/CodeSnippet-D7Heh1nd.js.map +1 -0
- package/dist/Collection-ChAxs3rz.js +219 -0
- package/dist/Collection-ChAxs3rz.js.map +1 -0
- package/dist/CollectionAuthentication-BDpvv8cA.js +56 -0
- package/dist/CollectionAuthentication-BDpvv8cA.js.map +1 -0
- package/dist/CollectionCookies-DyjPPMdt.js +19 -0
- package/dist/CollectionCookies-DyjPPMdt.js.map +1 -0
- package/dist/CollectionEnvironment-dwisJ-h5.js +514 -0
- package/dist/CollectionEnvironment-dwisJ-h5.js.map +1 -0
- package/dist/CollectionOverview-CJ9-Vmei.js +131 -0
- package/dist/CollectionOverview-CJ9-Vmei.js.map +1 -0
- package/dist/CollectionScripts-CMNlBlby.js +19 -0
- package/dist/CollectionScripts-CMNlBlby.js.map +1 -0
- package/dist/CollectionServers-BWkIGwz4.js +168 -0
- package/dist/CollectionServers-BWkIGwz4.js.map +1 -0
- package/dist/CollectionSettings-CqUUYOym.js +87 -0
- package/dist/CollectionSettings-CqUUYOym.js.map +1 -0
- package/dist/CollectionSync-CAflc5yW.js +19 -0
- package/dist/CollectionSync-CAflc5yW.js.map +1 -0
- package/dist/CommandActionInput-TkcAx6E8.js +97 -0
- package/dist/CommandActionInput-TkcAx6E8.js.map +1 -0
- package/dist/CommandPalette-BiA0IgO8.js +964 -0
- package/dist/CommandPalette-BiA0IgO8.js.map +1 -0
- package/dist/CommandPaletteImport-Diu5dDIY.js +622 -0
- package/dist/CommandPaletteImport-Diu5dDIY.js.map +1 -0
- package/dist/Cookies-CNRSxP8J.js +284 -0
- package/dist/Cookies-CNRSxP8J.js.map +1 -0
- package/dist/DataTable-BqbZKW3K.js +62 -0
- package/dist/DataTable-BqbZKW3K.js.map +1 -0
- package/dist/DataTableHeader-DJVB0jCZ.js +21 -0
- package/dist/DataTableHeader-DJVB0jCZ.js.map +1 -0
- package/dist/DataTableInput-SkIUPlrB.js +166 -0
- package/dist/DataTableInput-SkIUPlrB.js.map +1 -0
- package/dist/DataTableRow-c3XveEUO.js +57 -0
- package/dist/DataTableRow-c3XveEUO.js.map +1 -0
- package/dist/DeleteSidebarListElement-C-p87d03.js +78 -0
- package/dist/DeleteSidebarListElement-C-p87d03.js.map +1 -0
- package/dist/EditSidebarListElement-CodWPnM6.js +32 -0
- package/dist/EditSidebarListElement-CodWPnM6.js.map +1 -0
- package/dist/Editor-BomsGWHx.js +909 -0
- package/dist/Editor-BomsGWHx.js.map +1 -0
- package/dist/EmptyState-Cnm7hGW5.js +46 -0
- package/dist/EmptyState-Cnm7hGW5.js.map +1 -0
- package/dist/Environment-D_CbZk0A.js +416 -0
- package/dist/Environment-D_CbZk0A.js.map +1 -0
- package/dist/EnvironmentModal-CcyqnPc2.js +288 -0
- package/dist/EnvironmentModal-CcyqnPc2.js.map +1 -0
- package/dist/Form-bA4bV_oA.js +83 -0
- package/dist/Form-bA4bV_oA.js.map +1 -0
- package/dist/HttpMethod-rnWEgC3T.js +78 -0
- package/dist/HttpMethod-rnWEgC3T.js.map +1 -0
- package/dist/IconSelector-BDC_GQXv.js +67 -0
- package/dist/IconSelector-BDC_GQXv.js.map +1 -0
- package/dist/ImportCollection-BIYMxB9Q.js +804 -0
- package/dist/ImportCollection-BIYMxB9Q.js.map +1 -0
- package/dist/IntegrationLogo-B9EDW8db.js +51 -0
- package/dist/IntegrationLogo-B9EDW8db.js.map +1 -0
- package/dist/MainLayout-oMIJ5QXF.js +281 -0
- package/dist/MainLayout-oMIJ5QXF.js.map +1 -0
- package/dist/Modal-DkOa_KK0.js +67 -0
- package/dist/Modal-DkOa_KK0.js.map +1 -0
- package/dist/ModalClientContainer-qHsZi4wQ.js +65 -0
- package/dist/ModalClientContainer-qHsZi4wQ.js.map +1 -0
- package/dist/Request-BWfYWyBa.js +212 -0
- package/dist/Request-BWfYWyBa.js.map +1 -0
- package/dist/RequestAuth-BU6ubH-c.js +989 -0
- package/dist/RequestAuth-BU6ubH-c.js.map +1 -0
- package/dist/RequestRoot-7xhK5_qr.js +1611 -0
- package/dist/RequestRoot-7xhK5_qr.js.map +1 -0
- package/dist/RequestSection-Bx8UHW-k.js +1582 -0
- package/dist/RequestSection-Bx8UHW-k.js.map +1 -0
- package/dist/ResponseSection-CLrgLMN_.js +949 -0
- package/dist/ResponseSection-CLrgLMN_.js.map +1 -0
- package/dist/ScalarAsciiArt-BjuSnj8e.js +45 -0
- package/dist/ScalarAsciiArt-BjuSnj8e.js.map +1 -0
- package/dist/SectionFilter-hrtoRLwj.js +99 -0
- package/dist/SectionFilter-hrtoRLwj.js.map +1 -0
- package/dist/Server-BS4zjUdO.js +303 -0
- package/dist/Server-BS4zjUdO.js.map +1 -0
- package/dist/ServerVariablesForm-BRZ9XC8o.js +145 -0
- package/dist/ServerVariablesForm-BRZ9XC8o.js.map +1 -0
- package/dist/Settings-BuLKHzRY.js +347 -0
- package/dist/Settings-BuLKHzRY.js.map +1 -0
- package/dist/Sidebar-Xl9_nFXX.js +73 -0
- package/dist/Sidebar-Xl9_nFXX.js.map +1 -0
- package/dist/SidebarButton-BAagdMDe.js +37 -0
- package/dist/SidebarButton-BAagdMDe.js.map +1 -0
- package/dist/SidebarListElement-BfTPiihc.js +232 -0
- package/dist/SidebarListElement-BfTPiihc.js.map +1 -0
- package/dist/TheCommandPalette-Dl9TAeke.js +204 -0
- package/dist/TheCommandPalette-Dl9TAeke.js.map +1 -0
- package/dist/ValueEmitter-QYkZ9Hdc.js +20 -0
- package/dist/ValueEmitter-QYkZ9Hdc.js.map +1 -0
- package/dist/ViewLayout-BOXN0IYo.js +17 -0
- package/dist/ViewLayout-BOXN0IYo.js.map +1 -0
- package/dist/ViewLayoutCollapse-CiTb-Uml.js +86 -0
- package/dist/ViewLayoutCollapse-CiTb-Uml.js.map +1 -0
- package/dist/ViewLayoutContent-CvMoJYPF.js +13 -0
- package/dist/ViewLayoutContent-CvMoJYPF.js.map +1 -0
- package/dist/ViewLayoutSection-mUqKbQry.js +23 -0
- package/dist/ViewLayoutSection-mUqKbQry.js.map +1 -0
- package/dist/WatchModeToggle-D_eAiTWJ.js +41 -0
- package/dist/WatchModeToggle-D_eAiTWJ.js.map +1 -0
- package/dist/_plugin-vue_export-helper-BmmBcIzD.js +8 -0
- package/dist/analytics-BZimCWcw.js +7 -0
- package/dist/analytics-BZimCWcw.js.map +1 -0
- package/dist/build-request-security-BQjNr2MD.js +41 -0
- package/dist/build-request-security-BQjNr2MD.js.map +1 -0
- package/dist/code-input-iq-moLxi.js +775 -0
- package/dist/code-input-iq-moLxi.js.map +1 -0
- package/dist/components/AddressBar/AddressBar.vue.d.ts +1 -1
- package/dist/components/AddressBar/index.d.ts +1 -1
- package/dist/components/AddressBar/index.js +5 -4
- package/dist/components/CodeInput/CodeInput.vue.d.ts +1 -1
- package/dist/components/CodeInput/codeVariableWidget.d.ts +1 -1
- package/dist/components/CodeInput/index.d.ts +1 -1
- package/dist/components/CodeInput/index.js +2 -4
- package/dist/components/CommandPalette/index.d.ts +1 -1
- package/dist/components/CommandPalette/index.js +3 -4
- package/dist/components/DataTable/DataTableInput.vue.d.ts +2 -2
- package/dist/components/DataTable/index.d.ts +8 -8
- package/dist/components/DataTable/index.js +6 -18
- package/dist/components/Form/LabelInput.vue.d.ts +1 -1
- package/dist/components/HttpMethod/index.d.ts +1 -1
- package/dist/components/HttpMethod/index.js +2 -4
- package/dist/components/ImportCollection/index.d.ts +1 -1
- package/dist/components/ImportCollection/index.js +2 -4
- package/dist/components/ImportCollection/utils/import-collection.d.ts +1 -1
- package/dist/components/ImportCollection/utils/workspace-store-is-empty.d.ts +1 -1
- package/dist/components/Server/ServerVariablesForm.vue.d.ts +1 -1
- package/dist/components/Server/index.d.ts +3 -3
- package/dist/components/Server/index.js +3 -8
- package/dist/components/Sidebar/index.d.ts +1 -1
- package/dist/components/Sidebar/index.js +2 -4
- package/dist/components/ViewLayout/index.d.ts +1 -1
- package/dist/components/ViewLayout/index.js +2 -4
- package/dist/components/index.d.ts +3 -3
- package/dist/components/index.js +7 -8
- package/dist/components-ChixwQhN.js +61 -0
- package/dist/components-ChixwQhN.js.map +1 -0
- package/dist/components-DfJHvSLM.js +183 -0
- package/dist/components-DfJHvSLM.js.map +1 -0
- package/dist/computer-D7VW3Ruy.js +562 -0
- package/dist/computer-D7VW3Ruy.js.map +1 -0
- package/dist/consts-CyGRb9dl.js +318 -0
- package/dist/consts-CyGRb9dl.js.map +1 -0
- package/dist/curl-nbw1OxbV.js +54 -0
- package/dist/curl-nbw1OxbV.js.map +1 -0
- package/dist/data-table-PL7e8NRO.js +282 -0
- package/dist/data-table-PL7e8NRO.js.map +1 -0
- package/dist/editor-BZ_J0eze.js +466 -0
- package/dist/editor-BZ_J0eze.js.map +1 -0
- package/dist/environments-ByLK9lnC.js +592 -0
- package/dist/environments-ByLK9lnC.js.map +1 -0
- package/dist/formatters-DOGXZq9R.js +36 -0
- package/dist/formatters-DOGXZq9R.js.map +1 -0
- package/dist/forms-CZX6cFDS.js +42 -0
- package/dist/forms-CZX6cFDS.js.map +1 -0
- package/dist/get-active-environment-CkxyQ1dM.js +19 -0
- package/dist/get-active-environment-CkxyQ1dM.js.map +1 -0
- package/dist/get-resolved-url-SybDPV0U.js +85 -0
- package/dist/get-resolved-url-SybDPV0U.js.map +1 -0
- package/dist/get-server-url-UVN-dx79.js +32 -0
- package/dist/get-server-url-UVN-dx79.js.map +1 -0
- package/dist/get-servers-B_WNlQWB.js +106 -0
- package/dist/get-servers-B_WNlQWB.js.map +1 -0
- package/dist/get-snippet-DBRUSfZ2.js +39 -0
- package/dist/get-snippet-DBRUSfZ2.js.map +1 -0
- package/dist/global-cookies-D3ZS9ON3.js +184 -0
- package/dist/global-cookies-D3ZS9ON3.js.map +1 -0
- package/dist/hooks/index.d.ts +4 -4
- package/dist/hooks/index.js +3 -11
- package/dist/hooks/useSidebar.d.ts +1 -1
- package/dist/hooks-BvZxH4XB.js +80 -0
- package/dist/hooks-BvZxH4XB.js.map +1 -0
- package/dist/index.d.ts +3 -3
- package/dist/index.js +8 -12
- package/dist/layout-BWiL7dfb.js +81 -0
- package/dist/layout-BWiL7dfb.js.map +1 -0
- package/dist/layouts/App/create-api-client-app.d.ts +9 -9
- package/dist/layouts/App/index.d.ts +2 -2
- package/dist/layouts/App/index.js +5 -7
- package/dist/layouts/Modal/create-api-client-modal.d.ts +1 -1
- package/dist/layouts/Modal/index.d.ts +2 -2
- package/dist/layouts/Modal/index.js +3 -4
- package/dist/layouts/Web/create-api-client-web.d.ts +9 -9
- package/dist/layouts/Web/index.d.ts +2 -2
- package/dist/layouts/Web/index.js +101 -6
- package/dist/layouts/Web/index.js.map +1 -0
- package/dist/libs/create-client.d.ts +9 -9
- package/dist/libs/create-client.d.ts.map +1 -1
- package/dist/libs/environment-parser.d.ts +1 -1
- package/dist/libs/get-request-uid-by-path-method.d.ts +1 -1
- package/dist/libs/hot-keys.d.ts +1 -1
- package/dist/libs/importers/index.d.ts +1 -1
- package/dist/libs/importers/index.js +2 -4
- package/dist/libs/index.d.ts +15 -15
- package/dist/libs/index.js +6 -45
- package/dist/libs/local-storage.d.ts +1 -1
- package/dist/libs/send-request/create-request-operation.d.ts +3 -3
- package/dist/libs/send-request/index.d.ts +3 -3
- package/dist/libs/send-request/index.js +3 -8
- package/dist/libs-spbv4P0g.js +249 -0
- package/dist/libs-spbv4P0g.js.map +1 -0
- package/dist/monacoeditorwork/json.worker.bundle.js +8 -8
- package/dist/monacoeditorwork/yaml.worker.bundle.js +151 -151
- package/dist/operation-block-DE-hoO03.js +1674 -0
- package/dist/operation-block-DE-hoO03.js.map +1 -0
- package/dist/operation-code-sample-xgx4qi2H.js +1738 -0
- package/dist/operation-code-sample-xgx4qi2H.js.map +1 -0
- package/dist/parse-curl-BtypQT3D.js +106 -0
- package/dist/parse-curl-BtypQT3D.js.map +1 -0
- package/dist/plugins/hooks/usePluginManager.d.ts +1 -1
- package/dist/plugins/index.d.ts +2 -2
- package/dist/plugins/index.js +2 -7
- package/dist/plugins/plugin-manager.d.ts +10 -4
- package/dist/plugins/plugin-manager.d.ts.map +1 -1
- package/dist/plugins-B52hCIyZ.js +50 -0
- package/dist/plugins-B52hCIyZ.js.map +1 -0
- package/dist/rabbitjump-CMZXAR6d.js +9 -0
- package/dist/rabbitjump-CMZXAR6d.js.map +1 -0
- package/dist/request-block-N7dPFyrG.js +1466 -0
- package/dist/request-block-N7dPFyrG.js.map +1 -0
- package/dist/resize-D2IYvVdh.js +114 -0
- package/dist/resize-D2IYvVdh.js.map +1 -0
- package/dist/response-block-DmkaDZYs.js +1188 -0
- package/dist/response-block-DmkaDZYs.js.map +1 -0
- package/dist/scalar-address-bar-block-BbysOhkE.js +425 -0
- package/dist/scalar-address-bar-block-BbysOhkE.js.map +1 -0
- package/dist/scalar-auth-selector-block-Bs79QOMA.js +1889 -0
- package/dist/scalar-auth-selector-block-Bs79QOMA.js.map +1 -0
- package/dist/search-CmsQQkjn.js +151 -0
- package/dist/search-CmsQQkjn.js.map +1 -0
- package/dist/send-request-BsTfRiBC.js +348 -0
- package/dist/send-request-BsTfRiBC.js.map +1 -0
- package/dist/server-tcI-OCyx.js +140 -0
- package/dist/server-tcI-OCyx.js.map +1 -0
- package/dist/set-request-cookies-BJJhsU4A.js +88 -0
- package/dist/set-request-cookies-BJJhsU4A.js.map +1 -0
- package/dist/settings-BKk_1lcH.js +455 -0
- package/dist/settings-BKk_1lcH.js.map +1 -0
- package/dist/sidebar-ceSbYmnt.js +217 -0
- package/dist/sidebar-ceSbYmnt.js.map +1 -0
- package/dist/store/collections.d.ts +1 -1
- package/dist/store/environment.d.ts +1 -1
- package/dist/store/events.d.ts +8 -8
- package/dist/store/import-spec.d.ts +2 -2
- package/dist/store/index.d.ts +2 -2
- package/dist/store/index.js +2 -10
- package/dist/store/request-example.d.ts +1 -1
- package/dist/store/requests.d.ts +1 -1
- package/dist/store/security-schemes.d.ts +1 -1
- package/dist/store/servers.d.ts +1 -1
- package/dist/store/store.d.ts +7 -7
- package/dist/store/tags.d.ts +1 -1
- package/dist/store/workspace.d.ts +1 -1
- package/dist/store-DaPoVtIS.js +1512 -0
- package/dist/store-DaPoVtIS.js.map +1 -0
- package/dist/string-template-sS5PtY6T.js +64 -0
- package/dist/string-template-sS5PtY6T.js.map +1 -0
- package/dist/style.css +10372 -1
- package/dist/types/index.js +0 -1
- package/dist/use-global-hot-keys-D8Ai8Qbm.js +274 -0
- package/dist/use-global-hot-keys-D8Ai8Qbm.js.map +1 -0
- package/dist/useSidebar-DLTwHDI-.js +45 -0
- package/dist/useSidebar-DLTwHDI-.js.map +1 -0
- package/dist/v2/blocks/operation-block/OperationBlock.vue.d.ts +3 -3
- package/dist/v2/blocks/operation-block/OperationBlock.vue.d.ts.map +1 -1
- package/dist/v2/blocks/operation-block/components/Header.vue.d.ts +2 -2
- package/dist/v2/blocks/operation-block/helpers/apply-allow-reserved-to-url.d.ts +6 -0
- package/dist/v2/blocks/operation-block/helpers/apply-allow-reserved-to-url.d.ts.map +1 -0
- package/dist/v2/blocks/operation-block/helpers/build-request-body.d.ts.map +1 -1
- package/dist/v2/blocks/operation-block/helpers/build-request-parameters.d.ts +1 -0
- package/dist/v2/blocks/operation-block/helpers/build-request-parameters.d.ts.map +1 -1
- package/dist/v2/blocks/operation-block/helpers/build-request-security.d.ts +2 -2
- package/dist/v2/blocks/operation-block/helpers/build-request.d.ts +2 -2
- package/dist/v2/blocks/operation-block/helpers/build-request.d.ts.map +1 -1
- package/dist/v2/blocks/operation-block/helpers/get-resolved-url.d.ts +2 -1
- package/dist/v2/blocks/operation-block/helpers/get-resolved-url.d.ts.map +1 -1
- package/dist/v2/blocks/operation-block/helpers/har-to-fetch-response.d.ts +1 -1
- package/dist/v2/blocks/operation-block/helpers/send-request.d.ts +1 -1
- package/dist/v2/blocks/operation-block/index.d.ts +4 -4
- package/dist/v2/blocks/operation-block/index.js +20 -11
- package/dist/v2/blocks/operation-code-sample/components/OperationCodeSample.vue.d.ts +2 -2
- package/dist/v2/blocks/operation-code-sample/helpers/find-client.d.ts +1 -1
- package/dist/v2/blocks/operation-code-sample/helpers/generate-client-options.d.ts +1 -1
- package/dist/v2/blocks/operation-code-sample/helpers/generate-code-snippet.d.ts +2 -2
- package/dist/v2/blocks/operation-code-sample/helpers/get-clients.d.ts +2 -2
- package/dist/v2/blocks/operation-code-sample/helpers/get-secrets.d.ts +1 -1
- package/dist/v2/blocks/operation-code-sample/helpers/operation-to-har/operation-to-har.d.ts +1 -1
- package/dist/v2/blocks/operation-code-sample/helpers/operation-to-har/process-body.d.ts +1 -1
- 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-security-schemes.d.ts +1 -1
- package/dist/v2/blocks/operation-code-sample/index.d.ts +6 -6
- package/dist/v2/blocks/operation-code-sample/index.js +2 -16
- package/dist/v2/blocks/request-block/RequestBlock.vue.d.ts +4 -4
- package/dist/v2/blocks/request-block/components/RequestCodeSnippet.vue.d.ts +1 -1
- package/dist/v2/blocks/request-block/components/RequestParams.vue.d.ts +1 -1
- package/dist/v2/blocks/request-block/components/RequestTable.vue.d.ts +1 -1
- package/dist/v2/blocks/request-block/helpers/create-parameter-handlers.d.ts +1 -1
- package/dist/v2/blocks/request-block/helpers/get-default-headers.d.ts +3 -2
- package/dist/v2/blocks/request-block/helpers/get-default-headers.d.ts.map +1 -1
- package/dist/v2/blocks/request-block/helpers/get-form-body-rows.d.ts +1 -1
- package/dist/v2/blocks/request-block/index.d.ts +1 -1
- package/dist/v2/blocks/request-block/index.js +9 -4
- package/dist/v2/blocks/response-block/ResponseBlock.vue.d.ts +1 -1
- package/dist/v2/blocks/response-block/components/ResponseBodyPreview.vue.d.ts +1 -1
- package/dist/v2/blocks/response-block/components/ResponseEmpty.vue.d.ts +1 -1
- package/dist/v2/blocks/response-block/index.d.ts +1 -1
- package/dist/v2/blocks/response-block/index.js +6 -4
- package/dist/v2/blocks/scalar-address-bar-block/components/AddressBar.vue.d.ts +2 -2
- package/dist/v2/blocks/scalar-address-bar-block/index.d.ts +2 -2
- package/dist/v2/blocks/scalar-address-bar-block/index.js +5 -4
- package/dist/v2/blocks/scalar-auth-selector-block/components/AuthSelector.vue.d.ts +3 -3
- package/dist/v2/blocks/scalar-auth-selector-block/components/OAuth2.vue.d.ts +1 -1
- package/dist/v2/blocks/scalar-auth-selector-block/components/RequestAuthDataTable.vue.d.ts +2 -2
- package/dist/v2/blocks/scalar-auth-selector-block/components/RequestAuthDataTableInput.vue.d.ts +1 -1
- package/dist/v2/blocks/scalar-auth-selector-block/components/RequestAuthTab.vue.d.ts +1 -1
- package/dist/v2/blocks/scalar-auth-selector-block/helpers/extract-security-scheme-secrets.d.ts.map +1 -1
- package/dist/v2/blocks/scalar-auth-selector-block/helpers/fetch-openid-connect-discovery.d.ts +1 -1
- package/dist/v2/blocks/scalar-auth-selector-block/helpers/oauth.d.ts +2 -2
- package/dist/v2/blocks/scalar-auth-selector-block/helpers/openid-discovery-to-flows.d.ts +1 -1
- package/dist/v2/blocks/scalar-auth-selector-block/helpers/security-scheme.d.ts.map +1 -1
- package/dist/v2/blocks/scalar-auth-selector-block/index.d.ts +4 -4
- package/dist/v2/blocks/scalar-auth-selector-block/index.js +6 -8
- package/dist/v2/components/code-input/CodeInput.vue.d.ts +1 -1
- package/dist/v2/components/code-input/index.d.ts +1 -1
- package/dist/v2/components/code-input/index.js +2 -4
- package/dist/v2/components/data-table/DataTableInput.vue.d.ts +1 -1
- package/dist/v2/components/data-table/DataTableInputSelect.vue.d.ts +1 -1
- package/dist/v2/components/data-table/index.d.ts +8 -8
- package/dist/v2/components/data-table/index.js +3 -18
- package/dist/v2/components/forms/index.d.ts +1 -1
- package/dist/v2/components/forms/index.js +2 -4
- package/dist/v2/components/layout/index.d.ts +1 -1
- package/dist/v2/components/layout/index.js +2 -4
- package/dist/v2/components/modals/index.d.ts +1 -1
- package/dist/v2/components/modals/index.js +37 -3
- package/dist/v2/components/modals/index.js.map +1 -0
- package/dist/v2/components/resize/index.d.ts +2 -2
- package/dist/v2/components/resize/index.js +2 -6
- package/dist/v2/components/server/ServerDropdown.vue.d.ts +1 -1
- package/dist/v2/components/server/index.d.ts +1 -1
- package/dist/v2/components/server/index.js +2 -4
- package/dist/v2/components/sidebar/Sidebar.vue.d.ts +1 -1
- package/dist/v2/components/sidebar/index.d.ts +3 -3
- package/dist/v2/components/sidebar/index.js +3 -8
- package/dist/v2/constants.d.ts +3 -0
- package/dist/v2/constants.d.ts.map +1 -0
- package/dist/v2/features/app/App.vue.d.ts +4 -4
- package/dist/v2/features/app/components/AppSidebar.vue.d.ts +1 -1
- package/dist/v2/features/app/components/index.d.ts +1 -1
- package/dist/v2/features/app/components/index.js +10 -5
- package/dist/v2/features/app/helpers/create-api-client-app.d.ts +3 -3
- package/dist/v2/features/app/helpers/get-route-param.d.ts +1 -1
- package/dist/v2/features/app/helpers/routes.d.ts +5 -5
- package/dist/v2/features/app/hooks/use-theme.d.ts +1 -1
- package/dist/v2/features/app/index.d.ts +8 -8
- package/dist/v2/features/app/index.js +3161 -19
- package/dist/v2/features/app/index.js.map +1 -0
- package/dist/v2/features/collection/DocumentCollection.vue.d.ts +1 -1
- package/dist/v2/features/collection/OperationCollection.vue.d.ts +1 -1
- package/dist/v2/features/collection/WorkspaceCollection.vue.d.ts +1 -1
- package/dist/v2/features/collection/components/Authentication.vue.d.ts +4 -4
- package/dist/v2/features/collection/components/Authentication.vue.d.ts.map +1 -1
- package/dist/v2/features/collection/components/Cookies.vue.d.ts +4 -4
- package/dist/v2/features/collection/components/Editor/Editor.vue.d.ts +4 -4
- package/dist/v2/features/collection/components/Editor/index.d.ts +1 -1
- package/dist/v2/features/collection/components/Editor/index.js +2 -4
- package/dist/v2/features/collection/components/Environment.vue.d.ts +4 -4
- package/dist/v2/features/collection/components/Overview.vue.d.ts +4 -4
- package/dist/v2/features/collection/components/Servers.vue.d.ts +4 -4
- package/dist/v2/features/collection/components/Settings.vue.d.ts +4 -4
- package/dist/v2/features/collection/components/Tabs.vue.d.ts +1 -1
- package/dist/v2/features/command-palette/TheCommandPalette.vue.d.ts +1 -1
- package/dist/v2/features/command-palette/hooks/use-command-palette-state.d.ts +10 -45
- package/dist/v2/features/command-palette/hooks/use-command-palette-state.d.ts.map +1 -1
- package/dist/v2/features/command-palette/index.d.ts +2 -2
- package/dist/v2/features/command-palette/index.js +3 -6
- package/dist/v2/features/editor/helpers/json/create-json-model.d.ts +1 -1
- package/dist/v2/features/editor/helpers/json/get-json-ast-node-from-path.d.ts +1 -1
- package/dist/v2/features/editor/helpers/json/json-pointer-path.d.ts +1 -1
- package/dist/v2/features/editor/helpers/yaml/create-yaml-model.d.ts +1 -1
- package/dist/v2/features/editor/helpers/yaml/get-yaml-node-range-from-path.d.ts +1 -1
- package/dist/v2/features/editor/hooks/use-editor.d.ts +1 -1
- package/dist/v2/features/editor/hooks/use-json-pointer-link-support.d.ts +1 -1
- package/dist/v2/features/editor/index.d.ts +4 -4
- package/dist/v2/features/editor/index.js +2 -10
- package/dist/v2/features/environments/index.d.ts +1 -1
- package/dist/v2/features/environments/index.js +4 -4
- package/dist/v2/features/global-cookies/index.d.ts +1 -1
- package/dist/v2/features/global-cookies/index.js +4 -4
- package/dist/v2/features/modal/Modal.vue.d.ts +1 -1
- package/dist/v2/features/modal/helpers/create-api-client-modal.d.ts +2 -2
- package/dist/v2/features/modal/hooks/use-modal-sidebar.d.ts +1 -1
- package/dist/v2/features/modal/index.d.ts +3 -3
- package/dist/v2/features/modal/index.js +639 -7
- package/dist/v2/features/modal/index.js.map +1 -0
- package/dist/v2/features/modal/modal-events.d.ts +1 -1
- package/dist/v2/features/operation/Operation.vue.d.ts +2 -2
- package/dist/v2/features/operation/Operation.vue.d.ts.map +1 -1
- package/dist/v2/features/operation/helpers/get-selected-security.d.ts +6 -1
- package/dist/v2/features/operation/helpers/get-selected-security.d.ts.map +1 -1
- package/dist/v2/features/operation/index.d.ts +5 -5
- package/dist/v2/features/operation/index.js +19 -12
- package/dist/v2/features/search/helpers/create-fuse-instance.d.ts +1 -1
- package/dist/v2/features/search/helpers/create-search-index.d.ts +1 -1
- package/dist/v2/features/search/index.d.ts +1 -1
- package/dist/v2/features/search/index.js +2 -4
- package/dist/v2/features/settings/index.d.ts +2 -2
- package/dist/v2/features/settings/index.js +2 -6
- package/dist/v2/helpers/get-active-proxy-url.d.ts +1 -1
- package/dist/v2/helpers/get-tab-details.d.ts +1 -1
- package/dist/v2/helpers/handle-hotkeys.d.ts +1 -1
- package/dist/v2/helpers/index.d.ts +2 -2
- package/dist/v2/helpers/index.js +3 -6
- package/dist/v2/hooks/use-global-hot-keys.d.ts +1 -1
- package/dist/views/Collection/components/EnvironmentForm.vue.d.ts +1 -1
- package/dist/views/Collection/components/MarkdownInput.vue.d.ts +1 -1
- package/dist/views/Components/CodeSnippet/CodeSnippet.vue.d.ts +1 -1
- package/dist/views/Components/CodeSnippet/helpers/get-har-request.d.ts +1 -1
- package/dist/views/Components/CodeSnippet/helpers/get-snippet.d.ts +1 -1
- package/dist/views/Components/CodeSnippet/index.d.ts +4 -4
- package/dist/views/Components/CodeSnippet/index.js +3 -10
- package/dist/views/Environment/EnvironmentVariableDropdown.vue.d.ts +1 -1
- package/dist/views/Environment/handle-drag.d.ts +1 -1
- package/dist/views/Request/Request.vue.d.ts +1 -1
- package/dist/views/Request/RequestSection/RequestAuth/OAuth2.vue.d.ts +1 -1
- package/dist/views/Request/RequestSection/RequestAuth/OAuthScopesInput.vue.d.ts +1 -1
- package/dist/views/Request/RequestSection/RequestAuth/RequestAuth.vue.d.ts +1 -1
- package/dist/views/Request/RequestSection/RequestAuth/RequestAuthDataTable.vue.d.ts +1 -1
- package/dist/views/Request/RequestSection/RequestAuth/RequestAuthDataTableInput.vue.d.ts +2 -2
- package/dist/views/Request/RequestSection/RequestAuth/RequestAuthTab.vue.d.ts +1 -1
- package/dist/views/Request/RequestSection/RequestAuth/helpers/restore-auth-from-local-storage.d.ts +1 -1
- package/dist/views/Request/RequestSection/RequestAuth/index.d.ts +3 -3
- package/dist/views/Request/RequestSection/RequestAuth/index.js +4 -8
- package/dist/views/Request/RequestSection/RequestBody.vue.d.ts +1 -1
- package/dist/views/Request/RequestSection/RequestCodeExample.vue.d.ts +1 -1
- package/dist/views/Request/RequestSection/RequestParams.vue.d.ts +1 -1
- package/dist/views/Request/RequestSection/RequestPathParams.vue.d.ts +1 -1
- package/dist/views/Request/RequestSection/RequestSection.vue.d.ts +1 -1
- package/dist/views/Request/RequestSection/RequestTable.vue.d.ts +1 -1
- package/dist/views/Request/RequestSection/helpers/update-scheme.d.ts +1 -1
- package/dist/views/Request/RequestSection/index.d.ts +2 -2
- package/dist/views/Request/RequestSection/index.js +42 -5
- package/dist/views/Request/RequestSection/index.js.map +1 -0
- package/dist/views/Request/RequestSidebarItem.vue.d.ts +1 -1
- package/dist/views/Request/RequestSidebarItemMenu.vue.d.ts +3 -3
- package/dist/views/Request/RequestSubpageHeader.vue.d.ts +1 -1
- package/dist/views/Request/ResponseSection/ResponseBodyPreview.vue.d.ts +1 -1
- package/dist/views/Request/ResponseSection/ResponseSection.vue.d.ts +1 -1
- package/dist/views/Request/ResponseSection/index.d.ts +2 -2
- package/dist/views/Request/ResponseSection/index.js +7 -6
- package/dist/views/Request/components/index.d.ts +1 -1
- package/dist/views/Request/components/index.js +2 -4
- package/dist/views/Request/consts/index.d.ts +2 -2
- package/dist/views/Request/consts/index.js +2 -10
- package/dist/views/Request/handle-drag.d.ts +2 -2
- package/dist/views/Request/libs/auth.d.ts +1 -1
- package/dist/views/Request/libs/index.d.ts +3 -3
- package/dist/views/Request/libs/index.js +3 -22
- package/dist/views/Request/libs/oauth2.d.ts +1 -1
- package/dist/views/Request/libs/watch-mode.d.ts +2 -2
- package/dist/views/Request/types/index.js +0 -1
- package/dist/watch-mode-Dbaqd9bG.js +375 -0
- package/dist/watch-mode-Dbaqd9bG.js.map +1 -0
- package/package.json +29 -33
- package/dist/_virtual/_plugin-vue_export-helper.js +0 -9
- package/dist/analytics.js +0 -9
- package/dist/assets/computer.ascii.js +0 -34
- package/dist/assets/keycap.ascii.js +0 -25
- package/dist/assets/rabbit.ascii.js +0 -11
- package/dist/assets/rabbitjump.ascii.js +0 -11
- package/dist/components/AddressBar/AddressBar.vue.js +0 -7
- package/dist/components/AddressBar/AddressBar.vue2.js +0 -160
- package/dist/components/AddressBar/AddressBarHistory.vue.js +0 -7
- package/dist/components/AddressBar/AddressBarHistory.vue2.js +0 -98
- package/dist/components/AddressBar/httpStatusCodeColors.js +0 -38
- package/dist/components/CodeInput/CodeInput.vue.js +0 -8
- package/dist/components/CodeInput/CodeInput.vue2.js +0 -209
- package/dist/components/CodeInput/codeVariableWidget.js +0 -111
- package/dist/components/CommandPalette/CommandActionForm.vue.js +0 -44
- package/dist/components/CommandPalette/CommandActionForm.vue2.js +0 -4
- package/dist/components/CommandPalette/CommandActionInput.vue.js +0 -52
- package/dist/components/CommandPalette/CommandActionInput.vue2.js +0 -4
- package/dist/components/CommandPalette/CommandPaletteCollection.vue.js +0 -80
- package/dist/components/CommandPalette/CommandPaletteCollection.vue2.js +0 -4
- package/dist/components/CommandPalette/CommandPaletteExample.vue.js +0 -116
- package/dist/components/CommandPalette/CommandPaletteExample.vue2.js +0 -4
- package/dist/components/CommandPalette/CommandPaletteImport.vue.js +0 -217
- package/dist/components/CommandPalette/CommandPaletteImport.vue2.js +0 -4
- package/dist/components/CommandPalette/CommandPaletteImportCurl.vue.js +0 -7
- package/dist/components/CommandPalette/CommandPaletteImportCurl.vue2.js +0 -136
- package/dist/components/CommandPalette/CommandPaletteServer.vue.js +0 -123
- package/dist/components/CommandPalette/CommandPaletteServer.vue2.js +0 -4
- package/dist/components/CommandPalette/CommandPaletteTag.vue.js +0 -84
- package/dist/components/CommandPalette/CommandPaletteTag.vue2.js +0 -4
- package/dist/components/CommandPalette/CommandPaletteWorkspace.vue.js +0 -48
- package/dist/components/CommandPalette/CommandPaletteWorkspace.vue2.js +0 -4
- package/dist/components/CommandPalette/TheCommandPalette.vue.js +0 -7
- package/dist/components/CommandPalette/TheCommandPalette.vue2.js +0 -305
- package/dist/components/CommandPalette/WatchModeToggle.vue.js +0 -39
- package/dist/components/CommandPalette/WatchModeToggle.vue2.js +0 -4
- package/dist/components/DataTable/DataTable.vue.js +0 -38
- package/dist/components/DataTable/DataTable.vue2.js +0 -4
- package/dist/components/DataTable/DataTableCell.vue.js +0 -26
- package/dist/components/DataTable/DataTableCell.vue2.js +0 -4
- package/dist/components/DataTable/DataTableCheckbox.vue.js +0 -53
- package/dist/components/DataTable/DataTableCheckbox.vue2.js +0 -4
- package/dist/components/DataTable/DataTableHeader.vue.js +0 -18
- package/dist/components/DataTable/DataTableHeader.vue2.js +0 -4
- package/dist/components/DataTable/DataTableInput.vue.js +0 -7
- package/dist/components/DataTable/DataTableInput.vue2.js +0 -124
- package/dist/components/DataTable/DataTableInputSelect.vue.js +0 -146
- package/dist/components/DataTable/DataTableInputSelect.vue2.js +0 -4
- package/dist/components/DataTable/DataTableRow.vue.js +0 -12
- package/dist/components/DataTable/DataTableText.vue.js +0 -23
- package/dist/components/DataTable/DataTableText.vue2.js +0 -4
- package/dist/components/EmptyState.vue.js +0 -7
- package/dist/components/EmptyState.vue2.js +0 -42
- package/dist/components/EnvironmentSelector/EnvironmentSelector.vue.js +0 -113
- package/dist/components/EnvironmentSelector/EnvironmentSelector.vue2.js +0 -4
- package/dist/components/Form/Form.vue.js +0 -83
- package/dist/components/Form/Form.vue2.js +0 -4
- package/dist/components/Form/LabelInput.vue.js +0 -7
- package/dist/components/Form/LabelInput.vue2.js +0 -42
- package/dist/components/HelpfulLink.vue.js +0 -20
- package/dist/components/HelpfulLink.vue2.js +0 -4
- package/dist/components/HttpMethod/HttpMethod.vue.js +0 -7
- package/dist/components/HttpMethod/HttpMethod.vue2.js +0 -62
- package/dist/components/IconSelector.vue.js +0 -75
- package/dist/components/IconSelector.vue2.js +0 -4
- package/dist/components/ImportCollection/DropEventListener.vue.js +0 -81
- package/dist/components/ImportCollection/DropEventListener.vue2.js +0 -4
- package/dist/components/ImportCollection/ImportCollectionListener.vue.js +0 -77
- package/dist/components/ImportCollection/ImportCollectionListener.vue2.js +0 -4
- package/dist/components/ImportCollection/ImportCollectionModal.vue.js +0 -208
- package/dist/components/ImportCollection/ImportCollectionModal.vue3.js +0 -5
- package/dist/components/ImportCollection/ImportNowButton.vue.js +0 -73
- package/dist/components/ImportCollection/ImportNowButton.vue2.js +0 -4
- package/dist/components/ImportCollection/IntegrationLogo.vue.js +0 -44
- package/dist/components/ImportCollection/IntegrationLogo.vue2.js +0 -4
- package/dist/components/ImportCollection/PasteEventListener.vue.js +0 -24
- package/dist/components/ImportCollection/PasteEventListener.vue2.js +0 -4
- package/dist/components/ImportCollection/PrefetchError.vue.js +0 -27
- package/dist/components/ImportCollection/PrefetchError.vue2.js +0 -4
- package/dist/components/ImportCollection/UrlQueryParameterChecker.vue.js +0 -20
- package/dist/components/ImportCollection/UrlQueryParameterChecker.vue2.js +0 -4
- package/dist/components/ImportCollection/WorkspaceSelector.vue.js +0 -134
- package/dist/components/ImportCollection/WorkspaceSelector.vue2.js +0 -4
- package/dist/components/ImportCollection/hooks/useUrlPrefetcher.js +0 -106
- package/dist/components/ImportCollection/utils/get-openapi-version.js +0 -20
- package/dist/components/ImportCollection/utils/import-collection.js +0 -29
- package/dist/components/ImportCollection/utils/is-document.js +0 -9
- package/dist/components/ImportCollection/utils/is-url.js +0 -9
- package/dist/components/ImportCollection/utils/workspace-store-is-empty.js +0 -7
- package/dist/components/OpenApiClientButton.vue.js +0 -7
- package/dist/components/OpenApiClientButton.vue2.js +0 -48
- package/dist/components/ScalarAsciiArt.vue.js +0 -7
- package/dist/components/ScalarAsciiArt.vue2.js +0 -37
- package/dist/components/Search/useSearch.js +0 -78
- package/dist/components/SectionFilter.vue.js +0 -7
- package/dist/components/SectionFilter.vue2.js +0 -64
- package/dist/components/SectionFilterButton.vue.js +0 -23
- package/dist/components/SectionFilterButton.vue2.js +0 -4
- package/dist/components/Server/ServerDropdown.vue.js +0 -132
- package/dist/components/Server/ServerDropdown.vue2.js +0 -4
- package/dist/components/Server/ServerDropdownItem.vue.js +0 -7
- package/dist/components/Server/ServerDropdownItem.vue2.js +0 -84
- package/dist/components/Server/ServerSelector.vue.js +0 -82
- package/dist/components/Server/ServerSelector.vue2.js +0 -4
- package/dist/components/Server/ServerVariablesForm.vue.js +0 -49
- package/dist/components/Server/ServerVariablesForm.vue2.js +0 -4
- package/dist/components/Server/ServerVariablesSelect.vue.js +0 -54
- package/dist/components/Server/ServerVariablesSelect.vue2.js +0 -4
- package/dist/components/Server/ServerVariablesTextbox.vue.js +0 -29
- package/dist/components/Server/ServerVariablesTextbox.vue2.js +0 -4
- package/dist/components/SideNav/DownloadAppButton.vue.js +0 -7
- package/dist/components/SideNav/DownloadAppButton.vue2.js +0 -33
- package/dist/components/SideNav/SideHelp.vue.js +0 -127
- package/dist/components/SideNav/SideHelp.vue2.js +0 -4
- package/dist/components/SideNav/SideNav.vue.js +0 -96
- package/dist/components/SideNav/SideNav.vue2.js +0 -4
- package/dist/components/SideNav/SideNavGroup.vue.js +0 -16
- package/dist/components/SideNav/SideNavGroup.vue2.js +0 -4
- package/dist/components/SideNav/SideNavLink.vue.js +0 -39
- package/dist/components/SideNav/SideNavLink.vue2.js +0 -4
- package/dist/components/SideNav/SideNavRouterLink.vue.js +0 -27
- package/dist/components/SideNav/SideNavRouterLink.vue2.js +0 -4
- package/dist/components/Sidebar/Actions/DeleteSidebarListElement.vue.js +0 -30
- package/dist/components/Sidebar/Actions/DeleteSidebarListElement.vue2.js +0 -4
- package/dist/components/Sidebar/Actions/EditSidebarListCollection.vue.js +0 -58
- package/dist/components/Sidebar/Actions/EditSidebarListCollection.vue2.js +0 -4
- package/dist/components/Sidebar/Actions/EditSidebarListElement.vue.js +0 -29
- package/dist/components/Sidebar/Actions/EditSidebarListElement.vue2.js +0 -4
- package/dist/components/Sidebar/Actions/SidebarListElementForm.vue.js +0 -46
- package/dist/components/Sidebar/Actions/SidebarListElementForm.vue2.js +0 -4
- package/dist/components/Sidebar/Sidebar.vue.js +0 -7
- package/dist/components/Sidebar/Sidebar.vue2.js +0 -63
- package/dist/components/Sidebar/SidebarButton.vue.js +0 -33
- package/dist/components/Sidebar/SidebarButton.vue2.js +0 -4
- package/dist/components/Sidebar/SidebarList.vue.js +0 -12
- package/dist/components/Sidebar/SidebarListElement.vue.js +0 -8
- package/dist/components/Sidebar/SidebarListElement.vue2.js +0 -94
- package/dist/components/Sidebar/SidebarListElementActions.vue.js +0 -86
- package/dist/components/Sidebar/SidebarListElementActions.vue2.js +0 -4
- package/dist/components/Sidebar/SidebarToggle.vue.js +0 -49
- package/dist/components/Sidebar/SidebarToggle.vue2.js +0 -4
- package/dist/components/TopNav/TopNav.vue.js +0 -210
- package/dist/components/TopNav/TopNav.vue2.js +0 -4
- package/dist/components/TopNav/TopNavItem.vue.js +0 -7
- package/dist/components/TopNav/TopNavItem.vue2.js +0 -138
- package/dist/components/ViewLayout/ViewLayout.vue.js +0 -18
- package/dist/components/ViewLayout/ViewLayout.vue2.js +0 -4
- package/dist/components/ViewLayout/ViewLayoutCollapse.vue.js +0 -92
- package/dist/components/ViewLayout/ViewLayoutCollapse.vue2.js +0 -4
- package/dist/components/ViewLayout/ViewLayoutContent.vue.js +0 -12
- package/dist/components/ViewLayout/ViewLayoutSection.vue.js +0 -23
- package/dist/components/ViewLayout/ViewLayoutSection.vue2.js +0 -4
- package/dist/constants.js +0 -40
- package/dist/data/httpHeaders.js +0 -537
- package/dist/hooks/useAnalytics.js +0 -11
- package/dist/hooks/useClientConfig.js +0 -7
- package/dist/hooks/useFileDialog.js +0 -21
- package/dist/hooks/useLayout.js +0 -8
- package/dist/hooks/useResponseBody.js +0 -20
- package/dist/hooks/useSidebar.js +0 -28
- package/dist/layouts/App/ApiClientApp.vue.js +0 -70
- package/dist/layouts/App/ApiClientApp.vue3.js +0 -5
- package/dist/layouts/App/MainLayout.vue.js +0 -26
- package/dist/layouts/App/MainLayout.vue2.js +0 -4
- package/dist/layouts/App/create-api-client-app.js +0 -35
- package/dist/layouts/App/hotkeys.js +0 -21
- package/dist/layouts/Modal/ApiClientModal.vue.js +0 -30
- package/dist/layouts/Modal/ApiClientModal.vue2.js +0 -4
- package/dist/layouts/Modal/create-api-client-modal.js +0 -32
- package/dist/layouts/Web/ApiClientWeb.vue.js +0 -64
- package/dist/layouts/Web/ApiClientWeb.vue3.js +0 -5
- package/dist/layouts/Web/create-api-client-web.js +0 -32
- package/dist/libs/create-client.js +0 -189
- package/dist/libs/electron.js +0 -4
- package/dist/libs/env-helpers.js +0 -6
- package/dist/libs/environment-parser.js +0 -18
- package/dist/libs/errors.js +0 -16
- package/dist/libs/event-bus.js +0 -32
- package/dist/libs/extractAttachmentFilename.js +0 -18
- package/dist/libs/find-request.js +0 -23
- package/dist/libs/formatters.js +0 -10
- package/dist/libs/get-request-uid-by-path-method.js +0 -18
- package/dist/libs/getOpenApiDocumentDetails.js +0 -40
- package/dist/libs/hot-keys.js +0 -44
- package/dist/libs/importers/curl.js +0 -53
- package/dist/libs/isUrl.js +0 -7
- package/dist/libs/local-storage.js +0 -41
- package/dist/libs/normalize-headers.js +0 -27
- package/dist/libs/parse-curl.js +0 -59
- package/dist/libs/postman.js +0 -37
- package/dist/libs/send-request/build-request-security.js +0 -35
- package/dist/libs/send-request/create-fetch-body.js +0 -25
- package/dist/libs/send-request/create-fetch-headers.js +0 -11
- package/dist/libs/send-request/create-fetch-query-params.js +0 -33
- package/dist/libs/send-request/create-request-operation.js +0 -140
- package/dist/libs/send-request/decode-buffer.js +0 -9
- package/dist/libs/send-request/set-request-cookies.js +0 -58
- package/dist/libs/string-template.js +0 -42
- package/dist/libs/validate-parameters.js +0 -16
- package/dist/plugins/hooks/usePluginManager.js +0 -10
- package/dist/plugins/plugin-manager.js +0 -26
- package/dist/routes.js +0 -210
- package/dist/store/active-entities.js +0 -118
- package/dist/store/collections.js +0 -73
- package/dist/store/cookies.js +0 -13
- package/dist/store/environment.js +0 -32
- package/dist/store/events.js +0 -35
- package/dist/store/import-spec.js +0 -55
- package/dist/store/request-example.js +0 -43
- package/dist/store/requests.js +0 -97
- package/dist/store/router-params.js +0 -22
- package/dist/store/security-schemes.js +0 -55
- package/dist/store/servers.js +0 -39
- package/dist/store/store.js +0 -144
- package/dist/store/tags.js +0 -45
- package/dist/store/workspace.js +0 -52
- package/dist/v2/blocks/operation-block/OperationBlock.vue.js +0 -242
- package/dist/v2/blocks/operation-block/OperationBlock.vue2.js +0 -4
- package/dist/v2/blocks/operation-block/components/Header.vue.js +0 -7
- package/dist/v2/blocks/operation-block/components/Header.vue2.js +0 -100
- package/dist/v2/blocks/operation-block/helpers/build-request-body.js +0 -40
- package/dist/v2/blocks/operation-block/helpers/build-request-cookie-header.js +0 -31
- package/dist/v2/blocks/operation-block/helpers/build-request-parameters.js +0 -107
- package/dist/v2/blocks/operation-block/helpers/build-request-security.js +0 -46
- package/dist/v2/blocks/operation-block/helpers/build-request.js +0 -70
- package/dist/v2/blocks/operation-block/helpers/de-serialize-parameter.js +0 -25
- package/dist/v2/blocks/operation-block/helpers/decode-buffer.js +0 -9
- package/dist/v2/blocks/operation-block/helpers/filter-global-cookies.js +0 -14
- package/dist/v2/blocks/operation-block/helpers/get-cookie-header-keys.js +0 -4
- package/dist/v2/blocks/operation-block/helpers/get-environment-variables.js +0 -7
- package/dist/v2/blocks/operation-block/helpers/get-example.js +0 -36
- package/dist/v2/blocks/operation-block/helpers/get-resolved-url.js +0 -17
- package/dist/v2/blocks/operation-block/helpers/get-selected-body-content-type.js +0 -4
- package/dist/v2/blocks/operation-block/helpers/get-server-url.js +0 -12
- package/dist/v2/blocks/operation-block/helpers/har-to-fetch-request.js +0 -31
- package/dist/v2/blocks/operation-block/helpers/har-to-fetch-response.js +0 -43
- package/dist/v2/blocks/operation-block/helpers/response-cache.js +0 -12
- package/dist/v2/blocks/operation-block/helpers/send-request.js +0 -122
- package/dist/v2/blocks/operation-block/helpers/serialize-parameter.js +0 -49
- package/dist/v2/blocks/operation-block/helpers/validate-path-parameters.js +0 -17
- package/dist/v2/blocks/operation-code-sample/components/ExamplePicker.vue.js +0 -56
- package/dist/v2/blocks/operation-code-sample/components/ExamplePicker.vue2.js +0 -4
- package/dist/v2/blocks/operation-code-sample/components/HttpMethod.vue.js +0 -30
- package/dist/v2/blocks/operation-code-sample/components/HttpMethod.vue2.js +0 -4
- package/dist/v2/blocks/operation-code-sample/components/OperationCodeSample.vue.js +0 -7
- package/dist/v2/blocks/operation-code-sample/components/OperationCodeSample.vue2.js +0 -227
- package/dist/v2/blocks/operation-code-sample/helpers/find-client.js +0 -22
- package/dist/v2/blocks/operation-code-sample/helpers/generate-client-options.js +0 -27
- package/dist/v2/blocks/operation-code-sample/helpers/generate-code-snippet.js +0 -40
- package/dist/v2/blocks/operation-code-sample/helpers/get-clients.js +0 -20
- package/dist/v2/blocks/operation-code-sample/helpers/get-custom-code-samples.js +0 -4
- package/dist/v2/blocks/operation-code-sample/helpers/get-example-from-schema.js +0 -302
- package/dist/v2/blocks/operation-code-sample/helpers/get-resolved-ref-deep.js +0 -28
- package/dist/v2/blocks/operation-code-sample/helpers/get-secrets.js +0 -10
- package/dist/v2/blocks/operation-code-sample/helpers/operation-to-har/operation-to-har.js +0 -67
- package/dist/v2/blocks/operation-code-sample/helpers/operation-to-har/process-body.js +0 -66
- package/dist/v2/blocks/operation-code-sample/helpers/operation-to-har/process-parameters.js +0 -172
- package/dist/v2/blocks/operation-code-sample/helpers/operation-to-har/process-security-schemes.js +0 -55
- package/dist/v2/blocks/operation-code-sample/helpers/operation-to-har/process-server-url.js +0 -18
- package/dist/v2/blocks/request-block/RequestBlock.vue.js +0 -7
- package/dist/v2/blocks/request-block/RequestBlock.vue2.js +0 -347
- package/dist/v2/blocks/request-block/components/RequestBody.vue.js +0 -7
- package/dist/v2/blocks/request-block/components/RequestBody.vue2.js +0 -191
- package/dist/v2/blocks/request-block/components/RequestBodyForm.vue.js +0 -84
- package/dist/v2/blocks/request-block/components/RequestBodyForm.vue2.js +0 -4
- package/dist/v2/blocks/request-block/components/RequestCodeSnippet.vue.js +0 -135
- package/dist/v2/blocks/request-block/components/RequestCodeSnippet.vue2.js +0 -4
- package/dist/v2/blocks/request-block/components/RequestParams.vue.js +0 -78
- package/dist/v2/blocks/request-block/components/RequestParams.vue2.js +0 -4
- package/dist/v2/blocks/request-block/components/RequestTable.vue.js +0 -7
- package/dist/v2/blocks/request-block/components/RequestTable.vue2.js +0 -74
- package/dist/v2/blocks/request-block/components/RequestTableRow.vue.js +0 -204
- package/dist/v2/blocks/request-block/components/RequestTableRow.vue2.js +0 -4
- package/dist/v2/blocks/request-block/components/RequestTableTooltip.vue.js +0 -7
- package/dist/v2/blocks/request-block/components/RequestTableTooltip.vue2.js +0 -63
- package/dist/v2/blocks/request-block/helpers/create-parameter-handlers.js +0 -55
- package/dist/v2/blocks/request-block/helpers/files.js +0 -7
- package/dist/v2/blocks/request-block/helpers/get-default-headers.js +0 -26
- package/dist/v2/blocks/request-block/helpers/get-form-body-rows.js +0 -29
- package/dist/v2/blocks/request-block/helpers/get-parameter-content.js +0 -9
- package/dist/v2/blocks/request-block/helpers/get-parameter-schema.js +0 -6
- package/dist/v2/blocks/request-block/helpers/get-request-body-example.js +0 -16
- package/dist/v2/blocks/request-block/helpers/group-by.js +0 -10
- package/dist/v2/blocks/request-block/helpers/is-param-disabled.js +0 -7
- package/dist/v2/blocks/request-block/helpers/validate-parameter.js +0 -32
- package/dist/v2/blocks/response-block/ResponseBlock.vue.js +0 -7
- package/dist/v2/blocks/response-block/ResponseBlock.vue2.js +0 -180
- package/dist/v2/blocks/response-block/components/Headers.vue.js +0 -96
- package/dist/v2/blocks/response-block/components/Headers.vue2.js +0 -4
- package/dist/v2/blocks/response-block/components/ResponseBody.vue.js +0 -7
- package/dist/v2/blocks/response-block/components/ResponseBody.vue2.js +0 -87
- package/dist/v2/blocks/response-block/components/ResponseBodyDownload.vue.js +0 -36
- package/dist/v2/blocks/response-block/components/ResponseBodyDownload.vue2.js +0 -4
- package/dist/v2/blocks/response-block/components/ResponseBodyInfo.vue.js +0 -14
- package/dist/v2/blocks/response-block/components/ResponseBodyPreview.vue.js +0 -7
- package/dist/v2/blocks/response-block/components/ResponseBodyPreview.vue2.js +0 -63
- package/dist/v2/blocks/response-block/components/ResponseBodyRaw.vue.js +0 -7
- package/dist/v2/blocks/response-block/components/ResponseBodyRaw.vue2.js +0 -41
- package/dist/v2/blocks/response-block/components/ResponseBodyStreaming.vue.js +0 -94
- package/dist/v2/blocks/response-block/components/ResponseBodyStreaming.vue2.js +0 -4
- package/dist/v2/blocks/response-block/components/ResponseBodyToggle.vue.js +0 -25
- package/dist/v2/blocks/response-block/components/ResponseBodyToggle.vue2.js +0 -4
- package/dist/v2/blocks/response-block/components/ResponseBodyVirtual.vue.js +0 -52
- package/dist/v2/blocks/response-block/components/ResponseBodyVirtual.vue3.js +0 -5
- package/dist/v2/blocks/response-block/components/ResponseCookies.vue.js +0 -54
- package/dist/v2/blocks/response-block/components/ResponseCookies.vue2.js +0 -4
- package/dist/v2/blocks/response-block/components/ResponseEmpty.vue.js +0 -7
- package/dist/v2/blocks/response-block/components/ResponseEmpty.vue2.js +0 -79
- package/dist/v2/blocks/response-block/components/ResponseLoadingOverlay.vue.js +0 -7
- package/dist/v2/blocks/response-block/components/ResponseLoadingOverlay.vue2.js +0 -46
- package/dist/v2/blocks/response-block/components/ResponseMetaInformation.vue.js +0 -67
- package/dist/v2/blocks/response-block/components/ResponseMetaInformation.vue2.js +0 -4
- package/dist/v2/blocks/response-block/helpers/extract-filename.js +0 -18
- package/dist/v2/blocks/response-block/helpers/get-content-length.js +0 -12
- package/dist/v2/blocks/response-block/helpers/media-types.js +0 -126
- package/dist/v2/blocks/response-block/helpers/parse-set-cookie.js +0 -12
- package/dist/v2/blocks/response-block/helpers/process-response-body.js +0 -16
- package/dist/v2/blocks/scalar-address-bar-block/components/AddressBar.vue.js +0 -7
- package/dist/v2/blocks/scalar-address-bar-block/components/AddressBar.vue2.js +0 -208
- package/dist/v2/blocks/scalar-address-bar-block/components/AddressBarHistory.vue.js +0 -7
- package/dist/v2/blocks/scalar-address-bar-block/components/AddressBarHistory.vue2.js +0 -95
- package/dist/v2/blocks/scalar-address-bar-block/components/EnvironmentSelector.vue.js +0 -145
- package/dist/v2/blocks/scalar-address-bar-block/components/EnvironmentSelector.vue2.js +0 -4
- package/dist/v2/blocks/scalar-address-bar-block/components/httpStatusCodeColors.js +0 -38
- package/dist/v2/blocks/scalar-address-bar-block/hooks/use-loading-animation.js +0 -25
- package/dist/v2/blocks/scalar-auth-selector-block/components/AuthSelector.vue.js +0 -184
- package/dist/v2/blocks/scalar-auth-selector-block/components/AuthSelector.vue2.js +0 -4
- package/dist/v2/blocks/scalar-auth-selector-block/components/DeleteRequestAuthModal.vue.js +0 -51
- package/dist/v2/blocks/scalar-auth-selector-block/components/DeleteRequestAuthModal.vue2.js +0 -4
- package/dist/v2/blocks/scalar-auth-selector-block/components/OAuth2.vue.js +0 -330
- package/dist/v2/blocks/scalar-auth-selector-block/components/OAuth2.vue2.js +0 -4
- package/dist/v2/blocks/scalar-auth-selector-block/components/OAuthScopesAddModal.vue.js +0 -7
- package/dist/v2/blocks/scalar-auth-selector-block/components/OAuthScopesAddModal.vue2.js +0 -76
- package/dist/v2/blocks/scalar-auth-selector-block/components/OAuthScopesInput.vue.js +0 -165
- package/dist/v2/blocks/scalar-auth-selector-block/components/OAuthScopesInput.vue3.js +0 -5
- package/dist/v2/blocks/scalar-auth-selector-block/components/OpenIDConnect.vue.js +0 -91
- package/dist/v2/blocks/scalar-auth-selector-block/components/OpenIDConnect.vue2.js +0 -4
- package/dist/v2/blocks/scalar-auth-selector-block/components/RequestAuthDataTable.vue.js +0 -83
- package/dist/v2/blocks/scalar-auth-selector-block/components/RequestAuthDataTable.vue2.js +0 -4
- package/dist/v2/blocks/scalar-auth-selector-block/components/RequestAuthDataTableInput.vue.js +0 -46
- package/dist/v2/blocks/scalar-auth-selector-block/components/RequestAuthDataTableInput.vue2.js +0 -4
- package/dist/v2/blocks/scalar-auth-selector-block/components/RequestAuthTab.vue.js +0 -244
- package/dist/v2/blocks/scalar-auth-selector-block/components/RequestAuthTab.vue2.js +0 -4
- package/dist/v2/blocks/scalar-auth-selector-block/helpers/auth-options.js +0 -97
- package/dist/v2/blocks/scalar-auth-selector-block/helpers/extract-security-scheme-secrets.js +0 -135
- package/dist/v2/blocks/scalar-auth-selector-block/helpers/fetch-openid-connect-discovery.js +0 -35
- package/dist/v2/blocks/scalar-auth-selector-block/helpers/is-auth-optional.js +0 -7
- package/dist/v2/blocks/scalar-auth-selector-block/helpers/merge-security.js +0 -23
- package/dist/v2/blocks/scalar-auth-selector-block/helpers/oauth.js +0 -139
- package/dist/v2/blocks/scalar-auth-selector-block/helpers/openid-discovery-to-flows.js +0 -27
- package/dist/v2/blocks/scalar-auth-selector-block/helpers/security-scheme.js +0 -64
- package/dist/v2/components/callout/Callout.vue.js +0 -7
- package/dist/v2/components/callout/Callout.vue2.js +0 -43
- package/dist/v2/components/code-input/CodeInput.vue.js +0 -8
- package/dist/v2/components/code-input/CodeInput.vue2.js +0 -213
- package/dist/v2/components/code-input/code-variable-widget.js +0 -106
- package/dist/v2/components/data-table/DataTable.vue.js +0 -38
- package/dist/v2/components/data-table/DataTable.vue2.js +0 -4
- package/dist/v2/components/data-table/DataTableCell.vue.js +0 -26
- package/dist/v2/components/data-table/DataTableCell.vue2.js +0 -4
- package/dist/v2/components/data-table/DataTableCheckbox.vue.js +0 -53
- package/dist/v2/components/data-table/DataTableCheckbox.vue2.js +0 -4
- package/dist/v2/components/data-table/DataTableHeader.vue.js +0 -18
- package/dist/v2/components/data-table/DataTableHeader.vue2.js +0 -4
- package/dist/v2/components/data-table/DataTableInput.vue.js +0 -7
- package/dist/v2/components/data-table/DataTableInput.vue2.js +0 -121
- package/dist/v2/components/data-table/DataTableInputSelect.vue.js +0 -149
- package/dist/v2/components/data-table/DataTableInputSelect.vue2.js +0 -4
- package/dist/v2/components/data-table/DataTableRow.vue.js +0 -12
- package/dist/v2/components/data-table/DataTableText.vue.js +0 -23
- package/dist/v2/components/data-table/DataTableText.vue2.js +0 -4
- package/dist/v2/components/forms/ConfirmationForm.vue.js +0 -45
- package/dist/v2/components/forms/ConfirmationForm.vue2.js +0 -4
- package/dist/v2/components/layout/CollapsibleSection.vue.js +0 -89
- package/dist/v2/components/layout/CollapsibleSection.vue2.js +0 -4
- package/dist/v2/components/layout/ValueEmitter.vue.js +0 -21
- package/dist/v2/components/layout/ValueEmitter.vue2.js +0 -4
- package/dist/v2/components/modals/DeleteModal.vue.js +0 -31
- package/dist/v2/components/modals/DeleteModal.vue2.js +0 -4
- package/dist/v2/components/modals/ModalClientContainer.vue.js +0 -7
- package/dist/v2/components/modals/ModalClientContainer.vue2.js +0 -60
- package/dist/v2/components/resize/Resize.vue.js +0 -8
- package/dist/v2/components/resize/Resize.vue2.js +0 -36
- package/dist/v2/components/resize/use-split-resize.js +0 -57
- package/dist/v2/components/server/ServerDropdown.vue.js +0 -91
- package/dist/v2/components/server/ServerDropdown.vue2.js +0 -4
- package/dist/v2/components/server/ServerDropdownItem.vue.js +0 -7
- package/dist/v2/components/server/ServerDropdownItem.vue2.js +0 -49
- package/dist/v2/components/sidebar/Sidebar.vue.js +0 -115
- package/dist/v2/components/sidebar/Sidebar.vue2.js +0 -4
- package/dist/v2/components/sidebar/SidebarMenu.vue.js +0 -52
- package/dist/v2/components/sidebar/SidebarMenu.vue2.js +0 -4
- package/dist/v2/components/sidebar/SidebarToggle.vue.js +0 -52
- package/dist/v2/components/sidebar/SidebarToggle.vue2.js +0 -4
- package/dist/v2/features/app/App.vue.js +0 -152
- package/dist/v2/features/app/App.vue3.js +0 -5
- package/dist/v2/features/app/app-events.js +0 -251
- package/dist/v2/features/app/app-state.js +0 -415
- package/dist/v2/features/app/components/AppSidebar.vue.js +0 -7
- package/dist/v2/features/app/components/AppSidebar.vue2.js +0 -304
- package/dist/v2/features/app/components/CreateWorkspaceModal.vue.js +0 -56
- package/dist/v2/features/app/components/CreateWorkspaceModal.vue2.js +0 -4
- package/dist/v2/features/app/components/DesktopTab.vue.js +0 -7
- package/dist/v2/features/app/components/DesktopTab.vue2.js +0 -134
- package/dist/v2/features/app/components/DesktopTabs.vue.js +0 -56
- package/dist/v2/features/app/components/DesktopTabs.vue2.js +0 -4
- package/dist/v2/features/app/components/DownloadAppButton.vue.js +0 -7
- package/dist/v2/features/app/components/DownloadAppButton.vue2.js +0 -19
- package/dist/v2/features/app/components/SidebarItemMenu.vue.js +0 -185
- package/dist/v2/features/app/components/SidebarItemMenu.vue2.js +0 -4
- package/dist/v2/features/app/components/SplashScreen.vue.js +0 -7
- package/dist/v2/features/app/components/SplashScreen.vue2.js +0 -18
- package/dist/v2/features/app/helpers/create-api-client-app.js +0 -36
- package/dist/v2/features/app/helpers/filter-workspaces.js +0 -5
- package/dist/v2/features/app/helpers/get-route-param.js +0 -9
- package/dist/v2/features/app/helpers/group-workspaces.js +0 -23
- package/dist/v2/features/app/helpers/routes.js +0 -157
- package/dist/v2/features/app/hooks/use-document-watcher.js +0 -66
- package/dist/v2/features/app/hooks/use-theme.js +0 -48
- package/dist/v2/features/collection/DocumentCollection.vue.js +0 -336
- package/dist/v2/features/collection/DocumentCollection.vue3.js +0 -5
- package/dist/v2/features/collection/OperationCollection.vue.js +0 -86
- package/dist/v2/features/collection/OperationCollection.vue2.js +0 -4
- package/dist/v2/features/collection/WorkspaceCollection.vue.js +0 -68
- package/dist/v2/features/collection/WorkspaceCollection.vue2.js +0 -4
- package/dist/v2/features/collection/components/Authentication.vue.js +0 -7
- package/dist/v2/features/collection/components/Authentication.vue2.js +0 -154
- package/dist/v2/features/collection/components/Cookies.vue.js +0 -52
- package/dist/v2/features/collection/components/Cookies.vue2.js +0 -4
- package/dist/v2/features/collection/components/Editor/Editor.vue.js +0 -7
- package/dist/v2/features/collection/components/Editor/Editor.vue2.js +0 -344
- package/dist/v2/features/collection/components/Editor/components/EditorDiagnosticsPanel.vue.js +0 -78
- package/dist/v2/features/collection/components/Editor/components/EditorDiagnosticsPanel.vue2.js +0 -4
- package/dist/v2/features/collection/components/Editor/components/EditorSavePanel.vue.js +0 -83
- package/dist/v2/features/collection/components/Editor/components/EditorSavePanel.vue2.js +0 -4
- package/dist/v2/features/collection/components/Editor/helpers/get-diagnostic-counts.js +0 -10
- package/dist/v2/features/collection/components/Editor/helpers/get-operation-context.js +0 -5
- package/dist/v2/features/collection/components/Editor/helpers/get-visible-diagnostics.js +0 -5
- package/dist/v2/features/collection/components/Editor/helpers/parse-editor-object.js +0 -21
- package/dist/v2/features/collection/components/Editor/helpers/stringify-document.js +0 -5
- package/dist/v2/features/collection/components/Editor/hooks/use-editor-state.js +0 -25
- package/dist/v2/features/collection/components/Environment.vue.js +0 -54
- package/dist/v2/features/collection/components/Environment.vue2.js +0 -4
- package/dist/v2/features/collection/components/Form.vue.js +0 -78
- package/dist/v2/features/collection/components/Form.vue2.js +0 -4
- package/dist/v2/features/collection/components/LabelInput.vue.js +0 -7
- package/dist/v2/features/collection/components/LabelInput.vue2.js +0 -35
- package/dist/v2/features/collection/components/Overview.vue.js +0 -7
- package/dist/v2/features/collection/components/Overview.vue2.js +0 -208
- package/dist/v2/features/collection/components/Servers.vue.js +0 -210
- package/dist/v2/features/collection/components/Servers.vue2.js +0 -4
- package/dist/v2/features/collection/components/Settings.vue.js +0 -61
- package/dist/v2/features/collection/components/Settings.vue2.js +0 -4
- package/dist/v2/features/collection/components/SyncConflictResolutionEditor.vue.js +0 -7
- package/dist/v2/features/collection/components/SyncConflictResolutionEditor.vue2.js +0 -136
- package/dist/v2/features/collection/components/Tabs.vue.js +0 -44
- package/dist/v2/features/collection/components/Tabs.vue2.js +0 -4
- package/dist/v2/features/collection/helpers/get-default-operation-security-toggle.js +0 -13
- package/dist/v2/features/command-palette/TheCommandPalette.vue.js +0 -7
- package/dist/v2/features/command-palette/TheCommandPalette.vue2.js +0 -152
- package/dist/v2/features/command-palette/components/CommandActionForm.vue.js +0 -48
- package/dist/v2/features/command-palette/components/CommandActionForm.vue2.js +0 -4
- package/dist/v2/features/command-palette/components/CommandActionInput.vue.js +0 -52
- package/dist/v2/features/command-palette/components/CommandActionInput.vue2.js +0 -4
- package/dist/v2/features/command-palette/components/CommandPaletteExample.vue.js +0 -211
- package/dist/v2/features/command-palette/components/CommandPaletteExample.vue2.js +0 -4
- package/dist/v2/features/command-palette/components/CommandPaletteImport.vue.js +0 -182
- package/dist/v2/features/command-palette/components/CommandPaletteImport.vue2.js +0 -4
- package/dist/v2/features/command-palette/components/CommandPaletteImportCurl.vue.js +0 -7
- package/dist/v2/features/command-palette/components/CommandPaletteImportCurl.vue2.js +0 -115
- package/dist/v2/features/command-palette/components/CommandPaletteOpenApiDocument.vue.js +0 -78
- package/dist/v2/features/command-palette/components/CommandPaletteOpenApiDocument.vue2.js +0 -4
- package/dist/v2/features/command-palette/components/CommandPaletteRequest.vue.js +0 -221
- package/dist/v2/features/command-palette/components/CommandPaletteRequest.vue2.js +0 -4
- package/dist/v2/features/command-palette/components/CommandPaletteTag.vue.js +0 -114
- package/dist/v2/features/command-palette/components/CommandPaletteTag.vue2.js +0 -4
- package/dist/v2/features/command-palette/components/WatchModeToggle.vue.js +0 -40
- package/dist/v2/features/command-palette/components/WatchModeToggle.vue2.js +0 -4
- package/dist/v2/features/command-palette/helpers/generate-unique-slug.js +0 -11
- package/dist/v2/features/command-palette/helpers/get-openapi-document-details.js +0 -31
- package/dist/v2/features/command-palette/helpers/get-openapi-from-postman.js +0 -11
- package/dist/v2/features/command-palette/helpers/get-operation-from-curl.js +0 -76
- package/dist/v2/features/command-palette/helpers/get-postman-document-details.js +0 -18
- package/dist/v2/features/command-palette/helpers/import-document-to-workspace.js +0 -33
- package/dist/v2/features/command-palette/helpers/is-postman-collection.js +0 -11
- package/dist/v2/features/command-palette/helpers/load-document-from-source.js +0 -52
- package/dist/v2/features/command-palette/hooks/use-command-palette-state.js +0 -139
- package/dist/v2/features/editor/config.js +0 -16
- package/dist/v2/features/editor/helpers/configure-language-support.js +0 -39
- package/dist/v2/features/editor/helpers/ensure-monaco-environment.js +0 -20
- package/dist/v2/features/editor/helpers/json/create-json-model.js +0 -19
- package/dist/v2/features/editor/helpers/json/get-json-ast-node-from-path.js +0 -9
- package/dist/v2/features/editor/helpers/json/json-ast.js +0 -24
- package/dist/v2/features/editor/helpers/json/json-pointer-links.js +0 -72
- package/dist/v2/features/editor/helpers/json/json-pointer-path.js +0 -21
- package/dist/v2/features/editor/helpers/range-to-whole-line.js +0 -8
- package/dist/v2/features/editor/helpers/theme/apply-scalar-theme.js +0 -56
- package/dist/v2/features/editor/helpers/theme/load-css-variables.js +0 -21
- package/dist/v2/features/editor/helpers/yaml/create-yaml-model.js +0 -19
- package/dist/v2/features/editor/helpers/yaml/get-yaml-node-range-from-path.js +0 -50
- package/dist/v2/features/editor/hooks/use-editor-markers.js +0 -34
- package/dist/v2/features/editor/hooks/use-editor.js +0 -107
- package/dist/v2/features/editor/hooks/use-json-pointer-link-support.js +0 -27
- package/dist/v2/features/editor/hooks/use-three-way-merge-editor.js +0 -316
- package/dist/v2/features/editor/schemas/openapi-3.1-schema.json.js +0 -25
- package/dist/v2/features/environments/EnvironmentsList.vue.js +0 -68
- package/dist/v2/features/environments/EnvironmentsList.vue2.js +0 -4
- package/dist/v2/features/environments/components/Environment.vue.js +0 -66
- package/dist/v2/features/environments/components/Environment.vue2.js +0 -4
- package/dist/v2/features/environments/components/EnvironmentColors.vue.js +0 -121
- package/dist/v2/features/environments/components/EnvironmentColors.vue2.js +0 -4
- package/dist/v2/features/environments/components/EnvironmentCreateModal.vue.js +0 -85
- package/dist/v2/features/environments/components/EnvironmentCreateModal.vue2.js +0 -4
- package/dist/v2/features/environments/components/EnvironmentDeleteModal.vue.js +0 -53
- package/dist/v2/features/environments/components/EnvironmentDeleteModal.vue2.js +0 -4
- package/dist/v2/features/environments/components/EnvironmentVariablesDropdown.vue.js +0 -109
- package/dist/v2/features/environments/components/EnvironmentVariablesDropdown.vue2.js +0 -4
- package/dist/v2/features/environments/components/EnvironmentVariablesTable.vue.js +0 -7
- package/dist/v2/features/environments/components/EnvironmentVariablesTable.vue2.js +0 -136
- package/dist/v2/features/global-cookies/components/CookiesTable.vue.js +0 -7
- package/dist/v2/features/global-cookies/components/CookiesTable.vue2.js +0 -189
- package/dist/v2/features/modal/Modal.vue.js +0 -122
- package/dist/v2/features/modal/Modal.vue2.js +0 -4
- package/dist/v2/features/modal/helpers/create-api-client-modal.js +0 -89
- package/dist/v2/features/modal/helpers/map-hidden-clients-config.js +0 -36
- package/dist/v2/features/modal/helpers/resolve-route-parameters.js +0 -29
- package/dist/v2/features/modal/helpers/restore-workspace-state.js +0 -36
- package/dist/v2/features/modal/hooks/use-modal-sidebar.js +0 -93
- package/dist/v2/features/modal/modal-events.js +0 -44
- package/dist/v2/features/operation/Operation.vue.js +0 -126
- package/dist/v2/features/operation/Operation.vue2.js +0 -4
- package/dist/v2/features/operation/helpers/combine-params.js +0 -14
- package/dist/v2/features/operation/helpers/get-security-requirements.js +0 -4
- package/dist/v2/features/operation/helpers/get-selected-security.js +0 -18
- package/dist/v2/features/operation/helpers/get-selected-server.js +0 -4
- package/dist/v2/features/search/helpers/create-fuse-instance.js +0 -43
- package/dist/v2/features/search/helpers/create-search-index.js +0 -63
- package/dist/v2/features/search/hooks/use-search-index.js +0 -18
- package/dist/v2/features/settings/CollectionSettings.vue.js +0 -275
- package/dist/v2/features/settings/CollectionSettings.vue2.js +0 -4
- package/dist/v2/features/settings/DocumentSettings.vue.js +0 -115
- package/dist/v2/features/settings/DocumentSettings.vue2.js +0 -4
- package/dist/v2/features/settings/components/Appearance.vue.js +0 -88
- package/dist/v2/features/settings/components/Appearance.vue2.js +0 -4
- package/dist/v2/features/settings/components/Section.vue.js +0 -35
- package/dist/v2/features/settings/components/Section.vue2.js +0 -4
- package/dist/v2/features/settings/helpers/get-theme-colors.js +0 -16
- package/dist/v2/helpers/drag-handle-factory.js +0 -120
- package/dist/v2/helpers/generate-location-id.js +0 -10
- package/dist/v2/helpers/get-active-environment.js +0 -22
- package/dist/v2/helpers/get-active-proxy-url.js +0 -5
- package/dist/v2/helpers/get-servers.js +0 -66
- package/dist/v2/helpers/get-tab-details.js +0 -34
- package/dist/v2/helpers/handle-hotkeys.js +0 -54
- package/dist/v2/helpers/is-url.js +0 -5
- package/dist/v2/helpers/slugify.js +0 -4
- package/dist/v2/helpers/storage.js +0 -16
- package/dist/v2/hooks/use-color-mode.js +0 -24
- package/dist/v2/hooks/use-global-hot-keys.js +0 -11
- package/dist/v2/hooks/use-scroll-lock.js +0 -21
- package/dist/v2/workspace-events.js +0 -252
- package/dist/views/Collection/Collection.vue.js +0 -4
- package/dist/views/Collection/Collection.vue2.js +0 -49
- package/dist/views/Collection/CollectionAuthentication.vue.js +0 -7
- package/dist/views/Collection/CollectionAuthentication.vue2.js +0 -56
- package/dist/views/Collection/CollectionCookies.vue.js +0 -4
- package/dist/views/Collection/CollectionCookies.vue2.js +0 -16
- package/dist/views/Collection/CollectionEnvironment.vue.js +0 -5
- package/dist/views/Collection/CollectionEnvironment.vue2.js +0 -229
- package/dist/views/Collection/CollectionInfoForm.vue.js +0 -7
- package/dist/views/Collection/CollectionInfoForm.vue2.js +0 -63
- package/dist/views/Collection/CollectionNavigation.vue.js +0 -133
- package/dist/views/Collection/CollectionNavigation.vue2.js +0 -4
- package/dist/views/Collection/CollectionOverview.vue.js +0 -4
- package/dist/views/Collection/CollectionOverview.vue2.js +0 -34
- package/dist/views/Collection/CollectionScripts.vue.js +0 -4
- package/dist/views/Collection/CollectionScripts.vue2.js +0 -16
- package/dist/views/Collection/CollectionServerForm.vue.js +0 -75
- package/dist/views/Collection/CollectionServerForm.vue2.js +0 -4
- package/dist/views/Collection/CollectionServers.vue.js +0 -4
- package/dist/views/Collection/CollectionServers.vue2.js +0 -94
- package/dist/views/Collection/CollectionSettings.vue.js +0 -4
- package/dist/views/Collection/CollectionSettings.vue2.js +0 -118
- package/dist/views/Collection/CollectionSync.vue.js +0 -4
- package/dist/views/Collection/CollectionSync.vue2.js +0 -16
- package/dist/views/Collection/components/EnvironmentForm.vue.js +0 -7
- package/dist/views/Collection/components/EnvironmentForm.vue2.js +0 -270
- package/dist/views/Collection/components/MarkdownInput.vue.js +0 -7
- package/dist/views/Collection/components/MarkdownInput.vue2.js +0 -100
- package/dist/views/Components/CodeSnippet/CodeSnippet.vue.js +0 -50
- package/dist/views/Components/CodeSnippet/CodeSnippet.vue2.js +0 -4
- package/dist/views/Components/CodeSnippet/helpers/convert-to-har-request.js +0 -62
- package/dist/views/Components/CodeSnippet/helpers/get-har-request.js +0 -82
- package/dist/views/Components/CodeSnippet/helpers/get-snippet.js +0 -30
- package/dist/views/Cookies/CookieForm.vue.js +0 -34
- package/dist/views/Cookies/CookieForm.vue2.js +0 -4
- package/dist/views/Cookies/CookieModal.vue.js +0 -7
- package/dist/views/Cookies/CookieModal.vue2.js +0 -88
- package/dist/views/Cookies/Cookies.vue.js +0 -4
- package/dist/views/Cookies/Cookies.vue2.js +0 -162
- package/dist/views/Environment/Environment.vue.js +0 -4
- package/dist/views/Environment/Environment.vue2.js +0 -402
- package/dist/views/Environment/EnvironmentColorModal.vue.js +0 -42
- package/dist/views/Environment/EnvironmentColorModal.vue2.js +0 -4
- package/dist/views/Environment/EnvironmentColors.vue.js +0 -118
- package/dist/views/Environment/EnvironmentColors.vue2.js +0 -4
- package/dist/views/Environment/EnvironmentModal.vue.js +0 -131
- package/dist/views/Environment/EnvironmentModal.vue2.js +0 -4
- package/dist/views/Environment/EnvironmentVariableDropdown.vue.js +0 -129
- package/dist/views/Environment/EnvironmentVariableDropdown.vue2.js +0 -4
- package/dist/views/Environment/handle-drag.js +0 -32
- package/dist/views/Request/Request.vue.js +0 -7
- package/dist/views/Request/Request.vue2.js +0 -105
- package/dist/views/Request/RequestRoot.vue.js +0 -7
- package/dist/views/Request/RequestRoot.vue2.js +0 -123
- package/dist/views/Request/RequestSection/RequestAuth/DeleteRequestAuthModal.vue.js +0 -52
- package/dist/views/Request/RequestSection/RequestAuth/DeleteRequestAuthModal.vue2.js +0 -4
- package/dist/views/Request/RequestSection/RequestAuth/OAuth2.vue.js +0 -246
- package/dist/views/Request/RequestSection/RequestAuth/OAuth2.vue2.js +0 -4
- package/dist/views/Request/RequestSection/RequestAuth/OAuthScopesInput.vue.js +0 -135
- package/dist/views/Request/RequestSection/RequestAuth/OAuthScopesInput.vue2.js +0 -4
- package/dist/views/Request/RequestSection/RequestAuth/RequestAuth.vue.js +0 -7
- package/dist/views/Request/RequestSection/RequestAuth/RequestAuth.vue2.js +0 -209
- package/dist/views/Request/RequestSection/RequestAuth/RequestAuthDataTable.vue.js +0 -7
- package/dist/views/Request/RequestSection/RequestAuth/RequestAuthDataTable.vue2.js +0 -116
- package/dist/views/Request/RequestSection/RequestAuth/RequestAuthDataTableInput.vue.js +0 -50
- package/dist/views/Request/RequestSection/RequestAuth/RequestAuthDataTableInput.vue2.js +0 -4
- package/dist/views/Request/RequestSection/RequestAuth/RequestAuthTab.vue.js +0 -219
- package/dist/views/Request/RequestSection/RequestAuth/RequestAuthTab.vue2.js +0 -4
- package/dist/views/Request/RequestSection/RequestAuth/helpers/restore-auth-from-local-storage.js +0 -28
- package/dist/views/Request/RequestSection/RequestBody.vue.js +0 -7
- package/dist/views/Request/RequestSection/RequestBody.vue2.js +0 -451
- package/dist/views/Request/RequestSection/RequestCodeExample.vue.js +0 -7
- package/dist/views/Request/RequestSection/RequestCodeExample.vue2.js +0 -170
- package/dist/views/Request/RequestSection/RequestParams.vue.js +0 -162
- package/dist/views/Request/RequestSection/RequestParams.vue2.js +0 -4
- package/dist/views/Request/RequestSection/RequestPathParams.vue.js +0 -96
- package/dist/views/Request/RequestSection/RequestPathParams.vue2.js +0 -4
- package/dist/views/Request/RequestSection/RequestSection.vue.js +0 -7
- package/dist/views/Request/RequestSection/RequestSection.vue2.js +0 -247
- package/dist/views/Request/RequestSection/RequestTable.vue.js +0 -7
- package/dist/views/Request/RequestSection/RequestTable.vue2.js +0 -227
- package/dist/views/Request/RequestSection/RequestTableTooltip.vue.js +0 -7
- package/dist/views/Request/RequestSection/RequestTableTooltip.vue2.js +0 -61
- package/dist/views/Request/RequestSection/helpers/filter-security-requirements.js +0 -29
- package/dist/views/Request/RequestSection/helpers/getting-started.js +0 -13
- package/dist/views/Request/RequestSection/helpers/update-scheme.js +0 -16
- package/dist/views/Request/RequestSidebar.vue.js +0 -7
- package/dist/views/Request/RequestSidebar.vue2.js +0 -341
- package/dist/views/Request/RequestSidebarItem.vue.js +0 -8
- package/dist/views/Request/RequestSidebarItem.vue2.js +0 -464
- package/dist/views/Request/RequestSidebarItemMenu.vue.js +0 -7
- package/dist/views/Request/RequestSidebarItemMenu.vue2.js +0 -236
- package/dist/views/Request/RequestSubpageHeader.vue.js +0 -7
- package/dist/views/Request/RequestSubpageHeader.vue2.js +0 -79
- package/dist/views/Request/ResponseSection/RequestHeaders.vue.js +0 -96
- package/dist/views/Request/ResponseSection/RequestHeaders.vue2.js +0 -4
- package/dist/views/Request/ResponseSection/ResponseBody.vue.js +0 -7
- package/dist/views/Request/ResponseSection/ResponseBody.vue2.js +0 -83
- package/dist/views/Request/ResponseSection/ResponseBodyDownload.vue.js +0 -36
- package/dist/views/Request/ResponseSection/ResponseBodyDownload.vue2.js +0 -4
- package/dist/views/Request/ResponseSection/ResponseBodyInfo.vue.js +0 -14
- package/dist/views/Request/ResponseSection/ResponseBodyPreview.vue.js +0 -7
- package/dist/views/Request/ResponseSection/ResponseBodyPreview.vue2.js +0 -63
- package/dist/views/Request/ResponseSection/ResponseBodyRaw.vue.js +0 -7
- package/dist/views/Request/ResponseSection/ResponseBodyRaw.vue2.js +0 -42
- package/dist/views/Request/ResponseSection/ResponseBodyStreaming.vue.js +0 -74
- package/dist/views/Request/ResponseSection/ResponseBodyStreaming.vue2.js +0 -4
- package/dist/views/Request/ResponseSection/ResponseBodyToggle.vue.js +0 -25
- package/dist/views/Request/ResponseSection/ResponseBodyToggle.vue2.js +0 -4
- package/dist/views/Request/ResponseSection/ResponseBodyVirtual.vue.js +0 -50
- package/dist/views/Request/ResponseSection/ResponseBodyVirtual.vue3.js +0 -5
- package/dist/views/Request/ResponseSection/ResponseCookies.vue.js +0 -51
- package/dist/views/Request/ResponseSection/ResponseCookies.vue2.js +0 -4
- package/dist/views/Request/ResponseSection/ResponseEmpty.vue.js +0 -7
- package/dist/views/Request/ResponseSection/ResponseEmpty.vue2.js +0 -103
- package/dist/views/Request/ResponseSection/ResponseHeaders.vue.js +0 -96
- package/dist/views/Request/ResponseSection/ResponseHeaders.vue2.js +0 -4
- package/dist/views/Request/ResponseSection/ResponseLoadingOverlay.vue.js +0 -7
- package/dist/views/Request/ResponseSection/ResponseLoadingOverlay.vue2.js +0 -38
- package/dist/views/Request/ResponseSection/ResponseMetaInformation.vue.js +0 -67
- package/dist/views/Request/ResponseSection/ResponseMetaInformation.vue2.js +0 -4
- package/dist/views/Request/ResponseSection/ResponseSection.vue.js +0 -7
- package/dist/views/Request/ResponseSection/ResponseSection.vue2.js +0 -189
- package/dist/views/Request/components/WorkspaceDropdown.vue.js +0 -182
- package/dist/views/Request/components/WorkspaceDropdown.vue2.js +0 -4
- package/dist/views/Request/consts/mediaTypes.js +0 -131
- package/dist/views/Request/consts/new-auth-options.js +0 -100
- package/dist/views/Request/handle-drag.js +0 -42
- package/dist/views/Request/hooks/useOpenApiWatcher.js +0 -57
- package/dist/views/Request/libs/auth.js +0 -52
- package/dist/views/Request/libs/oauth2.js +0 -127
- package/dist/views/Request/libs/request.js +0 -40
- package/dist/views/Request/libs/watch-mode.js +0 -337
- package/dist/views/Settings/Settings.vue.js +0 -4
- package/dist/views/Settings/Settings.vue2.js +0 -29
- package/dist/views/Settings/SettingsGeneral.vue.js +0 -286
- package/dist/views/Settings/SettingsGeneral.vue2.js +0 -4
- package/dist/views/Settings/components/SettingsAppearance.vue.js +0 -85
- package/dist/views/Settings/components/SettingsAppearance.vue2.js +0 -4
- package/dist/views/Settings/components/SettingsSection.vue.js +0 -24
- package/dist/views/Settings/components/SettingsSection.vue2.js +0 -4
|
@@ -0,0 +1,775 @@
|
|
|
1
|
+
import { t as _plugin_vue_export_helper_default } from "./_plugin-vue_export-helper-BmmBcIzD.js";
|
|
2
|
+
import { Fragment, computed, createApp, createBlock, createCommentVNode, createElementBlock, createElementVNode, createTextVNode, createVNode, defineComponent, h, mergeProps, nextTick, normalizeClass, normalizeStyle, onMounted, openBlock, ref, renderList, renderSlot, toDisplayString, toRef, unref, useAttrs, vModelText, watch, withCtx, withDirectives, withKeys, withModifiers } from "vue";
|
|
3
|
+
import { ScalarButton, ScalarComboboxMultiselect, ScalarDropdown, ScalarDropdownDivider, ScalarDropdownItem, ScalarIcon, ScalarTeleport, ScalarTooltip } from "@scalar/components";
|
|
4
|
+
import { isDefined } from "@scalar/helpers/array/is-defined";
|
|
5
|
+
import { ScalarIconPlus } from "@scalar/icons";
|
|
6
|
+
import { Decoration, EditorView, RangeSetBuilder, ViewPlugin, WidgetType, colorPicker, useCodeMirror, useDropdown } from "@scalar/use-codemirror";
|
|
7
|
+
import { nanoid } from "nanoid";
|
|
8
|
+
import { onClickOutside } from "@vueuse/core";
|
|
9
|
+
import Fuse from "fuse.js";
|
|
10
|
+
import { REGEX } from "@scalar/helpers/regex/regex-helpers";
|
|
11
|
+
//#region src/v2/components/data-table/DataTableInputSelect.vue?vue&type=script&setup=true&lang.ts
|
|
12
|
+
var _hoisted_1$2 = { class: "group-[.alert]:outline-orange group-[.error]:outline-red w-full pr-10 -outline-offset-1 has-[:focus-visible]:rounded-[4px] has-[:focus-visible]:outline" };
|
|
13
|
+
var _hoisted_2$2 = { class: "text-c-1 whitespace-nowrap" };
|
|
14
|
+
var _hoisted_3$2 = { class: "text-c-1 overflow-hidden text-ellipsis" };
|
|
15
|
+
var _hoisted_4$2 = { class: "overflow-hidden text-ellipsis" };
|
|
16
|
+
var _hoisted_5$1 = { class: "flex h-4 w-4 items-center justify-center" };
|
|
17
|
+
//#endregion
|
|
18
|
+
//#region src/v2/components/data-table/DataTableInputSelect.vue
|
|
19
|
+
var DataTableInputSelect_default = /* @__PURE__ */ defineComponent({
|
|
20
|
+
__name: "DataTableInputSelect",
|
|
21
|
+
props: {
|
|
22
|
+
modelValue: { type: [
|
|
23
|
+
String,
|
|
24
|
+
Number,
|
|
25
|
+
Boolean,
|
|
26
|
+
Array,
|
|
27
|
+
Object
|
|
28
|
+
] },
|
|
29
|
+
value: {},
|
|
30
|
+
default: { type: [
|
|
31
|
+
String,
|
|
32
|
+
Number,
|
|
33
|
+
Boolean,
|
|
34
|
+
Array,
|
|
35
|
+
Object
|
|
36
|
+
] },
|
|
37
|
+
canAddCustomValue: {
|
|
38
|
+
type: Boolean,
|
|
39
|
+
default: true
|
|
40
|
+
},
|
|
41
|
+
type: {}
|
|
42
|
+
},
|
|
43
|
+
emits: ["update:modelValue"],
|
|
44
|
+
setup(__props, { emit: __emit }) {
|
|
45
|
+
const props = __props;
|
|
46
|
+
const emit = __emit;
|
|
47
|
+
const options = computed(() => props.value ?? []);
|
|
48
|
+
const addingCustomValue = ref(false);
|
|
49
|
+
const customValue = ref("");
|
|
50
|
+
const inputRef = ref(null);
|
|
51
|
+
watch(customValue, (newValue) => {
|
|
52
|
+
emit("update:modelValue", newValue);
|
|
53
|
+
});
|
|
54
|
+
const updateSelected = (value) => {
|
|
55
|
+
emit("update:modelValue", value);
|
|
56
|
+
addingCustomValue.value = false;
|
|
57
|
+
};
|
|
58
|
+
const addCustomValue = () => {
|
|
59
|
+
if (customValue.value.trim()) updateSelected(customValue.value);
|
|
60
|
+
};
|
|
61
|
+
const handleBlur = () => {
|
|
62
|
+
if (!customValue.value.trim()) emit("update:modelValue", "");
|
|
63
|
+
addingCustomValue.value = false;
|
|
64
|
+
};
|
|
65
|
+
const isSelected = (value) => {
|
|
66
|
+
return props.modelValue.toString() === value;
|
|
67
|
+
};
|
|
68
|
+
watch(addingCustomValue, (newValue) => {
|
|
69
|
+
if (newValue) nextTick(() => {
|
|
70
|
+
inputRef.value?.focus();
|
|
71
|
+
});
|
|
72
|
+
});
|
|
73
|
+
const initialValue = computed(() => {
|
|
74
|
+
return props.modelValue !== void 0 ? props.modelValue : props.default;
|
|
75
|
+
});
|
|
76
|
+
/** Options for the array type */
|
|
77
|
+
const arrayOptions = computed(() => options.value.map((option) => {
|
|
78
|
+
const id = option.toString();
|
|
79
|
+
return {
|
|
80
|
+
id,
|
|
81
|
+
label: id,
|
|
82
|
+
value: id
|
|
83
|
+
};
|
|
84
|
+
}));
|
|
85
|
+
/** Filter the options by what is selected */
|
|
86
|
+
const selectedArrayOptions = computed(() => {
|
|
87
|
+
const selectedValues = new Set(props.modelValue.toString().split(","));
|
|
88
|
+
return arrayOptions.value.filter((option) => selectedValues.has(option.id));
|
|
89
|
+
});
|
|
90
|
+
/** Update the model value when the selected options change */
|
|
91
|
+
const updateSelectedOptions = (selectedOptions) => {
|
|
92
|
+
emit("update:modelValue", selectedOptions.map((option) => option.value).join(","));
|
|
93
|
+
};
|
|
94
|
+
return (_ctx, _cache) => {
|
|
95
|
+
return openBlock(), createElementBlock("div", _hoisted_1$2, [__props.type === "array" ? (openBlock(), createBlock(unref(ScalarComboboxMultiselect), {
|
|
96
|
+
key: 0,
|
|
97
|
+
modelValue: selectedArrayOptions.value,
|
|
98
|
+
options: arrayOptions.value,
|
|
99
|
+
"onUpdate:modelValue": updateSelectedOptions
|
|
100
|
+
}, {
|
|
101
|
+
default: withCtx(() => [createVNode(unref(ScalarButton), {
|
|
102
|
+
class: "custom-scroll h-full justify-start gap-1.5 px-2 py-1.5 pr-6 font-normal outline-none",
|
|
103
|
+
fullWidth: "",
|
|
104
|
+
variant: "ghost"
|
|
105
|
+
}, {
|
|
106
|
+
default: withCtx(() => [createElementVNode("span", _hoisted_2$2, toDisplayString(selectedArrayOptions.value.length > 0 ? selectedArrayOptions.value.map((option) => option.label).join(", ") : "Select a value"), 1), createVNode(unref(ScalarIcon), {
|
|
107
|
+
class: "min-w-4",
|
|
108
|
+
icon: "ChevronDown",
|
|
109
|
+
size: "md"
|
|
110
|
+
})]),
|
|
111
|
+
_: 1
|
|
112
|
+
})]),
|
|
113
|
+
_: 1
|
|
114
|
+
}, 8, ["modelValue", "options"])) : addingCustomValue.value ? withDirectives((openBlock(), createElementBlock("input", {
|
|
115
|
+
key: 1,
|
|
116
|
+
ref_key: "inputRef",
|
|
117
|
+
ref: inputRef,
|
|
118
|
+
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => customValue.value = $event),
|
|
119
|
+
class: "text-c-1 w-full min-w-0 border-none px-2 py-1.5 outline-none",
|
|
120
|
+
placeholder: "Value",
|
|
121
|
+
type: "text",
|
|
122
|
+
onBlur: handleBlur,
|
|
123
|
+
onKeyup: withKeys(addCustomValue, ["enter"])
|
|
124
|
+
}, null, 544)), [[vModelText, customValue.value]]) : (openBlock(), createBlock(unref(ScalarDropdown), {
|
|
125
|
+
key: 2,
|
|
126
|
+
resize: "",
|
|
127
|
+
value: initialValue.value
|
|
128
|
+
}, {
|
|
129
|
+
items: withCtx(() => [(openBlock(true), createElementBlock(Fragment, null, renderList(options.value, (option) => {
|
|
130
|
+
return openBlock(), createBlock(unref(ScalarDropdownItem), {
|
|
131
|
+
key: option,
|
|
132
|
+
class: "group/item flex items-center gap-1.5 overflow-hidden text-ellipsis whitespace-nowrap",
|
|
133
|
+
value: option,
|
|
134
|
+
onClick: ($event) => updateSelected(option)
|
|
135
|
+
}, {
|
|
136
|
+
default: withCtx(() => [createElementVNode("div", { class: normalizeClass(["flex h-4 w-4 items-center justify-center rounded-full p-[3px]", isSelected(option) ? "bg-c-accent text-b-1" : "shadow-border text-transparent"]) }, [createVNode(unref(ScalarIcon), {
|
|
137
|
+
class: "size-2.5",
|
|
138
|
+
icon: "Checkmark",
|
|
139
|
+
thickness: "3"
|
|
140
|
+
})], 2), createElementVNode("span", _hoisted_4$2, toDisplayString(option), 1)]),
|
|
141
|
+
_: 2
|
|
142
|
+
}, 1032, ["value", "onClick"]);
|
|
143
|
+
}), 128)), __props.canAddCustomValue ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [options.value.length ? (openBlock(), createBlock(unref(ScalarDropdownDivider), { key: 0 })) : createCommentVNode("", true), createVNode(unref(ScalarDropdownItem), {
|
|
144
|
+
class: "flex items-center gap-1.5",
|
|
145
|
+
onClick: _cache[1] || (_cache[1] = ($event) => addingCustomValue.value = true)
|
|
146
|
+
}, {
|
|
147
|
+
default: withCtx(() => [createElementVNode("div", _hoisted_5$1, [createVNode(unref(ScalarIcon), {
|
|
148
|
+
icon: "Add",
|
|
149
|
+
size: "sm"
|
|
150
|
+
})]), _cache[2] || (_cache[2] = createElementVNode("span", null, "Add value", -1))]),
|
|
151
|
+
_: 1
|
|
152
|
+
})], 64)) : createCommentVNode("", true)]),
|
|
153
|
+
default: withCtx(() => [createVNode(unref(ScalarButton), {
|
|
154
|
+
class: "size-full justify-start gap-1.5 overflow-auto px-2 py-1.5 font-normal whitespace-nowrap outline-none",
|
|
155
|
+
variant: "ghost"
|
|
156
|
+
}, {
|
|
157
|
+
default: withCtx(() => [createElementVNode("span", _hoisted_3$2, toDisplayString(initialValue.value ?? "Select a value"), 1), createVNode(unref(ScalarIcon), {
|
|
158
|
+
icon: "ChevronDown",
|
|
159
|
+
size: "md"
|
|
160
|
+
})]),
|
|
161
|
+
_: 1
|
|
162
|
+
})]),
|
|
163
|
+
_: 1
|
|
164
|
+
}, 8, ["value"]))]);
|
|
165
|
+
};
|
|
166
|
+
}
|
|
167
|
+
});
|
|
168
|
+
//#endregion
|
|
169
|
+
//#region src/v2/features/environments/components/EnvironmentVariablesDropdown.vue?vue&type=script&setup=true&lang.ts
|
|
170
|
+
var _hoisted_1$1 = {
|
|
171
|
+
key: 0,
|
|
172
|
+
class: "gap-1/2 flex flex-col"
|
|
173
|
+
};
|
|
174
|
+
var _hoisted_2$1 = ["onClick"];
|
|
175
|
+
var _hoisted_3$1 = { class: "flex items-center gap-2 whitespace-nowrap" };
|
|
176
|
+
var _hoisted_4$1 = { class: "w-20 overflow-hidden text-right text-ellipsis whitespace-nowrap" };
|
|
177
|
+
//#endregion
|
|
178
|
+
//#region src/v2/features/environments/components/EnvironmentVariablesDropdown.vue
|
|
179
|
+
var EnvironmentVariablesDropdown_default = /* @__PURE__ */ defineComponent({
|
|
180
|
+
__name: "EnvironmentVariablesDropdown",
|
|
181
|
+
props: {
|
|
182
|
+
query: {},
|
|
183
|
+
environment: {},
|
|
184
|
+
dropdownPosition: {}
|
|
185
|
+
},
|
|
186
|
+
emits: ["select", "redirect"],
|
|
187
|
+
setup(__props, { expose: __expose, emit: __emit }) {
|
|
188
|
+
const emit = __emit;
|
|
189
|
+
const isOpen = ref(true);
|
|
190
|
+
const dropdownRef = ref(null);
|
|
191
|
+
const selectedVariableIndex = ref(0);
|
|
192
|
+
const redirectToEnvironment = () => {
|
|
193
|
+
emit("redirect");
|
|
194
|
+
isOpen.value = false;
|
|
195
|
+
};
|
|
196
|
+
/** Normalize the variables to have a name and value */
|
|
197
|
+
const normalizedVariables = computed(() => __props.environment.variables.map((v) => ({
|
|
198
|
+
key: v.name,
|
|
199
|
+
value: typeof v.value === "string" ? v.value : v.value.default
|
|
200
|
+
})));
|
|
201
|
+
const fuse = new Fuse(normalizedVariables.value, { keys: ["key", "value"] });
|
|
202
|
+
const filteredVariables = computed(() => {
|
|
203
|
+
if (!__props.query)
|
|
204
|
+
/** return the last 4 environment variables on first display */
|
|
205
|
+
return normalizedVariables.value.slice(-4).filter(({ key, value }) => key !== "" || value !== "");
|
|
206
|
+
/** filter environment variables by name */
|
|
207
|
+
const result = fuse.search(__props.query, { limit: 10 });
|
|
208
|
+
if (result.length > 0) return result.map((res) => res.item).filter(({ key, value }) => key !== "" || value !== "");
|
|
209
|
+
return [];
|
|
210
|
+
});
|
|
211
|
+
const selectVariable = (variableKey) => {
|
|
212
|
+
emit("select", variableKey);
|
|
213
|
+
};
|
|
214
|
+
const handleArrowKey = (direction) => {
|
|
215
|
+
const offset = direction === "up" ? -1 : 1;
|
|
216
|
+
const length = filteredVariables.value.length;
|
|
217
|
+
if (length === 0) return;
|
|
218
|
+
selectedVariableIndex.value = (selectedVariableIndex.value + offset + length) % length;
|
|
219
|
+
};
|
|
220
|
+
const handleSelect = () => {
|
|
221
|
+
if (selectedVariableIndex.value >= 0) {
|
|
222
|
+
const selectedVariable = filteredVariables.value[selectedVariableIndex.value];
|
|
223
|
+
if (selectedVariable) selectVariable(selectedVariable.key);
|
|
224
|
+
}
|
|
225
|
+
};
|
|
226
|
+
__expose({
|
|
227
|
+
handleArrowKey,
|
|
228
|
+
handleSelect
|
|
229
|
+
});
|
|
230
|
+
onMounted(() => {
|
|
231
|
+
selectedVariableIndex.value = 0;
|
|
232
|
+
});
|
|
233
|
+
const dropdownStyle = computed(() => {
|
|
234
|
+
return {
|
|
235
|
+
left: (__props.dropdownPosition?.left ?? 0) + "px",
|
|
236
|
+
top: (__props.dropdownPosition?.top ?? 0) + 5 + "px"
|
|
237
|
+
};
|
|
238
|
+
});
|
|
239
|
+
onClickOutside(dropdownRef, () => {
|
|
240
|
+
isOpen.value = false;
|
|
241
|
+
}, { ignore: [dropdownRef] });
|
|
242
|
+
return (_ctx, _cache) => {
|
|
243
|
+
return isOpen.value ? (openBlock(), createBlock(unref(ScalarTeleport), {
|
|
244
|
+
key: 0,
|
|
245
|
+
class: "scalar-client"
|
|
246
|
+
}, {
|
|
247
|
+
default: withCtx(() => [createElementVNode("div", {
|
|
248
|
+
ref_key: "dropdownRef",
|
|
249
|
+
ref: dropdownRef,
|
|
250
|
+
class: "custom-scroll fixed top-0 left-0 flex max-h-[60svh] w-56 flex-col rounded border p-0.75",
|
|
251
|
+
style: normalizeStyle(dropdownStyle.value)
|
|
252
|
+
}, [filteredVariables.value.length ? (openBlock(), createElementBlock("ul", _hoisted_1$1, [(openBlock(true), createElementBlock(Fragment, null, renderList(filteredVariables.value, (item, index) => {
|
|
253
|
+
return openBlock(), createElementBlock("li", {
|
|
254
|
+
key: item.key,
|
|
255
|
+
class: normalizeClass(["font-code text-xxs hover:bg-b-2 flex h-8 cursor-pointer items-center justify-between gap-1.5 rounded p-1.5 transition-colors duration-150", { "bg-b-2": index === selectedVariableIndex.value }]),
|
|
256
|
+
onClick: ($event) => selectVariable(item.key)
|
|
257
|
+
}, [createElementVNode("div", _hoisted_3$1, [createElementVNode("span", {
|
|
258
|
+
class: "h-2.25 w-2.25 min-w-2.25 rounded-full",
|
|
259
|
+
style: normalizeStyle({ backgroundColor: __props.environment.color })
|
|
260
|
+
}, null, 4), createTextVNode(" " + toDisplayString(item.key), 1)]), createElementVNode("span", _hoisted_4$1, toDisplayString(item.value), 1)], 10, _hoisted_2$1);
|
|
261
|
+
}), 128))])) : (openBlock(), createBlock(unref(ScalarButton), {
|
|
262
|
+
key: 1,
|
|
263
|
+
class: "font-code text-xxs bg-b-inherit hover:bg-b-2 flex h-8 w-full justify-start gap-2 px-1.5 transition-colors duration-150",
|
|
264
|
+
variant: "outlined",
|
|
265
|
+
onClick: redirectToEnvironment
|
|
266
|
+
}, {
|
|
267
|
+
default: withCtx(() => [createVNode(unref(ScalarIconPlus), { class: "size-3" }), _cache[0] || (_cache[0] = createTextVNode(" Add Variable ", -1))]),
|
|
268
|
+
_: 1
|
|
269
|
+
})), _cache[1] || (_cache[1] = createElementVNode("div", { class: "bg-b-1 brightness-lifted absolute inset-0 -z-1 rounded shadow-lg" }, null, -1))], 4)]),
|
|
270
|
+
_: 1
|
|
271
|
+
})) : createCommentVNode("", true);
|
|
272
|
+
};
|
|
273
|
+
}
|
|
274
|
+
});
|
|
275
|
+
//#endregion
|
|
276
|
+
//#region src/v2/components/code-input/code-variable-widget.ts
|
|
277
|
+
/**
|
|
278
|
+
* Displays the value of a variable of the active environment in a pill.
|
|
279
|
+
* Uses Vue for tooltip functionality.
|
|
280
|
+
*/
|
|
281
|
+
var PillWidget = class PillWidget extends WidgetType {
|
|
282
|
+
app;
|
|
283
|
+
pillColor;
|
|
284
|
+
variableInfo;
|
|
285
|
+
constructor(variableName, environment) {
|
|
286
|
+
super();
|
|
287
|
+
this.variableName = variableName;
|
|
288
|
+
this.pillColor = environment?.color || "var(--scalar-color-1)";
|
|
289
|
+
const variable = environment?.variables?.find((v) => v.name === variableName);
|
|
290
|
+
const value = variable ? typeof variable.value === "string" ? variable.value : variable.value?.default : void 0;
|
|
291
|
+
this.variableInfo = {
|
|
292
|
+
value: value || "No value",
|
|
293
|
+
hasValue: Boolean(value)
|
|
294
|
+
};
|
|
295
|
+
}
|
|
296
|
+
toDOM() {
|
|
297
|
+
const span = document.createElement("span");
|
|
298
|
+
span.className = "cm-pill";
|
|
299
|
+
span.textContent = this.variableName;
|
|
300
|
+
span.style.setProperty("--tw-bg-base", this.pillColor);
|
|
301
|
+
span.style.opacity = this.variableInfo.hasValue ? "1" : "0.5";
|
|
302
|
+
this.app = createApp(defineComponent({ render: () => {
|
|
303
|
+
const tooltipTrigger = h("div", { class: "flex items-center gap-1 whitespace-nowrap" }, [h("span", this.variableName)]);
|
|
304
|
+
return h(ScalarTooltip, {
|
|
305
|
+
content: this.variableInfo.value,
|
|
306
|
+
delay: 0,
|
|
307
|
+
placement: "bottom",
|
|
308
|
+
offset: 6
|
|
309
|
+
}, { default: () => tooltipTrigger });
|
|
310
|
+
} }));
|
|
311
|
+
this.app.mount(span);
|
|
312
|
+
return span;
|
|
313
|
+
}
|
|
314
|
+
destroy() {
|
|
315
|
+
if (this.app) {
|
|
316
|
+
this.app.unmount();
|
|
317
|
+
this.app = null;
|
|
318
|
+
}
|
|
319
|
+
}
|
|
320
|
+
eq(other) {
|
|
321
|
+
return other instanceof PillWidget && other.variableName === this.variableName && other.pillColor === this.pillColor && other.variableInfo.value === this.variableInfo.value && other.variableInfo.hasValue === this.variableInfo.hasValue;
|
|
322
|
+
}
|
|
323
|
+
ignoreEvent() {
|
|
324
|
+
return false;
|
|
325
|
+
}
|
|
326
|
+
};
|
|
327
|
+
/**
|
|
328
|
+
* Styles the active environment variable pill.
|
|
329
|
+
* This plugin creates decorations for environment variables in the editor.
|
|
330
|
+
*/
|
|
331
|
+
var pillPlugin = (props) => ViewPlugin.fromClass(class {
|
|
332
|
+
decorations;
|
|
333
|
+
lastEnvironment;
|
|
334
|
+
constructor(view) {
|
|
335
|
+
this.lastEnvironment = props.environment;
|
|
336
|
+
this.decorations = this.buildDecorations(view);
|
|
337
|
+
}
|
|
338
|
+
update(update) {
|
|
339
|
+
if (props.environment !== this.lastEnvironment) {
|
|
340
|
+
this.lastEnvironment = props.environment;
|
|
341
|
+
this.decorations = this.buildDecorations(update.view);
|
|
342
|
+
return;
|
|
343
|
+
}
|
|
344
|
+
if (update.docChanged || update.viewportChanged) this.decorations = this.buildDecorations(update.view);
|
|
345
|
+
}
|
|
346
|
+
buildDecorations(view) {
|
|
347
|
+
const builder = new RangeSetBuilder();
|
|
348
|
+
for (const { from, to } of view.visibleRanges) {
|
|
349
|
+
const text = view.state.doc.sliceString(from, to);
|
|
350
|
+
const regex = new RegExp(REGEX.VARIABLES.source, REGEX.VARIABLES.flags);
|
|
351
|
+
let match;
|
|
352
|
+
while ((match = regex.exec(text)) !== null) {
|
|
353
|
+
const start = from + match.index;
|
|
354
|
+
const end = start + match[0].length;
|
|
355
|
+
const variableName = match[1] ?? "";
|
|
356
|
+
if (view.state.doc.sliceString(start, end).includes("\n")) continue;
|
|
357
|
+
builder.add(start, end, Decoration.widget({
|
|
358
|
+
widget: new PillWidget(variableName, props.environment),
|
|
359
|
+
side: 1
|
|
360
|
+
}));
|
|
361
|
+
}
|
|
362
|
+
}
|
|
363
|
+
return builder.finish();
|
|
364
|
+
}
|
|
365
|
+
}, { decorations: (v) => v.decorations });
|
|
366
|
+
/**
|
|
367
|
+
* Custom backspace handler for the editor.
|
|
368
|
+
* Handles special cases like removing entire variable syntax and clearing all content.
|
|
369
|
+
*/
|
|
370
|
+
var backspaceCommand = EditorView.domEventHandlers({ keydown(event, view) {
|
|
371
|
+
if (event.key !== "Backspace") return false;
|
|
372
|
+
const { state } = view;
|
|
373
|
+
const { from, to } = state.selection.main;
|
|
374
|
+
if (from === 0 && to === state.doc.length) {
|
|
375
|
+
view.dispatch({
|
|
376
|
+
changes: {
|
|
377
|
+
from: 0,
|
|
378
|
+
to: state.doc.length
|
|
379
|
+
},
|
|
380
|
+
selection: { anchor: 0 }
|
|
381
|
+
});
|
|
382
|
+
event.preventDefault();
|
|
383
|
+
return true;
|
|
384
|
+
}
|
|
385
|
+
if (from === to && from >= 2) {
|
|
386
|
+
if (state.doc.sliceString(from - 2, from) === "}}") {
|
|
387
|
+
view.dispatch({
|
|
388
|
+
changes: {
|
|
389
|
+
from: from - 2,
|
|
390
|
+
to: from
|
|
391
|
+
},
|
|
392
|
+
selection: { anchor: from - 2 }
|
|
393
|
+
});
|
|
394
|
+
event.preventDefault();
|
|
395
|
+
return true;
|
|
396
|
+
}
|
|
397
|
+
}
|
|
398
|
+
return false;
|
|
399
|
+
} });
|
|
400
|
+
//#endregion
|
|
401
|
+
//#region src/v2/components/code-input/CodeInput.vue?vue&type=script&setup=true&lang.ts
|
|
402
|
+
var _hoisted_1 = { class: "whitespace-nowrap" };
|
|
403
|
+
var _hoisted_2 = ["id"];
|
|
404
|
+
var _hoisted_3 = {
|
|
405
|
+
key: 0,
|
|
406
|
+
class: "z-context text-c-2 absolute right-1.5 bottom-1 hidden font-sans group-has-[:focus-visible]/input:block",
|
|
407
|
+
role: "alert"
|
|
408
|
+
};
|
|
409
|
+
var _hoisted_4 = {
|
|
410
|
+
key: 5,
|
|
411
|
+
class: "centered-y text-orange absolute right-7 text-xs"
|
|
412
|
+
};
|
|
413
|
+
var _hoisted_5 = {
|
|
414
|
+
key: 6,
|
|
415
|
+
class: "centered-y absolute right-0 flex h-full items-center p-1.5 group-has-[.cm-focused]:z-1"
|
|
416
|
+
};
|
|
417
|
+
var _hoisted_6 = {
|
|
418
|
+
key: 7,
|
|
419
|
+
class: "required centered-y text-xxs text-c-3 group-[.error]:text-red bg-b-1 pointer-events-none absolute right-0 mr-0.5 pt-px pr-2 opacity-100 shadow-[-8px_0_4px_var(--scalar-background-1)] transition-opacity duration-150 group-[.alert]:bg-transparent group-[.alert]:shadow-none group-[.error]:bg-transparent group-[.error]:shadow-none peer-has-[.cm-focused]:opacity-0"
|
|
420
|
+
};
|
|
421
|
+
//#endregion
|
|
422
|
+
//#region src/v2/components/code-input/CodeInput.vue
|
|
423
|
+
var CodeInput_default = /* @__PURE__ */ _plugin_vue_export_helper_default(/* @__PURE__ */ defineComponent({
|
|
424
|
+
inheritAttrs: false,
|
|
425
|
+
__name: "CodeInput",
|
|
426
|
+
props: {
|
|
427
|
+
modelValue: { type: [
|
|
428
|
+
String,
|
|
429
|
+
Number,
|
|
430
|
+
Boolean,
|
|
431
|
+
Array,
|
|
432
|
+
Object
|
|
433
|
+
] },
|
|
434
|
+
environment: {},
|
|
435
|
+
type: {},
|
|
436
|
+
disabled: {
|
|
437
|
+
type: Boolean,
|
|
438
|
+
default: false
|
|
439
|
+
},
|
|
440
|
+
error: {
|
|
441
|
+
type: Boolean,
|
|
442
|
+
default: false
|
|
443
|
+
},
|
|
444
|
+
layout: { default: "desktop" },
|
|
445
|
+
enum: {},
|
|
446
|
+
examples: {},
|
|
447
|
+
default: { type: [
|
|
448
|
+
String,
|
|
449
|
+
Number,
|
|
450
|
+
Boolean,
|
|
451
|
+
Array,
|
|
452
|
+
Object
|
|
453
|
+
] },
|
|
454
|
+
nullable: {
|
|
455
|
+
type: Boolean,
|
|
456
|
+
default: false
|
|
457
|
+
},
|
|
458
|
+
placeholder: {},
|
|
459
|
+
required: { type: Boolean },
|
|
460
|
+
colorPicker: {
|
|
461
|
+
type: Boolean,
|
|
462
|
+
default: false
|
|
463
|
+
},
|
|
464
|
+
lineNumbers: {
|
|
465
|
+
type: Boolean,
|
|
466
|
+
default: false
|
|
467
|
+
},
|
|
468
|
+
lint: {
|
|
469
|
+
type: Boolean,
|
|
470
|
+
default: false
|
|
471
|
+
},
|
|
472
|
+
lineWrapping: {
|
|
473
|
+
type: Boolean,
|
|
474
|
+
default: false
|
|
475
|
+
},
|
|
476
|
+
language: {},
|
|
477
|
+
extensions: { default: () => [] },
|
|
478
|
+
disableTabIndent: {
|
|
479
|
+
type: Boolean,
|
|
480
|
+
default: false
|
|
481
|
+
},
|
|
482
|
+
disableEnter: {
|
|
483
|
+
type: Boolean,
|
|
484
|
+
default: false
|
|
485
|
+
},
|
|
486
|
+
disableCloseBrackets: {
|
|
487
|
+
type: Boolean,
|
|
488
|
+
default: false
|
|
489
|
+
},
|
|
490
|
+
emitOnBlur: {
|
|
491
|
+
type: Boolean,
|
|
492
|
+
default: true
|
|
493
|
+
},
|
|
494
|
+
withVariables: {
|
|
495
|
+
type: Boolean,
|
|
496
|
+
default: true
|
|
497
|
+
},
|
|
498
|
+
alwaysEmitChange: {
|
|
499
|
+
type: Boolean,
|
|
500
|
+
default: false
|
|
501
|
+
},
|
|
502
|
+
handleFieldChange: { type: Function },
|
|
503
|
+
handleFieldSubmit: { type: Function },
|
|
504
|
+
linethrough: { type: Boolean }
|
|
505
|
+
},
|
|
506
|
+
emits: [
|
|
507
|
+
"update:modelValue",
|
|
508
|
+
"submit",
|
|
509
|
+
"blur",
|
|
510
|
+
"redirectToEnvironment"
|
|
511
|
+
],
|
|
512
|
+
setup(__props, { expose: __expose, emit: __emit }) {
|
|
513
|
+
const emit = __emit;
|
|
514
|
+
const attrs = useAttrs();
|
|
515
|
+
const componentId = attrs.id || `id-${nanoid()}`;
|
|
516
|
+
const isFocused = ref(false);
|
|
517
|
+
/**
|
|
518
|
+
* Determines if we should render a select dropdown for boolean types.
|
|
519
|
+
*/
|
|
520
|
+
const isBooleanMode = computed(() => {
|
|
521
|
+
if (__props.enum?.length) return false;
|
|
522
|
+
return __props.type === "boolean" || Array.isArray(__props.type) && __props.type.includes("boolean");
|
|
523
|
+
});
|
|
524
|
+
/**
|
|
525
|
+
* Options for boolean select mode.
|
|
526
|
+
*/
|
|
527
|
+
const booleanOptions = computed(() => __props.nullable ? [
|
|
528
|
+
"true",
|
|
529
|
+
"false",
|
|
530
|
+
"null"
|
|
531
|
+
] : ["true", "false"]);
|
|
532
|
+
/**
|
|
533
|
+
* Default type when dealing with type arrays.
|
|
534
|
+
* Finds the first non-null type.
|
|
535
|
+
*/
|
|
536
|
+
const defaultType = computed(() => {
|
|
537
|
+
if (Array.isArray(__props.type)) return __props.type.find((t) => t !== "null") ?? "string";
|
|
538
|
+
return __props.type;
|
|
539
|
+
});
|
|
540
|
+
/**
|
|
541
|
+
* Handles value changes during typing.
|
|
542
|
+
*/
|
|
543
|
+
const handleChange = (value) => {
|
|
544
|
+
if (!__props.alwaysEmitChange && value === serializeValue(__props.modelValue)) return;
|
|
545
|
+
if (__props.handleFieldChange) __props.handleFieldChange(value);
|
|
546
|
+
else emit("update:modelValue", value);
|
|
547
|
+
};
|
|
548
|
+
/**
|
|
549
|
+
* Handles form submission (enter key or blur with emitOnBlur).
|
|
550
|
+
*/
|
|
551
|
+
const handleSubmit = (value) => {
|
|
552
|
+
if (__props.handleFieldSubmit) __props.handleFieldSubmit(value);
|
|
553
|
+
else emit("submit", value);
|
|
554
|
+
};
|
|
555
|
+
/**
|
|
556
|
+
* Handles input blur event.
|
|
557
|
+
*/
|
|
558
|
+
const handleBlur = (value) => {
|
|
559
|
+
isFocused.value = false;
|
|
560
|
+
if (__props.emitOnBlur && __props.modelValue) handleSubmit(value);
|
|
561
|
+
emit("blur", value);
|
|
562
|
+
};
|
|
563
|
+
/**
|
|
564
|
+
* Handles model value updates from select components.
|
|
565
|
+
*/
|
|
566
|
+
const handleSelectChange = (value) => emit("update:modelValue", value);
|
|
567
|
+
/**
|
|
568
|
+
* Build extensions array.
|
|
569
|
+
* Note: Extensions are not reactive after initialization.
|
|
570
|
+
*/
|
|
571
|
+
const buildExtensions = () => {
|
|
572
|
+
const extensionsList = [...__props.extensions];
|
|
573
|
+
if (__props.colorPicker) extensionsList.push(colorPicker);
|
|
574
|
+
return extensionsList;
|
|
575
|
+
};
|
|
576
|
+
/**
|
|
577
|
+
* Reactive pill plugin for environment variable visualization.
|
|
578
|
+
*/
|
|
579
|
+
const pillPluginExtension = computed(() => pillPlugin({
|
|
580
|
+
environment: __props.environment,
|
|
581
|
+
isReadOnly: __props.layout === "modal"
|
|
582
|
+
}));
|
|
583
|
+
/**
|
|
584
|
+
* Combined extensions for CodeMirror.
|
|
585
|
+
*/
|
|
586
|
+
const codeMirrorExtensions = computed(() => [
|
|
587
|
+
...buildExtensions(),
|
|
588
|
+
pillPluginExtension.value,
|
|
589
|
+
backspaceCommand
|
|
590
|
+
]);
|
|
591
|
+
const codeMirrorRef = ref(null);
|
|
592
|
+
/** Converts the model value to a string for CodeMirror */
|
|
593
|
+
const serializeValue = (value) => {
|
|
594
|
+
if (typeof value === "string") return value;
|
|
595
|
+
return JSON.stringify(value);
|
|
596
|
+
};
|
|
597
|
+
const { codeMirror } = useCodeMirror({
|
|
598
|
+
content: toRef(() => serializeValue(__props.modelValue)),
|
|
599
|
+
onChange: (value) => {
|
|
600
|
+
handleChange(value);
|
|
601
|
+
updateDropdownVisibility();
|
|
602
|
+
},
|
|
603
|
+
onFocus: () => {
|
|
604
|
+
isFocused.value = true;
|
|
605
|
+
},
|
|
606
|
+
onBlur: handleBlur,
|
|
607
|
+
codeMirrorRef,
|
|
608
|
+
disableTabIndent: toRef(() => __props.disableTabIndent),
|
|
609
|
+
disableEnter: toRef(() => __props.disableEnter),
|
|
610
|
+
disableCloseBrackets: toRef(() => __props.disableCloseBrackets),
|
|
611
|
+
lineNumbers: toRef(() => __props.lineNumbers),
|
|
612
|
+
language: toRef(() => __props.language),
|
|
613
|
+
lint: toRef(() => __props.lint),
|
|
614
|
+
extensions: codeMirrorExtensions,
|
|
615
|
+
placeholder: toRef(() => __props.placeholder)
|
|
616
|
+
});
|
|
617
|
+
/**
|
|
618
|
+
* Handle autofocus attribute.
|
|
619
|
+
*/
|
|
620
|
+
watch(codeMirror, () => {
|
|
621
|
+
if (codeMirror.value && Object.hasOwn(attrs, "autofocus")) codeMirror.value.focus();
|
|
622
|
+
});
|
|
623
|
+
const showDropdown = ref(false);
|
|
624
|
+
const dropdownQuery = ref("");
|
|
625
|
+
const dropdownPosition = ref({
|
|
626
|
+
left: 0,
|
|
627
|
+
top: 0
|
|
628
|
+
});
|
|
629
|
+
const dropdownRef = ref(null);
|
|
630
|
+
const { handleDropdownSelect, updateDropdownVisibility } = useDropdown({
|
|
631
|
+
codeMirror,
|
|
632
|
+
query: dropdownQuery,
|
|
633
|
+
showDropdown,
|
|
634
|
+
dropdownPosition
|
|
635
|
+
});
|
|
636
|
+
/**
|
|
637
|
+
* Determines if the environment variable dropdown should be visible.
|
|
638
|
+
*/
|
|
639
|
+
const displayVariablesDropdown = computed(() => {
|
|
640
|
+
return showDropdown.value && __props.withVariables && __props.layout !== "modal" && Boolean(__props.environment);
|
|
641
|
+
});
|
|
642
|
+
/**
|
|
643
|
+
* Handles keyboard navigation for dropdown and form submission.
|
|
644
|
+
*/
|
|
645
|
+
const handleKeyDown = (key, event) => {
|
|
646
|
+
if (showDropdown.value) {
|
|
647
|
+
if (key === "down" || key === "up") {
|
|
648
|
+
event.preventDefault();
|
|
649
|
+
dropdownRef.value?.handleArrowKey(key);
|
|
650
|
+
} else if (key === "enter") {
|
|
651
|
+
event.preventDefault();
|
|
652
|
+
dropdownRef.value?.handleSelect();
|
|
653
|
+
}
|
|
654
|
+
return;
|
|
655
|
+
}
|
|
656
|
+
if (key === "escape" && !__props.disableTabIndent) event.stopPropagation();
|
|
657
|
+
if (key === "enter" && event.target instanceof HTMLDivElement) handleSubmit(event.target.textContent ?? "");
|
|
658
|
+
};
|
|
659
|
+
__expose({
|
|
660
|
+
focus: (position) => {
|
|
661
|
+
if (!codeMirror.value) return;
|
|
662
|
+
codeMirror.value.focus();
|
|
663
|
+
if (!isDefined(position)) return;
|
|
664
|
+
const anchor = (() => {
|
|
665
|
+
if (position === "start") return 0;
|
|
666
|
+
if (position === "end") return codeMirror.value.state.doc.length;
|
|
667
|
+
return position;
|
|
668
|
+
})();
|
|
669
|
+
codeMirror.value.dispatch({
|
|
670
|
+
selection: { anchor },
|
|
671
|
+
scrollIntoView: true
|
|
672
|
+
});
|
|
673
|
+
},
|
|
674
|
+
isFocused,
|
|
675
|
+
handleChange,
|
|
676
|
+
handleSubmit,
|
|
677
|
+
handleBlur,
|
|
678
|
+
booleanOptions,
|
|
679
|
+
codeMirror,
|
|
680
|
+
modelValue: __props.modelValue,
|
|
681
|
+
cursorPosition: () => codeMirror.value?.state.selection.main.head,
|
|
682
|
+
serializeValue
|
|
683
|
+
});
|
|
684
|
+
return (_ctx, _cache) => {
|
|
685
|
+
return openBlock(), createElementBlock(Fragment, null, [
|
|
686
|
+
__props.disabled ? (openBlock(), createElementBlock("div", {
|
|
687
|
+
key: 0,
|
|
688
|
+
class: normalizeClass(["text-c-2 flex cursor-default items-center justify-center", {
|
|
689
|
+
"font-code pr-2 pl-1 text-base": __props.layout === "modal",
|
|
690
|
+
"px-2": __props.layout !== "modal",
|
|
691
|
+
"line-through": __props.linethrough
|
|
692
|
+
}]),
|
|
693
|
+
"data-testid": "code-input-disabled"
|
|
694
|
+
}, [createElementVNode("span", _hoisted_1, toDisplayString(__props.modelValue), 1)], 2)) : __props.enum?.length ? (openBlock(), createBlock(DataTableInputSelect_default, {
|
|
695
|
+
key: 1,
|
|
696
|
+
default: __props.default,
|
|
697
|
+
modelValue: __props.modelValue,
|
|
698
|
+
type: defaultType.value,
|
|
699
|
+
value: __props.enum,
|
|
700
|
+
"onUpdate:modelValue": handleSelectChange
|
|
701
|
+
}, null, 8, [
|
|
702
|
+
"default",
|
|
703
|
+
"modelValue",
|
|
704
|
+
"type",
|
|
705
|
+
"value"
|
|
706
|
+
])) : isBooleanMode.value ? (openBlock(), createBlock(DataTableInputSelect_default, {
|
|
707
|
+
key: 2,
|
|
708
|
+
default: __props.default,
|
|
709
|
+
modelValue: __props.modelValue,
|
|
710
|
+
value: booleanOptions.value,
|
|
711
|
+
"onUpdate:modelValue": handleSelectChange
|
|
712
|
+
}, null, 8, [
|
|
713
|
+
"default",
|
|
714
|
+
"modelValue",
|
|
715
|
+
"value"
|
|
716
|
+
])) : __props.examples?.length ? (openBlock(), createBlock(DataTableInputSelect_default, {
|
|
717
|
+
key: 3,
|
|
718
|
+
default: __props.default,
|
|
719
|
+
modelValue: __props.modelValue,
|
|
720
|
+
value: __props.examples,
|
|
721
|
+
"onUpdate:modelValue": handleSelectChange
|
|
722
|
+
}, null, 8, [
|
|
723
|
+
"default",
|
|
724
|
+
"modelValue",
|
|
725
|
+
"value"
|
|
726
|
+
])) : (openBlock(), createElementBlock("div", mergeProps({
|
|
727
|
+
key: 4,
|
|
728
|
+
id: unref(componentId)
|
|
729
|
+
}, _ctx.$attrs, {
|
|
730
|
+
ref_key: "codeMirrorRef",
|
|
731
|
+
ref: codeMirrorRef,
|
|
732
|
+
class: ["group/input group-[.alert]:outline-orange group-[.error]:outline-red font-code peer relative w-full overflow-hidden text-xs leading-[1.44] whitespace-nowrap -outline-offset-1 has-[:focus-visible]:rounded-[4px] has-[:focus-visible]:outline", {
|
|
733
|
+
"line-wrapping has-[:focus-visible]:bg-b-1 has-[:focus-visible]:absolute has-[:focus-visible]:z-1": __props.lineWrapping,
|
|
734
|
+
"flow-code-input--error": __props.error,
|
|
735
|
+
"line-through": __props.linethrough
|
|
736
|
+
}],
|
|
737
|
+
onKeydown: [
|
|
738
|
+
_cache[0] || (_cache[0] = withKeys(withModifiers(($event) => handleKeyDown("down", $event), ["stop"]), ["down"])),
|
|
739
|
+
_cache[1] || (_cache[1] = withKeys(($event) => handleKeyDown("enter", $event), ["enter"])),
|
|
740
|
+
_cache[2] || (_cache[2] = withKeys(($event) => handleKeyDown("escape", $event), ["escape"])),
|
|
741
|
+
_cache[3] || (_cache[3] = withKeys(withModifiers(($event) => handleKeyDown("up", $event), ["stop"]), ["up"]))
|
|
742
|
+
]
|
|
743
|
+
}), [!__props.disableTabIndent ? (openBlock(), createElementBlock("div", _hoisted_3, [..._cache[5] || (_cache[5] = [
|
|
744
|
+
createTextVNode(" Press ", -1),
|
|
745
|
+
createElementVNode("kbd", { class: "-mx-0.25 rounded border px-0.5 font-mono" }, "Esc", -1),
|
|
746
|
+
createTextVNode(" then ", -1),
|
|
747
|
+
createElementVNode("kbd", { class: "-mx-0.25 rounded border px-0.5 font-mono" }, "Tab", -1),
|
|
748
|
+
createTextVNode(" to exit ", -1)
|
|
749
|
+
])])) : createCommentVNode("", true)], 16, _hoisted_2)),
|
|
750
|
+
_ctx.$slots.warning ? (openBlock(), createElementBlock("div", _hoisted_4, [renderSlot(_ctx.$slots, "warning", {}, void 0, true)])) : createCommentVNode("", true),
|
|
751
|
+
_ctx.$slots.icon ? (openBlock(), createElementBlock("div", _hoisted_5, [renderSlot(_ctx.$slots, "icon", {}, void 0, true)])) : createCommentVNode("", true),
|
|
752
|
+
__props.required ? (openBlock(), createElementBlock("div", _hoisted_6, " Required ")) : createCommentVNode("", true),
|
|
753
|
+
displayVariablesDropdown.value && __props.environment ? (openBlock(), createBlock(EnvironmentVariablesDropdown_default, {
|
|
754
|
+
key: 8,
|
|
755
|
+
ref_key: "dropdownRef",
|
|
756
|
+
ref: dropdownRef,
|
|
757
|
+
dropdownPosition: dropdownPosition.value,
|
|
758
|
+
environment: __props.environment,
|
|
759
|
+
query: dropdownQuery.value,
|
|
760
|
+
onRedirect: _cache[4] || (_cache[4] = ($event) => emit("redirectToEnvironment")),
|
|
761
|
+
onSelect: unref(handleDropdownSelect)
|
|
762
|
+
}, null, 8, [
|
|
763
|
+
"dropdownPosition",
|
|
764
|
+
"environment",
|
|
765
|
+
"query",
|
|
766
|
+
"onSelect"
|
|
767
|
+
])) : createCommentVNode("", true)
|
|
768
|
+
], 64);
|
|
769
|
+
};
|
|
770
|
+
}
|
|
771
|
+
}), [["__scopeId", "data-v-776dfdde"]]);
|
|
772
|
+
//#endregion
|
|
773
|
+
export { DataTableInputSelect_default as n, CodeInput_default as t };
|
|
774
|
+
|
|
775
|
+
//# sourceMappingURL=code-input-iq-moLxi.js.map
|