Skip to content

Commit eb54078

Browse files
author
Giorgio Ruscigno
committed
Update JetpackPrologueStyleGuide, add feature flagged colors for the new Jetpack prologue screen
1 parent a7a8963 commit eb54078

File tree

1 file changed

+13
-7
lines changed

1 file changed

+13
-7
lines changed

WordPress/Jetpack/Classes/NUX/JetpackPrologueStyleGuide.swift

Lines changed: 13 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,9 @@ import WordPressAuthenticator
55
/// The colors in here intentionally do not support light or dark modes since they're the same on both.
66
///
77
struct JetpackPrologueStyleGuide {
8-
static let backgroundColor = UIColor(red: 0.00, green: 0.11, blue: 0.18, alpha: 1.00)
8+
static let backgroundColor = FeatureFlag.newLandingScreen.enabled ?
9+
UIColor(light: .muriel(color: .jetpackGreen, .shade5), dark: .muriel(color: .jetpackGreen, .shade100)):
10+
UIColor(red: 0.00, green: 0.11, blue: 0.18, alpha: 1.00)
911

1012
struct Title {
1113
static let font: UIFont = WPStyleGuide.fontForTextStyle(.title3, fontWeight: .semibold)
@@ -24,22 +26,26 @@ struct JetpackPrologueStyleGuide {
2426

2527
static let continueButtonStyle = NUXButtonStyle(normal: .init(backgroundColor: .white,
2628
borderColor: .white,
27-
titleColor: Self.backgroundColor),
29+
titleColor: FeatureFlag.newLandingScreen.enabled ? .black: Self.backgroundColor),
2830

2931
highlighted: .init(backgroundColor: UIColor(red: 1.00, green: 1.00, blue: 1.00, alpha: 0.90),
3032
borderColor: UIColor(red: 1.00, green: 1.00, blue: 1.00, alpha: 0.90),
31-
titleColor: Self.backgroundColor),
33+
titleColor: FeatureFlag.newLandingScreen.enabled ? .black: Self.backgroundColor),
3234

3335
disabled: .init(backgroundColor: .white,
3436
borderColor: .white,
3537
titleColor: Self.backgroundColor))
3638

37-
static let siteAddressButtonStyle = NUXButtonStyle(normal: .init(backgroundColor: Self.backgroundColor,
38-
borderColor: UIColor(red: 1.00, green: 1.00, blue: 1.00, alpha: 0.40),
39+
static let siteAddressButtonStyle = NUXButtonStyle(normal: .init(backgroundColor: FeatureFlag.newLandingScreen.enabled ?
40+
UIColor.muriel(color: .jetpackGreen, .shade50) :
41+
Self.backgroundColor,
42+
borderColor: FeatureFlag.newLandingScreen.enabled ? .clear : UIColor(red: 1.00, green: 1.00, blue: 1.00, alpha: 0.40),
3943
titleColor: .white),
4044

41-
highlighted: .init(backgroundColor: Self.backgroundColor,
42-
borderColor: UIColor(red: 1.00, green: 1.00, blue: 1.00, alpha: 0.20),
45+
highlighted: .init(backgroundColor: FeatureFlag.newLandingScreen.enabled ?
46+
UIColor.muriel(color: .jetpackGreen, .shade90) :
47+
Self.backgroundColor,
48+
borderColor: FeatureFlag.newLandingScreen.enabled ? .clear : UIColor(red: 1.00, green: 1.00, blue: 1.00, alpha: 0.20),
4349
titleColor: UIColor.white.withAlphaComponent(0.7)),
4450

4551
disabled: .init(backgroundColor: .white,

0 commit comments

Comments
 (0)