@scalar/blocks 0.11.1 → 0.11.2

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 (77) hide show
  1. package/CHANGELOG.md +8 -0
  2. package/dist/code-example/components/CodeExample.vue.d.ts.map +1 -1
  3. package/dist/code-example/components/CodeExample.vue.js +1 -1
  4. package/dist/code-example/components/CodeExample.vue_vue_type_script_setup_true_lang.js +60 -66
  5. package/dist/code-example/components/CodeExample.vue_vue_type_script_setup_true_lang.js.map +1 -1
  6. package/dist/code-example/helpers/operation-to-har/process-parameters.d.ts.map +1 -1
  7. package/dist/code-example/helpers/operation-to-har/process-parameters.js +105 -105
  8. package/dist/code-example/helpers/operation-to-har/process-parameters.js.map +1 -1
  9. package/dist/constants.js +1 -1
  10. package/dist/schema/SchemaProperty.vue.d.ts +1 -1
  11. package/dist/schema/SchemaProperty.vue.d.ts.map +1 -1
  12. package/dist/schema/SchemaProperty.vue.js +1 -1
  13. package/dist/schema/SchemaProperty.vue_vue_type_script_setup_true_lang.js +7 -2
  14. package/dist/schema/SchemaProperty.vue_vue_type_script_setup_true_lang.js.map +1 -1
  15. package/dist/schema/SchemaPropertyHeading.vue.d.ts +1 -1
  16. package/dist/schema/SchemaPropertyHeading.vue.d.ts.map +1 -1
  17. package/dist/schema/components/CopyLinkButton.vue.d.ts +5 -0
  18. package/dist/schema/components/CopyLinkButton.vue.d.ts.map +1 -1
  19. package/dist/schema/components/CopyLinkButton.vue_vue_type_script_setup_true_lang.js +2 -1
  20. package/dist/schema/components/CopyLinkButton.vue_vue_type_script_setup_true_lang.js.map +1 -1
  21. package/dist/schema/localization/index.d.ts +1 -1
  22. package/dist/shared/ExternalExampleStatus.vue.d.ts +12 -0
  23. package/dist/shared/ExternalExampleStatus.vue.d.ts.map +1 -0
  24. package/dist/shared/ExternalExampleStatus.vue.js +6 -0
  25. package/dist/shared/ExternalExampleStatus.vue.js.map +1 -0
  26. package/dist/shared/ExternalExampleStatus.vue_vue_type_script_setup_true_lang.js +26 -0
  27. package/dist/shared/ExternalExampleStatus.vue_vue_type_script_setup_true_lang.js.map +1 -0
  28. package/dist/shared/external-example-localization/index.d.ts +4 -0
  29. package/dist/shared/external-example-localization/index.d.ts.map +1 -0
  30. package/dist/shared/external-example-localization/index.js +17 -0
  31. package/dist/shared/external-example-localization/index.js.map +1 -0
  32. package/dist/shared/external-example-localization/locales/ar.d.ts +8 -0
  33. package/dist/shared/external-example-localization/locales/ar.d.ts.map +1 -0
  34. package/dist/shared/external-example-localization/locales/ar.js +9 -0
  35. package/dist/shared/external-example-localization/locales/ar.js.map +1 -0
  36. package/dist/shared/external-example-localization/locales/de.d.ts +8 -0
  37. package/dist/shared/external-example-localization/locales/de.d.ts.map +1 -0
  38. package/dist/shared/external-example-localization/locales/de.js +9 -0
  39. package/dist/shared/external-example-localization/locales/de.js.map +1 -0
  40. package/dist/shared/external-example-localization/locales/en.d.ts +8 -0
  41. package/dist/shared/external-example-localization/locales/en.d.ts.map +1 -0
  42. package/dist/shared/external-example-localization/locales/en.js +9 -0
  43. package/dist/shared/external-example-localization/locales/en.js.map +1 -0
  44. package/dist/shared/external-example-localization/locales/es.d.ts +8 -0
  45. package/dist/shared/external-example-localization/locales/es.d.ts.map +1 -0
  46. package/dist/shared/external-example-localization/locales/es.js +9 -0
  47. package/dist/shared/external-example-localization/locales/es.js.map +1 -0
  48. package/dist/shared/external-example-localization/locales/fr.d.ts +8 -0
  49. package/dist/shared/external-example-localization/locales/fr.d.ts.map +1 -0
  50. package/dist/shared/external-example-localization/locales/fr.js +9 -0
  51. package/dist/shared/external-example-localization/locales/fr.js.map +1 -0
  52. package/dist/shared/external-example-localization/locales/pt.d.ts +8 -0
  53. package/dist/shared/external-example-localization/locales/pt.d.ts.map +1 -0
  54. package/dist/shared/external-example-localization/locales/pt.js +9 -0
  55. package/dist/shared/external-example-localization/locales/pt.js.map +1 -0
  56. package/dist/shared/external-example-localization/locales/ru.d.ts +8 -0
  57. package/dist/shared/external-example-localization/locales/ru.d.ts.map +1 -0
  58. package/dist/shared/external-example-localization/locales/ru.js +9 -0
  59. package/dist/shared/external-example-localization/locales/ru.js.map +1 -0
  60. package/dist/shared/external-example-localization/locales/zh-cn.d.ts +8 -0
  61. package/dist/shared/external-example-localization/locales/zh-cn.d.ts.map +1 -0
  62. package/dist/shared/external-example-localization/locales/zh-cn.js +9 -0
  63. package/dist/shared/external-example-localization/locales/zh-cn.js.map +1 -0
  64. package/dist/shared/external-example-localization/locales/zh-tw.d.ts +8 -0
  65. package/dist/shared/external-example-localization/locales/zh-tw.d.ts.map +1 -0
  66. package/dist/shared/external-example-localization/locales/zh-tw.js +9 -0
  67. package/dist/shared/external-example-localization/locales/zh-tw.js.map +1 -0
  68. package/dist/shared/external-example-localization/translations.d.ts +67 -0
  69. package/dist/shared/external-example-localization/translations.d.ts.map +1 -0
  70. package/dist/shared/external-example-localization/translations.js +24 -0
  71. package/dist/shared/external-example-localization/translations.js.map +1 -0
  72. package/dist/shared/index.d.ts +3 -0
  73. package/dist/shared/index.d.ts.map +1 -1
  74. package/dist/shared/index.js +4 -2
  75. package/dist/style.css +1 -1
  76. package/dist/vue-styles.css +1 -1
  77. package/package.json +4 -4
@@ -1,12 +1,12 @@
1
- import { deSerializeParameter as e, filterDisabledProperties as t, getExampleFromSchema as n, isParamDisabled as r, serializeContentValue as i, serializeCookieStyle as a, serializeDeepObjectStyle as o, serializeFormStyle as s, serializeFormStyleForCookies as c, serializePipeDelimitedStyle as l, serializeSimpleStyle as u, serializeSpaceDelimitedStyle as d } from "@scalar/workspace-store/request-example";
2
- import { getResolvedRef as f } from "@scalar/workspace-store/helpers/get-resolved-ref";
3
- import { getCookieSerializationError as p } from "@scalar/helpers/http/get-cookie-serialization-error";
4
- import { replacePathVariables as m } from "@scalar/helpers/regex/replace-variables";
5
- import { assertReservedPathUrl as h, hasPathDotSegment as g, includesUndefinedPathPrefix as _, serializePathParameter as v, serializeReservedPathParameter as y } from "@scalar/workspace-store/helpers/encode-path-parameter";
6
- import { getParameterExample as b } from "@scalar/workspace-store/helpers/get-parameter-example";
7
- import { getQuerystringParameter as x, serializeQuerystringParameter as S } from "@scalar/workspace-store/helpers/querystring-parameter";
1
+ import { deSerializeParameter as e, encodeReservedQueryValue as t, filterDisabledProperties as n, getExampleFromSchema as r, isParamDisabled as i, serializeContentValue as a, serializeCookieStyle as o, serializeDeepObjectStyle as s, serializeFormStyle as c, serializeFormStyleForCookies as l, serializePipeDelimitedStyle as u, serializeSimpleStyle as d, serializeSpaceDelimitedStyle as f } from "@scalar/workspace-store/request-example";
2
+ import { getResolvedRef as p } from "@scalar/workspace-store/helpers/get-resolved-ref";
3
+ import { getCookieSerializationError as m } from "@scalar/helpers/http/get-cookie-serialization-error";
4
+ import { replacePathVariables as h } from "@scalar/helpers/regex/replace-variables";
5
+ import { assertReservedPathUrl as g, hasPathDotSegment as _, includesUndefinedPathPrefix as v, serializePathParameter as y, serializeReservedPathParameter as b } from "@scalar/workspace-store/helpers/encode-path-parameter";
6
+ import { getParameterExample as x } from "@scalar/workspace-store/helpers/get-parameter-example";
7
+ import { getQuerystringParameter as S, serializeQuerystringParameter as C } from "@scalar/workspace-store/helpers/querystring-parameter";
8
8
  // src/code-example/helpers/operation-to-har/process-parameters.ts
9
- var C = class extends Error {}, w = (e) => (e ?? []).map((e) => f(e)).filter((e) => e !== void 0), T = (e) => "allowReserved" in e && e.allowReserved !== void 0 ? e.allowReserved : "schema" in e && e.schema && typeof e.schema == "object" && "allowReserved" in e.schema ? e.schema.allowReserved === !0 : !1, E = (e) => {
9
+ var w = class extends Error {}, T = (e) => (e ?? []).map((e) => p(e)).filter((e) => e !== void 0), E = (e) => "allowReserved" in e && e.allowReserved !== void 0 ? e.allowReserved : "schema" in e && e.schema && typeof e.schema == "object" && "allowReserved" in e.schema ? e.schema.allowReserved === !0 : !1, D = (e) => {
10
10
  if (e.in === "header") return {
11
11
  style: "simple",
12
12
  explode: "explode" in e && e.explode !== void 0 && e.explode
@@ -29,171 +29,171 @@ var C = class extends Error {}, w = (e) => (e ?? []).map((e) => f(e)).filter((e)
29
29
  style: n,
30
30
  explode: "explode" in e && e.explode !== void 0 ? e.explode : n === "form"
31
31
  };
32
- }, D = (i, a, o, s, c) => {
33
- let l = b(i, a), u = l.example, d = i.in === "query" && !l.serialized && !l.mediaSerialized ? u?.["x-scalar-disabled-properties"] : void 0;
34
- if (d) return t(e(l.value, i), d, r(i, u, o));
35
- if (r(i, u, o)) return;
36
- if (l.value !== void 0) return e(l.value, i);
37
- if (!("schema" in i) || !i.schema) return;
38
- let p = {
32
+ }, O = (t, a, o, s, c) => {
33
+ let l = x(t, a), u = l.example, d = t.in === "query" && !l.serialized && !l.mediaSerialized ? u?.["x-scalar-disabled-properties"] : void 0;
34
+ if (d) return n(e(l.value, t), d, i(t, u, o));
35
+ if (i(t, u, o)) return;
36
+ if (l.value !== void 0) return e(l.value, t);
37
+ if (!("schema" in t) || !t.schema) return;
38
+ let f = {
39
39
  openapiVersion: s,
40
40
  jsonSchemaDialect: c,
41
- ...i.in === "path" ? {
42
- emptyString: `{${i.name}}`,
41
+ ...t.in === "path" ? {
42
+ emptyString: `{${t.name}}`,
43
43
  preserveStringFallback: !0
44
44
  } : {}
45
- }, m = f(i.schema);
46
- return m ? n(m, p) : void 0;
47
- }, O = ({ harRequest: t, parameters: n, example: f, defaultDisabled: O, openapiVersion: k, jsonSchemaDialect: A }) => {
48
- let j = [...t.headers], M = [...t.queryString], N = [...t.cookies], P = [], F = t.url, I = t.url, L = !1, R = !1, z = [], B = [], V = (e, t, n = !1) => {
49
- F = m(F, { [e]: t }), I = m(I, { [e]: n ? `x${t}` : t }), L ||= n;
50
- }, H = (e, t, n) => {
51
- T(n) ? z.push(`${encodeURIComponent(e)}=${t}`) : M.push({
45
+ }, m = p(t.schema);
46
+ return m ? r(m, f) : void 0;
47
+ }, k = ({ harRequest: n, parameters: r, example: p, defaultDisabled: k, openapiVersion: A, jsonSchemaDialect: j }) => {
48
+ let M = [...n.headers], N = [...n.queryString], P = [...n.cookies], F = [], I = n.url, L = n.url, R = !1, z = !1, B = [], V = [], H = (e, t, n = !1) => {
49
+ I = h(I, { [e]: t }), L = h(L, { [e]: n ? `x${t}` : t }), R ||= n;
50
+ }, U = (e, n, r) => {
51
+ E(r) ? B.push(`${encodeURIComponent(e)}=${t(n)}`) : N.push({
52
52
  name: e,
53
- value: t
53
+ value: n
54
54
  });
55
- }, U = w(n);
56
- for (let t of U) {
55
+ }, W = T(r);
56
+ for (let t of W) {
57
57
  if (!t.in || !t.name) continue;
58
58
  if (t.in === "querystring") {
59
- let e = x(t, f, {
60
- defaultDisabled: O,
61
- openapiVersion: k,
62
- jsonSchemaDialect: A
59
+ let e = S(t, p, {
60
+ defaultDisabled: k,
61
+ openapiVersion: A,
62
+ jsonSchemaDialect: j
63
63
  });
64
64
  if (e) {
65
- let t = F.indexOf("#"), n = t === -1 ? "" : F.slice(t), r = (t === -1 ? F : F.slice(0, t)).split("?")[0], i = S(e);
66
- F = `${r}${i ? `?${i}` : ""}${n}`;
65
+ let t = I.indexOf("#"), n = t === -1 ? "" : I.slice(t), r = (t === -1 ? I : I.slice(0, t)).split("?")[0], i = C(e);
66
+ I = `${r}${i ? `?${i}` : ""}${n}`;
67
67
  }
68
68
  continue;
69
69
  }
70
- let n = b(t, f);
71
- if (n.serialized && !r(t, n.example, O)) {
70
+ let n = x(t, p);
71
+ if (n.serialized && !i(t, n.example, k)) {
72
72
  let e = String(n.value);
73
73
  switch (t.in) {
74
74
  case "path":
75
- V(t.name, e);
75
+ H(t.name, e);
76
76
  break;
77
77
  case "query":
78
- z.push(e);
78
+ B.push(e);
79
79
  break;
80
80
  case "header":
81
- j.push({
81
+ M.push({
82
82
  name: t.name,
83
83
  value: e
84
84
  });
85
85
  break;
86
- case "cookie": B.push(e);
86
+ case "cookie": V.push(e);
87
87
  }
88
88
  continue;
89
89
  }
90
- if (n.mediaSerialized && !r(t, n.example, O)) {
90
+ if (n.mediaSerialized && !i(t, n.example, k)) {
91
91
  let e = String(n.value);
92
92
  switch (t.in) {
93
93
  case "query":
94
- H(t.name, e, t);
94
+ U(t.name, e, t);
95
95
  break;
96
96
  case "header":
97
- j.push({
97
+ M.push({
98
98
  name: t.name,
99
99
  value: e
100
100
  });
101
101
  break;
102
102
  case "path":
103
- V(t.name, encodeURIComponent(e));
103
+ H(t.name, encodeURIComponent(e));
104
104
  break;
105
- case "cookie": N.push({
105
+ case "cookie": P.push({
106
106
  name: t.name,
107
107
  value: e
108
108
  });
109
109
  }
110
110
  continue;
111
111
  }
112
- let { style: m, explode: h } = E(t), g = t.in === "path" && (m === "matrix" || m === "label"), w = g ? e(n.value, t) : D(t, f, O, k, A);
113
- if (!(g ? !n.example || r(t, n.example, O) : w === void 0)) switch (t.in) {
112
+ let { style: r, explode: h } = D(t), g = t.in === "path" && (r === "matrix" || r === "label"), _ = g ? e(n.value, t) : O(t, p, k, A, j);
113
+ if (!(g ? !n.example || i(t, n.example, k) : _ === void 0)) switch (t.in) {
114
114
  case "path": {
115
- let e = k?.startsWith("3.2.") && "schema" in t && t.allowReserved === !0;
116
- if (R ||= !!e, g) {
117
- let n = v(t.name, {
118
- value: w,
119
- style: m,
115
+ let e = A?.startsWith("3.2.") && "schema" in t && t.allowReserved === !0;
116
+ if (z ||= !!e, g) {
117
+ let n = y(t.name, {
118
+ value: _,
119
+ style: r,
120
120
  explode: h,
121
- includeUndefinedPrefix: _(k)
122
- }, void 0, e), r = m === "matrix" ? ";" : ".";
123
- V(F.includes(`{${t.name}}`) ? t.name : `${r}${t.name}`, n, m === "label" && !e);
124
- } else if (e) V(t.name, y(t.name, {
125
- value: w,
126
- style: m,
121
+ includeUndefinedPrefix: v(A)
122
+ }, void 0, e), i = r === "matrix" ? ";" : ".";
123
+ H(I.includes(`{${t.name}}`) ? t.name : `${i}${t.name}`, n, r === "label" && !e);
124
+ } else if (e) H(t.name, b(t.name, {
125
+ value: _,
126
+ style: r,
127
127
  explode: h
128
128
  }));
129
129
  else {
130
- let e = m === "simple" ? u(w, h) : w;
131
- V(t.name, String(e));
130
+ let e = r === "simple" ? d(_, h) : _;
131
+ H(t.name, String(e));
132
132
  }
133
133
  break;
134
134
  }
135
135
  case "query":
136
136
  if ("content" in t && t.content) {
137
- let e = Object.keys(t.content)[0] ?? "application/json", n = i(w, e);
138
- H(t.name, n, t);
137
+ let e = Object.keys(t.content)[0] ?? "application/json", n = a(_, e);
138
+ U(t.name, n, t);
139
139
  break;
140
140
  }
141
- switch (m) {
141
+ switch (r) {
142
142
  case "form": {
143
- let e = s(w, h);
144
- if (Array.isArray(e)) for (let n of e) H(n.key || t.name, String(n.value), t);
145
- else H(t.name, String(e), t);
143
+ let e = c(_, h);
144
+ if (Array.isArray(e)) for (let n of e) U(n.key || t.name, String(n.value), t);
145
+ else U(t.name, String(e), t);
146
146
  break;
147
147
  }
148
148
  case "spaceDelimited": {
149
- let e = d(w);
150
- H(t.name, e, t);
149
+ let e = f(_);
150
+ U(t.name, e, t);
151
151
  break;
152
152
  }
153
153
  case "pipeDelimited": {
154
- let e = l(w);
155
- H(t.name, e, t);
154
+ let e = u(_);
155
+ U(t.name, e, t);
156
156
  break;
157
157
  }
158
158
  case "deepObject":
159
- if (Array.isArray(w)) {
160
- let e = s(w, !0);
161
- if (Array.isArray(e)) for (let n of e) H(n.key || t.name, String(n.value), t);
162
- else H(t.name, String(e), t);
159
+ if (Array.isArray(_)) {
160
+ let e = c(_, !0);
161
+ if (Array.isArray(e)) for (let n of e) U(n.key || t.name, String(n.value), t);
162
+ else U(t.name, String(e), t);
163
163
  } else {
164
- let e = o(t.name, w);
165
- for (let n of e) H(n.key, n.value, t);
164
+ let e = s(t.name, _);
165
+ for (let n of e) U(n.key, n.value, t);
166
166
  }
167
167
  break;
168
- default: H(t.name, String(w), t);
168
+ default: U(t.name, String(_), t);
169
169
  }
170
170
  break;
171
171
  case "header": {
172
- let e = u(w, h);
173
- j.push({
172
+ let e = d(_, h);
173
+ M.push({
174
174
  name: t.name,
175
175
  value: String(e)
176
176
  });
177
177
  break;
178
178
  }
179
179
  case "cookie": {
180
- let [e, n] = (k ?? "").split("."), r = e === "3" && n === "2" && !("content" in t) ? p(t, w) : void 0;
181
- if (r) throw new C(r);
182
- if (m === "cookie") {
183
- P.push(...a(t.name, w, h));
180
+ let [e, n] = (A ?? "").split("."), i = e === "3" && n === "2" && !("content" in t) ? m(t, _) : void 0;
181
+ if (i) throw new w(i);
182
+ if (r === "cookie") {
183
+ F.push(...o(t.name, _, h));
184
184
  break;
185
185
  }
186
- let i = c(w, h);
187
- if (Array.isArray(i)) for (let e of i) {
186
+ let a = l(_, h);
187
+ if (Array.isArray(a)) for (let e of a) {
188
188
  let n = e.key || t.name, r = e.value === null ? "null" : String(e.value);
189
- N.push({
189
+ P.push({
190
190
  name: n,
191
191
  value: r
192
192
  });
193
193
  }
194
194
  else {
195
- let e = i === null ? "null" : String(i);
196
- N.push({
195
+ let e = a === null ? "null" : String(a);
196
+ P.push({
197
197
  name: t.name,
198
198
  value: e
199
199
  });
@@ -202,34 +202,34 @@ var C = class extends Error {}, w = (e) => (e ?? []).map((e) => f(e)).filter((e)
202
202
  }
203
203
  }
204
204
  }
205
- if (P.length || B.length) {
205
+ if (F.length || V.length) {
206
206
  let e = [
207
- ...N.map((e) => `${encodeURIComponent(e.name)}=${encodeURIComponent(e.value)}`),
208
- ...P.map((e) => `${e.name}=${e.value}`),
209
- ...B
210
- ].join("; "), t = j.find((e) => e.name.toLowerCase() === "cookie");
211
- t ? j.splice(j.indexOf(t), 1, {
207
+ ...P.map((e) => `${encodeURIComponent(e.name)}=${encodeURIComponent(e.value)}`),
208
+ ...F.map((e) => `${e.name}=${e.value}`),
209
+ ...V
210
+ ].join("; "), t = M.find((e) => e.name.toLowerCase() === "cookie");
211
+ t ? M.splice(M.indexOf(t), 1, {
212
212
  ...t,
213
213
  value: t.value ? `${t.value}; ${e}` : e
214
- }) : j.push({
214
+ }) : M.push({
215
215
  name: "Cookie",
216
216
  value: e
217
217
  });
218
218
  }
219
- if (z.length) {
220
- let e = F.indexOf("#"), t = e < 0 ? "" : F.slice(e), n = e < 0 ? F : F.slice(0, e);
221
- F = `${n}${n.includes("?") ? "&" : "?"}${z.join("&")}${t}`;
219
+ if (B.length) {
220
+ let e = I.indexOf("#"), t = e < 0 ? "" : I.slice(e), n = e < 0 ? I : I.slice(0, e);
221
+ I = `${n}${n.includes("?") ? "&" : "?"}${B.join("&")}${t}`;
222
222
  }
223
- if (R && h(F), L && g(F, I)) throw URIError("A label-style path parameter produces a dot segment that browsers remove.");
223
+ if (z && g(I), R && _(I, L)) throw URIError("A label-style path parameter produces a dot segment that browsers remove.");
224
224
  return {
225
- url: F,
226
- headers: j,
227
- queryString: M,
228
- cookies: P.length || B.length ? [] : N,
229
- hasCookieStyleEntries: P.length > 0 || B.length > 0,
230
- ...z.length ? { hasSerializedQuery: !0 } : {}
225
+ url: I,
226
+ headers: M,
227
+ queryString: N,
228
+ cookies: F.length || V.length ? [] : P,
229
+ hasCookieStyleEntries: F.length > 0 || V.length > 0,
230
+ ...B.length ? { hasSerializedQuery: !0 } : {}
231
231
  };
232
232
  };
233
- export { C as CookieSerializationError, O as processParameters };
233
+ export { w as CookieSerializationError, k as processParameters };
234
234
 
235
235
  //# sourceMappingURL=process-parameters.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"process-parameters.js","names":["CookieSerializationError","deReferenceParams","params","getResolvedRef","param","isAllowReserved","getParameterStyleAndExplode","explode","defaultStyle","style","getParameterValue","selected","getParameterExample","example","exampleValue","propertyStates","filterDisabledProperties","deSerializeParameter","isParamDisabled","defaultDisabled","options","schema","getExampleFromSchema","processParameters","newHeaders","harRequest","newQueryString","newCookies","cookieStyleEntries","newUrl","markedPathUrl","hasStyledLabel","hasReservedPathParameter","serializedQuery","serializedCookies","substitutePathParameter","replacePathVariables","name","value","markLabel","appendQueryParameter","deReferencedParams","parameters","querystring","getQuerystringParameter","hashIndex","hash","base","query","serializeQuerystringParameter","wireValue","text","isStyledPath","paramValue","openapiVersion","jsonSchemaDialect","allowReserved","serializePathParameter","includesUndefinedPathPrefix","operator","serializeReservedPathParameter","serializeSimpleStyle","paramContentType","serializedValue","serializeContentValue","serialized","serializeFormStyle","entry","serializeSpaceDelimitedStyle","serializePipeDelimitedStyle","entries","serializeDeepObjectStyle","major","minor","error","getCookieSerializationError","serializeCookieStyle","serializeFormStyleForCookies","key","cookieValue","cookie","existing","header","assertReservedPathUrl","hasPathDotSegment"],"sources":["../../../../src/code-example/helpers/operation-to-har/process-parameters.ts"],"sourcesContent":["import { getCookieSerializationError } from '@scalar/helpers/http/get-cookie-serialization-error'\nimport { replacePathVariables } from '@scalar/helpers/regex/replace-variables'\nimport {\n assertReservedPathUrl,\n hasPathDotSegment,\n includesUndefinedPathPrefix,\n serializePathParameter,\n serializeReservedPathParameter,\n} from '@scalar/workspace-store/helpers/encode-path-parameter'\nimport { getParameterExample } from '@scalar/workspace-store/helpers/get-parameter-example'\nimport { getResolvedRef } from '@scalar/workspace-store/helpers/get-resolved-ref'\nimport {\n getQuerystringParameter,\n serializeQuerystringParameter,\n} from '@scalar/workspace-store/helpers/querystring-parameter'\nimport {\n deSerializeParameter,\n filterDisabledProperties,\n getExampleFromSchema,\n isParamDisabled,\n serializeContentValue,\n serializeCookieStyle,\n serializeDeepObjectStyle,\n serializeFormStyle,\n serializeFormStyleForCookies,\n serializePipeDelimitedStyle,\n serializeSimpleStyle,\n serializeSpaceDelimitedStyle,\n} from '@scalar/workspace-store/request-example'\nimport type { OperationObject, ParameterObject } from '@scalar/workspace-store/schemas/v3.2/strict/openapi-document'\nimport type { Request as HarRequest } from 'har-format'\n\n/** An invalid cookie declaration that authors can repair before generating a sample. */\nexport class CookieSerializationError extends Error {}\n\ntype ProcessedParameters = {\n /** Named serialized examples already embedded in the URL. */\n hasSerializedQuery?: boolean\n url: string\n headers: HarRequest['headers']\n queryString: HarRequest['queryString']\n cookies: HarRequest['cookies']\n /** Whether serialized cookie-style values require a complete Cookie header. */\n hasCookieStyleEntries: boolean\n}\n\n/** Ensures we don't have any references in the parameters */\nconst deReferenceParams = (params: OperationObject['parameters']): ParameterObject[] =>\n (params ?? []).map((param) => getResolvedRef(param)).filter((param) => param !== undefined)\n\n/** Whether the parameter allows reserved characters (from param or schema). */\nconst isAllowReserved = (param: ParameterObject): boolean => {\n if ('allowReserved' in param && param.allowReserved !== undefined) {\n return param.allowReserved\n }\n if ('schema' in param && param.schema && typeof param.schema === 'object' && 'allowReserved' in param.schema) {\n return (param.schema as { allowReserved?: boolean }).allowReserved === true\n }\n return false\n}\n\n/**\n * Get the style and explode values for a parameter according to OpenAPI 3.1.1 specification.\n * Handles defaults and validation for parameter location restrictions.\n */\nconst getParameterStyleAndExplode = (param: ParameterObject): { style: string; explode: boolean } => {\n // Headers only support 'simple' style\n if (param.in === 'header') {\n const explode = 'explode' in param && param.explode !== undefined ? param.explode : false\n return { style: 'simple', explode }\n }\n\n // Cookies default to form for compatibility and also support cookie style.\n if (param.in === 'cookie') {\n const explode = 'explode' in param && param.explode !== undefined ? param.explode : true\n return { style: 'style' in param && param.style === 'cookie' ? 'cookie' : 'form', explode }\n }\n\n const defaultStyle = {\n path: 'simple',\n query: 'form',\n querystring: 'form',\n header: 'simple',\n cookie: 'form',\n }[param.in]\n\n // Use provided style or default based on location\n const style = 'style' in param && param.style ? param.style : defaultStyle\n\n // Determine explode value: use provided value or default based on style\n const explode = 'explode' in param && param.explode !== undefined ? param.explode : style === 'form'\n\n return { style, explode }\n}\n\n/**\n * Extract the value for a parameter from example data or schema.\n * Prioritizes example data over schema examples.\n * Returns null if the parameter is disabled so we can skip it.\n */\nconst getParameterValue = (\n param: ParameterObject,\n example: string | undefined,\n defaultDisabled: boolean,\n openapiVersion?: string,\n jsonSchemaDialect?: string,\n): unknown => {\n // Try to get value from example first\n const selected = getParameterExample(param, example)\n const exampleValue = selected.example\n\n const propertyStates =\n param.in === 'query' && !selected.serialized && !selected.mediaSerialized\n ? exampleValue?.['x-scalar-disabled-properties']\n : undefined\n if (propertyStates) {\n return filterDisabledProperties(\n deSerializeParameter(selected.value, param),\n propertyStates,\n isParamDisabled(param, exampleValue, defaultDisabled),\n )\n }\n\n // If the parameter is disabled, return undefined so we can skip it.\n if (isParamDisabled(param, exampleValue, defaultDisabled)) {\n return undefined\n }\n\n // If the example value is set, return it.\n if (selected.value !== undefined) {\n return deSerializeParameter(selected.value, param)\n }\n\n // Fall back to schema example if available\n if (!('schema' in param) || !param.schema) {\n return undefined\n }\n\n const options = {\n openapiVersion,\n jsonSchemaDialect,\n ...(param.in === 'path' ? { emptyString: `{${param.name}}`, preserveStringFallback: true } : {}),\n }\n const schema = getResolvedRef(param.schema)\n return schema ? getExampleFromSchema(schema, options) : undefined\n}\n\n/**\n * Process OpenAPI parameters and return the updated properties.\n * Handles path, query, and header parameters with various styles and explode options.\n *\n * @see https://spec.openapis.org/oas/latest.html#style-values\n */\nexport const processParameters = ({\n harRequest,\n parameters,\n example,\n defaultDisabled,\n openapiVersion,\n jsonSchemaDialect,\n}: {\n harRequest: HarRequest\n parameters: OperationObject['parameters']\n /** The name of the example to use */\n example?: string | undefined\n /** Whether to disable parameters by default. */\n defaultDisabled: boolean\n /** Originating API description version. */\n openapiVersion?: string\n jsonSchemaDialect?: string\n}): ProcessedParameters => {\n // Create copies of the arrays to avoid modifying the input\n const newHeaders = [...harRequest.headers]\n const newQueryString = [...harRequest.queryString]\n const newCookies = [...harRequest.cookies]\n const cookieStyleEntries: HarRequest['cookies'] = []\n let newUrl = harRequest.url\n let markedPathUrl = harRequest.url\n let hasStyledLabel = false\n let hasReservedPathParameter = false\n const serializedQuery: string[] = []\n const serializedCookies: string[] = []\n\n const substitutePathParameter = (name: string, value: string, markLabel = false): void => {\n newUrl = replacePathVariables(newUrl, { [name]: value })\n // Mark only label substitutions so literal dot segments keep their usual URL semantics.\n markedPathUrl = replacePathVariables(markedPathUrl, { [name]: markLabel ? `x${value}` : value })\n hasStyledLabel ||= markLabel\n }\n\n const appendQueryParameter = (name: string, value: string, param: ParameterObject): void => {\n if (isAllowReserved(param)) {\n // HTTP clients cannot infer reserved expansion from a HAR name/value pair.\n serializedQuery.push(`${encodeURIComponent(name)}=${value}`)\n } else {\n newQueryString.push({ name, value })\n }\n }\n\n // Filter out references\n const deReferencedParams = deReferenceParams(parameters)\n\n for (const param of deReferencedParams) {\n if (!param.in || !param.name) {\n continue\n }\n\n if (param.in === 'querystring') {\n const querystring = getQuerystringParameter(param, example, {\n defaultDisabled,\n openapiVersion,\n jsonSchemaDialect,\n })\n if (querystring) {\n const hashIndex = newUrl.indexOf('#')\n const hash = hashIndex === -1 ? '' : newUrl.slice(hashIndex)\n const base = (hashIndex === -1 ? newUrl : newUrl.slice(0, hashIndex)).split('?')[0]\n const query = serializeQuerystringParameter(querystring)\n newUrl = `${base}${query ? `?${query}` : ''}${hash}`\n }\n continue\n }\n\n const selected = getParameterExample(param, example)\n if (selected.serialized && !isParamDisabled(param, selected.example, defaultDisabled)) {\n const wireValue = String(selected.value)\n switch (param.in) {\n case 'path':\n substitutePathParameter(param.name, wireValue)\n break\n case 'query':\n serializedQuery.push(wireValue)\n break\n case 'header':\n newHeaders.push({ name: param.name, value: wireValue })\n break\n case 'cookie':\n serializedCookies.push(wireValue)\n break\n }\n continue\n }\n if (selected.mediaSerialized && !isParamDisabled(param, selected.example, defaultDisabled)) {\n const text = String(selected.value)\n switch (param.in) {\n case 'query':\n appendQueryParameter(param.name, text, param)\n break\n case 'header':\n newHeaders.push({ name: param.name, value: text })\n break\n case 'path':\n substitutePathParameter(param.name, encodeURIComponent(text))\n break\n case 'cookie':\n newCookies.push({ name: param.name, value: text })\n break\n }\n continue\n }\n const { style, explode } = getParameterStyleAndExplode(param)\n const isStyledPath = param.in === 'path' && (style === 'matrix' || style === 'label')\n // Like Test Request, leave the template visible when no example supplies a styled path value.\n const paramValue = isStyledPath\n ? deSerializeParameter(selected.value, param)\n : getParameterValue(param, example, defaultDisabled, openapiVersion, jsonSchemaDialect)\n if (\n isStyledPath\n ? !selected.example || isParamDisabled(param, selected.example, defaultDisabled)\n : paramValue === undefined\n ) {\n continue\n }\n\n switch (param.in) {\n case 'path': {\n const allowReserved = openapiVersion?.startsWith('3.2.') && 'schema' in param && param.allowReserved === true\n hasReservedPathParameter ||= Boolean(allowReserved)\n\n if (isStyledPath) {\n const value = serializePathParameter(\n param.name,\n {\n value: paramValue,\n style,\n explode,\n includeUndefinedPrefix: includesUndefinedPathPrefix(openapiVersion),\n },\n undefined,\n allowReserved,\n )\n // Support older samples that include a URI template operator in the path.\n const operator = style === 'matrix' ? ';' : '.'\n const name = newUrl.includes(`{${param.name}}`) ? param.name : `${operator}${param.name}`\n substitutePathParameter(name, value, style === 'label' && !allowReserved)\n } else if (allowReserved) {\n substitutePathParameter(\n param.name,\n serializeReservedPathParameter(param.name, { value: paramValue, style, explode }),\n )\n } else {\n const value = style === 'simple' ? serializeSimpleStyle(paramValue, explode) : paramValue\n substitutePathParameter(param.name, String(value))\n }\n break\n }\n\n case 'query': {\n // Content type parameters should be serialized according to the parameter's own content type\n if ('content' in param && param.content) {\n // We grab the first for now but eventually we should support selecting the content type per parameter\n const paramContentType = Object.keys(param.content)[0] ?? 'application/json'\n const serializedValue = serializeContentValue(paramValue, paramContentType)\n appendQueryParameter(param.name, serializedValue, param)\n break\n }\n\n // Handle query parameters\n switch (style) {\n case 'form': {\n const serialized = serializeFormStyle(paramValue, explode)\n\n // If serialized is an array of key-value pairs (exploded object or array)\n if (Array.isArray(serialized)) {\n for (const entry of serialized) {\n const key = entry.key || param.name\n appendQueryParameter(key, String(entry.value), param)\n }\n }\n // Otherwise, convert to string\n else {\n appendQueryParameter(param.name, String(serialized), param)\n }\n break\n }\n case 'spaceDelimited': {\n const serialized = serializeSpaceDelimitedStyle(paramValue)\n appendQueryParameter(param.name, serialized, param)\n break\n }\n case 'pipeDelimited': {\n const serialized = serializePipeDelimitedStyle(paramValue)\n appendQueryParameter(param.name, serialized, param)\n break\n }\n case 'deepObject': {\n // OAS marks deepObject-on-array and deepObject+explode:false as undefined.\n // Mirror process-body: fall back to form/explode:true for arrays and always\n // invoke the serializer for objects so authors get useful output instead of\n // a silently-dropped parameter.\n if (Array.isArray(paramValue)) {\n const serialized = serializeFormStyle(paramValue, true)\n if (Array.isArray(serialized)) {\n for (const entry of serialized) {\n const key = entry.key || param.name\n appendQueryParameter(key, String(entry.value), param)\n }\n } else {\n appendQueryParameter(param.name, String(serialized), param)\n }\n } else {\n const entries = serializeDeepObjectStyle(param.name, paramValue)\n for (const entry of entries) {\n appendQueryParameter(entry.key, entry.value, param)\n }\n }\n break\n }\n\n // Default to form style\n default:\n appendQueryParameter(param.name, String(paramValue), param)\n }\n break\n }\n\n // Headers only support 'simple' style according to OpenAPI 3.1.1\n // For arrays, simple style always produces comma-separated values regardless of explode\n // The explode parameter only affects object serialization\n case 'header': {\n const serialized = serializeSimpleStyle(paramValue, explode)\n newHeaders.push({ name: param.name, value: String(serialized) })\n break\n }\n\n // Keep cookie style separate so snippet generators cannot percent-encode it.\n case 'cookie': {\n const [major, minor] = (openapiVersion ?? '').split('.')\n const error =\n major === '3' && minor === '2' && !('content' in param)\n ? getCookieSerializationError(param, paramValue)\n : undefined\n if (error) {\n throw new CookieSerializationError(error)\n }\n if (style === 'cookie') {\n cookieStyleEntries.push(...serializeCookieStyle(param.name, paramValue, explode))\n break\n }\n const serialized = serializeFormStyleForCookies(paramValue, explode)\n\n // If serialized is an array of key-value pairs (exploded object or array)\n if (Array.isArray(serialized)) {\n for (const entry of serialized) {\n const key = entry.key || param.name\n const value = entry.value === null ? 'null' : String(entry.value)\n newCookies.push({ name: key, value })\n }\n }\n // Otherwise, convert to string\n else {\n const value = serialized === null ? 'null' : String(serialized)\n newCookies.push({ name: param.name, value })\n }\n break\n }\n }\n }\n\n // HAR cookie entries are encoded by snippet generators. Use a complete header\n // when cookie style is present, preserving legacy encoding for other cookies.\n if (cookieStyleEntries.length || serializedCookies.length) {\n const cookieValue = [\n ...newCookies.map((cookie) => `${encodeURIComponent(cookie.name)}=${encodeURIComponent(cookie.value)}`),\n ...cookieStyleEntries.map((cookie) => `${cookie.name}=${cookie.value}`),\n ...serializedCookies,\n ].join('; ')\n const existing = newHeaders.find((header) => header.name.toLowerCase() === 'cookie')\n if (existing) {\n newHeaders.splice(newHeaders.indexOf(existing), 1, {\n ...existing,\n value: existing.value ? `${existing.value}; ${cookieValue}` : cookieValue,\n })\n } else {\n newHeaders.push({ name: 'Cookie', value: cookieValue })\n }\n }\n\n if (serializedQuery.length) {\n const hashIndex = newUrl.indexOf('#')\n const hash = hashIndex < 0 ? '' : newUrl.slice(hashIndex)\n const base = hashIndex < 0 ? newUrl : newUrl.slice(0, hashIndex)\n newUrl = `${base}${base.includes('?') ? '&' : '?'}${serializedQuery.join('&')}${hash}`\n }\n\n if (hasReservedPathParameter) {\n assertReservedPathUrl(newUrl)\n }\n if (hasStyledLabel && hasPathDotSegment(newUrl, markedPathUrl)) {\n throw new URIError('A label-style path parameter produces a dot segment that browsers remove.')\n }\n\n return {\n url: newUrl,\n headers: newHeaders,\n queryString: newQueryString,\n cookies: cookieStyleEntries.length || serializedCookies.length ? [] : newCookies,\n hasCookieStyleEntries: cookieStyleEntries.length > 0 || serializedCookies.length > 0,\n ...(serializedQuery.length ? { hasSerializedQuery: true } : {}),\n }\n}\n"],"mappings":";;;;;;;;AAiCA,IAAaA,IAAb,cAA8C,MAAM,CAAC,GAc/CC,KAAqB,OACxBC,KAAU,CAAC,EAAA,CAAG,KAAK,MAAUC,EAAeC,CAAK,CAAC,CAAC,CAAC,QAAQ,MAAUA,MAAU,KAAA,CAAS,GAGtFC,KAAmB,MACnB,mBAAmBD,KAASA,EAAM,kBAAkB,KAAA,IAC/CA,EAAM,gBAEX,YAAYA,KAASA,EAAM,UAAU,OAAOA,EAAM,UAAW,YAAY,mBAAmBA,EAAM,SAC5FA,EAAM,OAAuC,kBAAkB,KAElE,IAOHE,KAA+B,MAAgE;CAEnG,IAAIF,EAAM,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EAA2E;CAGhG,OAAO;EACL,KAAKD;EACL,SAASL;EACT,aAAaE;EACb,SAASE,EAAmB,UAAUM,EAAkB,SAAS,CAAC,IAAIP;EACtE,uBAAuBC,EAAmB,SAAS,KAAKM,EAAkB,SAAS;EACnF,GAAID,EAAgB,SAAS,EAAE,oBAAoB,GAAK,IAAI,CAAC;CAC/D;AACF"}
1
+ {"version":3,"file":"process-parameters.js","names":["CookieSerializationError","deReferenceParams","params","getResolvedRef","param","isAllowReserved","getParameterStyleAndExplode","explode","defaultStyle","style","getParameterValue","selected","getParameterExample","example","exampleValue","propertyStates","filterDisabledProperties","deSerializeParameter","isParamDisabled","defaultDisabled","options","schema","getExampleFromSchema","processParameters","newHeaders","harRequest","newQueryString","newCookies","cookieStyleEntries","newUrl","markedPathUrl","hasStyledLabel","hasReservedPathParameter","serializedQuery","serializedCookies","substitutePathParameter","replacePathVariables","name","value","markLabel","appendQueryParameter","encodeReservedQueryValue","deReferencedParams","parameters","querystring","getQuerystringParameter","hashIndex","hash","base","query","serializeQuerystringParameter","wireValue","text","isStyledPath","paramValue","openapiVersion","jsonSchemaDialect","allowReserved","serializePathParameter","includesUndefinedPathPrefix","operator","serializeReservedPathParameter","serializeSimpleStyle","paramContentType","serializedValue","serializeContentValue","serialized","serializeFormStyle","entry","serializeSpaceDelimitedStyle","serializePipeDelimitedStyle","entries","serializeDeepObjectStyle","major","minor","error","getCookieSerializationError","serializeCookieStyle","serializeFormStyleForCookies","key","cookieValue","cookie","existing","header","assertReservedPathUrl","hasPathDotSegment"],"sources":["../../../../src/code-example/helpers/operation-to-har/process-parameters.ts"],"sourcesContent":["import { getCookieSerializationError } from '@scalar/helpers/http/get-cookie-serialization-error'\nimport { replacePathVariables } from '@scalar/helpers/regex/replace-variables'\nimport {\n assertReservedPathUrl,\n hasPathDotSegment,\n includesUndefinedPathPrefix,\n serializePathParameter,\n serializeReservedPathParameter,\n} from '@scalar/workspace-store/helpers/encode-path-parameter'\nimport { getParameterExample } from '@scalar/workspace-store/helpers/get-parameter-example'\nimport { getResolvedRef } from '@scalar/workspace-store/helpers/get-resolved-ref'\nimport {\n getQuerystringParameter,\n serializeQuerystringParameter,\n} from '@scalar/workspace-store/helpers/querystring-parameter'\nimport {\n deSerializeParameter,\n encodeReservedQueryValue,\n filterDisabledProperties,\n getExampleFromSchema,\n isParamDisabled,\n serializeContentValue,\n serializeCookieStyle,\n serializeDeepObjectStyle,\n serializeFormStyle,\n serializeFormStyleForCookies,\n serializePipeDelimitedStyle,\n serializeSimpleStyle,\n serializeSpaceDelimitedStyle,\n} from '@scalar/workspace-store/request-example'\nimport type { OperationObject, ParameterObject } from '@scalar/workspace-store/schemas/v3.2/strict/openapi-document'\nimport type { Request as HarRequest } from 'har-format'\n\n/** An invalid cookie declaration that authors can repair before generating a sample. */\nexport class CookieSerializationError extends Error {}\n\ntype ProcessedParameters = {\n /** Named serialized examples already embedded in the URL. */\n hasSerializedQuery?: boolean\n url: string\n headers: HarRequest['headers']\n queryString: HarRequest['queryString']\n cookies: HarRequest['cookies']\n /** Whether serialized cookie-style values require a complete Cookie header. */\n hasCookieStyleEntries: boolean\n}\n\n/** Ensures we don't have any references in the parameters */\nconst deReferenceParams = (params: OperationObject['parameters']): ParameterObject[] =>\n (params ?? []).map((param) => getResolvedRef(param)).filter((param) => param !== undefined)\n\n/** Whether the parameter allows reserved characters (from param or schema). */\nconst isAllowReserved = (param: ParameterObject): boolean => {\n if ('allowReserved' in param && param.allowReserved !== undefined) {\n return param.allowReserved\n }\n if ('schema' in param && param.schema && typeof param.schema === 'object' && 'allowReserved' in param.schema) {\n return (param.schema as { allowReserved?: boolean }).allowReserved === true\n }\n return false\n}\n\n/**\n * Get the style and explode values for a parameter according to OpenAPI 3.1.1 specification.\n * Handles defaults and validation for parameter location restrictions.\n */\nconst getParameterStyleAndExplode = (param: ParameterObject): { style: string; explode: boolean } => {\n // Headers only support 'simple' style\n if (param.in === 'header') {\n const explode = 'explode' in param && param.explode !== undefined ? param.explode : false\n return { style: 'simple', explode }\n }\n\n // Cookies default to form for compatibility and also support cookie style.\n if (param.in === 'cookie') {\n const explode = 'explode' in param && param.explode !== undefined ? param.explode : true\n return { style: 'style' in param && param.style === 'cookie' ? 'cookie' : 'form', explode }\n }\n\n const defaultStyle = {\n path: 'simple',\n query: 'form',\n querystring: 'form',\n header: 'simple',\n cookie: 'form',\n }[param.in]\n\n // Use provided style or default based on location\n const style = 'style' in param && param.style ? param.style : defaultStyle\n\n // Determine explode value: use provided value or default based on style\n const explode = 'explode' in param && param.explode !== undefined ? param.explode : style === 'form'\n\n return { style, explode }\n}\n\n/**\n * Extract the value for a parameter from example data or schema.\n * Prioritizes example data over schema examples.\n * Returns null if the parameter is disabled so we can skip it.\n */\nconst getParameterValue = (\n param: ParameterObject,\n example: string | undefined,\n defaultDisabled: boolean,\n openapiVersion?: string,\n jsonSchemaDialect?: string,\n): unknown => {\n // Try to get value from example first\n const selected = getParameterExample(param, example)\n const exampleValue = selected.example\n\n const propertyStates =\n param.in === 'query' && !selected.serialized && !selected.mediaSerialized\n ? exampleValue?.['x-scalar-disabled-properties']\n : undefined\n if (propertyStates) {\n return filterDisabledProperties(\n deSerializeParameter(selected.value, param),\n propertyStates,\n isParamDisabled(param, exampleValue, defaultDisabled),\n )\n }\n\n // If the parameter is disabled, return undefined so we can skip it.\n if (isParamDisabled(param, exampleValue, defaultDisabled)) {\n return undefined\n }\n\n // If the example value is set, return it.\n if (selected.value !== undefined) {\n return deSerializeParameter(selected.value, param)\n }\n\n // Fall back to schema example if available\n if (!('schema' in param) || !param.schema) {\n return undefined\n }\n\n const options = {\n openapiVersion,\n jsonSchemaDialect,\n ...(param.in === 'path' ? { emptyString: `{${param.name}}`, preserveStringFallback: true } : {}),\n }\n const schema = getResolvedRef(param.schema)\n return schema ? getExampleFromSchema(schema, options) : undefined\n}\n\n/**\n * Process OpenAPI parameters and return the updated properties.\n * Handles path, query, and header parameters with various styles and explode options.\n *\n * @see https://spec.openapis.org/oas/latest.html#style-values\n */\nexport const processParameters = ({\n harRequest,\n parameters,\n example,\n defaultDisabled,\n openapiVersion,\n jsonSchemaDialect,\n}: {\n harRequest: HarRequest\n parameters: OperationObject['parameters']\n /** The name of the example to use */\n example?: string | undefined\n /** Whether to disable parameters by default. */\n defaultDisabled: boolean\n /** Originating API description version. */\n openapiVersion?: string\n jsonSchemaDialect?: string\n}): ProcessedParameters => {\n // Create copies of the arrays to avoid modifying the input\n const newHeaders = [...harRequest.headers]\n const newQueryString = [...harRequest.queryString]\n const newCookies = [...harRequest.cookies]\n const cookieStyleEntries: HarRequest['cookies'] = []\n let newUrl = harRequest.url\n let markedPathUrl = harRequest.url\n let hasStyledLabel = false\n let hasReservedPathParameter = false\n const serializedQuery: string[] = []\n const serializedCookies: string[] = []\n\n const substitutePathParameter = (name: string, value: string, markLabel = false): void => {\n newUrl = replacePathVariables(newUrl, { [name]: value })\n // Mark only label substitutions so literal dot segments keep their usual URL semantics.\n markedPathUrl = replacePathVariables(markedPathUrl, { [name]: markLabel ? `x${value}` : value })\n hasStyledLabel ||= markLabel\n }\n\n const appendQueryParameter = (name: string, value: string, param: ParameterObject): void => {\n if (isAllowReserved(param)) {\n // HTTP clients cannot infer reserved expansion from a HAR name/value pair.\n serializedQuery.push(`${encodeURIComponent(name)}=${encodeReservedQueryValue(value)}`)\n } else {\n newQueryString.push({ name, value })\n }\n }\n\n // Filter out references\n const deReferencedParams = deReferenceParams(parameters)\n\n for (const param of deReferencedParams) {\n if (!param.in || !param.name) {\n continue\n }\n\n if (param.in === 'querystring') {\n const querystring = getQuerystringParameter(param, example, {\n defaultDisabled,\n openapiVersion,\n jsonSchemaDialect,\n })\n if (querystring) {\n const hashIndex = newUrl.indexOf('#')\n const hash = hashIndex === -1 ? '' : newUrl.slice(hashIndex)\n const base = (hashIndex === -1 ? newUrl : newUrl.slice(0, hashIndex)).split('?')[0]\n const query = serializeQuerystringParameter(querystring)\n newUrl = `${base}${query ? `?${query}` : ''}${hash}`\n }\n continue\n }\n\n const selected = getParameterExample(param, example)\n if (selected.serialized && !isParamDisabled(param, selected.example, defaultDisabled)) {\n const wireValue = String(selected.value)\n switch (param.in) {\n case 'path':\n substitutePathParameter(param.name, wireValue)\n break\n case 'query':\n serializedQuery.push(wireValue)\n break\n case 'header':\n newHeaders.push({ name: param.name, value: wireValue })\n break\n case 'cookie':\n serializedCookies.push(wireValue)\n break\n }\n continue\n }\n if (selected.mediaSerialized && !isParamDisabled(param, selected.example, defaultDisabled)) {\n const text = String(selected.value)\n switch (param.in) {\n case 'query':\n appendQueryParameter(param.name, text, param)\n break\n case 'header':\n newHeaders.push({ name: param.name, value: text })\n break\n case 'path':\n substitutePathParameter(param.name, encodeURIComponent(text))\n break\n case 'cookie':\n newCookies.push({ name: param.name, value: text })\n break\n }\n continue\n }\n const { style, explode } = getParameterStyleAndExplode(param)\n const isStyledPath = param.in === 'path' && (style === 'matrix' || style === 'label')\n // Like Test Request, leave the template visible when no example supplies a styled path value.\n const paramValue = isStyledPath\n ? deSerializeParameter(selected.value, param)\n : getParameterValue(param, example, defaultDisabled, openapiVersion, jsonSchemaDialect)\n if (\n isStyledPath\n ? !selected.example || isParamDisabled(param, selected.example, defaultDisabled)\n : paramValue === undefined\n ) {\n continue\n }\n\n switch (param.in) {\n case 'path': {\n const allowReserved = openapiVersion?.startsWith('3.2.') && 'schema' in param && param.allowReserved === true\n hasReservedPathParameter ||= Boolean(allowReserved)\n\n if (isStyledPath) {\n const value = serializePathParameter(\n param.name,\n {\n value: paramValue,\n style,\n explode,\n includeUndefinedPrefix: includesUndefinedPathPrefix(openapiVersion),\n },\n undefined,\n allowReserved,\n )\n // Support older samples that include a URI template operator in the path.\n const operator = style === 'matrix' ? ';' : '.'\n const name = newUrl.includes(`{${param.name}}`) ? param.name : `${operator}${param.name}`\n substitutePathParameter(name, value, style === 'label' && !allowReserved)\n } else if (allowReserved) {\n substitutePathParameter(\n param.name,\n serializeReservedPathParameter(param.name, { value: paramValue, style, explode }),\n )\n } else {\n const value = style === 'simple' ? serializeSimpleStyle(paramValue, explode) : paramValue\n substitutePathParameter(param.name, String(value))\n }\n break\n }\n\n case 'query': {\n // Content type parameters should be serialized according to the parameter's own content type\n if ('content' in param && param.content) {\n // We grab the first for now but eventually we should support selecting the content type per parameter\n const paramContentType = Object.keys(param.content)[0] ?? 'application/json'\n const serializedValue = serializeContentValue(paramValue, paramContentType)\n appendQueryParameter(param.name, serializedValue, param)\n break\n }\n\n // Handle query parameters\n switch (style) {\n case 'form': {\n const serialized = serializeFormStyle(paramValue, explode)\n\n // If serialized is an array of key-value pairs (exploded object or array)\n if (Array.isArray(serialized)) {\n for (const entry of serialized) {\n const key = entry.key || param.name\n appendQueryParameter(key, String(entry.value), param)\n }\n }\n // Otherwise, convert to string\n else {\n appendQueryParameter(param.name, String(serialized), param)\n }\n break\n }\n case 'spaceDelimited': {\n const serialized = serializeSpaceDelimitedStyle(paramValue)\n appendQueryParameter(param.name, serialized, param)\n break\n }\n case 'pipeDelimited': {\n const serialized = serializePipeDelimitedStyle(paramValue)\n appendQueryParameter(param.name, serialized, param)\n break\n }\n case 'deepObject': {\n // OAS marks deepObject-on-array and deepObject+explode:false as undefined.\n // Mirror process-body: fall back to form/explode:true for arrays and always\n // invoke the serializer for objects so authors get useful output instead of\n // a silently-dropped parameter.\n if (Array.isArray(paramValue)) {\n const serialized = serializeFormStyle(paramValue, true)\n if (Array.isArray(serialized)) {\n for (const entry of serialized) {\n const key = entry.key || param.name\n appendQueryParameter(key, String(entry.value), param)\n }\n } else {\n appendQueryParameter(param.name, String(serialized), param)\n }\n } else {\n const entries = serializeDeepObjectStyle(param.name, paramValue)\n for (const entry of entries) {\n appendQueryParameter(entry.key, entry.value, param)\n }\n }\n break\n }\n\n // Default to form style\n default:\n appendQueryParameter(param.name, String(paramValue), param)\n }\n break\n }\n\n // Headers only support 'simple' style according to OpenAPI 3.1.1\n // For arrays, simple style always produces comma-separated values regardless of explode\n // The explode parameter only affects object serialization\n case 'header': {\n const serialized = serializeSimpleStyle(paramValue, explode)\n newHeaders.push({ name: param.name, value: String(serialized) })\n break\n }\n\n // Keep cookie style separate so snippet generators cannot percent-encode it.\n case 'cookie': {\n const [major, minor] = (openapiVersion ?? '').split('.')\n const error =\n major === '3' && minor === '2' && !('content' in param)\n ? getCookieSerializationError(param, paramValue)\n : undefined\n if (error) {\n throw new CookieSerializationError(error)\n }\n if (style === 'cookie') {\n cookieStyleEntries.push(...serializeCookieStyle(param.name, paramValue, explode))\n break\n }\n const serialized = serializeFormStyleForCookies(paramValue, explode)\n\n // If serialized is an array of key-value pairs (exploded object or array)\n if (Array.isArray(serialized)) {\n for (const entry of serialized) {\n const key = entry.key || param.name\n const value = entry.value === null ? 'null' : String(entry.value)\n newCookies.push({ name: key, value })\n }\n }\n // Otherwise, convert to string\n else {\n const value = serialized === null ? 'null' : String(serialized)\n newCookies.push({ name: param.name, value })\n }\n break\n }\n }\n }\n\n // HAR cookie entries are encoded by snippet generators. Use a complete header\n // when cookie style is present, preserving legacy encoding for other cookies.\n if (cookieStyleEntries.length || serializedCookies.length) {\n const cookieValue = [\n ...newCookies.map((cookie) => `${encodeURIComponent(cookie.name)}=${encodeURIComponent(cookie.value)}`),\n ...cookieStyleEntries.map((cookie) => `${cookie.name}=${cookie.value}`),\n ...serializedCookies,\n ].join('; ')\n const existing = newHeaders.find((header) => header.name.toLowerCase() === 'cookie')\n if (existing) {\n newHeaders.splice(newHeaders.indexOf(existing), 1, {\n ...existing,\n value: existing.value ? `${existing.value}; ${cookieValue}` : cookieValue,\n })\n } else {\n newHeaders.push({ name: 'Cookie', value: cookieValue })\n }\n }\n\n if (serializedQuery.length) {\n const hashIndex = newUrl.indexOf('#')\n const hash = hashIndex < 0 ? '' : newUrl.slice(hashIndex)\n const base = hashIndex < 0 ? newUrl : newUrl.slice(0, hashIndex)\n newUrl = `${base}${base.includes('?') ? '&' : '?'}${serializedQuery.join('&')}${hash}`\n }\n\n if (hasReservedPathParameter) {\n assertReservedPathUrl(newUrl)\n }\n if (hasStyledLabel && hasPathDotSegment(newUrl, markedPathUrl)) {\n throw new URIError('A label-style path parameter produces a dot segment that browsers remove.')\n }\n\n return {\n url: newUrl,\n headers: newHeaders,\n queryString: newQueryString,\n cookies: cookieStyleEntries.length || serializedCookies.length ? [] : newCookies,\n hasCookieStyleEntries: cookieStyleEntries.length > 0 || serializedCookies.length > 0,\n ...(serializedQuery.length ? { hasSerializedQuery: true } : {}),\n }\n}\n"],"mappings":";;;;;;;;AAkCA,IAAaA,IAAb,cAA8C,MAAM,CAAC,GAc/CC,KAAqB,OACxBC,KAAU,CAAC,EAAA,CAAG,KAAK,MAAUC,EAAeC,CAAK,CAAC,CAAC,CAAC,QAAQ,MAAUA,MAAU,KAAA,CAAS,GAGtFC,KAAmB,MACnB,mBAAmBD,KAASA,EAAM,kBAAkB,KAAA,IAC/CA,EAAM,gBAEX,YAAYA,KAASA,EAAM,UAAU,OAAOA,EAAM,UAAW,YAAY,mBAAmBA,EAAM,SAC5FA,EAAM,OAAuC,kBAAkB,KAElE,IAOHE,KAA+B,MAAgE;CAEnG,IAAIF,EAAM,OAAO,UAEf,OAAO;EAAE,OAAO;EAAU,SADV,aAAaA,KAASA,EAAM,YAAY,KAAA,KAAYA,EAAM;CACxC;CAIpC,IAAIA,EAAM,OAAO,UAAU;EACzB,IAAMG,IAAU,aAAaH,KAASA,EAAM,YAAY,KAAA,IAAYA,EAAM,UAAU;EACpF,OAAO;GAAE,OAAO,WAAWA,KAASA,EAAM,UAAU,WAAW,WAAW;GAAQ;EAAQ;CAC5F;CAEA,IAAMI,IAAe;EACnB,MAAM;EACN,OAAO;EACP,aAAa;EACb,QAAQ;EACR,QAAQ;CACV,EAAEJ,EAAM,KAGFK,IAAQ,WAAWL,KAASA,EAAM,QAAQA,EAAM,QAAQI;CAK9D,OAAO;EAAE;EAAO,SAFA,aAAaJ,KAASA,EAAM,YAAY,KAAA,IAAYA,EAAM,UAAUK,MAAU;CAEtE;AAC1B,GAOMC,KACJ,GACA,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ACL,CAAC,CAAC,KAAK,IAAI,GACLgD,IAAW1D,EAAW,MAAM,MAAW2D,EAAO,KAAK,YAAY,MAAM,QAAQ;EACnF,AAAID,IACF1D,EAAW,OAAOA,EAAW,QAAQ0D,CAAQ,GAAG,GAAG;GACjD,GAAGA;GACH,OAAOA,EAAS,QAAQ,GAAGA,EAAS,MAAM,IAAIF,MAAgBA;EAChE,CAAC,IAEDxD,EAAW,KAAK;GAAE,MAAM;GAAU,OAAOwD;EAAY,CAAC;CAE1D;CAEA,IAAI/C,EAAgB,QAAQ;EAC1B,IAAMa,IAAYjB,EAAO,QAAQ,GAAG,GAC9BkB,IAAOD,IAAY,IAAI,KAAKjB,EAAO,MAAMiB,CAAS,GAClDE,IAAOF,IAAY,IAAIjB,IAASA,EAAO,MAAM,GAAGiB,CAAS;EAC/D,IAAS,GAAGE,IAAOA,EAAK,SAAS,GAAG,IAAI,MAAM,MAAMf,EAAgB,KAAK,GAAG,IAAIc;CAClF;CAKA,IAHIf,KACFoD,EAAsBvD,CAAM,GAE1BE,KAAkBsD,EAAkBxD,GAAQC,CAAa,GAC3D,MAAU,SAAS,2EAA2E;CAGhG,OAAO;EACL,KAAKD;EACL,SAASL;EACT,aAAaE;EACb,SAASE,EAAmB,UAAUM,EAAkB,SAAS,CAAC,IAAIP;EACtE,uBAAuBC,EAAmB,SAAS,KAAKM,EAAkB,SAAS;EACnF,GAAID,EAAgB,SAAS,EAAE,oBAAoB,GAAK,IAAI,CAAC;CAC/D;AACF"}
package/dist/constants.js CHANGED
@@ -1,5 +1,5 @@
1
1
  // src/constants.ts
2
- var e = typeof OVERRIDE_PACKAGE_VERSION < "u" ? OVERRIDE_PACKAGE_VERSION : "0.11.1";
2
+ var e = typeof OVERRIDE_PACKAGE_VERSION < "u" ? OVERRIDE_PACKAGE_VERSION : "0.11.2";
3
3
  export { e as APP_VERSION };
4
4
 
5
5
  //# sourceMappingURL=constants.js.map
@@ -85,8 +85,8 @@ declare const __VLS_export: import("vue").DefineComponent<{
85
85
  cycleKey?: unknown;
86
86
  } & SchemaRenderingProps> & Readonly<{}>, {
87
87
  required: boolean;
88
- level: number;
89
88
  hideModelNames: boolean;
89
+ level: number;
90
90
  depth: number;
91
91
  compact: boolean;
92
92
  }, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
@@ -1 +1 @@
1
- {"version":3,"file":"SchemaProperty.vue.d.ts","sourceRoot":"","sources":["../../src/schema/SchemaProperty.vue"],"names":[],"mappings":"AAi3CA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,gCAAgC,CAAA;AAGvE,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,sDAAsD,CAAA;AAClF,OAAO,KAAK,EACV,mBAAmB,EACnB,YAAY,EACb,MAAM,8DAA8D,CAAA;AAErE,OAAO,EAUL,KAAK,SAAS,EACf,MAAM,KAAK,CAAA;AAsCZ,OAAO,KAAK,EAAE,aAAa,EAAE,oBAAoB,EAAE,MAAM,SAAS,CAAA;wBAU7C,OAAO,YAAY;AAAxC,wBAAyC;AACzC,QAAA,MAAM,YAAY;SAEP,MAAM,GAAG,SAAS;YACf,YAAY,GAAG,SAAS;IAChC,oEAAoE;aAC3D,MAAM,EAAE;IACjB,uFAAuF;sBACrE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC;qBACxB,OAAO;YAChB,MAAM;IACd;;;OAGG;YACK,MAAM;WACP,MAAM;eACF,OAAO;cACR,OAAO;oBACD,mBAAmB;kBACrB,MAAM;qBACH,OAAO;kBACV,OAAO;IACrB,kGAAkG;gBACtF,MAAM,GAAG,IAAI;cACf,sBAAsB,GAAG,mBAAmB;iBACzC,MAAM,EAAE;cACX,iBAAiB,GAAG,IAAI;aACzB,aAAa;IACtB,+EAA+E;wBAC3D,MAAM,EAAE;IAC5B,iFAAiF;0BAC3D,YAAY;IAClC,mFAAmF;oBACnE,MAAM;IACtB,uFAAuF;sBACrE,MAAM,EAAE;IAC1B,oFAAoF;6BAC3D,MAAM;IAC/B,2EAA2E;eAChE,OAAO;;SArCb,MAAM,GAAG,SAAS;YACf,YAAY,GAAG,SAAS;IAChC,oEAAoE;aAC3D,MAAM,EAAE;IACjB,uFAAuF;sBACrE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC;qBACxB,OAAO;YAChB,MAAM;IACd;;;OAGG;YACK,MAAM;WACP,MAAM;eACF,OAAO;cACR,OAAO;oBACD,mBAAmB;kBACrB,MAAM;qBACH,OAAO;kBACV,OAAO;IACrB,kGAAkG;gBACtF,MAAM,GAAG,IAAI;cACf,sBAAsB,GAAG,mBAAmB;iBACzC,MAAM,EAAE;cACX,iBAAiB,GAAG,IAAI;aACzB,aAAa;IACtB,+EAA+E;wBAC3D,MAAM,EAAE;IAC5B,iFAAiF;0BAC3D,YAAY;IAClC,mFAAmF;oBACnE,MAAM;IACtB,uFAAuF;sBACrE,MAAM,EAAE;IAC1B,oFAAoF;6BAC3D,MAAM;IAC/B,2EAA2E;eAChE,OAAO;;cAvBP,OAAO;WAPV,MAAM;oBAWG,OAAO;WANhB,MAAM;aAGJ,OAAO;6EA+iDnB,CAAC"}
1
+ {"version":3,"file":"SchemaProperty.vue.d.ts","sourceRoot":"","sources":["../../src/schema/SchemaProperty.vue"],"names":[],"mappings":"AAk3CA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,gCAAgC,CAAA;AAGvE,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,sDAAsD,CAAA;AAClF,OAAO,KAAK,EACV,mBAAmB,EACnB,YAAY,EACb,MAAM,8DAA8D,CAAA;AAErE,OAAO,EAUL,KAAK,SAAS,EACf,MAAM,KAAK,CAAA;AAsCZ,OAAO,KAAK,EAAE,aAAa,EAAE,oBAAoB,EAAE,MAAM,SAAS,CAAA;wBAU7C,OAAO,YAAY;AAAxC,wBAAyC;AACzC,QAAA,MAAM,YAAY;SAEP,MAAM,GAAG,SAAS;YACf,YAAY,GAAG,SAAS;IAChC,oEAAoE;aAC3D,MAAM,EAAE;IACjB,uF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3
  import t from "../_virtual/_plugin-vue_export-helper.js";
4
4
  // src/schema/SchemaProperty.vue
5
- var n = /*#__PURE__*/ t(e, [["__scopeId", "data-v-171bc332"]]);
5
+ var n = /*#__PURE__*/ t(e, [["__scopeId", "data-v-9c93c754"]]);
6
6
  export { n as default };
7
7
 
8
8
  //# sourceMappingURL=SchemaProperty.vue.js.map
@@ -333,8 +333,13 @@ var ze = ["id"], Be = {
333
333
  name: "trailing",
334
334
  fn: x(() => [f(t, {
335
335
  anchorId: O.value.join("."),
336
- eventBus: p.eventBus
337
- }, null, 8, ["anchorId", "eventBus"])]),
336
+ eventBus: p.eventBus,
337
+ propertyName: p.name
338
+ }, null, 8, [
339
+ "anchorId",
340
+ "eventBus",
341
+ "propertyName"
342
+ ])]),
338
343
  key: "3"
339
344
  } : void 0
340
345
  ]), 1040, [