移动端顺序问题上

2020-10-28 10:30:16 浏览数 (1)

代码语言:javascript复制
<!DOCTYPE html>
<html lang="en">
<head>
	<meta charset="UTF-8">
	<meta name="viewport" content="width=device-width, initial-scale=1.0">
	<title>Document</title>
	<style type="text/css">
		*{margin: 0;padding:0;list-style: none;}
#div1,#div2,#div3{width: 200px;height: 200px;background: black;float: left;
	transition:1s;
	position: absolute;left: 50%;top: 50%;margin: -100px 0 0 -100px;
	transform:perspective(800px);
	

}
#div2
{
	transform: translateX(150px) rotate(150deg);background: green;
}
#div3
{
	transform:rotate(60deg) translateX(150px);background: red;
}
/*transform从后往前执行*/
	</style>

</head>
<body>
	<div id='div1'>
	
</div>
<div id='div2'></div>
<div id='div3'></div>
</body>
</html>

0 人点赞