mirror of
https://github.com/TryGhost/Ghost.git
synced 2025-01-20 22:42:53 -05:00
Success notifications now fade out after 3 seconds
This commit is contained in:
parent
32b245c53c
commit
94ae164086
3 changed files with 23 additions and 1 deletions
|
@ -56,6 +56,10 @@
|
|||
});
|
||||
});
|
||||
|
||||
$(document).on('animationend', '.js-notification', function () {
|
||||
$(this).hide();
|
||||
});
|
||||
|
||||
|
||||
/**
|
||||
* Example of how to add a persistent notification.
|
||||
|
|
|
@ -870,6 +870,11 @@ nav {
|
|||
@extend %notification;
|
||||
@include icon($i-success);
|
||||
background: $green;
|
||||
|
||||
@include animation(fade-out 1s linear);
|
||||
@include animation-delay(3s);
|
||||
@include animation-iteration-count(1);
|
||||
@include animation-fill-mode(forwards);
|
||||
}
|
||||
|
||||
.notification-error {
|
||||
|
|
|
@ -178,4 +178,17 @@ $green: #9FBB58;
|
|||
text-decoration: none;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/* =============================================================================
|
||||
Animations
|
||||
============================================================================= */
|
||||
|
||||
@include keyframes(fade-out) {
|
||||
from {
|
||||
opacity: 1;
|
||||
}
|
||||
to {
|
||||
opacity: 0;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue