-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathxsplit-flap.css
More file actions
140 lines (124 loc) · 3.19 KB
/
xsplit-flap.css
File metadata and controls
140 lines (124 loc) · 3.19 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
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
:root {
--flapWidth: 40px;
--flapTextColor: #FFEB3B;
}
.splitflap {
position: relative;
min-width: var(--flapWidth);
height: calc(var(--flapWidth) * 1.5);
line-height: calc(var(--flapWidth) * 1.5 + var(--flapWidth)*0.1);
margin: 2px;
font-size: var(--flapWidth);
font-family: monospace;
text-align: center;
color: var(--flapTextColor, #FFEB3B);
}
.top {
position: relative;
height: 50%;
width: 100%;
background-color: #000000;
/*border-radius: 10px 10px 0 0;*/
border-top-left-radius: calc(var(--flapWidth)/5);
border-top-right-radius: calc(var(--flapWidth)/5);
border-bottom-left-radius: 0px;
border-bottom-right-radius: 0px;
border-bottom: 1px solid black;
overflow: hidden;
z-index: 0;
}
.bottom {
position: relative;
height: 100%;
width: 100%;
margin-top: -75%;
/* border-radius: 10px 10px 10px 10px; */
border-top-left-radius: calc(var(--flapWidth)/5);
border-top-right-radius: calc(var(--flapWidth)/5);
border-bottom-left-radius: calc(var(--flapWidth)/5);
border-bottom-right-radius: calc(var(--flapWidth)/5);
z-index: -1;
background-color: black;
background-image: linear-gradient(rgba(0, 0, 0, 0), #000000);
transform-origin: center;
}
.bottom:after {
content: "";
background-image: -webkit-linear-gradient(0deg, white 7%, black 7%, black 93%, white 93%, white 100%);
display: block;
height: 1px;
width: 100%;
position: absolute;
top: 50%;
}
.nextHalf {
position: relative;
height: 50%;
width: 100%;
margin-top: -150%;
overflow: hidden;
/* border-radius: 10px 10px 0 0; */
border-top-left-radius: calc(var(--flapWidth)/5);
border-top-right-radius: calc(var(--flapWidth)/5);
border-bottom-left-radius: 0px;
border-bottom-right-radius: 0px;
z-index: 2;
background-color: black;
background-image: linear-gradient(#000000, rgba(0, 0, 0, 0));
transform-origin: bottom;
}
.nextHalf:after {
content: "";
background-image: -webkit-linear-gradient(0deg, white 7%, black 7%, black 93%, white 93%, white 100%);
display: block;
height: 2px;
width: 100%;
position: absolute;
bottom: 0;
}
.nextFull {
position: relative;
height: 100%;
width: 100%;
background-color: #000000;
margin-top: -150%;
/* border-radius: 10px 10px 10px 10px; */
border-top-left-radius: calc(var(--flapWidth)/5);
border-top-right-radius: calc(var(--flapWidth)/5);
border-bottom-left-radius: calc(var(--flapWidth)/5);
border-bottom-right-radius: calc(var(--flapWidth)/5);
z-index: -3;
}
.flip1 {
animation: flip1 ease-in 1;
animation-duration: 1s;
}
.flip2 {
animation: flip2 ease-out 1;
animation-duration: 1s;
}
@keyframes flip1 {
0% {
transform: rotateX(0deg);
background-color: #000000;
}
50% {
transform: rotateX(90deg);
background-color: black;
}
100% {
transform: rotateX(90deg);
}
}
@keyframes flip2 {
0% {
transform: rotateX(-90deg);
}
50% {
transform: rotateX(-90deg);
}
100% {
transform: rotateX(0deg);
background-color: #000000;
}
}