1

I have a navigation bar embedded Search Controller. When Search Controller is dismissed, navigation back bar button item is reverting to default color(blue) only in iOS13.

Is there any way to fix this problem?

Here: Gif

4

1 回答 1

0

我也遇到了这个问题。

我放置了一个自定义按钮而不是系统后退按钮。它对我有用。

您应该在推送到 viewController 之前放置它。如果你有两个或更多的 viewController,你应该把它放在最前面。

    let backItem = UIBarButtonItem()
    backItem.title = "Back" 
    backItem.tintColor = .red
    navigationItem.backBarButtonItem = backItem
于 2019-10-31T14:16:21.007 回答