blob: afdcf32b8b4be93852cf75e5f8960913e00d5ca0 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
|
@use 'sass:meta';
@use 'iro-sass/src/bem';
@use 'iro-sass/src/props';
@use '../props' as *;
@forward 'popover.vars';
@use 'popover.vars' as vars;
@mixin styles {
@include materialize-at-root(meta.module-variables('vars'));
@include bem.object('popover') {
position: fixed;
inset-block-start: 0;
inset-inline-start: 0;
z-index: props.get(vars.$z-index);
padding-block: props.get(vars.$pad-b);
padding-inline: props.get(vars.$pad-i);
background-color: props.get(vars.$bg-color);
filter: props.get(vars.$filter);
border: props.get(vars.$border-width) solid props.get(vars.$border-color);
border-radius: props.get(vars.$rounding);
transform: translate(var(--x), var(--y));
@include bem.modifier('up-left') {
transform: translate(var(--x), calc(var(--y) - 100%));
}
@include bem.modifier('up-right') {
transform: translate(calc(var(--x) - 100%), calc(var(--y) - 100%));
}
@include bem.modifier('down-right') {
transform: translate(calc(var(--x) - 100%), var(--y));
}
}
}
|