Home >Web Front-end >HTML Tutorial >按钮效果 css_html/css_WEB-ITnose

按钮效果 css_html/css_WEB-ITnose

WBOY
WBOYOriginal
2016-06-24 11:20:561056browse

<!doctype html><br /><html lang="en"><br /><head><br />    <meta charset="UTF-8"><br />    <title>Document</title><br />    <style><br />        .toggle > div {<br />            width: 100px;<br />            height: 40px;<br />            border-radius: 20px;<br />            background: #fff;<br />            position: relative;<br />            border: solid 2px #e6e6e6;<br />            transition: all ease-in-out 0.25s 0s;<br />            display: inline-block;<br />        }<br /><br />        .toggle > div div {<br />            position: absolute;<br />            top: 0;<br />            left: 0;<br />            height: 40px;<br />            width: 40px;<br />            border-radius: 50%;<br />            box-shadow: 0 2px 7px rgba(0, 0, 0, 0.35), 0 1px 1px rgba(0, 0, 0, 0.15);<br />            transition: all ease-in-out 0.25s 0s;<br />        }<br /><br />        .clearfix:after {<br />            clear: both;<br />            font-size: 0;<br />            height: 0;<br />            display: block;<br />            visibility: hidden;<br />            content: " ";<br />            line-height: 0<br />        }<br /><br />        .clearfix {<br />            zoom: 1<br />        }<br /><br />        /* for IE6 IE7 */<br />        .toggle input:checked + .ss {<br />            background: #4cd964;<br />            border-color: #4cd964;<br />        }<br /><br />        .toggle input:checked + .ss div {<br />            transform: translate3d(60px, 0, 0);<br />            background-color: #fff;<br />        }<br />    </style><br /></head><br /><body><br /><label class="toggle "><br />    <input type="checkbox" checked style="display: none"><br /><br />    <div class="ss"><br />        <div></div><br />    </div><br /></label><br /><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /><div></div><br /></body><br /></html>

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn