fix an issue when input showing error message the layout would change

pull/891/head
ryanzhao 2 years ago
parent f6bf61f1b3
commit f5e086dee1

@ -56,11 +56,17 @@ public struct SessionTextField: View {
.stroke(themeColor: (error?.isEmpty == false) ? .danger : .borderSeparator)
)
Text(error ?? " ")
.bold()
.font(.system(size: Values.mediumFontSize))
.foregroundColor(themeColor: .danger)
.multilineTextAlignment(.center)
ZStack {
Text(error ?? "")
.bold()
.font(.system(size: Values.mediumFontSize))
.foregroundColor(themeColor: .danger)
.multilineTextAlignment(.center)
}
.frame(
height: 50,
alignment: .top
)
}
}
}

Loading…
Cancel
Save