Contact me added in Bug Report Screen (#1307)

* contact me added

* fixing tests
This commit is contained in:
Mauro
2023-07-12 10:20:51 +02:00
committed by GitHub
parent 98e7489aaf
commit c573892954
26 changed files with 59 additions and 38 deletions
@@ -26,10 +26,9 @@ struct BugReportScreen: View {
var body: some View {
Form {
textFieldSection
attachScreenshotSection
sendLogsSection
canContactSection
}
.scrollDismissesKeyboard(.immediately)
.compoundForm()
@@ -77,6 +76,18 @@ struct BugReportScreen: View {
.compoundFormSection()
}
private var canContactSection: some View {
Section {
Toggle(L10n.screenBugReportContactMeTitle, isOn: $context.canContact)
.toggleStyle(.compoundForm)
.accessibilityIdentifier(A11yIdentifiers.bugReportScreen.canContact)
} footer: {
Text(L10n.screenBugReportContactMe)
.compoundFormSectionFooter()
}
.compoundFormSection()
}
@ViewBuilder
private var attachScreenshotSection: some View {
Section {