mirror of
https://github.com/elk-zone/elk.git
synced 2024-11-22 01:15:25 +03:00
fix: update more public and explore links
This commit is contained in:
parent
fd1be3b86c
commit
04615e443e
4 changed files with 8 additions and 8 deletions
|
@ -18,14 +18,14 @@ const moreMenuVisible = ref(false)
|
|||
<div i-ri:notification-4-line />
|
||||
</NuxtLink>
|
||||
</template>
|
||||
<NuxtLink to="/explore" :active-class="moreMenuVisible ? '' : 'text-primary'" flex flex-row items-center place-content-center h-full flex-1 @click="$scrollToTop">
|
||||
<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 group to="/public/local" :active-class="moreMenuVisible ? '' : 'text-primary'" flex flex-row items-center place-content-center h-full flex-1 @click="$scrollToTop">
|
||||
<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>
|
||||
<template v-if="!currentUser">
|
||||
<NuxtLink to="/public" :active-class="moreMenuVisible ? '' : 'text-primary'" flex flex-row items-center place-content-center h-full flex-1 @click="$scrollToTop">
|
||||
<NuxtLink :to="`/${currentServer}/public`" :active-class="moreMenuVisible ? '' : 'text-primary'" flex flex-row items-center place-content-center h-full flex-1 @click="$scrollToTop">
|
||||
<div i-ri:earth-line />
|
||||
</NuxtLink>
|
||||
</template>
|
||||
|
|
|
@ -17,9 +17,9 @@ const { notifications } = useNotifications()
|
|||
</template>
|
||||
</NavSideItem>
|
||||
</template>
|
||||
<NavSideItem :text="$t('nav_side.explore')" to="/explore" icon="i-ri:hashtag" />
|
||||
<NavSideItem :text="$t('nav_side.local')" to="/public/local" icon="i-ri:group-2-line " />
|
||||
<NavSideItem :text="$t('nav_side.federated')" to="/public" icon="i-ri:earth-line" />
|
||||
<NavSideItem :text="$t('nav_side.explore')" :to="`/${currentServer}/explore`" icon="i-ri:hashtag" />
|
||||
<NavSideItem :text="$t('nav_side.local')" :to="`/${currentServer}/public/local`" icon="i-ri:group-2-line " />
|
||||
<NavSideItem :text="$t('nav_side.federated')" :to="`/${currentServer}/public`" icon="i-ri:earth-line" />
|
||||
<template v-if="currentUser">
|
||||
<NavSideItem :text="$t('nav_side.conversations')" to="/conversations" icon="i-ri:at-line" />
|
||||
<NavSideItem :text="$t('nav_side.favourites')" to="/favourites" icon="i-ri:heart-3-line" />
|
||||
|
|
|
@ -23,7 +23,7 @@ const reload = async () => {
|
|||
try {
|
||||
if (!useMasto())
|
||||
await loginTo(currentUser.value)
|
||||
clearError({ redirect: currentUser.value ? '/home' : '/public' })
|
||||
clearError({ redirect: currentUser.value ? '/home' : `/${currentServer.value}/public` })
|
||||
}
|
||||
catch {
|
||||
state.value = 'error'
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
export default defineNuxtRouteMiddleware((to) => {
|
||||
if (!currentUser.value)
|
||||
return navigateTo('/public')
|
||||
return navigateTo(`/${currentServer.value}/public`)
|
||||
if (to.path === '/')
|
||||
return navigateTo('/home')
|
||||
})
|
||||
|
|
Loading…
Reference in a new issue