MCPcopy
hub / github.com/autoNumeric/autoNumeric / _checkIfInRange

Method _checkIfInRange

src/AutoNumeric.js:8643–8646  ·  view source on GitHub ↗

* Return TRUE if the given value (a number as a string) is within the range set in the settings `minimumValue` and `maximumValue`, FALSE otherwise. * * @param {string} value * @param {object} parsedMinValue Parsed via the `parseStr()` function * @param {object} parsedMaxValue Par

(value, parsedMinValue, parsedMaxValue)

Source from the content-addressed store, hash-verified

8641 * @returns {boolean}
8642 */
8643 static _checkIfInRange(value, parsedMinValue, parsedMaxValue) {
8644 const parsedValue = AutoNumericHelper.parseStr(value);
8645 return AutoNumericHelper.testMinMax(parsedMinValue, parsedValue) > -1 && AutoNumericHelper.testMinMax(parsedMaxValue, parsedValue) < 1;
8646 }
8647
8648 /**
8649 * Update the selection values as well as resets the internal state of the current AutoNumeric object.

Callers 1

_onPasteMethod · 0.80

Calls 2

parseStrMethod · 0.80
testMinMaxMethod · 0.80

Tested by

no test coverage detected