mirror of
https://github.com/woocommerce/woocommerce-paypal-payments.git
synced 2025-09-08 21:52:55 +08:00
Add ApplePay preview support on non ios devices
Fix clicking on preview ApplePay / GooglePay buttons
This commit is contained in:
parent
813af819dd
commit
1b87bc3da1
3 changed files with 23 additions and 1 deletions
|
@ -52,5 +52,17 @@
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.wp-admin {
|
||||||
|
.ppcp-button-applepay {
|
||||||
|
pointer-events: none;
|
||||||
|
}
|
||||||
|
&.ppcp-non-ios-device {
|
||||||
|
.ppcp-button-applepay {
|
||||||
|
apple-pay-button {
|
||||||
|
display: block;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -99,6 +99,10 @@ import widgetBuilder from "../../../ppcp-button/resources/js/modules/Renderer/Wi
|
||||||
while (options = buttonQueue.pop()) {
|
while (options = buttonQueue.pop()) {
|
||||||
createButton(options.ppcpConfig);
|
createButton(options.ppcpConfig);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (!window.ApplePaySession) {
|
||||||
|
jQuery('body').addClass('ppcp-non-ios-device')
|
||||||
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
document.addEventListener(
|
document.addEventListener(
|
||||||
|
|
|
@ -44,3 +44,9 @@
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.wp-admin {
|
||||||
|
.ppcp-button-googlepay {
|
||||||
|
pointer-events: none;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue