@scalar/api-reference 1.32.10 → 1.34.0
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 +99 -0
- package/dist/browser/standalone.js +16194 -15784
- package/dist/browser/webpack-stats.json +1 -1
- package/dist/components/Anchor/Anchor.vue.d.ts.map +1 -1
- package/dist/components/Anchor/Anchor.vue.js +50 -5
- package/dist/components/Anchor/Anchor.vue2.js +2 -42
- package/dist/components/Anchor/WithBreadcrumb.vue.d.ts +24 -0
- package/dist/components/Anchor/WithBreadcrumb.vue.d.ts.map +1 -0
- package/dist/components/Anchor/WithBreadcrumb.vue.js +4 -0
- package/dist/components/Anchor/WithBreadcrumb.vue2.js +46 -0
- package/dist/components/Anchor/index.d.ts +1 -0
- package/dist/components/Anchor/index.d.ts.map +1 -1
- package/dist/components/ApiReference.vue.js +6 -6
- package/dist/components/ApiReferenceLayout.vue.d.ts.map +1 -1
- package/dist/components/ApiReferenceLayout.vue.js +6 -6
- package/dist/components/ApiReferenceLayout.vue2.js +179 -193
- package/dist/components/ApiReferenceLayout.vue3.js +4 -0
- package/dist/components/ApiReferenceLayout.vue4.js +4 -0
- package/dist/components/ApiReferenceLayout.vue5.js +4 -0
- package/dist/components/ApiReferenceLayout.vue6.js +4 -0
- package/dist/components/Badge/Badge.vue.js +1 -1
- package/dist/components/Badge/Badge.vue2.js +4 -0
- package/dist/components/ClassicHeader.vue.js +1 -1
- package/dist/components/ClassicHeader.vue2.js +4 -0
- package/dist/components/Content/ClientLibraries/ClientLibraries.vue.d.ts +14 -1
- package/dist/components/Content/ClientLibraries/ClientLibraries.vue.d.ts.map +1 -1
- package/dist/components/Content/ClientLibraries/ClientLibraries.vue.js +3 -3
- package/dist/components/Content/ClientLibraries/ClientLibraries.vue2.js +74 -84
- package/dist/components/Content/ClientLibraries/ClientLibraries.vue3.js +4 -0
- package/dist/components/Content/ClientLibraries/ClientSelector.vue.d.ts +8 -0
- package/dist/components/Content/ClientLibraries/ClientSelector.vue.d.ts.map +1 -1
- package/dist/components/Content/ClientLibraries/ClientSelector.vue.js +2 -2
- package/dist/components/Content/ClientLibraries/ClientSelector.vue2.js +81 -80
- package/dist/components/Content/ClientLibraries/ClientSelector.vue3.js +4 -0
- package/dist/components/Content/ClientLibraries/featured-clients.d.ts +11 -0
- package/dist/components/Content/ClientLibraries/featured-clients.d.ts.map +1 -0
- package/dist/components/Content/ClientLibraries/featured-clients.js +17 -0
- package/dist/components/Content/Content.vue.d.ts +5 -6
- package/dist/components/Content/Content.vue.d.ts.map +1 -1
- package/dist/components/Content/Content.vue.js +49 -6
- package/dist/components/Content/Content.vue2.js +2 -160
- package/dist/components/Content/Content.vue3.js +5 -0
- package/dist/components/Content/Introduction/Description.vue.js +1 -1
- package/dist/components/Content/Introduction/Description.vue3.js +4 -0
- package/dist/components/Content/Introduction/Introduction.vue.d.ts +7 -17
- package/dist/components/Content/Introduction/Introduction.vue.d.ts.map +1 -1
- package/dist/components/Content/Introduction/Introduction.vue.js +3 -3
- package/dist/components/Content/Introduction/Introduction.vue2.js +104 -150
- package/dist/components/Content/Introduction/Introduction.vue3.js +4 -0
- package/dist/components/Content/Introduction/IntroductionSection.vue.d.ts +25 -0
- package/dist/components/Content/Introduction/IntroductionSection.vue.d.ts.map +1 -0
- package/dist/components/Content/Introduction/IntroductionSection.vue.js +7 -0
- package/dist/components/Content/Introduction/IntroductionSection.vue2.js +159 -0
- package/dist/components/Content/Introduction/IntroductionSection.vue3.js +4 -0
- package/dist/components/Content/Models/{ModelsAccordion.vue.d.ts → ClassicLayout.vue.d.ts} +2 -2
- package/dist/components/Content/Models/ClassicLayout.vue.d.ts.map +1 -0
- package/dist/components/Content/Models/ClassicLayout.vue.js +7 -0
- package/dist/components/Content/Models/{ModelsAccordion.vue2.js → ClassicLayout.vue2.js} +30 -30
- package/dist/components/Content/Models/ClassicLayout.vue3.js +4 -0
- package/dist/components/Content/Models/Models.vue.d.ts +3 -1
- package/dist/components/Content/Models/Models.vue.d.ts.map +1 -1
- package/dist/components/Content/Models/Models.vue.js +38 -5
- package/dist/components/Content/Models/Models.vue2.js +2 -114
- package/dist/components/Content/Models/ModernLayout.vue.d.ts +7 -0
- package/dist/components/Content/Models/ModernLayout.vue.d.ts.map +1 -0
- package/dist/components/Content/Models/ModernLayout.vue.js +7 -0
- package/dist/components/Content/Models/ModernLayout.vue2.js +100 -0
- package/dist/components/Content/Models/ModernLayout.vue3.js +4 -0
- package/dist/components/Content/Models/index.d.ts +0 -1
- package/dist/components/Content/Models/index.d.ts.map +1 -1
- package/dist/components/Content/Operations/TraversedEntry.vue.d.ts +22 -0
- package/dist/components/Content/Operations/TraversedEntry.vue.d.ts.map +1 -0
- package/dist/components/Content/Operations/TraversedEntry.vue.js +97 -0
- package/dist/components/Content/Operations/TraversedEntry.vue2.js +4 -0
- package/dist/components/Content/Operations/TraversedEntryContainer.vue.d.ts +17 -0
- package/dist/components/Content/Operations/TraversedEntryContainer.vue.d.ts.map +1 -0
- package/dist/components/Content/Operations/TraversedEntryContainer.vue.js +60 -0
- package/dist/components/Content/Operations/TraversedEntryContainer.vue2.js +4 -0
- package/dist/components/Content/Operations/get-current-index.d.ts +4 -0
- package/dist/components/Content/Operations/get-current-index.d.ts.map +1 -0
- package/dist/components/Content/Operations/get-current-index.js +16 -0
- package/dist/components/Content/Operations/index.d.ts +2 -0
- package/dist/components/Content/Operations/index.d.ts.map +1 -0
- package/dist/components/Content/Schema/Schema.preview.d.ts +28 -0
- package/dist/components/Content/Schema/Schema.preview.d.ts.map +1 -1
- package/dist/components/Content/Schema/Schema.vue.d.ts +2 -0
- package/dist/components/Content/Schema/Schema.vue.d.ts.map +1 -1
- package/dist/components/Content/Schema/Schema.vue.js +3 -3
- package/dist/components/Content/Schema/Schema.vue2.js +164 -157
- package/dist/components/Content/Schema/Schema.vue3.js +4 -0
- package/dist/components/Content/Schema/SchemaComposition.vue.d.ts +1 -0
- package/dist/components/Content/Schema/SchemaComposition.vue.d.ts.map +1 -1
- package/dist/components/Content/Schema/SchemaComposition.vue.js +58 -53
- package/dist/components/Content/Schema/SchemaEnumPropertyItem.vue.d.ts.map +1 -1
- package/dist/components/Content/Schema/SchemaEnumPropertyItem.vue.js +3 -3
- package/dist/components/Content/Schema/SchemaEnumPropertyItem.vue3.js +4 -0
- package/dist/components/Content/Schema/SchemaEnumValues.vue.d.ts.map +1 -1
- package/dist/components/Content/Schema/SchemaEnumValues.vue.js +3 -3
- package/dist/components/Content/Schema/SchemaEnumValues.vue2.js +63 -68
- package/dist/components/Content/Schema/SchemaEnumValues.vue3.js +4 -0
- package/dist/components/Content/Schema/SchemaHeading.vue.d.ts.map +1 -1
- package/dist/components/Content/Schema/SchemaHeading.vue.js +4 -4
- package/dist/components/Content/Schema/SchemaHeading.vue2.js +23 -22
- package/dist/components/Content/Schema/SchemaHeading.vue3.js +4 -0
- package/dist/components/Content/Schema/SchemaObjectProperties.vue.d.ts +1 -0
- package/dist/components/Content/Schema/SchemaObjectProperties.vue.d.ts.map +1 -1
- package/dist/components/Content/Schema/SchemaObjectProperties.vue.js +52 -40
- package/dist/components/Content/Schema/SchemaProperty.vue.d.ts +1 -0
- package/dist/components/Content/Schema/SchemaProperty.vue.d.ts.map +1 -1
- package/dist/components/Content/Schema/SchemaProperty.vue.js +3 -3
- package/dist/components/Content/Schema/SchemaProperty.vue2.js +103 -89
- package/dist/components/Content/Schema/SchemaProperty.vue3.js +4 -0
- package/dist/components/Content/Schema/SchemaPropertyDetail.vue.d.ts.map +1 -1
- package/dist/components/Content/Schema/SchemaPropertyDetail.vue.js +2 -2
- package/dist/components/Content/Schema/SchemaPropertyDetail.vue3.js +4 -0
- package/dist/components/Content/Schema/SchemaPropertyExamples.vue.js +3 -3
- package/dist/components/Content/Schema/SchemaPropertyExamples.vue3.js +4 -0
- package/dist/components/Content/Schema/SchemaPropertyHeading.vue.d.ts.map +1 -1
- package/dist/components/Content/Schema/SchemaPropertyHeading.vue.js +3 -3
- package/dist/components/Content/Schema/SchemaPropertyHeading.vue2.js +30 -24
- package/dist/components/Content/Schema/SchemaPropertyHeading.vue3.js +4 -0
- package/dist/components/Content/Schema/helpers/merge-all-of-schemas.d.ts +2 -1
- package/dist/components/Content/Schema/helpers/merge-all-of-schemas.d.ts.map +1 -1
- package/dist/components/Content/Schema/helpers/merge-all-of-schemas.js +59 -52
- package/dist/components/Content/Schema/helpers/optimize-value-for-display.d.ts.map +1 -1
- package/dist/components/Content/Schema/helpers/optimize-value-for-display.js +24 -20
- package/dist/components/Content/Schema/helpers/schema-name.d.ts +1 -1
- package/dist/components/Content/Schema/helpers/schema-name.d.ts.map +1 -1
- package/dist/components/Content/{Tag/TagAccordion.vue.d.ts → Tags/ClassicLayout.vue.d.ts} +3 -3
- package/dist/components/Content/Tags/ClassicLayout.vue.d.ts.map +1 -0
- package/dist/components/Content/Tags/ClassicLayout.vue.js +7 -0
- package/dist/components/Content/Tags/ClassicLayout.vue2.js +51 -0
- package/dist/components/Content/Tags/ClassicLayout.vue3.js +4 -0
- package/dist/components/Content/{Tag/TagSection.vue.d.ts → Tags/ModernLayout.vue.d.ts} +17 -13
- package/dist/components/Content/Tags/ModernLayout.vue.d.ts.map +1 -0
- package/dist/components/Content/Tags/ModernLayout.vue.js +7 -0
- package/dist/components/Content/Tags/ModernLayout.vue2.js +69 -0
- package/dist/components/Content/Tags/ModernLayout.vue3.js +4 -0
- package/dist/components/Content/Tags/Tag.vue.d.ts +25 -0
- package/dist/components/Content/Tags/Tag.vue.d.ts.map +1 -0
- package/dist/components/Content/Tags/Tag.vue.js +27 -0
- package/dist/components/Content/{Tag/Tag.vue.d.ts → Tags/TagSection.vue.d.ts} +3 -6
- package/dist/components/Content/Tags/TagSection.vue.d.ts.map +1 -0
- package/dist/components/Content/Tags/TagSection.vue.js +104 -0
- package/dist/components/Content/Tags/TagSection.vue2.js +4 -0
- package/dist/components/Content/Tags/index.d.ts +2 -0
- package/dist/components/Content/Tags/index.d.ts.map +1 -0
- package/dist/components/GettingStarted.vue.js +1 -1
- package/dist/components/GettingStarted.vue3.js +4 -0
- package/dist/components/HttpMethod/HttpMethod.vue.d.ts.map +1 -1
- package/dist/components/HttpMethod/HttpMethod.vue.js +8 -6
- package/dist/components/{Content/Lazy → Lazy}/Lazy.vue.d.ts +2 -10
- package/dist/components/Lazy/Lazy.vue.d.ts.map +1 -0
- package/dist/components/Lazy/Lazy.vue2.js +26 -0
- package/dist/components/Lazy/index.d.ts +3 -0
- package/dist/components/Lazy/index.d.ts.map +1 -0
- package/dist/components/Lazy/lazyBus.d.ts +10 -0
- package/dist/components/Lazy/lazyBus.d.ts.map +1 -0
- package/dist/components/Lazy/lazyBus.js +7 -0
- package/dist/components/LinkList/LinkList.vue.d.ts +3 -1
- package/dist/components/LinkList/LinkList.vue.d.ts.map +1 -1
- package/dist/components/LinkList/LinkList.vue.js +5 -10
- package/dist/components/LinkList/LinkList.vue2.js +32 -0
- package/dist/components/LinkList/LinkList.vue3.js +4 -0
- package/dist/components/LoadingSkeleton.vue.d.ts.map +1 -1
- package/dist/components/LoadingSkeleton.vue.js +3 -3
- package/dist/components/LoadingSkeleton.vue3.js +4 -0
- package/dist/components/MobileHeader.vue.js +1 -1
- package/dist/components/MobileHeader.vue3.js +4 -0
- package/dist/components/OperationPath.vue.js +1 -1
- package/dist/components/OperationPath.vue3.js +4 -0
- package/dist/components/{Content/Tag → OperationsList}/OperationsList.vue.d.ts +2 -5
- package/dist/components/OperationsList/OperationsList.vue.d.ts.map +1 -0
- package/dist/components/OperationsList/OperationsList.vue.js +7 -0
- package/dist/components/OperationsList/OperationsList.vue2.js +60 -0
- package/dist/components/OperationsList/OperationsList.vue3.js +4 -0
- package/dist/components/{Content/Tag → OperationsList}/OperationsListItem.vue.d.ts +2 -4
- package/dist/components/OperationsList/OperationsListItem.vue.d.ts.map +1 -0
- package/dist/components/OperationsList/OperationsListItem.vue.js +7 -0
- package/dist/components/OperationsList/OperationsListItem.vue2.js +63 -0
- package/dist/components/OperationsList/OperationsListItem.vue3.js +4 -0
- package/dist/components/OperationsList/index.d.ts +2 -0
- package/dist/components/OperationsList/index.d.ts.map +1 -0
- package/dist/components/ScreenReader.vue.js +1 -1
- package/dist/components/ScreenReader.vue3.js +4 -0
- package/dist/components/Section/CompactSection.vue.d.ts.map +1 -1
- package/dist/components/Section/CompactSection.vue.js +3 -3
- package/dist/components/Section/CompactSection.vue2.js +35 -36
- package/dist/components/Section/CompactSection.vue3.js +4 -0
- package/dist/components/Section/Section.vue.js +1 -1
- package/dist/components/Section/Section.vue3.js +4 -0
- package/dist/components/Section/SectionAccordion.vue.d.ts.map +1 -1
- package/dist/components/Section/SectionAccordion.vue.js +3 -3
- package/dist/components/Section/SectionAccordion.vue2.js +42 -36
- package/dist/components/Section/SectionAccordion.vue3.js +4 -0
- package/dist/components/Section/SectionColumn.vue.js +1 -1
- package/dist/components/Section/SectionColumn.vue2.js +4 -0
- package/dist/components/Section/SectionColumns.vue.js +1 -1
- package/dist/components/Section/SectionColumns.vue2.js +4 -0
- package/dist/components/Section/SectionContainer.vue.d.ts +9 -2
- package/dist/components/Section/SectionContainer.vue.d.ts.map +1 -1
- package/dist/components/Section/SectionContainer.vue.js +5 -11
- package/dist/components/Section/SectionContainer.vue2.js +18 -0
- package/dist/components/Section/SectionContainer.vue3.js +4 -0
- package/dist/components/Section/SectionContainerAccordion.vue.d.ts.map +1 -1
- package/dist/components/Section/SectionContainerAccordion.vue.js +3 -3
- package/dist/components/Section/SectionContainerAccordion.vue3.js +4 -0
- package/dist/components/Section/SectionContent.vue.js +1 -1
- package/dist/components/Section/SectionContent.vue3.js +4 -0
- package/dist/components/Section/SectionHeader.vue.js +1 -1
- package/dist/components/Section/SectionHeader.vue3.js +4 -0
- package/dist/components/Section/SectionHeaderTag.vue.js +1 -1
- package/dist/components/Section/SectionHeaderTag.vue3.js +4 -0
- package/dist/components/SectionFlare/SectionFlare.vue.d.ts +3 -0
- package/dist/components/SectionFlare/SectionFlare.vue.d.ts.map +1 -0
- package/dist/components/SectionFlare/SectionFlare.vue.js +13 -0
- package/dist/components/SectionFlare/SectionFlare.vue2.js +4 -0
- package/dist/components/SectionFlare/index.d.ts +2 -0
- package/dist/components/SectionFlare/index.d.ts.map +1 -0
- package/dist/components/ShowMoreButton.vue.d.ts.map +1 -1
- package/dist/components/ShowMoreButton.vue.js +3 -3
- package/dist/components/ShowMoreButton.vue2.js +12 -12
- package/dist/components/ShowMoreButton.vue3.js +4 -0
- package/dist/features/Operation/Operation.vue.d.ts +5 -1
- package/dist/features/Operation/Operation.vue.d.ts.map +1 -1
- package/dist/features/Operation/Operation.vue.js +55 -38
- package/dist/features/Operation/components/ContentTypeSelect.vue.d.ts +4 -4
- package/dist/features/Operation/components/ContentTypeSelect.vue.d.ts.map +1 -1
- package/dist/features/Operation/components/ContentTypeSelect.vue.js +28 -30
- package/dist/features/Operation/components/OperationParameters.vue.d.ts +1 -0
- package/dist/features/Operation/components/OperationParameters.vue.d.ts.map +1 -1
- package/dist/features/Operation/components/OperationParameters.vue.js +49 -43
- package/dist/features/Operation/components/OperationResponses.vue.d.ts +1 -0
- package/dist/features/Operation/components/OperationResponses.vue.d.ts.map +1 -1
- package/dist/features/Operation/components/OperationResponses.vue.js +4 -3
- package/dist/features/Operation/components/ParameterHeaders.vue.d.ts +1 -0
- package/dist/features/Operation/components/ParameterHeaders.vue.d.ts.map +1 -1
- package/dist/features/Operation/components/ParameterHeaders.vue.js +3 -3
- package/dist/features/Operation/components/ParameterHeaders.vue2.js +28 -26
- package/dist/features/Operation/components/ParameterHeaders.vue3.js +4 -0
- package/dist/features/Operation/components/ParameterList.vue.d.ts +1 -0
- package/dist/features/Operation/components/ParameterList.vue.d.ts.map +1 -1
- package/dist/features/Operation/components/ParameterList.vue.js +3 -3
- package/dist/features/Operation/components/ParameterList.vue2.js +17 -15
- package/dist/features/Operation/components/ParameterList.vue3.js +4 -0
- package/dist/features/Operation/components/ParameterListItem.vue.d.ts +1 -0
- package/dist/features/Operation/components/ParameterListItem.vue.d.ts.map +1 -1
- package/dist/features/Operation/components/ParameterListItem.vue.js +3 -3
- package/dist/features/Operation/components/ParameterListItem.vue2.js +36 -33
- package/dist/features/Operation/components/ParameterListItem.vue3.js +4 -0
- package/dist/features/Operation/components/RequestBody.vue.d.ts +2 -2
- package/dist/features/Operation/components/RequestBody.vue.d.ts.map +1 -1
- package/dist/features/Operation/components/RequestBody.vue.js +3 -3
- package/dist/features/Operation/components/RequestBody.vue2.js +47 -39
- package/dist/features/Operation/components/RequestBody.vue3.js +4 -0
- package/dist/features/Operation/components/callbacks/Callback.vue.d.ts +1 -0
- package/dist/features/Operation/components/callbacks/Callback.vue.d.ts.map +1 -1
- package/dist/features/Operation/components/callbacks/Callback.vue.js +3 -3
- package/dist/features/Operation/components/callbacks/Callback.vue2.js +10 -9
- package/dist/features/Operation/components/callbacks/Callback.vue3.js +4 -0
- package/dist/features/Operation/components/callbacks/Callbacks.vue.d.ts.map +1 -1
- package/dist/features/Operation/components/callbacks/Callbacks.vue.js +20 -28
- package/dist/features/Operation/layouts/ClassicLayout.vue.d.ts +6 -0
- package/dist/features/Operation/layouts/ClassicLayout.vue.d.ts.map +1 -1
- package/dist/features/Operation/layouts/ClassicLayout.vue.js +2 -2
- package/dist/features/Operation/layouts/ClassicLayout.vue2.js +77 -62
- package/dist/features/Operation/layouts/ClassicLayout.vue3.js +4 -0
- package/dist/features/Operation/layouts/ModernLayout.vue.d.ts +6 -0
- package/dist/features/Operation/layouts/ModernLayout.vue.d.ts.map +1 -1
- package/dist/features/Operation/layouts/ModernLayout.vue.js +3 -3
- package/dist/features/Operation/layouts/ModernLayout.vue2.js +72 -57
- package/dist/features/Operation/layouts/ModernLayout.vue3.js +4 -0
- package/dist/features/Search/{SearchButton.vue.d.ts → components/SearchButton.vue.d.ts} +0 -2
- package/dist/features/Search/components/SearchButton.vue.d.ts.map +1 -0
- package/dist/features/Search/components/SearchButton.vue.js +65 -0
- package/dist/features/Search/{SearchModal.vue.d.ts → components/SearchModal.vue.d.ts} +0 -2
- package/dist/features/Search/components/SearchModal.vue.d.ts.map +1 -0
- package/dist/features/Search/components/SearchModal.vue.js +7 -0
- package/dist/features/Search/components/SearchModal.vue2.js +199 -0
- package/dist/features/Search/components/SearchModal.vue3.js +4 -0
- package/dist/features/Search/helpers/create-fuse-instance.d.ts +9 -0
- package/dist/features/Search/helpers/create-fuse-instance.d.ts.map +1 -0
- package/dist/features/Search/helpers/create-fuse-instance.js +46 -0
- package/dist/features/Search/helpers/create-search-index.d.ts +7 -0
- package/dist/features/Search/helpers/create-search-index.d.ts.map +1 -0
- package/dist/features/Search/helpers/create-search-index.js +109 -0
- package/dist/features/Search/hooks/useSearchIndex.d.ts +14 -0
- package/dist/features/Search/hooks/useSearchIndex.d.ts.map +1 -0
- package/dist/features/Search/hooks/useSearchIndex.js +46 -0
- package/dist/features/Search/index.d.ts +2 -2
- package/dist/features/Search/index.d.ts.map +1 -1
- package/dist/features/Search/types.d.ts +15 -0
- package/dist/features/Search/types.d.ts.map +1 -0
- package/dist/features/api-client-modal/ApiClientModal.vue.d.ts.map +1 -1
- package/dist/features/api-client-modal/useApiClient.d.ts +414 -354
- package/dist/features/api-client-modal/useApiClient.d.ts.map +1 -1
- package/dist/features/download-link/DownloadLink.vue.js +2 -2
- package/dist/features/download-link/DownloadLink.vue3.js +4 -0
- package/dist/features/example-responses/ExampleResponse.vue.d.ts +4 -2
- package/dist/features/example-responses/ExampleResponse.vue.d.ts.map +1 -1
- package/dist/features/example-responses/ExampleResponse.vue.js +3 -3
- package/dist/features/example-responses/ExampleResponse.vue2.js +15 -14
- package/dist/features/example-responses/ExampleResponse.vue3.js +4 -0
- package/dist/features/example-responses/ExampleResponseTab.vue.js +1 -1
- package/dist/features/example-responses/ExampleResponseTab.vue3.js +4 -0
- package/dist/features/example-responses/ExampleResponseTabList.vue.js +1 -1
- package/dist/features/example-responses/ExampleResponseTabList.vue3.js +4 -0
- package/dist/features/example-responses/ExampleResponses.vue.d.ts +3 -2
- package/dist/features/example-responses/ExampleResponses.vue.d.ts.map +1 -1
- package/dist/features/example-responses/ExampleResponses.vue.js +4 -4
- package/dist/features/example-responses/ExampleResponses.vue2.js +107 -104
- package/dist/features/example-responses/ExampleResponses.vue3.js +4 -0
- package/dist/features/info-object/License.vue.d.ts.map +1 -1
- package/dist/features/info-object/License.vue.js +18 -15
- package/dist/features/sidebar/components/Sidebar.vue.js +3 -3
- package/dist/features/sidebar/components/Sidebar.vue3.js +4 -0
- package/dist/features/sidebar/components/SidebarElement.vue.js +3 -3
- package/dist/features/sidebar/components/SidebarElement.vue3.js +4 -0
- package/dist/features/sidebar/components/SidebarGroup.vue.js +1 -1
- package/dist/features/sidebar/components/SidebarGroup.vue3.js +4 -0
- package/dist/features/sidebar/components/SidebarHttpBadge.vue.js +1 -1
- package/dist/features/sidebar/components/SidebarHttpBadge.vue3.js +4 -0
- package/dist/features/sidebar/helpers/create-sidebar.js +12 -12
- package/dist/features/test-request-button/TestRequestButton.vue.js +1 -1
- package/dist/features/test-request-button/TestRequestButton.vue3.js +4 -0
- package/dist/features/traverse-schema/helpers/traverse-paths.d.ts +3 -1
- package/dist/features/traverse-schema/helpers/traverse-paths.d.ts.map +1 -1
- package/dist/features/traverse-schema/helpers/traverse-schemas.d.ts.map +1 -1
- package/dist/features/traverse-schema/helpers/traverse-schemas.js +18 -18
- package/dist/features/traverse-schema/helpers/traverse-tags.d.ts.map +1 -1
- package/dist/features/traverse-schema/helpers/traverse-webhooks.d.ts.map +1 -1
- package/dist/features/traverse-schema/index.d.ts +2 -1
- package/dist/features/traverse-schema/index.d.ts.map +1 -1
- package/dist/features/traverse-schema/types.d.ts +10 -6
- package/dist/features/traverse-schema/types.d.ts.map +1 -1
- package/dist/helpers/test-utils.d.ts +60 -0
- package/dist/helpers/test-utils.d.ts.map +1 -0
- package/dist/hooks/useNavState.d.ts +4 -1
- package/dist/hooks/useNavState.d.ts.map +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +24 -23
- package/dist/libs/openapi.d.ts +11 -8
- package/dist/libs/openapi.d.ts.map +1 -1
- package/dist/libs/openapi.js +34 -55
- package/dist/style.css +1 -1
- package/dist/types.d.ts +6 -6
- package/dist/types.d.ts.map +1 -1
- package/dist/v2/ApiReferenceWorkspace.vue.d.ts +1 -1
- package/dist/v2/ApiReferenceWorkspace.vue.d.ts.map +1 -1
- package/dist/v2/ApiReferenceWorkspace.vue.js +128 -129
- package/dist/v2/ApiReferenceWorkspace.vue2.js +4 -0
- package/dist/v2/ApiReferenceWorkspace.vue3.js +1 -1
- package/dist/v2/blocks/scalar-request-example-block/components/ExamplePicker.vue.d.ts +2 -2
- package/dist/v2/blocks/scalar-request-example-block/components/ExamplePicker.vue.d.ts.map +1 -1
- package/dist/v2/blocks/scalar-request-example-block/components/ExamplePicker.vue2.js +32 -29
- package/dist/v2/blocks/scalar-request-example-block/components/RequestExample.vue.d.ts +4 -13
- package/dist/v2/blocks/scalar-request-example-block/components/RequestExample.vue.d.ts.map +1 -1
- package/dist/v2/blocks/scalar-request-example-block/components/RequestExample.vue.js +3 -3
- package/dist/v2/blocks/scalar-request-example-block/components/RequestExample.vue2.js +185 -181
- package/dist/v2/blocks/scalar-request-example-block/components/RequestExample.vue3.js +4 -0
- package/dist/v2/blocks/scalar-request-example-block/helpers/find-client.d.ts +1 -0
- package/dist/v2/blocks/scalar-request-example-block/helpers/find-client.d.ts.map +1 -1
- package/dist/v2/blocks/scalar-request-example-block/helpers/find-client.js +1 -0
- package/dist/v2/blocks/scalar-request-example-block/helpers/generate-client-options.d.ts +12 -13
- package/dist/v2/blocks/scalar-request-example-block/helpers/generate-client-options.d.ts.map +1 -1
- package/dist/v2/blocks/scalar-request-example-block/helpers/generate-client-options.js +28 -30
- package/dist/v2/blocks/scalar-request-example-block/types.d.ts +11 -3
- package/dist/v2/blocks/scalar-request-example-block/types.d.ts.map +1 -1
- package/dist/v2/helpers/get-document-name.d.ts +13 -0
- package/dist/v2/helpers/get-document-name.d.ts.map +1 -0
- package/dist/v2/helpers/get-document-name.js +15 -0
- package/dist/v2/helpers/normalize-content.d.ts +3 -0
- package/dist/v2/helpers/normalize-content.d.ts.map +1 -0
- package/dist/v2/helpers/normalize-content.js +8 -0
- package/package.json +25 -19
- package/dist/components/Content/ClientLibraries/useFeaturedHttpClients.d.ts +0 -16
- package/dist/components/Content/ClientLibraries/useFeaturedHttpClients.d.ts.map +0 -1
- package/dist/components/Content/ClientLibraries/useFeaturedHttpClients.js +0 -36
- package/dist/components/Content/Lazy/Lazy.vue.d.ts.map +0 -1
- package/dist/components/Content/Lazy/Lazy.vue2.js +0 -22
- package/dist/components/Content/Lazy/Loading.vue.d.ts +0 -18
- package/dist/components/Content/Lazy/Loading.vue.d.ts.map +0 -1
- package/dist/components/Content/Lazy/Loading.vue.js +0 -163
- package/dist/components/Content/Lazy/Loading.vue3.js +0 -5
- package/dist/components/Content/Lazy/index.d.ts +0 -3
- package/dist/components/Content/Lazy/index.d.ts.map +0 -1
- package/dist/components/Content/Lazy/lazyBus.d.ts +0 -4
- package/dist/components/Content/Lazy/lazyBus.d.ts.map +0 -1
- package/dist/components/Content/Lazy/lazyBus.js +0 -5
- package/dist/components/Content/Models/ModelsAccordion.vue.d.ts.map +0 -1
- package/dist/components/Content/Models/ModelsAccordion.vue.js +0 -7
- package/dist/components/Content/Tag/OperationsList.vue.d.ts.map +0 -1
- package/dist/components/Content/Tag/OperationsList.vue.js +0 -7
- package/dist/components/Content/Tag/OperationsList.vue2.js +0 -58
- package/dist/components/Content/Tag/OperationsListItem.vue.d.ts.map +0 -1
- package/dist/components/Content/Tag/OperationsListItem.vue.js +0 -7
- package/dist/components/Content/Tag/OperationsListItem.vue2.js +0 -67
- package/dist/components/Content/Tag/Tag.vue.d.ts.map +0 -1
- package/dist/components/Content/Tag/Tag.vue.js +0 -99
- package/dist/components/Content/Tag/TagAccordion.vue.d.ts.map +0 -1
- package/dist/components/Content/Tag/TagAccordion.vue.js +0 -7
- package/dist/components/Content/Tag/TagAccordion.vue2.js +0 -50
- package/dist/components/Content/Tag/TagList.vue.d.ts +0 -22
- package/dist/components/Content/Tag/TagList.vue.d.ts.map +0 -1
- package/dist/components/Content/Tag/TagList.vue.js +0 -73
- package/dist/components/Content/Tag/TagList.vue2.js +0 -4
- package/dist/components/Content/Tag/TagSection.vue.d.ts.map +0 -1
- package/dist/components/Content/Tag/TagSection.vue.js +0 -7
- package/dist/components/Content/Tag/TagSection.vue2.js +0 -67
- package/dist/components/Content/Tag/index.d.ts +0 -3
- package/dist/components/Content/Tag/index.d.ts.map +0 -1
- package/dist/features/Search/SearchButton.vue.d.ts.map +0 -1
- package/dist/features/Search/SearchButton.vue.js +0 -66
- package/dist/features/Search/SearchModal.vue.d.ts.map +0 -1
- package/dist/features/Search/SearchModal.vue.js +0 -7
- package/dist/features/Search/SearchModal.vue2.js +0 -207
- package/dist/features/Search/useSearchIndex.d.ts +0 -32
- package/dist/features/Search/useSearchIndex.d.ts.map +0 -1
- package/dist/features/Search/useSearchIndex.js +0 -170
- package/dist/helpers/parse.d.ts +0 -10
- package/dist/helpers/parse.d.ts.map +0 -1
- package/dist/helpers/parse.js +0 -81
- package/dist/stores/useHttpClientStore.d.ts +0 -43
- package/dist/stores/useHttpClientStore.d.ts.map +0 -1
- package/dist/stores/useHttpClientStore.js +0 -70
- package/dist/v2/hooks/useStore.d.ts +0 -9
- package/dist/v2/hooks/useStore.d.ts.map +0 -1
- package/dist/v2/hooks/useStore.js +0 -14
- /package/dist/components/Content/{Tag → Tags}/Tag.vue2.js +0 -0
- /package/dist/components/{Content/Lazy → Lazy}/Lazy.vue.js +0 -0
- /package/dist/features/Search/{SearchButton.vue2.js → components/SearchButton.vue2.js} +0 -0
package/dist/types.d.ts
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import type { AnyApiReferenceConfiguration, ApiReferenceConfiguration } from '@scalar/types/api-reference';
|
|
2
|
-
import type { OpenAPIV3_1
|
|
2
|
+
import type { OpenAPIV3_1 } from '@scalar/types/legacy';
|
|
3
|
+
import type { WorkspaceStore } from '@scalar/workspace-store/client';
|
|
3
4
|
export type { ApiReferenceConfiguration };
|
|
4
5
|
export type ReferenceProps = {
|
|
5
6
|
configuration?: AnyApiReferenceConfiguration;
|
|
@@ -28,14 +29,14 @@ export type ReferenceLayoutProps = {
|
|
|
28
29
|
*/
|
|
29
30
|
originalDocument?: string;
|
|
30
31
|
isDark: boolean;
|
|
31
|
-
/**
|
|
32
|
-
* @deprecated We can't use this anymore. Use `dereferencedDocument` instead.
|
|
33
|
-
*/
|
|
34
|
-
parsedSpec?: Spec;
|
|
35
32
|
/**
|
|
36
33
|
* @deprecated Use `originalDocument` instead.
|
|
37
34
|
*/
|
|
38
35
|
rawSpec?: string;
|
|
36
|
+
/**
|
|
37
|
+
* @deprecated this is just temporary until we switch to the new store, we prop drill it down
|
|
38
|
+
*/
|
|
39
|
+
store: WorkspaceStore;
|
|
39
40
|
};
|
|
40
41
|
export type GettingStartedExamples = 'Petstore' | 'CoinMarketCap';
|
|
41
42
|
export type ContentProperties = {
|
|
@@ -65,7 +66,6 @@ export type DocumentSelectorSlot = {
|
|
|
65
66
|
'document-selector': any;
|
|
66
67
|
};
|
|
67
68
|
export type ReferenceSlotProps = {
|
|
68
|
-
spec: Spec;
|
|
69
69
|
breadcrumb: string;
|
|
70
70
|
};
|
|
71
71
|
//# sourceMappingURL=types.d.ts.map
|
package/dist/types.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,4BAA4B,EAAE,yBAAyB,EAAE,MAAM,6BAA6B,CAAA;AAC1G,OAAO,KAAK,EAAE,WAAW,EAAE,
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,4BAA4B,EAAE,yBAAyB,EAAE,MAAM,6BAA6B,CAAA;AAC1G,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,sBAAsB,CAAA;AACvD,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,gCAAgC,CAAA;AAEpE,YAAY,EAAE,yBAAyB,EAAE,CAAA;AAEzC,MAAM,MAAM,cAAc,GAAG;IAC3B,aAAa,CAAC,EAAE,4BAA4B,CAAA;CAC7C,CAAA;AAED;;GAEG;AACH,MAAM,MAAM,oBAAoB,GAAG;IACjC,aAAa,EAAE,OAAO,CAAC,yBAAyB,CAAC,CAAA;IACjD;;;;;;;;;;;;OAYG;IACH,oBAAoB,CAAC,EAAE,WAAW,CAAC,QAAQ,CAAA;IAC3C;;OAEG;IACH,gBAAgB,CAAC,EAAE,MAAM,CAAA;IACzB,MAAM,EAAE,OAAO,CAAA;IACf;;OAEG;IACH,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB;;OAEG;IACH,KAAK,EAAE,cAAc,CAAA;CACtB,CAAA;AAED,MAAM,MAAM,sBAAsB,GAAG,UAAU,GAAG,eAAe,CAAA;AAEjE,MAAM,MAAM,iBAAiB,GAAG;IAC9B,CAAC,GAAG,EAAE,MAAM,GAAG;QACb,IAAI,EAAE,MAAM,CAAA;QACZ,MAAM,CAAC,EAAE,MAAM,CAAA;QACf,OAAO,CAAC,EAAE,GAAG,CAAA;QACb,QAAQ,CAAC,EAAE,MAAM,EAAE,CAAA;QACnB,IAAI,CAAC,EAAE,MAAM,EAAE,CAAA;QACf,WAAW,CAAC,EAAE,MAAM,CAAA;QACpB,UAAU,CAAC,EAAE,iBAAiB,CAAA;KAC/B,CAAA;CACF,CAAA;AAED,MAAM,MAAM,aAAa,GAAG;IAC1B,MAAM,CAAC,EAAE;QACP,IAAI,EAAE,MAAM,CAAA;QACZ,QAAQ,CAAC,EAAE,MAAM,EAAE,CAAA;QACnB,UAAU,EAAE,iBAAiB,CAAA;KAC9B,CAAA;CACF,CAAA;AACD,2DAA2D;AAC3D,MAAM,MAAM,mBAAmB,GAC3B,QAAQ,GACR,QAAQ,GACR,QAAQ,GACR,eAAe,GACf,aAAa,GACb,eAAe,GACf,aAAa,CAAA;AAEjB,MAAM,MAAM,oBAAoB,GAAG;KAChC,CAAC,IAAI,mBAAmB,GAAG,CAAC,KAAK,EAAE,kBAAkB,KAAK,GAAG;CAC/D,CAAA;AAED,MAAM,MAAM,oBAAoB,GAAG;IACjC,mBAAmB,EAAE,GAAG,CAAA;CACzB,CAAA;AAED,MAAM,MAAM,kBAAkB,GAAG;IAC/B,UAAU,EAAE,MAAM,CAAA;CACnB,CAAA"}
|
|
@@ -2,7 +2,7 @@ import type { AnyApiReferenceConfiguration } from '@scalar/types';
|
|
|
2
2
|
import { type WorkspaceStore } from '@scalar/workspace-store/client';
|
|
3
3
|
type __VLS_Props = {
|
|
4
4
|
configuration?: AnyApiReferenceConfiguration;
|
|
5
|
-
|
|
5
|
+
store: WorkspaceStore;
|
|
6
6
|
};
|
|
7
7
|
declare function __VLS_template(): {
|
|
8
8
|
attrs: Partial<{}>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ApiReferenceWorkspace.vue.d.ts","sourceRoot":"","sources":["../../src/v2/ApiReferenceWorkspace.vue"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"ApiReferenceWorkspace.vue.d.ts","sourceRoot":"","sources":["../../src/v2/ApiReferenceWorkspace.vue"],"names":[],"mappings":"AAmVA,OAAO,KAAK,EACV,4BAA4B,EAE7B,MAAM,eAAe,CAAA;AAEtB,OAAO,EAAE,KAAK,cAAc,EAAE,MAAM,gCAAgC,CAAA;AA2BpE,KAAK,WAAW,GAAG;IACjB,aAAa,CAAC,EAAE,4BAA4B,CAAA;IAC5C,KAAK,EAAE,cAAc,CAAA;CACtB,CAAC;AA+NF,iBAAS,cAAc;WA8GT,OAAO,IAA6B;;wBAXrB,GAAG;wBACH,GAAG;iCACM,GAAG;;;;;;EAcxC;AAgBD,KAAK,oBAAoB,GAAG,UAAU,CAAC,OAAO,cAAc,CAAC,CAAC;AAC9D,QAAA,MAAM,eAAe,kSAMnB,CAAC;wBACkB,uBAAuB,CAAC,OAAO,eAAe,EAAE,oBAAoB,CAAC,OAAO,CAAC,CAAC;AAAnG,wBAAoG;AAWpG,KAAK,uBAAuB,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IACxC,QAAO;QACN,MAAM,EAAE,CAAC,CAAC;KAEV,CAAA;CACD,CAAC"}
|
|
@@ -1,170 +1,169 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import { safeLocalStorage as
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import
|
|
8
|
-
import {
|
|
9
|
-
import
|
|
10
|
-
import {
|
|
11
|
-
import {
|
|
12
|
-
import {
|
|
13
|
-
import {
|
|
14
|
-
import
|
|
15
|
-
|
|
1
|
+
import { defineComponent as R, ref as c, toRef as _, provide as $, useTemplateRef as w, onBeforeMount as V, watch as u, computed as A, createElementBlock as B, openBlock as D, createBlock as P, createCommentVNode as U, createVNode as E, unref as n, resolveDynamicComponent as K, withCtx as s, createTextVNode as F, toDisplayString as O, renderSlot as p, isRef as Y } from "vue";
|
|
2
|
+
import { safeLocalStorage as x, REFERENCE_LS_KEYS as g } from "@scalar/helpers/object/local-storage";
|
|
3
|
+
import { makeUrlAbsolute as z } from "@scalar/helpers/url/make-url-absolute";
|
|
4
|
+
import { redirectToProxy as H } from "@scalar/oas-utils/helpers";
|
|
5
|
+
import { useColorMode as W } from "@scalar/use-hooks/useColorMode";
|
|
6
|
+
import { deepClone as j } from "@scalar/workspace-store/helpers/general";
|
|
7
|
+
import { useSeoMeta as q } from "@unhead/vue";
|
|
8
|
+
import { useFavicon as G } from "@vueuse/core";
|
|
9
|
+
import J from "../components/ApiReferenceLayout.vue.js";
|
|
10
|
+
import { NAV_STATE_SYMBOL as Q } from "../hooks/useNavState.js";
|
|
11
|
+
import { isClient as M } from "./blocks/scalar-request-example-block/helpers/find-client.js";
|
|
12
|
+
import { getDocumentName as X } from "./helpers/get-document-name.js";
|
|
13
|
+
import { normalizeContent as Z } from "./helpers/normalize-content.js";
|
|
14
|
+
import { useMultipleDocuments as ee } from "../features/multiple-documents/useMultipleDocuments.js";
|
|
15
|
+
import { onCustomEvent as f } from "./events/listeners.js";
|
|
16
|
+
import te from "../features/multiple-documents/DocumentSelector.vue.js";
|
|
17
|
+
const De = /* @__PURE__ */ R({
|
|
16
18
|
__name: "ApiReferenceWorkspace",
|
|
17
19
|
props: {
|
|
18
20
|
configuration: {},
|
|
19
|
-
|
|
21
|
+
store: {}
|
|
20
22
|
},
|
|
21
|
-
setup(
|
|
22
|
-
const
|
|
23
|
-
availableDocuments:
|
|
24
|
-
selectedConfiguration:
|
|
25
|
-
selectedDocumentIndex:
|
|
26
|
-
isIntersectionEnabled:
|
|
27
|
-
hash:
|
|
28
|
-
hashPrefix:
|
|
29
|
-
} =
|
|
30
|
-
configuration:
|
|
31
|
-
isIntersectionEnabled:
|
|
32
|
-
hash:
|
|
33
|
-
hashPrefix:
|
|
34
|
-
}),
|
|
35
|
-
|
|
23
|
+
setup(y) {
|
|
24
|
+
const v = y, {
|
|
25
|
+
availableDocuments: C,
|
|
26
|
+
selectedConfiguration: o,
|
|
27
|
+
selectedDocumentIndex: i,
|
|
28
|
+
isIntersectionEnabled: m,
|
|
29
|
+
hash: S,
|
|
30
|
+
hashPrefix: T
|
|
31
|
+
} = ee({
|
|
32
|
+
configuration: _(v, "configuration"),
|
|
33
|
+
isIntersectionEnabled: c(!1),
|
|
34
|
+
hash: c(""),
|
|
35
|
+
hashPrefix: c("")
|
|
36
|
+
}), h = (e, t) => fetch(
|
|
37
|
+
H(o.value.proxyUrl, e.toString()),
|
|
36
38
|
t
|
|
37
39
|
);
|
|
38
|
-
|
|
39
|
-
const
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
if (o.workspace.documents[e.slug ?? "default"] === void 0) {
|
|
43
|
-
if (e.content) {
|
|
44
|
-
const t = typeof e.content == "string" ? q(e.content) : e.content;
|
|
45
|
-
return o.addDocumentSync({
|
|
46
|
-
name: e.slug ?? "default",
|
|
47
|
-
document: typeof t == "function" ? t() : t
|
|
48
|
-
});
|
|
49
|
-
}
|
|
50
|
-
if (e.url)
|
|
51
|
-
return o.addDocument({
|
|
52
|
-
name: e.slug ?? "default",
|
|
53
|
-
url: e.url,
|
|
54
|
-
fetch: K
|
|
55
|
-
});
|
|
56
|
-
}
|
|
57
|
-
};
|
|
58
|
-
f.value.forEach((e) => {
|
|
59
|
-
e.content && m(e);
|
|
60
|
-
}), V(() => {
|
|
61
|
-
f.value.forEach((e) => {
|
|
62
|
-
e.url && m(e);
|
|
63
|
-
});
|
|
64
|
-
}), F(() => {
|
|
65
|
-
f.value.forEach((t) => {
|
|
66
|
-
t.url && m(t);
|
|
67
|
-
});
|
|
68
|
-
const e = S().getItem(
|
|
40
|
+
$(Q, { isIntersectionEnabled: m, hash: S, hashPrefix: T });
|
|
41
|
+
const d = w("root"), a = v.store;
|
|
42
|
+
V(() => {
|
|
43
|
+
const e = x().getItem(
|
|
69
44
|
g.SELECTED_CLIENT
|
|
70
45
|
);
|
|
71
|
-
|
|
72
|
-
})
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
x({
|
|
80
|
-
targetKey: t,
|
|
81
|
-
clientKey: r
|
|
46
|
+
M(e) && !a.workspace["x-scalar-default-client"] && a.update("x-scalar-default-client", e);
|
|
47
|
+
});
|
|
48
|
+
const k = async (e) => {
|
|
49
|
+
var l;
|
|
50
|
+
const t = Z(e.content), r = X({
|
|
51
|
+
name: e.slug || e.title,
|
|
52
|
+
url: e.url,
|
|
53
|
+
document: t
|
|
82
54
|
});
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
55
|
+
if (a.workspace.documents[r]) {
|
|
56
|
+
if (t) {
|
|
57
|
+
m.value = !1;
|
|
58
|
+
const N = j(t);
|
|
59
|
+
a.replaceDocument(r, N), a.update("x-scalar-active-document", r), setTimeout(() => {
|
|
60
|
+
m.value = !0;
|
|
61
|
+
}, 300);
|
|
62
|
+
}
|
|
63
|
+
return;
|
|
64
|
+
}
|
|
65
|
+
if (t)
|
|
66
|
+
return await a.addDocument({
|
|
67
|
+
name: r,
|
|
68
|
+
document: t
|
|
69
|
+
});
|
|
70
|
+
if (e.url)
|
|
71
|
+
return await a.addDocument({
|
|
72
|
+
name: e.slug ?? "default",
|
|
73
|
+
url: z(e.url, {
|
|
74
|
+
basePath: (l = o.value.pathRouting) == null ? void 0 : l.basePath
|
|
75
|
+
}),
|
|
76
|
+
fetch: h
|
|
77
|
+
});
|
|
78
|
+
};
|
|
79
|
+
u(
|
|
80
|
+
() => o.value.url,
|
|
81
|
+
(e) => e && k(o.value),
|
|
82
|
+
{ immediate: !0 }
|
|
83
|
+
), u(
|
|
84
|
+
() => o.value.content,
|
|
85
|
+
(e) => e && k(o.value),
|
|
86
|
+
{ immediate: !0, deep: !0 }
|
|
87
|
+
), f(d, "scalar-update-dark-mode", (e) => {
|
|
88
|
+
a.update("x-scalar-dark-mode", e.detail.value);
|
|
89
|
+
}), f(d, "scalar-update-active-document", (e) => {
|
|
90
|
+
a.update("x-scalar-active-document", e.detail.value);
|
|
91
|
+
}), f(d, "scalar-update-selected-client", (e) => {
|
|
92
|
+
a.update("x-scalar-default-client", e.detail), x().setItem(g.SELECTED_CLIENT, e.detail);
|
|
93
|
+
}), u(
|
|
94
|
+
() => o.value.defaultHttpClient,
|
|
92
95
|
(e) => {
|
|
93
96
|
if (e) {
|
|
94
|
-
const { targetKey: t, clientKey: r } = e,
|
|
95
|
-
|
|
97
|
+
const { targetKey: t, clientKey: r } = e, l = `${t}/${r}`;
|
|
98
|
+
M(l) && a.update("x-scalar-default-client", l);
|
|
96
99
|
}
|
|
97
100
|
},
|
|
98
101
|
{ immediate: !0 }
|
|
99
102
|
);
|
|
100
|
-
const { toggleColorMode:
|
|
101
|
-
initialColorMode:
|
|
102
|
-
overrideColorMode:
|
|
103
|
+
const { toggleColorMode: b, isDarkMode: I } = W({
|
|
104
|
+
initialColorMode: o.value.darkMode ? "dark" : void 0,
|
|
105
|
+
overrideColorMode: o.value.forceDarkModeState
|
|
103
106
|
});
|
|
104
|
-
|
|
105
|
-
() =>
|
|
106
|
-
(e) =>
|
|
107
|
-
),
|
|
108
|
-
() =>
|
|
109
|
-
(e) =>
|
|
107
|
+
u(
|
|
108
|
+
() => o.value.darkMode,
|
|
109
|
+
(e) => a.update("x-scalar-dark-mode", !!e)
|
|
110
|
+
), u(
|
|
111
|
+
() => I.value,
|
|
112
|
+
(e) => a.update("x-scalar-dark-mode", e),
|
|
110
113
|
{ immediate: !0 }
|
|
111
|
-
),
|
|
112
|
-
() =>
|
|
114
|
+
), u(
|
|
115
|
+
() => i.value,
|
|
113
116
|
(e) => {
|
|
114
117
|
var t;
|
|
115
|
-
return
|
|
118
|
+
return a.update(
|
|
116
119
|
"x-scalar-active-document",
|
|
117
|
-
(t =
|
|
120
|
+
(t = C.value[e]) == null ? void 0 : t.slug
|
|
118
121
|
);
|
|
119
122
|
},
|
|
120
123
|
{ immediate: !0 }
|
|
121
|
-
),
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
e.forEach(m);
|
|
125
|
-
}
|
|
126
|
-
), a.value.metaData && Q(a.value.metaData);
|
|
127
|
-
const _ = H(() => a.value.favicon);
|
|
128
|
-
return X(_), (e, t) => {
|
|
124
|
+
), o.value.metaData && q(o.value.metaData);
|
|
125
|
+
const L = A(() => o.value.favicon);
|
|
126
|
+
return G(L), (e, t) => {
|
|
129
127
|
var r;
|
|
130
|
-
return
|
|
128
|
+
return D(), B("div", {
|
|
131
129
|
ref_key: "root",
|
|
132
|
-
ref:
|
|
130
|
+
ref: d
|
|
133
131
|
}, [
|
|
134
|
-
(r =
|
|
135
|
-
default:
|
|
136
|
-
|
|
132
|
+
(r = n(o)) != null && r.customCss ? (D(), P(K("style"), { key: 0 }, {
|
|
133
|
+
default: s(() => [
|
|
134
|
+
F(O(n(o).customCss), 1)
|
|
137
135
|
]),
|
|
138
136
|
_: 1
|
|
139
|
-
})) :
|
|
140
|
-
|
|
141
|
-
configuration:
|
|
142
|
-
isDark: !!
|
|
143
|
-
|
|
144
|
-
|
|
137
|
+
})) : U("", !0),
|
|
138
|
+
E(J, {
|
|
139
|
+
configuration: n(o),
|
|
140
|
+
isDark: !!n(a).workspace["x-scalar-dark-mode"],
|
|
141
|
+
store: n(a),
|
|
142
|
+
onToggleDarkMode: t[1] || (t[1] = () => n(b)()),
|
|
143
|
+
onUpdateContent: t[2] || (t[2] = (l) => e.$emit("updateContent", l))
|
|
145
144
|
}, {
|
|
146
|
-
footer:
|
|
147
|
-
|
|
145
|
+
footer: s(() => [
|
|
146
|
+
p(e.$slots, "footer")
|
|
148
147
|
]),
|
|
149
|
-
"content-end":
|
|
150
|
-
|
|
148
|
+
"content-end": s(() => [
|
|
149
|
+
p(e.$slots, "footer")
|
|
151
150
|
]),
|
|
152
|
-
"document-selector":
|
|
153
|
-
|
|
154
|
-
modelValue:
|
|
155
|
-
"onUpdate:modelValue": t[0] || (t[0] = (
|
|
156
|
-
options:
|
|
151
|
+
"document-selector": s(() => [
|
|
152
|
+
E(n(te), {
|
|
153
|
+
modelValue: n(i),
|
|
154
|
+
"onUpdate:modelValue": t[0] || (t[0] = (l) => Y(i) ? i.value = l : null),
|
|
155
|
+
options: n(C)
|
|
157
156
|
}, null, 8, ["modelValue", "options"])
|
|
158
157
|
]),
|
|
159
|
-
"sidebar-start":
|
|
160
|
-
|
|
158
|
+
"sidebar-start": s(() => [
|
|
159
|
+
p(e.$slots, "sidebar-start")
|
|
161
160
|
]),
|
|
162
161
|
_: 3
|
|
163
|
-
}, 8, ["configuration", "isDark"])
|
|
162
|
+
}, 8, ["configuration", "isDark", "store"])
|
|
164
163
|
], 512);
|
|
165
164
|
};
|
|
166
165
|
}
|
|
167
166
|
});
|
|
168
167
|
export {
|
|
169
|
-
|
|
168
|
+
De as default
|
|
170
169
|
};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import type {
|
|
1
|
+
import type { MediaTypeObject } from '@scalar/workspace-store/schemas/v3.1/strict/media-header-encoding';
|
|
2
2
|
type __VLS_Props = {
|
|
3
|
-
examples:
|
|
3
|
+
examples: MediaTypeObject['examples'];
|
|
4
4
|
};
|
|
5
5
|
type __VLS_PublicProps = {
|
|
6
6
|
modelValue: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ExamplePicker.vue.d.ts","sourceRoot":"","sources":["../../../../../src/v2/blocks/scalar-request-example-block/components/ExamplePicker.vue"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"ExamplePicker.vue.d.ts","sourceRoot":"","sources":["../../../../../src/v2/blocks/scalar-request-example-block/components/ExamplePicker.vue"],"names":[],"mappings":"AAmFA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,mEAAmE,CAAA;AAIxG,KAAK,WAAW,GAAG;IACjB,QAAQ,EAAE,eAAe,CAAC,UAAU,CAAC,CAAA;CACtC,CAAC;AAwCF,KAAK,iBAAiB,GAAG;IACzB,UAAU,EAAE,MAAM,CAAC;CAClB,GAAG,WAAW,CAAC;;oBAjCO,MAAM,GAAG,IAAI;;;;;;;AAuLpC,wBASG"}
|
|
@@ -1,61 +1,64 @@
|
|
|
1
|
-
import { defineComponent as h, mergeModels as
|
|
2
|
-
import { ScalarDropdown as
|
|
1
|
+
import { defineComponent as h, mergeModels as w, useModel as _, createBlock as u, openBlock as c, unref as t, withCtx as r, createVNode as i, createElementVNode as m, toDisplayString as p, createElementBlock as g, Fragment as v, renderList as b, normalizeClass as C } from "vue";
|
|
2
|
+
import { ScalarDropdown as S, ScalarButton as k, ScalarDropdownItem as E, ScalarIcon as V } from "@scalar/components";
|
|
3
3
|
import { ScalarIconCaretDown as B } from "@scalar/icons";
|
|
4
|
-
const D = { class: "overflow-hidden text-ellipsis" },
|
|
4
|
+
const D = { class: "overflow-hidden text-ellipsis" }, N = /* @__PURE__ */ h({
|
|
5
5
|
__name: "ExamplePicker",
|
|
6
|
-
props: /* @__PURE__ */
|
|
6
|
+
props: /* @__PURE__ */ w({
|
|
7
7
|
examples: {}
|
|
8
8
|
}, {
|
|
9
|
-
modelValue: {
|
|
9
|
+
modelValue: {
|
|
10
|
+
required: !0
|
|
11
|
+
},
|
|
10
12
|
modelModifiers: {}
|
|
11
13
|
}),
|
|
12
14
|
emits: ["update:modelValue"],
|
|
13
|
-
setup(
|
|
14
|
-
const
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
const l = f.examples[e];
|
|
18
|
-
return (l == null ? void 0 : l.summary) ?? e;
|
|
15
|
+
setup(d, { expose: f }) {
|
|
16
|
+
const a = _(d, "modelValue"), o = (e) => {
|
|
17
|
+
var n, s;
|
|
18
|
+
return e ? ((s = (n = d.examples) == null ? void 0 : n[e]) == null ? void 0 : s.summary) ?? e : "Select an example";
|
|
19
19
|
}, x = (e) => {
|
|
20
20
|
a.value = e;
|
|
21
21
|
};
|
|
22
|
-
return
|
|
23
|
-
getLabel:
|
|
22
|
+
return f({
|
|
23
|
+
getLabel: o,
|
|
24
24
|
selectedExampleKey: a
|
|
25
|
-
}), (e,
|
|
26
|
-
items:
|
|
27
|
-
(
|
|
28
|
-
key:
|
|
29
|
-
onClick: (
|
|
25
|
+
}), (e, n) => (c(), u(t(S), { placement: "bottom-start" }, {
|
|
26
|
+
items: r(() => [
|
|
27
|
+
(c(!0), g(v, null, b(e.examples, (s, l) => (c(), u(t(E), {
|
|
28
|
+
key: l,
|
|
29
|
+
onClick: (z) => x(l)
|
|
30
30
|
}, {
|
|
31
|
-
default:
|
|
31
|
+
default: r(() => [
|
|
32
32
|
m("div", {
|
|
33
|
-
class:
|
|
33
|
+
class: C([
|
|
34
34
|
"flex h-4 w-4 items-center justify-center rounded-full p-[3px]",
|
|
35
|
-
a.value ===
|
|
35
|
+
a.value === l ? "bg-c-accent text-b-1" : "shadow-border text-transparent"
|
|
36
36
|
])
|
|
37
37
|
}, [
|
|
38
|
-
|
|
38
|
+
i(t(V), {
|
|
39
39
|
class: "size-2.5",
|
|
40
40
|
icon: "Checkmark",
|
|
41
41
|
thickness: "3"
|
|
42
42
|
})
|
|
43
43
|
], 2),
|
|
44
|
-
m("span", D,
|
|
44
|
+
m("span", D, p(o(l)), 1)
|
|
45
45
|
]),
|
|
46
46
|
_: 2
|
|
47
47
|
}, 1032, ["onClick"]))), 128))
|
|
48
48
|
]),
|
|
49
|
-
default:
|
|
50
|
-
|
|
49
|
+
default: r(() => [
|
|
50
|
+
i(t(k), {
|
|
51
51
|
"data-testid": "example-picker",
|
|
52
52
|
class: "text-c-2 hover:text-c-1 flex h-full w-fit gap-1.5 px-1.5 py-0.75 text-base font-normal",
|
|
53
53
|
fullWidth: "",
|
|
54
54
|
variant: "ghost"
|
|
55
55
|
}, {
|
|
56
|
-
default:
|
|
57
|
-
m("span", null,
|
|
58
|
-
|
|
56
|
+
default: r(() => [
|
|
57
|
+
m("span", null, p(o(a.value)), 1),
|
|
58
|
+
i(t(B), {
|
|
59
|
+
weight: "bold",
|
|
60
|
+
class: "ui-open:rotate-180 mt-0.25 size-3 transition-transform duration-100"
|
|
61
|
+
})
|
|
59
62
|
]),
|
|
60
63
|
_: 1
|
|
61
64
|
})
|
|
@@ -65,5 +68,5 @@ const D = { class: "overflow-hidden text-ellipsis" }, j = /* @__PURE__ */ h({
|
|
|
65
68
|
}
|
|
66
69
|
});
|
|
67
70
|
export {
|
|
68
|
-
|
|
71
|
+
N as default
|
|
69
72
|
};
|
|
@@ -4,20 +4,16 @@ import type { OperationObject } from '@scalar/workspace-store/schemas/v3.1/stric
|
|
|
4
4
|
import type { SecuritySchemeObject } from '@scalar/workspace-store/schemas/v3.1/strict/security-scheme';
|
|
5
5
|
import type { ServerObject } from '@scalar/workspace-store/schemas/v3.1/strict/server';
|
|
6
6
|
import { type Dereference } from '@scalar/workspace-store/schemas/v3.1/type-guard';
|
|
7
|
+
import type { ClientOptionGroup } from '../../../../v2/blocks/scalar-request-example-block/types';
|
|
7
8
|
export type RequestExampleProps = {
|
|
8
9
|
/**
|
|
9
|
-
* List of all
|
|
10
|
-
*
|
|
11
|
-
* For the complete list:
|
|
12
|
-
* @see https://github.com/scalar/scalar/blob/main/packages/types/src/snippetz/snippetz.ts#L8
|
|
13
|
-
*
|
|
14
|
-
* @defaults to all available clients + any included custom code examples
|
|
10
|
+
* List of all http clients formatted into option groups for the client selector
|
|
15
11
|
*/
|
|
16
|
-
|
|
12
|
+
clientOptions: ClientOptionGroup[];
|
|
17
13
|
/**
|
|
18
14
|
* Pre-selected client, this will determine which client is initially selected in the dropdown
|
|
19
15
|
*
|
|
20
|
-
* @defaults to
|
|
16
|
+
* @defaults to shell/curl or a custom sample if one is available
|
|
21
17
|
*/
|
|
22
18
|
selectedClient?: AvailableClients[number];
|
|
23
19
|
/**
|
|
@@ -59,11 +55,6 @@ export type RequestExampleProps = {
|
|
|
59
55
|
* A method to generate the label of the block, should return an html string
|
|
60
56
|
*/
|
|
61
57
|
generateLabel?: () => string;
|
|
62
|
-
/**
|
|
63
|
-
* Whether to hide the client selector
|
|
64
|
-
* @default false
|
|
65
|
-
*/
|
|
66
|
-
hideClientSelector?: boolean;
|
|
67
58
|
};
|
|
68
59
|
/**
|
|
69
60
|
* Request Example
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"RequestExample.vue.d.ts","sourceRoot":"","sources":["../../../../../src/v2/blocks/scalar-request-example-block/components/RequestExample.vue"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"RequestExample.vue.d.ts","sourceRoot":"","sources":["../../../../../src/v2/blocks/scalar-request-example-block/components/RequestExample.vue"],"names":[],"mappings":"AAuZA,OAAO,KAAK,EAAE,UAAU,IAAI,cAAc,EAAE,MAAM,mCAAmC,CAAA;AAGrF,OAAO,EAAE,KAAK,gBAAgB,EAAiB,MAAM,kBAAkB,CAAA;AAEvE,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,6DAA6D,CAAA;AAClG,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,6DAA6D,CAAA;AACvG,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,oDAAoD,CAAA;AACtF,OAAO,EAEL,KAAK,WAAW,EACjB,MAAM,iDAAiD,CAAA;AAQxD,OAAO,KAAK,EAEV,iBAAiB,EAClB,MAAM,gDAAgD,CAAA;AAOvD,MAAM,MAAM,mBAAmB,GAAG;IAChC;;OAEG;IACH,aAAa,EAAE,iBAAiB,EAAE,CAAA;IAClC;;;;OAIG;IACH,cAAc,CAAC,EAAE,gBAAgB,CAAC,MAAM,CAAC,CAAA;IACzC;;OAEG;IACH,cAAc,CAAC,EAAE,YAAY,GAAG,SAAS,CAAA;IACzC;;;;;OAKG;IACH,mBAAmB,CAAC,EAAE,MAAM,CAAA;IAC5B;;OAEG;IACH,eAAe,CAAC,EAAE,MAAM,CAAA;IACxB;;OAEG;IACH,eAAe,CAAC,EAAE,oBAAoB,EAAE,CAAA;IACxC;;OAEG;IACH,MAAM,EAAE,cAAc,CAAA;IACtB;;OAEG;IACH,IAAI,EAAE,MAAM,CAAA;IACZ;;OAEG;IACH,SAAS,EAAE,WAAW,CAAC,eAAe,CAAC,CAAA;IACvC;;OAEG;IACH,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB;;OAEG;IACH,aAAa,CAAC,EAAE,MAAM,MAAM,CAAA;CAC7B,CAAA;AAED;;;;;;;;GAQG;;YAmBO,MAAM,OAAO;YACb,MAAM,OAAO;;YADb,MAAM,OAAO;YACb,MAAM,OAAO;;AAnBvB,wBAicC;AAWD,KAAK,uBAAuB,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IACxC,QAAO;QACN,MAAM,EAAE,CAAC,CAAC;KAEV,CAAA;CACD,CAAC"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import o from "./RequestExample.vue2.js";
|
|
2
|
-
|
|
2
|
+
import "./RequestExample.vue3.js";
|
|
3
3
|
import t from "../../../../_virtual/_plugin-vue_export-helper.js";
|
|
4
|
-
const
|
|
4
|
+
const p = /* @__PURE__ */ t(o, [["__scopeId", "data-v-f42f9860"]]);
|
|
5
5
|
export {
|
|
6
|
-
|
|
6
|
+
p as default
|
|
7
7
|
};
|