nhanh-pure-function 3.0.6-beta.10 → 3.0.6-beta.12

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.
@@ -17,8 +17,28 @@ export declare class _Browser_KeyedWindowManager {
17
17
  private static keys;
18
18
  /** 请使用静态方法 */
19
19
  private constructor();
20
- /** 添加已有窗口 */
21
- static add(key: string, win: Window): void;
20
+ /** 获取键值对管理器的唯一标识符 */
21
+ static Get_KeyedWindowManager: symbol;
22
+ /**
23
+ * 初始化
24
+ * @param name 窗口名称
25
+ */
26
+ static init(name: string): void;
27
+ /**
28
+ * 更新窗口管理器
29
+ * @param self 最新实例
30
+ */
31
+ static update(self: typeof _Browser_KeyedWindowManager): void;
32
+ /**
33
+ * 通知所有窗口 同步所以可访问的窗口
34
+ */
35
+ static notify(): void;
36
+ /**
37
+ * 检查窗口的 opener 是否与当前页面同源
38
+ * @param win 窗口对象
39
+ * @returns 如果 opener 与当前页面同源则返回true,否则返回false
40
+ */
41
+ static isSameOrigin(url?: string | URL): boolean | "" | undefined;
22
42
  /**
23
43
  * 根据键打开或聚焦窗口
24
44
  * @param key 窗口的唯一键
@@ -27,7 +47,7 @@ export declare class _Browser_KeyedWindowManager {
27
47
  * @param windowFeatures 新窗口的特性
28
48
  * @returns 返回已打开或新打开的窗口
29
49
  */
30
- static open(key: string, url?: string | URL, target?: WindowTarget, windowFeatures?: string): Window | undefined;
50
+ static open(key: string, url?: string | URL, target?: WindowTarget, windowFeatures?: string): void | Window;
31
51
  /**
32
52
  * 检查指定键的窗口是否打开
33
53
  * @param key 窗口的唯一键
@@ -63,7 +83,7 @@ export declare class _Browser_KeyedWindowManager {
63
83
  * paperHeightPx: number; // 纸张总高度(px)
64
84
  * }
65
85
  */
66
- export declare function _Browser_CalculatePrintableArea(type: PaperType, padding: number): {
86
+ export declare function _Browser_CalculatePrintableArea(type: PaperType, padding: number): void | {
67
87
  /** 内容宽度(像素) */
68
88
  contentWidth: number;
69
89
  /** 内容高度(像素) */
@@ -3,8 +3,11 @@ import { _Type_DeepPartial } from '../..';
3
3
  export default class Axis {
4
4
  /** 画布 */
5
5
  private canvas;
6
+ /** 轴画布 */
6
7
  private axis_canvas;
8
+ /** 轴画布上下文 */
7
9
  private ctx;
10
+ /** 是否重新绘制轴 */
8
11
  private isReload;
9
12
  /** 网格开关 */
10
13
  show: {
@@ -8,9 +8,9 @@ export declare function _Utility_ExecuteWhenIdle(callback: Function, timeout?: n
8
8
  * 等待条件满足
9
9
  * @param conditionChecker 条件检查器
10
10
  * @param timeoutMillis 超时毫秒数
11
- * @returns Promise<unknown>
11
+ * @returns Promise<number> 耗时
12
12
  */
13
- export declare function _Utility_WaitForCondition(conditionChecker: () => boolean, timeoutMillis: number): Promise<"完成" | "超时">;
13
+ export declare function _Utility_WaitForCondition(conditionChecker: () => boolean, timeoutMillis: number): Promise<number>;
14
14
  /**
15
15
  * 合并对象 注意: 本函数会直接操作 A
16
16
  * @param {Object | Array} A
@@ -91,7 +91,7 @@ export declare class _Valid_FileTypeChecker {
91
91
  static parseAddresses(url: string): {
92
92
  url: string;
93
93
  name: string;
94
- type: "audio" | "code" | "script" | "video" | "text" | "image" | "ppt" | "word" | "excel" | "pdf" | "archive" | "font" | "database" | "markup" | "configuration" | "logs" | "unknown";
94
+ type: "image" | "ppt" | "word" | "excel" | "pdf" | "text" | "audio" | "video" | "archive" | "code" | "font" | "database" | "markup" | "configuration" | "logs" | "script" | "unknown";
95
95
  }[];
96
96
  /**
97
97
  * 检查 MIME 类型是否与指定的模式匹配
@@ -121,5 +121,5 @@ export declare class _Valid_FileTypeChecker {
121
121
  * @param {string} url - 文件的URL
122
122
  * @returns {string} - 如果URL与任何已知类型匹配,则返回文件类型,否则返回"unknown"
123
123
  */
124
- static _detectFileType(url: string): "audio" | "code" | "script" | "video" | "text" | "image" | "ppt" | "word" | "excel" | "pdf" | "archive" | "font" | "database" | "markup" | "configuration" | "logs" | "unknown";
124
+ static _detectFileType(url: string): "image" | "ppt" | "word" | "excel" | "pdf" | "text" | "audio" | "video" | "archive" | "code" | "font" | "database" | "markup" | "configuration" | "logs" | "script" | "unknown";
125
125
  }