@scalar/api-reference 1.49.2 → 1.49.4
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 +15 -0
- package/dist/_virtual/_plugin-vue_export-helper.js +8 -0
- package/dist/blocks/index.js +4 -2
- package/dist/blocks/scalar-client-selector-block/components/ClientDropdown.vue.d.ts.map +1 -1
- package/dist/blocks/scalar-client-selector-block/components/ClientDropdown.vue.js +9 -0
- package/dist/blocks/scalar-client-selector-block/components/ClientDropdown.vue.js.map +1 -0
- package/dist/blocks/scalar-client-selector-block/components/ClientDropdown.vue.script.js +106 -0
- package/dist/blocks/scalar-client-selector-block/components/ClientDropdown.vue.script.js.map +1 -0
- package/dist/blocks/scalar-client-selector-block/components/ClientSelector.vue.js +9 -0
- package/dist/blocks/scalar-client-selector-block/components/ClientSelector.vue.js.map +1 -0
- package/dist/blocks/scalar-client-selector-block/components/ClientSelector.vue.script.js +121 -0
- package/dist/blocks/scalar-client-selector-block/components/ClientSelector.vue.script.js.map +1 -0
- package/dist/blocks/scalar-client-selector-block/helpers/featured-clients.js +27 -0
- package/dist/blocks/scalar-client-selector-block/helpers/featured-clients.js.map +1 -0
- package/dist/blocks/scalar-client-selector-block/index.d.ts +1 -1
- package/dist/blocks/scalar-info-block/components/DownloadLink.vue.js +9 -0
- package/dist/blocks/scalar-info-block/components/DownloadLink.vue.js.map +1 -0
- package/dist/blocks/scalar-info-block/components/DownloadLink.vue.script.js +55 -0
- package/dist/blocks/scalar-info-block/components/DownloadLink.vue.script.js.map +1 -0
- package/dist/blocks/scalar-info-block/components/InfoBlock.vue.js +7 -0
- package/dist/blocks/scalar-info-block/components/InfoBlock.vue.js.map +1 -0
- package/dist/blocks/scalar-info-block/components/InfoBlock.vue.script.js +69 -0
- package/dist/blocks/scalar-info-block/components/InfoBlock.vue.script.js.map +1 -0
- package/dist/blocks/scalar-info-block/components/InfoDescription.vue.js +9 -0
- package/dist/blocks/scalar-info-block/components/InfoDescription.vue.js.map +1 -0
- package/dist/blocks/scalar-info-block/components/InfoDescription.vue.script.js +68 -0
- package/dist/blocks/scalar-info-block/components/InfoDescription.vue.script.js.map +1 -0
- package/dist/blocks/scalar-info-block/components/InfoLinks.vue.js +7 -0
- package/dist/blocks/scalar-info-block/components/InfoLinks.vue.js.map +1 -0
- package/dist/blocks/scalar-info-block/components/InfoLinks.vue.script.js +40 -0
- package/dist/blocks/scalar-info-block/components/InfoLinks.vue.script.js.map +1 -0
- package/dist/blocks/scalar-info-block/components/InfoMarkdownSection.vue.js +7 -0
- package/dist/blocks/scalar-info-block/components/InfoMarkdownSection.vue.js.map +1 -0
- package/dist/blocks/scalar-info-block/components/InfoMarkdownSection.vue.script.js +35 -0
- package/dist/blocks/scalar-info-block/components/InfoMarkdownSection.vue.script.js.map +1 -0
- package/dist/blocks/scalar-info-block/components/InfoVersion.vue.js +7 -0
- package/dist/blocks/scalar-info-block/components/InfoVersion.vue.js.map +1 -0
- package/dist/blocks/scalar-info-block/components/InfoVersion.vue.script.js +25 -0
- package/dist/blocks/scalar-info-block/components/InfoVersion.vue.script.js.map +1 -0
- package/dist/blocks/scalar-info-block/components/IntroductionCard.vue.js +9 -0
- package/dist/blocks/scalar-info-block/components/IntroductionCard.vue.js.map +1 -0
- package/dist/blocks/scalar-info-block/components/IntroductionCard.vue.script.js +15 -0
- package/dist/blocks/scalar-info-block/components/IntroductionCard.vue.script.js.map +1 -0
- package/dist/blocks/scalar-info-block/components/IntroductionCardItem.vue.js +14 -0
- package/dist/blocks/scalar-info-block/components/IntroductionCardItem.vue.js.map +1 -0
- package/dist/blocks/scalar-info-block/components/IntroductionLayout.vue.js +9 -0
- package/dist/blocks/scalar-info-block/components/IntroductionLayout.vue.js.map +1 -0
- package/dist/blocks/scalar-info-block/components/IntroductionLayout.vue.script.js +92 -0
- package/dist/blocks/scalar-info-block/components/IntroductionLayout.vue.script.js.map +1 -0
- package/dist/blocks/scalar-info-block/components/OpenApiVersion.vue.js +7 -0
- package/dist/blocks/scalar-info-block/components/OpenApiVersion.vue.js.map +1 -0
- package/dist/blocks/scalar-info-block/components/OpenApiVersion.vue.script.js +19 -0
- package/dist/blocks/scalar-info-block/components/OpenApiVersion.vue.script.js.map +1 -0
- package/dist/blocks/scalar-info-block/index.d.ts +2 -2
- package/dist/blocks/scalar-server-selector-block/components/Selector.vue.js +7 -0
- package/dist/blocks/scalar-server-selector-block/components/Selector.vue.js.map +1 -0
- package/dist/blocks/scalar-server-selector-block/components/Selector.vue.script.js +71 -0
- package/dist/blocks/scalar-server-selector-block/components/Selector.vue.script.js.map +1 -0
- package/dist/blocks/scalar-server-selector-block/components/ServerSelector.vue.js +7 -0
- package/dist/blocks/scalar-server-selector-block/components/ServerSelector.vue.js.map +1 -0
- package/dist/blocks/scalar-server-selector-block/components/ServerSelector.vue.script.js +69 -0
- package/dist/blocks/scalar-server-selector-block/components/ServerSelector.vue.script.js.map +1 -0
- package/dist/blocks/scalar-server-selector-block/index.d.ts +1 -1
- package/dist/browser/standalone.js +35377 -34973
- package/dist/browser/webpack-stats.json +1 -1
- package/dist/components/AgentScalar/AgentScalarButton.vue.js +7 -0
- package/dist/components/AgentScalar/AgentScalarButton.vue.js.map +1 -0
- package/dist/components/AgentScalar/AgentScalarButton.vue.script.js +21 -0
- package/dist/components/AgentScalar/AgentScalarButton.vue.script.js.map +1 -0
- package/dist/components/AgentScalar/AgentScalarChatInterface.vue.js +7 -0
- package/dist/components/AgentScalar/AgentScalarChatInterface.vue.js.map +1 -0
- package/dist/{AgentScalarChatInterface-MUbtSqMw.js → components/AgentScalar/AgentScalarChatInterface.vue.script.js} +5 -6
- package/dist/components/AgentScalar/AgentScalarChatInterface.vue.script.js.map +1 -0
- package/dist/components/AgentScalar/AgentScalarDrawer.vue.d.ts +0 -1
- package/dist/components/AgentScalar/AgentScalarDrawer.vue.d.ts.map +1 -1
- package/dist/components/AgentScalar/AgentScalarDrawer.vue.js +9 -0
- package/dist/components/AgentScalar/AgentScalarDrawer.vue.js.map +1 -0
- package/dist/components/AgentScalar/AgentScalarDrawer.vue.script.js +65 -0
- package/dist/components/AgentScalar/AgentScalarDrawer.vue.script.js.map +1 -0
- package/dist/components/AgentScalar/OpenMCPButton.vue.js +9 -0
- package/dist/components/AgentScalar/OpenMCPButton.vue.js.map +1 -0
- package/dist/components/AgentScalar/OpenMCPButton.vue.script.js +184 -0
- package/dist/components/AgentScalar/OpenMCPButton.vue.script.js.map +1 -0
- package/dist/components/AgentScalar/index.d.ts +3 -3
- package/dist/components/Anchor/Anchor.vue.js +7 -0
- package/dist/components/Anchor/Anchor.vue.js.map +1 -0
- package/dist/components/Anchor/Anchor.vue.script.js +40 -0
- package/dist/components/Anchor/Anchor.vue.script.js.map +1 -0
- package/dist/components/Anchor/WithBreadcrumb.vue.js +7 -0
- package/dist/components/Anchor/WithBreadcrumb.vue.js.map +1 -0
- package/dist/components/Anchor/WithBreadcrumb.vue.script.js +32 -0
- package/dist/components/Anchor/WithBreadcrumb.vue.script.js.map +1 -0
- package/dist/components/Anchor/index.d.ts +2 -2
- package/dist/components/ApiReference.vue.d.ts.map +1 -1
- package/dist/components/ApiReference.vue.js +12 -0
- package/dist/components/ApiReference.vue.js.map +1 -0
- package/dist/components/ApiReference.vue.script.js +662 -0
- package/dist/components/ApiReference.vue.script.js.map +1 -0
- package/dist/components/Badge/Badge.vue.js +9 -0
- package/dist/components/Badge/Badge.vue.js.map +1 -0
- package/dist/components/Badge/Badge.vue.script.js +22 -0
- package/dist/components/Badge/Badge.vue.script.js.map +1 -0
- package/dist/components/Badge/index.d.ts +1 -1
- package/dist/components/ClassicHeader.vue.js +16 -0
- package/dist/components/ClassicHeader.vue.js.map +1 -0
- package/dist/components/Content/Auth/Auth.vue.js +7 -0
- package/dist/components/Content/Auth/Auth.vue.js.map +1 -0
- package/dist/components/Content/Auth/Auth.vue.script.js +70 -0
- package/dist/components/Content/Auth/Auth.vue.script.js.map +1 -0
- package/dist/components/Content/Auth/helpers/get-default-security.js +64 -0
- package/dist/components/Content/Auth/helpers/get-default-security.js.map +1 -0
- package/dist/components/Content/Auth/index.d.ts +1 -1
- package/dist/components/Content/Content.vue.js +8 -0
- package/dist/components/Content/Content.vue.js.map +1 -0
- package/dist/components/Content/Content.vue.script.js +192 -0
- package/dist/components/Content/Content.vue.script.js.map +1 -0
- package/dist/components/Content/Models/Model.vue.js +7 -0
- package/dist/components/Content/Models/Model.vue.js.map +1 -0
- package/dist/components/Content/Models/Model.vue.script.js +61 -0
- package/dist/components/Content/Models/Model.vue.script.js.map +1 -0
- package/dist/components/Content/Models/ModelTag.vue.js +7 -0
- package/dist/components/Content/Models/ModelTag.vue.js.map +1 -0
- package/dist/components/Content/Models/ModelTag.vue.script.js +69 -0
- package/dist/components/Content/Models/ModelTag.vue.script.js.map +1 -0
- package/dist/components/Content/Models/components/ClassicLayout.vue.js +9 -0
- package/dist/components/Content/Models/components/ClassicLayout.vue.js.map +1 -0
- package/dist/components/Content/Models/components/ClassicLayout.vue.script.js +81 -0
- package/dist/components/Content/Models/components/ClassicLayout.vue.script.js.map +1 -0
- package/dist/components/Content/Models/components/ModernLayout.vue.js +7 -0
- package/dist/components/Content/Models/components/ModernLayout.vue.js.map +1 -0
- package/dist/components/Content/Models/components/ModernLayout.vue.script.js +66 -0
- package/dist/components/Content/Models/components/ModernLayout.vue.script.js.map +1 -0
- package/dist/components/Content/Models/index.d.ts +2 -2
- package/dist/components/Content/Operations/TraversedEntry.vue.js +7 -0
- package/dist/components/Content/Operations/TraversedEntry.vue.js.map +1 -0
- package/dist/components/Content/Operations/TraversedEntry.vue.script.js +213 -0
- package/dist/components/Content/Operations/TraversedEntry.vue.script.js.map +1 -0
- package/dist/components/Content/Schema/RenderString.vue.js +7 -0
- package/dist/components/Content/Schema/RenderString.vue.js.map +1 -0
- package/dist/components/Content/Schema/RenderString.vue.script.js +36 -0
- package/dist/components/Content/Schema/RenderString.vue.script.js.map +1 -0
- package/dist/components/Content/Schema/Schema.vue.d.ts +1 -1
- package/dist/components/Content/Schema/Schema.vue.js +9 -0
- package/dist/components/Content/Schema/Schema.vue.js.map +1 -0
- package/dist/components/Content/Schema/Schema.vue.script.js +184 -0
- package/dist/components/Content/Schema/Schema.vue.script.js.map +1 -0
- package/dist/components/Content/Schema/SchemaComposition.vue.d.ts +2 -2
- package/dist/components/Content/Schema/SchemaComposition.vue.js +7 -0
- package/dist/components/Content/Schema/SchemaComposition.vue.js.map +1 -0
- package/dist/components/Content/Schema/SchemaComposition.vue.script.js +146 -0
- package/dist/components/Content/Schema/SchemaComposition.vue.script.js.map +1 -0
- package/dist/components/Content/Schema/SchemaEnumPropertyItem.vue.js +9 -0
- package/dist/components/Content/Schema/SchemaEnumPropertyItem.vue.js.map +1 -0
- package/dist/components/Content/Schema/SchemaEnumPropertyItem.vue.script.js +29 -0
- package/dist/components/Content/Schema/SchemaEnumPropertyItem.vue.script.js.map +1 -0
- package/dist/components/Content/Schema/SchemaEnums.vue.js +9 -0
- package/dist/components/Content/Schema/SchemaEnums.vue.js.map +1 -0
- package/dist/components/Content/Schema/SchemaEnums.vue.script.js +108 -0
- package/dist/components/Content/Schema/SchemaEnums.vue.script.js.map +1 -0
- package/dist/components/Content/Schema/SchemaHeading.vue.js +9 -0
- package/dist/components/Content/Schema/SchemaHeading.vue.js.map +1 -0
- package/dist/components/Content/Schema/SchemaHeading.vue.script.js +45 -0
- package/dist/components/Content/Schema/SchemaHeading.vue.script.js.map +1 -0
- package/dist/components/Content/Schema/SchemaObjectExampleCodeBlock.vue.js +7 -0
- package/dist/components/Content/Schema/SchemaObjectExampleCodeBlock.vue.js.map +1 -0
- package/dist/components/Content/Schema/SchemaObjectExampleCodeBlock.vue.script.js +55 -0
- package/dist/components/Content/Schema/SchemaObjectExampleCodeBlock.vue.script.js.map +1 -0
- package/dist/components/Content/Schema/SchemaObjectProperties.vue.d.ts +1 -1
- package/dist/components/Content/Schema/SchemaObjectProperties.vue.js +7 -0
- package/dist/components/Content/Schema/SchemaObjectProperties.vue.js.map +1 -0
- package/dist/components/Content/Schema/SchemaObjectProperties.vue.script.js +161 -0
- package/dist/components/Content/Schema/SchemaObjectProperties.vue.script.js.map +1 -0
- package/dist/components/Content/Schema/SchemaProperty.vue.d.ts +1 -1
- package/dist/components/Content/Schema/SchemaProperty.vue.js +9 -0
- package/dist/components/Content/Schema/SchemaProperty.vue.js.map +1 -0
- package/dist/components/Content/Schema/SchemaProperty.vue.script.js +256 -0
- package/dist/components/Content/Schema/SchemaProperty.vue.script.js.map +1 -0
- package/dist/components/Content/Schema/SchemaPropertyDefault.vue.js +9 -0
- package/dist/components/Content/Schema/SchemaPropertyDefault.vue.js.map +1 -0
- package/dist/components/Content/Schema/SchemaPropertyDefault.vue.script.js +35 -0
- package/dist/components/Content/Schema/SchemaPropertyDefault.vue.script.js.map +1 -0
- package/dist/components/Content/Schema/SchemaPropertyDetail.vue.js +9 -0
- package/dist/components/Content/Schema/SchemaPropertyDetail.vue.js.map +1 -0
- package/dist/components/Content/Schema/SchemaPropertyDetail.vue.script.js +30 -0
- package/dist/components/Content/Schema/SchemaPropertyDetail.vue.script.js.map +1 -0
- package/dist/components/Content/Schema/SchemaPropertyExamples.vue.js +9 -0
- package/dist/components/Content/Schema/SchemaPropertyExamples.vue.js.map +1 -0
- package/dist/components/Content/Schema/SchemaPropertyExamples.vue.script.js +67 -0
- package/dist/components/Content/Schema/SchemaPropertyExamples.vue.script.js.map +1 -0
- package/dist/components/Content/Schema/SchemaPropertyHeading.vue.js +9 -0
- package/dist/components/Content/Schema/SchemaPropertyHeading.vue.js.map +1 -0
- package/dist/components/Content/Schema/SchemaPropertyHeading.vue.script.js +251 -0
- package/dist/components/Content/Schema/SchemaPropertyHeading.vue.script.js.map +1 -0
- package/dist/components/Content/Schema/helpers/format-example.js +26 -0
- package/dist/components/Content/Schema/helpers/format-example.js.map +1 -0
- package/dist/components/Content/Schema/helpers/format-value.js +22 -0
- package/dist/components/Content/Schema/helpers/format-value.js.map +1 -0
- package/dist/components/Content/Schema/helpers/get-compositions-to-render.d.ts +1 -1
- package/dist/components/Content/Schema/helpers/get-compositions-to-render.js +32 -0
- package/dist/components/Content/Schema/helpers/get-compositions-to-render.js.map +1 -0
- package/dist/components/Content/Schema/helpers/get-enum-values.js +22 -0
- package/dist/components/Content/Schema/helpers/get-enum-values.js.map +1 -0
- package/dist/components/Content/Schema/helpers/get-property-description.js +36 -0
- package/dist/components/Content/Schema/helpers/get-property-description.js.map +1 -0
- package/dist/components/Content/Schema/helpers/get-ref-name.js +19 -0
- package/dist/components/Content/Schema/helpers/get-ref-name.js.map +1 -0
- package/dist/components/Content/Schema/helpers/get-schema-type.js +49 -0
- package/dist/components/Content/Schema/helpers/get-schema-type.js.map +1 -0
- package/dist/components/Content/Schema/helpers/has-complex-array-items.js +53 -0
- package/dist/components/Content/Schema/helpers/has-complex-array-items.js.map +1 -0
- package/dist/components/Content/Schema/helpers/is-empty-schema-object.js +18 -0
- package/dist/components/Content/Schema/helpers/is-empty-schema-object.js.map +1 -0
- package/dist/components/Content/Schema/helpers/is-type-object.js +18 -0
- package/dist/components/Content/Schema/helpers/is-type-object.js.map +1 -0
- package/dist/components/Content/Schema/helpers/merge-all-of-schemas.js +175 -0
- package/dist/components/Content/Schema/helpers/merge-all-of-schemas.js.map +1 -0
- package/dist/components/Content/Schema/helpers/optimize-value-for-display.js +68 -0
- package/dist/components/Content/Schema/helpers/optimize-value-for-display.js.map +1 -0
- package/dist/components/Content/Schema/helpers/schema-composition.js +11 -0
- package/dist/components/Content/Schema/helpers/schema-composition.js.map +1 -0
- package/dist/components/Content/Schema/helpers/schema-name.js +23 -0
- package/dist/components/Content/Schema/helpers/schema-name.js.map +1 -0
- package/dist/components/Content/Schema/helpers/should-display-description.js +17 -0
- package/dist/components/Content/Schema/helpers/should-display-description.js.map +1 -0
- package/dist/components/Content/Schema/helpers/should-display-heading.js +18 -0
- package/dist/components/Content/Schema/helpers/should-display-heading.js.map +1 -0
- package/dist/components/Content/Schema/helpers/should-render-array-item-composition.js +20 -0
- package/dist/components/Content/Schema/helpers/should-render-array-item-composition.js.map +1 -0
- package/dist/components/Content/Schema/helpers/sort-property-names.js +45 -0
- package/dist/components/Content/Schema/helpers/sort-property-names.js.map +1 -0
- package/dist/components/Content/Schema/index.d.ts +4 -4
- package/dist/components/Content/Tags/Tag.vue.js +7 -0
- package/dist/components/Content/Tags/Tag.vue.js.map +1 -0
- package/dist/components/Content/Tags/Tag.vue.script.js +56 -0
- package/dist/components/Content/Tags/Tag.vue.script.js.map +1 -0
- package/dist/components/Content/Tags/components/ClassicLayout.vue.js +9 -0
- package/dist/components/Content/Tags/components/ClassicLayout.vue.js.map +1 -0
- package/dist/components/Content/Tags/components/ClassicLayout.vue.script.js +49 -0
- package/dist/components/Content/Tags/components/ClassicLayout.vue.script.js.map +1 -0
- package/dist/components/Content/Tags/components/ModernLayout.vue.js +9 -0
- package/dist/components/Content/Tags/components/ModernLayout.vue.js.map +1 -0
- package/dist/components/Content/Tags/components/ModernLayout.vue.script.js +63 -0
- package/dist/components/Content/Tags/components/ModernLayout.vue.script.js.map +1 -0
- package/dist/components/Content/Tags/components/TagSection.vue.js +7 -0
- package/dist/components/Content/Tags/components/TagSection.vue.js.map +1 -0
- package/dist/components/Content/Tags/components/TagSection.vue.script.js +78 -0
- package/dist/components/Content/Tags/components/TagSection.vue.script.js.map +1 -0
- package/dist/components/Content/Tags/index.d.ts +1 -1
- package/dist/components/Content/index.d.ts +2 -2
- package/dist/components/GettingStarted.vue.js +9 -0
- package/dist/components/GettingStarted.vue.js.map +1 -0
- package/dist/components/GettingStarted.vue.script.js +71 -0
- package/dist/components/GettingStarted.vue.script.js.map +1 -0
- package/dist/components/HttpMethod/HttpMethod.vue.js +7 -0
- package/dist/components/HttpMethod/HttpMethod.vue.js.map +1 -0
- package/dist/components/HttpMethod/HttpMethod.vue.script.js +33 -0
- package/dist/components/HttpMethod/HttpMethod.vue.script.js.map +1 -0
- package/dist/components/HttpMethod/index.d.ts +1 -1
- package/dist/components/IntersectionObserver.vue.js +7 -0
- package/dist/components/IntersectionObserver.vue.js.map +1 -0
- package/dist/components/IntersectionObserver.vue.script.js +45 -0
- package/dist/components/IntersectionObserver.vue.script.js.map +1 -0
- package/dist/components/Lazy/Lazy.vue.js +7 -0
- package/dist/components/Lazy/Lazy.vue.js.map +1 -0
- package/dist/components/Lazy/Lazy.vue.script.js +101 -0
- package/dist/components/Lazy/Lazy.vue.script.js.map +1 -0
- package/dist/components/LinkList/LinkList.vue.js +9 -0
- package/dist/components/LinkList/LinkList.vue.js.map +1 -0
- package/dist/components/LinkList/LinkList.vue.script.js +53 -0
- package/dist/components/LinkList/LinkList.vue.script.js.map +1 -0
- package/dist/components/LinkList/index.d.ts +1 -1
- package/dist/components/LoadingSkeleton.vue.js +9 -0
- package/dist/components/LoadingSkeleton.vue.js.map +1 -0
- package/dist/components/LoadingSkeleton.vue.script.js +20 -0
- package/dist/components/LoadingSkeleton.vue.script.js.map +1 -0
- package/dist/components/MobileHeader.vue.d.ts.map +1 -1
- package/dist/components/MobileHeader.vue.js +7 -0
- package/dist/components/MobileHeader.vue.js.map +1 -0
- package/dist/components/MobileHeader.vue.script.js +43 -0
- package/dist/components/MobileHeader.vue.script.js.map +1 -0
- package/dist/components/OperationPath.vue.js +9 -0
- package/dist/components/OperationPath.vue.js.map +1 -0
- package/dist/components/OperationPath.vue.script.js +24 -0
- package/dist/components/OperationPath.vue.script.js.map +1 -0
- package/dist/components/OperationsList/OperationsList.vue.js +9 -0
- package/dist/components/OperationsList/OperationsList.vue.js.map +1 -0
- package/dist/components/OperationsList/OperationsList.vue.script.js +49 -0
- package/dist/components/OperationsList/OperationsList.vue.script.js.map +1 -0
- package/dist/components/OperationsList/OperationsListItem.vue.js +9 -0
- package/dist/components/OperationsList/OperationsListItem.vue.js.map +1 -0
- package/dist/components/OperationsList/OperationsListItem.vue.script.js +51 -0
- package/dist/components/OperationsList/OperationsListItem.vue.script.js.map +1 -0
- package/dist/components/OperationsList/index.d.ts +1 -1
- package/dist/components/RenderPlugins/RenderPlugins.vue.js +7 -0
- package/dist/components/RenderPlugins/RenderPlugins.vue.js.map +1 -0
- package/dist/components/RenderPlugins/RenderPlugins.vue.script.js +44 -0
- package/dist/components/RenderPlugins/RenderPlugins.vue.script.js.map +1 -0
- package/dist/components/RenderPlugins/index.d.ts +1 -1
- package/dist/components/ScreenReader.vue.js +9 -0
- package/dist/components/ScreenReader.vue.js.map +1 -0
- package/dist/components/ScreenReader.vue.script.js +22 -0
- package/dist/components/ScreenReader.vue.script.js.map +1 -0
- package/dist/components/Section/CompactSection.vue.js +9 -0
- package/dist/components/Section/CompactSection.vue.js.map +1 -0
- package/dist/components/Section/CompactSection.vue.script.js +56 -0
- package/dist/components/Section/CompactSection.vue.script.js.map +1 -0
- package/dist/components/Section/Section.vue.js +9 -0
- package/dist/components/Section/Section.vue.js.map +1 -0
- package/dist/components/Section/Section.vue.script.js +23 -0
- package/dist/components/Section/Section.vue.script.js.map +1 -0
- package/dist/components/Section/SectionAccordion.vue.js +9 -0
- package/dist/components/Section/SectionAccordion.vue.js.map +1 -0
- package/dist/components/Section/SectionAccordion.vue.script.js +60 -0
- package/dist/components/Section/SectionAccordion.vue.script.js.map +1 -0
- package/dist/components/Section/SectionColumn.vue.js +14 -0
- package/dist/components/Section/SectionColumn.vue.js.map +1 -0
- package/dist/components/Section/SectionColumns.vue.js +14 -0
- package/dist/components/Section/SectionColumns.vue.js.map +1 -0
- package/dist/components/Section/SectionContainer.vue.js +9 -0
- package/dist/components/Section/SectionContainer.vue.js.map +1 -0
- package/dist/components/Section/SectionContainer.vue.script.js +19 -0
- package/dist/components/Section/SectionContainer.vue.script.js.map +1 -0
- package/dist/components/Section/SectionContainerAccordion.vue.js +9 -0
- package/dist/components/Section/SectionContainerAccordion.vue.js.map +1 -0
- package/dist/components/Section/SectionContainerAccordion.vue.script.js +40 -0
- package/dist/components/Section/SectionContainerAccordion.vue.script.js.map +1 -0
- package/dist/components/Section/SectionContent.vue.js +9 -0
- package/dist/components/Section/SectionContent.vue.js.map +1 -0
- package/dist/components/Section/SectionContent.vue.script.js +23 -0
- package/dist/components/Section/SectionContent.vue.script.js.map +1 -0
- package/dist/components/Section/SectionHeader.vue.js +9 -0
- package/dist/components/Section/SectionHeader.vue.js.map +1 -0
- package/dist/components/Section/SectionHeader.vue.script.js +23 -0
- package/dist/components/Section/SectionHeader.vue.script.js.map +1 -0
- package/dist/components/Section/SectionHeaderTag.vue.js +9 -0
- package/dist/components/Section/SectionHeaderTag.vue.js.map +1 -0
- package/dist/components/Section/SectionHeaderTag.vue.script.js +18 -0
- package/dist/components/Section/SectionHeaderTag.vue.script.js.map +1 -0
- package/dist/components/Section/index.d.ts +10 -10
- package/dist/components/SectionFlare/SectionFlare.vue.js +14 -0
- package/dist/components/SectionFlare/SectionFlare.vue.js.map +1 -0
- package/dist/components/SectionFlare/index.d.ts +1 -1
- package/dist/components/ShowMoreButton.vue.js +9 -0
- package/dist/components/ShowMoreButton.vue.js.map +1 -0
- package/dist/components/ShowMoreButton.vue.script.js +22 -0
- package/dist/components/ShowMoreButton.vue.script.js.map +1 -0
- package/dist/components/index.d.ts +5 -5
- package/dist/components/index.js +20 -102
- package/dist/{urls-gPTXGgbj.js → consts/urls.js} +2 -2
- package/dist/consts/urls.js.map +1 -0
- package/dist/features/Operation/Operation.vue.js +7 -0
- package/dist/features/Operation/Operation.vue.js.map +1 -0
- package/dist/features/Operation/Operation.vue.script.js +115 -0
- package/dist/features/Operation/Operation.vue.script.js.map +1 -0
- package/dist/features/Operation/components/ContentTypeSelect.vue.js +7 -0
- package/dist/features/Operation/components/ContentTypeSelect.vue.js.map +1 -0
- package/dist/features/Operation/components/ContentTypeSelect.vue.script.js +75 -0
- package/dist/features/Operation/components/ContentTypeSelect.vue.script.js.map +1 -0
- package/dist/features/Operation/components/Header.vue.js +7 -0
- package/dist/features/Operation/components/Header.vue.js.map +1 -0
- package/dist/features/Operation/components/Header.vue.script.js +42 -0
- package/dist/features/Operation/components/Header.vue.script.js.map +1 -0
- package/dist/features/Operation/components/Headers.vue.js +9 -0
- package/dist/features/Operation/components/Headers.vue.js.map +1 -0
- package/dist/features/Operation/components/Headers.vue.script.js +58 -0
- package/dist/features/Operation/components/Headers.vue.script.js.map +1 -0
- package/dist/features/Operation/components/OperationParameters.vue.d.ts +1 -1
- package/dist/features/Operation/components/OperationParameters.vue.js +7 -0
- package/dist/features/Operation/components/OperationParameters.vue.js.map +1 -0
- package/dist/features/Operation/components/OperationParameters.vue.script.js +108 -0
- package/dist/features/Operation/components/OperationParameters.vue.script.js.map +1 -0
- package/dist/features/Operation/components/OperationResponses.vue.d.ts +1 -1
- package/dist/features/Operation/components/OperationResponses.vue.js +7 -0
- package/dist/features/Operation/components/OperationResponses.vue.js.map +1 -0
- package/dist/features/Operation/components/OperationResponses.vue.script.js +48 -0
- package/dist/features/Operation/components/OperationResponses.vue.script.js.map +1 -0
- package/dist/features/Operation/components/ParameterList.vue.d.ts +1 -1
- package/dist/features/Operation/components/ParameterList.vue.js +7 -0
- package/dist/features/Operation/components/ParameterList.vue.js.map +1 -0
- package/dist/features/Operation/components/ParameterList.vue.script.js +53 -0
- package/dist/features/Operation/components/ParameterList.vue.script.js.map +1 -0
- package/dist/features/Operation/components/ParameterListItem.vue.d.ts +1 -1
- package/dist/features/Operation/components/ParameterListItem.vue.js +9 -0
- package/dist/features/Operation/components/ParameterListItem.vue.js.map +1 -0
- package/dist/features/Operation/components/ParameterListItem.vue.script.js +161 -0
- package/dist/features/Operation/components/ParameterListItem.vue.script.js.map +1 -0
- package/dist/features/Operation/components/RequestBody.vue.js +9 -0
- package/dist/features/Operation/components/RequestBody.vue.js.map +1 -0
- package/dist/features/Operation/components/RequestBody.vue.script.js +154 -0
- package/dist/features/Operation/components/RequestBody.vue.script.js.map +1 -0
- package/dist/features/Operation/components/callbacks/Callback.vue.d.ts +1 -1
- package/dist/features/Operation/components/callbacks/Callback.vue.js +9 -0
- package/dist/features/Operation/components/callbacks/Callback.vue.js.map +1 -0
- package/dist/features/Operation/components/callbacks/Callback.vue.script.js +62 -0
- package/dist/features/Operation/components/callbacks/Callback.vue.script.js.map +1 -0
- package/dist/features/Operation/components/callbacks/Callbacks.vue.d.ts +1 -1
- package/dist/features/Operation/components/callbacks/Callbacks.vue.js +7 -0
- package/dist/features/Operation/components/callbacks/Callbacks.vue.js.map +1 -0
- package/dist/features/Operation/components/callbacks/Callbacks.vue.script.js +67 -0
- package/dist/features/Operation/components/callbacks/Callbacks.vue.script.js.map +1 -0
- package/dist/features/Operation/helpers/filter-selected-security.js +30 -0
- package/dist/features/Operation/helpers/filter-selected-security.js.map +1 -0
- package/dist/features/Operation/helpers/get-first-server.js +27 -0
- package/dist/features/Operation/helpers/get-first-server.js.map +1 -0
- package/dist/features/Operation/index.d.ts +1 -1
- package/dist/features/Operation/layouts/ClassicLayout.vue.d.ts +1 -1
- package/dist/features/Operation/layouts/ClassicLayout.vue.js +9 -0
- package/dist/features/Operation/layouts/ClassicLayout.vue.js.map +1 -0
- package/dist/features/Operation/layouts/ClassicLayout.vue.script.js +243 -0
- package/dist/features/Operation/layouts/ClassicLayout.vue.script.js.map +1 -0
- package/dist/features/Operation/layouts/ModernLayout.vue.d.ts +1 -1
- package/dist/features/Operation/layouts/ModernLayout.vue.js +9 -0
- package/dist/features/Operation/layouts/ModernLayout.vue.js.map +1 -0
- package/dist/features/Operation/layouts/ModernLayout.vue.script.js +243 -0
- package/dist/features/Operation/layouts/ModernLayout.vue.script.js.map +1 -0
- package/dist/features/Search/components/SearchButton.vue.js +7 -0
- package/dist/features/Search/components/SearchButton.vue.js.map +1 -0
- package/dist/features/Search/components/SearchButton.vue.script.js +77 -0
- package/dist/features/Search/components/SearchButton.vue.script.js.map +1 -0
- package/dist/features/Search/components/SearchModal.vue.js +9 -0
- package/dist/features/Search/components/SearchModal.vue.js.map +1 -0
- package/dist/features/Search/components/SearchModal.vue.script.js +115 -0
- package/dist/features/Search/components/SearchModal.vue.script.js.map +1 -0
- package/dist/features/Search/components/SearchResult.vue.d.ts +1 -1
- package/dist/features/Search/components/SearchResult.vue.js +7 -0
- package/dist/features/Search/components/SearchResult.vue.js.map +1 -0
- package/dist/features/Search/components/SearchResult.vue.script.js +69 -0
- package/dist/features/Search/components/SearchResult.vue.script.js.map +1 -0
- package/dist/features/Search/helpers/create-fuse-instance.d.ts +1 -1
- package/dist/features/Search/helpers/create-fuse-instance.js +52 -0
- package/dist/features/Search/helpers/create-fuse-instance.js.map +1 -0
- package/dist/features/Search/helpers/create-search-index.d.ts +1 -1
- package/dist/features/Search/helpers/create-search-index.js +127 -0
- package/dist/features/Search/helpers/create-search-index.js.map +1 -0
- package/dist/features/Search/hooks/useSearchIndex.js +31 -0
- package/dist/features/Search/hooks/useSearchIndex.js.map +1 -0
- package/dist/features/Search/index.d.ts +2 -2
- package/dist/features/Search/types.d.ts +1 -1
- package/dist/features/ask-agent-button/AskAgentButton.vue.js +9 -0
- package/dist/features/ask-agent-button/AskAgentButton.vue.js.map +1 -0
- package/dist/features/ask-agent-button/AskAgentButton.vue.script.js +49 -0
- package/dist/features/ask-agent-button/AskAgentButton.vue.script.js.map +1 -0
- package/dist/features/developer-tools/DeveloperTools.vue.js +7 -0
- package/dist/features/developer-tools/DeveloperTools.vue.js.map +1 -0
- package/dist/features/developer-tools/DeveloperTools.vue.script.js +49 -0
- package/dist/features/developer-tools/DeveloperTools.vue.script.js.map +1 -0
- package/dist/features/developer-tools/components/ApiReferenceToolbarBlurb.vue.js +13 -0
- package/dist/features/developer-tools/components/ApiReferenceToolbarBlurb.vue.js.map +1 -0
- package/dist/features/developer-tools/components/ApiReferenceToolbarConfigLayout.vue.js +7 -0
- package/dist/features/developer-tools/components/ApiReferenceToolbarConfigLayout.vue.js.map +1 -0
- package/dist/features/developer-tools/components/ApiReferenceToolbarConfigLayout.vue.script.js +38 -0
- package/dist/features/developer-tools/components/ApiReferenceToolbarConfigLayout.vue.script.js.map +1 -0
- package/dist/features/developer-tools/components/ApiReferenceToolbarConfigLayoutOptions.vue.js +7 -0
- package/dist/features/developer-tools/components/ApiReferenceToolbarConfigLayoutOptions.vue.js.map +1 -0
- package/dist/features/developer-tools/components/ApiReferenceToolbarConfigLayoutOptions.vue.script.js +112 -0
- package/dist/features/developer-tools/components/ApiReferenceToolbarConfigLayoutOptions.vue.script.js.map +1 -0
- package/dist/features/developer-tools/components/ApiReferenceToolbarConfigTheme.vue.js +7 -0
- package/dist/features/developer-tools/components/ApiReferenceToolbarConfigTheme.vue.js.map +1 -0
- package/dist/features/developer-tools/components/ApiReferenceToolbarConfigTheme.vue.script.js +60 -0
- package/dist/features/developer-tools/components/ApiReferenceToolbarConfigTheme.vue.script.js.map +1 -0
- package/dist/features/developer-tools/components/ApiReferenceToolbarPopover.vue.js +7 -0
- package/dist/features/developer-tools/components/ApiReferenceToolbarPopover.vue.js.map +1 -0
- package/dist/features/developer-tools/components/ApiReferenceToolbarPopover.vue.script.js +35 -0
- package/dist/features/developer-tools/components/ApiReferenceToolbarPopover.vue.script.js.map +1 -0
- package/dist/features/developer-tools/components/ApiReferenceToolbarRegisterButton.vue.js +7 -0
- package/dist/features/developer-tools/components/ApiReferenceToolbarRegisterButton.vue.js.map +1 -0
- package/dist/features/developer-tools/components/ApiReferenceToolbarRegisterButton.vue.script.js +68 -0
- package/dist/features/developer-tools/components/ApiReferenceToolbarRegisterButton.vue.script.js.map +1 -0
- package/dist/features/developer-tools/components/ApiReferenceToolbarShareRegister.vue.js +7 -0
- package/dist/features/developer-tools/components/ApiReferenceToolbarShareRegister.vue.js.map +1 -0
- package/dist/features/developer-tools/components/ApiReferenceToolbarShareRegister.vue.script.js +80 -0
- package/dist/features/developer-tools/components/ApiReferenceToolbarShareRegister.vue.script.js.map +1 -0
- package/dist/features/developer-tools/components/ApiReferenceToolbarShareTemporary.vue.js +7 -0
- package/dist/features/developer-tools/components/ApiReferenceToolbarShareTemporary.vue.js.map +1 -0
- package/dist/features/developer-tools/components/ApiReferenceToolbarShareTemporary.vue.script.js +66 -0
- package/dist/features/developer-tools/components/ApiReferenceToolbarShareTemporary.vue.script.js.map +1 -0
- package/dist/features/developer-tools/components/ApiReferenceToolbarTitle.vue.js +7 -0
- package/dist/features/developer-tools/components/ApiReferenceToolbarTitle.vue.js.map +1 -0
- package/dist/features/developer-tools/components/ApiReferenceToolbarTitle.vue.script.js +44 -0
- package/dist/features/developer-tools/components/ApiReferenceToolbarTitle.vue.script.js.map +1 -0
- package/dist/features/developer-tools/components/DeployApiReference.vue.js +7 -0
- package/dist/features/developer-tools/components/DeployApiReference.vue.js.map +1 -0
- package/dist/features/developer-tools/components/DeployApiReference.vue.script.js +26 -0
- package/dist/features/developer-tools/components/DeployApiReference.vue.script.js.map +1 -0
- package/dist/features/developer-tools/components/ModifyConfiguration.vue.js +7 -0
- package/dist/features/developer-tools/components/ModifyConfiguration.vue.js.map +1 -0
- package/dist/features/developer-tools/components/ModifyConfiguration.vue.script.js +86 -0
- package/dist/features/developer-tools/components/ModifyConfiguration.vue.script.js.map +1 -0
- package/dist/features/developer-tools/components/ShareApiReference.vue.js +7 -0
- package/dist/features/developer-tools/components/ShareApiReference.vue.js.map +1 -0
- package/dist/features/developer-tools/components/ShareApiReference.vue.script.js +26 -0
- package/dist/features/developer-tools/components/ShareApiReference.vue.script.js.map +1 -0
- package/dist/features/developer-tools/index.d.ts +1 -1
- package/dist/features/example-responses/ExampleResponse.vue.js +9 -0
- package/dist/features/example-responses/ExampleResponse.vue.js.map +1 -0
- package/dist/features/example-responses/ExampleResponse.vue.script.js +56 -0
- package/dist/features/example-responses/ExampleResponse.vue.script.js.map +1 -0
- package/dist/features/example-responses/ExampleResponseTab.vue.js +9 -0
- package/dist/features/example-responses/ExampleResponseTab.vue.js.map +1 -0
- package/dist/features/example-responses/ExampleResponseTab.vue.script.js +21 -0
- package/dist/features/example-responses/ExampleResponseTab.vue.script.js.map +1 -0
- package/dist/features/example-responses/ExampleResponseTabList.vue.js +9 -0
- package/dist/features/example-responses/ExampleResponseTabList.vue.js.map +1 -0
- package/dist/features/example-responses/ExampleResponseTabList.vue.script.js +31 -0
- package/dist/features/example-responses/ExampleResponseTabList.vue.script.js.map +1 -0
- package/dist/features/example-responses/ExampleResponses.vue.js +9 -0
- package/dist/features/example-responses/ExampleResponses.vue.js.map +1 -0
- package/dist/features/example-responses/ExampleResponses.vue.script.js +157 -0
- package/dist/features/example-responses/ExampleResponses.vue.script.js.map +1 -0
- package/dist/features/example-responses/ExampleSchema.vue.js +7 -0
- package/dist/features/example-responses/ExampleSchema.vue.js.map +1 -0
- package/dist/features/example-responses/ExampleSchema.vue.script.js +42 -0
- package/dist/features/example-responses/ExampleSchema.vue.script.js.map +1 -0
- package/dist/features/example-responses/has-response-content.js +37 -0
- package/dist/features/example-responses/has-response-content.js.map +1 -0
- package/dist/features/example-responses/index.d.ts +1 -1
- package/dist/features/external-docs/ExternalDocs.vue.js +7 -0
- package/dist/features/external-docs/ExternalDocs.vue.js.map +1 -0
- package/dist/features/external-docs/ExternalDocs.vue.script.js +37 -0
- package/dist/features/external-docs/ExternalDocs.vue.script.js.map +1 -0
- package/dist/features/external-docs/index.d.ts +1 -1
- package/dist/features/index.d.ts +2 -2
- package/dist/features/index.js +4 -3
- package/dist/features/info-object/Contact.vue.js +7 -0
- package/dist/features/info-object/Contact.vue.js.map +1 -0
- package/dist/features/info-object/Contact.vue.script.js +37 -0
- package/dist/features/info-object/Contact.vue.script.js.map +1 -0
- package/dist/features/info-object/License.vue.js +7 -0
- package/dist/features/info-object/License.vue.js.map +1 -0
- package/dist/features/info-object/License.vue.script.js +32 -0
- package/dist/features/info-object/License.vue.script.js.map +1 -0
- package/dist/features/info-object/TermsOfService.vue.js +7 -0
- package/dist/features/info-object/TermsOfService.vue.js.map +1 -0
- package/dist/features/info-object/TermsOfService.vue.script.js +29 -0
- package/dist/features/info-object/TermsOfService.vue.script.js.map +1 -0
- package/dist/features/info-object/index.d.ts +3 -3
- package/dist/features/multiple-documents/DocumentSelector.vue.js +7 -0
- package/dist/features/multiple-documents/DocumentSelector.vue.js.map +1 -0
- package/dist/features/multiple-documents/DocumentSelector.vue.script.js +48 -0
- package/dist/features/multiple-documents/DocumentSelector.vue.script.js.map +1 -0
- package/dist/features/specification-extension/SpecificationExtension.vue.js +7 -0
- package/dist/features/specification-extension/SpecificationExtension.vue.js.map +1 -0
- package/dist/features/specification-extension/SpecificationExtension.vue.script.js +56 -0
- package/dist/features/specification-extension/SpecificationExtension.vue.script.js.map +1 -0
- package/dist/features/specification-extension/helpers.js +15 -0
- package/dist/features/specification-extension/helpers.js.map +1 -0
- package/dist/features/specification-extension/index.d.ts +2 -2
- package/dist/features/test-request-button/TestRequestButton.vue.js +9 -0
- package/dist/features/test-request-button/TestRequestButton.vue.js.map +1 -0
- package/dist/features/test-request-button/TestRequestButton.vue.script.js +47 -0
- package/dist/features/test-request-button/TestRequestButton.vue.script.js.map +1 -0
- package/dist/features/test-request-button/index.d.ts +1 -1
- package/dist/features/x-badges/XBadges.vue.js +7 -0
- package/dist/features/x-badges/XBadges.vue.js.map +1 -0
- package/dist/features/x-badges/XBadges.vue.script.js +31 -0
- package/dist/features/x-badges/XBadges.vue.script.js.map +1 -0
- package/dist/features/x-badges/index.d.ts +1 -1
- package/dist/helpers/color-mode.js +15 -0
- package/dist/helpers/color-mode.js.map +1 -0
- package/dist/helpers/download.js +77 -0
- package/dist/helpers/download.js.map +1 -0
- package/dist/helpers/id-routing.js +107 -0
- package/dist/helpers/id-routing.js.map +1 -0
- package/dist/helpers/index.d.ts +8 -8
- package/dist/helpers/index.js +8 -2
- package/dist/{lazy-bus-CV8Ox5hD.js → helpers/lazy-bus.js} +3 -106
- package/dist/helpers/lazy-bus.js.map +1 -0
- package/dist/helpers/load-from-perssistance.js +23 -0
- package/dist/helpers/load-from-perssistance.js.map +1 -0
- package/dist/helpers/map-config-plugins.js +44 -0
- package/dist/helpers/map-config-plugins.js.map +1 -0
- package/dist/helpers/map-config-to-workspace-store.js +24 -0
- package/dist/helpers/map-config-to-workspace-store.js.map +1 -0
- package/dist/helpers/normalize-configurations.js +66 -0
- package/dist/helpers/normalize-configurations.js.map +1 -0
- package/dist/helpers/openapi.js +132 -0
- package/dist/helpers/openapi.js.map +1 -0
- package/dist/{storage--3JuzjCI.js → helpers/storage.js} +2 -2
- package/dist/helpers/storage.js.map +1 -0
- package/dist/helpers/upload-temp-document.js +24 -0
- package/dist/helpers/upload-temp-document.js.map +1 -0
- package/dist/hooks/index.d.ts +2 -2
- package/dist/hooks/index.js +2 -2
- package/dist/{use-agent-Bnm1de0n.js → hooks/use-agent.js} +2 -2
- package/dist/hooks/use-agent.js.map +1 -0
- package/dist/{use-intersection-8QqPi2O-.js → hooks/use-intersection.js} +2 -2
- package/dist/hooks/use-intersection.js.map +1 -0
- package/dist/index.d.ts +5 -5
- package/dist/index.js +6 -6
- package/dist/plugins/hooks/usePluginManager.d.ts +1 -1
- package/dist/plugins/hooks/usePluginManager.js +16 -0
- package/dist/plugins/hooks/usePluginManager.js.map +1 -0
- package/dist/plugins/index.d.ts +3 -3
- package/dist/plugins/index.js +3 -1
- package/dist/plugins/persistance-plugin.js +39 -0
- package/dist/plugins/persistance-plugin.js.map +1 -0
- package/dist/plugins/plugin-manager.js +32 -0
- package/dist/plugins/plugin-manager.js.map +1 -0
- package/dist/ssr.d.ts +2 -2
- package/dist/ssr.js +6 -6
- package/dist/standalone/lib/html-api.js +73 -0
- package/dist/standalone/lib/html-api.js.map +1 -0
- package/dist/style.css +7878 -6432
- package/package.json +12 -12
- package/dist/AgentScalarChatInterface-MUbtSqMw.js.map +0 -1
- package/dist/ExternalDocs-phu7GxpZ.js +0 -272
- package/dist/ExternalDocs-phu7GxpZ.js.map +0 -1
- package/dist/MobileHeader-DAm6yQX0.js +0 -1373
- package/dist/MobileHeader-DAm6yQX0.js.map +0 -1
- package/dist/Operation-CvpVIkc3.js +0 -3829
- package/dist/Operation-CvpVIkc3.js.map +0 -1
- package/dist/SearchButton-xzhIpMCZ.js +0 -621
- package/dist/SearchButton-xzhIpMCZ.js.map +0 -1
- package/dist/ServerSelector-5y29y2BJ.js +0 -852
- package/dist/ServerSelector-5y29y2BJ.js.map +0 -1
- package/dist/components/index.js.map +0 -1
- package/dist/lazy-bus-CV8Ox5hD.js.map +0 -1
- package/dist/normalize-configurations-DcVpOEjD.js +0 -232
- package/dist/normalize-configurations-DcVpOEjD.js.map +0 -1
- package/dist/plugins-4EyiUD_A.js +0 -80
- package/dist/plugins-4EyiUD_A.js.map +0 -1
- package/dist/src-DJwsRvMU.js +0 -1686
- package/dist/src-DJwsRvMU.js.map +0 -1
- package/dist/storage--3JuzjCI.js.map +0 -1
- package/dist/urls-gPTXGgbj.js.map +0 -1
- package/dist/use-agent-Bnm1de0n.js.map +0 -1
- package/dist/use-intersection-8QqPi2O-.js.map +0 -1
|
@@ -0,0 +1,243 @@
|
|
|
1
|
+
import Badge_default from "../../../components/Badge/Badge.vue.js";
|
|
2
|
+
import Section_default from "../../../components/Section/Section.vue.js";
|
|
3
|
+
import SectionColumn_default from "../../../components/Section/SectionColumn.vue.js";
|
|
4
|
+
import SectionColumns_default from "../../../components/Section/SectionColumns.vue.js";
|
|
5
|
+
import SectionContent_default from "../../../components/Section/SectionContent.vue.js";
|
|
6
|
+
import SectionHeader_default from "../../../components/Section/SectionHeader.vue.js";
|
|
7
|
+
import SectionHeaderTag_default from "../../../components/Section/SectionHeaderTag.vue.js";
|
|
8
|
+
import Anchor_default from "../../../components/Anchor/Anchor.vue.js";
|
|
9
|
+
import { getXKeysFromObject } from "../../specification-extension/helpers.js";
|
|
10
|
+
import SpecificationExtension_default from "../../specification-extension/SpecificationExtension.vue.js";
|
|
11
|
+
import LinkList_default from "../../../components/LinkList/LinkList.vue.js";
|
|
12
|
+
import ExternalDocs_default from "../../external-docs/ExternalDocs.vue.js";
|
|
13
|
+
import OperationPath_default from "../../../components/OperationPath.vue.js";
|
|
14
|
+
import ExampleResponses_default from "../../example-responses/ExampleResponses.vue.js";
|
|
15
|
+
import OperationParameters_default from "../components/OperationParameters.vue.js";
|
|
16
|
+
import OperationResponses_default from "../components/OperationResponses.vue.js";
|
|
17
|
+
import Callbacks_default from "../components/callbacks/Callbacks.vue.js";
|
|
18
|
+
import TestRequestButton_default from "../../test-request-button/TestRequestButton.vue.js";
|
|
19
|
+
import XBadges_default from "../../x-badges/XBadges.vue.js";
|
|
20
|
+
import AskAgentButton_default from "../../ask-agent-button/AskAgentButton.vue.js";
|
|
21
|
+
import { computed, createBlock, createCommentVNode, createElementVNode, createSlots, createTextVNode, createVNode, defineComponent, normalizeClass, openBlock, toDisplayString, unref, useId, withCtx } from "vue";
|
|
22
|
+
import { ScalarErrorBoundary, ScalarMarkdown } from "@scalar/components";
|
|
23
|
+
import { ScalarIconWebhooksLogo } from "@scalar/icons";
|
|
24
|
+
import { getOperationStability, getOperationStabilityColor, isOperationDeprecated } from "@scalar/oas-utils/helpers";
|
|
25
|
+
import { OperationCodeSample } from "@scalar/api-client/v2/blocks/operation-code-sample";
|
|
26
|
+
import { getResolvedRef } from "@scalar/workspace-store/helpers/get-resolved-ref";
|
|
27
|
+
//#region src/features/Operation/layouts/ModernLayout.vue?vue&type=script&setup=true&lang.ts
|
|
28
|
+
var _hoisted_1 = { class: "flex flex-row justify-between gap-1" };
|
|
29
|
+
var _hoisted_2 = { class: "flex gap-1" };
|
|
30
|
+
var _hoisted_3 = { class: "flex gap-1" };
|
|
31
|
+
var _hoisted_4 = { class: "operation-details" };
|
|
32
|
+
var _hoisted_5 = { class: "examples" };
|
|
33
|
+
var _hoisted_6 = { class: "flex" };
|
|
34
|
+
var ModernLayout_vue_vue_type_script_setup_true_lang_default = /* @__PURE__ */ defineComponent({
|
|
35
|
+
__name: "ModernLayout",
|
|
36
|
+
props: {
|
|
37
|
+
id: {},
|
|
38
|
+
method: {},
|
|
39
|
+
options: {},
|
|
40
|
+
path: {},
|
|
41
|
+
clientOptions: {},
|
|
42
|
+
isWebhook: { type: Boolean },
|
|
43
|
+
selectedClient: {},
|
|
44
|
+
eventBus: {},
|
|
45
|
+
operation: {},
|
|
46
|
+
selectedServer: {},
|
|
47
|
+
selectedSecuritySchemes: {}
|
|
48
|
+
},
|
|
49
|
+
setup(__props) {
|
|
50
|
+
const operationTitle = computed(() => __props.operation.summary || __props.path || "");
|
|
51
|
+
const labelId = useId();
|
|
52
|
+
const operationExtensions = computed(() => getXKeysFromObject(__props.operation));
|
|
53
|
+
return (_ctx, _cache) => {
|
|
54
|
+
return openBlock(), createBlock(unref(Section_default), {
|
|
55
|
+
id: __props.id,
|
|
56
|
+
"aria-labelledby": unref(labelId),
|
|
57
|
+
label: operationTitle.value,
|
|
58
|
+
tabindex: "-1",
|
|
59
|
+
onIntersecting: _cache[1] || (_cache[1] = () => __props.eventBus?.emit("intersecting:nav-item", { id: __props.id }))
|
|
60
|
+
}, {
|
|
61
|
+
default: withCtx(() => [createVNode(unref(SectionContent_default), null, {
|
|
62
|
+
default: withCtx(() => [
|
|
63
|
+
createElementVNode("div", _hoisted_1, [createElementVNode("div", _hoisted_2, [
|
|
64
|
+
__props.options?.showOperationId && __props.operation.operationId ? (openBlock(), createBlock(unref(Badge_default), { key: 0 }, {
|
|
65
|
+
default: withCtx(() => [createTextVNode(toDisplayString(__props.operation.operationId), 1)]),
|
|
66
|
+
_: 1
|
|
67
|
+
})) : createCommentVNode("", true),
|
|
68
|
+
unref(getOperationStability)(__props.operation) ? (openBlock(), createBlock(unref(Badge_default), {
|
|
69
|
+
key: 1,
|
|
70
|
+
class: normalizeClass(["capitalize", unref(getOperationStabilityColor)(__props.operation)])
|
|
71
|
+
}, {
|
|
72
|
+
default: withCtx(() => [createTextVNode(toDisplayString(unref(getOperationStability)(__props.operation)), 1)]),
|
|
73
|
+
_: 1
|
|
74
|
+
}, 8, ["class"])) : createCommentVNode("", true),
|
|
75
|
+
__props.isWebhook ? (openBlock(), createBlock(unref(Badge_default), {
|
|
76
|
+
key: 2,
|
|
77
|
+
class: "font-code text-green flex w-fit items-center justify-center gap-1"
|
|
78
|
+
}, {
|
|
79
|
+
default: withCtx(() => [createVNode(unref(ScalarIconWebhooksLogo), { weight: "bold" }), _cache[2] || (_cache[2] = createTextVNode("Webhook ", -1))]),
|
|
80
|
+
_: 1
|
|
81
|
+
})) : createCommentVNode("", true),
|
|
82
|
+
createVNode(unref(XBadges_default), {
|
|
83
|
+
badges: __props.operation["x-badges"],
|
|
84
|
+
position: "before"
|
|
85
|
+
}, null, 8, ["badges"])
|
|
86
|
+
]), createElementVNode("div", _hoisted_3, [createVNode(unref(XBadges_default), {
|
|
87
|
+
badges: __props.operation["x-badges"],
|
|
88
|
+
position: "after"
|
|
89
|
+
}, null, 8, ["badges"])])]),
|
|
90
|
+
createElementVNode("div", { class: normalizeClass(unref(isOperationDeprecated)(__props.operation) ? "deprecated" : "") }, [createVNode(unref(SectionHeader_default), null, {
|
|
91
|
+
default: withCtx(() => [createVNode(unref(Anchor_default), { onCopyAnchorUrl: _cache[0] || (_cache[0] = () => __props.eventBus?.emit("copy-url:nav-item", { id: __props.id })) }, {
|
|
92
|
+
default: withCtx(() => [createVNode(unref(SectionHeaderTag_default), {
|
|
93
|
+
id: unref(labelId),
|
|
94
|
+
level: 3
|
|
95
|
+
}, {
|
|
96
|
+
default: withCtx(() => [createTextVNode(toDisplayString(operationTitle.value), 1)]),
|
|
97
|
+
_: 1
|
|
98
|
+
}, 8, ["id"])]),
|
|
99
|
+
_: 1
|
|
100
|
+
})]),
|
|
101
|
+
_: 1
|
|
102
|
+
})], 2),
|
|
103
|
+
createVNode(unref(SectionColumns_default), null, {
|
|
104
|
+
default: withCtx(() => [createVNode(unref(SectionColumn_default), null, {
|
|
105
|
+
default: withCtx(() => [createElementVNode("div", _hoisted_4, [
|
|
106
|
+
createVNode(SpecificationExtension_default, { value: operationExtensions.value }, null, 8, ["value"]),
|
|
107
|
+
createVNode(unref(ScalarMarkdown), {
|
|
108
|
+
anchorPrefix: __props.id,
|
|
109
|
+
"aria-label": "Operation Description",
|
|
110
|
+
role: "group",
|
|
111
|
+
transformType: "heading",
|
|
112
|
+
value: __props.operation.description,
|
|
113
|
+
withAnchors: "",
|
|
114
|
+
withImages: ""
|
|
115
|
+
}, null, 8, ["anchorPrefix", "value"]),
|
|
116
|
+
createVNode(OperationParameters_default, {
|
|
117
|
+
breadcrumb: [__props.id],
|
|
118
|
+
eventBus: __props.eventBus,
|
|
119
|
+
options: __props.options,
|
|
120
|
+
parameters: __props.operation.parameters,
|
|
121
|
+
requestBody: unref(getResolvedRef)(__props.operation.requestBody)
|
|
122
|
+
}, null, 8, [
|
|
123
|
+
"breadcrumb",
|
|
124
|
+
"eventBus",
|
|
125
|
+
"options",
|
|
126
|
+
"parameters",
|
|
127
|
+
"requestBody"
|
|
128
|
+
]),
|
|
129
|
+
createVNode(OperationResponses_default, {
|
|
130
|
+
breadcrumb: [__props.id],
|
|
131
|
+
collapsableItems: !__props.options.expandAllResponses,
|
|
132
|
+
eventBus: __props.eventBus,
|
|
133
|
+
options: __props.options,
|
|
134
|
+
responses: __props.operation.responses
|
|
135
|
+
}, null, 8, [
|
|
136
|
+
"breadcrumb",
|
|
137
|
+
"collapsableItems",
|
|
138
|
+
"eventBus",
|
|
139
|
+
"options",
|
|
140
|
+
"responses"
|
|
141
|
+
]),
|
|
142
|
+
createVNode(unref(ScalarErrorBoundary), null, {
|
|
143
|
+
default: withCtx(() => [__props.operation.callbacks ? (openBlock(), createBlock(Callbacks_default, {
|
|
144
|
+
key: 0,
|
|
145
|
+
callbacks: __props.operation.callbacks,
|
|
146
|
+
class: "mt-6",
|
|
147
|
+
eventBus: __props.eventBus,
|
|
148
|
+
options: __props.options,
|
|
149
|
+
path: __props.path
|
|
150
|
+
}, null, 8, [
|
|
151
|
+
"callbacks",
|
|
152
|
+
"eventBus",
|
|
153
|
+
"options",
|
|
154
|
+
"path"
|
|
155
|
+
])) : createCommentVNode("", true)]),
|
|
156
|
+
_: 1
|
|
157
|
+
})
|
|
158
|
+
])]),
|
|
159
|
+
_: 1
|
|
160
|
+
}), createVNode(unref(SectionColumn_default), null, {
|
|
161
|
+
default: withCtx(() => [createElementVNode("div", _hoisted_5, [
|
|
162
|
+
__props.operation.externalDocs ? (openBlock(), createBlock(unref(LinkList_default), { key: 0 }, {
|
|
163
|
+
default: withCtx(() => [createVNode(unref(ExternalDocs_default), { value: __props.operation.externalDocs }, null, 8, ["value"])]),
|
|
164
|
+
_: 1
|
|
165
|
+
})) : createCommentVNode("", true),
|
|
166
|
+
createVNode(unref(ScalarErrorBoundary), null, {
|
|
167
|
+
default: withCtx(() => [createVNode(unref(OperationCodeSample), {
|
|
168
|
+
clientOptions: __props.clientOptions,
|
|
169
|
+
eventBus: __props.eventBus,
|
|
170
|
+
fallback: "",
|
|
171
|
+
isWebhook: __props.isWebhook,
|
|
172
|
+
method: __props.method,
|
|
173
|
+
operation: __props.operation,
|
|
174
|
+
path: __props.path,
|
|
175
|
+
securitySchemes: __props.selectedSecuritySchemes,
|
|
176
|
+
selectedClient: __props.selectedClient,
|
|
177
|
+
selectedServer: __props.selectedServer
|
|
178
|
+
}, createSlots({
|
|
179
|
+
header: withCtx(() => [createVNode(OperationPath_default, {
|
|
180
|
+
class: "font-code text-c-2 [&_em]:text-c-1 [&_em]:not-italic",
|
|
181
|
+
deprecated: __props.operation?.deprecated,
|
|
182
|
+
path: __props.path
|
|
183
|
+
}, null, 8, ["deprecated", "path"])]),
|
|
184
|
+
_: 2
|
|
185
|
+
}, [!__props.isWebhook ? {
|
|
186
|
+
name: "footer",
|
|
187
|
+
fn: withCtx(({ exampleName }) => [createElementVNode("div", _hoisted_6, [createVNode(AskAgentButton_default), !__props.options.hideTestRequestButton ? (openBlock(), createBlock(unref(TestRequestButton_default), {
|
|
188
|
+
key: 0,
|
|
189
|
+
id: __props.id,
|
|
190
|
+
eventBus: __props.eventBus,
|
|
191
|
+
exampleName,
|
|
192
|
+
method: __props.method,
|
|
193
|
+
path: __props.path
|
|
194
|
+
}, null, 8, [
|
|
195
|
+
"id",
|
|
196
|
+
"eventBus",
|
|
197
|
+
"exampleName",
|
|
198
|
+
"method",
|
|
199
|
+
"path"
|
|
200
|
+
])) : createCommentVNode("", true)])]),
|
|
201
|
+
key: "0"
|
|
202
|
+
} : void 0]), 1032, [
|
|
203
|
+
"clientOptions",
|
|
204
|
+
"eventBus",
|
|
205
|
+
"isWebhook",
|
|
206
|
+
"method",
|
|
207
|
+
"operation",
|
|
208
|
+
"path",
|
|
209
|
+
"securitySchemes",
|
|
210
|
+
"selectedClient",
|
|
211
|
+
"selectedServer"
|
|
212
|
+
])]),
|
|
213
|
+
_: 1
|
|
214
|
+
}),
|
|
215
|
+
createVNode(unref(ScalarErrorBoundary), null, {
|
|
216
|
+
default: withCtx(() => [__props.operation.responses ? (openBlock(), createBlock(unref(ExampleResponses_default), {
|
|
217
|
+
key: 0,
|
|
218
|
+
responses: __props.operation.responses,
|
|
219
|
+
style: { "margin-top": "12px" }
|
|
220
|
+
}, null, 8, ["responses"])) : createCommentVNode("", true)]),
|
|
221
|
+
_: 1
|
|
222
|
+
})
|
|
223
|
+
])]),
|
|
224
|
+
_: 1
|
|
225
|
+
})]),
|
|
226
|
+
_: 1
|
|
227
|
+
})
|
|
228
|
+
]),
|
|
229
|
+
_: 1
|
|
230
|
+
})]),
|
|
231
|
+
_: 1
|
|
232
|
+
}, 8, [
|
|
233
|
+
"id",
|
|
234
|
+
"aria-labelledby",
|
|
235
|
+
"label"
|
|
236
|
+
]);
|
|
237
|
+
};
|
|
238
|
+
}
|
|
239
|
+
});
|
|
240
|
+
//#endregion
|
|
241
|
+
export { ModernLayout_vue_vue_type_script_setup_true_lang_default as default };
|
|
242
|
+
|
|
243
|
+
//# sourceMappingURL=ModernLayout.vue.script.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ModernLayout.vue.script.js","names":[],"sources":["../../../../src/features/Operation/layouts/ModernLayout.vue"],"sourcesContent":["<script setup lang=\"ts\">\nimport { OperationCodeSample } from '@scalar/api-client/v2/blocks/operation-code-sample'\nimport type { SecuritySchemeObjectSecret } from '@scalar/api-client/v2/blocks/scalar-auth-selector-block'\nimport { ScalarErrorBoundary, ScalarMarkdown } from '@scalar/components'\nimport { ScalarIconWebhooksLogo } from '@scalar/icons'\nimport {\n getOperationStability,\n getOperationStabilityColor,\n isOperationDeprecated,\n} from '@scalar/oas-utils/helpers'\nimport { getResolvedRef } from '@scalar/workspace-store/helpers/get-resolved-ref'\nimport type {\n OperationObject,\n ServerObject,\n} from '@scalar/workspace-store/schemas/v3.1/strict/openapi-document'\nimport { computed, useId } from 'vue'\n\nimport { Anchor } from '@/components/Anchor'\nimport { Badge } from '@/components/Badge'\nimport { LinkList } from '@/components/LinkList'\nimport OperationPath from '@/components/OperationPath.vue'\nimport {\n Section,\n SectionColumn,\n SectionColumns,\n SectionContent,\n SectionHeader,\n SectionHeaderTag,\n} from '@/components/Section'\nimport AskAgentButton from '@/features/ask-agent-button/AskAgentButton.vue'\nimport { ExampleResponses } from '@/features/example-responses'\nimport { ExternalDocs } from '@/features/external-docs'\nimport Callbacks from '@/features/Operation/components/callbacks/Callbacks.vue'\nimport OperationParameters from '@/features/Operation/components/OperationParameters.vue'\nimport OperationResponses from '@/features/Operation/components/OperationResponses.vue'\nimport type { OperationProps } from '@/features/Operation/Operation.vue'\nimport { getXKeysFromObject } from '@/features/specification-extension'\nimport SpecificationExtension from '@/features/specification-extension/SpecificationExtension.vue'\nimport { TestRequestButton } from '@/features/test-request-button'\nimport { XBadges } from '@/features/x-badges'\n\nconst {\n clientOptions,\n eventBus,\n isWebhook,\n method,\n operation,\n options,\n path,\n selectedServer,\n selectedSecuritySchemes,\n selectedClient,\n} = defineProps<\n Omit<\n OperationProps,\n | 'document'\n | 'pathValue'\n | 'server'\n | 'isCollapsed'\n | 'securitySchemes'\n | 'authStore'\n > & {\n /** Operation object with path params */\n operation: OperationObject\n /** The selected server for the operation */\n selectedServer: ServerObject | null\n /** The selected security schemes for the operation */\n selectedSecuritySchemes: SecuritySchemeObjectSecret[]\n }\n>()\n\nconst operationTitle = computed(() => operation.summary || path || '')\n\nconst labelId = useId()\n\nconst operationExtensions = computed(() => getXKeysFromObject(operation))\n</script>\n\n<template>\n <Section\n :id=\"id\"\n :aria-labelledby=\"labelId\"\n :label=\"operationTitle\"\n tabindex=\"-1\"\n @intersecting=\"() => eventBus?.emit('intersecting:nav-item', { id })\">\n <SectionContent>\n <div class=\"flex flex-row justify-between gap-1\">\n <!-- Left -->\n <div class=\"flex gap-1\">\n <!-- Operation ID -->\n <Badge v-if=\"options?.showOperationId && operation.operationId\">\n {{ operation.operationId }}\n </Badge>\n <!-- Stability badge -->\n <Badge\n v-if=\"getOperationStability(operation)\"\n class=\"capitalize\"\n :class=\"getOperationStabilityColor(operation)\">\n {{ getOperationStability(operation) }}\n </Badge>\n <!-- Webhook badge -->\n <Badge\n v-if=\"isWebhook\"\n class=\"font-code text-green flex w-fit items-center justify-center gap-1\">\n <ScalarIconWebhooksLogo weight=\"bold\" />Webhook\n </Badge>\n <!-- x-badges before -->\n <XBadges\n :badges=\"operation['x-badges']\"\n position=\"before\" />\n </div>\n <!-- Right -->\n <div class=\"flex gap-1\">\n <!-- x-badges after -->\n <XBadges\n :badges=\"operation['x-badges']\"\n position=\"after\" />\n </div>\n </div>\n <div :class=\"isOperationDeprecated(operation) ? 'deprecated' : ''\">\n <SectionHeader>\n <Anchor\n @copyAnchorUrl=\"() => eventBus?.emit('copy-url:nav-item', { id })\">\n <SectionHeaderTag\n :id=\"labelId\"\n :level=\"3\">\n {{ operationTitle }}\n </SectionHeaderTag>\n </Anchor>\n </SectionHeader>\n </div>\n <SectionColumns>\n <SectionColumn>\n <div class=\"operation-details\">\n <SpecificationExtension :value=\"operationExtensions\" />\n <ScalarMarkdown\n :anchorPrefix=\"id\"\n aria-label=\"Operation Description\"\n role=\"group\"\n transformType=\"heading\"\n :value=\"operation.description\"\n withAnchors\n withImages />\n <OperationParameters\n :breadcrumb=\"[id]\"\n :eventBus\n :options\n :parameters=\"operation.parameters\"\n :requestBody=\"getResolvedRef(operation.requestBody)\" />\n <OperationResponses\n :breadcrumb=\"[id]\"\n :collapsableItems=\"!options.expandAllResponses\"\n :eventBus\n :options\n :responses=\"operation.responses\" />\n\n <!-- Callbacks -->\n <ScalarErrorBoundary>\n <Callbacks\n v-if=\"operation.callbacks\"\n :callbacks=\"operation.callbacks\"\n class=\"mt-6\"\n :eventBus\n :options\n :path />\n </ScalarErrorBoundary>\n </div>\n </SectionColumn>\n <SectionColumn>\n <div class=\"examples\">\n <!-- External Docs -->\n <LinkList v-if=\"operation.externalDocs\">\n <ExternalDocs :value=\"operation.externalDocs\" />\n </LinkList>\n\n <!-- New Example Request -->\n <ScalarErrorBoundary>\n <OperationCodeSample\n :clientOptions\n :eventBus\n fallback\n :isWebhook\n :method\n :operation\n :path\n :securitySchemes=\"selectedSecuritySchemes\"\n :selectedClient\n :selectedServer>\n <template #header>\n <OperationPath\n class=\"font-code text-c-2 [&_em]:text-c-1 [&_em]:not-italic\"\n :deprecated=\"operation?.deprecated\"\n :path=\"path\" />\n </template>\n <template\n v-if=\"!isWebhook\"\n #footer=\"{ exampleName }\">\n <div class=\"flex\">\n <AskAgentButton />\n <TestRequestButton\n v-if=\"!options.hideTestRequestButton\"\n :id\n :eventBus\n :exampleName\n :method\n :path />\n </div>\n </template>\n </OperationCodeSample>\n </ScalarErrorBoundary>\n\n <ScalarErrorBoundary>\n <ExampleResponses\n v-if=\"operation.responses\"\n :responses=\"operation.responses\"\n style=\"margin-top: 12px\" />\n </ScalarErrorBoundary>\n </div>\n </SectionColumn>\n </SectionColumns>\n </SectionContent>\n </Section>\n</template>\n\n<style scoped>\n.examples {\n position: sticky;\n top: calc(var(--refs-viewport-offset) + 24px);\n}\n\n.examples > * {\n max-height: calc((var(--refs-viewport-height) - 60px) / 2);\n position: relative;\n}\n\n.examples > *:first-of-type:last-of-type {\n max-height: calc((var(--refs-viewport-height) - 60px));\n}\n\n/*\n * Don't constrain card height on mobile\n * (or zoomed in screens)\n */\n@media (max-width: 600px) {\n .examples > * {\n max-height: unset;\n }\n}\n.deprecated * {\n text-decoration: line-through;\n}\n</style>\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAuEA,MAAM,iBAAiB,eAAe,QAAA,UAAU,WAAW,QAAA,QAAQ,GAAE;EAErE,MAAM,UAAU,OAAM;EAEtB,MAAM,sBAAsB,eAAe,mBAAmB,QAAA,UAAU,CAAA;;uBAItE,YA8IU,MAAA,gBAAA,EAAA;IA7IP,IAAI,QAAA;IACJ,mBAAiB,MAAA,QAAO;IACxB,OAAO,eAAA;IACR,UAAS;IACR,gBAAY,OAAA,OAAA,OAAA,WAAQ,QAAA,UAAU,KAAI,yBAAA,EAAA,IAA4B,QAAA,IAAE,CAAA;;2BAwIhD,CAvIjB,YAuIiB,MAAA,uBAAA,EAAA,MAAA;4BAtGT;MAhCN,mBAgCM,OAhCN,YAgCM,CA9BJ,mBAsBM,OAtBN,YAsBM;OApBS,QAAA,SAAS,mBAAmB,QAAA,UAAU,eAAA,WAAA,EAAnD,YAEQ,MAAA,cAAA,EAAA,EAAA,KAAA,GAAA,EAAA;+BADqB,CAAA,gBAAA,gBAAxB,QAAA,UAAU,YAAW,EAAA,EAAA,CAAA,CAAA;;;OAIlB,MAAA,sBAAqB,CAAC,QAAA,UAAS,IAAA,WAAA,EADvC,YAKQ,MAAA,cAAA,EAAA;;QAHN,OAAK,eAAA,CAAC,cACE,MAAA,2BAA0B,CAAC,QAAA,UAAS,CAAA,CAAA;;+BACN,CAAA,gBAAA,gBAAnC,MAAA,sBAAqB,CAAC,QAAA,UAAS,CAAA,EAAA,EAAA,CAAA,CAAA;;;OAI5B,QAAA,aAAA,WAAA,EADR,YAIQ,MAAA,cAAA,EAAA;;QAFN,OAAM;;+BACkC,CAAxC,YAAwC,MAAA,uBAAA,EAAA,EAAhB,QAAO,QAAM,CAAA,EAAA,OAAA,OAAA,OAAA,KAAA,gBAAG,YAC1C,GAAA,EAAA,CAAA;;;OAEA,YAEsB,MAAA,gBAAA,EAAA;QADnB,QAAQ,QAAA,UAAS;QAClB,UAAS;;UAGb,mBAKM,OALN,YAKM,CAHJ,YAEqB,MAAA,gBAAA,EAAA;OADlB,QAAQ,QAAA,UAAS;OAClB,UAAS;;MAGf,mBAWM,OAAA,EAXA,OAAK,eAAE,MAAA,sBAAqB,CAAC,QAAA,UAAS,GAAA,eAAA,GAAA,EAAA,EAAA,CAC1C,YASgB,MAAA,sBAAA,EAAA,MAAA;8BADL,CAPT,YAOS,MAAA,eAAA,EAAA,EANN,iBAAa,OAAA,OAAA,OAAA,WAAQ,QAAA,UAAU,KAAI,qBAAA,EAAA,IAAwB,QAAA,IAAE,CAAA,GAAA,EAAA;+BAK3C,CAJnB,YAImB,MAAA,yBAAA,EAAA;SAHhB,IAAI,MAAA,QAAO;SACX,OAAO;;gCACY,CAAA,gBAAA,gBAAjB,eAAA,MAAc,EAAA,EAAA,CAAA,CAAA;;;;;;;MAKzB,YAwFiB,MAAA,uBAAA,EAAA,MAAA;8BApDC,CAnChB,YAmCgB,MAAA,sBAAA,EAAA,MAAA;+BADR,CAjCN,mBAiCM,OAjCN,YAiCM;SAhCJ,YAAuD,gCAAA,EAA9B,OAAO,oBAAA,OAAmB,EAAA,MAAA,GAAA,CAAA,QAAA,CAAA;SACnD,YAOe,MAAA,eAAA,EAAA;UANZ,cAAc,QAAA;UACf,cAAW;UACX,MAAK;UACL,eAAc;UACb,OAAO,QAAA,UAAU;UAClB,aAAA;UACA,YAAA;;SACF,YAKyD,6BAAA;UAJtD,YAAU,CAAG,QAAA,GAAE;UACf,UAAA,QAAA;UACA,SAAA,QAAA;UACA,YAAY,QAAA,UAAU;UACtB,aAAa,MAAA,eAAc,CAAC,QAAA,UAAU,YAAW;;;;;;;;SACpD,YAKqC,4BAAA;UAJlC,YAAU,CAAG,QAAA,GAAE;UACf,kBAAgB,CAAG,QAAA,QAAQ;UAC3B,UAAA,QAAA;UACA,SAAA,QAAA;UACA,WAAW,QAAA,UAAU;;;;;;;;SAGxB,YAQsB,MAAA,oBAAA,EAAA,MAAA;kCANZ,QAAA,UAAU,aAAA,WAAA,EADlB,YAMU,mBAAA;;WAJP,WAAW,QAAA,UAAU;WACtB,OAAM;WACL,UAAA,QAAA;WACA,SAAA,QAAA;WACA,MAAA,QAAA;;;;;;;;;;;WAIT,YAkDgB,MAAA,sBAAA,EAAA,MAAA;+BADR,CAhDN,mBAgDM,OAhDN,YAgDM;SA9CY,QAAA,UAAU,gBAAA,WAAA,EAA1B,YAEW,MAAA,iBAAA,EAAA,EAAA,KAAA,GAAA,EAAA;iCADuC,CAAhD,YAAgD,MAAA,qBAAA,EAAA,EAAjC,OAAO,QAAA,UAAU,cAAA,EAAA,MAAA,GAAA,CAAA,QAAA,CAAA,CAAA,CAAA;;;SAIlC,YAiCsB,MAAA,oBAAA,EAAA,MAAA;iCADE,CA/BtB,YA+BsB,MAAA,oBAAA,EAAA;WA9BnB,eAAA,QAAA;WACA,UAAA,QAAA;WACD,UAAA;WACC,WAAA,QAAA;WACA,QAAA,QAAA;WACA,WAAA,QAAA;WACA,MAAA,QAAA;WACA,iBAAiB,QAAA;WACjB,gBAAA,QAAA;WACA,gBAAA,QAAA;;WACU,QAAM,cAIE,CAHjB,YAGiB,uBAAA;YAFf,OAAM;YACL,YAAY,QAAA,WAAW;YACvB,MAAM,QAAA;;;eAGF,QAAA,YAAA;iBACN;wBAUK,EAVK,kBAAW,CACtB,mBASM,OATN,YASM,CARJ,YAAkB,uBAAA,EAAA,CAET,QAAA,QAAQ,yBAAA,WAAA,EADjB,YAMU,MAAA,0BAAA,EAAA;;YAJP,IAAA,QAAA;YACA,UAAA,QAAA;YACA;YACA,QAAA,QAAA;YACA,MAAA,QAAA;;;;;;;;;;;;;;;;;;;;;;SAMX,YAKsB,MAAA,oBAAA,EAAA,MAAA;kCAHZ,QAAA,UAAU,aAAA,WAAA,EADlB,YAG6B,MAAA,yBAAA,EAAA;;WAD1B,WAAW,QAAA,UAAU;WACtB,OAAA,EAAA,cAAA,QAAwB"}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import SearchButton_vue_vue_type_script_setup_true_lang_default from "./SearchButton.vue.script.js";
|
|
2
|
+
//#region src/features/Search/components/SearchButton.vue
|
|
3
|
+
var SearchButton_default = SearchButton_vue_vue_type_script_setup_true_lang_default;
|
|
4
|
+
//#endregion
|
|
5
|
+
export { SearchButton_default as default };
|
|
6
|
+
|
|
7
|
+
//# sourceMappingURL=SearchButton.vue.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SearchButton.vue.js","names":[],"sources":["../../../../src/features/Search/components/SearchButton.vue"],"sourcesContent":["<script setup lang=\"ts\">\nimport {\n ScalarIconButton,\n ScalarSidebarSearchButton,\n useModal,\n} from '@scalar/components'\nimport { isMacOS } from '@scalar/helpers/general/is-mac-os'\nimport { ScalarIconMagnifyingGlass } from '@scalar/icons'\nimport type { WorkspaceEventBus } from '@scalar/workspace-store/events'\nimport type { OpenApiDocument } from '@scalar/workspace-store/schemas/v3.1/strict/openapi-document'\nimport { nextTick, onBeforeUnmount, onMounted, ref, watch } from 'vue'\n\nimport SearchModal from './SearchModal.vue'\n\nconst { searchHotKey = 'k', hideModels = false } = defineProps<{\n forceIcon?: boolean\n searchHotKey?: string\n hideModels?: boolean\n document?: OpenApiDocument\n eventBus: WorkspaceEventBus\n}>()\n\nconst button = ref<InstanceType<typeof ScalarSidebarSearchButton>>()\nconst modalState = useModal()\n\nconst handleHotKey = (e: KeyboardEvent) => {\n if ((isMacOS() ? e.metaKey : e.ctrlKey) && e.key === searchHotKey) {\n e.preventDefault()\n e.stopPropagation()\n\n if (modalState.open) {\n modalState.hide()\n } else {\n modalState.show()\n }\n }\n}\n\nwatch(\n () => modalState.open,\n async (next, prev) => {\n // Return focus to the button when the modal is closed\n if (!next && prev) {\n await nextTick()\n button.value?.$el.focus()\n }\n },\n)\n\n// Handle keyboard shortcuts\n// TODO: we can move this to the hotkey event bus but we would need to set up a custom key from the searchHotKey config\n// and make sure it works correctly inside the references first\nonMounted(() => window.addEventListener('keydown', handleHotKey))\nonBeforeUnmount(() => window.removeEventListener('keydown', handleHotKey))\n\nfunction handleClick() {\n modalState.show()\n}\n</script>\n<template>\n <ScalarIconButton\n v-if=\"forceIcon\"\n :icon=\"ScalarIconMagnifyingGlass\"\n label=\"Search\"\n @click=\"handleClick\" />\n <ScalarSidebarSearchButton\n v-else\n ref=\"button\"\n class=\"w-full\"\n :class=\"$attrs.class\"\n @click=\"handleClick\">\n <span class=\"sr-only\">Open Search</span>\n <span\n aria-hidden=\"true\"\n class=\"sidebar-search-placeholder\">\n Search\n </span>\n <template #shortcut>\n <template v-if=\"isMacOS()\">\n <span class=\"sr-only\">Command</span>\n <span aria-hidden=\"true\">⌘</span>\n </template>\n <template v-else>\n <span class=\"sr-only\">CTRL</span>\n <span aria-hidden=\"true\">⌃</span>\n </template>\n {{ searchHotKey }}\n </template>\n </ScalarSidebarSearchButton>\n\n <SearchModal\n :document\n :eventBus=\"eventBus\"\n :hideModels=\"hideModels\"\n :modalState=\"modalState\" />\n</template>\n"],"mappings":""}
|
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
import SearchModal_default from "./SearchModal.vue.js";
|
|
2
|
+
import { Fragment, createBlock, createElementBlock, createElementVNode, createTextVNode, createVNode, defineComponent, nextTick, normalizeClass, onBeforeUnmount, onMounted, openBlock, ref, toDisplayString, unref, watch, withCtx } from "vue";
|
|
3
|
+
import { ScalarIconButton, ScalarSidebarSearchButton, useModal } from "@scalar/components";
|
|
4
|
+
import { ScalarIconMagnifyingGlass } from "@scalar/icons";
|
|
5
|
+
import { isMacOS } from "@scalar/helpers/general/is-mac-os";
|
|
6
|
+
//#region src/features/Search/components/SearchButton.vue?vue&type=script&setup=true&lang.ts
|
|
7
|
+
var SearchButton_vue_vue_type_script_setup_true_lang_default = /* @__PURE__ */ defineComponent({
|
|
8
|
+
__name: "SearchButton",
|
|
9
|
+
props: {
|
|
10
|
+
forceIcon: { type: Boolean },
|
|
11
|
+
searchHotKey: { default: "k" },
|
|
12
|
+
hideModels: {
|
|
13
|
+
type: Boolean,
|
|
14
|
+
default: false
|
|
15
|
+
},
|
|
16
|
+
document: {},
|
|
17
|
+
eventBus: {}
|
|
18
|
+
},
|
|
19
|
+
setup(__props) {
|
|
20
|
+
const button = ref();
|
|
21
|
+
const modalState = useModal();
|
|
22
|
+
const handleHotKey = (e) => {
|
|
23
|
+
if ((isMacOS() ? e.metaKey : e.ctrlKey) && e.key === __props.searchHotKey) {
|
|
24
|
+
e.preventDefault();
|
|
25
|
+
e.stopPropagation();
|
|
26
|
+
if (modalState.open) modalState.hide();
|
|
27
|
+
else modalState.show();
|
|
28
|
+
}
|
|
29
|
+
};
|
|
30
|
+
watch(() => modalState.open, async (next, prev) => {
|
|
31
|
+
if (!next && prev) {
|
|
32
|
+
await nextTick();
|
|
33
|
+
button.value?.$el.focus();
|
|
34
|
+
}
|
|
35
|
+
});
|
|
36
|
+
onMounted(() => window.addEventListener("keydown", handleHotKey));
|
|
37
|
+
onBeforeUnmount(() => window.removeEventListener("keydown", handleHotKey));
|
|
38
|
+
function handleClick() {
|
|
39
|
+
modalState.show();
|
|
40
|
+
}
|
|
41
|
+
return (_ctx, _cache) => {
|
|
42
|
+
return openBlock(), createElementBlock(Fragment, null, [__props.forceIcon ? (openBlock(), createBlock(unref(ScalarIconButton), {
|
|
43
|
+
key: 0,
|
|
44
|
+
icon: unref(ScalarIconMagnifyingGlass),
|
|
45
|
+
label: "Search",
|
|
46
|
+
onClick: handleClick
|
|
47
|
+
}, null, 8, ["icon"])) : (openBlock(), createBlock(unref(ScalarSidebarSearchButton), {
|
|
48
|
+
key: 1,
|
|
49
|
+
ref_key: "button",
|
|
50
|
+
ref: button,
|
|
51
|
+
class: normalizeClass(["w-full", _ctx.$attrs.class]),
|
|
52
|
+
onClick: handleClick
|
|
53
|
+
}, {
|
|
54
|
+
shortcut: withCtx(() => [unref(isMacOS)() ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [_cache[0] || (_cache[0] = createElementVNode("span", { class: "sr-only" }, "Command", -1)), _cache[1] || (_cache[1] = createElementVNode("span", { "aria-hidden": "true" }, "⌘", -1))], 64)) : (openBlock(), createElementBlock(Fragment, { key: 1 }, [_cache[2] || (_cache[2] = createElementVNode("span", { class: "sr-only" }, "CTRL", -1)), _cache[3] || (_cache[3] = createElementVNode("span", { "aria-hidden": "true" }, "⌃", -1))], 64)), createTextVNode(" " + toDisplayString(__props.searchHotKey), 1)]),
|
|
55
|
+
default: withCtx(() => [_cache[4] || (_cache[4] = createElementVNode("span", { class: "sr-only" }, "Open Search", -1)), _cache[5] || (_cache[5] = createElementVNode("span", {
|
|
56
|
+
"aria-hidden": "true",
|
|
57
|
+
class: "sidebar-search-placeholder"
|
|
58
|
+
}, " Search ", -1))]),
|
|
59
|
+
_: 1
|
|
60
|
+
}, 8, ["class"])), createVNode(SearchModal_default, {
|
|
61
|
+
document: __props.document,
|
|
62
|
+
eventBus: __props.eventBus,
|
|
63
|
+
hideModels: __props.hideModels,
|
|
64
|
+
modalState: unref(modalState)
|
|
65
|
+
}, null, 8, [
|
|
66
|
+
"document",
|
|
67
|
+
"eventBus",
|
|
68
|
+
"hideModels",
|
|
69
|
+
"modalState"
|
|
70
|
+
])], 64);
|
|
71
|
+
};
|
|
72
|
+
}
|
|
73
|
+
});
|
|
74
|
+
//#endregion
|
|
75
|
+
export { SearchButton_vue_vue_type_script_setup_true_lang_default as default };
|
|
76
|
+
|
|
77
|
+
//# sourceMappingURL=SearchButton.vue.script.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SearchButton.vue.script.js","names":["$attrs"],"sources":["../../../../src/features/Search/components/SearchButton.vue"],"sourcesContent":["<script setup lang=\"ts\">\nimport {\n ScalarIconButton,\n ScalarSidebarSearchButton,\n useModal,\n} from '@scalar/components'\nimport { isMacOS } from '@scalar/helpers/general/is-mac-os'\nimport { ScalarIconMagnifyingGlass } from '@scalar/icons'\nimport type { WorkspaceEventBus } from '@scalar/workspace-store/events'\nimport type { OpenApiDocument } from '@scalar/workspace-store/schemas/v3.1/strict/openapi-document'\nimport { nextTick, onBeforeUnmount, onMounted, ref, watch } from 'vue'\n\nimport SearchModal from './SearchModal.vue'\n\nconst { searchHotKey = 'k', hideModels = false } = defineProps<{\n forceIcon?: boolean\n searchHotKey?: string\n hideModels?: boolean\n document?: OpenApiDocument\n eventBus: WorkspaceEventBus\n}>()\n\nconst button = ref<InstanceType<typeof ScalarSidebarSearchButton>>()\nconst modalState = useModal()\n\nconst handleHotKey = (e: KeyboardEvent) => {\n if ((isMacOS() ? e.metaKey : e.ctrlKey) && e.key === searchHotKey) {\n e.preventDefault()\n e.stopPropagation()\n\n if (modalState.open) {\n modalState.hide()\n } else {\n modalState.show()\n }\n }\n}\n\nwatch(\n () => modalState.open,\n async (next, prev) => {\n // Return focus to the button when the modal is closed\n if (!next && prev) {\n await nextTick()\n button.value?.$el.focus()\n }\n },\n)\n\n// Handle keyboard shortcuts\n// TODO: we can move this to the hotkey event bus but we would need to set up a custom key from the searchHotKey config\n// and make sure it works correctly inside the references first\nonMounted(() => window.addEventListener('keydown', handleHotKey))\nonBeforeUnmount(() => window.removeEventListener('keydown', handleHotKey))\n\nfunction handleClick() {\n modalState.show()\n}\n</script>\n<template>\n <ScalarIconButton\n v-if=\"forceIcon\"\n :icon=\"ScalarIconMagnifyingGlass\"\n label=\"Search\"\n @click=\"handleClick\" />\n <ScalarSidebarSearchButton\n v-else\n ref=\"button\"\n class=\"w-full\"\n :class=\"$attrs.class\"\n @click=\"handleClick\">\n <span class=\"sr-only\">Open Search</span>\n <span\n aria-hidden=\"true\"\n class=\"sidebar-search-placeholder\">\n Search\n </span>\n <template #shortcut>\n <template v-if=\"isMacOS()\">\n <span class=\"sr-only\">Command</span>\n <span aria-hidden=\"true\">⌘</span>\n </template>\n <template v-else>\n <span class=\"sr-only\">CTRL</span>\n <span aria-hidden=\"true\">⌃</span>\n </template>\n {{ searchHotKey }}\n </template>\n </ScalarSidebarSearchButton>\n\n <SearchModal\n :document\n :eventBus=\"eventBus\"\n :hideModels=\"hideModels\"\n :modalState=\"modalState\" />\n</template>\n"],"mappings":";;;;;;;;;;;;;;;;;;;EAsBA,MAAM,SAAS,KAAoD;EACnE,MAAM,aAAa,UAAS;EAE5B,MAAM,gBAAgB,MAAqB;AACzC,QAAK,SAAS,GAAG,EAAE,UAAU,EAAE,YAAY,EAAE,QAAQ,QAAA,cAAc;AACjE,MAAE,gBAAe;AACjB,MAAE,iBAAgB;AAElB,QAAI,WAAW,KACb,YAAW,MAAK;QAEhB,YAAW,MAAK;;;AAKtB,cACQ,WAAW,MACjB,OAAO,MAAM,SAAS;AAEpB,OAAI,CAAC,QAAQ,MAAM;AACjB,UAAM,UAAS;AACf,WAAO,OAAO,IAAI,OAAM;;IAG9B;AAKA,kBAAgB,OAAO,iBAAiB,WAAW,aAAa,CAAA;AAChE,wBAAsB,OAAO,oBAAoB,WAAW,aAAa,CAAA;EAEzE,SAAS,cAAc;AACrB,cAAW,MAAK;;;2DAKR,QAAA,aAAA,WAAA,EADR,YAIyB,MAAA,iBAAA,EAAA;;IAFtB,MAAM,MAAA,0BAAyB;IAChC,OAAM;IACL,SAAO;0CACV,YAuB4B,MAAA,0BAAA,EAAA;;aArBtB;IAAJ,KAAI;IACJ,OAAK,eAAA,CAAC,UACEA,KAAAA,OAAO,MAAK,CAAA;IACnB,SAAO;;IAOG,UAAQ,cAIN,CAHK,MAAA,QAAO,EAAA,IAAA,WAAA,EAAvB,mBAGW,UAAA,EAAA,KAAA,GAAA,EAAA,CAAA,OAAA,OAAA,OAAA,KAFT,mBAAoC,QAAA,EAA9B,OAAM,WAAS,EAAC,WAAO,GAAA,GAAA,OAAA,OAAA,OAAA,KAC7B,mBAAiC,QAAA,EAA3B,eAAY,QAAM,EAAC,KAAC,GAAA,EAAA,EAAA,GAAA,KAAA,WAAA,EAE5B,mBAGW,UAAA,EAAA,KAAA,GAAA,EAAA,CAAA,OAAA,OAAA,OAAA,KAFT,mBAAiC,QAAA,EAA3B,OAAM,WAAS,EAAC,QAAI,GAAA,GAAA,OAAA,OAAA,OAAA,KAC1B,mBAAiC,QAAA,EAA3B,eAAY,QAAM,EAAC,KAAC,GAAA,EAAA,EAAA,GAAA,GAAA,gBACjB,MACX,gBAAG,QAAA,aAAY,EAAA,EAAA,CAAA,CAAA;2BAfuB,CAAA,OAAA,OAAA,OAAA,KAAxC,mBAAwC,QAAA,EAAlC,OAAM,WAAS,EAAC,eAAW,GAAA,GAAA,OAAA,OAAA,OAAA,KACjC,mBAIO,QAAA;KAHL,eAAY;KACZ,OAAM;OAA6B,YAErC,GAAA,EAAA,CAAA;;sBAcF,YAI6B,qBAAA;IAH1B,UAAA,QAAA;IACA,UAAU,QAAA;IACV,YAAY,QAAA;IACZ,YAAY,MAAA,WAAU"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import _plugin_vue_export_helper_default from "../../../_virtual/_plugin-vue_export-helper.js";
|
|
2
|
+
import SearchModal_vue_vue_type_script_setup_true_lang_default from "./SearchModal.vue.script.js";
|
|
3
|
+
/* empty css */
|
|
4
|
+
//#region src/features/Search/components/SearchModal.vue
|
|
5
|
+
var SearchModal_default = /* @__PURE__ */ _plugin_vue_export_helper_default(SearchModal_vue_vue_type_script_setup_true_lang_default, [["__scopeId", "data-v-c1c368f9"]]);
|
|
6
|
+
//#endregion
|
|
7
|
+
export { SearchModal_default as default };
|
|
8
|
+
|
|
9
|
+
//# sourceMappingURL=SearchModal.vue.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SearchModal.vue.js","names":[],"sources":["../../../../src/features/Search/components/SearchModal.vue"],"sourcesContent":["<script setup lang=\"ts\">\nimport {\n ScalarModal,\n ScalarSearchInput,\n ScalarSearchResultList,\n type ModalState,\n} from '@scalar/components'\nimport type { WorkspaceEventBus } from '@scalar/workspace-store/events'\nimport type { OpenApiDocument } from '@scalar/workspace-store/schemas/v3.1/strict/openapi-document'\nimport { nanoid } from 'nanoid'\nimport { computed, ref, watch } from 'vue'\n\nimport { useSearchIndex } from '@/features/Search/hooks/useSearchIndex'\n\nimport SearchResult from './SearchResult.vue'\n\nconst props = defineProps<{\n modalState: ModalState\n document: OpenApiDocument | undefined\n eventBus: WorkspaceEventBus\n}>()\n\n/** Base id for the search form */\nconst id = nanoid()\n/** An id for the results listbox */\nconst listboxId = `${id}-search-result`\n/** An id for the results instructions */\nconst instructionsId = `${id}-search-instructions`\n\nconst { query, results } = useSearchIndex(() => props.document)\n\nconst selectedIndex = ref<number | undefined>(undefined)\n\n/** Clear the query value when the modal is opened */\nwatch(\n () => props.modalState.open,\n (open) => {\n if (open) {\n query.value = ''\n }\n },\n)\n\n/** Keyboard navigation */\nconst navigateSearchResults = (direction: 'up' | 'down') => {\n const offset = direction === 'up' ? -1 : 1\n const length = results.value.length\n\n if (typeof selectedIndex.value === 'number') {\n // Ensures we loop around the array by using the remainder\n selectedIndex.value = (selectedIndex.value + offset + length) % length\n } else {\n // If no index is selected, we select the first or last item depending on the direction\n\n selectedIndex.value = offset === -1 ? length - 1 : 0\n }\n}\n\n/** Handle the selection of a search result */\nfunction handleSelect(idx: number | undefined) {\n if (typeof idx !== 'number' || !results.value[idx]) {\n return\n }\n\n const result = results.value[idx]\n props.modalState.hide()\n props.eventBus.emit('scroll-to:nav-item', { id: result.item.id })\n}\n\n/**\n * Active descendant id for the search input\n * NOTE: Result items MUST share this id for the aria-activedescendant attribute to work correctly\n */\nconst activeDescendantId = computed(() => {\n const selectedResult = results.value[selectedIndex.value ?? -1]\n\n return selectedResult ? `search-result-${selectedResult.item.id}` : undefined\n})\n</script>\n<template>\n <ScalarModal\n aria-label=\"Reference Search\"\n :state=\"modalState\"\n variant=\"search\">\n <div\n class=\"mb-0 flex flex-col\"\n role=\"search\">\n <ScalarSearchInput\n v-model=\"query\"\n :aria-activedescendant=\"activeDescendantId\"\n aria-autocomplete=\"list\"\n :aria-controls=\"listboxId\"\n :aria-describedby=\"instructionsId\"\n role=\"combobox\"\n @blur=\"selectedIndex = undefined\"\n @keydown.down.stop.prevent=\"navigateSearchResults('down')\"\n @keydown.enter.stop.prevent=\"() => handleSelect(selectedIndex)\"\n @keydown.up.stop.prevent=\"navigateSearchResults('up')\" />\n </div>\n <ScalarSearchResultList\n :id=\"listboxId\"\n aria-label=\"Reference Search Results\"\n class=\"custom-scroll p-1 pt-0\"\n :noResults=\"!results.length\">\n <template #query>\n {{ query }}\n </template>\n <SearchResult\n v-for=\"(result, idx) in results\"\n :id=\"`search-result-${result.item.id}`\"\n :key=\"result.refIndex\"\n :isSelected=\"selectedIndex === idx\"\n :result=\"result\"\n @click.prevent=\"() => handleSelect(idx)\" />\n </ScalarSearchResultList>\n <div\n :id=\"instructionsId\"\n class=\"ref-search-meta\">\n <span\n aria-hidden=\"true\"\n class=\"contents\">\n <span>↑↓ Navigate</span>\n <span>⏎ Select</span>\n </span>\n <span class=\"sr-only\">\n Press up arrow / down arrow to navigate, enter to select, type to filter\n results\n </span>\n </div>\n </ScalarModal>\n</template>\n<style scoped>\n.ref-search-meta {\n background: var(--scalar-background-1);\n border-bottom-left-radius: var(--scalar-radius-lg);\n border-bottom-right-radius: var(--scalar-radius-lg);\n padding: 6px 12px;\n font-size: var(--scalar-font-size-4);\n color: var(--scalar-color-3);\n font-weight: var(--scalar-semibold);\n display: flex;\n gap: 12px;\n border-top: var(--scalar-border-width) solid var(--scalar-border-color);\n}\n</style>\n"],"mappings":""}
|
|
@@ -0,0 +1,115 @@
|
|
|
1
|
+
import { useSearchIndex } from "../hooks/useSearchIndex.js";
|
|
2
|
+
import SearchResult_default from "./SearchResult.vue.js";
|
|
3
|
+
import { Fragment, computed, createBlock, createElementBlock, createElementVNode, createTextVNode, createVNode, defineComponent, isRef, openBlock, ref, renderList, toDisplayString, unref, watch, withCtx, withKeys, withModifiers } from "vue";
|
|
4
|
+
import { ScalarModal, ScalarSearchInput, ScalarSearchResultList } from "@scalar/components";
|
|
5
|
+
import { nanoid } from "nanoid";
|
|
6
|
+
//#region src/features/Search/components/SearchModal.vue?vue&type=script&setup=true&lang.ts
|
|
7
|
+
var _hoisted_1 = {
|
|
8
|
+
class: "mb-0 flex flex-col",
|
|
9
|
+
role: "search"
|
|
10
|
+
};
|
|
11
|
+
var SearchModal_vue_vue_type_script_setup_true_lang_default = /* @__PURE__ */ defineComponent({
|
|
12
|
+
__name: "SearchModal",
|
|
13
|
+
props: {
|
|
14
|
+
modalState: {},
|
|
15
|
+
document: {},
|
|
16
|
+
eventBus: {}
|
|
17
|
+
},
|
|
18
|
+
setup(__props) {
|
|
19
|
+
const props = __props;
|
|
20
|
+
/** Base id for the search form */
|
|
21
|
+
const id = nanoid();
|
|
22
|
+
/** An id for the results listbox */
|
|
23
|
+
const listboxId = `${id}-search-result`;
|
|
24
|
+
/** An id for the results instructions */
|
|
25
|
+
const instructionsId = `${id}-search-instructions`;
|
|
26
|
+
const { query, results } = useSearchIndex(() => props.document);
|
|
27
|
+
const selectedIndex = ref(void 0);
|
|
28
|
+
/** Clear the query value when the modal is opened */
|
|
29
|
+
watch(() => props.modalState.open, (open) => {
|
|
30
|
+
if (open) query.value = "";
|
|
31
|
+
});
|
|
32
|
+
/** Keyboard navigation */
|
|
33
|
+
const navigateSearchResults = (direction) => {
|
|
34
|
+
const offset = direction === "up" ? -1 : 1;
|
|
35
|
+
const length = results.value.length;
|
|
36
|
+
if (typeof selectedIndex.value === "number") selectedIndex.value = (selectedIndex.value + offset + length) % length;
|
|
37
|
+
else selectedIndex.value = offset === -1 ? length - 1 : 0;
|
|
38
|
+
};
|
|
39
|
+
/** Handle the selection of a search result */
|
|
40
|
+
function handleSelect(idx) {
|
|
41
|
+
if (typeof idx !== "number" || !results.value[idx]) return;
|
|
42
|
+
const result = results.value[idx];
|
|
43
|
+
props.modalState.hide();
|
|
44
|
+
props.eventBus.emit("scroll-to:nav-item", { id: result.item.id });
|
|
45
|
+
}
|
|
46
|
+
/**
|
|
47
|
+
* Active descendant id for the search input
|
|
48
|
+
* NOTE: Result items MUST share this id for the aria-activedescendant attribute to work correctly
|
|
49
|
+
*/
|
|
50
|
+
const activeDescendantId = computed(() => {
|
|
51
|
+
const selectedResult = results.value[selectedIndex.value ?? -1];
|
|
52
|
+
return selectedResult ? `search-result-${selectedResult.item.id}` : void 0;
|
|
53
|
+
});
|
|
54
|
+
return (_ctx, _cache) => {
|
|
55
|
+
return openBlock(), createBlock(unref(ScalarModal), {
|
|
56
|
+
"aria-label": "Reference Search",
|
|
57
|
+
state: __props.modalState,
|
|
58
|
+
variant: "search"
|
|
59
|
+
}, {
|
|
60
|
+
default: withCtx(() => [
|
|
61
|
+
createElementVNode("div", _hoisted_1, [createVNode(unref(ScalarSearchInput), {
|
|
62
|
+
modelValue: unref(query),
|
|
63
|
+
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => isRef(query) ? query.value = $event : null),
|
|
64
|
+
"aria-activedescendant": activeDescendantId.value,
|
|
65
|
+
"aria-autocomplete": "list",
|
|
66
|
+
"aria-controls": listboxId,
|
|
67
|
+
"aria-describedby": instructionsId,
|
|
68
|
+
role: "combobox",
|
|
69
|
+
onBlur: _cache[1] || (_cache[1] = ($event) => selectedIndex.value = void 0),
|
|
70
|
+
onKeydown: [
|
|
71
|
+
_cache[2] || (_cache[2] = withKeys(withModifiers(($event) => navigateSearchResults("down"), ["stop", "prevent"]), ["down"])),
|
|
72
|
+
_cache[3] || (_cache[3] = withKeys(withModifiers(() => handleSelect(selectedIndex.value), ["stop", "prevent"]), ["enter"])),
|
|
73
|
+
_cache[4] || (_cache[4] = withKeys(withModifiers(($event) => navigateSearchResults("up"), ["stop", "prevent"]), ["up"]))
|
|
74
|
+
]
|
|
75
|
+
}, null, 8, ["modelValue", "aria-activedescendant"])]),
|
|
76
|
+
createVNode(unref(ScalarSearchResultList), {
|
|
77
|
+
id: listboxId,
|
|
78
|
+
"aria-label": "Reference Search Results",
|
|
79
|
+
class: "custom-scroll p-1 pt-0",
|
|
80
|
+
noResults: !unref(results).length
|
|
81
|
+
}, {
|
|
82
|
+
query: withCtx(() => [createTextVNode(toDisplayString(unref(query)), 1)]),
|
|
83
|
+
default: withCtx(() => [(openBlock(true), createElementBlock(Fragment, null, renderList(unref(results), (result, idx) => {
|
|
84
|
+
return openBlock(), createBlock(SearchResult_default, {
|
|
85
|
+
id: `search-result-${result.item.id}`,
|
|
86
|
+
key: result.refIndex,
|
|
87
|
+
isSelected: selectedIndex.value === idx,
|
|
88
|
+
result,
|
|
89
|
+
onClick: withModifiers(() => handleSelect(idx), ["prevent"])
|
|
90
|
+
}, null, 8, [
|
|
91
|
+
"id",
|
|
92
|
+
"isSelected",
|
|
93
|
+
"result",
|
|
94
|
+
"onClick"
|
|
95
|
+
]);
|
|
96
|
+
}), 128))]),
|
|
97
|
+
_: 1
|
|
98
|
+
}, 8, ["noResults"]),
|
|
99
|
+
createElementVNode("div", {
|
|
100
|
+
id: instructionsId,
|
|
101
|
+
class: "ref-search-meta"
|
|
102
|
+
}, [..._cache[5] || (_cache[5] = [createElementVNode("span", {
|
|
103
|
+
"aria-hidden": "true",
|
|
104
|
+
class: "contents"
|
|
105
|
+
}, [createElementVNode("span", null, "↑↓ Navigate"), createElementVNode("span", null, "⏎ Select")], -1), createElementVNode("span", { class: "sr-only" }, " Press up arrow / down arrow to navigate, enter to select, type to filter results ", -1)])])
|
|
106
|
+
]),
|
|
107
|
+
_: 1
|
|
108
|
+
}, 8, ["state"]);
|
|
109
|
+
};
|
|
110
|
+
}
|
|
111
|
+
});
|
|
112
|
+
//#endregion
|
|
113
|
+
export { SearchModal_vue_vue_type_script_setup_true_lang_default as default };
|
|
114
|
+
|
|
115
|
+
//# sourceMappingURL=SearchModal.vue.script.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SearchModal.vue.script.js","names":[],"sources":["../../../../src/features/Search/components/SearchModal.vue"],"sourcesContent":["<script setup lang=\"ts\">\nimport {\n ScalarModal,\n ScalarSearchInput,\n ScalarSearchResultList,\n type ModalState,\n} from '@scalar/components'\nimport type { WorkspaceEventBus } from '@scalar/workspace-store/events'\nimport type { OpenApiDocument } from '@scalar/workspace-store/schemas/v3.1/strict/openapi-document'\nimport { nanoid } from 'nanoid'\nimport { computed, ref, watch } from 'vue'\n\nimport { useSearchIndex } from '@/features/Search/hooks/useSearchIndex'\n\nimport SearchResult from './SearchResult.vue'\n\nconst props = defineProps<{\n modalState: ModalState\n document: OpenApiDocument | undefined\n eventBus: WorkspaceEventBus\n}>()\n\n/** Base id for the search form */\nconst id = nanoid()\n/** An id for the results listbox */\nconst listboxId = `${id}-search-result`\n/** An id for the results instructions */\nconst instructionsId = `${id}-search-instructions`\n\nconst { query, results } = useSearchIndex(() => props.document)\n\nconst selectedIndex = ref<number | undefined>(undefined)\n\n/** Clear the query value when the modal is opened */\nwatch(\n () => props.modalState.open,\n (open) => {\n if (open) {\n query.value = ''\n }\n },\n)\n\n/** Keyboard navigation */\nconst navigateSearchResults = (direction: 'up' | 'down') => {\n const offset = direction === 'up' ? -1 : 1\n const length = results.value.length\n\n if (typeof selectedIndex.value === 'number') {\n // Ensures we loop around the array by using the remainder\n selectedIndex.value = (selectedIndex.value + offset + length) % length\n } else {\n // If no index is selected, we select the first or last item depending on the direction\n\n selectedIndex.value = offset === -1 ? length - 1 : 0\n }\n}\n\n/** Handle the selection of a search result */\nfunction handleSelect(idx: number | undefined) {\n if (typeof idx !== 'number' || !results.value[idx]) {\n return\n }\n\n const result = results.value[idx]\n props.modalState.hide()\n props.eventBus.emit('scroll-to:nav-item', { id: result.item.id })\n}\n\n/**\n * Active descendant id for the search input\n * NOTE: Result items MUST share this id for the aria-activedescendant attribute to work correctly\n */\nconst activeDescendantId = computed(() => {\n const selectedResult = results.value[selectedIndex.value ?? -1]\n\n return selectedResult ? `search-result-${selectedResult.item.id}` : undefined\n})\n</script>\n<template>\n <ScalarModal\n aria-label=\"Reference Search\"\n :state=\"modalState\"\n variant=\"search\">\n <div\n class=\"mb-0 flex flex-col\"\n role=\"search\">\n <ScalarSearchInput\n v-model=\"query\"\n :aria-activedescendant=\"activeDescendantId\"\n aria-autocomplete=\"list\"\n :aria-controls=\"listboxId\"\n :aria-describedby=\"instructionsId\"\n role=\"combobox\"\n @blur=\"selectedIndex = undefined\"\n @keydown.down.stop.prevent=\"navigateSearchResults('down')\"\n @keydown.enter.stop.prevent=\"() => handleSelect(selectedIndex)\"\n @keydown.up.stop.prevent=\"navigateSearchResults('up')\" />\n </div>\n <ScalarSearchResultList\n :id=\"listboxId\"\n aria-label=\"Reference Search Results\"\n class=\"custom-scroll p-1 pt-0\"\n :noResults=\"!results.length\">\n <template #query>\n {{ query }}\n </template>\n <SearchResult\n v-for=\"(result, idx) in results\"\n :id=\"`search-result-${result.item.id}`\"\n :key=\"result.refIndex\"\n :isSelected=\"selectedIndex === idx\"\n :result=\"result\"\n @click.prevent=\"() => handleSelect(idx)\" />\n </ScalarSearchResultList>\n <div\n :id=\"instructionsId\"\n class=\"ref-search-meta\">\n <span\n aria-hidden=\"true\"\n class=\"contents\">\n <span>↑↓ Navigate</span>\n <span>⏎ Select</span>\n </span>\n <span class=\"sr-only\">\n Press up arrow / down arrow to navigate, enter to select, type to filter\n results\n </span>\n </div>\n </ScalarModal>\n</template>\n<style scoped>\n.ref-search-meta {\n background: var(--scalar-background-1);\n border-bottom-left-radius: var(--scalar-radius-lg);\n border-bottom-right-radius: var(--scalar-radius-lg);\n padding: 6px 12px;\n font-size: var(--scalar-font-size-4);\n color: var(--scalar-color-3);\n font-weight: var(--scalar-semibold);\n display: flex;\n gap: 12px;\n border-top: var(--scalar-border-width) solid var(--scalar-border-color);\n}\n</style>\n"],"mappings":";;;;;;;;;;;;;;;;;;EAgBA,MAAM,QAAQ;;EAOd,MAAM,KAAK,QAAO;;EAElB,MAAM,YAAY,GAAG,GAAG;;EAExB,MAAM,iBAAiB,GAAG,GAAG;EAE7B,MAAM,EAAE,OAAO,YAAY,qBAAqB,MAAM,SAAQ;EAE9D,MAAM,gBAAgB,IAAwB,KAAA,EAAS;;AAGvD,cACQ,MAAM,WAAW,OACtB,SAAS;AACR,OAAI,KACF,OAAM,QAAQ;IAGpB;;EAGA,MAAM,yBAAyB,cAA6B;GAC1D,MAAM,SAAS,cAAc,OAAO,KAAK;GACzC,MAAM,SAAS,QAAQ,MAAM;AAE7B,OAAI,OAAO,cAAc,UAAU,SAEjC,eAAc,SAAS,cAAc,QAAQ,SAAS,UAAU;OAIhE,eAAc,QAAQ,WAAW,KAAK,SAAS,IAAI;;;EAKvD,SAAS,aAAa,KAAyB;AAC7C,OAAI,OAAO,QAAQ,YAAY,CAAC,QAAQ,MAAM,KAC5C;GAGF,MAAM,SAAS,QAAQ,MAAM;AAC7B,SAAM,WAAW,MAAK;AACtB,SAAM,SAAS,KAAK,sBAAsB,EAAE,IAAI,OAAO,KAAK,IAAI,CAAA;;;;;;EAOlE,MAAM,qBAAqB,eAAe;GACxC,MAAM,iBAAiB,QAAQ,MAAM,cAAc,SAAS;AAE5D,UAAO,iBAAiB,iBAAiB,eAAe,KAAK,OAAO,KAAA;IACrE;;uBAGC,YAiDc,MAAA,YAAA,EAAA;IAhDZ,cAAW;IACV,OAAO,QAAA;IACR,SAAQ;;2BAeF;KAdN,mBAcM,OAdN,YAcM,CAXJ,YAU2D,MAAA,kBAAA,EAAA;kBAThD,MAAA,MAAK;wFAAA,QAAA,SAAA;MACb,yBAAuB,mBAAA;MACxB,qBAAkB;MACjB,iBAAe;MACf,oBAAkB;MACnB,MAAK;MACJ,QAAI,OAAA,OAAA,OAAA,MAAA,WAAE,cAAA,QAAgB,KAAA;MACtB,WAAO;oEAAoB,sBAAqB,OAAA,EAAA,CAAA,QAAA,UAAA,CAAA,EAAA,CAAA,OAAA,CAAA;8DACd,aAAa,cAAA,MAAa,EAAA,CAAA,QAAA,UAAA,CAAA,EAAA,CAAA,QAAA,CAAA;oEACnC,sBAAqB,KAAA,EAAA,CAAA,QAAA,UAAA,CAAA,EAAA,CAAA,KAAA,CAAA;;;KAEnD,YAeyB,MAAA,uBAAA,EAAA;MAdtB,IAAI;MACL,cAAW;MACX,OAAM;MACL,WAAS,CAAG,MAAA,QAAO,CAAC;;MACV,OAAK,cACH,CAAA,gBAAA,gBAAR,MAAA,MAAK,CAAA,EAAA,EAAA,CAAA,CAAA;6BAGwB,EAAA,UAAA,KAAA,EADlC,mBAM6C,UAAA,MAAA,WALnB,MAAA,QAAO,GAAvB,QAAQ,QAAG;2BADrB,YAM6C,sBAAA;QAJ1C,IAAE,iBAAmB,OAAO,KAAK;QACjC,KAAK,OAAO;QACZ,YAAY,cAAA,UAAkB;QACtB;QACR,SAAK,oBAAgB,aAAa,IAAG,EAAA,CAAA,UAAA,CAAA;;;;;;;;;;KAE1C,mBAaM,OAAA;MAZH,IAAI;MACL,OAAM;uCACN,mBAKO,QAAA;MAJL,eAAY;MACZ,OAAM;SACN,mBAAwB,QAAA,MAAlB,cAAW,EACjB,mBAAqB,QAAA,MAAf,WAAQ,CAAA,EAAA,GAAA,EAEhB,mBAGO,QAAA,EAHD,OAAM,WAAS,EAAC,sFAGtB,GAAA,CAAA,EAAA,CAAA"}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import SearchResult_vue_vue_type_script_setup_true_lang_default from "./SearchResult.vue.script.js";
|
|
2
|
+
//#region src/features/Search/components/SearchResult.vue
|
|
3
|
+
var SearchResult_default = SearchResult_vue_vue_type_script_setup_true_lang_default;
|
|
4
|
+
//#endregion
|
|
5
|
+
export { SearchResult_default as default };
|
|
6
|
+
|
|
7
|
+
//# sourceMappingURL=SearchResult.vue.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SearchResult.vue.js","names":[],"sources":["../../../../src/features/Search/components/SearchResult.vue"],"sourcesContent":["<script setup lang=\"ts\">\nimport { ScalarSearchResultItem } from '@scalar/components'\nimport {\n ScalarIconBracketsCurly,\n ScalarIconTag,\n ScalarIconTerminalWindow,\n ScalarIconTextAlignLeft,\n} from '@scalar/icons'\nimport type { ScalarIconComponent } from '@scalar/icons/types'\nimport { HttpMethod } from '@scalar/sidebar'\nimport type { FuseResult } from 'fuse.js'\n\nimport type { EntryType, FuseData } from '@/features/Search/types'\n\ndefineProps<{\n id: string\n isSelected: boolean\n result: FuseResult<FuseData>\n}>()\n\nconst ENTRY_ICONS: { [x in EntryType]: ScalarIconComponent } = {\n heading: ScalarIconTextAlignLeft,\n model: ScalarIconBracketsCurly,\n operation: ScalarIconTerminalWindow,\n tag: ScalarIconTag,\n webhook: ScalarIconTerminalWindow,\n}\n\nconst ENTRY_LABELS: { [x in EntryType]: string } = {\n heading: 'Heading',\n operation: 'Operation',\n tag: 'Tag',\n model: 'Model',\n webhook: 'Webhook',\n}\n</script>\n\n<template>\n <ScalarSearchResultItem\n :id=\"id\"\n :icon=\"ENTRY_ICONS[result.item.type]\"\n :selected=\"isSelected\">\n <span\n :class=\"{\n 'text-decoration-line':\n result.item.entry.type === 'operation' &&\n result.item.entry.isDeprecated,\n }\">\n <span class=\"sr-only\">\n {{ ENTRY_LABELS[result.item.type] }}: \n <template\n v-if=\"\n result.item.entry.type === 'operation' &&\n result.item.entry.isDeprecated\n \">\n (Deprecated) \n </template>\n </span>\n {{ result.item.title }}\n <span class=\"sr-only\">,</span>\n </span>\n <template\n v-if=\"\n result.item.type !== 'webhook' &&\n (result.item.method || result.item.path) &&\n result.item.path !== result.item.title\n \"\n #description>\n <span class=\"inline-flex items-center gap-1\">\n <template v-if=\"result.item.type === 'operation'\">\n <HttpMethod\n aria-hidden=\"true\"\n :method=\"result.item.method ?? 'get'\" />\n <span class=\"sr-only\">\n HTTP Method: {{ result.item.method ?? 'get' }}\n </span>\n </template>\n <span class=\"sr-only\">Path: </span>\n {{ result.item.path }}\n </span>\n </template>\n <template\n v-else-if=\"result.item.description\"\n #description>\n <span class=\"sr-only\">Description: </span>\n {{ result.item.description }}\n </template>\n </ScalarSearchResultItem>\n</template>\n"],"mappings":""}
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
import { Fragment, createBlock, createCommentVNode, createElementBlock, createElementVNode, createSlots, createTextVNode, createVNode, defineComponent, normalizeClass, openBlock, toDisplayString, unref, withCtx } from "vue";
|
|
2
|
+
import { ScalarSearchResultItem } from "@scalar/components";
|
|
3
|
+
import { HttpMethod } from "@scalar/sidebar";
|
|
4
|
+
import { ScalarIconBracketsCurly, ScalarIconTag, ScalarIconTerminalWindow, ScalarIconTextAlignLeft } from "@scalar/icons";
|
|
5
|
+
//#region src/features/Search/components/SearchResult.vue?vue&type=script&setup=true&lang.ts
|
|
6
|
+
var _hoisted_1 = { class: "sr-only" };
|
|
7
|
+
var _hoisted_2 = { class: "inline-flex items-center gap-1" };
|
|
8
|
+
var _hoisted_3 = { class: "sr-only" };
|
|
9
|
+
var SearchResult_vue_vue_type_script_setup_true_lang_default = /* @__PURE__ */ defineComponent({
|
|
10
|
+
__name: "SearchResult",
|
|
11
|
+
props: {
|
|
12
|
+
id: {},
|
|
13
|
+
isSelected: { type: Boolean },
|
|
14
|
+
result: {}
|
|
15
|
+
},
|
|
16
|
+
setup(__props) {
|
|
17
|
+
const ENTRY_ICONS = {
|
|
18
|
+
heading: ScalarIconTextAlignLeft,
|
|
19
|
+
model: ScalarIconBracketsCurly,
|
|
20
|
+
operation: ScalarIconTerminalWindow,
|
|
21
|
+
tag: ScalarIconTag,
|
|
22
|
+
webhook: ScalarIconTerminalWindow
|
|
23
|
+
};
|
|
24
|
+
const ENTRY_LABELS = {
|
|
25
|
+
heading: "Heading",
|
|
26
|
+
operation: "Operation",
|
|
27
|
+
tag: "Tag",
|
|
28
|
+
model: "Model",
|
|
29
|
+
webhook: "Webhook"
|
|
30
|
+
};
|
|
31
|
+
return (_ctx, _cache) => {
|
|
32
|
+
return openBlock(), createBlock(unref(ScalarSearchResultItem), {
|
|
33
|
+
id: __props.id,
|
|
34
|
+
icon: ENTRY_ICONS[__props.result.item.type],
|
|
35
|
+
selected: __props.isSelected
|
|
36
|
+
}, createSlots({
|
|
37
|
+
default: withCtx(() => [createElementVNode("span", { class: normalizeClass({ "text-decoration-line": __props.result.item.entry.type === "operation" && __props.result.item.entry.isDeprecated }) }, [
|
|
38
|
+
createElementVNode("span", _hoisted_1, [createTextVNode(toDisplayString(ENTRY_LABELS[__props.result.item.type]) + ":\xA0 ", 1), __props.result.item.entry.type === "operation" && __props.result.item.entry.isDeprecated ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [createTextVNode(" (Deprecated)\xA0 ")], 64)) : createCommentVNode("", true)]),
|
|
39
|
+
createTextVNode(" " + toDisplayString(__props.result.item.title) + " ", 1),
|
|
40
|
+
_cache[0] || (_cache[0] = createElementVNode("span", { class: "sr-only" }, ",", -1))
|
|
41
|
+
], 2)]),
|
|
42
|
+
_: 2
|
|
43
|
+
}, [__props.result.item.type !== "webhook" && (__props.result.item.method || __props.result.item.path) && __props.result.item.path !== __props.result.item.title ? {
|
|
44
|
+
name: "description",
|
|
45
|
+
fn: withCtx(() => [createElementVNode("span", _hoisted_2, [
|
|
46
|
+
__props.result.item.type === "operation" ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [createVNode(unref(HttpMethod), {
|
|
47
|
+
"aria-hidden": "true",
|
|
48
|
+
method: __props.result.item.method ?? "get"
|
|
49
|
+
}, null, 8, ["method"]), createElementVNode("span", _hoisted_3, " HTTP Method: " + toDisplayString(__props.result.item.method ?? "get"), 1)], 64)) : createCommentVNode("", true),
|
|
50
|
+
_cache[1] || (_cache[1] = createElementVNode("span", { class: "sr-only" }, "Path:\xA0", -1)),
|
|
51
|
+
createTextVNode(" " + toDisplayString(__props.result.item.path), 1)
|
|
52
|
+
])]),
|
|
53
|
+
key: "0"
|
|
54
|
+
} : __props.result.item.description ? {
|
|
55
|
+
name: "description",
|
|
56
|
+
fn: withCtx(() => [_cache[2] || (_cache[2] = createElementVNode("span", { class: "sr-only" }, "Description:\xA0", -1)), createTextVNode(" " + toDisplayString(__props.result.item.description), 1)]),
|
|
57
|
+
key: "1"
|
|
58
|
+
} : void 0]), 1032, [
|
|
59
|
+
"id",
|
|
60
|
+
"icon",
|
|
61
|
+
"selected"
|
|
62
|
+
]);
|
|
63
|
+
};
|
|
64
|
+
}
|
|
65
|
+
});
|
|
66
|
+
//#endregion
|
|
67
|
+
export { SearchResult_vue_vue_type_script_setup_true_lang_default as default };
|
|
68
|
+
|
|
69
|
+
//# sourceMappingURL=SearchResult.vue.script.js.map
|