Skip to content

Commit d45493f

Browse files
authored
Merge pull request #18440 from wordpress-mobile/feature/18176-background_colors
Feature Introduction: fix colors
2 parents ec68c1f + fd5b79a commit d45493f

3 files changed

Lines changed: 11 additions & 7 deletions

File tree

WordPress/Classes/ViewRelated/Feature Introduction/Blogging Prompts/BloggingPromptsFeatureDescriptionView.swift

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -30,10 +30,7 @@ private extension BloggingPromptsFeatureDescriptionView {
3030
promptCard.configureForExampleDisplay()
3131
promptCard.translatesAutoresizingMaskIntoConstraints = false
3232

33-
promptCard.layer.borderWidth = Style.borderWidth
3433
promptCard.layer.cornerRadius = Style.cardCornerRadius
35-
promptCard.layer.borderColor = Style.cardBorderColor
36-
3734
promptCard.layer.shadowOffset = Style.cardShadowOffset
3835
promptCard.layer.shadowOpacity = Style.cardShadowOpacity
3936
promptCard.layer.shadowRadius = Style.cardShadowRadius
@@ -49,7 +46,7 @@ private extension BloggingPromptsFeatureDescriptionView {
4946
}
5047

5148
func configureNote() {
52-
noteTextView.layer.borderWidth = Style.borderWidth
49+
noteTextView.layer.borderWidth = Style.noteBorderWidth
5350
noteTextView.layer.cornerRadius = Style.noteCornerRadius
5451
noteTextView.layer.borderColor = Style.noteBorderColor
5552
noteTextView.textContainerInset = Style.noteInsets
@@ -84,12 +81,11 @@ private extension BloggingPromptsFeatureDescriptionView {
8481
static let textColor: UIColor = .textSubtle
8582
static let noteInsets = UIEdgeInsets(top: 12, left: 12, bottom: 12, right: 12)
8683
static let noteCornerRadius: CGFloat = 6
84+
static let noteBorderWidth: CGFloat = 1
85+
static let noteBorderColor = UIColor.textQuaternary.cgColor
8786
static let cardCornerRadius: CGFloat = 10
8887
static let cardShadowRadius: CGFloat = 14
8988
static let cardShadowOpacity: Float = 0.1
9089
static let cardShadowOffset = CGSize(width: 0, height: 10.0)
91-
static let cardBorderColor = UIColor(red: 0.882, green: 0.886, blue: 0.886, alpha: 1).cgColor
92-
static let borderWidth: CGFloat = 1
93-
static let noteBorderColor = UIColor.textQuaternary.cgColor
9490
}
9591
}

WordPress/Classes/ViewRelated/Feature Introduction/FeatureIntroductionViewController.swift

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -85,6 +85,7 @@ private extension FeatureIntroductionViewController {
8585
func configureView() {
8686
navigationItem.rightBarButtonItem = CollapsableHeaderViewController.closeButton(target: self, action: #selector(closeButtonTapped))
8787
scrollView.addSubview(contentView)
88+
hideHeaderVisualEffects()
8889

8990
NSLayoutConstraint.activate([
9091
contentView.topAnchor.constraint(equalTo: scrollView.topAnchor),

WordPress/Classes/ViewRelated/Gutenberg/Collapsable Header/CollapsableHeaderViewController.swift

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -515,6 +515,13 @@ class CollapsableHeaderViewController: UIViewController, NoResultsViewHost {
515515
selectedStateButtonsContainer.insertArrangedSubview(primaryActionButton, at: 0)
516516
}
517517

518+
/// A public interface to hide the header blur.
519+
func hideHeaderVisualEffects() {
520+
visualEffects.forEach { (visualEffect) in
521+
visualEffect.isHidden = true
522+
}
523+
}
524+
518525
/// In scenarios where the content offset before content changes doesn't align with the available space after the content changes then the offset can be lost. In
519526
/// order to preserve the header's collpased state we cache the offset and attempt to reapply it if needed.
520527
private var stashedOffset: CGPoint? = nil

0 commit comments

Comments
 (0)