When I add a UISearchController to a UINavigationItem from an UINavigationController; it becomes white when the view loads and changes to the color specified when the user c
I'm experiencing same issue, and already opened a radar to Apple. Even though, if you set the backgroundColor to the appearance of the UINavigationBar, then the navigation bar instead of becoming transparent when pulling down and showing the search bar becomes that color, but then the status bar still remains white.
UINavigationBar.appearance().tintColor = .white
UINavigationBar.appearance().barTintColor = .blue
UINavigationBar.appearance().titleTextAttributes = [NSAttributedString.Key.foregroundColor : UIColor.white]
UINavigationBar.appearance().backgroundColor = .red
Here is some code that tries to mitigate that behaviour, but I'm open to hear for the status bar thing