@scalar/api-client 2.1.8 → 2.1.9

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 (78) hide show
  1. package/CHANGELOG.md +11 -0
  2. package/dist/assets/rabbit.ascii.js +11 -0
  3. package/dist/assets/rabbitjump.ascii.js +11 -0
  4. package/dist/components/CodeInput/CodeInput.vue.d.ts.map +1 -1
  5. package/dist/components/CodeInput/CodeInput.vue.js +2 -2
  6. package/dist/components/CommandPalette/CommandPaletteCollection.vue.d.ts.map +1 -1
  7. package/dist/components/CommandPalette/CommandPaletteCollection.vue.js +7 -7
  8. package/dist/components/ContextBar.vue.d.ts.map +1 -1
  9. package/dist/components/ContextBar.vue.js +2 -2
  10. package/dist/components/ContextBar.vue2.js +22 -13
  11. package/dist/components/DarkModeToggle/DarkModeIconToggle.vue.js +1 -1
  12. package/dist/components/IconSelector.vue.d.ts.map +1 -1
  13. package/dist/components/IconSelector.vue.js +4 -3
  14. package/dist/components/ScalarAsciiArt.vue.d.ts.map +1 -1
  15. package/dist/components/ScalarAsciiArt.vue.js +1 -1
  16. package/dist/components/ScalarAsciiArt.vue2.js +10 -10
  17. package/dist/components/SideNav/SideHelp.vue.js +1 -1
  18. package/dist/components/SideNav/SideNav.vue.d.ts.map +1 -1
  19. package/dist/components/SideNav/SideNav.vue.js +2 -2
  20. package/dist/components/SideNav/SideNav.vue2.js +19 -22
  21. package/dist/components/SideNav/SideNavLink.vue.d.ts +0 -2
  22. package/dist/components/SideNav/SideNavLink.vue.d.ts.map +1 -1
  23. package/dist/components/SideNav/SideNavLink.vue.js +19 -21
  24. package/dist/components/Sidebar/Sidebar.vue.js +2 -2
  25. package/dist/components/Sidebar/Sidebar.vue2.js +1 -1
  26. package/dist/components/Sidebar/SidebarButton.vue.d.ts.map +1 -1
  27. package/dist/components/Sidebar/SidebarButton.vue.js +24 -26
  28. package/dist/components/ViewLayout/ViewLayoutSection.vue.js +1 -1
  29. package/dist/layouts/App/ApiClientApp.vue.d.ts.map +1 -1
  30. package/dist/layouts/App/ApiClientApp.vue.js +4 -4
  31. package/dist/layouts/App/create-api-client-app.d.ts +2 -2
  32. package/dist/layouts/App/create-api-client-app.d.ts.map +1 -1
  33. package/dist/layouts/Modal/create-api-client-modal.d.ts +4 -4
  34. package/dist/layouts/Modal/create-api-client-modal.d.ts.map +1 -1
  35. package/dist/layouts/Modal/create-api-client-modal.js +19 -17
  36. package/dist/libs/create-client.d.ts +7 -18
  37. package/dist/libs/create-client.d.ts.map +1 -1
  38. package/dist/store/import-spec.d.ts +3 -2
  39. package/dist/store/import-spec.d.ts.map +1 -1
  40. package/dist/store/import-spec.js +34 -26
  41. package/dist/store/store.d.ts +4 -4
  42. package/dist/style.css +1 -1
  43. package/dist/views/Cookies/Cookies.vue.d.ts.map +1 -1
  44. package/dist/views/Cookies/Cookies.vue2.js +74 -80
  45. package/dist/views/Environment/Environment.vue.d.ts.map +1 -1
  46. package/dist/views/Environment/Environment.vue2.js +86 -92
  47. package/dist/views/Request/Request.vue.d.ts.map +1 -1
  48. package/dist/views/Request/Request.vue.js +1 -1
  49. package/dist/views/Request/Request.vue2.js +26 -26
  50. package/dist/views/Request/RequestSection/RequestAuth/RequestAuth.vue.d.ts.map +1 -1
  51. package/dist/views/Request/RequestSection/RequestAuth/RequestAuth.vue.js +2 -2
  52. package/dist/views/Request/RequestSection/RequestAuth/RequestAuth.vue2.js +88 -80
  53. package/dist/views/Request/RequestSection/RequestSection.vue.d.ts.map +1 -1
  54. package/dist/views/Request/RequestSection/RequestSection.vue.js +45 -45
  55. package/dist/views/Request/RequestSidebar.vue.d.ts.map +1 -1
  56. package/dist/views/Request/RequestSidebar.vue.js +2 -2
  57. package/dist/views/Request/RequestSidebar.vue2.js +131 -108
  58. package/dist/views/Request/ResponseSection/ResponseEmpty.vue.d.ts.map +1 -1
  59. package/dist/views/Request/ResponseSection/ResponseEmpty.vue.js +2 -2
  60. package/dist/views/Request/ResponseSection/ResponseEmpty.vue2.js +8 -5
  61. package/dist/views/Request/ResponseSection/ResponseSection.vue.d.ts.map +1 -1
  62. package/dist/views/Request/ResponseSection/ResponseSection.vue.js +33 -33
  63. package/dist/views/Servers/Servers.vue.d.ts.map +1 -1
  64. package/dist/views/Servers/Servers.vue2.js +48 -54
  65. package/package.json +5 -9
  66. package/dist/components/Search/SearchButton.vue.d.ts +0 -7
  67. package/dist/components/Search/SearchButton.vue.d.ts.map +0 -1
  68. package/dist/components/Search/SearchModal.vue.d.ts +0 -17
  69. package/dist/components/Search/SearchModal.vue.d.ts.map +0 -1
  70. package/dist/components/Search/SearchModal.vue.js +0 -7
  71. package/dist/components/Search/SearchModal.vue2.js +0 -142
  72. package/dist/components/Search/index.d.ts +0 -3
  73. package/dist/components/Search/index.d.ts.map +0 -1
  74. package/dist/components/Search/index.js +0 -4
  75. package/dist/components/SideNav/WorkspaceProfileIcon.vue.js +0 -31
  76. package/dist/components/SideNav/WorkspaceProfileIcon.vue3.js +0 -5
  77. package/dist/components/SubpageHeader.vue.js +0 -7
  78. package/dist/components/SubpageHeader.vue2.js +0 -34
package/package.json CHANGED
@@ -18,7 +18,7 @@
18
18
  "rest",
19
19
  "testing"
20
20
  ],
21
- "version": "2.1.8",
21
+ "version": "2.1.9",
22
22
  "engines": {
23
23
  "node": ">=18"
24
24
  },
@@ -77,10 +77,6 @@
77
77
  "import": "./dist/components/Sidebar/index.js",
78
78
  "types": "./dist/components/Sidebar/index.d.ts"
79
79
  },
80
- "./components/Search": {
81
- "import": "./dist/components/Search/index.js",
82
- "types": "./dist/components/Search/index.d.ts"
83
- },
84
80
  "./components/HttpMethod": {
85
81
  "import": "./dist/components/HttpMethod/index.js",
86
82
  "types": "./dist/components/HttpMethod/index.d.ts"
@@ -131,16 +127,16 @@
131
127
  "zod": "^3.23.8",
132
128
  "@scalar/components": "0.12.48",
133
129
  "@scalar/draggable": "0.1.5",
134
- "@scalar/oas-utils": "0.2.48",
135
- "@scalar/object-utils": "1.1.9",
136
130
  "@scalar/icons": "0.1.0",
131
+ "@scalar/oas-utils": "0.2.49",
137
132
  "@scalar/openapi-parser": "0.8.4",
138
133
  "@scalar/openapi-types": "0.1.1",
134
+ "@scalar/object-utils": "1.1.9",
139
135
  "@scalar/themes": "0.9.32",
140
136
  "@scalar/types": "0.0.11",
141
- "@scalar/use-codemirror": "0.11.14",
142
137
  "@scalar/use-toasts": "0.7.6",
143
- "@scalar/use-tooltip": "1.0.2"
138
+ "@scalar/use-tooltip": "1.0.2",
139
+ "@scalar/use-codemirror": "0.11.14"
144
140
  },
145
141
  "devDependencies": {
146
142
  "@types/content-type": "^1.1.8",
@@ -1,7 +0,0 @@
1
- declare const _default: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
2
- openSearchModal: () => void;
3
- }, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{}>> & {
4
- onOpenSearchModal?: (() => any) | undefined;
5
- }, {}, {}>;
6
- export default _default;
7
- //# sourceMappingURL=SearchButton.vue.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"SearchButton.vue.d.ts","sourceRoot":"","sources":["../../../src/components/Search/SearchButton.vue"],"names":[],"mappings":";;;;;AAoIA,wBAMG"}
@@ -1,17 +0,0 @@
1
- import { type ModalState } from '@scalar/components';
2
- declare const _default: import("vue").DefineComponent<__VLS_TypePropsToOption<{
3
- modalState: ModalState;
4
- }>, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<__VLS_TypePropsToOption<{
5
- modalState: ModalState;
6
- }>>>, {}, {}>;
7
- export default _default;
8
- type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
9
- type __VLS_TypePropsToOption<T> = {
10
- [K in keyof T]-?: {} extends Pick<T, K> ? {
11
- type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
12
- } : {
13
- type: import('vue').PropType<T[K]>;
14
- required: true;
15
- };
16
- };
17
- //# sourceMappingURL=SearchModal.vue.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"SearchModal.vue.d.ts","sourceRoot":"","sources":["../../../src/components/Search/SearchModal.vue"],"names":[],"mappings":"AA8PA,OAAO,EACL,KAAK,UAAU,EAKhB,MAAM,oBAAoB,CAAA;;gBAUb,UAAU;;gBAAV,UAAU;;AA+WxB,wBAMG;AAOH,KAAK,sBAAsB,CAAC,CAAC,IAAI,CAAC,SAAS,SAAS,GAAG,KAAK,GAAG,CAAC,CAAC;AAC5D,KAAK,uBAAuB,CAAC,CAAC,IAAI;KAChC,CAAC,IAAI,MAAM,CAAC,CAAC,CAAC,GAAG,EAAE,SAAS,IAAI,CAAC,CAAC,EAAE,CAAC,CAAC,GACpC;QAAE,IAAI,EAAE,OAAO,KAAK,EAAE,QAAQ,CAAC,sBAAsB,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAA;KAAE,GAC9D;QAAE,IAAI,EAAE,OAAO,KAAK,EAAE,QAAQ,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;QAAC,QAAQ,EAAE,IAAI,CAAA;KAAE;CACzD,CAAC"}
@@ -1,7 +0,0 @@
1
- import o from "./SearchModal.vue2.js";
2
- /* empty css */
3
- import r from "../../_virtual/_plugin-vue_export-helper.js";
4
- const e = /* @__PURE__ */ r(o, [["__scopeId", "data-v-85de57c6"]]);
5
- export {
6
- e as default
7
- };
@@ -1,142 +0,0 @@
1
- import { defineComponent as D, ref as i, watch as y, computed as B, openBlock as w, createBlock as E, unref as d, withCtx as r, createElementVNode as h, createVNode as R, createTextVNode as m, toDisplayString as p, createElementBlock as N, Fragment as T, renderList as W, createSlots as L, pushScopeId as U, popScopeId as H } from "vue";
2
- import { ScalarModal as K, ScalarSearchInput as P, ScalarSearchResultList as j, ScalarSearchResultItem as z } from "@scalar/components";
3
- import { useMagicKeys as G, whenever as g } from "@vueuse/core";
4
- import J from "fuse.js";
5
- import { useRouter as O } from "vue-router";
6
- import Q from "../HttpMethod/HttpMethod.vue.js";
7
- import { useWorkspace as X } from "../../store/store.js";
8
- const Y = (u) => (U("data-v-85de57c6"), u = u(), H(), u), Z = /* @__PURE__ */ Y(() => /* @__PURE__ */ h("div", { class: "ref-search-meta" }, [
9
- /* @__PURE__ */ h("span", null, "↑↓ Navigate"),
10
- /* @__PURE__ */ h("span", null, "⏎ Select")
11
- ], -1)), se = /* @__PURE__ */ D({
12
- __name: "SearchModal",
13
- props: {
14
- modalState: {}
15
- },
16
- setup(u) {
17
- const c = u, F = O(), { activeWorkspaceRequests: I, requests: V } = X(), v = G(), l = i([]), f = i([]), o = i(0), s = i(""), _ = i(null), S = new J(l.value, {
18
- keys: ["title", "description", "body"]
19
- }), $ = () => {
20
- s.value = "", o.value = 0, f.value = [];
21
- }, b = (e) => {
22
- l.value = e.map((a) => ({
23
- id: a.uid,
24
- title: a.summary ?? a.method,
25
- description: a.description ?? "",
26
- httpVerb: a.method,
27
- path: a.path
28
- })), S.setCollection(l.value);
29
- }, x = () => {
30
- o.value = 0, f.value = S.search(s.value);
31
- };
32
- y(
33
- () => c.modalState.open,
34
- (e) => {
35
- var a;
36
- if (!e) {
37
- l.value.length > 0 && (l.value = [], S.setCollection(l.value));
38
- return;
39
- }
40
- (a = _.value) == null || a.focus(), $(), b(
41
- I.value.map((t) => V[t])
42
- );
43
- }
44
- ), y(
45
- I,
46
- (e) => {
47
- b(e.map((a) => V[a]));
48
- },
49
- { immediate: !0 }
50
- );
51
- function C(e) {
52
- F.push(e.item.id), c.modalState.hide();
53
- }
54
- const k = B(
55
- () => n.value[o.value]
56
- ), n = B(
57
- () => s.value.length === 0 ? l.value.map((e) => ({
58
- item: e
59
- })) : f.value
60
- );
61
- return g(v.enter, () => {
62
- c.modalState.open && window && C(k.value);
63
- }), g(v.ArrowDown, () => {
64
- var e;
65
- c.modalState.open && window && (o.value < n.value.length - 1 ? o.value++ : o.value = 0, (e = document.getElementById(`search-modal-${k.value.item.id}`)) == null || e.scrollIntoView({
66
- behavior: "smooth",
67
- block: "center"
68
- }));
69
- }), g(v.ArrowUp, () => {
70
- var e;
71
- c.modalState.open && window && (o.value > 0 ? o.value-- : o.value = n.value.length - 1, (e = document.getElementById(`search-modal-${k.value.item.id}`)) == null || e.scrollIntoView({
72
- behavior: "smooth",
73
- block: "center"
74
- }));
75
- }), (e, a) => (w(), E(d(K), {
76
- state: e.modalState,
77
- variant: "search"
78
- }, {
79
- default: r(() => [
80
- h("div", {
81
- ref_key: "searchModalRef",
82
- ref: _,
83
- class: "ref-search-container"
84
- }, [
85
- R(d(P), {
86
- modelValue: s.value,
87
- "onUpdate:modelValue": a[0] || (a[0] = (t) => s.value = t),
88
- onInput: x
89
- }, null, 8, ["modelValue"])
90
- ], 512),
91
- R(d(j), {
92
- class: "ref-search-results custom-scroll",
93
- noResults: !n.value.length
94
- }, {
95
- query: r(() => [
96
- m(p(s.value), 1)
97
- ]),
98
- default: r(() => [
99
- (w(!0), N(T, null, W(n.value, (t, M) => (w(), E(d(z), {
100
- id: `#search-modal-${t.item.id}`,
101
- key: t.refIndex,
102
- active: o.value === M,
103
- icon: "Terminal",
104
- onClick: (A) => C(t),
105
- onFocus: (A) => o.value = M
106
- }, L({
107
- addon: r(() => [
108
- R(d(Q), {
109
- method: t.item.httpVerb ?? "get"
110
- }, null, 8, ["method"])
111
- ]),
112
- default: r(() => [
113
- m(p(t.item.title) + " ", 1)
114
- ]),
115
- _: 2
116
- }, [
117
- (t.item.httpVerb || t.item.path) && t.item.path !== t.item.title ? {
118
- name: "description",
119
- fn: r(() => [
120
- m(p(t.item.path), 1)
121
- ]),
122
- key: "0"
123
- } : t.item.description ? {
124
- name: "description",
125
- fn: r(() => [
126
- m(p(t.item.description), 1)
127
- ]),
128
- key: "1"
129
- } : void 0
130
- ]), 1032, ["id", "active", "onClick", "onFocus"]))), 128))
131
- ]),
132
- _: 1
133
- }, 8, ["noResults"]),
134
- Z
135
- ]),
136
- _: 1
137
- }, 8, ["state"]));
138
- }
139
- });
140
- export {
141
- se as default
142
- };
@@ -1,3 +0,0 @@
1
- import SearchModal from './SearchModal.vue.js';
2
- export { SearchModal };
3
- //# sourceMappingURL=index.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/Search/index.ts"],"names":[],"mappings":"AAAA,OAAO,WAAW,MAAM,mBAAmB,CAAA;AAE3C,OAAO,EAAE,WAAW,EAAE,CAAA"}
@@ -1,4 +0,0 @@
1
- import { default as o } from "./SearchModal.vue.js";
2
- export {
3
- o as SearchModal
4
- };
@@ -1,31 +0,0 @@
1
- import { defineComponent as i, openBlock as a, createElementBlock as s, toDisplayString as n, createBlock as p, unref as l } from "vue";
2
- import { ScalarIcon as m } from "@scalar/components";
3
- const k = {
4
- "aria-label": "Workspace Menu",
5
- class: "workspace-avatar shine-effect",
6
- type: "button"
7
- }, f = ["src"], u = { key: 1 }, U = /* @__PURE__ */ i({
8
- __name: "WorkspaceProfileIcon",
9
- props: {
10
- activeUser: {}
11
- },
12
- setup(_) {
13
- return (e, d) => {
14
- var r, o, t, c;
15
- return a(), s("button", k, [
16
- (r = e.activeUser) != null && r.imageUri ? (a(), s("img", {
17
- key: 0,
18
- class: "workspace-avatar-image",
19
- src: e.activeUser.imageUri
20
- }, null, 8, f)) : (o = e.activeUser) != null && o.displayName && ((t = e.activeUser) != null && t.displayName[0]) ? (a(), s("span", u, n((c = e.activeUser) == null ? void 0 : c.displayName[0]), 1)) : (a(), p(l(m), {
21
- key: 2,
22
- class: "text-c-1 h-6 w-6",
23
- icon: "Logo"
24
- }))
25
- ]);
26
- };
27
- }
28
- });
29
- export {
30
- U as default
31
- };
@@ -1,5 +0,0 @@
1
- import o from "./WorkspaceProfileIcon.vue.js";
2
- /* empty css */
3
- export {
4
- o as default
5
- };
@@ -1,7 +0,0 @@
1
- import o from "./SubpageHeader.vue2.js";
2
- /* empty css */
3
- import e from "../_virtual/_plugin-vue_export-helper.js";
4
- const p = /* @__PURE__ */ e(o, [["__scopeId", "data-v-4f9e2869"]]);
5
- export {
6
- p as default
7
- };
@@ -1,34 +0,0 @@
1
- import { defineComponent as d, resolveComponent as a, openBlock as l, createElementBlock as i, createElementVNode as r, createVNode as t, unref as o, withCtx as p, renderSlot as u, pushScopeId as m, popScopeId as f } from "vue";
2
- import { ScalarIcon as _ } from "@scalar/components";
3
- import { useRoute as h } from "vue-router";
4
- const b = (e) => (m("data-v-4f9e2869"), e = e(), f(), e), v = { class: "flex flex-1 flex-col rounded pt-0 h-full bg-b-1 relative border-1/2 rounded mr-1.5 mb-1.5 overflow-hidden" }, x = { class: "hidden md:flex lg:min-h-header items-center w-full p-1 t-app__top-container items-center border-b-1/2" }, k = /* @__PURE__ */ b(() => /* @__PURE__ */ r("span", { class: "leading-none" }, "Back To Requests", -1)), I = /* @__PURE__ */ d({
5
- __name: "SubpageHeader",
6
- setup(e) {
7
- const n = h();
8
- return (s, g) => {
9
- const c = a("router-link");
10
- return l(), i("div", v, [
11
- r("div", x, [
12
- t(c, {
13
- class: "text-c-2 text-sm font-medium ml-1 flex items-center p-1.5 hover:bg-b-2 rounded cursor-pointer gap-0.5 active:text-c-1 no-underline dark:hover:bg-b-2",
14
- to: `/workspace/${o(n).params.workspace}/request/default`
15
- }, {
16
- default: p(() => [
17
- t(o(_), {
18
- icon: "ChevronLeft",
19
- size: "md",
20
- thickness: "1.75"
21
- }),
22
- k
23
- ]),
24
- _: 1
25
- }, 8, ["to"])
26
- ]),
27
- u(s.$slots, "default", {}, void 0, !0)
28
- ]);
29
- };
30
- }
31
- });
32
- export {
33
- I as default
34
- };