Pen Settings

HTML

CSS

CSS Base

Vendor Prefixing

Add External Stylesheets/Pens

Any URL's added here will be added as <link>s in order, and before the CSS in the editor. You can use the CSS from another Pen by using it's URL and the proper URL extention.

+ add another resource

JavaScript

Babel includes JSX processing.

Add External Scripts/Pens

Any URL's added here will be added as <script>s in order, and run before the JavaScript in the editor. You can use the URL of any other Pen and it will include the JavaScript from that Pen.

+ add another resource

Packages

Add Packages

Search for and use JavaScript packages from npm here. By selecting a package, an import statement will be added to the top of the JavaScript editor for this package.

Behavior

Save Automatically?

If active, Pens will autosave every 30 seconds after being saved once.

Auto-Updating Preview

If enabled, the preview panel updates automatically as you code. If disabled, use the "Run" button to update.

Format on Save

If enabled, your code will be formatted when you actively save your Pen. Note: your code becomes un-folded during formatting.

Editor Settings

Code Indentation

Want to change your Syntax Highlighting theme, Fonts and more?

Visit your global Editor Settings.

HTML

              
                  <header>
    <h1 class="title">Validador de Tarjeta de Crédito</h1>
  </header>

  <div class="demo">
    <form class="payment-card">
      <div class="bank-card">
        <div class="bank-card__side bank-card__side_front">
          <div class="bank-card__inner">
            <label class="bank-card__label bank-card__label_holder">
              <span class="bank-card__hint">Nombre completo</span>
              <input type="text" class="bank-card__field" placeholder="Nombre completo" pattern="[A-Za-z, ]{2,}" name="holder-card" id="name"
                required>
            </label>
          </div>
          <div class="bank-card__inner">
            <label class="bank-card__label bank-card__label_number">
              <span class="bank-card__hint">Número de tarjeta</span>
              <input type="text" class="bank-card__field" placeholder="Numero de tarjeta" pattern="[0-9]{16}" name="number-card" id="cn"
                required>
            </label>
          </div>
          <div class="bank-card__inner">
            <span class="bank-card__caption">validando</span>
          </div>
          <div class="bank-card__inner bank-card__footer">
            <label class="bank-card__label bank-card__month">
              <span class="bank-card__hint">Month</span>
              <input type="text" class="bank-card__field" placeholder="MM" maxlength="2" pattern="[0-9]{2}" name="mm-card" id="MM" required>
            </label>
            <span class="bank-card__separator">/</span>
            <label class="bank-card__label bank-card__year">
              <span class="bank-card__hint">Year</span>
              <input type="text" class="bank-card__field" placeholder="YY" maxlength="2" pattern="[0-9]{2}" name="year-card" id="YY" required>
            </label>
          </div>
        </div>
        <div class="bank-card__side bank-card__side_back">
          <div class="bank-card__inner">
            <label class="bank-card__label bank-card__cvc">
              <span class="bank-card__hint">CVV</span>
              <input type="text" class="bank-card__field" placeholder="CVV" maxlength="3" pattern="[0-9]{3}" name="cvc-card" id="cvv" required>
            </label>
          </div>
        </div>
      </div>
      <div class="payment-card__footer">
        <button class="payment-card__button" id="btn">Enviar</button>
      </div>
    </form>
  </div>
  <footer class="footer">
    <a class="melnik909" rel="noopener noreferrer">Gracias por la preferencia</a>
  </footer>

              
            
!

CSS

              
                @media screen and (min-width: 768px){

    html{
      font-size: 62.5%;
    }
  }
  
  @media screen and (max-width: 767px){
  
    html{
      font-size: 55%;
    }
  }
  
  body{
    font-family: -apple-system, BlinkMacSystemFont, "Roboto", "Open Sans", "Helvetica Neue", "Segoe UI", sans-serif;
    font-size: 1.6rem;
    margin: 0;
  }
  
  .demo{
    min-height: 470px;
    box-sizing: border-box;
    position: relative;
  
    padding-left: 1rem;
    padding-right: 1rem;
  
    display: flex;
    justify-content: center;
    align-items: center;
  }
  
  .footer{
    padding: 2rem;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;  
  }
  
  a{
    color: #000;
  }
  
  a:focus{
    outline: 2px solid #fdde60;
  }
  
  a:hover{
    text-decoration: none;
  }
  
  .melnik909{
    margin-left: 2rem;
  }
  
  /*
  * CSS payment card
  */
  
  .payment-card{
    width: 60rem;
  }
  
  .payment-card__footer{
    text-align: center;
    margin-top: 2rem;
  }
  
  .bank-card{
    position: relative;
  }
  
  @media screen and (min-width: 481px){
  
    .bank-card{
      height: 30rem;
    }
  
    .bank-card__side{
      border-radius: 10px;
      border: 1px solid transparent;
      position: absolute;
      width: 65%;
    }
  
    .bank-card__side_front{
      background-color: #f0f0ee;
      padding: 5%;
      box-shadow: 0 0 10px #f4f4f2;
      border-color: #a29e97;
  
      top: 0;
      left: 0;
      z-index: 3;
    }
  
    .bank-card__side_back{
      background-color: #e0ddd7;
      padding: 24.5% 5% 11%;
      box-shadow: 0 0 2rem #f3f3f3;
  
      text-align: right;
      border-color: #dad9d6;
  
      top: 12%;
      right: 0;
    }
  
    .bank-card__side_back:before{
      content: "";
      width: 100%;
      height: 25%;
      background-color: #8e8b85;
  
      position: absolute;
      top: 14%;
      right: 0;
    }
  }
  
  @media screen and (max-width: 480px){
  
    .bank-card__side{
      border: 1px solid #a29e97;
      background-color: #f0f0ee;
      padding-left: 5%;
      padding-right: 5%;
    }
  
    .bank-card__side_front{
      border-radius: 10px 10px 0 0;
      border-bottom: none;
      padding-top: 5%;
    }
  
    .bank-card__side_back{
      border-radius: 0 0 10px 10px;
      border-top: none;
      padding-bottom: 5%;
    }
  }
  
  .bank-card__inner{
    margin-bottom: 4%;
  }
  
  .bank-card__inner:last-child{
    margin-bottom: 0;
  }
  
  .bank-card__label{
    display: inline-block;
    vertical-align: middle;
  }
  
  .bank-card__label_holder, .bank-card__label_number{
    width: 100%;
  }
  
  @media screen and (min-width: 481px){
  
    .bank-card__month, .bank-card__year{
      width: 25%;
    }
  }
  
  @media screen and (max-width: 480px){
  
    .bank-card__month, .bank-card__year{
      width: 48%;
    }
  }
  
  @media screen and (min-width: 481px){
  
    .bank-card__cvc{
      width: 25%;
    }
  }
  
  @media screen and (max-width: 480px){
  
    .bank-card__cvc{
      width: 100%;
      margin-top: 4%;
    }
  }
  
  .bank-card__hint{
    position: absolute;
    left: -9999px;
  }
  
  .bank-card__caption{
    text-transform: uppercase;
    font-size: 1.1rem;
    margin-left: 1%;
  }
  
  .bank-card__field{
    box-sizing: border-box;
    border: 3px solid #d0d0ce;
    width: 100%;
  
    padding: 1rem;
    font-family: inherit;
    font-size: 100%;
  }
  
  .bank-card__field:focus{
    outline: none;
    border-color: #fdde60;
  }
  
  .bank-card__separator{
    font-size: 3.2rem;
    color: #c4c4c3;
  
    margin-left: 3%;
    margin-right: 3%;
    display: inline-block;
    vertical-align: middle;
  }
  
  @media screen and (max-width: 480px){
  
    .bank-card__separator{
      display: none;
    }
  }
  
  @media screen and (min-width: 481px){
  
    .bank-card__footer{
      background-image: url(data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSI2MCIgaGVpZ2h0PSIzNiIgdmlld0JveD0iMCAwIDMwMCAxODAiPjxwYXRoIGQ9Ik0yOTguMDMyIDkwLjVjLjAxNCA0OC45MzYtMzkuNjQ2IDg4LjYxNC04OC41ODIgODguNjI3LTQ4LjkzNy4wMTItODguNjE0LTM5LjY0Ni04OC42MjctODguNTgyVjkwLjVjLS4wMTMtNDguOTM1IDM5LjY0Ny04OC42MTUgODguNTgxLTg4LjYyOCA0OC45MzctLjAxMyA4OC42MTUgMzkuNjQ3IDg4LjYyOCA4OC41ODN2LjA0NXoiIGZpbGw9IiNmOTAiLz48cGF0aCBkPSJNOTAuMDAxIDEuODk1QzQxLjM1NSAyLjIwNCAxLjk2NyA0MS43ODEgMS45NjcgOTAuNWMwIDQ4LjkwOSAzOS42OTUgODguNjA0IDg4LjYwNSA4OC42MDQgMjIuOTU1IDAgNDMuODc5LTguNzQ4IDU5LjYyNC0yMy4wODZsLS4wMDctLjAwNGguMDE5YTg5LjQzNyA4OS40MzcgMCAwIDAgOC45OTUtOS40ODhIMTQxLjA1YTg2LjUzNiA4Ni41MzYgMCAwIDEtNi42MDYtOS4xMjdoMzEuMzA4YTg4Ljc1IDg4Ljc1IDAgMCAwIDUuMTU4LTkuNDg4aC00MS42MzVhODcuMzkyIDg3LjM5MiAwIDAgMS0zLjcwMy05LjMwOWg0OS4wNDVhODguMzg4IDg4LjM4OCAwIDAgMCA0LjU2LTI4LjEwM2MwLTYuNTEyLS43MDYtMTIuODYxLTIuMDQyLTE4Ljk3NGgtNTQuMTY0YTg4LjM0NyA4OC4zNDcgMCAwIDEgMi41MjgtOS4zMDhoNDkuMDYzYTg4LjYxOCA4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DUtMi40OTZsLjQ4MiAyLjI1NCAxLjY1IDcuNTUzaC01LjkxOHoiIGlkPSJwYXRoMTQiIGZpbGw9IiMwMDQ2ODYiLz48cGF0aCBkPSJNMjUuMDQuNDczbC02Ljk4IDE3LjgzNS0uNzQzLTMuNjI0Yy0xLjMtNC4xNzktNS4zNDgtOC43MDUtOS44NzMtMTAuOTcxbDYuMzgxIDIyLjg3MiA3LjU0My0uMDA5TDMyLjU5LjQ3M0gyNS4wNHoiIGlkPSJwYXRoMTYiIGZpbGw9IiMwMDQ2ODYiLz48cGF0aCBkPSJNMTEuNTg2LjQ1N0guMDkxTDAgMS4wMDFjOC45NDMgMi4xNjUgMTQuODYgNy4zOTcgMTcuMzE3IDEzLjY4M2wtMi41LTEyLjAxOUMxNC4zODYgMS4wMSAxMy4xMzQuNTE1IDExLjU4Ni40NTd6IiBpZD0icGF0aDE4IiBmaWxsPSIjZWY5YjExIi8+PC9nPjwvc3ZnPg==);
      background-repeat: no-repeat;
      background-position: 78% 50%, 100% 50% ;
    }
  }
  
  @media screen and (max-width: 480px){
  
    .bank-card__footer{
      display: flex;
      justify-content: space-between;
    }
  }
  
  .payment-card__button{
  
    background-color: #335299;
    transition: background-color .4s ease-out;
  
    border-radius: 5px;
    border: 3px solid transparent;
    cursor: pointer;
    padding: 1rem 6.5rem;
    font-size: 100%;
    font-family: inherit;
    color: #fff;
  }
  
  .payment-card__button:focus{
    outline: none;
    border-color: #fdde60;
  }
  
  .payment-card__button:hover, .payment-card__button:focus{
    background-color: #8e8b85;
  }

  .title {
    text-align: center;
  }

  
              
            
!

JS

              
                // Llamando al DOM
const btn = document.getElementById('btn');
let cardNumber = document.getElementById('cn'),
name = document.getElementById('name'),
yy = document.getElementById('YY'),
mm = document.getElementById('MM'), 
cvv = document.getElementById('cvv');


// Trayendo valores de los inputs
btn.addEventListener('click', function () {
  // Obteniendo los datos de  l cliente en base a su número de tarjeta
  if ($.validCard(cardNumber.value)) {
    const client = persona.filter((val) => val.number === cardNumber)[0];
    // Solo pasará a validar los siguientes datos si se encuentra el número de tarjeta ingresado en la data
    if (client) {
      // Validando si los demás inputs son correctos
      if (client.name === name && client.cvv === cvv && client.yy === yy && client.mm === mm) {
        alert('Datos correctos');

      } else alert('Los datos no coinciden con el número de tarjeta');
    } else alert('Los datos no se encuentran en la base de datos');
  } else {
    alert('Ingrese datos');
  }
});


 //Creando las validaciones 
const expNum = /[^0-9]/g;
const expLet = /[^a-zA-ZÑñáéíóúÁÉÍÓÚ\s]*$/g;

let inputNumber = document.getElementById('cn');
let inputString = document.getElementById('name');

//Función que acepta solo números
inputNumber.addEventListener('input', function (){
  inputNumber.value = inputNumber.value.replace(expNum,'');
});

//Función que acepta solo letras
inputString.addEventListener('input', function (){
  inputString.value = inputString.value.replace(expLet,'');
});



/*
function validarNumCard(numeroTarjeta) {
  soloNumero(numeroTarjeta);
  cantidadNumeros(numeroTarjeta);
}

function soloNumero(numeroTarjeta) {
  numeroTarjeta.value = numeroTarjeta.value.replace(expNum,'');
}

function cantidadNumeros(numeroTarjeta) {
  numeroTarjeta
}

*/
              
            
!
999px

Console