-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #78 from sebgroup/develop
Cut release
- Loading branch information
Showing
22 changed files
with
7,502 additions
and
5,787 deletions.
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,82 @@ | ||
$animations: ( | ||
slideInLeft: slideInLeft $transition-slide-in-duration, | ||
slideInRight: slideInRight $transition-slide-in-duration, | ||
slideInUp: slideInUp $transition-slide-in-duration, | ||
fadeIn: fadeIn $transition-fade-duration, | ||
fadeInUp: fadeInUp $transition-fade-duration, | ||
); | ||
|
||
@mixin animations() { | ||
@if $enable-transitions { | ||
@keyframes fadeIn { | ||
0% { | ||
opacity: 0; | ||
} | ||
100% { | ||
opacity: 1; | ||
} | ||
} | ||
@keyframes fadeInUp { | ||
0% { | ||
opacity: 0; | ||
transform: translate3d(0,30px,0); | ||
} | ||
100% { | ||
opacity: 1; | ||
transform: translate3d(0,0,0); | ||
} | ||
} | ||
@keyframes slideInRight { | ||
0% { | ||
transform: translate3d(100%,0,0); | ||
} | ||
100% { | ||
transform: translate3d(0,0,0); | ||
} | ||
} | ||
@keyframes slideInLeft { | ||
0% { | ||
transform: translate3d(-100%,0,0); | ||
} | ||
100% { | ||
transform: translate3d(0,0,0); | ||
} | ||
} | ||
@keyframes slideInUp { | ||
0% { | ||
transform: translate3d(0,100%,0); | ||
} | ||
100% { | ||
transform: translate3d(0,0,0); | ||
} | ||
} | ||
} | ||
} | ||
/** | ||
* Add one or more transitions | ||
* | ||
* @example | ||
* @include add-transition('slideInUp'); | ||
* @include add-transition(('slideInUp','fadeIn')) | ||
*/ | ||
@mixin add-transition($list) { | ||
$combined: ''; | ||
@if type-of($list) == 'string' { | ||
animation: map_get($animations, $list); | ||
} @else if type-of($list) == 'list' { | ||
@for $i from 1 through length($list) { | ||
$anim: map_get($animations, nth($list, $i)); | ||
@if $anim == null { | ||
@warn nth($list, $i) unquote('not found, please use one of the following animations:') to-list($animations, 'keys'); | ||
} | ||
|
||
@if $i == length($list) { | ||
$combined: $combined + $anim; | ||
} | ||
@else { | ||
$combined: $combined + $anim + ','; | ||
} | ||
} | ||
animation: unquote($combined); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
@if $enable-transitions { | ||
@include animations(); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,26 @@ | ||
@import "../bootstrap-core/functions"; | ||
|
||
// convert map to list | ||
@function to-list($value, $keep: 'both') { | ||
$keep: if(index('keys' 'values', $keep), $keep, 'both'); | ||
|
||
@if type-of($value) == 'map' { | ||
$keys: (); | ||
$values: (); | ||
|
||
@each $key, $val in $value { | ||
$keys: append($keys, $key); | ||
$values: append($values, $val); | ||
} | ||
|
||
@if $keep == 'keys' { | ||
@return $keys; | ||
} @else if $keep == 'values' { | ||
@return $values; | ||
} @else { | ||
@return zip($keys, $values); | ||
} | ||
} | ||
|
||
@return if(type-of($value) != 'list', ($value,), $value); | ||
} |
Oops, something went wrong.