diff --git a/src/app/components/AlertItem.svelte b/src/app/components/AlertItem.svelte index d83035dc..4adab9c4 100644 --- a/src/app/components/AlertItem.svelte +++ b/src/app/components/AlertItem.svelte @@ -17,14 +17,14 @@ const {alert}: Props = $props() const cron = $derived(getTagValue("cron", alert.tags)) - const room = $derived(getTagValue("room", alert.tags)) + const channel = $derived(getTagValue("channel", alert.tags)) const feeds = $derived(getTagValues("feed", alert.tags)) const description = $derived( getTagValue("description", alert.tags) || [ `${cron?.endsWith("1") ? "Weekly" : "Daily"} alert for events`, displayFeeds(feeds.map(parseJson)), - `sent via ${room}.`, + `sent via ${channel}.`, ].join(" "), ) diff --git a/src/app/core/sync.ts b/src/app/core/sync.ts index de20d397..9af61436 100644 --- a/src/app/core/sync.ts +++ b/src/app/core/sync.ts @@ -265,6 +265,7 @@ const syncSpace = (url: string) => { filters: [ {kinds: [RELAY_MEMBERS]}, {kinds: [ROOM_META, ROOM_DELETE]}, + {kinds: [ROOM_ADMINS, ROOM_MEMBERS]}, {kinds: [RELAY_ADD_MEMBER, RELAY_REMOVE_MEMBER]}, ...MESSAGE_KINDS.map(kind => ({kinds: [kind]})), makeCommentFilter(CONTENT_KINDS), @@ -328,7 +329,7 @@ const syncSpaces = () => { // Chat -const syncRoomChat = (url: string, h: string) => { +const syncRoom = (url: string, h: string) => { const controller = new AbortController() pullAndListen({ @@ -359,7 +360,7 @@ const syncRooms = () => { const key = `${url}'${h}` if (!unsubscribersByKey.has(key)) { - newUnsubscribersByKey.set(key, syncRoomChat(url, h)) + newUnsubscribersByKey.set(key, syncRoom(url, h)) } keys.add(key) diff --git a/src/app/util/storage.ts b/src/app/util/storage.ts index 4fa48bd9..29f58311 100644 --- a/src/app/util/storage.ts +++ b/src/app/util/storage.ts @@ -25,6 +25,7 @@ import { ROOM_ADD_MEMBER, ROOM_CREATE_PERMISSION, ROOM_MEMBERS, + ROOM_ADMINS, ROOM_META, ROOM_DELETE, ROOM_REMOVE_MEMBER, @@ -77,6 +78,7 @@ const syncEvents = async () => { const roomKinds = [ ROOM_META, ROOM_DELETE, + ROOM_ADMINS, ROOM_MEMBERS, ROOM_ADD_MEMBER, ROOM_REMOVE_MEMBER, diff --git a/src/routes/spaces/[relay]/[h]/+page.svelte b/src/routes/spaces/[relay]/[h]/+page.svelte index 0465c79f..d3deff62 100644 --- a/src/routes/spaces/[relay]/[h]/+page.svelte +++ b/src/routes/spaces/[relay]/[h]/+page.svelte @@ -339,7 +339,7 @@ {/snippet} {#snippet action()}
- {#if $userIsAdmin || true} + {#if $userIsAdmin}