{"action":"created","comment":{"url":"https://api.github.com/repos/LLK/scratch-svg-renderer/pulls/comments/225989181","pull_request_review_id":165704787,"id":225989181,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDIyNTk4OTE4MQ==","diff_hunk":"@@ -197,6 +199,30 @@ class SvgRenderer {\n         }\n     }\n \n+    /**\n+     * Fix SVGs to comply with SVG spec. Scratch 2 defaults to x2 = 0 when x2 is missing, but\n+     * SVG defaults to x2 = 1 when missing.\n+     */\n+    _transformGradients () {\n+        // Collect all gradient elements into a list.\n+        const linearGradientElements = [];\n+        const collectElements = domElement => {\n+            if (domElement.localName === 'linearGradient') {","path":"src/svg-renderer.js","position":21,"original_position":21,"commit_id":"c489616a4082874bc59ea7ca7921d499b83c7702","original_commit_id":"c489616a4082874bc59ea7ca7921d499b83c7702","user":{"login":"cwillisf","id":7019101,"node_id":"MDQ6VXNlcjcwMTkxMDE=","avatar_url":"https://avatars0.githubusercontent.com/u/7019101?v=4","gravatar_id":"","url":"https://api.github.com/users/cwillisf","html_url":"https://github.com/cwillisf","followers_url":"https://api.github.com/users/cwillisf/followers","following_url":"https://api.github.com/users/cwillisf/following{/other_user}","gists_url":"https://api.github.com/users/cwillisf/gists{/gist_id}","starred_url":"https://api.github.com/users/cwillisf/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cwillisf/subscriptions","organizations_url":"https://api.github.com/users/cwillisf/orgs","repos_url":"https://api.github.com/users/cwillisf/repos","events_url":"https://api.github.com/users/cwillisf/events{/privacy}","received_events_url":"https://api.github.com/users/cwillisf/received_events","type":"User","site_admin":false},"body":"Are there any similar issues with radial gradients?","created_at":"2018-10-17T15:47:36Z","updated_at":"2018-10-17T15:53:24Z","html_url":"https://github.com/LLK/scratch-svg-renderer/pull/55#discussion_r225989181","pull_request_url":"https://api.github.com/repos/LLK/scratch-svg-renderer/pulls/55","author_association":"MEMBER","_links":{"self":{"href":"https://api.github.com/repos/LLK/scratch-svg-renderer/pulls/comments/225989181"},"html":{"href":"https://github.com/LLK/scratch-svg-renderer/pull/55#discussion_r225989181"},"pull_request":{"href":"https://api.github.com/repos/LLK/scratch-svg-renderer/pulls/55"}}},"pull_request":{"url":"https://api.github.com/repos/LLK/scratch-svg-renderer/pulls/55","id":223633603,"node_id":"MDExOlB1bGxSZXF1ZXN0MjIzNjMzNjAz","html_url":"https://github.com/LLK/scratch-svg-renderer/pull/55","diff_url":"https://github.com/LLK/scratch-svg-renderer/pull/55.diff","patch_url":"https://github.com/LLK/scratch-svg-renderer/pull/55.patch","issue_url":"https://api.github.com/repos/LLK/scratch-svg-renderer/issues/55","number":55,"state":"open","locked":false,"title":"Fix gradients","user":{"login":"fsih","id":2855464,"node_id":"MDQ6VXNlcjI4NTU0NjQ=","avatar_url":"https://avatars3.githubusercontent.com/u/2855464?v=4","gravatar_id":"","url":"https://api.github.com/users/fsih","html_url":"https://github.com/fsih","followers_url":"https://api.github.com/users/fsih/followers","following_url":"https://api.github.com/users/fsih/following{/other_user}","gists_url":"https://api.github.com/users/fsih/gists{/gist_id}","starred_url":"https://api.github.com/users/fsih/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/fsih/subscriptions","organizations_url":"https://api.github.com/users/fsih/orgs","repos_url":"https://api.github.com/users/fsih/repos","events_url":"https://api.github.com/users/fsih/events{/privacy}","received_events_url":"https://api.github.com/users/fsih/received_events","type":"User","site_admin":false},"body":"### Resolves\r\nFixes https://github.com/LLK/scratch-render/issues/236\r\n\r\n### Proposed Changes\r\nFix exported Scratch 2.0 SVGs to match SVG spec\r\n\r\n### Reason for Changes\r\nScratch 2.0 assumes that for linearGradient elements, x2 defaults to 0, but in the SVG spec x2 defaults to 100%\r\n\r\n### Test Coverage\r\nTested several projects from the aforementioned bug\r\n","created_at":"2018-10-17T14:45:22Z","updated_at":"2018-10-17T15:53:23Z","closed_at":null,"merged_at":null,"merge_commit_sha":"9e6d2fd093ed810ab55990b390db939ed16a517a","assignee":{"login":"cwillisf","id":7019101,"node_id":"MDQ6VXNlcjcwMTkxMDE=","avatar_url":"https://avatars0.githubusercontent.com/u/7019101?v=4","gravatar_id":"","url":"https://api.github.com/users/cwillisf","html_url":"https://github.com/cwillisf","followers_url":"https://api.github.com/users/cwillisf/followers","following_url":"https://api.github.com/users/cwillisf/following{/other_user}","gists_url":"https://api.github.com/users/cwillisf/gists{/gist_id}","starred_url":"https://api.github.com/users/cwillisf/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cwillisf/subscriptions","organizations_url":"https://api.github.com/users/cwillisf/orgs","repos_url":"https://api.github.com/users/cwillisf/repos","events_url":"https://api.github.com/users/cwillisf/events{/privacy}","received_events_url":"https://api.github.com/users/cwillisf/received_events","type":"User","site_admin":false},"assignees":[{"login":"cwillisf","id":7019101,"node_id":"MDQ6VXNlcjcwMTkxMDE=","avatar_url":"https://avatars0.githubusercontent.com/u/7019101?v=4","gravatar_id":"","url":"https://api.github.com/users/cwillisf","html_url":"https://github.com/cwillisf","followers_url":"https://api.github.com/users/cwillisf/followers","following_url":"https://api.github.com/users/cwillisf/following{/other_user}","gists_url":"https://api.github.com/users/cwillisf/gists{/gist_id}","starred_url":"https://api.github.com/users/cwillisf/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cwillisf/subscriptions","organizations_url":"https://api.github.com/users/cwillisf/orgs","repos_url":"https://api.github.com/users/cwillisf/repos","events_url":"https://api.github.com/users/cwillisf/events{/privacy}","received_events_url":"https://api.github.com/users/cwillisf/received_events","type":"User","site_admin":false}],"requested_reviewers":[],"requested_teams":[],"labels":[{"id":809184959,"node_id":"MDU6TGFiZWw4MDkxODQ5NTk=","url":"https://api.github.com/repos/LLK/scratch-svg-renderer/labels/pr%20-%20needs%20review","name":"pr - needs review","color":"fbca04","default":false}],"milestone":{"url":"https://api.github.com/repos/LLK/scratch-svg-renderer/milestones/10","html_url":"https://github.com/LLK/scratch-svg-renderer/milestone/10","labels_url":"https://api.github.com/repos/LLK/scratch-svg-renderer/milestones/10/labels","id":3585004,"node_id":"MDk6TWlsZXN0b25lMzU4NTAwNA==","number":10,"title":"October 2018","description":"","creator":{"login":"thisandagain","id":747641,"node_id":"MDQ6VXNlcjc0NzY0MQ==","avatar_url":"https://avatars3.githubusercontent.com/u/747641?v=4","gravatar_id":"","url":"https://api.github.com/users/thisandagain","html_url":"https://github.com/thisandagain","followers_url":"https://api.github.com/users/thisandagain/followers","following_url":"https://api.github.com/users/thisandagain/following{/other_user}","gists_url":"https://api.github.com/users/thisandagain/gists{/gist_id}","starred_url":"https://api.github.com/users/thisandagain/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/thisandagain/subscriptions","organizations_url":"https://api.github.com/users/thisandagain/orgs","repos_url":"https://api.github.com/users/thisandagain/repos","events_url":"https://api.github.com/users/thisandagain/events{/privacy}","received_events_url":"https://api.github.com/users/thisandagain/received_events","type":"User","site_admin":false},"open_issues":2,"closed_issues":0,"state":"open","created_at":"2018-08-20T20:07:20Z","updated_at":"2018-10-17T14:45:22Z","due_on":"2018-10-31T07:00:00Z","closed_at":null},"commits_url":"https://api.github.com/repos/LLK/scratch-svg-renderer/pulls/55/commits","review_comments_url":"https://api.github.com/repos/LLK/scratch-svg-renderer/pulls/55/comments","review_comment_url":"https://api.github.com/repos/LLK/scratch-svg-renderer/pulls/comments{/number}","comments_url":"https://api.github.com/repos/LLK/scratch-svg-renderer/issues/55/comments","statuses_url":"https://api.github.com/repos/LLK/scratch-svg-renderer/statuses/c489616a4082874bc59ea7ca7921d499b83c7702","head":{"label":"fsih:fixGradients","ref":"fixGradients","sha":"c489616a4082874bc59ea7ca7921d499b83c7702","user":{"login":"fsih","id":2855464,"node_id":"MDQ6VXNlcjI4NTU0NjQ=","avatar_url":"https://avatars3.githubusercontent.com/u/2855464?v=4","gravatar_id":"","url":"https://api.github.com/users/fsih","html_url":"https://github.com/fsih","followers_url":"https://api.github.com/users/fsih/followers","following_url":"https://api.github.com/users/fsih/following{/other_user}","gists_url":"https://api.github.com/users/fsih/gists{/gist_id}","starred_url":"https://api.github.com/users/fsih/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/fsih/subscriptions","organizations_url":"https://api.github.com/users/fsih/orgs","repos_url":"https://api.github.com/users/fsih/repos","events_url":"https://api.github.com/users/fsih/events{/privacy}","received_events_url":"https://api.github.com/users/fsih/received_events","type":"User","site_admin":false},"repo":{"id":118030142,"node_id":"MDEwOlJlcG9zaXRvcnkxMTgwMzAxNDI=","name":"scratch-svg-renderer","full_name":"fsih/scratch-svg-renderer","private":false,"owner":{"login":"fsih","id":2855464,"node_id":"MDQ6VXNlcjI4NTU0NjQ=","avatar_url":"https://avatars3.githubusercontent.com/u/2855464?v=4","gravatar_id":"","url":"https://api.github.com/users/fsih","html_url":"https://github.com/fsih","followers_url":"https://api.github.com/users/fsih/followers","following_url":"https://api.github.com/users/fsih/following{/other_user}","gists_url":"https://api.github.com/users/fsih/gists{/gist_id}","starred_url":"https://api.github.com/users/fsih/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/fsih/subscriptions","organizations_url":"https://api.github.com/users/fsih/orgs","repos_url":"https://api.github.com/users/fsih/repos","events_url":"https://api.github.com/users/fsih/events{/privacy}","received_events_url":"https://api.github.com/users/fsih/received_events","type":"User","site_admin":false},"html_url":"https://github.com/fsih/scratch-svg-renderer","description":"Scratch SVG renderer","fork":true,"url":"https://api.github.com/repos/fsih/scratch-svg-renderer","forks_url":"https://api.github.com/repos/fsih/scratch-svg-renderer/forks","keys_url":"https://api.github.com/repos/fsih/scratch-svg-renderer/keys{/key_id}","collaborators_url":"https://api.github.com/repos/fsih/scratch-svg-renderer/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/fsih/scratch-svg-renderer/teams","hooks_url":"https://api.github.com/repos/fsih/scratch-svg-renderer/hooks","issue_events_url":"https://api.github.com/repos/fsih/scratch-svg-renderer/issues/events{/number}","events_url":"https://api.github.com/repos/fsih/scratch-svg-renderer/events","assignees_url":"https://api.github.com/repos/fsih/scratch-svg-renderer/assignees{/user}","branches_url":"https://api.github.com/repos/fsih/scratch-svg-renderer/branches{/branch}","tags_url":"https://api.github.com/repos/fsih/scratch-svg-renderer/tags","blobs_url":"https://api.github.com/repos/fsih/scratch-svg-renderer/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/fsih/scratch-svg-renderer/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/fsih/scratch-svg-renderer/git/refs{/sha}","trees_url":"https://api.github.com/repos/fsih/scratch-svg-renderer/git/trees{/sha}","statuses_url":"https://api.github.com/repos/fsih/scratch-svg-renderer/statuses/{sha}","languages_url":"https://api.github.com/repos/fsih/scratch-svg-renderer/languages","stargazers_url":"https://api.github.com/repos/fsih/scratch-svg-renderer/stargazers","contributors_url":"https://api.github.com/repos/fsih/scratch-svg-renderer/contributors","subscribers_url":"https://api.github.com/repos/fsih/scratch-svg-renderer/subscribers","subscription_url":"https://api.github.com/repos/fsih/scratch-svg-renderer/subscription","commits_url":"https://api.github.com/repos/fsih/scratch-svg-renderer/commits{/sha}","git_commits_url":"https://api.github.com/repos/fsih/scratch-svg-renderer/git/commits{/sha}","comments_url":"https://api.github.com/repos/fsih/scratch-svg-renderer/comments{/number}","issue_comment_url":"https://api.github.com/repos/fsih/scratch-svg-renderer/issues/comments{/number}","contents_url":"https://api.github.com/repos/fsih/scratch-svg-renderer/contents/{+path}","compare_url":"https://api.github.com/repos/fsih/scratch-svg-renderer/compare/{base}...{head}","merges_url":"https://api.github.com/repos/fsih/scratch-svg-renderer/merges","archive_url":"https://api.github.com/repos/fsih/scratch-svg-renderer/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/fsih/scratch-svg-renderer/downloads","issues_url":"https://api.github.com/repos/fsih/scratch-svg-renderer/issues{/number}","pulls_url":"https://api.github.com/repos/fsih/scratch-svg-renderer/pulls{/number}","milestones_url":"https://api.github.com/repos/fsih/scratch-svg-renderer/milestones{/number}","notifications_url":"https://api.github.com/repos/fsih/scratch-svg-renderer/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/fsih/scratch-svg-renderer/labels{/name}","releases_url":"https://api.github.com/repos/fsih/scratch-svg-renderer/releases{/id}","deployments_url":"https://api.github.com/repos/fsih/scratch-svg-renderer/deployments","created_at":"2018-01-18T19:47:31Z","updated_at":"2018-01-18T19:47:32Z","pushed_at":"2018-10-17T14:39:17Z","git_url":"git://github.com/fsih/scratch-svg-renderer.git","ssh_url":"git@github.com:fsih/scratch-svg-renderer.git","clone_url":"https://github.com/fsih/scratch-svg-renderer.git","svn_url":"https://github.com/fsih/scratch-svg-renderer","homepage":null,"size":356,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":0,"license":{"key":"bsd-3-clause","name":"BSD 3-Clause \"New\" or \"Revised\" License","spdx_id":"BSD-3-Clause","url":"https://api.github.com/licenses/bsd-3-clause","node_id":"MDc6TGljZW5zZTU="},"forks":0,"open_issues":0,"watchers":0,"default_branch":"develop"}},"base":{"label":"LLK:develop","ref":"develop","sha":"430351df99c1ed3ceec79f5fa2999b905d69dbf0","user":{"login":"LLK","id":3420800,"node_id":"MDEyOk9yZ2FuaXphdGlvbjM0MjA4MDA=","avatar_url":"https://avatars1.githubusercontent.com/u/3420800?v=4","gravatar_id":"","url":"https://api.github.com/users/LLK","html_url":"https://github.com/LLK","followers_url":"https://api.github.com/users/LLK/followers","following_url":"https://api.github.com/users/LLK/following{/other_user}","gists_url":"https://api.github.com/users/LLK/gists{/gist_id}","starred_url":"https://api.github.com/users/LLK/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/LLK/subscriptions","organizations_url":"https://api.github.com/users/LLK/orgs","repos_url":"https://api.github.com/users/LLK/repos","events_url":"https://api.github.com/users/LLK/events{/privacy}","received_events_url":"https://api.github.com/users/LLK/received_events","type":"Organization","site_admin":false},"repo":{"id":117267980,"node_id":"MDEwOlJlcG9zaXRvcnkxMTcyNjc5ODA=","name":"scratch-svg-renderer","full_name":"LLK/scratch-svg-renderer","private":false,"owner":{"login":"LLK","id":3420800,"node_id":"MDEyOk9yZ2FuaXphdGlvbjM0MjA4MDA=","avatar_url":"https://avatars1.githubusercontent.com/u/3420800?v=4","gravatar_id":"","url":"https://api.github.com/users/LLK","html_url":"https://github.com/LLK","followers_url":"https://api.github.com/users/LLK/followers","following_url":"https://api.github.com/users/LLK/following{/other_user}","gists_url":"https://api.github.com/users/LLK/gists{/gist_id}","starred_url":"https://api.github.com/users/LLK/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/LLK/subscriptions","organizations_url":"https://api.github.com/users/LLK/orgs","repos_url":"https://api.github.com/users/LLK/repos","events_url":"https://api.github.com/users/LLK/events{/privacy}","received_events_url":"https://api.github.com/users/LLK/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/LLK/scratch-svg-renderer","description":"Scratch SVG renderer","fork":false,"url":"https://api.github.com/repos/LLK/scratch-svg-renderer","forks_url":"https://api.github.com/repos/LLK/scratch-svg-renderer/forks","keys_url":"https://api.github.com/repos/LLK/scratch-svg-renderer/keys{/key_id}","collaborators_url":"https://api.github.com/repos/LLK/scratch-svg-renderer/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/LLK/scratch-svg-renderer/teams","hooks_url":"https://api.github.com/repos/LLK/scratch-svg-renderer/hooks","issue_events_url":"https://api.github.com/repos/LLK/scratch-svg-renderer/issues/events{/number}","events_url":"https://api.github.com/repos/LLK/scratch-svg-renderer/events","assignees_url":"https://api.github.com/repos/LLK/scratch-svg-renderer/assignees{/user}","branches_url":"https://api.github.com/repos/LLK/scratch-svg-renderer/branches{/branch}","tags_url":"https://api.github.com/repos/LLK/scratch-svg-renderer/tags","blobs_url":"https://api.github.com/repos/LLK/scratch-svg-renderer/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/LLK/scratch-svg-renderer/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/LLK/scratch-svg-renderer/git/refs{/sha}","trees_url":"https://api.github.com/repos/LLK/scratch-svg-renderer/git/trees{/sha}","statuses_url":"https://api.github.com/repos/LLK/scratch-svg-renderer/statuses/{sha}","languages_url":"https://api.github.com/repos/LLK/scratch-svg-renderer/languages","stargazers_url":"https://api.github.com/repos/LLK/scratch-svg-renderer/stargazers","contributors_url":"https://api.github.com/repos/LLK/scratch-svg-renderer/contributors","subscribers_url":"https://api.github.com/repos/LLK/scratch-svg-renderer/subscribers","subscription_url":"https://api.github.com/repos/LLK/scratch-svg-renderer/subscription","commits_url":"https://api.github.com/repos/LLK/scratch-svg-renderer/commits{/sha}","git_commits_url":"https://api.github.com/repos/LLK/scratch-svg-renderer/git/commits{/sha}","comments_url":"https://api.github.com/repos/LLK/scratch-svg-renderer/comments{/number}","issue_comment_url":"https://api.github.com/repos/LLK/scratch-svg-renderer/issues/comments{/number}","contents_url":"https://api.github.com/repos/LLK/scratch-svg-renderer/contents/{+path}","compare_url":"https://api.github.com/repos/LLK/scratch-svg-renderer/compare/{base}...{head}","merges_url":"https://api.github.com/repos/LLK/scratch-svg-renderer/merges","archive_url":"https://api.github.com/repos/LLK/scratch-svg-renderer/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/LLK/scratch-svg-renderer/downloads","issues_url":"https://api.github.com/repos/LLK/scratch-svg-renderer/issues{/number}","pulls_url":"https://api.github.com/repos/LLK/scratch-svg-renderer/pulls{/number}","milestones_url":"https://api.github.com/repos/LLK/scratch-svg-renderer/milestones{/number}","notifications_url":"https://api.github.com/repos/LLK/scratch-svg-renderer/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/LLK/scratch-svg-renderer/labels{/name}","releases_url":"https://api.github.com/repos/LLK/scratch-svg-renderer/releases{/id}","deployments_url":"https://api.github.com/repos/LLK/scratch-svg-renderer/deployments","created_at":"2018-01-12T17:13:37Z","updated_at":"2018-10-08T05:43:32Z","pushed_at":"2018-10-17T14:45:23Z","git_url":"git://github.com/LLK/scratch-svg-renderer.git","ssh_url":"git@github.com:LLK/scratch-svg-renderer.git","clone_url":"https://github.com/LLK/scratch-svg-renderer.git","svn_url":"https://github.com/LLK/scratch-svg-renderer","homepage":null,"size":373,"stargazers_count":9,"watchers_count":9,"language":"JavaScript","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":12,"mirror_url":null,"archived":false,"open_issues_count":12,"license":{"key":"bsd-3-clause","name":"BSD 3-Clause \"New\" or \"Revised\" License","spdx_id":"BSD-3-Clause","url":"https://api.github.com/licenses/bsd-3-clause","node_id":"MDc6TGljZW5zZTU="},"forks":12,"open_issues":12,"watchers":9,"default_branch":"develop"}},"_links":{"self":{"href":"https://api.github.com/repos/LLK/scratch-svg-renderer/pulls/55"},"html":{"href":"https://github.com/LLK/scratch-svg-renderer/pull/55"},"issue":{"href":"https://api.github.com/repos/LLK/scratch-svg-renderer/issues/55"},"comments":{"href":"https://api.github.com/repos/LLK/scratch-svg-renderer/issues/55/comments"},"review_comments":{"href":"https://api.github.com/repos/LLK/scratch-svg-renderer/pulls/55/comments"},"review_comment":{"href":"https://api.github.com/repos/LLK/scratch-svg-renderer/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/LLK/scratch-svg-renderer/pulls/55/commits"},"statuses":{"href":"https://api.github.com/repos/LLK/scratch-svg-renderer/statuses/c489616a4082874bc59ea7ca7921d499b83c7702"}},"author_association":"MEMBER"}}
{"actor":{"display_login":"cwillisf"}}