@scalar/api-client 2.36.0 → 2.36.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.
- package/CHANGELOG.md +65 -0
- package/dist/monacoeditorwork/editor.worker.bundle.js +14463 -0
- package/dist/monacoeditorwork/json.worker.bundle.js +22211 -0
- package/dist/monacoeditorwork/yaml.worker.bundle.js +46771 -0
- package/dist/style.css +1 -1
- package/dist/v2/blocks/operation-block/helpers/build-request-body.d.ts.map +1 -1
- package/dist/v2/blocks/operation-block/helpers/build-request-body.js +28 -27
- package/dist/v2/blocks/operation-code-sample/components/ExamplePicker.vue.d.ts.map +1 -1
- package/dist/v2/blocks/operation-code-sample/components/ExamplePicker.vue.js +12 -11
- package/dist/v2/blocks/operation-code-sample/helpers/operation-to-har/process-body.d.ts.map +1 -1
- package/dist/v2/blocks/operation-code-sample/helpers/operation-to-har/process-body.js +47 -42
- package/dist/v2/blocks/request-block/helpers/get-default-headers.js +1 -1
- package/dist/v2/blocks/scalar-auth-selector-block/components/OAuth2.vue.d.ts.map +1 -1
- package/dist/v2/blocks/scalar-auth-selector-block/components/OAuth2.vue.js +65 -59
- package/dist/v2/blocks/scalar-auth-selector-block/helpers/extract-security-scheme-secrets.d.ts.map +1 -1
- package/dist/v2/blocks/scalar-auth-selector-block/helpers/extract-security-scheme-secrets.js +57 -42
- package/dist/v2/blocks/scalar-auth-selector-block/helpers/oauth.d.ts.map +1 -1
- package/dist/v2/blocks/scalar-auth-selector-block/helpers/oauth.js +44 -41
- package/dist/v2/blocks/scalar-auth-selector-block/helpers/secret-types.d.ts +2 -2
- package/dist/v2/blocks/scalar-auth-selector-block/helpers/secret-types.d.ts.map +1 -1
- package/dist/v2/components/resize/index.d.ts +1 -0
- package/dist/v2/components/resize/index.d.ts.map +1 -1
- package/dist/v2/components/resize/index.js +4 -2
- package/dist/v2/components/resize/use-split-resize.d.ts +27 -0
- package/dist/v2/components/resize/use-split-resize.d.ts.map +1 -0
- package/dist/v2/components/resize/use-split-resize.js +57 -0
- package/dist/v2/components/sidebar/Sidebar.vue.d.ts.map +1 -1
- package/dist/v2/components/sidebar/Sidebar.vue.js +38 -34
- package/dist/v2/features/app/App.vue.d.ts +5 -0
- package/dist/v2/features/app/App.vue.d.ts.map +1 -1
- package/dist/v2/features/app/App.vue.js +71 -63
- package/dist/v2/features/app/components/DesktopTabs.vue.d.ts.map +1 -1
- package/dist/v2/features/app/components/DesktopTabs.vue.js +34 -30
- package/dist/v2/features/app/helpers/create-api-client-app.d.ts +7 -1
- package/dist/v2/features/app/helpers/create-api-client-app.d.ts.map +1 -1
- package/dist/v2/features/app/helpers/create-api-client-app.js +15 -10
- package/dist/v2/features/app/helpers/routes.d.ts +6 -0
- package/dist/v2/features/app/helpers/routes.d.ts.map +1 -1
- package/dist/v2/features/app/helpers/routes.js +3 -2
- package/dist/v2/features/app/hooks/use-document-watcher.js +13 -13
- package/dist/v2/features/collection/DocumentCollection.vue.d.ts.map +1 -1
- package/dist/v2/features/collection/DocumentCollection.vue.js +292 -100
- package/dist/v2/features/collection/DocumentCollection.vue3.js +5 -0
- package/dist/v2/features/collection/OperationCollection.vue.js +20 -19
- package/dist/v2/features/collection/WorkspaceCollection.vue.js +6 -5
- package/dist/v2/features/collection/components/Authentication.vue2.js +16 -15
- package/dist/v2/features/collection/components/Cookies.vue.js +7 -6
- package/dist/v2/features/collection/components/Editor/Editor.vue.d.ts.map +1 -1
- package/dist/v2/features/collection/components/Editor/Editor.vue.js +3 -3
- package/dist/v2/features/collection/components/Editor/Editor.vue2.js +182 -171
- package/dist/v2/features/collection/components/Editor/hooks/use-editor-state.d.ts +2 -1
- package/dist/v2/features/collection/components/Editor/hooks/use-editor-state.d.ts.map +1 -1
- package/dist/v2/features/collection/components/Environment.vue.js +13 -12
- package/dist/v2/features/collection/components/Overview.vue2.js +7 -6
- package/dist/v2/features/collection/components/Servers.vue.js +64 -63
- package/dist/v2/features/collection/components/Settings.vue.js +8 -7
- package/dist/v2/features/collection/components/SyncConflictResolutionEditor.vue.d.ts +18 -0
- package/dist/v2/features/collection/components/SyncConflictResolutionEditor.vue.d.ts.map +1 -0
- package/dist/v2/features/collection/components/SyncConflictResolutionEditor.vue.js +7 -0
- package/dist/v2/features/collection/components/SyncConflictResolutionEditor.vue2.js +136 -0
- package/dist/v2/features/editor/config.d.ts +16 -0
- package/dist/v2/features/editor/config.d.ts.map +1 -0
- package/dist/v2/features/editor/config.js +16 -0
- package/dist/v2/features/editor/helpers/configure-language-support.d.ts +13 -0
- package/dist/v2/features/editor/helpers/configure-language-support.d.ts.map +1 -0
- package/dist/v2/features/{collection/components/Editor → editor}/helpers/configure-language-support.js +6 -7
- package/dist/v2/features/editor/helpers/ensure-monaco-environment.d.ts.map +1 -0
- package/dist/v2/features/{collection/components/Editor → editor}/helpers/ensure-monaco-environment.js +9 -12
- package/dist/v2/features/editor/helpers/json/create-json-model.d.ts +12 -0
- package/dist/v2/features/editor/helpers/json/create-json-model.d.ts.map +1 -0
- package/dist/v2/features/editor/helpers/json/create-json-model.js +19 -0
- package/dist/v2/features/editor/helpers/json/get-json-ast-node-from-path.d.ts.map +1 -0
- package/dist/v2/features/editor/helpers/json/json-ast.d.ts.map +1 -0
- package/dist/v2/features/editor/helpers/json/json-pointer-links.d.ts.map +1 -0
- package/dist/v2/features/editor/helpers/json/json-pointer-path.d.ts.map +1 -0
- package/dist/v2/features/editor/helpers/json/json-pointer-path.js +21 -0
- package/dist/v2/features/editor/helpers/model.d.ts +9 -0
- package/dist/v2/features/editor/helpers/model.d.ts.map +1 -0
- package/dist/v2/features/editor/helpers/range-to-whole-line.d.ts +14 -0
- package/dist/v2/features/editor/helpers/range-to-whole-line.d.ts.map +1 -0
- package/dist/v2/features/editor/helpers/range-to-whole-line.js +8 -0
- package/dist/v2/features/editor/helpers/theme/apply-scalar-theme.d.ts.map +1 -0
- package/dist/v2/features/editor/helpers/theme/load-css-variables.d.ts.map +1 -0
- package/dist/v2/features/editor/helpers/yaml/create-yaml-model.d.ts +13 -0
- package/dist/v2/features/editor/helpers/yaml/create-yaml-model.d.ts.map +1 -0
- package/dist/v2/features/editor/helpers/yaml/create-yaml-model.js +19 -0
- package/dist/v2/features/{collection/components/Editor/helpers → editor/helpers/yaml}/get-yaml-node-range-from-path.d.ts +2 -2
- package/dist/v2/features/editor/helpers/yaml/get-yaml-node-range-from-path.d.ts.map +1 -0
- package/dist/v2/features/editor/hooks/use-editor-markers.d.ts.map +1 -0
- package/dist/v2/features/editor/hooks/use-editor.d.ts +39 -0
- package/dist/v2/features/editor/hooks/use-editor.d.ts.map +1 -0
- package/dist/v2/features/editor/hooks/use-editor.js +107 -0
- package/dist/v2/features/editor/hooks/use-json-pointer-link-support.d.ts +16 -0
- package/dist/v2/features/editor/hooks/use-json-pointer-link-support.d.ts.map +1 -0
- package/dist/v2/features/editor/hooks/use-json-pointer-link-support.js +27 -0
- package/dist/v2/features/editor/hooks/use-three-way-merge-editor.d.ts +77 -0
- package/dist/v2/features/editor/hooks/use-three-way-merge-editor.d.ts.map +1 -0
- package/dist/v2/features/editor/hooks/use-three-way-merge-editor.js +316 -0
- package/dist/v2/features/editor/index.d.ts +5 -0
- package/dist/v2/features/editor/index.d.ts.map +1 -0
- package/dist/v2/features/editor/index.js +10 -0
- package/dist/v2/features/operation/Operation.vue.js +18 -17
- package/dist/v2/types/configuration.d.ts +11 -0
- package/dist/v2/types/configuration.d.ts.map +1 -0
- package/dist/views/Components/CodeSnippet/helpers/get-har-request.d.ts.map +1 -1
- package/dist/views/Components/CodeSnippet/helpers/get-har-request.js +44 -45
- package/dist/views/Request/ResponseSection/ResponseEmpty.vue2.js +1 -1
- package/package.json +24 -18
- package/dist/assets/yaml.worker-CcQnAKCg.js +0 -490
- package/dist/v2/features/collection/DocumentCollection.vue2.js +0 -4
- package/dist/v2/features/collection/components/Editor/helpers/apply-scalar-theme.d.ts.map +0 -1
- package/dist/v2/features/collection/components/Editor/helpers/configure-language-support.d.ts +0 -7
- package/dist/v2/features/collection/components/Editor/helpers/configure-language-support.d.ts.map +0 -1
- package/dist/v2/features/collection/components/Editor/helpers/ensure-monaco-environment.d.ts.map +0 -1
- package/dist/v2/features/collection/components/Editor/helpers/get-json-ast-node-from-path.d.ts.map +0 -1
- package/dist/v2/features/collection/components/Editor/helpers/get-yaml-node-range-from-path.d.ts.map +0 -1
- package/dist/v2/features/collection/components/Editor/helpers/json-ast.d.ts.map +0 -1
- package/dist/v2/features/collection/components/Editor/helpers/json-pointer-links.d.ts.map +0 -1
- package/dist/v2/features/collection/components/Editor/helpers/json-pointer-path.d.ts.map +0 -1
- package/dist/v2/features/collection/components/Editor/helpers/json-pointer-path.js +0 -20
- package/dist/v2/features/collection/components/Editor/helpers/load-css-variables.d.ts.map +0 -1
- package/dist/v2/features/collection/components/Editor/helpers/yaml.worker.d.ts +0 -2
- package/dist/v2/features/collection/components/Editor/helpers/yaml.worker.d.ts.map +0 -1
- package/dist/v2/features/collection/components/Editor/helpers/yaml.worker.js +0 -11
- package/dist/v2/features/collection/components/Editor/hooks/use-editor-markers.d.ts.map +0 -1
- package/dist/v2/features/collection/components/Editor/hooks/use-editor.d.ts +0 -39
- package/dist/v2/features/collection/components/Editor/hooks/use-editor.d.ts.map +0 -1
- package/dist/v2/features/collection/components/Editor/hooks/use-editor.js +0 -153
- /package/dist/v2/features/{collection/components/Editor → editor}/helpers/ensure-monaco-environment.d.ts +0 -0
- /package/dist/v2/features/{collection/components/Editor/helpers → editor/helpers/json}/get-json-ast-node-from-path.d.ts +0 -0
- /package/dist/v2/features/{collection/components/Editor/helpers → editor/helpers/json}/get-json-ast-node-from-path.js +0 -0
- /package/dist/v2/features/{collection/components/Editor/helpers → editor/helpers/json}/json-ast.d.ts +0 -0
- /package/dist/v2/features/{collection/components/Editor/helpers → editor/helpers/json}/json-ast.js +0 -0
- /package/dist/v2/features/{collection/components/Editor/helpers → editor/helpers/json}/json-pointer-links.d.ts +0 -0
- /package/dist/v2/features/{collection/components/Editor/helpers → editor/helpers/json}/json-pointer-links.js +0 -0
- /package/dist/v2/features/{collection/components/Editor/helpers → editor/helpers/json}/json-pointer-path.d.ts +0 -0
- /package/dist/v2/features/{collection/components/Editor/helpers → editor/helpers/theme}/apply-scalar-theme.d.ts +0 -0
- /package/dist/v2/features/{collection/components/Editor/helpers → editor/helpers/theme}/apply-scalar-theme.js +0 -0
- /package/dist/v2/features/{collection/components/Editor/helpers → editor/helpers/theme}/load-css-variables.d.ts +0 -0
- /package/dist/v2/features/{collection/components/Editor/helpers → editor/helpers/theme}/load-css-variables.js +0 -0
- /package/dist/v2/features/{collection/components/Editor/helpers → editor/helpers/yaml}/get-yaml-node-range-from-path.js +0 -0
- /package/dist/v2/features/{collection/components/Editor → editor}/hooks/use-editor-markers.d.ts +0 -0
- /package/dist/v2/features/{collection/components/Editor → editor}/hooks/use-editor-markers.js +0 -0
- /package/dist/v2/features/{collection/components/Editor → editor}/schemas/openapi-3.1-schema.json.js +0 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"build-request-body.d.ts","sourceRoot":"","sources":["../../../../../src/v2/blocks/operation-block/helpers/build-request-body.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,0DAA0D,CAAA;AAKjG;;GAEG;AACH,eAAO,MAAM,gBAAgB,GAC3B,aAAa,iBAAiB,GAAG,SAAS;AAC1C,8DAA8D;AAC9D,MAAK,MAAM,CAAC,MAAM,EAAE,MAAM,CAAM;AAChC,qCAAqC;AACrC,mBAAsB,KACrB,QAAQ,GAAG,
|
|
1
|
+
{"version":3,"file":"build-request-body.d.ts","sourceRoot":"","sources":["../../../../../src/v2/blocks/operation-block/helpers/build-request-body.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,0DAA0D,CAAA;AAKjG;;GAEG;AACH,eAAO,MAAM,gBAAgB,GAC3B,aAAa,iBAAiB,GAAG,SAAS;AAC1C,8DAA8D;AAC9D,MAAK,MAAM,CAAC,MAAM,EAAE,MAAM,CAAM;AAChC,qCAAqC;AACrC,mBAAsB,KACrB,QAAQ,GAAG,IAuFb,CAAA"}
|
|
@@ -1,39 +1,40 @@
|
|
|
1
|
-
import { replaceEnvVariables as
|
|
2
|
-
import { unpackProxyObject as
|
|
3
|
-
import { getSelectedBodyContentType as
|
|
4
|
-
import { getExampleFromBody as
|
|
5
|
-
const
|
|
6
|
-
if (!
|
|
1
|
+
import { replaceEnvVariables as i } from "@scalar/helpers/regex/replace-variables";
|
|
2
|
+
import { unpackProxyObject as m } from "@scalar/workspace-store/helpers/unpack-proxy";
|
|
3
|
+
import { getSelectedBodyContentType as d } from "./get-selected-body-content-type.js";
|
|
4
|
+
import { getExampleFromBody as y } from "../../request-block/helpers/get-request-body-example.js";
|
|
5
|
+
const j = (u, o = {}, c = "default") => {
|
|
6
|
+
if (!u)
|
|
7
7
|
return null;
|
|
8
|
-
const
|
|
9
|
-
if (!
|
|
8
|
+
const n = d(u, c);
|
|
9
|
+
if (!n)
|
|
10
10
|
return null;
|
|
11
|
-
const e =
|
|
11
|
+
const e = y(u, n, c);
|
|
12
12
|
if (!e)
|
|
13
13
|
return null;
|
|
14
|
-
if ((
|
|
15
|
-
const
|
|
16
|
-
return
|
|
14
|
+
if ((n === "multipart/form-data" || n === "application/x-www-form-urlencoded") && Array.isArray(e.value)) {
|
|
15
|
+
const f = e.value.filter((r) => !r.isDisabled), a = n === "multipart/form-data" ? new FormData() : new URLSearchParams();
|
|
16
|
+
return f.forEach(({ name: r, value: l }) => {
|
|
17
17
|
if (!r)
|
|
18
18
|
return;
|
|
19
|
-
const
|
|
20
|
-
if (
|
|
21
|
-
const
|
|
22
|
-
|
|
23
|
-
} else typeof
|
|
24
|
-
}),
|
|
19
|
+
const p = i(r, o);
|
|
20
|
+
if (l instanceof File && a instanceof FormData) {
|
|
21
|
+
const s = m(l);
|
|
22
|
+
a.append(p, s, s.name);
|
|
23
|
+
} else typeof l == "string" && a.append(p, i(l, o));
|
|
24
|
+
}), a;
|
|
25
25
|
}
|
|
26
|
-
if (
|
|
27
|
-
const
|
|
28
|
-
for (const [
|
|
29
|
-
if (
|
|
30
|
-
const
|
|
31
|
-
|
|
26
|
+
if (n === "application/x-www-form-urlencoded" && e.value !== null && typeof e.value == "object" && !Array.isArray(e.value)) {
|
|
27
|
+
const f = new URLSearchParams();
|
|
28
|
+
for (const [a, r] of Object.entries(e.value))
|
|
29
|
+
if (a && r !== void 0 && r !== null) {
|
|
30
|
+
const l = i(a, o), p = typeof r == "string" ? r : String(r);
|
|
31
|
+
f.append(l, i(p, o));
|
|
32
32
|
}
|
|
33
|
-
return
|
|
33
|
+
return f;
|
|
34
34
|
}
|
|
35
|
-
|
|
35
|
+
const t = e.value !== null && typeof e.value == "object" ? m(e.value) : e.value;
|
|
36
|
+
return t instanceof File ? t : typeof t == "object" ? i(JSON.stringify(t), o) : typeof t == "string" ? i(t, o) : t;
|
|
36
37
|
};
|
|
37
38
|
export {
|
|
38
|
-
|
|
39
|
+
j as buildRequestBody
|
|
39
40
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ExamplePicker.vue.d.ts","sourceRoot":"","sources":["../../../../../src/v2/blocks/operation-code-sample/components/ExamplePicker.vue"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"ExamplePicker.vue.d.ts","sourceRoot":"","sources":["../../../../../src/v2/blocks/operation-code-sample/components/ExamplePicker.vue"],"names":[],"mappings":"AAgEA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,8DAA8D,CAAA;AAGnG,KAAK,WAAW,GAAG;IACjB,QAAQ,CAAC,EAAE,eAAe,CAAC,UAAU,CAAC,GAAG,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAA;CAChE,CAAC;AAwBF,KAAK,gBAAgB,GAAG;IACxB,UAAU,EAAE,MAAM,CAAC;CAClB,CAAC;AAKF,KAAK,iBAAiB,GAAG,WAAW,GAAG,gBAAgB,CAAC;AAyGxD,QAAA,MAAM,YAAY;;;;kFAGhB,CAAC;wBACkB,OAAO,YAAY;AAAxC,wBAAyC"}
|
|
@@ -1,7 +1,8 @@
|
|
|
1
|
-
import { defineComponent as u, mergeModels as p, useModel as c, computed as m, createBlock as f, openBlock as x, unref as l, withCtx as n, createVNode as i,
|
|
2
|
-
import { ScalarListbox as
|
|
3
|
-
import { ScalarIconCaretDown as
|
|
4
|
-
const
|
|
1
|
+
import { defineComponent as u, mergeModels as p, useModel as c, computed as m, createBlock as f, openBlock as x, unref as l, withCtx as n, createVNode as i, mergeProps as v, createElementVNode as w, toDisplayString as V } from "vue";
|
|
2
|
+
import { ScalarListbox as b, ScalarButton as g } from "@scalar/components";
|
|
3
|
+
import { ScalarIconCaretDown as h } from "@scalar/icons";
|
|
4
|
+
const S = { class: "min-w-0 flex-1 truncate" }, y = /* @__PURE__ */ u({
|
|
5
|
+
inheritAttrs: !1,
|
|
5
6
|
__name: "ExamplePicker",
|
|
6
7
|
props: /* @__PURE__ */ p({
|
|
7
8
|
examples: { default: () => ({}) }
|
|
@@ -22,7 +23,7 @@ const _ = { class: "min-w-0 flex-1 truncate" }, k = /* @__PURE__ */ u({
|
|
|
22
23
|
get: () => s.value.find(({ id: e }) => e === r.value),
|
|
23
24
|
set: (e) => r.value = e?.id ?? ""
|
|
24
25
|
});
|
|
25
|
-
return (e, t) => (x(), f(l(
|
|
26
|
+
return (e, t) => (x(), f(l(b), {
|
|
26
27
|
modelValue: a.value,
|
|
27
28
|
"onUpdate:modelValue": t[0] || (t[0] = (d) => a.value = d),
|
|
28
29
|
class: "w-fit min-w-32",
|
|
@@ -31,25 +32,25 @@ const _ = { class: "min-w-0 flex-1 truncate" }, k = /* @__PURE__ */ u({
|
|
|
31
32
|
teleport: ""
|
|
32
33
|
}, {
|
|
33
34
|
default: n(() => [
|
|
34
|
-
i(l(
|
|
35
|
+
i(l(g), v({
|
|
35
36
|
class: "text-c-2 hover:text-c-1 flex h-full w-fit min-w-0 gap-1.5 px-1.5 py-0.75 text-base font-normal",
|
|
36
37
|
"data-testid": "example-picker",
|
|
37
38
|
variant: "ghost"
|
|
38
|
-
}, {
|
|
39
|
+
}, e.$attrs), {
|
|
39
40
|
default: n(() => [
|
|
40
|
-
|
|
41
|
-
i(l(
|
|
41
|
+
w("div", S, V(a.value?.label ?? "Select an example"), 1),
|
|
42
|
+
i(l(h), {
|
|
42
43
|
class: "ui-open:rotate-180 mt-0.25 size-3 transition-transform duration-100",
|
|
43
44
|
weight: "bold"
|
|
44
45
|
})
|
|
45
46
|
]),
|
|
46
47
|
_: 1
|
|
47
|
-
})
|
|
48
|
+
}, 16)
|
|
48
49
|
]),
|
|
49
50
|
_: 1
|
|
50
51
|
}, 8, ["modelValue", "options"]));
|
|
51
52
|
}
|
|
52
53
|
});
|
|
53
54
|
export {
|
|
54
|
-
|
|
55
|
+
y as default
|
|
55
56
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"process-body.d.ts","sourceRoot":"","sources":["../../../../../../src/v2/blocks/operation-code-sample/helpers/operation-to-har/process-body.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,8DAA8D,CAAA;AAErG,OAAO,KAAK,EAAS,QAAQ,EAAE,MAAM,YAAY,CAAA;AAIjD,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,oBAAoB,CAAA;AAE7D,KAAK,gBAAgB,GAAG,IAAI,CAAC,mBAAmB,EAAE,aAAa,GAAG,SAAS,CAAC,GAAG;IAC7E,WAAW,EAAE,iBAAiB,CAAA;CAC/B,CAAA;AAoDD;;;GAGG;AACH,eAAO,MAAM,WAAW,GAAI,uCAAuC,gBAAgB,KAAG,QAAQ,GAAG,
|
|
1
|
+
{"version":3,"file":"process-body.d.ts","sourceRoot":"","sources":["../../../../../../src/v2/blocks/operation-code-sample/helpers/operation-to-har/process-body.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,8DAA8D,CAAA;AAErG,OAAO,KAAK,EAAS,QAAQ,EAAE,MAAM,YAAY,CAAA;AAIjD,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,oBAAoB,CAAA;AAE7D,KAAK,gBAAgB,GAAG,IAAI,CAAC,mBAAmB,EAAE,aAAa,GAAG,SAAS,CAAC,GAAG;IAC7E,WAAW,EAAE,iBAAiB,CAAA;CAC/B,CAAA;AAoDD;;;GAGG;AACH,eAAO,MAAM,WAAW,GAAI,uCAAuC,gBAAgB,KAAG,QAAQ,GAAG,SA8EhG,CAAA"}
|
|
@@ -1,58 +1,63 @@
|
|
|
1
|
-
import { json2xml as
|
|
2
|
-
import { getResolvedRef as
|
|
3
|
-
import { unpackProxyObject as
|
|
4
|
-
import { getExampleFromSchema as
|
|
5
|
-
import { getExample as
|
|
6
|
-
const
|
|
7
|
-
const
|
|
8
|
-
for (const [
|
|
1
|
+
import { json2xml as c } from "@scalar/helpers/file/json2xml";
|
|
2
|
+
import { getResolvedRef as u } from "@scalar/workspace-store/helpers/get-resolved-ref";
|
|
3
|
+
import { unpackProxyObject as s } from "@scalar/workspace-store/helpers/unpack-proxy";
|
|
4
|
+
import { getExampleFromSchema as y } from "../get-example-from-schema.js";
|
|
5
|
+
import { getExample as x } from "../../../operation-block/helpers/get-example.js";
|
|
6
|
+
const f = (a) => {
|
|
7
|
+
const r = [], l = Array.isArray(a) ? a.filter((t) => !t.isDisabled).map((t) => [t.name, t.value]) : Object.entries(a);
|
|
8
|
+
for (const [t, n] of l)
|
|
9
9
|
if (n != null)
|
|
10
10
|
if (n instanceof File) {
|
|
11
|
-
const o =
|
|
12
|
-
|
|
11
|
+
const o = s(n);
|
|
12
|
+
r.push({ name: t, value: `@${o.name}` });
|
|
13
13
|
} else if (Array.isArray(n))
|
|
14
14
|
for (const o of n)
|
|
15
15
|
if (o instanceof File) {
|
|
16
|
-
const
|
|
17
|
-
|
|
16
|
+
const i = s(o);
|
|
17
|
+
r.push({ name: t, value: `@${i.name}` });
|
|
18
18
|
} else
|
|
19
|
-
|
|
19
|
+
r.push({ name: t, value: String(o) });
|
|
20
20
|
else if (typeof n == "object") {
|
|
21
|
-
const o =
|
|
22
|
-
for (const
|
|
23
|
-
|
|
21
|
+
const o = f(n);
|
|
22
|
+
for (const i of o)
|
|
23
|
+
r.push({ name: `${t}.${i.name}`, value: i.value });
|
|
24
24
|
} else
|
|
25
|
-
|
|
26
|
-
return
|
|
27
|
-
}, h = ({ requestBody: a, contentType:
|
|
28
|
-
const
|
|
29
|
-
if (typeof
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
25
|
+
r.push({ name: t, value: String(n) });
|
|
26
|
+
return r;
|
|
27
|
+
}, h = ({ requestBody: a, contentType: r, example: l }) => {
|
|
28
|
+
const t = r || Object.keys(a.content)[0] || "", n = (e) => `@${s(e).name || "filename"}`, o = t === "multipart/form-data" || t === "application/x-www-form-urlencoded", i = t === "application/xml", m = x(a, l, r)?.value;
|
|
29
|
+
if (typeof m < "u") {
|
|
30
|
+
const e = m !== null && typeof m == "object" ? s(m) : m;
|
|
31
|
+
return o && typeof e == "object" && e !== null ? {
|
|
32
|
+
mimeType: t,
|
|
33
|
+
params: f(e)
|
|
34
|
+
} : i && typeof e == "object" && e !== null ? {
|
|
35
|
+
mimeType: t,
|
|
36
|
+
text: c(e)
|
|
37
|
+
} : e instanceof File ? {
|
|
38
|
+
mimeType: t,
|
|
39
|
+
text: n(e)
|
|
36
40
|
} : {
|
|
37
|
-
mimeType:
|
|
38
|
-
text: typeof
|
|
41
|
+
mimeType: t,
|
|
42
|
+
text: typeof e == "string" ? e : JSON.stringify(e)
|
|
39
43
|
};
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
44
|
+
}
|
|
45
|
+
const p = u(a.content[t]?.schema);
|
|
46
|
+
if (typeof p < "u") {
|
|
47
|
+
const e = y(p, {
|
|
43
48
|
mode: "write",
|
|
44
|
-
xml:
|
|
49
|
+
xml: i
|
|
45
50
|
});
|
|
46
|
-
if (
|
|
47
|
-
return
|
|
48
|
-
mimeType:
|
|
49
|
-
params:
|
|
50
|
-
} :
|
|
51
|
-
mimeType:
|
|
52
|
-
text:
|
|
51
|
+
if (e !== void 0)
|
|
52
|
+
return o && typeof e == "object" && e !== null ? {
|
|
53
|
+
mimeType: t,
|
|
54
|
+
params: f(e)
|
|
55
|
+
} : i && typeof e == "object" && e !== null ? {
|
|
56
|
+
mimeType: t,
|
|
57
|
+
text: c(e)
|
|
53
58
|
} : {
|
|
54
|
-
mimeType:
|
|
55
|
-
text: typeof
|
|
59
|
+
mimeType: t,
|
|
60
|
+
text: typeof e == "string" ? e : JSON.stringify(e)
|
|
56
61
|
};
|
|
57
62
|
}
|
|
58
63
|
};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { canMethodHaveBody as m } from "@scalar/helpers/http/can-method-have-body";
|
|
2
2
|
import { getResolvedRef as r } from "@scalar/workspace-store/helpers/get-resolved-ref";
|
|
3
3
|
import { isElectron as y } from "../../../../libs/electron.js";
|
|
4
|
-
const l = "2.36.
|
|
4
|
+
const l = "2.36.2", T = "application/json", C = "*/*", a = (n, s, o) => ({
|
|
5
5
|
name: n,
|
|
6
6
|
defaultValue: s,
|
|
7
7
|
isOverridden: o.has(n.toLowerCase())
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"OAuth2.vue.d.ts","sourceRoot":"","sources":["../../../../../src/v2/blocks/scalar-auth-selector-block/components/OAuth2.vue"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"OAuth2.vue.d.ts","sourceRoot":"","sources":["../../../../../src/v2/blocks/scalar-auth-selector-block/components/OAuth2.vue"],"names":[],"mappings":"AAwZA,OAAO,KAAK,EAEV,iBAAiB,EAClB,MAAM,gCAAgC,CAAA;AACvC,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,2EAA2E,CAAA;AAGnH,OAAO,KAAK,EAEV,YAAY,EACb,MAAM,8DAA8D,CAAA;AAOrE,OAAO,KAAK,EAIV,sBAAsB,EACtB,0BAA0B,EAC3B,MAAM,6DAA6D,CAAA;AAIpE,KAAK,WAAW,GAAG;IACjB,wCAAwC;IACxC,WAAW,EAAE,kBAAkB,CAAA;IAC/B,kBAAkB;IAClB,KAAK,EAAE,sBAAsB,CAAA;IAC7B,6BAA6B;IAC7B,IAAI,EAAE,MAAM,sBAAsB,CAAA;IAClC,sBAAsB;IACtB,cAAc,EAAE,MAAM,EAAE,CAAA;IACxB,sBAAsB;IACtB,MAAM,EAAE,0BAA0B,CAAA;IAClC,mCAAmC;IACnC,MAAM,EAAE,YAAY,GAAG,IAAI,CAAA;IAC3B,gBAAgB;IAChB,QAAQ,EAAE,MAAM,CAAA;IAChB,kCAAkC;IAClC,IAAI,EAAE,MAAM,CAAA;IACZ,2CAA2C;IAC3C,QAAQ,EAAE,iBAAiB,CAAA;CAC5B,CAAC;AAmwBF,QAAA,MAAM,YAAY;;;;;;;;;;;;;;;;;;;;;;;;kFAGhB,CAAC;wBACkB,OAAO,YAAY;AAAxC,wBAAyC"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { defineComponent as O, computed as C, ref as P, watch as R, createElementBlock as k, openBlock as m, Fragment as p, createVNode as r, unref as o, withCtx as l, createTextVNode as
|
|
1
|
+
import { defineComponent as O, computed as C, ref as P, watch as R, createElementBlock as k, openBlock as m, Fragment as p, createVNode as r, unref as o, withCtx as l, createTextVNode as u, createElementVNode as S, createBlock as v, createCommentVNode as f } from "vue";
|
|
2
2
|
import { useLoadingState as I, ScalarButton as V } from "@scalar/components";
|
|
3
3
|
import { pkceOptions as L } from "@scalar/oas-utils/entities/spec";
|
|
4
4
|
import { useToasts as F } from "@scalar/use-toasts";
|
|
@@ -7,7 +7,7 @@ import E from "./OAuthScopesInput.vue.js";
|
|
|
7
7
|
/* empty css */
|
|
8
8
|
import { authorizeOauth2 as N } from "../helpers/oauth.js";
|
|
9
9
|
import c from "./RequestAuthDataTableInput.vue.js";
|
|
10
|
-
import
|
|
10
|
+
import i from "../../../../components/DataTable/DataTableRow.vue.js";
|
|
11
11
|
const j = { class: "flex h-8 items-center justify-end gap-2 border-t" }, Q = { class: "flex h-8 w-full items-center justify-end border-t" }, J = /* @__PURE__ */ O({
|
|
12
12
|
__name: "OAuth2",
|
|
13
13
|
props: {
|
|
@@ -23,11 +23,11 @@ const j = { class: "flex h-8 items-center justify-end gap-2 border-t" }, Q = { c
|
|
|
23
23
|
},
|
|
24
24
|
emits: ["update:selectedScopes"],
|
|
25
25
|
setup(t, { emit: T }) {
|
|
26
|
-
const g = T,
|
|
26
|
+
const g = T, x = I(), { toast: B } = F(), n = C(() => t.flows[t.type]), w = C(
|
|
27
27
|
() => t.selectedScopes.filter((s) => s in (n.value.scopes ?? {}))
|
|
28
|
-
),
|
|
28
|
+
), y = (s) => {
|
|
29
29
|
if (t.scheme.type === "openIdConnect")
|
|
30
|
-
return
|
|
30
|
+
return d(s);
|
|
31
31
|
t.eventBus.emit("auth:update:security-scheme", {
|
|
32
32
|
payload: {
|
|
33
33
|
type: t.scheme.type,
|
|
@@ -37,45 +37,45 @@ const j = { class: "flex h-8 items-center justify-end gap-2 border-t" }, Q = { c
|
|
|
37
37
|
},
|
|
38
38
|
name: t.name
|
|
39
39
|
});
|
|
40
|
-
},
|
|
40
|
+
}, d = (s) => t.eventBus.emit("auth:update:security-scheme-secrets", {
|
|
41
41
|
payload: {
|
|
42
42
|
type: t.scheme.type,
|
|
43
43
|
[t.type]: s
|
|
44
44
|
},
|
|
45
45
|
name: t.name
|
|
46
|
-
}),
|
|
46
|
+
}), b = () => t.eventBus.emit("auth:clear:security-scheme-secrets", {
|
|
47
47
|
name: t.name
|
|
48
|
-
}),
|
|
48
|
+
}), U = P(!1);
|
|
49
49
|
R(
|
|
50
50
|
() => n.value["x-scalar-secret-redirect-uri"],
|
|
51
51
|
(s) => {
|
|
52
|
-
|
|
52
|
+
U.value || s || typeof window > "u" || !("x-scalar-secret-redirect-uri" in n.value) || (U.value = !0, d({
|
|
53
53
|
"x-scalar-secret-redirect-uri": window.location.origin + window.location.pathname
|
|
54
54
|
}));
|
|
55
55
|
},
|
|
56
56
|
{ immediate: !0 }
|
|
57
57
|
);
|
|
58
|
-
const
|
|
59
|
-
if (
|
|
58
|
+
const z = async () => {
|
|
59
|
+
if (x.isLoading)
|
|
60
60
|
return;
|
|
61
|
-
|
|
61
|
+
x.start();
|
|
62
62
|
const [s, e] = await N(
|
|
63
63
|
t.flows,
|
|
64
64
|
t.type,
|
|
65
|
-
|
|
65
|
+
w.value,
|
|
66
66
|
t.server,
|
|
67
67
|
t.proxyUrl,
|
|
68
68
|
A(t.environment)
|
|
69
69
|
);
|
|
70
|
-
await
|
|
70
|
+
await x.clear(), e?.accessToken ? d({
|
|
71
71
|
"x-scalar-secret-token": e.accessToken,
|
|
72
72
|
...e.refreshToken ? { "x-scalar-secret-refresh-token": e.refreshToken } : {}
|
|
73
|
-
}) : (console.error(s),
|
|
74
|
-
}, h = (s) =>
|
|
73
|
+
}) : (console.error(s), B(s?.message ?? "Failed to authorize", "error"));
|
|
74
|
+
}, h = (s) => y({
|
|
75
75
|
"x-scalar-credentials-location": s === "body" ? "body" : "header"
|
|
76
76
|
});
|
|
77
77
|
return (s, e) => n.value["x-scalar-secret-token"] ? (m(), k(p, { key: 0 }, [
|
|
78
|
-
r(o(
|
|
78
|
+
r(o(i), null, {
|
|
79
79
|
default: l(() => [
|
|
80
80
|
r(c, {
|
|
81
81
|
class: "border-r-transparent",
|
|
@@ -83,31 +83,31 @@ const j = { class: "flex h-8 items-center justify-end gap-2 border-t" }, Q = { c
|
|
|
83
83
|
modelValue: n.value["x-scalar-secret-token"],
|
|
84
84
|
placeholder: "QUxMIFlPVVIgQkFTRSBBUkUgQkVMT05HIFRPIFVT",
|
|
85
85
|
type: "password",
|
|
86
|
-
"onUpdate:modelValue": e[0] || (e[0] = (a) =>
|
|
86
|
+
"onUpdate:modelValue": e[0] || (e[0] = (a) => d({ "x-scalar-secret-token": a }))
|
|
87
87
|
}, {
|
|
88
88
|
default: l(() => [...e[12] || (e[12] = [
|
|
89
|
-
|
|
89
|
+
u(" Access Token ", -1)
|
|
90
90
|
])]),
|
|
91
91
|
_: 1
|
|
92
92
|
}, 8, ["environment", "modelValue"])
|
|
93
93
|
]),
|
|
94
94
|
_: 1
|
|
95
95
|
}),
|
|
96
|
-
r(o(
|
|
96
|
+
r(o(i), { class: "min-w-full" }, {
|
|
97
97
|
default: l(() => [
|
|
98
98
|
S("div", j, [
|
|
99
99
|
r(o(V), {
|
|
100
100
|
class: "mr-1 p-0 px-2 py-0.5",
|
|
101
|
-
loader: o(
|
|
101
|
+
loader: o(x),
|
|
102
102
|
size: "sm",
|
|
103
103
|
variant: "outlined",
|
|
104
|
-
onClick: e[1] || (e[1] = () =>
|
|
104
|
+
onClick: e[1] || (e[1] = () => d({
|
|
105
105
|
"x-scalar-secret-token": "",
|
|
106
106
|
"x-scalar-secret-refresh-token": ""
|
|
107
107
|
}))
|
|
108
108
|
}, {
|
|
109
109
|
default: l(() => [...e[13] || (e[13] = [
|
|
110
|
-
|
|
110
|
+
u(" Clear ", -1)
|
|
111
111
|
])]),
|
|
112
112
|
_: 1
|
|
113
113
|
}, 8, ["loader"])
|
|
@@ -116,46 +116,52 @@ const j = { class: "flex h-8 items-center justify-end gap-2 border-t" }, Q = { c
|
|
|
116
116
|
_: 1
|
|
117
117
|
})
|
|
118
118
|
], 64)) : (m(), k(p, { key: 1 }, [
|
|
119
|
-
r(o(
|
|
119
|
+
r(o(i), null, {
|
|
120
120
|
default: l(() => [
|
|
121
121
|
"authorizationUrl" in n.value ? (m(), v(c, {
|
|
122
122
|
key: 0,
|
|
123
123
|
containerClass: "border-r-0",
|
|
124
124
|
environment: t.environment,
|
|
125
|
-
modelValue: n.value
|
|
125
|
+
modelValue: n.value["x-scalar-secret-auth-url"] ?? "",
|
|
126
126
|
placeholder: "https://galaxy.scalar.com/authorize",
|
|
127
|
-
"onUpdate:modelValue": e[2] || (e[2] = (a) =>
|
|
127
|
+
"onUpdate:modelValue": e[2] || (e[2] = (a) => {
|
|
128
|
+
d({ "x-scalar-secret-auth-url": a }), y({ authorizationUrl: a });
|
|
129
|
+
})
|
|
128
130
|
}, {
|
|
129
131
|
default: l(() => [...e[14] || (e[14] = [
|
|
130
|
-
|
|
132
|
+
u(" Auth URL ", -1)
|
|
131
133
|
])]),
|
|
132
134
|
_: 1
|
|
133
135
|
}, 8, ["environment", "modelValue"])) : f("", !0),
|
|
134
136
|
"tokenUrl" in n.value ? (m(), v(c, {
|
|
135
137
|
key: 1,
|
|
136
138
|
environment: t.environment,
|
|
137
|
-
modelValue: n.value
|
|
139
|
+
modelValue: n.value["x-scalar-secret-token-url"] ?? "",
|
|
138
140
|
placeholder: "https://galaxy.scalar.com/token",
|
|
139
|
-
"onUpdate:modelValue": e[3] || (e[3] = (a) =>
|
|
141
|
+
"onUpdate:modelValue": e[3] || (e[3] = (a) => {
|
|
142
|
+
d({ "x-scalar-secret-token-url": a }), y({ tokenUrl: a });
|
|
143
|
+
})
|
|
140
144
|
}, {
|
|
141
145
|
default: l(() => [...e[15] || (e[15] = [
|
|
142
|
-
|
|
146
|
+
u(" Token URL ", -1)
|
|
143
147
|
])]),
|
|
144
148
|
_: 1
|
|
145
149
|
}, 8, ["environment", "modelValue"])) : f("", !0)
|
|
146
150
|
]),
|
|
147
151
|
_: 1
|
|
148
152
|
}),
|
|
149
|
-
"x-scalar-secret-redirect-uri" in n.value ? (m(), v(o(
|
|
153
|
+
"x-scalar-secret-redirect-uri" in n.value ? (m(), v(o(i), { key: 0 }, {
|
|
150
154
|
default: l(() => [
|
|
151
155
|
r(c, {
|
|
152
156
|
environment: t.environment,
|
|
153
157
|
modelValue: n.value["x-scalar-secret-redirect-uri"],
|
|
154
158
|
placeholder: "https://galaxy.scalar.com/callback",
|
|
155
|
-
"onUpdate:modelValue": e[4] || (e[4] = (a) =>
|
|
159
|
+
"onUpdate:modelValue": e[4] || (e[4] = (a) => {
|
|
160
|
+
d({ "x-scalar-secret-redirect-uri": a });
|
|
161
|
+
})
|
|
156
162
|
}, {
|
|
157
163
|
default: l(() => [...e[16] || (e[16] = [
|
|
158
|
-
|
|
164
|
+
u(" Redirect URL ", -1)
|
|
159
165
|
])]),
|
|
160
166
|
_: 1
|
|
161
167
|
}, 8, ["environment", "modelValue"])
|
|
@@ -163,34 +169,34 @@ const j = { class: "flex h-8 items-center justify-end gap-2 border-t" }, Q = { c
|
|
|
163
169
|
_: 1
|
|
164
170
|
})) : f("", !0),
|
|
165
171
|
"x-scalar-secret-username" in n.value && "x-scalar-secret-password" in n.value ? (m(), k(p, { key: 1 }, [
|
|
166
|
-
r(o(
|
|
172
|
+
r(o(i), null, {
|
|
167
173
|
default: l(() => [
|
|
168
174
|
r(c, {
|
|
169
175
|
class: "text-c-2",
|
|
170
176
|
environment: t.environment,
|
|
171
177
|
modelValue: n.value["x-scalar-secret-username"],
|
|
172
178
|
placeholder: "janedoe",
|
|
173
|
-
"onUpdate:modelValue": e[5] || (e[5] = (a) =>
|
|
179
|
+
"onUpdate:modelValue": e[5] || (e[5] = (a) => d({ "x-scalar-secret-username": a }))
|
|
174
180
|
}, {
|
|
175
181
|
default: l(() => [...e[17] || (e[17] = [
|
|
176
|
-
|
|
182
|
+
u(" Username ", -1)
|
|
177
183
|
])]),
|
|
178
184
|
_: 1
|
|
179
185
|
}, 8, ["environment", "modelValue"])
|
|
180
186
|
]),
|
|
181
187
|
_: 1
|
|
182
188
|
}),
|
|
183
|
-
r(o(
|
|
189
|
+
r(o(i), null, {
|
|
184
190
|
default: l(() => [
|
|
185
191
|
r(c, {
|
|
186
192
|
environment: t.environment,
|
|
187
193
|
modelValue: n.value["x-scalar-secret-password"],
|
|
188
194
|
placeholder: "********",
|
|
189
195
|
type: "password",
|
|
190
|
-
"onUpdate:modelValue": e[6] || (e[6] = (a) =>
|
|
196
|
+
"onUpdate:modelValue": e[6] || (e[6] = (a) => d({ "x-scalar-secret-password": a }))
|
|
191
197
|
}, {
|
|
192
198
|
default: l(() => [...e[18] || (e[18] = [
|
|
193
|
-
|
|
199
|
+
u(" Password ", -1)
|
|
194
200
|
])]),
|
|
195
201
|
_: 1
|
|
196
202
|
}, 8, ["environment", "modelValue"])
|
|
@@ -198,59 +204,59 @@ const j = { class: "flex h-8 items-center justify-end gap-2 border-t" }, Q = { c
|
|
|
198
204
|
_: 1
|
|
199
205
|
})
|
|
200
206
|
], 64)) : f("", !0),
|
|
201
|
-
r(o(
|
|
207
|
+
r(o(i), null, {
|
|
202
208
|
default: l(() => [
|
|
203
209
|
r(c, {
|
|
204
210
|
environment: t.environment,
|
|
205
211
|
modelValue: n.value["x-scalar-secret-client-id"],
|
|
206
212
|
placeholder: "12345",
|
|
207
|
-
"onUpdate:modelValue": e[7] || (e[7] = (a) =>
|
|
213
|
+
"onUpdate:modelValue": e[7] || (e[7] = (a) => d({ "x-scalar-secret-client-id": a }))
|
|
208
214
|
}, {
|
|
209
215
|
default: l(() => [...e[19] || (e[19] = [
|
|
210
|
-
|
|
216
|
+
u(" Client ID ", -1)
|
|
211
217
|
])]),
|
|
212
218
|
_: 1
|
|
213
219
|
}, 8, ["environment", "modelValue"])
|
|
214
220
|
]),
|
|
215
221
|
_: 1
|
|
216
222
|
}),
|
|
217
|
-
"x-scalar-secret-client-secret" in n.value ? (m(), v(o(
|
|
223
|
+
"x-scalar-secret-client-secret" in n.value ? (m(), v(o(i), { key: 2 }, {
|
|
218
224
|
default: l(() => [
|
|
219
225
|
r(c, {
|
|
220
226
|
environment: t.environment,
|
|
221
227
|
modelValue: n.value["x-scalar-secret-client-secret"],
|
|
222
228
|
placeholder: "XYZ123",
|
|
223
229
|
type: "password",
|
|
224
|
-
"onUpdate:modelValue": e[8] || (e[8] = (a) =>
|
|
230
|
+
"onUpdate:modelValue": e[8] || (e[8] = (a) => d({ "x-scalar-secret-client-secret": a }))
|
|
225
231
|
}, {
|
|
226
232
|
default: l(() => [...e[20] || (e[20] = [
|
|
227
|
-
|
|
233
|
+
u(" Client Secret ", -1)
|
|
228
234
|
])]),
|
|
229
235
|
_: 1
|
|
230
236
|
}, 8, ["environment", "modelValue"])
|
|
231
237
|
]),
|
|
232
238
|
_: 1
|
|
233
239
|
})) : f("", !0),
|
|
234
|
-
"x-usePkce" in n.value ? (m(), v(o(
|
|
240
|
+
"x-usePkce" in n.value ? (m(), v(o(i), { key: 3 }, {
|
|
235
241
|
default: l(() => [
|
|
236
242
|
r(c, {
|
|
237
243
|
enum: o(L),
|
|
238
244
|
environment: t.environment,
|
|
239
245
|
modelValue: n.value["x-usePkce"],
|
|
240
246
|
readOnly: "",
|
|
241
|
-
"onUpdate:modelValue": e[9] || (e[9] = (a) =>
|
|
247
|
+
"onUpdate:modelValue": e[9] || (e[9] = (a) => y({
|
|
242
248
|
"x-usePkce": a
|
|
243
249
|
}))
|
|
244
250
|
}, {
|
|
245
251
|
default: l(() => [...e[21] || (e[21] = [
|
|
246
|
-
|
|
252
|
+
u(" Use PKCE ", -1)
|
|
247
253
|
])]),
|
|
248
254
|
_: 1
|
|
249
255
|
}, 8, ["enum", "environment", "modelValue"])
|
|
250
256
|
]),
|
|
251
257
|
_: 1
|
|
252
258
|
})) : f("", !0),
|
|
253
|
-
t.type !== "implicit" ? (m(), v(o(
|
|
259
|
+
t.type !== "implicit" ? (m(), v(o(i), { key: 4 }, {
|
|
254
260
|
default: l(() => [
|
|
255
261
|
r(c, {
|
|
256
262
|
enum: ["header", "body"],
|
|
@@ -261,49 +267,49 @@ const j = { class: "flex h-8 items-center justify-end gap-2 border-t" }, Q = { c
|
|
|
261
267
|
"onUpdate:modelValue": e[10] || (e[10] = (a) => h(a))
|
|
262
268
|
}, {
|
|
263
269
|
default: l(() => [...e[22] || (e[22] = [
|
|
264
|
-
|
|
270
|
+
u(" Credentials Location ", -1)
|
|
265
271
|
])]),
|
|
266
272
|
_: 1
|
|
267
273
|
}, 8, ["environment", "modelValue"])
|
|
268
274
|
]),
|
|
269
275
|
_: 1
|
|
270
276
|
})) : f("", !0),
|
|
271
|
-
r(o(
|
|
277
|
+
r(o(i), null, {
|
|
272
278
|
default: l(() => [
|
|
273
279
|
r(E, {
|
|
274
280
|
flow: n.value,
|
|
275
281
|
flowType: t.type,
|
|
276
|
-
selectedScopes:
|
|
282
|
+
selectedScopes: w.value,
|
|
277
283
|
"onUpdate:selectedScopes": e[11] || (e[11] = (a) => g("update:selectedScopes", a))
|
|
278
284
|
}, null, 8, ["flow", "flowType", "selectedScopes"])
|
|
279
285
|
]),
|
|
280
286
|
_: 1
|
|
281
287
|
}),
|
|
282
|
-
r(o(
|
|
288
|
+
r(o(i), { class: "min-w-full" }, {
|
|
283
289
|
default: l(() => [
|
|
284
290
|
S("div", Q, [
|
|
285
291
|
t.scheme.type === "openIdConnect" ? (m(), v(o(V), {
|
|
286
292
|
key: 0,
|
|
287
293
|
class: "mr-1 p-0 px-2 py-0.5",
|
|
288
|
-
loader: o(
|
|
294
|
+
loader: o(x),
|
|
289
295
|
size: "sm",
|
|
290
296
|
variant: "outlined",
|
|
291
|
-
onClick:
|
|
297
|
+
onClick: b
|
|
292
298
|
}, {
|
|
293
299
|
default: l(() => [...e[23] || (e[23] = [
|
|
294
|
-
|
|
300
|
+
u(" Clear ", -1)
|
|
295
301
|
])]),
|
|
296
302
|
_: 1
|
|
297
303
|
}, 8, ["loader"])) : f("", !0),
|
|
298
304
|
r(o(V), {
|
|
299
305
|
class: "mr-0.75 p-0 px-2 py-0.5",
|
|
300
|
-
loader: o(
|
|
306
|
+
loader: o(x),
|
|
301
307
|
size: "sm",
|
|
302
308
|
variant: "outlined",
|
|
303
|
-
onClick:
|
|
309
|
+
onClick: z
|
|
304
310
|
}, {
|
|
305
311
|
default: l(() => [...e[24] || (e[24] = [
|
|
306
|
-
|
|
312
|
+
u(" Authorize ", -1)
|
|
307
313
|
])]),
|
|
308
314
|
_: 1
|
|
309
315
|
}, 8, ["loader"])
|
package/dist/v2/blocks/scalar-auth-selector-block/helpers/extract-security-scheme-secrets.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"extract-security-scheme-secrets.d.ts","sourceRoot":"","sources":["../../../../../src/v2/blocks/scalar-auth-selector-block/helpers/extract-security-scheme-secrets.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,wBAAwB,CAAA;AAC5D,OAAO,KAAK,EAAE,SAAS,EAA2C,MAAM,uCAAuC,CAAA;AAC/G,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,iDAAiD,CAAA;AAOlF,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,8DAA8D,CAAA;AAExG,OAAO,KAAK,EAUV,0BAA0B,EAC3B,MAAM,gBAAgB,CAAA;AAEvB,wGAAwG;AACxG,MAAM,MAAM,gBAAgB,GAAG,oBAAoB,GAAG,WAAW,CAAC,cAAc,CAAC,CAAA;
|
|
1
|
+
{"version":3,"file":"extract-security-scheme-secrets.d.ts","sourceRoot":"","sources":["../../../../../src/v2/blocks/scalar-auth-selector-block/helpers/extract-security-scheme-secrets.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,wBAAwB,CAAA;AAC5D,OAAO,KAAK,EAAE,SAAS,EAA2C,MAAM,uCAAuC,CAAA;AAC/G,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,iDAAiD,CAAA;AAOlF,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,8DAA8D,CAAA;AAExG,OAAO,KAAK,EAUV,0BAA0B,EAC3B,MAAM,gBAAgB,CAAA;AAEvB,wGAAwG;AACxG,MAAM,MAAM,gBAAgB,GAAG,oBAAoB,GAAG,WAAW,CAAC,cAAc,CAAC,CAAA;AAyJjF,6DAA6D;AAC7D,eAAO,MAAM,4BAA4B,GAEvC,QAAQ,oBAAoB,GAAG,WAAW,CAAC,cAAc,CAAC,EAC1D,WAAW,SAAS,EACpB,MAAM,MAAM,EACZ,cAAc,MAAM,KACnB,0BAuDF,CAAA"}
|