在线预览 源码下载
实现html代码:
css3代码:
form { width: 100vw; height: 100vh; display: flex; flex-flow: column wrap; justify-content: center; align-items: center; } form .frame { display: flex; flex-flow: row nowrap; } form .frame input { display: none; } form .frame label { cursor: pointer; position: relative; width: 30px; height: 30px; margin: 10px; background: #8ABA56; transition: all 0.3s ease-in-out; font-size: 12pt; color: #FFF; -webkit-font-smoothing: antialiased; } form .frame label.radio { border-radius: 100%; } form .frame label.check { border-radius: 5px; } form .frame label .fa { position: absolute; top: 0; left: 0; right: 0; bottom: 0; opacity: 0; -webkit-transform: scale(0); transition: all 0.3s ease-in-out; line-height: 30px; text-align: center; } form .frame input:checked + label { background: #678b40; } form .frame input:checked + label .fa { opacity: 1; -webkit-transform: scale(1); } 好了。复制上面的html代码和css代码。轻松搞定一款漂亮的checkbox、radio按钮
Copyright © 2019- iias.cn 版权所有
违法及侵权请联系:TEL:199 18 7713 E-MAIL:2724546146@qq.com
本站由北京市万商天勤律师事务所王兴未律师提供法律服务