@paypal/checkout-components 5.0.246 → 5.0.248

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@paypal/checkout-components",
3
- "version": "5.0.246",
3
+ "version": "5.0.248",
4
4
  "description": "PayPal Checkout components, for integrating checkout products.",
5
5
  "main": "index.js",
6
6
  "scripts": {
@@ -47,7 +47,13 @@ type CardFieldsProps = {|
47
47
  branded? : boolean,
48
48
  minLength?: number,
49
49
  maxLength?: number,
50
-
50
+ onChange?: () => ZalgoPromise<Object> | Object,
51
+ inputEvents?: {|
52
+ onChange?: () => ZalgoPromise<Object> | Object,
53
+ onBlur?: () => ZalgoPromise<Object> | Object,
54
+ onFocus?: () => ZalgoPromise<Object> | Object,
55
+ onInputSubmitRequest?: () => ZalgoPromise<Object> | Object,
56
+ |},
51
57
  createOrder : () => ZalgoPromise<string> | string,
52
58
  onApprove : ({| returnUrl : string |}, {| redirect : (?CrossDomainWindowType, ?string) => ZalgoPromise<void> |}) => ?ZalgoPromise<void>,
53
59
  onComplete : ({| returnUrl : string |}, {| redirect : (?CrossDomainWindowType, ?string) => ZalgoPromise<void> |}) => ?ZalgoPromise<void>,
@@ -230,6 +236,30 @@ export const getCardFieldsComponent : () => CardFieldsComponent = memoize(() : C
230
236
  }
231
237
  },
232
238
 
239
+ onChange: {
240
+ type: 'function',
241
+ required: false,
242
+ value: ({props}) => {
243
+ if (props.onChange) {
244
+ return props.onChange
245
+ } else {
246
+ return props.parent.props.onChange
247
+ }
248
+ }
249
+ },
250
+
251
+ inputEvents: {
252
+ type: 'object',
253
+ required: false,
254
+ value: ({props}) => {
255
+ if (props.inputEvents) {
256
+ return props.inputEvents
257
+ } else {
258
+ return props.parent.props.inputEvents
259
+ }
260
+ }
261
+ },
262
+
233
263
  minLength: {
234
264
  type: 'number',
235
265
  required: false,
@@ -446,6 +476,16 @@ export const getCardFieldsComponent : () => CardFieldsComponent = memoize(() : C
446
476
  queryParam: true
447
477
  },
448
478
 
479
+ onChange: {
480
+ type: 'function',
481
+ required: false
482
+ },
483
+
484
+ inputEvents: {
485
+ type: 'object',
486
+ required: false
487
+ },
488
+
449
489
  minLength: {
450
490
  type: 'number',
451
491
  required: false,