@rebilly/instruments 8.12.0 → 8.12.1
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/CHANGELOG.md +2 -0
- package/dist/index.js +18 -19
- package/dist/index.min.js +7 -7
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
package/dist/index.js
CHANGED
|
@@ -10612,7 +10612,7 @@ class PlanPricingBracketModel {
|
|
|
10612
10612
|
this.price = parsePrice(price);
|
|
10613
10613
|
}
|
|
10614
10614
|
}
|
|
10615
|
-
const _PlanPricingModel = class
|
|
10615
|
+
const _PlanPricingModel = class _PlanPricingModel2 {
|
|
10616
10616
|
// {
|
|
10617
10617
|
// formula = PlanPricingModel.Formulas.fixedFee,
|
|
10618
10618
|
// price = 0,
|
|
@@ -10620,11 +10620,11 @@ const _PlanPricingModel = class _PlanPricingModel {
|
|
|
10620
10620
|
// brackets = [],
|
|
10621
10621
|
// }
|
|
10622
10622
|
constructor(data = {}) {
|
|
10623
|
-
this.formula = data.formula ??
|
|
10623
|
+
this.formula = data.formula ?? _PlanPricingModel2.Formulas.fixedFee;
|
|
10624
10624
|
switch (data.formula) {
|
|
10625
|
-
case
|
|
10626
|
-
case
|
|
10627
|
-
case
|
|
10625
|
+
case _PlanPricingModel2.Formulas.stairstep:
|
|
10626
|
+
case _PlanPricingModel2.Formulas.tiered:
|
|
10627
|
+
case _PlanPricingModel2.Formulas.volume:
|
|
10628
10628
|
if (data.brackets == null) {
|
|
10629
10629
|
throw new Error("Invalid brackets.");
|
|
10630
10630
|
}
|
|
@@ -10632,23 +10632,23 @@ const _PlanPricingModel = class _PlanPricingModel {
|
|
|
10632
10632
|
(bracket) => new PlanPricingBracketModel(bracket)
|
|
10633
10633
|
);
|
|
10634
10634
|
break;
|
|
10635
|
-
case
|
|
10635
|
+
case _PlanPricingModel2.Formulas.flatRate:
|
|
10636
10636
|
this.price = parsePrice(data.price) ?? 0;
|
|
10637
10637
|
this.maxQuantity = data.maxQuantity ?? null;
|
|
10638
10638
|
break;
|
|
10639
|
-
case
|
|
10639
|
+
case _PlanPricingModel2.Formulas.fixedFee:
|
|
10640
10640
|
default:
|
|
10641
10641
|
this.price = parsePrice(data.price) ?? 0;
|
|
10642
10642
|
break;
|
|
10643
10643
|
}
|
|
10644
10644
|
}
|
|
10645
10645
|
get isSimple() {
|
|
10646
|
-
return Object.values(
|
|
10646
|
+
return Object.values(_PlanPricingModel2.SimpleFormulas).includes(
|
|
10647
10647
|
this.formula
|
|
10648
10648
|
);
|
|
10649
10649
|
}
|
|
10650
10650
|
get isBracket() {
|
|
10651
|
-
return Object.values(
|
|
10651
|
+
return Object.values(_PlanPricingModel2.BracketFormulas).includes(
|
|
10652
10652
|
this.formula
|
|
10653
10653
|
);
|
|
10654
10654
|
}
|
|
@@ -13926,7 +13926,7 @@ class PaymentMetadataModel extends BaseModel {
|
|
|
13926
13926
|
return this.landscapeLogo || this.portraitLogo;
|
|
13927
13927
|
}
|
|
13928
13928
|
}
|
|
13929
|
-
|
|
13929
|
+
class ReadyToPayFeatureModel {
|
|
13930
13930
|
constructor({
|
|
13931
13931
|
name = "",
|
|
13932
13932
|
expirationTime = "",
|
|
@@ -13954,13 +13954,12 @@ const _ReadyToPayFeatureModel = class _ReadyToPayFeatureModel {
|
|
|
13954
13954
|
this.paypalClientId = paypalClientId;
|
|
13955
13955
|
this.linkToken = linkToken;
|
|
13956
13956
|
}
|
|
13957
|
-
}
|
|
13958
|
-
|
|
13957
|
+
}
|
|
13958
|
+
ReadyToPayFeatureModel.FeatureName = {
|
|
13959
13959
|
paypalBillingAgreement: "PayPal billing agreement",
|
|
13960
13960
|
googlePay: "Google Pay",
|
|
13961
13961
|
applePay: "Apple Pay"
|
|
13962
13962
|
};
|
|
13963
|
-
let ReadyToPayFeatureModel = _ReadyToPayFeatureModel;
|
|
13964
13963
|
class ReadyToPayModel {
|
|
13965
13964
|
constructor({
|
|
13966
13965
|
index: index2 = null,
|
|
@@ -14131,9 +14130,9 @@ async function fetchReadyToPayout() {
|
|
|
14131
14130
|
return filterReadyToPayout(readyToPayout);
|
|
14132
14131
|
});
|
|
14133
14132
|
}
|
|
14134
|
-
const _InvoiceModel = class
|
|
14133
|
+
const _InvoiceModel = class _InvoiceModel2 extends BaseModel {
|
|
14135
14134
|
get isPaid() {
|
|
14136
|
-
return this.status ===
|
|
14135
|
+
return this.status === _InvoiceModel2.Status.paid;
|
|
14137
14136
|
}
|
|
14138
14137
|
};
|
|
14139
14138
|
_InvoiceModel.Status = {
|
|
@@ -23289,7 +23288,7 @@ function handleComputedProperty(options) {
|
|
|
23289
23288
|
var _a;
|
|
23290
23289
|
return Object.assign({}, options, {
|
|
23291
23290
|
_computed: {
|
|
23292
|
-
version: "8.
|
|
23291
|
+
version: "8.12.0",
|
|
23293
23292
|
paymentMethodsUrl: ((_a = options._dev) == null ? void 0 : _a.paymentMethodsUrl) ?? "https://forms.secure-payments.app"
|
|
23294
23293
|
}
|
|
23295
23294
|
});
|
|
@@ -24998,7 +24997,7 @@ const theme = new Proxy(properties, {
|
|
|
24998
24997
|
return true;
|
|
24999
24998
|
}
|
|
25000
24999
|
});
|
|
25001
|
-
const _Theme = class
|
|
25000
|
+
const _Theme = class _Theme2 {
|
|
25002
25001
|
constructor(overrides = {}) {
|
|
25003
25002
|
this.overrides = overrides;
|
|
25004
25003
|
this.theme = theme;
|
|
@@ -25009,7 +25008,7 @@ const _Theme = class _Theme {
|
|
|
25009
25008
|
});
|
|
25010
25009
|
}
|
|
25011
25010
|
get cssVars() {
|
|
25012
|
-
return Object.keys(this.theme).filter((v2) => !
|
|
25011
|
+
return Object.keys(this.theme).filter((v2) => !_Theme2.nonCssProperties.includes(v2)).map((p2, i2) => `${!i2 ? "" : " "}--rebilly-${p2}: ${this.theme[p2]};`).join("\n");
|
|
25013
25012
|
}
|
|
25014
25013
|
build() {
|
|
25015
25014
|
this.overrideTheme();
|
|
@@ -26478,7 +26477,7 @@ class RebillyInstrumentsInstance {
|
|
|
26478
26477
|
await show({ componentName, payload });
|
|
26479
26478
|
}
|
|
26480
26479
|
get version() {
|
|
26481
|
-
return `RebillyInstruments Ver.${"8.
|
|
26480
|
+
return `RebillyInstruments Ver.${"8.12.0"}`;
|
|
26482
26481
|
}
|
|
26483
26482
|
on(eventName, callback) {
|
|
26484
26483
|
on({ eventName, callback });
|