flotilla/src/app/components/MenuSettings.svelte

103 lines
3.2 KiB
Svelte
Raw Normal View History

2024-10-09 23:11:23 +00:00
<script lang="ts">
2025-09-10 22:26:39 +00:00
import UserRounded from "@assets/icons/user-rounded.svg?dataurl"
import Server from "@assets/icons/server.svg?dataurl"
import Settings from "@assets/icons/settings-minimalistic.svg?dataurl"
import Code2 from "@assets/icons/code-2.svg?dataurl"
import Exit from "@assets/icons/logout-3.svg?dataurl"
import Bell from "@assets/icons/bell.svg?dataurl"
import Wallet from "@assets/icons/wallet.svg?dataurl"
2024-10-09 23:15:09 +00:00
import Icon from "@lib/components/Icon.svelte"
import Link from "@lib/components/Link.svelte"
import Button from "@lib/components/Button.svelte"
import CardButton from "@lib/components/CardButton.svelte"
2024-10-09 23:11:23 +00:00
import LogOut from "@app/components/LogOut.svelte"
import {PLATFORM_NAME} from "@app/core/state"
import {pushModal} from "@app/util/modal"
2024-10-09 23:11:23 +00:00
const logout = () => pushModal(LogOut)
</script>
2024-10-09 23:15:09 +00:00
<div class="column menu gap-2">
2024-10-24 18:52:02 +00:00
<Link replaceState href="/settings/profile">
2025-09-11 21:47:06 +00:00
<CardButton class="dark:btn-neutral">
2025-02-04 00:37:14 +00:00
{#snippet icon()}
2025-09-10 22:26:39 +00:00
<div><Icon icon={UserRounded} size={7} /></div>
2025-02-04 00:37:14 +00:00
{/snippet}
{#snippet title()}
<div>Profile</div>
{/snippet}
{#snippet info()}
<div>Customize your user profile</div>
{/snippet}
2024-10-23 16:45:06 +00:00
</CardButton>
</Link>
<Link replaceState href="/settings/alerts">
2025-09-11 21:47:06 +00:00
<CardButton class="dark:btn-neutral">
{#snippet icon()}
<div><Icon icon={Bell} size={7} /></div>
{/snippet}
{#snippet title()}
<div>Alerts</div>
{/snippet}
{#snippet info()}
<div>Set up email digests and push notifications</div>
{/snippet}
</CardButton>
</Link>
<Link replaceState href="/settings/wallet">
2025-09-11 21:47:06 +00:00
<CardButton class="dark:btn-neutral">
{#snippet icon()}
<div><Icon icon={Wallet} size={7} /></div>
{/snippet}
{#snippet title()}
<div>Wallet</div>
{/snippet}
{#snippet info()}
<div>Connect a bitcoin wallet for sending social tips</div>
{/snippet}
</CardButton>
</Link>
2024-10-24 18:52:02 +00:00
<Link replaceState href="/settings/relays">
2025-09-11 21:47:06 +00:00
<CardButton class="dark:btn-neutral">
2025-02-04 00:37:14 +00:00
{#snippet icon()}
2025-09-10 22:26:39 +00:00
<div><Icon icon={Server} size={7} /></div>
2025-02-04 00:37:14 +00:00
{/snippet}
{#snippet title()}
<div>Relays</div>
{/snippet}
{#snippet info()}
<div>Control how {PLATFORM_NAME} talks to the network</div>
{/snippet}
2024-10-09 23:11:23 +00:00
</CardButton>
</Link>
<Link replaceState href="/settings/content">
2025-09-11 21:47:06 +00:00
<CardButton class="dark:btn-neutral">
2025-02-04 00:37:14 +00:00
{#snippet icon()}
2025-09-10 22:26:39 +00:00
<div><Icon icon={Settings} size={7} /></div>
2025-02-04 00:37:14 +00:00
{/snippet}
{#snippet title()}
<div>Settings</div>
{/snippet}
{#snippet info()}
<div>Get into the details about how {PLATFORM_NAME} works</div>
{/snippet}
2024-10-09 23:11:23 +00:00
</CardButton>
</Link>
2024-10-24 18:52:02 +00:00
<Link replaceState href="/settings/about">
2025-09-11 21:47:06 +00:00
<CardButton class="dark:btn-neutral">
2025-02-04 00:37:14 +00:00
{#snippet icon()}
2025-09-10 22:26:39 +00:00
<div><Icon icon={Code2} size={7} /></div>
2025-02-04 00:37:14 +00:00
{/snippet}
{#snippet title()}
<div>About</div>
{/snippet}
{#snippet info()}
<div>Learn about {PLATFORM_NAME} and support the developer</div>
{/snippet}
2024-10-09 23:11:23 +00:00
</CardButton>
</Link>
<Button onclick={logout} class="btn btn-neutral">
2025-09-10 22:26:39 +00:00
<Icon icon={Exit} /> Log Out
2024-10-09 23:11:23 +00:00
</Button>
</div>