@rebilly/instruments 9.84.0 → 9.84.2

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 CHANGED
@@ -1,6 +1,6 @@
1
- ## [9.84.0](https://github.com/Rebilly/rebilly/compare/instruments/core-v9.83.0...instruments/core-v9.84.0) (2024-09-24)
1
+ ## [9.84.2](https://github.com/Rebilly/rebilly/compare/instruments/core-v9.84.1...instruments/core-v9.84.2) (2024-09-26)
2
2
 
3
3
 
4
- ### Features
4
+ ### Bug Fixes
5
5
 
6
- * **instruments, docs:** Consent improvements ([#7729](https://github.com/Rebilly/rebilly/issues/7729)) ([b5906cb](https://github.com/Rebilly/rebilly/commit/b5906cb5d3589829e8055eb28538724dd8ec979f))
6
+ * **instrument:** Fix HPF deposit button alignment ([#7740](https://github.com/Rebilly/rebilly/issues/7740)) ([3f6baf5](https://github.com/Rebilly/rebilly/commit/3f6baf53e2e28016b514107584fb6a5305778dcc))
package/dist/index.js CHANGED
@@ -2738,6 +2738,49 @@ function updateAddonsHandler(iframe) {
2738
2738
  }
2739
2739
  );
2740
2740
  }
2741
+ class BaseModel {
2742
+ constructor({ ...fields } = {}) {
2743
+ Object.entries(fields).forEach(([key, value]) => {
2744
+ this[key] = value;
2745
+ });
2746
+ }
2747
+ }
2748
+ const _InvoiceModel = class _InvoiceModel extends BaseModel {
2749
+ get isPaid() {
2750
+ return this.status === _InvoiceModel.Status.paid;
2751
+ }
2752
+ get isVoid() {
2753
+ return this.status === _InvoiceModel.Status.voided;
2754
+ }
2755
+ get isRefunded() {
2756
+ return this.status === _InvoiceModel.Status.refunded;
2757
+ }
2758
+ get isAbandoned() {
2759
+ return this.status === _InvoiceModel.Status.abandoned;
2760
+ }
2761
+ };
2762
+ _InvoiceModel.Status = {
2763
+ draft: "draft",
2764
+ unpaid: "unpaid",
2765
+ paid: "paid",
2766
+ partiallyPaid: "partially-paid",
2767
+ pastDue: "past-due",
2768
+ abandoned: "abandoned",
2769
+ voided: "voided",
2770
+ partiallyRefunded: "partially-refunded",
2771
+ refunded: "refunded",
2772
+ disputed: "disputed"
2773
+ };
2774
+ let InvoiceModel = _InvoiceModel;
2775
+ function updateInvoiceHandler(iframe) {
2776
+ iframe.component.on(
2777
+ `${iframe.name}-update-invoice`,
2778
+ async ({ invoice }) => {
2779
+ state.data.invoice = new InvoiceModel(invoice);
2780
+ state.updateModel();
2781
+ }
2782
+ );
2783
+ }
2741
2784
  const errorTemplate = (error2) => {
2742
2785
  const title2 = "Error";
2743
2786
  function displayString(message = null) {
@@ -2937,6 +2980,7 @@ let ViewIframe$1 = class ViewIframe extends BaseIframe {
2937
2980
  showErrorHandler(this);
2938
2981
  updateCouponsHandler(this);
2939
2982
  updateAddonsHandler(this);
2983
+ updateInvoiceHandler(this);
2940
2984
  showConfirmationModalHandler(this);
2941
2985
  }
2942
2986
  };
@@ -3330,13 +3374,6 @@ function cloneDeep(value) {
3330
3374
  }
3331
3375
  var cloneDeep_1 = cloneDeep;
3332
3376
  const cloneDeep$1 = /* @__PURE__ */ getDefaultExportFromCjs(cloneDeep_1);
3333
- class BaseModel {
3334
- constructor({ ...fields } = {}) {
3335
- Object.entries(fields).forEach(([key, value]) => {
3336
- this[key] = value;
3337
- });
3338
- }
3339
- }
3340
3377
  class SummaryLineItemModel extends BaseModel {
3341
3378
  constructor({
3342
3379
  unitPrice = 0,
@@ -6220,7 +6257,7 @@ function C$1({ options: e2 }) {
6220
6257
  }
6221
6258
  function o2() {
6222
6259
  const i = {
6223
- "REB-API-CONSUMER": `${["Rebilly", e2.appName, "js-sdk"].filter((g) => g).join("/")}@b5906cb`
6260
+ "REB-API-CONSUMER": `${["Rebilly", e2.appName, "js-sdk"].filter((g) => g).join("/")}@3f6baf5`
6224
6261
  };
6225
6262
  return e2.apiKey && (i["REB-APIKEY"] = e2.apiKey), i;
6226
6263
  }
@@ -16418,33 +16455,6 @@ async function fetchReadyToPayout() {
16418
16455
  return filterReadyToPayout(readyToPayout);
16419
16456
  });
16420
16457
  }
16421
- const _InvoiceModel = class _InvoiceModel extends BaseModel {
16422
- get isPaid() {
16423
- return this.status === _InvoiceModel.Status.paid;
16424
- }
16425
- get isVoid() {
16426
- return this.status === _InvoiceModel.Status.voided;
16427
- }
16428
- get isRefunded() {
16429
- return this.status === _InvoiceModel.Status.refunded;
16430
- }
16431
- get isAbandoned() {
16432
- return this.status === _InvoiceModel.Status.abandoned;
16433
- }
16434
- };
16435
- _InvoiceModel.Status = {
16436
- draft: "draft",
16437
- unpaid: "unpaid",
16438
- paid: "paid",
16439
- partiallyPaid: "partially-paid",
16440
- pastDue: "past-due",
16441
- abandoned: "abandoned",
16442
- voided: "voided",
16443
- partiallyRefunded: "partially-refunded",
16444
- refunded: "refunded",
16445
- disputed: "disputed"
16446
- };
16447
- let InvoiceModel = _InvoiceModel;
16448
16458
  async function fetchInvoiceAndProducts({
16449
16459
  data
16450
16460
  }) {
@@ -28004,12 +28014,12 @@ const vars = (theme2) => `
28004
28014
 
28005
28015
  @media screen and (max-width: 480px) {
28006
28016
  .rebilly-instruments-button-group {
28007
- flex-direction: column-reverse;
28017
+ flex-direction: column;
28008
28018
  }
28009
28019
 
28010
28020
  .rebilly-instruments-button-group
28011
28021
  .rebilly-instruments-button:first-of-type {
28012
- margin: 0;
28022
+ margin-bottom: var(--rebilly-spacingS);
28013
28023
  }
28014
28024
 
28015
28025
  .rebilly-instruments-button-group .rebilly-instruments-button:last-of-type {
@@ -28019,7 +28029,7 @@ const vars = (theme2) => `
28019
28029
  .rebilly-instruments-button-group
28020
28030
  .rebilly-instruments-button
28021
28031
  + .rebilly-instruments-button {
28022
- margin-bottom: var(--rebilly-spacingS);
28032
+ margin: 0 0 var(--rebilly-spacingS) 0;
28023
28033
  }
28024
28034
  }
28025
28035