2013-02-05 14:16:51 -05:00
|
|
|
// --------------------------------------------------
|
|
|
|
// Mixins used throughout the theme
|
|
|
|
// --------------------------------------------------
|
|
|
|
|
|
|
|
// Media queries
|
|
|
|
// --------------------------------------------------
|
|
|
|
|
|
|
|
|
|
|
|
@mixin small-width {
|
2014-07-24 12:21:22 -04:00
|
|
|
@media all and (max-width: 850px) {
|
2013-02-05 14:16:51 -05:00
|
|
|
@content;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
@mixin medium-width {
|
2014-07-24 12:21:22 -04:00
|
|
|
@media all and (min-width: 1000px) and (max-width: 1139px) {
|
2013-02-05 14:16:51 -05:00
|
|
|
@content;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
@mixin large-width {
|
2014-07-24 12:21:22 -04:00
|
|
|
@media all and (min-width: 1140px) {
|
2013-02-05 14:16:51 -05:00
|
|
|
@content;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2014-07-24 12:21:22 -04:00
|
|
|
@mixin mobile-portrait { @media all and (max-width : 320px) { @content; } }
|
|
|
|
@mixin not-mobile-portrait { @media all and (min-width : 321px) { @content; } }
|
|
|
|
@mixin mobile-landscape { @media all and (min-width : 321px) and (max-width : 959px) { @content; } }
|
|
|
|
@mixin not-tablet-landscape { @media all and (max-width : 959px) { @content; } }
|
|
|
|
@mixin tablet-landscape { @media all and (min-width : 960px) { @content; } }
|
2013-12-18 11:50:51 -05:00
|
|
|
|
2013-02-05 14:16:51 -05:00
|
|
|
// CSS3 properties
|
|
|
|
// --------------------------------------------------
|
|
|
|
|
2015-03-23 10:23:42 -04:00
|
|
|
// Clearfix
|
|
|
|
|
|
|
|
@mixin clearfix() {
|
|
|
|
&:before,
|
|
|
|
&:after {
|
|
|
|
content: "";
|
|
|
|
display: table;
|
|
|
|
}
|
|
|
|
&:after {
|
|
|
|
clear: both;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2013-02-05 14:16:51 -05:00
|
|
|
// 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
|
|
|
|
|
2015-08-19 01:02:01 -04:00
|
|
|
//noinspection CssOptimizeSimilarProperties
|
2013-02-05 14:16:51 -05:00
|
|
|
@mixin linear-gradient($start-color, $end-color) {
|
|
|
|
background-color: $start-color;
|
|
|
|
background-image: linear-gradient(to bottom, $start-color, $end-color);
|
|
|
|
}
|
|
|
|
|
|
|
|
// Visibility
|
|
|
|
// --------------------------------------------------
|
|
|
|
|
|
|
|
@mixin hover {
|
|
|
|
.discourse-no-touch & {
|
|
|
|
&:hover {
|
|
|
|
@content;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2014-12-23 05:52:20 -05:00
|
|
|
@mixin visible {
|
|
|
|
opacity: 1;
|
|
|
|
visibility: visible;
|
|
|
|
transition-delay: 0s;
|
2013-02-05 14:16:51 -05:00
|
|
|
}
|
|
|
|
|
2013-04-08 17:43:52 -04:00
|
|
|
//
|
|
|
|
// --------------------------------------------------
|
|
|
|
|
2014-12-23 05:52:20 -05:00
|
|
|
// Unselectable (avoids unwanted selections with iPad, touch laptops, etc)
|
2013-04-08 17:43:52 -04:00
|
|
|
|
|
|
|
@mixin unselectable {
|
|
|
|
-webkit-user-select: none;
|
|
|
|
-moz-user-select: none;
|
|
|
|
-ms-user-select: none;
|
|
|
|
}
|
2015-08-19 13:27:17 -04:00
|
|
|
|
|
|
|
|
|
|
|
// Stuff we repeat
|
|
|
|
@mixin post-aside {
|
|
|
|
border-left: 5px solid dark-light-diff($primary, $secondary, 90%, -85%);
|
2015-08-20 19:47:34 -04:00
|
|
|
background-color: blend-primary-secondary(5%);
|
2015-08-19 13:27:17 -04:00
|
|
|
}
|