Skip to content
/ rcc-validator Public template

💳 A credit/debit card validator fields for React

Notifications You must be signed in to change notification settings

joelcalheiros/rcc-validator

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

React Credit Card Validator

A credit/debit card validator fields for React

Usage

import CreditCardValidator from 'rcc-validator';

<CreditCardValidator
  onChangeCreditCardValidator={this.onChangeCreditCardValidator}
  boxClassName="container"
  customTextLabels={{
    holderPlaceholder: "Titular do cartão",
    numberPlaceholder: "Número do cartão",
    cardNumberInvalidLabel: 'O número do cartão não é valido',
    expiryMonthInvalidLabel: 'A data de validade é inválida',
    cvvInvalidLabel: 'O código de segurança é inválido',
  }}
  cardTypes={
    [
      { name: '', value: '' },
      { name: 'Master Card', value: 'mastercard' },
      { name: 'Visa', value: 'visa' },
      { name: 'Visa Debit', value: 'visadebit' },
      { name: 'Visa Electron', value: 'visaelectron' },
      { name: 'V Pay', value: 'vpay' },
      { name: 'Maestro', value: 'maestro' },
      { name: 'American Express', value: 'amex' },
    ]
  }
/>

About

💳 A credit/debit card validator fields for React

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published