@whitesev/utils 2.7.7 → 2.8.0

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.
@@ -79,34 +79,34 @@ export declare interface ReactFiberNode {
79
79
  * 用于存储组件的更新状态,比如新的状态、属性或者 context 的变化。通过 updateQueue ,React 可以跟踪组件的更新并在合适的时机执行更新。
80
80
  */
81
81
  updateQueue: any;
82
- [key: string | symbol]: any;
82
+ [key: string | symbol | number]: any;
83
83
  }
84
84
 
85
85
  export declare interface ReactProps {
86
86
  $$typeof: symbol;
87
- children: (boolean | ReactProps)[] | ReactProps;
87
+ children: ReactProps;
88
88
  key: string | null;
89
89
  ref: any;
90
90
  props: ReactProps;
91
91
  type: string;
92
92
  _owner: any;
93
- [key: string | symbol]: any;
93
+ [key: string | symbol | number]: any;
94
94
  }
95
95
 
96
96
  export declare interface ReactEvents {
97
- [key: string | symbol]: any;
97
+ [key: string | symbol | number]: any;
98
98
  }
99
99
 
100
100
  export declare interface ReactEventHandlers {
101
- [key: string | symbol]: any;
101
+ [key: string | symbol | number]: any;
102
102
  }
103
103
 
104
104
  export declare interface ReactInternalInstance {
105
- [key: string | symbol]: any;
105
+ [key: string | symbol | number]: any;
106
106
  }
107
107
 
108
108
  export declare interface ReactContainer {
109
- [key: string | symbol]: any;
109
+ [key: string | symbol | number]: any;
110
110
  }
111
111
 
112
112
  export declare interface ReactInstance {
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "$schema": "https://json.schemastore.org/package.json",
3
3
  "name": "@whitesev/utils",
4
- "version": "2.7.7",
4
+ "version": "2.8.0",
5
5
  "type": "module",
6
6
  "description": "一个常用的工具库",
7
7
  "main": "dist/index.cjs.js",
package/src/Dictionary.ts CHANGED
@@ -79,13 +79,13 @@ export class UtilsDictionary<K extends unknown, V extends any> {
79
79
  * 获取字典所有的键
80
80
  */
81
81
  keys(): K[] {
82
- return this.items.keys().toArray();
82
+ return Array.from(this.items.keys());
83
83
  }
84
84
  /**
85
85
  * 返回字典中的所有值
86
86
  */
87
87
  values(): V[] {
88
- return this.items.values().toArray();
88
+ return Array.from(this.items.values());
89
89
  }
90
90
  /**
91
91
  * 清空字典
package/src/Utils.ts CHANGED
@@ -36,7 +36,7 @@ class Utils {
36
36
  this.windowApi = new WindowApi(option);
37
37
  }
38
38
  /** 版本号 */
39
- version = "2025.9.8";
39
+ version = "2025.9.14";
40
40
  /**
41
41
  * 在页面中增加style元素,如果html节点存在子节点,添加子节点第一个,反之,添加到html节点的子节点最后一个
42
42
  * @param cssText css字符串
@@ -79,34 +79,34 @@ export declare interface ReactFiberNode {
79
79
  * 用于存储组件的更新状态,比如新的状态、属性或者 context 的变化。通过 updateQueue ,React 可以跟踪组件的更新并在合适的时机执行更新。
80
80
  */
81
81
  updateQueue: any;
82
- [key: string | symbol]: any;
82
+ [key: string | symbol | number]: any;
83
83
  }
84
84
 
85
85
  export declare interface ReactProps {
86
86
  $$typeof: symbol;
87
- children: (boolean | ReactProps)[] | ReactProps;
87
+ children: ReactProps;
88
88
  key: string | null;
89
89
  ref: any;
90
90
  props: ReactProps;
91
91
  type: string;
92
92
  _owner: any;
93
- [key: string | symbol]: any;
93
+ [key: string | symbol | number]: any;
94
94
  }
95
95
 
96
96
  export declare interface ReactEvents {
97
- [key: string | symbol]: any;
97
+ [key: string | symbol | number]: any;
98
98
  }
99
99
 
100
100
  export declare interface ReactEventHandlers {
101
- [key: string | symbol]: any;
101
+ [key: string | symbol | number]: any;
102
102
  }
103
103
 
104
104
  export declare interface ReactInternalInstance {
105
- [key: string | symbol]: any;
105
+ [key: string | symbol | number]: any;
106
106
  }
107
107
 
108
108
  export declare interface ReactContainer {
109
- [key: string | symbol]: any;
109
+ [key: string | symbol | number]: any;
110
110
  }
111
111
 
112
112
  export declare interface ReactInstance {