fix: iOS 15 new tab bar appearance not override issue

This commit is contained in:
CMK 2021-10-11 12:35:20 +08:00
parent 051a8f40e3
commit e5a3c4ae0d
1 changed files with 5 additions and 0 deletions

View File

@ -48,6 +48,11 @@ extension ThemeService {
tabBarAppearance.backgroundColor = theme.tabBarBackgroundColor
tabBarAppearance.selectionIndicatorTintColor = Asset.Colors.brandBlue.color
UITabBar.appearance().standardAppearance = tabBarAppearance
if #available(iOS 15.0, *) {
UITabBar.appearance().scrollEdgeAppearance = tabBarAppearance
} else {
// Fallback on earlier versions
}
UITabBar.appearance().barTintColor = theme.tabBarBackgroundColor
// set table view cell appearance