From 0544c198e8ef0ddc40205525676d7aa28149b077 Mon Sep 17 00:00:00 2001 From: Dominic Masters Date: Tue, 8 May 2018 08:27:39 +1000 Subject: [PATCH] Added animation mixins --- public/styles/index.scss | 1 + public/styles/tools/_animation.scss | 39 +++++++++++++++++++++++++++++ 2 files changed, 40 insertions(+) create mode 100644 public/styles/tools/_animation.scss diff --git a/public/styles/index.scss b/public/styles/index.scss index 473172a..1ee6fa5 100644 --- a/public/styles/index.scss +++ b/public/styles/index.scss @@ -34,6 +34,7 @@ @import './tools/flex.scss'; @import './tools/list.scss'; @import './tools/prefix.scss'; +@import './tools/_animation.scss'; @import './tools/_transform.scss'; @import './tools/_responsive.scss'; diff --git a/public/styles/tools/_animation.scss b/public/styles/tools/_animation.scss new file mode 100644 index 0000000..5706bc5 --- /dev/null +++ b/public/styles/tools/_animation.scss @@ -0,0 +1,39 @@ +/* + * Animation Tools + * Provides common animation tools, as well as mixins. + * + * Dependencies: + * styles/settings/animation.scss + * styles/tools/prefix.scss + * + * Version: + * 1.0.0 - 2018/05/08 + */ +@mixin t-keyframes($animation_name) { + @-webkit-keyframes #{$animation_name} { + @content; + } + + @-moz-keyframes #{$animation_name} { + @content; + } + + @keyframes #{$animation_name} { + @content; + } +} + +@mixin t-animation-name($animation_name) { + @include t-prefix-property("animation-name", $animation_name, webkit moz spec); +} + +@mixin t-animation-delay($animation_name) { + @include t-prefix-property("animation-delay", $animation_name, webkit moz spec); +} + +@mixin t-animation-duration($animation_name) { + @include t-prefix-property("animation-duration", $animation_name, webkit moz spec); +} +@mixin t-animation-fill-mode($animation_name) { + @include t-prefix-property("animation-fill-mode", $animation_name, webkit moz spec); +}