elk/pages/settings/profile/index.vue

46 lines
1.3 KiB
Vue
Raw Normal View History

<script setup lang="ts">
definePageMeta({
middleware: 'auth',
})
2023-01-04 16:57:12 +03:00
const { t } = useI18n()
useHydratedHead({
2023-01-04 16:57:12 +03:00
title: () => `${t('settings.profile.label')} | ${t('nav.settings')}`,
})
</script>
<template>
<MainContent back-on-small-screen>
<template #title>
<div text-lg font-bold flex items-center gap-2 @click="$scrollToTop">
<span>{{ isHydrated ? $t('settings.profile.label') : '' }}</span>
</div>
</template>
2023-01-02 23:19:36 +03:00
<SettingsItem
command large
icon="i-ri:user-settings-line"
:text="isHydrated ? $t('settings.profile.appearance.label') : ''"
:description="isHydrated ? $t('settings.profile.appearance.description') : ''"
to="/settings/profile/appearance"
/>
2023-01-02 23:19:36 +03:00
<SettingsItem
command large
icon="i-ri:hashtag"
:text="isHydrated ? $t('settings.profile.featured_tags.label') : ''"
:description="isHydrated ? $t('settings.profile.featured_tags.description') : ''"
to="/settings/profile/featured-tags"
/>
<SettingsItem
v-if="isHydrated && currentUser"
command large
icon="i-ri:settings-line"
:text="$t('settings.account_settings.label')"
:description="$t('settings.account_settings.description')"
:to="`https://${currentUser!.server}/auth/edit`"
external target="_blank"
/>
</MainContent>
</template>