zoukankan      html  css  js  c++  java
  • 自定义input[type="checkbox"]样式

    input[type=checkbox] {
    visibility: hidden;
    position: relative;
    }

    input[type=checkbox]:after {
    content: "";
    display: block;
    position: absolute;
    18px;
    height: 18px;
    visibility: visible;
    box-sizing: border-box;
    border-radius: 18px;
    background: #CBCED1;
    }
    input[type=checkbox]:checked::after{
    background: #2882DD;
    }
    input[type=checkbox]:checked::before {
    content: "";
    display: block;
    position: absolute;
    left: 4px;
    top: 4px;
    10px;
    height: 6px;
    border: 2px solid #fff;
    border-top-color: transparent;
    border-right-color: transparent;
    -ms-transform: rotate(-60deg);
    -moz-transform: rotate(-60deg);
    -webkit-transform: rotate(-60deg);
    transform: rotate(-45deg);
    visibility: visible;
    z-index: 1;
    box-sizing: border-box;
    }
    input[type=checkbox]:before {
    content: "";
    display: block;
    position: absolute;
    left: 4px;
    top: 4px;
    10px;
    height: 6px;
    border: 2px solid #fff;
    border-top-color: transparent;
    border-right-color: transparent;
    -ms-transform: rotate(-60deg);
    -moz-transform: rotate(-60deg);
    -webkit-transform: rotate(-60deg);
    transform: rotate(-45deg);
    visibility: visible;
    z-index: 1;
    box-sizing: border-box;
    }

    
    

    
    
  • 相关阅读:
    欢迎使用CSDN-markdown编辑器
    欢迎使用CSDN-markdown编辑器
    Math类简介
    Math类简介
    http_server
    tcp服务器
    swoole安装
    laravel源码解析
    VMware的Unity模式
    string.format() %d越界的问题
  • 原文地址:https://www.cnblogs.com/mumusen/p/9361298.html
Copyright © 2011-2022 走看看