@vived/app 3.3.3 → 3.4.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.
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { AppObject } from "./AppObject";
|
|
2
|
+
import { AppObjectComponent } from "./AppObjectComponent";
|
|
3
|
+
export declare class AppObjectView implements AppObjectComponent {
|
|
4
|
+
readonly type: string;
|
|
5
|
+
readonly appObject: AppObject;
|
|
6
|
+
dispose(): void;
|
|
7
|
+
constructor(appObject: AppObject, type: string);
|
|
8
|
+
}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.AppObjectView = void 0;
|
|
4
|
+
class AppObjectView {
|
|
5
|
+
constructor(appObject, type) {
|
|
6
|
+
this.appObject = appObject;
|
|
7
|
+
this.type = type;
|
|
8
|
+
appObject.addComponent(this);
|
|
9
|
+
}
|
|
10
|
+
dispose() {
|
|
11
|
+
if (this.appObject.getComponent(this.type) === this) {
|
|
12
|
+
this.appObject.removeComponent(this.type);
|
|
13
|
+
}
|
|
14
|
+
}
|
|
15
|
+
;
|
|
16
|
+
}
|
|
17
|
+
exports.AppObjectView = AppObjectView;
|
package/lib/AppObject/index.d.ts
CHANGED
package/lib/AppObject/index.js
CHANGED