parent
4ef477114e
commit
6322354efb
4 changed files with 98 additions and 3 deletions
@ -0,0 +1,47 @@ |
||||
import React from "react"; |
||||
|
||||
import arrow from "../../assets/icons/white-left-arrow.svg"; |
||||
|
||||
const ButtonNewDesign = ({ |
||||
bgColor, |
||||
bgHoverColor, |
||||
iconBgColor, |
||||
textColor, |
||||
border, |
||||
borderColor, |
||||
borderRadius, |
||||
fontSize, |
||||
padding, |
||||
icon, |
||||
buttonIcon, |
||||
}) => { |
||||
return ( |
||||
<button |
||||
className={`w-fit h-fit flex items-center transiton duration-200 hover:bg-opacity-70 ${bgColor} ${bgHoverColor} ${textColor} ${border} ${borderColor} ${borderRadius} ${fontSize} ${padding}`} |
||||
> |
||||
اطلاعات بیشتر |
||||
{icon && ( |
||||
<span className={`rounded-full mr-2 ${iconBgColor} `}> |
||||
<img src={buttonIcon} alt="" className="w-full" /> |
||||
</span> |
||||
)} |
||||
</button> |
||||
); |
||||
}; |
||||
|
||||
export default ButtonNewDesign; |
||||
|
||||
ButtonNewDesign.defaultProps = { |
||||
bgColor: "bg-darkGreenBg", |
||||
bgHoverColor: "hover:bg-gray-900", |
||||
iconBgColor: "bg-darkGreenBg", |
||||
textColor: "text-white", |
||||
border: "border-b-4", |
||||
borderColor: "border-lightBlueBorderColor", |
||||
borderRadius: "rounded", |
||||
fontSize: "text-sm", |
||||
padding: "p-4", |
||||
// icons
|
||||
icon: true, |
||||
buttonIcon: arrow, |
||||
}; |
After Width: | Height: | Size: 470 B |
After Width: | Height: | Size: 243 B |
Loading…
Reference in new issue