{"action":"created","comment":{"url":"https://api.github.com/repos/economist-components/component-toggle-display/pulls/comments/46667342","id":46667342,"diff_hunk":"@@ -0,0 +1,36 @@\n+@import '.';\n+\n+.toggle-display {\n+  margin-left: 2rem;\n+}\n+\n+.toggle-display * {\n+  line-height: 0;\n+}\n+\n+.toggle-display__link {\n+  background-color: #e3120b;\n+}\n+\n+[data-display=\"open\"] .toggle-display__link {","path":"example.css","position":15,"original_position":15,"commit_id":"015bb4a828417bb96a6c478848aa25dd3e45b6b7","original_commit_id":"015bb4a828417bb96a6c478848aa25dd3e45b6b7","user":{"login":"keithamus","id":118266,"avatar_url":"https://avatars.githubusercontent.com/u/118266?v=3","gravatar_id":"","url":"https://api.github.com/users/keithamus","html_url":"https://github.com/keithamus","followers_url":"https://api.github.com/users/keithamus/followers","following_url":"https://api.github.com/users/keithamus/following{/other_user}","gists_url":"https://api.github.com/users/keithamus/gists{/gist_id}","starred_url":"https://api.github.com/users/keithamus/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/keithamus/subscriptions","organizations_url":"https://api.github.com/users/keithamus/orgs","repos_url":"https://api.github.com/users/keithamus/repos","events_url":"https://api.github.com/users/keithamus/events{/privacy}","received_events_url":"https://api.github.com/users/keithamus/received_events","type":"User","site_admin":false},"body":"This attribute may well be on another component up the tree, so it'd be good to specify which element you're hooking off of:\r\n\r\n```css\r\n.toggle-display [data-display=\"open\"] .toggle-display__link {\r\n```","created_at":"2015-12-04T10:22:02Z","updated_at":"2015-12-04T10:22:02Z","html_url":"https://github.com/economist-components/component-toggle-display/pull/1#discussion_r46667342","pull_request_url":"https://api.github.com/repos/economist-components/component-toggle-display/pulls/1","_links":{"self":{"href":"https://api.github.com/repos/economist-components/component-toggle-display/pulls/comments/46667342"},"html":{"href":"https://github.com/economist-components/component-toggle-display/pull/1#discussion_r46667342"},"pull_request":{"href":"https://api.github.com/repos/economist-components/component-toggle-display/pulls/1"}}},"pull_request":{"url":"https://api.github.com/repos/economist-components/component-toggle-display/pulls/1","id":52132775,"html_url":"https://github.com/economist-components/component-toggle-display/pull/1","diff_url":"https://github.com/economist-components/component-toggle-display/pull/1.diff","patch_url":"https://github.com/economist-components/component-toggle-display/pull/1.patch","issue_url":"https://api.github.com/repos/economist-components/component-toggle-display/issues/1","number":1,"state":"open","locked":false,"title":"Initial commit with working component and tests","user":{"login":"danielmoll","id":1107257,"avatar_url":"https://avatars.githubusercontent.com/u/1107257?v=3","gravatar_id":"","url":"https://api.github.com/users/danielmoll","html_url":"https://github.com/danielmoll","followers_url":"https://api.github.com/users/danielmoll/followers","following_url":"https://api.github.com/users/danielmoll/following{/other_user}","gists_url":"https://api.github.com/users/danielmoll/gists{/gist_id}","starred_url":"https://api.github.com/users/danielmoll/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/danielmoll/subscriptions","organizations_url":"https://api.github.com/users/danielmoll/orgs","repos_url":"https://api.github.com/users/danielmoll/repos","events_url":"https://api.github.com/users/danielmoll/events{/privacy}","received_events_url":"https://api.github.com/users/danielmoll/received_events","type":"User","site_admin":false},"body":"The idea is that we have a component that wraps child components, an open and close item, and open and close callbacks to enable the toggling the display of the child content. For example, a share bar or hamburger menu.\r\n\r\nYou'll see the below code in `index.es6` this is due to the fact that `react-click-outside` wraps `component-toggle-display` and makes it impossible to test directly. I had problems even with `.renderIntoDocument()` so I should to export the component directly for testing. Please advise if there is a better way?\r\n\r\n```\r\nexport const TestableToggleDisplay = ToggleDisplay;\r\nexport default enhanceWithClickOutside(ToggleDisplay);\r\n```","created_at":"2015-11-30T14:49:43Z","updated_at":"2015-12-04T10:22:02Z","closed_at":null,"merged_at":null,"merge_commit_sha":"93b5a523a20d1957daeaa4e493a9783cef19c2bd","assignee":{"login":"fabiosantoscode","id":1611595,"avatar_url":"https://avatars.githubusercontent.com/u/1611595?v=3","gravatar_id":"","url":"https://api.github.com/users/fabiosantoscode","html_url":"https://github.com/fabiosantoscode","followers_url":"https://api.github.com/users/fabiosantoscode/followers","following_url":"https://api.github.com/users/fabiosantoscode/following{/other_user}","gists_url":"https://api.github.com/users/fabiosantoscode/gists{/gist_id}","starred_url":"https://api.github.com/users/fabiosantoscode/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/fabiosantoscode/subscriptions","organizations_url":"https://api.github.com/users/fabiosantoscode/orgs","repos_url":"https://api.github.com/users/fabiosantoscode/repos","events_url":"https://api.github.com/users/fabiosantoscode/events{/privacy}","received_events_url":"https://api.github.com/users/fabiosantoscode/received_events","type":"User","site_admin":false},"milestone":null,"commits_url":"https://api.github.com/repos/economist-components/component-toggle-display/pulls/1/commits","review_comments_url":"https://api.github.com/repos/economist-components/component-toggle-display/pulls/1/comments","review_comment_url":"https://api.github.com/repos/economist-components/component-toggle-display/pulls/comments{/number}","comments_url":"https://api.github.com/repos/economist-components/component-toggle-display/issues/1/comments","statuses_url":"https://api.github.com/repos/economist-components/component-toggle-display/statuses/015bb4a828417bb96a6c478848aa25dd3e45b6b7","head":{"label":"danielmoll:initial-commit","ref":"initial-commit","sha":"015bb4a828417bb96a6c478848aa25dd3e45b6b7","user":{"login":"danielmoll","id":1107257,"avatar_url":"https://avatars.githubusercontent.com/u/1107257?v=3","gravatar_id":"","url":"https://api.github.com/users/danielmoll","html_url":"https://github.com/danielmoll","followers_url":"https://api.github.com/users/danielmoll/followers","following_url":"https://api.github.com/users/danielmoll/following{/other_user}","gists_url":"https://api.github.com/users/danielmoll/gists{/gist_id}","starred_url":"https://api.github.com/users/danielmoll/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/danielmoll/subscriptions","organizations_url":"https://api.github.com/users/danielmoll/orgs","repos_url":"https://api.github.com/users/danielmoll/repos","events_url":"https://api.github.com/users/danielmoll/events{/privacy}","received_events_url":"https://api.github.com/users/danielmoll/received_events","type":"User","site_admin":false},"repo":{"id":46986146,"name":"component-toggle-display","full_name":"danielmoll/component-toggle-display","owner":{"login":"danielmoll","id":1107257,"avatar_url":"https://avatars.githubusercontent.com/u/1107257?v=3","gravatar_id":"","url":"https://api.github.com/users/danielmoll","html_url":"https://github.com/danielmoll","followers_url":"https://api.github.com/users/danielmoll/followers","following_url":"https://api.github.com/users/danielmoll/following{/other_user}","gists_url":"https://api.github.com/users/danielmoll/gists{/gist_id}","starred_url":"https://api.github.com/users/danielmoll/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/danielmoll/subscriptions","organizations_url":"https://api.github.com/users/danielmoll/orgs","repos_url":"https://api.github.com/users/danielmoll/repos","events_url":"https://api.github.com/users/danielmoll/events{/privacy}","received_events_url":"https://api.github.com/users/danielmoll/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/danielmoll/component-toggle-display","description":"","fork":true,"url":"https://api.github.com/repos/danielmoll/component-toggle-display","forks_url":"https://api.github.com/repos/danielmoll/component-toggle-display/forks","keys_url":"https://api.github.com/repos/danielmoll/component-toggle-display/keys{/key_id}","collaborators_url":"https://api.github.com/repos/danielmoll/component-toggle-display/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/danielmoll/component-toggle-display/teams","hooks_url":"https://api.github.com/repos/danielmoll/component-toggle-display/hooks","issue_events_url":"https://api.github.com/repos/danielmoll/component-toggle-display/issues/events{/number}","events_url":"https://api.github.com/repos/danielmoll/component-toggle-display/events","assignees_url":"https://api.github.com/repos/danielmoll/component-toggle-display/assignees{/user}","branches_url":"https://api.github.com/repos/danielmoll/component-toggle-display/branches{/branch}","tags_url":"https://api.github.com/repos/danielmoll/component-toggle-display/tags","blobs_url":"https://api.github.com/repos/danielmoll/component-toggle-display/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/danielmoll/component-toggle-display/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/danielmoll/component-toggle-display/git/refs{/sha}","trees_url":"https://api.github.com/repos/danielmoll/component-toggle-display/git/trees{/sha}","statuses_url":"https://api.github.com/repos/danielmoll/component-toggle-display/statuses/{sha}","languages_url":"https://api.github.com/repos/danielmoll/component-toggle-display/languages","stargazers_url":"https://api.github.com/repos/danielmoll/component-toggle-display/stargazers","contributors_url":"https://api.github.com/repos/danielmoll/component-toggle-display/contributors","subscribers_url":"https://api.github.com/repos/danielmoll/component-toggle-display/subscribers","subscription_url":"https://api.github.com/repos/danielmoll/component-toggle-display/subscription","commits_url":"https://api.github.com/repos/danielmoll/component-toggle-display/commits{/sha}","git_commits_url":"https://api.github.com/repos/danielmoll/component-toggle-display/git/commits{/sha}","comments_url":"https://api.github.com/repos/danielmoll/component-toggle-display/comments{/number}","issue_comment_url":"https://api.github.com/repos/danielmoll/component-toggle-display/issues/comments{/number}","contents_url":"https://api.github.com/repos/danielmoll/component-toggle-display/contents/{+path}","compare_url":"https://api.github.com/repos/danielmoll/component-toggle-display/compare/{base}...{head}","merges_url":"https://api.github.com/repos/danielmoll/component-toggle-display/merges","archive_url":"https://api.github.com/repos/danielmoll/component-toggle-display/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/danielmoll/component-toggle-display/downloads","issues_url":"https://api.github.com/repos/danielmoll/component-toggle-display/issues{/number}","pulls_url":"https://api.github.com/repos/danielmoll/component-toggle-display/pulls{/number}","milestones_url":"https://api.github.com/repos/danielmoll/component-toggle-display/milestones{/number}","notifications_url":"https://api.github.com/repos/danielmoll/component-toggle-display/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/danielmoll/component-toggle-display/labels{/name}","releases_url":"https://api.github.com/repos/danielmoll/component-toggle-display/releases{/id}","created_at":"2015-11-27T15:06:43Z","updated_at":"2015-11-27T15:05:02Z","pushed_at":"2015-12-02T17:28:21Z","git_url":"git://github.com/danielmoll/component-toggle-display.git","ssh_url":"git@github.com:danielmoll/component-toggle-display.git","clone_url":"https://github.com/danielmoll/component-toggle-display.git","svn_url":"https://github.com/danielmoll/component-toggle-display","homepage":null,"size":3,"stargazers_count":0,"watchers_count":0,"language":null,"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":"economist-components:master","ref":"master","sha":"e997d90dbf738d8259074569ab1a4d7a64fb34ad","user":{"login":"economist-components","id":14197671,"avatar_url":"https://avatars.githubusercontent.com/u/14197671?v=3","gravatar_id":"","url":"https://api.github.com/users/economist-components","html_url":"https://github.com/economist-components","followers_url":"https://api.github.com/users/economist-components/followers","following_url":"https://api.github.com/users/economist-components/following{/other_user}","gists_url":"https://api.github.com/users/economist-components/gists{/gist_id}","starred_url":"https://api.github.com/users/economist-components/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/economist-components/subscriptions","organizations_url":"https://api.github.com/users/economist-components/orgs","repos_url":"https://api.github.com/users/economist-components/repos","events_url":"https://api.github.com/users/economist-components/events{/privacy}","received_events_url":"https://api.github.com/users/economist-components/received_events","type":"Organization","site_admin":false},"repo":{"id":46986060,"name":"component-toggle-display","full_name":"economist-components/component-toggle-display","owner":{"login":"economist-components","id":14197671,"avatar_url":"https://avatars.githubusercontent.com/u/14197671?v=3","gravatar_id":"","url":"https://api.github.com/users/economist-components","html_url":"https://github.com/economist-components","followers_url":"https://api.github.com/users/economist-components/followers","following_url":"https://api.github.com/users/economist-components/following{/other_user}","gists_url":"https://api.github.com/users/economist-components/gists{/gist_id}","starred_url":"https://api.github.com/users/economist-components/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/economist-components/subscriptions","organizations_url":"https://api.github.com/users/economist-components/orgs","repos_url":"https://api.github.com/users/economist-components/repos","events_url":"https://api.github.com/users/economist-components/events{/privacy}","received_events_url":"https://api.github.com/users/economist-components/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/economist-components/component-toggle-display","description":"","fork":false,"url":"https://api.github.com/repos/economist-components/component-toggle-display","forks_url":"https://api.github.com/repos/economist-components/component-toggle-display/forks","keys_url":"https://api.github.com/repos/economist-components/component-toggle-display/keys{/key_id}","collaborators_url":"https://api.github.com/repos/economist-components/component-toggle-display/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/economist-components/component-toggle-display/teams","hooks_url":"https://api.github.com/repos/economist-components/component-toggle-display/hooks","issue_events_url":"https://api.github.com/repos/economist-components/component-toggle-display/issues/events{/number}","events_url":"https://api.github.com/repos/economist-components/component-toggle-display/events","assignees_url":"https://api.github.com/repos/economist-components/component-toggle-display/assignees{/user}","branches_url":"https://api.github.com/repos/economist-components/component-toggle-display/branches{/branch}","tags_url":"https://api.github.com/repos/economist-components/component-toggle-display/tags","blobs_url":"https://api.github.com/repos/economist-components/component-toggle-display/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/economist-components/component-toggle-display/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/economist-components/component-toggle-display/git/refs{/sha}","trees_url":"https://api.github.com/repos/economist-components/component-toggle-display/git/trees{/sha}","statuses_url":"https://api.github.com/repos/economist-components/component-toggle-display/statuses/{sha}","languages_url":"https://api.github.com/repos/economist-components/component-toggle-display/languages","stargazers_url":"https://api.github.com/repos/economist-components/component-toggle-display/stargazers","contributors_url":"https://api.github.com/repos/economist-components/component-toggle-display/contributors","subscribers_url":"https://api.github.com/repos/economist-components/component-toggle-display/subscribers","subscription_url":"https://api.github.com/repos/economist-components/component-toggle-display/subscription","commits_url":"https://api.github.com/repos/economist-components/component-toggle-display/commits{/sha}","git_commits_url":"https://api.github.com/repos/economist-components/component-toggle-display/git/commits{/sha}","comments_url":"https://api.github.com/repos/economist-components/component-toggle-display/comments{/number}","issue_comment_url":"https://api.github.com/repos/economist-components/component-toggle-display/issues/comments{/number}","contents_url":"https://api.github.com/repos/economist-components/component-toggle-display/contents/{+path}","compare_url":"https://api.github.com/repos/economist-components/component-toggle-display/compare/{base}...{head}","merges_url":"https://api.github.com/repos/economist-components/component-toggle-display/merges","archive_url":"https://api.github.com/repos/economist-components/component-toggle-display/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/economist-components/component-toggle-display/downloads","issues_url":"https://api.github.com/repos/economist-components/component-toggle-display/issues{/number}","pulls_url":"https://api.github.com/repos/economist-components/component-toggle-display/pulls{/number}","milestones_url":"https://api.github.com/repos/economist-components/component-toggle-display/milestones{/number}","notifications_url":"https://api.github.com/repos/economist-components/component-toggle-display/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/economist-components/component-toggle-display/labels{/name}","releases_url":"https://api.github.com/repos/economist-components/component-toggle-display/releases{/id}","created_at":"2015-11-27T15:05:02Z","updated_at":"2015-11-27T15:05:02Z","pushed_at":"2015-12-02T17:28:21Z","git_url":"git://github.com/economist-components/component-toggle-display.git","ssh_url":"git@github.com:economist-components/component-toggle-display.git","clone_url":"https://github.com/economist-components/component-toggle-display.git","svn_url":"https://github.com/economist-components/component-toggle-display","homepage":null,"size":0,"stargazers_count":0,"watchers_count":0,"language":null,"has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1,"mirror_url":null,"open_issues_count":1,"forks":1,"open_issues":1,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/economist-components/component-toggle-display/pulls/1"},"html":{"href":"https://github.com/economist-components/component-toggle-display/pull/1"},"issue":{"href":"https://api.github.com/repos/economist-components/component-toggle-display/issues/1"},"comments":{"href":"https://api.github.com/repos/economist-components/component-toggle-display/issues/1/comments"},"review_comments":{"href":"https://api.github.com/repos/economist-components/component-toggle-display/pulls/1/comments"},"review_comment":{"href":"https://api.github.com/repos/economist-components/component-toggle-display/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/economist-components/component-toggle-display/pulls/1/commits"},"statuses":{"href":"https://api.github.com/repos/economist-components/component-toggle-display/statuses/015bb4a828417bb96a6c478848aa25dd3e45b6b7"}}}}