Show warning for non-nip29 relays

This commit is contained in:
Jon Staab
2025-06-05 14:43:39 -07:00
parent 45397e7fb8
commit 397ecf773e
2 changed files with 41 additions and 0 deletions

View File

@@ -0,0 +1,34 @@
<script lang="ts">
import Button from "@lib/components/Button.svelte"
import Link from "@lib/components/Link.svelte"
import ModalHeader from "@lib/components/ModalHeader.svelte"
import {PLATFORM_NAME} from "@app/state"
</script>
<div class="column gap-4">
<ModalHeader>
{#snippet title()}
<div>Where did my rooms go?</div>
{/snippet}
</ModalHeader>
<p>
You might have noticed that old rooms have disappeared from navigation. {PLATFORM_NAME} is still
under heavy development, which means that we occasionally have to make breaking changes. In this
case, we've changed how rooms work in {PLATFORM_NAME} to be more fully compatible with other NIP
29 clients, like <Link external class="link" href="https://chachi.chat">Chachi</Link> and
<Link external class="link" href="https://0xchat.com">0xChat</Link>.
</p>
<p>
This one is particularly annoying, but there is a migration path. To start with, your messages
are all still available under the "Chat" tab - all conversations have just been merged together.
</p>
<p>
Next, if you run a relay please upgrade to a version that supports NIP 29. {PLATFORM_NAME} works
best with the latest version of <Link
external
class="link"
href="https://github.com/coracle-social/frith">Frith</Link
>, which includes a migrate script to upgrade your old rooms into NIP 29 compatible rooms.
</p>
<Button class="btn btn-primary" onclick={() => history.back()}>Got it</Button>
</div>

View File

@@ -15,6 +15,7 @@
import ProfileList from "@app/components/ProfileList.svelte"
import RoomCreate from "@app/components/RoomCreate.svelte"
import MenuSpaceRoomItem from "@app/components/MenuSpaceRoomItem.svelte"
import InfoMissingRooms from "@app/components/InfoMissingRooms.svelte"
import {
userRoomsByUrl,
hasMembershipUrl,
@@ -44,6 +45,8 @@
showMenu = !showMenu
}
const showMissingRooms = () => pushModal(InfoMissingRooms)
const showMembers = () =>
pushModal(
ProfileList,
@@ -161,6 +164,10 @@
notification={$notifications.has(chatPath)}>
<Icon icon="chat-round" /> Chat
</SecondaryNavItem>
<Button class="link flex items-center gap-2 py-2 pl-4 text-sm" onclick={showMissingRooms}>
<Icon icon="info-circle" size={4} />
Where did my rooms go?
</Button>
{/if}
</div>
</SecondaryNavSection>