antd
Version:
An enterprise-class UI design language and React-based implementation
260 lines (259 loc) • 6.18 kB
CSS
/* stylelint-disable at-rule-empty-line-before,at-rule-name-space-after,at-rule-no-unknown */
/* stylelint-disable declaration-bang-space-before */
/* stylelint-disable declaration-bang-space-before */
.ant-input-number {
position: relative;
padding: 4px 7px;
width: 100%;
line-height: 1.5;
color: rgba(0, 0, 0, 0.65);
background-color: #fff;
background-image: none;
transition: all .3s;
margin: 0;
padding: 0;
font-size: 12px;
height: 28px;
display: inline-block;
border: 1px solid #d9d9d9;
border-radius: 4px;
width: 80px;
}
.ant-input-number::-moz-placeholder {
color: #bfbfbf;
opacity: 1;
}
.ant-input-number:-ms-input-placeholder {
color: #bfbfbf;
}
.ant-input-number::-webkit-input-placeholder {
color: #bfbfbf;
}
.ant-input-number:hover {
border-color: #49a9ee;
}
.ant-input-number:focus {
border-color: #49a9ee;
outline: 0;
box-shadow: 0 0 0 2px rgba(16, 142, 233, 0.2);
}
.ant-input-number-disabled {
background-color: #f7f7f7;
opacity: 1;
cursor: not-allowed;
color: rgba(0, 0, 0, 0.25);
}
.ant-input-number-disabled:hover {
border-color: #e2e2e2;
}
textarea.ant-input-number {
max-width: 100%;
height: auto;
vertical-align: bottom;
transition: all .3s, height 0s;
}
.ant-input-number-lg {
padding: 6px 7px;
height: 32px;
}
.ant-input-number-sm {
padding: 1px 7px;
height: 22px;
}
.ant-input-number-handler {
text-align: center;
line-height: 0;
height: 50%;
overflow: hidden;
color: rgba(0, 0, 0, 0.43);
position: relative;
transition: all 0.1s linear;
display: block;
width: 100%;
font-weight: bold;
}
.ant-input-number-handler:active {
background: #f4f4f4;
}
.ant-input-number-handler:hover .ant-input-number-handler-up-inner,
.ant-input-number-handler:hover .ant-input-number-handler-down-inner {
color: #49a9ee;
}
.ant-input-number-handler-up-inner,
.ant-input-number-handler-down-inner {
font-style: normal;
vertical-align: baseline;
text-align: center;
text-transform: none;
line-height: 1;
text-rendering: optimizeLegibility;
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
line-height: 12px;
-webkit-user-select: none;
-moz-user-select: none;
-ms-user-select: none;
user-select: none;
position: absolute;
width: 12px;
height: 12px;
transition: all 0.1s linear;
display: inline-block;
font-size: 12px;
font-size: 7px \9;
-ms-transform: scale(0.58333333) rotate(0deg);
transform: scale(0.58333333) rotate(0deg);
/* IE6-IE8 */
-ms-filter: "progid:DXImageTransform.Microsoft.Matrix(sizingMethod='auto expand', M11=1, M12=0, M21=0, M22=1)";
zoom: 1;
right: 4px;
color: rgba(0, 0, 0, 0.43);
}
.ant-input-number-handler-up-inner:before,
.ant-input-number-handler-down-inner:before {
display: block;
font-family: "anticon" ;
}
:root .ant-input-number-handler-up-inner,
:root .ant-input-number-handler-down-inner {
-webkit-filter: none;
filter: none;
}
:root .ant-input-number-handler-up-inner,
:root .ant-input-number-handler-down-inner {
font-size: 12px;
}
.ant-input-number:hover {
border-color: #49a9ee;
}
.ant-input-number-focused {
border-color: #49a9ee;
outline: 0;
box-shadow: 0 0 0 2px rgba(16, 142, 233, 0.2);
}
.ant-input-number-disabled {
background-color: #f7f7f7;
opacity: 1;
cursor: not-allowed;
color: rgba(0, 0, 0, 0.25);
}
.ant-input-number-disabled:hover {
border-color: #e2e2e2;
}
.ant-input-number-input {
width: 100%;
text-align: left;
outline: 0;
-moz-appearance: textfield;
height: 26px;
transition: all 0.3s linear;
color: rgba(0, 0, 0, 0.65);
background-color: #fff;
border: 0;
border-radius: 4px;
padding: 0 7px;
display: block;
}
.ant-input-number-input::-moz-placeholder {
color: #bfbfbf;
opacity: 1;
}
.ant-input-number-input:-ms-input-placeholder {
color: #bfbfbf;
}
.ant-input-number-input::-webkit-input-placeholder {
color: #bfbfbf;
}
.ant-input-number-input[disabled] {
background-color: #f7f7f7;
opacity: 1;
cursor: not-allowed;
color: rgba(0, 0, 0, 0.25);
}
.ant-input-number-input[disabled]:hover {
border-color: #e2e2e2;
}
.ant-input-number-lg {
padding: 0;
}
.ant-input-number-lg input {
height: 30px;
}
.ant-input-number-sm {
padding: 0;
}
.ant-input-number-sm input {
height: 20px;
}
.ant-input-number-handler-wrap {
border-left: 1px solid #d9d9d9;
width: 22px;
height: 100%;
background: #fff;
position: absolute;
top: 0;
right: 0;
opacity: 0;
border-radius: 0 4px 4px 0;
transition: opacity 0.24s linear 0.1s;
z-index: 2;
}
.ant-input-number-handler-wrap:hover .ant-input-number-handler {
height: 40%;
}
.ant-input-number:hover .ant-input-number-handler-wrap {
opacity: 1;
}
.ant-input-number-handler-up {
cursor: pointer;
}
.ant-input-number-handler-up-inner {
top: 50%;
margin-top: -6px;
}
.ant-input-number-handler-up-inner:before {
text-align: center;
content: "\e61e";
}
.ant-input-number-handler-up:hover {
height: 60% ;
}
.ant-input-number-handler-down {
border-top: 1px solid #d9d9d9;
top: -1px;
cursor: pointer;
}
.ant-input-number-handler-down-inner {
top: 50%;
margin-top: -6px;
}
.ant-input-number-handler-down-inner:before {
text-align: center;
content: "\e61d";
}
.ant-input-number-handler-down:hover {
height: 60% ;
}
.ant-input-number-handler-down-disabled .ant-input-number-handler-down-inner,
.ant-input-number-handler-up-disabled .ant-input-number-handler-down-inner,
.ant-input-number-disabled .ant-input-number-handler-down-inner,
.ant-input-number-handler-down-disabled .ant-input-number-handler-up-inner,
.ant-input-number-handler-up-disabled .ant-input-number-handler-up-inner,
.ant-input-number-disabled .ant-input-number-handler-up-inner {
opacity: 0.72;
color: #ccc ;
cursor: not-allowed;
}
.ant-input-number-disabled .ant-input-number-input {
opacity: 0.72;
cursor: not-allowed;
background-color: #f7f7f7;
}
.ant-input-number-disabled .ant-input-number-handler-wrap {
display: none;
}
.ant-input-number-disabled .ant-input-number-handler {
opacity: 0.72;
color: #ccc ;
cursor: not-allowed;
}