@crediball/elements 0.12.0 → 0.13.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.
|
@@ -452,8 +452,8 @@ var CrediballPaywallElement = class extends CrediballElement {
|
|
|
452
452
|
const title = this.getAttribute("title") ?? uiContent?.paywallTitle ?? "You need more credits to continue.";
|
|
453
453
|
const description = this.getAttribute("description") ?? uiContent?.paywallDescription ?? "Top up to keep using this feature.";
|
|
454
454
|
const addButtonText = uiContent?.paywallButtonText ?? "Add";
|
|
455
|
-
const amountsAttr = this.getAttribute("amounts");
|
|
456
|
-
const legacyAmounts = amountsAttr ? amountsAttr.split(",").map((s) => Number(s.trim())).filter((n) => Number.isFinite(n)) : [5, 10];
|
|
455
|
+
const amountsAttr = this.client ? null : this.getAttribute("amounts");
|
|
456
|
+
const legacyAmounts = amountsAttr ? amountsAttr.split(",").map((s) => Number(s.trim())).filter((n) => Number.isFinite(n)) : this.client ? [] : [5, 10];
|
|
457
457
|
const packages = pkgs?.packages ?? [];
|
|
458
458
|
const plans = pkgs?.activeSubscription ? [] : pkgs?.subscriptionPlans ?? [];
|
|
459
459
|
const custom = pkgs?.customTopup;
|
|
@@ -886,8 +886,8 @@ var Crediball = (() => {
|
|
|
886
886
|
const title = this.getAttribute("title") ?? uiContent?.paywallTitle ?? "You need more credits to continue.";
|
|
887
887
|
const description = this.getAttribute("description") ?? uiContent?.paywallDescription ?? "Top up to keep using this feature.";
|
|
888
888
|
const addButtonText = uiContent?.paywallButtonText ?? "Add";
|
|
889
|
-
const amountsAttr = this.getAttribute("amounts");
|
|
890
|
-
const legacyAmounts = amountsAttr ? amountsAttr.split(",").map((s) => Number(s.trim())).filter((n) => Number.isFinite(n)) : [5, 10];
|
|
889
|
+
const amountsAttr = this.client ? null : this.getAttribute("amounts");
|
|
890
|
+
const legacyAmounts = amountsAttr ? amountsAttr.split(",").map((s) => Number(s.trim())).filter((n) => Number.isFinite(n)) : this.client ? [] : [5, 10];
|
|
891
891
|
const packages = pkgs?.packages ?? [];
|
|
892
892
|
const plans = pkgs?.activeSubscription ? [] : pkgs?.subscriptionPlans ?? [];
|
|
893
893
|
const custom = pkgs?.customTopup;
|
package/dist/index.js
CHANGED
package/dist/register.js
CHANGED
package/package.json
CHANGED