assignment a4
This commit is contained in:
35
practices/24-10-29/css/index.css
Normal file
35
practices/24-10-29/css/index.css
Normal file
@@ -0,0 +1,35 @@
|
||||
@import 'shared.css';
|
||||
|
||||
html,
|
||||
body {
|
||||
height: 100%;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
body {
|
||||
position: relative;
|
||||
}
|
||||
|
||||
div {
|
||||
height: 128px;
|
||||
width: 128px;
|
||||
background-color: red;
|
||||
|
||||
position: absolute;
|
||||
top: calc(50% - 64px);
|
||||
left: calc(50% - 64px);
|
||||
|
||||
&:hover,
|
||||
&:focus {
|
||||
animation: move 10s ease-in-out both;
|
||||
}
|
||||
}
|
||||
|
||||
@keyframes move {
|
||||
0% {
|
||||
}
|
||||
100% {
|
||||
top: 0;
|
||||
left: 0;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user