feat: basic chat flow

This commit is contained in:
reya
2024-07-24 14:22:51 +07:00
parent 9b1edf7f62
commit d9c4993b71
17 changed files with 828 additions and 80 deletions

12
src-tauri/src/common.rs Normal file
View File

@@ -0,0 +1,12 @@
use nostr_sdk::prelude::*;
pub fn is_target(target: &PublicKey, tags: &Vec<Tag>) -> bool {
for tag in tags {
if let Some(TagStandard::PublicKey { public_key, .. }) = tag.as_standardized() {
if public_key == target {
return true;
}
}
}
false
}