UINavigationBar 's background color change can be achieved by UINavigationBarAppearance
let appearance = UINavigationBarAppearance()
appearance.configureWithOpaqueBackground()
appearance.backgroundColor = .black
navigationController?.navigationBar.standardAppearance = appearance
navigationController?.navigationBar.scrollEdgeAppearance = appearance
For the UIBarButtonItem , Liquid glass automatically chooses the tint color depending upon the background of the navigation example:
Additionally, if you set the value of style property of UIBarButtonItem to UIBarButtonItem.Style.prominent it would change the liquid glass background color like this:
nb1.style = .prominent
nb2.style = .prominent
nb3.style = .prominent
nb4.style = .prominent