@tanstack/react-table 8.10.5 → 8.10.6

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.
@@ -2372,6 +2372,9 @@
2372
2372
  return a === b ? 0 : a > b ? 1 : -1;
2373
2373
  }
2374
2374
  function toString(a) {
2375
+ if (typeof a === 'boolean') {
2376
+ return String(a);
2377
+ }
2375
2378
  if (typeof a === 'number') {
2376
2379
  if (isNaN(a) || a === Infinity || a === -Infinity) {
2377
2380
  return '';
@@ -2388,6 +2391,13 @@
2388
2391
  // It handles numbers, mixed alphanumeric combinations, and even
2389
2392
  // null, undefined, and Infinity
2390
2393
  function compareAlphanumeric(aStr, bStr) {
2394
+ // Check if the string contains only a number
2395
+ const aFloat = parseFloat(aStr);
2396
+ const bFloat = parseFloat(bStr);
2397
+ if (!isNaN(aFloat) && !isNaN(bFloat)) {
2398
+ return compareBasic(aFloat, bFloat);
2399
+ }
2400
+
2391
2401
  // Split on number groups, but keep the delimiter
2392
2402
  // Then remove falsey split values
2393
2403
  const a = aStr.split(reSplitAlphaNumeric).filter(Boolean);