Returns the translateX positioning for a tick mark based on it's index.
(index: number)
| 593 | |
| 594 | /** Returns the translateX positioning for a tick mark based on it's index. */ |
| 595 | _calcTickMarkTransform(index: number): string { |
| 596 | // TODO(wagnermaciel): See if we can avoid doing this and just using flex to position these. |
| 597 | const offset = index * (this._tickMarkTrackWidth / (this._tickMarks.length - 1)); |
| 598 | const translateX = this._isRtl() ? this._cachedWidth - 6 - offset : offset; |
| 599 | return `translateX(${translateX}px)`; |
| 600 | } |
| 601 | |
| 602 | // Handlers for updating the slider ui. |
| 603 |