CardNumberInput
A text input field for 16-digits credit card inputs
The CardNumberInput
field is used during a payment flow to type in the credit card number. Below is the simplest example, only the input field with the numbers visible to the user and a descriptive card icon on the left.
Basic usage
In most use-cases the it is also useful to include a label for more information about the input.
Labels usage
By default, the CardNumberInput
displays a card icon on the left side. Hide this by using the hideIcon
-prop.
Hidden icon usage
The card number input also provides error handling.