Skip to content

A wrapper for jessepollak.github.io/card credit card UI

Notifications You must be signed in to change notification settings

JutoApp/jessepollack-card

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

A wrapper for Jesse Pollack's jessepollak.github.io/card credit card UI:

card

For more info see Jesse Pollack's repo.

Installation

    meteor add juto:jessepollack-card

Example

HTML:

    <template name="creditCardCheck">
      <div class='card-wrapper'></div>
      <form id="cc">
        <input type="text" name="number">
        <input type="text" name="first-name"/>
        <input type="text" name="last-name"/>
        <input type="text" name="expiry"/>
        <input type="text" name="cvc"/>
      </form>     
    </template>

JS:

    Template.creditCardCheck.onRendered(function(){
      this.$('#cc').card({
        // a selector or DOM element for the container
        // where you want the card to appear
        container: '.card-wrapper', // *required*
        formSelectors: {
          nameInput: 'input[name="first-name"], input[name="last-name"]'
        }
      });
    });

About

A wrapper for jessepollak.github.io/card credit card UI

Resources

Stars

Watchers

Forks

Packages

No packages published