dev-classes 1.5.5 → 1.5.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.
@@ -15,7 +15,9 @@ export declare class Utils {
15
15
  static isJSON: (str: string) => boolean;
16
16
  static filterItems: <T extends Array<{ [key in string]: any; } & {
17
17
  name: string;
18
- }>>(list: T, searchQuery: string) => T;
18
+ }>>(list: T, searchQuery: string, config?: {
19
+ filteKey?: string;
20
+ }) => T;
19
21
  static sortByOnline: <T extends Array<{ [key in string]: any; } & {
20
22
  name: string;
21
23
  online: boolean;
package/dist/index.js CHANGED
@@ -2307,7 +2307,7 @@ c(x, "events", (e, t, r, n = "") => new Promise((i, o) => {
2307
2307
  return !1;
2308
2308
  }
2309
2309
  return !0;
2310
- }), c(x, "filterItems", (e, t) => e.filter((r) => r.name.toLowerCase().includes(t.toLowerCase()))), c(x, "sortByOnline", (e) => {
2310
+ }), c(x, "filterItems", (e, t, r) => e.filter((n) => n[(r == null ? void 0 : r.filteKey) || "name"].toLowerCase().includes(t.toLowerCase()))), c(x, "sortByOnline", (e) => {
2311
2311
  const t = [], r = [];
2312
2312
  for (let o = 0; e.length > o; o++) {
2313
2313
  const a = e[o];
package/package.json CHANGED
@@ -11,7 +11,7 @@
11
11
  "url": "git+https://github.com/SinGlEBW/dev-classes.git"
12
12
  },
13
13
  "license": "MIT",
14
- "version": "1.5.5",
14
+ "version": "1.5.6",
15
15
  "type": "module",
16
16
  "module": "./dist/index.js",
17
17
  "main": "./dist/index.js",