-
Notifications
You must be signed in to change notification settings - Fork 1
/
_sliders.scss
executable file
·86 lines (79 loc) · 1.48 KB
/
_sliders.scss
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
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
/*!
* Spry Sliders
*/
.slider {
position: relative;
&-slides {
display : flex;
overflow-x : scroll;
scroll-behavior : smooth;
scroll-snap-type : x mandatory;
-ms-overflow-style: none;
flex-wrap : nowrap;
&::-webkit-scrollbar {
width : 0;
display: none;
}
&::-webkit-scrollbar-track {
background: transparent;
}
&::-webkit-scrollbar-thumb {
background: transparent;
border : none;
}
>* {
display : flex;
flex-direction : column;
position : relative;
flex : 0 0 100%;
width : 100%;
scroll-snap-align: start;
justify-content : center;
}
}
&[data-snap] .slider-slides > * {
scroll-snap-stop: always;
}
.grid img[loading="lazy"],
.row img[loading="lazy"] {
width: 100%;
height: 100%;
}
.slider-prev,
.slider-next {
content : '';
z-index : 1;
position : absolute;
top : 50%;
left : 0;
transform: translateY(-50%);
transition: opacity .2s ease-in-out;
}
.slider-next {
right: 0;
left : auto;
}
&[data-position="start"] .slider-prev,
&[data-position="end"] .slider-next {
opacity: 0;
}
.slider-pagination {
display: flex;
justify-content: center;
align-items: center;
gap: 2%;
& > * {
cursor: pointer;
border-radius: 50%;
background-color: var(--spry-accent-color);
width: 1em;
height: 1em;
transition: opacity .2s ease-in-out;
opacity: .4;
&:hover,
&.active {
opacity: 1;
}
}
}
}