cleanup modal

This commit is contained in:
Jacob Overgaard
2024-04-23 14:56:03 +02:00
parent 9e71db69ff
commit b2a7234248

View File

@@ -32,14 +32,6 @@ export class UmbAppAuthModalElement extends UmbModalBaseElement<UmbModalAppAuthC
);
}
constructor() {
super();
this.consumeContext(UMB_AUTH_CONTEXT, (context) => {
this.observe(context.authorizationSignal, () => {}, '_authorizationSignal');
});
}
render() {
return html`
<umb-body-layout id="login-layout">
@@ -60,7 +52,7 @@ export class UmbAppAuthModalElement extends UmbModalBaseElement<UmbModalAppAuthC
private onSubmit = async (providerName: string) => {
const authContext = await this.getContext(UMB_AUTH_CONTEXT);
await authContext.makeAuthorizationRequest(providerName);
console.log('[AuthModal] Received authorization signal');
const isAuthed = authContext.getIsAuthorized();
this.value = { success: isAuthed };
if (isAuthed) {