@scalar/api-reference 1.25.127 → 1.25.130

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 (128) hide show
  1. package/CHANGELOG.md +67 -0
  2. package/dist/browser/standalone.js +13272 -13158
  3. package/dist/browser/webpack-stats.json +1 -1
  4. package/dist/components/ApiReference.vue.d.ts.map +1 -1
  5. package/dist/components/ApiReference.vue.js +40 -64
  6. package/dist/components/ApiReferenceLayout.vue.d.ts +2 -2
  7. package/dist/components/ApiReferenceLayout.vue.d.ts.map +1 -1
  8. package/dist/components/ApiReferenceLayout.vue.js +2 -2
  9. package/dist/components/ApiReferenceLayout.vue2.js +158 -159
  10. package/dist/components/Content/ClientLibraries/ClientLibraries.vue.d.ts.map +1 -1
  11. package/dist/components/Content/ClientLibraries/ClientLibraries.vue.js +1 -1
  12. package/dist/components/Content/ClientLibraries/ClientLibraries.vue2.js +69 -17
  13. package/dist/components/Content/ClientLibraries/ClientSelector.vue.d.ts +5 -1
  14. package/dist/components/Content/ClientLibraries/ClientSelector.vue.d.ts.map +1 -1
  15. package/dist/components/Content/ClientLibraries/ClientSelector.vue.js +2 -2
  16. package/dist/components/Content/ClientLibraries/ClientSelector.vue2.js +73 -94
  17. package/dist/components/Content/ClientLibraries/useFeaturedHttpClients.d.ts +16 -0
  18. package/dist/components/Content/ClientLibraries/useFeaturedHttpClients.d.ts.map +1 -0
  19. package/dist/components/Content/ClientLibraries/useFeaturedHttpClients.js +36 -0
  20. package/dist/components/Content/Lazy/Loading.vue.js +15 -15
  21. package/dist/components/Content/Schema/Schema.vue.d.ts.map +1 -1
  22. package/dist/components/Content/Schema/Schema.vue.js +2 -2
  23. package/dist/components/Content/Schema/Schema.vue2.js +4 -1
  24. package/dist/components/Content/Schema/SchemaProperty.vue.d.ts +1 -1
  25. package/dist/components/Content/Schema/SchemaProperty.vue.js +1 -1
  26. package/dist/components/Content/Schema/SchemaProperty.vue2.js +1 -1
  27. package/dist/components/Content/Schema/SchemaPropertyHeading.vue.d.ts.map +1 -1
  28. package/dist/components/Content/Schema/SchemaPropertyHeading.vue.js +2 -2
  29. package/dist/components/Content/Schema/SchemaPropertyHeading.vue2.js +143 -124
  30. package/dist/components/Content/Tag/{Endpoints.vue.d.ts → OperationsList.vue.d.ts} +1 -3
  31. package/dist/components/Content/Tag/OperationsList.vue.d.ts.map +1 -0
  32. package/dist/components/Content/Tag/OperationsList.vue.js +7 -0
  33. package/dist/components/Content/Tag/OperationsList.vue2.js +62 -0
  34. package/dist/components/Content/Tag/OperationsListItem.vue.d.ts +9 -0
  35. package/dist/components/Content/Tag/OperationsListItem.vue.d.ts.map +1 -0
  36. package/dist/components/Content/Tag/OperationsListItem.vue.js +7 -0
  37. package/dist/components/Content/Tag/OperationsListItem.vue2.js +66 -0
  38. package/dist/components/Content/Tag/Tag.vue.d.ts +4 -64
  39. package/dist/components/Content/Tag/Tag.vue.d.ts.map +1 -1
  40. package/dist/components/Content/Tag/Tag.vue.js +87 -5
  41. package/dist/components/Content/Tag/Tag.vue2.js +2 -63
  42. package/dist/components/Content/Tag/TagList.vue.d.ts.map +1 -1
  43. package/dist/components/Content/Tag/TagList.vue.js +11 -11
  44. package/dist/components/Content/Tag/TagSection.vue.d.ts +70 -0
  45. package/dist/components/Content/Tag/TagSection.vue.d.ts.map +1 -0
  46. package/dist/components/Content/Tag/TagSection.vue.js +7 -0
  47. package/dist/components/Content/Tag/TagSection.vue2.js +65 -0
  48. package/dist/components/Content/Tag/index.d.ts +1 -2
  49. package/dist/components/Content/Tag/index.d.ts.map +1 -1
  50. package/dist/components/GettingStarted.vue.d.ts.map +1 -1
  51. package/dist/components/GettingStarted.vue.js +1 -1
  52. package/dist/components/GettingStarted.vue2.js +13 -13
  53. package/dist/components/Layouts/ClassicLayout.vue.d.ts +3 -3
  54. package/dist/components/Layouts/ClassicLayout.vue.d.ts.map +1 -1
  55. package/dist/components/Layouts/Layouts.vue.d.ts +3 -3
  56. package/dist/components/Layouts/Layouts.vue.d.ts.map +1 -1
  57. package/dist/components/Layouts/ModernLayout.vue.d.ts +3 -3
  58. package/dist/components/Layouts/ModernLayout.vue.d.ts.map +1 -1
  59. package/dist/components/Layouts/ModernLayout.vue.js +2 -2
  60. package/dist/components/Section/CompactSection.vue.d.ts.map +1 -1
  61. package/dist/components/Section/CompactSection.vue.js +2 -2
  62. package/dist/components/Section/CompactSection.vue2.js +30 -29
  63. package/dist/esm.d.ts +5 -3
  64. package/dist/esm.d.ts.map +1 -1
  65. package/dist/features/ApiClientModal/ApiClientModal.vue.d.ts +2 -2
  66. package/dist/features/ApiClientModal/ApiClientModal.vue.d.ts.map +1 -1
  67. package/dist/features/ApiClientModal/useApiClient.d.ts +386 -346
  68. package/dist/features/ApiClientModal/useApiClient.d.ts.map +1 -1
  69. package/dist/features/ExampleRequest/ExampleRequest.vue.d.ts.map +1 -1
  70. package/dist/features/ExampleRequest/ExampleRequest.vue.js +1 -1
  71. package/dist/features/ExampleRequest/ExampleRequest.vue2.js +82 -74
  72. package/dist/features/ExampleResponses/ExampleResponse.vue.d.ts.map +1 -1
  73. package/dist/features/ExampleResponses/ExampleResponse.vue.js +2 -2
  74. package/dist/features/ExampleResponses/ExampleResponse.vue2.js +11 -11
  75. package/dist/features/ExampleResponses/ExampleResponses.vue.d.ts.map +1 -1
  76. package/dist/features/ExampleResponses/ExampleResponses.vue.js +2 -2
  77. package/dist/features/ExampleResponses/ExampleResponses.vue2.js +90 -78
  78. package/dist/features/Operation/components/ContentTypeSelect.vue.d.ts +1 -1
  79. package/dist/features/Operation/components/ContentTypeSelect.vue.d.ts.map +1 -1
  80. package/dist/features/Operation/components/ContentTypeSelect.vue.js +1 -1
  81. package/dist/features/Operation/components/ContentTypeSelect.vue2.js +29 -25
  82. package/dist/features/Operation/components/ParameterListItem.vue.d.ts.map +1 -1
  83. package/dist/features/Operation/components/ParameterListItem.vue.js +1 -1
  84. package/dist/features/Operation/components/ParameterListItem.vue2.js +40 -47
  85. package/dist/features/Operation/components/RequestBody.vue.d.ts.map +1 -1
  86. package/dist/features/Operation/components/RequestBody.vue.js +2 -2
  87. package/dist/features/Operation/layouts/ClassicLayout.vue.d.ts.map +1 -1
  88. package/dist/features/Operation/layouts/ClassicLayout.vue.js +2 -2
  89. package/dist/features/Operation/layouts/ClassicLayout.vue2.js +54 -54
  90. package/dist/features/Operation/layouts/ModernLayout.vue.d.ts.map +1 -1
  91. package/dist/features/Operation/layouts/ModernLayout.vue.js +1 -1
  92. package/dist/features/Operation/layouts/ModernLayout.vue2.js +65 -67
  93. package/dist/helpers/get-request.d.ts +2 -1
  94. package/dist/helpers/get-request.d.ts.map +1 -1
  95. package/dist/helpers/index.d.ts +0 -1
  96. package/dist/helpers/index.d.ts.map +1 -1
  97. package/dist/hooks/index.d.ts +0 -1
  98. package/dist/hooks/index.d.ts.map +1 -1
  99. package/dist/hooks/useConfig.d.ts +3 -3
  100. package/dist/hooks/useConfig.d.ts.map +1 -1
  101. package/dist/hooks/useConfig.js +5 -4
  102. package/dist/hooks/useReactiveSpec.d.ts +8 -8
  103. package/dist/hooks/useSidebar.d.ts.map +1 -1
  104. package/dist/hooks/useSidebar.js +126 -116
  105. package/dist/index.js +56 -62
  106. package/dist/libs/operation.d.ts +15 -0
  107. package/dist/libs/operation.d.ts.map +1 -0
  108. package/dist/libs/operation.js +16 -0
  109. package/dist/standalone/lib/html-api.d.ts +3 -3
  110. package/dist/standalone/lib/html-api.d.ts.map +1 -1
  111. package/dist/stores/useHttpClientStore.d.ts +1 -1
  112. package/dist/stores/useHttpClientStore.d.ts.map +1 -1
  113. package/dist/style.css +1 -1
  114. package/dist/types.d.ts +20 -3
  115. package/dist/types.d.ts.map +1 -1
  116. package/package.json +13 -13
  117. package/dist/components/Content/Tag/Endpoints.vue.d.ts.map +0 -1
  118. package/dist/components/Content/Tag/Endpoints.vue.js +0 -7
  119. package/dist/components/Content/Tag/Endpoints.vue2.js +0 -161
  120. package/dist/helpers/operation.d.ts +0 -14
  121. package/dist/helpers/operation.d.ts.map +0 -1
  122. package/dist/helpers/operation.js +0 -18
  123. package/dist/hooks/useDeprecationWarnings.d.ts +0 -6
  124. package/dist/hooks/useDeprecationWarnings.d.ts.map +0 -1
  125. package/dist/hooks/useDeprecationWarnings.js +0 -20
  126. package/dist/standalone/lib/html-rendering.d.ts +0 -51
  127. package/dist/standalone/lib/html-rendering.d.ts.map +0 -1
  128. package/dist/standalone/lib/html-rendering.js +0 -54
@@ -1,60 +1,61 @@
1
- import { defineComponent as d, ref as m, watch as p, nextTick as u, openBlock as a, createElementBlock as f, createElementVNode as v, normalizeClass as h, createVNode as i, unref as b, withCtx as n, renderSlot as r, createBlock as C, createCommentVNode as k } from "vue";
2
- import { ScalarIcon as g } from "@scalar/components";
3
- import S from "../Anchor/Anchor.vue.js";
4
- import _ from "./Section.vue.js";
5
- import { useNavState as w } from "../../hooks/useNavState.js";
6
- import { scrollToId as N } from "../../helpers/scrollToId.js";
7
- const B = ["aria-expanded"], V = ["id"], A = /* @__PURE__ */ d({
1
+ import { defineComponent as u, ref as m, useId as f, watch as v, nextTick as h, openBlock as n, createElementBlock as b, createElementVNode as C, unref as t, normalizeClass as k, createVNode as r, withCtx as s, renderSlot as c, createBlock as g, createCommentVNode as S } from "vue";
2
+ import { ScalarIcon as _ } from "@scalar/components";
3
+ import w from "../Anchor/Anchor.vue.js";
4
+ import N from "./Section.vue.js";
5
+ import { useNavState as y } from "../../hooks/useNavState.js";
6
+ import { scrollToId as B } from "../../helpers/scrollToId.js";
7
+ const I = { class: "collapsible-section" }, V = ["id", "aria-controls", "aria-expanded"], R = /* @__PURE__ */ u({
8
8
  __name: "CompactSection",
9
9
  props: {
10
10
  id: {},
11
11
  label: {}
12
12
  },
13
- setup(s) {
14
- const t = s, { hash: c } = w(), e = m(!1);
15
- return p(
16
- c,
13
+ setup(d) {
14
+ const a = d, { hash: p } = y(), e = m(!1), l = f();
15
+ return v(
16
+ p,
17
17
  async (o) => {
18
- o === t.id && !e.value && (e.value = !0, await u(), N(t.id));
18
+ o === a.id && !e.value && (e.value = !0, await h(), B(a.id));
19
19
  },
20
20
  { immediate: !0 }
21
- ), (o, l) => (a(), f("div", {
22
- "aria-expanded": e.value,
23
- class: "collapsible-section"
24
- }, [
25
- v("div", {
21
+ ), (o, i) => (n(), b("div", I, [
22
+ C("button", {
26
23
  id: o.id,
27
- class: h(["collapsible-section-trigger", { "collapsible-section-trigger-open": e.value }]),
28
- onClick: l[0] || (l[0] = ($) => e.value = !e.value)
24
+ "aria-controls": t(l),
25
+ "aria-expanded": e.value,
26
+ class: k(["collapsible-section-trigger", { "collapsible-section-trigger-open": e.value }]),
27
+ type: "button",
28
+ onClick: i[0] || (i[0] = ($) => e.value = !e.value)
29
29
  }, [
30
- i(b(g), {
30
+ r(t(_), {
31
31
  icon: e.value ? "ChevronDown" : "ChevronRight",
32
32
  size: "md",
33
33
  thickness: "1.5"
34
34
  }, null, 8, ["icon"]),
35
- i(S, {
35
+ r(w, {
36
36
  id: o.id,
37
37
  class: "collapsible-section-header"
38
38
  }, {
39
- default: n(() => [
40
- r(o.$slots, "heading", {}, void 0, !0)
39
+ default: s(() => [
40
+ c(o.$slots, "heading", {}, void 0, !0)
41
41
  ]),
42
42
  _: 3
43
43
  }, 8, ["id"])
44
44
  ], 10, V),
45
- e.value ? (a(), C(_, {
45
+ e.value ? (n(), g(N, {
46
46
  key: 0,
47
+ id: t(l),
47
48
  class: "collapsible-section-content",
48
49
  label: o.label
49
50
  }, {
50
- default: n(() => [
51
- r(o.$slots, "default", {}, void 0, !0)
51
+ default: s(() => [
52
+ c(o.$slots, "default", {}, void 0, !0)
52
53
  ]),
53
54
  _: 3
54
- }, 8, ["label"])) : k("", !0)
55
- ], 8, B));
55
+ }, 8, ["id", "label"])) : S("", !0)
56
+ ]));
56
57
  }
57
58
  });
58
59
  export {
59
- A as default
60
+ R as default
60
61
  };
package/dist/esm.d.ts CHANGED
@@ -1,17 +1,19 @@
1
- import type { ReferenceConfiguration, SpecConfiguration } from '@scalar/types/legacy';
1
+ import type { SpecConfiguration } from '@scalar/types/legacy';
2
+ import type { ApiReferenceConfiguration } from '@scalar/types/api-reference';
3
+ import type { ReferenceConfiguration } from '@scalar/types/legacy';
2
4
  /** Initialize Scalar References */
3
5
  export declare function createScalarReferences(
4
6
  /** Element to mount the references to */
5
7
  el: HTMLElement | null,
6
8
  /** Configuration object for Scalar References */
7
- initialConfig: ReferenceConfiguration,
9
+ initialConfig: ApiReferenceConfiguration | ReferenceConfiguration,
8
10
  /**
9
11
  * Will attempt to mount the references immediately
10
12
  * For SSR this may need to be blocked and done client side
11
13
  */
12
14
  mountOnInitialize?: boolean): {
13
15
  /** Update the configuration for a mounted reference */
14
- updateConfig(newConfig: ReferenceConfiguration, mergeConfigs?: boolean): void;
16
+ updateConfig(newConfig: ApiReferenceConfiguration | ReferenceConfiguration, mergeConfigs?: boolean): void;
15
17
  updateSpec(spec: SpecConfiguration): void;
16
18
  /** Mount the references to a given element */
17
19
  mount: (mountingEl?: HTMLElement | null) => void;
package/dist/esm.d.ts.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"esm.d.ts","sourceRoot":"","sources":["../src/esm.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,sBAAsB,EAAE,iBAAiB,EAAE,MAAM,sBAAsB,CAAA;AAMrF,mCAAmC;AACnC,wBAAgB,sBAAsB;AACpC,yCAAyC;AACzC,EAAE,EAAE,WAAW,GAAG,IAAI;AACtB,iDAAiD;AACjD,aAAa,EAAE,sBAAsB;AACrC;;;GAGG;AACH,iBAAiB,UAAO;IAoBtB,uDAAuD;4BAC/B,sBAAsB;qBAO7B,iBAAiB;IAGlC,8CAA8C;;IAE9C,sCAAsC;;EAGzC"}
1
+ {"version":3,"file":"esm.d.ts","sourceRoot":"","sources":["../src/esm.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,sBAAsB,CAAA;AAI7D,OAAO,KAAK,EAAE,yBAAyB,EAAE,MAAM,6BAA6B,CAAA;AAC5E,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,sBAAsB,CAAA;AAIlE,mCAAmC;AACnC,wBAAgB,sBAAsB;AACpC,yCAAyC;AACzC,EAAE,EAAE,WAAW,GAAG,IAAI;AACtB,iDAAiD;AACjD,aAAa,EAAE,yBAAyB,GAAG,sBAAsB;AACjE;;;GAGG;AACH,iBAAiB,UAAO;IAoBtB,uDAAuD;4BAC/B,yBAAyB,GAAG,sBAAsB;qBAOzD,iBAAiB;IAGlC,8CAA8C;;IAE9C,sCAAsC;;EAGzC"}
@@ -1,6 +1,6 @@
1
- import type { ClientConfiguration } from '@scalar/api-client/libs';
1
+ import type { ApiClientConfiguration } from '@scalar/types/api-reference';
2
2
  type __VLS_Props = {
3
- configuration: ClientConfiguration;
3
+ configuration: Partial<ApiClientConfiguration>;
4
4
  };
5
5
  declare const _default: import("vue").DefineComponent<__VLS_Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, HTMLDivElement>;
6
6
  export default _default;
@@ -1 +1 @@
1
- {"version":3,"file":"ApiClientModal.vue.d.ts","sourceRoot":"","sources":["../../../src/features/ApiClientModal/ApiClientModal.vue"],"names":[],"mappings":"AAoDA,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,yBAAyB,CAAA;AAUlE,KAAK,WAAW,GAAG;IACjB,aAAa,EAAE,mBAAmB,CAAA;CACnC,CAAC;;AA2FF,wBAOG"}
1
+ {"version":3,"file":"ApiClientModal.vue.d.ts","sourceRoot":"","sources":["../../../src/features/ApiClientModal/ApiClientModal.vue"],"names":[],"mappings":"AAqDA,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,6BAA6B,CAAA;AASzE,KAAK,WAAW,GAAG;IACjB,aAAa,EAAE,OAAO,CAAC,sBAAsB,CAAC,CAAA;CAC/C,CAAC;;AA2FF,wBAOG"}