diff --git a/ElementX/Resources/Localizations/en.lproj/Localizable.strings b/ElementX/Resources/Localizations/en.lproj/Localizable.strings index bb731f67e..b522cc88c 100644 --- a/ElementX/Resources/Localizations/en.lproj/Localizable.strings +++ b/ElementX/Resources/Localizations/en.lproj/Localizable.strings @@ -2,6 +2,8 @@ "a11y_hide_password" = "Hide password"; "a11y_notifications_mentions_only" = "Mentions only"; "a11y_notifications_muted" = "Muted"; +"a11y_poll" = "Poll"; +"a11y_poll_end" = "Ended poll"; "a11y_send_files" = "Send files"; "a11y_show_password" = "Show password"; "a11y_user_menu" = "User menu"; @@ -274,6 +276,7 @@ "screen_edit_profile_display_name_placeholder" = "Your display name"; "screen_edit_profile_error" = "An unknown error was encountered and the information couldn't be changed."; "screen_edit_profile_error_title" = "Unable to update profile"; +"screen_edit_profile_title" = "Edit profile"; "screen_edit_profile_updating_details" = "Updating profile…"; "screen_invites_decline_chat_message" = "Are you sure you want to decline the invitation to join %1$@?"; "screen_invites_decline_chat_title" = "Decline invite"; diff --git a/ElementX/Sources/Generated/Strings.swift b/ElementX/Sources/Generated/Strings.swift index 23943892d..37fd3987c 100644 --- a/ElementX/Sources/Generated/Strings.swift +++ b/ElementX/Sources/Generated/Strings.swift @@ -16,6 +16,10 @@ public enum L10n { public static var a11yNotificationsMentionsOnly: String { return L10n.tr("Localizable", "a11y_notifications_mentions_only") } /// Muted public static var a11yNotificationsMuted: String { return L10n.tr("Localizable", "a11y_notifications_muted") } + /// Poll + public static var a11yPoll: String { return L10n.tr("Localizable", "a11y_poll") } + /// Ended poll + public static var a11yPollEnd: String { return L10n.tr("Localizable", "a11y_poll_end") } /// Send files public static var a11ySendFiles: String { return L10n.tr("Localizable", "a11y_send_files") } /// Show password @@ -692,6 +696,8 @@ public enum L10n { public static var screenEditProfileError: String { return L10n.tr("Localizable", "screen_edit_profile_error") } /// Unable to update profile public static var screenEditProfileErrorTitle: String { return L10n.tr("Localizable", "screen_edit_profile_error_title") } + /// Edit profile + public static var screenEditProfileTitle: String { return L10n.tr("Localizable", "screen_edit_profile_title") } /// Updating profile… public static var screenEditProfileUpdatingDetails: String { return L10n.tr("Localizable", "screen_edit_profile_updating_details") } /// Are you sure you want to decline the invitation to join %1$@? diff --git a/ElementX/Sources/Other/AvatarSize.swift b/ElementX/Sources/Other/AvatarSize.swift index faeaff276..100a05c4e 100644 --- a/ElementX/Sources/Other/AvatarSize.swift +++ b/ElementX/Sources/Other/AvatarSize.swift @@ -50,6 +50,7 @@ enum UserAvatarSizeOnScreen { case memberDetails case inviteUsers case readReceipt + case editUserDetails var value: CGFloat { switch self { @@ -60,7 +61,7 @@ enum UserAvatarSizeOnScreen { case .home: return 32 case .settings: - return 60 + return 52 case .roomDetails: return 44 case .startChat: @@ -69,6 +70,8 @@ enum UserAvatarSizeOnScreen { return 70 case .inviteUsers: return 56 + case .editUserDetails: + return 96 } } } diff --git a/ElementX/Sources/Screens/Settings/UserDetailsEditScreen/View/UserDetailsEditScreen.swift b/ElementX/Sources/Screens/Settings/UserDetailsEditScreen/View/UserDetailsEditScreen.swift index 3810c5daa..5754dee90 100644 --- a/ElementX/Sources/Screens/Settings/UserDetailsEditScreen/View/UserDetailsEditScreen.swift +++ b/ElementX/Sources/Screens/Settings/UserDetailsEditScreen/View/UserDetailsEditScreen.swift @@ -23,11 +23,21 @@ struct UserDetailsEditScreen: View { var body: some View { Form { - avatar + Section { + avatar + } footer: { + Text(context.viewState.userID) + .frame(maxWidth: .infinity) + .font(.compound.bodyLG) + .foregroundColor(.compound.textPrimary) + .padding(.bottom, 16) + } + nameSection } .compoundList() .scrollDismissesKeyboard(.immediately) + .navigationTitle(L10n.screenEditProfileTitle) .navigationBarTitleDisplayMode(.inline) .toolbar { toolbar } } @@ -53,7 +63,7 @@ struct UserDetailsEditScreen: View { url: context.viewState.selectedAvatarURL, name: context.viewState.currentDisplayName, contentID: context.viewState.userID, - avatarSize: .user(on: .memberDetails), + avatarSize: .user(on: .editUserDetails), imageProvider: context.imageProvider) .overlay(alignment: .bottomTrailing) { avatarOverlayIcon