Skip to content

Commit

Permalink
Bug 1355121 - Add the correct insets for the onboarding view in AS. (#…
Browse files Browse the repository at this point in the history
…2620) r=sleroux
  • Loading branch information
farhanpatel committed Apr 12, 2017
1 parent 636a921 commit a93cb54
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions Client/Frontend/Home/ActivityStreamPanel.swift
Expand Up @@ -154,7 +154,7 @@ extension ActivityStreamPanel {
case .topSites:
return UIDevice.current.userInterfaceIdiom == .pad ? ASPanelUX.SectionInsetsForIpad : 0
case .highlightIntro:
return 0
return UIDevice.current.userInterfaceIdiom == .pad ? ASPanelUX.SectionInsetsForIpad : 0
}
}

Expand All @@ -176,7 +176,7 @@ extension ActivityStreamPanel {
case .topSites:
return CGSize(width: frameWidth - inset, height: height)
case .highlightIntro:
return CGSize(width: frameWidth - inset, height: height)
return CGSize(width: frameWidth - inset - (ASHorizontalScrollCellUX.MinimumInsets * 2), height: height)
}
}

Expand Down
2 changes: 1 addition & 1 deletion Client/Frontend/Widgets/ActivityStreamHighlightCell.swift
Expand Up @@ -212,7 +212,7 @@ class HighlightIntroCell: UICollectionViewCell {
titleLabel.text = Strings.HighlightIntroTitle
descriptionLabel.text = Strings.HighlightIntroDescription

let titleInsets = UIEdgeInsets(top: HighlightIntroCellUX.margin, left: HighlightIntroCellUX.margin, bottom: 0, right: 0)
let titleInsets = UIEdgeInsets(top: HighlightIntroCellUX.margin, left: 0, bottom: 0, right: 0)
titleLabel.snp.makeConstraints { make in
make.leading.top.equalTo(self.contentView).inset(titleInsets)
make.trailing.equalTo(mainImageView.snp.leading)
Expand Down

0 comments on commit a93cb54

Please sign in to comment.