29 lines
1.4 KiB
Vue
29 lines
1.4 KiB
Vue
<template>
|
|
<div class="min-h-[calc(100vh-9rem)] w-full">
|
|
<SharedHero v-if="hero" :data="hero" />
|
|
<div class="container mx-auto py-12 px-2 min-h-[50vh] flex flex-col gap-2">
|
|
<div v-for="item in content" class="contents">
|
|
<DynamicZoneColumnImageText v-if="item.__component == 'dynamic-zone.column-image-text'" :data="item" />
|
|
<DynamicZoneDualColumnText v-else-if="item.__component == 'dynamic-zone.dual-column-text'" :data="item" />
|
|
<DynamicZoneEmphasiseArticle v-else-if="item.__component == 'dynamic-zone.emphasise-article'" :data="item" />
|
|
<DynamicZoneFullImage v-else-if="item.__component == 'dynamic-zone.full-image'" :data="item" />
|
|
<DynamicZoneFullText v-else-if="item.__component == 'dynamic-zone.full-text'" :data="item" />
|
|
<DynamicZoneGallery v-else-if="item.__component == 'dynamic-zone.gallery'" :data="item" />
|
|
<DynamicZoneFileDownload v-else-if="item.__component == 'dynamic-zone.file-download'" :data="item" />
|
|
<SharedList v-else-if="item.__component == 'shared.list'" :data="item" />
|
|
<br />
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</template>
|
|
|
|
<script setup lang="ts">
|
|
import type { PropType } from "vue";
|
|
import type SharedHero from "../types/component/sharedHero";
|
|
import type { ComponentTypes } from "../types/component/baseComponent";
|
|
|
|
defineProps({
|
|
hero: { type: Object as PropType<SharedHero>, required: false, default: null },
|
|
content: Array<ComponentTypes>,
|
|
});
|
|
</script>
|