forked from google/santa-tracker-web
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcountdown-timer.scss
More file actions
95 lines (85 loc) · 1.74 KB
/
Copy pathcountdown-timer.scss
File metadata and controls
95 lines (85 loc) · 1.74 KB
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
87
88
89
90
91
92
93
94
95
$counterMargin: 7px;
$digitWidth: 38px;
$digitHeight: 27px;
$digitLineHeight: 53px;
#counter {
user-select: none;
.counter-box {
width: 77px;
height: 77px;
position: relative;
margin: 0 2px;
&::before {
content: "";
background: url(img/number-bg.svg);
background-size: contain;
width: 100%;
height: 100%;
position: absolute;
left: 0;
top: 0;
opacity: 0.8;
}
.holder {
font-size: 34px;
color: white;
font-weight: 700;
line-height: 77px;
height: 100%;
width: 100%;
position: absolute;
box-sizing: border-box;
transform: translateZ(0);
will-change: transform;
text-shadow: none;
}
.holder.prev {
transform: translateY(100%);
opacity: 0;
}
&.anim {
.holder.active {
animation: counter-step-active 0.4s;
}
.holder.prev {
animation: counter-step-prev 0.4s;
}
}
}
// NOTE: This is $width-twocol from village
@media (max-width: 600px) {
.counter-box {
width: 65px;
height: 65px;
.holder {
line-height: 65px;
font-size: 28px;
}
}
}
h2 {
position: absolute;
bottom: 0;
left: 0;
right: 0;
text-align: center;
margin: 0 !important;
}
h2 {
font-size: 12px;
letter-spacing: 1px;
font-weight: 600;
color: #fff;
margin: 6px 0;
line-height: 12px;
text-transform: uppercase;
}
}
@keyframes counter-step-active {
0% { transform: translateY(50%); opacity: 0; }
100% { transform: translateY(0%); opacity: 1; }
}
@keyframes counter-step-prev {
0% { transform: translateY(0%); opacity: 1; }
100% { transform: translateY(-50%); opacity: 0; }
}