mirror of
https://gitlab.opencode.de/bwi/bundesmessenger/clients/bundesmessenger-ios.git
synced 2026-04-17 23:18:27 +02:00
MESSENGER-5706 merge from #5660 and refactoring
This commit is contained in:
@@ -37,6 +37,7 @@ struct DeveloperSettingsView: View {
|
||||
@State private var showAlertBirthdayCampaign = false
|
||||
@State private var permalinkPrefix: String? = UserDefaults.standard.string(forKey: "bwi_permalink_prefix")
|
||||
@State private var showIntroduceFederation = false
|
||||
@State private var showAnnouncementFederation = false
|
||||
|
||||
var body: some View {
|
||||
Form {
|
||||
@@ -83,6 +84,23 @@ struct DeveloperSettingsView: View {
|
||||
}
|
||||
}
|
||||
SwiftUI.Section(header: Text(BWIL10n.bwiSettingsDeveloperIntroduceFederation)) {
|
||||
Button(action: { showAnnouncementFederation = true }) {
|
||||
Text(BWIL10n.bwiSettingsDeveloperAnnouncementFederationPreview)
|
||||
.foregroundColor(Color(themeService.theme.tintColor))
|
||||
.font(.system(size: 17))
|
||||
}
|
||||
.sheet(isPresented: $showAnnouncementFederation) {
|
||||
IntroduceFederationView()
|
||||
.interactiveDismissDisabled()
|
||||
.environmentObject(BWIThemeService.shared)
|
||||
}
|
||||
if let session = session {
|
||||
Button(action: { BWIAccountNotificationService(mxSession: session).setShowFederationAnnouncementFlag(true) }) {
|
||||
Text(BWIL10n.bwiSettingsDeveloperAnnouncementFederationReset)
|
||||
.foregroundColor(Color(themeService.theme.tintColor))
|
||||
.font(.system(size: 17))
|
||||
}
|
||||
}
|
||||
Button(action: { showIntroduceFederation = true }) {
|
||||
Text(BWIL10n.bwiSettingsDeveloperIntroduceFederationPreview)
|
||||
.foregroundColor(Color(themeService.theme.tintColor))
|
||||
|
||||
Reference in New Issue
Block a user