简单实现前端浏览器背景互动效果
不多说-直接上代码
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<title>无标题文档</title>
</head>
<body>
// Mouse X Position:
<input id="xxx" type="text" />
<br>
// Mouse Y Position:
<input id="yyy" type="text" />
<div data-v-4a3c9f12="" id="sss" class="ball-1" style="transform: translate(4.12131px, 7.35076px);position:absolute;left: 20px;bottom: 320px;border:1px solid #000;width:30px;height:30px;">
<img data-v-4a3c9f12="" src="">
</div>
<script>
funct