151 lines
2.6 KiB
SCSS
151 lines
2.6 KiB
SCSS
.btn {
|
|
font-size: inherit;
|
|
border: none;
|
|
background: $primary radial-gradient(circle at 0px 0px, #3949ab 0%, rgba(0, 0, 0, .2) 100%) no-repeat;
|
|
color: #fff;
|
|
padding: 0.3em 1.1em;
|
|
margin: .2em 0;
|
|
cursor: pointer;
|
|
position: relative;
|
|
user-select: none;
|
|
border-radius: .1rem;
|
|
box-shadow: $box-shadow-1;
|
|
overflow: hidden;
|
|
display: flex;
|
|
justify-content: center;
|
|
align-items: center;
|
|
transition: background-color .5s, box-shadow .5s;
|
|
|
|
&:focus {
|
|
box-shadow: $box-shadow-2;
|
|
}
|
|
|
|
&--empty {
|
|
background: transparent;
|
|
}
|
|
|
|
&--outline {
|
|
background: transparent;
|
|
border: 1px solid $primary;
|
|
}
|
|
|
|
&--space {
|
|
margin-top: .5rem;
|
|
margin-bottom: .5rem;
|
|
}
|
|
|
|
&[disabled] {
|
|
background: $hoverDark !important;
|
|
color: #303030 !important;
|
|
pointer-events: none;
|
|
}
|
|
|
|
&--valid {
|
|
background: $validColor radial-gradient(circle at 0px 0px, $validColor 0%, rgba(0, 0, 0, .2) 100%) no-repeat;
|
|
}
|
|
|
|
&--accent {
|
|
background: $second radial-gradient(circle at 0px 0px, $second 0%, rgba(0, 0, 0, .2) 100%) no-repeat;
|
|
}
|
|
|
|
&--warn {
|
|
background: $warningBorder radial-gradient(circle at 0px 0px, $warningBorder 0%, rgba(0, 0, 0, .2) 100%) no-repeat;
|
|
}
|
|
&--error {
|
|
background: $errorBorder radial-gradient(circle at 0px 0px, $errorBorder 0%, rgba(0, 0, 0, .2) 100%) no-repeat;
|
|
}
|
|
|
|
&--icon {
|
|
.icon {
|
|
font-size: 1em;
|
|
margin-right: 0;
|
|
}
|
|
}
|
|
}
|
|
|
|
.btn-fab {
|
|
border-radius: 2em;
|
|
width: 2em;
|
|
height: 2em;
|
|
padding: .2em;
|
|
}
|
|
|
|
.ripple {
|
|
position: absolute;
|
|
top: 0;
|
|
left: 0;
|
|
width: 100%;
|
|
height: 100%;
|
|
overflow: hidden;
|
|
background: transparent;
|
|
pointer-events: stroke;
|
|
|
|
&__effect {
|
|
position: absolute;
|
|
top: 50%;
|
|
left: 50%;
|
|
transform: translate(-50%, -50%);
|
|
opacity: 1;
|
|
width: 200%;
|
|
height: 0;
|
|
padding-bottom: 200%;
|
|
border-radius: 50%;
|
|
background: rgba(99, 99, 99, 0.2);
|
|
animation: a-ripple .5s ease-in;
|
|
pointer-events: none;
|
|
|
|
&.to-remove {
|
|
animation: remove-ripple .5s;
|
|
}
|
|
}
|
|
}
|
|
|
|
.btn--outline .ripple__effect {
|
|
background: rgba(57, 73, 171, .5);
|
|
z-index: -1;
|
|
}
|
|
|
|
.btn__content {
|
|
z-index: 1;
|
|
font-weight: 400;
|
|
pointer-events: none;
|
|
}
|
|
|
|
@keyframes remove-ripple {
|
|
from {
|
|
opacity: 1;
|
|
}
|
|
to {
|
|
opacity: 0;
|
|
}
|
|
}
|
|
|
|
@keyframes a-ripple {
|
|
0% {
|
|
opacity: 0;
|
|
padding-bottom: 0;
|
|
width: 0;
|
|
}
|
|
25% {
|
|
opacity: 1;
|
|
}
|
|
100% {
|
|
width: 200%;
|
|
padding-bottom: 200%;
|
|
}
|
|
}
|
|
|
|
.btn-line {
|
|
text-align: right;
|
|
|
|
button {
|
|
margin-right: 0.2em;
|
|
margin-left: 0.2em;
|
|
display: inline-block;
|
|
}
|
|
|
|
button:last-child {
|
|
margin-right: 0;
|
|
}
|
|
}
|