2022-11-25 08:13:35 +00:00
|
|
|
<script setup lang="ts">
|
2022-12-04 14:17:02 +00:00
|
|
|
// only one icon can be lit up at the same time
|
|
|
|
const moreMenuVisible = ref(false)
|
2022-11-25 08:13:35 +00:00
|
|
|
</script>
|
|
|
|
|
|
|
|
<template>
|
2022-12-04 14:17:02 +00:00
|
|
|
<nav
|
|
|
|
h-14 border="t base" flex flex-row text-xl
|
2022-12-05 13:20:23 +00:00
|
|
|
of-y-scroll scrollbar-hide overscroll-none
|
|
|
|
class="after-content-empty after:(h-[calc(100%+0.5px)] w-0.1px pointer-events-none)"
|
2022-12-04 14:17:02 +00:00
|
|
|
>
|
|
|
|
<!-- These weird styles above are used for scroll locking, don't change it unless you know exactly what you're doing. -->
|
2023-01-15 08:38:02 +00:00
|
|
|
<template v-if="currentUser">
|
2022-12-04 14:17:02 +00:00
|
|
|
<NuxtLink to="/home" :active-class="moreMenuVisible ? '' : 'text-primary'" flex flex-row items-center place-content-center h-full flex-1 @click="$scrollToTop">
|
2022-11-25 08:13:35 +00:00
|
|
|
<div i-ri:home-5-line />
|
|
|
|
</NuxtLink>
|
2023-01-17 20:30:06 +00:00
|
|
|
<NuxtLink :to="isHydrated ? `/${currentServer}/explore` : '/explore'" :active-class="moreMenuVisible ? '' : 'text-primary'" flex flex-row items-center place-content-center h-full flex-1 @click="$scrollToTop">
|
2022-12-27 21:41:44 +00:00
|
|
|
<div i-ri:search-line />
|
|
|
|
</NuxtLink>
|
2022-12-04 14:17:02 +00:00
|
|
|
<NuxtLink to="/notifications" :active-class="moreMenuVisible ? '' : 'text-primary'" flex flex-row items-center place-content-center h-full flex-1 @click="$scrollToTop">
|
2022-11-25 08:13:35 +00:00
|
|
|
<div i-ri:notification-4-line />
|
|
|
|
</NuxtLink>
|
2022-12-27 21:41:44 +00:00
|
|
|
<NuxtLink to="/conversations" :active-class="moreMenuVisible ? '' : 'text-primary'" flex flex-row items-center place-content-center h-full flex-1 @click="$scrollToTop">
|
|
|
|
<div i-ri:at-line />
|
|
|
|
</NuxtLink>
|
2022-11-25 08:13:35 +00:00
|
|
|
</template>
|
2023-01-15 08:38:02 +00:00
|
|
|
<template v-else>
|
2022-12-27 21:41:44 +00:00
|
|
|
<NuxtLink :to="`/${currentServer}/explore`" :active-class="moreMenuVisible ? '' : 'text-primary'" flex flex-row items-center place-content-center h-full flex-1 @click="$scrollToTop">
|
|
|
|
<div i-ri:hashtag />
|
|
|
|
</NuxtLink>
|
|
|
|
<NuxtLink to="/search" :active-class="moreMenuVisible ? '' : 'text-primary'" flex flex-row items-center place-content-center h-full flex-1 @click="$scrollToTop">
|
|
|
|
<div i-ri:search-line />
|
|
|
|
</NuxtLink>
|
|
|
|
<NuxtLink group :to="`/${currentServer}/public/local`" :active-class="moreMenuVisible ? '' : 'text-primary'" flex flex-row items-center place-content-center h-full flex-1 @click="$scrollToTop">
|
|
|
|
<div i-ri:group-2-line />
|
|
|
|
</NuxtLink>
|
2022-12-04 20:05:11 +00:00
|
|
|
<NuxtLink :to="`/${currentServer}/public`" :active-class="moreMenuVisible ? '' : 'text-primary'" flex flex-row items-center place-content-center h-full flex-1 @click="$scrollToTop">
|
2022-12-04 14:17:02 +00:00
|
|
|
<div i-ri:earth-line />
|
|
|
|
</NuxtLink>
|
|
|
|
</template>
|
2023-01-06 15:46:36 +00:00
|
|
|
<NavBottomMoreMenu v-slot="{ toggleVisible, show }" v-model="moreMenuVisible" flex flex-row items-center place-content-center h-full flex-1 cursor-pointer>
|
2022-12-04 14:17:02 +00:00
|
|
|
<label
|
2022-12-07 00:05:17 +00:00
|
|
|
flex items-center place-content-center h-full flex-1 class="select-none"
|
2022-12-04 14:17:02 +00:00
|
|
|
:class="show ? '!text-primary' : ''"
|
|
|
|
>
|
2023-01-06 15:46:36 +00:00
|
|
|
<input type="checkbox" z="-1" absolute inset-0 opacity-0 @click="toggleVisible">
|
2022-12-04 14:17:02 +00:00
|
|
|
<span v-show="show" i-ri:close-fill />
|
|
|
|
<span v-show="!show" i-ri:more-fill />
|
|
|
|
</label>
|
|
|
|
</NavBottomMoreMenu>
|
2022-11-25 08:13:35 +00:00
|
|
|
</nav>
|
|
|
|
</template>
|