export var getLeft = function (value, min, max) {
    return ((value - min) * 100) / (max - min);
};
export var getValue = function (ratio, min, max) {
    return min + (max - min) * ratio;
};
export var toFixed = function (value, fractionDigits) {
    return Number(value.toFixed(fractionDigits));
};
export function isLeftValue(nextValue, value) {
    if (nextValue > value[1]) {
        return false;
    }
    if (nextValue <= value[0] ||
        Math.abs(value[0] - nextValue) <= Math.abs(value[1] - nextValue)) {
        return true;
    }
    return false;
}
