From 4641c09b5db4656e3548ed1f499a35585771e2c4 Mon Sep 17 00:00:00 2001 From: Marco Crapts Date: Thu, 8 Jun 2023 23:16:46 +0200 Subject: [PATCH] disable GH and MS auth - not working native --- src/components/Auth.vue | 36 ++++++++++++++++++++---------------- 1 file changed, 20 insertions(+), 16 deletions(-) diff --git a/src/components/Auth.vue b/src/components/Auth.vue index 851ef34..e487d05 100644 --- a/src/components/Auth.vue +++ b/src/components/Auth.vue @@ -69,24 +69,28 @@ const providers: Provider[] = [ // mode: 'redirect' // }) // const provider = new OAuthProvider('microsoft.com') - // // const credential = provider.credential({ - // // idToken: result.credential?.idToken, - // // rawNonce: result.credential?.nonce - // // }) - // if (result.credential) { - // const credential = provider.credential(result.credential) - // console.log(credential) - // try { - // const user = await signInWithCredential(auth, credential) - // console.log('user', user) - // } catch (error: any) { - // console.log(error) - // console.log('message', error.message) - // } - // } + // const credential = provider.credential({ + // idToken: result.credential?.idToken, + // rawNonce: result.credential?.nonce + // }) + // await signInWithCredential(auth, credential) + // } + // }, + // { + // name: 'github', + // icon: 'fa-brands fa-github', + // signin: async () => { + // const result = await FirebaseAuthentication.signInWithGithub({ + // mode: 'redirect' + // }) + // const provider = new OAuthProvider('github.com') + // const credential = provider.credential({ + // idToken: result.credential?.idToken, + // rawNonce: result.credential?.nonce + // }) + // await signInWithCredential(auth, credential) // } // } - // Microsoft users can't be signed in manually so this does not work on native ] // type Provider = (typeof providers)[number] const signInWithProvider = async (provider: Provider) => {