-
Notifications
You must be signed in to change notification settings - Fork 2.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
❗Sign in with Apple - Button Not Respond after Closing Native Popup #14198
Comments
Hi @buildappsmart thanks for reporting this issue and providing detailed triaging information. We will investigate. |
Update: This issue is reproducible on my end. The cause is that the Amplify JS library currently cannot detect the events triggered by the native Sign in with Apple bottom sheet. We will need to investigate whether there is a viable solution for this use case. Update2: Apple doesn't seem to provide a way to detect the cancellation of the native sign in with Apple bottom sheet. Update3: Brought this up to the Amazon Cognito service and waiting for response... |
Hi @buildappsmart, sorry about the delayed response. This issue seems to be caused by a gap on Apple's end that when cancelling the native SIWA bottom sheet, the system doesn't send any information to the Cognito Hosted UI endpoint, nor to the Web app which invokes it. This caused the library not to be able to detect anything and react. Currently the only workaround is to refresh the page which clears the stuck sign-in process, so |
Thanks @HuiSF for looking into this. I tried other cloud providers like Supabase auth, they don't have this issue and they are using Sign in with Apple REST API |
Understood @buildappsmart, currently the Sign in with Apple feature in Amplify JS is based on Amazon Cognito Hosted UI. The library doesn't directly communicate with Apple service. We will look into this. As this is an unsupported use case for whatever reason, I will mark this as a feature request for following up. |
Same issue here, it should be labeled as bug rather than feature-request |
Hi @samswitz sorry for the inconvenience, Amazon Cognito Hosted UI and Amplify JS cannot handle this use cases due to the feature gap that exists on Apple's side, we will need to look into other solutions to cover this use case. |
Before opening, please confirm:
JavaScript Framework
Next.js
Amplify APIs
Authentication
Amplify Version
v6
Amplify Categories
auth
Backend
Amplify Gen 2
Environment information
Describe the bug
Click the HTML button to sign In with apple, after closing the native popup, the button will no longer respond.
This issue occurs on an iPhone's web browser (e.g., Safari) where a native popup appears instead of redirecting to Apple account Sign In web page.
amplify.mp4
Expected behavior
Click the button to sign In with apple, after closing the native popup, the button should still function.
Reproduction steps
auth.mysite.com
aws-amplify
and@aws-amplify/adapter-nextjs
signInWithRedirect({ provider: 'Apple' })
npm run dev
http://localhost:3000/login
on iPhone web browser (eg. Safari), or deploy your website to production and visithttps://www.mysite.com/login
Code Snippet
app/login/page.tsx
components/AmplifyConfigureClient.tsx
app/layout.tsx
Log output
aws-exports.js
No response
Manual configuration
Additional configuration
No response
Mobile Device
No response
Mobile Operating System
No response
Mobile Browser
No response
Mobile Browser Version
No response
Additional information and screenshots
No response
The text was updated successfully, but these errors were encountered: