angularauthenticationgoogle-chromegoogle-one-tapsocial-authentication

Angular SocialAuthService google. How to close google tap (credential_picker_container)?


I use angular 14. Before updating I have used angular 13 with @abacritt/angularx-social-login 1.1.0, now It has been updated to ^1.2.5 and appeared one tap google auth iframe. I do auth with my own service and when client authed, we are moving to dashboard, but google tap iframe leaves on the page. I want to close it when I make auth with my own service. How to close (or disable) this? (angular 14, @abacritt/angularx-social-login ^1.2.5)


Solution

  • in your app.module.ts:

    {
      provide: 'SocialAuthServiceConfig',
      useValue: {
        autoLogin: false,
        providers: [
          {
            id: GoogleLoginProvider.PROVIDER_ID,
            provider: new GoogleLoginProvider('google-id', {
              oneTapEnabled: false
            }),
          },
        ],
      } as SocialAuthServiceConfig,