layui实现背景粒子运动的登录页面效果代码
代码语言:html
所属分类:布局界面
代码描述:layui实现背景粒子运动的登录页面效果代码
下面为部分代码预览,完整代码请点击下载或在bfwstudio webide中打开
<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8" /> <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1" /> <meta http-equiv="X-UA-Compatible" content="ie=edge" /> <link type="text/css" rel="stylesheet" href="//repo.bfw.wiki/bfwrepo/js/layui/css/layui.css"> <style> html, body { height: 100%; } body { background-color: #f5f5f5; } .login-form { background-color: #fff; width: 320px; padding: 50px; position: relative; top: 50%; left: 50%; transform: translate(-50%, -50%); } .login-form .login-title { margin-bottom: 20px; text-align: center; } .login-form input { padding-left: 38px; } .login-form .layui-form-item .layui-icon { display: inline-block; height: 38px; width: 38px; line-height: 38px; text-align: center; position: absolute; } .login-form input[name="captcha"] { width: 195px; display: inline-block; margin-right: 1px; } #particles-js { width: 100%; height: 100%; position: absolute; top: 0; left: 0; overflow: hidden; } #captcha { width: 120px; height: 40px; } </style> </head> <body> <!-- 粒子背景 --> <div id="particles-js"></div> <!-- 登录表单 --> <form class="layui-form login-form layui-panel" autocomplete="off"> <h1 class="login-title"> <img style="height: 30px" src="//repo.bfw.wiki/bfwrepo/icon/5f7d03118a427.png" alt="logo" /> <span>用户登录</span> </h1> <!-- 用户名 --> <div class="layui-form-item"> <i class="layui-icon layui-icon-username"></i> <input type="text" name="username" placeholder="请输入用户名" class="layui-input" lay-verify="required&.........完整代码请登录后点击上方下载按钮下载查看
网友评论0