{"action":"created","issue":{"url":"https://api.github.com/repos/Automattic/wp-calypso/issues/7620","repository_url":"https://api.github.com/repos/Automattic/wp-calypso","labels_url":"https://api.github.com/repos/Automattic/wp-calypso/issues/7620/labels{/name}","comments_url":"https://api.github.com/repos/Automattic/wp-calypso/issues/7620/comments","events_url":"https://api.github.com/repos/Automattic/wp-calypso/issues/7620/events","html_url":"https://github.com/Automattic/wp-calypso/pull/7620","id":172765542,"number":7620,"title":"State: move ui.currentPreviewUrl to ui.preview.currentPreviewUrl","user":{"login":"sirbrillig","id":2036909,"avatar_url":"https://avatars.githubusercontent.com/u/2036909?v=3","gravatar_id":"","url":"https://api.github.com/users/sirbrillig","html_url":"https://github.com/sirbrillig","followers_url":"https://api.github.com/users/sirbrillig/followers","following_url":"https://api.github.com/users/sirbrillig/following{/other_user}","gists_url":"https://api.github.com/users/sirbrillig/gists{/gist_id}","starred_url":"https://api.github.com/users/sirbrillig/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sirbrillig/subscriptions","organizations_url":"https://api.github.com/users/sirbrillig/orgs","repos_url":"https://api.github.com/users/sirbrillig/repos","events_url":"https://api.github.com/users/sirbrillig/events{/privacy}","received_events_url":"https://api.github.com/users/sirbrillig/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/Automattic/wp-calypso/labels/[Status]%20Needs%20Review","name":"[Status] Needs Review","color":"fbca04"}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":2,"created_at":"2016-08-23T17:59:29Z","updated_at":"2016-08-24T17:37:08Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/Automattic/wp-calypso/pulls/7620","html_url":"https://github.com/Automattic/wp-calypso/pull/7620","diff_url":"https://github.com/Automattic/wp-calypso/pull/7620.diff","patch_url":"https://github.com/Automattic/wp-calypso/pull/7620.patch"},"body":"Adds a `state.ui.preview` tree to make it easier to add more preview-related UI state reducers in the future.\r\n\r\nPartially extracted from #7477\r\n\r\n### Testing\r\n\r\nTwo views are affected by this change: `DesignPreview` and `PostActionsEllipsisMenuView`\r\n\r\n1. Test the \"regular\" preview functionality by visiting any page under my-sites like `/posts/my/[your site here]` and clicking the icon next to your site title:\r\n\r\n<img width=\"250\" alt=\"screen_shot_2016-08-16_at_4_32_06_pm\" src=\"https://cloud.githubusercontent.com/assets/2036909/17714754/1893c2d0-63cf-11e6-81fe-107f521d6abf.png\">\r\n\r\nThe preview should appear as normal.\r\n\r\n<img width=\"940\" alt=\"screen shot 2016-08-16 at 4 36 02 pm\" src=\"https://cloud.githubusercontent.com/assets/2036909/17714847/8d9f2ea2-63cf-11e6-9141-49bd0d7c5166.png\">\r\n\r\n2. Visit a post type page like: `/types/post/drafts/[your site here]` and click the \"...\" menu next to a post. Click \"Preview\":\r\n\r\n<img width=\"926\" alt=\"screen_shot_2016-08-19_at_4_55_27_pm\" src=\"https://cloud.githubusercontent.com/assets/2036909/17824084/e0f1b8f8-662d-11e6-8211-9e4c6db00287.png\">\r\n\r\nMake sure the preview of *that post* (not the front page of your site) appears:\r\n\r\n<img width=\"936\" alt=\"screen shot 2016-08-23 at 2 04 24 pm\" src=\"https://cloud.githubusercontent.com/assets/2036909/17903736/8da6c2b4-693a-11e6-9bee-45428f7f7622.png\">\r\n\r\n\r\n\r\nTest live: https://calypso.live/?branch=add/state-ui-preview"},"comment":{"url":"https://api.github.com/repos/Automattic/wp-calypso/issues/comments/242147862","html_url":"https://github.com/Automattic/wp-calypso/pull/7620#issuecomment-242147862","issue_url":"https://api.github.com/repos/Automattic/wp-calypso/issues/7620","id":242147862,"user":{"login":"kwight","id":349751,"avatar_url":"https://avatars.githubusercontent.com/u/349751?v=3","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":"2016-08-24T17:37:07Z","updated_at":"2016-08-24T17:37:07Z","body":"Works as expected according to the testing directions (tested both `/types/post/draft` and /types/page/draft`). I noticed the Preview link in the standard views (eg. /posts/drafts) pop out to a new tab, but I'm assuming that's a separate thing from what we're doing here?\r\n\r\nCouldn't find any other references to `clearPreviewUrl` or `setPreviewUrl` either. :y:"}}
{"actor":{"display_login":"kwight"}}