mirror of
https://github.com/uiverse-io/galaxy.git
synced 2025-11-28 05:00:22 +08:00
57 lines
903 B
HTML
57 lines
903 B
HTML
<button> <span>Button</span>
|
|
</button>
|
|
<style>
|
|
/* From Uiverse.io by BHARGAVPATEL1244 - Tags: button */
|
|
button {
|
|
outline: none;
|
|
cursor: pointer;
|
|
border: none;
|
|
padding: 0.9rem 2rem;
|
|
margin: 0;
|
|
font-family: inherit;
|
|
font-size: inherit;
|
|
position: relative;
|
|
display: inline-block;
|
|
letter-spacing: 0.05rem;
|
|
font-weight: 700;
|
|
font-size: 17px;
|
|
border-radius: 500px;
|
|
overflow: hidden;
|
|
background: #66ff66;
|
|
color: ghostwhite;
|
|
}
|
|
|
|
button span {
|
|
position: relative;
|
|
z-index: 10;
|
|
transition: color 0.4s;
|
|
}
|
|
|
|
button:hover span {
|
|
color: black;
|
|
}
|
|
|
|
button::before,
|
|
button::after {
|
|
position: absolute;
|
|
top: 0;
|
|
left: 0;
|
|
width: 100%;
|
|
height: 100%;
|
|
z-index: 0;
|
|
}
|
|
|
|
button::before {
|
|
content: "";
|
|
background: #000;
|
|
width: 120%;
|
|
left: -10%;
|
|
transform: skew(30deg);
|
|
transition: transform 0.4s cubic-bezier(0.3, 1, 0.8, 1);
|
|
}
|
|
|
|
button:hover::before {
|
|
transform: translate3d(100%, 0, 0);
|
|
}
|
|
|
|
</style>
|