@scalar/api-reference 1.25.115 → 1.25.118

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.
Files changed (67) hide show
  1. package/CHANGELOG.md +76 -0
  2. package/dist/browser/standalone.js +15973 -15829
  3. package/dist/browser/webpack-stats.json +1 -1
  4. package/dist/components/ApiReferenceLayout.vue.js +2 -2
  5. package/dist/components/ApiReferenceLayout.vue2.js +1 -1
  6. package/dist/components/Content/Introduction/Introduction.vue.d.ts.map +1 -1
  7. package/dist/components/Content/Introduction/Introduction.vue.js +1 -1
  8. package/dist/components/Content/Introduction/Introduction.vue2.js +39 -38
  9. package/dist/components/Content/Lazy/Loading.vue.d.ts.map +1 -1
  10. package/dist/components/Content/Lazy/Loading.vue.js +58 -60
  11. package/dist/components/Content/Schema/SchemaProperty.vue.d.ts +6 -0
  12. package/dist/components/Content/Schema/SchemaProperty.vue.d.ts.map +1 -1
  13. package/dist/components/Content/Schema/SchemaProperty.vue.js +2 -2
  14. package/dist/components/Content/Schema/SchemaProperty.vue2.js +124 -120
  15. package/dist/components/Content/Schema/helpers/optimizeValueForDisplay.d.ts +1 -3
  16. package/dist/components/Content/Schema/helpers/optimizeValueForDisplay.d.ts.map +1 -1
  17. package/dist/components/Content/Tag/TagList.vue.d.ts.map +1 -1
  18. package/dist/components/Content/Tag/TagList.vue.js +36 -38
  19. package/dist/components/Sidebar/SidebarElement.vue.d.ts.map +1 -1
  20. package/dist/components/Sidebar/SidebarElement.vue.js +1 -1
  21. package/dist/components/Sidebar/SidebarElement.vue2.js +59 -55
  22. package/dist/features/ApiClientModal/useApiClient.d.ts +208 -128
  23. package/dist/features/ApiClientModal/useApiClient.d.ts.map +1 -1
  24. package/dist/features/ExampleRequest/ExampleRequest.vue.d.ts +6 -4
  25. package/dist/features/ExampleRequest/ExampleRequest.vue.d.ts.map +1 -1
  26. package/dist/features/ExampleRequest/ExampleRequest.vue.js +1 -1
  27. package/dist/features/ExampleRequest/ExampleRequest.vue2.js +130 -119
  28. package/dist/features/ExampleResponses/ExampleResponses.vue.d.ts +2 -2
  29. package/dist/features/ExampleResponses/ExampleResponses.vue.d.ts.map +1 -1
  30. package/dist/features/ExampleResponses/ExampleResponses.vue.js +3 -3
  31. package/dist/features/ExampleResponses/ExampleResponses.vue2.js +86 -91
  32. package/dist/features/Operation/Operation.vue.d.ts +4 -5
  33. package/dist/features/Operation/Operation.vue.d.ts.map +1 -1
  34. package/dist/features/Operation/Operation.vue.js +34 -41
  35. package/dist/features/Operation/layouts/ClassicLayout.vue.d.ts +6 -6
  36. package/dist/features/Operation/layouts/ClassicLayout.vue.d.ts.map +1 -1
  37. package/dist/features/Operation/layouts/ClassicLayout.vue.js +2 -2
  38. package/dist/features/Operation/layouts/ClassicLayout.vue2.js +54 -51
  39. package/dist/features/Operation/layouts/ModernLayout.vue.d.ts +6 -6
  40. package/dist/features/Operation/layouts/ModernLayout.vue.d.ts.map +1 -1
  41. package/dist/features/Operation/layouts/ModernLayout.vue.js +2 -2
  42. package/dist/features/Operation/layouts/ModernLayout.vue2.js +71 -71
  43. package/dist/helpers/get-request.d.ts.map +1 -1
  44. package/dist/helpers/index.d.ts +0 -3
  45. package/dist/helpers/index.d.ts.map +1 -1
  46. package/dist/hooks/useConfig.d.ts +1 -1
  47. package/dist/hooks/useConfig.d.ts.map +1 -1
  48. package/dist/hooks/useConfig.js +1 -1
  49. package/dist/hooks/useNavState.d.ts.map +1 -1
  50. package/dist/hooks/useNavState.js +26 -24
  51. package/dist/hooks/useReactiveSpec.d.ts +1 -1
  52. package/dist/index.js +66 -72
  53. package/dist/style.css +1 -1
  54. package/package.json +12 -12
  55. package/dist/features/Operation/hooks/useRequestExample.d.ts +0 -17
  56. package/dist/features/Operation/hooks/useRequestExample.d.ts.map +0 -1
  57. package/dist/features/Operation/hooks/useRequestExample.js +0 -68
  58. package/dist/helpers/convertRequestToHarRequest.d.ts +0 -7
  59. package/dist/helpers/convertRequestToHarRequest.d.ts.map +0 -1
  60. package/dist/helpers/convertRequestToHarRequest.js +0 -64
  61. package/dist/helpers/get-request.js +0 -6
  62. package/dist/helpers/getExampleCode.d.ts +0 -8
  63. package/dist/helpers/getExampleCode.d.ts.map +0 -1
  64. package/dist/helpers/getExampleCode.js +0 -16
  65. package/dist/helpers/joinWithSlash.d.ts +0 -5
  66. package/dist/helpers/joinWithSlash.d.ts.map +0 -1
  67. package/dist/helpers/joinWithSlash.js +0 -4
@@ -1 +1 @@
1
- {"version":3,"file":"ModernLayout.vue.d.ts","sourceRoot":"","sources":["../../../../src/features/Operation/layouts/ModernLayout.vue"],"names":[],"mappings":"AAoIA,OAAO,KAAK,EAAE,OAAO,IAAI,aAAa,EAAE,MAAM,iCAAiC,CAAA;AAC/E,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,sBAAsB,CAAA;AAQhE,KAAK,WAAW,GAAG;IACjB,EAAE,CAAC,EAAE,MAAM,CAAA;IACX,8CAA8C;IAC9C,SAAS,EAAE,oBAAoB,CAAA;IAC/B,aAAa,CAAC,EAAE,aAAa,CAAA;IAC7B,OAAO,EAAE,OAAO,GAAG,IAAI,CAAA;IACvB,iBAAiB,EAAE,MAAM,EAAE,CAAA;CAC5B,CAAC;;AAwNF,wBAOG"}
1
+ {"version":3,"file":"ModernLayout.vue.d.ts","sourceRoot":"","sources":["../../../../src/features/Operation/layouts/ModernLayout.vue"],"names":[],"mappings":"AA4IA,OAAO,KAAK,EACV,UAAU,EACV,SAAS,EACT,MAAM,EACP,MAAM,iCAAiC,CAAA;AACxC,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,sBAAsB,CAAA;AAQhE,KAAK,WAAW,GAAG;IACjB,EAAE,CAAC,EAAE,MAAM,CAAA;IACX,UAAU,EAAE,UAAU,CAAA;IACtB,MAAM,EAAE,MAAM,GAAG,SAAS,CAAA;IAC1B,SAAS,EAAE,SAAS,CAAA;IACpB,0CAA0C;IAC1C,oBAAoB,EAAE,oBAAoB,CAAA;CAC3C,CAAC;;AA0NF,wBAOG"}
@@ -1,7 +1,7 @@
1
1
  import o from "./ModernLayout.vue2.js";
2
2
  /* empty css */
3
3
  import t from "../../../_virtual/_plugin-vue_export-helper.js";
4
- const e = /* @__PURE__ */ t(o, [["__scopeId", "data-v-ec5acf12"]]);
4
+ const f = /* @__PURE__ */ t(o, [["__scopeId", "data-v-0916dd9f"]]);
5
5
  export {
6
- e as default
6
+ f as default
7
7
  };
@@ -1,55 +1,57 @@
1
- import { defineComponent as c, openBlock as n, createBlock as l, unref as o, withCtx as r, createVNode as t, normalizeClass as p, createTextVNode as s, toDisplayString as m, createCommentVNode as h, createElementVNode as i } from "vue";
2
- import C from "../../../components/OperationPath.vue.js";
3
- import { getOperationStability as d, getOperationStabilityColor as y, isOperationDeprecated as q } from "../../../helpers/operation.js";
4
- import { ScalarMarkdown as S, ScalarErrorBoundary as u } from "@scalar/components";
1
+ import { defineComponent as c, openBlock as i, createBlock as l, unref as o, withCtx as t, createVNode as r, normalizeClass as p, createTextVNode as s, toDisplayString as m, createCommentVNode as O, createElementVNode as a } from "vue";
2
+ import h from "../../../components/OperationPath.vue.js";
3
+ import { getOperationStability as d, getOperationStabilityColor as v, isOperationDeprecated as S } from "../../../helpers/operation.js";
4
+ import { ScalarMarkdown as C, ScalarErrorBoundary as f } from "@scalar/components";
5
5
  import _ from "../components/OperationParameters.vue.js";
6
- import E from "../components/OperationResponses.vue.js";
6
+ import y from "../components/OperationResponses.vue.js";
7
7
  import g from "../../../components/Section/Section.vue.js";
8
- import v from "../../../components/Section/SectionContent.vue.js";
9
- import b from "../../../components/Badge/Badge.vue.js";
10
- import k from "../../../components/Section/SectionHeader.vue.js";
11
- import B from "../../../components/Anchor/Anchor.vue.js";
8
+ import b from "../../../components/Section/SectionContent.vue.js";
9
+ import k from "../../../components/Badge/Badge.vue.js";
10
+ import B from "../../../components/Section/SectionHeader.vue.js";
11
+ import E from "../../../components/Anchor/Anchor.vue.js";
12
12
  import N from "../../../components/Section/SectionColumns.vue.js";
13
- import f from "../../../components/Section/SectionColumn.vue.js";
14
- import O from "../../ExampleRequest/ExampleRequest.vue.js";
15
- import V from "../../TestRequestButton/TestRequestButton.vue.js";
16
- import w from "../../ExampleResponses/ExampleResponses.vue.js";
17
- const R = { class: "operation-details" }, D = { class: "examples" }, Y = /* @__PURE__ */ c({
13
+ import u from "../../../components/Section/SectionColumn.vue.js";
14
+ import V from "../../ExampleRequest/ExampleRequest.vue.js";
15
+ import w from "../../TestRequestButton/TestRequestButton.vue.js";
16
+ import R from "../../ExampleResponses/ExampleResponses.vue.js";
17
+ const q = { class: "operation-details" }, D = { class: "examples" }, Y = /* @__PURE__ */ c({
18
18
  __name: "ModernLayout",
19
19
  props: {
20
20
  id: {},
21
+ collection: {},
22
+ server: {},
21
23
  operation: {},
22
- requestEntity: {},
23
- request: {},
24
- secretCredentials: {}
24
+ transformedOperation: {}
25
25
  },
26
26
  setup(M) {
27
- return (e, T) => (n(), l(o(g), {
27
+ return (e, T) => (i(), l(o(g), {
28
28
  id: e.id,
29
- label: e.operation.name
29
+ label: e.transformedOperation.name
30
30
  }, {
31
- default: r(() => [
32
- t(o(v), null, {
33
- default: r(() => [
34
- o(d)(e.operation) ? (n(), l(o(b), {
31
+ default: t(() => [
32
+ r(o(b), null, {
33
+ default: t(() => [
34
+ o(d)(e.transformedOperation) ? (i(), l(o(k), {
35
35
  key: 0,
36
- class: p(o(y)(e.operation))
36
+ class: p(o(v)(e.transformedOperation))
37
37
  }, {
38
- default: r(() => [
39
- s(m(o(d)(e.operation)), 1)
38
+ default: t(() => [
39
+ s(m(o(d)(e.transformedOperation)), 1)
40
40
  ]),
41
41
  _: 1
42
- }, 8, ["class"])) : h("", !0),
43
- i("div", {
44
- class: p(o(q)(e.operation) ? "deprecated" : "")
42
+ }, 8, ["class"])) : O("", !0),
43
+ a("div", {
44
+ class: p(
45
+ o(S)(e.transformedOperation) ? "deprecated" : ""
46
+ )
45
47
  }, [
46
- t(o(k), { level: 3 }, {
47
- default: r(() => [
48
- t(o(B), {
48
+ r(o(B), { level: 3 }, {
49
+ default: t(() => [
50
+ r(o(E), {
49
51
  id: e.id ?? ""
50
52
  }, {
51
- default: r(() => [
52
- s(m(e.operation.name), 1)
53
+ default: t(() => [
54
+ s(m(e.transformedOperation.name), 1)
53
55
  ]),
54
56
  _: 1
55
57
  }, 8, ["id"])
@@ -57,59 +59,57 @@ const R = { class: "operation-details" }, D = { class: "examples" }, Y = /* @__P
57
59
  _: 1
58
60
  })
59
61
  ], 2),
60
- t(o(N), null, {
61
- default: r(() => [
62
- t(o(f), null, {
63
- default: r(() => {
64
- var a;
65
- return [
66
- i("div", R, [
67
- t(o(S), {
68
- value: (a = e.requestEntity) == null ? void 0 : a.description,
69
- withImages: ""
70
- }, null, 8, ["value"]),
71
- t(_, { operation: e.requestEntity }, null, 8, ["operation"]),
72
- t(E, { operation: e.operation }, null, 8, ["operation"])
73
- ])
74
- ];
75
- }),
62
+ r(o(N), null, {
63
+ default: t(() => [
64
+ r(o(u), null, {
65
+ default: t(() => [
66
+ a("div", q, [
67
+ r(o(C), {
68
+ value: e.operation.description,
69
+ withImages: ""
70
+ }, null, 8, ["value"]),
71
+ r(_, { operation: e.operation }, null, 8, ["operation"]),
72
+ r(y, { operation: e.transformedOperation }, null, 8, ["operation"])
73
+ ])
74
+ ]),
76
75
  _: 1
77
76
  }),
78
- t(o(f), null, {
79
- default: r(() => [
80
- i("div", D, [
81
- t(o(u), null, {
82
- default: r(() => [
83
- t(o(O), {
77
+ r(o(u), null, {
78
+ default: t(() => [
79
+ a("div", D, [
80
+ r(o(f), null, {
81
+ default: t(() => [
82
+ r(o(V), {
83
+ collection: e.collection,
84
84
  fallback: "",
85
85
  operation: e.operation,
86
- request: e.request,
87
- secretCredentials: e.secretCredentials
86
+ server: e.server,
87
+ transformedOperation: e.transformedOperation
88
88
  }, {
89
- header: r(() => {
90
- var a;
89
+ header: t(() => {
90
+ var n;
91
91
  return [
92
- t(C, {
92
+ r(h, {
93
93
  class: "example-path",
94
- deprecated: (a = e.operation.information) == null ? void 0 : a.deprecated,
95
- path: e.operation.path
94
+ deprecated: (n = e.transformedOperation.information) == null ? void 0 : n.deprecated,
95
+ path: e.transformedOperation.path
96
96
  }, null, 8, ["deprecated", "path"])
97
97
  ];
98
98
  }),
99
- footer: r(() => [
100
- t(o(V), { operation: e.requestEntity }, null, 8, ["operation"])
99
+ footer: t(() => [
100
+ r(o(w), { operation: e.operation }, null, 8, ["operation"])
101
101
  ]),
102
102
  _: 1
103
- }, 8, ["operation", "request", "secretCredentials"])
103
+ }, 8, ["collection", "operation", "server", "transformedOperation"])
104
104
  ]),
105
105
  _: 1
106
106
  }),
107
- t(o(u), null, {
108
- default: r(() => [
109
- t(o(w), {
110
- operation: e.operation,
107
+ r(o(f), null, {
108
+ default: t(() => [
109
+ r(o(R), {
110
+ responses: e.operation.responses,
111
111
  style: { "margin-top": "12px" }
112
- }, null, 8, ["operation"])
112
+ }, null, 8, ["responses"])
113
113
  ]),
114
114
  _: 1
115
115
  })
@@ -1 +1 @@
1
- {"version":3,"file":"get-request.d.ts","sourceRoot":"","sources":["../../src/helpers/get-request.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,0BAA0B,CAAA;AAE9D,6CAA6C;AAC7C,eAAO,MAAM,UAAU,aACX,cAAc,CAAC,UAAU,CAAC,QAC9B,MAAM,UACJ,MAAM;;;;;;;;;;;;;mBAKilT,CAAC;;;;;;;;;;;;;mBAA8f,CAAC;eAAyC,CAAC;cAA6B,CAAC;eAA8B,CAAC;aAA4B,CAAC;gBAA8H,CAAC;iBAAwC,CAAC;mBAAkC,CAAC;;;;;aAD76U,CAAA"}
1
+ {"version":3,"file":"get-request.d.ts","sourceRoot":"","sources":["../../src/helpers/get-request.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,0BAA0B,CAAA;AAE9D,6CAA6C;AAC7C,eAAO,MAAM,UAAU,aACX,cAAc,CAAC,UAAU,CAAC,QAC9B,MAAM,UACJ,MAAM;;;;;;;;;;;;;mBAK+uT,CAAC;;;;;;;;;;;;;mBAA8f,CAAC;eAAyC,CAAC;cAA6B,CAAC;eAA8B,CAAC;aAA4B,CAAC;gBAA8H,CAAC;iBAAwC,CAAC;mBAAkC,CAAC;;;;;aAD3kV,CAAA"}
@@ -1,8 +1,6 @@
1
1
  export * from './createEmptySpecification.js';
2
2
  export * from './deepMerge.js';
3
3
  export * from './operation.js';
4
- export * from './getExampleCode.js';
5
- export * from './convertRequestToHarRequest.js';
6
4
  export * from './getHeadingsFromMarkdown.js';
7
5
  export * from './getLowestHeadingLevel.js';
8
6
  export * from './getModels.js';
@@ -11,7 +9,6 @@ export * from './hasModels.js';
11
9
  export * from './hasSecuritySchemes.js';
12
10
  export * from './hasWebhooks.js';
13
11
  export * from './isMacOs.js';
14
- export * from './joinWithSlash.js';
15
12
  export * from './mapFromObject.js';
16
13
  export * from './mergeAllObjects.js';
17
14
  export * from './parse.js';
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/helpers/index.ts"],"names":[],"mappings":"AAAA,cAAc,4BAA4B,CAAA;AAC1C,cAAc,aAAa,CAAA;AAC3B,cAAc,aAAa,CAAA;AAC3B,cAAc,kBAAkB,CAAA;AAChC,cAAc,8BAA8B,CAAA;AAC5C,cAAc,2BAA2B,CAAA;AACzC,cAAc,yBAAyB,CAAA;AACvC,cAAc,aAAa,CAAA;AAC3B,cAAc,oBAAoB,CAAA;AAClC,cAAc,aAAa,CAAA;AAC3B,cAAc,sBAAsB,CAAA;AACpC,cAAc,eAAe,CAAA;AAC7B,cAAc,WAAW,CAAA;AACzB,cAAc,iBAAiB,CAAA;AAC/B,cAAc,iBAAiB,CAAA;AAC/B,cAAc,mBAAmB,CAAA;AACjC,cAAc,SAAS,CAAA;AACvB,cAAc,cAAc,CAAA;AAC5B,cAAc,SAAS,CAAA;AACvB,cAAc,iBAAiB,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/helpers/index.ts"],"names":[],"mappings":"AAAA,cAAc,4BAA4B,CAAA;AAC1C,cAAc,aAAa,CAAA;AAC3B,cAAc,aAAa,CAAA;AAC3B,cAAc,2BAA2B,CAAA;AACzC,cAAc,yBAAyB,CAAA;AACvC,cAAc,aAAa,CAAA;AAC3B,cAAc,oBAAoB,CAAA;AAClC,cAAc,aAAa,CAAA;AAC3B,cAAc,sBAAsB,CAAA;AACpC,cAAc,eAAe,CAAA;AAC7B,cAAc,WAAW,CAAA;AACzB,cAAc,iBAAiB,CAAA;AAC/B,cAAc,mBAAmB,CAAA;AACjC,cAAc,SAAS,CAAA;AACvB,cAAc,cAAc,CAAA;AAC5B,cAAc,SAAS,CAAA;AACvB,cAAc,iBAAiB,CAAA"}
@@ -2,5 +2,5 @@ import type { ReferenceConfiguration } from '../types';
2
2
  import { type InjectionKey } from 'vue';
3
3
  export declare const CONFIGURATION_SYMBOL: InjectionKey<ReferenceConfiguration>;
4
4
  /** Hook for easy access to the reference configuration */
5
- export declare const useConfig: () => ReferenceConfiguration | undefined;
5
+ export declare const useConfig: () => ReferenceConfiguration;
6
6
  //# sourceMappingURL=useConfig.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"useConfig.d.ts","sourceRoot":"","sources":["../../src/hooks/useConfig.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,SAAS,CAAA;AACrD,OAAO,EAAE,KAAK,YAAY,EAAU,MAAM,KAAK,CAAA;AAE/C,eAAO,MAAM,oBAAoB,EACnB,YAAY,CAAC,sBAAsB,CAAC,CAAA;AAElD,0DAA0D;AAC1D,eAAO,MAAM,SAAS,0CAGrB,CAAA"}
1
+ {"version":3,"file":"useConfig.d.ts","sourceRoot":"","sources":["../../src/hooks/useConfig.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,SAAS,CAAA;AACrD,OAAO,EAAE,KAAK,YAAY,EAAU,MAAM,KAAK,CAAA;AAE/C,eAAO,MAAM,oBAAoB,EACnB,YAAY,CAAC,sBAAsB,CAAC,CAAA;AAElD,0DAA0D;AAC1D,eAAO,MAAM,SAAS,8BAGrB,CAAA"}
@@ -1,5 +1,5 @@
1
1
  import { inject as o } from "vue";
2
- const n = Symbol(), i = () => o(n, void 0);
2
+ const n = Symbol(), i = () => o(n, {});
3
3
  export {
4
4
  n as CONFIGURATION_SYMBOL,
5
5
  i as useConfig
@@ -1 +1 @@
1
- {"version":3,"file":"useNavState.d.ts","sourceRoot":"","sources":["../../src/hooks/useNavState.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,OAAO,EAAE,GAAG,EAAE,oBAAoB,EAAE,MAAM,sBAAsB,CAAA;AAI9E,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,UAAU,CAAA;AAqF3C;;;;;;GAMG;AACH,eAAO,MAAM,WAAW;;IAsDpB,mCAAmC;4BACX,MAAM;IAG9B;;;;OAIG;+BAnF0B,MAAM;IAqFnC;;;;;OAKG;oCApGY,MAAM;IAsGrB;;;OAGG;uCA9HY,MAAM;IAgIrB,0DAA0D;;6BAjC5B;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,MAAM,CAAC,EAAE,MAAM,CAAA;KAAE;yBA5BrC;QAAE,IAAI,EAAE,MAAM,CAAA;KAAE;4BATb,OAAO;gCAyBH,oBAAoB,aAAa,GAAG;iCA9GrC,MAAM;;oBAuGjB,GAAG;;;;CAiE3B,CAAA"}
1
+ {"version":3,"file":"useNavState.d.ts","sourceRoot":"","sources":["../../src/hooks/useNavState.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,OAAO,EAAE,GAAG,EAAE,oBAAoB,EAAE,MAAM,sBAAsB,CAAA;AAI9E,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,UAAU,CAAA;AAwF3C;;;;;;GAMG;AACH,eAAO,MAAM,WAAW;;IAsDpB,mCAAmC;4BACX,MAAM;IAG9B;;;;OAIG;+BAnF0B,MAAM;IAqFnC;;;;;OAKG;oCApGY,MAAM;IAsGrB;;;OAGG;uCAjIY,MAAM;IAmIrB,0DAA0D;;6BAjC5B;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,MAAM,CAAC,EAAE,MAAM,CAAA;KAAE;yBA5BrC;QAAE,IAAI,EAAE,MAAM,CAAA;KAAE;4BATb,OAAO;gCAyBH,oBAAoB,aAAa,GAAG;iCAjHrC,MAAM;;oBA0GjB,GAAG;;;;CAiE3B,CAAA"}
@@ -1,19 +1,18 @@
1
1
  import { useConfig as p } from "./useConfig.js";
2
- import { ssrState as m } from "@scalar/oas-utils/helpers";
2
+ import { ssrState as m, combineUrlAndPath as f } from "@scalar/oas-utils/helpers";
3
3
  import { slug as c } from "github-slugger";
4
4
  import { ref as l } from "vue";
5
- import { joinWithSlash as f } from "../helpers/joinWithSlash.js";
6
- const s = l(""), u = l(m.hash ?? ""), a = l(), w = l(!1), d = (e) => {
5
+ const s = l(""), u = l(m.hash ?? ""), o = l(), w = l(!1), h = (e) => {
7
6
  var n;
8
- if (!a.value) return "";
9
- const r = new RegExp("^" + ((n = a.value) == null ? void 0 : n.basePath) + "/?");
7
+ if (!o.value) return "";
8
+ const r = new RegExp("^" + ((n = o.value) == null ? void 0 : n.basePath) + "/?");
10
9
  return decodeURIComponent(e.replace(r, ""));
11
10
  }, I = (e = u.value) => {
12
11
  var i;
13
- const r = (i = e.match(/(tag\/[^/]+)/)) == null ? void 0 : i[0], n = e.startsWith("model") ? "models" : "", o = e.startsWith("webhook") ? "webhooks" : "";
14
- return r || n || o;
12
+ const r = (i = e.match(/(tag\/[^/]+)/)) == null ? void 0 : i[0], n = e.startsWith("model") ? "models" : "", a = e.startsWith("webhook") ? "webhooks" : "";
13
+ return r || n || a;
15
14
  }, v = () => {
16
- u.value = a.value ? d(window.location.pathname) : (
15
+ u.value = o.value ? h(window.location.pathname) : (
17
16
  // Must remove the prefix from the hash as the internal hash value should be pure
18
17
  decodeURIComponent(window.location.hash.replace(/^#/, "")).slice(
19
18
  s.value.length
@@ -21,14 +20,17 @@ const s = l(""), u = l(m.hash ?? ""), a = l(), w = l(!1), d = (e) => {
21
20
  );
22
21
  }, $ = (e, r = window.location.href) => {
23
22
  const n = new URL(r);
24
- a.value ? n.pathname = f(a.value.basePath, e) : n.hash = s.value + e, u.value = e, window.history.replaceState({}, "", n);
23
+ o.value ? n.pathname = f(
24
+ o.value.basePath,
25
+ e
26
+ ) : n.hash = s.value + e, u.value = e, window.history.replaceState({}, "", n);
25
27
  }, S = (e, r = window.location.href, n = window.location.search) => {
26
- const o = new URL(r);
27
- return o.hash = s.value + e, o.search = n, o.toString();
28
- }, y = (e = u.value) => `${s.value}${e}`, R = () => decodeURIComponent(
28
+ const a = new URL(r);
29
+ return a.hash = s.value + e, a.search = n, a.toString();
30
+ }, U = (e = u.value) => `${s.value}${e}`, b = () => decodeURIComponent(
29
31
  window.location.hash.replace(/^#/, "").slice(s.value.length)
30
- ), C = () => {
31
- const e = p(), r = (t) => typeof (e == null ? void 0 : e.generateHeadingSlug) == "function" ? `${e.generateHeadingSlug(t)}` : t.slug ? `description/${t.slug}` : "", n = (t) => t != null && t.name ? typeof (e == null ? void 0 : e.generateModelSlug) == "function" ? `model/${e.generateModelSlug(t)}` : `model/${c(t.name)}` : "models", o = (t) => typeof (e == null ? void 0 : e.generateTagSlug) == "function" ? `tag/${e.generateTagSlug(t)}` : `tag/${c(t.name)}`;
32
+ ), x = () => {
33
+ const e = p(), r = (t) => typeof (e == null ? void 0 : e.generateHeadingSlug) == "function" ? `${e.generateHeadingSlug(t)}` : t.slug ? `description/${t.slug}` : "", n = (t) => t != null && t.name ? typeof (e == null ? void 0 : e.generateModelSlug) == "function" ? `model/${e.generateModelSlug(t)}` : `model/${c(t.name)}` : "models", a = (t) => typeof (e == null ? void 0 : e.generateTagSlug) == "function" ? `tag/${e.generateTagSlug(t)}` : `tag/${c(t.name)}`;
32
34
  return {
33
35
  hash: u,
34
36
  /** Sets the prefix for the hash */
@@ -40,7 +42,7 @@ const s = l(""), u = l(m.hash ?? ""), a = l(), w = l(!1), d = (e) => {
40
42
  * @param hashTarget The hash to target with the return
41
43
  * @returns The full hash
42
44
  */
43
- getFullHash: y,
45
+ getFullHash: U,
44
46
  /**
45
47
  * Gets the hashed url with the prefix
46
48
  * @param replacementHash The hash to replace the current hash with
@@ -54,27 +56,27 @@ const s = l(""), u = l(m.hash ?? ""), a = l(), w = l(!1), d = (e) => {
54
56
  */
55
57
  replaceUrlState: $,
56
58
  /** Gets the portion of the hash used by the references */
57
- getReferenceHash: R,
59
+ getReferenceHash: b,
58
60
  getWebhookId: (t) => t != null && t.name ? typeof (e == null ? void 0 : e.generateWebhookSlug) == "function" ? `webhook/${e.generateWebhookSlug(t)}` : `webhook/${t.method}/${c(t.name)}` : "webhooks",
59
61
  getModelId: n,
60
62
  getHeadingId: r,
61
63
  getOperationId: (t, g) => {
62
- var h;
63
- return typeof (e == null ? void 0 : e.generateOperationSlug) == "function" ? `${o(g)}/${e.generateOperationSlug({
64
+ var d;
65
+ return typeof (e == null ? void 0 : e.generateOperationSlug) == "function" ? `${a(g)}/${e.generateOperationSlug({
64
66
  path: t.path,
65
67
  operationId: t.operationId,
66
68
  method: t.httpVerb,
67
- summary: (h = t.information) == null ? void 0 : h.summary
68
- })}` : `${o(g)}/${t.httpVerb}${t.path}`;
69
+ summary: (d = t.information) == null ? void 0 : d.summary
70
+ })}` : `${a(g)}/${t.httpVerb}${t.path}`;
69
71
  },
70
- getPathRoutingId: d,
72
+ getPathRoutingId: h,
71
73
  getSectionId: I,
72
- getTagId: o,
74
+ getTagId: a,
73
75
  isIntersectionEnabled: w,
74
- pathRouting: a,
76
+ pathRouting: o,
75
77
  updateHash: v
76
78
  };
77
79
  };
78
80
  export {
79
- C as useNavState
81
+ x as useNavState
80
82
  };
@@ -153,8 +153,8 @@ export declare function useReactiveSpec({ specConfig, proxyUrl, }: {
153
153
  version?: string | undefined;
154
154
  summary?: string | undefined;
155
155
  license?: {
156
- url?: string | undefined;
157
156
  name?: string | undefined;
157
+ url?: string | undefined;
158
158
  identifier?: string | undefined;
159
159
  } | undefined;
160
160
  } | undefined;