Fix profile view toolbar alignment bug in iOS 18

Changelog-Fixed: Fix profile view toolbar alignment bug in iOS 18
This commit is contained in:
2024-07-28 22:48:05 -04:00
committed by Daniel D’Aquino
parent a9bb2ef98b
commit f0b5162205

View File

@@ -217,16 +217,6 @@ struct ProfileView: View {
}
}
var customNavbar: some View {
HStack {
navBackButton
Spacer()
navActionSheetButton
}
.padding(.top, 5)
.accentColor(DamusColors.white)
}
func lnButton(unownedProfile: Profile?, record: ProfileRecord?) -> some View {
return ProfileZapLinkView(unownedProfileRecord: record, profileModel: self.profile) { reactions_enabled, lud16, lnurl in
Image(reactions_enabled ? "zap.fill" : "zap")
@@ -458,8 +448,15 @@ struct ProfileView: View {
.navigationTitle("")
.navigationBarBackButtonHidden()
.toolbar {
ToolbarItem(placement: .principal) {
customNavbar
ToolbarItem(placement: .topBarLeading) {
navBackButton
.padding(.top, 5)
.accentColor(DamusColors.white)
}
ToolbarItem(placement: .topBarTrailing) {
navActionSheetButton
.padding(.top, 5)
.accentColor(DamusColors.white)
}
}
.toolbarBackground(.hidden)