@mixin button_base() {
position: relative;
display: inline-block;
font-size: 11px;
line-height: 18px;
text-decoration: none;
padding: 4px 22px;
color: $dark_color;
text-transform: uppercase;
border-radius: $border_radius_small;
border-width: 1px;
border-style: solid;
outline: none;
cursor: pointer;
transition: all 200ms linear;
&:before {
position: absolute;
display: block;
width: 100%;
height: 100%;
top: 0;
left: 0;
border-radius: $border_radius_small;
background-image: linear-gradient(180deg, rgba(255,255,255,0.3) 0%, rgba(255,255,255,0) 100%);
content: '';
}
&:hover {
&:before {
background-image: linear-gradient(0deg, rgba(255,255,255,0.3) 0%, rgba(255,255,255,0) 100%);
}
}
&:active {
&:before {
opacity: 0;
}
}
}
@mixin button_normal() {
background: $dark_color_2;
&:hover {
background: $dark_color_2_h;
}
}
@mixin button_primary() {
background: $blue_color;
&:hover {
background: $blue_color_h;
}
}
@mixin button_success() {
background: $green_color;
&:hover {
background: $green_color_h;
}
}
@mixin button_danger() {
background: $red_color;
&:hover {
background: $red_color_h;
}
}
@mixin button_warning() {
background: $orange_color;
&:hover {
background: $orange_color_h;
}
}
@mixin secondary_button() {
color: $light_color;
border-color: $secondary_outset_1 $secondary_outset_2 $secondary_outset_2 $secondary_outset_1;
background-color: $secondary_gradint_2;
&:active {
background-color: $secondary_bg_color;
border-color: darken( $secondary_outset_2, 10%) $secondary_outset_1 $secondary_outset_1 darken( $secondary_outset_2, 10%);
}
}
@mixin input() {
font-size: 12px;
line-height: 16px;
color: $dark_color;
background-color: $bg_color;
border-radius: $border_radius_extra_small;
padding: 5px;
min-height: 28px;
border: 1px solid $border_color;
box-shadow: none;
&:focus{
border-color: darken( $border_color, 20% );
box-shadow: none;
}
}
@mixin button_icon( $icon ) {
content: $icon;
display: inline-block;
font-family: dashicons;
font-size: 16px;
font-style: normal;
font-weight: 400;
height: 18px;
line-height: 18px;
text-align: center;
text-decoration: inherit;
transition: all 200ms linear;
vertical-align: middle;
}
@mixin button_icon_before( $icon ) {
&:before {
@include button_icon( $icon );
padding: 0 5px 0 0;
}
}
@mixin button_icon_after( $icon ) {
&:after {
@include button_icon( $icon );
padding: 0 0 0 5px;
}
}
@mixin button_icon_middle( $icon ) {
&:before {
@include button_icon( $icon );
margin: 0 -5px;
}
}
@mixin link() {
display: inline-block;
text-decoration: none;
font-size: 12px;
line-height: 20px;
font-weight: bold;
color: $blue_color;
text-transform: uppercase;
transition: all 200ms linear;
&:hover {
color: $dark_color_1;
box-shadow: none;
}
&:focus,
&:active {
outline: none;
border-color: rgba(41, 143, 252, .6);
box-shadow: 0 0 2px rgba(41, 143, 252, .6);
color: $blue_color;
}
}
@mixin link_icon_before( $icon ) {
&:before {
@include button_icon( $icon );
padding: 0 5px 0 0;
color: $grey_color_4;
}
&:hover {
&:before {
color: $blue_color;
}
}
}
@mixin container() {
padding: 30px;
border: 2px solid $grey_color_2;
background: $grey_color_3;
border-radius: $border_radius_large;
}
@mixin container_heading() {
margin: -30px -30px 30px -30px;
border-radius: $border_radius_large $border_radius_large 0 0;
border-bottom: 1px solid $grey_color_2;
padding: 20px 30px;
font-weight: bold;
font-size: 16px;
line-height: 18px;
text-align: center;
background: #fff;
}
@mixin box() {
margin: 0 0 30px;
padding: 20px;
background: #fff;
box-shadow: $box_shadow_box;
border-radius: $border_radius_small;
}
@mixin box_heading() {
margin: -20px -20px 20px -20px;
border-radius: $border_radius_small $border_radius_small 0 0;
border-bottom: 1px solid $grey_color_2;
padding: 20px 30px;
font-weight: bold;
font-size: 16px;
line-height: 18px;
background: #fff;
}
Solar Meter - Solar Energy
Skip to content