Native Payments Sheet Scroll View and Keyboard Error
PayPal SDK Version
Latest
Environment
Sandbox
Xcode Version
Xcode 15.2
OS Version & Device
iPhone 15 - iOS 16.4
Integration type
Swfit Package Manager
Development Processor
Intel
Describe the bug
When scrolling down on the native payments sheet, the scroll view gets messed up after the keyboard goes away. Please see my reproducing steps for more details.
To reproduce
- Launch Native Payments with no client ID in sandbox. This could be on the simulator or an actual device. I used the iPhone 15.
- Pay with Debit or Credit Card as guest
- Use software keyboard (iPhone keyboard instead of physical computer keyboard)
- Enter a few numbers in the credit card number, then click off of the form by clicking an empty space in the form. This should make your keyboard go away.
- Now, at the bottom of the screen you should see a bunch of white space left behind by the keyboard disappearing.
- You can scroll down on the white space and keep scrolling down, but you won't actual scroll down on the checkout form. You can kinda see two vertical scroll indicators here.
- To fix it, you have to scroll all the way up then you can scroll down with no issues.
Expected behavior
I want the keyboard to go away and for there to not be any extra white space at the bottom of the payment sheet. It should just be the other form fields. This way, if I scroll down, I can actually see the rest of the form.
Screenshots
Hey @rlomeli158
Are you able to provide a video of you reproducing the issue? Also are you using any libraries for keyboard management such as IQKeyboardManager?
Sure here you go! I am not using any custom libraries.
https://github.com/paypal/paypal-ios/assets/55671239/fe47fc0b-0065-4292-b969-60802f22161f
Hi @rlomeli158 - is this issue happening only on a simulator and not on real devices?
That video was from a real device, so it happens on both!