Browse Source

add unit `px` to all less value, make them explicit

pull/6860/head
neekey 7 years ago
parent
commit
7e522291c8
  1. 4
      components/auto-complete/style/index.less
  2. 4
      components/button/style/mixin.less
  3. 4
      components/input/style/mixin.less
  4. 2
      components/input/style/search-input.less
  5. 4
      components/radio/style/index.less
  6. 2
      components/slider/style/index.less
  7. 12
      components/spin/style/index.less
  8. 14
      components/style/themes/default.less

4
components/auto-complete/style/index.less

@ -19,8 +19,8 @@
line-height: @input-height-base;
}
&__placeholder {
margin-left: (@input-padding-horizontal + 1);
margin-right: (@input-padding-horizontal + 1);
margin-left: (@input-padding-horizontal + 1px);
margin-right: (@input-padding-horizontal + 1px);
}
}
}

4
components/button/style/mixin.less

@ -224,11 +224,11 @@
// circle button: the content only contains icon
.btn-circle(@btnClassName: btn) {
.square(@btn-circle-size);
.button-size(@btn-circle-size; 0; @font-size-base + 2; 50%);
.button-size(@btn-circle-size; 0; @font-size-base + 2px; 50%);
&.@{btnClassName}-lg {
.square(@btn-circle-size-lg);
.button-size(@btn-circle-size-lg; 0; @btn-font-size-lg + 2; 50%);
.button-size(@btn-circle-size-lg; 0; @btn-font-size-lg + 2px; 50%);
}
&.@{btnClassName}-sm {

4
components/input/style/mixin.less

@ -1,7 +1,7 @@
@import "../../style/themes/default";
@import "../../style/mixins/index";
@input-affix-width: 17;
@input-affix-width: 17px;
// size mixins for input
.input-lg() {
@ -148,7 +148,7 @@
// Reset Select's style in addon
.@{ant-prefix}-select {
margin: -(@input-padding-vertical-base + 1) (-@input-padding-horizontal); // lesshint spaceAroundOperator: false
margin: -(@input-padding-vertical-base + 1px) (-@input-padding-horizontal); // lesshint spaceAroundOperator: false
.@{ant-prefix}-select-selection {
background-color: inherit;

2
components/input/style/search-input.less

@ -35,7 +35,7 @@
.@{ant-prefix}-search-btn {
.btn-default;
border-radius: 0 @border-radius-base - 1 @border-radius-base - 1 0;
border-radius: 0 @border-radius-base - 1px @border-radius-base - 1px 0;
left: -1px;
position: relative;
border-width: 0 0 0 1px;

4
components/radio/style/index.less

@ -136,7 +136,7 @@ span.@{radio-prefix-cls} + * {
.@{radio-prefix-cls}-button-wrapper {
margin: 0;
height: @input-height-base;
line-height: @input-height-base - 2;
line-height: @input-height-base - 2px;
color: @radio-button-color;
display: inline-block;
transition: all 0.3s ease;
@ -165,7 +165,7 @@ span.@{radio-prefix-cls} + * {
.@{radio-group-prefix-cls}-small & {
height: @input-height-sm;
line-height: @input-height-sm - 2;
line-height: @input-height-sm - 2px;
padding: 0 12px;
&:first-child {
border-radius: @border-radius-sm 0 0 @border-radius-sm;

2
components/slider/style/index.less

@ -8,7 +8,7 @@
@slider-tooltip-color: #fff;
@slider-tooltip-bg: tint(@text-color, 4%);
@slider-tooltip-arrow-width: 4px;
@slider-tooltip-distance: @slider-tooltip-arrow-width + 4;
@slider-tooltip-distance: @slider-tooltip-arrow-width + 4px;
@slider-tooltip-arrow-color: @slider-tooltip-bg;
.@{slider-prefix-cls} {

12
components/spin/style/index.less

@ -41,10 +41,10 @@
position: absolute;
top: 50%;
width: 100%;
padding-top: (@spin-dot-size - @font-size-base) / 2 + 2;
padding-top: (@spin-dot-size - @font-size-base) / 2 + 2px;
}
&.@{spin-prefix-cls}-show-text .@{spin-prefix-cls}-dot {
margin-top: -@spin-dot-size / 2 - 10;
margin-top: -@spin-dot-size / 2 - 10px;
}
}
@ -53,10 +53,10 @@
margin: -@spin-dot-size-sm / 2;
}
.@{spin-prefix-cls}-text {
padding-top: (@spin-dot-size-sm - @font-size-base) / 2 + 2;
padding-top: (@spin-dot-size-sm - @font-size-base) / 2 + 2px;
}
&.@{spin-prefix-cls}-show-text .@{spin-prefix-cls}-dot {
margin-top: -@spin-dot-size-sm / 2 - 10;
margin-top: -@spin-dot-size-sm / 2 - 10px;
}
}
@ -65,10 +65,10 @@
margin: -@spin-dot-size-lg / 2;
}
.@{spin-prefix-cls}-text {
padding-top: (@spin-dot-size-lg - @font-size-base) / 2 + 2;
padding-top: (@spin-dot-size-lg - @font-size-base) / 2 + 2px;
}
&.@{spin-prefix-cls}-show-text .@{spin-prefix-cls}-dot {
margin-top: -@spin-dot-size-lg / 2 - 10;
margin-top: -@spin-dot-size-lg / 2 - 10px;
}
}
}

14
components/style/themes/default.less

@ -172,10 +172,10 @@
@screen-xl-min : @screen-xl;
// provide a maximum
@screen-xs-max : (@screen-sm-min - 1);
@screen-sm-max : (@screen-md-min - 1);
@screen-md-max : (@screen-lg-min - 1);
@screen-lg-max : (@screen-xl-min - 1);
@screen-xs-max : (@screen-sm-min - 1px);
@screen-sm-max : (@screen-md-min - 1px);
@screen-md-max : (@screen-lg-min - 1px);
@screen-lg-max : (@screen-xl-min - 1px);
// Grid system
@grid-columns : 24;
@ -244,7 +244,7 @@
//** Tooltip arrow width
@tooltip-arrow-width: 5px;
//** Tooltip distance with trigger
@tooltip-distance: @tooltip-arrow-width - 1 + 4;
@tooltip-distance: @tooltip-arrow-width - 1px + 4px;
//** Tooltip arrow color
@tooltip-arrow-color: @tooltip-bg;
@ -261,11 +261,11 @@
//** Popover arrow color
@popover-arrow-color: @popover-bg;
//** Popover outer arrow width
@popover-arrow-outer-width: (@popover-arrow-width + 1);
@popover-arrow-outer-width: (@popover-arrow-width + 1px);
//** Popover outer arrow color
@popover-arrow-outer-color: fadeout(@border-color-base, 30%);
//** Popover distance with trigger
@popover-distance: @popover-arrow-width + 4;
@popover-distance: @popover-arrow-width + 4px;
// Modal
// --

Loading…
Cancel
Save