-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathyes.css
More file actions
105 lines (105 loc) · 2.33 KB
/
yes.css
File metadata and controls
105 lines (105 loc) · 2.33 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
96
97
98
99
100
101
102
103
104
105
* {
margin: 0;
padding: 0;
box-sizing: border-box;
}
body {
min-height: 100vh;
display: grid;
place-items: center;
overflow: hidden;
font-family: sans-serif;
background-color: rgb(1, 1, 1);
background-image: linear-gradient (#ffe5e5);
color: white;
transition: background-color 500ms ease;
} /* header */
header {
position: absolute;
z-index: 999;
text-align: center;
top: 0rem;
text-decoration: aquamarine;
padding: 1rem;
background: inherit;
}
.container {
position: relative;
width: min(400px, 100%);
}
ul {
list-style: none;
width: 100%;
height: 80%;
position: relative;
perspective: 900px;
transform-style: preserve-3d;
}
ul > li {
position: absolute;
left: 50%;
top: calc(50% - 1.2rem);
--rotateX: calc(
1deg * var(--rotateDegrees) * calc(var(--day_idx) - var(--currentDay))
);
transform: rotateX(var(--rotateX)) translateZ(190px) translateX(-50%)
scale(var(--scale, 1));
--hue: calc(var(--rotateDegrees) * var(--day_idx));
background-color: hsl(var(--hue), 50%, var(--lightness, 50%));
width: 115%;
color: white;
display: grid;
grid-template-columns: 2.5rem auto;
height: 1.4rem;
transition: transform 900ms ease, background-color 900ms ease;
}
ul > li.active {
--lightness: 30%;
--scale: 1.1;
}
ul > li > * {
display: grid;
align-items: center;
}
li > time {
text-align: center;
}
li > span {
padding-inline-start: 0.5rem;
color: white;
} /* controls */
.controls {
position: absolute;
top: 50%;
left: 124%;
transform: translateY(-50%);
display: flex;
flex-direction: column;
gap: 0.125rem;
}
.controls button {
width: 1.5rem;
aspect-ratio: 1;
font-size: 1.5rem;
color: rgb(106, 245, 25);
border: none;
background: pink;
display: flex;
place-items: center;
}
.controls button:hover,
.controls button:focus {
background: red;
}
.controls button:active {
transform: scale(1.1);
}
.border {
width: 96%;
height: 3em;
border: 1px solid white;
position: absolute;
top: 50%;
left: 50%;
transform: translate(-50%, -50%);
}