-
Notifications
You must be signed in to change notification settings - Fork 8
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
Render the express payment button in the editor #215
Comments
@alexflorisca this is difficult to implement with the Square extension, the main problem being the editor loading inside an iframe. We provide an HTML container (DIV, SPAN) which Square uses to inject the buttons, but before that it checks for As a workaround, I tried loading the Square Web API inside the iframe and did a override such as:
which fixed this problem. The second check the Square Web API performs is the Do you know of any similar cases with other gateways that were resolved? |
Could you use |
@alexflorisca that check is done by Square's 3rd party script so we can't modify that part. |
Is it worth reaching out to Square to see if they are able to accommodate this situation and change their script to check for |
I have raised the following issue: square/web-payments-quickstart#244 cc: @vikrampm1 / @jeffpaul it would be helpful if you can escalate the issue above. Thanks! |
Ok great thanks. I see they are moving away from checking winow.location anyway, hopefully we can get an estimate of when that would be release and when we can move this forward 🤞 |
Just checked with the Square team and square/web-payments-quickstart#244 won't be ready until Q1 next year. |
Ok /cc'ing @opr for context. This is blocking the Square extension from rendering the buttons in the editor |
Thanks @alexflorisca - does this impact anything we're trying to ship, or is it just a case of Square not rendering correctly in the editor and the experience not being 100% complete for merchants using it? |
This impact payment plugin compatibility with the new express checkout style controls. Square won't be compatible untill the buttons can be rendered in the editor. |
Currently, two preview images of both the Apple Pay and Google Pay buttons are being rendered in the editor. The first issue here is that only one of these should be rendered per slot, otherwise it breaks the grid layout (see screenshot)
The first 2 images of Apple Pay and Google Pay in the top left come from the Square extension.
With new changes about to be introduced in Core in woocommerce/woocommerce#50791, we are asking payment extensions to render the actual buttons in the editor instead of a preview. This has several benefits:
This will involve:
registerExpressPaymentMethod
, passing the same component to theedit
property as thecontent
property.Please reach out if you need any help
The text was updated successfully, but these errors were encountered: