mirror of
https://github.com/muerwre/muerwre.github.io.git
synced 2025-04-25 02:46:39 +07:00
34 lines
702 B
Vue
34 lines
702 B
Vue
<template>
|
|
<masonry-wall
|
|
:items="parentItems"
|
|
:ssr-columns="1"
|
|
:column-width="300"
|
|
:gap="10"
|
|
>
|
|
<template #default="{ item }">
|
|
<div :class="$style.row">
|
|
<LayoutMainMenuRow
|
|
:title="item.title"
|
|
:url="item.url"
|
|
:children="item.children"
|
|
/>
|
|
</div>
|
|
</template>
|
|
</masonry-wall>
|
|
</template>
|
|
|
|
<script setup>
|
|
const { data: navigation } = await useAsyncData("navigation", () => {
|
|
return fetchContentNavigation();
|
|
});
|
|
|
|
const parentItems = navigation.value.filter(
|
|
(it) => it.children && Array.isArray(it.children) && it.children.length > 0
|
|
);
|
|
</script>
|
|
|
|
<style lang="scss" module>
|
|
.row {
|
|
margin-bottom: 10px;
|
|
}
|
|
</style>
|