@scalar/api-reference 1.25.102 → 1.25.103

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.
@@ -6,11 +6,13 @@ type __VLS_Props = {
6
6
  compact?: boolean;
7
7
  description?: string;
8
8
  additional?: boolean;
9
+ withExamples?: boolean;
9
10
  };
10
11
  declare const _default_1: import("vue").DefineComponent<__VLS_Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {
11
12
  required: boolean;
12
13
  level: number;
13
14
  compact: boolean;
15
+ withExamples: boolean;
14
16
  }, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, HTMLDivElement>;
15
17
  export default _default_1;
16
18
  //# sourceMappingURL=SchemaProperty.vue.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"SchemaProperty.vue.d.ts","sourceRoot":"","sources":["../../../../src/components/Content/Schema/SchemaProperty.vue"],"names":[],"mappings":"AAmbA,KAAK,WAAW,GAAG;IACf,KAAK,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAA;IAC3B,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,IAAI,CAAC,EAAE,MAAM,CAAA;IACb,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,OAAO,CAAC,EAAE,OAAO,CAAA;IACjB,WAAW,CAAC,EAAE,MAAM,CAAA;IACpB,UAAU,CAAC,EAAE,OAAO,CAAA;CACrB,CAAC;;cAJW,OAAO;WAFV,MAAM;aAGJ,OAAO;;AA8YrB,0BAQG"}
1
+ {"version":3,"file":"SchemaProperty.vue.d.ts","sourceRoot":"","sources":["../../../../src/components/Content/Schema/SchemaProperty.vue"],"names":[],"mappings":"AAibA,KAAK,WAAW,GAAG;IACf,KAAK,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAA;IAC3B,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,IAAI,CAAC,EAAE,MAAM,CAAA;IACb,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,OAAO,CAAC,EAAE,OAAO,CAAA;IACjB,WAAW,CAAC,EAAE,MAAM,CAAA;IACpB,UAAU,CAAC,EAAE,OAAO,CAAA;IACpB,YAAY,CAAC,EAAE,OAAO,CAAA;CACvB,CAAC;;cALW,OAAO;WAFV,MAAM;aAGJ,OAAO;kBAGF,OAAO;;AAwY1B,0BAQG"}
@@ -1,7 +1,7 @@
1
1
  import o from "./SchemaProperty.vue2.js";
2
2
  /* empty css */
3
3
  import r from "../../../_virtual/_plugin-vue_export-helper.js";
4
- const a = /* @__PURE__ */ r(o, [["__scopeId", "data-v-96221229"]]);
4
+ const p = /* @__PURE__ */ r(o, [["__scopeId", "data-v-32801e8b"]]);
5
5
  export {
6
- a as default
6
+ p as default
7
7
  };
@@ -1,4 +1,5 @@
1
- import { defineComponent as W, computed as y, openBlock as l, createElementBlock as t, normalizeClass as Z, createVNode as r, createSlots as X, withCtx as v, createTextVNode as b, toDisplayString as s, unref as p, createCommentVNode as n, createElementVNode as c, Fragment as i, renderList as d, createBlock as E } from "vue";
1
+ import { defineComponent as Q, computed as y, openBlock as l, createElementBlock as t, normalizeClass as M, createVNode as n, createSlots as W, withCtx as v, createTextVNode as b, toDisplayString as r, unref as u, createCommentVNode as s, createElementVNode as c, Fragment as i, renderList as m, createBlock as E } from "vue";
2
+ import { formatExample as X } from "./helpers/formatExample.js";
2
3
  import { Disclosure as Y, DisclosurePanel as _, DisclosureButton as x } from "@headlessui/vue";
3
4
  import { ScalarMarkdown as S, ScalarIcon as ee } from "@scalar/components";
4
5
  import f from "./Schema.vue.js";
@@ -12,16 +13,16 @@ const te = {
12
13
  }, oe = {
13
14
  key: 2,
14
15
  class: "property-example custom-scroll"
15
- }, ne = { class: "property-example-value" }, re = {
16
+ }, se = { class: "property-example-value" }, ne = {
16
17
  key: 3,
17
18
  class: "property-example custom-scroll"
18
- }, se = { class: "property-example-label" }, ie = {
19
+ }, re = { class: "property-example-label" }, ie = {
19
20
  key: 4,
20
21
  class: "property-enum"
21
22
  }, ue = {
22
23
  key: 0,
23
24
  class: "property-list"
24
- }, pe = { class: "property-heading" }, de = { class: "property-name" }, me = { class: "property-description" }, ce = {
25
+ }, pe = { class: "property-heading" }, me = { class: "property-name" }, de = { class: "property-description" }, ce = {
25
26
  key: 1,
26
27
  class: "property-enum-values"
27
28
  }, ve = {
@@ -36,7 +37,7 @@ const te = {
36
37
  }, he = {
37
38
  key: 1,
38
39
  class: "property-rule"
39
- }, Be = /* @__PURE__ */ W({
40
+ }, De = /* @__PURE__ */ Q({
40
41
  __name: "SchemaProperty",
41
42
  props: {
42
43
  value: {},
@@ -45,10 +46,11 @@ const te = {
45
46
  required: { type: Boolean, default: !1 },
46
47
  compact: { type: Boolean, default: !1 },
47
48
  description: {},
48
- additional: { type: Boolean }
49
+ additional: { type: Boolean },
50
+ withExamples: { type: Boolean, default: !0 }
49
51
  },
50
- setup(M) {
51
- const h = M, B = {
52
+ setup($) {
53
+ const h = $, B = {
52
54
  integer: {
53
55
  _default: "Integer numbers.",
54
56
  int32: "Signed 32-bit integers (commonly used integer type).",
@@ -61,152 +63,152 @@ const te = {
61
63
  byte: "base64-encoded characters, for example, U3dhZ2dlciByb2Nrcw==",
62
64
  binary: "binary data, used to describe files"
63
65
  }
64
- }, D = function(e, a) {
65
- return a != null && a.properties || a != null && a.additionalProperties ? null : e || (a == null ? void 0 : a.description) || null;
66
- }, C = function(e) {
66
+ }, D = function(e, o) {
67
+ return o != null && o.properties || o != null && o.additionalProperties ? null : e || (o == null ? void 0 : o.description) || null;
68
+ }, w = function(e) {
67
69
  return !e || !B[e.type] ? null : B[e.type][e.format || "_default"];
68
- }, m = function(e) {
69
- var a;
70
- return (e == null ? void 0 : e.enum) || ((a = e == null ? void 0 : e.items) == null ? void 0 : a.enum) || [];
71
- }, G = ["oneOf", "anyOf", "allOf", "not"], j = y(() => m(h.value).length > 9), P = y(() => j.value ? 5 : 9), J = y(
72
- () => m(h.value).slice(0, P.value)
70
+ }, d = function(e) {
71
+ var o;
72
+ return (e == null ? void 0 : e.enum) || ((o = e == null ? void 0 : e.items) == null ? void 0 : o.enum) || [];
73
+ }, G = ["oneOf", "anyOf", "allOf", "not"], C = y(() => d(h.value).length > 9), P = y(() => C.value ? 5 : 9), J = y(
74
+ () => d(h.value).slice(0, P.value)
73
75
  ), K = y(
74
- () => m(h.value).slice(P.value)
75
- ), Q = (e) => Array.isArray(e) ? `[${e.map((a) => `"${a.trim()}"`).join(", ")}]` : e;
76
- return (e, a) => {
77
- var w, N, O, q, F, A, I, L, V, $, z, H, R;
76
+ () => d(h.value).slice(P.value)
77
+ );
78
+ return (e, o) => {
79
+ var j, N, O, q, F, I, L, V, z, H, R, T, U;
78
80
  return l(), t("div", {
79
- class: Z(["property", [
81
+ class: M(["property", [
80
82
  `property--level-${e.level}`,
81
83
  {
82
84
  "property--compact": e.compact,
83
- "property--deprecated": (w = e.value) == null ? void 0 : w.deprecated
85
+ "property--deprecated": (j = e.value) == null ? void 0 : j.deprecated
84
86
  }
85
87
  ]])
86
88
  }, [
87
- r(le, {
89
+ n(le, {
88
90
  additional: e.additional,
89
- enum: m(e.value).length > 0,
91
+ enum: d(e.value).length > 0,
90
92
  required: e.required,
91
93
  value: e.value
92
- }, X({ _: 2 }, [
94
+ }, W({ _: 2 }, [
93
95
  e.name ? {
94
96
  name: "name",
95
97
  fn: v(() => [
96
- b(s(e.name), 1)
98
+ b(r(e.name), 1)
97
99
  ]),
98
100
  key: "0"
99
101
  } : void 0,
100
102
  (N = e.value) != null && N.example ? {
101
103
  name: "example",
102
104
  fn: v(() => [
103
- b(" Example: " + s(e.value.example), 1)
105
+ b(" Example: " + r(e.value.example), 1)
104
106
  ]),
105
107
  key: "1"
106
108
  } : void 0
107
109
  ]), 1032, ["additional", "enum", "required", "value"]),
108
110
  D(e.description, e.value) ? (l(), t("div", te, [
109
- r(p(S), {
111
+ n(u(S), {
110
112
  value: D(e.description, e.value)
111
113
  }, null, 8, ["value"])
112
- ])) : C(e.value) ? (l(), t("div", ae, [
113
- r(p(S), {
114
- value: C(e.value) || ""
114
+ ])) : w(e.value) ? (l(), t("div", ae, [
115
+ n(u(S), {
116
+ value: w(e.value) || ""
115
117
  }, null, 8, ["value"])
116
- ])) : n("", !0),
117
- (O = e.value) != null && O.example || (F = (q = e.value) == null ? void 0 : q.items) != null && F.example ? (l(), t("div", oe, [
118
- a[0] || (a[0] = c("span", { class: "property-example-label" }, "Example", -1)),
119
- c("code", ne, s(Q(e.value.example || ((A = e.value) == null ? void 0 : A.items.example))), 1)
120
- ])) : n("", !0),
121
- (I = e.value) != null && I.examples && typeof e.value.examples == "object" && Object.keys(e.value.examples).length > 0 ? (l(), t("div", re, [
122
- c("span", se, s(Object.keys(e.value.examples).length === 1 ? "Example" : "Examples"), 1),
123
- (l(!0), t(i, null, d(e.value.examples, (o, u) => (l(), t("code", {
124
- key: u,
118
+ ])) : s("", !0),
119
+ e.withExamples && ((O = e.value) != null && O.example || (F = (q = e.value) == null ? void 0 : q.items) != null && F.example) ? (l(), t("div", oe, [
120
+ o[0] || (o[0] = c("span", { class: "property-example-label" }, "Example", -1)),
121
+ c("code", se, r(u(X)(e.value.example || ((I = e.value) == null ? void 0 : I.items.example))), 1)
122
+ ])) : s("", !0),
123
+ (L = e.value) != null && L.examples && typeof e.value.examples == "object" && Object.keys(e.value.examples).length > 0 ? (l(), t("div", ne, [
124
+ c("span", re, r(Object.keys(e.value.examples).length === 1 ? "Example" : "Examples"), 1),
125
+ (l(!0), t(i, null, m(e.value.examples, (a, p) => (l(), t("code", {
126
+ key: p,
125
127
  class: "property-example-value"
126
- }, s(o), 1))), 128))
127
- ])) : n("", !0),
128
- ((L = m(e.value)) == null ? void 0 : L.length) > 0 ? (l(), t("div", ie, [
129
- (V = e.value) != null && V["x-enumDescriptions"] ? (l(), t("div", ue, [
130
- (l(!0), t(i, null, d(m(e.value), (o) => (l(), t("div", {
131
- key: o,
128
+ }, r(a), 1))), 128))
129
+ ])) : s("", !0),
130
+ ((V = d(e.value)) == null ? void 0 : V.length) > 0 ? (l(), t("div", ie, [
131
+ (z = e.value) != null && z["x-enumDescriptions"] ? (l(), t("div", ue, [
132
+ (l(!0), t(i, null, m(d(e.value), (a) => (l(), t("div", {
133
+ key: a,
132
134
  class: "property"
133
135
  }, [
134
136
  c("div", pe, [
135
- c("div", de, s(o), 1)
137
+ c("div", me, r(a), 1)
136
138
  ]),
137
- c("div", me, [
138
- r(p(S), {
139
- value: e.value["x-enumDescriptions"][o]
139
+ c("div", de, [
140
+ n(u(S), {
141
+ value: e.value["x-enumDescriptions"][a]
140
142
  }, null, 8, ["value"])
141
143
  ])
142
144
  ]))), 128))
143
145
  ])) : (l(), t("ul", ce, [
144
- (l(!0), t(i, null, d(J.value, (o) => (l(), t("li", {
145
- key: o,
146
+ (l(!0), t(i, null, m(J.value, (a) => (l(), t("li", {
147
+ key: a,
146
148
  class: "property-enum-value"
147
- }, s(o), 1))), 128)),
148
- j.value ? (l(), E(p(Y), { key: 0 }, {
149
- default: v(({ open: o }) => [
150
- r(p(_), null, {
149
+ }, r(a), 1))), 128)),
150
+ C.value ? (l(), E(u(Y), { key: 0 }, {
151
+ default: v(({ open: a }) => [
152
+ n(u(_), null, {
151
153
  default: v(() => [
152
- (l(!0), t(i, null, d(K.value, (u) => (l(), t("li", {
153
- key: u,
154
+ (l(!0), t(i, null, m(K.value, (p) => (l(), t("li", {
155
+ key: p,
154
156
  class: "property-enum-value"
155
- }, s(u), 1))), 128))
157
+ }, r(p), 1))), 128))
156
158
  ]),
157
159
  _: 1
158
160
  }),
159
- r(p(x), { class: "enum-toggle-button" }, {
161
+ n(u(x), { class: "enum-toggle-button" }, {
160
162
  default: v(() => [
161
- r(p(ee), {
162
- class: Z(["enum-toggle-button-icon", { "enum-toggle-button-icon--open": o }]),
163
+ n(u(ee), {
164
+ class: M(["enum-toggle-button-icon", { "enum-toggle-button-icon--open": a }]),
163
165
  icon: "Add",
164
166
  size: "sm"
165
167
  }, null, 8, ["class"]),
166
- b(" " + s(o ? "Hide values" : "Show all values"), 1)
168
+ b(" " + r(a ? "Hide values" : "Show all values"), 1)
167
169
  ]),
168
170
  _: 2
169
171
  }, 1024)
170
172
  ]),
171
173
  _: 1
172
- })) : n("", !0)
174
+ })) : s("", !0)
173
175
  ]))
174
- ])) : n("", !0),
175
- (($ = e.value) == null ? void 0 : $.type) === "object" && ((z = e.value) != null && z.properties || (H = e.value) != null && H.additionalProperties) ? (l(), t("div", ve, [
176
- r(f, {
176
+ ])) : s("", !0),
177
+ ((H = e.value) == null ? void 0 : H.type) === "object" && ((R = e.value) != null && R.properties || (T = e.value) != null && T.additionalProperties) ? (l(), t("div", ve, [
178
+ n(f, {
177
179
  compact: e.compact,
178
180
  level: e.level + 1,
179
181
  value: e.value
180
182
  }, null, 8, ["compact", "level", "value"])
181
- ])) : n("", !0),
182
- (R = e.value) != null && R.items ? (l(), t(i, { key: 6 }, [
183
+ ])) : s("", !0),
184
+ (U = e.value) != null && U.items ? (l(), t(i, { key: 6 }, [
183
185
  ["object"].includes(e.value.items.type) ? (l(), t("div", ye, [
184
- r(f, {
186
+ n(f, {
185
187
  compact: e.compact,
186
188
  level: e.level + 1,
187
189
  value: e.value.items
188
190
  }, null, 8, ["compact", "level", "value"])
189
- ])) : n("", !0)
190
- ], 64)) : n("", !0),
191
- (l(), t(i, null, d(G, (o) => {
192
- var u, T, U;
193
- return l(), t(i, { key: o }, [
194
- (u = e.value) != null && u[o] ? (l(), t("div", fe, [
195
- (l(!0), t(i, null, d(e.value[o], (g, k) => (l(), E(f, {
191
+ ])) : s("", !0)
192
+ ], 64)) : s("", !0),
193
+ (l(), t(i, null, m(G, (a) => {
194
+ var p, Z, A;
195
+ return l(), t(i, { key: a }, [
196
+ (p = e.value) != null && p[a] ? (l(), t("div", fe, [
197
+ (l(!0), t(i, null, m(e.value[a], (g, k) => (l(), E(f, {
196
198
  key: k,
197
199
  compact: e.compact,
198
200
  level: e.level + 1,
199
201
  value: g
200
202
  }, null, 8, ["compact", "level", "value"]))), 128))
201
- ])) : n("", !0),
202
- (U = (T = e.value) == null ? void 0 : T.items) != null && U[o] && e.level < 3 ? (l(), t("div", he, [
203
- (l(!0), t(i, null, d(e.value.items[o], (g, k) => (l(), E(f, {
203
+ ])) : s("", !0),
204
+ (A = (Z = e.value) == null ? void 0 : Z.items) != null && A[a] && e.level < 3 ? (l(), t("div", he, [
205
+ (l(!0), t(i, null, m(e.value.items[a], (g, k) => (l(), E(f, {
204
206
  key: k,
205
207
  compact: e.compact,
206
208
  level: e.level + 1,
207
209
  value: g
208
210
  }, null, 8, ["compact", "level", "value"]))), 128))
209
- ])) : n("", !0)
211
+ ])) : s("", !0)
210
212
  ], 64);
211
213
  }), 64))
212
214
  ], 2);
@@ -214,5 +216,5 @@ const te = {
214
216
  }
215
217
  });
216
218
  export {
217
- Be as default
219
+ De as default
218
220
  };
@@ -0,0 +1,5 @@
1
+ /**
2
+ * Converts an example value to a string that can be displayed in the UI.
3
+ */
4
+ export declare function formatExample(example: unknown): string | number;
5
+ //# sourceMappingURL=formatExample.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"formatExample.d.ts","sourceRoot":"","sources":["../../../../../src/components/Content/Schema/helpers/formatExample.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,wBAAgB,aAAa,CAAC,OAAO,EAAE,OAAO,GAAG,MAAM,GAAG,MAAM,CA0C/D"}
@@ -0,0 +1,6 @@
1
+ function t(r) {
2
+ return Array.isArray(r) ? `[${r.map((n) => typeof n == "string" || typeof n == "number" ? `"${n.toString().trim()}"` : typeof n == "object" ? JSON.stringify(n) : n === void 0 ? "undefined" : n === null ? "null" : n).join(", ")}]` : typeof r == "object" ? JSON.stringify(r) : r === null ? "null" : r === void 0 ? "undefined" : typeof r == "string" ? r.trim() : r.toString().trim();
3
+ }
4
+ export {
5
+ t as formatExample
6
+ };
@@ -1 +1 @@
1
- {"version":3,"file":"OperationResponses.vue.d.ts","sourceRoot":"","sources":["../../../../src/features/Operation/components/OperationResponses.vue"],"names":[],"mappings":"AA2BA,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,sBAAsB,CAAA;AAOhE,KAAK,WAAW,GAAG;IACf,SAAS,EAAE,oBAAoB,CAAA;IAC/B,gBAAgB,CAAC,EAAE,OAAO,CAAA;CAC3B,CAAC;;sBADmB,OAAO;;AA8E9B,wBAQG"}
1
+ {"version":3,"file":"OperationResponses.vue.d.ts","sourceRoot":"","sources":["../../../../src/features/Operation/components/OperationResponses.vue"],"names":[],"mappings":"AA4BA,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,sBAAsB,CAAA;AAOhE,KAAK,WAAW,GAAG;IACf,SAAS,EAAE,oBAAoB,CAAA;IAC/B,gBAAgB,CAAC,EAAE,OAAO,CAAA;CAC3B,CAAC;;sBADmB,OAAO;;AA8E9B,wBAQG"}
@@ -1,17 +1,18 @@
1
- import { defineComponent as p, openBlock as a, createBlock as n, unref as l, withCtx as m, createTextVNode as i } from "vue";
1
+ import { defineComponent as a, openBlock as p, createBlock as l, unref as n, withCtx as m, createTextVNode as i } from "vue";
2
2
  import { useResponses as c } from "../hooks/useResponses.js";
3
3
  import f from "./ParameterList.vue.js";
4
- const I = /* @__PURE__ */ p({
4
+ const x = /* @__PURE__ */ a({
5
5
  __name: "OperationResponses",
6
6
  props: {
7
7
  operation: {},
8
8
  collapsableItems: { type: Boolean, default: !0 }
9
9
  },
10
- setup(o) {
11
- const t = o, { responses: s } = c(t.operation);
12
- return (r, e) => (a(), n(f, {
10
+ setup(s) {
11
+ const t = s, { responses: o } = c(t.operation);
12
+ return (r, e) => (p(), l(f, {
13
13
  collapsableItems: r.collapsableItems,
14
- parameters: l(s)
14
+ parameters: n(o),
15
+ withExamples: !1
15
16
  }, {
16
17
  title: m(() => e[0] || (e[0] = [
17
18
  i("Responses")
@@ -21,5 +22,5 @@ const I = /* @__PURE__ */ p({
21
22
  }
22
23
  });
23
24
  export {
24
- I as default
25
+ x as default
25
26
  };
@@ -3,6 +3,7 @@ type __VLS_Props = {
3
3
  parameters?: Parameter[];
4
4
  showChildren?: boolean;
5
5
  collapsableItems?: boolean;
6
+ withExamples?: boolean;
6
7
  };
7
8
  declare function __VLS_template(): {
8
9
  attrs: Partial<{}>;
@@ -14,6 +15,7 @@ declare function __VLS_template(): {
14
15
  };
15
16
  type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
16
17
  declare const __VLS_component: import("vue").DefineComponent<__VLS_Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {
18
+ withExamples: boolean;
17
19
  showChildren: boolean;
18
20
  collapsableItems: boolean;
19
21
  }, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
@@ -1 +1 @@
1
- {"version":3,"file":"ParameterList.vue.d.ts","sourceRoot":"","sources":["../../../../src/features/Operation/components/ParameterList.vue"],"names":[],"mappings":"AA0DA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,sBAAsB,CAAA;AAMrD,KAAK,WAAW,GAAG;IACf,UAAU,CAAC,EAAE,SAAS,EAAE,CAAA;IACxB,YAAY,CAAC,EAAE,OAAO,CAAA;IACtB,gBAAgB,CAAC,EAAE,OAAO,CAAA;CAC3B,CAAC;AAkBJ,iBAAS,cAAc;WAsDT,OAAO,IAA6B;;uBARvB,GAAG;;;;EAa7B;AAUD,KAAK,oBAAoB,GAAG,UAAU,CAAC,OAAO,cAAc,CAAC,CAAC;AAC9D,QAAA,MAAM,eAAe;kBA1FF,OAAO;sBACH,OAAO;6EAgG5B,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"}
1
+ {"version":3,"file":"ParameterList.vue.d.ts","sourceRoot":"","sources":["../../../../src/features/Operation/components/ParameterList.vue"],"names":[],"mappings":"AA6DA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,sBAAsB,CAAA;AAMrD,KAAK,WAAW,GAAG;IACf,UAAU,CAAC,EAAE,SAAS,EAAE,CAAA;IACxB,YAAY,CAAC,EAAE,OAAO,CAAA;IACtB,gBAAgB,CAAC,EAAE,OAAO,CAAA;IAC1B,YAAY,CAAC,EAAE,OAAO,CAAA;CACvB,CAAC;AAoBJ,iBAAS,cAAc;WAsDT,OAAO,IAA6B;;uBARvB,GAAG;;;;EAa7B;AAUD,KAAK,oBAAoB,GAAG,UAAU,CAAC,OAAO,cAAc,CAAC,CAAC;AAC9D,QAAA,MAAM,eAAe;kBA3FF,OAAO;kBAFP,OAAO;sBACH,OAAO;6EAmG5B,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"}
@@ -1,7 +1,7 @@
1
1
  import t from "./ParameterList.vue2.js";
2
2
  /* empty css */
3
- import o from "../../../_virtual/_plugin-vue_export-helper.js";
4
- const e = /* @__PURE__ */ o(t, [["__scopeId", "data-v-835fb005"]]);
3
+ import a from "../../../_virtual/_plugin-vue_export-helper.js";
4
+ const e = /* @__PURE__ */ a(t, [["__scopeId", "data-v-dba0156a"]]);
5
5
  export {
6
6
  e as default
7
7
  };
@@ -1,34 +1,36 @@
1
- import { defineComponent as o, openBlock as t, createElementBlock as l, createElementVNode as s, renderSlot as n, Fragment as m, renderList as p, createBlock as i, createCommentVNode as d } from "vue";
2
- import c from "./ParameterListItem.vue.js";
3
- const h = {
1
+ import { defineComponent as o, openBlock as t, createElementBlock as r, createElementVNode as s, renderSlot as m, Fragment as n, renderList as p, createBlock as i, createCommentVNode as d } from "vue";
2
+ import h from "./ParameterListItem.vue.js";
3
+ const c = {
4
4
  key: 0,
5
5
  class: "parameter-list"
6
- }, u = { class: "parameter-list-title" }, f = { class: "parameter-list-items" }, I = /* @__PURE__ */ o({
6
+ }, u = { class: "parameter-list-title" }, f = { class: "parameter-list-items" }, E = /* @__PURE__ */ o({
7
7
  __name: "ParameterList",
8
8
  props: {
9
9
  parameters: {},
10
10
  showChildren: { type: Boolean, default: !1 },
11
- collapsableItems: { type: Boolean, default: !1 }
11
+ collapsableItems: { type: Boolean, default: !1 },
12
+ withExamples: { type: Boolean, default: !0 }
12
13
  },
13
- setup(_) {
14
- return (e, C) => {
15
- var r;
16
- return (r = e.parameters) != null && r.length ? (t(), l("div", h, [
14
+ setup(w) {
15
+ return (e, _) => {
16
+ var a;
17
+ return (a = e.parameters) != null && a.length ? (t(), r("div", c, [
17
18
  s("div", u, [
18
- n(e.$slots, "title", {}, void 0, !0)
19
+ m(e.$slots, "title", {}, void 0, !0)
19
20
  ]),
20
21
  s("ul", f, [
21
- (t(!0), l(m, null, p(e.parameters, (a) => (t(), i(c, {
22
- key: a.name,
22
+ (t(!0), r(n, null, p(e.parameters, (l) => (t(), i(h, {
23
+ key: l.name,
23
24
  collapsableItems: e.collapsableItems,
24
- parameter: a,
25
- showChildren: e.showChildren
26
- }, null, 8, ["collapsableItems", "parameter", "showChildren"]))), 128))
25
+ parameter: l,
26
+ showChildren: e.showChildren,
27
+ withExamples: e.withExamples
28
+ }, null, 8, ["collapsableItems", "parameter", "showChildren", "withExamples"]))), 128))
27
29
  ])
28
30
  ])) : d("", !0);
29
31
  };
30
32
  }
31
33
  });
32
34
  export {
33
- I as default
35
+ E as default
34
36
  };
@@ -3,8 +3,10 @@ type __VLS_Props = {
3
3
  parameter: Parameter;
4
4
  showChildren?: boolean;
5
5
  collapsableItems?: boolean;
6
+ withExamples?: boolean;
6
7
  };
7
8
  declare const _default: import("vue").DefineComponent<__VLS_Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {
9
+ withExamples: boolean;
8
10
  showChildren: boolean;
9
11
  collapsableItems: boolean;
10
12
  }, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, HTMLLIElement>;
@@ -1 +1 @@
1
- {"version":3,"file":"ParameterListItem.vue.d.ts","sourceRoot":"","sources":["../../../../src/features/Operation/components/ParameterListItem.vue"],"names":[],"mappings":"AAmOA,OAAO,KAAK,EAAe,SAAS,EAAE,MAAM,sBAAsB,CAAA;AAQlE,KAAK,WAAW,GAAG;IACf,SAAS,EAAE,SAAS,CAAA;IACpB,YAAY,CAAC,EAAE,OAAO,CAAA;IACtB,gBAAgB,CAAC,EAAE,OAAO,CAAA;CAC3B,CAAC;;kBAFe,OAAO;sBACH,OAAO;;AA6O9B,wBAQG"}
1
+ {"version":3,"file":"ParameterListItem.vue.d.ts","sourceRoot":"","sources":["../../../../src/features/Operation/components/ParameterListItem.vue"],"names":[],"mappings":"AAsOA,OAAO,KAAK,EAAe,SAAS,EAAE,MAAM,sBAAsB,CAAA;AAQlE,KAAK,WAAW,GAAG;IACf,SAAS,EAAE,SAAS,CAAA;IACpB,YAAY,CAAC,EAAE,OAAO,CAAA;IACtB,gBAAgB,CAAC,EAAE,OAAO,CAAA;IAC1B,YAAY,CAAC,EAAE,OAAO,CAAA;CACvB,CAAC;;kBADe,OAAO;kBAFP,OAAO;sBACH,OAAO;;AAgP9B,wBAQG"}
@@ -1,7 +1,7 @@
1
1
  import t from "./ParameterListItem.vue2.js";
2
2
  /* empty css */
3
3
  import o from "../../../_virtual/_plugin-vue_export-helper.js";
4
- const e = /* @__PURE__ */ o(t, [["__scopeId", "data-v-9508a2d2"]]);
4
+ const e = /* @__PURE__ */ o(t, [["__scopeId", "data-v-ab978914"]]);
5
5
  export {
6
6
  e as default
7
7
  };
@@ -1,57 +1,58 @@
1
- import { defineComponent as k, computed as y, ref as B, openBlock as s, createElementBlock as g, createVNode as r, unref as n, withCtx as m, createBlock as i, normalizeClass as b, createTextVNode as S, toDisplayString as c, createElementVNode as u, createCommentVNode as d } from "vue";
2
- import V from "../../../components/ScreenReader.vue.js";
3
- import { Disclosure as q, DisclosureButton as w, DisclosurePanel as D } from "@headlessui/vue";
4
- import { ScalarIcon as T } from "@scalar/components";
5
- import _ from "./ContentTypeSelect.vue.js";
1
+ import { defineComponent as k, computed as y, ref as w, openBlock as s, createElementBlock as B, createVNode as r, unref as o, withCtx as m, createBlock as i, normalizeClass as g, createTextVNode as E, toDisplayString as c, createElementVNode as u, createCommentVNode as d } from "vue";
2
+ import b from "../../../components/ScreenReader.vue.js";
3
+ import { Disclosure as S, DisclosureButton as V, DisclosurePanel as q } from "@headlessui/vue";
4
+ import { ScalarIcon as D } from "@scalar/components";
5
+ import T from "./ContentTypeSelect.vue.js";
6
6
  import I from "./ParameterHeaders.vue.js";
7
7
  import N from "../../../components/Content/Schema/SchemaProperty.vue.js";
8
- const P = { class: "parameter-item" }, j = { class: "parameter-item-name" }, E = { class: "parameter-item-type" }, R = { class: "absolute right-0" }, J = /* @__PURE__ */ k({
8
+ const P = { class: "parameter-item" }, _ = { class: "parameter-item-name" }, j = { class: "parameter-item-type" }, R = { class: "absolute right-0" }, J = /* @__PURE__ */ k({
9
9
  __name: "ParameterListItem",
10
10
  props: {
11
11
  parameter: {},
12
12
  showChildren: { type: Boolean, default: !1 },
13
- collapsableItems: { type: Boolean, default: !1 }
13
+ collapsableItems: { type: Boolean, default: !1 },
14
+ withExamples: { type: Boolean, default: !0 }
14
15
  },
15
16
  setup(v) {
16
- const t = v, C = y(() => t.parameter.content ? Object.keys(t.parameter.content) : []), o = B(
17
+ const t = v, C = y(() => t.parameter.content ? Object.keys(t.parameter.content) : []), n = w(
17
18
  C.value[0]
18
19
  );
19
- t.parameter.content && "application/json" in t.parameter.content && (o.value = "application/json");
20
+ t.parameter.content && "application/json" in t.parameter.content && (n.value = "application/json");
20
21
  const a = y(() => !!(t.collapsableItems && t.parameter.content));
21
- return (e, f) => (s(), g("li", P, [
22
- r(n(q), null, {
22
+ return (e, f) => (s(), B("li", P, [
23
+ r(o(S), null, {
23
24
  default: m(({ open: p }) => [
24
- a.value ? (s(), i(n(w), {
25
+ a.value ? (s(), i(o(V), {
25
26
  key: 0,
26
- class: b(["flex parameter-item-trigger", { "parameter-item-trigger-open": p }])
27
+ class: g(["flex parameter-item-trigger", { "parameter-item-trigger-open": p }])
27
28
  }, {
28
29
  default: m(() => [
29
- r(n(T), {
30
+ r(o(D), {
30
31
  class: "parameter-item-icon",
31
32
  icon: p ? "ChevronDown" : "ChevronRight",
32
33
  thickness: "1.5"
33
34
  }, null, 8, ["icon"]),
34
- r(V, null, {
35
+ r(b, null, {
35
36
  default: m(() => [
36
- S(c(p ? "Collapse" : "Expand"), 1)
37
+ E(c(p ? "Collapse" : "Expand"), 1)
37
38
  ]),
38
39
  _: 2
39
40
  }, 1024),
40
- u("span", j, c(e.parameter.name), 1),
41
- u("span", E, c(e.parameter.description), 1),
41
+ u("span", _, c(e.parameter.name), 1),
42
+ u("span", j, c(e.parameter.description), 1),
42
43
  u("div", R, [
43
- a.value && t.parameter.content ? (s(), i(_, {
44
+ a.value && t.parameter.content ? (s(), i(T, {
44
45
  key: 0,
45
46
  class: "parameter-item-content-type",
46
- defaultValue: o.value,
47
+ defaultValue: n.value,
47
48
  requestBody: t.parameter,
48
- onSelectContentType: f[0] || (f[0] = ({ contentType: l }) => o.value = l)
49
+ onSelectContentType: f[0] || (f[0] = ({ contentType: l }) => n.value = l)
49
50
  }, null, 8, ["defaultValue", "requestBody"])) : d("", !0)
50
51
  ])
51
52
  ]),
52
53
  _: 2
53
54
  }, 1032, ["class"])) : d("", !0),
54
- r(n(D), {
55
+ r(o(q), {
55
56
  class: "parameter-item-container parameter-item-container-markdown",
56
57
  static: !a.value
57
58
  }, {
@@ -62,14 +63,15 @@ const P = { class: "parameter-item" }, j = { class: "parameter-item-name" }, E =
62
63
  key: 0,
63
64
  headers: e.parameter.headers
64
65
  }, null, 8, ["headers"])) : d("", !0),
65
- r(n(N), {
66
+ r(o(N), {
66
67
  compact: "",
67
68
  description: a.value ? "" : e.parameter.description,
68
69
  name: a.value ? "" : e.parameter.name,
69
70
  noncollapsible: e.showChildren,
70
71
  required: e.parameter.required,
71
- value: e.parameter.content ? (h = (l = e.parameter.content) == null ? void 0 : l[o.value]) == null ? void 0 : h.schema : e.parameter.schema
72
- }, null, 8, ["description", "name", "noncollapsible", "required", "value"])
72
+ value: e.parameter.content ? (h = (l = e.parameter.content) == null ? void 0 : l[n.value]) == null ? void 0 : h.schema : e.parameter.schema,
73
+ withExamples: e.withExamples
74
+ }, null, 8, ["description", "name", "noncollapsible", "required", "value", "withExamples"])
73
75
  ];
74
76
  }),
75
77
  _: 1