html5设置密码查看,HTML5一款密码强度校验和明文切换输入控件

CSS

语言:

CSSSCSS

确定

html {

box-sizing: border-box;

font-size: 62.5%;

}

* {

padding: 0;

margin: 0;

-webkit-font-smoothing: antialiased;

-moz-osx-font-smoothing: grayscale;

box-sizing: inherit;

}

*::after,

*::before {

box-sizing: inherit;

}

.bg-transparent {

background-color: transparent !important;

}

.bg-red {

background-color: #e74c3c !important;

}

.bg-orange {

background-color: #e67e22 !important;

}

.bg-green {

background-color: #2ecc71 !important;

}

body .password-wrapper {

position: absolute;

top: 50%;

left: 50%;

transform: translate(-50%, -50%);

}

body {

background-color: #3498db;

}

body .password-wrapper {

width: 80%;

max-width: 320px;

border-radius: 5px;

background-color: #fff;

overflow: hidden;

}

body .password-wrapper .input {

border: none;

padding: 10px 15px;

font: small-caption;

font-size: 18px;

font-size: 1.8rem;

width: calc(100% - 50px);

color: #34495e;

outline: none;

line-height: 1.5;

}

body .password-wrapper .icon-wrapper {

position: relative;

display: inline;

float: right;

width: 50px;

height: 50px;

background-color: #34495e;

transition: background-color 0.25s ease-out;

cursor: pointer;

}

body .password-wrapper .icon-wrapper .ion-eye,

body .password-wrapper .icon-wrapper .ion-more {

font-size: 26px;

font-size: 2.6rem;

position: absolute;

top: 11px;

right: 12px;

color: #ccc;

transition: color 0.25s ease-out;

}

body .password-wrapper .icon-wrapper .ion-more {

right: 14px;

}

body .password-wrapper .icon-wrapper:hover {

transition: background-color 0.25s ease-out;

background-color: #2c3e50;

}

body .password-wrapper .icon-wrapper:hover .ion-eye,

body .password-wrapper .icon-wrapper:hover .ion-more {

color: #3498db;

transition: color 0.25s ease-in;

}

body .password-wrapper .strength-lines {

position: absolute;

bottom: 2px;

left: 0;

right: 0;

width: calc(100% - 50px);

height: 6px;

z-index: 3;

}

body .password-wrapper .strength-lines .line {

position: absolute;

background-color: transparent;

height: 6px;

border-radius: 2px;

transition: background-color 0.25s ease-in;

}

body .password-wrapper .strength-lines .line:not(:first-of-type):not(:last-of-type) {

left: 33%;

right: 33%;

}

body .password-wrapper .strength-lines .line:first-of-type {

left: 4px;

right: 68%;

}

body .password-wrapper .strength-lines .line:last-of-type {

left: 68%;

right: 4px;

}

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

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值