google-pay / google-pay-button

Google Pay button - React, Angular, and custom element
Apache License 2.0
250 stars 60 forks source link

Button not appearing in Firefox and Safari #199

Closed wislert closed 1 year ago

wislert commented 1 year ago

Describe the bug: Button not appearing in Firefox/Safari

To Reproduce: Open the page with GPay Button

Expected behavior: Button works in all browsers

Screenshots Firefox:

firefox

Safari:

safari

Chrome:

chrome

Component information:

Environment:

dmengelt commented 1 year ago

@wislert thanks for reporting this. are you able to reproduce the issue here: https://stackblitz.com/edit/google-pay-react-ecbhkg?file=src%2FApp.js

thanks for a quick feedback

wislert commented 1 year ago

When I removed the property existingPaymentMethodRequired this problem was gone.

dmengelt commented 1 year ago

Thanks for reporting back. If you specify existingPaymentMethodRequired=true the result and paymentMethodPresent properties of the IsReadyToPayResponse must return true in order for the button to show up. This only affects the PRODUCTION environment.

See the details here: https://github.com/google-pay/google-pay-button/blob/main/src/lib/button-manager.ts#L260

dmengelt commented 1 year ago

@wislert Does it work as expected for you now? If not, is there a way for me to reach your site? If this is not possible please share your full Google Pay Button config here. (specifically existingPaymentMethodRequired and allowedPaymentMethods)

dmengelt commented 1 year ago

Closing due to no feedback