airwallex-payment-elements
Advanced tools
Comparing version 0.0.33 to 0.0.34
@@ -24,5 +24,8 @@ import { css, html, LitElement } from 'lit-element'; | ||
theme: { type: Object, reflect: true }, | ||
height: { type: Number, hasChanged() { | ||
height: { | ||
type: Number, | ||
hasChanged() { | ||
return true; | ||
} } | ||
} | ||
} | ||
}; | ||
@@ -39,2 +42,3 @@ } | ||
handleEvent(data) { | ||
console.info(`Airwallex Checkout Message: [${JSON.stringify(data)}]`); | ||
const event = new CustomEvent('airwallex-checkout', { | ||
@@ -49,5 +53,4 @@ detail: data, | ||
if (event.origin === this.gatewayBaseurl && event.isTrusted) { | ||
console.info(`Airwallex Checkout Message: [${JSON.stringify(event.data)}]`); | ||
const { style, ...rest } = event.data; | ||
this.height = style && style.height || 0; | ||
this.height = (style && style.height) || 0; | ||
if (event.data.code !== 'AWX_CHECKOUT_STYLE') { | ||
@@ -54,0 +57,0 @@ this.handleEvent(rest); |
{ | ||
"name": "airwallex-payment-elements", | ||
"version": "0.0.33", | ||
"version": "0.0.34", | ||
"main": "dist/index.js", | ||
@@ -5,0 +5,0 @@ "module": "dist/index.js", |
@@ -22,3 +22,4 @@ import { css, html, LitElement } from 'lit-element'; | ||
this.currency = this.intentId = this.customerId = this.successUrl = this.cancelUrl = this.errorUrl = ''; | ||
this.theme = {}; this.height = 0; | ||
this.theme = {}; | ||
this.height = 0; | ||
} | ||
@@ -38,5 +39,8 @@ static get properties() { | ||
theme: { type: Object, reflect: true }, | ||
height: { type: Number, hasChanged() { | ||
return true; | ||
}} | ||
height: { | ||
type: Number, | ||
hasChanged() { | ||
return true; | ||
} | ||
} | ||
}; | ||
@@ -53,2 +57,3 @@ } | ||
handleEvent(data) { | ||
console.info(`Airwallex Checkout Message: [${JSON.stringify(data)}]`); | ||
const event = new CustomEvent('airwallex-checkout', { | ||
@@ -63,7 +68,6 @@ detail: data, | ||
if (event.origin === this.gatewayBaseurl && event.isTrusted) { | ||
console.info(`Airwallex Checkout Message: [${JSON.stringify(event.data)}]`); | ||
const { style, ...rest } = event.data; | ||
this.height = style && style.height || 0; | ||
this.height = (style && style.height) || 0; | ||
if (event.data.code !== 'AWX_CHECKOUT_STYLE') { | ||
this.handleEvent(rest); | ||
this.handleEvent(rest); | ||
} | ||
@@ -70,0 +74,0 @@ if (event.data.code === 'AWX_CHECKOUT_SUCCESS') { |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
2852595
3130