{"action":"created","comment":{"url":"https://api.github.com/repos/angular/angular.js/pulls/comments/23474092","id":23474092,"diff_hunk":"@@ -83,7 +83,8 @@ function $AriaProvider() {\n     ariaMultiline: true,\n     ariaValue: true,\n     tabindex: true,\n-    bindKeypress: true\n+    bindKeypress: true,\n+    keypressNodeNames: ['DIV', 'LI']","path":"src/ngAria/aria.js","position":6,"original_position":6,"commit_id":"93dd331076c16ce48936ecba5c1edb26be791d02","original_commit_id":"93dd331076c16ce48936ecba5c1edb26be791d02","user":{"login":"marcysutton","id":1045233,"avatar_url":"https://avatars.githubusercontent.com/u/1045233?v=3","gravatar_id":"","url":"https://api.github.com/users/marcysutton","html_url":"https://github.com/marcysutton","followers_url":"https://api.github.com/users/marcysutton/followers","following_url":"https://api.github.com/users/marcysutton/following{/other_user}","gists_url":"https://api.github.com/users/marcysutton/gists{/gist_id}","starred_url":"https://api.github.com/users/marcysutton/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/marcysutton/subscriptions","organizations_url":"https://api.github.com/users/marcysutton/orgs","repos_url":"https://api.github.com/users/marcysutton/repos","events_url":"https://api.github.com/users/marcysutton/events{/privacy}","received_events_url":"https://api.github.com/users/marcysutton/received_events","type":"User","site_admin":false},"body":"Fair point. `<button>` is the biggest issue we had, since it gets both click and keypress. `<a>` should not be used with `ng-click` (that's what buttons are for) but rather `ng-href` and routing...although I suppose that could be abused. There's also the `<details>`/`<summary>` elements, `<dialog>`, form controls, and [a few more](http://www.w3.org/html/wg/drafts/html/master/interactive-elements.html). An interesting thing to consider, as well, is the work being done on Custom Elements and tabindex: https://docs.google.com/document/d/1k93Ez6yNSyWQDtGjdJJqTBPmljk9l2WS3JTe5OHHB50/edit#heading=h.tf9twftfr65h\r\n\r\nSo, we need some mechanism of checking whether or not to apply keypress–I'm personally in favor of opt-in for `<div>` and `<li>` so that it limits the scope of this behavior. It's just a question of whether we want that list to be configurable.","created_at":"2015-01-23T19:39:00Z","updated_at":"2015-01-23T19:39:00Z","html_url":"https://github.com/angular/angular.js/pull/10766#discussion_r23474092","pull_request_url":"https://api.github.com/repos/angular/angular.js/pulls/10766","_links":{"self":{"href":"https://api.github.com/repos/angular/angular.js/pulls/comments/23474092"},"html":{"href":"https://github.com/angular/angular.js/pull/10766#discussion_r23474092"},"pull_request":{"href":"https://api.github.com/repos/angular/angular.js/pulls/10766"}}},"pull_request":{"url":"https://api.github.com/repos/angular/angular.js/pulls/10766","id":27458756,"html_url":"https://github.com/angular/angular.js/pull/10766","diff_url":"https://github.com/angular/angular.js/pull/10766.diff","patch_url":"https://github.com/angular/angular.js/pull/10766.patch","issue_url":"https://api.github.com/repos/angular/angular.js/issues/10766","number":10766,"state":"open","locked":false,"title":"bug(ngAria): native controls fire a single click event","user":{"login":"marcysutton","id":1045233,"avatar_url":"https://avatars.githubusercontent.com/u/1045233?v=3","gravatar_id":"","url":"https://api.github.com/users/marcysutton","html_url":"https://github.com/marcysutton","followers_url":"https://api.github.com/users/marcysutton/followers","following_url":"https://api.github.com/users/marcysutton/following{/other_user}","gists_url":"https://api.github.com/users/marcysutton/gists{/gist_id}","starred_url":"https://api.github.com/users/marcysutton/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/marcysutton/subscriptions","organizations_url":"https://api.github.com/users/marcysutton/orgs","repos_url":"https://api.github.com/users/marcysutton/repos","events_url":"https://api.github.com/users/marcysutton/events{/privacy}","received_events_url":"https://api.github.com/users/marcysutton/received_events","type":"User","site_admin":false},"body":"To fix the widespread accessibility issue of `ngClick` on divs, ngAria dynamically binds `keypress` in addition to `tabIndex`. As first implemented, this introduced a bug where `<button>` elements would have both events bound, causing multiple callbacks to fire. This PR makes limits the addition of keypress to `<div>` and `<li>`, to start, and adds an array as a config option so developers can add or remove elements from the list.\r\n\r\nCloses https://github.com/angular/angular.js/issues/10388. Thanks to @caitp for the help & unit test on native elements.","created_at":"2015-01-15T20:18:52Z","updated_at":"2015-01-23T19:39:00Z","closed_at":null,"merged_at":null,"merge_commit_sha":"f992aa6ad4655b03835eb8540e8cf1fca21b97c5","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/angular/angular.js/pulls/10766/commits","review_comments_url":"https://api.github.com/repos/angular/angular.js/pulls/10766/comments","review_comment_url":"https://api.github.com/repos/angular/angular.js/pulls/comments/{number}","comments_url":"https://api.github.com/repos/angular/angular.js/issues/10766/comments","statuses_url":"https://api.github.com/repos/angular/angular.js/statuses/93dd331076c16ce48936ecba5c1edb26be791d02","head":{"label":"marcysutton:ngaria-ngclick-bugfix","ref":"ngaria-ngclick-bugfix","sha":"93dd331076c16ce48936ecba5c1edb26be791d02","user":{"login":"marcysutton","id":1045233,"avatar_url":"https://avatars.githubusercontent.com/u/1045233?v=3","gravatar_id":"","url":"https://api.github.com/users/marcysutton","html_url":"https://github.com/marcysutton","followers_url":"https://api.github.com/users/marcysutton/followers","following_url":"https://api.github.com/users/marcysutton/following{/other_user}","gists_url":"https://api.github.com/users/marcysutton/gists{/gist_id}","starred_url":"https://api.github.com/users/marcysutton/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/marcysutton/subscriptions","organizations_url":"https://api.github.com/users/marcysutton/orgs","repos_url":"https://api.github.com/users/marcysutton/repos","events_url":"https://api.github.com/users/marcysutton/events{/privacy}","received_events_url":"https://api.github.com/users/marcysutton/received_events","type":"User","site_admin":false},"repo":{"id":24772089,"name":"angular.js","full_name":"marcysutton/angular.js","owner":{"login":"marcysutton","id":1045233,"avatar_url":"https://avatars.githubusercontent.com/u/1045233?v=3","gravatar_id":"","url":"https://api.github.com/users/marcysutton","html_url":"https://github.com/marcysutton","followers_url":"https://api.github.com/users/marcysutton/followers","following_url":"https://api.github.com/users/marcysutton/following{/other_user}","gists_url":"https://api.github.com/users/marcysutton/gists{/gist_id}","starred_url":"https://api.github.com/users/marcysutton/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/marcysutton/subscriptions","organizations_url":"https://api.github.com/users/marcysutton/orgs","repos_url":"https://api.github.com/users/marcysutton/repos","events_url":"https://api.github.com/users/marcysutton/events{/privacy}","received_events_url":"https://api.github.com/users/marcysutton/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/marcysutton/angular.js","description":"HTML enhanced for web apps","fork":true,"url":"https://api.github.com/repos/marcysutton/angular.js","forks_url":"https://api.github.com/repos/marcysutton/angular.js/forks","keys_url":"https://api.github.com/repos/marcysutton/angular.js/keys{/key_id}","collaborators_url":"https://api.github.com/repos/marcysutton/angular.js/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/marcysutton/angular.js/teams","hooks_url":"https://api.github.com/repos/marcysutton/angular.js/hooks","issue_events_url":"https://api.github.com/repos/marcysutton/angular.js/issues/events{/number}","events_url":"https://api.github.com/repos/marcysutton/angular.js/events","assignees_url":"https://api.github.com/repos/marcysutton/angular.js/assignees{/user}","branches_url":"https://api.github.com/repos/marcysutton/angular.js/branches{/branch}","tags_url":"https://api.github.com/repos/marcysutton/angular.js/tags","blobs_url":"https://api.github.com/repos/marcysutton/angular.js/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/marcysutton/angular.js/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/marcysutton/angular.js/git/refs{/sha}","trees_url":"https://api.github.com/repos/marcysutton/angular.js/git/trees{/sha}","statuses_url":"https://api.github.com/repos/marcysutton/angular.js/statuses/{sha}","languages_url":"https://api.github.com/repos/marcysutton/angular.js/languages","stargazers_url":"https://api.github.com/repos/marcysutton/angular.js/stargazers","contributors_url":"https://api.github.com/repos/marcysutton/angular.js/contributors","subscribers_url":"https://api.github.com/repos/marcysutton/angular.js/subscribers","subscription_url":"https://api.github.com/repos/marcysutton/angular.js/subscription","commits_url":"https://api.github.com/repos/marcysutton/angular.js/commits{/sha}","git_commits_url":"https://api.github.com/repos/marcysutton/angular.js/git/commits{/sha}","comments_url":"https://api.github.com/repos/marcysutton/angular.js/comments{/number}","issue_comment_url":"https://api.github.com/repos/marcysutton/angular.js/issues/comments/{number}","contents_url":"https://api.github.com/repos/marcysutton/angular.js/contents/{+path}","compare_url":"https://api.github.com/repos/marcysutton/angular.js/compare/{base}...{head}","merges_url":"https://api.github.com/repos/marcysutton/angular.js/merges","archive_url":"https://api.github.com/repos/marcysutton/angular.js/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/marcysutton/angular.js/downloads","issues_url":"https://api.github.com/repos/marcysutton/angular.js/issues{/number}","pulls_url":"https://api.github.com/repos/marcysutton/angular.js/pulls{/number}","milestones_url":"https://api.github.com/repos/marcysutton/angular.js/milestones{/number}","notifications_url":"https://api.github.com/repos/marcysutton/angular.js/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/marcysutton/angular.js/labels{/name}","releases_url":"https://api.github.com/repos/marcysutton/angular.js/releases{/id}","created_at":"2014-10-03T20:09:52Z","updated_at":"2014-10-03T20:15:47Z","pushed_at":"2015-01-21T00:36:46Z","git_url":"git://github.com/marcysutton/angular.js.git","ssh_url":"git@github.com:marcysutton/angular.js.git","clone_url":"https://github.com/marcysutton/angular.js.git","svn_url":"https://github.com/marcysutton/angular.js","homepage":"http://angularjs.org","size":61321,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"angular:master","ref":"master","sha":"331cac233f56dc7f63ab8ac48de0d40fc7256047","user":{"login":"angular","id":139426,"avatar_url":"https://avatars.githubusercontent.com/u/139426?v=3","gravatar_id":"","url":"https://api.github.com/users/angular","html_url":"https://github.com/angular","followers_url":"https://api.github.com/users/angular/followers","following_url":"https://api.github.com/users/angular/following{/other_user}","gists_url":"https://api.github.com/users/angular/gists{/gist_id}","starred_url":"https://api.github.com/users/angular/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/angular/subscriptions","organizations_url":"https://api.github.com/users/angular/orgs","repos_url":"https://api.github.com/users/angular/repos","events_url":"https://api.github.com/users/angular/events{/privacy}","received_events_url":"https://api.github.com/users/angular/received_events","type":"Organization","site_admin":false},"repo":{"id":460078,"name":"angular.js","full_name":"angular/angular.js","owner":{"login":"angular","id":139426,"avatar_url":"https://avatars.githubusercontent.com/u/139426?v=3","gravatar_id":"","url":"https://api.github.com/users/angular","html_url":"https://github.com/angular","followers_url":"https://api.github.com/users/angular/followers","following_url":"https://api.github.com/users/angular/following{/other_user}","gists_url":"https://api.github.com/users/angular/gists{/gist_id}","starred_url":"https://api.github.com/users/angular/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/angular/subscriptions","organizations_url":"https://api.github.com/users/angular/orgs","repos_url":"https://api.github.com/users/angular/repos","events_url":"https://api.github.com/users/angular/events{/privacy}","received_events_url":"https://api.github.com/users/angular/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/angular/angular.js","description":"HTML enhanced for web apps","fork":false,"url":"https://api.github.com/repos/angular/angular.js","forks_url":"https://api.github.com/repos/angular/angular.js/forks","keys_url":"https://api.github.com/repos/angular/angular.js/keys{/key_id}","collaborators_url":"https://api.github.com/repos/angular/angular.js/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/angular/angular.js/teams","hooks_url":"https://api.github.com/repos/angular/angular.js/hooks","issue_events_url":"https://api.github.com/repos/angular/angular.js/issues/events{/number}","events_url":"https://api.github.com/repos/angular/angular.js/events","assignees_url":"https://api.github.com/repos/angular/angular.js/assignees{/user}","branches_url":"https://api.github.com/repos/angular/angular.js/branches{/branch}","tags_url":"https://api.github.com/repos/angular/angular.js/tags","blobs_url":"https://api.github.com/repos/angular/angular.js/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/angular/angular.js/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/angular/angular.js/git/refs{/sha}","trees_url":"https://api.github.com/repos/angular/angular.js/git/trees{/sha}","statuses_url":"https://api.github.com/repos/angular/angular.js/statuses/{sha}","languages_url":"https://api.github.com/repos/angular/angular.js/languages","stargazers_url":"https://api.github.com/repos/angular/angular.js/stargazers","contributors_url":"https://api.github.com/repos/angular/angular.js/contributors","subscribers_url":"https://api.github.com/repos/angular/angular.js/subscribers","subscription_url":"https://api.github.com/repos/angular/angular.js/subscription","commits_url":"https://api.github.com/repos/angular/angular.js/commits{/sha}","git_commits_url":"https://api.github.com/repos/angular/angular.js/git/commits{/sha}","comments_url":"https://api.github.com/repos/angular/angular.js/comments{/number}","issue_comment_url":"https://api.github.com/repos/angular/angular.js/issues/comments/{number}","contents_url":"https://api.github.com/repos/angular/angular.js/contents/{+path}","compare_url":"https://api.github.com/repos/angular/angular.js/compare/{base}...{head}","merges_url":"https://api.github.com/repos/angular/angular.js/merges","archive_url":"https://api.github.com/repos/angular/angular.js/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/angular/angular.js/downloads","issues_url":"https://api.github.com/repos/angular/angular.js/issues{/number}","pulls_url":"https://api.github.com/repos/angular/angular.js/pulls{/number}","milestones_url":"https://api.github.com/repos/angular/angular.js/milestones{/number}","notifications_url":"https://api.github.com/repos/angular/angular.js/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/angular/angular.js/labels{/name}","releases_url":"https://api.github.com/repos/angular/angular.js/releases{/id}","created_at":"2010-01-06T00:34:37Z","updated_at":"2015-01-23T19:23:59Z","pushed_at":"2015-01-23T19:23:59Z","git_url":"git://github.com/angular/angular.js.git","ssh_url":"git@github.com:angular/angular.js.git","clone_url":"https://github.com/angular/angular.js.git","svn_url":"https://github.com/angular/angular.js","homepage":"http://angularjs.org","size":209168,"stargazers_count":34366,"watchers_count":34366,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":13722,"mirror_url":null,"open_issues_count":1113,"forks":13722,"open_issues":1113,"watchers":34366,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/angular/angular.js/pulls/10766"},"html":{"href":"https://github.com/angular/angular.js/pull/10766"},"issue":{"href":"https://api.github.com/repos/angular/angular.js/issues/10766"},"comments":{"href":"https://api.github.com/repos/angular/angular.js/issues/10766/comments"},"review_comments":{"href":"https://api.github.com/repos/angular/angular.js/pulls/10766/comments"},"review_comment":{"href":"https://api.github.com/repos/angular/angular.js/pulls/comments/{number}"},"commits":{"href":"https://api.github.com/repos/angular/angular.js/pulls/10766/commits"},"statuses":{"href":"https://api.github.com/repos/angular/angular.js/statuses/93dd331076c16ce48936ecba5c1edb26be791d02"}}}}