@vived/app 4.28.0 → 4.28.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/lib/Components/Babylon/Factories/index.d.ts +1 -0
- package/lib/Components/Babylon/Factories/index.js +13 -0
- package/lib/Components/Babylon/Factories/setupBabylon.d.ts +2 -0
- package/lib/Components/Babylon/Factories/setupBabylon.js +11 -0
- package/lib/Components/Babylon/index.d.ts +2 -0
- package/lib/Components/Babylon/index.js +2 -0
- package/lib/Components/BaseApp/Factories/index.d.ts +1 -0
- package/lib/Components/BaseApp/Factories/index.js +13 -0
- package/lib/Components/BaseApp/Factories/setupBaseApp.d.ts +2 -0
- package/lib/Components/BaseApp/Factories/setupBaseApp.js +22 -0
- package/lib/Components/BaseApp/index.d.ts +1 -0
- package/lib/Components/BaseApp/index.js +1 -0
- package/lib/Components/Callouts/Factories/calloutFactory.d.ts +3 -0
- package/lib/Components/Callouts/Factories/calloutFactory.js +42 -0
- package/lib/Components/Callouts/Factories/calloutRepoFactory.d.ts +3 -0
- package/lib/Components/Callouts/Factories/calloutRepoFactory.js +19 -0
- package/lib/Components/Callouts/Factories/index.d.ts +3 -0
- package/lib/Components/Callouts/Factories/index.js +15 -0
- package/lib/Components/Callouts/Factories/setupCallouts.d.ts +2 -0
- package/lib/Components/Callouts/Factories/setupCallouts.js +24 -0
- package/lib/Components/Callouts/index.d.ts +1 -0
- package/lib/Components/Callouts/index.js +1 -0
- package/lib/Components/Camera/Factories/index.d.ts +1 -0
- package/lib/Components/Camera/Factories/index.js +13 -0
- package/lib/Components/Camera/Factories/setupCamera.d.ts +2 -0
- package/lib/Components/Camera/Factories/setupCamera.js +15 -0
- package/lib/Components/Camera/index.d.ts +1 -0
- package/lib/Components/Camera/index.js +1 -0
- package/lib/Components/Challenge/Factories/index.d.ts +1 -0
- package/lib/Components/Challenge/Factories/index.js +13 -0
- package/lib/Components/Challenge/Factories/setupChallenge.d.ts +2 -0
- package/lib/Components/Challenge/Factories/setupChallenge.js +46 -0
- package/lib/Components/Challenge/UCs/SetChallengeUC.d.ts +1 -1
- package/lib/Components/Challenge/index.d.ts +1 -0
- package/lib/Components/Challenge/index.js +1 -0
- package/lib/Components/ChannelModel/Factories/channelModelFactory.d.ts +3 -0
- package/lib/Components/ChannelModel/Factories/channelModelFactory.js +14 -0
- package/lib/Components/ChannelModel/Factories/channelObjectFactory.d.ts +3 -0
- package/lib/Components/ChannelModel/Factories/channelObjectFactory.js +19 -0
- package/lib/Components/ChannelModel/Factories/index.d.ts +3 -0
- package/lib/Components/ChannelModel/Factories/index.js +15 -0
- package/lib/Components/ChannelModel/Factories/setupChannelModels.d.ts +2 -0
- package/lib/Components/ChannelModel/Factories/setupChannelModels.js +25 -0
- package/lib/Components/ChannelModel/index.d.ts +1 -0
- package/lib/Components/ChannelModel/index.js +1 -0
- package/lib/Components/Dispatcher/Factories/index.d.ts +1 -0
- package/lib/Components/Dispatcher/Factories/index.js +13 -0
- package/lib/Components/Dispatcher/Factories/setupDispatchers.d.ts +3 -0
- package/lib/Components/Dispatcher/Factories/setupDispatchers.js +35 -0
- package/lib/Components/Dispatcher/index.d.ts +1 -0
- package/lib/Components/Dispatcher/index.js +1 -0
- package/lib/Components/GLBModel/Factories/glbModelFactory.d.ts +3 -0
- package/lib/Components/GLBModel/Factories/glbModelFactory.js +12 -0
- package/lib/Components/GLBModel/Factories/index.d.ts +2 -0
- package/lib/Components/GLBModel/Factories/index.js +14 -0
- package/lib/Components/GLBModel/Factories/setupGLBModel.d.ts +2 -0
- package/lib/Components/GLBModel/Factories/setupGLBModel.js +11 -0
- package/lib/Components/GLBModel/index.d.ts +1 -0
- package/lib/Components/GLBModel/index.js +1 -0
- package/lib/Components/KeyboardInput/Factories/index.d.ts +1 -0
- package/lib/Components/KeyboardInput/Factories/index.js +13 -0
- package/lib/Components/KeyboardInput/Factories/setupKeyboard.d.ts +2 -0
- package/lib/Components/KeyboardInput/Factories/setupKeyboard.js +9 -0
- package/lib/Components/KeyboardInput/index.d.ts +1 -0
- package/lib/Components/KeyboardInput/index.js +1 -0
- package/lib/Components/LabelDrop/Factories/index.d.ts +2 -0
- package/lib/Components/LabelDrop/Factories/index.js +14 -0
- package/lib/Components/LabelDrop/Factories/labelDropItemFactory.d.ts +3 -0
- package/lib/Components/LabelDrop/Factories/labelDropItemFactory.js +24 -0
- package/lib/Components/LabelDrop/Factories/setupLabelDrop.d.ts +2 -0
- package/lib/Components/LabelDrop/Factories/setupLabelDrop.js +51 -0
- package/lib/Components/LabelDrop/index.d.ts +1 -0
- package/lib/Components/LabelDrop/index.js +1 -0
- package/lib/Components/Landmarks/Factories/index.d.ts +3 -0
- package/lib/Components/Landmarks/Factories/index.js +15 -0
- package/lib/Components/Landmarks/Factories/landmarkFactory.d.ts +3 -0
- package/lib/Components/Landmarks/Factories/landmarkFactory.js +40 -0
- package/lib/Components/Landmarks/Factories/landmarkRepoFactory.d.ts +3 -0
- package/lib/Components/Landmarks/Factories/landmarkRepoFactory.js +16 -0
- package/lib/Components/Landmarks/Factories/setupLandmarks.d.ts +2 -0
- package/lib/Components/Landmarks/Factories/setupLandmarks.js +32 -0
- package/lib/Components/Landmarks/UseCases/TryAddNewLandmarkUC.d.ts +2 -2
- package/lib/Components/Landmarks/UseCases/TryAddNewLandmarkUC.js +2 -2
- package/lib/Components/Landmarks/UseCases/TryPreviewLandmarkUC.d.ts +2 -2
- package/lib/Components/Landmarks/UseCases/TryPreviewLandmarkUC.js +2 -2
- package/lib/Components/Landmarks/index.d.ts +1 -0
- package/lib/Components/Landmarks/index.js +1 -0
- package/lib/Components/ObjectPick/Factories/index.d.ts +1 -0
- package/lib/Components/ObjectPick/Factories/index.js +13 -0
- package/lib/Components/ObjectPick/Factories/setupObjectPick.d.ts +2 -0
- package/lib/Components/ObjectPick/Factories/setupObjectPick.js +26 -0
- package/lib/Components/ObjectPick/index.d.ts +1 -0
- package/lib/Components/ObjectPick/index.js +1 -0
- package/lib/Components/RequestHandler/Factories/index.d.ts +1 -0
- package/lib/Components/RequestHandler/Factories/index.js +13 -0
- package/lib/Components/RequestHandler/Factories/setupAppHandlers.d.ts +3 -0
- package/lib/Components/RequestHandler/Factories/setupAppHandlers.js +20 -0
- package/lib/Components/RequestHandler/index.d.ts +1 -0
- package/lib/Components/RequestHandler/index.js +1 -0
- package/lib/Components/StateMachine/Factories/index.d.ts +1 -0
- package/lib/Components/StateMachine/Factories/index.js +13 -0
- package/lib/Components/StateMachine/Factories/setupStateMachine.d.ts +2 -0
- package/lib/Components/StateMachine/Factories/setupStateMachine.js +12 -0
- package/lib/Components/StateMachine/index.d.ts +1 -0
- package/lib/Components/StateMachine/index.js +1 -0
- package/lib/Components/ThemeColors/Factories/index.d.ts +1 -0
- package/lib/Components/ThemeColors/Factories/index.js +13 -0
- package/lib/Components/ThemeColors/Factories/setupTheme.d.ts +2 -0
- package/lib/Components/ThemeColors/Factories/setupTheme.js +12 -0
- package/lib/Components/ThemeColors/index.d.ts +1 -0
- package/lib/Components/ThemeColors/index.js +1 -0
- package/package.json +1 -1
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
|
|
5
|
+
}) : (function(o, m, k, k2) {
|
|
6
|
+
if (k2 === undefined) k2 = k;
|
|
7
|
+
o[k2] = m[k];
|
|
8
|
+
}));
|
|
9
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
10
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
11
|
+
};
|
|
12
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
13
|
+
__exportStar(require("./setupGLBModel"), exports);
|
|
14
|
+
__exportStar(require("./glbModelFactory"), exports);
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.setupGLBModel = void 0;
|
|
4
|
+
const Entities_1 = require("../Entities");
|
|
5
|
+
const glbModelFactory_1 = require("./glbModelFactory");
|
|
6
|
+
function setupGLBModel(appObjects) {
|
|
7
|
+
const ao = appObjects.getOrCreate("GLBModels");
|
|
8
|
+
const repo = Entities_1.makeGlbModelRepo(ao);
|
|
9
|
+
repo.glbModelFactory = glbModelFactory_1.makeGlbModelFactory(appObjects);
|
|
10
|
+
}
|
|
11
|
+
exports.setupGLBModel = setupGLBModel;
|
|
@@ -11,5 +11,6 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
11
11
|
};
|
|
12
12
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
13
13
|
__exportStar(require("./Entities"), exports);
|
|
14
|
+
__exportStar(require("./Factories"), exports);
|
|
14
15
|
__exportStar(require("./Mocks"), exports);
|
|
15
16
|
__exportStar(require("./UCs"), exports);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./setupKeyboard";
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
|
|
5
|
+
}) : (function(o, m, k, k2) {
|
|
6
|
+
if (k2 === undefined) k2 = k;
|
|
7
|
+
o[k2] = m[k];
|
|
8
|
+
}));
|
|
9
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
10
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
11
|
+
};
|
|
12
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
13
|
+
__exportStar(require("./setupKeyboard"), exports);
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.setupKeyboard = void 0;
|
|
4
|
+
const Entities_1 = require("../Entities");
|
|
5
|
+
function setupKeyboard(appObject) {
|
|
6
|
+
const ao = appObject.getOrCreate("Keyboard");
|
|
7
|
+
Entities_1.makeKeyboardInput(ao);
|
|
8
|
+
}
|
|
9
|
+
exports.setupKeyboard = setupKeyboard;
|
|
@@ -11,4 +11,5 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
11
11
|
};
|
|
12
12
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
13
13
|
__exportStar(require("./Entities"), exports);
|
|
14
|
+
__exportStar(require("./Factories"), exports);
|
|
14
15
|
__exportStar(require("./Mocks"), exports);
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
|
|
5
|
+
}) : (function(o, m, k, k2) {
|
|
6
|
+
if (k2 === undefined) k2 = k;
|
|
7
|
+
o[k2] = m[k];
|
|
8
|
+
}));
|
|
9
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
10
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
11
|
+
};
|
|
12
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
13
|
+
__exportStar(require("./labelDropItemFactory"), exports);
|
|
14
|
+
__exportStar(require("./setupLabelDrop"), exports);
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.makeLabelDropItemFactory = void 0;
|
|
4
|
+
const PM_1 = require("../../Label/PM");
|
|
5
|
+
const UC_1 = require("../../Label/UC");
|
|
6
|
+
const Entities_1 = require("../Entities");
|
|
7
|
+
const PM_2 = require("../PM");
|
|
8
|
+
const UseCases_1 = require("../UseCases");
|
|
9
|
+
function makeLabelDropItemFactory(appObjects) {
|
|
10
|
+
return function labelDropItemFactory(id) {
|
|
11
|
+
const ao = appObjects.getOrCreate(id);
|
|
12
|
+
const entity = new Entities_1.LabelDropItemEntity(ao);
|
|
13
|
+
// UCs
|
|
14
|
+
new UC_1.SetCustomLabelUC(ao);
|
|
15
|
+
new UC_1.ClearCustomLabelUC(ao);
|
|
16
|
+
new UseCases_1.InitializeLabelDropLabelHook(ao);
|
|
17
|
+
// PMs
|
|
18
|
+
PM_1.makeLabelPM(ao);
|
|
19
|
+
PM_2.makeLabelDropTargetsPM(ao);
|
|
20
|
+
entity.labelEntity.customLabelValidator = UseCases_1.labelDropLabelValidator;
|
|
21
|
+
return entity;
|
|
22
|
+
};
|
|
23
|
+
}
|
|
24
|
+
exports.makeLabelDropItemFactory = makeLabelDropItemFactory;
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.setupLabelDrop = void 0;
|
|
4
|
+
const ValueObjects_1 = require("../../../ValueObjects");
|
|
5
|
+
const Stylus_1 = require("../../Stylus");
|
|
6
|
+
const Transform3D_1 = require("../../Transform3D");
|
|
7
|
+
const Controller_1 = require("../Controller");
|
|
8
|
+
const Entities_1 = require("../Entities");
|
|
9
|
+
const PM_1 = require("../PM");
|
|
10
|
+
const UseCases_1 = require("../UseCases");
|
|
11
|
+
const labelDropItemFactory_1 = require("./labelDropItemFactory");
|
|
12
|
+
function setupLabelDrop(appObjects) {
|
|
13
|
+
const ao = appObjects.getOrCreate("LabelDrop");
|
|
14
|
+
// Entity
|
|
15
|
+
const labelDropEntity = Entities_1.makeLabelDropRepo(ao);
|
|
16
|
+
labelDropEntity.labelDropItemFactory = labelDropItemFactory_1.makeLabelDropItemFactory(appObjects);
|
|
17
|
+
// UCs
|
|
18
|
+
new UseCases_1.SerializeLabelDrop(ao);
|
|
19
|
+
UseCases_1.makeEditLabelDropUC(ao);
|
|
20
|
+
UseCases_1.makeDragLabelDropUC(ao);
|
|
21
|
+
UseCases_1.makeDragLabelDropWorldUC(ao);
|
|
22
|
+
UseCases_1.makeDeleteLabelDropUC(ao);
|
|
23
|
+
UseCases_1.makeDeleteAllLabelDropUC(ao);
|
|
24
|
+
UseCases_1.makeToggleLabelDropTargetUC(ao);
|
|
25
|
+
UseCases_1.makeLabelDropCorrectAnimationUC(ao);
|
|
26
|
+
UseCases_1.makeLabelDropOnNothingAnimationUC(ao);
|
|
27
|
+
UseCases_1.makeLabelDropIncorrectAnimationUC(ao);
|
|
28
|
+
UseCases_1.makeValidateLabelDrop(ao);
|
|
29
|
+
// PMs
|
|
30
|
+
PM_1.makeLabelDropEditingIDPM(ao);
|
|
31
|
+
PM_1.makeRemainingLabelDropListPM(ao);
|
|
32
|
+
PM_1.makeLabelDropReviewPM(ao);
|
|
33
|
+
Transform3D_1.makeTransform3DPM(ao);
|
|
34
|
+
PM_1.makeLabelDropDragItemPM(ao);
|
|
35
|
+
PM_1.makeLabelDropListPM(ao);
|
|
36
|
+
// Controllers
|
|
37
|
+
Controller_1.makeMouseLabelDropAuthor(ao);
|
|
38
|
+
Controller_1.makeTouchLabelDropAuthor(ao);
|
|
39
|
+
Controller_1.makeStylusLabelDrop(ao);
|
|
40
|
+
const stylus = Stylus_1.StylusEntity.get(appObjects);
|
|
41
|
+
if (!stylus) {
|
|
42
|
+
appObjects.submitError("setupLabelDrop", "StylusEntity needs to be setup before Label Drop");
|
|
43
|
+
}
|
|
44
|
+
else {
|
|
45
|
+
labelDropEntity.dragHelperTransform.parent = stylus.transform;
|
|
46
|
+
labelDropEntity.dragHelperTransform.localPosition = ValueObjects_1.Vector3.Zero();
|
|
47
|
+
labelDropEntity.dragHelperTransform.localRotation = ValueObjects_1.Quaternion.Identity();
|
|
48
|
+
labelDropEntity.dragHelperTransform.localScale = ValueObjects_1.Vector3.One();
|
|
49
|
+
}
|
|
50
|
+
}
|
|
51
|
+
exports.setupLabelDrop = setupLabelDrop;
|
|
@@ -13,6 +13,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
13
13
|
__exportStar(require("./Adapters"), exports);
|
|
14
14
|
__exportStar(require("./Controller"), exports);
|
|
15
15
|
__exportStar(require("./Entities"), exports);
|
|
16
|
+
__exportStar(require("./Factories"), exports);
|
|
16
17
|
__exportStar(require("./Mocks"), exports);
|
|
17
18
|
__exportStar(require("./PM"), exports);
|
|
18
19
|
__exportStar(require("./UseCases"), exports);
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
|
|
5
|
+
}) : (function(o, m, k, k2) {
|
|
6
|
+
if (k2 === undefined) k2 = k;
|
|
7
|
+
o[k2] = m[k];
|
|
8
|
+
}));
|
|
9
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
10
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
11
|
+
};
|
|
12
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
13
|
+
__exportStar(require("./landmarkFactory"), exports);
|
|
14
|
+
__exportStar(require("./landmarkRepoFactory"), exports);
|
|
15
|
+
__exportStar(require("./setupLandmarks"), exports);
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.makeLandmarkFactory = void 0;
|
|
4
|
+
const PM_1 = require("../../Hideable/PM");
|
|
5
|
+
const PM_2 = require("../../Label/PM");
|
|
6
|
+
const UC_1 = require("../../Label/UC");
|
|
7
|
+
const OverlayColor_1 = require("../../OverlayColor");
|
|
8
|
+
const Selection_1 = require("../../Selection");
|
|
9
|
+
const Transform3D_1 = require("../../Transform3D");
|
|
10
|
+
const Entities_1 = require("../Entities");
|
|
11
|
+
const PM_3 = require("../PM");
|
|
12
|
+
const UseCases_1 = require("../UseCases");
|
|
13
|
+
function makeLandmarkFactory(appObjects) {
|
|
14
|
+
return function landmarkFactory(id) {
|
|
15
|
+
const appObject = appObjects.getOrCreate(id);
|
|
16
|
+
let landmarkEntity = Entities_1.LandmarkEntity.get(appObject);
|
|
17
|
+
if (!landmarkEntity) {
|
|
18
|
+
landmarkEntity = Entities_1.makeLandmarkEntity(appObject);
|
|
19
|
+
}
|
|
20
|
+
// UCs
|
|
21
|
+
new OverlayColor_1.SetOverlayColorUC(appObject);
|
|
22
|
+
new UC_1.SetCustomLabelUC(appObject);
|
|
23
|
+
new UC_1.ClearCustomLabelUC(appObject);
|
|
24
|
+
UseCases_1.makeSetLandmarkSizeUC(appObject);
|
|
25
|
+
UseCases_1.makeDeleteLandmarkUC(appObject);
|
|
26
|
+
// PMs
|
|
27
|
+
Transform3D_1.makeTransform3DPM(appObject);
|
|
28
|
+
OverlayColor_1.makeOverlayColorPM(appObject);
|
|
29
|
+
Selection_1.makeSelectableStatePM(appObject);
|
|
30
|
+
PM_1.makeIsHiddenPM(appObject);
|
|
31
|
+
PM_2.makeLabelPM(appObject);
|
|
32
|
+
PM_3.makeLandmarkSizePM(appObject);
|
|
33
|
+
const selection = Selection_1.Selection.get(appObject.appObjectRepo);
|
|
34
|
+
if (selection) {
|
|
35
|
+
selection.addSelectable(landmarkEntity.selectable);
|
|
36
|
+
}
|
|
37
|
+
return landmarkEntity;
|
|
38
|
+
};
|
|
39
|
+
}
|
|
40
|
+
exports.makeLandmarkFactory = makeLandmarkFactory;
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.makeLandmarkRepoFactory = void 0;
|
|
4
|
+
const Entities_1 = require("../Entities");
|
|
5
|
+
const PM_1 = require("../PM");
|
|
6
|
+
const landmarkFactory_1 = require("./landmarkFactory");
|
|
7
|
+
function makeLandmarkRepoFactory(appObjects) {
|
|
8
|
+
return function landmarkRepoFactory(id) {
|
|
9
|
+
const appObject = appObjects.getOrCreate(id);
|
|
10
|
+
const repo = Entities_1.LandmarkRepo.addIfMissing(appObject);
|
|
11
|
+
repo.landmarkFactory = landmarkFactory_1.makeLandmarkFactory(appObjects);
|
|
12
|
+
PM_1.makeLandmarkListPM(appObject);
|
|
13
|
+
return repo;
|
|
14
|
+
};
|
|
15
|
+
}
|
|
16
|
+
exports.makeLandmarkRepoFactory = makeLandmarkRepoFactory;
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.setupLandmarks = void 0;
|
|
4
|
+
const Hideable_1 = require("../../Hideable");
|
|
5
|
+
const OverlayColor_1 = require("../../OverlayColor");
|
|
6
|
+
const Selection_1 = require("../../Selection");
|
|
7
|
+
const Transform3D_1 = require("../../Transform3D");
|
|
8
|
+
const Controller_1 = require("../Controller");
|
|
9
|
+
const Entities_1 = require("../Entities");
|
|
10
|
+
const UseCases_1 = require("../UseCases");
|
|
11
|
+
const landmarkRepoFactory_1 = require("./landmarkRepoFactory");
|
|
12
|
+
function setupLandmarks(appObjects) {
|
|
13
|
+
const landmarksAO = appObjects.getOrCreate("Landmarks");
|
|
14
|
+
const globals = Entities_1.makeLandmarkGlobals(landmarksAO);
|
|
15
|
+
globals.landmarkRepoFactory = landmarkRepoFactory_1.makeLandmarkRepoFactory(appObjects);
|
|
16
|
+
// UCs
|
|
17
|
+
new UseCases_1.SerializeLandmarks(landmarksAO);
|
|
18
|
+
UseCases_1.makeDeleteAllLandmarksUC(landmarksAO);
|
|
19
|
+
UseCases_1.makeTryAddLandmarkUC(landmarksAO);
|
|
20
|
+
// Controllers
|
|
21
|
+
Controller_1.makeMouseLandmark(landmarksAO);
|
|
22
|
+
Controller_1.makeTouchLandmark(landmarksAO);
|
|
23
|
+
const previewAO = appObjects.getOrCreate("LandmarkPreview");
|
|
24
|
+
const preview = Entities_1.makeLandmarkEntity(previewAO);
|
|
25
|
+
UseCases_1.makeTryPreviewLandmark(previewAO);
|
|
26
|
+
Transform3D_1.makeTransform3DPM(previewAO);
|
|
27
|
+
OverlayColor_1.makeOverlayColorPM(previewAO);
|
|
28
|
+
Selection_1.makeSelectableStatePM(previewAO);
|
|
29
|
+
Hideable_1.makeIsHiddenPM(previewAO);
|
|
30
|
+
globals.previewLandmark = preview;
|
|
31
|
+
}
|
|
32
|
+
exports.setupLandmarks = setupLandmarks;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { AppObject, AppObjectUC } from "../../../AppObject";
|
|
1
|
+
import { AppObject, AppObjectRepo, AppObjectUC } from "../../../AppObject";
|
|
2
2
|
import { ParametricLine } from "../../../ValueObjects";
|
|
3
3
|
import { LandmarkEntity } from "../Entities/LandmarkEntity";
|
|
4
4
|
export declare abstract class TryAddNewLandmarkUC extends AppObjectUC {
|
|
5
5
|
static readonly type = "TryAddNewLandmarkUC";
|
|
6
6
|
abstract allow(): boolean;
|
|
7
7
|
abstract addFromRay(ray: ParametricLine): LandmarkEntity | undefined;
|
|
8
|
-
static get(
|
|
8
|
+
static get(appObjects: AppObjectRepo): TryAddNewLandmarkUC | undefined;
|
|
9
9
|
}
|
|
10
10
|
export declare function makeTryAddLandmarkUC(appObject: AppObject): TryAddNewLandmarkUC;
|
|
@@ -10,8 +10,8 @@ const Entities_1 = require("../Entities");
|
|
|
10
10
|
const LandmarkGlobals_1 = require("../Entities/LandmarkGlobals");
|
|
11
11
|
const AddLandmarkUndoRedo_1 = require("./AddLandmarkUndoRedo");
|
|
12
12
|
class TryAddNewLandmarkUC extends AppObject_1.AppObjectUC {
|
|
13
|
-
static get(
|
|
14
|
-
return
|
|
13
|
+
static get(appObjects) {
|
|
14
|
+
return AppObject_1.getSingletonComponent(this.type, appObjects);
|
|
15
15
|
}
|
|
16
16
|
}
|
|
17
17
|
exports.TryAddNewLandmarkUC = TryAddNewLandmarkUC;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { AppObject, AppObjectUC } from "../../../AppObject";
|
|
1
|
+
import { AppObject, AppObjectRepo, AppObjectUC } from "../../../AppObject";
|
|
2
2
|
import { ParametricLine } from "../../../ValueObjects";
|
|
3
3
|
export declare abstract class TryPreviewLandmarkUC extends AppObjectUC {
|
|
4
4
|
static readonly type = "TryPreviewLandmarkUC";
|
|
5
5
|
abstract allow(): boolean;
|
|
6
6
|
abstract tryPreviewLandmark: (ray: ParametricLine, pressed: boolean) => boolean | undefined;
|
|
7
7
|
abstract hidePreview: () => void;
|
|
8
|
-
static get(
|
|
8
|
+
static get(appObjects: AppObjectRepo): TryPreviewLandmarkUC | undefined;
|
|
9
9
|
}
|
|
10
10
|
export declare function makeTryPreviewLandmark(appObject: AppObject): TryPreviewLandmarkUC;
|
|
@@ -7,8 +7,8 @@ const Babylon_1 = require("../../Babylon");
|
|
|
7
7
|
const LandmarkEntity_1 = require("../Entities/LandmarkEntity");
|
|
8
8
|
const LandmarkRepo_1 = require("../Entities/LandmarkRepo");
|
|
9
9
|
class TryPreviewLandmarkUC extends AppObject_1.AppObjectUC {
|
|
10
|
-
static get(
|
|
11
|
-
return
|
|
10
|
+
static get(appObjects) {
|
|
11
|
+
return AppObject_1.getSingletonComponent(this.type, appObjects);
|
|
12
12
|
}
|
|
13
13
|
}
|
|
14
14
|
exports.TryPreviewLandmarkUC = TryPreviewLandmarkUC;
|
|
@@ -13,6 +13,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
13
13
|
__exportStar(require("./Adapters"), exports);
|
|
14
14
|
__exportStar(require("./Controller"), exports);
|
|
15
15
|
__exportStar(require("./Entities"), exports);
|
|
16
|
+
__exportStar(require("./Factories"), exports);
|
|
16
17
|
__exportStar(require("./Mocks"), exports);
|
|
17
18
|
__exportStar(require("./PM"), exports);
|
|
18
19
|
__exportStar(require("./UseCases"), exports);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./setupObjectPick";
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
|
|
5
|
+
}) : (function(o, m, k, k2) {
|
|
6
|
+
if (k2 === undefined) k2 = k;
|
|
7
|
+
o[k2] = m[k];
|
|
8
|
+
}));
|
|
9
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
10
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
11
|
+
};
|
|
12
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
13
|
+
__exportStar(require("./setupObjectPick"), exports);
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.setupObjectPick = void 0;
|
|
4
|
+
const Controllers_1 = require("../Controllers");
|
|
5
|
+
const Entities_1 = require("../Entities");
|
|
6
|
+
const PM_1 = require("../PM");
|
|
7
|
+
const UseCases_1 = require("../UseCases");
|
|
8
|
+
function setupObjectPick(appObjects) {
|
|
9
|
+
const ao = appObjects.getOrCreate("ObjectPick");
|
|
10
|
+
Entities_1.makeObjectPickEntity(ao);
|
|
11
|
+
// UCs
|
|
12
|
+
UseCases_1.makeAddCorrectObjectIdUC(ao);
|
|
13
|
+
UseCases_1.makeClearCorrectObjectIdsUC(ao);
|
|
14
|
+
UseCases_1.makeRemoveCorrectObjectIdUC(ao);
|
|
15
|
+
UseCases_1.makeTrySelectObjectPickUC(ao);
|
|
16
|
+
UseCases_1.makeTrySubmitObjectPickUC(ao);
|
|
17
|
+
UseCases_1.makeValidateObjectPickUC(ao);
|
|
18
|
+
new UseCases_1.SerializeObjectPick(ao);
|
|
19
|
+
// PMs
|
|
20
|
+
PM_1.makeObjectPickPM(ao);
|
|
21
|
+
// Controllers
|
|
22
|
+
new Controllers_1.MouseObjectPickMC(ao);
|
|
23
|
+
new Controllers_1.TouchObjectPickTC(ao);
|
|
24
|
+
new Controllers_1.StylusObjectPickSC(ao);
|
|
25
|
+
}
|
|
26
|
+
exports.setupObjectPick = setupObjectPick;
|
|
@@ -13,6 +13,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
13
13
|
__exportStar(require("./Adapters"), exports);
|
|
14
14
|
__exportStar(require("./Controllers"), exports);
|
|
15
15
|
__exportStar(require("./Entities"), exports);
|
|
16
|
+
__exportStar(require("./Factories"), exports);
|
|
16
17
|
__exportStar(require("./Mocks"), exports);
|
|
17
18
|
__exportStar(require("./PM"), exports);
|
|
18
19
|
__exportStar(require("./UseCases"), exports);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./setupAppHandlers";
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
|
|
5
|
+
}) : (function(o, m, k, k2) {
|
|
6
|
+
if (k2 === undefined) k2 = k;
|
|
7
|
+
o[k2] = m[k];
|
|
8
|
+
}));
|
|
9
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
10
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
11
|
+
};
|
|
12
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
13
|
+
__exportStar(require("./setupAppHandlers"), exports);
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.setupAppHandlers = void 0;
|
|
4
|
+
const Entities_1 = require("../Entities");
|
|
5
|
+
const UC_1 = require("../UC");
|
|
6
|
+
function setupAppHandlers(appObjects) {
|
|
7
|
+
const handlerAO = appObjects.getOrCreate("AppHandlers");
|
|
8
|
+
const appHandler = Entities_1.makeAppHandler(handlerAO);
|
|
9
|
+
UC_1.makeDisposeAppUC(handlerAO);
|
|
10
|
+
UC_1.makeSetAppStateUC(handlerAO);
|
|
11
|
+
UC_1.makeSetIsAuthoringUC(handlerAO);
|
|
12
|
+
UC_1.makeSetThemeColorUC(handlerAO);
|
|
13
|
+
UC_1.makeShowBabylonInspectorUC(handlerAO);
|
|
14
|
+
UC_1.makeStartAppUC(handlerAO);
|
|
15
|
+
UC_1.makeStartZSpaceUC(handlerAO);
|
|
16
|
+
UC_1.makeStopAppUC(handlerAO);
|
|
17
|
+
UC_1.makeStopZSpaceUC(handlerAO);
|
|
18
|
+
return appHandler;
|
|
19
|
+
}
|
|
20
|
+
exports.setupAppHandlers = setupAppHandlers;
|
|
@@ -11,4 +11,5 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
11
11
|
};
|
|
12
12
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
13
13
|
__exportStar(require("./Entities"), exports);
|
|
14
|
+
__exportStar(require("./Factories"), exports);
|
|
14
15
|
__exportStar(require("./UC"), exports);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./setupStateMachine";
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
|
|
5
|
+
}) : (function(o, m, k, k2) {
|
|
6
|
+
if (k2 === undefined) k2 = k;
|
|
7
|
+
o[k2] = m[k];
|
|
8
|
+
}));
|
|
9
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
10
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
11
|
+
};
|
|
12
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
13
|
+
__exportStar(require("./setupStateMachine"), exports);
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.setupStateMachine = void 0;
|
|
4
|
+
const Utilities_1 = require("../../../Utilities");
|
|
5
|
+
const Entities_1 = require("../Entities");
|
|
6
|
+
function setupStateMachine(appObjects) {
|
|
7
|
+
const ao = appObjects.getOrCreate("StateMachine");
|
|
8
|
+
const stateMachine = Entities_1.makeStateMachineEntity(ao);
|
|
9
|
+
// Setup
|
|
10
|
+
stateMachine.transitionEaseFunction = Utilities_1.cubicInOut;
|
|
11
|
+
}
|
|
12
|
+
exports.setupStateMachine = setupStateMachine;
|
|
@@ -12,4 +12,5 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
12
12
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
13
13
|
__exportStar(require("./Controller"), exports);
|
|
14
14
|
__exportStar(require("./Entities"), exports);
|
|
15
|
+
__exportStar(require("./Factories"), exports);
|
|
15
16
|
__exportStar(require("./Mocks"), exports);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./setupTheme";
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
|
|
5
|
+
}) : (function(o, m, k, k2) {
|
|
6
|
+
if (k2 === undefined) k2 = k;
|
|
7
|
+
o[k2] = m[k];
|
|
8
|
+
}));
|
|
9
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
10
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
11
|
+
};
|
|
12
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
13
|
+
__exportStar(require("./setupTheme"), exports);
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.setupTheme = void 0;
|
|
4
|
+
const Entities_1 = require("../Entities");
|
|
5
|
+
const PM_1 = require("../PM");
|
|
6
|
+
function setupTheme(appObjects) {
|
|
7
|
+
const themeAO = appObjects.getOrCreate("ThemeColors");
|
|
8
|
+
Entities_1.makeThemeColors(themeAO);
|
|
9
|
+
// Setup PMs
|
|
10
|
+
new PM_1.ThemeColorMapPM(themeAO);
|
|
11
|
+
}
|
|
12
|
+
exports.setupTheme = setupTheme;
|