<template>
    <div>
        <el-scrollbar>
            <lv1 :menuList="menuList" @change="handleShowSubMenus" />
        </el-scrollbar>
    </div>
</template>

<script lang="ts" setup>
import lv1 from "./components/lv1.vue";
const $router = useRouter();
defineProps<{ menuList: Menu.MenuOptions[] }>();

const handleShowSubMenus = (menu: any) => {
    $router.push({
        path: menu.path
    });
};
</script>
<style lang="scss" scoped>
.sub-menu {
    position: fixed;
    top: 0;
    left: 65px;
    z-index: 100;
    box-sizing: border-box;
    width: 210px;
    height: 100%;
    background-color: #ffffff;
    border-radius: 0 24px 24px 0;
    box-shadow: 24px 0 26px -23px rgb(223 228 237 / 60%);
}
</style>
