{"action":"created","comment":{"url":"https://api.github.com/repos/TechnologyAdvice/stardust/pulls/comments/61656773","id":61656773,"diff_hunk":"@@ -1,5 +1,8 @@\n+import keyboardeventKeyPolyfill from 'keyboardevent-key-polyfill'\n import { deprecateComponent } from './utils/deprecate'\n \n+keyboardeventKeyPolyfill.polyfill()","path":"src/index.js","position":4,"original_position":4,"commit_id":"7ebc55875b28eaab4e3be8c0b8ada67725ea68ab","original_commit_id":"4f1582964e3b8729fb6d3b66a7533358ac57e59a","user":{"login":"jhabdas","id":440298,"avatar_url":"https://avatars.githubusercontent.com/u/440298?v=3","gravatar_id":"","url":"https://api.github.com/users/jhabdas","html_url":"https://github.com/jhabdas","followers_url":"https://api.github.com/users/jhabdas/followers","following_url":"https://api.github.com/users/jhabdas/following{/other_user}","gists_url":"https://api.github.com/users/jhabdas/gists{/gist_id}","starred_url":"https://api.github.com/users/jhabdas/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jhabdas/subscriptions","organizations_url":"https://api.github.com/users/jhabdas/orgs","repos_url":"https://api.github.com/users/jhabdas/repos","events_url":"https://api.github.com/users/jhabdas/events{/privacy}","received_events_url":"https://api.github.com/users/jhabdas/received_events","type":"User","site_admin":false},"body":"Tamping is how Prototype got the job done! :trollface: ","created_at":"2016-04-29T23:17:47Z","updated_at":"2016-04-29T23:17:47Z","html_url":"https://github.com/TechnologyAdvice/stardust/pull/226#discussion_r61656773","pull_request_url":"https://api.github.com/repos/TechnologyAdvice/stardust/pulls/226","_links":{"self":{"href":"https://api.github.com/repos/TechnologyAdvice/stardust/pulls/comments/61656773"},"html":{"href":"https://github.com/TechnologyAdvice/stardust/pull/226#discussion_r61656773"},"pull_request":{"href":"https://api.github.com/repos/TechnologyAdvice/stardust/pulls/226"}}},"pull_request":{"url":"https://api.github.com/repos/TechnologyAdvice/stardust/pulls/226","id":68137142,"html_url":"https://github.com/TechnologyAdvice/stardust/pull/226","diff_url":"https://github.com/TechnologyAdvice/stardust/pull/226.diff","patch_url":"https://github.com/TechnologyAdvice/stardust/pull/226.patch","issue_url":"https://api.github.com/repos/TechnologyAdvice/stardust/issues/226","number":226,"state":"open","locked":false,"title":"Dropdown without jQuery","user":{"login":"levithomason","id":5067638,"avatar_url":"https://avatars.githubusercontent.com/u/5067638?v=3","gravatar_id":"","url":"https://api.github.com/users/levithomason","html_url":"https://github.com/levithomason","followers_url":"https://api.github.com/users/levithomason/followers","following_url":"https://api.github.com/users/levithomason/following{/other_user}","gists_url":"https://api.github.com/users/levithomason/gists{/gist_id}","starred_url":"https://api.github.com/users/levithomason/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/levithomason/subscriptions","organizations_url":"https://api.github.com/users/levithomason/orgs","repos_url":"https://api.github.com/users/levithomason/repos","events_url":"https://api.github.com/users/levithomason/events{/privacy}","received_events_url":"https://api.github.com/users/levithomason/received_events","type":"User","site_admin":false},"body":"# Hey...\r\n\r\nThis is an interim PR.  There are todos, comments, missing features, and ugly things.  There shouldn't be any bugs or cruft, though.\r\n\r\nThe rewrite thus far is >600 lines in the Dropdown and >700 lines in Dropdown tests.  I want to get some eyes and feedback on the functionality and approach thus far before cleaning up and abstracting things.\r\n\r\nThe `multiple` feature will be added in the next Dropdown PR.\r\n\r\n## Areas of concern\r\n\r\nThese are the areas to watch and comment on.  These are some known ugly parts.  They've been added as TODOs to the main PR #206.\r\n\r\n### Events\r\n\r\nWe have two event systems at play, React synthetic events and real DOM events.  You'll see lots of `document.add/removeEventListener` calls.  This is necessary for keyboard and mouse events that are dispatched on the document.  Example, clicking outside the dropdown or pressing escape to close an open dropdown.  Ideally, we'll write a clean abstraction for handling these.  Considering that we need to:\r\n\r\n- prevent duplicate handlers\r\n- cleanup all events on unmount\r\n- provide once() functionality\r\n- add/remove events at any time (not just lifecycle methods)\r\n\r\n### Debug / Logging\r\n\r\nCurrently, nearly every method has a `console.debug()` when called and a `console.log()` for any relevant debugging data.  This would be pulled into an actual debug util.  Consider:\r\n\r\n- [debug](https://www.npmjs.com/package/debug) module\r\n- removal in production code\r\n- runtime flag to enable/disable by module\r\n\r\n### Spreading Consumer Props\r\n\r\nStardust components should spread the consumer's props.  We've experimented with a couple patterns for doing this effectively, though they each beak down.  Consider:\r\n\r\n- every prop not defined in propTypes (public interface) is a consumer prop\r\n- propTypes may be stripped from production code in the future\r\n- using `...props` in `render()` isn't sufficient when breaking down many render methods\r\n\r\nIf it weren't for stripping propTypes in production we may be able to naively:\r\n```js\r\nconst getConsumerProps = (self) => _.omit(self.props, _.keys(self.constructor.propTypes))\r\n```","created_at":"2016-04-27T22:40:39Z","updated_at":"2016-04-29T23:17:47Z","closed_at":null,"merged_at":null,"merge_commit_sha":"2ab771662158394b22106e1d1d43e88863e0a866","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/TechnologyAdvice/stardust/pulls/226/commits","review_comments_url":"https://api.github.com/repos/TechnologyAdvice/stardust/pulls/226/comments","review_comment_url":"https://api.github.com/repos/TechnologyAdvice/stardust/pulls/comments{/number}","comments_url":"https://api.github.com/repos/TechnologyAdvice/stardust/issues/226/comments","statuses_url":"https://api.github.com/repos/TechnologyAdvice/stardust/statuses/7ebc55875b28eaab4e3be8c0b8ada67725ea68ab","head":{"label":"TechnologyAdvice:feature/dropdown-no-jquery","ref":"feature/dropdown-no-jquery","sha":"7ebc55875b28eaab4e3be8c0b8ada67725ea68ab","user":{"login":"TechnologyAdvice","id":6045188,"avatar_url":"https://avatars.githubusercontent.com/u/6045188?v=3","gravatar_id":"","url":"https://api.github.com/users/TechnologyAdvice","html_url":"https://github.com/TechnologyAdvice","followers_url":"https://api.github.com/users/TechnologyAdvice/followers","following_url":"https://api.github.com/users/TechnologyAdvice/following{/other_user}","gists_url":"https://api.github.com/users/TechnologyAdvice/gists{/gist_id}","starred_url":"https://api.github.com/users/TechnologyAdvice/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/TechnologyAdvice/subscriptions","organizations_url":"https://api.github.com/users/TechnologyAdvice/orgs","repos_url":"https://api.github.com/users/TechnologyAdvice/repos","events_url":"https://api.github.com/users/TechnologyAdvice/events{/privacy}","received_events_url":"https://api.github.com/users/TechnologyAdvice/received_events","type":"Organization","site_admin":false},"repo":{"id":37734226,"name":"stardust","full_name":"TechnologyAdvice/stardust","owner":{"login":"TechnologyAdvice","id":6045188,"avatar_url":"https://avatars.githubusercontent.com/u/6045188?v=3","gravatar_id":"","url":"https://api.github.com/users/TechnologyAdvice","html_url":"https://github.com/TechnologyAdvice","followers_url":"https://api.github.com/users/TechnologyAdvice/followers","following_url":"https://api.github.com/users/TechnologyAdvice/following{/other_user}","gists_url":"https://api.github.com/users/TechnologyAdvice/gists{/gist_id}","starred_url":"https://api.github.com/users/TechnologyAdvice/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/TechnologyAdvice/subscriptions","organizations_url":"https://api.github.com/users/TechnologyAdvice/orgs","repos_url":"https://api.github.com/users/TechnologyAdvice/repos","events_url":"https://api.github.com/users/TechnologyAdvice/events{/privacy}","received_events_url":"https://api.github.com/users/TechnologyAdvice/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/TechnologyAdvice/stardust","description":":star2: React component library based on Semantic UI","fork":false,"url":"https://api.github.com/repos/TechnologyAdvice/stardust","forks_url":"https://api.github.com/repos/TechnologyAdvice/stardust/forks","keys_url":"https://api.github.com/repos/TechnologyAdvice/stardust/keys{/key_id}","collaborators_url":"https://api.github.com/repos/TechnologyAdvice/stardust/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/TechnologyAdvice/stardust/teams","hooks_url":"https://api.github.com/repos/TechnologyAdvice/stardust/hooks","issue_events_url":"https://api.github.com/repos/TechnologyAdvice/stardust/issues/events{/number}","events_url":"https://api.github.com/repos/TechnologyAdvice/stardust/events","assignees_url":"https://api.github.com/repos/TechnologyAdvice/stardust/assignees{/user}","branches_url":"https://api.github.com/repos/TechnologyAdvice/stardust/branches{/branch}","tags_url":"https://api.github.com/repos/TechnologyAdvice/stardust/tags","blobs_url":"https://api.github.com/repos/TechnologyAdvice/stardust/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/TechnologyAdvice/stardust/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/TechnologyAdvice/stardust/git/refs{/sha}","trees_url":"https://api.github.com/repos/TechnologyAdvice/stardust/git/trees{/sha}","statuses_url":"https://api.github.com/repos/TechnologyAdvice/stardust/statuses/{sha}","languages_url":"https://api.github.com/repos/TechnologyAdvice/stardust/languages","stargazers_url":"https://api.github.com/repos/TechnologyAdvice/stardust/stargazers","contributors_url":"https://api.github.com/repos/TechnologyAdvice/stardust/contributors","subscribers_url":"https://api.github.com/repos/TechnologyAdvice/stardust/subscribers","subscription_url":"https://api.github.com/repos/TechnologyAdvice/stardust/subscription","commits_url":"https://api.github.com/repos/TechnologyAdvice/stardust/commits{/sha}","git_commits_url":"https://api.github.com/repos/TechnologyAdvice/stardust/git/commits{/sha}","comments_url":"https://api.github.com/repos/TechnologyAdvice/stardust/comments{/number}","issue_comment_url":"https://api.github.com/repos/TechnologyAdvice/stardust/issues/comments{/number}","contents_url":"https://api.github.com/repos/TechnologyAdvice/stardust/contents/{+path}","compare_url":"https://api.github.com/repos/TechnologyAdvice/stardust/compare/{base}...{head}","merges_url":"https://api.github.com/repos/TechnologyAdvice/stardust/merges","archive_url":"https://api.github.com/repos/TechnologyAdvice/stardust/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/TechnologyAdvice/stardust/downloads","issues_url":"https://api.github.com/repos/TechnologyAdvice/stardust/issues{/number}","pulls_url":"https://api.github.com/repos/TechnologyAdvice/stardust/pulls{/number}","milestones_url":"https://api.github.com/repos/TechnologyAdvice/stardust/milestones{/number}","notifications_url":"https://api.github.com/repos/TechnologyAdvice/stardust/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/TechnologyAdvice/stardust/labels{/name}","releases_url":"https://api.github.com/repos/TechnologyAdvice/stardust/releases{/id}","deployments_url":"https://api.github.com/repos/TechnologyAdvice/stardust/deployments","created_at":"2015-06-19T16:47:19Z","updated_at":"2016-04-28T14:05:26Z","pushed_at":"2016-04-29T23:04:55Z","git_url":"git://github.com/TechnologyAdvice/stardust.git","ssh_url":"git@github.com:TechnologyAdvice/stardust.git","clone_url":"https://github.com/TechnologyAdvice/stardust.git","svn_url":"https://github.com/TechnologyAdvice/stardust","homepage":"https://technologyadvice.github.io/stardust","size":9260,"stargazers_count":56,"watchers_count":56,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":4,"mirror_url":null,"open_issues_count":48,"forks":4,"open_issues":48,"watchers":56,"default_branch":"master"}},"base":{"label":"TechnologyAdvice:master","ref":"master","sha":"8985b6423c0370e7c247c2024d2181ff99441531","user":{"login":"TechnologyAdvice","id":6045188,"avatar_url":"https://avatars.githubusercontent.com/u/6045188?v=3","gravatar_id":"","url":"https://api.github.com/users/TechnologyAdvice","html_url":"https://github.com/TechnologyAdvice","followers_url":"https://api.github.com/users/TechnologyAdvice/followers","following_url":"https://api.github.com/users/TechnologyAdvice/following{/other_user}","gists_url":"https://api.github.com/users/TechnologyAdvice/gists{/gist_id}","starred_url":"https://api.github.com/users/TechnologyAdvice/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/TechnologyAdvice/subscriptions","organizations_url":"https://api.github.com/users/TechnologyAdvice/orgs","repos_url":"https://api.github.com/users/TechnologyAdvice/repos","events_url":"https://api.github.com/users/TechnologyAdvice/events{/privacy}","received_events_url":"https://api.github.com/users/TechnologyAdvice/received_events","type":"Organization","site_admin":false},"repo":{"id":37734226,"name":"stardust","full_name":"TechnologyAdvice/stardust","owner":{"login":"TechnologyAdvice","id":6045188,"avatar_url":"https://avatars.githubusercontent.com/u/6045188?v=3","gravatar_id":"","url":"https://api.github.com/users/TechnologyAdvice","html_url":"https://github.com/TechnologyAdvice","followers_url":"https://api.github.com/users/TechnologyAdvice/followers","following_url":"https://api.github.com/users/TechnologyAdvice/following{/other_user}","gists_url":"https://api.github.com/users/TechnologyAdvice/gists{/gist_id}","starred_url":"https://api.github.com/users/TechnologyAdvice/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/TechnologyAdvice/subscriptions","organizations_url":"https://api.github.com/users/TechnologyAdvice/orgs","repos_url":"https://api.github.com/users/TechnologyAdvice/repos","events_url":"https://api.github.com/users/TechnologyAdvice/events{/privacy}","received_events_url":"https://api.github.com/users/TechnologyAdvice/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/TechnologyAdvice/stardust","description":":star2: React component library based on Semantic UI","fork":false,"url":"https://api.github.com/repos/TechnologyAdvice/stardust","forks_url":"https://api.github.com/repos/TechnologyAdvice/stardust/forks","keys_url":"https://api.github.com/repos/TechnologyAdvice/stardust/keys{/key_id}","collaborators_url":"https://api.github.com/repos/TechnologyAdvice/stardust/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/TechnologyAdvice/stardust/teams","hooks_url":"https://api.github.com/repos/TechnologyAdvice/stardust/hooks","issue_events_url":"https://api.github.com/repos/TechnologyAdvice/stardust/issues/events{/number}","events_url":"https://api.github.com/repos/TechnologyAdvice/stardust/events","assignees_url":"https://api.github.com/repos/TechnologyAdvice/stardust/assignees{/user}","branches_url":"https://api.github.com/repos/TechnologyAdvice/stardust/branches{/branch}","tags_url":"https://api.github.com/repos/TechnologyAdvice/stardust/tags","blobs_url":"https://api.github.com/repos/TechnologyAdvice/stardust/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/TechnologyAdvice/stardust/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/TechnologyAdvice/stardust/git/refs{/sha}","trees_url":"https://api.github.com/repos/TechnologyAdvice/stardust/git/trees{/sha}","statuses_url":"https://api.github.com/repos/TechnologyAdvice/stardust/statuses/{sha}","languages_url":"https://api.github.com/repos/TechnologyAdvice/stardust/languages","stargazers_url":"https://api.github.com/repos/TechnologyAdvice/stardust/stargazers","contributors_url":"https://api.github.com/repos/TechnologyAdvice/stardust/contributors","subscribers_url":"https://api.github.com/repos/TechnologyAdvice/stardust/subscribers","subscription_url":"https://api.github.com/repos/TechnologyAdvice/stardust/subscription","commits_url":"https://api.github.com/repos/TechnologyAdvice/stardust/commits{/sha}","git_commits_url":"https://api.github.com/repos/TechnologyAdvice/stardust/git/commits{/sha}","comments_url":"https://api.github.com/repos/TechnologyAdvice/stardust/comments{/number}","issue_comment_url":"https://api.github.com/repos/TechnologyAdvice/stardust/issues/comments{/number}","contents_url":"https://api.github.com/repos/TechnologyAdvice/stardust/contents/{+path}","compare_url":"https://api.github.com/repos/TechnologyAdvice/stardust/compare/{base}...{head}","merges_url":"https://api.github.com/repos/TechnologyAdvice/stardust/merges","archive_url":"https://api.github.com/repos/TechnologyAdvice/stardust/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/TechnologyAdvice/stardust/downloads","issues_url":"https://api.github.com/repos/TechnologyAdvice/stardust/issues{/number}","pulls_url":"https://api.github.com/repos/TechnologyAdvice/stardust/pulls{/number}","milestones_url":"https://api.github.com/repos/TechnologyAdvice/stardust/milestones{/number}","notifications_url":"https://api.github.com/repos/TechnologyAdvice/stardust/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/TechnologyAdvice/stardust/labels{/name}","releases_url":"https://api.github.com/repos/TechnologyAdvice/stardust/releases{/id}","deployments_url":"https://api.github.com/repos/TechnologyAdvice/stardust/deployments","created_at":"2015-06-19T16:47:19Z","updated_at":"2016-04-28T14:05:26Z","pushed_at":"2016-04-29T23:04:55Z","git_url":"git://github.com/TechnologyAdvice/stardust.git","ssh_url":"git@github.com:TechnologyAdvice/stardust.git","clone_url":"https://github.com/TechnologyAdvice/stardust.git","svn_url":"https://github.com/TechnologyAdvice/stardust","homepage":"https://technologyadvice.github.io/stardust","size":9260,"stargazers_count":56,"watchers_count":56,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":4,"mirror_url":null,"open_issues_count":48,"forks":4,"open_issues":48,"watchers":56,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/TechnologyAdvice/stardust/pulls/226"},"html":{"href":"https://github.com/TechnologyAdvice/stardust/pull/226"},"issue":{"href":"https://api.github.com/repos/TechnologyAdvice/stardust/issues/226"},"comments":{"href":"https://api.github.com/repos/TechnologyAdvice/stardust/issues/226/comments"},"review_comments":{"href":"https://api.github.com/repos/TechnologyAdvice/stardust/pulls/226/comments"},"review_comment":{"href":"https://api.github.com/repos/TechnologyAdvice/stardust/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/TechnologyAdvice/stardust/pulls/226/commits"},"statuses":{"href":"https://api.github.com/repos/TechnologyAdvice/stardust/statuses/7ebc55875b28eaab4e3be8c0b8ada67725ea68ab"}}}}