{"action":"created","comment":{"url":"https://api.github.com/repos/CartoDB/deep-insights.js/pulls/comments/60544091","id":60544091,"diff_hunk":"@@ -0,0 +1,141 @@\n+var cdb = require('cartodb.js');\n+var CategoryColors = require('./category/category-colors');\n+var AutoStyler = cdb.core.Model.extend({\n+  initialize: function (dataviewModel) {\n+    this.dataviewModel = dataviewModel;\n+    this.colors = new CategoryColors();\n+    this.vector = !!this.dataviewModel._dataProvider;","path":"src/widgets/auto-styler.js","position":7,"original_position":7,"commit_id":"85d33a761d531cca3f3ace43bb51fbccfeaa62a7","original_commit_id":"85d33a761d531cca3f3ace43bb51fbccfeaa62a7","user":{"login":"alonsogarciapablo","id":390398,"avatar_url":"https://avatars.githubusercontent.com/u/390398?v=3","gravatar_id":"","url":"https://api.github.com/users/alonsogarciapablo","html_url":"https://github.com/alonsogarciapablo","followers_url":"https://api.github.com/users/alonsogarciapablo/followers","following_url":"https://api.github.com/users/alonsogarciapablo/following{/other_user}","gists_url":"https://api.github.com/users/alonsogarciapablo/gists{/gist_id}","starred_url":"https://api.github.com/users/alonsogarciapablo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/alonsogarciapablo/subscriptions","organizations_url":"https://api.github.com/users/alonsogarciapablo/orgs","repos_url":"https://api.github.com/users/alonsogarciapablo/repos","events_url":"https://api.github.com/users/alonsogarciapablo/events{/privacy}","received_events_url":"https://api.github.com/users/alonsogarciapablo/received_events","type":"User","site_admin":false},"body":"Again, this class shouldn't know about how the map is rendered... That was the goal of deep-insights.js (separating widgets from map rendering). In this class we have several conditionals that make it work differently for raster and vector... CartoDB.js's API should provide methods so that we don't need to things like accessing `this.dataviewModel._dataProvider`...","created_at":"2016-04-21T08:37:54Z","updated_at":"2016-04-21T08:37:54Z","html_url":"https://github.com/CartoDB/deep-insights.js/pull/304#discussion_r60544091","pull_request_url":"https://api.github.com/repos/CartoDB/deep-insights.js/pulls/304","_links":{"self":{"href":"https://api.github.com/repos/CartoDB/deep-insights.js/pulls/comments/60544091"},"html":{"href":"https://github.com/CartoDB/deep-insights.js/pull/304#discussion_r60544091"},"pull_request":{"href":"https://api.github.com/repos/CartoDB/deep-insights.js/pulls/304"}}},"pull_request":{"url":"https://api.github.com/repos/CartoDB/deep-insights.js/pulls/304","id":66839063,"html_url":"https://github.com/CartoDB/deep-insights.js/pull/304","diff_url":"https://github.com/CartoDB/deep-insights.js/pull/304.diff","patch_url":"https://github.com/CartoDB/deep-insights.js/pull/304.patch","issue_url":"https://api.github.com/repos/CartoDB/deep-insights.js/issues/304","number":304,"state":"open","locked":false,"title":"[dnm] Auto style","user":{"login":"fdansv","id":3707222,"avatar_url":"https://avatars.githubusercontent.com/u/3707222?v=3","gravatar_id":"","url":"https://api.github.com/users/fdansv","html_url":"https://github.com/fdansv","followers_url":"https://api.github.com/users/fdansv/followers","following_url":"https://api.github.com/users/fdansv/following{/other_user}","gists_url":"https://api.github.com/users/fdansv/gists{/gist_id}","starred_url":"https://api.github.com/users/fdansv/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/fdansv/subscriptions","organizations_url":"https://api.github.com/users/fdansv/orgs","repos_url":"https://api.github.com/users/fdansv/repos","events_url":"https://api.github.com/users/fdansv/events{/privacy}","received_events_url":"https://api.github.com/users/fdansv/received_events","type":"User","site_admin":false},"body":"* [x] Put CartoCSS generation somewhere else\r\n* [x] Rename apply colors/apply sizes to auto style\r\n* [ ] Merge https://github.com/CartoDB/cartodb.js/pull/1232\r\n* [ ] Testing\r\n\r\n@javisantana @alonsogarciapablo ","created_at":"2016-04-18T11:40:34Z","updated_at":"2016-04-21T08:37:55Z","closed_at":null,"merged_at":null,"merge_commit_sha":"f413bc02837d312ae4df803791efa4ab91bd8003","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/CartoDB/deep-insights.js/pulls/304/commits","review_comments_url":"https://api.github.com/repos/CartoDB/deep-insights.js/pulls/304/comments","review_comment_url":"https://api.github.com/repos/CartoDB/deep-insights.js/pulls/comments{/number}","comments_url":"https://api.github.com/repos/CartoDB/deep-insights.js/issues/304/comments","statuses_url":"https://api.github.com/repos/CartoDB/deep-insights.js/statuses/85d33a761d531cca3f3ace43bb51fbccfeaa62a7","head":{"label":"CartoDB:auto-style","ref":"auto-style","sha":"85d33a761d531cca3f3ace43bb51fbccfeaa62a7","user":{"login":"CartoDB","id":1799254,"avatar_url":"https://avatars.githubusercontent.com/u/1799254?v=3","gravatar_id":"","url":"https://api.github.com/users/CartoDB","html_url":"https://github.com/CartoDB","followers_url":"https://api.github.com/users/CartoDB/followers","following_url":"https://api.github.com/users/CartoDB/following{/other_user}","gists_url":"https://api.github.com/users/CartoDB/gists{/gist_id}","starred_url":"https://api.github.com/users/CartoDB/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/CartoDB/subscriptions","organizations_url":"https://api.github.com/users/CartoDB/orgs","repos_url":"https://api.github.com/users/CartoDB/repos","events_url":"https://api.github.com/users/CartoDB/events{/privacy}","received_events_url":"https://api.github.com/users/CartoDB/received_events","type":"Organization","site_admin":false},"repo":{"id":47708079,"name":"deep-insights.js","full_name":"CartoDB/deep-insights.js","owner":{"login":"CartoDB","id":1799254,"avatar_url":"https://avatars.githubusercontent.com/u/1799254?v=3","gravatar_id":"","url":"https://api.github.com/users/CartoDB","html_url":"https://github.com/CartoDB","followers_url":"https://api.github.com/users/CartoDB/followers","following_url":"https://api.github.com/users/CartoDB/following{/other_user}","gists_url":"https://api.github.com/users/CartoDB/gists{/gist_id}","starred_url":"https://api.github.com/users/CartoDB/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/CartoDB/subscriptions","organizations_url":"https://api.github.com/users/CartoDB/orgs","repos_url":"https://api.github.com/users/CartoDB/repos","events_url":"https://api.github.com/users/CartoDB/events{/privacy}","received_events_url":"https://api.github.com/users/CartoDB/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/CartoDB/deep-insights.js","description":"WIP","fork":false,"url":"https://api.github.com/repos/CartoDB/deep-insights.js","forks_url":"https://api.github.com/repos/CartoDB/deep-insights.js/forks","keys_url":"https://api.github.com/repos/CartoDB/deep-insights.js/keys{/key_id}","collaborators_url":"https://api.github.com/repos/CartoDB/deep-insights.js/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/CartoDB/deep-insights.js/teams","hooks_url":"https://api.github.com/repos/CartoDB/deep-insights.js/hooks","issue_events_url":"https://api.github.com/repos/CartoDB/deep-insights.js/issues/events{/number}","events_url":"https://api.github.com/repos/CartoDB/deep-insights.js/events","assignees_url":"https://api.github.com/repos/CartoDB/deep-insights.js/assignees{/user}","branches_url":"https://api.github.com/repos/CartoDB/deep-insights.js/branches{/branch}","tags_url":"https://api.github.com/repos/CartoDB/deep-insights.js/tags","blobs_url":"https://api.github.com/repos/CartoDB/deep-insights.js/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/CartoDB/deep-insights.js/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/CartoDB/deep-insights.js/git/refs{/sha}","trees_url":"https://api.github.com/repos/CartoDB/deep-insights.js/git/trees{/sha}","statuses_url":"https://api.github.com/repos/CartoDB/deep-insights.js/statuses/{sha}","languages_url":"https://api.github.com/repos/CartoDB/deep-insights.js/languages","stargazers_url":"https://api.github.com/repos/CartoDB/deep-insights.js/stargazers","contributors_url":"https://api.github.com/repos/CartoDB/deep-insights.js/contributors","subscribers_url":"https://api.github.com/repos/CartoDB/deep-insights.js/subscribers","subscription_url":"https://api.github.com/repos/CartoDB/deep-insights.js/subscription","commits_url":"https://api.github.com/repos/CartoDB/deep-insights.js/commits{/sha}","git_commits_url":"https://api.github.com/repos/CartoDB/deep-insights.js/git/commits{/sha}","comments_url":"https://api.github.com/repos/CartoDB/deep-insights.js/comments{/number}","issue_comment_url":"https://api.github.com/repos/CartoDB/deep-insights.js/issues/comments{/number}","contents_url":"https://api.github.com/repos/CartoDB/deep-insights.js/contents/{+path}","compare_url":"https://api.github.com/repos/CartoDB/deep-insights.js/compare/{base}...{head}","merges_url":"https://api.github.com/repos/CartoDB/deep-insights.js/merges","archive_url":"https://api.github.com/repos/CartoDB/deep-insights.js/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/CartoDB/deep-insights.js/downloads","issues_url":"https://api.github.com/repos/CartoDB/deep-insights.js/issues{/number}","pulls_url":"https://api.github.com/repos/CartoDB/deep-insights.js/pulls{/number}","milestones_url":"https://api.github.com/repos/CartoDB/deep-insights.js/milestones{/number}","notifications_url":"https://api.github.com/repos/CartoDB/deep-insights.js/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/CartoDB/deep-insights.js/labels{/name}","releases_url":"https://api.github.com/repos/CartoDB/deep-insights.js/releases{/id}","deployments_url":"https://api.github.com/repos/CartoDB/deep-insights.js/deployments","created_at":"2015-12-09T17:40:11Z","updated_at":"2016-04-20T14:59:53Z","pushed_at":"2016-04-20T15:53:23Z","git_url":"git://github.com/CartoDB/deep-insights.js.git","ssh_url":"git@github.com:CartoDB/deep-insights.js.git","clone_url":"https://github.com/CartoDB/deep-insights.js.git","svn_url":"https://github.com/CartoDB/deep-insights.js","homepage":null,"size":12183,"stargazers_count":10,"watchers_count":10,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":10,"mirror_url":null,"open_issues_count":39,"forks":10,"open_issues":39,"watchers":10,"default_branch":"master"}},"base":{"label":"CartoDB:master","ref":"master","sha":"bc95ec06bffffd19db357af35b62c45ac11c55e5","user":{"login":"CartoDB","id":1799254,"avatar_url":"https://avatars.githubusercontent.com/u/1799254?v=3","gravatar_id":"","url":"https://api.github.com/users/CartoDB","html_url":"https://github.com/CartoDB","followers_url":"https://api.github.com/users/CartoDB/followers","following_url":"https://api.github.com/users/CartoDB/following{/other_user}","gists_url":"https://api.github.com/users/CartoDB/gists{/gist_id}","starred_url":"https://api.github.com/users/CartoDB/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/CartoDB/subscriptions","organizations_url":"https://api.github.com/users/CartoDB/orgs","repos_url":"https://api.github.com/users/CartoDB/repos","events_url":"https://api.github.com/users/CartoDB/events{/privacy}","received_events_url":"https://api.github.com/users/CartoDB/received_events","type":"Organization","site_admin":false},"repo":{"id":47708079,"name":"deep-insights.js","full_name":"CartoDB/deep-insights.js","owner":{"login":"CartoDB","id":1799254,"avatar_url":"https://avatars.githubusercontent.com/u/1799254?v=3","gravatar_id":"","url":"https://api.github.com/users/CartoDB","html_url":"https://github.com/CartoDB","followers_url":"https://api.github.com/users/CartoDB/followers","following_url":"https://api.github.com/users/CartoDB/following{/other_user}","gists_url":"https://api.github.com/users/CartoDB/gists{/gist_id}","starred_url":"https://api.github.com/users/CartoDB/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/CartoDB/subscriptions","organizations_url":"https://api.github.com/users/CartoDB/orgs","repos_url":"https://api.github.com/users/CartoDB/repos","events_url":"https://api.github.com/users/CartoDB/events{/privacy}","received_events_url":"https://api.github.com/users/CartoDB/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/CartoDB/deep-insights.js","description":"WIP","fork":false,"url":"https://api.github.com/repos/CartoDB/deep-insights.js","forks_url":"https://api.github.com/repos/CartoDB/deep-insights.js/forks","keys_url":"https://api.github.com/repos/CartoDB/deep-insights.js/keys{/key_id}","collaborators_url":"https://api.github.com/repos/CartoDB/deep-insights.js/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/CartoDB/deep-insights.js/teams","hooks_url":"https://api.github.com/repos/CartoDB/deep-insights.js/hooks","issue_events_url":"https://api.github.com/repos/CartoDB/deep-insights.js/issues/events{/number}","events_url":"https://api.github.com/repos/CartoDB/deep-insights.js/events","assignees_url":"https://api.github.com/repos/CartoDB/deep-insights.js/assignees{/user}","branches_url":"https://api.github.com/repos/CartoDB/deep-insights.js/branches{/branch}","tags_url":"https://api.github.com/repos/CartoDB/deep-insights.js/tags","blobs_url":"https://api.github.com/repos/CartoDB/deep-insights.js/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/CartoDB/deep-insights.js/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/CartoDB/deep-insights.js/git/refs{/sha}","trees_url":"https://api.github.com/repos/CartoDB/deep-insights.js/git/trees{/sha}","statuses_url":"https://api.github.com/repos/CartoDB/deep-insights.js/statuses/{sha}","languages_url":"https://api.github.com/repos/CartoDB/deep-insights.js/languages","stargazers_url":"https://api.github.com/repos/CartoDB/deep-insights.js/stargazers","contributors_url":"https://api.github.com/repos/CartoDB/deep-insights.js/contributors","subscribers_url":"https://api.github.com/repos/CartoDB/deep-insights.js/subscribers","subscription_url":"https://api.github.com/repos/CartoDB/deep-insights.js/subscription","commits_url":"https://api.github.com/repos/CartoDB/deep-insights.js/commits{/sha}","git_commits_url":"https://api.github.com/repos/CartoDB/deep-insights.js/git/commits{/sha}","comments_url":"https://api.github.com/repos/CartoDB/deep-insights.js/comments{/number}","issue_comment_url":"https://api.github.com/repos/CartoDB/deep-insights.js/issues/comments{/number}","contents_url":"https://api.github.com/repos/CartoDB/deep-insights.js/contents/{+path}","compare_url":"https://api.github.com/repos/CartoDB/deep-insights.js/compare/{base}...{head}","merges_url":"https://api.github.com/repos/CartoDB/deep-insights.js/merges","archive_url":"https://api.github.com/repos/CartoDB/deep-insights.js/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/CartoDB/deep-insights.js/downloads","issues_url":"https://api.github.com/repos/CartoDB/deep-insights.js/issues{/number}","pulls_url":"https://api.github.com/repos/CartoDB/deep-insights.js/pulls{/number}","milestones_url":"https://api.github.com/repos/CartoDB/deep-insights.js/milestones{/number}","notifications_url":"https://api.github.com/repos/CartoDB/deep-insights.js/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/CartoDB/deep-insights.js/labels{/name}","releases_url":"https://api.github.com/repos/CartoDB/deep-insights.js/releases{/id}","deployments_url":"https://api.github.com/repos/CartoDB/deep-insights.js/deployments","created_at":"2015-12-09T17:40:11Z","updated_at":"2016-04-20T14:59:53Z","pushed_at":"2016-04-20T15:53:23Z","git_url":"git://github.com/CartoDB/deep-insights.js.git","ssh_url":"git@github.com:CartoDB/deep-insights.js.git","clone_url":"https://github.com/CartoDB/deep-insights.js.git","svn_url":"https://github.com/CartoDB/deep-insights.js","homepage":null,"size":12183,"stargazers_count":10,"watchers_count":10,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":10,"mirror_url":null,"open_issues_count":39,"forks":10,"open_issues":39,"watchers":10,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/CartoDB/deep-insights.js/pulls/304"},"html":{"href":"https://github.com/CartoDB/deep-insights.js/pull/304"},"issue":{"href":"https://api.github.com/repos/CartoDB/deep-insights.js/issues/304"},"comments":{"href":"https://api.github.com/repos/CartoDB/deep-insights.js/issues/304/comments"},"review_comments":{"href":"https://api.github.com/repos/CartoDB/deep-insights.js/pulls/304/comments"},"review_comment":{"href":"https://api.github.com/repos/CartoDB/deep-insights.js/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/CartoDB/deep-insights.js/pulls/304/commits"},"statuses":{"href":"https://api.github.com/repos/CartoDB/deep-insights.js/statuses/85d33a761d531cca3f3ace43bb51fbccfeaa62a7"}}}}