ant-design-vue/components/input-number/style/index.less

169 lines
3.4 KiB
Plaintext
Raw Normal View History

2019-01-02 13:01:56 +00:00
@import '../../style/themes/default';
@import '../../style/mixins/index';
@import '../../input/style/mixin';
2018-04-04 05:57:23 +00:00
2019-01-02 13:01:56 +00:00
@input-number-prefix-cls: ~'@{ant-prefix}-input-number';
2018-04-04 05:57:23 +00:00
.@{input-number-prefix-cls} {
.reset-component;
.input;
2019-03-30 08:06:06 +00:00
display: inline-block;
width: 90px;
2018-04-04 05:57:23 +00:00
margin: 0;
padding: 0;
border: @border-width-base @border-style-base @border-color-base;
border-radius: @border-radius-base;
&-handler {
position: relative;
display: block;
width: 100%;
2019-03-30 08:06:06 +00:00
height: 50%;
overflow: hidden;
color: @text-color-secondary;
2018-04-04 05:57:23 +00:00
font-weight: bold;
2019-03-30 08:06:06 +00:00
line-height: 0;
text-align: center;
transition: all 0.1s linear;
2018-04-04 05:57:23 +00:00
&:active {
2019-03-30 08:06:06 +00:00
background: @input-number-handler-active-bg;
2018-04-04 05:57:23 +00:00
}
&:hover &-up-inner,
&:hover &-down-inner {
color: @primary-5;
}
}
&-handler-up-inner,
&-handler-down-inner {
.iconfont-mixin();
position: absolute;
2019-03-30 08:06:06 +00:00
right: 4px;
2018-04-04 05:57:23 +00:00
width: 12px;
height: 12px;
color: @text-color-secondary;
2019-03-30 08:06:06 +00:00
line-height: 12px;
transition: all 0.1s linear;
user-select: none;
2018-04-04 05:57:23 +00:00
}
&:hover {
.hover();
}
&-focused {
.active();
}
&-disabled {
.disabled();
.@{input-number-prefix-cls}-input {
cursor: not-allowed;
}
.@{input-number-prefix-cls}-handler-wrap {
display: none;
}
}
&-input {
width: 100%;
height: @input-height-base - 2px;
2019-03-30 08:06:06 +00:00
padding: 0 @control-padding-horizontal - 1px;
text-align: left;
update to antd3.8.3 (#159) * refactor: align * feat: update align to 2.4.3 * feat: update trigger 2.5.4 * feat: update tooltip 3.7.2 * fix: align * feat: update vc-calendar to 9.6.2 * feat: update vc-checkbox to 2.1.5 * feat: update vc-dialog to 7.1.8 * feat: update vc-from to 2.2.1 * feat: update vc-notification to 3.1.1 * test: update snapshots * feat: update vc-tree to 1.12.6 * feat: update vc-table to 6.2.8 * feat: update vc-upload to 2.5.1 * feat: update vc-input-number to 4.0.12 * feat: update vc-tabs to 9.2.6 * refactor: vc-menu * refactor: update vc-menu to 7.0.5 * style: remove unused * feat: update pagination to 1.16.5 * feat: add vc-progress 2.2.5 tag * feat: add vc-rate 2.4.0 tag * feat: update vc-slider to 8.6.1 * fix: tooltip error * style: delete conosle * feat: update vc-steps to 3.1.1 * add vc-switch tag 1.6.0 * feat: update upload to 2.5.1 * fix: update vc-menu * fix: update store * fix: add ref dir * fix: trigger mock shouldComponentUpdate * fix: update vc-select * revert: trigger lazyrenderbox * fix: update vc-select * fix: update vc-select * fix: update vc-select * fix: update vc-menu * fix: update vc-slick ref * update style to 3.8.2 * test: update snapshots * update vc-select * update util & affix * feat: add drawer * fix: support title add slot mode * test: update affix test * update alert * update anchor * update snapshots * fix: doc and vc-drawer * update select & auto-complete * update back-top & grid * feractor: avatar * test: add drawer test * update badge * update button * update card * update divider * feat: update vc-tabs to 9.3.6 and tabs * add afterEnter callback * update form * fix: update drawer * test: update snapshots * update modal & notification * test: update snapshots * update message * update locale-provider * update dropdown * update layout popconfirm popover * update time-picker * update menu * update date-picker * docs: update input docs * update input * update snapshots * update table * update test snapshots * feat: update progress * update checkbox * feat: update spin * update radio * docs: slider steps timeline * update list * update transfer * update collapse * update cascader * update upload
2018-09-05 13:28:54 +00:00
background-color: transparent;
2018-04-04 05:57:23 +00:00
border: 0;
border-radius: @border-radius-base;
2019-03-30 08:06:06 +00:00
outline: 0;
transition: all 0.3s linear;
-moz-appearance: textfield;
2018-04-04 05:57:23 +00:00
.placeholder();
}
&-lg {
padding: 0;
font-size: @font-size-lg;
input {
height: @input-height-lg - 2px;
}
}
&-sm {
padding: 0;
input {
height: @input-height-sm - 2px;
padding: 0 @control-padding-horizontal-sm - 1px;
}
}
&-handler-wrap {
position: absolute;
top: 0;
right: 0;
2019-03-30 08:06:06 +00:00
width: 22px;
height: 100%;
background: @component-background;
border-left: @border-width-base @border-style-base @border-color-base;
2018-04-04 05:57:23 +00:00
border-radius: 0 @border-radius-base @border-radius-base 0;
2019-03-30 08:06:06 +00:00
opacity: 0;
2018-04-04 05:57:23 +00:00
transition: opacity 0.24s linear 0.1s;
2019-03-30 08:06:06 +00:00
// Fix input number inside Menu makes icon too large
// We arise the selector priority by nest selector here
// https://github.com/ant-design/ant-design/issues/14367
.@{input-number-prefix-cls}-handler {
.@{input-number-prefix-cls}-handler-up-inner,
.@{input-number-prefix-cls}-handler-down-inner {
.iconfont-size-under-12px(7px);
min-width: auto;
margin-right: 0;
}
}
2018-04-04 05:57:23 +00:00
}
&-handler-wrap:hover &-handler {
height: 40%;
}
&:hover &-handler-wrap {
opacity: 1;
}
&-handler-up {
cursor: pointer;
&-inner {
top: 50%;
2018-09-16 13:36:22 +00:00
margin-top: -5px;
2018-11-14 13:33:56 +00:00
text-align: center;
2018-04-04 05:57:23 +00:00
}
&:hover {
height: 60% !important;
}
}
&-handler-down {
2018-09-16 13:36:22 +00:00
top: 0;
2019-03-30 08:06:06 +00:00
border-top: @border-width-base @border-style-base @border-color-base;
2018-04-04 05:57:23 +00:00
cursor: pointer;
&-inner {
top: 50%;
margin-top: -6px;
2018-11-14 13:33:56 +00:00
text-align: center;
2018-04-04 05:57:23 +00:00
}
&:hover {
height: 60% !important;
}
}
&-handler-up-disabled,
&-handler-down-disabled {
cursor: not-allowed;
}
&-handler-up-disabled:hover &-handler-up-inner,
&-handler-down-disabled:hover &-handler-down-inner {
color: @disabled-color;
}
}