@netless/window-manager 0.4.21 → 0.4.24
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/CHANGELOG.md +12 -0
- package/dist/AppListener.d.ts +1 -0
- package/dist/AttributesDelegate.d.ts +9 -6
- package/dist/InternalEmitter.d.ts +1 -0
- package/dist/View/MainView.d.ts +3 -0
- package/dist/constants.d.ts +2 -1
- package/dist/index.cjs.js +47 -0
- package/dist/index.cjs.js.map +1 -0
- package/dist/index.es.js +44 -15
- package/dist/index.es.js.map +1 -1
- package/dist/index.umd.js +10 -10
- package/dist/index.umd.js.map +1 -1
- package/package.json +2 -2
- package/src/AppListener.ts +8 -0
- package/src/AppManager.ts +12 -8
- package/src/AttributesDelegate.ts +14 -2
- package/src/InternalEmitter.ts +1 -0
- package/src/View/MainView.ts +31 -13
- package/src/constants.ts +1 -0
- package/vite.config.js +1 -1
package/CHANGELOG.md
CHANGED
package/dist/AppListener.d.ts
CHANGED
@@ -31,6 +31,12 @@ export declare type StoreContext = {
|
|
31
31
|
safeUpdateAttributes: (keys: string[], value: any) => void;
|
32
32
|
safeSetAttributes: (attributes: any) => void;
|
33
33
|
};
|
34
|
+
export declare type ICamera = Camera & {
|
35
|
+
id: string;
|
36
|
+
};
|
37
|
+
export declare type ISize = Size & {
|
38
|
+
id: string;
|
39
|
+
};
|
34
40
|
export declare class AttributesDelegate {
|
35
41
|
private context;
|
36
42
|
constructor(context: StoreContext);
|
@@ -55,12 +61,9 @@ export declare class AttributesDelegate {
|
|
55
61
|
setMainViewSceneIndex(index: number): void;
|
56
62
|
getMainViewCamera(): MainViewCamera;
|
57
63
|
getMainViewSize(): MainViewSize;
|
58
|
-
setMainViewCamera(camera:
|
59
|
-
|
60
|
-
|
61
|
-
setMainViewSize(size: (Size & {
|
62
|
-
id: string;
|
63
|
-
}) | undefined): void;
|
64
|
+
setMainViewCamera(camera: ICamera): void;
|
65
|
+
setMainViewSize(size: ISize): void;
|
66
|
+
setMainViewCameraAndSize(camera: ICamera, size: ISize): void;
|
64
67
|
setAppFocus: (appId: string, focus: boolean) => void;
|
65
68
|
updateCursor(uid: string, position: Position): void;
|
66
69
|
updateCursorState(uid: string, cursorState: string | undefined): void;
|
@@ -39,6 +39,7 @@ export declare type EmitterEvent = {
|
|
39
39
|
rootDirRemoved: undefined;
|
40
40
|
setReadonly: boolean;
|
41
41
|
changePageState: undefined;
|
42
|
+
writableChange: boolean;
|
42
43
|
};
|
43
44
|
export declare type EmitterType = Emittery<EmitterEvent>;
|
44
45
|
export declare const emitter: EmitterType;
|
package/dist/View/MainView.d.ts
CHANGED
@@ -9,10 +9,13 @@ export declare class MainViewProxy {
|
|
9
9
|
private store;
|
10
10
|
private sideEffectManager;
|
11
11
|
constructor(manager: AppManager);
|
12
|
+
private startListenWritableChange;
|
13
|
+
ensureCameraAndSize(): void;
|
12
14
|
private get mainViewCamera();
|
13
15
|
private get mainViewSize();
|
14
16
|
private moveCameraSizeByAttributes;
|
15
17
|
start(): void;
|
18
|
+
addCameraReaction: () => void;
|
16
19
|
setCameraAndSize(): void;
|
17
20
|
private cameraReaction;
|
18
21
|
private sizeChangeHandler;
|
package/dist/constants.d.ts
CHANGED
@@ -14,7 +14,8 @@ export declare enum Events {
|
|
14
14
|
MoveCameraToContain = "MoveCameraToContain",
|
15
15
|
CursorMove = "CursorMove",
|
16
16
|
RootDirRemoved = "RootDirRemoved",
|
17
|
-
Refresh = "Refresh"
|
17
|
+
Refresh = "Refresh",
|
18
|
+
InitMainViewCamera = "InitMainViewCamera"
|
18
19
|
}
|
19
20
|
export declare const MagixEventName = "__WindowManger";
|
20
21
|
export declare enum AppAttributes {
|