feat: allow choosing favorite buttons in bottom navigation bar (#2761)

This commit is contained in:
TAKAHASHI Shuuji 2024-04-12 18:38:43 +09:00 committed by GitHub
parent 2a6a994da1
commit 2cb070c83c
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
14 changed files with 286 additions and 47 deletions

View file

@ -0,0 +1,15 @@
<script setup lang="ts">
import { STORAGE_KEY_LAST_ACCESSED_EXPLORE_ROUTE } from '~/constants'
defineProps<{
activeClass: string
}>()
const lastAccessedExploreRoute = useLocalStorage(STORAGE_KEY_LAST_ACCESSED_EXPLORE_ROUTE, '')
</script>
<template>
<NuxtLink :to="`/${currentServer}/explore/${lastAccessedExploreRoute}`" :aria-label="$t('nav.explore')" :active-class="activeClass" flex flex-row items-center place-content-center h-full flex-1 class="coarse-pointer:select-none" @click="$scrollToTop">
<div i-ri:compass-3-line />
</NuxtLink>
</template>