02.Navigation
LargeTitle
默认情况下,在SwiftUI
中创建的Navigation
都是开启LargeTitle样式的。 如果不想使用改样式可以用过下面的方式调整:
var body: some View {
Form {
Section {
Text("Hello World 1")
Text("Hello World 2")
Text("Hello World 3")
Text("Hello World 4")
Text("Hello World 5")
}
}
.navigationBarTitle("Add pose", displayMode: .large)
}
隐藏导航栏
.navigationBarHidden(true)
Last updated
Was this helpful?