@netless/appliance-plugin 1.1.43 → 1.1.44-beta.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.
Files changed (63) hide show
  1. package/dist/appliance-plugin.js +1 -1
  2. package/dist/appliance-plugin.mjs +12 -12
  3. package/dist/{bridge-GmRa7-tp.js → bridge-CskJoX5M.js} +1 -1
  4. package/dist/{bridge-D30E9dr6.mjs → bridge-rKHCYJ6m.mjs} +1 -1
  5. package/dist/bridge.js +1 -1
  6. package/dist/bridge.mjs +1 -1
  7. package/dist/collector/types.d.ts +3 -0
  8. package/dist/component/textEditor/types.d.ts +5 -0
  9. package/dist/core/mainEngine.d.ts +10 -2
  10. package/dist/core/mainThread/snapshotThread.d.ts +3 -2
  11. package/dist/core/mainThread/subLocalThread.d.ts +5 -2
  12. package/dist/core/mainThread/subServiceThread.d.ts +1 -0
  13. package/dist/core/mainThread/subTopThread.d.ts +2 -2
  14. package/dist/core/tools/arrow.d.ts +423 -1
  15. package/dist/core/tools/base.d.ts +444 -2
  16. package/dist/core/tools/ellipse.d.ts +423 -1
  17. package/dist/core/tools/eraser.d.ts +846 -2
  18. package/dist/core/tools/eraserFaces.d.ts +2 -0
  19. package/dist/core/tools/laserPen.d.ts +846 -2
  20. package/dist/core/tools/pencil.d.ts +848 -2
  21. package/dist/core/tools/pencilEraser.d.ts +1692 -4
  22. package/dist/core/tools/pencilEraserBitMap.d.ts +2115 -5
  23. package/dist/core/tools/polygon.d.ts +423 -1
  24. package/dist/core/tools/rectangle.d.ts +423 -1
  25. package/dist/core/tools/selector.d.ts +2121 -7
  26. package/dist/core/tools/speechBalloon.d.ts +423 -1
  27. package/dist/core/tools/star.d.ts +423 -1
  28. package/dist/core/tools/straight.d.ts +423 -1
  29. package/dist/core/tools/text.d.ts +3 -3
  30. package/dist/core/tools/utils.d.ts +2 -2
  31. package/dist/core/types.d.ts +9 -0
  32. package/dist/core/utils/affineMatrix.d.ts +33 -0
  33. package/dist/core/utils/fontFamily.d.ts +8 -0
  34. package/dist/core/utils/index.d.ts +2 -0
  35. package/dist/core/utils/selectorMatrix.d.ts +4 -0
  36. package/dist/core/utils/selectorRefresh.d.ts +8 -0
  37. package/dist/core/utils/textRaster.d.ts +2 -0
  38. package/dist/core/vNodeManager.d.ts +1 -1
  39. package/dist/core/worker/base.d.ts +1 -1
  40. package/dist/core/worker/fullWorkerLocal.d.ts +1 -0
  41. package/dist/core/worker/fullWorkerService.d.ts +2 -1
  42. package/dist/core/worker/simpleWorker.d.ts +1 -1
  43. package/dist/core/worker/subWorkerTopLayer.d.ts +2 -2
  44. package/dist/fullWorker.js +148 -147
  45. package/dist/index-B0SB7Efu.js +570 -0
  46. package/dist/index-BIVRfc_x.js +570 -0
  47. package/dist/{index-CQuJ6lL1.mjs → index-BbBSxLGe.mjs} +473 -442
  48. package/dist/index-Bzg5OMdP.js +1 -0
  49. package/dist/{index-Ct5ShjRI.js → index-C-tBYq0K.js} +1 -1
  50. package/dist/{index-CatWUcZt.mjs → index-Ca2t53R7.mjs} +1 -1
  51. package/dist/{index-rDe1jjPM.mjs → index-ConirzkM.mjs} +1 -1
  52. package/dist/index-CsNG_bzI.js +1 -0
  53. package/dist/{index-C-pO2InQ.mjs → index-DWevrjrE.mjs} +12001 -11664
  54. package/dist/{index-DYDy0dd5.mjs → index-LcCU1tMV.mjs} +473 -442
  55. package/dist/{index-DGdruTPt.js → index-ZMuKk-bl.js} +1 -1
  56. package/dist/{index-CrJWLjuD.mjs → index-_3yxgNoj.mjs} +19490 -19158
  57. package/dist/plugin/baseApplianceManager.d.ts +2 -2
  58. package/dist/subWorker.js +133 -132
  59. package/package.json +58 -56
  60. package/dist/index-B44Av4kp.js +0 -1
  61. package/dist/index-CKtpWZ9L.js +0 -1
  62. package/dist/index-DLzvL8jo.js +0 -570
  63. package/dist/index-LmgcnMI8.js +0 -570
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./index-LmgcnMI8.js");exports.ActiveContainerType=e.ActiveContainerType;exports.ApplianceMultiPlugin=e.ApplianceMultiPlugin;exports.ApplianceNames=e.ApplianceNames;exports.AppliancePluginCursorNames=e.AppliancePluginCursorNames;exports.ApplianceSigleWrapper=e.ApplianceSigleWrapper;exports.ApplianceSinglePlugin=e.ApplianceSinglePlugin;exports.Camera_Ack_Slow_Timeout=e.Camera_Ack_Slow_Timeout;exports.Camera_Transport_Fallback_Timeout=e.Camera_Transport_Fallback_Timeout;exports.Camera_Update_Business_Timeout=e.Camera_Update_Business_Timeout;exports.Cursor_Hover_Id=e.Cursor_Hover_Id;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.ESVGType=e.ESVGType;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.EventWorkState=e.EventWorkState;exports.EvevtWorkState=e.EventWorkState;exports.FontFaceFallbackBlacklistLevel=e.FontFaceFallbackBlacklistLevel;exports.InternalMsgEmitterType=e.InternalMsgEmitterType;exports.Main_View_Id=e.Main_View_Id;exports.Plugin=e.Plugin;exports.Renderer_Business_Default_Timeout=e.Renderer_Business_Default_Timeout;exports.ShapeType=e.ShapeType;exports.Task_Time_Interval=e.Task_Time_Interval;exports.WorkerCanvasContextBlacklistLevel=e.WorkerCanvasContextBlacklistLevel;exports.WorkerMaskTextureFormatBlacklistLevel=e.WorkerMaskTextureFormatBlacklistLevel;exports.WorkerMaskTextureUploadBlacklistLevel=e.WorkerMaskTextureUploadBlacklistLevel;exports.WorkerRenderModeBlacklistLevel=e.WorkerRenderModeBlacklistLevel;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./index-BIVRfc_x.js");exports.ActiveContainerType=e.ActiveContainerType;exports.ApplianceMultiPlugin=e.ApplianceMultiPlugin;exports.ApplianceNames=e.ApplianceNames;exports.AppliancePluginCursorNames=e.AppliancePluginCursorNames;exports.ApplianceSigleWrapper=e.ApplianceSigleWrapper;exports.ApplianceSinglePlugin=e.ApplianceSinglePlugin;exports.Camera_Ack_Slow_Timeout=e.Camera_Ack_Slow_Timeout;exports.Camera_Transport_Fallback_Timeout=e.Camera_Transport_Fallback_Timeout;exports.Camera_Update_Business_Timeout=e.Camera_Update_Business_Timeout;exports.Cursor_Hover_Id=e.Cursor_Hover_Id;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.ESVGType=e.ESVGType;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.EventWorkState=e.EventWorkState;exports.EvevtWorkState=e.EventWorkState;exports.FontFaceFallbackBlacklistLevel=e.FontFaceFallbackBlacklistLevel;exports.InternalMsgEmitterType=e.InternalMsgEmitterType;exports.Main_View_Id=e.Main_View_Id;exports.Plugin=e.Plugin;exports.Renderer_Business_Default_Timeout=e.Renderer_Business_Default_Timeout;exports.ShapeType=e.ShapeType;exports.Task_Time_Interval=e.Task_Time_Interval;exports.WorkerCanvasContextBlacklistLevel=e.WorkerCanvasContextBlacklistLevel;exports.WorkerMaskTextureFormatBlacklistLevel=e.WorkerMaskTextureFormatBlacklistLevel;exports.WorkerMaskTextureUploadBlacklistLevel=e.WorkerMaskTextureUploadBlacklistLevel;exports.WorkerRenderModeBlacklistLevel=e.WorkerRenderModeBlacklistLevel;
@@ -1,9 +1,9 @@
1
- import { Y as s, Z as t, _ as r, $ as l, a0 as i, a1 as p, a2 as o, a3 as n, a4 as T, C as E, s as c, b as k, a5 as y, H as _, K as u, a6 as m, a as v, a7 as g, d as S, a8 as d, a9 as C, c as M, aa as A, E as B, ab as F, e as W, e as x, ac as I, ad as L, y as P, ae as R, af as b, ag as f, T as h, ah as w, ai as D, aj as H, ak as K } from "./index-C-pO2InQ.mjs";
1
+ import { _ as s, $ as t, a0 as l, a1 as r, a2 as i, a3 as p, a4 as o, a5 as n, a6 as T, C as E, s as c, b as k, a7 as _, I as y, L as m, a8 as u, a as v, a9 as g, d as S, aa as d, ab as C, c as M, ac as A, E as B, ad as F, e as W, e as I, ae as L, af as x, z as P, ag as R, ah as b, ai as f, T as h, aj as w, ak as D, al as N, am as U } from "./index-DWevrjrE.mjs";
2
2
  export {
3
3
  s as ActiveContainerType,
4
4
  t as ApplianceMultiPlugin,
5
- r as ApplianceNames,
6
- l as AppliancePluginCursorNames,
5
+ l as ApplianceNames,
6
+ r as AppliancePluginCursorNames,
7
7
  i as ApplianceSigleWrapper,
8
8
  p as ApplianceSinglePlugin,
9
9
  o as Camera_Ack_Slow_Timeout,
@@ -12,10 +12,10 @@ export {
12
12
  E as Cursor_Hover_Id,
13
13
  c as ECanvasShowType,
14
14
  k as EDataType,
15
- y as EForceStopReason,
16
- _ as EImageType,
17
- u as EMatrixrRelationType,
18
- m as EOperationType,
15
+ _ as EForceStopReason,
16
+ y as EImageType,
17
+ m as EMatrixrRelationType,
18
+ u as EOperationType,
19
19
  v as EPostMessageType,
20
20
  g as ERenderFilterType,
21
21
  S as ESVGType,
@@ -26,9 +26,9 @@ export {
26
26
  B as EmitEventType,
27
27
  F as EventMessageType,
28
28
  W as EventWorkState,
29
- x as EvevtWorkState,
30
- I as FontFaceFallbackBlacklistLevel,
31
- L as InternalMsgEmitterType,
29
+ I as EvevtWorkState,
30
+ L as FontFaceFallbackBlacklistLevel,
31
+ x as InternalMsgEmitterType,
32
32
  P as Main_View_Id,
33
33
  R as Plugin,
34
34
  b as Renderer_Business_Default_Timeout,
@@ -36,6 +36,6 @@ export {
36
36
  h as Task_Time_Interval,
37
37
  w as WorkerCanvasContextBlacklistLevel,
38
38
  D as WorkerMaskTextureFormatBlacklistLevel,
39
- H as WorkerMaskTextureUploadBlacklistLevel,
40
- K as WorkerRenderModeBlacklistLevel
39
+ N as WorkerMaskTextureUploadBlacklistLevel,
40
+ U as WorkerRenderModeBlacklistLevel
41
41
  };
@@ -1 +1 @@
1
- "use strict";var l=Object.defineProperty;var o=(i,e,t)=>e in i?l(i,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):i[e]=t;var n=(i,e,t)=>o(i,typeof e!="symbol"?e+"":e,t);let r;function c(i){r=i}function u(){if(!r)throw new Error("[@netless/appliance-plugin/bridge] white-web-sdk runtime has not been bound yet.");return r}class h{constructor(){n(this,"control");n(this,"_listeners",{})}_inject(e){this.control=e}_onEvent(e,t){this._listeners[e]&&this._listeners[e](...t)}callbacks(e,t){this._listeners[e]=t}removeCallback(e){delete this._listeners[e]}}class g{constructor(e){n(this,"control");n(this,"worker");n(this,"publicMsgEmitter");n(this,"plugins",new Map);const{control:t,publicMsgEmitter:s}=e;this.control=t,this.publicMsgEmitter=s,this.worker=t.worker}use(e){this.plugins.set(e.kind,e),e._inject(this.control),e.onCreate()}destroy(){this.plugins.forEach(e=>{this.plugins.delete(e.kind),e.onDestroy()})}dispatchPluginEvent(e,...t){this.plugins.forEach(s=>{s._onEvent(e,t)})}}async function a(i){return c(i),Promise.resolve().then(()=>require("./index-DLzvL8jo.js")).then(e=>e.index)}exports.Plugin=h;exports.PluginManager=g;exports.getWhiteWebSdkBridgeRuntime=u;exports.loadAppliancePluginBridge=a;
1
+ "use strict";var l=Object.defineProperty;var o=(i,e,t)=>e in i?l(i,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):i[e]=t;var n=(i,e,t)=>o(i,typeof e!="symbol"?e+"":e,t);let r;function c(i){r=i}function u(){if(!r)throw new Error("[@netless/appliance-plugin/bridge] white-web-sdk runtime has not been bound yet.");return r}class h{constructor(){n(this,"control");n(this,"_listeners",{})}_inject(e){this.control=e}_onEvent(e,t){this._listeners[e]&&this._listeners[e](...t)}callbacks(e,t){this._listeners[e]=t}removeCallback(e){delete this._listeners[e]}}class g{constructor(e){n(this,"control");n(this,"worker");n(this,"publicMsgEmitter");n(this,"plugins",new Map);const{control:t,publicMsgEmitter:s}=e;this.control=t,this.publicMsgEmitter=s,this.worker=t.worker}use(e){this.plugins.set(e.kind,e),e._inject(this.control),e.onCreate()}destroy(){this.plugins.forEach(e=>{this.plugins.delete(e.kind),e.onDestroy()})}dispatchPluginEvent(e,...t){this.plugins.forEach(s=>{s._onEvent(e,t)})}}async function a(i){return c(i),Promise.resolve().then(()=>require("./index-B0SB7Efu.js")).then(e=>e.index)}exports.Plugin=h;exports.PluginManager=g;exports.getWhiteWebSdkBridgeRuntime=u;exports.loadAppliancePluginBridge=a;
@@ -54,7 +54,7 @@ class g {
54
54
  }
55
55
  }
56
56
  async function d(i) {
57
- return c(i), import("./index-CrJWLjuD.mjs").then((t) => t.Z);
57
+ return c(i), import("./index-_3yxgNoj.mjs").then((t) => t.$);
58
58
  }
59
59
  export {
60
60
  g as P,
package/dist/bridge.js CHANGED
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./bridge-GmRa7-tp.js");exports.Plugin=e.Plugin;exports.loadAppliancePluginBridge=e.loadAppliancePluginBridge;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./bridge-CskJoX5M.js");exports.Plugin=e.Plugin;exports.loadAppliancePluginBridge=e.loadAppliancePluginBridge;
package/dist/bridge.mjs CHANGED
@@ -1,4 +1,4 @@
1
- import { a as i, l as e } from "./bridge-D30E9dr6.mjs";
1
+ import { a as i, l as e } from "./bridge-rKHCYJ6m.mjs";
2
2
  export {
3
3
  i as Plugin,
4
4
  e as loadAppliancePluginBridge
@@ -1,6 +1,7 @@
1
1
  import type { EPostMessageType, EToolsKey, EventMessageType, EventWorkState } from "../core/enum";
2
2
  import type { ShapeOptions } from "../core/tools";
3
3
  import type { IUpdateNodeOpt, IworkId } from "../core/types";
4
+ import type { AffineMatrix } from "../core/utils/affineMatrix";
4
5
  import type { _ObjectTrue, EmitEventType } from "../plugin/types";
5
6
  export declare type DiffOneView<ISerializableStorageViewData> = {
6
7
  oldValue?: ISerializableStorageViewData;
@@ -65,6 +66,8 @@ export interface INormalPushMsg {
65
66
  requestId?: string;
66
67
  /** selector 事件专用:当前选中操作的生命周期 */
67
68
  workState?: EventWorkState;
69
+ /** Live selector transform for the text editor overlay. */
70
+ previewMatrix?: AffineMatrix;
68
71
  }
69
72
  export interface INormalStorageData {
70
73
  [key: string]: IStorageValueItem | undefined;
@@ -1,5 +1,6 @@
1
1
  import { EDataType, EventWorkState, IUpdateNodeOpt } from "../../core";
2
2
  import { BaseShapeOptions } from "../../core/tools";
3
+ import type { AffineMatrix } from "../../core/utils/affineMatrix";
3
4
  import type { EmitEventType } from "../../plugin/types";
4
5
  export declare enum ETextEditorType {
5
6
  Text = 1,
@@ -9,6 +10,8 @@ export type VerticalAlignType = "top" | "middle" | "bottom";
9
10
  export type TextAlignType = "left" | "center" | "right";
10
11
  export type FontWeightType = "bold" | "normal";
11
12
  export type FontStyleType = "italic" | "normal";
13
+ export declare const TextDefaultLineHeightRatio = 1.2;
14
+ export declare function getTextLineHeight(fontSize: number, lineHeight?: number): number;
12
15
  export interface TextOptions extends BaseShapeOptions {
13
16
  fontColor: string;
14
17
  fontSize: number;
@@ -47,6 +50,8 @@ export type TextEditorInfo = {
47
50
  canSync?: boolean;
48
51
  dataType?: EDataType;
49
52
  translate?: [number, number];
53
+ /** Selector gesture transform, used only for the live DOM preview. */
54
+ previewMatrix?: AffineMatrix;
50
55
  justLocal?: boolean;
51
56
  updateNodeOpt?: IUpdateNodeOpt;
52
57
  requestId?: string;
@@ -19,6 +19,14 @@ export type UndoTickerForceEndRoute = {
19
19
  };
20
20
  export declare function getUndoTickerForceEndRoute(source: UndoTickerSource): UndoTickerForceEndRoute;
21
21
  export type ForceDoneReason = "camera-update" | "dpr-update" | "scene-change" | "clean-scene" | "set-readonly" | "disconnect" | "destroy" | "view-destroy" | "render-runtime-fallback";
22
+ export type ForceDoneOptions = {
23
+ /**
24
+ * When false, drain only View-local render state. No Collector/storage or
25
+ * Undo persistence is allowed. This is used while rebinding a read-only
26
+ * View, where the runtime still needs local cleanup but cannot sync data.
27
+ */
28
+ syncStorage?: boolean;
29
+ };
22
30
  type ViewForceDoneAckBase = {
23
31
  viewId: string;
24
32
  scenePath: string;
@@ -109,7 +117,7 @@ export declare abstract class MasterController {
109
117
  abstract waitForLocalEventQueue(viewId?: string): Promise<void>;
110
118
  abstract finishActiveContinuousMethods(viewId: string, scenePath: string): Promise<void>;
111
119
  abstract abortActiveContinuousMethods(viewId: string, workId?: string): boolean;
112
- abstract forceDoneLocalWorks(viewId: string, scenePath: string, reason: ForceDoneReason): Promise<ViewForceDoneAck>;
120
+ abstract forceDoneLocalWorks(viewId: string, scenePath: string, reason: ForceDoneReason, options?: ForceDoneOptions): Promise<ViewForceDoneAck>;
113
121
  abstract invalidateTransactionBarrier(viewId: string): void;
114
122
  /** 更新指定view场景路径下的相机参数 */
115
123
  abstract updateCamera(viewId: string, cameraOpt: ICameraOpt): void;
@@ -515,7 +523,7 @@ export declare class MasterControlForWorker extends MasterController {
515
523
  originalEventLintener(workState: EventWorkState, point: [number, number], viewId: string): Promise<void>;
516
524
  waitForLocalEventQueue(viewId?: string): Promise<void>;
517
525
  finishActiveContinuousMethods(viewId: string, scenePath: string): Promise<void>;
518
- forceDoneLocalWorks(viewId: string, scenePath: string, reason: ForceDoneReason): Promise<ViewForceDoneAck>;
526
+ forceDoneLocalWorks(viewId: string, scenePath: string, reason: ForceDoneReason, options?: ForceDoneOptions): Promise<ViewForceDoneAck>;
519
527
  invalidateTransactionBarrier(viewId: string): void;
520
528
  private waitForCurrentTransactionBarrier;
521
529
  private executeTransactionBarrier;
@@ -2,7 +2,7 @@ import { Group } from "spritejs";
2
2
  import { IMainThreadInitOption } from "./base";
3
3
  import { MasterControlForWorker } from "../mainEngine";
4
4
  import { IActiveToolsDataType, IBatchMainMessage, ICameraOpt, IRectType, IWorkerMessage } from "../types";
5
- import type { BaseShapeTool } from "../tools/base";
5
+ import { BaseShapeTool } from "../tools/base";
6
6
  import type { ImageShape } from "../tools/image";
7
7
  import { TextShape } from "../tools/text";
8
8
  import { ISvgShadowShape } from "../tools/shadowSvg";
@@ -37,9 +37,10 @@ export declare class SnapshotThreadImpl {
37
37
  loadImageBitMap(msg: Pick<IWorkerMessage, "toolsType" | "opt" | "workId" | "requestId">): Promise<HTMLImageElement | ImageBitmap | undefined>;
38
38
  createWorkShapeNode(opt: IActiveToolsDataType & {
39
39
  workId: string;
40
- }): TextShape | import("../tools").ArrowShape | import("../tools").PencilShape | import("../tools/straight").StraightShape | import("../tools").EllipseShape | import("../tools").PolygonShape | import("../tools").StarShape | import("../tools").RectangleShape | import("../tools").SpeechBalloonShape | import("../tools").LaserPenShape | import("../tools").EraserShape | import("../tools").BitMapEraserShape | import("../tools/pencilEraser").PencilEraserShape | import("../tools").SelectorShape | ImageShape | ISvgShadowShape | undefined;
40
+ }): TextShape | import("../tools").ArrowShape | import("../tools").PencilShape | import("../tools/straight").StraightShape | import("../tools").EllipseShape | import("../tools").PolygonShape | import("../tools").StarShape | import("../tools").RectangleShape | import("../tools").SpeechBalloonShape | import("../tools").LaserPenShape | import("../tools").EraserShape | import("../tools/pencilEraser").PencilEraserShape | import("../tools").BitMapEraserShape | import("../tools").SelectorShape | ImageShape | ISvgShadowShape | undefined;
41
41
  setFullWork(data: Pick<IWorkerMessage, "workId" | "opt" | "toolsType">): BaseShapeTool | undefined;
42
42
  runFullWork(data: IWorkerMessage): Promise<IRectType | undefined>;
43
+ private syncMatrixRect;
43
44
  private getSnapshot;
44
45
  private getSceneRect;
45
46
  private getRectImageBitmap;
@@ -1,5 +1,6 @@
1
1
  import { IActiveToolsDataType, IWorkerMessage, IMainMessage, IUpdateSelectorPropsType, IBatchMainMessage, BaseNodeMapItem } from "../types";
2
- import type { BaseShapeTool, BaseShapeOptions, SelectorShape, ImageShape, ShapeToolsClass } from "../tools";
2
+ import type { BaseShapeOptions, SelectorShape, ImageShape, ShapeToolsClass } from "../tools";
3
+ import { BaseShapeTool } from "../tools/base";
3
4
  import { MainThreadEngineImpl, ISubThreadInitOption } from "./base";
4
5
  import { VNodeManager } from "../vNodeManager";
5
6
  import { EToolsKey } from "../enum";
@@ -52,6 +53,7 @@ export interface SubLocalThread {
52
53
  opt: BaseShapeOptions;
53
54
  toolsType: EToolsKey;
54
55
  ops?: string;
56
+ previewMatrix?: BaseNodeMapItem["previewMatrix"];
55
57
  }>;
56
58
  smoothSync?: boolean;
57
59
  }) => void;
@@ -89,6 +91,7 @@ export declare class SubLocalMainThreadImpl implements SubLocalThread {
89
91
  opt: BaseShapeOptions;
90
92
  toolsType: EToolsKey;
91
93
  ops?: string | undefined;
94
+ previewMatrix?: BaseNodeMapItem["previewMatrix"];
92
95
  }>;
93
96
  smoothSync?: boolean;
94
97
  }) => void) | undefined;
@@ -129,5 +132,5 @@ export declare class SubLocalMainThreadImpl implements SubLocalThread {
129
132
  setWorkOptions(workId: string, opt: BaseShapeOptions): void;
130
133
  createWorkShapeNode(opt: IActiveToolsDataType & {
131
134
  workId: string;
132
- }): TextShape | import("../tools").ArrowShape | import("../tools").PencilShape | import("../tools/straight").StraightShape | import("../tools").EllipseShape | import("../tools").PolygonShape | import("../tools").StarShape | import("../tools").RectangleShape | import("../tools").SpeechBalloonShape | import("../tools").LaserPenShape | import("../tools").EraserShape | BitMapEraserShape | PencilEraserShape | SelectorShape | ImageShape | ISvgShadowShape | undefined;
135
+ }): TextShape | import("../tools").ArrowShape | import("../tools").PencilShape | import("../tools/straight").StraightShape | import("../tools").EllipseShape | import("../tools").PolygonShape | import("../tools").StarShape | import("../tools").RectangleShape | import("../tools").SpeechBalloonShape | import("../tools").LaserPenShape | import("../tools").EraserShape | PencilEraserShape | BitMapEraserShape | SelectorShape | ImageShape | ISvgShadowShape | undefined;
133
136
  }
@@ -38,6 +38,7 @@ export declare class SubServiceMainThreadImpl implements SubServiceThread {
38
38
  private runAnimation;
39
39
  flush(): Promise<void>;
40
40
  private hasDiffData;
41
+ private syncMatrixRect;
41
42
  private activeWorkShape;
42
43
  private removeNode;
43
44
  private removeSelectWork;
@@ -33,7 +33,7 @@ export declare class SubTopThreadImpl implements SubTopThread {
33
33
  constructor(opt: ISubThreadInitOption);
34
34
  createLocalWork(data: IWorkerMessage): void;
35
35
  getLocalWorkShape(workId: string): ILocalWorkItem | undefined;
36
- createLocalWorkShape(workId: string, opt?: BaseShapeOptions): import("../tools/text").TextShape | import("../tools").ArrowShape | import("../tools").PencilShape | import("../tools/straight").StraightShape | import("../tools").EllipseShape | import("../tools").PolygonShape | import("../tools").StarShape | import("../tools").RectangleShape | import("../tools").SpeechBalloonShape | import("../tools").LaserPenShape | import("../tools").EraserShape | import("../tools").BitMapEraserShape | import("../tools/pencilEraser").PencilEraserShape | import("../tools").SelectorShape | import("../tools").ImageShape | import("../tools/shadowSvg").ISvgShadowShape | undefined;
36
+ createLocalWorkShape(workId: string, opt?: BaseShapeOptions): import("../tools/text").TextShape | import("../tools").ArrowShape | import("../tools").PencilShape | import("../tools/straight").StraightShape | import("../tools").EllipseShape | import("../tools").PolygonShape | import("../tools").StarShape | import("../tools").RectangleShape | import("../tools").SpeechBalloonShape | import("../tools").LaserPenShape | import("../tools").EraserShape | import("../tools/pencilEraser").PencilEraserShape | import("../tools").BitMapEraserShape | import("../tools").SelectorShape | import("../tools").ImageShape | import("../tools/shadowSvg").ISvgShadowShape | undefined;
37
37
  canUseTopLayer(toolsType: EToolsKey): toolsType is EToolsKey.LaserPen;
38
38
  destroy(): void;
39
39
  clearAll(): void;
@@ -42,7 +42,7 @@ export declare class SubTopThreadImpl implements SubTopThread {
42
42
  getToolsOpt(): IActiveToolsDataType | undefined;
43
43
  createWorkShapeNode(opt: IActiveToolsDataType & {
44
44
  workId: string;
45
- }): import("../tools/text").TextShape | import("../tools").ArrowShape | import("../tools").PencilShape | import("../tools/straight").StraightShape | import("../tools").EllipseShape | import("../tools").PolygonShape | import("../tools").StarShape | import("../tools").RectangleShape | import("../tools").SpeechBalloonShape | import("../tools").LaserPenShape | import("../tools").EraserShape | import("../tools").BitMapEraserShape | import("../tools/pencilEraser").PencilEraserShape | import("../tools").SelectorShape | import("../tools").ImageShape | import("../tools/shadowSvg").ISvgShadowShape | undefined;
45
+ }): import("../tools/text").TextShape | import("../tools").ArrowShape | import("../tools").PencilShape | import("../tools/straight").StraightShape | import("../tools").EllipseShape | import("../tools").PolygonShape | import("../tools").StarShape | import("../tools").RectangleShape | import("../tools").SpeechBalloonShape | import("../tools").LaserPenShape | import("../tools").EraserShape | import("../tools/pencilEraser").PencilEraserShape | import("../tools").BitMapEraserShape | import("../tools").SelectorShape | import("../tools").ImageShape | import("../tools/shadowSvg").ISvgShadowShape | undefined;
46
46
  private setNodeKey;
47
47
  private activeServiceWorkShape;
48
48
  private computNextAnimationIndex;