feat: add nav more menu on mobile (#322)
Co-authored-by: 三咲智子 Kevin Deng <sxzz@sxzz.moe>
This commit is contained in:
parent
8f32b1ce22
commit
cbd5867275
11 changed files with 237 additions and 54 deletions
|
@ -3,13 +3,13 @@ const { notifications } = useNotifications()
|
|||
</script>
|
||||
|
||||
<template>
|
||||
<nav px3 py4 flex="~ col gap2" text-lg>
|
||||
<nav md:px3 md:py4 flex="~ col gap2" text-size-base leading-normal md:text-lg>
|
||||
<template v-if="currentUser">
|
||||
<NavSideItem :text="$t('nav_side.home')" to="/home" icon="i-ri:home-5-line" />
|
||||
<NavSideItem :text="$t('nav_side.notifications')" to="/notifications" icon="i-ri:notification-4-line">
|
||||
<template #icon>
|
||||
<div flex relative>
|
||||
<div class="i-ri:notification-4-line" />
|
||||
<div class="i-ri:notification-4-line" md:text-size-inherit text-xl />
|
||||
<div v-if="notifications" class="top-[-0.3rem] right-[-0.3rem]" absolute font-bold rounded-full h-4 w-4 text-xs bg-primary text-inverted flex items-center justify-center>
|
||||
{{ notifications < 10 ? notifications : '•' }}
|
||||
</div>
|
||||
|
@ -31,7 +31,7 @@ const { notifications } = useNotifications()
|
|||
icon="i-ri:account-circle-line"
|
||||
>
|
||||
<template #icon>
|
||||
<AccountAvatar :account="currentUser.account" h="1.2em" />
|
||||
<AccountAvatar :account="currentUser.account" h="1.2em" md:text-size-inherit text-xl />
|
||||
</template>
|
||||
<ContentRich
|
||||
:content="getDisplayName(currentUser.account, { rich: true }) || $t('nav_side.profile')"
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue