angular-card ============ Angular directive for card https://github.com/jessepollak/card  ## Demo http://jessepollak.github.io/card/ ## Installation ### npm `npm install angular-card` ## Usage ### `name` is required for form and inputs (you can use any unique name) ### `width` is optional, it can be set on the element or the options object (defaults to 350) ```html
``` ```js angular.module('app', ['gavruk.card']) .controller('ExampleCtrl', ['$scope', function($scope) { $scope.card = { name: 'Mike Brown', number: '5555 4444 3333 1111', expiry: '11 / 2020', cvc: '123' }; $scope.cardPlaceholders = { name: 'Your Full Name', number: 'xxxx xxxx xxxx xxxx', expiry: 'MM/YY', cvc: 'xxx' }; $scope.cardMessages = { validDate: 'valid\nthru', monthYear: 'MM/YYYY', }; $scope.cardOptions = { debug: false, formatting: true, width: 500 //optional }; }]); ``` #### Using multiple fields for card expiry Simply use 2 input fields for the expiry, and pass either `month`, or `year` to the directive. ```js ```