-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathtransition-transform.css
More file actions
52 lines (51 loc) · 999 Bytes
/
transition-transform.css
File metadata and controls
52 lines (51 loc) · 999 Bytes
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
* {
padding: 0;
margin: 0;
box-sizing: border-box;
}
body {
background-color: #0a0a0a;
color: white;
display: flex;
justify-content: space-evenly;
}
.transition-container {
padding: 10px;
display: flex;
justify-content: center;
align-items: center;
height: 100vh;
gap: 10px;
}
.transition-container .box {
background-color: yellowgreen;
height: 150px;
width: 150px;
transition-property: all;
transition-duration: 2s;
}
.transition-container .box:hover {
/* background-color: red; */
width: 300px;
height: 300px;
}
.transform-container {
height: 100vh;
display: flex;
justify-content: center;
align-items: center;
padding: 10px;
gap: 10px;
}
.transform-container .box {
background-color: coral;
height: 100px;
width: 100px;
/* rotate: 50deg; */
transition: transform 3s ease-in-out;
}
.transform-container .box:hover {
/* transform: translate(50px) rotate(45deg) scale(1.5); */
/* translate: 10px 20px; */
transform: scale(3);
}