@mll-lab/js-utils 2.25.0 → 2.26.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -15316,6 +15316,17 @@ function isPartialGermanNumber(value) {
15316
15316
  return /^-?\d*[.\d]*,?\d*$/.test(value);
15317
15317
  }
15318
15318
 
15319
+ /**
15320
+ * Round up to the nearest step.
15321
+ */
15322
+ function ceil(value, step) {
15323
+ const inverse = 1.0 / step;
15324
+ return Math.ceil(value * inverse) / inverse;
15325
+ }
15326
+ function isZeroish(value, precision = 0.001) {
15327
+ return Math.abs(value) < precision;
15328
+ }
15329
+
15319
15330
  /**
15320
15331
  * Round a number to a given number of decimal places.
15321
15332
  *
@@ -15491,6 +15502,7 @@ exports.ISO_DATE_FORMAT = ISO_DATE_FORMAT;
15491
15502
  exports.ISO_DATE_TIME_FORMAT = ISO_DATE_TIME_FORMAT;
15492
15503
  exports.SECONDLESS_DATE_TIME_FORMAT = SECONDLESS_DATE_TIME_FORMAT;
15493
15504
  exports.callSequentially = callSequentially;
15505
+ exports.ceil = ceil;
15494
15506
  exports.containSameValues = containSameValues;
15495
15507
  exports.downloadBlob = downloadBlob;
15496
15508
  exports.errorMessage = errorMessage;
@@ -15527,6 +15539,7 @@ exports.isString = isString;
15527
15539
  exports.isToday = isToday;
15528
15540
  exports.isURL = isURL;
15529
15541
  exports.isWord = isWord;
15542
+ exports.isZeroish = isZeroish;
15530
15543
  exports.joinNonEmpty = joinNonEmpty;
15531
15544
  exports.last = last;
15532
15545
  exports.makeStringCompareFn = makeStringCompareFn;