Some layout changes to the profile view
This commit is contained in:
@@ -93,9 +93,11 @@ struct EventView: View {
|
||||
}
|
||||
.buttonStyle(PlainButtonStyle())
|
||||
TextEvent(inner_ev, pubkey: inner_ev.pubkey)
|
||||
.padding([.top], 2)
|
||||
}
|
||||
} else {
|
||||
TextEvent(event, pubkey: pubkey)
|
||||
.padding([.top], 6)
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -146,7 +148,7 @@ struct EventView: View {
|
||||
.background(event_validity_color(event.validity))
|
||||
.id(event.id)
|
||||
.frame(maxWidth: .infinity, minHeight: PFP_SIZE)
|
||||
.padding([.bottom], 4)
|
||||
.padding([.bottom], 2)
|
||||
.event_context_menu(event, privkey: damus.keypair.privkey)
|
||||
}
|
||||
}
|
||||
|
||||
@@ -55,7 +55,7 @@ struct ProfileNameView: View {
|
||||
if let real_name = profile?.display_name {
|
||||
VStack(alignment: .leading) {
|
||||
Text(real_name)
|
||||
.font(.title)
|
||||
.font(.title3.weight(.bold))
|
||||
ProfileName(pubkey: pubkey, profile: profile, prefix: "@", contacts: contacts, show_friend_confirmed: true)
|
||||
.font(.callout)
|
||||
.foregroundColor(.gray)
|
||||
@@ -103,8 +103,6 @@ struct ProfileView: View {
|
||||
|
||||
HStack(alignment: .center) {
|
||||
ProfilePicView(pubkey: profile.pubkey, size: PFP_SIZE, highlight: .custom(Color.black, 2), profiles: damus_state.profiles)
|
||||
|
||||
ProfileNameView(pubkey: profile.pubkey, profile: data, contacts: damus_state.contacts)
|
||||
|
||||
Spacer()
|
||||
|
||||
@@ -119,6 +117,9 @@ struct ProfileView: View {
|
||||
FollowButtonView(target: profile.get_follow_target(), follow_state: damus_state.contacts.follow_state(profile.pubkey))
|
||||
}
|
||||
|
||||
ProfileNameView(pubkey: profile.pubkey, profile: data, contacts: damus_state.contacts)
|
||||
.padding(.bottom)
|
||||
|
||||
KeyView(pubkey: profile.pubkey)
|
||||
.padding(.bottom, 10)
|
||||
.pubkey_context_menu(bech32_pubkey: bech32_pubkey(profile.pubkey) ?? profile.pubkey)
|
||||
@@ -158,6 +159,7 @@ struct ProfileView: View {
|
||||
VStack(alignment: .leading) {
|
||||
ScrollView {
|
||||
TopSection
|
||||
.padding(.horizontal)
|
||||
|
||||
Divider()
|
||||
|
||||
@@ -165,7 +167,6 @@ struct ProfileView: View {
|
||||
}
|
||||
.frame(maxHeight: .infinity, alignment: .topLeading)
|
||||
}
|
||||
.padding([.leading, .trailing], 6)
|
||||
.frame(maxWidth: .infinity, alignment: .topLeading)
|
||||
.navigationBarTitle("Profile")
|
||||
.onReceive(handle_notify(.switched_timeline)) { _ in
|
||||
|
||||
Reference in New Issue
Block a user