@fileverse-dev/formulajs 4.4.20-mod-7 → 4.4.21-price-and-wallet-1

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.
@@ -1,4 +1,4 @@
1
- /* @fileverse-dev/formulajs v4.4.20-mod-7 */
1
+ /* @fileverse-dev/formulajs v4.4.21-price-and-wallet-1 */
2
2
  var _excluded = [ "confirmations", "dataDecoded" ];
3
3
 
4
4
  function _objectWithoutProperties(e, t) {
@@ -4964,59 +4964,41 @@ function _typeof(o) {
4964
4964
  }
4965
4965
  function XLOOKUP(search_key, lookup_range, result_range, isColV, missing_value, match_mode, search_mode) {
4966
4966
  var isCol = isColV === "true" ? true : false;
4967
- console.log("XLOOKUP parameters:", {
4968
- search_key: search_key,
4969
- lookup_range: lookup_range,
4970
- result_range: result_range,
4971
- missing_value: missing_value,
4972
- match_mode: match_mode,
4973
- search_mode: search_mode,
4974
- isCol: isCol
4975
- });
4976
4967
  if (search_key === undefined || search_key === null) {
4977
- console.log("Error: search_key is required");
4978
- return new Error("Error: search_key is required");
4968
+ return new Error("search_key");
4969
+ }
4970
+ if (!lookup_range) {
4971
+ return new Error("lookup_range");
4979
4972
  }
4980
- if (!lookup_range || !result_range) {
4981
- console.log("Error: lookup_range and result_range are required");
4982
- return new Error("Error: lookup_range and result_range are required");
4973
+ if (!result_range) {
4974
+ return new Error("result_range");
4983
4975
  }
4984
4976
  var lookup_array = normalizeLookupRange(lookup_range);
4985
4977
  if (!lookup_array) {
4986
- console.log("Error: lookup_range must be a singular row or column");
4987
- return new Error("Error: lookup_range must be a singular row or column");
4978
+ return new Error("lookup_range_single");
4988
4979
  }
4989
4980
  var result_array = normalizeResultRange(result_range);
4990
4981
  if (!result_array) {
4991
- console.log("Error: Invalid result_range");
4992
- return new Error("Error: Invalid result_range");
4982
+ return new Error("result_range_invalid");
4993
4983
  }
4994
4984
  result_array.map((function(row) {
4995
4985
  if (row.length !== lookup_array.length) {
4996
- console.log("Error: lookup_range and result_range must have the same number of columns");
4997
- return new Error("Error: lookup_range and result_range must have the same number of columns/rows");
4986
+ return new Error("lookup_range_and_result_range");
4998
4987
  }
4999
4988
  }));
5000
- missing_value = missing_value !== undefined ? missing_value : new Error("Error: Didn't find value in XLOOKUP evaluation");
4989
+ missing_value = missing_value !== undefined ? missing_value : new Error("not_found");
5001
4990
  match_mode = match_mode !== undefined ? match_mode : 0;
5002
4991
  search_mode = search_mode !== undefined ? search_mode : 1;
5003
4992
  isCol = isCol !== undefined ? isCol : false;
5004
4993
  if (![ 0, 1, -1, 2 ].includes(match_mode)) {
5005
- console.log("Error: match_mode must be 0, 1, -1, or 2");
5006
- return new Error("Error: match_mode must be 0, 1, -1, or 2");
4994
+ return new Error("match_mode_must");
5007
4995
  }
5008
4996
  if (![ 1, -1, 2, -2 ].includes(search_mode)) {
5009
- console.log("Error: search_mode must be 1, -1, 2, or -2");
5010
- return new Error("Error: search_mode must be 1, -1, 2, or -2");
4997
+ return new Error("search_mode_must");
5011
4998
  }
5012
4999
  if (Math.abs(search_mode) === 2 && match_mode === 2) {
5013
- console.log("Error: Binary search (search_mode ±2) cannot be used with wildcard matching (match_mode 2)");
5014
- return new Error("Error: Binary search (search_mode ±2) cannot be used with wildcard matching (match_mode 2)");
5000
+ return new Error("binary_search_and_wildcard");
5015
5001
  }
5016
- console.log("Normalized arrays:", {
5017
- lookup_array: lookup_array,
5018
- result_array: result_array
5019
- });
5020
5002
  var res = performLookup(search_key, lookup_array, result_array, missing_value, match_mode, search_mode, isCol);
5021
5003
  res = isCol ? Array.isArray(res) ? res.map((function(item) {
5022
5004
  return [ item.toString() ];
@@ -5054,15 +5036,6 @@ function _typeof(o) {
5054
5036
  return result_range;
5055
5037
  }
5056
5038
  function performLookup(search_key, lookup_array, result_array, missing_value, match_mode, search_mode, isCol) {
5057
- console.log("performLookup called with:", {
5058
- search_key: search_key,
5059
- lookup_array: lookup_array,
5060
- result_array: result_array,
5061
- missing_value: missing_value,
5062
- match_mode: match_mode,
5063
- search_mode: search_mode,
5064
- isCol: isCol
5065
- });
5066
5039
  var foundIndex = -1;
5067
5040
  switch (match_mode) {
5068
5041
  case 0:
@@ -5106,7 +5079,6 @@ function _typeof(o) {
5106
5079
  var _value = lookup_array[i];
5107
5080
  var processedValue = typeof _value === "string" ? _value.toLowerCase().trim() : _value;
5108
5081
  if (processedValue === processedSearchKey) {
5109
- console.log("Exact match found at index ".concat(i, ":"), _value);
5110
5082
  return i;
5111
5083
  }
5112
5084
  }
@@ -5199,7 +5171,6 @@ function _typeof(o) {
5199
5171
  var i = _step4.value;
5200
5172
  var _value4 = lookup_array[i];
5201
5173
  if (typeof _value4 === "string" && regex.test(_value4)) {
5202
- console.log("Wildcard match found at index ".concat(i, ":"), _value4);
5203
5174
  return i;
5204
5175
  }
5205
5176
  }