重置input checked

<!--
作者:duke
时间:2018-10-24
描述: 重置input 样式
-->

<!DOCTYPE HTML>
<html>

<head>
<meta charset="utf-8">
<title>table</title>
</head>
<style>
input[disabled='disabled'] {
-webkit-appearance: none;
padding: 0;
margin: 0;
border: 0;
width: 16px;
height: 16px;
padding: 10px 0;
background: red;
position: relative;
margin-left: 300px;
}

input[disabled='disabled']:after {
content: "";
width: 1px;
height: 21px;
position: absolute;
background: #000;
transform: rotateZ(41deg);
left: 8px;
top: 0;
}

input[disabled='disabled']:before {
content: "";
width: 1px;
height: 21px;
position: absolute;
background: #000;
transform: rotateZ(-41deg);
left: 8px;
top: 0;
}
/*input:checked {

-webkit-appearance: none;
outline: none;
padding: 0;
margin: 0;
border: 0;
width: 16px;
height: 16px;
padding: 10px 0;
background: red;
position: relative;

}*/

input:checked:after {
content: "";
position: absolute;
left: 6px;
width: 3px;
height: 11px;
top: 3px;
border-bottom: 2px solid #fff;
border-right: 2px solid #fff;
transform: rotateZ(41deg);
}

input[type='checkbox'] {
-webkit-appearance: none;
outline: none;
padding: 0;
margin: 0;
border: 0;
width: 16px;
height: 16px;
padding: 10px 0;
background: red;
position: relative;
}
</style>

<body>

<input type="checkbox" disabled="disabled" />
<input type="checkbox" />

</body>

</html>

转载于:https://www.cnblogs.com/duke-peng/p/9843357.html

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值