From af9739d80596bbe1505bf268abf308e279dad269 Mon Sep 17 00:00:00 2001 From: TidusJar Date: Sun, 19 Aug 2018 20:28:26 +0100 Subject: [PATCH] Made the popup a bit better !wip --- src/Ombi/ClientApp/app/login/login.component.ts | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/src/Ombi/ClientApp/app/login/login.component.ts b/src/Ombi/ClientApp/app/login/login.component.ts index 2c5a52404..abf387fa1 100644 --- a/src/Ombi/ClientApp/app/login/login.component.ts +++ b/src/Ombi/ClientApp/app/login/login.component.ts @@ -116,6 +116,7 @@ export class LoginComponent implements OnDestroy, OnInit { localStorage.setItem("id_token", x.access_token); if (this.authService.loggedIn()) { + this.ngOnDestroy(); this.router.navigate(["search"]); } else { this.notify.error(this.errorBody); @@ -130,8 +131,17 @@ export class LoginComponent implements OnDestroy, OnInit { this.authService.login({ usePlexOAuth: true, password: "", rememberMe: true, username: "", plexTvPin: pin }).subscribe(x => { - window.open(x.url, "_blank"); + window.open(x.url, "_blank", `toolbar=0, + location=0, + status=0, + menubar=0, + scrollbars=1, + resizable=1, + width=500, + height=500`); + this.pinTimer = setInterval(() => { + this.notify.info("Authenticating", "Loading... Please Wait"); this.getPinResult(x.pinId); }, 10000); }); @@ -144,6 +154,7 @@ export class LoginComponent implements OnDestroy, OnInit { localStorage.setItem("id_token", x.access_token); if (this.authService.loggedIn()) { + this.ngOnDestroy(); this.router.navigate(["search"]); return; }