@scalar/api-reference 1.31.7 → 1.31.9
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 +55 -0
- package/dist/browser/standalone.js +18613 -18470
- package/dist/browser/webpack-stats.json +1 -1
- package/dist/components/ApiReference.vue.d.ts.map +1 -1
- package/dist/components/ApiReference.vue.js +10 -30
- package/dist/components/ApiReferenceLayout.vue.d.ts.map +1 -1
- package/dist/components/ApiReferenceLayout.vue.js +2 -2
- package/dist/components/ApiReferenceLayout.vue2.js +240 -222
- package/dist/components/Content/Content.vue.d.ts +2 -0
- package/dist/components/Content/Content.vue.d.ts.map +1 -1
- package/dist/components/Content/Content.vue.js +2 -2
- package/dist/components/Content/Content.vue2.js +84 -74
- package/dist/components/Content/Introduction/Introduction.vue.d.ts +1 -3
- package/dist/components/Content/Introduction/Introduction.vue.d.ts.map +1 -1
- package/dist/components/Content/Introduction/Introduction.vue.js +2 -2
- package/dist/components/Content/Introduction/Introduction.vue2.js +93 -83
- package/dist/components/Content/Lazy/Loading.vue.d.ts.map +1 -1
- package/dist/components/Content/Lazy/Loading.vue.js +84 -86
- package/dist/components/Content/Models/Models.vue.js +1 -1
- package/dist/components/Content/Models/Models.vue2.js +4 -4
- package/dist/components/Content/Schema/Schema.vue.d.ts.map +1 -1
- package/dist/components/Content/Schema/Schema.vue.js +2 -2
- package/dist/components/Content/Schema/Schema.vue2.js +53 -53
- package/dist/components/Content/Schema/SchemaDiscriminator.vue.d.ts.map +1 -1
- package/dist/components/Content/Schema/SchemaDiscriminator.vue.js +1 -1
- package/dist/components/Content/Schema/SchemaProperty.vue.d.ts.map +1 -1
- package/dist/components/Content/Schema/SchemaProperty.vue.js +1 -1
- package/dist/components/Content/Schema/SchemaProperty.vue2.js +117 -112
- package/dist/components/Content/Schema/SchemaPropertyHeading.vue.d.ts.map +1 -1
- package/dist/components/Content/Schema/SchemaPropertyHeading.vue.js +2 -2
- package/dist/components/Content/Schema/SchemaPropertyHeading.vue2.js +161 -191
- package/dist/components/Content/Schema/helpers/schema-name.d.ts +13 -0
- package/dist/components/Content/Schema/helpers/schema-name.d.ts.map +1 -1
- package/dist/components/Content/Schema/helpers/schema-name.js +59 -13
- package/dist/components/Content/Tag/OperationsList.vue.d.ts.map +1 -1
- package/dist/components/Content/Tag/OperationsList.vue.js +1 -1
- package/dist/components/Content/Tag/OperationsList.vue2.js +22 -25
- package/dist/components/Content/Tag/OperationsListItem.vue.d.ts +2 -3
- package/dist/components/Content/Tag/OperationsListItem.vue.d.ts.map +1 -1
- package/dist/components/Content/Tag/OperationsListItem.vue.js +2 -2
- package/dist/components/Content/Tag/OperationsListItem.vue2.js +46 -47
- package/dist/components/Content/Tag/Tag.vue.d.ts.map +1 -1
- package/dist/components/Content/Tag/Tag.vue.js +45 -47
- package/dist/components/Content/Tag/TagList.vue.d.ts +2 -0
- package/dist/components/Content/Tag/TagList.vue.d.ts.map +1 -1
- package/dist/components/Content/Tag/TagList.vue.js +40 -41
- package/dist/components/Content/Tag/TagSection.vue.d.ts.map +1 -1
- package/dist/components/Content/Tag/TagSection.vue.js +2 -2
- package/dist/components/Content/Tag/TagSection.vue2.js +21 -21
- package/dist/components/HttpMethod/HttpMethod.vue.d.ts +16 -1
- package/dist/components/HttpMethod/HttpMethod.vue.d.ts.map +1 -1
- package/dist/components/HttpMethod/HttpMethod.vue.js +12 -11
- package/dist/components/MobileHeader.vue.d.ts +1 -8
- package/dist/components/MobileHeader.vue.d.ts.map +1 -1
- package/dist/components/MobileHeader.vue.js +1 -1
- package/dist/components/MobileHeader.vue2.js +19 -19
- package/dist/components/Section/Section.vue.js +2 -2
- package/dist/components/Section/Section.vue2.js +1 -1
- package/dist/components/ShowMoreButton.vue.js +2 -2
- package/dist/components/ShowMoreButton.vue2.js +1 -1
- package/dist/components/Sidebar/Sidebar.vue.d.ts +2 -4
- package/dist/components/Sidebar/Sidebar.vue.d.ts.map +1 -1
- package/dist/components/Sidebar/Sidebar.vue.js +1 -1
- package/dist/components/Sidebar/Sidebar.vue2.js +113 -159
- package/dist/components/Sidebar/SidebarElement.vue.d.ts +2 -11
- package/dist/components/Sidebar/SidebarElement.vue.d.ts.map +1 -1
- package/dist/components/Sidebar/SidebarElement.vue.js +2 -2
- package/dist/components/Sidebar/SidebarElement.vue2.js +85 -81
- package/dist/components/Sidebar/SidebarHttpBadge.vue.d.ts +16 -1
- package/dist/components/Sidebar/SidebarHttpBadge.vue.d.ts.map +1 -1
- package/dist/components/Sidebar/SidebarHttpBadge.vue.js +2 -2
- package/dist/components/Sidebar/SidebarHttpBadge.vue2.js +11 -5
- package/dist/features/ApiClientModal/ApiClientModal.vue.d.ts.map +1 -1
- package/dist/features/ApiClientModal/ApiClientModal.vue.js +54 -42
- package/dist/features/ApiClientModal/useApiClient.d.ts +74 -72
- package/dist/features/ApiClientModal/useApiClient.d.ts.map +1 -1
- package/dist/features/DocumentSource/hooks/useDocumentSource.d.ts +0 -2
- package/dist/features/DocumentSource/hooks/useDocumentSource.d.ts.map +1 -1
- package/dist/features/DocumentSource/hooks/useDocumentSource.js +40 -67
- package/dist/features/DownloadLink/DownloadLink.vue.js +1 -1
- package/dist/features/ExampleRequest/ExampleRequest.vue.d.ts +5 -5
- package/dist/features/ExampleRequest/ExampleRequest.vue.d.ts.map +1 -1
- package/dist/features/ExampleRequest/ExampleRequest.vue.js +1 -1
- package/dist/features/ExampleRequest/ExampleRequest.vue2.js +200 -179
- package/dist/features/Operation/Operation.vue.d.ts +0 -1
- package/dist/features/Operation/Operation.vue.d.ts.map +1 -1
- package/dist/features/Operation/Operation.vue.js +31 -34
- package/dist/features/Operation/components/OperationParameters.vue.d.ts +3 -2
- package/dist/features/Operation/components/OperationParameters.vue.d.ts.map +1 -1
- package/dist/features/Operation/components/OperationParameters.vue.js +62 -64
- package/dist/features/Operation/components/OperationResponses.vue.d.ts +1 -2
- package/dist/features/Operation/components/OperationResponses.vue.d.ts.map +1 -1
- package/dist/features/Operation/components/OperationResponses.vue.js +2 -2
- 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 +31 -38
- package/dist/features/Operation/hooks/useResponses.d.ts +3 -3
- package/dist/features/Operation/hooks/useResponses.d.ts.map +1 -1
- package/dist/features/Operation/hooks/useResponses.js +12 -13
- package/dist/features/Operation/index.d.ts +0 -1
- package/dist/features/Operation/index.d.ts.map +1 -1
- package/dist/features/Operation/layouts/ClassicLayout.vue.d.ts +4 -6
- 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 +85 -72
- package/dist/features/Operation/layouts/ModernLayout.vue.d.ts +2 -4
- package/dist/features/Operation/layouts/ModernLayout.vue.d.ts.map +1 -1
- package/dist/features/Operation/layouts/ModernLayout.vue.js +2 -2
- package/dist/features/Operation/layouts/ModernLayout.vue2.js +114 -98
- package/dist/features/Search/SearchModal.vue.js +2 -2
- package/dist/features/Search/SearchModal.vue2.js +1 -1
- package/dist/features/Search/useSearchIndex.d.ts.map +1 -1
- package/dist/features/Search/useSearchIndex.js +61 -64
- package/dist/features/sidebar/helpers/create-sidebar.d.ts +4 -2
- package/dist/features/sidebar/helpers/create-sidebar.d.ts.map +1 -1
- package/dist/features/sidebar/helpers/create-sidebar.js +33 -0
- package/dist/features/sidebar/hooks/useSidebar.d.ts +2 -3
- package/dist/features/sidebar/hooks/useSidebar.d.ts.map +1 -1
- package/dist/features/sidebar/hooks/useSidebar.js +18 -0
- package/dist/features/sidebar/index.d.ts +2 -1
- package/dist/features/sidebar/index.d.ts.map +1 -1
- package/dist/features/traverse-schema/helpers/get-tag.d.ts +4 -2
- package/dist/features/traverse-schema/helpers/get-tag.d.ts.map +1 -1
- package/dist/features/traverse-schema/helpers/get-tag.js +7 -0
- package/dist/features/traverse-schema/helpers/traverse-description.js +33 -0
- package/dist/features/traverse-schema/helpers/traverse-document.d.ts.map +1 -1
- package/dist/features/traverse-schema/helpers/traverse-document.js +34 -0
- package/dist/features/traverse-schema/helpers/traverse-paths.d.ts +5 -3
- package/dist/features/traverse-schema/helpers/traverse-paths.d.ts.map +1 -1
- package/dist/features/traverse-schema/helpers/traverse-paths.js +32 -0
- package/dist/features/traverse-schema/helpers/traverse-schemas.d.ts +2 -2
- package/dist/features/traverse-schema/helpers/traverse-schemas.d.ts.map +1 -1
- package/dist/features/traverse-schema/helpers/traverse-schemas.js +23 -0
- package/dist/features/traverse-schema/helpers/traverse-tags.d.ts +2 -2
- package/dist/features/traverse-schema/helpers/traverse-tags.d.ts.map +1 -1
- package/dist/features/traverse-schema/helpers/traverse-tags.js +43 -0
- package/dist/features/traverse-schema/helpers/traverse-webhooks.d.ts +2 -2
- package/dist/features/traverse-schema/helpers/traverse-webhooks.d.ts.map +1 -1
- package/dist/features/traverse-schema/helpers/traverse-webhooks.js +26 -0
- package/dist/features/traverse-schema/index.d.ts +3 -3
- package/dist/features/traverse-schema/index.d.ts.map +1 -1
- package/dist/features/traverse-schema/types.d.ts +8 -5
- package/dist/features/traverse-schema/types.d.ts.map +1 -1
- package/dist/helpers/parse.d.ts +2 -1
- package/dist/helpers/parse.d.ts.map +1 -1
- package/dist/helpers/parse.js +72 -88
- package/dist/hooks/useMultipleDocuments.d.ts +6 -6
- package/dist/hooks/useMultipleDocuments.d.ts.map +1 -1
- package/dist/hooks/useNavState.d.ts +1 -1
- package/dist/hooks/useNavState.d.ts.map +1 -1
- package/dist/hooks/useNavState.js +14 -9
- package/dist/hooks/useOperation.d.ts +7 -7
- package/dist/hooks/useOperation.d.ts.map +1 -1
- package/dist/hooks/useOperation.js +13 -12
- package/dist/index.d.ts +0 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +23 -25
- package/dist/legacy/fixtures/index.d.ts +1 -1
- package/dist/libs/openapi.d.ts +3 -4
- package/dist/libs/openapi.d.ts.map +1 -1
- package/dist/libs/openapi.js +8 -9
- package/dist/style.css +1 -1
- package/dist/v2/ApiReferenceWorkspace.vue.d.ts +4 -18
- package/dist/v2/ApiReferenceWorkspace.vue.d.ts.map +1 -1
- package/dist/v2/ApiReferenceWorkspace.vue.js +68 -45
- package/package.json +17 -17
- package/dist/components/Content/Webhooks/index.d.ts +0 -2
- package/dist/components/Content/Webhooks/index.d.ts.map +0 -1
- package/dist/features/Operation/Webhooks.vue.d.ts +0 -7
- package/dist/features/Operation/Webhooks.vue.d.ts.map +0 -1
- package/dist/features/Operation/Webhooks.vue.js +0 -7
- package/dist/features/Operation/Webhooks.vue2.js +0 -121
- package/dist/features/Operation/components/Webhook.vue.d.ts +0 -7
- package/dist/features/Operation/components/Webhook.vue.d.ts.map +0 -1
- package/dist/features/Operation/components/Webhook.vue.js +0 -7
- package/dist/features/Operation/components/Webhook.vue2.js +0 -29
- package/dist/features/traverse-schema/helpers/operation-id-params.d.ts +0 -8
- package/dist/features/traverse-schema/helpers/operation-id-params.d.ts.map +0 -1
- package/dist/features/traverse-schema/helpers/operation-id-params.js +0 -8
- package/dist/hooks/useSidebar.d.ts +0 -53
- package/dist/hooks/useSidebar.d.ts.map +0 -1
- package/dist/hooks/useSidebar.js +0 -248
- package/dist/legacy/fixtures/httpRequestMethods.js +0 -14
|
@@ -1,41 +1,43 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import { provideUseId as
|
|
3
|
-
import { OpenApiClientButton as
|
|
4
|
-
import { LAYOUT_SYMBOL as
|
|
5
|
-
import { WORKSPACE_SYMBOL as
|
|
6
|
-
import { addScalarClassesToHeadless as
|
|
7
|
-
import { sleep as
|
|
8
|
-
import { hasObtrusiveScrollbars as
|
|
9
|
-
import { apiReferenceConfigurationSchema as
|
|
10
|
-
import { useBreakpoints as
|
|
11
|
-
import { useToasts as
|
|
12
|
-
import { useMediaQuery as
|
|
13
|
-
import
|
|
14
|
-
import
|
|
15
|
-
import
|
|
16
|
-
import {
|
|
17
|
-
import {
|
|
18
|
-
import {
|
|
19
|
-
import { downloadEventBus as
|
|
20
|
-
import {
|
|
21
|
-
import {
|
|
22
|
-
import {
|
|
23
|
-
import {
|
|
24
|
-
import {
|
|
25
|
-
import
|
|
26
|
-
import
|
|
27
|
-
import
|
|
28
|
-
import
|
|
29
|
-
|
|
1
|
+
import { defineComponent as ve, computed as T, provide as y, ref as D, onBeforeMount as ge, onMounted as Y, watch as E, toValue as K, onUnmounted as he, useId as Se, createElementBlock as m, openBlock as a, Fragment as z, createElementVNode as v, createVNode as f, normalizeStyle as ye, normalizeClass as be, unref as r, createCommentVNode as s, withDirectives as we, createBlock as b, renderSlot as u, normalizeProps as g, guardReactiveProps as h, withCtx as l, vShow as ke, createSlots as Ce } from "vue";
|
|
2
|
+
import { provideUseId as $e } from "@headlessui/vue";
|
|
3
|
+
import { OpenApiClientButton as Te } from "@scalar/api-client/components";
|
|
4
|
+
import { LAYOUT_SYMBOL as De } from "@scalar/api-client/hooks";
|
|
5
|
+
import { WORKSPACE_SYMBOL as Ee, ACTIVE_ENTITIES_SYMBOL as Me } from "@scalar/api-client/store";
|
|
6
|
+
import { addScalarClassesToHeadless as Oe, ScalarErrorBoundary as Be, ScalarSidebarFooter as Ie, ScalarColorModeToggleButton as Re, ScalarColorModeToggleIcon as Le } from "@scalar/components";
|
|
7
|
+
import { sleep as He } from "@scalar/helpers/testing/sleep";
|
|
8
|
+
import { hasObtrusiveScrollbars as Ae, getThemeStyles as Pe } from "@scalar/themes";
|
|
9
|
+
import { apiReferenceConfigurationSchema as _e } from "@scalar/types/api-reference";
|
|
10
|
+
import { useBreakpoints as Fe } from "@scalar/use-hooks/useBreakpoints";
|
|
11
|
+
import { useToasts as Ne, ScalarToasts as Ve } from "@scalar/use-toasts";
|
|
12
|
+
import { useMediaQuery as Ue, useResizeObserver as Ye, useDebounceFn as Ke } from "@vueuse/core";
|
|
13
|
+
import ze from "./ClassicHeader.vue.js";
|
|
14
|
+
import Ge from "./GettingStarted.vue.js";
|
|
15
|
+
import Qe from "./MobileHeader.vue.js";
|
|
16
|
+
import { parse as We } from "../helpers/parse.js";
|
|
17
|
+
import { CONFIGURATION_SYMBOL as je } from "../hooks/useConfig.js";
|
|
18
|
+
import { useNavState as qe } from "../hooks/useNavState.js";
|
|
19
|
+
import { downloadEventBus as G, downloadDocument as Je } from "../libs/download.js";
|
|
20
|
+
import { createEmptySpecification as Xe } from "../libs/openapi.js";
|
|
21
|
+
import { useHttpClientStore as Ze } from "../stores/useHttpClientStore.js";
|
|
22
|
+
import { useDocumentSource as xe } from "../features/DocumentSource/hooks/useDocumentSource.js";
|
|
23
|
+
import { OPENAPI_VERSION_SYMBOL as et } from "../features/DownloadLink/openapi-version-symbol.js";
|
|
24
|
+
import { useSidebar as tt } from "../features/sidebar/hooks/useSidebar.js";
|
|
25
|
+
import { PLUGIN_MANAGER_SYMBOL as ot } from "../plugins/hooks/usePluginManager.js";
|
|
26
|
+
import { createPluginManager as rt } from "../plugins/plugin-manager.js";
|
|
27
|
+
import at from "./Sidebar/Sidebar.vue.js";
|
|
28
|
+
import Q from "../features/Search/SearchButton.vue.js";
|
|
29
|
+
import nt from "./Content/Content.vue.js";
|
|
30
|
+
import it from "../features/ApiClientModal/ApiClientModal.vue.js";
|
|
31
|
+
const st = ["innerHTML"], lt = { class: "references-header" }, ut = ["aria-label"], dt = { class: "references-navigation-list" }, ct = { key: 0 }, mt = {
|
|
30
32
|
key: 1,
|
|
31
33
|
class: "scalar-api-references-standalone-search"
|
|
32
|
-
},
|
|
34
|
+
}, ft = { key: 1 }, pt = { class: "references-editor" }, vt = { class: "references-editor-textarea" }, gt = ["aria-label"], ht = {
|
|
33
35
|
key: 0,
|
|
34
36
|
class: "w-64 empty:hidden"
|
|
35
|
-
},
|
|
37
|
+
}, St = {
|
|
36
38
|
key: 0,
|
|
37
39
|
class: "references-footer"
|
|
38
|
-
},
|
|
40
|
+
}, qt = /* @__PURE__ */ ve({
|
|
39
41
|
inheritAttrs: !1,
|
|
40
42
|
__name: "ApiReferenceLayout",
|
|
41
43
|
props: {
|
|
@@ -47,285 +49,301 @@ const tt = ["innerHTML"], ot = { class: "references-header" }, at = ["aria-label
|
|
|
47
49
|
rawSpec: {}
|
|
48
50
|
},
|
|
49
51
|
emits: ["changeTheme", "updateContent", "loadSwaggerFile", "linkSwaggerFile", "toggleDarkMode"],
|
|
50
|
-
setup(
|
|
52
|
+
setup(M) {
|
|
51
53
|
const t = T(
|
|
52
|
-
() =>
|
|
53
|
-
), { initializeToasts:
|
|
54
|
-
|
|
54
|
+
() => _e.parse(M.configuration)
|
|
55
|
+
), { initializeToasts: W, toast: j } = Ne();
|
|
56
|
+
W((e) => j(e));
|
|
55
57
|
const {
|
|
56
|
-
originalDocument:
|
|
57
|
-
originalOpenApiVersion:
|
|
58
|
-
dereferencedDocument:
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
} = je({
|
|
58
|
+
originalDocument: q,
|
|
59
|
+
originalOpenApiVersion: J,
|
|
60
|
+
dereferencedDocument: d,
|
|
61
|
+
workspaceStore: X,
|
|
62
|
+
activeEntitiesStore: Z
|
|
63
|
+
} = xe({
|
|
63
64
|
configuration: t,
|
|
64
|
-
dereferencedDocument:
|
|
65
|
-
originalDocument:
|
|
65
|
+
dereferencedDocument: M.dereferencedDocument,
|
|
66
|
+
originalDocument: M.originalDocument
|
|
66
67
|
});
|
|
67
|
-
|
|
68
|
-
const
|
|
69
|
-
|
|
70
|
-
|
|
68
|
+
y(et, J), y(Ee, X), y(Me, Z);
|
|
69
|
+
const x = Ue("(min-width: 1150px)"), ee = D("100dvh"), w = D(null);
|
|
70
|
+
Ye(w, (e) => {
|
|
71
|
+
ee.value = e[0].contentRect.height + "px";
|
|
71
72
|
});
|
|
72
|
-
const
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
hash: ae,
|
|
86
|
-
isIntersectionEnabled: B,
|
|
87
|
-
updateHash: R,
|
|
88
|
-
replaceUrlState: re
|
|
89
|
-
} = ze(t);
|
|
73
|
+
const te = T(Ae), R = qe(t), { isSidebarOpen: O, setCollapsedSidebarItem: L, scrollToOperation: oe, items: re } = tt(d, {
|
|
74
|
+
...R,
|
|
75
|
+
config: t
|
|
76
|
+
}), {
|
|
77
|
+
getReferenceId: ae,
|
|
78
|
+
getPathRoutingId: ne,
|
|
79
|
+
getSectionId: ie,
|
|
80
|
+
getTagId: se,
|
|
81
|
+
hash: B,
|
|
82
|
+
isIntersectionEnabled: H,
|
|
83
|
+
updateHash: A,
|
|
84
|
+
replaceUrlState: le
|
|
85
|
+
} = R;
|
|
90
86
|
if (t.value.redirect && typeof window < "u") {
|
|
91
87
|
const e = t.value.redirect(
|
|
92
88
|
(t.value.pathRouting ? window.location.pathname : "") + window.location.hash
|
|
93
89
|
);
|
|
94
90
|
e && history.replaceState({}, "", e);
|
|
95
91
|
}
|
|
96
|
-
|
|
97
|
-
|
|
92
|
+
ge(() => {
|
|
93
|
+
A(), Oe();
|
|
94
|
+
});
|
|
95
|
+
const P = async (e) => {
|
|
98
96
|
var o;
|
|
99
|
-
|
|
100
|
-
},
|
|
101
|
-
|
|
102
|
-
var
|
|
97
|
+
H.value = !1, A(), e ? oe(e) : (o = w.value) == null || o.scrollTo(0, 0), await He(100), H.value = !0;
|
|
98
|
+
}, _ = D(0);
|
|
99
|
+
Y(() => {
|
|
100
|
+
var n, i, C;
|
|
103
101
|
history.scrollRestoration = "manual";
|
|
104
|
-
const e = (
|
|
102
|
+
const e = (i = (n = w.value) == null ? void 0 : n.parentElement) == null ? void 0 : i.getBoundingClientRect(), o = (C = w.value) == null ? void 0 : C.getBoundingClientRect();
|
|
105
103
|
if (e && o) {
|
|
106
|
-
const
|
|
107
|
-
|
|
104
|
+
const $ = o.top - e.top;
|
|
105
|
+
_.value = $ < 2 ? 0 : $;
|
|
108
106
|
}
|
|
109
107
|
window.onhashchange = () => {
|
|
110
|
-
|
|
111
|
-
}, window.onpopstate = () => t.value.pathRouting &&
|
|
108
|
+
P(ae());
|
|
109
|
+
}, window.onpopstate = () => t.value.pathRouting && P(ne(window.location.pathname)), window.addEventListener("scroll", F, { passive: !0 });
|
|
112
110
|
});
|
|
113
|
-
const
|
|
114
|
-
() =>
|
|
115
|
-
),
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
111
|
+
const ue = T(
|
|
112
|
+
() => x.value || !t.value.isEditable
|
|
113
|
+
), F = Ke(() => {
|
|
114
|
+
window.scrollY < 50 && le("");
|
|
115
|
+
}), N = D(!1);
|
|
116
|
+
E(d, (e) => {
|
|
117
|
+
var o, n;
|
|
118
|
+
if (!(N.value || !((o = e.tags) != null && o.length))) {
|
|
119
|
+
if (B.value) {
|
|
120
|
+
const i = ie(B.value);
|
|
121
|
+
i && L(i, !0);
|
|
122
|
+
} else {
|
|
123
|
+
const i = (n = e.tags) == null ? void 0 : n[0];
|
|
124
|
+
i && L(se(i), !0);
|
|
125
|
+
}
|
|
126
|
+
N.value = !0;
|
|
119
127
|
}
|
|
120
|
-
})
|
|
121
|
-
|
|
128
|
+
});
|
|
129
|
+
const k = D(Xe());
|
|
130
|
+
E(
|
|
131
|
+
d,
|
|
132
|
+
async (e) => {
|
|
133
|
+
if (!e)
|
|
134
|
+
return;
|
|
135
|
+
const o = await We(e, re.value.entries);
|
|
136
|
+
k.value = o;
|
|
137
|
+
},
|
|
138
|
+
{ immediate: !0 }
|
|
139
|
+
);
|
|
140
|
+
const p = T(() => ({
|
|
141
|
+
spec: k.value
|
|
122
142
|
}));
|
|
123
|
-
|
|
124
|
-
() =>
|
|
125
|
-
|
|
126
|
-
|
|
143
|
+
Y(
|
|
144
|
+
() => G.on(({ filename: e, format: o }) => {
|
|
145
|
+
Je(
|
|
146
|
+
K(q) || K(M.rawSpec) || "",
|
|
127
147
|
e,
|
|
128
148
|
o
|
|
129
149
|
);
|
|
130
150
|
})
|
|
131
|
-
),
|
|
132
|
-
|
|
133
|
-
|
|
151
|
+
), he(() => {
|
|
152
|
+
window.removeEventListener("scroll", F), G.reset();
|
|
153
|
+
}), $e(() => Se()), y(De, "modal"), y(je, t), y(
|
|
154
|
+
ot,
|
|
155
|
+
rt({
|
|
134
156
|
plugins: t.value.plugins
|
|
135
157
|
})
|
|
136
158
|
);
|
|
137
|
-
function
|
|
138
|
-
|
|
159
|
+
function V(e, o) {
|
|
160
|
+
E(
|
|
139
161
|
() => t.value[e],
|
|
140
|
-
(
|
|
141
|
-
typeof
|
|
162
|
+
(n) => {
|
|
163
|
+
typeof n < "u" && o(n);
|
|
142
164
|
},
|
|
143
165
|
{ immediate: !0 }
|
|
144
166
|
);
|
|
145
167
|
}
|
|
146
|
-
const { setExcludedClients:
|
|
147
|
-
|
|
148
|
-
const
|
|
168
|
+
const { setExcludedClients: de, setDefaultHttpClient: ce } = Ze();
|
|
169
|
+
V("defaultHttpClient", ce), V("hiddenClients", de);
|
|
170
|
+
const me = T(
|
|
149
171
|
() => `<style>
|
|
150
|
-
${
|
|
172
|
+
${Pe(t.value.theme, {
|
|
151
173
|
fonts: t.value.withDefaultFonts
|
|
152
174
|
})}</style>`
|
|
153
|
-
), { mediaQueries:
|
|
154
|
-
return
|
|
155
|
-
o && !e && (
|
|
156
|
-
}),
|
|
157
|
-
e && e !== o && (
|
|
175
|
+
), { mediaQueries: fe } = Fe(), pe = !1;
|
|
176
|
+
return E(fe.lg, (e, o) => {
|
|
177
|
+
o && !e && (O.value = !1);
|
|
178
|
+
}), E(B, (e, o) => {
|
|
179
|
+
e && e !== o && (O.value = !1);
|
|
158
180
|
}), (e, o) => {
|
|
159
|
-
var
|
|
160
|
-
return
|
|
161
|
-
|
|
162
|
-
|
|
181
|
+
var n, i, C, $, U;
|
|
182
|
+
return a(), m(z, null, [
|
|
183
|
+
v("div", { innerHTML: me.value }, null, 8, st),
|
|
184
|
+
v("div", {
|
|
163
185
|
ref_key: "documentEl",
|
|
164
|
-
ref:
|
|
165
|
-
class:
|
|
186
|
+
ref: w,
|
|
187
|
+
class: be(["scalar-app scalar-api-reference references-layout", [
|
|
166
188
|
{
|
|
167
189
|
"scalar-api-references-standalone-mobile": t.value.showSidebar ?? !0,
|
|
168
|
-
"scalar-scrollbars-obtrusive":
|
|
190
|
+
"scalar-scrollbars-obtrusive": te.value,
|
|
169
191
|
"references-editable": t.value.isEditable,
|
|
170
192
|
"references-sidebar": t.value.showSidebar,
|
|
171
|
-
"references-sidebar-mobile-open":
|
|
193
|
+
"references-sidebar-mobile-open": r(O),
|
|
172
194
|
"references-classic": t.value.layout === "classic"
|
|
173
195
|
},
|
|
174
196
|
e.$attrs.class
|
|
175
197
|
]]),
|
|
176
|
-
style:
|
|
177
|
-
"--scalar-y-offset": `var(--scalar-custom-header-height, ${
|
|
178
|
-
})
|
|
179
|
-
onScrollPassive: o[7] || (o[7] = //@ts-ignore
|
|
180
|
-
(...n) => a(P) && a(P)(...n))
|
|
198
|
+
style: ye({
|
|
199
|
+
"--scalar-y-offset": `var(--scalar-custom-header-height, ${_.value}px)`
|
|
200
|
+
})
|
|
181
201
|
}, [
|
|
182
|
-
|
|
183
|
-
t.value.layout === "modern" && (t.value.showSidebar ?? !0) ? (
|
|
184
|
-
|
|
185
|
-
open: a(g),
|
|
186
|
-
"onUpdate:open": o[0] || (o[0] = (n) => he(g) ? g.value = n : null)
|
|
187
|
-
}, null, 8, ["open"])) : l("", !0),
|
|
188
|
-
u(e.$slots, "header", f(v(m.value)), void 0, !0)
|
|
202
|
+
v("div", lt, [
|
|
203
|
+
t.value.layout === "modern" && (t.value.showSidebar ?? !0) ? (a(), b(Qe, { key: 0 })) : s("", !0),
|
|
204
|
+
u(e.$slots, "header", g(h(p.value)), void 0, !0)
|
|
189
205
|
]),
|
|
190
|
-
t.value.showSidebar ? (
|
|
206
|
+
t.value.showSidebar ? (a(), m("aside", {
|
|
191
207
|
key: 0,
|
|
192
|
-
"aria-label": `Sidebar for ${(
|
|
208
|
+
"aria-label": `Sidebar for ${(i = (n = r(d)) == null ? void 0 : n.info) == null ? void 0 : i.title}`,
|
|
193
209
|
class: "references-navigation t-doc__sidebar"
|
|
194
210
|
}, [
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
default:
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
211
|
+
v("div", dt, [
|
|
212
|
+
f(r(Be), null, {
|
|
213
|
+
default: l(() => {
|
|
214
|
+
var S, c;
|
|
215
|
+
return [
|
|
216
|
+
f(r(at), {
|
|
217
|
+
title: ((c = (S = r(d)) == null ? void 0 : S.info) == null ? void 0 : c.title) ?? "The OpenAPI Schema"
|
|
218
|
+
}, {
|
|
219
|
+
"sidebar-start": l(() => {
|
|
220
|
+
var I;
|
|
221
|
+
return [
|
|
222
|
+
e.$slots["document-selector"] ? (a(), m("div", ct, [
|
|
223
|
+
u(e.$slots, "document-selector", {}, void 0, !0)
|
|
224
|
+
])) : s("", !0),
|
|
225
|
+
t.value.hideSearch ? s("", !0) : (a(), m("div", mt, [
|
|
226
|
+
f(r(Q), {
|
|
227
|
+
searchHotKey: (I = t.value) == null ? void 0 : I.searchHotKey,
|
|
228
|
+
spec: k.value
|
|
229
|
+
}, null, 8, ["searchHotKey", "spec"])
|
|
230
|
+
])),
|
|
231
|
+
u(e.$slots, "sidebar-start", g(h(p.value)), void 0, !0)
|
|
232
|
+
];
|
|
233
|
+
}),
|
|
234
|
+
"sidebar-end": l(() => [
|
|
235
|
+
u(e.$slots, "sidebar-end", g(h(p.value)), () => [
|
|
236
|
+
f(r(Ie), { class: "darklight-reference" }, {
|
|
237
|
+
toggle: l(() => [
|
|
238
|
+
t.value.hideDarkModeToggle ? (a(), m("span", ft)) : (a(), b(r(Re), {
|
|
239
|
+
key: 0,
|
|
240
|
+
modelValue: e.isDark,
|
|
241
|
+
"onUpdate:modelValue": o[0] || (o[0] = (I) => e.$emit("toggleDarkMode"))
|
|
242
|
+
}, null, 8, ["modelValue"]))
|
|
243
|
+
]),
|
|
244
|
+
default: l(() => [
|
|
245
|
+
t.value.hideClientButton ? s("", !0) : (a(), b(r(Te), {
|
|
246
|
+
key: 0,
|
|
247
|
+
buttonSource: "sidebar",
|
|
248
|
+
integration: t.value._integration,
|
|
249
|
+
isDevelopment: pe,
|
|
250
|
+
url: t.value.url
|
|
251
|
+
}, null, 8, ["integration", "url"]))
|
|
252
|
+
]),
|
|
253
|
+
_: 1
|
|
254
|
+
})
|
|
255
|
+
], !0)
|
|
256
|
+
]),
|
|
257
|
+
_: 3
|
|
258
|
+
}, 8, ["title"])
|
|
259
|
+
];
|
|
260
|
+
}),
|
|
244
261
|
_: 3
|
|
245
262
|
})
|
|
246
263
|
])
|
|
247
|
-
], 8,
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
u(e.$slots, "editor",
|
|
264
|
+
], 8, ut)) : s("", !0),
|
|
265
|
+
we(v("div", pt, [
|
|
266
|
+
v("div", vt, [
|
|
267
|
+
u(e.$slots, "editor", g(h(p.value)), void 0, !0)
|
|
251
268
|
])
|
|
252
269
|
], 512), [
|
|
253
|
-
[
|
|
270
|
+
[ke, t.value.isEditable]
|
|
254
271
|
]),
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
"aria-label": `Open API Documentation for ${(
|
|
272
|
+
ue.value ? (a(), m(z, { key: 1 }, [
|
|
273
|
+
v("main", {
|
|
274
|
+
"aria-label": `Open API Documentation for ${($ = (C = r(d)) == null ? void 0 : C.info) == null ? void 0 : $.title}`,
|
|
258
275
|
class: "references-rendered"
|
|
259
276
|
}, [
|
|
260
|
-
|
|
277
|
+
f(r(nt), {
|
|
261
278
|
layout: t.value.layout,
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
279
|
+
document: r(d),
|
|
280
|
+
parsedSpec: k.value
|
|
281
|
+
}, Ce({
|
|
282
|
+
start: l(() => [
|
|
283
|
+
u(e.$slots, "content-start", g(h(p.value)), () => [
|
|
284
|
+
t.value.layout === "classic" ? (a(), b(ze, { key: 0 }, {
|
|
285
|
+
"dark-mode-toggle": l(() => [
|
|
286
|
+
t.value.hideDarkModeToggle ? s("", !0) : (a(), b(r(Le), {
|
|
269
287
|
key: 0,
|
|
270
288
|
class: "text-c-2 hover:text-c-1",
|
|
271
289
|
mode: e.isDark ? "dark" : "light",
|
|
272
290
|
style: { transform: "scale(1.4)" },
|
|
273
291
|
variant: "icon",
|
|
274
|
-
onClick: o[
|
|
292
|
+
onClick: o[1] || (o[1] = (S) => e.$emit("toggleDarkMode"))
|
|
275
293
|
}, null, 8, ["mode"]))
|
|
276
294
|
]),
|
|
277
|
-
default:
|
|
278
|
-
e.$slots["document-selector"] ? (
|
|
295
|
+
default: l(() => [
|
|
296
|
+
e.$slots["document-selector"] ? (a(), m("div", ht, [
|
|
279
297
|
u(e.$slots, "document-selector", {}, void 0, !0)
|
|
280
|
-
])) :
|
|
281
|
-
t.value.hideSearch ?
|
|
298
|
+
])) : s("", !0),
|
|
299
|
+
t.value.hideSearch ? s("", !0) : (a(), b(r(Q), {
|
|
282
300
|
key: 1,
|
|
283
301
|
class: "t-doc__sidebar",
|
|
284
302
|
searchHotKey: t.value.searchHotKey,
|
|
285
|
-
spec:
|
|
303
|
+
spec: k.value
|
|
286
304
|
}, null, 8, ["searchHotKey", "spec"]))
|
|
287
305
|
]),
|
|
288
306
|
_: 3
|
|
289
|
-
})) :
|
|
307
|
+
})) : s("", !0)
|
|
290
308
|
], !0)
|
|
291
309
|
]),
|
|
292
|
-
end:
|
|
293
|
-
u(e.$slots, "content-end",
|
|
310
|
+
end: l(() => [
|
|
311
|
+
u(e.$slots, "content-end", g(h(p.value)), void 0, !0)
|
|
294
312
|
]),
|
|
295
313
|
_: 2
|
|
296
314
|
}, [
|
|
297
|
-
(
|
|
315
|
+
(U = t.value) != null && U.isEditable ? {
|
|
298
316
|
name: "empty-state",
|
|
299
|
-
fn:
|
|
300
|
-
var
|
|
317
|
+
fn: l(() => {
|
|
318
|
+
var S;
|
|
301
319
|
return [
|
|
302
|
-
|
|
303
|
-
theme: ((
|
|
304
|
-
onChangeTheme: o[
|
|
305
|
-
onLinkSwaggerFile: o[
|
|
306
|
-
onLoadSwaggerFile: o[
|
|
307
|
-
onUpdateContent: o[
|
|
320
|
+
f(Ge, {
|
|
321
|
+
theme: ((S = t.value) == null ? void 0 : S.theme) || "default",
|
|
322
|
+
onChangeTheme: o[2] || (o[2] = (c) => e.$emit("changeTheme", c)),
|
|
323
|
+
onLinkSwaggerFile: o[3] || (o[3] = (c) => e.$emit("linkSwaggerFile")),
|
|
324
|
+
onLoadSwaggerFile: o[4] || (o[4] = (c) => e.$emit("loadSwaggerFile")),
|
|
325
|
+
onUpdateContent: o[5] || (o[5] = (c) => e.$emit("updateContent", c))
|
|
308
326
|
}, null, 8, ["theme"])
|
|
309
327
|
];
|
|
310
328
|
}),
|
|
311
329
|
key: "0"
|
|
312
330
|
} : void 0
|
|
313
|
-
]), 1032, ["layout", "parsedSpec"])
|
|
314
|
-
], 8,
|
|
315
|
-
e.$slots.footer ? (
|
|
316
|
-
u(e.$slots, "footer",
|
|
317
|
-
])) :
|
|
318
|
-
], 64)) :
|
|
319
|
-
|
|
331
|
+
]), 1032, ["layout", "document", "parsedSpec"])
|
|
332
|
+
], 8, gt),
|
|
333
|
+
e.$slots.footer ? (a(), m("div", St, [
|
|
334
|
+
u(e.$slots, "footer", g(h(p.value)), void 0, !0)
|
|
335
|
+
])) : s("", !0)
|
|
336
|
+
], 64)) : s("", !0),
|
|
337
|
+
f(r(it), {
|
|
320
338
|
configuration: t.value,
|
|
321
|
-
dereferencedDocument:
|
|
339
|
+
dereferencedDocument: r(d)
|
|
322
340
|
}, null, 8, ["configuration", "dereferencedDocument"])
|
|
323
|
-
],
|
|
324
|
-
|
|
341
|
+
], 6),
|
|
342
|
+
f(r(Ve))
|
|
325
343
|
], 64);
|
|
326
344
|
};
|
|
327
345
|
}
|
|
328
346
|
});
|
|
329
347
|
export {
|
|
330
|
-
|
|
348
|
+
qt as default
|
|
331
349
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Content.vue.d.ts","sourceRoot":"","sources":["../../../src/components/Content/Content.vue"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"Content.vue.d.ts","sourceRoot":"","sources":["../../../src/components/Content/Content.vue"],"names":[],"mappings":"AAiSA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAA;AACxD,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,sBAAsB,CAAA;AAehD,KAAK,WAAW,GAAG;IACf,QAAQ,EAAE,WAAW,CAAC,QAAQ,CAAA;IAC9B,UAAU,EAAE,IAAI,CAAA;IAChB,MAAM,CAAC,EAAE,QAAQ,GAAG,SAAS,CAAA;CAC9B,CAAC;AAwDJ,iBAAS,cAAc;WA2OT,OAAO,IAA6B;;uBAVvB,GAAG;+BACM,GAAG;qBACb,GAAG;;;;EAa5B;AA4BD,KAAK,oBAAoB,GAAG,UAAU,CAAC,OAAO,cAAc,CAAC,CAAC;AAC9D,QAAA,MAAM,eAAe;YAtUR,QAAQ,GAAG,SAAS;6EA6U/B,CAAC;wBACkB,uBAAuB,CAAC,OAAO,eAAe,EAAE,oBAAoB,CAAC,OAAO,CAAC,CAAC;AAAnG,wBAAoG;AAgBpG,KAAK,uBAAuB,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IACxC,QAAO;QACN,MAAM,EAAE,CAAC,CAAC;KAEV,CAAA;CACD,CAAC"}
|
|
@@ -2,7 +2,7 @@ import o from "./Content.vue2.js";
|
|
|
2
2
|
/* empty css */
|
|
3
3
|
/* empty css */
|
|
4
4
|
import t from "../../_virtual/_plugin-vue_export-helper.js";
|
|
5
|
-
const
|
|
5
|
+
const a = /* @__PURE__ */ t(o, [["__scopeId", "data-v-54b62036"]]);
|
|
6
6
|
export {
|
|
7
|
-
|
|
7
|
+
a as default
|
|
8
8
|
};
|