Merge pull request #18 from wswidzinski/button-hover

Button hover
This commit is contained in:
Wojtek Świdziński 2018-01-16 13:04:55 +01:00 committed by GitHub
commit 09e84f6c91
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
8 changed files with 30 additions and 21 deletions

View File

@ -4,14 +4,7 @@
<div <div
class="button__wrapper js-parallax" class="button__wrapper js-parallax"
data-rellax-speed="{{ternary rellax-speed rellax-speed 0}}" data-rellax-speed="{{ternary rellax-speed rellax-speed 0}}"
style=" style="{{#if backgroundColor }} background-color: {{ backgroundColor }}; {{/if}}"
{{#if outlineColor }}
color: {{ outlineColor }};
{{/if}}
{{#if backgroundColor }}
background-color: {{ backgroundColor }};
{{/if}}
"
> >
{{#if icon}} {{#if icon}}
<div class="button__icon"> <div class="button__icon">

View File

@ -16,7 +16,6 @@
{{#each getInvolved.buttons as |button|}} {{#each getInvolved.buttons as |button|}}
{{> components/button {{> components/button
class="get-involved__button" class="get-involved__button"
outlineColor="#fff"
label=button.label label=button.label
icon=(svg button.icon) icon=(svg button.icon)
}} }}

View File

@ -29,7 +29,6 @@
{{> components/button {{> components/button
label=hero.button.label label=hero.button.label
outlineColor="#FFF"
class="hero__button" class="hero__button"
icon=(svg hero.button.icon width="24px" height="24px") icon=(svg hero.button.icon width="24px" height="24px")
}} }}

View File

@ -33,7 +33,6 @@
<div class="introduction__button"> <div class="introduction__button">
{{> components/button {{> components/button
label=introduction.button.label label=introduction.button.label
outlineColor="#fff"
backgroundColor="#000" backgroundColor="#000"
rellax-speed="0.5" rellax-speed="0.5"
}} }}

View File

@ -8,14 +8,12 @@
<div class="structure__image"></div> <div class="structure__image"></div>
<div class="structure__button"> {{> components/button
{{> components/button label=structure.button.label
label=structure.button.label class="structure__button"
outlineColor="#ff3a00" backgroundColor="#000"
backgroundColor="#000" icon=(svg structure.button.icon)
icon=(svg structure.button.icon) }}
}}
</div>
</div> </div>
<div class="structure__details"> <div class="structure__details">

View File

@ -1,10 +1,21 @@
$_button_transition: all .25s ease-in-out;
.button { .button {
width: 100%; width: 100%;
font-family: 'Work Sans'; font-family: 'Work Sans';
font-size: 14px; font-size: 14px;
font-weight: 600; font-weight: 600;
color: white; color: $color-white;
text-transform: uppercase; text-transform: uppercase;
transition: $_button_transition;
&:hover {
color: $color-scarlet;
}
&:hover &__icon {
transform: scale(1);
}
&__wrapper { &__wrapper {
display: inline-flex; display: inline-flex;
@ -17,6 +28,8 @@
&__icon { &__icon {
margin-right: 10px; margin-right: 10px;
transform: scale(.8);
transition: $_button_transition;
} }
@media #{$screen-sm} { @media #{$screen-sm} {

View File

@ -134,6 +134,10 @@
&__button { &__button {
margin: 10px 0; margin: 10px 0;
&:hover {
color: $color-black !important;
}
@media #{$screen-only-xs}, #{$screen-only-sm} { @media #{$screen-only-xs}, #{$screen-only-sm} {
.js-parallax { .js-parallax {
@include disableTransform(); @include disableTransform();

View File

@ -78,7 +78,11 @@
&__button { &__button {
margin-top: 10px; margin-top: 10px;
color: $color-scarlet; color: $color-scarlet !important;
&:hover {
color: $color-blue !important;
}
@media #{$screen-sm} { @media #{$screen-sm} {
position: absolute; position: absolute;