GitHub PullRequestEvent at 2014-03-20 00:29:12
Repository: formatter.js
Actor: jaridmargolin
Payload: {"action":"closed","number":38,"pull_request":{"url":"https://api.github.com/repos/firstopinion/formatter.js/pulls/38","id":13598338,"html_url":"https://github.com/firstopinion/formatter.js/pull/38","diff_url":"https://github.com/firstopinion/formatter.js/pull/38.diff","patch_url":"https://github.com/firstopinion/formatter.js/pull/38.patch","issue_url":"https://api.github.com/repos/firstopinion/formatter.js/issues/38","number":38,"state":"closed","title":"Add multi-pattern support.","user":{"login":"braintreeps","id":200407,"avatar_url":"https://avatars.githubusercontent.com/u/200407?","gravatar_id":"ee7b6959f53d27ac8ff4ac35ef942948","url":"https://api.github.com/users/braintreeps","html_url":"https://github.com/braintreeps","followers_url":"https://api.github.com/users/braintreeps/followers","following_url":"https://api.github.com/users/braintreeps/following{/other_user}","gists_url":"https://api.github.com/users/braintreeps/gists{/gist_id}","starred_url":"https://api.github.com/users/braintreeps/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/braintreeps/subscriptions","organizations_url":"https://api.github.com/users/braintreeps/orgs","repos_url":"https://api.github.com/users/braintreeps/repos","events_url":"https://api.github.com/users/braintreeps/events{/privacy}","received_events_url":"https://api.github.com/users/braintreeps/received_events","type":"User","site_admin":false},"body":"Hi there!\r\n\r\nWe wanted to use this library to add validations on a credit card form. In our case, the desired behavior was to change the formatting patterns based on the credit card type and whether or not the user enters an expiration date starting with a 0, 1, or other number.\r\n\r\nIn order to accomplish this, we augmented `formatter.js` to accept a set of patterns, in addition to the single pattern it previously accepted. Basically, you provide a set of regex patterns and corresponding format patterns. The library then dynamically applies a pattern based on the input element's value each time it changes.\r\n\r\nThese changes are fully backwards compatible with one exception. `myFormatter.opts.pattern` is no longer accessible as the pattern now is saved as a `patternMatcher`, rather than a pattern string.\r\n\r\nThe changes to README and tests should give you a more precise outline of the new behavior.\r\n\r\nCheers!\r\nMickey","created_at":"2014-03-15T00:23:26Z","updated_at":"2014-03-20T00:29:10Z","closed_at":"2014-03-20T00:29:10Z","merged_at":"2014-03-20T00:29:10Z","merge_commit_sha":"09a6443895d4cbb1a6fe202c93de8a2c424b1989","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/firstopinion/formatter.js/pulls/38/commits","review_comments_url":"https://api.github.com/repos/firstopinion/formatter.js/pulls/38/comments","review_comment_url":"https://api.github.com/repos/firstopinion/formatter.js/pulls/comments/{number}","comments_url":"https://api.github.com/repos/firstopinion/formatter.js/issues/38/comments","statuses_url":"https://api.github.com/repos/firstopinion/formatter.js/statuses/1239bc92510f7b58a0e7442adf28f6bf7d2d5ada","head":{"label":"braintreeps:master","ref":"master","sha":"1239bc92510f7b58a0e7442adf28f6bf7d2d5ada","user":{"login":"braintreeps","id":200407,"avatar_url":"https://avatars.githubusercontent.com/u/200407?","gravatar_id":"ee7b6959f53d27ac8ff4ac35ef942948","url":"https://api.github.com/users/braintreeps","html_url":"https://github.com/braintreeps","followers_url":"https://api.github.com/users/braintreeps/followers","following_url":"https://api.github.com/users/braintreeps/following{/other_user}","gists_url":"https://api.github.com/users/braintreeps/gists{/gist_id}","starred_url":"https://api.github.com/users/braintreeps/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/braintreeps/subscriptions","organizations_url":"https://api.github.com/users/braintreeps/orgs","repos_url":"https://api.github.com/users/braintreeps/repos","events_url":"https://api.github.com/users/braintreeps/events{/privacy}","received_events_url":"https://api.github.com/users/braintreeps/received_events","type":"User","site_admin":false},"repo":{"id":17686069,"name":"formatter.js","full_name":"braintreeps/formatter.js","owner":{"login":"braintreeps","id":200407,"avatar_url":"https://avatars.githubusercontent.com/u/200407?","gravatar_id":"ee7b6959f53d27ac8ff4ac35ef942948","url":"https://api.github.com/users/braintreeps","html_url":"https://github.com/braintreeps","followers_url":"https://api.github.com/users/braintreeps/followers","following_url":"https://api.github.com/users/braintreeps/following{/other_user}","gists_url":"https://api.github.com/users/braintreeps/gists{/gist_id}","starred_url":"https://api.github.com/users/braintreeps/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/braintreeps/subscriptions","organizations_url":"https://api.github.com/users/braintreeps/orgs","repos_url":"https://api.github.com/users/braintreeps/repos","events_url":"https://api.github.com/users/braintreeps/events{/privacy}","received_events_url":"https://api.github.com/users/braintreeps/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/braintreeps/formatter.js","description":"Format html inputs to match a specified pattern","fork":true,"url":"https://api.github.com/repos/braintreeps/formatter.js","forks_url":"https://api.github.com/repos/braintreeps/formatter.js/forks","keys_url":"https://api.github.com/repos/braintreeps/formatter.js/keys{/key_id}","collaborators_url":"https://api.github.com/repos/braintreeps/formatter.js/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/braintreeps/formatter.js/teams","hooks_url":"https://api.github.com/repos/braintreeps/formatter.js/hooks","issue_events_url":"https://api.github.com/repos/braintreeps/formatter.js/issues/events{/number}","events_url":"https://api.github.com/repos/braintreeps/formatter.js/events","assignees_url":"https://api.github.com/repos/braintreeps/formatter.js/assignees{/user}","branches_url":"https://api.github.com/repos/braintreeps/formatter.js/branches{/branch}","tags_url":"https://api.github.com/repos/braintreeps/formatter.js/tags","blobs_url":"https://api.github.com/repos/braintreeps/formatter.js/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/braintreeps/formatter.js/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/braintreeps/formatter.js/git/refs{/sha}","trees_url":"https://api.github.com/repos/braintreeps/formatter.js/git/trees{/sha}","statuses_url":"https://api.github.com/repos/braintreeps/formatter.js/statuses/{sha}","languages_url":"https://api.github.com/repos/braintreeps/formatter.js/languages","stargazers_url":"https://api.github.com/repos/braintreeps/formatter.js/stargazers","contributors_url":"https://api.github.com/repos/braintreeps/formatter.js/contributors","subscribers_url":"https://api.github.com/repos/braintreeps/formatter.js/subscribers","subscription_url":"https://api.github.com/repos/braintreeps/formatter.js/subscription","commits_url":"https://api.github.com/repos/braintreeps/formatter.js/commits{/sha}","git_commits_url":"https://api.github.com/repos/braintreeps/formatter.js/git/commits{/sha}","comments_url":"https://api.github.com/repos/braintreeps/formatter.js/comments{/number}","issue_comment_url":"https://api.github.com/repos/braintreeps/formatter.js/issues/comments/{number}","contents_url":"https://api.github.com/repos/braintreeps/formatter.js/contents/{+path}","compare_url":"https://api.github.com/repos/braintreeps/formatter.js/compare/{base}...{head}","merges_url":"https://api.github.com/repos/braintreeps/formatter.js/merges","archive_url":"https://api.github.com/repos/braintreeps/formatter.js/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/braintreeps/formatter.js/downloads","issues_url":"https://api.github.com/repos/braintreeps/formatter.js/issues{/number}","pulls_url":"https://api.github.com/repos/braintreeps/formatter.js/pulls{/number}","milestones_url":"https://api.github.com/repos/braintreeps/formatter.js/milestones{/number}","notifications_url":"https://api.github.com/repos/braintreeps/formatter.js/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/braintreeps/formatter.js/labels{/name}","releases_url":"https://api.github.com/repos/braintreeps/formatter.js/releases{/id}","created_at":"2014-03-12T22:16:55Z","updated_at":"2014-03-20T00:29:10Z","pushed_at":"2014-03-19T04:06:45Z","git_url":"git://github.com/braintreeps/formatter.js.git","ssh_url":"git@github.com:braintreeps/formatter.js.git","clone_url":"https://github.com/braintreeps/formatter.js.git","svn_url":"https://github.com/braintreeps/formatter.js","homepage":"http://firstopinion.github.io/formatter.js ","size":215,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":false,"has_downloads":true,"has_wiki":true,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master","master_branch":"master"}},"base":{"label":"firstopinion:master","ref":"master","sha":"56be36bf0ddb487b947ea10299091c2a9b5694e5","user":{"login":"firstopinion","id":3673684,"avatar_url":"https://avatars.githubusercontent.com/u/3673684?","gravatar_id":"46a806500efce66927490805674ad7fd","url":"https://api.github.com/users/firstopinion","html_url":"https://github.com/firstopinion","followers_url":"https://api.github.com/users/firstopinion/followers","following_url":"https://api.github.com/users/firstopinion/following{/other_user}","gists_url":"https://api.github.com/users/firstopinion/gists{/gist_id}","starred_url":"https://api.github.com/users/firstopinion/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/firstopinion/subscriptions","organizations_url":"https://api.github.com/users/firstopinion/orgs","repos_url":"https://api.github.com/users/firstopinion/repos","events_url":"https://api.github.com/users/firstopinion/events{/privacy}","received_events_url":"https://api.github.com/users/firstopinion/received_events","type":"Organization","site_admin":false},"repo":{"id":12876724,"name":"formatter.js","full_name":"firstopinion/formatter.js","owner":{"login":"firstopinion","id":3673684,"avatar_url":"https://avatars.githubusercontent.com/u/3673684?","gravatar_id":"46a806500efce66927490805674ad7fd","url":"https://api.github.com/users/firstopinion","html_url":"https://github.com/firstopinion","followers_url":"https://api.github.com/users/firstopinion/followers","following_url":"https://api.github.com/users/firstopinion/following{/other_user}","gists_url":"https://api.github.com/users/firstopinion/gists{/gist_id}","starred_url":"https://api.github.com/users/firstopinion/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/firstopinion/subscriptions","organizations_url":"https://api.github.com/users/firstopinion/orgs","repos_url":"https://api.github.com/users/firstopinion/repos","events_url":"https://api.github.com/users/firstopinion/events{/privacy}","received_events_url":"https://api.github.com/users/firstopinion/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/firstopinion/formatter.js","description":"Format html inputs to match a specified pattern","fork":false,"url":"https://api.github.com/repos/firstopinion/formatter.js","forks_url":"https://api.github.com/repos/firstopinion/formatter.js/forks","keys_url":"https://api.github.com/repos/firstopinion/formatter.js/keys{/key_id}","collaborators_url":"https://api.github.com/repos/firstopinion/formatter.js/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/firstopinion/formatter.js/teams","hooks_url":"https://api.github.com/repos/firstopinion/formatter.js/hooks","issue_events_url":"https://api.github.com/repos/firstopinion/formatter.js/issues/events{/number}","events_url":"https://api.github.com/repos/firstopinion/formatter.js/events","assignees_url":"https://api.github.com/repos/firstopinion/formatter.js/assignees{/user}","branches_url":"https://api.github.com/repos/firstopinion/formatter.js/branches{/branch}","tags_url":"https://api.github.com/repos/firstopinion/formatter.js/tags","blobs_url":"https://api.github.com/repos/firstopinion/formatter.js/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/firstopinion/formatter.js/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/firstopinion/formatter.js/git/refs{/sha}","trees_url":"https://api.github.com/repos/firstopinion/formatter.js/git/trees{/sha}","statuses_url":"https://api.github.com/repos/firstopinion/formatter.js/statuses/{sha}","languages_url":"https://api.github.com/repos/firstopinion/formatter.js/languages","stargazers_url":"https://api.github.com/repos/firstopinion/formatter.js/stargazers","contributors_url":"https://api.github.com/repos/firstopinion/formatter.js/contributors","subscribers_url":"https://api.github.com/repos/firstopinion/formatter.js/subscribers","subscription_url":"https://api.github.com/repos/firstopinion/formatter.js/subscription","commits_url":"https://api.github.com/repos/firstopinion/formatter.js/commits{/sha}","git_commits_url":"https://api.github.com/repos/firstopinion/formatter.js/git/commits{/sha}","comments_url":"https://api.github.com/repos/firstopinion/formatter.js/comments{/number}","issue_comment_url":"https://api.github.com/repos/firstopinion/formatter.js/issues/comments/{number}","contents_url":"https://api.github.com/repos/firstopinion/formatter.js/contents/{+path}","compare_url":"https://api.github.com/repos/firstopinion/formatter.js/compare/{base}...{head}","merges_url":"https://api.github.com/repos/firstopinion/formatter.js/merges","archive_url":"https://api.github.com/repos/firstopinion/formatter.js/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/firstopinion/formatter.js/downloads","issues_url":"https://api.github.com/repos/firstopinion/formatter.js/issues{/number}","pulls_url":"https://api.github.com/repos/firstopinion/formatter.js/pulls{/number}","milestones_url":"https://api.github.com/repos/firstopinion/formatter.js/milestones{/number}","notifications_url":"https://api.github.com/repos/firstopinion/formatter.js/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/firstopinion/formatter.js/labels{/name}","releases_url":"https://api.github.com/repos/firstopinion/formatter.js/releases{/id}","created_at":"2013-09-16T19:38:10Z","updated_at":"2014-03-20T00:29:10Z","pushed_at":"2014-03-20T00:29:10Z","git_url":"git://github.com/firstopinion/formatter.js.git","ssh_url":"git@github.com:firstopinion/formatter.js.git","clone_url":"https://github.com/firstopinion/formatter.js.git","svn_url":"https://github.com/firstopinion/formatter.js","homepage":"http://firstopinion.github.io/formatter.js ","size":604,"stargazers_count":1921,"watchers_count":1921,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"forks_count":115,"mirror_url":null,"open_issues_count":10,"forks":115,"open_issues":10,"watchers":1921,"default_branch":"master","master_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/firstopinion/formatter.js/pulls/38"},"html":{"href":"https://github.com/firstopinion/formatter.js/pull/38"},"issue":{"href":"https://api.github.com/repos/firstopinion/formatter.js/issues/38"},"comments":{"href":"https://api.github.com/repos/firstopinion/formatter.js/issues/38/comments"},"review_comments":{"href":"https://api.github.com/repos/firstopinion/formatter.js/pulls/38/comments"},"review_comment":{"href":"https://api.github.com/repos/firstopinion/formatter.js/pulls/comments/{number}"},"commits":{"href":"https://api.github.com/repos/firstopinion/formatter.js/pulls/38/commits"},"statuses":{"href":"https://api.github.com/repos/firstopinion/formatter.js/statuses/1239bc92510f7b58a0e7442adf28f6bf7d2d5ada"}},"merged":true,"mergeable":null,"mergeable_state":"unknown","merged_by":{"login":"jaridmargolin","id":933685,"avatar_url":"https://avatars.githubusercontent.com/u/933685?","gravatar_id":"9ade3bc1ed2ae6bfcc94d7cd4157d58b","url":"https://api.github.com/users/jaridmargolin","html_url":"https://github.com/jaridmargolin","followers_url":"https://api.github.com/users/jaridmargolin/followers","following_url":"https://api.github.com/users/jaridmargolin/following{/other_user}","gists_url":"https://api.github.com/users/jaridmargolin/gists{/gist_id}","starred_url":"https://api.github.com/users/jaridmargolin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jaridmargolin/subscriptions","organizations_url":"https://api.github.com/users/jaridmargolin/orgs","repos_url":"https://api.github.com/users/jaridmargolin/repos","events_url":"https://api.github.com/users/jaridmargolin/events{/privacy}","received_events_url":"https://api.github.com/users/jaridmargolin/received_events","type":"User","site_admin":false},"comments":4,"review_comments":0,"commits":3,"additions":741,"deletions":96,"changed_files":14}}