Auto generate callback url and supply id on login
This commit is contained in:
parent
3152bd1839
commit
6f1d995cc8
|
@ -26,7 +26,9 @@
|
|||
</script>
|
||||
|
||||
{#if show}
|
||||
<ActionButton on:click={() => window.open("/api/admin/auth/oidc/", "_blank")}>
|
||||
<ActionButton
|
||||
on:click={() => window.open(`/api/admin/auth/oidc/${$oidc.uuid}`, "_blank")}
|
||||
>
|
||||
<div class="inner">
|
||||
<img {src} alt="oidc icon" />
|
||||
<p>{`Sign in with ${$oidc.name || "OIDC"}`}</p>
|
||||
|
|
|
@ -75,9 +75,13 @@
|
|||
providers.google?.config.clientSecret &&
|
||||
providers.google?.config.callbackURL
|
||||
$: oidcComplete =
|
||||
providers.oidc?.config.configs[0].configUrl &&
|
||||
providers.oidc?.config.configs[0].clientID &&
|
||||
providers.oidc?.config.configs[0].clientSecret
|
||||
providers.oidc?.config?.configs[0].configUrl &&
|
||||
providers.oidc?.config?.configs[0].clientID &&
|
||||
providers.oidc?.config?.configs[0].clientSecret
|
||||
|
||||
$: oidcCallback = providers.oidc?.config.configs[0].uuid
|
||||
? `/api/admin/auth/oidc/callback/${providers.oidc?.config.configs[0].uuid}`
|
||||
: ""
|
||||
|
||||
async function uploadLogo(file) {
|
||||
let data = new FormData()
|
||||
|
@ -234,6 +238,10 @@
|
|||
<Input bind:value={providers.oidc.config.configs[0][field]} />
|
||||
</div>
|
||||
{/each}
|
||||
<div class="form-row">
|
||||
<Label size="L">Callback URL</Label>
|
||||
<Input readonly bind:value={oidcCallback} />
|
||||
</div>
|
||||
<br />
|
||||
<Body size="S">
|
||||
To customize your login button, fill out the fields below.
|
||||
|
|
Loading…
Reference in New Issue