css实现checkbox勾选对号动画效果代码
代码语言:html
所属分类:布局界面
代码描述:css实现checkbox勾选对号动画效果代码
下面为部分代码预览,完整代码请点击下载或在bfwstudio webide中打开
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width,initial-scale=1.0,maximum=1.0,minimum=1.0,user-scalable=0" />
<title>BFW NEW PAGE</title>
<style>
body{
background: black;
padding: 150px;
}
.checkbox-wrapper * {
-webkit-tap-highlight-color: transparent;
outline: none;
}
.checkbox-wrapper input[type="checkbox"] {
display: none;
}
.checkbox-wrapper label {
--size: 50px;
--shadow: calc(var(--size) * .07) calc(var(--size) * .1);
position: relative;
display: block;
width: var(--size);
height: var(--size);
margin: 0 auto;
background-color: #4158D0;
background-image: linear-gradient(43deg, #4158D0 0%, #C850C0 46%, #FFCC70 100%);
border-radius: 50%;
box-shadow: 0 var(--shadow) #ffbeb8;
cursor: pointer;
transition: 0.2s ease transform, 0.2s ease background-color,
0.2s ease box-shadow;
overflow: hidden;
z-index: 1;
}
.checkbox-wrapper label:before {
content: "";
position: absolute;
top: 50%;
right: 0;
left: 0;.........完整代码请登录后点击上方下载按钮下载查看
网友评论0