{"action":"created","comment":{"url":"https://api.github.com/repos/concord-consortium/thermoscope/pulls/comments/93507090","pull_request_review_id":14036510,"id":93507090,"diff_hunk":"@@ -111,9 +118,35 @@ export default class Interactive extends PureComponent {\n         newState[\"showNewAtom\"+el] = false;\n         _this.setState(newState);\n         _this.addNewDraggableAtom(el);\n+      } else {\n+        if (d.x > 4.187 && d.x < 4.328 && d.y > 0.141 && d.y < 0.287) {\n+          // mark atoms for deletion\n+          if (!d.marked) {\n+            _this.setState({deleteHover: true});\n+            api.setAtomProperties(i, {marked: 1});\n+          }\n+        } else if (d.marked) {\n+            _this.setState({deleteHover: false});\n+          api.setAtomProperties(i, {marked: 0});\n+        }\n       }\n     });\n \n+    let deleteMarkedAtoms = function() {\n+      let atomsToDelete = [];\n+      for (let i=0, ii=api.getNumberOfAtoms(); i<ii; i++) {\n+        if (api.getAtomProperties(i).marked)\n+          atomsToDelete.push(i);\n+      }\n+      for (let i=atomsToDelete.length-1; i>-1; i--) {\n+        api.removeAtom(atomsToDelete[i]);\n+      }\n+\n+      _this.setState({deleteHover: false});","path":"js/particle-modeler/index.js","position":null,"original_position":53,"commit_id":"6d2d6e6d7efe59082a6f7260eb3c27f99dc55fed","original_commit_id":"82bba96c28f2d460acb933ec2c1a752fdc343cd2","user":{"login":"sfentress","id":35721,"avatar_url":"https://avatars.githubusercontent.com/u/35721?v=3","gravatar_id":"","url":"https://api.github.com/users/sfentress","html_url":"https://github.com/sfentress","followers_url":"https://api.github.com/users/sfentress/followers","following_url":"https://api.github.com/users/sfentress/following{/other_user}","gists_url":"https://api.github.com/users/sfentress/gists{/gist_id}","starred_url":"https://api.github.com/users/sfentress/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sfentress/subscriptions","organizations_url":"https://api.github.com/users/sfentress/orgs","repos_url":"https://api.github.com/users/sfentress/repos","events_url":"https://api.github.com/users/sfentress/events{/privacy}","received_events_url":"https://api.github.com/users/sfentress/received_events","type":"User","site_admin":false},"body":"Totally true, I forget we are using ES6.","created_at":"2016-12-21T19:48:19Z","updated_at":"2016-12-21T19:48:19Z","html_url":"https://github.com/concord-consortium/thermoscope/pull/5#discussion_r93507090","pull_request_url":"https://api.github.com/repos/concord-consortium/thermoscope/pulls/5","_links":{"self":{"href":"https://api.github.com/repos/concord-consortium/thermoscope/pulls/comments/93507090"},"html":{"href":"https://github.com/concord-consortium/thermoscope/pull/5#discussion_r93507090"},"pull_request":{"href":"https://api.github.com/repos/concord-consortium/thermoscope/pulls/5"}}},"pull_request":{"url":"https://api.github.com/repos/concord-consortium/thermoscope/pulls/5","id":98383440,"html_url":"https://github.com/concord-consortium/thermoscope/pull/5","diff_url":"https://github.com/concord-consortium/thermoscope/pull/5.diff","patch_url":"https://github.com/concord-consortium/thermoscope/pull/5.patch","issue_url":"https://api.github.com/repos/concord-consortium/thermoscope/issues/5","number":5,"state":"open","locked":false,"title":"Add delete icon; dragging atoms here deletes them","user":{"login":"sfentress","id":35721,"avatar_url":"https://avatars.githubusercontent.com/u/35721?v=3","gravatar_id":"","url":"https://api.github.com/users/sfentress","html_url":"https://github.com/sfentress","followers_url":"https://api.github.com/users/sfentress/followers","following_url":"https://api.github.com/users/sfentress/following{/other_user}","gists_url":"https://api.github.com/users/sfentress/gists{/gist_id}","starred_url":"https://api.github.com/users/sfentress/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sfentress/subscriptions","organizations_url":"https://api.github.com/users/sfentress/orgs","repos_url":"https://api.github.com/users/sfentress/repos","events_url":"https://api.github.com/users/sfentress/events{/privacy}","received_events_url":"https://api.github.com/users/sfentress/received_events","type":"User","site_admin":false},"body":"Also relayout in-lab UI to simplify it a bit.\r\n\r\n[#136183811]","created_at":"2016-12-16T18:44:21Z","updated_at":"2016-12-21T19:48:19Z","closed_at":null,"merged_at":null,"merge_commit_sha":"e3a3f4f6eeb772ba63a84d911cd4b58edf4f51da","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/concord-consortium/thermoscope/pulls/5/commits","review_comments_url":"https://api.github.com/repos/concord-consortium/thermoscope/pulls/5/comments","review_comment_url":"https://api.github.com/repos/concord-consortium/thermoscope/pulls/comments{/number}","comments_url":"https://api.github.com/repos/concord-consortium/thermoscope/issues/5/comments","statuses_url":"https://api.github.com/repos/concord-consortium/thermoscope/statuses/6d2d6e6d7efe59082a6f7260eb3c27f99dc55fed","head":{"label":"concord-consortium:delete-atoms","ref":"delete-atoms","sha":"6d2d6e6d7efe59082a6f7260eb3c27f99dc55fed","user":{"login":"concord-consortium","id":319219,"avatar_url":"https://avatars.githubusercontent.com/u/319219?v=3","gravatar_id":"","url":"https://api.github.com/users/concord-consortium","html_url":"https://github.com/concord-consortium","followers_url":"https://api.github.com/users/concord-consortium/followers","following_url":"https://api.github.com/users/concord-consortium/following{/other_user}","gists_url":"https://api.github.com/users/concord-consortium/gists{/gist_id}","starred_url":"https://api.github.com/users/concord-consortium/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/concord-consortium/subscriptions","organizations_url":"https://api.github.com/users/concord-consortium/orgs","repos_url":"https://api.github.com/users/concord-consortium/repos","events_url":"https://api.github.com/users/concord-consortium/events{/privacy}","received_events_url":"https://api.github.com/users/concord-consortium/received_events","type":"Organization","site_admin":false},"repo":{"id":74585893,"name":"thermoscope","full_name":"concord-consortium/thermoscope","owner":{"login":"concord-consortium","id":319219,"avatar_url":"https://avatars.githubusercontent.com/u/319219?v=3","gravatar_id":"","url":"https://api.github.com/users/concord-consortium","html_url":"https://github.com/concord-consortium","followers_url":"https://api.github.com/users/concord-consortium/followers","following_url":"https://api.github.com/users/concord-consortium/following{/other_user}","gists_url":"https://api.github.com/users/concord-consortium/gists{/gist_id}","starred_url":"https://api.github.com/users/concord-consortium/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/concord-consortium/subscriptions","organizations_url":"https://api.github.com/users/concord-consortium/orgs","repos_url":"https://api.github.com/users/concord-consortium/repos","events_url":"https://api.github.com/users/concord-consortium/events{/privacy}","received_events_url":"https://api.github.com/users/concord-consortium/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/concord-consortium/thermoscope","description":"A visualization of matter at different temperatures","fork":false,"url":"https://api.github.com/repos/concord-consortium/thermoscope","forks_url":"https://api.github.com/repos/concord-consortium/thermoscope/forks","keys_url":"https://api.github.com/repos/concord-consortium/thermoscope/keys{/key_id}","collaborators_url":"https://api.github.com/repos/concord-consortium/thermoscope/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/concord-consortium/thermoscope/teams","hooks_url":"https://api.github.com/repos/concord-consortium/thermoscope/hooks","issue_events_url":"https://api.github.com/repos/concord-consortium/thermoscope/issues/events{/number}","events_url":"https://api.github.com/repos/concord-consortium/thermoscope/events","assignees_url":"https://api.github.com/repos/concord-consortium/thermoscope/assignees{/user}","branches_url":"https://api.github.com/repos/concord-consortium/thermoscope/branches{/branch}","tags_url":"https://api.github.com/repos/concord-consortium/thermoscope/tags","blobs_url":"https://api.github.com/repos/concord-consortium/thermoscope/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/concord-consortium/thermoscope/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/concord-consortium/thermoscope/git/refs{/sha}","trees_url":"https://api.github.com/repos/concord-consortium/thermoscope/git/trees{/sha}","statuses_url":"https://api.github.com/repos/concord-consortium/thermoscope/statuses/{sha}","languages_url":"https://api.github.com/repos/concord-consortium/thermoscope/languages","stargazers_url":"https://api.github.com/repos/concord-consortium/thermoscope/stargazers","contributors_url":"https://api.github.com/repos/concord-consortium/thermoscope/contributors","subscribers_url":"https://api.github.com/repos/concord-consortium/thermoscope/subscribers","subscription_url":"https://api.github.com/repos/concord-consortium/thermoscope/subscription","commits_url":"https://api.github.com/repos/concord-consortium/thermoscope/commits{/sha}","git_commits_url":"https://api.github.com/repos/concord-consortium/thermoscope/git/commits{/sha}","comments_url":"https://api.github.com/repos/concord-consortium/thermoscope/comments{/number}","issue_comment_url":"https://api.github.com/repos/concord-consortium/thermoscope/issues/comments{/number}","contents_url":"https://api.github.com/repos/concord-consortium/thermoscope/contents/{+path}","compare_url":"https://api.github.com/repos/concord-consortium/thermoscope/compare/{base}...{head}","merges_url":"https://api.github.com/repos/concord-consortium/thermoscope/merges","archive_url":"https://api.github.com/repos/concord-consortium/thermoscope/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/concord-consortium/thermoscope/downloads","issues_url":"https://api.github.com/repos/concord-consortium/thermoscope/issues{/number}","pulls_url":"https://api.github.com/repos/concord-consortium/thermoscope/pulls{/number}","milestones_url":"https://api.github.com/repos/concord-consortium/thermoscope/milestones{/number}","notifications_url":"https://api.github.com/repos/concord-consortium/thermoscope/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/concord-consortium/thermoscope/labels{/name}","releases_url":"https://api.github.com/repos/concord-consortium/thermoscope/releases{/id}","deployments_url":"https://api.github.com/repos/concord-consortium/thermoscope/deployments","created_at":"2016-11-23T14:47:38Z","updated_at":"2016-11-23T17:03:28Z","pushed_at":"2016-12-21T19:46:36Z","git_url":"git://github.com/concord-consortium/thermoscope.git","ssh_url":"git@github.com:concord-consortium/thermoscope.git","clone_url":"https://github.com/concord-consortium/thermoscope.git","svn_url":"https://github.com/concord-consortium/thermoscope","homepage":null,"size":16006,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":0,"mirror_url":null,"open_issues_count":2,"forks":0,"open_issues":2,"watchers":0,"default_branch":"master"}},"base":{"label":"concord-consortium:master","ref":"master","sha":"bea69292abdc4d05ea996856ed0f357fd6f0ace7","user":{"login":"concord-consortium","id":319219,"avatar_url":"https://avatars.githubusercontent.com/u/319219?v=3","gravatar_id":"","url":"https://api.github.com/users/concord-consortium","html_url":"https://github.com/concord-consortium","followers_url":"https://api.github.com/users/concord-consortium/followers","following_url":"https://api.github.com/users/concord-consortium/following{/other_user}","gists_url":"https://api.github.com/users/concord-consortium/gists{/gist_id}","starred_url":"https://api.github.com/users/concord-consortium/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/concord-consortium/subscriptions","organizations_url":"https://api.github.com/users/concord-consortium/orgs","repos_url":"https://api.github.com/users/concord-consortium/repos","events_url":"https://api.github.com/users/concord-consortium/events{/privacy}","received_events_url":"https://api.github.com/users/concord-consortium/received_events","type":"Organization","site_admin":false},"repo":{"id":74585893,"name":"thermoscope","full_name":"concord-consortium/thermoscope","owner":{"login":"concord-consortium","id":319219,"avatar_url":"https://avatars.githubusercontent.com/u/319219?v=3","gravatar_id":"","url":"https://api.github.com/users/concord-consortium","html_url":"https://github.com/concord-consortium","followers_url":"https://api.github.com/users/concord-consortium/followers","following_url":"https://api.github.com/users/concord-consortium/following{/other_user}","gists_url":"https://api.github.com/users/concord-consortium/gists{/gist_id}","starred_url":"https://api.github.com/users/concord-consortium/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/concord-consortium/subscriptions","organizations_url":"https://api.github.com/users/concord-consortium/orgs","repos_url":"https://api.github.com/users/concord-consortium/repos","events_url":"https://api.github.com/users/concord-consortium/events{/privacy}","received_events_url":"https://api.github.com/users/concord-consortium/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/concord-consortium/thermoscope","description":"A visualization of matter at different temperatures","fork":false,"url":"https://api.github.com/repos/concord-consortium/thermoscope","forks_url":"https://api.github.com/repos/concord-consortium/thermoscope/forks","keys_url":"https://api.github.com/repos/concord-consortium/thermoscope/keys{/key_id}","collaborators_url":"https://api.github.com/repos/concord-consortium/thermoscope/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/concord-consortium/thermoscope/teams","hooks_url":"https://api.github.com/repos/concord-consortium/thermoscope/hooks","issue_events_url":"https://api.github.com/repos/concord-consortium/thermoscope/issues/events{/number}","events_url":"https://api.github.com/repos/concord-consortium/thermoscope/events","assignees_url":"https://api.github.com/repos/concord-consortium/thermoscope/assignees{/user}","branches_url":"https://api.github.com/repos/concord-consortium/thermoscope/branches{/branch}","tags_url":"https://api.github.com/repos/concord-consortium/thermoscope/tags","blobs_url":"https://api.github.com/repos/concord-consortium/thermoscope/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/concord-consortium/thermoscope/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/concord-consortium/thermoscope/git/refs{/sha}","trees_url":"https://api.github.com/repos/concord-consortium/thermoscope/git/trees{/sha}","statuses_url":"https://api.github.com/repos/concord-consortium/thermoscope/statuses/{sha}","languages_url":"https://api.github.com/repos/concord-consortium/thermoscope/languages","stargazers_url":"https://api.github.com/repos/concord-consortium/thermoscope/stargazers","contributors_url":"https://api.github.com/repos/concord-consortium/thermoscope/contributors","subscribers_url":"https://api.github.com/repos/concord-consortium/thermoscope/subscribers","subscription_url":"https://api.github.com/repos/concord-consortium/thermoscope/subscription","commits_url":"https://api.github.com/repos/concord-consortium/thermoscope/commits{/sha}","git_commits_url":"https://api.github.com/repos/concord-consortium/thermoscope/git/commits{/sha}","comments_url":"https://api.github.com/repos/concord-consortium/thermoscope/comments{/number}","issue_comment_url":"https://api.github.com/repos/concord-consortium/thermoscope/issues/comments{/number}","contents_url":"https://api.github.com/repos/concord-consortium/thermoscope/contents/{+path}","compare_url":"https://api.github.com/repos/concord-consortium/thermoscope/compare/{base}...{head}","merges_url":"https://api.github.com/repos/concord-consortium/thermoscope/merges","archive_url":"https://api.github.com/repos/concord-consortium/thermoscope/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/concord-consortium/thermoscope/downloads","issues_url":"https://api.github.com/repos/concord-consortium/thermoscope/issues{/number}","pulls_url":"https://api.github.com/repos/concord-consortium/thermoscope/pulls{/number}","milestones_url":"https://api.github.com/repos/concord-consortium/thermoscope/milestones{/number}","notifications_url":"https://api.github.com/repos/concord-consortium/thermoscope/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/concord-consortium/thermoscope/labels{/name}","releases_url":"https://api.github.com/repos/concord-consortium/thermoscope/releases{/id}","deployments_url":"https://api.github.com/repos/concord-consortium/thermoscope/deployments","created_at":"2016-11-23T14:47:38Z","updated_at":"2016-11-23T17:03:28Z","pushed_at":"2016-12-21T19:46:36Z","git_url":"git://github.com/concord-consortium/thermoscope.git","ssh_url":"git@github.com:concord-consortium/thermoscope.git","clone_url":"https://github.com/concord-consortium/thermoscope.git","svn_url":"https://github.com/concord-consortium/thermoscope","homepage":null,"size":16006,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":0,"mirror_url":null,"open_issues_count":2,"forks":0,"open_issues":2,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/concord-consortium/thermoscope/pulls/5"},"html":{"href":"https://github.com/concord-consortium/thermoscope/pull/5"},"issue":{"href":"https://api.github.com/repos/concord-consortium/thermoscope/issues/5"},"comments":{"href":"https://api.github.com/repos/concord-consortium/thermoscope/issues/5/comments"},"review_comments":{"href":"https://api.github.com/repos/concord-consortium/thermoscope/pulls/5/comments"},"review_comment":{"href":"https://api.github.com/repos/concord-consortium/thermoscope/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/concord-consortium/thermoscope/pulls/5/commits"},"statuses":{"href":"https://api.github.com/repos/concord-consortium/thermoscope/statuses/6d2d6e6d7efe59082a6f7260eb3c27f99dc55fed"}}}}
{"actor":{"display_login":"sfentress"}}