@bigcommerce/checkout-sdk 1.743.2 → 1.744.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.
@@ -5151,6 +5151,19 @@ declare interface CreditCardPlaceHolder {
5151
5151
  encryptedSecurityCode: string;
5152
5152
  }
5153
5153
 
5154
+ /**
5155
+ * This object is used to pass custom fonts when creating an [Elements](https://stripe.com/docs/js/elements_object/create) object.
5156
+ */
5157
+ declare interface CssFontSource {
5158
+ /**
5159
+ * A relative or absolute URL pointing to a CSS file with [@font-face](https://developer.mozilla.org/en-US/docs/Web/CSS/@font-face) definitions, for example:
5160
+ * `https://fonts.googleapis.com/css?family=Open+Sans`
5161
+ * Note that if you are using a [content security policy](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Security-Policy) (CSP),
5162
+ * [additional directives](https://stripe.com/docs/security#content-security-policy) may be necessary.
5163
+ */
5164
+ cssSrc: string;
5165
+ }
5166
+
5154
5167
  declare interface CssProperties {
5155
5168
  background?: string;
5156
5169
  caretColor?: string;
@@ -5208,6 +5221,37 @@ declare interface CustomError extends Error {
5208
5221
  subtype?: string;
5209
5222
  }
5210
5223
 
5224
+ /**
5225
+ * This object is used to pass custom fonts when creating an [Elements](https://stripe.com/docs/js/elements_object/create) object.
5226
+ */
5227
+ declare interface CustomFontSource {
5228
+ /**
5229
+ * The name to give the font.
5230
+ */
5231
+ family: string;
5232
+ /**
5233
+ * A valid [src](https://developer.mozilla.org/en-US/docs/Web/CSS/@font-face/src) value pointing to your
5234
+ * custom font file. This is usually (though not always) a link to a file with a .woff , .otf, or .svg suffix.
5235
+ */
5236
+ src: string;
5237
+ /**
5238
+ * A valid [font-display](https://developer.mozilla.org/en-US/docs/Web/CSS/@font-face/font-display) value.
5239
+ */
5240
+ display?: string;
5241
+ /**
5242
+ * One of normal, italic, oblique. Defaults to normal.
5243
+ */
5244
+ style?: string;
5245
+ /**
5246
+ * A valid [unicode-range](https://developer.mozilla.org/en-US/docs/Web/CSS/@font-face/unicode-range) value.
5247
+ */
5248
+ unicodeRange?: string;
5249
+ /**
5250
+ * A valid [font-weight](https://developer.mozilla.org/en-US/docs/Web/CSS/font-weight). Note that this is a string, not a number.
5251
+ */
5252
+ weight?: string;
5253
+ }
5254
+
5211
5255
  declare interface CustomItem {
5212
5256
  id: string;
5213
5257
  listPrice: number;
@@ -8599,6 +8643,18 @@ declare class StoredCardHostedFormService {
8599
8643
  deinitialize(): void;
8600
8644
  }
8601
8645
 
8646
+ /**
8647
+ * All available options are here https://stripe.com/docs/stripe-js/appearance-api#supported-css-properties
8648
+ */
8649
+ declare interface StripeAppearanceOptions {
8650
+ variables?: Record<string, StripeAppearanceValues>;
8651
+ rules?: Record<string, Record<string, StripeAppearanceValues>>;
8652
+ }
8653
+
8654
+ declare type StripeAppearanceValues = string | string[] | number | undefined;
8655
+
8656
+ declare type StripeCustomFont = CssFontSource | CustomFontSource;
8657
+
8602
8658
  declare interface StripeCustomerEvent extends StripeEvent {
8603
8659
  collapsed?: boolean;
8604
8660
  authenticated: boolean;
@@ -8798,9 +8854,13 @@ declare interface StripeOCSPaymentInitializeOptions {
8798
8854
  */
8799
8855
  layout?: Record<string, string | number | boolean>;
8800
8856
  /**
8801
- * Checkout styles from store theme
8857
+ * Stripe OCS appearance options for styling the accordion.
8858
+ */
8859
+ appearance?: StripeAppearanceOptions;
8860
+ /**
8861
+ * Stripe OCS fonts options for styling the accordion.
8802
8862
  */
8803
- style?: Record<string, StripeUPEAppearanceValues>;
8863
+ fonts?: StripeCustomFont[];
8804
8864
  onError?(error?: Error): void;
8805
8865
  render(): void;
8806
8866
  initStripeElementUpdateTrigger?(updateTriggerFn: (payload: StripeElementUpdateOptions) => void): void;
@@ -8834,8 +8894,6 @@ declare interface StripeShippingEvent extends StripeEvent {
8834
8894
  };
8835
8895
  }
8836
8896
 
8837
- declare type StripeUPEAppearanceValues = string | string[] | number | undefined;
8838
-
8839
8897
  declare interface StripeUPECustomerInitializeOptions {
8840
8898
  /**
8841
8899
  * The ID of a container which the stripe iframe should be inserted.
@@ -8899,7 +8957,7 @@ declare interface StripeUPEPaymentInitializeOptions {
8899
8957
  /**
8900
8958
  * Checkout styles from store theme
8901
8959
  */
8902
- style?: Record<string, StripeUPEAppearanceValues>;
8960
+ style?: Record<string, StripeAppearanceValues>;
8903
8961
  onError?(error?: Error): void;
8904
8962
  render(): void;
8905
8963
  initStripeElementUpdateTrigger?(updateTriggerFn: (payload: StripeElementUpdateOptions) => void): void;