fix: set barButtonItem and tabBarItem tint color to brand blue

This commit is contained in:
CMK 2021-06-17 14:30:24 +08:00
parent cd31d79357
commit 41fa6f2b3e
4 changed files with 9 additions and 6 deletions

View File

@ -24,7 +24,7 @@ class HashtagTimelineViewController: UIViewController, NeedsDependency, MediaPre
let composeBarButtonItem: UIBarButtonItem = {
let barButtonItem = UIBarButtonItem()
barButtonItem.tintColor = Asset.Colors.Label.highlight.color
barButtonItem.tintColor = Asset.Colors.brandBlue.color
barButtonItem.image = UIImage(systemName: "square.and.pencil")?.withRenderingMode(.alwaysTemplate)
return barButtonItem
}()

View File

@ -38,14 +38,14 @@ final class HomeTimelineViewController: UIViewController, NeedsDependency, Media
let settingBarButtonItem: UIBarButtonItem = {
let barButtonItem = UIBarButtonItem()
barButtonItem.tintColor = Asset.Colors.Label.highlight.color
barButtonItem.tintColor = Asset.Colors.brandBlue.color
barButtonItem.image = UIImage(systemName: "gear")?.withRenderingMode(.alwaysTemplate)
return barButtonItem
}()
let composeBarButtonItem: UIBarButtonItem = {
let barButtonItem = UIBarButtonItem()
barButtonItem.tintColor = Asset.Colors.Label.highlight.color
barButtonItem.tintColor = Asset.Colors.brandBlue.color
barButtonItem.image = UIImage(systemName: "square.and.pencil")?.withRenderingMode(.alwaysTemplate)
return barButtonItem
}()

View File

@ -106,9 +106,11 @@ extension MainTabBarController {
selectedIndex = 0
// TODO: custom accent color
// let tabBarAppearance = UITabBarAppearance()
// tabBarAppearance.configureWithDefaultBackground()
// tabBar.standardAppearance = tabBarAppearance
let tabBarAppearance = UITabBarAppearance()
tabBarAppearance.configureWithDefaultBackground()
tabBarAppearance.selectionIndicatorTintColor = Asset.Colors.brandBlue.color
tabBar.standardAppearance = tabBarAppearance
context.apiService.error
.receive(on: DispatchQueue.main)

View File

@ -23,6 +23,7 @@ class AppDelegate: UIResponder, UIApplicationDelegate {
UserDefaults.standard.setValue(UIApplication.appVersion(), forKey: "Mastodon.appVersion")
UserDefaults.standard.setValue(UIApplication.appBuild(), forKey: "Mastodon.appBundle")
// Setup notification
UNUserNotificationCenter.current().delegate = self
application.registerForRemoteNotifications()