Files
NSG_PORTAL_V2/components/dynamic-page/page/layouts/Default.vue
T

49 lines
1.4 KiB
Vue
Raw Normal View History

2024-05-30 18:06:50 +07:00
<script setup lang="ts">
const props = defineProps<{
layout?: any
}>()
const CLASS_FOR_LAYOUT = computed(() => {
let _classForLayout = {};
switch (props.layout) {
case 'Full_Page':
_classForLayout = {
2024-05-31 17:05:23 +07:00
page_container: 'page_container mx-auto w-full px-2',
2024-05-30 21:32:51 +07:00
layout_container: 'layout_container px-5',
2024-05-30 18:06:50 +07:00
};
break;
case 'Center_Page':
_classForLayout = {
2024-05-31 17:05:23 +07:00
page_container: 'page_container mx-auto w-full px-2 container ',
2024-05-31 12:49:28 +07:00
layout_container: 'layout_container container-xxl mx-auto',
2024-05-30 18:06:50 +07:00
};
break;
case 'Background_Page':
_classForLayout = {
2024-05-31 17:05:23 +07:00
page_container: 'page_container mx-auto w-full background-container px-2',
2024-05-31 15:31:05 +07:00
layout_container: 'layout_container mx-auto',
2024-05-30 18:06:50 +07:00
};
break;
default:
_classForLayout = {
2024-05-31 17:05:23 +07:00
page_container: 'page_container mx-auto px-2',
2024-05-30 18:06:50 +07:00
layout_container: 'layout_container',
};
break;
}
return _classForLayout;
})
</script>
<template>
<div :class="[CLASS_FOR_LAYOUT.page_container]">
<div :class="[CLASS_FOR_LAYOUT.layout_container]" class="grid-container grid grid-cols-1 gap-20 py-10 style_layout">
2024-05-30 18:06:50 +07:00
<slot />
</div>
</div>
</template>
<style lang="scss" scoped>
</style>