/******************************* Semantic - Transition Author: Jack Lukic CSS animation definitions for transition module *******************************/ /* Some transitions adapted from Animate CSS https://github.com/daneden/animate.css */ .ui.transition { animation-iteration-count: 1; animation-duration: 1s; animation-timing-function: ease; animation-fill-mode: both; } /******************************* States *******************************/ .ui.animating.transition { display: block; backface-visibility: hidden; transform: translateZ(0); } /* Loading */ .ui.loading.transition { position: absolute; top: -999999px; right: -99999px; } /* Hidden */ .ui.hidden.transition { display: none; } /* Visible */ .ui.visible.transition { display: block; visibility: visible; } /* Disabled */ .ui.disabled.transition { animation-play-state: paused; } /******************************* Variations *******************************/ .ui.looping.transition { animation-iteration-count: infinite; } /******************************* Types *******************************/ /*-------------- Emphasis ---------------*/ .ui.flash.transition { animation-name: flash; } .ui.shake.transition { animation-name: shake; } .ui.bounce.transition { animation-name: bounce; } .ui.tada.transition { animation-name: tada; } /* originally authored by Nick Pettit - https://github.com/nickpettit/glide */ .ui.pulse.transition { animation-name: pulse; } /*-------------- Flips ---------------*/ .ui.flip.transition.in, .ui.flip.transition.out { -webkit-perspective: 2000px; perspective: 2000px; } .ui.horizontal.flip.transition.in, .ui.horizontal.flip.transition.out { animation-name: horizontalFlip; } .ui.horizontal.flip.transition.out { animation-name: horizontalFlipOut; } .ui.vertical.flip.transition.in, .ui.vertical.flip.transition.out { animation-name: verticalFlip; } .ui.vertical.flip.transition.out { animation-name: verticalFlipOut; } /*-------------- Fades ---------------*/ .ui.fade.transition.in { animation-name: fade; } .ui.fade.transition.out { animation-name: fadeOut; } .ui.fade.up.transition.in { animation-name: fadeUp; } .ui.fade.up.transition.out { animation-name: fadeUpOut; } .ui.fade.down.transition.in { animation-name: fadeDown; } .ui.fade.down.transition.out { animation-name: fadeDownOut; } /*-------------- Scale ---------------*/ .ui.scale.transition.in { animation-name: scale; } .ui.scale.transition.out { animation-name: scaleOut; } /*-------------- Slide ---------------*/ .ui.slide.down.transition.in { animation-name: slide; transform-origin: 50% 0%; -ms-transform-origin: 50% 0%; -webkit-transform-origin: 50% 0%; } .ui.slide.down.transition.out { animation-name: slideOut; transform-origin: 50% 0%; } .ui.slide.up.transition.in { animation-name: slide; transform-origin: 50% 100%; } .ui.slide.up.transition.out { animation-name: slideOut; transform-origin: 50% 100%; } @keyframes slide { 0% { opacity: 0; transform: scaleY(0); } 100% { opacity: 1; transform: scaleY(1); } } @keyframes slideOut { 0% { opacity: 1; transform: scaleY(1); } 100% { opacity: 0; transform: scaleY(0); } } /******************************* Animations *******************************/ /*-------------- Emphasis ---------------*/ /* Flash */ @keyframes flash { 0%, 50%, 100% { opacity: 1; } 25%, 75% { opacity: 0; } } /* Shake */ @keyframes shake { 0%, 100% { transform: translateX(0); } 10%, 30%, 50%, 70%, 90% { transform: translateX(-10px); } 20%, 40%, 60%, 80% { transform: translateX(10px); } } /* Bounce */ @keyframes bounce { 0%, 20%, 50%, 80%, 100% { transform: translateY(0); } 40% { transform: translateY(-30px); } 60% { transform: translateY(-15px); } } /* Tada */ @keyframes tada { 0% { transform: scale(1); } 10%, 20% { transform: scale(0.9) rotate(-3deg); } 30%, 50%, 70%, 90% { transform: scale(1.1) rotate(3deg); } 40%, 60%, 80% { transform: scale(1.1) rotate(-3deg); } 100% { transform: scale(1) rotate(0); } } /* Pulse */ @keyframes pulse { 0% { transform: scale(1); opacity: 1; } 50% { transform: scale(0.9); opacity: 0.7; } 100% { transform: scale(1); opacity: 1; } } /*-------------- Flips ---------------*/ /* Horizontal */ @keyframes horizontalFlip { 0% { transform: rotateY(-90deg); opacity: 0; } 100% { transform: rotateY(0deg); opacity: 1; } } /* Horizontal */ @keyframes horizontalFlipOut { 0% { transform: rotateY(0deg); opacity: 1; } 100% { transform: rotateY(90deg); opacity: 0; } } /* Vertical */ @keyframes verticalFlip { 0% { transform: rotateX(-90deg); opacity: 0; } 100% { transform: rotateX(0deg); opacity: 1; } } @keyframes verticalFlipOut { 0% { transform: rotateX(0deg); opacity: 1; } 100% { transform: rotateX(-90deg); opacity: 0; } } /*-------------- Fades ---------------*/ /* Fade */ @keyframes fade { 0% { opacity: 0; } 100% { opacity: 1; } } @keyframes fadeOut { 0% { opacity: 1; } 100% { opacity: 0; } } /* Fade Up */ @keyframes fadeUp { 0% { opacity: 0; transform: translateY(20px); } 100% { opacity: 1; transform: translateY(0); } } @keyframes fadeUpOut { 0% { opacity: 1; transform: translateY(0); } 100% { opacity: 0; transform: translateY(20px); } } /* Fade Down */ @keyframes fadeDown { 0% { opacity: 0; transform: translateY(-20px); } 100% { opacity: 1; transform: translateY(0); } } @keyframes fadeDownOut { 0% { opacity: 1; transform: translateY(0); } 100% { opacity: 0; transform: translateY(-20px); } } /*-------------- Scale ---------------*/ /* Scale */ @keyframes scale { 0% { opacity: 0; transform: scale(0.7); } 100% { opacity: 1; transform: scale(1); } } @keyframes scaleOut { 0% { opacity: 1; transform: scale(1); } 100% { opacity: 0; transform: scale(0.7); } }