13. CSS Part 4 (Ans)
13. CSS Part 4 (Ans)
Practice Solutions
Answers
/* Qs1. Add a 2s transition on box1 for width changes.
It should have 'ease-in' speed curve & 0.5s delay */
#box1 {
width: 100px;
height: 100px;
background: green;
transition: width 2s ease-in 0.5s;
}
#box1:hover {
width: 600px;
}
#box2 {
width: 100px;
height: 100px;
background: red;
transform: translate(200px, 200px) rotate(90deg);
}
#box3 {
width: 100px;
height: 100px;
background: lightblue;
transform: skewX(20deg);
}
#box4 {
width: 100px;
height: 100px;
background: lightgreen;
box-shadow: 2px 2px 5px green;
}
#myPic {
width: 200px;
height: 200px;
background: pink;
background-image: url("picture.jpg");
background-size: cover;
opacity: 50%;
}
Our Telegram Channel: https://t.me/Delta_Apna_College_Web