Signup/Sign In
Ask Question
Not satisfied by the Answer? Still looking for a better solution?

Level 13 Lesson 6 Css

<!DOCTYPE html>
<html>
<head>
<title>transform-style Example</title>
<style>
.parent{
position: relative;
height: 200px;
width: 200px;
margin: 100px;
padding: 10px;
border: 1px solid black;
background-color: pink;

}

.child1 {
padding: 60px;
position: absolute;
border: 1px solid black;
background-color: aqua;
transform: rotateY(60deg);
}

.child2 {
padding: 50px;
position: absolute;
border: 1px solid black;
background-color: purple;
transform: rotateZ(-60deg);
}
</style>
</head>
<body>
<div class="parent">
<div class="child1"></div>
<div class="child2"></div>
</div>
</body>
</html>
by

3 Answers

mohamadmahdi
<!DOCTYPE html>
<html>
<head>
<title>transform-style Example</title>
<style>
.parent{
position: relative;
height: 200px;
width: 200px;
margin: 100px;
padding: 10px;
border: 1px solid black;
background-color: pink;
transform-style: preserve-3d;
}

.child1 {
padding: 60px;
position: absolute;
border: 1px solid black;
background-color: aqua;
transform: rotateY(60deg);
}

.child2 {
padding: 50px;
position: absolute;
border: 1px solid black;
background-color: purple;
transform: rotateZ(-60deg);
}
</style>
</head>
<body>
<div class="parent">
<div class="child1"></div>
<div class="child2"></div>
</div>
</body>
</html>
iamabhishek
Have you solved this lesson or you still need help?
mohamadmahdi
i solved it thanks

Login / Signup to Answer the Question.