2018-11-26 18:47:56 +00:00
|
|
|
@mixin css-arrow(
|
|
|
|
$vertical-direction,
|
|
|
|
$size,
|
|
|
|
$color,
|
|
|
|
$border-width,
|
|
|
|
$border-color,
|
|
|
|
$left: 50%,
|
|
|
|
$left-offset: 0px
|
|
|
|
) {
|
2018-04-03 14:16:57 +00:00
|
|
|
& {
|
|
|
|
border: 1px solid $border-color;
|
|
|
|
}
|
|
|
|
|
|
|
|
&:after,
|
|
|
|
&:before {
|
2018-05-25 20:33:22 +00:00
|
|
|
@if ($vertical-direction == 'top') {
|
|
|
|
bottom: 100%;
|
|
|
|
} @else {
|
|
|
|
top: 100%;
|
|
|
|
}
|
2018-04-03 14:16:57 +00:00
|
|
|
border: solid transparent;
|
2018-11-26 18:47:56 +00:00
|
|
|
content: ' ';
|
2018-04-03 14:16:57 +00:00
|
|
|
height: 0;
|
|
|
|
width: 0;
|
|
|
|
position: absolute;
|
|
|
|
pointer-events: none;
|
|
|
|
}
|
|
|
|
|
|
|
|
&:after {
|
|
|
|
border-color: rgba($color, 0);
|
|
|
|
border-bottom-color: $color;
|
|
|
|
border-width: $size;
|
|
|
|
left: calc(#{$left} + #{$left-offset});
|
|
|
|
margin-left: -$size;
|
|
|
|
}
|
|
|
|
&:before {
|
|
|
|
border-color: rgba($border-color, 0);
|
|
|
|
border-bottom-color: $border-color;
|
|
|
|
border-width: $size + round(1.41421356 * $border-width);
|
|
|
|
left: calc(#{$left} + #{$left-offset});
|
|
|
|
margin-left: -($size + round(1.41421356 * $border-width));
|
|
|
|
}
|
2018-05-25 20:33:22 +00:00
|
|
|
&:before,
|
|
|
|
&:after {
|
|
|
|
@if ($vertical-direction == 'bottom') {
|
|
|
|
transform: rotate(180deg);
|
|
|
|
}
|
|
|
|
}
|
2018-04-03 14:16:57 +00:00
|
|
|
|
|
|
|
@at-root .ember-basic-dropdown-content--left#{&} {
|
|
|
|
&:after,
|
|
|
|
&:before {
|
|
|
|
left: auto;
|
|
|
|
right: calc(#{$left} + #{$left-offset} - #{$size});
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2018-05-25 20:33:22 +00:00
|
|
|
@mixin css-top-arrow($size, $color, $border-width, $border-color, $left: 50%, $left-offset: 0px) {
|
|
|
|
@include css-arrow('top', $size, $color, $border-width, $border-color, $left, $left-offset);
|
|
|
|
}
|
|
|
|
@mixin css-bottom-arrow($size, $color, $border-width, $border-color, $left: 50%, $left-offset: 0px) {
|
|
|
|
@include css-arrow('bottom', $size, $color, $border-width, $border-color, $left, $left-offset);
|
|
|
|
}
|
|
|
|
|
2018-04-03 14:16:57 +00:00
|
|
|
@mixin vault-block {
|
|
|
|
&:not(:last-child) {
|
|
|
|
margin-bottom: (5/14) + 0rem;
|
|
|
|
}
|
|
|
|
}
|