2018-01-01 19:46:28 +00:00
|
|
|
@import 'common/sass/variables';
|
|
|
|
@import 'common/sass/mixins';
|
|
|
|
|
2018-01-26 20:08:39 +00:00
|
|
|
$tooltip-bg: rgba(#222, 0.95);
|
|
|
|
|
2018-01-01 19:46:28 +00:00
|
|
|
.Tooltip {
|
|
|
|
position: absolute;
|
|
|
|
top: 0;
|
|
|
|
left: 50%;
|
|
|
|
width: 220px;
|
|
|
|
color: #FFF;
|
2018-01-26 20:08:39 +00:00
|
|
|
font-size: $font-size-small;
|
2018-01-01 19:46:28 +00:00
|
|
|
font-family: $font-family-sans-serif;
|
|
|
|
pointer-events: none;
|
|
|
|
opacity: 0;
|
|
|
|
visibility: hidden;
|
|
|
|
transform: translate(-50%, -100%) translateY(-5px);
|
|
|
|
transition-property: opacity, transform, visibility;
|
|
|
|
transition-duration: 100ms, 100ms, 0ms;
|
|
|
|
transition-delay: 0ms, 0ms, 100ms;
|
|
|
|
z-index: $zindex-tooltip;
|
|
|
|
|
|
|
|
> span {
|
|
|
|
display: inline-block;
|
2018-01-26 20:08:39 +00:00
|
|
|
background: $tooltip-bg;
|
|
|
|
border-radius: 3px;
|
|
|
|
padding: 6px 10px;
|
2018-01-01 19:46:28 +00:00
|
|
|
|
|
|
|
&:after {
|
|
|
|
position: absolute;
|
|
|
|
content: '';
|
|
|
|
bottom: 0;
|
|
|
|
left: 50%;
|
|
|
|
transform: translate(-50%, 100%);
|
2018-01-26 20:08:39 +00:00
|
|
|
@include triangle(10px, $tooltip-bg, down);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
// Sizing, medium is default
|
|
|
|
&.is-size-sm {
|
|
|
|
width: 200px;
|
|
|
|
font-size: $font-size-xs;
|
|
|
|
|
|
|
|
> span {
|
|
|
|
padding: 4px 8px;
|
|
|
|
border-radius: 2px;
|
|
|
|
|
|
|
|
&:after {
|
|
|
|
@include triangle(8px, $tooltip-bg, down);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
&.is-size-lg {
|
|
|
|
width: 240px;
|
|
|
|
font-size: $font-size-base;
|
|
|
|
|
|
|
|
> span {
|
|
|
|
padding: 8px 12px;
|
|
|
|
border-radius: 4px;
|
|
|
|
|
|
|
|
&:after {
|
|
|
|
@include triangle(12px, $tooltip-bg, down);
|
|
|
|
}
|
2018-01-01 19:46:28 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|