Update colors for UserView (IOPS-140)

This commit is contained in:
Marcus Kida 2023-05-04 11:56:34 +02:00
parent d1d9e86244
commit 313d5e2d8a
No known key found for this signature in database
GPG Key ID: 19FF64E08013CA40
4 changed files with 61 additions and 4 deletions

View File

@ -5,9 +5,27 @@
"color-space" : "srgb",
"components" : {
"alpha" : "0.150",
"blue" : "0.988",
"green" : "0.173",
"red" : "0.337"
"blue" : "0xFB",
"green" : "0x2C",
"red" : "0x55"
}
},
"idiom" : "universal"
},
{
"appearances" : [
{
"appearance" : "luminosity",
"value" : "dark"
}
],
"color" : {
"color-space" : "srgb",
"components" : {
"alpha" : "0.300",
"blue" : "0xFF",
"green" : "0x64",
"red" : "0x63"
}
},
"idiom" : "universal"

View File

@ -0,0 +1,38 @@
{
"colors" : [
{
"color" : {
"color-space" : "srgb",
"components" : {
"alpha" : "1.000",
"blue" : "0.800",
"green" : "0.227",
"red" : "0.337"
}
},
"idiom" : "universal"
},
{
"appearances" : [
{
"appearance" : "luminosity",
"value" : "dark"
}
],
"color" : {
"color-space" : "srgb",
"components" : {
"alpha" : "1.000",
"blue" : "0xFF",
"green" : "0x64",
"red" : "0x63"
}
},
"idiom" : "universal"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}

View File

@ -60,6 +60,7 @@ public enum Asset {
public static let userBlocked = ColorAsset(name: "Colors/Button/userBlocked")
public static let userFollow = ColorAsset(name: "Colors/Button/userFollow")
public static let userFollowing = ColorAsset(name: "Colors/Button/userFollowing")
public static let userFollowingTitle = ColorAsset(name: "Colors/Button/userFollowingTitle")
}
public enum Icon {
public static let plus = ColorAsset(name: "Colors/Icon/plus")

View File

@ -275,7 +275,7 @@ public extension UserView {
case .unfollow:
followButton.setTitle(L10n.Common.Controls.Friendship.following, for: .normal)
followButton.setBackgroundColor(Asset.Colors.Button.userFollowing.color, for: .normal)
followButton.setTitleColor(Asset.Colors.Button.userFollow.color, for: .normal)
followButton.setTitleColor(Asset.Colors.Button.userFollowingTitle.color, for: .normal)
case .blocked:
followButton.setTitle(L10n.Common.Controls.Friendship.blocked, for: .normal)
followButton.setBackgroundColor(Asset.Colors.Button.userBlocked.color, for: .normal)