@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,909 @@
|
|
|
1
|
+
import { t as _plugin_vue_export_helper_default } from "./_plugin-vue_export-helper-BmmBcIzD.js";
|
|
2
|
+
import { i as useEditor, t as useJsonPointerLinkSupport } from "./editor-BZ_J0eze.js";
|
|
3
|
+
import { Fragment, computed, createBlock, createCommentVNode, createElementBlock, createElementVNode, createTextVNode, createVNode, defineComponent, nextTick, normalizeClass, onBeforeUnmount, onMounted, openBlock, ref, renderList, shallowRef, toDisplayString, toValue, unref, watch, withCtx } from "vue";
|
|
4
|
+
import { ScalarButton, ScalarHotkey, ScalarLoading, ScalarToggle, useLoadingState } from "@scalar/components";
|
|
5
|
+
import { ScalarIconArrowsIn, ScalarIconArrowsOut, ScalarIconCaretDown, ScalarIconCaretRight, ScalarIconWarning, ScalarIconXCircle } from "@scalar/icons";
|
|
6
|
+
import { isMap, isPair, isScalar, isSeq, parse, parseDocument, stringify } from "yaml";
|
|
7
|
+
import { isObject } from "@scalar/helpers/object/is-object";
|
|
8
|
+
import { isHttpMethod } from "@scalar/helpers/http/is-http-method";
|
|
9
|
+
import * as monaco$1 from "monaco-editor";
|
|
10
|
+
import { debounce } from "@scalar/helpers/general/debounce";
|
|
11
|
+
import * as monaco from "monaco-editor/esm/vs/editor/editor.api.js";
|
|
12
|
+
import { configureMonacoYaml } from "monaco-yaml";
|
|
13
|
+
//#region src/v2/features/editor/helpers/json/json-ast.ts
|
|
14
|
+
/**
|
|
15
|
+
* Traverses the AST of a JSON document to find the node at the provided JsonPath.
|
|
16
|
+
* Returns undefined if the path does not exist in the AST.
|
|
17
|
+
*
|
|
18
|
+
* @param node - The root AST node to begin traversal from.
|
|
19
|
+
* @param path - The path to traverse within the AST, as an array of keys/indices.
|
|
20
|
+
* @returns The AST node at the specified path, or undefined if not found.
|
|
21
|
+
*/
|
|
22
|
+
var getJsonAstNodeAtPath = (node, path) => {
|
|
23
|
+
let current = node;
|
|
24
|
+
for (const segment of path) {
|
|
25
|
+
if (!current) return;
|
|
26
|
+
if (current.type === "object") {
|
|
27
|
+
const key = String(segment);
|
|
28
|
+
current = current.properties.find((p) => p.keyNode.value === key)?.valueNode;
|
|
29
|
+
continue;
|
|
30
|
+
}
|
|
31
|
+
if (current.type === "array") {
|
|
32
|
+
const index = typeof segment === "number" ? segment : Number.parseInt(String(segment), 10);
|
|
33
|
+
if (!Number.isFinite(index) || index < 0 || index >= current.items.length) return;
|
|
34
|
+
current = current.items[index];
|
|
35
|
+
continue;
|
|
36
|
+
}
|
|
37
|
+
return;
|
|
38
|
+
}
|
|
39
|
+
return current;
|
|
40
|
+
};
|
|
41
|
+
//#endregion
|
|
42
|
+
//#region src/v2/features/editor/helpers/json/get-json-ast-node-from-path.ts
|
|
43
|
+
/**
|
|
44
|
+
* Retrieves a JSON AST node from a Monaco editor model at the specified JSON path.
|
|
45
|
+
*
|
|
46
|
+
* Utilizes Monaco's JSON worker to parse the document and returns the AST node
|
|
47
|
+
* located at the given path, or null if not found.
|
|
48
|
+
*
|
|
49
|
+
* @param model - The Monaco editor text model representing the JSON document.
|
|
50
|
+
* @param path - The JSON path to locate the AST node.
|
|
51
|
+
* @returns A promise resolving to the AST node at the path, or null if not found.
|
|
52
|
+
*/
|
|
53
|
+
var getJsonAstNodeFromPath = async (model, path) => {
|
|
54
|
+
const jsonDocument = await (await (await monaco$1.languages.json.getWorker())(model.uri)).parseJSONDocument(model.uri.toString());
|
|
55
|
+
if (!jsonDocument?.root) return null;
|
|
56
|
+
return getJsonAstNodeAtPath(jsonDocument.root, path) ?? null;
|
|
57
|
+
};
|
|
58
|
+
var openapi_3_1_schema_default = {
|
|
59
|
+
$id: "https://spec.openapis.org/oas/3.1/schema/2025-11-23",
|
|
60
|
+
$schema: "https://json-schema.org/draft/2020-12/schema",
|
|
61
|
+
description: "The description of OpenAPI v3.1.x Documents without Schema Object validation",
|
|
62
|
+
type: "object",
|
|
63
|
+
properties: {
|
|
64
|
+
"openapi": {
|
|
65
|
+
"type": "string",
|
|
66
|
+
"pattern": "^3\\.1\\.\\d+(-.+)?$"
|
|
67
|
+
},
|
|
68
|
+
"info": { "$ref": "#/$defs/info" },
|
|
69
|
+
"jsonSchemaDialect": {
|
|
70
|
+
"type": "string",
|
|
71
|
+
"format": "uri-reference",
|
|
72
|
+
"default": "https://spec.openapis.org/oas/3.1/dialect/2024-11-10"
|
|
73
|
+
},
|
|
74
|
+
"servers": {
|
|
75
|
+
"type": "array",
|
|
76
|
+
"items": { "$ref": "#/$defs/server" },
|
|
77
|
+
"default": [{ "url": "/" }]
|
|
78
|
+
},
|
|
79
|
+
"paths": { "$ref": "#/$defs/paths" },
|
|
80
|
+
"webhooks": {
|
|
81
|
+
"type": "object",
|
|
82
|
+
"additionalProperties": { "$ref": "#/$defs/path-item" }
|
|
83
|
+
},
|
|
84
|
+
"components": { "$ref": "#/$defs/components" },
|
|
85
|
+
"security": {
|
|
86
|
+
"type": "array",
|
|
87
|
+
"items": { "$ref": "#/$defs/security-requirement" }
|
|
88
|
+
},
|
|
89
|
+
"tags": {
|
|
90
|
+
"type": "array",
|
|
91
|
+
"items": { "$ref": "#/$defs/tag" }
|
|
92
|
+
},
|
|
93
|
+
"externalDocs": { "$ref": "#/$defs/external-documentation" }
|
|
94
|
+
},
|
|
95
|
+
required: ["openapi", "info"],
|
|
96
|
+
anyOf: [
|
|
97
|
+
{ "required": ["paths"] },
|
|
98
|
+
{ "required": ["components"] },
|
|
99
|
+
{ "required": ["webhooks"] }
|
|
100
|
+
],
|
|
101
|
+
$ref: "#/$defs/specification-extensions",
|
|
102
|
+
unevaluatedProperties: false,
|
|
103
|
+
$defs: /* @__PURE__ */ JSON.parse("{\"info\":{\"$comment\":\"https://spec.openapis.org/oas/v3.1#info-object\",\"type\":\"object\",\"properties\":{\"title\":{\"type\":\"string\"},\"summary\":{\"type\":\"string\"},\"description\":{\"type\":\"string\"},\"termsOfService\":{\"type\":\"string\",\"format\":\"uri-reference\"},\"contact\":{\"$ref\":\"#/$defs/contact\"},\"license\":{\"$ref\":\"#/$defs/license\"},\"version\":{\"type\":\"string\"}},\"required\":[\"title\",\"version\"],\"$ref\":\"#/$defs/specification-extensions\",\"unevaluatedProperties\":false},\"contact\":{\"$comment\":\"https://spec.openapis.org/oas/v3.1#contact-object\",\"type\":\"object\",\"properties\":{\"name\":{\"type\":\"string\"},\"url\":{\"type\":\"string\",\"format\":\"uri-reference\"},\"email\":{\"type\":\"string\",\"format\":\"email\"}},\"$ref\":\"#/$defs/specification-extensions\",\"unevaluatedProperties\":false},\"license\":{\"$comment\":\"https://spec.openapis.org/oas/v3.1#license-object\",\"type\":\"object\",\"properties\":{\"name\":{\"type\":\"string\"},\"identifier\":{\"type\":\"string\"},\"url\":{\"type\":\"string\",\"format\":\"uri-reference\"}},\"required\":[\"name\"],\"dependentSchemas\":{\"identifier\":{\"not\":{\"required\":[\"url\"]}}},\"$ref\":\"#/$defs/specification-extensions\",\"unevaluatedProperties\":false},\"server\":{\"$comment\":\"https://spec.openapis.org/oas/v3.1#server-object\",\"type\":\"object\",\"properties\":{\"url\":{\"type\":\"string\"},\"description\":{\"type\":\"string\"},\"variables\":{\"type\":\"object\",\"additionalProperties\":{\"$ref\":\"#/$defs/server-variable\"}}},\"required\":[\"url\"],\"$ref\":\"#/$defs/specification-extensions\",\"unevaluatedProperties\":false},\"server-variable\":{\"$comment\":\"https://spec.openapis.org/oas/v3.1#server-variable-object\",\"type\":\"object\",\"properties\":{\"enum\":{\"type\":\"array\",\"items\":{\"type\":\"string\"},\"minItems\":1},\"default\":{\"type\":\"string\"},\"description\":{\"type\":\"string\"}},\"required\":[\"default\"],\"$ref\":\"#/$defs/specification-extensions\",\"unevaluatedProperties\":false},\"components\":{\"$comment\":\"https://spec.openapis.org/oas/v3.1#components-object\",\"type\":\"object\",\"properties\":{\"schemas\":{\"type\":\"object\",\"additionalProperties\":{\"$dynamicRef\":\"#meta\"}},\"responses\":{\"type\":\"object\",\"additionalProperties\":{\"$ref\":\"#/$defs/response-or-reference\"}},\"parameters\":{\"type\":\"object\",\"additionalProperties\":{\"$ref\":\"#/$defs/parameter-or-reference\"}},\"examples\":{\"type\":\"object\",\"additionalProperties\":{\"$ref\":\"#/$defs/example-or-reference\"}},\"requestBodies\":{\"type\":\"object\",\"additionalProperties\":{\"$ref\":\"#/$defs/request-body-or-reference\"}},\"headers\":{\"type\":\"object\",\"additionalProperties\":{\"$ref\":\"#/$defs/header-or-reference\"}},\"securitySchemes\":{\"type\":\"object\",\"additionalProperties\":{\"$ref\":\"#/$defs/security-scheme-or-reference\"}},\"links\":{\"type\":\"object\",\"additionalProperties\":{\"$ref\":\"#/$defs/link-or-reference\"}},\"callbacks\":{\"type\":\"object\",\"additionalProperties\":{\"$ref\":\"#/$defs/callbacks-or-reference\"}},\"pathItems\":{\"type\":\"object\",\"additionalProperties\":{\"$ref\":\"#/$defs/path-item\"}}},\"patternProperties\":{\"^(?:schemas|responses|parameters|examples|requestBodies|headers|securitySchemes|links|callbacks|pathItems)$\":{\"$comment\":\"Enumerating all of the property names in the regex above is necessary for unevaluatedProperties to work as expected\",\"propertyNames\":{\"pattern\":\"^[a-zA-Z0-9._-]+$\"}}},\"$ref\":\"#/$defs/specification-extensions\",\"unevaluatedProperties\":false},\"paths\":{\"$comment\":\"https://spec.openapis.org/oas/v3.1#paths-object\",\"type\":\"object\",\"patternProperties\":{\"^/\":{\"$ref\":\"#/$defs/path-item\"},\"^x-\":true},\"additionalProperties\":false},\"path-item\":{\"$comment\":\"https://spec.openapis.org/oas/v3.1#path-item-object\",\"type\":\"object\",\"properties\":{\"$ref\":{\"type\":\"string\",\"format\":\"uri-reference\"},\"summary\":{\"type\":\"string\"},\"description\":{\"type\":\"string\"},\"servers\":{\"type\":\"array\",\"items\":{\"$ref\":\"#/$defs/server\"}},\"parameters\":{\"type\":\"array\",\"items\":{\"$ref\":\"#/$defs/parameter-or-reference\"}},\"get\":{\"$ref\":\"#/$defs/operation\"},\"put\":{\"$ref\":\"#/$defs/operation\"},\"post\":{\"$ref\":\"#/$defs/operation\"},\"delete\":{\"$ref\":\"#/$defs/operation\"},\"options\":{\"$ref\":\"#/$defs/operation\"},\"head\":{\"$ref\":\"#/$defs/operation\"},\"patch\":{\"$ref\":\"#/$defs/operation\"},\"trace\":{\"$ref\":\"#/$defs/operation\"}},\"$ref\":\"#/$defs/specification-extensions\",\"unevaluatedProperties\":false},\"operation\":{\"$comment\":\"https://spec.openapis.org/oas/v3.1#operation-object\",\"type\":\"object\",\"properties\":{\"tags\":{\"type\":\"array\",\"items\":{\"type\":\"string\"}},\"summary\":{\"type\":\"string\"},\"description\":{\"type\":\"string\"},\"externalDocs\":{\"$ref\":\"#/$defs/external-documentation\"},\"operationId\":{\"type\":\"string\"},\"parameters\":{\"type\":\"array\",\"items\":{\"$ref\":\"#/$defs/parameter-or-reference\"}},\"requestBody\":{\"$ref\":\"#/$defs/request-body-or-reference\"},\"responses\":{\"$ref\":\"#/$defs/responses\"},\"callbacks\":{\"type\":\"object\",\"additionalProperties\":{\"$ref\":\"#/$defs/callbacks-or-reference\"}},\"deprecated\":{\"default\":false,\"type\":\"boolean\"},\"security\":{\"type\":\"array\",\"items\":{\"$ref\":\"#/$defs/security-requirement\"}},\"servers\":{\"type\":\"array\",\"items\":{\"$ref\":\"#/$defs/server\"}}},\"$ref\":\"#/$defs/specification-extensions\",\"unevaluatedProperties\":false},\"external-documentation\":{\"$comment\":\"https://spec.openapis.org/oas/v3.1#external-documentation-object\",\"type\":\"object\",\"properties\":{\"description\":{\"type\":\"string\"},\"url\":{\"type\":\"string\",\"format\":\"uri-reference\"}},\"required\":[\"url\"],\"$ref\":\"#/$defs/specification-extensions\",\"unevaluatedProperties\":false},\"parameter\":{\"$comment\":\"https://spec.openapis.org/oas/v3.1#parameter-object\",\"type\":\"object\",\"properties\":{\"name\":{\"type\":\"string\"},\"in\":{\"enum\":[\"query\",\"header\",\"path\",\"cookie\"]},\"description\":{\"type\":\"string\"},\"required\":{\"default\":false,\"type\":\"boolean\"},\"deprecated\":{\"default\":false,\"type\":\"boolean\"},\"schema\":{\"$dynamicRef\":\"#meta\"},\"content\":{\"$ref\":\"#/$defs/content\",\"minProperties\":1,\"maxProperties\":1}},\"required\":[\"name\",\"in\"],\"oneOf\":[{\"required\":[\"schema\"]},{\"required\":[\"content\"]}],\"if\":{\"properties\":{\"in\":{\"const\":\"query\"}}},\"then\":{\"properties\":{\"allowEmptyValue\":{\"default\":false,\"type\":\"boolean\"}}},\"dependentSchemas\":{\"schema\":{\"properties\":{\"style\":{\"type\":\"string\"},\"explode\":{\"type\":\"boolean\"}},\"allOf\":[{\"$ref\":\"#/$defs/examples\"},{\"$ref\":\"#/$defs/parameter/dependentSchemas/schema/$defs/styles-for-path\"},{\"$ref\":\"#/$defs/parameter/dependentSchemas/schema/$defs/styles-for-header\"},{\"$ref\":\"#/$defs/parameter/dependentSchemas/schema/$defs/styles-for-query\"},{\"$ref\":\"#/$defs/parameter/dependentSchemas/schema/$defs/styles-for-cookie\"}],\"$defs\":{\"styles-for-path\":{\"if\":{\"properties\":{\"in\":{\"const\":\"path\"}}},\"then\":{\"properties\":{\"name\":{\"pattern\":\"^[^{}]+$\"},\"style\":{\"default\":\"simple\",\"enum\":[\"matrix\",\"label\",\"simple\"]},\"required\":{\"const\":true},\"explode\":{\"default\":false}},\"required\":[\"required\"]}},\"styles-for-header\":{\"if\":{\"properties\":{\"in\":{\"const\":\"header\"}}},\"then\":{\"properties\":{\"style\":{\"default\":\"simple\",\"const\":\"simple\"},\"explode\":{\"default\":false}}}},\"styles-for-query\":{\"if\":{\"properties\":{\"in\":{\"const\":\"query\"}}},\"then\":{\"properties\":{\"style\":{\"default\":\"form\",\"enum\":[\"form\",\"spaceDelimited\",\"pipeDelimited\",\"deepObject\"]},\"allowReserved\":{\"default\":false,\"type\":\"boolean\"}},\"$ref\":\"#/$defs/explode-for-form\"}},\"styles-for-cookie\":{\"if\":{\"properties\":{\"in\":{\"const\":\"cookie\"}}},\"then\":{\"properties\":{\"style\":{\"default\":\"form\",\"const\":\"form\"}},\"$ref\":\"#/$defs/explode-for-form\"}}}}},\"$ref\":\"#/$defs/specification-extensions\",\"unevaluatedProperties\":false},\"parameter-or-reference\":{\"if\":{\"type\":\"object\",\"required\":[\"$ref\"]},\"then\":{\"$ref\":\"#/$defs/reference\"},\"else\":{\"$ref\":\"#/$defs/parameter\"}},\"request-body\":{\"$comment\":\"https://spec.openapis.org/oas/v3.1#request-body-object\",\"type\":\"object\",\"properties\":{\"description\":{\"type\":\"string\"},\"content\":{\"$ref\":\"#/$defs/content\"},\"required\":{\"default\":false,\"type\":\"boolean\"}},\"required\":[\"content\"],\"$ref\":\"#/$defs/specification-extensions\",\"unevaluatedProperties\":false},\"request-body-or-reference\":{\"if\":{\"type\":\"object\",\"required\":[\"$ref\"]},\"then\":{\"$ref\":\"#/$defs/reference\"},\"else\":{\"$ref\":\"#/$defs/request-body\"}},\"content\":{\"$comment\":\"https://spec.openapis.org/oas/v3.1#fixed-fields-10\",\"type\":\"object\",\"additionalProperties\":{\"$ref\":\"#/$defs/media-type\"},\"propertyNames\":{\"format\":\"media-range\"}},\"media-type\":{\"$comment\":\"https://spec.openapis.org/oas/v3.1#media-type-object\",\"type\":\"object\",\"properties\":{\"schema\":{\"$dynamicRef\":\"#meta\"},\"encoding\":{\"type\":\"object\",\"additionalProperties\":{\"$ref\":\"#/$defs/encoding\"}}},\"allOf\":[{\"$ref\":\"#/$defs/specification-extensions\"},{\"$ref\":\"#/$defs/examples\"}],\"unevaluatedProperties\":false},\"encoding\":{\"$comment\":\"https://spec.openapis.org/oas/v3.1#encoding-object\",\"type\":\"object\",\"properties\":{\"contentType\":{\"type\":\"string\",\"format\":\"media-range\"},\"headers\":{\"type\":\"object\",\"additionalProperties\":{\"$ref\":\"#/$defs/header-or-reference\"}},\"style\":{\"enum\":[\"form\",\"spaceDelimited\",\"pipeDelimited\",\"deepObject\"]},\"explode\":{\"type\":\"boolean\"},\"allowReserved\":{\"type\":\"boolean\"}},\"dependentSchemas\":{\"style\":{\"properties\":{\"allowReserved\":{\"default\":false}},\"$ref\":\"#/$defs/explode-for-form\"},\"explode\":{\"properties\":{\"style\":{\"default\":\"form\"},\"allowReserved\":{\"default\":false}}},\"allowReserved\":{\"properties\":{\"style\":{\"default\":\"form\"}},\"$ref\":\"#/$defs/explode-for-form\"}},\"$ref\":\"#/$defs/specification-extensions\",\"unevaluatedProperties\":false},\"responses\":{\"$comment\":\"https://spec.openapis.org/oas/v3.1#responses-object\",\"type\":\"object\",\"properties\":{\"default\":{\"$ref\":\"#/$defs/response-or-reference\"}},\"patternProperties\":{\"^[1-5](?:[0-9]{2}|XX)$\":{\"$ref\":\"#/$defs/response-or-reference\"}},\"minProperties\":1,\"$ref\":\"#/$defs/specification-extensions\",\"unevaluatedProperties\":false,\"if\":{\"$comment\":\"either default, or at least one response code property must exist\",\"patternProperties\":{\"^[1-5](?:[0-9]{2}|XX)$\":false}},\"then\":{\"required\":[\"default\"]}},\"response\":{\"$comment\":\"https://spec.openapis.org/oas/v3.1#response-object\",\"type\":\"object\",\"properties\":{\"description\":{\"type\":\"string\"},\"headers\":{\"type\":\"object\",\"additionalProperties\":{\"$ref\":\"#/$defs/header-or-reference\"}},\"content\":{\"$ref\":\"#/$defs/content\"},\"links\":{\"type\":\"object\",\"additionalProperties\":{\"$ref\":\"#/$defs/link-or-reference\"}}},\"required\":[\"description\"],\"$ref\":\"#/$defs/specification-extensions\",\"unevaluatedProperties\":false},\"response-or-reference\":{\"if\":{\"type\":\"object\",\"required\":[\"$ref\"]},\"then\":{\"$ref\":\"#/$defs/reference\"},\"else\":{\"$ref\":\"#/$defs/response\"}},\"callbacks\":{\"$comment\":\"https://spec.openapis.org/oas/v3.1#callback-object\",\"type\":\"object\",\"$ref\":\"#/$defs/specification-extensions\",\"additionalProperties\":{\"$ref\":\"#/$defs/path-item\"}},\"callbacks-or-reference\":{\"if\":{\"type\":\"object\",\"required\":[\"$ref\"]},\"then\":{\"$ref\":\"#/$defs/reference\"},\"else\":{\"$ref\":\"#/$defs/callbacks\"}},\"example\":{\"$comment\":\"https://spec.openapis.org/oas/v3.1#example-object\",\"type\":\"object\",\"properties\":{\"summary\":{\"type\":\"string\"},\"description\":{\"type\":\"string\"},\"value\":true,\"externalValue\":{\"type\":\"string\",\"format\":\"uri-reference\"}},\"not\":{\"required\":[\"value\",\"externalValue\"]},\"$ref\":\"#/$defs/specification-extensions\",\"unevaluatedProperties\":false},\"example-or-reference\":{\"if\":{\"type\":\"object\",\"required\":[\"$ref\"]},\"then\":{\"$ref\":\"#/$defs/reference\"},\"else\":{\"$ref\":\"#/$defs/example\"}},\"link\":{\"$comment\":\"https://spec.openapis.org/oas/v3.1#link-object\",\"type\":\"object\",\"properties\":{\"operationRef\":{\"type\":\"string\",\"format\":\"uri-reference\"},\"operationId\":{\"type\":\"string\"},\"parameters\":{\"$ref\":\"#/$defs/map-of-strings\"},\"requestBody\":true,\"description\":{\"type\":\"string\"},\"server\":{\"$ref\":\"#/$defs/server\"}},\"oneOf\":[{\"required\":[\"operationRef\"]},{\"required\":[\"operationId\"]}],\"$ref\":\"#/$defs/specification-extensions\",\"unevaluatedProperties\":false},\"link-or-reference\":{\"if\":{\"type\":\"object\",\"required\":[\"$ref\"]},\"then\":{\"$ref\":\"#/$defs/reference\"},\"else\":{\"$ref\":\"#/$defs/link\"}},\"header\":{\"$comment\":\"https://spec.openapis.org/oas/v3.1#header-object\",\"type\":\"object\",\"properties\":{\"description\":{\"type\":\"string\"},\"required\":{\"default\":false,\"type\":\"boolean\"},\"deprecated\":{\"default\":false,\"type\":\"boolean\"},\"schema\":{\"$dynamicRef\":\"#meta\"},\"content\":{\"$ref\":\"#/$defs/content\",\"minProperties\":1,\"maxProperties\":1}},\"oneOf\":[{\"required\":[\"schema\"]},{\"required\":[\"content\"]}],\"dependentSchemas\":{\"schema\":{\"properties\":{\"style\":{\"default\":\"simple\",\"const\":\"simple\"},\"explode\":{\"default\":false,\"type\":\"boolean\"}},\"$ref\":\"#/$defs/examples\"}},\"$ref\":\"#/$defs/specification-extensions\",\"unevaluatedProperties\":false},\"header-or-reference\":{\"if\":{\"type\":\"object\",\"required\":[\"$ref\"]},\"then\":{\"$ref\":\"#/$defs/reference\"},\"else\":{\"$ref\":\"#/$defs/header\"}},\"tag\":{\"$comment\":\"https://spec.openapis.org/oas/v3.1#tag-object\",\"type\":\"object\",\"properties\":{\"name\":{\"type\":\"string\"},\"description\":{\"type\":\"string\"},\"externalDocs\":{\"$ref\":\"#/$defs/external-documentation\"}},\"required\":[\"name\"],\"$ref\":\"#/$defs/specification-extensions\",\"unevaluatedProperties\":false},\"reference\":{\"$comment\":\"https://spec.openapis.org/oas/v3.1#reference-object\",\"type\":\"object\",\"properties\":{\"$ref\":{\"type\":\"string\",\"format\":\"uri-reference\"},\"summary\":{\"type\":\"string\"},\"description\":{\"type\":\"string\"}}},\"schema\":{\"$comment\":\"https://spec.openapis.org/oas/v3.1#schema-object\",\"$dynamicAnchor\":\"meta\",\"type\":[\"object\",\"boolean\"]},\"security-scheme\":{\"$comment\":\"https://spec.openapis.org/oas/v3.1#security-scheme-object\",\"type\":\"object\",\"properties\":{\"type\":{\"enum\":[\"apiKey\",\"http\",\"mutualTLS\",\"oauth2\",\"openIdConnect\"]},\"description\":{\"type\":\"string\"}},\"required\":[\"type\"],\"allOf\":[{\"$ref\":\"#/$defs/specification-extensions\"},{\"$ref\":\"#/$defs/security-scheme/$defs/type-apikey\"},{\"$ref\":\"#/$defs/security-scheme/$defs/type-http\"},{\"$ref\":\"#/$defs/security-scheme/$defs/type-http-bearer\"},{\"$ref\":\"#/$defs/security-scheme/$defs/type-oauth2\"},{\"$ref\":\"#/$defs/security-scheme/$defs/type-oidc\"}],\"unevaluatedProperties\":false,\"$defs\":{\"type-apikey\":{\"if\":{\"properties\":{\"type\":{\"const\":\"apiKey\"}}},\"then\":{\"properties\":{\"name\":{\"type\":\"string\"},\"in\":{\"enum\":[\"query\",\"header\",\"cookie\"]}},\"required\":[\"name\",\"in\"]}},\"type-http\":{\"if\":{\"properties\":{\"type\":{\"const\":\"http\"}}},\"then\":{\"properties\":{\"scheme\":{\"type\":\"string\"}},\"required\":[\"scheme\"]}},\"type-http-bearer\":{\"if\":{\"properties\":{\"type\":{\"const\":\"http\"},\"scheme\":{\"type\":\"string\",\"pattern\":\"^[Bb][Ee][Aa][Rr][Ee][Rr]$\"}},\"required\":[\"type\",\"scheme\"]},\"then\":{\"properties\":{\"bearerFormat\":{\"type\":\"string\"}}}},\"type-oauth2\":{\"if\":{\"properties\":{\"type\":{\"const\":\"oauth2\"}}},\"then\":{\"properties\":{\"flows\":{\"$ref\":\"#/$defs/oauth-flows\"}},\"required\":[\"flows\"]}},\"type-oidc\":{\"if\":{\"properties\":{\"type\":{\"const\":\"openIdConnect\"}}},\"then\":{\"properties\":{\"openIdConnectUrl\":{\"type\":\"string\",\"format\":\"uri-reference\"}},\"required\":[\"openIdConnectUrl\"]}}}},\"security-scheme-or-reference\":{\"if\":{\"type\":\"object\",\"required\":[\"$ref\"]},\"then\":{\"$ref\":\"#/$defs/reference\"},\"else\":{\"$ref\":\"#/$defs/security-scheme\"}},\"oauth-flows\":{\"type\":\"object\",\"properties\":{\"implicit\":{\"$ref\":\"#/$defs/oauth-flows/$defs/implicit\"},\"password\":{\"$ref\":\"#/$defs/oauth-flows/$defs/password\"},\"clientCredentials\":{\"$ref\":\"#/$defs/oauth-flows/$defs/client-credentials\"},\"authorizationCode\":{\"$ref\":\"#/$defs/oauth-flows/$defs/authorization-code\"}},\"$ref\":\"#/$defs/specification-extensions\",\"unevaluatedProperties\":false,\"$defs\":{\"implicit\":{\"type\":\"object\",\"properties\":{\"authorizationUrl\":{\"type\":\"string\",\"format\":\"uri-reference\"},\"refreshUrl\":{\"type\":\"string\",\"format\":\"uri-reference\"},\"scopes\":{\"$ref\":\"#/$defs/map-of-strings\"}},\"required\":[\"authorizationUrl\",\"scopes\"],\"$ref\":\"#/$defs/specification-extensions\",\"unevaluatedProperties\":false},\"password\":{\"type\":\"object\",\"properties\":{\"tokenUrl\":{\"type\":\"string\",\"format\":\"uri-reference\"},\"refreshUrl\":{\"type\":\"string\",\"format\":\"uri-reference\"},\"scopes\":{\"$ref\":\"#/$defs/map-of-strings\"}},\"required\":[\"tokenUrl\",\"scopes\"],\"$ref\":\"#/$defs/specification-extensions\",\"unevaluatedProperties\":false},\"client-credentials\":{\"type\":\"object\",\"properties\":{\"tokenUrl\":{\"type\":\"string\",\"format\":\"uri-reference\"},\"refreshUrl\":{\"type\":\"string\",\"format\":\"uri-reference\"},\"scopes\":{\"$ref\":\"#/$defs/map-of-strings\"}},\"required\":[\"tokenUrl\",\"scopes\"],\"$ref\":\"#/$defs/specification-extensions\",\"unevaluatedProperties\":false},\"authorization-code\":{\"type\":\"object\",\"properties\":{\"authorizationUrl\":{\"type\":\"string\",\"format\":\"uri-reference\"},\"tokenUrl\":{\"type\":\"string\",\"format\":\"uri-reference\"},\"refreshUrl\":{\"type\":\"string\",\"format\":\"uri-reference\"},\"scopes\":{\"$ref\":\"#/$defs/map-of-strings\"}},\"required\":[\"authorizationUrl\",\"tokenUrl\",\"scopes\"],\"$ref\":\"#/$defs/specification-extensions\",\"unevaluatedProperties\":false}}},\"security-requirement\":{\"$comment\":\"https://spec.openapis.org/oas/v3.1#security-requirement-object\",\"type\":\"object\",\"additionalProperties\":{\"type\":\"array\",\"items\":{\"type\":\"string\"}}},\"specification-extensions\":{\"$comment\":\"https://spec.openapis.org/oas/v3.1#specification-extensions\",\"patternProperties\":{\"^x-\":true}},\"examples\":{\"properties\":{\"example\":true,\"examples\":{\"type\":\"object\",\"additionalProperties\":{\"$ref\":\"#/$defs/example-or-reference\"}}},\"not\":{\"required\":[\"example\",\"examples\"]}},\"map-of-strings\":{\"type\":\"object\",\"additionalProperties\":{\"type\":\"string\"}},\"explode-for-form\":{\"$comment\":\"for encoding objects, and query and cookie parameters, style=form is the default\",\"if\":{\"properties\":{\"style\":{\"const\":\"form\"}}},\"then\":{\"properties\":{\"explode\":{\"default\":true}}},\"else\":{\"properties\":{\"explode\":{\"default\":false}}}}}")
|
|
104
|
+
};
|
|
105
|
+
//#endregion
|
|
106
|
+
//#region src/v2/features/editor/helpers/configure-language-support.ts
|
|
107
|
+
var OPENAPI_JSON_SCHEMA_URI = "inmemory://model/scalar/openapi-json-schema";
|
|
108
|
+
/**
|
|
109
|
+
* Configures JSON language support for the given model URI
|
|
110
|
+
*
|
|
111
|
+
* @param globPattern - The glob pattern to match the files to configure language support for
|
|
112
|
+
*/
|
|
113
|
+
var configureJson = (globPattern) => {
|
|
114
|
+
const defaults = monaco.languages.json.jsonDefaults;
|
|
115
|
+
const current = defaults.diagnosticsOptions;
|
|
116
|
+
const schemas = [...(current.schemas ?? []).filter((s) => s.uri !== OPENAPI_JSON_SCHEMA_URI), {
|
|
117
|
+
uri: OPENAPI_JSON_SCHEMA_URI,
|
|
118
|
+
fileMatch: [globPattern],
|
|
119
|
+
schema: openapi_3_1_schema_default
|
|
120
|
+
}];
|
|
121
|
+
defaults.setDiagnosticsOptions({
|
|
122
|
+
...current,
|
|
123
|
+
validate: true,
|
|
124
|
+
enableSchemaRequest: false,
|
|
125
|
+
schemas
|
|
126
|
+
});
|
|
127
|
+
};
|
|
128
|
+
/**
|
|
129
|
+
* Configures YAML language support for the given model URI
|
|
130
|
+
*
|
|
131
|
+
* @param globPattern - The glob pattern to match the files to configure language support for
|
|
132
|
+
*/
|
|
133
|
+
var configureYaml = (globPattern) => {
|
|
134
|
+
configureMonacoYaml(monaco, {
|
|
135
|
+
enableSchemaRequest: false,
|
|
136
|
+
validate: true,
|
|
137
|
+
format: true,
|
|
138
|
+
completion: true,
|
|
139
|
+
hover: true,
|
|
140
|
+
schemas: [{
|
|
141
|
+
fileMatch: [globPattern],
|
|
142
|
+
schema: openapi_3_1_schema_default,
|
|
143
|
+
uri: OPENAPI_JSON_SCHEMA_URI
|
|
144
|
+
}]
|
|
145
|
+
});
|
|
146
|
+
};
|
|
147
|
+
//#endregion
|
|
148
|
+
//#region src/v2/features/editor/helpers/json/create-json-model.ts
|
|
149
|
+
/**
|
|
150
|
+
* Creates a JSON Monaco editor model with enhanced language support.
|
|
151
|
+
*
|
|
152
|
+
* @param value - The initial JSON content for the model.
|
|
153
|
+
* @returns An object containing the Monaco model and a function to get a range from a JSON path.
|
|
154
|
+
*
|
|
155
|
+
* The returned `getRangeFromPath` function asynchronously finds the AST node for a JSON path,
|
|
156
|
+
* converts its offset and length to a Monaco Range, or returns null if not found.
|
|
157
|
+
*/
|
|
158
|
+
var createJsonModel = (value) => {
|
|
159
|
+
const model = monaco$1.editor.createModel(value ?? "", "json");
|
|
160
|
+
configureJson(model.uri.toString());
|
|
161
|
+
return {
|
|
162
|
+
model,
|
|
163
|
+
getRangeFromPath: async (path) => {
|
|
164
|
+
const node = await getJsonAstNodeFromPath(model, path);
|
|
165
|
+
if (!node) return null;
|
|
166
|
+
const start = model.getPositionAt(node.offset);
|
|
167
|
+
const end = model.getPositionAt(node.offset + node.length);
|
|
168
|
+
return new monaco$1.Range(start.lineNumber, start.column, end.lineNumber, end.column);
|
|
169
|
+
}
|
|
170
|
+
};
|
|
171
|
+
};
|
|
172
|
+
//#endregion
|
|
173
|
+
//#region src/v2/features/editor/helpers/yaml/get-yaml-node-range-from-path.ts
|
|
174
|
+
var isValidYamlRange = (range) => Array.isArray(range) && typeof range[0] === "number" && typeof range[1] === "number";
|
|
175
|
+
var safeParseDocument = (yamlText) => {
|
|
176
|
+
try {
|
|
177
|
+
return parseDocument(yamlText);
|
|
178
|
+
} catch {
|
|
179
|
+
return null;
|
|
180
|
+
}
|
|
181
|
+
};
|
|
182
|
+
/**
|
|
183
|
+
* Finds the byte range (offset) in the YAML text corresponding to a JSON path.
|
|
184
|
+
* Given a YAML string and a path (array of segments), parses the document and walks
|
|
185
|
+
* down the tree to find the target node or key, returning its start and end offsets.
|
|
186
|
+
* Will prefer to highlight the "key" part for map entries, to avoid highlighting the value which
|
|
187
|
+
* might be offset due to block structure.
|
|
188
|
+
*
|
|
189
|
+
* @param yamlText The YAML string
|
|
190
|
+
* @param path An array representing the path to traverse
|
|
191
|
+
* @returns The byte offsets in the YAML string of the node (or null if not found)
|
|
192
|
+
*/
|
|
193
|
+
var getYamlNodeRangeFromPath = (yamlText, path) => {
|
|
194
|
+
const doc = safeParseDocument(yamlText);
|
|
195
|
+
if (!doc) return null;
|
|
196
|
+
let current = doc.contents;
|
|
197
|
+
let lastPair = null;
|
|
198
|
+
for (const segment of path) {
|
|
199
|
+
if (isMap(current)) {
|
|
200
|
+
const key = String(segment);
|
|
201
|
+
const pair = current.items.find((p) => {
|
|
202
|
+
if (!isPair(p)) return false;
|
|
203
|
+
const pairKey = p.key;
|
|
204
|
+
return isScalar(pairKey) ? String(pairKey.value) === key : String(pairKey) === key;
|
|
205
|
+
});
|
|
206
|
+
if (!pair || !isPair(pair)) return null;
|
|
207
|
+
lastPair = pair;
|
|
208
|
+
current = pair.value;
|
|
209
|
+
continue;
|
|
210
|
+
}
|
|
211
|
+
if (isSeq(current)) {
|
|
212
|
+
const index = typeof segment === "number" ? segment : Number.parseInt(String(segment), 10);
|
|
213
|
+
if (!Number.isFinite(index) || index < 0 || index >= current.items.length) return null;
|
|
214
|
+
lastPair = null;
|
|
215
|
+
current = current.items[index];
|
|
216
|
+
continue;
|
|
217
|
+
}
|
|
218
|
+
return null;
|
|
219
|
+
}
|
|
220
|
+
if (lastPair && isPair(lastPair)) {
|
|
221
|
+
const keyRange = lastPair.key?.range;
|
|
222
|
+
const valueRange = lastPair.value?.range;
|
|
223
|
+
if (!isValidYamlRange(keyRange)) return null;
|
|
224
|
+
const startOffset = Math.max(0, keyRange[0]);
|
|
225
|
+
return {
|
|
226
|
+
startOffset,
|
|
227
|
+
endOffset: isValidYamlRange(valueRange) ? Math.max(startOffset, valueRange[1]) : Math.max(startOffset, keyRange[1])
|
|
228
|
+
};
|
|
229
|
+
}
|
|
230
|
+
const nodeRange = current?.range;
|
|
231
|
+
if (!isValidYamlRange(nodeRange)) return null;
|
|
232
|
+
const startOffset = Math.max(0, nodeRange[0]);
|
|
233
|
+
return {
|
|
234
|
+
startOffset,
|
|
235
|
+
endOffset: Math.max(startOffset, nodeRange[1])
|
|
236
|
+
};
|
|
237
|
+
};
|
|
238
|
+
//#endregion
|
|
239
|
+
//#region src/v2/features/editor/helpers/yaml/create-yaml-model.ts
|
|
240
|
+
/**
|
|
241
|
+
* Creates a YAML model for use in the Monaco editor.
|
|
242
|
+
*
|
|
243
|
+
* @param value - The initial YAML string value for the model.
|
|
244
|
+
* @returns An object containing the Monaco model and a method to get a range from a YAML path.
|
|
245
|
+
*
|
|
246
|
+
* The created model is configured for YAML language support.
|
|
247
|
+
* The `getRangeFromPath` method returns a Monaco Range object indicating the text range
|
|
248
|
+
* that corresponds to a given path in the YAML document, or null if the path is not found.
|
|
249
|
+
*/
|
|
250
|
+
var createYamlModel = (value) => {
|
|
251
|
+
const model = monaco$1.editor.createModel(value ?? "", "yaml");
|
|
252
|
+
configureYaml(model.uri.toString());
|
|
253
|
+
return {
|
|
254
|
+
model,
|
|
255
|
+
getRangeFromPath: (path) => {
|
|
256
|
+
const range = getYamlNodeRangeFromPath(model.getValue(), path);
|
|
257
|
+
if (!range) return null;
|
|
258
|
+
const start = model.getPositionAt(range.startOffset);
|
|
259
|
+
const end = model.getPositionAt(range.endOffset);
|
|
260
|
+
return new monaco$1.Range(start.lineNumber, start.column, end.lineNumber, end.column);
|
|
261
|
+
}
|
|
262
|
+
};
|
|
263
|
+
};
|
|
264
|
+
//#endregion
|
|
265
|
+
//#region src/v2/features/editor/hooks/use-editor-markers.ts
|
|
266
|
+
var useEditorMarkers = (editorRef) => {
|
|
267
|
+
const markers = ref([]);
|
|
268
|
+
let dispose = null;
|
|
269
|
+
const retryTimeouts = [];
|
|
270
|
+
const updateMarkers = () => {
|
|
271
|
+
const resource = toValue(editorRef)?.getModel()?.uri;
|
|
272
|
+
if (!resource) {
|
|
273
|
+
markers.value = [];
|
|
274
|
+
return;
|
|
275
|
+
}
|
|
276
|
+
markers.value = monaco.editor.getModelMarkers({}).filter((marker) => marker.resource.toString() === resource.toString());
|
|
277
|
+
};
|
|
278
|
+
const scheduleMarkerReads = () => {
|
|
279
|
+
retryTimeouts.push(setTimeout(updateMarkers, 0), setTimeout(updateMarkers, 80), setTimeout(updateMarkers, 220));
|
|
280
|
+
};
|
|
281
|
+
onMounted(() => {
|
|
282
|
+
dispose = monaco.editor.onDidChangeMarkers(() => {
|
|
283
|
+
scheduleMarkerReads();
|
|
284
|
+
});
|
|
285
|
+
scheduleMarkerReads();
|
|
286
|
+
});
|
|
287
|
+
onBeforeUnmount(() => {
|
|
288
|
+
dispose?.dispose();
|
|
289
|
+
retryTimeouts.forEach((timeout) => clearTimeout(timeout));
|
|
290
|
+
});
|
|
291
|
+
watch(() => toValue(editorRef)?.getModel()?.uri?.toString(), () => {
|
|
292
|
+
scheduleMarkerReads();
|
|
293
|
+
}, { immediate: true });
|
|
294
|
+
return { markers };
|
|
295
|
+
};
|
|
296
|
+
//#endregion
|
|
297
|
+
//#region src/v2/features/collection/components/Editor/components/EditorDiagnosticsPanel.vue?vue&type=script&setup=true&lang.ts
|
|
298
|
+
var _hoisted_1$2 = { class: "pointer-events-none absolute right-2 bottom-2 left-2 z-10" };
|
|
299
|
+
var _hoisted_2$2 = { class: "bg-b-1 shadow-border pointer-events-auto flex flex-col overflow-hidden rounded-lg text-[11px]" };
|
|
300
|
+
var _hoisted_3$2 = { class: "flex items-center gap-3" };
|
|
301
|
+
var _hoisted_4$2 = {
|
|
302
|
+
class: "text-c-danger flex items-center gap-1",
|
|
303
|
+
title: "Errors"
|
|
304
|
+
};
|
|
305
|
+
var _hoisted_5$2 = {
|
|
306
|
+
class: "text-c-alert flex items-center gap-1",
|
|
307
|
+
title: "Warnings"
|
|
308
|
+
};
|
|
309
|
+
var _hoisted_6$1 = { class: "text-c-3" };
|
|
310
|
+
var _hoisted_7$1 = {
|
|
311
|
+
key: 0,
|
|
312
|
+
class: "max-h-28 overflow-auto border-t"
|
|
313
|
+
};
|
|
314
|
+
var _hoisted_8$1 = ["onClick"];
|
|
315
|
+
var _hoisted_9$1 = { class: "min-w-0 flex-1" };
|
|
316
|
+
var _hoisted_10$1 = { class: "text-c-1 block truncate" };
|
|
317
|
+
var _hoisted_11$1 = { class: "text-c-3 block whitespace-nowrap" };
|
|
318
|
+
var _hoisted_12 = {
|
|
319
|
+
key: 1,
|
|
320
|
+
class: "text-c-3 border-t px-2.5 py-2"
|
|
321
|
+
};
|
|
322
|
+
//#endregion
|
|
323
|
+
//#region src/v2/features/collection/components/Editor/components/EditorDiagnosticsPanel.vue
|
|
324
|
+
var EditorDiagnosticsPanel_default = /* @__PURE__ */ defineComponent({
|
|
325
|
+
__name: "EditorDiagnosticsPanel",
|
|
326
|
+
props: {
|
|
327
|
+
expanded: { type: Boolean },
|
|
328
|
+
diagnosticCounts: {},
|
|
329
|
+
visibleDiagnostics: {}
|
|
330
|
+
},
|
|
331
|
+
emits: ["toggle", "focusDiagnostic"],
|
|
332
|
+
setup(__props, { emit: __emit }) {
|
|
333
|
+
const emit = __emit;
|
|
334
|
+
const getMarkerDotClass = (severity) => severity === monaco.MarkerSeverity.Error ? "bg-c-danger" : "bg-c-alert";
|
|
335
|
+
return (_ctx, _cache) => {
|
|
336
|
+
return openBlock(), createElementBlock("div", _hoisted_1$2, [createElementVNode("div", _hoisted_2$2, [createElementVNode("button", {
|
|
337
|
+
class: "bg-b-2/30 hover:bg-b-2/50 flex items-center justify-between px-2.5 py-2 text-left",
|
|
338
|
+
type: "button",
|
|
339
|
+
onClick: _cache[0] || (_cache[0] = ($event) => emit("toggle"))
|
|
340
|
+
}, [createElementVNode("span", _hoisted_3$2, [
|
|
341
|
+
_cache[1] || (_cache[1] = createElementVNode("span", { class: "text-c-2 font-medium" }, "Problems", -1)),
|
|
342
|
+
createElementVNode("span", _hoisted_4$2, [createVNode(unref(ScalarIconXCircle), { class: "size-3" }), createElementVNode("span", null, toDisplayString(__props.diagnosticCounts.errors), 1)]),
|
|
343
|
+
createElementVNode("span", _hoisted_5$2, [createVNode(unref(ScalarIconWarning), { class: "size-3" }), createElementVNode("span", null, toDisplayString(__props.diagnosticCounts.warnings), 1)])
|
|
344
|
+
]), createElementVNode("span", _hoisted_6$1, [__props.expanded ? (openBlock(), createBlock(unref(ScalarIconCaretDown), {
|
|
345
|
+
key: 0,
|
|
346
|
+
class: "size-3"
|
|
347
|
+
})) : (openBlock(), createBlock(unref(ScalarIconCaretRight), {
|
|
348
|
+
key: 1,
|
|
349
|
+
class: "size-3"
|
|
350
|
+
}))])]), __props.expanded ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [__props.visibleDiagnostics.length ? (openBlock(), createElementBlock("div", _hoisted_7$1, [(openBlock(true), createElementBlock(Fragment, null, renderList(__props.visibleDiagnostics, (marker, index) => {
|
|
351
|
+
return openBlock(), createElementBlock("button", {
|
|
352
|
+
key: `${marker.owner}-${marker.startLineNumber}-${marker.startColumn}-${index}`,
|
|
353
|
+
class: "hover:bg-b-2/40 flex w-full items-start gap-2 px-2.5 py-2 text-left",
|
|
354
|
+
type: "button",
|
|
355
|
+
onClick: ($event) => emit("focusDiagnostic", marker)
|
|
356
|
+
}, [createElementVNode("span", { class: normalizeClass(["mt-0.5 size-1.5 shrink-0 rounded-full", getMarkerDotClass(marker.severity)]) }, null, 2), createElementVNode("span", _hoisted_9$1, [createElementVNode("span", _hoisted_10$1, toDisplayString(marker.message), 1), createElementVNode("span", _hoisted_11$1, " Ln " + toDisplayString(marker.startLineNumber) + ", Col " + toDisplayString(marker.startColumn), 1)])], 8, _hoisted_8$1);
|
|
357
|
+
}), 128))])) : (openBlock(), createElementBlock("div", _hoisted_12, " Errors and warnings from the JSON/YAML language workers will show up here. "))], 64)) : createCommentVNode("", true)])]);
|
|
358
|
+
};
|
|
359
|
+
}
|
|
360
|
+
});
|
|
361
|
+
//#endregion
|
|
362
|
+
//#region src/v2/features/collection/components/Editor/components/EditorSavePanel.vue?vue&type=script&setup=true&lang.ts
|
|
363
|
+
var _hoisted_1$1 = { class: "bg-b-1 pointer-events-auto flex flex-col items-stretch overflow-hidden rounded-lg border shadow-sm" };
|
|
364
|
+
var _hoisted_2$1 = { class: "flex items-center gap-2 px-2 py-1.5" };
|
|
365
|
+
var _hoisted_3$1 = { class: "min-w-[48px]" };
|
|
366
|
+
var _hoisted_4$1 = {
|
|
367
|
+
key: 1,
|
|
368
|
+
class: "text-c-3 flex h-6 items-center justify-center rounded px-2 text-[11px] whitespace-nowrap"
|
|
369
|
+
};
|
|
370
|
+
var _hoisted_5$1 = {
|
|
371
|
+
key: 0,
|
|
372
|
+
class: "bg-b-2/40 flex items-center gap-2 border-t px-2 py-1 text-[11px]"
|
|
373
|
+
};
|
|
374
|
+
//#endregion
|
|
375
|
+
//#region src/v2/features/collection/components/Editor/components/EditorSavePanel.vue
|
|
376
|
+
var EditorSavePanel_default = /* @__PURE__ */ defineComponent({
|
|
377
|
+
__name: "EditorSavePanel",
|
|
378
|
+
props: {
|
|
379
|
+
isAutoSaveEnabled: { type: Boolean },
|
|
380
|
+
isDirty: { type: Boolean },
|
|
381
|
+
saveLoader: {}
|
|
382
|
+
},
|
|
383
|
+
emits: ["update:isAutoSaveEnabled", "saveNow"],
|
|
384
|
+
setup(__props, { emit: __emit }) {
|
|
385
|
+
const emit = __emit;
|
|
386
|
+
const editorStatusText = computed(() => {
|
|
387
|
+
if (!__props.isAutoSaveEnabled && __props.isDirty) return "Unsaved";
|
|
388
|
+
if (!__props.saveLoader.isActive) return null;
|
|
389
|
+
if (__props.saveLoader.isLoading) return "Saving…";
|
|
390
|
+
if (__props.saveLoader.isInvalid) return "Save failed";
|
|
391
|
+
if (__props.saveLoader.isValid) return "Saved";
|
|
392
|
+
return null;
|
|
393
|
+
});
|
|
394
|
+
const shouldShowEditorStatus = computed(() => editorStatusText.value !== null);
|
|
395
|
+
const editorStatusTone = computed(() => {
|
|
396
|
+
if (!shouldShowEditorStatus.value) return null;
|
|
397
|
+
if (!__props.isAutoSaveEnabled && __props.isDirty) return "warning";
|
|
398
|
+
if (__props.saveLoader.isLoading) return "loading";
|
|
399
|
+
if (__props.saveLoader.isInvalid) return "danger";
|
|
400
|
+
if (__props.saveLoader.isValid) return "success";
|
|
401
|
+
return null;
|
|
402
|
+
});
|
|
403
|
+
const editorStatusDotClass = computed(() => {
|
|
404
|
+
switch (editorStatusTone.value) {
|
|
405
|
+
case "warning": return "bg-c-alert";
|
|
406
|
+
case "success": return "bg-c-accent";
|
|
407
|
+
case "danger": return "bg-c-danger";
|
|
408
|
+
default: return "bg-b-3";
|
|
409
|
+
}
|
|
410
|
+
});
|
|
411
|
+
const editorStatusTextClass = computed(() => {
|
|
412
|
+
switch (editorStatusTone.value) {
|
|
413
|
+
case "warning": return "text-c-alert";
|
|
414
|
+
case "success": return "text-c-accent";
|
|
415
|
+
case "danger": return "text-c-danger";
|
|
416
|
+
default: return "text-c-2";
|
|
417
|
+
}
|
|
418
|
+
});
|
|
419
|
+
return (_ctx, _cache) => {
|
|
420
|
+
return openBlock(), createElementBlock("div", _hoisted_1$1, [createElementVNode("div", _hoisted_2$1, [
|
|
421
|
+
_cache[3] || (_cache[3] = createElementVNode("span", { class: "text-c-2 text-[11px] font-medium whitespace-nowrap" }, " Auto-save ", -1)),
|
|
422
|
+
createVNode(unref(ScalarToggle), {
|
|
423
|
+
modelValue: __props.isAutoSaveEnabled,
|
|
424
|
+
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => emit("update:isAutoSaveEnabled", $event))
|
|
425
|
+
}, null, 8, ["modelValue"]),
|
|
426
|
+
_cache[4] || (_cache[4] = createElementVNode("div", { class: "bg-b-3 mx-1 h-4 w-px" }, null, -1)),
|
|
427
|
+
createElementVNode("div", _hoisted_3$1, [!__props.isAutoSaveEnabled ? (openBlock(), createBlock(unref(ScalarButton), {
|
|
428
|
+
key: 0,
|
|
429
|
+
disabled: !__props.isDirty || __props.saveLoader.isLoading,
|
|
430
|
+
size: "xs",
|
|
431
|
+
variant: "outlined",
|
|
432
|
+
onClick: _cache[1] || (_cache[1] = ($event) => emit("saveNow"))
|
|
433
|
+
}, {
|
|
434
|
+
default: withCtx(() => [..._cache[2] || (_cache[2] = [createTextVNode(" Save ", -1)])]),
|
|
435
|
+
_: 1
|
|
436
|
+
}, 8, ["disabled"])) : (openBlock(), createElementBlock("div", _hoisted_4$1, " Auto "))])
|
|
437
|
+
]), shouldShowEditorStatus.value ? (openBlock(), createElementBlock("div", _hoisted_5$1, [__props.saveLoader.isActive ? (openBlock(), createBlock(unref(ScalarLoading), {
|
|
438
|
+
key: 0,
|
|
439
|
+
class: "self-center",
|
|
440
|
+
loader: __props.saveLoader,
|
|
441
|
+
size: "sm"
|
|
442
|
+
}, null, 8, ["loader"])) : (openBlock(), createElementBlock("span", {
|
|
443
|
+
key: 1,
|
|
444
|
+
class: normalizeClass(["size-1.5 rounded-full", editorStatusDotClass.value])
|
|
445
|
+
}, null, 2)), createElementVNode("span", { class: normalizeClass(["whitespace-nowrap", editorStatusTextClass.value]) }, toDisplayString(editorStatusText.value), 3)])) : createCommentVNode("", true)]);
|
|
446
|
+
};
|
|
447
|
+
}
|
|
448
|
+
});
|
|
449
|
+
//#endregion
|
|
450
|
+
//#region src/v2/features/collection/components/Editor/helpers/get-diagnostic-counts.ts
|
|
451
|
+
/**
|
|
452
|
+
* This function counts the number of error and warning markers in the provided array of Monaco editor markers.
|
|
453
|
+
*
|
|
454
|
+
* @param markers - The array of Monaco editor markers to count the errors and warnings for
|
|
455
|
+
* @returns An object with the number of errors and warnings
|
|
456
|
+
*/
|
|
457
|
+
var getDiagnosticCounts = (markers) => {
|
|
458
|
+
let errors = 0;
|
|
459
|
+
let warnings = 0;
|
|
460
|
+
for (const marker of markers) if (marker.severity === monaco.MarkerSeverity.Error) errors += 1;
|
|
461
|
+
else if (marker.severity === monaco.MarkerSeverity.Warning) warnings += 1;
|
|
462
|
+
return {
|
|
463
|
+
errors,
|
|
464
|
+
warnings
|
|
465
|
+
};
|
|
466
|
+
};
|
|
467
|
+
//#endregion
|
|
468
|
+
//#region src/v2/features/collection/components/Editor/helpers/get-operation-context.ts
|
|
469
|
+
/**
|
|
470
|
+
* Returns an OperationContext if both path is provided and method is a valid HTTP method.
|
|
471
|
+
* Returns null otherwise.
|
|
472
|
+
*/
|
|
473
|
+
var getOperationContext = (path, method) => {
|
|
474
|
+
if (!path || !isHttpMethod(method)) return null;
|
|
475
|
+
return {
|
|
476
|
+
path,
|
|
477
|
+
method
|
|
478
|
+
};
|
|
479
|
+
};
|
|
480
|
+
//#endregion
|
|
481
|
+
//#region src/v2/features/collection/components/Editor/helpers/get-visible-diagnostics.ts
|
|
482
|
+
var isVisibleDiagnostic = (marker) => marker.severity === monaco.MarkerSeverity.Error || marker.severity === monaco.MarkerSeverity.Warning;
|
|
483
|
+
var compareDiagnostics = (a, b) => {
|
|
484
|
+
if (a.severity !== b.severity) return b.severity - a.severity;
|
|
485
|
+
if (a.startLineNumber !== b.startLineNumber) return a.startLineNumber - b.startLineNumber;
|
|
486
|
+
return a.startColumn - b.startColumn;
|
|
487
|
+
};
|
|
488
|
+
/**
|
|
489
|
+
* Returns up to `maxVisible` diagnostics from the provided markers array,
|
|
490
|
+
* filtering to only errors and warnings, sorted by severity and position in the document.
|
|
491
|
+
*/
|
|
492
|
+
var getVisibleDiagnostics = (markers, maxVisible) => [...markers].filter(isVisibleDiagnostic).sort(compareDiagnostics).slice(0, maxVisible);
|
|
493
|
+
//#endregion
|
|
494
|
+
//#region src/v2/features/collection/components/Editor/helpers/parse-editor-object.ts
|
|
495
|
+
var safeParseJson = (value) => {
|
|
496
|
+
try {
|
|
497
|
+
return JSON.parse(value);
|
|
498
|
+
} catch {
|
|
499
|
+
return null;
|
|
500
|
+
}
|
|
501
|
+
};
|
|
502
|
+
var safeParseYaml = (value) => {
|
|
503
|
+
try {
|
|
504
|
+
return parse(value);
|
|
505
|
+
} catch {
|
|
506
|
+
return null;
|
|
507
|
+
}
|
|
508
|
+
};
|
|
509
|
+
/**
|
|
510
|
+
* Parses the editor value string in either JSON or YAML format.
|
|
511
|
+
* Returns the parsed object if valid and an object, otherwise returns null.
|
|
512
|
+
*
|
|
513
|
+
* @param value - The input string to parse.
|
|
514
|
+
* @param language - The language of the input string, either 'json' or 'yaml'.
|
|
515
|
+
* @returns The parsed object if it's valid, or null.
|
|
516
|
+
*/
|
|
517
|
+
var parseEditorObject = (value, language) => {
|
|
518
|
+
const parsed = language === "yaml" ? safeParseYaml(value) : safeParseJson(value);
|
|
519
|
+
if (!isObject(parsed)) return null;
|
|
520
|
+
return parsed;
|
|
521
|
+
};
|
|
522
|
+
//#endregion
|
|
523
|
+
//#region src/v2/features/collection/components/Editor/helpers/stringify-document.ts
|
|
524
|
+
/**
|
|
525
|
+
* Stringifies a JavaScript object/document into a formatted string.
|
|
526
|
+
* Uses YAML format if language is 'yaml', otherwise uses JSON.
|
|
527
|
+
*
|
|
528
|
+
* @param document - The JavaScript object to stringify
|
|
529
|
+
* @param language - Output language, expected to be either 'json' or 'yaml'
|
|
530
|
+
* @returns The stringified document in the specified language
|
|
531
|
+
*/
|
|
532
|
+
var stringifyDocument = (document, language) => {
|
|
533
|
+
if (language === "yaml") return stringify(document, { indent: 2 });
|
|
534
|
+
return JSON.stringify(document, null, 2);
|
|
535
|
+
};
|
|
536
|
+
//#endregion
|
|
537
|
+
//#region src/v2/features/collection/components/Editor/hooks/use-editor-state.ts
|
|
538
|
+
var DIAGNOSTICS_COLLAPSED_BOTTOM_PADDING = 46;
|
|
539
|
+
var DIAGNOSTICS_EXPANDED_BOTTOM_PADDING = 155;
|
|
540
|
+
var useEditorState = () => {
|
|
541
|
+
const isAutoSaveEnabled = ref(false);
|
|
542
|
+
const isDirty = ref(false);
|
|
543
|
+
const editorLanguage = ref("json");
|
|
544
|
+
const isDiagnosticsPaneExpanded = ref(false);
|
|
545
|
+
const isEditorMaximized = ref(false);
|
|
546
|
+
const isYamlMode = computed(() => editorLanguage.value === "yaml");
|
|
547
|
+
const editorBottomPadding = computed(() => isDiagnosticsPaneExpanded.value ? DIAGNOSTICS_EXPANDED_BOTTOM_PADDING : DIAGNOSTICS_COLLAPSED_BOTTOM_PADDING);
|
|
548
|
+
const editorRootClass = computed(() => isEditorMaximized.value ? "fixed inset-0 z-50 h-screen w-screen border bg-b-1 p-3 mac:pt-12" : "");
|
|
549
|
+
const getLanguageToggleClass = (isActive) => {
|
|
550
|
+
return `rounded-none px-2 py-1 text-[11px] leading-4 transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-c-accent/30 focus-visible:ring-offset-1 focus-visible:ring-offset-b-1 first:rounded-md last:rounded-md ${isActive ? "bg-b-2 text-c-1 hover:bg-b-2" : "text-c-2 hover:bg-b-2/60 hover:text-c-1"}`;
|
|
551
|
+
};
|
|
552
|
+
const toggleEditorMaximized = () => {
|
|
553
|
+
isEditorMaximized.value = !isEditorMaximized.value;
|
|
554
|
+
};
|
|
555
|
+
return {
|
|
556
|
+
isAutoSaveEnabled,
|
|
557
|
+
isDirty,
|
|
558
|
+
editorLanguage,
|
|
559
|
+
isDiagnosticsPaneExpanded,
|
|
560
|
+
isEditorMaximized,
|
|
561
|
+
isYamlMode,
|
|
562
|
+
editorBottomPadding,
|
|
563
|
+
editorRootClass,
|
|
564
|
+
getLanguageToggleClass,
|
|
565
|
+
toggleEditorMaximized
|
|
566
|
+
};
|
|
567
|
+
};
|
|
568
|
+
//#endregion
|
|
569
|
+
//#region src/v2/features/collection/components/Editor/Editor.vue?vue&type=script&setup=true&lang.ts
|
|
570
|
+
var _hoisted_1 = { class: "grid grid-cols-[minmax(0,1fr)_auto_minmax(0,1fr)] items-center gap-3" };
|
|
571
|
+
var _hoisted_2 = { class: "flex min-w-0 items-center gap-1 overflow-x-auto whitespace-nowrap" };
|
|
572
|
+
var _hoisted_3 = { class: "text-c-3 ml-2 text-[11px]" };
|
|
573
|
+
var _hoisted_4 = { class: "text-c-3 ml-2 text-[11px]" };
|
|
574
|
+
var _hoisted_5 = {
|
|
575
|
+
"aria-label": "Editor language",
|
|
576
|
+
class: "bg-b-1 shadow-border flex items-center justify-self-center overflow-hidden rounded-lg p-0.5",
|
|
577
|
+
role: "tablist"
|
|
578
|
+
};
|
|
579
|
+
var _hoisted_6 = { class: "flex min-w-0 shrink-0 items-center gap-2 justify-self-end" };
|
|
580
|
+
var _hoisted_7 = { class: "text-c-3 ml-2 text-[11px]" };
|
|
581
|
+
var _hoisted_8 = { class: "text-c-3 ml-2 text-[11px]" };
|
|
582
|
+
var _hoisted_9 = { class: "flex min-h-0 w-full min-w-0 flex-1 rounded-lg border" };
|
|
583
|
+
var _hoisted_10 = { class: "pointer-events-none absolute top-2 right-2 z-10" };
|
|
584
|
+
var _hoisted_11 = { key: 1 };
|
|
585
|
+
var MAX_VISIBLE_DIAGNOSTICS = 6;
|
|
586
|
+
var EDITOR_PERSIST_DEBOUNCE_KEY = "editor:replace-document";
|
|
587
|
+
//#endregion
|
|
588
|
+
//#region src/v2/features/collection/components/Editor/Editor.vue
|
|
589
|
+
var Editor_default = /* @__PURE__ */ _plugin_vue_export_helper_default(/* @__PURE__ */ defineComponent({
|
|
590
|
+
__name: "Editor",
|
|
591
|
+
props: {
|
|
592
|
+
documentSlug: {},
|
|
593
|
+
document: {},
|
|
594
|
+
eventBus: {},
|
|
595
|
+
layout: {},
|
|
596
|
+
path: {},
|
|
597
|
+
method: {},
|
|
598
|
+
exampleName: {},
|
|
599
|
+
environment: {},
|
|
600
|
+
securitySchemes: {},
|
|
601
|
+
workspaceStore: {},
|
|
602
|
+
activeWorkspace: {},
|
|
603
|
+
plugins: {},
|
|
604
|
+
customThemes: {},
|
|
605
|
+
currentTheme: {},
|
|
606
|
+
isDarkMode: { type: Boolean },
|
|
607
|
+
fetchRegistryDocument: { type: Function },
|
|
608
|
+
collectionType: {}
|
|
609
|
+
},
|
|
610
|
+
setup(__props) {
|
|
611
|
+
const monacoEditorRef = ref();
|
|
612
|
+
const editorApi = shallowRef();
|
|
613
|
+
const saveLoader = useLoadingState();
|
|
614
|
+
const { isAutoSaveEnabled, isDirty, editorLanguage, isDiagnosticsPaneExpanded, isEditorMaximized, isYamlMode, editorBottomPadding, editorRootClass, getLanguageToggleClass, toggleEditorMaximized } = useEditorState();
|
|
615
|
+
const jsonModel = createJsonModel();
|
|
616
|
+
const yamlModel = createYamlModel();
|
|
617
|
+
const selectedLanguage = ref("json");
|
|
618
|
+
const currentModel = computed(() => {
|
|
619
|
+
return selectedLanguage.value === "json" ? jsonModel : yamlModel;
|
|
620
|
+
});
|
|
621
|
+
const { markers: diagnostics } = useEditorMarkers(computed(() => editorApi.value?.editor));
|
|
622
|
+
const syncEditorBottomPadding = () => {
|
|
623
|
+
editorApi.value?.editor.updateOptions({ padding: {
|
|
624
|
+
top: 0,
|
|
625
|
+
bottom: editorBottomPadding.value
|
|
626
|
+
} });
|
|
627
|
+
};
|
|
628
|
+
const diagnosticCounts = computed(() => getDiagnosticCounts(diagnostics.value));
|
|
629
|
+
const visibleDiagnostics = computed(() => getVisibleDiagnostics(diagnostics.value, MAX_VISIBLE_DIAGNOSTICS));
|
|
630
|
+
const focusDiagnostic = (marker) => {
|
|
631
|
+
const editor = editorApi.value?.editor;
|
|
632
|
+
if (!editor) return;
|
|
633
|
+
editor.setSelection({
|
|
634
|
+
startLineNumber: marker.startLineNumber,
|
|
635
|
+
startColumn: marker.startColumn,
|
|
636
|
+
endLineNumber: marker.endLineNumber,
|
|
637
|
+
endColumn: marker.endColumn
|
|
638
|
+
});
|
|
639
|
+
editor.revealPositionInCenter({
|
|
640
|
+
lineNumber: marker.startLineNumber,
|
|
641
|
+
column: marker.startColumn
|
|
642
|
+
});
|
|
643
|
+
};
|
|
644
|
+
const getEditorValue = () => currentModel.value.model.getValue();
|
|
645
|
+
/** Value from the editor for a specific language (use when switching to avoid reading the wrong model). */
|
|
646
|
+
const getEditorValueForLanguage = (language) => (language === "json" ? jsonModel : yamlModel).model.getValue();
|
|
647
|
+
const getDocumentValue = async (language) => {
|
|
648
|
+
return stringifyDocument(await __props.workspaceStore.getEditableDocument(__props.documentSlug), language ?? selectedLanguage.value);
|
|
649
|
+
};
|
|
650
|
+
const debouncedPersist = debounce({ delay: 1500 });
|
|
651
|
+
const applyProgrammaticEditorValue = (value) => {
|
|
652
|
+
debouncedPersist.cleanup();
|
|
653
|
+
editorApi.value?.setValue(value, true);
|
|
654
|
+
};
|
|
655
|
+
const loadDocumentIntoEditor = async () => {
|
|
656
|
+
applyProgrammaticEditorValue(await getDocumentValue());
|
|
657
|
+
isDirty.value = false;
|
|
658
|
+
await focusOperation();
|
|
659
|
+
};
|
|
660
|
+
const formatDocument = async () => {
|
|
661
|
+
await editorApi.value?.formatDocument();
|
|
662
|
+
};
|
|
663
|
+
const focusOperation = async () => {
|
|
664
|
+
const operationContext = getOperationContext(__props.path, __props.method);
|
|
665
|
+
if (!operationContext) return;
|
|
666
|
+
await editorApi.value?.focusPath([
|
|
667
|
+
"paths",
|
|
668
|
+
operationContext.path,
|
|
669
|
+
operationContext.method
|
|
670
|
+
]);
|
|
671
|
+
};
|
|
672
|
+
const persistEditorToWorkspace = async (value) => {
|
|
673
|
+
const parsed = parseEditorObject(value, editorLanguage.value);
|
|
674
|
+
if (!parsed) {
|
|
675
|
+
const firstError = diagnostics.value.find((m) => m.severity === monaco.MarkerSeverity.Error);
|
|
676
|
+
if (firstError) focusDiagnostic(firstError);
|
|
677
|
+
await saveLoader.invalidate();
|
|
678
|
+
return;
|
|
679
|
+
}
|
|
680
|
+
saveLoader.start();
|
|
681
|
+
await __props.workspaceStore.replaceDocument(__props.documentSlug, parsed);
|
|
682
|
+
isDirty.value = false;
|
|
683
|
+
await saveLoader.validate({ duration: 900 });
|
|
684
|
+
};
|
|
685
|
+
const saveNow = async () => {
|
|
686
|
+
const value = getEditorValue();
|
|
687
|
+
if (!value) return;
|
|
688
|
+
await persistEditorToWorkspace(value);
|
|
689
|
+
};
|
|
690
|
+
const handleEditorChange = (value) => {
|
|
691
|
+
isDirty.value = true;
|
|
692
|
+
if (!isAutoSaveEnabled.value) return;
|
|
693
|
+
debouncedPersist.execute(EDITOR_PERSIST_DEBOUNCE_KEY, () => persistEditorToWorkspace(value));
|
|
694
|
+
};
|
|
695
|
+
const focusOperationServers = async () => {
|
|
696
|
+
const operationContext = getOperationContext(__props.path, __props.method);
|
|
697
|
+
if (!operationContext) return;
|
|
698
|
+
const value = getEditorValue();
|
|
699
|
+
if (!value) return;
|
|
700
|
+
const parsed = parseEditorObject(value, editorLanguage.value);
|
|
701
|
+
if (!parsed || !isObject(parsed.paths)) return;
|
|
702
|
+
const operationPathItem = parsed.paths[operationContext.path];
|
|
703
|
+
if (!isObject(operationPathItem)) return;
|
|
704
|
+
const operation = operationPathItem[operationContext.method];
|
|
705
|
+
if (!isObject(operation)) return;
|
|
706
|
+
operation.servers ??= [];
|
|
707
|
+
editorApi.value?.setValue(stringifyDocument(parsed, editorLanguage.value));
|
|
708
|
+
await editorApi.value?.focusPath([
|
|
709
|
+
"paths",
|
|
710
|
+
operationContext.path,
|
|
711
|
+
operationContext.method,
|
|
712
|
+
"servers"
|
|
713
|
+
]);
|
|
714
|
+
};
|
|
715
|
+
useJsonPointerLinkSupport(editorApi, currentModel);
|
|
716
|
+
onMounted(() => {
|
|
717
|
+
editorApi.value = useEditor({
|
|
718
|
+
element: monacoEditorRef.value ?? document.createElement("div"),
|
|
719
|
+
onChange: handleEditorChange,
|
|
720
|
+
model: currentModel,
|
|
721
|
+
actions: [
|
|
722
|
+
{
|
|
723
|
+
id: "scalar.editor.focusOperation",
|
|
724
|
+
label: "Focus Operation",
|
|
725
|
+
keybindings: [monaco.KeyMod.Alt | monaco.KeyCode.KeyO],
|
|
726
|
+
run: async () => {
|
|
727
|
+
await focusOperation();
|
|
728
|
+
}
|
|
729
|
+
},
|
|
730
|
+
{
|
|
731
|
+
id: "scalar.editor.focusOperationServers",
|
|
732
|
+
label: "Focus Operation Servers",
|
|
733
|
+
keybindings: [monaco.KeyMod.Alt | monaco.KeyCode.KeyS],
|
|
734
|
+
run: async () => {
|
|
735
|
+
await focusOperationServers();
|
|
736
|
+
}
|
|
737
|
+
},
|
|
738
|
+
{
|
|
739
|
+
id: "scalar.editor.formatDocument",
|
|
740
|
+
label: "Format Document",
|
|
741
|
+
keybindings: [monaco.KeyMod.Alt | monaco.KeyMod.Shift | monaco.KeyCode.KeyF],
|
|
742
|
+
run: async () => {
|
|
743
|
+
await formatDocument();
|
|
744
|
+
}
|
|
745
|
+
}
|
|
746
|
+
]
|
|
747
|
+
});
|
|
748
|
+
syncEditorBottomPadding();
|
|
749
|
+
loadDocumentIntoEditor();
|
|
750
|
+
});
|
|
751
|
+
onBeforeUnmount(() => {
|
|
752
|
+
debouncedPersist.cleanup();
|
|
753
|
+
if (isDirty.value && isAutoSaveEnabled.value) saveNow();
|
|
754
|
+
editorApi.value?.dispose?.();
|
|
755
|
+
jsonModel.model.dispose();
|
|
756
|
+
yamlModel.model.dispose();
|
|
757
|
+
});
|
|
758
|
+
watch(() => __props.documentSlug, loadDocumentIntoEditor);
|
|
759
|
+
watch(() => [__props.path, __props.method], async () => {
|
|
760
|
+
await focusOperation();
|
|
761
|
+
});
|
|
762
|
+
watch(isDiagnosticsPaneExpanded, () => {
|
|
763
|
+
syncEditorBottomPadding();
|
|
764
|
+
});
|
|
765
|
+
watch(editorLanguage, async (nextLanguage, previousLanguage) => {
|
|
766
|
+
const wasDirty = isDirty.value;
|
|
767
|
+
const value = getEditorValueForLanguage(previousLanguage ?? "json");
|
|
768
|
+
if (!value) {
|
|
769
|
+
selectedLanguage.value = nextLanguage;
|
|
770
|
+
await nextTick();
|
|
771
|
+
await focusOperation();
|
|
772
|
+
return;
|
|
773
|
+
}
|
|
774
|
+
const parsed = parseEditorObject(value, previousLanguage ?? "json");
|
|
775
|
+
selectedLanguage.value = nextLanguage;
|
|
776
|
+
await nextTick();
|
|
777
|
+
if (parsed) {
|
|
778
|
+
applyProgrammaticEditorValue(stringifyDocument(parsed, nextLanguage));
|
|
779
|
+
isDirty.value = wasDirty;
|
|
780
|
+
}
|
|
781
|
+
await focusOperation();
|
|
782
|
+
});
|
|
783
|
+
watch(isAutoSaveEnabled, (isEnabled) => {
|
|
784
|
+
if (!isEnabled) {
|
|
785
|
+
debouncedPersist.cleanup();
|
|
786
|
+
return;
|
|
787
|
+
}
|
|
788
|
+
if (isDirty.value) {
|
|
789
|
+
const value = getEditorValue();
|
|
790
|
+
if (!value) return;
|
|
791
|
+
debouncedPersist.execute(EDITOR_PERSIST_DEBOUNCE_KEY, () => persistEditorToWorkspace(value));
|
|
792
|
+
}
|
|
793
|
+
}, { flush: "post" });
|
|
794
|
+
return (_ctx, _cache) => {
|
|
795
|
+
return __props.collectionType === "operation" && unref(getOperationContext)(__props.path, __props.method) !== null ? (openBlock(), createElementBlock("div", {
|
|
796
|
+
key: 0,
|
|
797
|
+
class: normalizeClass(["flex w-full min-w-0 flex-1 flex-col gap-2", unref(editorRootClass)])
|
|
798
|
+
}, [createElementVNode("div", _hoisted_1, [
|
|
799
|
+
createElementVNode("div", _hoisted_2, [
|
|
800
|
+
_cache[6] || (_cache[6] = createElementVNode("span", { class: "text-c-2 text-xs font-medium whitespace-nowrap" }, " Shortcuts ", -1)),
|
|
801
|
+
createVNode(unref(ScalarButton), {
|
|
802
|
+
class: "whitespace-nowrap",
|
|
803
|
+
size: "xs",
|
|
804
|
+
variant: "ghost",
|
|
805
|
+
onClick: focusOperation
|
|
806
|
+
}, {
|
|
807
|
+
default: withCtx(() => [_cache[4] || (_cache[4] = createElementVNode("span", null, "Operation", -1)), createElementVNode("span", _hoisted_3, [createVNode(unref(ScalarHotkey), {
|
|
808
|
+
hotkey: "O",
|
|
809
|
+
modifier: ["Alt"]
|
|
810
|
+
})])]),
|
|
811
|
+
_: 1
|
|
812
|
+
}),
|
|
813
|
+
createVNode(unref(ScalarButton), {
|
|
814
|
+
class: "whitespace-nowrap",
|
|
815
|
+
size: "xs",
|
|
816
|
+
variant: "ghost",
|
|
817
|
+
onClick: focusOperationServers
|
|
818
|
+
}, {
|
|
819
|
+
default: withCtx(() => [_cache[5] || (_cache[5] = createElementVNode("span", null, "Servers", -1)), createElementVNode("span", _hoisted_4, [createVNode(unref(ScalarHotkey), {
|
|
820
|
+
hotkey: "S",
|
|
821
|
+
modifier: ["Alt"]
|
|
822
|
+
})])]),
|
|
823
|
+
_: 1
|
|
824
|
+
})
|
|
825
|
+
]),
|
|
826
|
+
createElementVNode("div", _hoisted_5, [createVNode(unref(ScalarButton), {
|
|
827
|
+
"aria-selected": !unref(isYamlMode),
|
|
828
|
+
class: normalizeClass(unref(getLanguageToggleClass)(!unref(isYamlMode))),
|
|
829
|
+
role: "tab",
|
|
830
|
+
size: "xs",
|
|
831
|
+
type: "button",
|
|
832
|
+
variant: "ghost",
|
|
833
|
+
onClick: _cache[0] || (_cache[0] = ($event) => editorLanguage.value = "json")
|
|
834
|
+
}, {
|
|
835
|
+
default: withCtx(() => [..._cache[7] || (_cache[7] = [createTextVNode(" JSON ", -1)])]),
|
|
836
|
+
_: 1
|
|
837
|
+
}, 8, ["aria-selected", "class"]), createVNode(unref(ScalarButton), {
|
|
838
|
+
"aria-selected": unref(isYamlMode),
|
|
839
|
+
class: normalizeClass(unref(getLanguageToggleClass)(unref(isYamlMode))),
|
|
840
|
+
role: "tab",
|
|
841
|
+
size: "xs",
|
|
842
|
+
type: "button",
|
|
843
|
+
variant: "ghost",
|
|
844
|
+
onClick: _cache[1] || (_cache[1] = ($event) => editorLanguage.value = "yaml")
|
|
845
|
+
}, {
|
|
846
|
+
default: withCtx(() => [..._cache[8] || (_cache[8] = [createTextVNode(" YAML ", -1)])]),
|
|
847
|
+
_: 1
|
|
848
|
+
}, 8, ["aria-selected", "class"])]),
|
|
849
|
+
createElementVNode("div", _hoisted_6, [createVNode(unref(ScalarButton), {
|
|
850
|
+
size: "xs",
|
|
851
|
+
variant: "ghost",
|
|
852
|
+
onClick: formatDocument
|
|
853
|
+
}, {
|
|
854
|
+
default: withCtx(() => [createElementVNode("span", null, "Format " + toDisplayString(unref(isYamlMode) ? "YAML" : "JSON"), 1), createElementVNode("span", _hoisted_7, [createVNode(unref(ScalarHotkey), {
|
|
855
|
+
hotkey: "F",
|
|
856
|
+
modifier: ["Alt", "Shift"]
|
|
857
|
+
})])]),
|
|
858
|
+
_: 1
|
|
859
|
+
}), createVNode(unref(ScalarButton), {
|
|
860
|
+
"aria-label": unref(isEditorMaximized) ? "Restore editor size" : "Maximize editor",
|
|
861
|
+
size: "xs",
|
|
862
|
+
variant: "ghost",
|
|
863
|
+
onClick: unref(toggleEditorMaximized)
|
|
864
|
+
}, {
|
|
865
|
+
default: withCtx(() => [createElementVNode("span", null, toDisplayString(unref(isEditorMaximized) ? "Restore" : "Maximize"), 1), createElementVNode("span", _hoisted_8, [unref(isEditorMaximized) ? (openBlock(), createBlock(unref(ScalarIconArrowsIn), {
|
|
866
|
+
key: 0,
|
|
867
|
+
class: "size-3.5"
|
|
868
|
+
})) : (openBlock(), createBlock(unref(ScalarIconArrowsOut), {
|
|
869
|
+
key: 1,
|
|
870
|
+
class: "size-3.5"
|
|
871
|
+
}))])]),
|
|
872
|
+
_: 1
|
|
873
|
+
}, 8, ["aria-label", "onClick"])])
|
|
874
|
+
]), createElementVNode("div", _hoisted_9, [createElementVNode("div", { class: normalizeClass(["relative w-full min-w-0 flex-1", unref(isEditorMaximized) ? "h-full min-h-0" : "h-[500px]"]) }, [
|
|
875
|
+
createElementVNode("div", _hoisted_10, [createVNode(EditorSavePanel_default, {
|
|
876
|
+
isAutoSaveEnabled: unref(isAutoSaveEnabled),
|
|
877
|
+
isDirty: unref(isDirty),
|
|
878
|
+
saveLoader: unref(saveLoader),
|
|
879
|
+
onSaveNow: saveNow,
|
|
880
|
+
"onUpdate:isAutoSaveEnabled": _cache[2] || (_cache[2] = ($event) => isAutoSaveEnabled.value = $event)
|
|
881
|
+
}, null, 8, [
|
|
882
|
+
"isAutoSaveEnabled",
|
|
883
|
+
"isDirty",
|
|
884
|
+
"saveLoader"
|
|
885
|
+
])]),
|
|
886
|
+
createVNode(EditorDiagnosticsPanel_default, {
|
|
887
|
+
diagnosticCounts: diagnosticCounts.value,
|
|
888
|
+
expanded: unref(isDiagnosticsPaneExpanded),
|
|
889
|
+
visibleDiagnostics: visibleDiagnostics.value,
|
|
890
|
+
onFocusDiagnostic: focusDiagnostic,
|
|
891
|
+
onToggle: _cache[3] || (_cache[3] = ($event) => isDiagnosticsPaneExpanded.value = !unref(isDiagnosticsPaneExpanded))
|
|
892
|
+
}, null, 8, [
|
|
893
|
+
"diagnosticCounts",
|
|
894
|
+
"expanded",
|
|
895
|
+
"visibleDiagnostics"
|
|
896
|
+
]),
|
|
897
|
+
createElementVNode("div", {
|
|
898
|
+
ref_key: "monacoEditorRef",
|
|
899
|
+
ref: monacoEditorRef,
|
|
900
|
+
class: "h-full w-full min-w-0 flex-1"
|
|
901
|
+
}, null, 512)
|
|
902
|
+
], 2)])], 2)) : (openBlock(), createElementBlock("div", _hoisted_11, "No operation context found"));
|
|
903
|
+
};
|
|
904
|
+
}
|
|
905
|
+
}), [["__scopeId", "data-v-850fff8f"]]);
|
|
906
|
+
//#endregion
|
|
907
|
+
export { createJsonModel as n, Editor_default as t };
|
|
908
|
+
|
|
909
|
+
//# sourceMappingURL=Editor-BomsGWHx.js.map
|