@scalar/api-client 2.2.33 → 2.2.35

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 (35) hide show
  1. package/CHANGELOG.md +31 -0
  2. package/dist/components/AddressBar/AddressBar.vue.js +2 -2
  3. package/dist/components/AddressBar/AddressBar.vue2.js +27 -26
  4. package/dist/components/ContextBar.vue.d.ts.map +1 -1
  5. package/dist/components/ContextBar.vue.js +1 -1
  6. package/dist/components/DataTable/DataTableCheckbox.vue.d.ts.map +1 -1
  7. package/dist/components/DataTable/DataTableCheckbox.vue.js +20 -15
  8. package/dist/layouts/App/create-api-client-app.d.ts +3 -1
  9. package/dist/layouts/App/create-api-client-app.d.ts.map +1 -1
  10. package/dist/layouts/Modal/create-api-client-modal.d.ts +6 -2
  11. package/dist/layouts/Modal/create-api-client-modal.d.ts.map +1 -1
  12. package/dist/layouts/Web/create-api-client-web.d.ts +3 -1
  13. package/dist/layouts/Web/create-api-client-web.d.ts.map +1 -1
  14. package/dist/libs/create-client.d.ts +3 -1
  15. package/dist/libs/create-client.d.ts.map +1 -1
  16. package/dist/store/events.d.ts +3 -1
  17. package/dist/store/events.d.ts.map +1 -1
  18. package/dist/store/store.d.ts +3 -1
  19. package/dist/store/store.d.ts.map +1 -1
  20. package/dist/style.css +1 -1
  21. package/dist/views/Request/RequestSection/RequestAuth/RequestAuthDataTable.vue.js +2 -2
  22. package/dist/views/Request/RequestSection/RequestAuth/RequestAuthDataTable.vue2.js +30 -27
  23. package/dist/views/Request/RequestSection/RequestBody.vue.d.ts.map +1 -1
  24. package/dist/views/Request/RequestSection/RequestBody.vue.js +2 -2
  25. package/dist/views/Request/RequestSection/RequestBody.vue2.js +38 -38
  26. package/dist/views/Request/RequestSection/RequestPathParams.vue.d.ts.map +1 -1
  27. package/dist/views/Request/RequestSection/RequestPathParams.vue.js +51 -42
  28. package/dist/views/Request/RequestSection/RequestTable.vue.d.ts +3 -3
  29. package/dist/views/Request/RequestSection/RequestTable.vue.d.ts.map +1 -1
  30. package/dist/views/Request/RequestSection/RequestTable.vue.js +2 -2
  31. package/dist/views/Request/RequestSection/RequestTable.vue2.js +68 -68
  32. package/dist/views/Request/ResponseSection/ResponseEmpty.vue2.js +1 -1
  33. package/dist/views/Request/libs/oauth2.d.ts.map +1 -1
  34. package/dist/views/Request/libs/oauth2.js +1 -1
  35. package/package.json +11 -11
@@ -1,25 +1,25 @@
1
- import { defineComponent as C, openBlock as u, createBlock as s, unref as p, withCtx as r, createElementBlock as y, Fragment as V, renderList as S, createElementVNode as d, createCommentVNode as m, createVNode as i, normalizeClass as U, createSlots as h, createTextVNode as E, toDisplayString as k, computed as T } from "vue";
1
+ import { defineComponent as C, openBlock as r, createBlock as i, withCtx as u, createElementBlock as b, Fragment as v, renderList as F, createElementVNode as s, createVNode as d, normalizeClass as R, createSlots as $, createCommentVNode as y, createTextVNode as S, toDisplayString as k, unref as V, computed as U } from "vue";
2
2
  import w from "../../../components/CodeInput/CodeInput.vue.js";
3
- import N from "../../../components/DataTable/DataTable.vue.js";
4
- import c from "../../../components/DataTable/DataTableCell.vue.js";
5
- import q from "../../../components/DataTable/DataTableCheckbox.vue.js";
6
- import I from "../../../components/DataTable/DataTableRow.vue.js";
7
- import { ScalarButton as z, ScalarIcon as D } from "@scalar/components";
8
- import H from "./RequestTableTooltip.vue.js";
9
- const A = { class: "contents" }, M = { class: "text-c-2 max-w-[100%] overflow-hidden filemask flex items-end justify-end" }, O = ["onClick"], X = /* @__PURE__ */ C({
3
+ import T from "../../../components/DataTable/DataTable.vue.js";
4
+ import p from "../../../components/DataTable/DataTableCell.vue.js";
5
+ import D from "../../../components/DataTable/DataTableCheckbox.vue.js";
6
+ import E from "../../../components/DataTable/DataTableRow.vue.js";
7
+ import { ScalarButton as N, ScalarIcon as q } from "@scalar/components";
8
+ import I from "./RequestTableTooltip.vue.js";
9
+ const z = { class: "contents" }, A = { class: "text-c-2 max-w-[100%] overflow-hidden filemask flex items-end justify-end" }, M = ["onClick"], W = /* @__PURE__ */ C({
10
10
  __name: "RequestTable",
11
11
  props: {
12
12
  items: {},
13
- isEnabledHidden: { type: Boolean, default: !1 },
13
+ hasCheckboxDisabled: { type: Boolean, default: !1 },
14
14
  showUploadButton: { type: Boolean, default: !1 }
15
15
  },
16
16
  emits: ["updateRow", "toggleRow", "addRow", "deleteRow", "inputFocus", "inputBlur", "uploadFile", "removeFile"],
17
- setup(g, { emit: x }) {
18
- const B = g, a = x, _ = B.isEnabledHidden ? ["", ""] : ["", "", "36px"], f = (e, o, l) => {
19
- a("updateRow", e, o, l);
20
- }, F = (e) => {
21
- a("uploadFile", e);
22
- }, b = (e) => !!(e.description || e.type || e.default || e.format), v = (e) => T(() => {
17
+ setup(O, { emit: x }) {
18
+ const n = x, _ = ["", "", "36px"], m = (e, o, l) => {
19
+ n("updateRow", e, o, l);
20
+ }, g = (e) => {
21
+ n("uploadFile", e);
22
+ }, c = (e) => !!(e.description || e.type || e.default || e.format), f = (e) => U(() => {
23
23
  if (e.type === "integer" && e.value !== void 0) {
24
24
  const o = Number(e.value);
25
25
  if (e.minimum !== void 0 && o < e.minimum)
@@ -28,45 +28,45 @@ const A = { class: "contents" }, M = { class: "text-c-2 max-w-[100%] overflow-hi
28
28
  return `Max is ${e.maximum}`;
29
29
  }
30
30
  return !1;
31
- }), R = (e) => Array.isArray(e.default) && e.default.length === 1 ? e.default[0] : e.default;
32
- return (e, o) => (u(), s(N, {
31
+ }), B = (e) => Array.isArray(e.default) && e.default.length === 1 ? e.default[0] : e.default;
32
+ return (e, o) => (r(), i(T, {
33
33
  class: "flex-1",
34
- columns: p(_)
34
+ columns: _
35
35
  }, {
36
- default: r(() => [
37
- (u(!0), y(V, null, S(e.items, (l, t) => (u(), s(I, { key: t }, {
38
- default: r(() => [
39
- d("label", A, [
40
- o[4] || (o[4] = d("span", { class: "sr-only" }, "Row Enabled", -1)),
41
- e.isEnabledHidden ? m("", !0) : (u(), s(q, {
42
- key: 0,
36
+ default: u(() => [
37
+ (r(!0), b(v, null, F(e.items, (l, t) => (r(), i(E, { key: t }, {
38
+ default: u(() => [
39
+ s("label", z, [
40
+ o[4] || (o[4] = s("span", { class: "sr-only" }, "Row Enabled", -1)),
41
+ d(D, {
43
42
  class: "!border-r-1/2",
43
+ disabled: e.hasCheckboxDisabled,
44
44
  modelValue: l.enabled,
45
- "onUpdate:modelValue": (n) => a("toggleRow", t, n)
46
- }, null, 8, ["modelValue", "onUpdate:modelValue"]))
45
+ "onUpdate:modelValue": (a) => n("toggleRow", t, a)
46
+ }, null, 8, ["disabled", "modelValue", "onUpdate:modelValue"])
47
47
  ]),
48
- i(c, null, {
49
- default: r(() => [
50
- i(w, {
48
+ d(p, null, {
49
+ default: u(() => [
50
+ d(w, {
51
51
  disableCloseBrackets: "",
52
52
  disableEnter: "",
53
53
  disableTabIndent: "",
54
54
  modelValue: l.key,
55
55
  placeholder: "Key",
56
56
  required: l.required,
57
- onBlur: o[0] || (o[0] = (n) => a("inputBlur")),
58
- onFocus: o[1] || (o[1] = (n) => a("inputFocus")),
59
- onSelectVariable: (n) => f(t, "key", n),
60
- "onUpdate:modelValue": (n) => a("updateRow", t, "key", n)
57
+ onBlur: o[0] || (o[0] = (a) => n("inputBlur")),
58
+ onFocus: o[1] || (o[1] = (a) => n("inputFocus")),
59
+ onSelectVariable: (a) => m(t, "key", a),
60
+ "onUpdate:modelValue": (a) => n("updateRow", t, "key", a)
61
61
  }, null, 8, ["modelValue", "required", "onSelectVariable", "onUpdate:modelValue"])
62
62
  ]),
63
63
  _: 2
64
64
  }, 1024),
65
- i(c, null, {
66
- default: r(() => [
67
- i(w, {
68
- class: U({
69
- "pr-6": b(l)
65
+ d(p, null, {
66
+ default: u(() => [
67
+ d(w, {
68
+ class: R({
69
+ "pr-6": c(l)
70
70
  }),
71
71
  default: l.default,
72
72
  disableCloseBrackets: "",
@@ -79,23 +79,23 @@ const A = { class: "contents" }, M = { class: "text-c-2 max-w-[100%] overflow-hi
79
79
  nullable: l.nullable,
80
80
  placeholder: "Value",
81
81
  type: l.type,
82
- onBlur: o[2] || (o[2] = (n) => a("inputBlur")),
83
- onFocus: o[3] || (o[3] = (n) => a("inputFocus")),
84
- onSelectVariable: (n) => f(t, "value", n),
85
- "onUpdate:modelValue": (n) => a("updateRow", t, "value", n)
86
- }, h({
87
- icon: r(() => [
88
- b(l) ? (u(), s(H, {
82
+ onBlur: o[2] || (o[2] = (a) => n("inputBlur")),
83
+ onFocus: o[3] || (o[3] = (a) => n("inputFocus")),
84
+ onSelectVariable: (a) => m(t, "value", a),
85
+ "onUpdate:modelValue": (a) => n("updateRow", t, "value", a)
86
+ }, $({
87
+ icon: u(() => [
88
+ c(l) ? (r(), i(I, {
89
89
  key: 0,
90
- item: { ...l, default: R(l) }
91
- }, null, 8, ["item"])) : m("", !0)
90
+ item: { ...l, default: B(l) }
91
+ }, null, 8, ["item"])) : y("", !0)
92
92
  ]),
93
93
  _: 2
94
94
  }, [
95
- v(l).value ? {
95
+ f(l).value ? {
96
96
  name: "warning",
97
- fn: r(() => [
98
- E(k(v(l).value), 1)
97
+ fn: u(() => [
98
+ S(k(f(l).value), 1)
99
99
  ]),
100
100
  key: "0"
101
101
  } : void 0
@@ -103,32 +103,32 @@ const A = { class: "contents" }, M = { class: "text-c-2 max-w-[100%] overflow-hi
103
103
  ]),
104
104
  _: 2
105
105
  }, 1024),
106
- e.showUploadButton ? (u(), s(c, {
106
+ e.showUploadButton ? (r(), i(p, {
107
107
  key: 0,
108
108
  class: "group/upload p-1 overflow-hidden relative text-ellipsis whitespace-nowrap"
109
109
  }, {
110
- default: r(() => {
111
- var n;
110
+ default: u(() => {
111
+ var a;
112
112
  return [
113
- l.file ? (u(), y(V, { key: 0 }, [
114
- d("div", M, [
115
- d("span", null, k((n = l.file) == null ? void 0 : n.name), 1)
113
+ l.file ? (r(), b(v, { key: 0 }, [
114
+ s("div", A, [
115
+ s("span", null, k((a = l.file) == null ? void 0 : a.name), 1)
116
116
  ]),
117
- d("button", {
117
+ s("button", {
118
118
  class: "absolute bg-b-2 font-medium centered-x centered-y hidden rounded text-center p-0.5 w-[calc(100%_-_8px)] group-hover/upload:block text-xs",
119
119
  type: "button",
120
- onClick: ($) => a("removeFile", t)
121
- }, " Delete ", 8, O)
122
- ], 64)) : (u(), s(p(z), {
120
+ onClick: (h) => n("removeFile", t)
121
+ }, " Delete ", 8, M)
122
+ ], 64)) : (r(), i(V(N), {
123
123
  key: 1,
124
124
  class: "bg-b-2 hover:bg-b-3 border-0 py-px text-c-2 shadow-none",
125
125
  size: "sm",
126
126
  variant: "outlined",
127
- onClick: ($) => F(t)
127
+ onClick: (h) => g(t)
128
128
  }, {
129
- default: r(() => [
130
- o[5] || (o[5] = d("span", null, "File", -1)),
131
- i(p(D), {
129
+ default: u(() => [
130
+ o[5] || (o[5] = s("span", null, "File", -1)),
131
+ d(V(q), {
132
132
  class: "ml-1",
133
133
  icon: "UploadSimple",
134
134
  size: "xs",
@@ -140,15 +140,15 @@ const A = { class: "contents" }, M = { class: "text-c-2 max-w-[100%] overflow-hi
140
140
  ];
141
141
  }),
142
142
  _: 2
143
- }, 1024)) : m("", !0)
143
+ }, 1024)) : y("", !0)
144
144
  ]),
145
145
  _: 2
146
146
  }, 1024))), 128))
147
147
  ]),
148
148
  _: 1
149
- }, 8, ["columns"]));
149
+ }));
150
150
  }
151
151
  });
152
152
  export {
153
- X as default
153
+ W as default
154
154
  };
@@ -17,7 +17,7 @@ const K = { class: "border-t relative col-1 flex-center gap-6 p-2 capitalize" },
17
17
  a.commandPalette.emit({ commandName: "Create Request" });
18
18
  }, y = (i) => {
19
19
  i != null && i.createNew && v.name === "request" && f();
20
- }, b = "2.2.33";
20
+ }, b = "2.2.35";
21
21
  return R(() => a.hotKeys.on(y)), C(() => a.hotKeys.off(y)), (i, e) => (r(), l("div", K, [
22
22
  o("div", {
23
23
  class: k(["flex h-[calc(100%_-_50px)] flex-col items-center justify-center", {
@@ -1 +1 @@
1
- {"version":3,"file":"oauth2.d.ts","sourceRoot":"","sources":["../../../../src/views/Request/libs/oauth2.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,QAAQ,CAAA;AAC3C,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,EAAE,MAAM,iCAAiC,CAAA;AAGzE,qDAAqD;AACrD,KAAK,eAAe,GAAG,OAAO,CAAC,UAAU,EAAE;IAAE,IAAI,EAAE,UAAU,CAAA;CAAE,CAAC,CAAA;AAEhE,KAAK,SAAS,GAAG;IACf,YAAY,EAAE,MAAM,CAAA;IACpB,aAAa,EAAE,MAAM,CAAA;IACrB,mBAAmB,EAAE,MAAM,CAAA;CAC5B,CAAA;AAmBD;;GAEG;AACH,eAAO,MAAM,qBAAqB,aACtB,MAAM,YACN,SAAS,GAAG,OAAO,KAC5B,OAAO,CAAC,MAAM,CAahB,CAAA;AAED;;;;GAIG;AACH,eAAO,MAAM,eAAe,SACpB,UAAU,gBAEF,MAAM,aAET,MAAM,KAChB,OAAO,CAAC,aAAa,CAAC,MAAM,CAAC,CAsJ/B,CAAA;AAED;;;GAGG;AACH,eAAO,MAAM,gBAAgB,SACrB,eAAe,UACb,MAAM,8BAKX;IACD,IAAI,CAAC,EAAE,MAAM,CAAA;IACb,IAAI,CAAC,EAAE,SAAS,GAAG,IAAI,CAAA;IACvB,QAAQ,CAAC,EAAE,MAAM,CAAA;CAClB,KACA,OAAO,CAAC,aAAa,CAAC,MAAM,CAAC,CA6D/B,CAAA"}
1
+ {"version":3,"file":"oauth2.d.ts","sourceRoot":"","sources":["../../../../src/views/Request/libs/oauth2.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,QAAQ,CAAA;AAC3C,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,EAAE,MAAM,iCAAiC,CAAA;AAGzE,qDAAqD;AACrD,KAAK,eAAe,GAAG,OAAO,CAAC,UAAU,EAAE;IAAE,IAAI,EAAE,UAAU,CAAA;CAAE,CAAC,CAAA;AAEhE,KAAK,SAAS,GAAG;IACf,YAAY,EAAE,MAAM,CAAA;IACpB,aAAa,EAAE,MAAM,CAAA;IACrB,mBAAmB,EAAE,MAAM,CAAA;CAC5B,CAAA;AAmBD;;GAEG;AACH,eAAO,MAAM,qBAAqB,aACtB,MAAM,YACN,SAAS,GAAG,OAAO,KAC5B,OAAO,CAAC,MAAM,CAahB,CAAA;AAED;;;;GAIG;AACH,eAAO,MAAM,eAAe,SACpB,UAAU,gBAEF,MAAM,aAET,MAAM,KAChB,OAAO,CAAC,aAAa,CAAC,MAAM,CAAC,CAuJ/B,CAAA;AAED;;;GAGG;AACH,eAAO,MAAM,gBAAgB,SACrB,eAAe,UACb,MAAM,8BAKX;IACD,IAAI,CAAC,EAAE,MAAM,CAAA;IACb,IAAI,CAAC,EAAE,SAAS,GAAG,IAAI,CAAA;IACvB,QAAQ,CAAC,EAAE,MAAM,CAAA;CAClB,KACA,OAAO,CAAC,aAAa,CAAC,MAAM,CAAC,CA6D/B,CAAA"}
@@ -15,7 +15,7 @@ const P = () => {
15
15
  proxyUrl: o
16
16
  });
17
17
  {
18
- const s = (Math.random() + 1).toString(36).substring(7), t = new URL(e.authorizationUrl);
18
+ const s = (Math.random() + 1).toString(36).substring(2, 10), t = new URL(e.authorizationUrl);
19
19
  let l = null;
20
20
  if (e.type === "implicit")
21
21
  t.searchParams.set("response_type", "token");
package/package.json CHANGED
@@ -18,7 +18,7 @@
18
18
  "rest",
19
19
  "testing"
20
20
  ],
21
- "version": "2.2.33",
21
+ "version": "2.2.35",
22
22
  "engines": {
23
23
  "node": ">=18"
24
24
  },
@@ -179,21 +179,21 @@
179
179
  "whatwg-mimetype": "^4.0.0",
180
180
  "yaml": "^2.4.5",
181
181
  "zod": "^3.23.8",
182
+ "@scalar/components": "0.13.15",
182
183
  "@scalar/draggable": "0.1.8",
183
184
  "@scalar/icons": "0.1.2",
184
- "@scalar/import": "0.2.17",
185
- "@scalar/oas-utils": "0.2.97",
186
185
  "@scalar/object-utils": "1.1.12",
186
+ "@scalar/import": "0.2.18",
187
187
  "@scalar/openapi-parser": "0.10.4",
188
188
  "@scalar/openapi-types": "0.1.6",
189
- "@scalar/themes": "0.9.60",
190
- "@scalar/postman-to-openapi": "0.1.20",
191
- "@scalar/types": "0.0.26",
192
- "@scalar/use-codemirror": "0.11.58",
193
- "@scalar/use-hooks": "0.1.14",
189
+ "@scalar/oas-utils": "0.2.98",
190
+ "@scalar/themes": "0.9.61",
191
+ "@scalar/postman-to-openapi": "0.1.21",
192
+ "@scalar/types": "0.0.27",
193
+ "@scalar/use-codemirror": "0.11.60",
194
+ "@scalar/use-hooks": "0.1.15",
194
195
  "@scalar/use-toasts": "0.7.8",
195
- "@scalar/use-tooltip": "1.0.5",
196
- "@scalar/components": "0.13.14"
196
+ "@scalar/use-tooltip": "1.0.5"
197
197
  },
198
198
  "devDependencies": {
199
199
  "@types/js-cookie": "^3.0.6",
@@ -211,7 +211,7 @@
211
211
  "vite-svg-loader": "^5.1.0",
212
212
  "vitest": "^1.6.0",
213
213
  "@scalar/build-tooling": "0.1.12",
214
- "@scalar/galaxy": "0.2.16"
214
+ "@scalar/galaxy": "0.2.17"
215
215
  },
216
216
  "scripts": {
217
217
  "build": "vite build && pnpm types:build && tsc-alias -p tsconfig.build.json",