feat: Add instance changing
This commit is contained in:
1 parent
f201123291
commit
3159583654
17 files changed
+142
-35
No files matched your search
@@ -1,6 +1,8 @@
|
||||
<script lang="ts">
|
||||
import Link from '$lib/components/Link.svelte'
|
||||
import Logo from '$lib/components/Logo.svelte'
|
||||
|
||||
export let instance_url: string | undefined
|
||||
</script>
|
||||
|
||||
<nav
|
||||
@@ -10,7 +12,18 @@
|
||||
<div class="flex flex-row gap-2 items-center mr-auto">
|
||||
<a href="/" class="flex flex-row items-center gap-2">
|
||||
<Logo width={40} />
|
||||
<span class="font-bold">Xylemmy</span>
|
||||
<div class="flex flex-col">
|
||||
<span class="font-bold">Xylemmy</span>
|
||||
{#if instance_url}
|
||||
<a
|
||||
class="text-xs opacity-50 hover:opacity-100 hover:underline
|
||||
transition-opacity"
|
||||
href="/instance"
|
||||
>
|
||||
{new URL(`https://${instance_url}`).hostname}
|
||||
</a>
|
||||
{/if}
|
||||
</div>
|
||||
</a>
|
||||
</div>
|
||||
<Link href="/communities">Communities</Link>
|
||||
|
||||
@@ -0,0 +1,7 @@
|
||||
<script lang="ts">
|
||||
import SvelteMarkdown from 'svelte-markdown'
|
||||
|
||||
export let source: string
|
||||
</script>
|
||||
|
||||
<SvelteMarkdown {source} />
|
||||
Reference in new issue
Block a user