Skip to content

Commit

Permalink
fix(core): tui-slider-ticks-labels error `Operation on an invalid t…
Browse files Browse the repository at this point in the history
…ype`
  • Loading branch information
nsbarsukov committed May 16, 2022
1 parent c3593a2 commit 31fce51
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 9 deletions.
2 changes: 1 addition & 1 deletion projects/core/styles/mixins/slider.less
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
};

.tui-slider-ticks-labels(@input-size: m) {
@first-tick-center: @thumb-diameters[ @@input-size] / 2;
@first-tick-center: (@thumb-diameters[ @@input-size] / 2);
display: flex;
margin: 0 @first-tick-center;
font: var(--tui-font-text-s);
Expand Down
14 changes: 7 additions & 7 deletions projects/kit/components/range/range.style.less
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@

.track(@thumb-width) {
position: relative;
margin: 0 @thumb-width / 2;
margin: 0 (@thumb-width / 2);
height: 100%;

/* Filled selected range */
Expand All @@ -46,7 +46,7 @@
right: var(--right);
height: 100%;
background: var(--tui-primary);
margin: 0 -@thumb-width / 2;
margin: 0 (-@thumb-width / 2);
}
}

Expand Down Expand Up @@ -102,7 +102,7 @@
.ignore-track-pointer-events();
.remove-track-background();
position: absolute;
top: @track-height / 2;
top: (@track-height / 2);
left: 0;
right: 0;
z-index: 1;
Expand Down Expand Up @@ -135,12 +135,12 @@

:host[data-size='s'] & {
.tui-slider-ticks-labels(s);
padding: 0 @thumb-diameters[ @s] / 2;
padding: 0 (@thumb-diameters[ @s] / 2);
}

:host[data-size='m'] & {
.tui-slider-ticks-labels(m);
padding: 0 @thumb-diameters[ @m] / 2;
padding: 0 (@thumb-diameters[ @m] / 2);
}
}

Expand All @@ -159,11 +159,11 @@
// TODO delete in v3.0
.segment {
&:last-of-type .number {
margin-right: -@thumb-diameters[ @m] / 2;
margin-right: (-@thumb-diameters[ @m] / 2);
}

&:first-of-type .number {
margin-left: -@thumb-diameters[ @m] / 2;
margin-left: (-@thumb-diameters[ @m] / 2);
}
}

Expand Down
2 changes: 1 addition & 1 deletion projects/kit/components/slider/slider.style.less
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
The most left point of the track is the most left point of the thumb (at the zero-position).
The first tick should start at the center of thumb to set correct position for all other ticks.
*/
@first-tick-offset: (@thumb-width - @ticks-thickness) / 2;
@first-tick-offset: ((@thumb-width - @ticks-thickness) / 2);
@ticks-background-size: calc(100% - @thumb-width);

@hide-first-tick: linear-gradient(
Expand Down

0 comments on commit 31fce51

Please sign in to comment.