refactor(aio): move media queries to mixin
This commit is contained in:
parent
3ccbe28d9f
commit
330b1090f4
|
@ -7,7 +7,7 @@ aio-search-results {
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: row;
|
flex-direction: row;
|
||||||
overflow: scroll;
|
overflow: scroll;
|
||||||
padding: 80px 20px 20px;
|
padding-top: 50px;
|
||||||
color: $offwhite;
|
color: $offwhite;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
max-height: 40%;
|
max-height: 40%;
|
||||||
|
@ -17,6 +17,7 @@ aio-search-results {
|
||||||
left: 0;
|
left: 0;
|
||||||
right: 0;
|
right: 0;
|
||||||
background-color: $darkgray;
|
background-color: $darkgray;
|
||||||
|
border: 24px solid $darkgray;
|
||||||
}
|
}
|
||||||
|
|
||||||
.search-area {
|
.search-area {
|
||||||
|
@ -40,4 +41,8 @@ aio-search-results {
|
||||||
text-decoration: none;
|
text-decoration: none;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@include bp(tiny) {
|
||||||
|
width: 100%;
|
||||||
|
}
|
||||||
}
|
}
|
|
@ -1,46 +1,3 @@
|
||||||
/************************************
|
|
||||||
|
|
||||||
Media queries
|
|
||||||
|
|
||||||
To use these, put this snippet in the approriate selector:
|
|
||||||
|
|
||||||
@include bp(tiny) {
|
|
||||||
background-color: purple;
|
|
||||||
}
|
|
||||||
|
|
||||||
Replace "tiny" with "medium" or "big" as necessary.
|
|
||||||
*************************************/
|
|
||||||
|
|
||||||
@mixin bp($point) {
|
|
||||||
|
|
||||||
$bp-xsmall: "(min-width: 320px)";
|
|
||||||
$bp-teeny: "(min-width: 480px)";
|
|
||||||
$bp-tiny: "(min-width: 600px)";
|
|
||||||
$bp-small: "(min-width: 650px)";
|
|
||||||
$bp-medium: "(min-width: 800px)";
|
|
||||||
$bp-big: "(min-width: 1000px)";
|
|
||||||
|
|
||||||
@if $point == big {
|
|
||||||
@media #{$bp-big} { @content; }
|
|
||||||
}
|
|
||||||
@else if $point == medium {
|
|
||||||
@media #{$bp-medium} { @content; }
|
|
||||||
}
|
|
||||||
@else if $point == small {
|
|
||||||
@media #{$bp-small} { @content; }
|
|
||||||
}
|
|
||||||
@else if $point == tiny {
|
|
||||||
@media #{$bp-tiny} { @content; }
|
|
||||||
}
|
|
||||||
@else if $point == teeny {
|
|
||||||
@media #{$bp-teeny} { @content; }
|
|
||||||
}
|
|
||||||
@else if $point == xsmall {
|
|
||||||
@media #{$bp-xsmall} { @content; }
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
/************************************/
|
|
||||||
/** STEF: HELP WITH LOGO SPACING **/
|
/** STEF: HELP WITH LOGO SPACING **/
|
||||||
.nav-link.home {
|
.nav-link.home {
|
||||||
margin: 0 20px 0 10px;
|
margin: 0 20px 0 10px;
|
||||||
|
|
|
@ -1,3 +1,45 @@
|
||||||
|
/************************************
|
||||||
|
|
||||||
|
Media queries
|
||||||
|
|
||||||
|
To use these, put this snippet in the approriate selector:
|
||||||
|
|
||||||
|
@include bp(tiny) {
|
||||||
|
background-color: purple;
|
||||||
|
}
|
||||||
|
|
||||||
|
Replace "tiny" with "medium" or "big" as necessary.
|
||||||
|
*************************************/
|
||||||
|
|
||||||
|
@mixin bp($point) {
|
||||||
|
|
||||||
|
$bp-xsmall: "(min-width: 320px)";
|
||||||
|
$bp-teeny: "(min-width: 480px)";
|
||||||
|
$bp-tiny: "(min-width: 600px)";
|
||||||
|
$bp-small: "(min-width: 650px)";
|
||||||
|
$bp-medium: "(min-width: 800px)";
|
||||||
|
$bp-big: "(min-width: 1000px)";
|
||||||
|
|
||||||
|
@if $point == big {
|
||||||
|
@media #{$bp-big} { @content; }
|
||||||
|
}
|
||||||
|
@else if $point == medium {
|
||||||
|
@media #{$bp-medium} { @content; }
|
||||||
|
}
|
||||||
|
@else if $point == small {
|
||||||
|
@media #{$bp-small} { @content; }
|
||||||
|
}
|
||||||
|
@else if $point == tiny {
|
||||||
|
@media #{$bp-tiny} { @content; }
|
||||||
|
}
|
||||||
|
@else if $point == teeny {
|
||||||
|
@media #{$bp-teeny} { @content; }
|
||||||
|
}
|
||||||
|
@else if $point == xsmall {
|
||||||
|
@media #{$bp-xsmall} { @content; }
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
@mixin rotate($degrees) {
|
@mixin rotate($degrees) {
|
||||||
-moz-transform: rotate($degrees);
|
-moz-transform: rotate($degrees);
|
||||||
-webkit-transform: rotate($degrees);
|
-webkit-transform: rotate($degrees);
|
||||||
|
|
Loading…
Reference in New Issue