{"action":"created","comment":{"url":"https://api.github.com/repos/mapseed/platform/pulls/comments/230961354","pull_request_review_id":171819086,"id":230961354,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDIzMDk2MTM1NA==","diff_hunk":"@@ -350,46 +332,36 @@ export default Backbone.View.extend({\n         store.dispatch(setLayerStatus(layerId, layerStatus)),\n     });\n \n-    if (this.options.rightSidebarConfig.is_enabled) {\n-      $(\"body\").addClass(\"right-sidebar-active\");\n-      if (this.options.rightSidebarConfig.is_visible_default) {\n-        $(\"body\").addClass(\"right-sidebar-visible\");\n-      }\n-\n-      // REACT PORT SECTION ///////////////////////////////////////////////////\n-      ReactDOM.render(\n-        <Provider store={store}>\n-          <ThemeProvider theme={theme}>\n-            <ThemeProvider theme={adjustedTheme}>\n-              <RightSidebar\n-                placeCollectionsPromise={placeCollectionsPromise}\n-                places={this.places}\n-                router={this.options.router}\n-              />\n-            </ThemeProvider>\n-          </ThemeProvider>\n-        </Provider>,\n-        document.getElementById(\"right-sidebar-container\"),\n-      );\n-      // END REACT PORT SECTION ///////////////////////////////////////////////\n-    }\n+    // Load activities from the API\n+    _.each(this.activities, function(collection, key) {\n+      collection.fetch({\n+        reset: true,\n+        attribute: \"target\",\n+        attributesToAdd: {\n+          datasetId: _.find(self.options.mapConfig.layers, function(layer) {\n+            return layer.id == key;\n+          }).id,\n+          datasetSlug: _.find(self.options.mapConfig.layers, function(layer) {\n+            return layer.id == key;\n+          }).slug,\n+        },\n+      });\n+    });\n \n-    // REACT PORT SECTION /////////////////////////////////////////////////////\n-    if (this.options.leftSidebarConfig.is_enabled) {\n-      ReactDOM.render(\n-        <Provider store={store}>\n-          <LeftSidebar />\n-        </Provider>,\n-        document.getElementById(\"left-sidebar-container\"),\n-      );\n-    }\n-    // END REACT PORT SECTION /////////////////////////////////////////////////\n+    // TODO(luke): When AppView is ported to a react component, await\n+    // the place collections to load in the App component:\n+    placeCollectionsPromise.then(fetchedCollections => {\n+      const allPlaces = fetchedCollections.reduce((places, collection) => {\n+        return [...collection.models.map(model => model.toJSON()), ...places];\n+      }, []);\n+      store.dispatch(setPlaces(allPlaces));","path":"src/base/static/js/views/app-view.js","position":242,"original_position":242,"commit_id":"865eab2c47bcbe37f93c08a62d944b98c8ab8d9a","original_commit_id":"865eab2c47bcbe37f93c08a62d944b98c8ab8d9a","user":{"login":"goldpbear","id":9222338,"node_id":"MDQ6VXNlcjkyMjIzMzg=","avatar_url":"https://avatars2.githubusercontent.com/u/9222338?v=4","gravatar_id":"","url":"https://api.github.com/users/goldpbear","html_url":"https://github.com/goldpbear","followers_url":"https://api.github.com/users/goldpbear/followers","following_url":"https://api.github.com/users/goldpbear/following{/other_user}","gists_url":"https://api.github.com/users/goldpbear/gists{/gist_id}","starred_url":"https://api.github.com/users/goldpbear/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/goldpbear/subscriptions","organizations_url":"https://api.github.com/users/goldpbear/orgs","repos_url":"https://api.github.com/users/goldpbear/repos","events_url":"https://api.github.com/users/goldpbear/events{/privacy}","received_events_url":"https://api.github.com/users/goldpbear/received_events","type":"User","site_admin":false},"body":"Perhaps we want to maintain a Backbone collection listener for the time being for this purpose.","created_at":"2018-11-06T00:12:51Z","updated_at":"2018-11-06T00:12:51Z","html_url":"https://github.com/mapseed/platform/pull/1047#discussion_r230961354","pull_request_url":"https://api.github.com/repos/mapseed/platform/pulls/1047","author_association":"CONTRIBUTOR","_links":{"self":{"href":"https://api.github.com/repos/mapseed/platform/pulls/comments/230961354"},"html":{"href":"https://github.com/mapseed/platform/pull/1047#discussion_r230961354"},"pull_request":{"href":"https://api.github.com/repos/mapseed/platform/pulls/1047"}},"in_reply_to_id":230960734},"pull_request":{"url":"https://api.github.com/repos/mapseed/platform/pulls/1047","id":223012805,"node_id":"MDExOlB1bGxSZXF1ZXN0MjIzMDEyODA1","html_url":"https://github.com/mapseed/platform/pull/1047","diff_url":"https://github.com/mapseed/platform/pull/1047.diff","patch_url":"https://github.com/mapseed/platform/pull/1047.patch","issue_url":"https://api.github.com/repos/mapseed/platform/issues/1047","number":1047,"state":"open","locked":false,"title":"Jalmogo/port list view","user":{"login":"jalMogo","id":42042460,"node_id":"MDQ6VXNlcjQyMDQyNDYw","avatar_url":"https://avatars1.githubusercontent.com/u/42042460?v=4","gravatar_id":"","url":"https://api.github.com/users/jalMogo","html_url":"https://github.com/jalMogo","followers_url":"https://api.github.com/users/jalMogo/followers","following_url":"https://api.github.com/users/jalMogo/following{/other_user}","gists_url":"https://api.github.com/users/jalMogo/gists{/gist_id}","starred_url":"https://api.github.com/users/jalMogo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jalMogo/subscriptions","organizations_url":"https://api.github.com/users/jalMogo/orgs","repos_url":"https://api.github.com/users/jalMogo/repos","events_url":"https://api.github.com/users/jalMogo/events{/privacy}","received_events_url":"https://api.github.com/users/jalMogo/received_events","type":"User","site_admin":false},"body":"Apologies for the huge PR. This probably should have been developed on a feature branch.\r\n\r\nFeedback is more than welcome, especially on the layout or design, which has been changed considerably.\r\n\r\nHere's the diff without whitespace: https://github.com/mapseed/platform/pull/1047/files?w=1\r\n\r\nThis PR:\r\n - Adds a PlaceList component, and renders our list of PlaceListItem's using react-virtualized. This will allow us to render large lists of places without affecting performance.\r\n - Refactors logic inside of AppView's `initialize` method, and moves it into new hooks, like `renderRightSidebar`, `renderList`, and `renderMain`. The goal here is to simplify the layout of our elements in AppView, which eventually should help to dissolve AppView into React components.\r\n - Add a new TextInput atom, as documented in our Design Language doc.\r\n - Adds new Typography atoms, per our Design Language doc. These include Small / Regular / Large Title atoms and Micro / Small / Regular / Large Text atoms.\r\n\r\nTODO's:\r\n - [x] Update custom flavor AppView's with the latest refactoring\r\n - [x] Style and layout the PlaceListItem component\r\n - [x] Make the new PlaceListItem component layout data-driven\r\n - [x] fix \"go to map\" bug after the `/list` route has been rendered: `TypeError: _map.mapPositionSelector(...) is undefined`\r\n - [x] test social media sharing\r\n - [ ] port the Hull, Augusta, Bathgate, Manazanares, and Williams flavor AppViews to use the new hooks. **Planning to do this after a code review**\r\n\r\nFollowup issues, for a separate PR:\r\n - [ ] make the list mobile-friendly\r\n - [ ] when new Places are added or supported or commented, the PlaceList should reflect that. The Redux store is loading the initial places, but isn't keeping up to date with any updates.\r\n - [ ] update PlaceList translations - there are currently none\r\n - [ ] fix PlaceList to handle SnohomishCD's data - this will require some new components. But since the list isn't linked from the website, maybe they don't need it? It's only accessible from the `/list` route. I think we should fix it, eventually, because they would probably find the list view useful.\r\n - [ ] When clicking the `view on map` button for a place in the list, the map doesn't increase the icon's size, and throws an error `Style is not done loading`. It's probably because the style isn't done loading when the event is triggered here: https://github.com/mapseed/platform/blob/ad0ae6b2b1ab7c52fd163ed5517e9e3e36deb6bf/src/base/static/components/organisms/main-map.js#L306 \r\n\r\n\r\n\r\n","created_at":"2018-10-15T19:13:47Z","updated_at":"2018-11-06T00:12:51Z","closed_at":null,"merged_at":null,"merge_commit_sha":"22f6d1a89fe44a9c97380ebf1ea556232ab727ad","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/mapseed/platform/pulls/1047/commits","review_comments_url":"https://api.github.com/repos/mapseed/platform/pulls/1047/comments","review_comment_url":"https://api.github.com/repos/mapseed/platform/pulls/comments{/number}","comments_url":"https://api.github.com/repos/mapseed/platform/issues/1047/comments","statuses_url":"https://api.github.com/repos/mapseed/platform/statuses/865eab2c47bcbe37f93c08a62d944b98c8ab8d9a","head":{"label":"mapseed:jalmogo/port-list-view","ref":"jalmogo/port-list-view","sha":"865eab2c47bcbe37f93c08a62d944b98c8ab8d9a","user":{"login":"mapseed","id":7245803,"node_id":"MDEyOk9yZ2FuaXphdGlvbjcyNDU4MDM=","avatar_url":"https://avatars2.githubusercontent.com/u/7245803?v=4","gravatar_id":"","url":"https://api.github.com/users/mapseed","html_url":"https://github.com/mapseed","followers_url":"https://api.github.com/users/mapseed/followers","following_url":"https://api.github.com/users/mapseed/following{/other_user}","gists_url":"https://api.github.com/users/mapseed/gists{/gist_id}","starred_url":"https://api.github.com/users/mapseed/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mapseed/subscriptions","organizations_url":"https://api.github.com/users/mapseed/orgs","repos_url":"https://api.github.com/users/mapseed/repos","events_url":"https://api.github.com/users/mapseed/events{/privacy}","received_events_url":"https://api.github.com/users/mapseed/received_events","type":"Organization","site_admin":false},"repo":{"id":28108305,"node_id":"MDEwOlJlcG9zaXRvcnkyODEwODMwNQ==","name":"platform","full_name":"mapseed/platform","private":false,"owner":{"login":"mapseed","id":7245803,"node_id":"MDEyOk9yZ2FuaXphdGlvbjcyNDU4MDM=","avatar_url":"https://avatars2.githubusercontent.com/u/7245803?v=4","gravatar_id":"","url":"https://api.github.com/users/mapseed","html_url":"https://github.com/mapseed","followers_url":"https://api.github.com/users/mapseed/followers","following_url":"https://api.github.com/users/mapseed/following{/other_user}","gists_url":"https://api.github.com/users/mapseed/gists{/gist_id}","starred_url":"https://api.github.com/users/mapseed/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mapseed/subscriptions","organizations_url":"https://api.github.com/users/mapseed/orgs","repos_url":"https://api.github.com/users/mapseed/repos","events_url":"https://api.github.com/users/mapseed/events{/privacy}","received_events_url":"https://api.github.com/users/mapseed/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/mapseed/platform","description":"Mapseed is a simple, beautiful way to collect information and tell geographic stories.","fork":false,"url":"https://api.github.com/repos/mapseed/platform","forks_url":"https://api.github.com/repos/mapseed/platform/forks","keys_url":"https://api.github.com/repos/mapseed/platform/keys{/key_id}","collaborators_url":"https://api.github.com/repos/mapseed/platform/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/mapseed/platform/teams","hooks_url":"https://api.github.com/repos/mapseed/platform/hooks","issue_events_url":"https://api.github.com/repos/mapseed/platform/issues/events{/number}","events_url":"https://api.github.com/repos/mapseed/platform/events","assignees_url":"https://api.github.com/repos/mapseed/platform/assignees{/user}","branches_url":"https://api.github.com/repos/mapseed/platform/branches{/branch}","tags_url":"https://api.github.com/repos/mapseed/platform/tags","blobs_url":"https://api.github.com/repos/mapseed/platform/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/mapseed/platform/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/mapseed/platform/git/refs{/sha}","trees_url":"https://api.github.com/repos/mapseed/platform/git/trees{/sha}","statuses_url":"https://api.github.com/repos/mapseed/platform/statuses/{sha}","languages_url":"https://api.github.com/repos/mapseed/platform/languages","stargazers_url":"https://api.github.com/repos/mapseed/platform/stargazers","contributors_url":"https://api.github.com/repos/mapseed/platform/contributors","subscribers_url":"https://api.github.com/repos/mapseed/platform/subscribers","subscription_url":"https://api.github.com/repos/mapseed/platform/subscription","commits_url":"https://api.github.com/repos/mapseed/platform/commits{/sha}","git_commits_url":"https://api.github.com/repos/mapseed/platform/git/commits{/sha}","comments_url":"https://api.github.com/repos/mapseed/platform/comments{/number}","issue_comment_url":"https://api.github.com/repos/mapseed/platform/issues/comments{/number}","contents_url":"https://api.github.com/repos/mapseed/platform/contents/{+path}","compare_url":"https://api.github.com/repos/mapseed/platform/compare/{base}...{head}","merges_url":"https://api.github.com/repos/mapseed/platform/merges","archive_url":"https://api.github.com/repos/mapseed/platform/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/mapseed/platform/downloads","issues_url":"https://api.github.com/repos/mapseed/platform/issues{/number}","pulls_url":"https://api.github.com/repos/mapseed/platform/pulls{/number}","milestones_url":"https://api.github.com/repos/mapseed/platform/milestones{/number}","notifications_url":"https://api.github.com/repos/mapseed/platform/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/mapseed/platform/labels{/name}","releases_url":"https://api.github.com/repos/mapseed/platform/releases{/id}","deployments_url":"https://api.github.com/repos/mapseed/platform/deployments","created_at":"2014-12-16T21:51:30Z","updated_at":"2018-11-05T23:12:21Z","pushed_at":"2018-11-05T23:12:19Z","git_url":"git://github.com/mapseed/platform.git","ssh_url":"git@github.com:mapseed/platform.git","clone_url":"https://github.com/mapseed/platform.git","svn_url":"https://github.com/mapseed/platform","homepage":"http://mapseed.org","size":60362,"stargazers_count":54,"watchers_count":54,"language":"HTML","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":26,"mirror_url":null,"archived":false,"open_issues_count":91,"license":{"key":"gpl-3.0","name":"GNU General Public License v3.0","spdx_id":"GPL-3.0","url":"https://api.github.com/licenses/gpl-3.0","node_id":"MDc6TGljZW5zZTk="},"forks":26,"open_issues":91,"watchers":54,"default_branch":"master"}},"base":{"label":"mapseed:master","ref":"master","sha":"6fd96e41d2a65a704382f2edefad1ee8727f6c4b","user":{"login":"mapseed","id":7245803,"node_id":"MDEyOk9yZ2FuaXphdGlvbjcyNDU4MDM=","avatar_url":"https://avatars2.githubusercontent.com/u/7245803?v=4","gravatar_id":"","url":"https://api.github.com/users/mapseed","html_url":"https://github.com/mapseed","followers_url":"https://api.github.com/users/mapseed/followers","following_url":"https://api.github.com/users/mapseed/following{/other_user}","gists_url":"https://api.github.com/users/mapseed/gists{/gist_id}","starred_url":"https://api.github.com/users/mapseed/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mapseed/subscriptions","organizations_url":"https://api.github.com/users/mapseed/orgs","repos_url":"https://api.github.com/users/mapseed/repos","events_url":"https://api.github.com/users/mapseed/events{/privacy}","received_events_url":"https://api.github.com/users/mapseed/received_events","type":"Organization","site_admin":false},"repo":{"id":28108305,"node_id":"MDEwOlJlcG9zaXRvcnkyODEwODMwNQ==","name":"platform","full_name":"mapseed/platform","private":false,"owner":{"login":"mapseed","id":7245803,"node_id":"MDEyOk9yZ2FuaXphdGlvbjcyNDU4MDM=","avatar_url":"https://avatars2.githubusercontent.com/u/7245803?v=4","gravatar_id":"","url":"https://api.github.com/users/mapseed","html_url":"https://github.com/mapseed","followers_url":"https://api.github.com/users/mapseed/followers","following_url":"https://api.github.com/users/mapseed/following{/other_user}","gists_url":"https://api.github.com/users/mapseed/gists{/gist_id}","starred_url":"https://api.github.com/users/mapseed/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mapseed/subscriptions","organizations_url":"https://api.github.com/users/mapseed/orgs","repos_url":"https://api.github.com/users/mapseed/repos","events_url":"https://api.github.com/users/mapseed/events{/privacy}","received_events_url":"https://api.github.com/users/mapseed/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/mapseed/platform","description":"Mapseed is a simple, beautiful way to collect information and tell geographic stories.","fork":false,"url":"https://api.github.com/repos/mapseed/platform","forks_url":"https://api.github.com/repos/mapseed/platform/forks","keys_url":"https://api.github.com/repos/mapseed/platform/keys{/key_id}","collaborators_url":"https://api.github.com/repos/mapseed/platform/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/mapseed/platform/teams","hooks_url":"https://api.github.com/repos/mapseed/platform/hooks","issue_events_url":"https://api.github.com/repos/mapseed/platform/issues/events{/number}","events_url":"https://api.github.com/repos/mapseed/platform/events","assignees_url":"https://api.github.com/repos/mapseed/platform/assignees{/user}","branches_url":"https://api.github.com/repos/mapseed/platform/branches{/branch}","tags_url":"https://api.github.com/repos/mapseed/platform/tags","blobs_url":"https://api.github.com/repos/mapseed/platform/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/mapseed/platform/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/mapseed/platform/git/refs{/sha}","trees_url":"https://api.github.com/repos/mapseed/platform/git/trees{/sha}","statuses_url":"https://api.github.com/repos/mapseed/platform/statuses/{sha}","languages_url":"https://api.github.com/repos/mapseed/platform/languages","stargazers_url":"https://api.github.com/repos/mapseed/platform/stargazers","contributors_url":"https://api.github.com/repos/mapseed/platform/contributors","subscribers_url":"https://api.github.com/repos/mapseed/platform/subscribers","subscription_url":"https://api.github.com/repos/mapseed/platform/subscription","commits_url":"https://api.github.com/repos/mapseed/platform/commits{/sha}","git_commits_url":"https://api.github.com/repos/mapseed/platform/git/commits{/sha}","comments_url":"https://api.github.com/repos/mapseed/platform/comments{/number}","issue_comment_url":"https://api.github.com/repos/mapseed/platform/issues/comments{/number}","contents_url":"https://api.github.com/repos/mapseed/platform/contents/{+path}","compare_url":"https://api.github.com/repos/mapseed/platform/compare/{base}...{head}","merges_url":"https://api.github.com/repos/mapseed/platform/merges","archive_url":"https://api.github.com/repos/mapseed/platform/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/mapseed/platform/downloads","issues_url":"https://api.github.com/repos/mapseed/platform/issues{/number}","pulls_url":"https://api.github.com/repos/mapseed/platform/pulls{/number}","milestones_url":"https://api.github.com/repos/mapseed/platform/milestones{/number}","notifications_url":"https://api.github.com/repos/mapseed/platform/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/mapseed/platform/labels{/name}","releases_url":"https://api.github.com/repos/mapseed/platform/releases{/id}","deployments_url":"https://api.github.com/repos/mapseed/platform/deployments","created_at":"2014-12-16T21:51:30Z","updated_at":"2018-11-05T23:12:21Z","pushed_at":"2018-11-05T23:12:19Z","git_url":"git://github.com/mapseed/platform.git","ssh_url":"git@github.com:mapseed/platform.git","clone_url":"https://github.com/mapseed/platform.git","svn_url":"https://github.com/mapseed/platform","homepage":"http://mapseed.org","size":60362,"stargazers_count":54,"watchers_count":54,"language":"HTML","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":26,"mirror_url":null,"archived":false,"open_issues_count":91,"license":{"key":"gpl-3.0","name":"GNU General Public License v3.0","spdx_id":"GPL-3.0","url":"https://api.github.com/licenses/gpl-3.0","node_id":"MDc6TGljZW5zZTk="},"forks":26,"open_issues":91,"watchers":54,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/mapseed/platform/pulls/1047"},"html":{"href":"https://github.com/mapseed/platform/pull/1047"},"issue":{"href":"https://api.github.com/repos/mapseed/platform/issues/1047"},"comments":{"href":"https://api.github.com/repos/mapseed/platform/issues/1047/comments"},"review_comments":{"href":"https://api.github.com/repos/mapseed/platform/pulls/1047/comments"},"review_comment":{"href":"https://api.github.com/repos/mapseed/platform/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/mapseed/platform/pulls/1047/commits"},"statuses":{"href":"https://api.github.com/repos/mapseed/platform/statuses/865eab2c47bcbe37f93c08a62d944b98c8ab8d9a"}},"author_association":"CONTRIBUTOR"}}
{"actor":{"display_login":"goldpbear"}}