I am using SwiftUI to create screen, I am adding few TextFields on ScrollView in body and the problem is when I tap last TextField and keyboard appear, it cover textField that I am editing, so my question is: Is there any way in SwiftUI to update ScrollView inset when keyboard appear?
I've tried to use List but that didn't work
Some code example:
var body: some View {
ScrollView {
Text("SomeParameter1")
TextField("", text: $text)
.textFieldStyle(RoundedBorderTextFieldStyle())
Text("SomeParameter2")
TextField("", text: $text)
.textFieldStyle(RoundedBorderTextFieldStyle())
Text("SomeParameter3")
TextField("", text: $text)
.textFieldStyle(RoundedBorderTextFieldStyle())
Text("SomeParameter4")
TextField("", text: $text)
.textFieldStyle(RoundedBorderTextFieldStyle())
}
}