From a32dc988bde1c7c5712ca354895482380229808c Mon Sep 17 00:00:00 2001 From: zarets Date: Sun, 30 May 2021 11:02:33 +0300 Subject: [PATCH] card number - support setting the input type (specifically to be able to mask the number using type = password) --- src/usePaymentInputs.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/usePaymentInputs.js b/src/usePaymentInputs.js index 8398b93..012912d 100644 --- a/src/usePaymentInputs.js +++ b/src/usePaymentInputs.js @@ -156,7 +156,7 @@ export default function usePaymentCard({ id: 'cardNumber', name: 'cardNumber', placeholder: 'Card number', - type: 'tel', + type: props.type || 'tel', [refKey || 'ref']: cardNumberField, ...props, onBlur: handleBlurCardNumber(props),