@cshah18/sdk 4.4.0 → 4.6.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/cobuy-sdk.esm.js
CHANGED
|
@@ -2341,7 +2341,7 @@ class LobbyModal {
|
|
|
2341
2341
|
const buttons = Array.from(document.querySelectorAll(".cobuy-button"));
|
|
2342
2342
|
const target = buttons.find((btn) => {
|
|
2343
2343
|
const text = (btn.textContent || "").trim().toLowerCase();
|
|
2344
|
-
return text.includes("continue to checkout") || text === "checkout" || text.includes("checkout");
|
|
2344
|
+
return (text.includes("continue to checkout") || text === "checkout" || text.includes("checkout"));
|
|
2345
2345
|
});
|
|
2346
2346
|
if (!target) {
|
|
2347
2347
|
this.logger.warn("[LobbyModal] Could not find a checkout button to trigger");
|
|
@@ -5658,6 +5658,8 @@ class ApiClient {
|
|
|
5658
5658
|
payload.currency = data.currency;
|
|
5659
5659
|
if (data.payment_method)
|
|
5660
5660
|
payload.payment_method = data.payment_method;
|
|
5661
|
+
if (data.micrositeCheckout !== undefined)
|
|
5662
|
+
payload.micrositeCheckout = data.micrositeCheckout;
|
|
5661
5663
|
if (data.metadata)
|
|
5662
5664
|
payload.metadata = data.metadata;
|
|
5663
5665
|
}
|
|
@@ -5698,7 +5700,6 @@ class AnalyticsClient {
|
|
|
5698
5700
|
event: "CTA_CLICKED",
|
|
5699
5701
|
productId,
|
|
5700
5702
|
timestamp: new Date().toISOString(),
|
|
5701
|
-
sessionId: this.sessionId,
|
|
5702
5703
|
context: {
|
|
5703
5704
|
pageUrl: typeof window !== "undefined" ? window.location.href : undefined,
|
|
5704
5705
|
userAgent: typeof navigator !== "undefined" ? navigator.userAgent : undefined,
|