diff --git a/README.md b/README.md index eead89c71..97b88096d 100644 --- a/README.md +++ b/README.md @@ -12,7 +12,7 @@ - [x] NIP-05 support - [x] Broadcast events - [x] User tipping -- [ ] Manage followers ( Contact List ) +- [x] Manage followers ( Contact List ) - [ ] Profile management - [ ] Relay management - [ ] Image upload @@ -24,7 +24,7 @@ ## Supported NIPs -- [ ] [NIP-02](https://github.com/nostr-protocol/nips/blob/master/02.md): Contact List and Petnames +- [x] [NIP-02](https://github.com/nostr-protocol/nips/blob/master/02.md): Contact List and Petnames - [ ] [NIP-03](https://github.com/nostr-protocol/nips/blob/master/03.md): OpenTimestamps Attestations for Events - [ ] [NIP-04](https://github.com/nostr-protocol/nips/blob/master/04.md): Encrypted Direct Message - [x] [NIP-05](https://github.com/nostr-protocol/nips/blob/master/05.md): Mapping Nostr keys to DNS-based internet identifiers @@ -53,7 +53,6 @@ - add `client` tag to published events - add button for creating lightning invoice via WebLN -- setup deploy to s3 - make app a valid web share target https://developer.chrome.com/articles/web-share-target/ - make app handle image files - block notes based on content diff --git a/src/components/connected-relays.tsx b/src/components/connected-relays.tsx index 674f05eca..504783782 100644 --- a/src/components/connected-relays.tsx +++ b/src/components/connected-relays.tsx @@ -9,7 +9,6 @@ import { ModalBody, ModalCloseButton, Button, - Spacer, } from "@chakra-ui/react"; import { Relay } from "../services/relays"; import relayPool from "../services/relays/relay-pool"; @@ -49,7 +48,7 @@ export const ConnectedRelays = () => { {relays.map((relay) => ( - + {relay.url} ))} diff --git a/src/components/following-list.tsx b/src/components/following-list.tsx index 674218316..c599754df 100644 --- a/src/components/following-list.tsx +++ b/src/components/following-list.tsx @@ -3,8 +3,8 @@ import { Link } from "react-router-dom"; import { Bech32Prefix, normalizeToBech32 } from "../helpers/nip-19"; import { getUserDisplayName } from "../helpers/user-metadata"; import useSubject from "../hooks/use-subject"; -import { useUserContacts } from "../hooks/use-user-contacts"; import { useUserMetadata } from "../hooks/use-user-metadata"; +import followingService from "../services/following"; import identity from "../services/identity"; import { UserAvatar } from "./user-avatar"; @@ -29,15 +29,15 @@ const FollowingListItem = ({ pubkey }: { pubkey: string }) => { export const FollowingList = () => { const pubkey = useSubject(identity.pubkey); - const contacts = useUserContacts(pubkey); + const following = useSubject(followingService.following); - if (!contacts) return ; + if (!following) return ; return ( - {contacts.contacts.map((contact) => ( - + {following.map((pTag) => ( + ))} diff --git a/src/components/note/note-contents.tsx b/src/components/note/note-contents.tsx index d888291fc..2c476b457 100644 --- a/src/components/note/note-contents.tsx +++ b/src/components/note/note-contents.tsx @@ -167,7 +167,7 @@ const embeds: EmbedType[] = [ regexp: /(https?:\/\/)([\da-z\.-]+\.[a-z\.]{2,6})([\/\w\.-]+\.(svg|gif|png|jpg|jpeg|webp|avif))[^\s]*/im, render: (match, event, trusted) => { const ImageComponent = trusted || !settings.blurImages.value ? Image : BlurredImage; - return ; + return ; }, name: "Image", isMedia: true, @@ -175,11 +175,7 @@ const embeds: EmbedType[] = [ // Video { regexp: /(https?:\/\/)([\da-z\.-]+\.[a-z\.]{2,6})([\/\w\.-]+\.(mp4|mkv|webm|mov))[^\s]*/im, - render: (match) => ( - - - ), + render: (match) =>