Implemented icon & link support for the Icon component
This commit is contained in:
parent
bf20e3b896
commit
2e9c5cde70
@ -2,7 +2,12 @@ import "./styles.sass";
|
||||
|
||||
const Button = (props) => {
|
||||
return (
|
||||
<button className="primary-btn">{props.text}</button>
|
||||
<a href={props.to} className="btn-link">
|
||||
<button className="primary-btn">
|
||||
{props.image ? <img src={props.image} alt="i" className="btn-icon"/> : <></>}
|
||||
{props.text}
|
||||
</button>
|
||||
</a>
|
||||
)
|
||||
}
|
||||
|
||||
|
@ -10,6 +10,15 @@
|
||||
border-radius: 14px
|
||||
cursor: pointer
|
||||
transition: all ease-in 0.1s
|
||||
display: flex
|
||||
|
||||
.btn-link
|
||||
text-decoration: none
|
||||
|
||||
.btn-icon
|
||||
width: 24px
|
||||
margin-right: 10px
|
||||
border-radius: 150px
|
||||
|
||||
.primary-btn:hover
|
||||
background-color: $primary-hover
|
Loading…
x
Reference in New Issue
Block a user