semantic-ui-less
Version:
LESS Only distribution of Semantic UI
276 lines (228 loc) • 6.04 kB
text/less
/*!
* # Semantic UI - Reveal
* http://github.com/semantic-org/semantic-ui/
*
*
* Released under the MIT license
* http://opensource.org/licenses/MIT
*
*/
/*******************************
Theme
*******************************/
@type : 'element';
@element : 'reveal';
@import (multiple) '../../theme.config';
/*******************************
Reveal
*******************************/
.ui.reveal {
display: inherit;
position: relative ;
font-size: 0em ;
}
.ui.reveal > .visible.content {
position: absolute ;
top: 0em ;
left: 0em ;
z-index: @topZIndex ;
transition: @transition;
}
.ui.reveal > .hidden.content {
position: relative ;
z-index: @bottomZIndex ;
}
/* Make sure hovered element is on top of other reveal */
.ui.active.reveal .visible.content,
.ui.reveal:hover .visible.content {
z-index: @activeZIndex ;
}
/*******************************
Types
*******************************/
/*--------------
Slide
---------------*/
.ui.slide.reveal {
position: relative ;
overflow: hidden ;
white-space: nowrap;
}
.ui.slide.reveal > .content {
display: block;
width: 100%;
white-space: normal;
float: left;
margin: 0em;
transition: @slideTransition;
}
.ui.slide.reveal > .visible.content {
position: relative ;
}
.ui.slide.reveal > .hidden.content {
position: absolute ;
left: 0% ;
width: 100% ;
transform: translateX(100%) ;
}
.ui.slide.active.reveal > .visible.content,
.ui.slide.reveal:hover > .visible.content {
transform: translateX(-100%) ;
}
.ui.slide.active.reveal > .hidden.content,
.ui.slide.reveal:hover > .hidden.content {
transform: translateX(0%) ;
}
.ui.slide.right.reveal > .visible.content {
transform: translateX(0%) ;
}
.ui.slide.right.reveal > .hidden.content {
transform: translateX(-100%) ;
}
.ui.slide.right.active.reveal > .visible.content,
.ui.slide.right.reveal:hover > .visible.content {
transform: translateX(100%) ;
}
.ui.slide.right.active.reveal > .hidden.content,
.ui.slide.right.reveal:hover > .hidden.content {
transform: translateX(0%) ;
}
.ui.slide.up.reveal > .hidden.content {
transform: translateY(100%) ;
}
.ui.slide.up.active.reveal > .visible.content,
.ui.slide.up.reveal:hover > .visible.content {
transform: translateY(-100%) ;
}
.ui.slide.up.active.reveal > .hidden.content,
.ui.slide.up.reveal:hover > .hidden.content {
transform: translateY(0%) ;
}
.ui.slide.down.reveal > .hidden.content {
transform: translateY(-100%) ;
}
.ui.slide.down.active.reveal > .visible.content,
.ui.slide.down.reveal:hover > .visible.content {
transform: translateY(100%) ;
}
.ui.slide.down.active.reveal > .hidden.content,
.ui.slide.down.reveal:hover > .hidden.content {
transform: translateY(0%) ;
}
/*--------------
Fade
---------------*/
.ui.fade.reveal > .visible.content {
opacity: 1;
}
.ui.fade.active.reveal > .visible.content,
.ui.fade.reveal:hover > .visible.content {
opacity: 0;
}
/*--------------
Move
---------------*/
.ui.move.reveal {
position: relative ;
overflow: hidden ;
white-space: nowrap;
}
.ui.move.reveal > .content {
display: block;
float: left;
white-space: normal;
margin: 0em;
transition: @moveTransition;
}
.ui.move.reveal > .visible.content {
position: relative ;
}
.ui.move.reveal > .hidden.content {
position: absolute ;
left: 0% ;
width: 100% ;
}
.ui.move.active.reveal > .visible.content,
.ui.move.reveal:hover > .visible.content {
transform: translateX(-100%) ;
}
.ui.move.right.active.reveal > .visible.content,
.ui.move.right.reveal:hover > .visible.content {
transform: translateX(100%) ;
}
.ui.move.up.active.reveal > .visible.content,
.ui.move.up.reveal:hover > .visible.content {
transform: translateY(-100%) ;
}
.ui.move.down.active.reveal > .visible.content,
.ui.move.down.reveal:hover > .visible.content {
transform: translateY(100%) ;
}
/*--------------
Rotate
---------------*/
.ui.rotate.reveal > .visible.content {
transition-duration: @transitionDuration;
transform: rotate(0deg);
}
.ui.rotate.reveal > .visible.content,
.ui.rotate.right.reveal > .visible.content {
transform-origin: bottom right;
}
.ui.rotate.active.reveal > .visible.content,
.ui.rotate.reveal:hover > .visible.content,
.ui.rotate.right.active.reveal > .visible.content,
.ui.rotate.right.reveal:hover > .visible.content {
transform: rotate(@rotateDegrees);
}
.ui.rotate.left.reveal > .visible.content {
transform-origin: bottom left;
}
.ui.rotate.left.active.reveal > .visible.content,
.ui.rotate.left.reveal:hover > .visible.content {
transform: rotate(-@rotateDegrees);
}
/*******************************
States
*******************************/
.ui.disabled.reveal:hover > .visible.visible.content {
position: static ;
display: block ;
opacity: 1 ;
top: 0 ;
left: 0 ;
right: auto ;
bottom: auto ;
transform: none ;
}
.ui.disabled.reveal:hover > .hidden.hidden.content {
display: none ;
}
/*******************************
Coupling
*******************************/
.ui.reveal > .ui.ribbon.label {
z-index: @overlayZIndex;
}
/*******************************
Variations
*******************************/
/*--------------
Visible
---------------*/
.ui.visible.reveal {
overflow: visible;
}
/*--------------
Instant
---------------*/
.ui.instant.reveal > .content {
transition-delay: 0s ;
}
/*--------------
Sizing
---------------*/
.ui.reveal > .content {
font-size: @medium ;
}
.loadUIOverrides();