Fixing callback URLs.
This commit is contained in:
parent
7afce332c8
commit
e98965a805
|
@ -29,30 +29,23 @@
|
||||||
const ConfigTypes = {
|
const ConfigTypes = {
|
||||||
Google: "google",
|
Google: "google",
|
||||||
OIDC: "oidc",
|
OIDC: "oidc",
|
||||||
// Github: "github",
|
|
||||||
// AzureAD: "ad",
|
|
||||||
}
|
}
|
||||||
|
|
||||||
const GoogleConfigFields = {
|
$: GoogleConfigFields = {
|
||||||
Google: ["clientID", "clientSecret", "callbackURL"],
|
Google: [
|
||||||
}
|
{name: "clientID", label: "Client ID"},
|
||||||
const GoogleConfigLabels = {
|
{name: "clientSecret", label: "Client secret"},
|
||||||
Google: {
|
{name: "callbackURL", label: "Callback URL", readonly: true, placeholder: `/api/admin/auth/${tenantId}/google/callback`},
|
||||||
clientID: "Client ID",
|
],
|
||||||
clientSecret: "Client secret",
|
|
||||||
callbackURL: "Callback URL",
|
|
||||||
},
|
|
||||||
}
|
}
|
||||||
|
|
||||||
const OIDCConfigFields = {
|
$: OIDCConfigFields = {
|
||||||
Oidc: ["configUrl", "clientID", "clientSecret"],
|
Oidc: [
|
||||||
}
|
{name: "configUrl", label: "Config URL"},
|
||||||
const OIDCConfigLabels = {
|
{name: "clientID", label: "Client ID"},
|
||||||
Oidc: {
|
{name: "clientSecret", label: "Client Secret"},
|
||||||
configUrl: "Config URL",
|
{name: "callbackURL", label: "Callback URL", readonly: true, placeholder: `/api/admin/auth/${tenantId}/oidc/callback`},
|
||||||
clientID: "Client ID",
|
],
|
||||||
clientSecret: "Client Secret",
|
|
||||||
},
|
|
||||||
}
|
}
|
||||||
|
|
||||||
let iconDropdownOptions = [
|
let iconDropdownOptions = [
|
||||||
|
@ -292,8 +285,8 @@
|
||||||
<Layout gap="XS" noPadding>
|
<Layout gap="XS" noPadding>
|
||||||
{#each GoogleConfigFields.Google as field}
|
{#each GoogleConfigFields.Google as field}
|
||||||
<div class="form-row">
|
<div class="form-row">
|
||||||
<Label size="L">{GoogleConfigLabels.Google[field]}</Label>
|
<Label size="L">{field.label}</Label>
|
||||||
<Input bind:value={providers.google.config[field]} />
|
<Input bind:value={providers.google.config[field.name]} readonly={field.readonly} placeholder={field.placeholder} />
|
||||||
</div>
|
</div>
|
||||||
{/each}
|
{/each}
|
||||||
<div class="form-row">
|
<div class="form-row">
|
||||||
|
@ -332,14 +325,10 @@
|
||||||
<Layout gap="XS" noPadding>
|
<Layout gap="XS" noPadding>
|
||||||
{#each OIDCConfigFields.Oidc as field}
|
{#each OIDCConfigFields.Oidc as field}
|
||||||
<div class="form-row">
|
<div class="form-row">
|
||||||
<Label size="L">{OIDCConfigLabels.Oidc[field]}</Label>
|
<Label size="L">{field.label}</Label>
|
||||||
<Input bind:value={providers.oidc.config.configs[0][field]} />
|
<Input bind:value={providers.oidc.config.configs[0][field.name]} readonly={field.readonly} placeholder={field.placeholder} />
|
||||||
</div>
|
</div>
|
||||||
{/each}
|
{/each}
|
||||||
<div class="form-row">
|
|
||||||
<Label size="L">Callback URL</Label>
|
|
||||||
<Input readonly placeholder={`/api/admin/auth/${tenantId}/oidc/callback`} />
|
|
||||||
</div>
|
|
||||||
<br />
|
<br />
|
||||||
<Body size="S">
|
<Body size="S">
|
||||||
To customize your login button, fill out the fields below.
|
To customize your login button, fill out the fields below.
|
||||||
|
|
Loading…
Reference in New Issue