|
|
@ -1,8 +1,11 @@ |
|
|
|
import React from "react"; |
|
|
|
import React from "react"; |
|
|
|
|
|
|
|
|
|
|
|
import dropbox from "./images/dropbox.svg"; |
|
|
|
import dropbox from "./images/dropbox.svg"; |
|
|
|
|
|
|
|
import googleDrive from "./images/google-drive.svg"; |
|
|
|
|
|
|
|
import blue from "./images/blue-icon.svg"; |
|
|
|
|
|
|
|
|
|
|
|
const CardHolder = ({ |
|
|
|
const CardHolder = ({ |
|
|
|
|
|
|
|
items, |
|
|
|
cardImage, |
|
|
|
cardImage, |
|
|
|
cardBackgroundColor, |
|
|
|
cardBackgroundColor, |
|
|
|
cardBorder, |
|
|
|
cardBorder, |
|
|
@ -10,23 +13,30 @@ const CardHolder = ({ |
|
|
|
cardBorderRadius, |
|
|
|
cardBorderRadius, |
|
|
|
}) => { |
|
|
|
}) => { |
|
|
|
return ( |
|
|
|
return ( |
|
|
|
|
|
|
|
<div className=""> |
|
|
|
|
|
|
|
{items.map((item, index) => ( |
|
|
|
<div |
|
|
|
<div |
|
|
|
className={`w-fit bg-white px-4 py-1 flex flex-row items-center ${cardBorder} ${cardBorderRadius}`} |
|
|
|
className={`w-full px-2 py-1 flex flex-row items-center mt-4 ${cardBorder} ${cardBorderRadius} |
|
|
|
|
|
|
|
${item.active === true ? "bg-blue-100" : "bg-white"} |
|
|
|
|
|
|
|
`}
|
|
|
|
style={{ |
|
|
|
style={{ |
|
|
|
backgroundColor: cardBackgroundColor, |
|
|
|
// backgroundColor: cardBackgroundColor,
|
|
|
|
borderColor: cardBorderColor, |
|
|
|
borderColor: item.active === true ? "#06BACE" : "#EEEEEE", |
|
|
|
}} |
|
|
|
}} |
|
|
|
|
|
|
|
key={index} |
|
|
|
> |
|
|
|
> |
|
|
|
<img src={cardImage} className="w-20" /> |
|
|
|
<img src={item.icon} className="w-14" /> |
|
|
|
<div className="flex flex-col mr-2"> |
|
|
|
<div className="flex flex-col mr-2 flex-1"> |
|
|
|
<p style={{ color: "#00253A" }} className="text-sm"> |
|
|
|
<p style={{ color: "#00253A" }} className="text-sm"> |
|
|
|
فضای ذخیره سازی گوگل درایو |
|
|
|
{item.title} |
|
|
|
</p> |
|
|
|
</p> |
|
|
|
<p className="text-xs text-gray-400 font-light mr-1 mt-2"> |
|
|
|
<p className="text-xs text-gray-400 font-light mr-1 mt-2"> |
|
|
|
فضای باقیمانده 40 گیگابایت از 1000 گیگابایت |
|
|
|
{item.des}{" "} |
|
|
|
</p> |
|
|
|
</p> |
|
|
|
</div> |
|
|
|
</div> |
|
|
|
</div> |
|
|
|
</div> |
|
|
|
|
|
|
|
))} |
|
|
|
|
|
|
|
</div> |
|
|
|
); |
|
|
|
); |
|
|
|
}; |
|
|
|
}; |
|
|
|
|
|
|
|
|
|
|
@ -38,4 +48,25 @@ CardHolder.defaultProps = { |
|
|
|
cardBorder: "border-4", |
|
|
|
cardBorder: "border-4", |
|
|
|
cardBorderColor: "#EEEEEE", |
|
|
|
cardBorderColor: "#EEEEEE", |
|
|
|
cardBorderRadius: "rounded-lg", |
|
|
|
cardBorderRadius: "rounded-lg", |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
items: [ |
|
|
|
|
|
|
|
{ |
|
|
|
|
|
|
|
icon: dropbox, |
|
|
|
|
|
|
|
title: "فضای ذخیره سازی گوگل درایو", |
|
|
|
|
|
|
|
des: "فضای باقیمانده 40 گیگابایت از 1000 گیگابایت", |
|
|
|
|
|
|
|
active: false, |
|
|
|
|
|
|
|
}, |
|
|
|
|
|
|
|
{ |
|
|
|
|
|
|
|
icon: blue, |
|
|
|
|
|
|
|
title: "فضای ذخیره سازی گوگل درایو", |
|
|
|
|
|
|
|
des: "فضای باقیمانده 40 گیگابایت از 1000 گیگابایت", |
|
|
|
|
|
|
|
active: true, |
|
|
|
|
|
|
|
}, |
|
|
|
|
|
|
|
{ |
|
|
|
|
|
|
|
icon: dropbox, |
|
|
|
|
|
|
|
title: "فضای ذخیره سازی گوگل درایو", |
|
|
|
|
|
|
|
des: "فضای باقیمانده 40 گیگابایت از 1000 گیگابایت", |
|
|
|
|
|
|
|
active: false, |
|
|
|
|
|
|
|
}, |
|
|
|
|
|
|
|
], |
|
|
|
}; |
|
|
|
}; |
|
|
|