mute: updating UI to support new mute list
This patch depends on: Adding filtering support for MuteItem events - Gives more specific mute reason in EventMutedBoxView - Showing all types of mutes in MutelistView - Allowing for adding mutes directly from MutelistView - Allowing for choosing duration of mute in EventMenu Related: https://github.com/damus-io/damus/issues/1718 Related: https://github.com/damus-io/damus/issues/856 Lighting Address: fishcharlie@strike.me Signed-off-by: Charlie Fish <contact@charlie.fish> Reviewed-by: William Casarin <jb55@jb55.com> Signed-off-by: William Casarin <jb55@jb55.com>
This commit is contained in:
committed by
William Casarin
parent
61a9e44898
commit
75d66434f3
@@ -196,8 +196,11 @@ struct ProfileView: View {
|
||||
damus_state.postbox.send(new_ev)
|
||||
}
|
||||
} else {
|
||||
Button(NSLocalizedString("Mute", comment: "Button to mute a profile."), role: .destructive) {
|
||||
notify(.mute(.user(profile.pubkey, nil)))
|
||||
MuteDurationMenu { duration in
|
||||
notify(.mute(.user(profile.pubkey, duration?.date_from_now)))
|
||||
} label: {
|
||||
Text(NSLocalizedString("Mute", comment: "Button to mute a profile."))
|
||||
.foregroundStyle(.red)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user