@ -8,12 +8,16 @@ import Tooptip1 from "../../Tooltip/Tooltip1";
import AnimatedProgressbar1 from "../../ProgressBar/AnimatedProgressbar1" ;
const VodDesign1 = ( {
productHolderClassn ame,
cardClassN ame,
relativeIcons ,
discountPricePercent ,
likeBtn ,
discount ,
playButtonClass ,
playImage ,
tooltip ,
productTitle ,
@ -27,6 +31,9 @@ const VodDesign1 = ({
star ,
discountPrice ,
priceHolder ,
priceTitle ,
price ,
progressBar ,
@ -35,9 +42,7 @@ const VodDesign1 = ({
priceDirection ,
productTitleAlignment ,
priceHolder ,
rangeHolder ,
priceTitle ,
addToCartHolder ,
productTitleCategoryHolder ,
productTitleCategoryHolderAlignment ,
@ -46,10 +51,11 @@ const VodDesign1 = ({
} ) => {
return (
< >
< div className = { ` ${ productHolderClassname } ` } >
{ /* product image */ }
< div className = { ` ${ cardClassName } ` } >
{ /* TOP SECTION === ProductImage && ICONS on image && PlayButton && Tooltip */ }
{ /* ProductImage */ }
< div
className = "group transition ease-in-out delay-150 duration-300 w-full relative flex items-center justify-center cursor-pointer"
className = "w-full group relative flex items-center justify-center transition ease-in-out duration-300 cursor-pointer"
style = { {
backgroundImage : ` url("images/VodDesign1watermelon.png") ` ,
backgroundSize : "100% 100%" ,
@ -59,12 +65,12 @@ const VodDesign1 = ({
data - modal - toggle = "large-modal"
>
{ /* icons on image */ }
< div className = "flex flex-col gap-y-2 absolute left-2 top-2" >
< div className = { ` ${ relativeIcons } ` } >
{ discountPricePercent && (
< ButtonDivTag
icon = { false }
text = { discountPricePercent + "%" }
className = "p-2 bg-[#4ACA5322] text-xs text-[#4ACA53] font-sansbold rounded-md"
className = "p-2 bg-[#44d04eee] text-xs text-white font-sansbold rounded-md"
/ >
) }
{ likeBtn && (
@ -82,17 +88,17 @@ const VodDesign1 = ({
text = { false }
icon = { "images/SingleProductdiscount.png" }
iconHolderClassName = { "" }
iconClassName = { "w-10 " }
iconClassName = { "w-9 " }
/ >
) }
< / d i v >
{ /* play button */ }
< div
className = "rounded-full p-4 group-hover:scale-125 transform transition-transform duration-300 bg-[#0D0D0D99]"
className = { ` rounded-full p-4 group-hover:scale-125 transform transition-transform duration-300 ${ playButtonClass } ` }
// onClick={() => setOpenModal(true)}
>
< img
src = "images/VodDesign1white-play-button-icon.svg"
src = { playImage }
alt = ""
className = "w-5"
// onClick={() => setOpenModal(true)}
@ -100,11 +106,12 @@ const VodDesign1 = ({
< / d i v >
{ /* select Color */ }
{ tooltip && (
< div className = "flex items-center gap-x-1 absolute right-2 bottom-2" >
< div className = "flex items-center gap-x-1 absolute right-2 bottom-2 bg-black " >
< Tooptip1 / >
< / d i v >
) }
< / d i v >
{ /* MiddleSection */ }
{ /* product content */ }
< div className = "px-2" >
{ /* content */ }
@ -128,7 +135,7 @@ const VodDesign1 = ({
< / d i v >
{ /* price */ }
< div
className = { ` flex ${ priceStarHolder } ${ priceStarAlignment } justify-between mt-2 ` }
className = { ` flex ${ priceStarHolder } ${ priceStarAlignment } justify-between mt-2 ` }
>
{ priceHolder && (
< div
@ -160,13 +167,12 @@ const VodDesign1 = ({
< / d i v >
{ /* add to cart */ }
{ addToCartHolder && (
< button
className = { ` rounded-md px-2 py-3 border text-xs text-productPrice mt-2 hover:bg-darkCrimsonBgColor hover:text-white active:bg-rangeFillBgColor transition duration-500 ${
< Button
text = { "اضافه کردن به سبد خرید" }
className = { ` rounded-md px-2 py-3 border text-xs text-productPrice mt-2 hover:bg-darkCrimsonBgColor hover:text-white active:bg-rangeFillBgColor transition duration-500 {
priceDirection . indexOf ( "col" ) !== - 1 ? "w-full" : ""
} ` }
>
اضافه کردن به سبد خرید
< / b u t t o n >
/ >
) }
< / d i v >
) }
@ -240,30 +246,33 @@ const VodDesign1 = ({
export default VodDesign1 ;
VodDesign1 . defaultProps = {
productHolderClassname :
"min-w-[600px] rounded-lg shadow-sm p-20 border border-[#C3C3C3]" ,
cardClassName : "w-[444px] rounded-lg shadow-sm p-2 border border-[#C3C3C3]" ,
relativeIcons : "flex flex-col items-center gap-y-2 absolute left-2 top-2" ,
discountPricePercent : "23" ,
likeBtn : true ,
discount : true ,
playButtonClass : "bg-[#0D0D0D99]" ,
playImage : "images/VodDesign1white-play-button-icon.svg" ,
productTitle : "نسخه چاپی علموم تجربه هفتم" ,
productTitleClass : "text-sm text-justify text-[#246E8A]" ,
// icons on product image
productColor : true ,
productContent : ` این کتاب شامل گلدان و گیاه و خاک می باشد و همچنین آپشن های خوب دیگری نیز دارد. ` ,
productContentClass : "mt-2 text-[#707070] text-justify text-xs leading-6" ,
productCat : true ,
star : true ,
// product price
discountPrice : true ,
priceHolder : true ,
priceTitle : false ,
priceTitle : tru e,
productContent : false ,
star : true ,
productTags : false ,
productCat : true ,
rangeHolder : true ,
productTags : [ "ارسال رایگان" , "برچسب های دیگر" , "دسته بندی به صورت کادو" ] ,
addToCartHolder : fals e,
addToCartHolder : true ,
productTitleAlignment : "text-justify" ,
@ -274,6 +283,6 @@ VodDesign1.defaultProps = {
productTitleCategoryHolder : "flex-row" ,
productTitleCategoryHolderAlignment : "items-center" ,
priceStarHolder : "flex-row " ,
priceStarAlignment : "items-c enter " ,
priceStarHolder : "flex-col " ,
priceStarAlignment : "just ify-be tw een" ,
} ;