mirror of
https://github.com/ionic-team/ionic-framework.git
synced 2025-08-23 14:01:20 +08:00
chore(build): fix range
This commit is contained in:
@ -488,8 +488,7 @@ interface RangeKnob {
|
||||
handleKeyboard: (name: KnobName, isIncrease: boolean) => void;
|
||||
}
|
||||
|
||||
function renderKnob({ knob, value, ratio, min, max, disabled, pressed, pin, handleKeyboard }: RangeKnob) {
|
||||
const isRTL = document.dir === 'rtl';
|
||||
function renderKnob(isRTL: boolean, { knob, value, ratio, min, max, disabled, pressed, pin, handleKeyboard }: RangeKnob) {
|
||||
const start = isRTL ? 'right' : 'left';
|
||||
|
||||
const knobStyle = () => {
|
||||
@ -552,4 +551,4 @@ function ratioToValue(
|
||||
|
||||
function valueToRatio(value: number, min: number, max: number): number {
|
||||
return clamp(0, (value - min) / (max - min), 1);
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user