Files
hossein-por-shop/frontend/components/product/ProductVideo.vue
T
marzban-dev 85e4296e60 Updated
2025-01-28 22:09:53 +03:30

36 lines
829 B
Vue

<script lang="ts" setup>
// import
import useGetProduct from "~/composables/api/product/useGetProduct";
// state
const route = useRoute();
const id = route.params.id as string | undefined;
const { data: product } = useGetProduct(id);
</script>
<template>
<section v-if="product?.video" class="h-[110svh] w-full relative bg-black mt-[5rem]">
<video
:src="product.video"
class="object-cover absolute size-full"
muted
autoplay
loop
/>
<div class="size-full absolute inset-0 bg-black/20" />
<StickyCard
color="آبی"
:price="product!.price"
picture="/img/product-6.webp"
:title="product!.name"
class="absolute right-10 bottom-10"
/>
</section>
</template>