@netless/appliance-plugin 1.1.21 → 1.1.22-beta.1
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/cdn/cdn.js +1 -1
- package/cdn/{fullWorker-CCXx1D.js → fullWorker-BQclbf.js} +105 -104
- package/cdn/{subWorker-BQlGot.js → subWorker-Co2GgG.js} +105 -104
- package/dist/appliance-plugin.js +1 -1
- package/dist/appliance-plugin.mjs +1 -1
- package/dist/core/enum.d.ts +3 -1
- package/dist/core/mainEngine.d.ts +3 -0
- package/dist/core/types.d.ts +6 -0
- package/dist/core/worker/workerManager.d.ts +2 -0
- package/dist/fullWorker.js +105 -104
- package/dist/index-7Ry75r2W.js +1 -0
- package/dist/{index-BZCUBik5.mjs → index-CEBD0CPi.mjs} +4 -2
- package/dist/{index-CPGlDbvm.mjs → index-Cyb4w2Wb.mjs} +3821 -3742
- package/dist/{index-CPFLN16a.js → index-ggI7Ru6d.js} +1 -1
- package/dist/plugin/baseApplianceManager.d.ts +6 -0
- package/dist/plugin/baseViewContainerManager.d.ts +6 -4
- package/dist/plugin/types.d.ts +9 -0
- package/dist/subWorker.js +105 -104
- package/package.json +1 -1
- package/dist/index-BdJLKyTl.js +0 -1
package/dist/appliance-plugin.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./index-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./index-7Ry75r2W.js");exports.ActiveContainerType=e.ActiveContainerType;exports.ApplianceMultiPlugin=e.ApplianceMultiPlugin;exports.ApplianceNames=e.ApplianceNames;exports.ApplianceSigleWrapper=e.ApplianceSigleWrapper;exports.ApplianceSinglePlugin=e.ApplianceSinglePlugin;exports.AutoDrawPlugin=e.AutoDrawPlugin;exports.ECanvasShowType=e.ECanvasShowType;exports.EDataType=e.EDataType;exports.EForceStopReason=e.EForceStopReason;exports.EImageType=e.EImageType;exports.EMatrixrRelationType=e.EMatrixrRelationType;exports.EOperationType=e.EOperationType;exports.EPostMessageType=e.EPostMessageType;exports.ERenderFilterType=e.ERenderFilterType;exports.EScaleType=e.EScaleType;exports.EStrokeType=e.EStrokeType;exports.EToolsKey=e.EToolsKey;exports.ElayerType=e.ElayerType;exports.EmitEventType=e.EmitEventType;exports.EventMessageType=e.EventMessageType;exports.EvevtWorkState=e.EvevtWorkState;exports.EvevtWorkType=e.EvevtWorkType;exports.InternalMsgEmitterType=e.InternalMsgEmitterType;exports.Plugin=e.Plugin;exports.ShapeType=e.ShapeType;exports.fullWorkerUrl=e.fullWorker;exports.subWorkerUrl=e.subWorker;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { H as s, A as p, B as r, z as t, y as l, U as n, k as i, b as o, J as y, m as E, o as T, P as g, c, Q as u, N as v, F as S, a as A, L as k, l as m, K as P, E as M, O as W, I as R, R as w, G as x, w as F, x as I } from "./index-
|
|
1
|
+
import { H as s, A as p, B as r, z as t, y as l, U as n, k as i, b as o, J as y, m as E, o as T, P as g, c, Q as u, N as v, F as S, a as A, L as k, l as m, K as P, E as M, O as W, I as R, R as w, G as x, w as F, x as I } from "./index-Cyb4w2Wb.mjs";
|
|
2
2
|
export {
|
|
3
3
|
s as ActiveContainerType,
|
|
4
4
|
p as ApplianceMultiPlugin,
|
package/dist/core/enum.d.ts
CHANGED
|
@@ -121,7 +121,9 @@ export declare enum EPostMessageType {
|
|
|
121
121
|
/** 获取vNode信息 */
|
|
122
122
|
GetVNodeInfo = 28,
|
|
123
123
|
/** 变更dpr */
|
|
124
|
-
UpdateDpr = 29
|
|
124
|
+
UpdateDpr = 29,
|
|
125
|
+
/** 设置字体库 */
|
|
126
|
+
SetFontFace = 30
|
|
125
127
|
}
|
|
126
128
|
export type ECanvasContextType = "webgl2" | "webgl" | "2d";
|
|
127
129
|
export declare enum ECanvasShowType {
|
|
@@ -156,6 +156,7 @@ export declare class MasterControlForWorker extends MasterController {
|
|
|
156
156
|
private isLockSentEventCursor;
|
|
157
157
|
private subMainThreadWorker?;
|
|
158
158
|
private getVNodeInfoResolveMap;
|
|
159
|
+
private setFontFacesResolve;
|
|
159
160
|
private isLocalWorkActive;
|
|
160
161
|
constructor(props: BaseSubWorkModuleProps);
|
|
161
162
|
get isBezier(): boolean;
|
|
@@ -177,6 +178,8 @@ export declare class MasterControlForWorker extends MasterController {
|
|
|
177
178
|
init(): Promise<void>;
|
|
178
179
|
private useMainThread;
|
|
179
180
|
on(): Promise<void>;
|
|
181
|
+
loadFontInMainThread(url: string): Promise<ArrayBuffer | undefined>;
|
|
182
|
+
private validateFontData;
|
|
180
183
|
clearReRenders(num?: number): void;
|
|
181
184
|
get isBusy(): boolean;
|
|
182
185
|
getLockSentEventCursor(): boolean;
|
package/dist/core/types.d.ts
CHANGED
|
@@ -134,6 +134,11 @@ export type IWorkerMessage = Omit<Partial<BaseCollectorReducerAction>, "op"> & {
|
|
|
134
134
|
maxCombineEraserTime?: number;
|
|
135
135
|
/** 平滑同步 */
|
|
136
136
|
smoothSync?: boolean;
|
|
137
|
+
/** 字体库 */
|
|
138
|
+
fontBuffers?: {
|
|
139
|
+
fontFamily: string;
|
|
140
|
+
buffer: ArrayBuffer;
|
|
141
|
+
}[];
|
|
137
142
|
[key: string]: any;
|
|
138
143
|
};
|
|
139
144
|
export interface IRectType {
|
|
@@ -186,6 +191,7 @@ export interface IMainMessage extends INormalPushMsg {
|
|
|
186
191
|
toolsTypes?: EToolsKey[];
|
|
187
192
|
isLockSentEventCursor?: boolean;
|
|
188
193
|
nextTasks?: IMainMessage[];
|
|
194
|
+
setFontFaceResult?: boolean;
|
|
189
195
|
[key: string]: any;
|
|
190
196
|
}
|
|
191
197
|
export interface IMainMessageRenderData {
|
|
@@ -18,6 +18,8 @@ export declare class WorkerManager<T extends WorkThreadEngineBase> {
|
|
|
18
18
|
protected workThreadMap: Map<string, T>;
|
|
19
19
|
constructor(worker: Worker, type: EWorkThreadType);
|
|
20
20
|
private init;
|
|
21
|
+
private setFontFaces;
|
|
22
|
+
private isFontAvailable;
|
|
21
23
|
private register;
|
|
22
24
|
post(msg: IBatchMainMessage, transfer?: Transferable[]): void;
|
|
23
25
|
}
|