{"action":"created","comment":{"url":"https://api.github.com/repos/Automattic/wp-calypso/pulls/comments/60768185","id":60768185,"diff_hunk":"@@ -77,18 +90,20 @@ const EditorPostFormats = React.createClass( {\n \t},\n \n \trenderPostFormats: function() {\n+\t\tvar selectedFormat = this.getSelectedPostFormat();\n+\n \t\treturn this.getPostFormats().map( function( postFormat ) {\n \t\t\treturn (\n \t\t\t\t<li key={ postFormat.slug } className=\"editor-post-formats__format\">\n \t\t\t\t\t<label>\n \t\t\t\t\t\t<FormRadio\n \t\t\t\t\t\t\tname=\"format\"\n \t\t\t\t\t\t\tvalue={ postFormat.slug }\n-\t\t\t\t\t\t\tchecked={ postFormat.slug === this.props.value }\n+\t\t\t\t\t\t\tchecked={ postFormat.slug === selectedFormat }\n \t\t\t\t\t\t\tonChange={ this.onChange } />\n \t\t\t\t\t\t<span className=\"editor-post-formats__format-label\">\n \t\t\t\t\t\t\t<span className={ 'editor-post-formats__format-icon' } >\n-\t\t\t\t\t\t\t\t<Gridicon icon={ this.getPostFormatIcon( postFormat ) } size={ 20 } />\n+\t\t\t\t\t\t\t\t<Gridicon icon={ this.getPostFormatIcon( postFormat ) } size={ 18 } />","path":"client/post-editor/editor-post-formats/index.jsx","position":46,"original_position":46,"commit_id":"1c342a8f5f59090c9a10c55afac5470ccfd73703","original_commit_id":"1c342a8f5f59090c9a10c55afac5470ccfd73703","user":{"login":"timmyc","id":22080,"avatar_url":"https://avatars.githubusercontent.com/u/22080?v=3","gravatar_id":"","url":"https://api.github.com/users/timmyc","html_url":"https://github.com/timmyc","followers_url":"https://api.github.com/users/timmyc/followers","following_url":"https://api.github.com/users/timmyc/following{/other_user}","gists_url":"https://api.github.com/users/timmyc/gists{/gist_id}","starred_url":"https://api.github.com/users/timmyc/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/timmyc/subscriptions","organizations_url":"https://api.github.com/users/timmyc/orgs","repos_url":"https://api.github.com/users/timmyc/repos","events_url":"https://api.github.com/users/timmyc/events{/privacy}","received_events_url":"https://api.github.com/users/timmyc/received_events","type":"User","site_admin":false},"body":"There was a lint failure on this line, that informed me the prior value of `20` did not follow proper Gridicon usage.  Not sure if we need to adjust any other styles because of this /cc @hugobaeta ","created_at":"2016-04-22T16:42:30Z","updated_at":"2016-04-22T16:42:30Z","html_url":"https://github.com/Automattic/wp-calypso/pull/4965#discussion_r60768185","pull_request_url":"https://api.github.com/repos/Automattic/wp-calypso/pulls/4965","_links":{"self":{"href":"https://api.github.com/repos/Automattic/wp-calypso/pulls/comments/60768185"},"html":{"href":"https://github.com/Automattic/wp-calypso/pull/4965#discussion_r60768185"},"pull_request":{"href":"https://api.github.com/repos/Automattic/wp-calypso/pulls/4965"}}},"pull_request":{"url":"https://api.github.com/repos/Automattic/wp-calypso/pulls/4965","id":67540109,"html_url":"https://github.com/Automattic/wp-calypso/pull/4965","diff_url":"https://github.com/Automattic/wp-calypso/pull/4965.diff","patch_url":"https://github.com/Automattic/wp-calypso/pull/4965.patch","issue_url":"https://api.github.com/repos/Automattic/wp-calypso/issues/4965","number":4965,"state":"open","locked":false,"title":"Editor: ensure the value for Default Post Format is in list of available","user":{"login":"timmyc","id":22080,"avatar_url":"https://avatars.githubusercontent.com/u/22080?v=3","gravatar_id":"","url":"https://api.github.com/users/timmyc","html_url":"https://github.com/timmyc","followers_url":"https://api.github.com/users/timmyc/followers","following_url":"https://api.github.com/users/timmyc/following{/other_user}","gists_url":"https://api.github.com/users/timmyc/gists{/gist_id}","starred_url":"https://api.github.com/users/timmyc/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/timmyc/subscriptions","organizations_url":"https://api.github.com/users/timmyc/orgs","repos_url":"https://api.github.com/users/timmyc/repos","events_url":"https://api.github.com/users/timmyc/events{/privacy}","received_events_url":"https://api.github.com/users/timmyc/received_events","type":"User","site_admin":false},"body":"Fixes #1000\r\n\r\nCurrently you can arrive at a state where the default post format set for a site is not an option in the post format listing in the editor sidebar.  I was able to re-create this issue with the Journalistic Theme by setting my default post format to \"Aside\".\r\n\r\nAside is not a valid post format for my theme but the option is [hard-coded](https://github.com/Automattic/wp-calypso/blob/master/client/my-sites/site-settings/form-writing.jsx#L93-L102) into Site Settings > Writing.  Perhaps that should be re-visited, but regardless, the logic in this branch should still be in place to validate the `default_post_format`.\r\n\r\nSo by setting my post format to aside, this is how things look in the editor sidebar:\r\n\r\n__Before__\r\n<img width=\"273\" alt=\"new_post_ _trout_bummin_ _wordpress_com\" src=\"https://cloud.githubusercontent.com/assets/22080/14748336/f00700b4-086d-11e6-92c2-b88b2f85c86c.png\">\r\n\r\n__After__\r\n<img width=\"272\" alt=\"new_post_ _trout_bummin_ _wordpress_com\" src=\"https://cloud.githubusercontent.com/assets/22080/14748358/15ba8d12-086e-11e6-829f-29b19f4afb78.png\">\r\n\r\n__To Test__\r\n- Set your default post format for a site to one that is not supported by your theme, you can surface one by comparing the list in Site Settings -> Writing to what you see in the editor sidebar\r\n- Open a new post in the editor, validate that the default post format is \"Standard\" and the proper radio button is selected in the accordion","created_at":"2016-04-22T16:41:17Z","updated_at":"2016-04-22T16:42:30Z","closed_at":null,"merged_at":null,"merge_commit_sha":"f70f64b0a3cb4ace4af5b32811ba05e8549db17d","assignee":{"login":"timmyc","id":22080,"avatar_url":"https://avatars.githubusercontent.com/u/22080?v=3","gravatar_id":"","url":"https://api.github.com/users/timmyc","html_url":"https://github.com/timmyc","followers_url":"https://api.github.com/users/timmyc/followers","following_url":"https://api.github.com/users/timmyc/following{/other_user}","gists_url":"https://api.github.com/users/timmyc/gists{/gist_id}","starred_url":"https://api.github.com/users/timmyc/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/timmyc/subscriptions","organizations_url":"https://api.github.com/users/timmyc/orgs","repos_url":"https://api.github.com/users/timmyc/repos","events_url":"https://api.github.com/users/timmyc/events{/privacy}","received_events_url":"https://api.github.com/users/timmyc/received_events","type":"User","site_admin":false},"milestone":null,"commits_url":"https://api.github.com/repos/Automattic/wp-calypso/pulls/4965/commits","review_comments_url":"https://api.github.com/repos/Automattic/wp-calypso/pulls/4965/comments","review_comment_url":"https://api.github.com/repos/Automattic/wp-calypso/pulls/comments{/number}","comments_url":"https://api.github.com/repos/Automattic/wp-calypso/issues/4965/comments","statuses_url":"https://api.github.com/repos/Automattic/wp-calypso/statuses/1c342a8f5f59090c9a10c55afac5470ccfd73703","head":{"label":"Automattic:fix/editor/1000","ref":"fix/editor/1000","sha":"1c342a8f5f59090c9a10c55afac5470ccfd73703","user":{"login":"Automattic","id":887802,"avatar_url":"https://avatars.githubusercontent.com/u/887802?v=3","gravatar_id":"","url":"https://api.github.com/users/Automattic","html_url":"https://github.com/Automattic","followers_url":"https://api.github.com/users/Automattic/followers","following_url":"https://api.github.com/users/Automattic/following{/other_user}","gists_url":"https://api.github.com/users/Automattic/gists{/gist_id}","starred_url":"https://api.github.com/users/Automattic/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Automattic/subscriptions","organizations_url":"https://api.github.com/users/Automattic/orgs","repos_url":"https://api.github.com/users/Automattic/repos","events_url":"https://api.github.com/users/Automattic/events{/privacy}","received_events_url":"https://api.github.com/users/Automattic/received_events","type":"Organization","site_admin":false},"repo":{"id":45936895,"name":"wp-calypso","full_name":"Automattic/wp-calypso","owner":{"login":"Automattic","id":887802,"avatar_url":"https://avatars.githubusercontent.com/u/887802?v=3","gravatar_id":"","url":"https://api.github.com/users/Automattic","html_url":"https://github.com/Automattic","followers_url":"https://api.github.com/users/Automattic/followers","following_url":"https://api.github.com/users/Automattic/following{/other_user}","gists_url":"https://api.github.com/users/Automattic/gists{/gist_id}","starred_url":"https://api.github.com/users/Automattic/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Automattic/subscriptions","organizations_url":"https://api.github.com/users/Automattic/orgs","repos_url":"https://api.github.com/users/Automattic/repos","events_url":"https://api.github.com/users/Automattic/events{/privacy}","received_events_url":"https://api.github.com/users/Automattic/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/Automattic/wp-calypso","description":"The new JavaScript- and API-powered WordPress.com","fork":false,"url":"https://api.github.com/repos/Automattic/wp-calypso","forks_url":"https://api.github.com/repos/Automattic/wp-calypso/forks","keys_url":"https://api.github.com/repos/Automattic/wp-calypso/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Automattic/wp-calypso/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Automattic/wp-calypso/teams","hooks_url":"https://api.github.com/repos/Automattic/wp-calypso/hooks","issue_events_url":"https://api.github.com/repos/Automattic/wp-calypso/issues/events{/number}","events_url":"https://api.github.com/repos/Automattic/wp-calypso/events","assignees_url":"https://api.github.com/repos/Automattic/wp-calypso/assignees{/user}","branches_url":"https://api.github.com/repos/Automattic/wp-calypso/branches{/branch}","tags_url":"https://api.github.com/repos/Automattic/wp-calypso/tags","blobs_url":"https://api.github.com/repos/Automattic/wp-calypso/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Automattic/wp-calypso/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Automattic/wp-calypso/git/refs{/sha}","trees_url":"https://api.github.com/repos/Automattic/wp-calypso/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Automattic/wp-calypso/statuses/{sha}","languages_url":"https://api.github.com/repos/Automattic/wp-calypso/languages","stargazers_url":"https://api.github.com/repos/Automattic/wp-calypso/stargazers","contributors_url":"https://api.github.com/repos/Automattic/wp-calypso/contributors","subscribers_url":"https://api.github.com/repos/Automattic/wp-calypso/subscribers","subscription_url":"https://api.github.com/repos/Automattic/wp-calypso/subscription","commits_url":"https://api.github.com/repos/Automattic/wp-calypso/commits{/sha}","git_commits_url":"https://api.github.com/repos/Automattic/wp-calypso/git/commits{/sha}","comments_url":"https://api.github.com/repos/Automattic/wp-calypso/comments{/number}","issue_comment_url":"https://api.github.com/repos/Automattic/wp-calypso/issues/comments{/number}","contents_url":"https://api.github.com/repos/Automattic/wp-calypso/contents/{+path}","compare_url":"https://api.github.com/repos/Automattic/wp-calypso/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Automattic/wp-calypso/merges","archive_url":"https://api.github.com/repos/Automattic/wp-calypso/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Automattic/wp-calypso/downloads","issues_url":"https://api.github.com/repos/Automattic/wp-calypso/issues{/number}","pulls_url":"https://api.github.com/repos/Automattic/wp-calypso/pulls{/number}","milestones_url":"https://api.github.com/repos/Automattic/wp-calypso/milestones{/number}","notifications_url":"https://api.github.com/repos/Automattic/wp-calypso/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Automattic/wp-calypso/labels{/name}","releases_url":"https://api.github.com/repos/Automattic/wp-calypso/releases{/id}","deployments_url":"https://api.github.com/repos/Automattic/wp-calypso/deployments","created_at":"2015-11-10T20:00:16Z","updated_at":"2016-04-22T15:04:16Z","pushed_at":"2016-04-22T16:41:17Z","git_url":"git://github.com/Automattic/wp-calypso.git","ssh_url":"git@github.com:Automattic/wp-calypso.git","clone_url":"https://github.com/Automattic/wp-calypso.git","svn_url":"https://github.com/Automattic/wp-calypso","homepage":"https://developer.wordpress.com/calypso/","size":74625,"stargazers_count":7193,"watchers_count":7193,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":866,"mirror_url":null,"open_issues_count":1287,"forks":866,"open_issues":1287,"watchers":7193,"default_branch":"master"}},"base":{"label":"Automattic:master","ref":"master","sha":"1aab1cba05f4a311d57aaa04eaed3f7507dcc6df","user":{"login":"Automattic","id":887802,"avatar_url":"https://avatars.githubusercontent.com/u/887802?v=3","gravatar_id":"","url":"https://api.github.com/users/Automattic","html_url":"https://github.com/Automattic","followers_url":"https://api.github.com/users/Automattic/followers","following_url":"https://api.github.com/users/Automattic/following{/other_user}","gists_url":"https://api.github.com/users/Automattic/gists{/gist_id}","starred_url":"https://api.github.com/users/Automattic/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Automattic/subscriptions","organizations_url":"https://api.github.com/users/Automattic/orgs","repos_url":"https://api.github.com/users/Automattic/repos","events_url":"https://api.github.com/users/Automattic/events{/privacy}","received_events_url":"https://api.github.com/users/Automattic/received_events","type":"Organization","site_admin":false},"repo":{"id":45936895,"name":"wp-calypso","full_name":"Automattic/wp-calypso","owner":{"login":"Automattic","id":887802,"avatar_url":"https://avatars.githubusercontent.com/u/887802?v=3","gravatar_id":"","url":"https://api.github.com/users/Automattic","html_url":"https://github.com/Automattic","followers_url":"https://api.github.com/users/Automattic/followers","following_url":"https://api.github.com/users/Automattic/following{/other_user}","gists_url":"https://api.github.com/users/Automattic/gists{/gist_id}","starred_url":"https://api.github.com/users/Automattic/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Automattic/subscriptions","organizations_url":"https://api.github.com/users/Automattic/orgs","repos_url":"https://api.github.com/users/Automattic/repos","events_url":"https://api.github.com/users/Automattic/events{/privacy}","received_events_url":"https://api.github.com/users/Automattic/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/Automattic/wp-calypso","description":"The new JavaScript- and API-powered WordPress.com","fork":false,"url":"https://api.github.com/repos/Automattic/wp-calypso","forks_url":"https://api.github.com/repos/Automattic/wp-calypso/forks","keys_url":"https://api.github.com/repos/Automattic/wp-calypso/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Automattic/wp-calypso/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Automattic/wp-calypso/teams","hooks_url":"https://api.github.com/repos/Automattic/wp-calypso/hooks","issue_events_url":"https://api.github.com/repos/Automattic/wp-calypso/issues/events{/number}","events_url":"https://api.github.com/repos/Automattic/wp-calypso/events","assignees_url":"https://api.github.com/repos/Automattic/wp-calypso/assignees{/user}","branches_url":"https://api.github.com/repos/Automattic/wp-calypso/branches{/branch}","tags_url":"https://api.github.com/repos/Automattic/wp-calypso/tags","blobs_url":"https://api.github.com/repos/Automattic/wp-calypso/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Automattic/wp-calypso/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Automattic/wp-calypso/git/refs{/sha}","trees_url":"https://api.github.com/repos/Automattic/wp-calypso/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Automattic/wp-calypso/statuses/{sha}","languages_url":"https://api.github.com/repos/Automattic/wp-calypso/languages","stargazers_url":"https://api.github.com/repos/Automattic/wp-calypso/stargazers","contributors_url":"https://api.github.com/repos/Automattic/wp-calypso/contributors","subscribers_url":"https://api.github.com/repos/Automattic/wp-calypso/subscribers","subscription_url":"https://api.github.com/repos/Automattic/wp-calypso/subscription","commits_url":"https://api.github.com/repos/Automattic/wp-calypso/commits{/sha}","git_commits_url":"https://api.github.com/repos/Automattic/wp-calypso/git/commits{/sha}","comments_url":"https://api.github.com/repos/Automattic/wp-calypso/comments{/number}","issue_comment_url":"https://api.github.com/repos/Automattic/wp-calypso/issues/comments{/number}","contents_url":"https://api.github.com/repos/Automattic/wp-calypso/contents/{+path}","compare_url":"https://api.github.com/repos/Automattic/wp-calypso/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Automattic/wp-calypso/merges","archive_url":"https://api.github.com/repos/Automattic/wp-calypso/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Automattic/wp-calypso/downloads","issues_url":"https://api.github.com/repos/Automattic/wp-calypso/issues{/number}","pulls_url":"https://api.github.com/repos/Automattic/wp-calypso/pulls{/number}","milestones_url":"https://api.github.com/repos/Automattic/wp-calypso/milestones{/number}","notifications_url":"https://api.github.com/repos/Automattic/wp-calypso/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Automattic/wp-calypso/labels{/name}","releases_url":"https://api.github.com/repos/Automattic/wp-calypso/releases{/id}","deployments_url":"https://api.github.com/repos/Automattic/wp-calypso/deployments","created_at":"2015-11-10T20:00:16Z","updated_at":"2016-04-22T15:04:16Z","pushed_at":"2016-04-22T16:41:17Z","git_url":"git://github.com/Automattic/wp-calypso.git","ssh_url":"git@github.com:Automattic/wp-calypso.git","clone_url":"https://github.com/Automattic/wp-calypso.git","svn_url":"https://github.com/Automattic/wp-calypso","homepage":"https://developer.wordpress.com/calypso/","size":74625,"stargazers_count":7193,"watchers_count":7193,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":866,"mirror_url":null,"open_issues_count":1287,"forks":866,"open_issues":1287,"watchers":7193,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/Automattic/wp-calypso/pulls/4965"},"html":{"href":"https://github.com/Automattic/wp-calypso/pull/4965"},"issue":{"href":"https://api.github.com/repos/Automattic/wp-calypso/issues/4965"},"comments":{"href":"https://api.github.com/repos/Automattic/wp-calypso/issues/4965/comments"},"review_comments":{"href":"https://api.github.com/repos/Automattic/wp-calypso/pulls/4965/comments"},"review_comment":{"href":"https://api.github.com/repos/Automattic/wp-calypso/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/Automattic/wp-calypso/pulls/4965/commits"},"statuses":{"href":"https://api.github.com/repos/Automattic/wp-calypso/statuses/1c342a8f5f59090c9a10c55afac5470ccfd73703"}}}}