Poll options can be multiline during creation (#2274)

This commit is contained in:
Mauro
2023-12-20 14:22:57 +01:00
committed by GitHub
parent 756b96f7ff
commit e8da21e340
4 changed files with 8 additions and 8 deletions
@@ -94,6 +94,8 @@ struct PollFormScreen: View {
.accessibilityIdentifier(A11yIdentifiers.pollFormScreen.addOption)
}
}
// Disables animations when the text view resizes for multiline
.animation(.noAnimation, value: UUID())
}
private var showResultsSection: some View {
@@ -166,13 +168,10 @@ private struct PollFormOptionRow: View {
.accessibilityLabel(L10n.actionRemove)
}
TextField(text: $text) {
TextField(text: $text, axis: .vertical) {
Text(placeholder)
.compoundTextFieldPlaceholder()
}
.introspect(.textField, on: .supportedVersions) { textField in
textField.clearButtonMode = .whileEditing
}
.tint(.compound.iconAccentTertiary)
.alignmentGuide(.listRowSeparatorLeading) { _ in 0 }
}