mirror of
https://github.com/discourse/discourse.git
synced 2024-12-02 05:29:17 -06:00
standardize on @transition mixin
This commit is contained in:
parent
e41ae020fa
commit
0b0e9be22f
@ -136,7 +136,6 @@ div.ac-wrap {
|
|||||||
#reply-control {
|
#reply-control {
|
||||||
.composer-loading {
|
.composer-loading {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
@include fades-in(0.25s);
|
|
||||||
left: 45%;
|
left: 45%;
|
||||||
top: 20%;
|
top: 20%;
|
||||||
}
|
}
|
||||||
|
@ -52,15 +52,6 @@
|
|||||||
background-image: linear-gradient(to bottom, $start-color, $end-color);
|
background-image: linear-gradient(to bottom, $start-color, $end-color);
|
||||||
}
|
}
|
||||||
|
|
||||||
// Transition
|
|
||||||
|
|
||||||
@mixin transition($transition) {
|
|
||||||
.discourse-no-touch & {
|
|
||||||
-webkit-transition: #{$transition};
|
|
||||||
transition: #{$transition};
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// Visibility
|
// Visibility
|
||||||
// --------------------------------------------------
|
// --------------------------------------------------
|
||||||
|
|
||||||
@ -72,34 +63,24 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@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 fade-soft($time: 1s) {
|
|
||||||
-webkit-transition: opacity $time ease-in-out;
|
|
||||||
-ms-transition: opacity $time ease-in-out;
|
|
||||||
transition: opacity $time ease-in-out;
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
@mixin visible {
|
@mixin visible {
|
||||||
opacity: 1;
|
opacity: 1;
|
||||||
visibility: visible;
|
visibility: visible;
|
||||||
-webkit-transition-delay: 0s;
|
|
||||||
transition-delay: 0s;
|
transition-delay: 0s;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Transitions
|
||||||
|
// --------------------------------------------------
|
||||||
|
|
||||||
|
@mixin transition($transition-property, $transition-time, $method) {
|
||||||
|
transition: $transition-property $transition-time $method;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
//
|
//
|
||||||
// --------------------------------------------------
|
// --------------------------------------------------
|
||||||
|
|
||||||
// Unselectable
|
// Unselectable (avoids unwanted selections with iPad, touch laptops, etc)
|
||||||
|
|
||||||
@mixin unselectable {
|
@mixin unselectable {
|
||||||
-webkit-user-select: none;
|
-webkit-user-select: none;
|
||||||
|
@ -41,8 +41,7 @@ h1 .topic-statuses .topic-status i {
|
|||||||
.reply-new {
|
.reply-new {
|
||||||
.discourse-no-touch & {
|
.discourse-no-touch & {
|
||||||
opacity:0;
|
opacity:0;
|
||||||
@include transition(opacity linear 0.4s);
|
@include transition(opacity 0.7s ease-in-out);
|
||||||
|
|
||||||
}
|
}
|
||||||
.discourse-touch & {opacity: 1;}
|
.discourse-touch & {opacity: 1;}
|
||||||
}
|
}
|
||||||
@ -51,7 +50,7 @@ h1 .topic-statuses .topic-status i {
|
|||||||
div.actions, .post-actions {
|
div.actions, .post-actions {
|
||||||
.discourse-no-touch & {
|
.discourse-no-touch & {
|
||||||
opacity: 0.2;
|
opacity: 0.2;
|
||||||
@include fade-soft(1s);
|
@include transition(opacity 0.7s ease-in-out);
|
||||||
}
|
}
|
||||||
.discourse-touch & {opacity: 1;}
|
.discourse-touch & {opacity: 1;}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user