fix: update welcome sign-up button appearance and override welcome scene to light style
This commit is contained in:
parent
6481565701
commit
be976c2795
|
@ -91,6 +91,7 @@ internal enum Asset {
|
||||||
}
|
}
|
||||||
internal static let battleshipGrey = ColorAsset(name: "Colors/battleshipGrey")
|
internal static let battleshipGrey = ColorAsset(name: "Colors/battleshipGrey")
|
||||||
internal static let brandBlue = ColorAsset(name: "Colors/brand.blue")
|
internal static let brandBlue = ColorAsset(name: "Colors/brand.blue")
|
||||||
|
internal static let brandBlueDarken20 = ColorAsset(name: "Colors/brand.blue.darken.20")
|
||||||
internal static let danger = ColorAsset(name: "Colors/danger")
|
internal static let danger = ColorAsset(name: "Colors/danger")
|
||||||
internal static let disabled = ColorAsset(name: "Colors/disabled")
|
internal static let disabled = ColorAsset(name: "Colors/disabled")
|
||||||
internal static let inactive = ColorAsset(name: "Colors/inactive")
|
internal static let inactive = ColorAsset(name: "Colors/inactive")
|
||||||
|
|
|
@ -0,0 +1,38 @@
|
||||||
|
{
|
||||||
|
"colors" : [
|
||||||
|
{
|
||||||
|
"color" : {
|
||||||
|
"color-space" : "srgb",
|
||||||
|
"components" : {
|
||||||
|
"alpha" : "1.000",
|
||||||
|
"blue" : "0xB0",
|
||||||
|
"green" : "0x73",
|
||||||
|
"red" : "0x1F"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"idiom" : "universal"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"appearances" : [
|
||||||
|
{
|
||||||
|
"appearance" : "luminosity",
|
||||||
|
"value" : "dark"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"color" : {
|
||||||
|
"color-space" : "srgb",
|
||||||
|
"components" : {
|
||||||
|
"alpha" : "1.000",
|
||||||
|
"blue" : "0xC9",
|
||||||
|
"green" : "0x80",
|
||||||
|
"red" : "0x1B"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"idiom" : "universal"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"info" : {
|
||||||
|
"author" : "xcode",
|
||||||
|
"version" : 1
|
||||||
|
}
|
||||||
|
}
|
|
@ -37,9 +37,10 @@ final class WelcomeViewController: UIViewController, NeedsDependency {
|
||||||
private(set) lazy var signUpButton: PrimaryActionButton = {
|
private(set) lazy var signUpButton: PrimaryActionButton = {
|
||||||
let button = PrimaryActionButton()
|
let button = PrimaryActionButton()
|
||||||
button.setTitle(L10n.Common.Controls.Actions.signUp, for: .normal)
|
button.setTitle(L10n.Common.Controls.Actions.signUp, for: .normal)
|
||||||
let backgroundImageColor: UIColor = traitCollection.userInterfaceIdiom == .phone ? .white : Asset.Colors.Button.normal.color
|
let backgroundImageColor: UIColor = traitCollection.userInterfaceIdiom == .phone ? .white : Asset.Colors.brandBlue.color
|
||||||
|
let backgroundImageHighlightedColor: UIColor = traitCollection.userInterfaceIdiom == .phone ? UIColor(white: 0.8, alpha: 1.0) : Asset.Colors.brandBlueDarken20.color
|
||||||
button.setBackgroundImage(.placeholder(color: backgroundImageColor), for: .normal)
|
button.setBackgroundImage(.placeholder(color: backgroundImageColor), for: .normal)
|
||||||
button.setBackgroundImage(.placeholder(color: backgroundImageColor.withAlphaComponent(0.9)), for: .highlighted)
|
button.setBackgroundImage(.placeholder(color: backgroundImageHighlightedColor), for: .highlighted)
|
||||||
let titleColor: UIColor = traitCollection.userInterfaceIdiom == .phone ? Asset.Colors.Button.normal.color : UIColor.white
|
let titleColor: UIColor = traitCollection.userInterfaceIdiom == .phone ? Asset.Colors.Button.normal.color : UIColor.white
|
||||||
button.setTitleColor(titleColor, for: .normal)
|
button.setTitleColor(titleColor, for: .normal)
|
||||||
button.translatesAutoresizingMaskIntoConstraints = false
|
button.translatesAutoresizingMaskIntoConstraints = false
|
||||||
|
@ -67,6 +68,8 @@ extension WelcomeViewController {
|
||||||
override func viewDidLoad() {
|
override func viewDidLoad() {
|
||||||
super.viewDidLoad()
|
super.viewDidLoad()
|
||||||
|
|
||||||
|
view.overrideUserInterfaceStyle = .light
|
||||||
|
|
||||||
setupOnboardingAppearance()
|
setupOnboardingAppearance()
|
||||||
setupIllustrationLayout()
|
setupIllustrationLayout()
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue