[英]Issue with NavigationBarTitle when scrolling List with TextFields inside of it
在尝试创建可重现的示例时,我能够解决自己的问题。
该错误是我将背景颜色应用于包含List
的父Group
的结果。 删除背景颜色解决了我的问题!
struct ChecklistView: View {
var body: some View {
Group {
if empty {
EmptyView()
} else {
ListView()
}
}
.background(Color(.tertiarySystemBackground).edgesIgnoringSafeArea(.all)) // removing this line fixed my issue
.navigationBarTitle("My title")
}
}
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.