fix: user has to login every time chrome sidepanel is opened (#5544)
We can pass the auth tokens to our front app via post message, which will also allow us to pass route names to navigate on it
This commit is contained in:
@ -203,7 +203,9 @@ export class AuthService {
|
||||
this.environmentService.get('NODE_ENV') ===
|
||||
NodeEnvironment.development
|
||||
? authorizeAppInput.redirectUrl
|
||||
: `${this.environmentService.get('CHROME_EXTENSION_REDIRECT_URL')}`,
|
||||
: `https://${this.environmentService.get(
|
||||
'CHROME_EXTENSION_ID',
|
||||
)}.chromiumapp.org/`,
|
||||
},
|
||||
];
|
||||
|
||||
|
||||
@ -96,4 +96,7 @@ export class ClientConfig {
|
||||
|
||||
@Field(() => Captcha)
|
||||
captcha: Captcha;
|
||||
|
||||
@Field(() => String, { nullable: true })
|
||||
chromeExtensionId: string | undefined;
|
||||
}
|
||||
|
||||
@ -48,6 +48,7 @@ export class ClientConfigResolver {
|
||||
provider: this.environmentService.get('CAPTCHA_DRIVER'),
|
||||
siteKey: this.environmentService.get('CAPTCHA_SITE_KEY'),
|
||||
},
|
||||
chromeExtensionId: this.environmentService.get('CHROME_EXTENSION_ID'),
|
||||
};
|
||||
|
||||
return Promise.resolve(clientConfig);
|
||||
|
||||
Reference in New Issue
Block a user