{"ast":null,"code":"import _toConsumableArray from \"@babel/runtime/helpers/esm/toConsumableArray\";\nimport * as React from 'react';\n\n/** Format the value in the range of [min, max] */\n\n/** Format value align with step */\n\n/** Format value align with step & marks */\n\nexport default function useOffset(min, max, step, markList, allowCross, pushable) {\n var formatRangeValue = React.useCallback(function (val) {\n return Math.max(min, Math.min(max, val));\n }, [min, max]);\n var formatStepValue = React.useCallback(function (val) {\n if (step !== null) {\n var stepValue = min + Math.round((formatRangeValue(val) - min) / step) * step;\n\n // Cut number in case to be like 0.30000000000000004\n var getDecimal = function getDecimal(num) {\n return (String(num).split('.')[1] || '').length;\n };\n var maxDecimal = Math.max(getDecimal(step), getDecimal(max), getDecimal(min));\n var fixedValue = Number(stepValue.toFixed(maxDecimal));\n return min <= fixedValue && fixedValue <= max ? fixedValue : null;\n }\n return null;\n }, [step, min, max, formatRangeValue]);\n var formatValue = React.useCallback(function (val) {\n var formatNextValue = formatRangeValue(val);\n\n // List align values\n var alignValues = markList.map(function (mark) {\n return mark.value;\n });\n if (step !== null) {\n alignValues.push(formatStepValue(val));\n }\n\n // min & max\n alignValues.push(min, max);\n\n // Align with marks\n var closeValue = alignValues[0];\n var closeDist = max - min;\n alignValues.forEach(function (alignValue) {\n var dist = Math.abs(formatNextValue - alignValue);\n if (dist <= closeDist) {\n closeValue = alignValue;\n closeDist = dist;\n }\n });\n return closeValue;\n }, [min, max, markList, step, formatRangeValue, formatStepValue]);\n\n // ========================== Offset ==========================\n // Single Value\n var offsetValue = function offsetValue(values, offset, valueIndex) {\n var mode = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : 'unit';\n if (typeof offset === 'number') {\n var nextValue;\n var originValue = values[valueIndex];\n\n // Only used for `dist` mode\n var targetDistValue = originValue + offset;\n\n // Compare next step value & mark value which is best match\n var potentialValues = [];\n markList.forEach(function (mark) {\n potentialValues.push(mark.value);\n });\n\n // Min & Max\n potentialValues.push(min, max);\n\n // In case origin value is align with mark but not with step\n potentialValues.push(formatStepValue(originValue));\n\n // Put offset step value also\n var sign = offset > 0 ? 1 : -1;\n if (mode === 'unit') {\n potentialValues.push(formatStepValue(originValue + sign * step));\n } else {\n potentialValues.push(formatStepValue(targetDistValue));\n }\n\n // Find close one\n potentialValues = potentialValues.filter(function (val) {\n return val !== null;\n })\n // Remove reverse value\n .filter(function (val) {\n return offset < 0 ? val <= originValue : val >= originValue;\n });\n if (mode === 'unit') {\n // `unit` mode can not contain itself\n potentialValues = potentialValues.filter(function (val) {\n return val !== originValue;\n });\n }\n var compareValue = mode === 'unit' ? originValue : targetDistValue;\n nextValue = potentialValues[0];\n var valueDist = Math.abs(nextValue - compareValue);\n potentialValues.forEach(function (potentialValue) {\n var dist = Math.abs(potentialValue - compareValue);\n if (dist < valueDist) {\n nextValue = potentialValue;\n valueDist = dist;\n }\n });\n\n // Out of range will back to range\n if (nextValue === undefined) {\n return offset < 0 ? min : max;\n }\n\n // `dist` mode\n if (mode === 'dist') {\n return nextValue;\n }\n\n // `unit` mode may need another round\n if (Math.abs(offset) > 1) {\n var cloneValues = _toConsumableArray(values);\n cloneValues[valueIndex] = nextValue;\n return offsetValue(cloneValues, offset - sign, valueIndex, mode);\n }\n return nextValue;\n } else if (offset === 'min') {\n return min;\n } else if (offset === 'max') {\n return max;\n }\n };\n\n /** Same as `offsetValue` but return `changed` mark to tell value changed */\n var offsetChangedValue = function offsetChangedValue(values, offset, valueIndex) {\n var mode = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : 'unit';\n var originValue = values[valueIndex];\n var nextValue = offsetValue(values, offset, valueIndex, mode);\n return {\n value: nextValue,\n changed: nextValue !== originValue\n };\n };\n var needPush = function needPush(dist) {\n return pushable === null && dist === 0 || typeof pushable === 'number' && dist < pushable;\n };\n\n // Values\n var offsetValues = function offsetValues(values, offset, valueIndex) {\n var mode = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : 'unit';\n var nextValues = values.map(formatValue);\n var originValue = nextValues[valueIndex];\n var nextValue = offsetValue(nextValues, offset, valueIndex, mode);\n nextValues[valueIndex] = nextValue;\n if (allowCross === false) {\n // >>>>> Allow Cross\n var pushNum = pushable || 0;\n\n // ============ AllowCross ===============\n if (valueIndex > 0 && nextValues[valueIndex - 1] !== originValue) {\n nextValues[valueIndex] = Math.max(nextValues[valueIndex], nextValues[valueIndex - 1] + pushNum);\n }\n if (valueIndex < nextValues.length - 1 && nextValues[valueIndex + 1] !== originValue) {\n nextValues[valueIndex] = Math.min(nextValues[valueIndex], nextValues[valueIndex + 1] - pushNum);\n }\n } else if (typeof pushable === 'number' || pushable === null) {\n // >>>>> Pushable\n // =============== Push ==================\n\n // >>>>>> Basic push\n // End values\n for (var i = valueIndex + 1; i < nextValues.length; i += 1) {\n var changed = true;\n while (needPush(nextValues[i] - nextValues[i - 1]) && changed) {\n var _offsetChangedValue = offsetChangedValue(nextValues, 1, i);\n nextValues[i] = _offsetChangedValue.value;\n changed = _offsetChangedValue.changed;\n }\n }\n\n // Start values\n for (var _i = valueIndex; _i > 0; _i -= 1) {\n var _changed = true;\n while (needPush(nextValues[_i] - nextValues[_i - 1]) && _changed) {\n var _offsetChangedValue2 = offsetChangedValue(nextValues, -1, _i - 1);\n nextValues[_i - 1] = _offsetChangedValue2.value;\n _changed = _offsetChangedValue2.changed;\n }\n }\n\n // >>>>> Revert back to safe push range\n // End to Start\n for (var _i2 = nextValues.length - 1; _i2 > 0; _i2 -= 1) {\n var _changed2 = true;\n while (needPush(nextValues[_i2] - nextValues[_i2 - 1]) && _changed2) {\n var _offsetChangedValue3 = offsetChangedValue(nextValues, -1, _i2 - 1);\n nextValues[_i2 - 1] = _offsetChangedValue3.value;\n _changed2 = _offsetChangedValue3.changed;\n }\n }\n\n // Start to End\n for (var _i3 = 0; _i3 < nextValues.length - 1; _i3 += 1) {\n var _changed3 = true;\n while (needPush(nextValues[_i3 + 1] - nextValues[_i3]) && _changed3) {\n var _offsetChangedValue4 = offsetChangedValue(nextValues, 1, _i3 + 1);\n nextValues[_i3 + 1] = _offsetChangedValue4.value;\n _changed3 = _offsetChangedValue4.changed;\n }\n }\n }\n return {\n value: nextValues[valueIndex],\n values: nextValues\n };\n };\n return [formatValue, offsetValues];\n}","map":{"version":3,"names":["_toConsumableArray","React","useOffset","min","max","step","markList","allowCross","pushable","formatRangeValue","useCallback","val","Math","formatStepValue","stepValue","round","getDecimal","num","String","split","length","maxDecimal","fixedValue","Number","toFixed","formatValue","formatNextValue","alignValues","map","mark","value","push","closeValue","closeDist","forEach","alignValue","dist","abs","offsetValue","values","offset","valueIndex","mode","arguments","undefined","nextValue","originValue","targetDistValue","potentialValues","sign","filter","compareValue","valueDist","potentialValue","cloneValues","offsetChangedValue","changed","needPush","offsetValues","nextValues","pushNum","i","_offsetChangedValue","_i","_changed","_offsetChangedValue2","_i2","_changed2","_offsetChangedValue3","_i3","_changed3","_offsetChangedValue4"],"sources":["C:/Users/Аришина)/source/repos/PromoCursed/node_modules/rc-slider/es/hooks/useOffset.js"],"sourcesContent":["import _toConsumableArray from \"@babel/runtime/helpers/esm/toConsumableArray\";\nimport * as React from 'react';\n\n/** Format the value in the range of [min, max] */\n\n/** Format value align with step */\n\n/** Format value align with step & marks */\n\nexport default function useOffset(min, max, step, markList, allowCross, pushable) {\n var formatRangeValue = React.useCallback(function (val) {\n return Math.max(min, Math.min(max, val));\n }, [min, max]);\n var formatStepValue = React.useCallback(function (val) {\n if (step !== null) {\n var stepValue = min + Math.round((formatRangeValue(val) - min) / step) * step;\n\n // Cut number in case to be like 0.30000000000000004\n var getDecimal = function getDecimal(num) {\n return (String(num).split('.')[1] || '').length;\n };\n var maxDecimal = Math.max(getDecimal(step), getDecimal(max), getDecimal(min));\n var fixedValue = Number(stepValue.toFixed(maxDecimal));\n return min <= fixedValue && fixedValue <= max ? fixedValue : null;\n }\n return null;\n }, [step, min, max, formatRangeValue]);\n var formatValue = React.useCallback(function (val) {\n var formatNextValue = formatRangeValue(val);\n\n // List align values\n var alignValues = markList.map(function (mark) {\n return mark.value;\n });\n if (step !== null) {\n alignValues.push(formatStepValue(val));\n }\n\n // min & max\n alignValues.push(min, max);\n\n // Align with marks\n var closeValue = alignValues[0];\n var closeDist = max - min;\n alignValues.forEach(function (alignValue) {\n var dist = Math.abs(formatNextValue - alignValue);\n if (dist <= closeDist) {\n closeValue = alignValue;\n closeDist = dist;\n }\n });\n return closeValue;\n }, [min, max, markList, step, formatRangeValue, formatStepValue]);\n\n // ========================== Offset ==========================\n // Single Value\n var offsetValue = function offsetValue(values, offset, valueIndex) {\n var mode = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : 'unit';\n if (typeof offset === 'number') {\n var nextValue;\n var originValue = values[valueIndex];\n\n // Only used for `dist` mode\n var targetDistValue = originValue + offset;\n\n // Compare next step value & mark value which is best match\n var potentialValues = [];\n markList.forEach(function (mark) {\n potentialValues.push(mark.value);\n });\n\n // Min & Max\n potentialValues.push(min, max);\n\n // In case origin value is align with mark but not with step\n potentialValues.push(formatStepValue(originValue));\n\n // Put offset step value also\n var sign = offset > 0 ? 1 : -1;\n if (mode === 'unit') {\n potentialValues.push(formatStepValue(originValue + sign * step));\n } else {\n potentialValues.push(formatStepValue(targetDistValue));\n }\n\n // Find close one\n potentialValues = potentialValues.filter(function (val) {\n return val !== null;\n })\n // Remove reverse value\n .filter(function (val) {\n return offset < 0 ? val <= originValue : val >= originValue;\n });\n if (mode === 'unit') {\n // `unit` mode can not contain itself\n potentialValues = potentialValues.filter(function (val) {\n return val !== originValue;\n });\n }\n var compareValue = mode === 'unit' ? originValue : targetDistValue;\n nextValue = potentialValues[0];\n var valueDist = Math.abs(nextValue - compareValue);\n potentialValues.forEach(function (potentialValue) {\n var dist = Math.abs(potentialValue - compareValue);\n if (dist < valueDist) {\n nextValue = potentialValue;\n valueDist = dist;\n }\n });\n\n // Out of range will back to range\n if (nextValue === undefined) {\n return offset < 0 ? min : max;\n }\n\n // `dist` mode\n if (mode === 'dist') {\n return nextValue;\n }\n\n // `unit` mode may need another round\n if (Math.abs(offset) > 1) {\n var cloneValues = _toConsumableArray(values);\n cloneValues[valueIndex] = nextValue;\n return offsetValue(cloneValues, offset - sign, valueIndex, mode);\n }\n return nextValue;\n } else if (offset === 'min') {\n return min;\n } else if (offset === 'max') {\n return max;\n }\n };\n\n /** Same as `offsetValue` but return `changed` mark to tell value changed */\n var offsetChangedValue = function offsetChangedValue(values, offset, valueIndex) {\n var mode = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : 'unit';\n var originValue = values[valueIndex];\n var nextValue = offsetValue(values, offset, valueIndex, mode);\n return {\n value: nextValue,\n changed: nextValue !== originValue\n };\n };\n var needPush = function needPush(dist) {\n return pushable === null && dist === 0 || typeof pushable === 'number' && dist < pushable;\n };\n\n // Values\n var offsetValues = function offsetValues(values, offset, valueIndex) {\n var mode = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : 'unit';\n var nextValues = values.map(formatValue);\n var originValue = nextValues[valueIndex];\n var nextValue = offsetValue(nextValues, offset, valueIndex, mode);\n nextValues[valueIndex] = nextValue;\n if (allowCross === false) {\n // >>>>> Allow Cross\n var pushNum = pushable || 0;\n\n // ============ AllowCross ===============\n if (valueIndex > 0 && nextValues[valueIndex - 1] !== originValue) {\n nextValues[valueIndex] = Math.max(nextValues[valueIndex], nextValues[valueIndex - 1] + pushNum);\n }\n if (valueIndex < nextValues.length - 1 && nextValues[valueIndex + 1] !== originValue) {\n nextValues[valueIndex] = Math.min(nextValues[valueIndex], nextValues[valueIndex + 1] - pushNum);\n }\n } else if (typeof pushable === 'number' || pushable === null) {\n // >>>>> Pushable\n // =============== Push ==================\n\n // >>>>>> Basic push\n // End values\n for (var i = valueIndex + 1; i < nextValues.length; i += 1) {\n var changed = true;\n while (needPush(nextValues[i] - nextValues[i - 1]) && changed) {\n var _offsetChangedValue = offsetChangedValue(nextValues, 1, i);\n nextValues[i] = _offsetChangedValue.value;\n changed = _offsetChangedValue.changed;\n }\n }\n\n // Start values\n for (var _i = valueIndex; _i > 0; _i -= 1) {\n var _changed = true;\n while (needPush(nextValues[_i] - nextValues[_i - 1]) && _changed) {\n var _offsetChangedValue2 = offsetChangedValue(nextValues, -1, _i - 1);\n nextValues[_i - 1] = _offsetChangedValue2.value;\n _changed = _offsetChangedValue2.changed;\n }\n }\n\n // >>>>> Revert back to safe push range\n // End to Start\n for (var _i2 = nextValues.length - 1; _i2 > 0; _i2 -= 1) {\n var _changed2 = true;\n while (needPush(nextValues[_i2] - nextValues[_i2 - 1]) && _changed2) {\n var _offsetChangedValue3 = offsetChangedValue(nextValues, -1, _i2 - 1);\n nextValues[_i2 - 1] = _offsetChangedValue3.value;\n _changed2 = _offsetChangedValue3.changed;\n }\n }\n\n // Start to End\n for (var _i3 = 0; _i3 < nextValues.length - 1; _i3 += 1) {\n var _changed3 = true;\n while (needPush(nextValues[_i3 + 1] - nextValues[_i3]) && _changed3) {\n var _offsetChangedValue4 = offsetChangedValue(nextValues, 1, _i3 + 1);\n nextValues[_i3 + 1] = _offsetChangedValue4.value;\n _changed3 = _offsetChangedValue4.changed;\n }\n }\n }\n return {\n value: nextValues[valueIndex],\n values: nextValues\n };\n };\n return [formatValue, offsetValues];\n}"],"mappings":"AAAA,OAAOA,kBAAkB,MAAM,8CAA8C;AAC7E,OAAO,KAAKC,KAAK,MAAM,OAAO;;AAE9B;;AAEA;;AAEA;;AAEA,eAAe,SAASC,SAASA,CAACC,GAAG,EAAEC,GAAG,EAAEC,IAAI,EAAEC,QAAQ,EAAEC,UAAU,EAAEC,QAAQ,EAAE;EAChF,IAAIC,gBAAgB,GAAGR,KAAK,CAACS,WAAW,CAAC,UAAUC,GAAG,EAAE;IACtD,OAAOC,IAAI,CAACR,GAAG,CAACD,GAAG,EAAES,IAAI,CAACT,GAAG,CAACC,GAAG,EAAEO,GAAG,CAAC,CAAC;EAC1C,CAAC,EAAE,CAACR,GAAG,EAAEC,GAAG,CAAC,CAAC;EACd,IAAIS,eAAe,GAAGZ,KAAK,CAACS,WAAW,CAAC,UAAUC,GAAG,EAAE;IACrD,IAA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