@scalar/api-client 2.38.1 → 2.38.2
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 +9 -0
- package/dist/AddressBar-B4xnl66I.js +302 -0
- package/dist/AddressBar-B4xnl66I.js.map +1 -0
- package/dist/App-BVH4lIe8.js +533 -0
- package/dist/App-BVH4lIe8.js.map +1 -0
- package/dist/App-CvClwSlM.js +2510 -0
- package/dist/App-CvClwSlM.js.map +1 -0
- package/dist/CodeInput-C-igR77V.js +694 -0
- package/dist/CodeInput-C-igR77V.js.map +1 -0
- package/dist/CodeSnippet-D7Heh1nd.js +218 -0
- package/dist/CodeSnippet-D7Heh1nd.js.map +1 -0
- package/dist/Collection-4MT9WmDD.js +219 -0
- package/dist/Collection-4MT9WmDD.js.map +1 -0
- package/dist/CollectionAuthentication-MHWQpw74.js +56 -0
- package/dist/CollectionAuthentication-MHWQpw74.js.map +1 -0
- package/dist/CollectionCookies-DyjPPMdt.js +19 -0
- package/dist/CollectionCookies-DyjPPMdt.js.map +1 -0
- package/dist/CollectionEnvironment-Dw35vIqo.js +514 -0
- package/dist/CollectionEnvironment-Dw35vIqo.js.map +1 -0
- package/dist/CollectionOverview-TUdDIu5f.js +131 -0
- package/dist/CollectionOverview-TUdDIu5f.js.map +1 -0
- package/dist/CollectionScripts-CMNlBlby.js +19 -0
- package/dist/CollectionScripts-CMNlBlby.js.map +1 -0
- package/dist/CollectionServers-BrjTCfDe.js +168 -0
- package/dist/CollectionServers-BrjTCfDe.js.map +1 -0
- package/dist/CollectionSettings-HVSlp2Gv.js +87 -0
- package/dist/CollectionSettings-HVSlp2Gv.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-CL8k4CoN.js +964 -0
- package/dist/CommandPalette-CL8k4CoN.js.map +1 -0
- package/dist/CommandPaletteImport-Diu5dDIY.js +622 -0
- package/dist/CommandPaletteImport-Diu5dDIY.js.map +1 -0
- package/dist/Cookies-DbOKTi1f.js +284 -0
- package/dist/Cookies-DbOKTi1f.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-yaU5g-kP.js +166 -0
- package/dist/DataTableInput-yaU5g-kP.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-DJatRQIg.js +416 -0
- package/dist/Environment-DJatRQIg.js.map +1 -0
- package/dist/EnvironmentModal-DBEJ4Kzj.js +288 -0
- package/dist/EnvironmentModal-DBEJ4Kzj.js.map +1 -0
- package/dist/Form-CSKzyHGO.js +83 -0
- package/dist/Form-CSKzyHGO.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-DfX1UQ5u.js +804 -0
- package/dist/ImportCollection-DfX1UQ5u.js.map +1 -0
- package/dist/IntegrationLogo-B9EDW8db.js +51 -0
- package/dist/IntegrationLogo-B9EDW8db.js.map +1 -0
- package/dist/MainLayout-BEFMl1ud.js +281 -0
- package/dist/MainLayout-BEFMl1ud.js.map +1 -0
- package/dist/Modal-sQ9vH6MN.js +67 -0
- package/dist/Modal-sQ9vH6MN.js.map +1 -0
- package/dist/ModalClientContainer-qHsZi4wQ.js +65 -0
- package/dist/ModalClientContainer-qHsZi4wQ.js.map +1 -0
- package/dist/Request-gscRsGQ8.js +212 -0
- package/dist/Request-gscRsGQ8.js.map +1 -0
- package/dist/RequestAuth-BzBfIysT.js +989 -0
- package/dist/RequestAuth-BzBfIysT.js.map +1 -0
- package/dist/RequestRoot-3Bj8JZD-.js +1611 -0
- package/dist/RequestRoot-3Bj8JZD-.js.map +1 -0
- package/dist/RequestSection-HhdJj9hW.js +1582 -0
- package/dist/RequestSection-HhdJj9hW.js.map +1 -0
- package/dist/ResponseSection-DMJ0tw8E.js +949 -0
- package/dist/ResponseSection-DMJ0tw8E.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-DnA_BzPS.js +303 -0
- package/dist/Server-DnA_BzPS.js.map +1 -0
- package/dist/ServerVariablesForm-BRZ9XC8o.js +145 -0
- package/dist/ServerVariablesForm-BRZ9XC8o.js.map +1 -0
- package/dist/Settings-CYZzdJPO.js +347 -0
- package/dist/Settings-CYZzdJPO.js.map +1 -0
- package/dist/Sidebar-C6AdX6-N.js +73 -0
- package/dist/Sidebar-C6AdX6-N.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-CSxJTn6F.js +183 -0
- package/dist/components-CSxJTn6F.js.map +1 -0
- package/dist/components-ChixwQhN.js +61 -0
- package/dist/components-ChixwQhN.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-BUCwrBzc.js +30 -0
- package/dist/get-resolved-url-BUCwrBzc.js.map +1 -0
- package/dist/get-server-url-o3On8CEr.js +32 -0
- package/dist/get-server-url-o3On8CEr.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-BnMIKAOh.js +1624 -0
- package/dist/operation-block-BnMIKAOh.js.map +1 -0
- package/dist/operation-code-sample-ZUTueV3v.js +1726 -0
- package/dist/operation-code-sample-ZUTueV3v.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-DwsGy64Q.js +1466 -0
- package/dist/request-block-DwsGy64Q.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--Vs6IBU1.js +425 -0
- package/dist/scalar-address-bar-block--Vs6IBU1.js.map +1 -0
- package/dist/scalar-auth-selector-block-DI3DLag9.js +1886 -0
- package/dist/scalar-auth-selector-block-DI3DLag9.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-DpSUVhjp.js +1512 -0
- package/dist/store-DpSUVhjp.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/components/Header.vue.d.ts +2 -2
- 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/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-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/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/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/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/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/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,303 @@
|
|
|
1
|
+
import { r as useWorkspace } from "./store-DpSUVhjp.js";
|
|
2
|
+
import { a as useLayout } from "./useSidebar-DLTwHDI-.js";
|
|
3
|
+
import { t as _plugin_vue_export_helper_default } from "./_plugin-vue_export-helper-BmmBcIzD.js";
|
|
4
|
+
import { t as ServerVariablesForm_default } from "./ServerVariablesForm-BRZ9XC8o.js";
|
|
5
|
+
import { Fragment, computed, createBlock, createCommentVNode, createElementBlock, createElementVNode, createTextVNode, createVNode, defineComponent, mergeProps, normalizeClass, openBlock, renderList, toDisplayString, unref, useId, useTemplateRef, watch, withCtx, withModifiers } from "vue";
|
|
6
|
+
import { ScalarButton, ScalarDropdownDivider, ScalarFloatingBackdrop, ScalarIcon, ScalarListbox, ScalarListboxCheckbox, ScalarMarkdown, ScalarPopover } from "@scalar/components";
|
|
7
|
+
import { emitCustomEvent } from "@scalar/workspace-store/events";
|
|
8
|
+
import { ScalarIconCaretDown } from "@scalar/icons";
|
|
9
|
+
//#region src/components/Server/ServerDropdownItem.vue?vue&type=script&setup=true&lang.ts
|
|
10
|
+
var _hoisted_1$2 = ["aria-expanded"];
|
|
11
|
+
var _hoisted_2$2 = { class: "overflow-hidden text-ellipsis whitespace-nowrap" };
|
|
12
|
+
var _hoisted_3$1 = ["id"];
|
|
13
|
+
var _hoisted_4 = { key: 0 };
|
|
14
|
+
var _hoisted_5 = { class: "description text-c-3 px-3 py-1.5" };
|
|
15
|
+
//#endregion
|
|
16
|
+
//#region src/components/Server/ServerDropdownItem.vue
|
|
17
|
+
var ServerDropdownItem_default = /* @__PURE__ */ _plugin_vue_export_helper_default(/* @__PURE__ */ defineComponent({
|
|
18
|
+
__name: "ServerDropdownItem",
|
|
19
|
+
props: {
|
|
20
|
+
collection: {},
|
|
21
|
+
operation: {},
|
|
22
|
+
server: {},
|
|
23
|
+
serverOption: {},
|
|
24
|
+
type: {}
|
|
25
|
+
},
|
|
26
|
+
emits: ["update:variable"],
|
|
27
|
+
setup(__props, { emit: __emit }) {
|
|
28
|
+
const props = __props;
|
|
29
|
+
const emit = __emit;
|
|
30
|
+
const formId = useId();
|
|
31
|
+
const { collectionMutators, requestMutators, servers } = useWorkspace();
|
|
32
|
+
/** Update the currently selected server on the collection or request */
|
|
33
|
+
const updateSelectedServer = (serverUid, event) => {
|
|
34
|
+
if (hasVariables(serverUid)) event?.stopPropagation();
|
|
35
|
+
if (isSelectedServer.value) {
|
|
36
|
+
if (props.operation?.servers?.length) requestMutators.edit(props.operation.uid, "selectedServerUid", null);
|
|
37
|
+
if (props.type === "collection") {
|
|
38
|
+
collectionMutators.edit(props.collection.uid, "selectedServerUid", void 0);
|
|
39
|
+
emitCustomEvent(wrapper.value, "scalar-update-selected-server", {
|
|
40
|
+
value: void 0,
|
|
41
|
+
options: { disableOldStoreUpdate: true }
|
|
42
|
+
});
|
|
43
|
+
} else if (props.type === "request" && props.operation) requestMutators.edit(props.operation.uid, "selectedServerUid", null);
|
|
44
|
+
return;
|
|
45
|
+
}
|
|
46
|
+
if (props.type === "collection" && props.collection) {
|
|
47
|
+
if (props.operation?.servers?.length) requestMutators.edit(props.operation.uid, "selectedServerUid", null);
|
|
48
|
+
collectionMutators.edit(props.collection.uid, "selectedServerUid", serverUid);
|
|
49
|
+
emitCustomEvent(wrapper.value, "scalar-update-selected-server", {
|
|
50
|
+
value: servers[serverUid]?.url,
|
|
51
|
+
options: { disableOldStoreUpdate: true }
|
|
52
|
+
});
|
|
53
|
+
} else if (props.type === "request" && props.operation) requestMutators.edit(props.operation.uid, "selectedServerUid", serverUid);
|
|
54
|
+
};
|
|
55
|
+
/** Set server checkbox in the dropdown */
|
|
56
|
+
const isSelectedServer = computed(() => {
|
|
57
|
+
if (props.type === "collection") return props.collection.selectedServerUid === props.serverOption.id && !props.operation?.selectedServerUid;
|
|
58
|
+
if (props.type === "request" && props.operation) return props.operation.selectedServerUid === props.serverOption.id;
|
|
59
|
+
return false;
|
|
60
|
+
});
|
|
61
|
+
const hasVariables = (serverUid) => {
|
|
62
|
+
if (!serverUid) return false;
|
|
63
|
+
const server = servers[serverUid];
|
|
64
|
+
return Object.keys(server?.variables ?? {}).length > 0;
|
|
65
|
+
};
|
|
66
|
+
const isExpanded = computed(() => isSelectedServer.value && hasVariables(props.server?.uid ?? ""));
|
|
67
|
+
const updateServerVariable = (key, value) => {
|
|
68
|
+
emit("update:variable", key, value);
|
|
69
|
+
};
|
|
70
|
+
const wrapper = useTemplateRef("wrapper-ref");
|
|
71
|
+
return (_ctx, _cache) => {
|
|
72
|
+
return openBlock(), createElementBlock("div", {
|
|
73
|
+
ref: "wrapper-ref",
|
|
74
|
+
class: normalizeClass(["group/item flex min-h-fit flex-col rounded border", { "border-transparent": !isSelectedServer.value }])
|
|
75
|
+
}, [createElementVNode("button", mergeProps(isExpanded.value ? { "aria-controls": unref(formId) } : {}, {
|
|
76
|
+
"aria-expanded": isExpanded.value,
|
|
77
|
+
class: ["flex min-h-8 cursor-pointer items-center gap-1.5 rounded px-1.5", isSelectedServer.value ? "text-c-1 bg-b-2" : "hover:bg-b-2"],
|
|
78
|
+
type: "button",
|
|
79
|
+
onClick: _cache[0] || (_cache[0] = (e) => updateSelectedServer(__props.serverOption.id, e))
|
|
80
|
+
}), [createVNode(unref(ScalarListboxCheckbox), { selected: isSelectedServer.value }, null, 8, ["selected"]), createElementVNode("span", _hoisted_2$2, toDisplayString(__props.serverOption.label), 1)], 16, _hoisted_1$2), isExpanded.value ? (openBlock(), createElementBlock("div", {
|
|
81
|
+
key: 0,
|
|
82
|
+
id: unref(formId),
|
|
83
|
+
class: "bg-b-2 divide divide-y rounded-b border-t *:pl-4",
|
|
84
|
+
onClick: _cache[1] || (_cache[1] = withModifiers(() => {}, ["stop"]))
|
|
85
|
+
}, [createVNode(ServerVariablesForm_default, {
|
|
86
|
+
variables: __props.server?.variables,
|
|
87
|
+
"onUpdate:variable": updateServerVariable
|
|
88
|
+
}, null, 8, ["variables"]), __props.server?.description ? (openBlock(), createElementBlock("div", _hoisted_4, [createElementVNode("div", _hoisted_5, [createVNode(unref(ScalarMarkdown), { value: __props.server.description }, null, 8, ["value"])])])) : createCommentVNode("", true)], 8, _hoisted_3$1)) : createCommentVNode("", true)], 2);
|
|
89
|
+
};
|
|
90
|
+
}
|
|
91
|
+
}), [["__scopeId", "data-v-92012388"]]);
|
|
92
|
+
//#endregion
|
|
93
|
+
//#region src/components/Server/ServerDropdown.vue?vue&type=script&setup=true&lang.ts
|
|
94
|
+
var _hoisted_1$1 = ["onClick"];
|
|
95
|
+
var _hoisted_2$1 = { class: "flex h-4 w-4 items-center justify-center" };
|
|
96
|
+
//#endregion
|
|
97
|
+
//#region src/components/Server/ServerDropdown.vue
|
|
98
|
+
var ServerDropdown_default = /* @__PURE__ */ defineComponent({
|
|
99
|
+
__name: "ServerDropdown",
|
|
100
|
+
props: {
|
|
101
|
+
collection: {},
|
|
102
|
+
operation: {},
|
|
103
|
+
server: {},
|
|
104
|
+
target: {}
|
|
105
|
+
},
|
|
106
|
+
setup(__props) {
|
|
107
|
+
const { layout } = useLayout();
|
|
108
|
+
const { servers, collectionMutators, events, serverMutators } = useWorkspace();
|
|
109
|
+
const requestServerOptions = computed(() => __props.operation?.servers?.map((serverUid) => ({
|
|
110
|
+
id: serverUid,
|
|
111
|
+
label: servers[serverUid]?.url ?? "Unknown server"
|
|
112
|
+
})));
|
|
113
|
+
const collectionServerOptions = computed(() => __props.collection?.servers?.filter((serverUid) => !__props.operation?.servers?.includes(serverUid)).map((serverUid) => ({
|
|
114
|
+
id: serverUid,
|
|
115
|
+
label: servers[serverUid]?.url ?? "Unknown server"
|
|
116
|
+
})));
|
|
117
|
+
/** If we have both request and collection servers we show the labels */
|
|
118
|
+
const showDropdownLabels = computed(() => requestServerOptions.value?.length && collectionServerOptions.value?.length);
|
|
119
|
+
watch([() => __props.collection, () => __props.operation], ([newCollection, newOperation]) => {
|
|
120
|
+
if (!newCollection || newCollection.selectedServerUid || newOperation?.selectedServerUid) return;
|
|
121
|
+
const firstServer = __props.collection.servers?.[0];
|
|
122
|
+
if (firstServer) collectionMutators.edit(__props.collection.uid, "selectedServerUid", firstServer);
|
|
123
|
+
});
|
|
124
|
+
/** Add server */
|
|
125
|
+
const handleAddServer = () => events.commandPalette.emit({ commandName: "Add Server" });
|
|
126
|
+
const serverUrlWithoutTrailingSlash = computed(() => {
|
|
127
|
+
if (__props.server?.url?.endsWith("/")) return __props.server.url.slice(0, -1);
|
|
128
|
+
return __props.server?.url || "";
|
|
129
|
+
});
|
|
130
|
+
const updateServerVariable = (key, value) => {
|
|
131
|
+
if (!__props.server) return;
|
|
132
|
+
const variables = __props.server.variables || {};
|
|
133
|
+
variables[key] = {
|
|
134
|
+
...variables[key],
|
|
135
|
+
default: value
|
|
136
|
+
};
|
|
137
|
+
serverMutators.edit(__props.server.uid, "variables", variables);
|
|
138
|
+
emitCustomEvent(wrapper.value?.$el, "scalar-update-selected-server-variables", {
|
|
139
|
+
key,
|
|
140
|
+
value
|
|
141
|
+
});
|
|
142
|
+
};
|
|
143
|
+
const wrapper = useTemplateRef("wrapper-ref");
|
|
144
|
+
return (_ctx, _cache) => {
|
|
145
|
+
return openBlock(), createBlock(unref(ScalarPopover), {
|
|
146
|
+
ref: "wrapper-ref",
|
|
147
|
+
class: "max-h-[inherit] p-0 text-base",
|
|
148
|
+
focus: "",
|
|
149
|
+
offset: 0,
|
|
150
|
+
placement: "bottom-start",
|
|
151
|
+
resize: "",
|
|
152
|
+
target: __props.target,
|
|
153
|
+
teleport: `#${__props.target}`
|
|
154
|
+
}, {
|
|
155
|
+
popover: withCtx(({ close }) => [createElementVNode("div", {
|
|
156
|
+
class: "custom-scroll flex max-h-[inherit] flex-col gap-1 border-t p-1",
|
|
157
|
+
onClick: close
|
|
158
|
+
}, [
|
|
159
|
+
(openBlock(true), createElementBlock(Fragment, null, renderList(requestServerOptions.value, (serverOption) => {
|
|
160
|
+
return openBlock(), createBlock(ServerDropdownItem_default, {
|
|
161
|
+
key: serverOption.id,
|
|
162
|
+
collection: __props.collection,
|
|
163
|
+
operation: __props.operation,
|
|
164
|
+
server: __props.server,
|
|
165
|
+
serverOption,
|
|
166
|
+
type: "request",
|
|
167
|
+
"onUpdate:variable": updateServerVariable
|
|
168
|
+
}, null, 8, [
|
|
169
|
+
"collection",
|
|
170
|
+
"operation",
|
|
171
|
+
"server",
|
|
172
|
+
"serverOption"
|
|
173
|
+
]);
|
|
174
|
+
}), 128)),
|
|
175
|
+
showDropdownLabels.value ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [createVNode(unref(ScalarDropdownDivider)), _cache[2] || (_cache[2] = createElementVNode("div", { class: "text-xxs text-c-2 px-2.5 py-1" }, "Collection", -1))], 64)) : createCommentVNode("", true),
|
|
176
|
+
(openBlock(true), createElementBlock(Fragment, null, renderList(collectionServerOptions.value, (serverOption) => {
|
|
177
|
+
return openBlock(), createBlock(ServerDropdownItem_default, {
|
|
178
|
+
key: serverOption.id,
|
|
179
|
+
collection: __props.collection,
|
|
180
|
+
operation: __props.operation,
|
|
181
|
+
server: __props.server,
|
|
182
|
+
serverOption,
|
|
183
|
+
type: "collection",
|
|
184
|
+
"onUpdate:variable": updateServerVariable
|
|
185
|
+
}, null, 8, [
|
|
186
|
+
"collection",
|
|
187
|
+
"operation",
|
|
188
|
+
"server",
|
|
189
|
+
"serverOption"
|
|
190
|
+
]);
|
|
191
|
+
}), 128)),
|
|
192
|
+
unref(layout) !== "modal" ? (openBlock(), createElementBlock("button", {
|
|
193
|
+
key: 1,
|
|
194
|
+
class: "text-xxs hover:bg-b-2 flex cursor-pointer items-center gap-1.5 rounded p-1.75",
|
|
195
|
+
type: "button",
|
|
196
|
+
onClick: handleAddServer
|
|
197
|
+
}, [createElementVNode("div", _hoisted_2$1, [createVNode(unref(ScalarIcon), {
|
|
198
|
+
icon: "Add",
|
|
199
|
+
size: "sm"
|
|
200
|
+
})]), _cache[3] || (_cache[3] = createElementVNode("span", null, "Add Server", -1))])) : createCommentVNode("", true)
|
|
201
|
+
], 8, _hoisted_1$1)]),
|
|
202
|
+
backdrop: withCtx(() => [createVNode(unref(ScalarFloatingBackdrop), { class: "-top-(--scalar-address-bar-height) rounded-lg" })]),
|
|
203
|
+
default: withCtx(() => [createVNode(unref(ScalarButton), {
|
|
204
|
+
class: "z-context-plus hover:bg-b-2 font-code text-c-2 ml-0.75 h-auto gap-0.75 rounded border px-1.5 text-base whitespace-nowrap",
|
|
205
|
+
variant: "ghost"
|
|
206
|
+
}, {
|
|
207
|
+
default: withCtx(() => [__props.operation?.selectedServerUid || __props.collection.selectedServerUid ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [_cache[0] || (_cache[0] = createElementVNode("span", { class: "sr-only" }, "Server:", -1)), createTextVNode(" " + toDisplayString(serverUrlWithoutTrailingSlash.value), 1)], 64)) : (openBlock(), createElementBlock(Fragment, { key: 1 }, [_cache[1] || (_cache[1] = createElementVNode("span", { class: "sr-only" }, "Add Server", -1)), createVNode(unref(ScalarIcon), {
|
|
208
|
+
icon: "Add",
|
|
209
|
+
size: "xs"
|
|
210
|
+
})], 64))]),
|
|
211
|
+
_: 1
|
|
212
|
+
})]),
|
|
213
|
+
_: 1
|
|
214
|
+
}, 8, ["target", "teleport"]);
|
|
215
|
+
};
|
|
216
|
+
}
|
|
217
|
+
});
|
|
218
|
+
//#endregion
|
|
219
|
+
//#region src/components/Server/ServerSelector.vue?vue&type=script&setup=true&lang.ts
|
|
220
|
+
var _hoisted_1 = { class: "overflow-x-auto" };
|
|
221
|
+
var _hoisted_2 = {
|
|
222
|
+
key: 1,
|
|
223
|
+
class: "text-c-1 flex h-auto w-full items-center gap-0.75 rounded-b-xl px-3 py-1.5 text-base/5 whitespace-nowrap"
|
|
224
|
+
};
|
|
225
|
+
var _hoisted_3 = { class: "overflow-x-auto" };
|
|
226
|
+
//#endregion
|
|
227
|
+
//#region src/components/Server/ServerSelector.vue
|
|
228
|
+
var ServerSelector_default = /* @__PURE__ */ defineComponent({
|
|
229
|
+
__name: "ServerSelector",
|
|
230
|
+
props: {
|
|
231
|
+
collection: {},
|
|
232
|
+
server: {},
|
|
233
|
+
target: {}
|
|
234
|
+
},
|
|
235
|
+
emits: ["updateServer"],
|
|
236
|
+
setup(__props, { emit: __emit }) {
|
|
237
|
+
const emit = __emit;
|
|
238
|
+
const { servers, collectionMutators } = useWorkspace();
|
|
239
|
+
const serverOptions = computed(() => __props.collection?.servers.map((serverUid) => ({
|
|
240
|
+
id: serverUid,
|
|
241
|
+
label: servers[serverUid]?.url ?? "Unknown server"
|
|
242
|
+
})));
|
|
243
|
+
const selectedServer = computed({
|
|
244
|
+
get: () => __props.server ? serverOptions.value.find((option) => option.id === __props.server.uid) : void 0,
|
|
245
|
+
set: (option) => {
|
|
246
|
+
if (!option) return;
|
|
247
|
+
collectionMutators.edit(__props.collection.uid, "selectedServerUid", option.id);
|
|
248
|
+
const serverUrl = servers[option.id]?.url;
|
|
249
|
+
if (serverUrl) emit("updateServer", serverUrl);
|
|
250
|
+
}
|
|
251
|
+
});
|
|
252
|
+
watch(() => __props.collection, (newCollection) => {
|
|
253
|
+
if (!newCollection || newCollection.selectedServerUid) return;
|
|
254
|
+
const firstServer = __props.collection.servers?.[0];
|
|
255
|
+
if (firstServer) {
|
|
256
|
+
collectionMutators.edit(__props.collection.uid, "selectedServerUid", firstServer);
|
|
257
|
+
if (servers[firstServer]?.url) emit("updateServer", servers[firstServer].url);
|
|
258
|
+
}
|
|
259
|
+
});
|
|
260
|
+
const serverUrlWithoutTrailingSlash = computed(() => {
|
|
261
|
+
if (__props.server?.url?.endsWith("/")) return __props.server.url.slice(0, -1);
|
|
262
|
+
return __props.server?.url || "";
|
|
263
|
+
});
|
|
264
|
+
return (_ctx, _cache) => {
|
|
265
|
+
return serverOptions.value.length > 1 ? (openBlock(), createBlock(unref(ScalarListbox), {
|
|
266
|
+
key: 0,
|
|
267
|
+
modelValue: selectedServer.value,
|
|
268
|
+
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => selectedServer.value = $event),
|
|
269
|
+
class: "group",
|
|
270
|
+
options: serverOptions.value,
|
|
271
|
+
placement: "bottom-start",
|
|
272
|
+
resize: "",
|
|
273
|
+
target: __props.target,
|
|
274
|
+
teleport: `#${__props.target}`
|
|
275
|
+
}, {
|
|
276
|
+
default: withCtx(() => [createVNode(unref(ScalarButton), {
|
|
277
|
+
class: "bg-b-1 text-c-1 h-auto w-full justify-start gap-1.5 overflow-x-auto rounded-t-none rounded-b-xl px-3 py-1.5 text-base font-normal whitespace-nowrap -outline-offset-1",
|
|
278
|
+
variant: "ghost"
|
|
279
|
+
}, {
|
|
280
|
+
default: withCtx(() => [
|
|
281
|
+
_cache[1] || (_cache[1] = createElementVNode("span", { class: "sr-only" }, "Server:", -1)),
|
|
282
|
+
createElementVNode("span", _hoisted_1, toDisplayString(serverUrlWithoutTrailingSlash.value), 1),
|
|
283
|
+
createVNode(unref(ScalarIconCaretDown), {
|
|
284
|
+
class: "text-c-2 ui-open:rotate-180 mt-px size-3 transition-transform duration-100",
|
|
285
|
+
weight: "bold"
|
|
286
|
+
})
|
|
287
|
+
]),
|
|
288
|
+
_: 1
|
|
289
|
+
})]),
|
|
290
|
+
_: 1
|
|
291
|
+
}, 8, [
|
|
292
|
+
"modelValue",
|
|
293
|
+
"options",
|
|
294
|
+
"target",
|
|
295
|
+
"teleport"
|
|
296
|
+
])) : (openBlock(), createElementBlock("div", _hoisted_2, [_cache[2] || (_cache[2] = createElementVNode("span", { class: "sr-only" }, "Server:", -1)), createElementVNode("span", _hoisted_3, toDisplayString(serverUrlWithoutTrailingSlash.value), 1)]));
|
|
297
|
+
};
|
|
298
|
+
}
|
|
299
|
+
});
|
|
300
|
+
//#endregion
|
|
301
|
+
export { ServerDropdown_default as n, ServerSelector_default as t };
|
|
302
|
+
|
|
303
|
+
//# sourceMappingURL=Server-DnA_BzPS.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Server-DnA_BzPS.js","names":[],"sources":["../src/components/Server/ServerDropdownItem.vue","../src/components/Server/ServerDropdownItem.vue","../src/components/Server/ServerDropdown.vue","../src/components/Server/ServerDropdown.vue","../src/components/Server/ServerSelector.vue","../src/components/Server/ServerSelector.vue"],"sourcesContent":["<script setup lang=\"ts\">\nimport { ScalarListboxCheckbox, ScalarMarkdown } from '@scalar/components'\nimport type {\n Collection,\n Request as Operation,\n Server,\n} from '@scalar/oas-utils/entities/spec'\nimport { emitCustomEvent } from '@scalar/workspace-store/events'\nimport { computed, useId, useTemplateRef } from 'vue'\n\nimport ServerVariablesForm from '@/components/Server/ServerVariablesForm.vue'\nimport type { ServerVariables } from '@/components/Server/types'\nimport { useWorkspace } from '@/store/store'\n\nconst props = defineProps<{\n collection: Collection\n operation: Operation | undefined\n server: Server | undefined\n serverOption: {\n id: Server['uid']\n label: string\n }\n type: 'collection' | 'request'\n}>()\n\nconst emit = defineEmits<{\n (e: 'update:variable', key: string, value: string): void\n}>()\n\nconst formId = useId()\nconst { collectionMutators, requestMutators, servers } = useWorkspace()\n\n/** Update the currently selected server on the collection or request */\nconst updateSelectedServer = (serverUid: Server['uid'], event?: Event) => {\n if (hasVariables(serverUid)) {\n event?.stopPropagation()\n }\n\n // Handle selected server deselection\n if (isSelectedServer.value) {\n // Clear selected server if selected\n if (props.operation?.servers?.length) {\n requestMutators.edit(props.operation.uid, 'selectedServerUid', null)\n }\n if (props.type === 'collection') {\n collectionMutators.edit(\n props.collection.uid,\n 'selectedServerUid',\n undefined,\n )\n\n emitCustomEvent(wrapper.value, 'scalar-update-selected-server', {\n value: undefined,\n options: { disableOldStoreUpdate: true },\n })\n } else if (props.type === 'request' && props.operation) {\n requestMutators.edit(props.operation.uid, 'selectedServerUid', null)\n }\n return\n }\n\n // Set selected server on Collection\n if (props.type === 'collection' && props.collection) {\n // Clear the selected server on the request so that the collection can be updated\n if (props.operation?.servers?.length) {\n requestMutators.edit(props.operation.uid, 'selectedServerUid', null)\n }\n collectionMutators.edit(\n props.collection.uid,\n 'selectedServerUid',\n serverUid,\n )\n\n emitCustomEvent(wrapper.value, 'scalar-update-selected-server', {\n value: servers[serverUid]?.url,\n options: { disableOldStoreUpdate: true },\n })\n }\n // Set on the operation\n else if (props.type === 'request' && props.operation) {\n requestMutators.edit(props.operation.uid, 'selectedServerUid', serverUid)\n }\n}\n\n/** Set server checkbox in the dropdown */\nconst isSelectedServer = computed(() => {\n if (props.type === 'collection') {\n // Check selected collection unless operation level server is selected\n return (\n props.collection.selectedServerUid === props.serverOption.id &&\n !props.operation?.selectedServerUid\n )\n }\n\n if (props.type === 'request' && props.operation) {\n return props.operation.selectedServerUid === props.serverOption.id\n }\n\n return false\n})\n\nconst hasVariables = (serverUid: string) => {\n if (!serverUid) {\n return false\n }\n\n const server = servers[serverUid]\n\n return Object.keys(server?.variables ?? {}).length > 0\n}\n\nconst isExpanded = computed(\n () => isSelectedServer.value && hasVariables(props.server?.uid ?? ''),\n)\n\nconst updateServerVariable = (key: string, value: string) => {\n emit('update:variable', key, value)\n}\n\nconst wrapper = useTemplateRef('wrapper-ref')\n</script>\n<template>\n <div\n ref=\"wrapper-ref\"\n class=\"group/item flex min-h-fit flex-col rounded border\"\n :class=\"{ 'border-transparent': !isSelectedServer }\">\n <button\n v-bind=\"isExpanded ? { 'aria-controls': formId } : {}\"\n :aria-expanded=\"isExpanded\"\n class=\"flex min-h-8 cursor-pointer items-center gap-1.5 rounded px-1.5\"\n :class=\"isSelectedServer ? 'text-c-1 bg-b-2' : 'hover:bg-b-2'\"\n type=\"button\"\n @click=\"(e) => updateSelectedServer(serverOption.id, e)\">\n <ScalarListboxCheckbox :selected=\"isSelectedServer\" />\n <span class=\"overflow-hidden text-ellipsis whitespace-nowrap\">\n {{ serverOption.label }}\n </span>\n </button>\n <!-- Server variables -->\n <div\n v-if=\"isExpanded\"\n :id=\"formId\"\n class=\"bg-b-2 divide divide-y rounded-b border-t *:pl-4\"\n @click.stop>\n <ServerVariablesForm\n :variables=\"server?.variables as ServerVariables\"\n @update:variable=\"updateServerVariable\" />\n <!-- Description -->\n <div v-if=\"server?.description\">\n <div class=\"description text-c-3 px-3 py-1.5\">\n <ScalarMarkdown :value=\"server.description\" />\n </div>\n </div>\n </div>\n </div>\n</template>\n<style scoped>\n.description :deep(.markdown) {\n font-weight: var(--scalar-semibold);\n color: var(--scalar-color--1);\n padding: 0 0;\n display: block;\n}\n.description :deep(.markdown > *:first-child) {\n margin-top: 0;\n}\n</style>\n","<script setup lang=\"ts\">\nimport { ScalarListboxCheckbox, ScalarMarkdown } from '@scalar/components'\nimport type {\n Collection,\n Request as Operation,\n Server,\n} from '@scalar/oas-utils/entities/spec'\nimport { emitCustomEvent } from '@scalar/workspace-store/events'\nimport { computed, useId, useTemplateRef } from 'vue'\n\nimport ServerVariablesForm from '@/components/Server/ServerVariablesForm.vue'\nimport type { ServerVariables } from '@/components/Server/types'\nimport { useWorkspace } from '@/store/store'\n\nconst props = defineProps<{\n collection: Collection\n operation: Operation | undefined\n server: Server | undefined\n serverOption: {\n id: Server['uid']\n label: string\n }\n type: 'collection' | 'request'\n}>()\n\nconst emit = defineEmits<{\n (e: 'update:variable', key: string, value: string): void\n}>()\n\nconst formId = useId()\nconst { collectionMutators, requestMutators, servers } = useWorkspace()\n\n/** Update the currently selected server on the collection or request */\nconst updateSelectedServer = (serverUid: Server['uid'], event?: Event) => {\n if (hasVariables(serverUid)) {\n event?.stopPropagation()\n }\n\n // Handle selected server deselection\n if (isSelectedServer.value) {\n // Clear selected server if selected\n if (props.operation?.servers?.length) {\n requestMutators.edit(props.operation.uid, 'selectedServerUid', null)\n }\n if (props.type === 'collection') {\n collectionMutators.edit(\n props.collection.uid,\n 'selectedServerUid',\n undefined,\n )\n\n emitCustomEvent(wrapper.value, 'scalar-update-selected-server', {\n value: undefined,\n options: { disableOldStoreUpdate: true },\n })\n } else if (props.type === 'request' && props.operation) {\n requestMutators.edit(props.operation.uid, 'selectedServerUid', null)\n }\n return\n }\n\n // Set selected server on Collection\n if (props.type === 'collection' && props.collection) {\n // Clear the selected server on the request so that the collection can be updated\n if (props.operation?.servers?.length) {\n requestMutators.edit(props.operation.uid, 'selectedServerUid', null)\n }\n collectionMutators.edit(\n props.collection.uid,\n 'selectedServerUid',\n serverUid,\n )\n\n emitCustomEvent(wrapper.value, 'scalar-update-selected-server', {\n value: servers[serverUid]?.url,\n options: { disableOldStoreUpdate: true },\n })\n }\n // Set on the operation\n else if (props.type === 'request' && props.operation) {\n requestMutators.edit(props.operation.uid, 'selectedServerUid', serverUid)\n }\n}\n\n/** Set server checkbox in the dropdown */\nconst isSelectedServer = computed(() => {\n if (props.type === 'collection') {\n // Check selected collection unless operation level server is selected\n return (\n props.collection.selectedServerUid === props.serverOption.id &&\n !props.operation?.selectedServerUid\n )\n }\n\n if (props.type === 'request' && props.operation) {\n return props.operation.selectedServerUid === props.serverOption.id\n }\n\n return false\n})\n\nconst hasVariables = (serverUid: string) => {\n if (!serverUid) {\n return false\n }\n\n const server = servers[serverUid]\n\n return Object.keys(server?.variables ?? {}).length > 0\n}\n\nconst isExpanded = computed(\n () => isSelectedServer.value && hasVariables(props.server?.uid ?? ''),\n)\n\nconst updateServerVariable = (key: string, value: string) => {\n emit('update:variable', key, value)\n}\n\nconst wrapper = useTemplateRef('wrapper-ref')\n</script>\n<template>\n <div\n ref=\"wrapper-ref\"\n class=\"group/item flex min-h-fit flex-col rounded border\"\n :class=\"{ 'border-transparent': !isSelectedServer }\">\n <button\n v-bind=\"isExpanded ? { 'aria-controls': formId } : {}\"\n :aria-expanded=\"isExpanded\"\n class=\"flex min-h-8 cursor-pointer items-center gap-1.5 rounded px-1.5\"\n :class=\"isSelectedServer ? 'text-c-1 bg-b-2' : 'hover:bg-b-2'\"\n type=\"button\"\n @click=\"(e) => updateSelectedServer(serverOption.id, e)\">\n <ScalarListboxCheckbox :selected=\"isSelectedServer\" />\n <span class=\"overflow-hidden text-ellipsis whitespace-nowrap\">\n {{ serverOption.label }}\n </span>\n </button>\n <!-- Server variables -->\n <div\n v-if=\"isExpanded\"\n :id=\"formId\"\n class=\"bg-b-2 divide divide-y rounded-b border-t *:pl-4\"\n @click.stop>\n <ServerVariablesForm\n :variables=\"server?.variables as ServerVariables\"\n @update:variable=\"updateServerVariable\" />\n <!-- Description -->\n <div v-if=\"server?.description\">\n <div class=\"description text-c-3 px-3 py-1.5\">\n <ScalarMarkdown :value=\"server.description\" />\n </div>\n </div>\n </div>\n </div>\n</template>\n<style scoped>\n.description :deep(.markdown) {\n font-weight: var(--scalar-semibold);\n color: var(--scalar-color--1);\n padding: 0 0;\n display: block;\n}\n.description :deep(.markdown > *:first-child) {\n margin-top: 0;\n}\n</style>\n","<script setup lang=\"ts\">\nimport {\n ScalarButton,\n ScalarDropdownDivider,\n ScalarFloatingBackdrop,\n ScalarIcon,\n ScalarPopover,\n} from '@scalar/components'\nimport type {\n Collection,\n Request as Operation,\n Server,\n} from '@scalar/oas-utils/entities/spec'\nimport { emitCustomEvent } from '@scalar/workspace-store/events'\nimport { computed, useTemplateRef, watch } from 'vue'\n\nimport { useLayout } from '@/hooks/useLayout'\nimport { useWorkspace } from '@/store/store'\n\nimport ServerDropdownItem from './ServerDropdownItem.vue'\n\nconst { target, collection, operation, server } = defineProps<{\n collection: Collection\n operation?: Operation\n server: Server | undefined\n /** The id of the target to use for the popover (e.g. address bar) */\n target: string\n}>()\n\nconst { layout } = useLayout()\nconst { servers, collectionMutators, events, serverMutators } = useWorkspace()\n\nconst requestServerOptions = computed(() =>\n operation?.servers?.map((serverUid) => ({\n id: serverUid,\n label: servers[serverUid]?.url ?? 'Unknown server',\n })),\n)\n\nconst collectionServerOptions = computed(() =>\n // Filters out servers already present in the request\n collection?.servers\n ?.filter((serverUid) => !operation?.servers?.includes(serverUid))\n .map((serverUid) => ({\n id: serverUid,\n label: servers[serverUid]?.url ?? 'Unknown server',\n })),\n)\n\n/** If we have both request and collection servers we show the labels */\nconst showDropdownLabels = computed(\n () =>\n requestServerOptions.value?.length && collectionServerOptions.value?.length,\n)\n\n// Ensure we always have a selected server\nwatch([() => collection, () => operation], ([newCollection, newOperation]) => {\n if (\n !newCollection ||\n newCollection.selectedServerUid ||\n newOperation?.selectedServerUid\n ) {\n return\n }\n\n const firstServer = collection.servers?.[0]\n\n if (firstServer) {\n collectionMutators.edit(collection.uid, 'selectedServerUid', firstServer)\n }\n})\n\n/** Add server */\nconst handleAddServer = () =>\n events.commandPalette.emit({\n commandName: 'Add Server',\n })\n\nconst serverUrlWithoutTrailingSlash = computed(() => {\n if (server?.url?.endsWith('/')) {\n return server.url.slice(0, -1)\n }\n return server?.url || ''\n})\n\nconst updateServerVariable = (key: string, value: string) => {\n if (!server) {\n return\n }\n\n const variables = server.variables || {}\n variables[key] = { ...variables[key], default: value }\n\n serverMutators.edit(server.uid, 'variables', variables)\n\n // Emit event to keep the new store in sync\n emitCustomEvent(\n wrapper.value?.$el,\n 'scalar-update-selected-server-variables',\n { key, value },\n )\n}\n\nconst wrapper = useTemplateRef('wrapper-ref')\n</script>\n<template>\n <ScalarPopover\n ref=\"wrapper-ref\"\n class=\"max-h-[inherit] p-0 text-base\"\n focus\n :offset=\"0\"\n placement=\"bottom-start\"\n resize\n :target=\"target\"\n :teleport=\"`#${target}`\">\n <ScalarButton\n class=\"z-context-plus hover:bg-b-2 font-code text-c-2 ml-0.75 h-auto gap-0.75 rounded border px-1.5 text-base whitespace-nowrap\"\n variant=\"ghost\">\n <template\n v-if=\"operation?.selectedServerUid || collection.selectedServerUid\">\n <span class=\"sr-only\">Server:</span>\n {{ serverUrlWithoutTrailingSlash }}\n </template>\n <template v-else>\n <span class=\"sr-only\">Add Server</span>\n <ScalarIcon\n icon=\"Add\"\n size=\"xs\" />\n </template>\n </ScalarButton>\n <template #popover=\"{ close }\">\n <div\n class=\"custom-scroll flex max-h-[inherit] flex-col gap-1 border-t p-1\"\n @click=\"close\">\n <!-- Request -->\n <ServerDropdownItem\n v-for=\"serverOption in requestServerOptions\"\n :key=\"serverOption.id\"\n :collection=\"collection\"\n :operation=\"operation\"\n :server=\"server\"\n :serverOption=\"serverOption\"\n type=\"request\"\n @update:variable=\"updateServerVariable\" />\n <template v-if=\"showDropdownLabels\">\n <ScalarDropdownDivider />\n <div class=\"text-xxs text-c-2 px-2.5 py-1\">Collection</div>\n </template>\n <!-- Collection -->\n <ServerDropdownItem\n v-for=\"serverOption in collectionServerOptions\"\n :key=\"serverOption.id\"\n :collection=\"collection\"\n :operation=\"operation\"\n :server=\"server\"\n :serverOption=\"serverOption\"\n type=\"collection\"\n @update:variable=\"updateServerVariable\" />\n <!-- Add Server -->\n <template v-if=\"layout !== 'modal'\">\n <button\n class=\"text-xxs hover:bg-b-2 flex cursor-pointer items-center gap-1.5 rounded p-1.75\"\n type=\"button\"\n @click=\"handleAddServer\">\n <div class=\"flex h-4 w-4 items-center justify-center\">\n <ScalarIcon\n icon=\"Add\"\n size=\"sm\" />\n </div>\n <span>Add Server</span>\n </button>\n </template>\n </div>\n </template>\n <template #backdrop>\n <ScalarFloatingBackdrop\n class=\"-top-(--scalar-address-bar-height) rounded-lg\" />\n </template>\n </ScalarPopover>\n</template>\n","<script setup lang=\"ts\">\nimport {\n ScalarButton,\n ScalarDropdownDivider,\n ScalarFloatingBackdrop,\n ScalarIcon,\n ScalarPopover,\n} from '@scalar/components'\nimport type {\n Collection,\n Request as Operation,\n Server,\n} from '@scalar/oas-utils/entities/spec'\nimport { emitCustomEvent } from '@scalar/workspace-store/events'\nimport { computed, useTemplateRef, watch } from 'vue'\n\nimport { useLayout } from '@/hooks/useLayout'\nimport { useWorkspace } from '@/store/store'\n\nimport ServerDropdownItem from './ServerDropdownItem.vue'\n\nconst { target, collection, operation, server } = defineProps<{\n collection: Collection\n operation?: Operation\n server: Server | undefined\n /** The id of the target to use for the popover (e.g. address bar) */\n target: string\n}>()\n\nconst { layout } = useLayout()\nconst { servers, collectionMutators, events, serverMutators } = useWorkspace()\n\nconst requestServerOptions = computed(() =>\n operation?.servers?.map((serverUid) => ({\n id: serverUid,\n label: servers[serverUid]?.url ?? 'Unknown server',\n })),\n)\n\nconst collectionServerOptions = computed(() =>\n // Filters out servers already present in the request\n collection?.servers\n ?.filter((serverUid) => !operation?.servers?.includes(serverUid))\n .map((serverUid) => ({\n id: serverUid,\n label: servers[serverUid]?.url ?? 'Unknown server',\n })),\n)\n\n/** If we have both request and collection servers we show the labels */\nconst showDropdownLabels = computed(\n () =>\n requestServerOptions.value?.length && collectionServerOptions.value?.length,\n)\n\n// Ensure we always have a selected server\nwatch([() => collection, () => operation], ([newCollection, newOperation]) => {\n if (\n !newCollection ||\n newCollection.selectedServerUid ||\n newOperation?.selectedServerUid\n ) {\n return\n }\n\n const firstServer = collection.servers?.[0]\n\n if (firstServer) {\n collectionMutators.edit(collection.uid, 'selectedServerUid', firstServer)\n }\n})\n\n/** Add server */\nconst handleAddServer = () =>\n events.commandPalette.emit({\n commandName: 'Add Server',\n })\n\nconst serverUrlWithoutTrailingSlash = computed(() => {\n if (server?.url?.endsWith('/')) {\n return server.url.slice(0, -1)\n }\n return server?.url || ''\n})\n\nconst updateServerVariable = (key: string, value: string) => {\n if (!server) {\n return\n }\n\n const variables = server.variables || {}\n variables[key] = { ...variables[key], default: value }\n\n serverMutators.edit(server.uid, 'variables', variables)\n\n // Emit event to keep the new store in sync\n emitCustomEvent(\n wrapper.value?.$el,\n 'scalar-update-selected-server-variables',\n { key, value },\n )\n}\n\nconst wrapper = useTemplateRef('wrapper-ref')\n</script>\n<template>\n <ScalarPopover\n ref=\"wrapper-ref\"\n class=\"max-h-[inherit] p-0 text-base\"\n focus\n :offset=\"0\"\n placement=\"bottom-start\"\n resize\n :target=\"target\"\n :teleport=\"`#${target}`\">\n <ScalarButton\n class=\"z-context-plus hover:bg-b-2 font-code text-c-2 ml-0.75 h-auto gap-0.75 rounded border px-1.5 text-base whitespace-nowrap\"\n variant=\"ghost\">\n <template\n v-if=\"operation?.selectedServerUid || collection.selectedServerUid\">\n <span class=\"sr-only\">Server:</span>\n {{ serverUrlWithoutTrailingSlash }}\n </template>\n <template v-else>\n <span class=\"sr-only\">Add Server</span>\n <ScalarIcon\n icon=\"Add\"\n size=\"xs\" />\n </template>\n </ScalarButton>\n <template #popover=\"{ close }\">\n <div\n class=\"custom-scroll flex max-h-[inherit] flex-col gap-1 border-t p-1\"\n @click=\"close\">\n <!-- Request -->\n <ServerDropdownItem\n v-for=\"serverOption in requestServerOptions\"\n :key=\"serverOption.id\"\n :collection=\"collection\"\n :operation=\"operation\"\n :server=\"server\"\n :serverOption=\"serverOption\"\n type=\"request\"\n @update:variable=\"updateServerVariable\" />\n <template v-if=\"showDropdownLabels\">\n <ScalarDropdownDivider />\n <div class=\"text-xxs text-c-2 px-2.5 py-1\">Collection</div>\n </template>\n <!-- Collection -->\n <ServerDropdownItem\n v-for=\"serverOption in collectionServerOptions\"\n :key=\"serverOption.id\"\n :collection=\"collection\"\n :operation=\"operation\"\n :server=\"server\"\n :serverOption=\"serverOption\"\n type=\"collection\"\n @update:variable=\"updateServerVariable\" />\n <!-- Add Server -->\n <template v-if=\"layout !== 'modal'\">\n <button\n class=\"text-xxs hover:bg-b-2 flex cursor-pointer items-center gap-1.5 rounded p-1.75\"\n type=\"button\"\n @click=\"handleAddServer\">\n <div class=\"flex h-4 w-4 items-center justify-center\">\n <ScalarIcon\n icon=\"Add\"\n size=\"sm\" />\n </div>\n <span>Add Server</span>\n </button>\n </template>\n </div>\n </template>\n <template #backdrop>\n <ScalarFloatingBackdrop\n class=\"-top-(--scalar-address-bar-height) rounded-lg\" />\n </template>\n </ScalarPopover>\n</template>\n","<script setup lang=\"ts\">\nimport { ScalarButton, ScalarListbox } from '@scalar/components'\nimport { ScalarIconCaretDown } from '@scalar/icons'\nimport type { Collection, Server } from '@scalar/oas-utils/entities/spec'\nimport { computed, watch } from 'vue'\n\nimport { useWorkspace } from '@/store/store'\n\ntype ServerOption = {\n id: Server['uid']\n label: string\n}\n\nconst { target, collection, server } = defineProps<{\n /** The collection */\n collection: Collection\n /** The selected server */\n server: Server | undefined\n /** The id of the target to use for the popover (e.g. address bar) */\n target: string\n}>()\n\nconst emit = defineEmits<{\n (e: 'updateServer', server: string): void\n}>()\n\nconst { servers, collectionMutators } = useWorkspace()\n\nconst serverOptions = computed<ServerOption[]>(() =>\n collection?.servers.map((serverUid) => ({\n id: serverUid,\n label: servers[serverUid]?.url ?? 'Unknown server',\n })),\n)\n\nconst selectedServer = computed<ServerOption | undefined>({\n get: () =>\n server\n ? serverOptions.value.find((option) => option.id === server.uid)\n : undefined,\n set: (option) => {\n if (!option) {\n return\n }\n collectionMutators.edit(\n collection.uid,\n 'selectedServerUid',\n option.id as Server['uid'],\n )\n const serverUrl = servers[option.id]?.url\n if (serverUrl) {\n emit('updateServer', serverUrl)\n }\n },\n})\n\n// Ensure we always have a selected server\nwatch(\n () => collection,\n (newCollection) => {\n if (!newCollection || newCollection.selectedServerUid) {\n return\n }\n\n const firstServer = collection.servers?.[0]\n\n if (firstServer) {\n collectionMutators.edit(collection.uid, 'selectedServerUid', firstServer)\n if (servers[firstServer]?.url) {\n emit('updateServer', servers[firstServer].url)\n }\n }\n },\n)\n\nconst serverUrlWithoutTrailingSlash = computed(() => {\n if (server?.url?.endsWith('/')) {\n return server.url.slice(0, -1)\n }\n return server?.url || ''\n})\n</script>\n<template>\n <ScalarListbox\n v-if=\"serverOptions.length > 1\"\n v-model=\"selectedServer\"\n class=\"group\"\n :options=\"serverOptions\"\n placement=\"bottom-start\"\n resize\n :target=\"target\"\n :teleport=\"`#${target}`\">\n <ScalarButton\n class=\"bg-b-1 text-c-1 h-auto w-full justify-start gap-1.5 overflow-x-auto rounded-t-none rounded-b-xl px-3 py-1.5 text-base font-normal whitespace-nowrap -outline-offset-1\"\n variant=\"ghost\">\n <span class=\"sr-only\">Server:</span>\n <span class=\"overflow-x-auto\">{{ serverUrlWithoutTrailingSlash }}</span>\n <ScalarIconCaretDown\n class=\"text-c-2 ui-open:rotate-180 mt-px size-3 transition-transform duration-100\"\n weight=\"bold\" />\n </ScalarButton>\n </ScalarListbox>\n <div\n v-else\n class=\"text-c-1 flex h-auto w-full items-center gap-0.75 rounded-b-xl px-3 py-1.5 text-base/5 whitespace-nowrap\">\n <span class=\"sr-only\">Server:</span>\n <span class=\"overflow-x-auto\">{{ serverUrlWithoutTrailingSlash }}</span>\n </div>\n</template>\n","<script setup lang=\"ts\">\nimport { ScalarButton, ScalarListbox } from '@scalar/components'\nimport { ScalarIconCaretDown } from '@scalar/icons'\nimport type { Collection, Server } from '@scalar/oas-utils/entities/spec'\nimport { computed, watch } from 'vue'\n\nimport { useWorkspace } from '@/store/store'\n\ntype ServerOption = {\n id: Server['uid']\n label: string\n}\n\nconst { target, collection, server } = defineProps<{\n /** The collection */\n collection: Collection\n /** The selected server */\n server: Server | undefined\n /** The id of the target to use for the popover (e.g. address bar) */\n target: string\n}>()\n\nconst emit = defineEmits<{\n (e: 'updateServer', server: string): void\n}>()\n\nconst { servers, collectionMutators } = useWorkspace()\n\nconst serverOptions = computed<ServerOption[]>(() =>\n collection?.servers.map((serverUid) => ({\n id: serverUid,\n label: servers[serverUid]?.url ?? 'Unknown server',\n })),\n)\n\nconst selectedServer = computed<ServerOption | undefined>({\n get: () =>\n server\n ? serverOptions.value.find((option) => option.id === server.uid)\n : undefined,\n set: (option) => {\n if (!option) {\n return\n }\n collectionMutators.edit(\n collection.uid,\n 'selectedServerUid',\n option.id as Server['uid'],\n )\n const serverUrl = servers[option.id]?.url\n if (serverUrl) {\n emit('updateServer', serverUrl)\n }\n },\n})\n\n// Ensure we always have a selected server\nwatch(\n () => collection,\n (newCollection) => {\n if (!newCollection || newCollection.selectedServerUid) {\n return\n }\n\n const firstServer = collection.servers?.[0]\n\n if (firstServer) {\n collectionMutators.edit(collection.uid, 'selectedServerUid', firstServer)\n if (servers[firstServer]?.url) {\n emit('updateServer', servers[firstServer].url)\n }\n }\n },\n)\n\nconst serverUrlWithoutTrailingSlash = computed(() => {\n if (server?.url?.endsWith('/')) {\n return server.url.slice(0, -1)\n }\n return server?.url || ''\n})\n</script>\n<template>\n <ScalarListbox\n v-if=\"serverOptions.length > 1\"\n v-model=\"selectedServer\"\n class=\"group\"\n :options=\"serverOptions\"\n placement=\"bottom-start\"\n resize\n :target=\"target\"\n :teleport=\"`#${target}`\">\n <ScalarButton\n class=\"bg-b-1 text-c-1 h-auto w-full justify-start gap-1.5 overflow-x-auto rounded-t-none rounded-b-xl px-3 py-1.5 text-base font-normal whitespace-nowrap -outline-offset-1\"\n variant=\"ghost\">\n <span class=\"sr-only\">Server:</span>\n <span class=\"overflow-x-auto\">{{ serverUrlWithoutTrailingSlash }}</span>\n <ScalarIconCaretDown\n class=\"text-c-2 ui-open:rotate-180 mt-px size-3 transition-transform duration-100\"\n weight=\"bold\" />\n </ScalarButton>\n </ScalarListbox>\n <div\n v-else\n class=\"text-c-1 flex h-auto w-full items-center gap-0.75 rounded-b-xl px-3 py-1.5 text-base/5 whitespace-nowrap\">\n <span class=\"sr-only\">Server:</span>\n <span class=\"overflow-x-auto\">{{ serverUrlWithoutTrailingSlash }}</span>\n </div>\n</template>\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;ECcA,MAAM,QAAQ;EAWd,MAAM,OAAO;EAIb,MAAM,SAAS,OAAM;EACrB,MAAM,EAAE,oBAAoB,iBAAiB,YAAY,cAAa;;EAGtE,MAAM,wBAAwB,WAA0B,UAAkB;AACxE,OAAI,aAAa,UAAU,CACzB,QAAO,iBAAgB;AAIzB,OAAI,iBAAiB,OAAO;AAE1B,QAAI,MAAM,WAAW,SAAS,OAC5B,iBAAgB,KAAK,MAAM,UAAU,KAAK,qBAAqB,KAAI;AAErE,QAAI,MAAM,SAAS,cAAc;AAC/B,wBAAmB,KACjB,MAAM,WAAW,KACjB,qBACA,KAAA,EACF;AAEA,qBAAgB,QAAQ,OAAO,iCAAiC;MAC9D,OAAO,KAAA;MACP,SAAS,EAAE,uBAAuB,MAAM;MACzC,CAAA;eACQ,MAAM,SAAS,aAAa,MAAM,UAC3C,iBAAgB,KAAK,MAAM,UAAU,KAAK,qBAAqB,KAAI;AAErE;;AAIF,OAAI,MAAM,SAAS,gBAAgB,MAAM,YAAY;AAEnD,QAAI,MAAM,WAAW,SAAS,OAC5B,iBAAgB,KAAK,MAAM,UAAU,KAAK,qBAAqB,KAAI;AAErE,uBAAmB,KACjB,MAAM,WAAW,KACjB,qBACA,UACF;AAEA,oBAAgB,QAAQ,OAAO,iCAAiC;KAC9D,OAAO,QAAQ,YAAY;KAC3B,SAAS,EAAE,uBAAuB,MAAM;KACzC,CAAA;cAGM,MAAM,SAAS,aAAa,MAAM,UACzC,iBAAgB,KAAK,MAAM,UAAU,KAAK,qBAAqB,UAAS;;;EAK5E,MAAM,mBAAmB,eAAe;AACtC,OAAI,MAAM,SAAS,aAEjB,QACE,MAAM,WAAW,sBAAsB,MAAM,aAAa,MAC1D,CAAC,MAAM,WAAW;AAItB,OAAI,MAAM,SAAS,aAAa,MAAM,UACpC,QAAO,MAAM,UAAU,sBAAsB,MAAM,aAAa;AAGlE,UAAO;IACR;EAED,MAAM,gBAAgB,cAAsB;AAC1C,OAAI,CAAC,UACH,QAAO;GAGT,MAAM,SAAS,QAAQ;AAEvB,UAAO,OAAO,KAAK,QAAQ,aAAa,EAAE,CAAC,CAAC,SAAS;;EAGvD,MAAM,aAAa,eACX,iBAAiB,SAAS,aAAa,MAAM,QAAQ,OAAO,GAAG,CACvE;EAEA,MAAM,wBAAwB,KAAa,UAAkB;AAC3D,QAAK,mBAAmB,KAAK,MAAK;;EAGpC,MAAM,UAAU,eAAe,cAAa;;uBAG1C,mBAgCM,OAAA;IA/BJ,KAAI;IACJ,OAAK,eAAA,CAAC,qDAAmD,EAAA,sBAAA,CACxB,iBAAA,OAAgB,CAAA,CAAA;OACjD,mBAWS,UAXT,WACU,WAUD,QAVW,EAAA,iBAAsB,MAAA,OAAM,EAAA,GAAA,EAAA,EAAA;IAC7C,iBAAe,WAAA;IAChB,OAAK,CAAC,mEACE,iBAAA,QAAgB,oBAAA,eAAA;IACxB,MAAK;IACJ,SAAK,OAAA,OAAA,OAAA,MAAG,MAAM,qBAAqB,QAAA,aAAa,IAAI,EAAC;QACtD,YAAsD,MAAA,sBAAA,EAAA,EAA9B,UAAU,iBAAA,OAAgB,EAAA,MAAA,GAAA,CAAA,WAAA,CAAA,EAClD,mBAEO,QAFP,cAEO,gBADF,QAAA,aAAa,MAAK,EAAA,EAAA,CAAA,EAAA,IAAA,aAAA,EAKjB,WAAA,SAAA,WAAA,EADR,mBAcM,OAAA;;IAZH,IAAI,MAAA,OAAM;IACX,OAAM;IACL,SAAK,OAAA,OAAA,OAAA,KAAA,oBAAN,IAAW,CAAA,OAAA,CAAA;OACX,YAE4C,6BAAA;IADzC,WAAW,QAAA,QAAQ;IACnB,qBAAiB;+BAET,QAAA,QAAQ,eAAA,WAAA,EAAnB,mBAIM,OAAA,YAAA,CAHJ,mBAEM,OAFN,YAEM,CADJ,YAA8C,MAAA,eAAA,EAAA,EAA7B,OAAO,QAAA,OAAO,aAAA,EAAA,MAAA,GAAA,CAAA,QAAA,CAAA,CAAA,CAAA,CAAA,CAAA,IAAA,mBAAA,IAAA,KAAA,CAAA,EAAA,GAAA,aAAA,IAAA,mBAAA,IAAA,KAAA,CAAA,EAAA,EAAA;;;;;;;;;;;;;;;;;;;EEzHzC,MAAM,EAAE,WAAW,WAAU;EAC7B,MAAM,EAAE,SAAS,oBAAoB,QAAQ,mBAAmB,cAAa;EAE7E,MAAM,uBAAuB,eAC3B,QAAA,WAAW,SAAS,KAAK,eAAe;GACtC,IAAI;GACJ,OAAO,QAAQ,YAAY,OAAO;GACnC,EAAE,CACL;EAEA,MAAM,0BAA0B,eAE9B,QAAA,YAAY,SACR,QAAQ,cAAc,CAAC,QAAA,WAAW,SAAS,SAAS,UAAU,CAAA,CAC/D,KAAK,eAAe;GACnB,IAAI;GACJ,OAAO,QAAQ,YAAY,OAAO;GACnC,EAAE,CACP;;EAGA,MAAM,qBAAqB,eAEvB,qBAAqB,OAAO,UAAU,wBAAwB,OAAO,OACzE;AAGA,QAAM,OAAO,QAAA,kBAAkB,QAAA,UAAU,GAAG,CAAC,eAAe,kBAAkB;AAC5E,OACE,CAAC,iBACD,cAAc,qBACd,cAAc,kBAEd;GAGF,MAAM,cAAc,QAAA,WAAW,UAAU;AAEzC,OAAI,YACF,oBAAmB,KAAK,QAAA,WAAW,KAAK,qBAAqB,YAAW;IAE3E;;EAGD,MAAM,wBACJ,OAAO,eAAe,KAAK,EACzB,aAAa,cACd,CAAA;EAEH,MAAM,gCAAgC,eAAe;AACnD,OAAI,QAAA,QAAQ,KAAK,SAAS,IAAI,CAC5B,QAAO,QAAA,OAAO,IAAI,MAAM,GAAG,GAAE;AAE/B,UAAO,QAAA,QAAQ,OAAO;IACvB;EAED,MAAM,wBAAwB,KAAa,UAAkB;AAC3D,OAAI,CAAC,QAAA,OACH;GAGF,MAAM,YAAY,QAAA,OAAO,aAAa,EAAC;AACvC,aAAU,OAAO;IAAE,GAAG,UAAU;IAAM,SAAS;IAAM;AAErD,kBAAe,KAAK,QAAA,OAAO,KAAK,aAAa,UAAS;AAGtD,mBACE,QAAQ,OAAO,KACf,2CACA;IAAE;IAAK;IAAO,CAChB;;EAGF,MAAM,UAAU,eAAe,cAAa;;uBAG1C,YAwEgB,MAAA,cAAA,EAAA;IAvEd,KAAI;IACJ,OAAM;IACN,OAAA;IACC,QAAQ;IACT,WAAU;IACV,QAAA;IACC,QAAQ,QAAA;IACR,UAAQ,IAAM,QAAA;;IAgBJ,SAAO,SA0CV,EA1Cc,YAAK,CACzB,mBAyCM,OAAA;KAxCJ,OAAM;KACL,SAAO;;uBAER,mBAQ4C,UAAA,MAAA,WAPnB,qBAAA,QAAhB,iBAAY;0BADrB,YAQ4C,4BAAA;OANzC,KAAK,aAAa;OAClB,YAAY,QAAA;OACZ,WAAW,QAAA;OACX,QAAQ,QAAA;OACM;OACf,MAAK;OACJ,qBAAiB;;;;;;;;KACJ,mBAAA,SAAA,WAAA,EAAhB,mBAGW,UAAA,EAAA,KAAA,GAAA,EAAA,CAFT,YAAyB,MAAA,sBAAA,CAAA,EAAA,OAAA,OAAA,OAAA,KACzB,mBAA2D,OAAA,EAAtD,OAAM,iCAA+B,EAAC,cAAU,GAAA,EAAA,EAAA,GAAA,IAAA,mBAAA,IAAA,KAAA;uBAGvD,mBAQ4C,UAAA,MAAA,WAPnB,wBAAA,QAAhB,iBAAY;0BADrB,YAQ4C,4BAAA;OANzC,KAAK,aAAa;OAClB,YAAY,QAAA;OACZ,WAAW,QAAA;OACX,QAAQ,QAAA;OACM;OACf,MAAK;OACJ,qBAAiB;;;;;;;;KAEJ,MAAA,OAAM,KAAA,WAAA,WAAA,EACpB,mBAUS,UAAA;;MATP,OAAM;MACN,MAAK;MACJ,SAAO;SACR,mBAIM,OAJN,cAIM,CAHJ,YAEc,MAAA,WAAA,EAAA;MADZ,MAAK;MACL,MAAK;qCAET,mBAAuB,QAAA,MAAjB,cAAU,GAAA,EAAA,CAAA,IAAA,mBAAA,IAAA,KAAA;;IAKb,UAAQ,cAEyC,CAD1D,YAC0D,MAAA,uBAAA,EAAA,EAAxD,OAAM,iDAA+C,CAAA,CAAA,CAAA;2BA/C1C,CAdf,YAce,MAAA,aAAA,EAAA;KAbb,OAAM;KACN,SAAQ;;4BAKG,CAHH,QAAA,WAAW,qBAAqB,QAAA,WAAW,qBAAA,WAAA,EADnD,mBAIW,UAAA,EAAA,KAAA,GAAA,EAAA,CAAA,OAAA,OAAA,OAAA,KAFT,mBAAoC,QAAA,EAA9B,OAAM,WAAS,EAAC,WAAO,GAAA,GAAA,gBAAO,MACpC,gBAAG,8BAAA,MAA6B,EAAA,EAAA,CAAA,EAAA,GAAA,KAAA,WAAA,EAElC,mBAKW,UAAA,EAAA,KAAA,GAAA,EAAA,CAAA,OAAA,OAAA,OAAA,KAJT,mBAAuC,QAAA,EAAjC,OAAM,WAAS,EAAC,cAAU,GAAA,GAChC,YAEc,MAAA,WAAA,EAAA;MADZ,MAAK;MACL,MAAK;;;;;;;;;;;;;;;;;;;;;;;;;;;;EEzGf,MAAM,OAAO;EAIb,MAAM,EAAE,SAAS,uBAAuB,cAAa;EAErD,MAAM,gBAAgB,eACpB,QAAA,YAAY,QAAQ,KAAK,eAAe;GACtC,IAAI;GACJ,OAAO,QAAQ,YAAY,OAAO;GACnC,EAAE,CACL;EAEA,MAAM,iBAAiB,SAAmC;GACxD,WACE,QAAA,SACI,cAAc,MAAM,MAAM,WAAW,OAAO,OAAO,QAAA,OAAO,IAAG,GAC7D,KAAA;GACN,MAAM,WAAW;AACf,QAAI,CAAC,OACH;AAEF,uBAAmB,KACjB,QAAA,WAAW,KACX,qBACA,OAAO,GACT;IACA,MAAM,YAAY,QAAQ,OAAO,KAAK;AACtC,QAAI,UACF,MAAK,gBAAgB,UAAS;;GAGnC,CAAA;AAGD,cACQ,QAAA,aACL,kBAAkB;AACjB,OAAI,CAAC,iBAAiB,cAAc,kBAClC;GAGF,MAAM,cAAc,QAAA,WAAW,UAAU;AAEzC,OAAI,aAAa;AACf,uBAAmB,KAAK,QAAA,WAAW,KAAK,qBAAqB,YAAW;AACxE,QAAI,QAAQ,cAAc,IACxB,MAAK,gBAAgB,QAAQ,aAAa,IAAG;;IAIrD;EAEA,MAAM,gCAAgC,eAAe;AACnD,OAAI,QAAA,QAAQ,KAAK,SAAS,IAAI,CAC5B,QAAO,QAAA,OAAO,IAAI,MAAM,GAAG,GAAE;AAE/B,UAAO,QAAA,QAAQ,OAAO;IACvB;;UAIS,cAAA,MAAc,SAAM,KAAA,WAAA,EAD5B,YAkBgB,MAAA,cAAA,EAAA;;gBAhBL,eAAA;gFAAc,QAAA;IACvB,OAAM;IACL,SAAS,cAAA;IACV,WAAU;IACV,QAAA;IACC,QAAQ,QAAA;IACR,UAAQ,IAAM,QAAA;;2BASA,CARf,YAQe,MAAA,aAAA,EAAA;KAPb,OAAM;KACN,SAAQ;;4BAC4B;gCAApC,mBAAoC,QAAA,EAA9B,OAAM,WAAS,EAAC,WAAO,GAAA;MAC7B,mBAAwE,QAAxE,YAAwE,gBAAvC,8BAAA,MAA6B,EAAA,EAAA;MAC9D,YAEkB,MAAA,oBAAA,EAAA;OADhB,OAAM;OACN,QAAO;;;;;;;;;;;uBAGb,mBAKM,OALN,YAKM,CAAA,OAAA,OAAA,OAAA,KAFJ,mBAAoC,QAAA,EAA9B,OAAM,WAAS,EAAC,WAAO,GAAA,GAC7B,mBAAwE,QAAxE,YAAwE,gBAAvC,8BAAA,MAA6B,EAAA,EAAA,CAAA,CAAA"}
|
|
@@ -0,0 +1,145 @@
|
|
|
1
|
+
import { Fragment, computed, createBlock, createCommentVNode, createElementBlock, createElementVNode, createTextVNode, createVNode, defineComponent, mergeProps, normalizeClass, openBlock, renderList, toDisplayString, unref, useId, vModelText, withCtx, withDirectives } from "vue";
|
|
2
|
+
import { ScalarButton, ScalarListbox } from "@scalar/components";
|
|
3
|
+
import { ScalarIconCaretDown } from "@scalar/icons";
|
|
4
|
+
//#region src/components/Server/ServerVariablesSelect.vue?vue&type=script&setup=true&lang.ts
|
|
5
|
+
var _hoisted_1$1 = {
|
|
6
|
+
key: 0,
|
|
7
|
+
class: "sr-only"
|
|
8
|
+
};
|
|
9
|
+
//#endregion
|
|
10
|
+
//#region src/components/Server/ServerVariablesSelect.vue
|
|
11
|
+
var ServerVariablesSelect_default = /* @__PURE__ */ defineComponent({
|
|
12
|
+
__name: "ServerVariablesSelect",
|
|
13
|
+
props: {
|
|
14
|
+
enum: {},
|
|
15
|
+
value: {},
|
|
16
|
+
controls: {}
|
|
17
|
+
},
|
|
18
|
+
emits: ["change"],
|
|
19
|
+
setup(__props, { emit: __emit }) {
|
|
20
|
+
const props = __props;
|
|
21
|
+
const emit = __emit;
|
|
22
|
+
const options = computed(() => props.enum.map((s) => ({
|
|
23
|
+
id: s,
|
|
24
|
+
label: s
|
|
25
|
+
})));
|
|
26
|
+
const selected = computed({
|
|
27
|
+
get: () => options.value.find((opt) => opt.id === props.value),
|
|
28
|
+
set: (opt) => emit("change", opt?.id ?? "")
|
|
29
|
+
});
|
|
30
|
+
return (_ctx, _cache) => {
|
|
31
|
+
return openBlock(), createBlock(unref(ScalarListbox), {
|
|
32
|
+
modelValue: selected.value,
|
|
33
|
+
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => selected.value = $event),
|
|
34
|
+
options: options.value
|
|
35
|
+
}, {
|
|
36
|
+
default: withCtx(() => [createVNode(unref(ScalarButton), {
|
|
37
|
+
"aria-controls": __props.controls,
|
|
38
|
+
class: "group/button h-8 gap-1.5 p-1.5 text-base font-normal",
|
|
39
|
+
variant: "ghost"
|
|
40
|
+
}, {
|
|
41
|
+
default: withCtx(() => [createElementVNode("span", { class: normalizeClass({ "text-c-1": __props.value }) }, [__props.value ? (openBlock(), createElementBlock("span", _hoisted_1$1, " Selected: ")) : createCommentVNode("", true), createTextVNode(" " + toDisplayString(__props.value || "Select value"), 1)], 2), createVNode(unref(ScalarIconCaretDown), {
|
|
42
|
+
weight: "bold",
|
|
43
|
+
class: "mt-0.25 size-3 transition-transform duration-100 group-aria-expanded/button:rotate-180"
|
|
44
|
+
})]),
|
|
45
|
+
_: 1
|
|
46
|
+
}, 8, ["aria-controls"])]),
|
|
47
|
+
_: 1
|
|
48
|
+
}, 8, ["modelValue", "options"]);
|
|
49
|
+
};
|
|
50
|
+
}
|
|
51
|
+
});
|
|
52
|
+
//#endregion
|
|
53
|
+
//#region src/components/Server/ServerVariablesTextbox.vue
|
|
54
|
+
var ServerVariablesTextbox_default = /* @__PURE__ */ defineComponent({
|
|
55
|
+
__name: "ServerVariablesTextbox",
|
|
56
|
+
props: {
|
|
57
|
+
value: {},
|
|
58
|
+
controls: {}
|
|
59
|
+
},
|
|
60
|
+
emits: ["change"],
|
|
61
|
+
setup(__props, { emit: __emit }) {
|
|
62
|
+
const props = __props;
|
|
63
|
+
const emit = __emit;
|
|
64
|
+
const model = computed({
|
|
65
|
+
get: () => props.value,
|
|
66
|
+
set: (v) => emit("change", v)
|
|
67
|
+
});
|
|
68
|
+
return (_ctx, _cache) => {
|
|
69
|
+
return withDirectives((openBlock(), createElementBlock("input", mergeProps({ "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => model.value = $event) }, __props.controls ? {
|
|
70
|
+
..._ctx.$attrs,
|
|
71
|
+
"aria-controls": __props.controls
|
|
72
|
+
} : {}, {
|
|
73
|
+
autocomplete: "off",
|
|
74
|
+
class: "text-c-1 w-full border-transparent px-1.5 py-1.25 -outline-offset-1 group-last/label:rounded-br-lg",
|
|
75
|
+
placeholder: "value",
|
|
76
|
+
spellcheck: "false",
|
|
77
|
+
type: "text"
|
|
78
|
+
}), null, 16)), [[vModelText, model.value]]);
|
|
79
|
+
};
|
|
80
|
+
}
|
|
81
|
+
});
|
|
82
|
+
//#endregion
|
|
83
|
+
//#region src/components/Server/ServerVariablesForm.vue?vue&type=script&setup=true&lang.ts
|
|
84
|
+
var _hoisted_1 = ["for"];
|
|
85
|
+
//#endregion
|
|
86
|
+
//#region src/components/Server/ServerVariablesForm.vue
|
|
87
|
+
var ServerVariablesForm_default = /* @__PURE__ */ defineComponent({
|
|
88
|
+
__name: "ServerVariablesForm",
|
|
89
|
+
props: {
|
|
90
|
+
variables: {},
|
|
91
|
+
values: {},
|
|
92
|
+
controls: {},
|
|
93
|
+
layout: { default: "client" }
|
|
94
|
+
},
|
|
95
|
+
emits: ["update:variable"],
|
|
96
|
+
setup(__props, { emit: __emit }) {
|
|
97
|
+
const emit = __emit;
|
|
98
|
+
const id = useId();
|
|
99
|
+
function setVariable(name, value) {
|
|
100
|
+
emit("update:variable", name, value);
|
|
101
|
+
}
|
|
102
|
+
const getVariable = (name) => {
|
|
103
|
+
return (__props.values?.[name] ?? __props.variables?.[name]?.default ?? "").toString();
|
|
104
|
+
};
|
|
105
|
+
return (_ctx, _cache) => {
|
|
106
|
+
return __props.variables && Object.keys(__props.variables ?? {}).length ? (openBlock(true), createElementBlock(Fragment, { key: 0 }, renderList(Object.keys(__props.variables), (name) => {
|
|
107
|
+
return openBlock(), createElementBlock("div", {
|
|
108
|
+
key: name,
|
|
109
|
+
class: normalizeClass(["group/label flex h-8 w-full", __props.layout === "reference" && "items-center border-x border-b last:rounded-b-lg"])
|
|
110
|
+
}, [createElementVNode("label", {
|
|
111
|
+
class: "flex items-center py-2 pl-3 group-has-[input]/label:mr-0 after:content-[':']",
|
|
112
|
+
for: `${unref(id)}-${name}`
|
|
113
|
+
}, toDisplayString(name), 9, _hoisted_1), __props.variables?.[name]?.enum?.length ? (openBlock(), createBlock(ServerVariablesSelect_default, {
|
|
114
|
+
key: 0,
|
|
115
|
+
id: `${unref(id)}-${name}`,
|
|
116
|
+
controls: __props.controls,
|
|
117
|
+
enum: __props.variables[name]?.enum?.map((v) => `${v}`) ?? [],
|
|
118
|
+
value: getVariable(name),
|
|
119
|
+
onChange: (s) => setVariable(name, s)
|
|
120
|
+
}, null, 8, [
|
|
121
|
+
"id",
|
|
122
|
+
"controls",
|
|
123
|
+
"enum",
|
|
124
|
+
"value",
|
|
125
|
+
"onChange"
|
|
126
|
+
])) : (openBlock(), createBlock(ServerVariablesTextbox_default, {
|
|
127
|
+
key: 1,
|
|
128
|
+
id: `${unref(id)}-${name}`,
|
|
129
|
+
controls: __props.controls,
|
|
130
|
+
value: getVariable(name),
|
|
131
|
+
onChange: (s) => setVariable(name, s)
|
|
132
|
+
}, null, 8, [
|
|
133
|
+
"id",
|
|
134
|
+
"controls",
|
|
135
|
+
"value",
|
|
136
|
+
"onChange"
|
|
137
|
+
]))], 2);
|
|
138
|
+
}), 128)) : createCommentVNode("", true);
|
|
139
|
+
};
|
|
140
|
+
}
|
|
141
|
+
});
|
|
142
|
+
//#endregion
|
|
143
|
+
export { ServerVariablesForm_default as t };
|
|
144
|
+
|
|
145
|
+
//# sourceMappingURL=ServerVariablesForm-BRZ9XC8o.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ServerVariablesForm-BRZ9XC8o.js","names":["$attrs"],"sources":["../src/components/Server/ServerVariablesSelect.vue","../src/components/Server/ServerVariablesSelect.vue","../src/components/Server/ServerVariablesTextbox.vue","../src/components/Server/ServerVariablesTextbox.vue","../src/components/Server/ServerVariablesForm.vue","../src/components/Server/ServerVariablesForm.vue"],"sourcesContent":["<script setup lang=\"ts\">\nimport {\n ScalarButton,\n ScalarListbox,\n type ScalarListboxOption,\n} from '@scalar/components'\nimport { ScalarIconCaretDown } from '@scalar/icons'\nimport { computed } from 'vue'\n\nconst props = defineProps<{\n enum: string[]\n value: string\n controls: string | undefined\n}>()\n\nconst emit = defineEmits<{\n (e: 'change', v: string): void\n}>()\n\nconst options = computed<ScalarListboxOption[]>(() =>\n props.enum.map((s) => ({ id: s, label: s })),\n)\n\nconst selected = computed<ScalarListboxOption | undefined>({\n get: () => options.value.find((opt) => opt.id === props.value),\n set: (opt?: ScalarListboxOption) => emit('change', opt?.id ?? ''),\n})\n</script>\n<template>\n <ScalarListbox\n v-model=\"selected\"\n :options=\"options\">\n <ScalarButton\n :aria-controls=\"controls\"\n class=\"group/button h-8 gap-1.5 p-1.5 text-base font-normal\"\n variant=\"ghost\">\n <span :class=\"{ 'text-c-1': value }\">\n <span\n v-if=\"value\"\n class=\"sr-only\">\n Selected:\n </span>\n {{ value || 'Select value' }}\n </span>\n <ScalarIconCaretDown\n weight=\"bold\"\n class=\"mt-0.25 size-3 transition-transform duration-100 group-aria-expanded/button:rotate-180\" />\n </ScalarButton>\n </ScalarListbox>\n</template>\n","<script setup lang=\"ts\">\nimport {\n ScalarButton,\n ScalarListbox,\n type ScalarListboxOption,\n} from '@scalar/components'\nimport { ScalarIconCaretDown } from '@scalar/icons'\nimport { computed } from 'vue'\n\nconst props = defineProps<{\n enum: string[]\n value: string\n controls: string | undefined\n}>()\n\nconst emit = defineEmits<{\n (e: 'change', v: string): void\n}>()\n\nconst options = computed<ScalarListboxOption[]>(() =>\n props.enum.map((s) => ({ id: s, label: s })),\n)\n\nconst selected = computed<ScalarListboxOption | undefined>({\n get: () => options.value.find((opt) => opt.id === props.value),\n set: (opt?: ScalarListboxOption) => emit('change', opt?.id ?? ''),\n})\n</script>\n<template>\n <ScalarListbox\n v-model=\"selected\"\n :options=\"options\">\n <ScalarButton\n :aria-controls=\"controls\"\n class=\"group/button h-8 gap-1.5 p-1.5 text-base font-normal\"\n variant=\"ghost\">\n <span :class=\"{ 'text-c-1': value }\">\n <span\n v-if=\"value\"\n class=\"sr-only\">\n Selected:\n </span>\n {{ value || 'Select value' }}\n </span>\n <ScalarIconCaretDown\n weight=\"bold\"\n class=\"mt-0.25 size-3 transition-transform duration-100 group-aria-expanded/button:rotate-180\" />\n </ScalarButton>\n </ScalarListbox>\n</template>\n","<script setup lang=\"ts\">\nimport { computed } from 'vue'\n\nconst props = defineProps<{\n value: string\n controls: string | undefined\n}>()\n\nconst emit = defineEmits<{\n (e: 'change', v: string): void\n}>()\n\nconst model = computed<string>({\n get: () => props.value,\n set: (v) => emit('change', v),\n})\n</script>\n<template>\n <input\n v-model=\"model\"\n v-bind=\"controls ? { ...$attrs, 'aria-controls': controls } : {}\"\n autocomplete=\"off\"\n class=\"text-c-1 w-full border-transparent px-1.5 py-1.25 -outline-offset-1 group-last/label:rounded-br-lg\"\n placeholder=\"value\"\n spellcheck=\"false\"\n type=\"text\" />\n</template>\n","<script setup lang=\"ts\">\nimport { computed } from 'vue'\n\nconst props = defineProps<{\n value: string\n controls: string | undefined\n}>()\n\nconst emit = defineEmits<{\n (e: 'change', v: string): void\n}>()\n\nconst model = computed<string>({\n get: () => props.value,\n set: (v) => emit('change', v),\n})\n</script>\n<template>\n <input\n v-model=\"model\"\n v-bind=\"controls ? { ...$attrs, 'aria-controls': controls } : {}\"\n autocomplete=\"off\"\n class=\"text-c-1 w-full border-transparent px-1.5 py-1.25 -outline-offset-1 group-last/label:rounded-br-lg\"\n placeholder=\"value\"\n spellcheck=\"false\"\n type=\"text\" />\n</template>\n","<script setup lang=\"ts\">\nimport { useId } from 'vue'\n\nimport ServerVariablesSelect from '@/components/Server/ServerVariablesSelect.vue'\nimport ServerVariablesTextbox from '@/components/Server/ServerVariablesTextbox.vue'\nimport type {\n ServerVariables,\n ServerVariableValues,\n} from '@/components/Server/types'\n\nconst {\n values,\n variables,\n layout = 'client',\n} = defineProps<{\n variables?: ServerVariables | undefined\n values?: ServerVariableValues\n /** The ID of the input controlled by the variables form */\n controls?: string\n /** The layout of the server variables form */\n layout?: 'client' | 'reference'\n}>()\n\nconst emit = defineEmits<{\n (e: 'update:variable', name: string, value: string): void\n}>()\n\nconst id = useId()\n\nfunction setVariable(name: string, value: string) {\n emit('update:variable', name, value)\n}\n\nconst getVariable = (name: string) => {\n return (values?.[name] ?? variables?.[name]?.default ?? '').toString()\n}\n</script>\n<template>\n <template v-if=\"variables && Object.keys(variables ?? {}).length\">\n <template\n v-for=\"name in Object.keys(variables)\"\n :key=\"name\">\n <div\n class=\"group/label flex h-8 w-full\"\n :class=\"\n layout === 'reference' &&\n 'items-center border-x border-b last:rounded-b-lg'\n \">\n <label\n class=\"flex items-center py-2 pl-3 group-has-[input]/label:mr-0 after:content-[':']\"\n :for=\"`${id}-${name}`\">\n {{ name }}\n </label>\n <template v-if=\"variables?.[name]?.enum?.length\">\n <ServerVariablesSelect\n :id=\"`${id}-${name}`\"\n :controls=\"controls\"\n :enum=\"variables[name]?.enum?.map((v) => `${v}`) ?? []\"\n :value=\"getVariable(name)\"\n @change=\"(s) => setVariable(name, s)\" />\n </template>\n <template v-else>\n <ServerVariablesTextbox\n :id=\"`${id}-${name}`\"\n :controls=\"controls\"\n :value=\"getVariable(name)\"\n @change=\"(s) => setVariable(name, s)\" />\n </template>\n </div>\n </template>\n </template>\n</template>\n","<script setup lang=\"ts\">\nimport { useId } from 'vue'\n\nimport ServerVariablesSelect from '@/components/Server/ServerVariablesSelect.vue'\nimport ServerVariablesTextbox from '@/components/Server/ServerVariablesTextbox.vue'\nimport type {\n ServerVariables,\n ServerVariableValues,\n} from '@/components/Server/types'\n\nconst {\n values,\n variables,\n layout = 'client',\n} = defineProps<{\n variables?: ServerVariables | undefined\n values?: ServerVariableValues\n /** The ID of the input controlled by the variables form */\n controls?: string\n /** The layout of the server variables form */\n layout?: 'client' | 'reference'\n}>()\n\nconst emit = defineEmits<{\n (e: 'update:variable', name: string, value: string): void\n}>()\n\nconst id = useId()\n\nfunction setVariable(name: string, value: string) {\n emit('update:variable', name, value)\n}\n\nconst getVariable = (name: string) => {\n return (values?.[name] ?? variables?.[name]?.default ?? '').toString()\n}\n</script>\n<template>\n <template v-if=\"variables && Object.keys(variables ?? {}).length\">\n <template\n v-for=\"name in Object.keys(variables)\"\n :key=\"name\">\n <div\n class=\"group/label flex h-8 w-full\"\n :class=\"\n layout === 'reference' &&\n 'items-center border-x border-b last:rounded-b-lg'\n \">\n <label\n class=\"flex items-center py-2 pl-3 group-has-[input]/label:mr-0 after:content-[':']\"\n :for=\"`${id}-${name}`\">\n {{ name }}\n </label>\n <template v-if=\"variables?.[name]?.enum?.length\">\n <ServerVariablesSelect\n :id=\"`${id}-${name}`\"\n :controls=\"controls\"\n :enum=\"variables[name]?.enum?.map((v) => `${v}`) ?? []\"\n :value=\"getVariable(name)\"\n @change=\"(s) => setVariable(name, s)\" />\n </template>\n <template v-else>\n <ServerVariablesTextbox\n :id=\"`${id}-${name}`\"\n :controls=\"controls\"\n :value=\"getVariable(name)\"\n @change=\"(s) => setVariable(name, s)\" />\n </template>\n </div>\n </template>\n </template>\n</template>\n"],"mappings":";;;;;;;;;;;;;;;;;;;ECSA,MAAM,QAAQ;EAMd,MAAM,OAAO;EAIb,MAAM,UAAU,eACd,MAAM,KAAK,KAAK,OAAO;GAAE,IAAI;GAAG,OAAO;GAAG,EAAE,CAC9C;EAEA,MAAM,WAAW,SAA0C;GACzD,WAAW,QAAQ,MAAM,MAAM,QAAQ,IAAI,OAAO,MAAM,MAAM;GAC9D,MAAM,QAA8B,KAAK,UAAU,KAAK,MAAM,GAAG;GAClE,CAAA;;uBAGC,YAmBgB,MAAA,cAAA,EAAA;gBAlBL,SAAA;0EAAQ,QAAA;IAChB,SAAS,QAAA;;2BAgBK,CAff,YAee,MAAA,aAAA,EAAA;KAdZ,iBAAe,QAAA;KAChB,OAAM;KACN,SAAQ;;4BAQD,CAPP,mBAOO,QAAA,EAPA,OAAK,eAAA,EAAA,YAAgB,QAAA,OAAK,CAAA,EAAA,EAAA,CAEvB,QAAA,SAAA,WAAA,EADR,mBAIO,QAJP,cAEkB,cAElB,IAAA,mBAAA,IAAA,KAAA,EAAA,gBAAO,MACP,gBAAG,QAAA,SAAK,eAAA,EAAA,EAAA,CAAA,EAAA,EAAA,EAEV,YAEmG,MAAA,oBAAA,EAAA;MADjG,QAAO;MACP,OAAM;;;;;;;;;;;;;;;;;;;EE3Cd,MAAM,QAAQ;EAKd,MAAM,OAAO;EAIb,MAAM,QAAQ,SAAiB;GAC7B,WAAW,MAAM;GACjB,MAAM,MAAM,KAAK,UAAU,EAAE;GAC9B,CAAA;;uCAGC,mBAOgB,SAPhB,WAOgB,EAAA,uBAAA,OAAA,OAAA,OAAA,MAAA,WAAA,MANA,QAAA,SAAA,EACN,QAAA,WAAQ;IAAA,GAAQA,KAAAA;IAAM,iBAAmB,QAAA;IAAQ,GAAA,EAAA,EAAA;IACzD,cAAa;IACb,OAAM;IACN,aAAY;IACZ,YAAW;IACX,MAAK;iCANI,MAAA,MAAK,CAAA,CAAA;;;;;;;;;;;;;;;;;;;EEIlB,MAAM,OAAO;EAIb,MAAM,KAAK,OAAM;EAEjB,SAAS,YAAY,MAAc,OAAe;AAChD,QAAK,mBAAmB,MAAM,MAAK;;EAGrC,MAAM,eAAe,SAAiB;AACpC,WAAQ,QAAA,SAAS,SAAS,QAAA,YAAY,OAAO,WAAW,IAAI,UAAS;;;UAIrD,QAAA,aAAa,OAAO,KAAK,QAAA,aAAS,EAAA,CAAA,CAAQ,UAAA,UAAA,KAAA,EACxD,mBA8BW,UAAA,EAAA,KAAA,GAAA,EAAA,WA7BM,OAAO,KAAK,QAAA,UAAS,GAA7B,SAAI;wBAEX,mBA0BM,OAAA;UA3BA;KAEJ,OAAK,eAAA,CAAC,+BACa,QAAA,WAAM,eAAA,mDAAA,CAAA;QAIzB,mBAIQ,SAAA;KAHN,OAAM;KACL,KAAG,GAAK,MAAA,GAAE,CAAA,GAAI;uBACZ,KAAI,EAAA,GAAA,WAAA,EAEO,QAAA,YAAY,OAAO,MAAM,UAAA,WAAA,EACvC,YAK0C,+BAAA;;KAJvC,IAAE,GAAK,MAAA,GAAE,CAAA,GAAI;KACb,UAAU,QAAA;KACV,MAAM,QAAA,UAAU,OAAO,MAAM,KAAK,MAAC,GAAQ,IAAC,IAAA,EAAA;KAC5C,OAAO,YAAY,KAAI;KACvB,WAAS,MAAM,YAAY,MAAM,EAAC;;;;;;;wBAGrC,YAI0C,gCAAA;;KAHvC,IAAE,GAAK,MAAA,GAAE,CAAA,GAAI;KACb,UAAU,QAAA;KACV,OAAO,YAAY,KAAI;KACvB,WAAS,MAAM,YAAY,MAAM,EAAC"}
|