@scalar/api-client 2.1.51 → 2.2.0

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 (201) hide show
  1. package/CHANGELOG.md +47 -0
  2. package/dist/components/AddressBar/AddressBar.vue.d.ts.map +1 -1
  3. package/dist/components/AddressBar/AddressBar.vue.js +1 -1
  4. package/dist/components/AddressBar/AddressBar.vue2.js +35 -42
  5. package/dist/components/AddressBar/AddressBarHistory.vue.d.ts.map +1 -1
  6. package/dist/components/AddressBar/AddressBarHistory.vue.js +2 -2
  7. package/dist/components/AddressBar/AddressBarHistory.vue2.js +25 -24
  8. package/dist/components/AddressBar/AddressBarServer.vue.d.ts.map +1 -1
  9. package/dist/components/AddressBar/AddressBarServer.vue.js +32 -39
  10. package/dist/components/AddressBar/AddressBarServerItem.vue.d.ts.map +1 -1
  11. package/dist/components/AddressBar/AddressBarServerItem.vue.js +10 -15
  12. package/dist/components/CodeInput/CodeInput.vue.d.ts.map +1 -1
  13. package/dist/components/CodeInput/CodeInput.vue.js +1 -1
  14. package/dist/components/CodeInput/CodeInput.vue2.js +48 -47
  15. package/dist/components/CodeInput/codeVariableWidget.d.ts +3 -2
  16. package/dist/components/CodeInput/codeVariableWidget.d.ts.map +1 -1
  17. package/dist/components/CommandPalette/CommandPaletteCollection.vue.d.ts.map +1 -1
  18. package/dist/components/CommandPalette/CommandPaletteCollection.vue.js +16 -15
  19. package/dist/components/CommandPalette/CommandPaletteExample.vue.d.ts.map +1 -1
  20. package/dist/components/CommandPalette/CommandPaletteExample.vue.js +18 -23
  21. package/dist/components/CommandPalette/CommandPaletteImport.vue.d.ts.map +1 -1
  22. package/dist/components/CommandPalette/CommandPaletteImport.vue.js +27 -26
  23. package/dist/components/CommandPalette/CommandPaletteRequest.vue.d.ts.map +1 -1
  24. package/dist/components/CommandPalette/CommandPaletteRequest.vue.js +19 -20
  25. package/dist/components/CommandPalette/CommandPaletteServer.vue.d.ts.map +1 -1
  26. package/dist/components/CommandPalette/CommandPaletteServer.vue.js +19 -24
  27. package/dist/components/CommandPalette/CommandPaletteTag.vue.d.ts.map +1 -1
  28. package/dist/components/CommandPalette/CommandPaletteTag.vue.js +23 -22
  29. package/dist/components/CommandPalette/TheCommandPalette.vue.d.ts.map +1 -1
  30. package/dist/components/CommandPalette/TheCommandPalette.vue.js +4 -4
  31. package/dist/components/CommandPalette/TheCommandPalette.vue2.js +47 -46
  32. package/dist/components/DataTable/DataTableInput.vue.d.ts +1 -1
  33. package/dist/components/DataTable/DataTableInput.vue.d.ts.map +1 -1
  34. package/dist/components/EnvironmentSelector/EnvironmentSelector.vue.d.ts.map +1 -1
  35. package/dist/components/EnvironmentSelector/EnvironmentSelector.vue.js +23 -28
  36. package/dist/components/HttpMethod/HttpMethod.vue.d.ts +2 -2
  37. package/dist/components/IconSelector.vue.js +2 -2
  38. package/dist/components/ImportCollection/ImportCollectionModal.vue.d.ts.map +1 -1
  39. package/dist/components/ImportCollection/ImportCollectionModal.vue.js +127 -96
  40. package/dist/components/ImportCollection/ImportNowButton.vue.d.ts.map +1 -1
  41. package/dist/components/ImportCollection/ImportNowButton.vue.js +28 -27
  42. package/dist/components/ImportCollection/IntegrationLogo.vue.d.ts +1 -1
  43. package/dist/components/ImportCollection/IntegrationLogo.vue.d.ts.map +1 -1
  44. package/dist/components/ImportCollection/IntegrationLogo.vue.js +14 -18
  45. package/dist/components/ImportCollection/WorkspaceSelector.vue.d.ts.map +1 -1
  46. package/dist/components/ImportCollection/WorkspaceSelector.vue.js +15 -14
  47. package/dist/components/Search/useSearch.d.ts.map +1 -1
  48. package/dist/components/Search/useSearch.js +20 -19
  49. package/dist/components/SideNav/SideNavRouterLink.vue.js +9 -9
  50. package/dist/components/Sidebar/Sidebar.vue.d.ts.map +1 -1
  51. package/dist/components/Sidebar/Sidebar.vue.js +2 -2
  52. package/dist/components/Sidebar/Sidebar.vue2.js +37 -39
  53. package/dist/components/TopNav/TopNav.vue.d.ts.map +1 -1
  54. package/dist/components/TopNav/TopNav.vue.js +1 -1
  55. package/dist/components/TopNav/TopNav.vue2.js +20 -19
  56. package/dist/components/TopNav/TopNavItem.vue.d.ts +2 -2
  57. package/dist/hooks/index.js +3 -2
  58. package/dist/hooks/useLayout.d.ts +2 -0
  59. package/dist/hooks/useLayout.d.ts.map +1 -1
  60. package/dist/hooks/useLayout.js +4 -3
  61. package/dist/layouts/App/ApiClientApp.vue.d.ts.map +1 -1
  62. package/dist/layouts/App/ApiClientApp.vue.js +38 -37
  63. package/dist/layouts/App/MainLayout.vue.d.ts.map +1 -1
  64. package/dist/layouts/App/MainLayout.vue.js +3 -3
  65. package/dist/layouts/App/create-api-client-app.d.ts +670 -1232
  66. package/dist/layouts/App/create-api-client-app.d.ts.map +1 -1
  67. package/dist/layouts/Modal/ApiClientModal.vue.d.ts.map +1 -1
  68. package/dist/layouts/Modal/ApiClientModal.vue.js +2 -2
  69. package/dist/layouts/Modal/ApiClientModal.vue2.js +24 -23
  70. package/dist/layouts/Modal/create-api-client-modal.d.ts +1384 -2508
  71. package/dist/layouts/Modal/create-api-client-modal.d.ts.map +1 -1
  72. package/dist/layouts/Web/ApiClientWeb.vue.d.ts.map +1 -1
  73. package/dist/layouts/Web/ApiClientWeb.vue.js +34 -33
  74. package/dist/layouts/Web/create-api-client-web.d.ts +670 -1232
  75. package/dist/layouts/Web/create-api-client-web.d.ts.map +1 -1
  76. package/dist/libs/create-client.d.ts +675 -1236
  77. package/dist/libs/create-client.d.ts.map +1 -1
  78. package/dist/libs/create-client.js +100 -95
  79. package/dist/libs/hot-keys.d.ts +1 -1
  80. package/dist/libs/send-request.d.ts +3 -7
  81. package/dist/libs/send-request.d.ts.map +1 -1
  82. package/dist/libs/send-request.js +126 -119
  83. package/dist/libs/string-template.d.ts.map +1 -1
  84. package/dist/libs/string-template.js +23 -22
  85. package/dist/store/active-entities.d.ts +333 -0
  86. package/dist/store/active-entities.d.ts.map +1 -0
  87. package/dist/store/active-entities.js +97 -0
  88. package/dist/store/collections.d.ts +4 -274
  89. package/dist/store/collections.d.ts.map +1 -1
  90. package/dist/store/cookies.d.ts +4 -4
  91. package/dist/store/environment.d.ts +4 -4
  92. package/dist/store/import-spec.d.ts +0 -54
  93. package/dist/store/import-spec.d.ts.map +1 -1
  94. package/dist/store/index.js +4 -3
  95. package/dist/store/request-example.d.ts +4 -4
  96. package/dist/store/requests.d.ts +15 -15
  97. package/dist/store/security-schemes.d.ts +527 -317
  98. package/dist/store/security-schemes.d.ts.map +1 -1
  99. package/dist/store/security-schemes.js +33 -41
  100. package/dist/store/servers.d.ts +4 -4
  101. package/dist/store/store-context.d.ts +0 -3
  102. package/dist/store/store-context.d.ts.map +1 -1
  103. package/dist/store/store.d.ts +640 -5297
  104. package/dist/store/store.d.ts.map +1 -1
  105. package/dist/store/store.js +111 -189
  106. package/dist/store/tags.d.ts +4 -4
  107. package/dist/store/workspace.d.ts +14 -24
  108. package/dist/store/workspace.d.ts.map +1 -1
  109. package/dist/style.css +1 -1
  110. package/dist/views/Cookies/CookieForm.vue.d.ts.map +1 -1
  111. package/dist/views/Cookies/CookieForm.vue.js +14 -13
  112. package/dist/views/Cookies/CookieRaw.vue.d.ts.map +1 -1
  113. package/dist/views/Cookies/CookieRaw.vue.js +14 -13
  114. package/dist/views/Environment/EnvironmentVariableDropdown.vue.d.ts +3 -3
  115. package/dist/views/Environment/EnvironmentVariableDropdown.vue.d.ts.map +1 -1
  116. package/dist/views/Request/Request.vue.d.ts.map +1 -1
  117. package/dist/views/Request/Request.vue.js +2 -2
  118. package/dist/views/Request/Request.vue2.js +94 -94
  119. package/dist/views/Request/RequestSection/RequestAuth/OAuth2.vue.d.ts +2 -2
  120. package/dist/views/Request/RequestSection/RequestAuth/OAuth2.vue.d.ts.map +1 -1
  121. package/dist/views/Request/RequestSection/RequestAuth/OAuth2.vue.js +96 -99
  122. package/dist/views/Request/RequestSection/RequestAuth/OAuthScopesInput.vue.d.ts +2 -2
  123. package/dist/views/Request/RequestSection/RequestAuth/OAuthScopesInput.vue.d.ts.map +1 -1
  124. package/dist/views/Request/RequestSection/RequestAuth/OAuthScopesInput.vue.js +49 -46
  125. package/dist/views/Request/RequestSection/RequestAuth/RequestAuth.vue.d.ts.map +1 -1
  126. package/dist/views/Request/RequestSection/RequestAuth/RequestAuth.vue.js +2 -2
  127. package/dist/views/Request/RequestSection/RequestAuth/RequestAuth.vue2.js +94 -100
  128. package/dist/views/Request/RequestSection/RequestAuth/RequestExampleAuth.vue.d.ts.map +1 -1
  129. package/dist/views/Request/RequestSection/RequestAuth/RequestExampleAuth.vue.js +60 -67
  130. package/dist/views/Request/RequestSection/RequestAuthDataTableInput.vue.d.ts +1 -1
  131. package/dist/views/Request/RequestSection/RequestAuthDataTableInput.vue.d.ts.map +1 -1
  132. package/dist/views/Request/RequestSection/RequestBody.vue.d.ts.map +1 -1
  133. package/dist/views/Request/RequestSection/RequestBody.vue.js +2 -2
  134. package/dist/views/Request/RequestSection/RequestBody.vue2.js +29 -28
  135. package/dist/views/Request/RequestSection/RequestParams.vue.d.ts.map +1 -1
  136. package/dist/views/Request/RequestSection/RequestParams.vue.js +11 -10
  137. package/dist/views/Request/RequestSection/RequestPathParams.vue.d.ts.map +1 -1
  138. package/dist/views/Request/RequestSection/RequestPathParams.vue.js +24 -28
  139. package/dist/views/Request/RequestSection/RequestSection.vue.d.ts.map +1 -1
  140. package/dist/views/Request/RequestSection/RequestSection.vue.js +2 -2
  141. package/dist/views/Request/RequestSection/RequestSection.vue2.js +19 -18
  142. package/dist/views/Request/RequestSection/RequestTable.vue.d.ts +2 -2
  143. package/dist/views/Request/RequestSection/RequestTableTooltip.vue.d.ts.map +1 -1
  144. package/dist/views/Request/RequestSection/RequestTableTooltip.vue.js +27 -27
  145. package/dist/views/Request/RequestSidebar.vue.d.ts.map +1 -1
  146. package/dist/views/Request/RequestSidebar.vue.js +1 -1
  147. package/dist/views/Request/RequestSidebar.vue2.js +74 -75
  148. package/dist/views/Request/RequestSidebarItem.vue.d.ts.map +1 -1
  149. package/dist/views/Request/RequestSidebarItem.vue.js +1 -1
  150. package/dist/views/Request/RequestSidebarItem.vue2.js +111 -109
  151. package/dist/views/Request/RequestSidebarItemMenu.vue.d.ts.map +1 -1
  152. package/dist/views/Request/RequestSidebarItemMenu.vue.js +2 -2
  153. package/dist/views/Request/RequestSidebarItemMenu.vue2.js +15 -16
  154. package/dist/views/Request/RequestSubpageHeader.vue.js +1 -1
  155. package/dist/views/Request/RequestSubpageHeader.vue2.js +14 -14
  156. package/dist/views/Request/ResponseSection/ResponseBodyRaw.vue.d.ts.map +1 -1
  157. package/dist/views/Request/ResponseSection/ResponseBodyRaw.vue.js +2 -2
  158. package/dist/views/Request/ResponseSection/ResponseBodyRaw.vue2.js +35 -15
  159. package/dist/views/Request/ResponseSection/ResponseEmpty.vue.d.ts.map +1 -1
  160. package/dist/views/Request/ResponseSection/ResponseEmpty.vue.js +1 -1
  161. package/dist/views/Request/ResponseSection/ResponseEmpty.vue2.js +23 -22
  162. package/dist/views/Request/components/WorkspaceDropdown.vue.d.ts.map +1 -1
  163. package/dist/views/Request/components/WorkspaceDropdown.vue.js +32 -31
  164. package/dist/views/Request/consts/new-auth-options.d.ts +16 -8
  165. package/dist/views/Request/consts/new-auth-options.d.ts.map +1 -1
  166. package/dist/views/Request/consts/new-auth-options.js +16 -8
  167. package/dist/views/Request/handle-drag.d.ts +2 -1
  168. package/dist/views/Request/handle-drag.d.ts.map +1 -1
  169. package/dist/views/Request/handle-drag.js +23 -25
  170. package/dist/views/Request/hooks/useOpenApiWatcher.d.ts.map +1 -1
  171. package/dist/views/Request/hooks/useOpenApiWatcher.js +40 -39
  172. package/dist/views/Request/libs/auth.d.ts +1 -29
  173. package/dist/views/Request/libs/auth.d.ts.map +1 -1
  174. package/dist/views/Request/libs/auth.js +2 -9
  175. package/dist/views/Request/libs/index.js +6 -8
  176. package/dist/views/Request/libs/live-sync.d.ts +6 -5
  177. package/dist/views/Request/libs/live-sync.d.ts.map +1 -1
  178. package/dist/views/Request/libs/live-sync.js +164 -185
  179. package/dist/views/Request/libs/oauth2.d.ts +6 -10
  180. package/dist/views/Request/libs/oauth2.d.ts.map +1 -1
  181. package/dist/views/Request/libs/oauth2.js +54 -69
  182. package/dist/views/Servers/ServerForm.vue.d.ts.map +1 -1
  183. package/dist/views/Servers/ServerForm.vue.js +14 -13
  184. package/dist/views/Servers/Servers.vue.d.ts.map +1 -1
  185. package/dist/views/Servers/Servers.vue2.js +18 -17
  186. package/dist/views/Settings/SettingsGeneral.vue.d.ts.map +1 -1
  187. package/dist/views/Settings/SettingsGeneral.vue.js +218 -126
  188. package/dist/views/Settings/{SettingsGeneralMode.vue.d.ts → components/SettingsAppearance.vue.d.ts} +2 -2
  189. package/dist/views/Settings/components/SettingsAppearance.vue.d.ts.map +1 -0
  190. package/dist/views/Settings/components/SettingsAppearance.vue.js +74 -0
  191. package/dist/views/Settings/components/SettingsAppearance.vue2.js +4 -0
  192. package/dist/views/Settings/components/SettingsSection.vue.d.ts +24 -0
  193. package/dist/views/Settings/components/SettingsSection.vue.d.ts.map +1 -0
  194. package/dist/views/Settings/components/SettingsSection.vue.js +24 -0
  195. package/dist/views/Settings/components/SettingsSection.vue2.js +4 -0
  196. package/package.json +12 -12
  197. package/dist/views/Request/RequestSection/RequestAuth/RequestAuthModal.vue.d.ts +0 -16
  198. package/dist/views/Request/RequestSection/RequestAuth/RequestAuthModal.vue.d.ts.map +0 -1
  199. package/dist/views/Settings/SettingsGeneralMode.vue.d.ts.map +0 -1
  200. package/dist/views/Settings/SettingsGeneralMode.vue.js +0 -78
  201. package/dist/views/Settings/SettingsGeneralMode.vue2.js +0 -4
@@ -1,66 +1,67 @@
1
- import { specDictionary as u } from "../../../store/import-spec.js";
2
- import { combineRenameDiffs as A, mutateCollectionDiff as R, mutateSecuritySchemeDiff as S, mutateServerDiff as d, mutateTagDiff as g, mutateRequestDiff as D } from "../libs/live-sync.js";
3
- import { fetchSpecFromUrl as E, createHash as T } from "@scalar/oas-utils/helpers";
4
- import { parseSchema as l } from "@scalar/oas-utils/transforms";
5
- import { useToasts as M } from "@scalar/use-toasts";
6
- import { useTimeoutPoll as I } from "@vueuse/core";
7
- import U from "microdiff";
8
- import { watch as C } from "vue";
9
- import { useWorkspace as L } from "../../../store/store.js";
10
- const N = 5 * 1e3, b = 60 * 1e3, V = () => {
11
- const { toast: f } = M(), c = L(), { activeCollection: t, activeWorkspace: v, collectionMutators: i } = c, o = (e) => f(
1
+ import { useActiveEntities as E } from "../../../store/active-entities.js";
2
+ import { specDictionary as f } from "../../../store/import-spec.js";
3
+ import { combineRenameDiffs as R, mutateCollectionDiff as S, mutateSecuritySchemeDiff as d, mutateServerDiff as g, mutateTagDiff as D, mutateRequestDiff as T } from "../libs/live-sync.js";
4
+ import { fetchSpecFromUrl as M, createHash as I } from "@scalar/oas-utils/helpers";
5
+ import { parseSchema as v } from "@scalar/oas-utils/transforms";
6
+ import { useToasts as U } from "@scalar/use-toasts";
7
+ import { useTimeoutPoll as C } from "@vueuse/core";
8
+ import L from "microdiff";
9
+ import { watch as N } from "vue";
10
+ import { useWorkspace as b } from "../../../store/store.js";
11
+ const P = 5 * 1e3, k = 60 * 1e3, B = () => {
12
+ const { toast: h } = U(), c = E(), o = b(), { activeCollection: t, activeWorkspace: O } = c, { collectionMutators: n } = o, r = (e) => h(
12
13
  `[useOpenApiWatcher] Changes to the ${e} were not applied`,
13
14
  "error"
14
- ), O = (e) => {
15
- e.path[0] === "info" || e.path[0] === "security" ? R(e, c) || o("collection") : e.path[0] === "components" && e.path[1] === "securitySchemes" ? S(e, c) || o("securitySchemes") : e.path[0] === "servers" ? d(e, c) || o("servers") : e.path[0] === "tags" ? g(e, c) || o("tags") : e.path[0] === "paths" && (D(e, c) || o("requests"));
16
- }, { pause: h, resume: p } = I(async () => {
17
- var m;
18
- const e = (m = t.value) == null ? void 0 : m.documentUrl;
15
+ ), W = (e) => {
16
+ e.path[0] === "info" || e.path[0] === "security" ? S(e, c, o) || r("collection") : e.path[0] === "components" && e.path[1] === "securitySchemes" ? d(e, c, o) || r("securitySchemes") : e.path[0] === "servers" ? g(e, c, o) || r("servers") : e.path[0] === "tags" ? D(e, c, o) || r("tags") : e.path[0] === "paths" && (T(e, c, o) || r("requests"));
17
+ }, { pause: p, resume: m } = C(async () => {
18
+ var l;
19
+ const e = (l = t.value) == null ? void 0 : l.documentUrl;
19
20
  if (!e) return;
20
- const s = u[e];
21
+ const s = f[e];
21
22
  try {
22
- const r = await E(
23
+ const a = await M(
23
24
  e,
24
- v.value.proxyUrl,
25
+ O.value.proxyUrl,
25
26
  !1
26
- ), n = T(r);
27
- if (i.edit(
27
+ ), u = I(a);
28
+ if (n.edit(
28
29
  t.value.uid,
29
30
  "watchModeStatus",
30
31
  "WATCHING"
31
32
  ), s != null && s.hash)
32
- if (s.hash && s.hash !== n) {
33
- const { schema: a } = await l(r), W = U(s.schema, a), w = A(W);
33
+ if (s.hash && s.hash !== u) {
34
+ const { schema: i } = await v(a), w = L(s.schema, i), A = R(w);
34
35
  try {
35
- w.forEach(O), u[e] = {
36
- hash: n,
37
- schema: a
36
+ A.forEach(W), f[e] = {
37
+ hash: u,
38
+ schema: i
38
39
  };
39
40
  } catch (y) {
40
41
  console.error("[useOpenApiWatcher] Error:", y);
41
42
  }
42
43
  } else console.log("[useOpenApiWatcher] No changes detected yet…");
43
44
  else {
44
- const { schema: a } = await l(r);
45
- a && (u[e] = {
46
- hash: n,
47
- schema: a
45
+ const { schema: i } = await v(a);
46
+ i && (f[e] = {
47
+ hash: u,
48
+ schema: i
48
49
  });
49
50
  }
50
- } catch (r) {
51
- console.error("[useOpenApiWatcher] Error:", r), console.info("[useOpenApiWatcher] Pausing watcher for 60 seconds"), h(), i.edit(
51
+ } catch (a) {
52
+ console.error("[useOpenApiWatcher] Error:", a), console.info("[useOpenApiWatcher] Pausing watcher for 60 seconds"), p(), n.edit(
52
53
  t.value.uid,
53
54
  "watchModeStatus",
54
55
  "ERROR"
55
- ), f(
56
+ ), h(
56
57
  "[useOpenApiWatcher] Unable to fetch the spec file, paused the watcher for 60 seconds",
57
58
  "error"
58
59
  ), setTimeout(() => {
59
- console.info("[useOpenApiWatcher] Resuming watcher"), p();
60
- }, b);
60
+ console.info("[useOpenApiWatcher] Resuming watcher"), m();
61
+ }, k);
61
62
  }
62
- }, N);
63
- C(
63
+ }, P);
64
+ N(
64
65
  [
65
66
  () => {
66
67
  var e;
@@ -72,7 +73,7 @@ const N = 5 * 1e3, b = 60 * 1e3, V = () => {
72
73
  }
73
74
  ],
74
75
  ([e, s]) => {
75
- e && s ? (console.info(`[useOpenApiWatcher] Watching ${e} …`), p()) : t.value && (h(), i.edit(
76
+ e && s ? (console.info(`[useOpenApiWatcher] Watching ${e} …`), m()) : t.value && (p(), n.edit(
76
77
  t.value.uid,
77
78
  "watchModeStatus",
78
79
  "IDLE"
@@ -82,5 +83,5 @@ const N = 5 * 1e3, b = 60 * 1e3, V = () => {
82
83
  );
83
84
  };
84
85
  export {
85
- V as useOpenApiWatcher
86
+ B as useOpenApiWatcher
86
87
  };
@@ -1,32 +1,4 @@
1
- import { type SecurityScheme } from '@scalar/oas-utils/entities/spec';
2
- /** Create a new value set for a given scheme type */
3
- export declare const createSchemeValueSet: (scheme: SecurityScheme) => {
4
- type: "apiKey";
5
- value: string;
6
- name: string;
7
- } | {
8
- type: "http";
9
- username: string;
10
- password: string;
11
- token: string;
12
- } | {
13
- type: "oauth-implicit";
14
- token: string;
15
- } | {
16
- type: "oauth-password";
17
- username: string;
18
- password: string;
19
- token: string;
20
- clientSecret: string;
21
- } | {
22
- type: "oauth-clientCredentials";
23
- token: string;
24
- clientSecret: string;
25
- } | {
26
- type: "oauth-authorizationCode";
27
- token: string;
28
- clientSecret: string;
29
- };
1
+ import type { SecurityScheme } from '@scalar/oas-utils/entities/spec';
30
2
  /** Format a scheme object into a display object */
31
3
  export declare const displaySchemeFormatter: (s: SecurityScheme) => {
32
4
  id: string;
@@ -1 +1 @@
1
- {"version":3,"file":"auth.d.ts","sourceRoot":"","sources":["../../../../src/views/Request/libs/auth.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,cAAc,EAEpB,MAAM,iCAAiC,CAAA;AAExC,qDAAqD;AACrD,eAAO,MAAM,oBAAoB,WAAY,cAAc;;;;;;;;;;;;;;;;;;;;;;;;;;CAQ1D,CAAA;AAED,mDAAmD;AACnD,eAAO,MAAM,sBAAsB,MAAO,cAAc;;;CAKvD,CAAA"}
1
+ {"version":3,"file":"auth.d.ts","sourceRoot":"","sources":["../../../../src/views/Request/libs/auth.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,iCAAiC,CAAA;AAErE,mDAAmD;AACnD,eAAO,MAAM,sBAAsB,MAAO,cAAc;;;CAKvD,CAAA"}
@@ -1,14 +1,7 @@
1
- import { securitySchemeExampleValueSchema as a } from "@scalar/oas-utils/entities/spec";
2
- const o = (e) => {
3
- const t = e.type === "oauth2" ? `oauth-${e.flow.type}` : e.type;
4
- return a.parse({
5
- type: t
6
- });
7
- }, p = (e) => ({
1
+ const r = (e) => ({
8
2
  id: e.uid,
9
3
  label: e.nameKey
10
4
  });
11
5
  export {
12
- o as createSchemeValueSet,
13
- p as displaySchemeFormatter
6
+ r as displaySchemeFormatter
14
7
  };
@@ -1,10 +1,8 @@
1
- import { createSchemeValueSet as a, displaySchemeFormatter as t } from "./auth.js";
2
- import { authorizeOauth2 as h, authorizeServers as m, generateCodeChallenge as l, isOauth2Example as u } from "./oauth2.js";
1
+ import { displaySchemeFormatter as o } from "./auth.js";
2
+ import { authorizeOauth2 as a, authorizeServers as h, generateCodeChallenge as m } from "./oauth2.js";
3
3
  export {
4
- h as authorizeOauth2,
5
- m as authorizeServers,
6
- a as createSchemeValueSet,
7
- t as displaySchemeFormatter,
8
- l as generateCodeChallenge,
9
- u as isOauth2Example
4
+ a as authorizeOauth2,
5
+ h as authorizeServers,
6
+ o as displaySchemeFormatter,
7
+ m as generateCodeChallenge
10
8
  };
@@ -1,4 +1,5 @@
1
1
  import type { WorkspaceStore } from '../../../store/index.js';
2
+ import type { ActiveEntitiesStore } from '../../../store/active-entities.js';
2
3
  import { type Path, type PathValue } from '@scalar/object-utils/nested';
3
4
  import { type Difference } from 'microdiff';
4
5
  import { type ZodSchema, type ZodTypeDef } from 'zod';
@@ -37,15 +38,15 @@ export declare const parseDiff: <T>(schema: ZodSchema<T, ZodTypeDef, any>, diff:
37
38
  *
38
39
  * @returns true if it succeeds, and false for a failure
39
40
  */
40
- export declare const mutateCollectionDiff: (diff: Difference, { activeCollection, collectionMutators }: WorkspaceStore) => boolean;
41
+ export declare const mutateCollectionDiff: (diff: Difference, { activeCollection }: ActiveEntitiesStore, { collectionMutators }: WorkspaceStore) => boolean;
41
42
  /**
42
43
  * Generates an array of payloads for the request mutator from the request diff, also executes the mutation
43
44
  */
44
- export declare const mutateRequestDiff: (diff: Difference, store: WorkspaceStore) => boolean;
45
+ export declare const mutateRequestDiff: (diff: Difference, { activeCollection }: ActiveEntitiesStore, store: WorkspaceStore) => boolean;
45
46
  /** Generates a payload for the server mutator from the server diff including the mutator method */
46
- export declare const mutateServerDiff: (diff: Difference, { activeCollection, servers, serverMutators }: WorkspaceStore) => boolean;
47
+ export declare const mutateServerDiff: (diff: Difference, { activeCollection }: ActiveEntitiesStore, { servers, serverMutators }: WorkspaceStore) => boolean;
47
48
  /** Generates a payload for the tag mutator from the tag diff */
48
- export declare const mutateTagDiff: (diff: Difference, { activeCollection, tags, tagMutators }: WorkspaceStore) => boolean;
49
+ export declare const mutateTagDiff: (diff: Difference, { activeCollection }: ActiveEntitiesStore, { tags, tagMutators }: WorkspaceStore) => boolean;
49
50
  /** Narrows down a zod union schema */
50
51
  export declare const narrowUnionSchema: (schema: ZodSchema, key: string, value: string) => ZodSchema | null;
51
52
  /**
@@ -55,5 +56,5 @@ export declare const narrowUnionSchema: (schema: ZodSchema, key: string, value:
55
56
  *
56
57
  * @returns true if it succeeds, and false for a failure
57
58
  */
58
- export declare const mutateSecuritySchemeDiff: (diff: Difference, { activeCollection, securitySchemes, securitySchemeMutators }: WorkspaceStore) => boolean;
59
+ export declare const mutateSecuritySchemeDiff: (diff: Difference, { activeCollection }: ActiveEntitiesStore, { securitySchemes, securitySchemeMutators }: WorkspaceStore) => boolean;
59
60
  //# sourceMappingURL=live-sync.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"live-sync.d.ts","sourceRoot":"","sources":["../../../../src/views/Request/libs/live-sync.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,SAAS,CAAA;AAgB7C,OAAO,EACL,KAAK,IAAI,EACT,KAAK,SAAS,EAEf,MAAM,6BAA6B,CAAA;AAEpC,OAAkB,EAAE,KAAK,UAAU,EAAE,MAAM,WAAW,CAAA;AACtD,OAAO,EAAE,KAAK,SAAS,EAAE,KAAK,UAAU,EAAK,MAAM,KAAK,CAAA;AAExD;;;;;;;GAOG;AACH,eAAO,MAAM,kBAAkB,SACvB,UAAU,EAAE,eACN,MAAM,EAAE,KACnB,UAAU,EAqFZ,CAAA;AAED,kEAAkE;AAClE,eAAO,MAAM,YAAY,GAAI,CAAC,OACvB,MAAM,EAAE,aACF,MAAM,CAAC,MAAM,EAAE,CAAC,CAAC,aACjB,CAAC,QAAQ,EAAE,CAAC,KAAK,OAAO,KAClC,CAAC,GAAG,IAMN,CAAA;AASD;;;GAGG;AACH,eAAO,MAAM,iBAAiB,WACpB,SAAS,QACX,CAAC,MAAM,GAAG,MAAM,CAAC,EAAE,KACxB,SAAS,GAAG,IAqDd,CAAA;AAED;;;;;GAKG;AACH,eAAO,MAAM,SAAS,GAAI,CAAC,UACjB,SAAS,CAAC,CAAC,EAAE,UAAU,EAAE,GAAG,CAAC,QAC/B,UAAU,KACf;IACD,0DAA0D;IAC1D,IAAI,EAAE,IAAI,CAAC,CAAC,CAAC,CAAA;IACb,mGAAmG;IACnG,YAAY,EAAE,IAAI,CAAC,CAAC,CAAC,CAAA;IACrB,2DAA2D;IAC3D,KAAK,EAAE,SAAS,CAAC,CAAC,EAAE,IAAI,CAAC,CAAC,CAAC,CAAC,GAAG,SAAS,CAAA;CACzC,GAAG,IAwBH,CAAA;AAED;;;;GAIG;AACH,eAAO,MAAM,oBAAoB,SACzB,UAAU,4CAC0B,cAAc,KACvD,OA0CF,CAAA;AAwBD;;GAEG;AACH,eAAO,MAAM,iBAAiB,SACtB,UAAU,SACT,cAAc,KACpB,OAwIF,CAAA;AAED,mGAAmG;AACnG,eAAO,MAAM,gBAAgB,SACrB,UAAU,iDAC+B,cAAc,KAC5D,OAoCF,CAAA;AAED,gEAAgE;AAChE,eAAO,MAAM,aAAa,SAClB,UAAU,2CACyB,cAAc,KACtD,OA+BF,CAAA;AAED,sCAAsC;AACtC,eAAO,MAAM,iBAAiB,WACpB,SAAS,OACZ,MAAM,SACJ,MAAM,KACZ,SAAS,GAAG,IAmBd,CAAA;AAED;;;;;;GAMG;AACH,eAAO,MAAM,wBAAwB,SAC7B,UAAU,iEAC+C,cAAc,KAC5E,OA+EF,CAAA"}
1
+ {"version":3,"file":"live-sync.d.ts","sourceRoot":"","sources":["../../../../src/views/Request/libs/live-sync.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,SAAS,CAAA;AAC7C,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,yBAAyB,CAAA;AAelE,OAAO,EACL,KAAK,IAAI,EACT,KAAK,SAAS,EAEf,MAAM,6BAA6B,CAAA;AAEpC,OAAkB,EAAE,KAAK,UAAU,EAAE,MAAM,WAAW,CAAA;AACtD,OAAO,EAAE,KAAK,SAAS,EAAE,KAAK,UAAU,EAAK,MAAM,KAAK,CAAA;AAExD;;;;;;;GAOG;AACH,eAAO,MAAM,kBAAkB,SACvB,UAAU,EAAE,eACN,MAAM,EAAE,KACnB,UAAU,EAqFZ,CAAA;AAED,kEAAkE;AAClE,eAAO,MAAM,YAAY,GAAI,CAAC,OACvB,MAAM,EAAE,aACF,MAAM,CAAC,MAAM,EAAE,CAAC,CAAC,aACjB,CAAC,QAAQ,EAAE,CAAC,KAAK,OAAO,KAClC,CAAC,GAAG,IAMN,CAAA;AASD;;;GAGG;AACH,eAAO,MAAM,iBAAiB,WACpB,SAAS,QACX,CAAC,MAAM,GAAG,MAAM,CAAC,EAAE,KACxB,SAAS,GAAG,IAqDd,CAAA;AAED;;;;;GAKG;AACH,eAAO,MAAM,SAAS,GAAI,CAAC,UACjB,SAAS,CAAC,CAAC,EAAE,UAAU,EAAE,GAAG,CAAC,QAC/B,UAAU,KACf;IACD,0DAA0D;IAC1D,IAAI,EAAE,IAAI,CAAC,CAAC,CAAC,CAAA;IACb,mGAAmG;IACnG,YAAY,EAAE,IAAI,CAAC,CAAC,CAAC,CAAA;IACrB,2DAA2D;IAC3D,KAAK,EAAE,SAAS,CAAC,CAAC,EAAE,IAAI,CAAC,CAAC,CAAC,CAAC,GAAG,SAAS,CAAA;CACzC,GAAG,IAwBH,CAAA;AAED;;;;GAIG;AACH,eAAO,MAAM,oBAAoB,SACzB,UAAU,wBACM,mBAAmB,0BACjB,cAAc,KACrC,OA0CF,CAAA;AAwBD;;GAEG;AACH,eAAO,MAAM,iBAAiB,SACtB,UAAU,wBACM,mBAAmB,SAClC,cAAc,KACpB,OAwIF,CAAA;AAED,mGAAmG;AACnG,eAAO,MAAM,gBAAgB,SACrB,UAAU,wBACM,mBAAmB,+BACZ,cAAc,KAC1C,OAoCF,CAAA;AAED,gEAAgE;AAChE,eAAO,MAAM,aAAa,SAClB,UAAU,wBACM,mBAAmB,yBAClB,cAAc,KACpC,OA+BF,CAAA;AAED,sCAAsC;AACtC,eAAO,MAAM,iBAAiB,WACpB,SAAS,OACZ,MAAM,SACJ,MAAM,KACZ,SAAS,GAAG,IAmBd,CAAA;AAED;;;;;;GAMG;AACH,eAAO,MAAM,wBAAwB,SAC7B,UAAU,wBACM,mBAAmB,+CACI,cAAc,KAC1D,OA0CF,CAAA"}