Merge improved mute functionality from Charlie
This merge adds a bunch of new features from charlie's work on the new mutelist changes: - Muted words - Mute performance optimizations - New mute list UI I needed to make a few changes to fix the tests in this merge. Otherwise it seems to work ok! Thank to Charlie for getting all of this working after many rounds of review! * branch `mute` of https://github.com/damus-io/damus: mute: fix bug with duplicate Indefinite items in MuteDurationMenu mute: fix mute hashtag from search view if no existing mutelist mute: integrate new MutelistManager mute: adding MutelistManager.swift mute: add maybe_get_content function to NdbNote mute: fix bug where mutes can't be added without existing mutelist mute: fix issue with not being able to change mute duration mute: don't mutate string when adding hashtag mute: implement fast MuteItem decoder tags: add u64 decoding function mute: migrating muted_threads to new mute list mute: adding ability to mute hashtag from SearchView mute: updating UI to support new mute list mute: adding filtering support for MuteItem events mute: receiving New Mute List Type mute: migrate Lists.swift to use new MuteItem mute: add new UI views for new mute list mute: adding new structs/enums for new mute list Changelog-Added: Add ability to mute words, add new mutelist interface (Charlie)
This commit is contained in:
@@ -8,8 +8,8 @@
|
||||
import Foundation
|
||||
|
||||
struct MuteNotify: Notify {
|
||||
typealias Payload = Pubkey
|
||||
var payload: Payload
|
||||
typealias Payload = MuteItem
|
||||
var payload: MuteItem
|
||||
}
|
||||
|
||||
extension NotifyHandler {
|
||||
@@ -19,7 +19,7 @@ extension NotifyHandler {
|
||||
}
|
||||
|
||||
extension Notifications {
|
||||
static func mute(_ target: Pubkey) -> Notifications<MuteNotify> {
|
||||
static func mute(_ target: MuteItem) -> Notifications<MuteNotify> {
|
||||
.init(.init(payload: target))
|
||||
}
|
||||
}
|
||||
|
||||
@@ -8,7 +8,7 @@
|
||||
import Foundation
|
||||
|
||||
struct NewMutesNotify: Notify {
|
||||
typealias Payload = Set<Pubkey>
|
||||
typealias Payload = Set<MuteItem>
|
||||
var payload: Payload
|
||||
}
|
||||
|
||||
@@ -19,7 +19,7 @@ extension NotifyHandler {
|
||||
}
|
||||
|
||||
extension Notifications {
|
||||
static func new_mutes(_ pubkeys: Set<Pubkey>) -> Notifications<NewMutesNotify> {
|
||||
static func new_mutes(_ pubkeys: Set<MuteItem>) -> Notifications<NewMutesNotify> {
|
||||
.init(.init(payload: pubkeys))
|
||||
}
|
||||
}
|
||||
|
||||
@@ -8,7 +8,7 @@
|
||||
import Foundation
|
||||
|
||||
struct NewUnmutesNotify: Notify {
|
||||
typealias Payload = Set<Pubkey>
|
||||
typealias Payload = Set<MuteItem>
|
||||
var payload: Payload
|
||||
}
|
||||
|
||||
@@ -19,7 +19,7 @@ extension NotifyHandler {
|
||||
}
|
||||
|
||||
extension Notifications {
|
||||
static func new_unmutes(_ pubkeys: Set<Pubkey>) -> Notifications<NewUnmutesNotify> {
|
||||
static func new_unmutes(_ pubkeys: Set<MuteItem>) -> Notifications<NewUnmutesNotify> {
|
||||
.init(.init(payload: pubkeys))
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user