-
Notifications
You must be signed in to change notification settings - Fork 14
#8681 add checkout.paymentMethodChangeStart
#398
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
#8681 add checkout.paymentMethodChangeStart
#398
Conversation
checkout.paymentMethodChangeStart
…-8681-checkout.paymentmethodchangestart2
c58840e to
d9a3354
Compare
…-8681-checkout.paymentmethodchangestart2
|
|
||
| package com.shopify.reactnative.checkoutsheetkit; | ||
|
|
||
| public enum CheckoutEventType { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ran into an error where the eventName was being passed wrong and getting mixed up between the prop onPaymentMethodStartChange versus event.type checkout.paymentMethodChangeStart so decided to unify here, comment above says as much but this gives an auto register pattern for the events
fcd5faf to
c19e9e6
Compare
| try { | ||
| CheckoutPaymentMethodChangeStartParams params = event.getParams(); | ||
|
|
||
| Map<String, Object> eventData = new HashMap<>(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this bits a tad repetitive between the inline/sheet event processors - will perform a follow up to have a factory class for event construction
| const handleError = useCallback< | ||
| Required<NativeCheckoutWebViewProps>['onError'] | ||
| >( | ||
| (event: {nativeEvent: CheckoutException}) => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These types on event: {nativeEvent} were duplicative in the end because we already pass the generic into useCallback so was able to remove them
c19e9e6 to
500215d
Compare
…-8681-checkout.paymentmethodchangestart2
...roid/src/main/java/com/shopify/reactnative/checkoutsheetkit/SheetCheckoutEventProcessor.java
Outdated
Show resolved
Hide resolved
...roid/src/main/java/com/shopify/reactnative/checkoutsheetkit/SheetCheckoutEventProcessor.java
Show resolved
Hide resolved
e45705f to
45c5e91
Compare
What changes are you making?
Implements
checkout.paymentMethodChangeStartevent from the native libraries:https://github.com/Shopify/checkout-sheet-kit-swift/pull/475/files
https://github.com/Shopify/checkout-sheet-kit-android/pull/425/files
Screen.Recording.2025-12-01.at.13.46.20.mov
PR Checklist
Important
Releasing a new version of the kit?
package.jsonfile.Tip
See the Contributing documentation for instructions on how to publish a new version of the library.