flotilla/src/app/components/Landing.svelte

56 lines
1.8 KiB
Svelte
Raw Normal View History

2024-08-09 23:22:09 +00:00
<script lang="ts">
2024-10-09 21:19:27 +00:00
import Icon from "@lib/components/Icon.svelte"
import Button from "@lib/components/Button.svelte"
2025-01-15 22:05:23 +00:00
import Link from "@lib/components/Link.svelte"
2024-10-15 22:52:30 +00:00
import Dialog from "@lib/components/Dialog.svelte"
2024-08-16 17:50:38 +00:00
import CardButton from "@lib/components/CardButton.svelte"
import LogIn from "@app/components/LogIn.svelte"
import SignUp from "@app/components/SignUp.svelte"
2025-01-16 22:54:43 +00:00
import {PLATFORM_TERMS, PLATFORM_PRIVACY, PLATFORM_NAME} from "@app/state"
2024-08-16 17:50:38 +00:00
import {pushModal} from "@app/modal"
2024-08-09 23:22:09 +00:00
const logIn = () => pushModal(LogIn)
const signUp = () => pushModal(SignUp)
</script>
2024-10-15 22:52:30 +00:00
<Dialog>
<div class="column gap-4">
<div class="py-2">
2024-10-22 18:04:40 +00:00
<h1 class="heading">Welcome to {PLATFORM_NAME}!</h1>
2024-10-29 21:40:37 +00:00
<p class="text-center">The chat app built for self-hosted communities.</p>
2024-10-15 22:52:30 +00:00
</div>
<Button onclick={logIn}>
<CardButton class="!btn-primary">
2025-02-04 00:37:14 +00:00
{#snippet icon()}
<div><Icon icon="login-2" size={7} /></div>
{/snippet}
{#snippet title()}
<div>Log in</div>
{/snippet}
{#snippet info()}
<div>If you've been here before, you know the drill.</div>
{/snippet}
2024-10-15 22:52:30 +00:00
</CardButton>
</Button>
<Button onclick={signUp}>
2024-10-15 22:52:30 +00:00
<CardButton>
2025-02-04 00:37:14 +00:00
{#snippet icon()}
<div><Icon icon="add-circle" size={7} /></div>
{/snippet}
{#snippet title()}
<div>Create an account</div>
{/snippet}
{#snippet info()}
<div>Just a few questions and you'll be on your way.</div>
{/snippet}
2024-10-15 22:52:30 +00:00
</CardButton>
</Button>
2025-01-15 22:05:23 +00:00
<p class="text-center text-xs opacity-75">
By using {PLATFORM_NAME}, you consent to our
2025-01-16 22:54:43 +00:00
<Link external class="link" href={PLATFORM_TERMS}>Terms of Service</Link> and
<Link external class="link" href={PLATFORM_PRIVACY}>Privacy Policy</Link>.
2025-01-15 22:05:23 +00:00
</p>
2024-08-09 23:22:09 +00:00
</div>
2024-10-15 22:52:30 +00:00
</Dialog>