@pay-com/js 1.1.9 → 1.1.13

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.
@@ -251,6 +251,38 @@ export type FailureError = {
251
251
  data?: Record<string, unknown>
252
252
  }
253
253
 
254
+ export type Mode = 'integrated' | 'modal'
255
+
256
+ export type Locale =
257
+ | 'en-US'
258
+ | 'en-GB'
259
+ | 'ro-RO'
260
+ | 'zh-CN'
261
+ | 'cs-CZ'
262
+ | 'da-DK'
263
+ | 'nl-NL'
264
+ | 'de-DE'
265
+ | 'fr-FR'
266
+ | 'fi-FI'
267
+ | 'el-GR'
268
+ | 'hu-HU'
269
+ | 'id-ID'
270
+ | 'it-IT'
271
+ | 'ja-JP'
272
+ | 'ko-KR'
273
+ | 'ko-KP'
274
+ | 'nb-NO'
275
+ | 'pl-PL'
276
+ | 'pt-PT'
277
+ | 'pt-BR'
278
+ | 'ru-RU'
279
+ | 'es-ES'
280
+ | 'se-SE'
281
+ | 'se-FI'
282
+ | 'se-NO'
283
+ | 'tr-TR'
284
+ | 'vi-VN'
285
+
254
286
  export interface CheckoutOpts {
255
287
  /**
256
288
  * @deprecated Got replaced by clientSecret
@@ -261,7 +293,7 @@ export interface CheckoutOpts {
261
293
  amount?: string
262
294
  onSuccess?: (payment: Record<string, unknown>) => void
263
295
  onFailure?: (error: FailureError) => void
264
- mode?: modeOpts
296
+ mode?: Mode
265
297
  throwOnSubmitFailure?: boolean
266
298
  paymentFailurePopupConfig?: {
267
299
  sessionExpiredPopupText?: string
@@ -273,6 +305,7 @@ export interface CheckoutOpts {
273
305
  displayEndOfSessionFailureMessages?: boolean
274
306
  disableAdditionalFields?: boolean
275
307
  }
308
+ locale?: Locale
276
309
  }
277
310
 
278
311
  interface PayComI {
@@ -398,6 +431,7 @@ export type UpdateTransactionDetailsOpts = {
398
431
  state?: string
399
432
  countryAlpha2: string
400
433
  }
434
+ customFieldsValues: Record<string, string | number | boolean>
401
435
  }
402
436
 
403
437
  export type PayOpts = {
package/lib/index.d.ts CHANGED
@@ -256,6 +256,38 @@ type FailureError = {
256
256
  data?: Record<string, unknown>
257
257
  }
258
258
 
259
+ type Mode = 'integrated' | 'modal'
260
+
261
+ type Locale =
262
+ | 'en-US'
263
+ | 'en-GB'
264
+ | 'ro-RO'
265
+ | 'zh-CN'
266
+ | 'cs-CZ'
267
+ | 'da-DK'
268
+ | 'nl-NL'
269
+ | 'de-DE'
270
+ | 'fr-FR'
271
+ | 'fi-FI'
272
+ | 'el-GR'
273
+ | 'hu-HU'
274
+ | 'id-ID'
275
+ | 'it-IT'
276
+ | 'ja-JP'
277
+ | 'ko-KR'
278
+ | 'ko-KP'
279
+ | 'nb-NO'
280
+ | 'pl-PL'
281
+ | 'pt-PT'
282
+ | 'pt-BR'
283
+ | 'ru-RU'
284
+ | 'es-ES'
285
+ | 'se-SE'
286
+ | 'se-FI'
287
+ | 'se-NO'
288
+ | 'tr-TR'
289
+ | 'vi-VN'
290
+
259
291
  interface CheckoutOpts {
260
292
  /**
261
293
  * @deprecated Got replaced by clientSecret
@@ -266,7 +298,7 @@ interface CheckoutOpts {
266
298
  amount?: string
267
299
  onSuccess?: (payment: Record<string, unknown>) => void
268
300
  onFailure?: (error: FailureError) => void
269
- mode?: modeOpts
301
+ mode?: Mode
270
302
  throwOnSubmitFailure?: boolean
271
303
  paymentFailurePopupConfig?: {
272
304
  sessionExpiredPopupText?: string
@@ -278,6 +310,7 @@ interface CheckoutOpts {
278
310
  displayEndOfSessionFailureMessages?: boolean
279
311
  disableAdditionalFields?: boolean
280
312
  }
313
+ locale?: Locale
281
314
  }
282
315
 
283
316
  interface PayComOpts {
@@ -397,6 +430,7 @@ type UpdateTransactionDetailsOpts = {
397
430
  state?: string
398
431
  countryAlpha2: string
399
432
  }
433
+ customFieldsValues: Record<string, string | number | boolean>
400
434
  }
401
435
 
402
436
  type PayOpts = {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pay-com/js",
3
- "version": "1.1.9",
3
+ "version": "1.1.13",
4
4
  "description": "Pay.com JS loading utility",
5
5
  "keywords": [
6
6
  "Pay.com",