@delopay/sdk 0.261.0 → 0.263.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/index.cjs CHANGED
@@ -213,6 +213,7 @@ __export(index_exports, {
213
213
  fontWeightValue: () => fontWeightValue,
214
214
  inputPadValue: () => inputPadValue,
215
215
  isCheckboxChecked: () => isCheckboxChecked,
216
+ isConfirmedChild: () => isConfirmedChild,
216
217
  isDarkSurface: () => isDarkSurface,
217
218
  isDefaultBadgeSet: () => isDefaultBadgeSet,
218
219
  isHexColor: () => isHexColor,
@@ -7123,6 +7124,31 @@ var CheckoutMethods = class {
7123
7124
  body
7124
7125
  });
7125
7126
  }
7127
+ /**
7128
+ * What DeloPay confirms beneath each item the shop can place: the card
7129
+ * networks the card form's accounts accept, and the methods or coins a
7130
+ * provider's page offers, per account, with source and freshness. A
7131
+ * provider that answers only per order reports `context_required` until
7132
+ * `currency` and `amount` are given. A layout item's `children` narrows
7133
+ * these lists and never adds to them.
7134
+ * `GET /checkout-methods/{profile_id}/children` (`/test/children` for Test)
7135
+ */
7136
+ async children(merchantId, profileId, params = {}) {
7137
+ const { environment, ...order } = params;
7138
+ const query = { merchant_id: merchantId, ...order };
7139
+ if (environment === "test") {
7140
+ return this.request(
7141
+ "GET",
7142
+ `/checkout-methods/${encodeURIComponent(profileId)}/test/children`,
7143
+ {
7144
+ query
7145
+ }
7146
+ );
7147
+ }
7148
+ return this.request("GET", `/checkout-methods/${encodeURIComponent(profileId)}/children`, {
7149
+ query
7150
+ });
7151
+ }
7126
7152
  /**
7127
7153
  * Delete the stored layout; the shop is back on the derived one.
7128
7154
  * `DELETE /checkout-methods/{profile_id}`
@@ -13066,6 +13092,9 @@ function presentationIconSrc(entry, color) {
13066
13092
  if (entry.fallback_icon) return builtinPaymentIconDataUri(entry.fallback_icon, color);
13067
13093
  return null;
13068
13094
  }
13095
+ function isConfirmedChild(child) {
13096
+ return child.source !== "merchant";
13097
+ }
13069
13098
  function isSupportedPresentation(response) {
13070
13099
  return response.contract_version === PRESENTATION_CONTRACT_VERSION;
13071
13100
  }
@@ -13766,6 +13795,7 @@ var encodeNativePanes = encodePanes;
13766
13795
  fontWeightValue,
13767
13796
  inputPadValue,
13768
13797
  isCheckboxChecked,
13798
+ isConfirmedChild,
13769
13799
  isDarkSurface,
13770
13800
  isDefaultBadgeSet,
13771
13801
  isHexColor,