2025-01-18 11:30:46 +01:00
|
|
|
<template>
|
2025-02-19 13:35:38 +01:00
|
|
|
<div class="flex flex-col gap-2 w-full min-h-fit max-w-4xl mx-auto">
|
2025-01-18 11:30:46 +01:00
|
|
|
<a
|
2025-02-14 13:57:55 +01:00
|
|
|
:href="baseUrl + data?.file.url"
|
|
|
|
:download="data?.file.name"
|
2025-01-18 11:30:46 +01:00
|
|
|
target="_blank"
|
|
|
|
class="w-fit text-primary underline"
|
|
|
|
>
|
2025-02-19 13:35:38 +01:00
|
|
|
Datei {{ data?.file.name }} herunterladen
|
2025-01-18 11:30:46 +01:00
|
|
|
</a>
|
|
|
|
</div>
|
|
|
|
</template>
|
|
|
|
|
|
|
|
<script setup lang="ts">
|
|
|
|
import type { PropType } from "vue";
|
2025-02-14 13:57:55 +01:00
|
|
|
import type DynamicZoneFileDownload from "../../types/component/dynamic-zone/fileDownload";
|
2025-01-18 11:30:46 +01:00
|
|
|
|
|
|
|
const runtimeConfig = useRuntimeConfig();
|
|
|
|
const baseUrl = runtimeConfig.public.strapi.url;
|
|
|
|
|
2025-02-19 13:35:38 +01:00
|
|
|
defineProps({
|
2025-01-18 11:30:46 +01:00
|
|
|
data: Object as PropType<DynamicZoneFileDownload>,
|
|
|
|
});
|
|
|
|
</script>
|