{"action":"created","comment":{"url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/pulls/comments/61959487","id":61959487,"diff_hunk":"@@ -0,0 +1,475 @@\n+#import \"MenuItemSourceView.h\"\n+#import \"MenuItemSourceTextBar.h\"\n+#import \"Menu.h\"\n+#import \"MenuItemSourceFooterView.h\"\n+#import \"Blog.h\"\n+#import \"Menu+ViewDesign.h\"\n+#import \"WPStyleGuide.h\"\n+\n+static NSTimeInterval const SearchBarFetchRequestUpdateDelay = 0.10;\n+static NSTimeInterval const SearchBarRemoteServiceUpdateDelay = 0.25;\n+\n+@interface MenuItemSourceView () <MenuItemSourceTextBarDelegate>\n+\n+/**\n+ View used as the tableView.tableHeaderView container view for self.stackView.\n+ */\n+@property (nonatomic, strong, readonly) UIView *stackedTableHeaderView;\n+\n+@property (nonatomic, strong, readonly) MenuItemSourceFooterView *footerView;\n+@property (nonatomic, assign) BOOL observeUserScrollingForEndOfTableView;\n+\n+@end\n+\n+@implementation MenuItemSourceView\n+\n+- (id)init\n+{\n+    self = [super init];\n+    if (self) {\n+        \n+        self.translatesAutoresizingMaskIntoConstraints = NO;\n+        self.backgroundColor = [UIColor whiteColor];\n+        \n+        [self initTableView];\n+        [self initStackedTableHeaderView];\n+        [self initStackView];\n+        [self initFooterView];\n+    }\n+    \n+    return self;\n+}\n+\n+- (void)initTableView\n+{\n+    UITableView *tableView = [[UITableView alloc] init];\n+    tableView.translatesAutoresizingMaskIntoConstraints = NO;\n+    tableView.dataSource = self;\n+    tableView.delegate = self;\n+    tableView.separatorColor = [WPStyleGuide greyLighten20];\n+    UIEdgeInsets inset = tableView.contentInset;\n+    inset.top = MenusDesignDefaultContentSpacing / 2.0;\n+    tableView.contentInset = inset;\n+    [self addSubview:tableView];\n+    \n+    [NSLayoutConstraint activateConstraints:@[\n+                                              [tableView.topAnchor constraintEqualToAnchor:self.topAnchor],\n+                                              [tableView.leadingAnchor constraintEqualToAnchor:self.leadingAnchor],\n+                                              [tableView.trailingAnchor constraintEqualToAnchor:self.trailingAnchor],\n+                                              [tableView.bottomAnchor constraintEqualToAnchor:self.bottomAnchor]\n+                                              ]];\n+    _tableView = tableView;\n+}\n+\n+- (void)initStackedTableHeaderView\n+{\n+    // setup the tableHeaderView and keep translatesAutoresizingMaskIntoConstraints to default YES\n+    // this allows the tableView to handle sizing the view as any other tableHeaderView\n+    UIView *stackedTableHeaderView = [[UIView alloc] init];\n+    _stackedTableHeaderView = stackedTableHeaderView;\n+}\n+\n+- (void)initStackView\n+{\n+    UIStackView *stackView = [[UIStackView alloc] init];\n+    stackView.translatesAutoresizingMaskIntoConstraints = NO;\n+    stackView.distribution = UIStackViewDistributionFill;\n+    stackView.alignment = UIStackViewAlignmentFill;\n+    stackView.axis = UILayoutConstraintAxisVertical;\n+    stackView.spacing = MenusDesignDefaultContentSpacing / 2.0;\n+    \n+    UIEdgeInsets margins = UIEdgeInsetsZero;\n+    margins.bottom = stackView.spacing;\n+    margins.left = MenusDesignDefaultContentSpacing;\n+    margins.right = MenusDesignDefaultContentSpacing;\n+    stackView.layoutMargins = margins;\n+    stackView.layoutMarginsRelativeArrangement = YES;\n+    \n+    NSAssert(_stackedTableHeaderView != nil, @\"stackedTableHeaderView is nil\");\n+    [_stackedTableHeaderView addSubview:stackView];\n+    // setup the constraints for the stackView\n+    // constrain the horiztonal edges to sync the width to the stackedTableHeaderView\n+    // do not include a bottom constraint so the stackView can layout its intrinsic height\n+    [NSLayoutConstraint activateConstraints:@[\n+                                              [stackView.topAnchor constraintEqualToAnchor:_stackedTableHeaderView.topAnchor],\n+                                              [stackView.leadingAnchor constraintEqualToAnchor:_stackedTableHeaderView.leadingAnchor],\n+                                              [stackView.trailingAnchor constraintEqualToAnchor:_stackedTableHeaderView.trailingAnchor]\n+                                              ]];\n+    _stackView = stackView;\n+}\n+\n+- (void)initFooterView\n+{\n+    MenuItemSourceFooterView *footerView = [[MenuItemSourceFooterView alloc] initWithFrame:CGRectMake(0, 0, self.tableView.frame.size.width, 60.0)];\n+    \n+    NSAssert(_tableView != nil, @\"tableView is nil\");\n+    _tableView.tableFooterView = footerView;\n+    \n+    _footerView = footerView;\n+}\n+\n+- (BOOL)resignFirstResponder\n+{\n+    if ([self.searchBar isFirstResponder]) {\n+        return [self.searchBar resignFirstResponder];\n+    }\n+    return [super resignFirstResponder];\n+}\n+\n+#pragma mark - view configuration\n+\n+- (void)layoutSubviews\n+{\n+    [super layoutSubviews];\n+    \n+    BOOL needsOffsetFix = NO;\n+    if (!self.tableView.tableHeaderView) {\n+        // set the tableHeaderView after we have called layoutSubviews the first time\n+        // this add the stackedTableHeaderView to view hierarchy\n+        self.tableView.tableHeaderView = self.stackedTableHeaderView;\n+        [self.stackedTableHeaderView layoutIfNeeded];\n+        needsOffsetFix = YES;\n+    }\n+\n+    // set the stackedTableHeaderView frame height to the intrinsic height of the stackView\n+    CGRect frame = self.stackView.bounds;\n+    self.stackedTableHeaderView.frame = frame;\n+    // reset the tableHeaderView to update the size change\n+    self.tableView.tableHeaderView = self.stackedTableHeaderView;\n+    \n+    if (needsOffsetFix) {\n+        if (self.tableView.contentOffset.y == 0.0) {\n+            CGPoint offset = self.tableView.contentOffset;\n+            offset.y = -self.tableView.contentInset.top;\n+            self.tableView.contentOffset = offset;\n+        }\n+    }\n+}\n+\n+- (void)refresh\n+{\n+    [self.tableView reloadData];\n+}\n+\n+- (void)insertSearchBarIfNeeded\n+{\n+    if (self.searchBar) {\n+        return;\n+    }\n+    \n+    MenuItemSourceTextBar *searchBar = [[MenuItemSourceTextBar alloc] initAsSearchBar];\n+    searchBar.translatesAutoresizingMaskIntoConstraints = NO;\n+    searchBar.delegate = self;\n+    \n+    NSAssert(_stackView != nil, @\"stackView is nil\");\n+    [_stackView addArrangedSubview:searchBar];\n+    \n+    NSLayoutConstraint *heightConstraint = [searchBar.heightAnchor constraintEqualToConstant:44.0];\n+    heightConstraint.priority = UILayoutPriorityDefaultHigh;\n+    heightConstraint.active = YES;\n+    \n+    [searchBar setContentCompressionResistancePriority:UILayoutPriorityDefaultHigh forAxis:UILayoutConstraintAxisVertical];\n+    _searchBar = searchBar;\n+    \n+    __weak MenuItemSourceView *weakSelf = self;\n+    {\n+        MenuItemSourceTextBarFieldObserver *observer = [[MenuItemSourceTextBarFieldObserver alloc] init];\n+        observer.interval = SearchBarFetchRequestUpdateDelay;\n+        [observer setOnTextChange:^(NSString *text) {\n+            [weakSelf searchBarInputChangeDetectedForLocalResultsUpdateWithText:text];\n+        }];\n+        [_searchBar addTextObserver:observer];\n+    }\n+    {\n+        MenuItemSourceTextBarFieldObserver *observer = [[MenuItemSourceTextBarFieldObserver alloc] init];\n+        observer.interval = SearchBarRemoteServiceUpdateDelay;\n+        [observer setOnTextChange:^(NSString *text) {\n+            [weakSelf searchBarInputChangeDetectedForRemoteResultsUpdateWithText:text];\n+        }];\n+        [_searchBar addTextObserver:observer];\n+    }\n+}\n+\n+- (BOOL)searchBarInputIsActive\n+{\n+    return [self.searchBar isFirstResponder] || self.searchBar.textField.text.length > 0;\n+}\n+\n+- (void)searchBarInputChangeDetectedForLocalResultsUpdateWithText:(NSString *)searchText\n+{\n+    // overrided in subclasses\n+}\n+\n+- (void)searchBarInputChangeDetectedForRemoteResultsUpdateWithText:(NSString *)searchText\n+{\n+    // overrided in subclasses\n+}\n+\n+- (void)showLoadingSourcesIndicatorIfEmpty\n+{\n+    if ([self fetchedResultsAreEmpty]) {\n+        [self showLoadingSourcesIndicator];\n+    }\n+}\n+\n+- (void)showLoadingSourcesIndicator\n+{\n+    [self.footerView startLoadingIndicatorAnimation];\n+}\n+\n+- (void)hideLoadingSourcesIndicator\n+{\n+    [self.footerView stopLoadingIndicatorAnimation];\n+    [self toggleNoResultsIndiciator];\n+}\n+\n+- (void)showLoadingErrorMessageForResults\n+{\n+    NSString *text = NSLocalizedString(@\"An error occurred loading the results, please try again in a moment.\", @\"The error message displayed when a user is editing a MenuItem and the results cannot be loaded, such as posts, pages, etc.\");\n+    [self.footerView toggleMessageWithText:text];\n+}\n+\n+- (BOOL)itemTypeMatchesSourceItemType\n+{\n+    return [self.item.type isEqualToString:[self sourceItemType]];\n+}\n+\n+- (void)setItemSourceWithContentID:(NSNumber *)contentID name:(NSString *)name\n+{\n+    MenuItem *item = self.item;\n+    if (item.contentID.integerValue == contentID.integerValue && item.type == [self sourceItemType]) {\n+        // No update needed.\n+        return;\n+    }\n+    item.contentID = contentID;\n+    item.type = [self sourceItemType];\n+    if (name.length && [self.delegate sourceViewItemNameCanBeOverridden:self]) {\n+        item.name = name;\n+    }\n+    [self.delegate sourceViewDidUpdateItem:self];\n+}\n+\n+- (NSString *)sourceItemType\n+{\n+    // overrided in subclasses\n+    return nil;\n+}\n+\n+- (void)toggleNoResultsIndiciator\n+{\n+    if ([self fetchedResultsAreEmpty] && !self.defersFooterViewMessageUpdates) {\n+        if (self.searchBarInputIsActive) {\n+            [self.footerView toggleMessageWithText:NSLocalizedString(@\"No results. Please try a different search.\", @\"Shown when user is searching for specific Menu item options and no items are available, such as posts, pages, etc.\")];\n+        } else {\n+            [self.footerView toggleMessageWithText:NSLocalizedString(@\"Nothing found.\", @\"Shown when user is loading Menu item options and no items are available, such as posts, pages, etc.\")];\n+        }\n+    } else {\n+        [self.footerView toggleMessageWithText:nil];\n+    }\n+}\n+\n+#pragma mark - NSFetchedResultsController and subclass methods\n+\n+- (NSFetchedResultsController *)resultsController\n+{\n+    NSFetchRequest *fetchRequest = nil;\n+    if (!_resultsController && [self managedObjectContext] && (fetchRequest = [self fetchRequest])) {\n+        \n+        NSFetchedResultsController *resultsController = [[NSFetchedResultsController alloc] initWithFetchRequest:fetchRequest managedObjectContext:[self managedObjectContext] sectionNameKeyPath:[self fetechedResultsControllerSectionNameKeyPath] cacheName:nil];\n+        resultsController.delegate = self;\n+        _resultsController = resultsController;\n+    }\n+    \n+    return _resultsController;\n+}\n+\n+- (NSManagedObjectContext *)managedObjectContext\n+{\n+    return self.blog.managedObjectContext;\n+}\n+\n+- (NSFetchRequest *)fetchRequest\n+{\n+    // overrided in subclasses\n+    return nil;\n+}\n+\n+- (NSPredicate *)defaultFetchRequestPredicate\n+{\n+    // overrided in subclasses if needed\n+    NSPredicate *predicate = [NSPredicate predicateWithFormat:@\"blog == %@\", [self blog]];\n+    return predicate;\n+}\n+\n+- (NSString *)fetechedResultsControllerSectionNameKeyPath\n+{\n+    // overrided in subclasses\n+    return nil;\n+}\n+\n+- (void)performResultsControllerFetchRequest\n+{\n+    if (!self.resultsController) {\n+        return;\n+    }\n+    NSError *error;\n+    if (![self.resultsController performFetch:&error]) {\n+        DDLogError(@\"Error occurred preforming fetch for MenuItem source of type: %@ error: %@\", [self sourceItemType], error);\n+    }\n+    [self toggleNoResultsIndiciator];\n+}\n+\n+- (BOOL)fetchedResultsAreEmpty\n+{\n+    return self.resultsController.fetchedObjects.count == 0;\n+}\n+\n+- (void)deselectVisibleSourceCellsIfNeeded\n+{\n+    NSArray *cells = [self.tableView visibleCells];\n+    for (MenuItemSourceCell *cell in cells) {\n+        if (![cell isKindOfClass:[MenuItemSourceCell class]]) {\n+            continue;\n+        }\n+        if (cell.sourceSelected) {\n+            cell.sourceSelected = NO;\n+        }\n+    }\n+}\n+\n+#pragma mark - subclass configuration\n+\n+- (void)configureSourceCell:(MenuItemSourceCell *)cell forIndexPath:(NSIndexPath *)indexPath\n+{\n+    // overrided in subclasses\n+}\n+\n+- (void)scrollingWillDisplayEndOfTableView:(UITableView *)tableView\n+{\n+    // overrided in subclasses\n+}\n+\n+#pragma mark - UIScrollView\n+\n+- (void)scrollViewWillBeginDragging:(UIScrollView *)scrollView\n+{\n+    self.observeUserScrollingForEndOfTableView = YES;\n+}\n+\n+- (void)scrollViewDidEndDragging:(UIScrollView *)scrollView willDecelerate:(BOOL)decelerate\n+{\n+    if (!decelerate) {\n+        self.observeUserScrollingForEndOfTableView = NO;\n+    }\n+}\n+\n+- (void)scrollViewDidEndDecelerating:(UIScrollView *)scrollView\n+{\n+    self.observeUserScrollingForEndOfTableView = NO;\n+}\n+\n+#pragma mark - UITableView\n+\n+- (NSInteger)numberOfSectionsInTableView:(UITableView *)tableView\n+{\n+    return self.resultsController.sections.count;\n+}\n+\n+- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section\n+{\n+    id <NSFetchedResultsSectionInfo> sectionInfo = [[self.resultsController sections] objectAtIndex:section];\n+    return [sectionInfo numberOfObjects];\n+}\n+\n+- (CGFloat)tableView:(UITableView *)tableView estimatedHeightForRowAtIndexPath:(NSIndexPath *)indexPath\n+{\n+    return 50;\n+}\n+\n+- (CGFloat)tableView:(UITableView *)tableView heightForRowAtIndexPath:(NSIndexPath *)indexPath\n+{\n+    return UITableViewAutomaticDimension;\n+}\n+\n+- (void)tableView:(UITableView *)tableView willDisplayCell:(nonnull UITableViewCell *)cell forRowAtIndexPath:(nonnull NSIndexPath *)indexPath\n+{\n+    NSInteger numSections = self.resultsController.sections.count;\n+    if (indexPath.section == numSections - 1 && self.observeUserScrollingForEndOfTableView) {","path":"WordPress/Classes/ViewRelated/Menus/Views/MenuItemSourceView.m","position":397,"original_position":397,"commit_id":"2999a393fea17ffec4dc01ff527453d950e41720","original_commit_id":"2999a393fea17ffec4dc01ff527453d950e41720","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},"body":"It would be nice if we could return early to avoid some of the nested conditionals. ","created_at":"2016-05-03T21:29:00Z","updated_at":"2016-05-03T21:29:00Z","html_url":"https://github.com/wordpress-mobile/WordPress-iOS/pull/5268#discussion_r61959487","pull_request_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/pulls/5268","_links":{"self":{"href":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/pulls/comments/61959487"},"html":{"href":"https://github.com/wordpress-mobile/WordPress-iOS/pull/5268#discussion_r61959487"},"pull_request":{"href":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/pulls/5268"}}},"pull_request":{"url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/pulls/5268","id":68633233,"html_url":"https://github.com/wordpress-mobile/WordPress-iOS/pull/5268","diff_url":"https://github.com/wordpress-mobile/WordPress-iOS/pull/5268.diff","patch_url":"https://github.com/wordpress-mobile/WordPress-iOS/pull/5268.patch","issue_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/issues/5268","number":5268,"state":"open","locked":false,"title":"Menus: Views for editing a MenuItem's source.","user":{"login":"kurzee","id":1873422,"avatar_url":"https://avatars.githubusercontent.com/u/1873422?v=3","gravatar_id":"","url":"https://api.github.com/users/kurzee","html_url":"https://github.com/kurzee","followers_url":"https://api.github.com/users/kurzee/followers","following_url":"https://api.github.com/users/kurzee/following{/other_user}","gists_url":"https://api.github.com/users/kurzee/gists{/gist_id}","starred_url":"https://api.github.com/users/kurzee/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kurzee/subscriptions","organizations_url":"https://api.github.com/users/kurzee/orgs","repos_url":"https://api.github.com/users/kurzee/repos","events_url":"https://api.github.com/users/kurzee/events{/privacy}","received_events_url":"https://api.github.com/users/kurzee/received_events","type":"User","site_admin":false},"body":"Adding a collection of views responsible for handling the loading and selection of different sources a `MenuItem` can point to.\r\n\r\nUltimately, these views live within views not included in this PR: `MenuItemEditingViewController` and `MenuItemSourceContainerView`. I've broken up the PR flow to limit as many lines as possible between reviewers. For the sake of that, this PR focuses only on the source views included that live within the limited red area outlined here:\r\n\r\n![simulator screen shot may 2 2016 5 11 11 pm](https://cloud.githubusercontent.com/assets/1873422/14969656/1bc90ecc-1089-11e6-9c50-f8debd563a39.png)\r\n\r\n**To test:**\r\n\r\n1. Build and run the staging branch `feature/menus-views` to load the complete Menus implementation.\r\n2. Select a .com site with admin rights.\r\n3. Select \"Menus\" under the site options.\r\n4. Select a `MenuItem` to edit its source, such as \"Home\", \"About\", \"Blog\", etc.\r\n5. Source views are loaded as Pages, Posts, Link, Categories, Tags or Posts using [custom content types](https://jetpack.com/support/custom-content-types/).\r\n6. You can select different types by hitting the header area with the left chevron, which loads the corresponding sources in the correct source view.\r\n\r\n![menus_sources](https://cloud.githubusercontent.com/assets/1873422/14970152/73632fde-108c-11e6-8ae2-dc901c0bacd4.gif)\r\n\r\n**Pages**\r\n\r\n1. Test that pages load as expected for a site.\r\n2. Test that searching loads both local and remote pages.\r\n\r\n**Posts**\r\n\r\n1. Test that posts load as expected for a site.\r\n2. Test that searching loads both local and remote posts.\r\n3. Test that posts continue loading via paging when scrolling to the bottom for a site with many posts.\r\n\r\n**Link**\r\n\r\n1. Test that the \"LINK ADDRESS (URL)\" field accepts text as expected.\r\n2. Test that the \"Open new link\" checkbox checks and un-checks as expected.\r\n\r\n**Categories**\r\n\r\n1. Test that the categories load as expected for a site.\r\n2. Ensure the parent/child nesting is as expected for a site.\r\n\r\n**Tags**\r\n\r\n1. Test that the tags load as expected for a site.\r\n2. Test that searching tags loads both local and remote tags for a site as expected.\r\n3. Test that paging a long list of tags loads as expected for a site.\r\n\r\n**Custom Posts**\r\n\r\n1. Load some custom post types for a site/theme as noted in https://jetpack.com/support/custom-content-types/\r\n2. Create posts using these types on the site.\r\n3. Load the associated custom type with the app Menus editing.\r\n4. Test that the custom posts load as expected for the site.\r\n\r\nNeeds review: @aerych (let me know if you'd like me to break this up additionally)","created_at":"2016-05-02T22:38:18Z","updated_at":"2016-05-03T21:29:00Z","closed_at":null,"merged_at":null,"merge_commit_sha":"916e20c6324893fb22409d386e16b394f908216a","assignee":{"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},"milestone":{"url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/milestones/54","html_url":"https://github.com/wordpress-mobile/WordPress-iOS/milestones/6.3","labels_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/milestones/54/labels","id":1562509,"number":54,"title":"6.3","description":"","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":11,"closed_issues":32,"state":"open","created_at":"2016-02-04T04:45:27Z","updated_at":"2016-05-03T21:26:23Z","due_on":null,"closed_at":null},"commits_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/pulls/5268/commits","review_comments_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/pulls/5268/comments","review_comment_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/pulls/comments{/number}","comments_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/issues/5268/comments","statuses_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/statuses/2999a393fea17ffec4dc01ff527453d950e41720","head":{"label":"wordpress-mobile:feature/menus-source-views","ref":"feature/menus-source-views","sha":"2999a393fea17ffec4dc01ff527453d950e41720","user":{"login":"wordpress-mobile","id":1306301,"avatar_url":"https://avatars.githubusercontent.com/u/1306301?v=3","gravatar_id":"","url":"https://api.github.com/users/wordpress-mobile","html_url":"https://github.com/wordpress-mobile","followers_url":"https://api.github.com/users/wordpress-mobile/followers","following_url":"https://api.github.com/users/wordpress-mobile/following{/other_user}","gists_url":"https://api.github.com/users/wordpress-mobile/gists{/gist_id}","starred_url":"https://api.github.com/users/wordpress-mobile/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/wordpress-mobile/subscriptions","organizations_url":"https://api.github.com/users/wordpress-mobile/orgs","repos_url":"https://api.github.com/users/wordpress-mobile/repos","events_url":"https://api.github.com/users/wordpress-mobile/events{/privacy}","received_events_url":"https://api.github.com/users/wordpress-mobile/received_events","type":"Organization","site_admin":false},"repo":{"id":8859285,"name":"WordPress-iOS","full_name":"wordpress-mobile/WordPress-iOS","owner":{"login":"wordpress-mobile","id":1306301,"avatar_url":"https://avatars.githubusercontent.com/u/1306301?v=3","gravatar_id":"","url":"https://api.github.com/users/wordpress-mobile","html_url":"https://github.com/wordpress-mobile","followers_url":"https://api.github.com/users/wordpress-mobile/followers","following_url":"https://api.github.com/users/wordpress-mobile/following{/other_user}","gists_url":"https://api.github.com/users/wordpress-mobile/gists{/gist_id}","starred_url":"https://api.github.com/users/wordpress-mobile/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/wordpress-mobile/subscriptions","organizations_url":"https://api.github.com/users/wordpress-mobile/orgs","repos_url":"https://api.github.com/users/wordpress-mobile/repos","events_url":"https://api.github.com/users/wordpress-mobile/events{/privacy}","received_events_url":"https://api.github.com/users/wordpress-mobile/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/wordpress-mobile/WordPress-iOS","description":"WordPress for iOS - Official repository","fork":false,"url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS","forks_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/forks","keys_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/keys{/key_id}","collaborators_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/teams","hooks_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/hooks","issue_events_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/issues/events{/number}","events_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/events","assignees_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/assignees{/user}","branches_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/branches{/branch}","tags_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/tags","blobs_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/git/refs{/sha}","trees_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/git/trees{/sha}","statuses_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/statuses/{sha}","languages_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/languages","stargazers_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/stargazers","contributors_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/contributors","subscribers_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/subscribers","subscription_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/subscription","commits_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/commits{/sha}","git_commits_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/git/commits{/sha}","comments_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/comments{/number}","issue_comment_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/issues/comments{/number}","contents_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/contents/{+path}","compare_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/compare/{base}...{head}","merges_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/merges","archive_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/downloads","issues_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/issues{/number}","pulls_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/pulls{/number}","milestones_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/milestones{/number}","notifications_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/labels{/name}","releases_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/releases{/id}","deployments_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/deployments","created_at":"2013-03-18T16:59:33Z","updated_at":"2016-05-03T06:13:56Z","pushed_at":"2016-05-03T21:26:44Z","git_url":"git://github.com/wordpress-mobile/WordPress-iOS.git","ssh_url":"git@github.com:wordpress-mobile/WordPress-iOS.git","clone_url":"https://github.com/wordpress-mobile/WordPress-iOS.git","svn_url":"https://github.com/wordpress-mobile/WordPress-iOS","homepage":"http://ios.wordpress.org/","size":493389,"stargazers_count":1009,"watchers_count":1009,"language":"Objective-C","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":459,"mirror_url":null,"open_issues_count":350,"forks":459,"open_issues":350,"watchers":1009,"default_branch":"develop"}},"base":{"label":"wordpress-mobile:develop","ref":"develop","sha":"432bfac78e45a73b0ecfad9b1e246697ea78cc8c","user":{"login":"wordpress-mobile","id":1306301,"avatar_url":"https://avatars.githubusercontent.com/u/1306301?v=3","gravatar_id":"","url":"https://api.github.com/users/wordpress-mobile","html_url":"https://github.com/wordpress-mobile","followers_url":"https://api.github.com/users/wordpress-mobile/followers","following_url":"https://api.github.com/users/wordpress-mobile/following{/other_user}","gists_url":"https://api.github.com/users/wordpress-mobile/gists{/gist_id}","starred_url":"https://api.github.com/users/wordpress-mobile/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/wordpress-mobile/subscriptions","organizations_url":"https://api.github.com/users/wordpress-mobile/orgs","repos_url":"https://api.github.com/users/wordpress-mobile/repos","events_url":"https://api.github.com/users/wordpress-mobile/events{/privacy}","received_events_url":"https://api.github.com/users/wordpress-mobile/received_events","type":"Organization","site_admin":false},"repo":{"id":8859285,"name":"WordPress-iOS","full_name":"wordpress-mobile/WordPress-iOS","owner":{"login":"wordpress-mobile","id":1306301,"avatar_url":"https://avatars.githubusercontent.com/u/1306301?v=3","gravatar_id":"","url":"https://api.github.com/users/wordpress-mobile","html_url":"https://github.com/wordpress-mobile","followers_url":"https://api.github.com/users/wordpress-mobile/followers","following_url":"https://api.github.com/users/wordpress-mobile/following{/other_user}","gists_url":"https://api.github.com/users/wordpress-mobile/gists{/gist_id}","starred_url":"https://api.github.com/users/wordpress-mobile/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/wordpress-mobile/subscriptions","organizations_url":"https://api.github.com/users/wordpress-mobile/orgs","repos_url":"https://api.github.com/users/wordpress-mobile/repos","events_url":"https://api.github.com/users/wordpress-mobile/events{/privacy}","received_events_url":"https://api.github.com/users/wordpress-mobile/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/wordpress-mobile/WordPress-iOS","description":"WordPress for iOS - Official repository","fork":false,"url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS","forks_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/forks","keys_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/keys{/key_id}","collaborators_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/teams","hooks_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/hooks","issue_events_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/issues/events{/number}","events_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/events","assignees_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/assignees{/user}","branches_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/branches{/branch}","tags_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/tags","blobs_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/git/refs{/sha}","trees_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/git/trees{/sha}","statuses_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/statuses/{sha}","languages_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/languages","stargazers_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/stargazers","contributors_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/contributors","subscribers_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/subscribers","subscription_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/subscription","commits_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/commits{/sha}","git_commits_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/git/commits{/sha}","comments_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/comments{/number}","issue_comment_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/issues/comments{/number}","contents_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/contents/{+path}","compare_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/compare/{base}...{head}","merges_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/merges","archive_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/downloads","issues_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/issues{/number}","pulls_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/pulls{/number}","milestones_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/milestones{/number}","notifications_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/labels{/name}","releases_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/releases{/id}","deployments_url":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/deployments","created_at":"2013-03-18T16:59:33Z","updated_at":"2016-05-03T06:13:56Z","pushed_at":"2016-05-03T21:26:44Z","git_url":"git://github.com/wordpress-mobile/WordPress-iOS.git","ssh_url":"git@github.com:wordpress-mobile/WordPress-iOS.git","clone_url":"https://github.com/wordpress-mobile/WordPress-iOS.git","svn_url":"https://github.com/wordpress-mobile/WordPress-iOS","homepage":"http://ios.wordpress.org/","size":493389,"stargazers_count":1009,"watchers_count":1009,"language":"Objective-C","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":459,"mirror_url":null,"open_issues_count":350,"forks":459,"open_issues":350,"watchers":1009,"default_branch":"develop"}},"_links":{"self":{"href":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/pulls/5268"},"html":{"href":"https://github.com/wordpress-mobile/WordPress-iOS/pull/5268"},"issue":{"href":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/issues/5268"},"comments":{"href":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/issues/5268/comments"},"review_comments":{"href":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/pulls/5268/comments"},"review_comment":{"href":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/pulls/5268/commits"},"statuses":{"href":"https://api.github.com/repos/wordpress-mobile/WordPress-iOS/statuses/2999a393fea17ffec4dc01ff527453d950e41720"}}}}