@sunny-base-web/utils 0.8.73 → 0.8.75

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.
package/dist/index.js CHANGED
@@ -856,7 +856,7 @@ function sortTree(treeData, sortFunction, options) {
856
856
  const { childProps } = options || {
857
857
  childProps: "children"
858
858
  };
859
- return treeData.toSorted(sortFunction).map((item) => {
859
+ return [...treeData].sort(sortFunction).map((item) => {
860
860
  const children = item[childProps];
861
861
  if (children && Array.isArray(children) && children.length > 0) {
862
862
  return {
package/dist/index.mjs CHANGED
@@ -782,7 +782,7 @@ function sortTree(treeData, sortFunction, options) {
782
782
  const { childProps } = options || {
783
783
  childProps: "children"
784
784
  };
785
- return treeData.toSorted(sortFunction).map((item) => {
785
+ return [...treeData].sort(sortFunction).map((item) => {
786
786
  const children = item[childProps];
787
787
  if (children && Array.isArray(children) && children.length > 0) {
788
788
  return {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sunny-base-web/utils",
3
- "version": "0.8.73",
3
+ "version": "0.8.75",
4
4
  "private": false,
5
5
  "main": "./dist/index.js",
6
6
  "module": "./dist/index.mjs",
@@ -27,14 +27,14 @@
27
27
  "nprogress": "^0.2.0",
28
28
  "tailwind-merge": "^3.4.0",
29
29
  "vue-i18n": "^11.2.8",
30
- "@sunny-base-web/constants": "^0.8.73"
30
+ "@sunny-base-web/constants": "^0.8.75"
31
31
  },
32
32
  "devDependencies": {
33
33
  "@types/nprogress": "^0.2.3",
34
34
  "tsup": "^8.5.1",
35
35
  "typescript": "^5.7.2",
36
36
  "vue-router": "^4.6.4",
37
- "@sunny-base-web/tsconfig": "0.8.73"
37
+ "@sunny-base-web/tsconfig": "0.8.75"
38
38
  },
39
39
  "scripts": {
40
40
  "build": "tsup src/index.ts --format cjs,esm --dts --clean",