add profile to toolbar
This commit is contained in:
@@ -74,21 +74,6 @@ struct ContentView: View {
|
|||||||
|
|
||||||
let sub_id = UUID().description
|
let sub_id = UUID().description
|
||||||
|
|
||||||
var LoadingContainer: some View {
|
|
||||||
HStack(alignment: .center) {
|
|
||||||
if home.signal.signal != home.signal.max_signal {
|
|
||||||
Text("\(home.signal.signal)/\(home.signal.max_signal)")
|
|
||||||
.font(.callout)
|
|
||||||
.foregroundColor(.gray)
|
|
||||||
}
|
|
||||||
|
|
||||||
NavigationLink(destination: ConfigView(state: damus_state!)) {
|
|
||||||
Label("", systemImage: "gear")
|
|
||||||
}
|
|
||||||
.buttonStyle(PlainButtonStyle())
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
var PostingTimelineView: some View {
|
var PostingTimelineView: some View {
|
||||||
VStack{
|
VStack{
|
||||||
FiltersView
|
FiltersView
|
||||||
@@ -196,7 +181,31 @@ struct ContentView: View {
|
|||||||
NavigationView {
|
NavigationView {
|
||||||
MainContent(damus: damus)
|
MainContent(damus: damus)
|
||||||
.toolbar {
|
.toolbar {
|
||||||
LoadingContainer
|
ToolbarItem(placement: .navigationBarLeading) {
|
||||||
|
let profile_model = ProfileModel(pubkey: damus_state!.pubkey, damus: damus_state!)
|
||||||
|
let followers_model = FollowersModel(damus_state: damus_state!, target: damus_state!.pubkey)
|
||||||
|
let prof_dest = ProfileView(damus_state: damus_state!, profile: profile_model, followers: followers_model)
|
||||||
|
|
||||||
|
NavigationLink(destination: prof_dest) {
|
||||||
|
ProfilePicView(pubkey: damus_state!.pubkey, size: 32, highlight: .none, profiles: damus_state!.profiles)
|
||||||
|
}
|
||||||
|
.buttonStyle(PlainButtonStyle())
|
||||||
|
}
|
||||||
|
|
||||||
|
ToolbarItem(placement: .navigationBarTrailing) {
|
||||||
|
HStack(alignment: .center) {
|
||||||
|
if home.signal.signal != home.signal.max_signal {
|
||||||
|
Text("\(home.signal.signal)/\(home.signal.max_signal)")
|
||||||
|
.font(.callout)
|
||||||
|
.foregroundColor(.gray)
|
||||||
|
}
|
||||||
|
|
||||||
|
NavigationLink(destination: ConfigView(state: damus_state!)) {
|
||||||
|
Label("", systemImage: "gear")
|
||||||
|
}
|
||||||
|
.buttonStyle(PlainButtonStyle())
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
.navigationViewStyle(.stack)
|
.navigationViewStyle(.stack)
|
||||||
|
|||||||
Reference in New Issue
Block a user