straumur-web-component 1.1.4-alpha.1 → 1.1.5-alpha.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/dist/index.d.ts CHANGED
@@ -83,6 +83,9 @@ type StraumurWebConfiguration = {
83
83
  locale?: "is" | "en";
84
84
  localizations?: Partial<Record<Language, Partial<Record<TranslationKey, string>>>>;
85
85
  instantPayments?: UniqueInstantPayments;
86
+ hideSubmitButton?: boolean;
87
+ onCardValidityChanged?: (isValid: boolean, isActive: boolean) => void;
88
+ allowedPaymentMethods?: PaymentMethod[];
86
89
  };
87
90
  type ResultCode = "AuthenticationFinished" | "AuthenticationNotRequired" | "Authorised" | "Cancelled" | "ChallengeShopper" | "Error" | "IdentifyShopper" | "PartiallyAuthorised" | "Pending" | "PresentToShopper" | "Received" | "RedirectShopper" | "Refused";
88
91
  type PaymentCompletedData = {
@@ -101,6 +104,9 @@ type StraumurCheckoutConfiguration = {
101
104
  locale: Language;
102
105
  customLocalizations?: Partial<Record<Language, Partial<Record<TranslationKey, string>>>>;
103
106
  instantPayments?: UniqueInstantPayments;
107
+ hideSubmitButton?: boolean;
108
+ onCardValidityChanged?: (isValid: boolean, isActive: boolean) => void;
109
+ allowedPaymentMethods?: PaymentMethod[];
104
110
  };
105
111
  type PlaceholderKeys = "cardNumber" | "expiryDate" | "expiryMonth" | "expiryYear" | "securityCodeThreeDigits" | "securityCodeFourDigits";
106
112
  type Placeholders = Partial<Record<PlaceholderKeys, string>>;
@@ -110,6 +116,7 @@ declare class StraumurCheckout {
110
116
  private paymentMethods;
111
117
  private mountElement;
112
118
  private i18n;
119
+ private submitApi;
113
120
  constructor(config: StraumurWebConfiguration);
114
121
  mount(selector: HTMLElement | string): Promise<void>;
115
122
  private renderComponent;
@@ -120,6 +127,7 @@ declare class StraumurCheckout {
120
127
  updateConfig(newConfig: Partial<StraumurCheckoutConfiguration>): void;
121
128
  setLanguage(locale: Language): void;
122
129
  destroy(): void;
130
+ submitCard(): boolean;
123
131
  }
124
132
 
125
133
  export { StraumurCheckout };