Remove setbuttonElementStyles google pay
This commit is contained in:
parent
6b534cc3b2
commit
f11354c60c
|
@ -13,7 +13,7 @@ export default Component.extend({
|
|||
console.log("GooglePay is unvailable")
|
||||
}
|
||||
});
|
||||
this.setbuttonElementStyles();
|
||||
|
||||
this.paymentRequest.on("paymentMethod", async (e) => {
|
||||
// create a payment intent on the server
|
||||
// confirm the payment on the client
|
||||
|
@ -21,22 +21,5 @@ export default Component.extend({
|
|||
});
|
||||
},
|
||||
|
||||
setbuttonElementStyles() {
|
||||
const root = document.querySelector(":root");
|
||||
const computedStyle = getComputedStyle(root);
|
||||
const primaryColor = computedStyle.getPropertyValue("--primary");
|
||||
const placeholderColor =
|
||||
computedStyle.getPropertyValue("--secondary-medium");
|
||||
this.buttonElement.update({
|
||||
style: {
|
||||
base: {
|
||||
color: primaryColor,
|
||||
"::placeholder": {
|
||||
color: placeholderColor,
|
||||
},
|
||||
},
|
||||
},
|
||||
});
|
||||
},
|
||||
didDestroyElement() {},
|
||||
});
|
||||
|
|
Loading…
Reference in New Issue