DONE: fix error on top-menu to for mobile view

This commit is contained in:
ISMAIL MASSERAN
2026-07-01 13:05:21 +08:00
parent 2e2d94f0d6
commit 9e9867217f
23 changed files with 535 additions and 937 deletions
@@ -10,12 +10,19 @@ interface Props {
}
const props = defineProps<Props>()
const open = defineModel<boolean>('open', { default: false })
const authStore = useAuthStore()
function handleClick(event: MouseEvent) {
if (!window.matchMedia('(max-width: 1279px)').matches) return
event.stopPropagation()
open.value = !open.value
}
</script>
<template>
<div :class="['side-menu__account group/profile transition-[width]', props.class]">
<div :class="['flex cursor-pointer items-center transition', props.innerClass]">
<div :class="['flex cursor-pointer items-center transition', props.innerClass]" @click="handleClick">
<div :class="[
'relative flex-none overflow-hidden rounded-full border-4',
props.avatarClass ?? 'h-10 w-10 border-background/20 dark:border-foreground/20',