introduce HybridFilter

This introduces a new filter construct called HybridFilter. This allows
filters to have different remote filter than local ones. For example,
adding kind0 to the remote for keeping profiles up to date on your
timeline, but only subscribing to kind1 locally.

Only home/contact filters use this feature for now.

Fixes: https://github.com/damus-io/notedeck/issues/995
Signed-off-by: William Casarin <jb55@jb55.com>
This commit is contained in:
William Casarin
2025-07-17 13:42:23 -07:00
parent d2994fa340
commit a4c1b38116
9 changed files with 123 additions and 36 deletions

View File

@@ -1,5 +0,0 @@
use nostrdb::Filter;
pub fn contacts_filter(pk: &[u8; 32]) -> Filter {
Filter::new().authors([pk]).kinds([3]).limit(1).build()
}

View File

@@ -3,7 +3,6 @@ pub mod app_images;
pub mod blur;
pub mod colors;
pub mod constants;
pub mod contacts;
pub mod context_menu;
pub mod gif;
pub mod icons;