{"action":"created","issue":{"url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/issues/4225","labels_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/issues/4225/labels{/name}","comments_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/issues/4225/comments","events_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/issues/4225/events","html_url":"https://github.com/wordpress-mobile/WordPress-iOS/pull/4225","id":103789272,"number":4225,"title":"Issues/4093 reader list refresh","user":{"login":"aerych","id":1435271,"avatar_url":"https://avatars.githubusercontent.com/u/1435271?v=3","gravatar_id":"","url":"https://api.github.com/users/aerych","html_url":"https://github.com/aerych","followers_url":"https://api.github.com/users/aerych/followers","following_url":"https://api.github.com/users/aerych/following{/other_user}","gists_url":"https://api.github.com/users/aerych/gists{/gist_id}","starred_url":"https://api.github.com/users/aerych/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/aerych/subscriptions","organizations_url":"https://api.github.com/users/aerych/orgs","repos_url":"https://api.github.com/users/aerych/repos","events_url":"https://api.github.com/users/aerych/events{/privacy}","received_events_url":"https://api.github.com/users/aerych/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":{"url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/milestones/46","html_url":"https://github.com/wordpress-mobile/WordPress-iOS/milestones/5.7","labels_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/milestones/46/labels","id":1188116,"number":46,"title":"5.7","description":null,"creator":{"login":"sendhil","id":437043,"avatar_url":"https://avatars.githubusercontent.com/u/437043?v=3","gravatar_id":"","url":"https://api.github.com/users/sendhil","html_url":"https://github.com/sendhil","followers_url":"https://api.github.com/users/sendhil/followers","following_url":"https://api.github.com/users/sendhil/following{/other_user}","gists_url":"https://api.github.com/users/sendhil/gists{/gist_id}","starred_url":"https://api.github.com/users/sendhil/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sendhil/subscriptions","organizations_url":"https://api.github.com/users/sendhil/orgs","repos_url":"https://api.github.com/users/sendhil/repos","events_url":"https://api.github.com/users/sendhil/events{/privacy}","received_events_url":"https://api.github.com/users/sendhil/received_events","type":"User","site_admin":false},"open_issues":13,"closed_issues":10,"state":"open","created_at":"2015-06-30T23:23:14Z","updated_at":"2015-09-04T06:30:59Z","due_on":"2015-10-08T00:00:00Z","closed_at":null},"comments":9,"created_at":"2015-08-28T20:20:57Z","updated_at":"2015-09-04T13:55:01Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/pulls/4225","html_url":"https://github.com/wordpress-mobile/WordPress-iOS/pull/4225","diff_url":"https://github.com/wordpress-mobile/WordPress-iOS/pull/4225.diff","patch_url":"https://github.com/wordpress-mobile/WordPress-iOS/pull/4225.patch"},"body":"Refs #4093 \r\n\r\nThis PR adds the refreshed reader post list to the app, but does not yet replace the current reader post list pending additional work. \r\n\r\nThe new `ReaderStreamViewController` ports the current `ReaderPostsViewController` to Swift. Other changes include:\r\n- Adds header views for site, tag, and some list topics. \r\n- Consolidates the functionality of the (now deprecated) `ReaderBrowseSiteViewController` \r\n- Adopts storyboards an xibs for layout\r\n- Improvements to the refresh mechanism. \r\n- Convenience methods for identifying a topic type.  These are subject to change when refreshing the topic model\r\n- Allows sharing posts from the list\r\n- Updates the (now deprecated) `ReaderPostsViewController` to reconcile other changes made to the `ReaderPostService` and `WPTableViewHandler`.\r\n\r\n#### Please note: \r\n- Card layout is pending a refresh to be full screen on the iPhone. \r\n- Some features in the new header views (e.g. following, some data fields) are not implemented pending improvements to the `ReaderTopic` model in a later.\r\n\r\nOf particular interest is this PR changes the `NSManagedObjectContext` used for fetching and displaying content in the new list, and in the old list, to be a child context of our main context, but also running on the main queue.  Syncing is still performed on a private queue, derived context. This is done for better separation of concerns and encapsulation of the mechanism to refresh the table view while preserving the visible content.  cc @astralbodies\r\n\r\n\r\n#### Things to test:\r\n\r\n#### General:\r\n- Does the new list load?\r\n- Does pull to refresh function?\r\n- Does load more function? \r\n\r\n#### Headers: \r\n- Freshly Pressed, Posts I Like, and Following feeds should not show a header. \r\n- Tags should show a tag header (following is not implemented)\r\n- Browsing a site should show a site header. Some content is a placeholder. Following is not enabled. \r\n- Custom lists should show a list header.  Some content is a placeholder.\r\n\r\n#### Cell Menus:\r\n- You should not see an option to block a site while browsing a site, or browsing Following.\r\n- You should be able to block a site, and undo a block.  Pull to refresh should clear an undo cell. \r\n- You should be able to share a post via the share menu option. \r\n\r\n#### Cell Features: \r\n- You should be able to like or unlike a post by tapping the like button in a cell\r\n- You should be able to view comments by tapping on the comment button in a cell\r\n- You should be able to view a post detail by tapping on a cell\r\n\r\n#### Site Browsing:\r\n- Tapping the site name or blavatar should browse a site. \r\n- When browsing a site, the site name should be disabled. Tapping the site name or blavatar should be like any other tap on a cell. \r\n\r\n#### Old list:\r\nPull to refresh should still work. \r\nInfinite scroll / load more should still work. \r\nYou should still be able to like or unlike a post from a cell\r\n\r\n### How to test\r\nYou'll need to edit `ReaderViewController.m` to use `ReaderStreamViewController` instead of `ReaderPostViewController`.  The relevant changes are in [this gist](https://gist.github.com/aerych/feeff93b445adb7d655c).\r\n\r\n@jleandroperez, can I trouble you for a review?  I expect there are a few opportunities to improve my Swift code that you could suggest.\r\n\r\nNeeds Review: @jleandroperez \r\n\r\n\r\n\r\n\r\n"},"comment":{"url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/issues/comments/137743695","html_url":"https://github.com/wordpress-mobile/WordPress-iOS/pull/4225#issuecomment-137743695","issue_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/issues/4225","id":137743695,"user":{"login":"aerych","id":1435271,"avatar_url":"https://avatars.githubusercontent.com/u/1435271?v=3","gravatar_id":"","url":"https://api.github.com/users/aerych","html_url":"https://github.com/aerych","followers_url":"https://api.github.com/users/aerych/followers","following_url":"https://api.github.com/users/aerych/following{/other_user}","gists_url":"https://api.github.com/users/aerych/gists{/gist_id}","starred_url":"https://api.github.com/users/aerych/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/aerych/subscriptions","organizations_url":"https://api.github.com/users/aerych/orgs","repos_url":"https://api.github.com/users/aerych/repos","events_url":"https://api.github.com/users/aerych/events{/privacy}","received_events_url":"https://api.github.com/users/aerych/received_events","type":"User","site_admin":false},"created_at":"2015-09-04T13:55:01Z","updated_at":"2015-09-04T13:55:01Z","body":"> Re: Like button, (maybe) one workaround would be to set a constraint for the button's height, so that it doesn't shift on like / unlike.\r\n\r\nDid you mean width? Its tricky when we consider how width might change with localizations, and we want everything to be flush right no matter what. "}}