sccoreui 6.5.39 → 6.5.40

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.
@@ -78,8 +78,10 @@ const TableFilter = () => {
78
78
  return -1;
79
79
  if (b === null || b === undefined)
80
80
  return 1;
81
- const x = a.toString().replace(/^0+/, "") || "0";
82
- const y = b.toString().replace(/^0+/, "") || "0";
81
+ const [aIntRaw, aFracRaw = ""] = a.toString().split(".");
82
+ const [bIntRaw, bFracRaw = ""] = b.toString().split(".");
83
+ const x = aIntRaw.replace(/^0+/, "") || "0";
84
+ const y = bIntRaw.replace(/^0+/, "") || "0";
83
85
  if (x.length > y.length)
84
86
  return 1;
85
87
  if (x.length < y.length)
@@ -88,6 +90,13 @@ const TableFilter = () => {
88
90
  return 1;
89
91
  if (x < y)
90
92
  return -1;
93
+ const fracLength = Math.max(aFracRaw.length, bFracRaw.length);
94
+ const xFrac = aFracRaw.padEnd(fracLength, "0");
95
+ const yFrac = bFracRaw.padEnd(fracLength, "0");
96
+ if (xFrac > yFrac)
97
+ return 1;
98
+ if (xFrac < yFrac)
99
+ return -1;
91
100
  return 0;
92
101
  };
93
102
  return (compareValues(normalize((value === null || value === void 0 ? void 0 : value[0]) || null), normalize((value === null || value === void 0 ? void 0 : value[1]) || null)) <= 0);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "sccoreui",
3
- "version": "6.5.39",
3
+ "version": "6.5.40",
4
4
  "description": "ui-sccore",
5
5
  "main": "./dist/index.js",
6
6
  "module": "./dist/index.js",