2013-02-05 14:16:51 -05:00
|
|
|
// --------------------------------------------------
|
|
|
|
// Mixins used throughout the theme
|
|
|
|
// --------------------------------------------------
|
|
|
|
|
|
|
|
// Media queries
|
|
|
|
// --------------------------------------------------
|
|
|
|
|
|
|
|
|
|
|
|
@mixin small-width {
|
2014-07-09 19:56:35 -04:00
|
|
|
@media screen and (max-width: 850px) {
|
2013-02-05 14:16:51 -05:00
|
|
|
@content;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
@mixin medium-width {
|
2014-07-12 00:12:50 -04:00
|
|
|
@media screen and (min-width: 1000px) and (max-width: 1139px) {
|
2013-02-05 14:16:51 -05:00
|
|
|
@content;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
@mixin large-width {
|
|
|
|
@media screen and (min-width: 1140px) {
|
|
|
|
@content;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2013-12-19 16:51:18 -05:00
|
|
|
@mixin mobile-portrait { @media only screen and (max-width : 320px) { @content; } }
|
|
|
|
@mixin not-mobile-portrait { @media only screen and (min-width : 321px) { @content; } }
|
|
|
|
@mixin mobile-landscape { @media only screen and (min-width : 321px) and (max-width : 959px) { @content; } }
|
|
|
|
@mixin not-tablet-landscape { @media only screen and (max-width : 959px) { @content; } }
|
|
|
|
@mixin tablet-landscape { @media only screen and (min-width : 960px) { @content; } }
|
2013-12-18 11:50:51 -05:00
|
|
|
|
2013-02-05 14:16:51 -05:00
|
|
|
// CSS3 properties
|
|
|
|
// --------------------------------------------------
|
|
|
|
|
|
|
|
// Box sizing
|
|
|
|
|
|
|
|
@mixin box-sizing($sizing) {
|
|
|
|
-webkit-box-sizing: $sizing;
|
|
|
|
-moz-box-sizing: $sizing;
|
|
|
|
box-sizing: $sizing;
|
|
|
|
}
|
|
|
|
|
|
|
|
// Border radius
|
|
|
|
|
|
|
|
@mixin border-radius-all($radius) {
|
2013-11-04 06:51:39 -05:00
|
|
|
border-radius: $radius;
|
2013-02-05 14:16:51 -05:00
|
|
|
}
|
|
|
|
|
|
|
|
// Box shadow
|
|
|
|
|
|
|
|
@mixin box-shadow($shadow) {
|
2013-11-04 06:51:39 -05:00
|
|
|
box-shadow: $shadow;
|
2013-02-05 14:16:51 -05:00
|
|
|
}
|
|
|
|
|
|
|
|
// Linear gradient
|
|
|
|
|
|
|
|
@mixin linear-gradient($start-color, $end-color) {
|
|
|
|
background-color: $start-color;
|
|
|
|
background-image: linear-gradient(to bottom, $start-color, $end-color);
|
|
|
|
}
|
|
|
|
|
|
|
|
// Transition
|
|
|
|
|
|
|
|
@mixin transition($transition) {
|
|
|
|
.discourse-no-touch & {
|
|
|
|
-webkit-transition: #{$transition};
|
|
|
|
-ms-transition: #{$transition};
|
|
|
|
transition: #{$transition};
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
// Visibility
|
|
|
|
// --------------------------------------------------
|
|
|
|
|
|
|
|
@mixin hover {
|
|
|
|
.discourse-no-touch & {
|
|
|
|
&:hover {
|
|
|
|
@content;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
@mixin fades-in($time: 0.5s) {
|
|
|
|
opacity: 0;
|
|
|
|
visibility: hidden;
|
|
|
|
.discourse-no-touch & {
|
|
|
|
-webkit-transition: visibility 0s linear $time, opacity $time linear;
|
|
|
|
-ms-transition: visibility 0s linear $time, opacity $time linear;
|
|
|
|
transition: visibility 0s linear $time, opacity $time linear;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
@mixin visible {
|
|
|
|
opacity: 1;
|
|
|
|
visibility: visible;
|
|
|
|
-webkit-transition-delay: 0s;
|
|
|
|
transition-delay: 0s;
|
|
|
|
}
|
|
|
|
|
2013-04-08 17:43:52 -04:00
|
|
|
//
|
|
|
|
// --------------------------------------------------
|
|
|
|
|
|
|
|
// Unselectable
|
|
|
|
|
|
|
|
@mixin unselectable {
|
|
|
|
-webkit-user-select: none;
|
|
|
|
-moz-user-select: none;
|
|
|
|
-ms-user-select: none;
|
|
|
|
}
|