{"action":"created","issue":{"url":"https://api.github.com/repos/Automattic/wp-calypso/issues/27297","repository_url":"https://api.github.com/repos/Automattic/wp-calypso","labels_url":"https://api.github.com/repos/Automattic/wp-calypso/issues/27297/labels{/name}","comments_url":"https://api.github.com/repos/Automattic/wp-calypso/issues/27297/comments","events_url":"https://api.github.com/repos/Automattic/wp-calypso/issues/27297/events","html_url":"https://github.com/Automattic/wp-calypso/pull/27297","id":361519133,"node_id":"MDExOlB1bGxSZXF1ZXN0MjE2NDcxNDg0","number":27297,"title":"Editor: Add the Gutenberg demo title to new Gutenberg posts.","user":{"login":"kwight","id":349751,"node_id":"MDQ6VXNlcjM0OTc1MQ==","avatar_url":"https://avatars2.githubusercontent.com/u/349751?v=4","gravatar_id":"","url":"https://api.github.com/users/kwight","html_url":"https://github.com/kwight","followers_url":"https://api.github.com/users/kwight/followers","following_url":"https://api.github.com/users/kwight/following{/other_user}","gists_url":"https://api.github.com/users/kwight/gists{/gist_id}","starred_url":"https://api.github.com/users/kwight/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kwight/subscriptions","organizations_url":"https://api.github.com/users/kwight/orgs","repos_url":"https://api.github.com/users/kwight/repos","events_url":"https://api.github.com/users/kwight/events{/privacy}","received_events_url":"https://api.github.com/users/kwight/received_events","type":"User","site_admin":false},"labels":[{"id":285009995,"node_id":"MDU6TGFiZWwyODUwMDk5OTU=","url":"https://api.github.com/repos/Automattic/wp-calypso/labels/Editor","name":"Editor","color":"006b75","default":false},{"id":967391996,"node_id":"MDU6TGFiZWw5NjczOTE5OTY=","url":"https://api.github.com/repos/Automattic/wp-calypso/labels/[Goal]%20Gutenberg","name":"[Goal] Gutenberg","color":"97f4d2","default":false},{"id":285010018,"node_id":"MDU6TGFiZWwyODUwMTAwMTg=","url":"https://api.github.com/repos/Automattic/wp-calypso/labels/[Status]%20Needs%20Review","name":"[Status] Needs Review","color":"fbca04","default":false},{"id":285010032,"node_id":"MDU6TGFiZWwyODUwMTAwMzI=","url":"https://api.github.com/repos/Automattic/wp-calypso/labels/[Type]%20Task","name":"[Type] Task","color":"0052cc","default":false}],"state":"open","locked":false,"assignee":{"login":"kwight","id":349751,"node_id":"MDQ6VXNlcjM0OTc1MQ==","avatar_url":"https://avatars2.githubusercontent.com/u/349751?v=4","gravatar_id":"","url":"https://api.github.com/users/kwight","html_url":"https://github.com/kwight","followers_url":"https://api.github.com/users/kwight/followers","following_url":"https://api.github.com/users/kwight/following{/other_user}","gists_url":"https://api.github.com/users/kwight/gists{/gist_id}","starred_url":"https://api.github.com/users/kwight/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kwight/subscriptions","organizations_url":"https://api.github.com/users/kwight/orgs","repos_url":"https://api.github.com/users/kwight/repos","events_url":"https://api.github.com/users/kwight/events{/privacy}","received_events_url":"https://api.github.com/users/kwight/received_events","type":"User","site_admin":false},"assignees":[{"login":"kwight","id":349751,"node_id":"MDQ6VXNlcjM0OTc1MQ==","avatar_url":"https://avatars2.githubusercontent.com/u/349751?v=4","gravatar_id":"","url":"https://api.github.com/users/kwight","html_url":"https://github.com/kwight","followers_url":"https://api.github.com/users/kwight/followers","following_url":"https://api.github.com/users/kwight/following{/other_user}","gists_url":"https://api.github.com/users/kwight/gists{/gist_id}","starred_url":"https://api.github.com/users/kwight/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kwight/subscriptions","organizations_url":"https://api.github.com/users/kwight/orgs","repos_url":"https://api.github.com/users/kwight/repos","events_url":"https://api.github.com/users/kwight/events{/privacy}","received_events_url":"https://api.github.com/users/kwight/received_events","type":"User","site_admin":false}],"milestone":null,"comments":2,"created_at":"2018-09-18T23:18:22Z","updated_at":"2018-09-19T17:36:28Z","closed_at":null,"author_association":"MEMBER","pull_request":{"url":"https://api.github.com/repos/Automattic/wp-calypso/pulls/27297","html_url":"https://github.com/Automattic/wp-calypso/pull/27297","diff_url":"https://github.com/Automattic/wp-calypso/pull/27297.diff","patch_url":"https://github.com/Automattic/wp-calypso/pull/27297.patch"},"body":"If we receive an auto-draft on opening the Gutenberg editor, replace its default \"Auto Draft\" title with that of the `wp-admin` demo post: \"Welcome to the Gutenberg Editor\". This should also allow easily adding the demo content as a next step.\r\n\r\n<img width=\"1088\" alt=\"screen shot 2018-09-18 at 4 11 42 pm\" src=\"https://user-images.githubusercontent.com/349751/45721725-1a751200-bb5e-11e8-9763-e7beed5cf010.png\">\r\n\r\nFixes #27162 .\r\n\r\n**Testing**\r\n\r\n1. Load this branch, go to `https://calypso.localhost:3000/gutenberg/post`, and select a site.\r\n2. This will create a new Gutenberg post, which should have \"Welcome to the Gutenberg Editor\" for the title."},"comment":{"url":"https://api.github.com/repos/Automattic/wp-calypso/issues/comments/422892715","html_url":"https://github.com/Automattic/wp-calypso/pull/27297#issuecomment-422892715","issue_url":"https://api.github.com/repos/Automattic/wp-calypso/issues/27297","id":422892715,"node_id":"MDEyOklzc3VlQ29tbWVudDQyMjg5MjcxNQ==","user":{"login":"kwight","id":349751,"node_id":"MDQ6VXNlcjM0OTc1MQ==","avatar_url":"https://avatars2.githubusercontent.com/u/349751?v=4","gravatar_id":"","url":"https://api.github.com/users/kwight","html_url":"https://github.com/kwight","followers_url":"https://api.github.com/users/kwight/followers","following_url":"https://api.github.com/users/kwight/following{/other_user}","gists_url":"https://api.github.com/users/kwight/gists{/gist_id}","starred_url":"https://api.github.com/users/kwight/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kwight/subscriptions","organizations_url":"https://api.github.com/users/kwight/orgs","repos_url":"https://api.github.com/users/kwight/repos","events_url":"https://api.github.com/users/kwight/events{/privacy}","received_events_url":"https://api.github.com/users/kwight/received_events","type":"User","site_admin":false},"created_at":"2018-09-19T17:36:28Z","updated_at":"2018-09-19T17:36:28Z","author_association":"MEMBER","body":"> Why would we want to force a title into the editor when the post has an auto-draft status?\r\n\r\nTo load, Gutenberg requires a valid post (p7jreA-1N0-p2), so if we're creating a new post, that comes in the form of an auto-draft (and [auto-drafts have a default title](https://core.trac.wordpress.org/browser/trunk/src/wp-admin/includes/post.php#L642) of \"Auto Draft\"). Something more useful to the user would be better (and this PR lines that up with the default content for the Gutenberg demo in `wp-admin`).\r\n\r\n> Are there any chances that auto-draft is set at some point to the post (my understanding is that it's only used for revisions, but still), effectively replacing the post title with the \"Welcome\" message?\r\n\r\nNot sure what you mean, but the first time the auto-draft is, erm, auto-saved, its status will go from `auto-draft` to a normal `draft` (I've confirmed this behaviour in both core and Calypso). Auto-drafts are [cleaned up by core](https://core.trac.wordpress.org/browser/trunk/src/wp-includes/post.php#L6597) every seven days."}}
{"actor":{"display_login":"kwight"}}