Add loading indicator to discover page, add deploy directions to readme

This commit is contained in:
Jon Staab
2024-11-14 15:43:55 -08:00
parent 8caab03e2f
commit e6483d36b2
8 changed files with 126 additions and 25 deletions
+1 -2
View File
@@ -16,7 +16,6 @@
export let pubkeys: string[]
export let messages: TrustedEvent[]
const message = messages[0]
const others = remove($pubkey!, pubkeys)
const active = $page.params.chat === id
const path = makeChatPath(pubkeys)
@@ -53,7 +52,7 @@
{/if}
</div>
<p class="overflow-hidden text-ellipsis whitespace-nowrap text-sm">
{message.content}
{messages[0].content}
</p>
</div>
</div>
+2 -2
View File
@@ -26,9 +26,9 @@
<form class="column gap-4" on:submit|preventDefault={logout}>
<ModalHeader>
<div slot="title">Are you sure you<br />want to log out?</div>
<div slot="title">Are you sure you want<br />to log out?</div>
</ModalHeader>
<p>Your local database will be cleared.</p>
<p class="text-center">Your local database will be cleared.</p>
<ModalFooter>
<Button class="btn btn-link" on:click={back}>
<Icon icon="alt-arrow-left" />
+9 -7
View File
@@ -21,11 +21,13 @@
{/each}
<Divider />
{/if}
<Button on:click={addSpace}>
<CardButton>
<div slot="icon"><Icon icon="login-2" size={7} /></div>
<div slot="title">Add a space</div>
<div slot="info">Join or create a new space</div>
</CardButton>
</Button>
{#if !PLATFORM_RELAY}
<Button on:click={addSpace}>
<CardButton>
<div slot="icon"><Icon icon="login-2" size={7} /></div>
<div slot="title">Add a space</div>
<div slot="info">Join or create a new space</div>
</CardButton>
</Button>
{/if}
</div>
+10 -1
View File
@@ -5,8 +5,11 @@
import type {Filter} from "@welshman/util"
import {deriveEvents} from "@welshman/store"
import {repository, load, loadRelaySelections, formatTimestampRelative} from "@welshman/app"
import Icon from "@lib/components/Icon.svelte"
import Link from "@lib/components/Link.svelte"
import Profile from "@app/components/Profile.svelte"
import ProfileInfo from "@app/components/ProfileInfo.svelte"
import {makeChatPath} from "@app/routes"
export let pubkey
@@ -28,7 +31,13 @@
</script>
<div class="card2 bg-alt col-2 shadow-xl">
<Profile {pubkey} />
<div class="flex justify-between">
<Profile {pubkey} />
<Link class="btn btn-primary" href={makeChatPath([pubkey])}>
<Icon icon="letter" />
Start a Chat
</Link>
</div>
<ProfileInfo {pubkey} />
{#if roots.length > 0}
{@const event = first(sortBy(e => -e.created_at, roots))}