@configura/babylon-view 1.4.0 → 1.6.0-alpha.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.
- package/LICENSE +201 -201
- package/README.md +1 -1
- package/dist/animation/AnimatableObject.d.ts +8 -8
- package/dist/animation/AnimatableObject.js +3 -3
- package/dist/animation/animator/Animator.d.ts +33 -33
- package/dist/animation/animator/Animator.js +58 -58
- package/dist/animation/animator/AnimatorEasing.d.ts +16 -16
- package/dist/animation/animator/AnimatorEasing.js +31 -31
- package/dist/animation/animator/AnimatorEasingMatrix.d.ts +14 -14
- package/dist/animation/animator/AnimatorEasingMatrix.js +16 -16
- package/dist/animation/animator/AnimatorHighlight.d.ts +16 -16
- package/dist/animation/animator/AnimatorHighlight.js +32 -32
- package/dist/animation/animator/AnimatorPointToPoint.d.ts +8 -8
- package/dist/animation/animator/AnimatorPointToPoint.js +14 -14
- package/dist/animation/animator/AnimatorQueue.d.ts +13 -13
- package/dist/animation/animator/AnimatorQueue.js +57 -57
- package/dist/animation/animator/AnimatorScale.d.ts +8 -8
- package/dist/animation/animator/AnimatorScale.js +13 -13
- package/dist/animation/animator/AnimatorSpin.d.ts +10 -10
- package/dist/animation/animator/AnimatorSpin.js +13 -13
- package/dist/animation/animator/EasingFunctions.d.ts +35 -35
- package/dist/animation/animator/EasingFunctions.js +137 -137
- package/dist/animation/coordinator/Coordinator.d.ts +28 -28
- package/dist/animation/coordinator/Coordinator.js +47 -47
- package/dist/animation/coordinator/CoordinatorDropAndSpin.d.ts +22 -22
- package/dist/animation/coordinator/CoordinatorDropAndSpin.js +133 -133
- package/dist/animation/coordinator/CoordinatorIdentity.d.ts +11 -11
- package/dist/animation/coordinator/CoordinatorIdentity.js +12 -12
- package/dist/animation/coordinator/CoordinatorNodeQueues.d.ts +18 -18
- package/dist/animation/coordinator/CoordinatorNodeQueues.js +50 -50
- package/dist/animation/coordinator/CoordinatorPulse.d.ts +21 -21
- package/dist/animation/coordinator/CoordinatorPulse.js +47 -47
- package/dist/animation/coordinator/CoordinatorPulseBounce.d.ts +14 -14
- package/dist/animation/coordinator/CoordinatorPulseBounce.js +40 -40
- package/dist/animation/coordinator/CoordinatorPulseHighlight.d.ts +13 -13
- package/dist/animation/coordinator/CoordinatorPulseHighlight.js +34 -34
- package/dist/animation/coordinator/CoordinatorPulseInflate.d.ts +14 -14
- package/dist/animation/coordinator/CoordinatorPulseInflate.js +30 -30
- package/dist/camera/CameraCreator.d.ts +5 -5
- package/dist/camera/CameraCreator.js +4 -4
- package/dist/camera/CfgArcRotateCameraPointersInput.d.ts +26 -26
- package/dist/camera/CfgArcRotateCameraPointersInput.js +264 -264
- package/dist/camera/CfgOrbitalCamera.d.ts +68 -68
- package/dist/camera/CfgOrbitalCamera.js +250 -250
- package/dist/camera/CfgOrbitalCameraControlProps.d.ts +6 -6
- package/dist/camera/CfgOrbitalCameraControlProps.js +3 -3
- package/dist/camera/GradingApplier.d.ts +3 -3
- package/dist/camera/GradingApplier.js +48 -48
- package/dist/engine/EngineCreator.d.ts +3 -3
- package/dist/engine/EngineCreator.js +10 -10
- package/dist/geometry/CfgGeometry.d.ts +29 -29
- package/dist/geometry/CfgGeometry.js +146 -146
- package/dist/geometry/CfgMesh.d.ts +10 -10
- package/dist/geometry/CfgMesh.js +38 -38
- package/dist/geometry/geoSplitter.d.ts +8 -8
- package/dist/geometry/geoSplitter.js +192 -192
- package/dist/geometry/stretch/CfgMorphTarget.d.ts +15 -15
- package/dist/geometry/stretch/CfgMorphTarget.js +65 -65
- package/dist/geometry/stretch/CfgStretchData.d.ts +116 -114
- package/dist/geometry/stretch/CfgStretchData.js +346 -340
- package/dist/geometry/stretch/CfgStretchMorphGeometry.d.ts +16 -16
- package/dist/geometry/stretch/CfgStretchMorphGeometry.js +95 -95
- package/dist/index.d.ts +13 -13
- package/dist/index.js +13 -13
- package/dist/light/CfgDirectionalLight.d.ts +8 -8
- package/dist/light/CfgDirectionalLight.js +18 -18
- package/dist/light/CfgHemisphericLight.d.ts +7 -7
- package/dist/light/CfgHemisphericLight.js +17 -17
- package/dist/light/CfgPointLight.d.ts +8 -8
- package/dist/light/CfgPointLight.js +18 -18
- package/dist/light/DefaultLightRig.d.ts +19 -19
- package/dist/light/DefaultLightRig.js +77 -77
- package/dist/light/LightRigCreator.d.ts +9 -9
- package/dist/light/LightRigCreator.js +3 -3
- package/dist/material/CfgMaterial.d.ts +68 -68
- package/dist/material/CfgMaterial.js +482 -482
- package/dist/material/DummyMaterialCreator.d.ts +4 -4
- package/dist/material/DummyMaterialCreator.js +15 -15
- package/dist/material/material.d.ts +18 -18
- package/dist/material/material.js +128 -128
- package/dist/material/texture.d.ts +14 -14
- package/dist/material/texture.js +306 -306
- package/dist/nodes/CfgContentRootNode.d.ts +19 -19
- package/dist/nodes/CfgContentRootNode.js +75 -75
- package/dist/nodes/CfgDeferredMeshNode.d.ts +55 -55
- package/dist/nodes/CfgDeferredMeshNode.js +377 -377
- package/dist/nodes/CfgProductNode.d.ts +126 -126
- package/dist/nodes/CfgProductNode.js +579 -578
- package/dist/nodes/CfgSymNode.d.ts +50 -50
- package/dist/nodes/CfgSymNode.js +249 -249
- package/dist/nodes/CfgSymRootNode.d.ts +45 -45
- package/dist/nodes/CfgSymRootNode.js +220 -220
- package/dist/nodes/CfgTransformNode.d.ts +33 -33
- package/dist/nodes/CfgTransformNode.js +83 -83
- package/dist/scene/SceneCreator.d.ts +6 -6
- package/dist/scene/SceneCreator.js +22 -22
- package/dist/utilities/CfgBoundingBox.d.ts +21 -21
- package/dist/utilities/CfgBoundingBox.js +81 -81
- package/dist/utilities/anchor/anchor.d.ts +55 -51
- package/dist/utilities/anchor/anchor.js +140 -136
- package/dist/utilities/anchor/anchorMap.d.ts +20 -20
- package/dist/utilities/anchor/anchorMap.js +111 -111
- package/dist/utilities/utilities3D.d.ts +70 -70
- package/dist/utilities/utilities3D.js +265 -265
- package/dist/utilities/utilitiesColor.d.ts +18 -18
- package/dist/utilities/utilitiesColor.js +48 -48
- package/dist/utilities/utilitiesImage.d.ts +6 -6
- package/dist/utilities/utilitiesImage.js +107 -107
- package/dist/utilities/utilitiesSymRootIdentifier.d.ts +7 -7
- package/dist/utilities/utilitiesSymRootIdentifier.js +26 -26
- package/dist/view/BaseView.d.ts +78 -78
- package/dist/view/BaseView.js +297 -297
- package/dist/view/BaseViewConfiguration.d.ts +32 -32
- package/dist/view/BaseViewConfiguration.js +10 -8
- package/dist/view/RenderEnv.d.ts +43 -43
- package/dist/view/RenderEnv.js +7 -7
- package/dist/view/SingleProductDefaultCameraView.d.ts +33 -33
- package/dist/view/SingleProductDefaultCameraView.js +141 -141
- package/dist/view/SingleProductDefaultCameraViewConfiguration.d.ts +46 -46
- package/dist/view/SingleProductDefaultCameraViewConfiguration.js +11 -11
- package/dist/view/SingleProductView.d.ts +42 -42
- package/dist/view/SingleProductView.js +206 -206
- package/dist/view/SingleProductViewConfiguration.d.ts +32 -32
- package/dist/view/SingleProductViewConfiguration.js +19 -19
- package/package.json +5 -5
|
@@ -1,40 +1,40 @@
|
|
|
1
|
-
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
2
|
-
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
3
|
-
return new (P || (P = Promise))(function (resolve, reject) {
|
|
4
|
-
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
5
|
-
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
6
|
-
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
7
|
-
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
8
|
-
});
|
|
9
|
-
};
|
|
10
|
-
import { Vector3 } from "@babylonjs/core/Maths/math.vector.js";
|
|
11
|
-
import { AnimatorPointToPoint } from "../animator/AnimatorPointToPoint.js";
|
|
12
|
-
import { EasingFunctions } from "../animator/EasingFunctions.js";
|
|
13
|
-
import { CoordinatorPulse, defaultConfig as baseDefaultConfig, } from "./CoordinatorPulse.js";
|
|
14
|
-
const defaultConfig = Object.assign(Object.assign({}, baseDefaultConfig), { height: 0.01, delay: 40, duration: 300 });
|
|
15
|
-
export class CoordinatorPulseBounce extends CoordinatorPulse {
|
|
16
|
-
static getCoordinatorCreator(config) {
|
|
17
|
-
return (view, phaseObservable) => {
|
|
18
|
-
return new this(view, phaseObservable, config || {});
|
|
19
|
-
};
|
|
20
|
-
}
|
|
21
|
-
constructor(view, phaseObservable, config) {
|
|
22
|
-
super(view, phaseObservable, Object.assign(Object.assign({}, defaultConfig), config));
|
|
23
|
-
}
|
|
24
|
-
_prepare(node, _isNewProduct) {
|
|
25
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
26
|
-
const queue = this.getAnimatorQueue(node, true);
|
|
27
|
-
const height = this._config.height *
|
|
28
|
-
(this.productNode === undefined ? 1 : Math.pow(this.productNode.boundingBox.spaceDiagonal, 2));
|
|
29
|
-
const adjustToWorldMatrix = node.worldOriginalMatrix.getRotationMatrix().transpose();
|
|
30
|
-
const animator = new AnimatorPointToPoint(node, {
|
|
31
|
-
easing: EasingFunctions.makeMirrored(EasingFunctions.easeInSine),
|
|
32
|
-
duration: this._config.duration,
|
|
33
|
-
delay: this._config.delay,
|
|
34
|
-
startPosition: Vector3.TransformCoordinates(new Vector3(0, 0, 0), adjustToWorldMatrix),
|
|
35
|
-
endPosition: Vector3.TransformCoordinates(new Vector3(0, height, 0), adjustToWorldMatrix),
|
|
36
|
-
});
|
|
37
|
-
queue.add(animator);
|
|
38
|
-
});
|
|
39
|
-
}
|
|
40
|
-
}
|
|
1
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
2
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
3
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
4
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
5
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
6
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
7
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
8
|
+
});
|
|
9
|
+
};
|
|
10
|
+
import { Vector3 } from "@babylonjs/core/Maths/math.vector.js";
|
|
11
|
+
import { AnimatorPointToPoint } from "../animator/AnimatorPointToPoint.js";
|
|
12
|
+
import { EasingFunctions } from "../animator/EasingFunctions.js";
|
|
13
|
+
import { CoordinatorPulse, defaultConfig as baseDefaultConfig, } from "./CoordinatorPulse.js";
|
|
14
|
+
const defaultConfig = Object.assign(Object.assign({}, baseDefaultConfig), { height: 0.01, delay: 40, duration: 300 });
|
|
15
|
+
export class CoordinatorPulseBounce extends CoordinatorPulse {
|
|
16
|
+
static getCoordinatorCreator(config) {
|
|
17
|
+
return (view, phaseObservable) => {
|
|
18
|
+
return new this(view, phaseObservable, config || {});
|
|
19
|
+
};
|
|
20
|
+
}
|
|
21
|
+
constructor(view, phaseObservable, config) {
|
|
22
|
+
super(view, phaseObservable, Object.assign(Object.assign({}, defaultConfig), config));
|
|
23
|
+
}
|
|
24
|
+
_prepare(node, _isNewProduct) {
|
|
25
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
26
|
+
const queue = this.getAnimatorQueue(node, true);
|
|
27
|
+
const height = this._config.height *
|
|
28
|
+
(this.productNode === undefined ? 1 : Math.pow(this.productNode.boundingBox.spaceDiagonal, 2));
|
|
29
|
+
const adjustToWorldMatrix = node.worldOriginalMatrix.getRotationMatrix().transpose();
|
|
30
|
+
const animator = new AnimatorPointToPoint(node, {
|
|
31
|
+
easing: EasingFunctions.makeMirrored(EasingFunctions.easeInSine),
|
|
32
|
+
duration: this._config.duration,
|
|
33
|
+
delay: this._config.delay,
|
|
34
|
+
startPosition: Vector3.TransformCoordinates(new Vector3(0, 0, 0), adjustToWorldMatrix),
|
|
35
|
+
endPosition: Vector3.TransformCoordinates(new Vector3(0, height, 0), adjustToWorldMatrix),
|
|
36
|
+
});
|
|
37
|
+
queue.add(animator);
|
|
38
|
+
});
|
|
39
|
+
}
|
|
40
|
+
}
|
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
import { Observable } from "@configura/web-utilities";
|
|
2
|
-
import { SingleProductView } from "../../view/SingleProductView.js";
|
|
3
|
-
import { SingleProductViewPhaseEvent } from "../../view/SingleProductViewConfiguration.js";
|
|
4
|
-
import { AnimatableObject } from "../AnimatableObject.js";
|
|
5
|
-
import { AnimatorHighlightConfig } from "../animator/AnimatorHighlight.js";
|
|
6
|
-
import { CoordinatorCreator } from "./Coordinator.js";
|
|
7
|
-
import { CoordinatorPulse, CoordinatorPulseConfig } from "./CoordinatorPulse.js";
|
|
8
|
-
export declare type CoordinatorPulseHighlightConfig = CoordinatorPulseConfig & AnimatorHighlightConfig;
|
|
9
|
-
export declare class CoordinatorPulseHighlight extends CoordinatorPulse<CoordinatorPulseHighlightConfig> {
|
|
10
|
-
static getCoordinatorCreator(config?: Partial<CoordinatorPulseHighlightConfig>): CoordinatorCreator;
|
|
11
|
-
protected constructor(view: SingleProductView, phaseObservable: Observable<SingleProductViewPhaseEvent>, config: Partial<CoordinatorPulseHighlightConfig>);
|
|
12
|
-
_prepare(node: AnimatableObject, _isNewProduct: boolean): Promise<void>;
|
|
13
|
-
}
|
|
1
|
+
import { Observable } from "@configura/web-utilities";
|
|
2
|
+
import { SingleProductView } from "../../view/SingleProductView.js";
|
|
3
|
+
import { SingleProductViewPhaseEvent } from "../../view/SingleProductViewConfiguration.js";
|
|
4
|
+
import { AnimatableObject } from "../AnimatableObject.js";
|
|
5
|
+
import { AnimatorHighlightConfig } from "../animator/AnimatorHighlight.js";
|
|
6
|
+
import { CoordinatorCreator } from "./Coordinator.js";
|
|
7
|
+
import { CoordinatorPulse, CoordinatorPulseConfig } from "./CoordinatorPulse.js";
|
|
8
|
+
export declare type CoordinatorPulseHighlightConfig = CoordinatorPulseConfig & AnimatorHighlightConfig;
|
|
9
|
+
export declare class CoordinatorPulseHighlight extends CoordinatorPulse<CoordinatorPulseHighlightConfig> {
|
|
10
|
+
static getCoordinatorCreator(config?: Partial<CoordinatorPulseHighlightConfig>): CoordinatorCreator;
|
|
11
|
+
protected constructor(view: SingleProductView, phaseObservable: Observable<SingleProductViewPhaseEvent>, config: Partial<CoordinatorPulseHighlightConfig>);
|
|
12
|
+
_prepare(node: AnimatableObject, _isNewProduct: boolean): Promise<void>;
|
|
13
|
+
}
|
|
14
14
|
//# sourceMappingURL=CoordinatorPulseHighlight.d.ts.map
|
|
@@ -1,34 +1,34 @@
|
|
|
1
|
-
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
2
|
-
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
3
|
-
return new (P || (P = Promise))(function (resolve, reject) {
|
|
4
|
-
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
5
|
-
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
6
|
-
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
7
|
-
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
8
|
-
});
|
|
9
|
-
};
|
|
10
|
-
import { AnimatorHighlight, defaultConfig as animatorHighlightDefaultConfig, } from "../animator/AnimatorHighlight.js";
|
|
11
|
-
import { EasingFunctions } from "../animator/EasingFunctions.js";
|
|
12
|
-
import { CoordinatorPulse, defaultConfig as baseDefaultConfig, } from "./CoordinatorPulse.js";
|
|
13
|
-
const defaultConfig = Object.assign(Object.assign({}, baseDefaultConfig), animatorHighlightDefaultConfig);
|
|
14
|
-
export class CoordinatorPulseHighlight extends CoordinatorPulse {
|
|
15
|
-
static getCoordinatorCreator(config) {
|
|
16
|
-
return (view, phaseObservable) => {
|
|
17
|
-
return new this(view, phaseObservable, config || {});
|
|
18
|
-
};
|
|
19
|
-
}
|
|
20
|
-
constructor(view, phaseObservable, config) {
|
|
21
|
-
super(view, phaseObservable, Object.assign(Object.assign({}, defaultConfig), config));
|
|
22
|
-
}
|
|
23
|
-
_prepare(node, _isNewProduct) {
|
|
24
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
25
|
-
const queue = this.getAnimatorQueue(node, true);
|
|
26
|
-
const width = this._config.width *
|
|
27
|
-
(this.productNode === undefined ? 1 : Math.pow(this.productNode.boundingBox.spaceDiagonal, 2));
|
|
28
|
-
const config = Object.assign(Object.assign({}, this._config), { width, easing: EasingFunctions.makeMirrored(EasingFunctions.easeInQuart), startPosition: 0 });
|
|
29
|
-
const animator = new AnimatorHighlight(node, config);
|
|
30
|
-
animator.apply0();
|
|
31
|
-
queue.add(animator);
|
|
32
|
-
});
|
|
33
|
-
}
|
|
34
|
-
}
|
|
1
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
2
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
3
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
4
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
5
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
6
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
7
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
8
|
+
});
|
|
9
|
+
};
|
|
10
|
+
import { AnimatorHighlight, defaultConfig as animatorHighlightDefaultConfig, } from "../animator/AnimatorHighlight.js";
|
|
11
|
+
import { EasingFunctions } from "../animator/EasingFunctions.js";
|
|
12
|
+
import { CoordinatorPulse, defaultConfig as baseDefaultConfig, } from "./CoordinatorPulse.js";
|
|
13
|
+
const defaultConfig = Object.assign(Object.assign({}, baseDefaultConfig), animatorHighlightDefaultConfig);
|
|
14
|
+
export class CoordinatorPulseHighlight extends CoordinatorPulse {
|
|
15
|
+
static getCoordinatorCreator(config) {
|
|
16
|
+
return (view, phaseObservable) => {
|
|
17
|
+
return new this(view, phaseObservable, config || {});
|
|
18
|
+
};
|
|
19
|
+
}
|
|
20
|
+
constructor(view, phaseObservable, config) {
|
|
21
|
+
super(view, phaseObservable, Object.assign(Object.assign({}, defaultConfig), config));
|
|
22
|
+
}
|
|
23
|
+
_prepare(node, _isNewProduct) {
|
|
24
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
25
|
+
const queue = this.getAnimatorQueue(node, true);
|
|
26
|
+
const width = this._config.width *
|
|
27
|
+
(this.productNode === undefined ? 1 : Math.pow(this.productNode.boundingBox.spaceDiagonal, 2));
|
|
28
|
+
const config = Object.assign(Object.assign({}, this._config), { width, easing: EasingFunctions.makeMirrored(EasingFunctions.easeInQuart), startPosition: 0 });
|
|
29
|
+
const animator = new AnimatorHighlight(node, config);
|
|
30
|
+
animator.apply0();
|
|
31
|
+
queue.add(animator);
|
|
32
|
+
});
|
|
33
|
+
}
|
|
34
|
+
}
|
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
import { Observable } from "@configura/web-utilities";
|
|
2
|
-
import { SingleProductView } from "../../view/SingleProductView.js";
|
|
3
|
-
import { SingleProductViewPhaseEvent } from "../../view/SingleProductViewConfiguration.js";
|
|
4
|
-
import { AnimatableObject } from "../AnimatableObject.js";
|
|
5
|
-
import { CoordinatorCreator } from "./Coordinator.js";
|
|
6
|
-
import { CoordinatorPulse, CoordinatorPulseConfig } from "./CoordinatorPulse.js";
|
|
7
|
-
export declare type CoordinatorPulseInflateConfig = CoordinatorPulseConfig & {
|
|
8
|
-
size: number;
|
|
9
|
-
};
|
|
10
|
-
export declare class CoordinatorPulseInflate extends CoordinatorPulse<CoordinatorPulseInflateConfig> {
|
|
11
|
-
static getCoordinatorCreator(config?: Partial<CoordinatorPulseInflateConfig>): CoordinatorCreator;
|
|
12
|
-
protected constructor(view: SingleProductView, phaseObservable: Observable<SingleProductViewPhaseEvent>, config: Partial<CoordinatorPulseInflateConfig>);
|
|
13
|
-
_prepare(node: AnimatableObject, _isNewProduct: boolean): Promise<void>;
|
|
14
|
-
}
|
|
1
|
+
import { Observable } from "@configura/web-utilities";
|
|
2
|
+
import { SingleProductView } from "../../view/SingleProductView.js";
|
|
3
|
+
import { SingleProductViewPhaseEvent } from "../../view/SingleProductViewConfiguration.js";
|
|
4
|
+
import { AnimatableObject } from "../AnimatableObject.js";
|
|
5
|
+
import { CoordinatorCreator } from "./Coordinator.js";
|
|
6
|
+
import { CoordinatorPulse, CoordinatorPulseConfig } from "./CoordinatorPulse.js";
|
|
7
|
+
export declare type CoordinatorPulseInflateConfig = CoordinatorPulseConfig & {
|
|
8
|
+
size: number;
|
|
9
|
+
};
|
|
10
|
+
export declare class CoordinatorPulseInflate extends CoordinatorPulse<CoordinatorPulseInflateConfig> {
|
|
11
|
+
static getCoordinatorCreator(config?: Partial<CoordinatorPulseInflateConfig>): CoordinatorCreator;
|
|
12
|
+
protected constructor(view: SingleProductView, phaseObservable: Observable<SingleProductViewPhaseEvent>, config: Partial<CoordinatorPulseInflateConfig>);
|
|
13
|
+
_prepare(node: AnimatableObject, _isNewProduct: boolean): Promise<void>;
|
|
14
|
+
}
|
|
15
15
|
//# sourceMappingURL=CoordinatorPulseInflate.d.ts.map
|
|
@@ -1,30 +1,30 @@
|
|
|
1
|
-
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
2
|
-
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
3
|
-
return new (P || (P = Promise))(function (resolve, reject) {
|
|
4
|
-
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
5
|
-
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
6
|
-
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
7
|
-
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
8
|
-
});
|
|
9
|
-
};
|
|
10
|
-
import { AnimatorScale } from "../animator/AnimatorScale.js";
|
|
11
|
-
import { EasingFunctions } from "../animator/EasingFunctions.js";
|
|
12
|
-
import { CoordinatorPulse, defaultConfig as baseDefaultConfig, } from "./CoordinatorPulse.js";
|
|
13
|
-
const defaultConfig = Object.assign(Object.assign({}, baseDefaultConfig), { size: 0.98, duration: 400 });
|
|
14
|
-
export class CoordinatorPulseInflate extends CoordinatorPulse {
|
|
15
|
-
static getCoordinatorCreator(config) {
|
|
16
|
-
return (view, phaseObservable) => {
|
|
17
|
-
return new this(view, phaseObservable, config || {});
|
|
18
|
-
};
|
|
19
|
-
}
|
|
20
|
-
constructor(view, phaseObservable, config) {
|
|
21
|
-
super(view, phaseObservable, Object.assign(Object.assign({}, defaultConfig), config));
|
|
22
|
-
}
|
|
23
|
-
_prepare(node, _isNewProduct) {
|
|
24
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
25
|
-
const queue = this.getAnimatorQueue(node, true);
|
|
26
|
-
const animator = new AnimatorScale(node, Object.assign(Object.assign({}, this._config), { easing: EasingFunctions.sinBounce(1), startPosition: 1, endPosition: this._config.size, translationVector: node.boundingBox.center }));
|
|
27
|
-
queue.add(animator);
|
|
28
|
-
});
|
|
29
|
-
}
|
|
30
|
-
}
|
|
1
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
2
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
3
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
4
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
5
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
6
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
7
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
8
|
+
});
|
|
9
|
+
};
|
|
10
|
+
import { AnimatorScale } from "../animator/AnimatorScale.js";
|
|
11
|
+
import { EasingFunctions } from "../animator/EasingFunctions.js";
|
|
12
|
+
import { CoordinatorPulse, defaultConfig as baseDefaultConfig, } from "./CoordinatorPulse.js";
|
|
13
|
+
const defaultConfig = Object.assign(Object.assign({}, baseDefaultConfig), { size: 0.98, duration: 400 });
|
|
14
|
+
export class CoordinatorPulseInflate extends CoordinatorPulse {
|
|
15
|
+
static getCoordinatorCreator(config) {
|
|
16
|
+
return (view, phaseObservable) => {
|
|
17
|
+
return new this(view, phaseObservable, config || {});
|
|
18
|
+
};
|
|
19
|
+
}
|
|
20
|
+
constructor(view, phaseObservable, config) {
|
|
21
|
+
super(view, phaseObservable, Object.assign(Object.assign({}, defaultConfig), config));
|
|
22
|
+
}
|
|
23
|
+
_prepare(node, _isNewProduct) {
|
|
24
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
25
|
+
const queue = this.getAnimatorQueue(node, true);
|
|
26
|
+
const animator = new AnimatorScale(node, Object.assign(Object.assign({}, this._config), { easing: EasingFunctions.sinBounce(1), startPosition: 1, endPosition: this._config.size, translationVector: node.boundingBox.center }));
|
|
27
|
+
queue.add(animator);
|
|
28
|
+
});
|
|
29
|
+
}
|
|
30
|
+
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { Camera } from "@babylonjs/core/Cameras/camera.js";
|
|
2
|
-
import { Scene } from "@babylonjs/core/scene.js";
|
|
3
|
-
import { CfgOrbitalCamera } from "./CfgOrbitalCamera.js";
|
|
4
|
-
export declare type CameraCreator<C extends Camera> = (scene: Scene, canvas: HTMLElement) => C;
|
|
5
|
-
export declare function getDefaultCamera(scene: Scene, canvas: HTMLElement): CfgOrbitalCamera;
|
|
1
|
+
import { Camera } from "@babylonjs/core/Cameras/camera.js";
|
|
2
|
+
import { Scene } from "@babylonjs/core/scene.js";
|
|
3
|
+
import { CfgOrbitalCamera } from "./CfgOrbitalCamera.js";
|
|
4
|
+
export declare type CameraCreator<C extends Camera> = (scene: Scene, canvas: HTMLElement) => C;
|
|
5
|
+
export declare function getDefaultCamera(scene: Scene, canvas: HTMLElement): CfgOrbitalCamera;
|
|
6
6
|
//# sourceMappingURL=CameraCreator.d.ts.map
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { CfgOrbitalCamera } from "./CfgOrbitalCamera.js";
|
|
2
|
-
export function getDefaultCamera(scene, canvas) {
|
|
3
|
-
return new CfgOrbitalCamera(scene, canvas);
|
|
4
|
-
}
|
|
1
|
+
import { CfgOrbitalCamera } from "./CfgOrbitalCamera.js";
|
|
2
|
+
export function getDefaultCamera(scene, canvas) {
|
|
3
|
+
return new CfgOrbitalCamera(scene, canvas);
|
|
4
|
+
}
|
|
@@ -1,27 +1,27 @@
|
|
|
1
|
-
import { ArcRotateCameraPointersInput } from "@babylonjs/core/Cameras/Inputs/arcRotateCameraPointersInput.js";
|
|
2
|
-
import "@babylonjs/core/Engines/Extensions/engine.webVR.js";
|
|
3
|
-
/**
|
|
4
|
-
* This class exists to workaround a severe touch input issue that exists on at least iOS 13.4 in
|
|
5
|
-
* Babylon release 4.1.0 and possibly later.
|
|
6
|
-
*
|
|
7
|
-
* The main workaround is marked with "--- START OF WORKAROUND ---" in the source below.
|
|
8
|
-
*
|
|
9
|
-
* Most of the code below is copied from the Babylon source class BaseCameraPointersInput.ts,
|
|
10
|
-
* which ArcRotateCameraPointersInput extends. Some additional private support code from
|
|
11
|
-
* BaseCameraPointersInput is also included and suffixed with "CfgPatch".
|
|
12
|
-
*
|
|
13
|
-
* @warning: DO NOT do any other changes to this file! They WILL be lost when this workaround is no
|
|
14
|
-
* longer needed.
|
|
15
|
-
*
|
|
16
|
-
* @todo Every time the babylon module is updated to a new release, test if the workaround is still
|
|
17
|
-
* needed. If not, simply remove this file and update CfgOrbitalCamera.ts to not use it.
|
|
18
|
-
*/
|
|
19
|
-
export declare class CfgArcRotateCameraPointersInput extends ArcRotateCameraPointersInput {
|
|
20
|
-
attachControl(noPreventDefault?: boolean): void;
|
|
21
|
-
detachControl(ignored?: any): void;
|
|
22
|
-
private _observerCfgPatch;
|
|
23
|
-
private _onLostFocusCfgPatch;
|
|
24
|
-
private _pointA;
|
|
25
|
-
private _pointB;
|
|
26
|
-
}
|
|
1
|
+
import { ArcRotateCameraPointersInput } from "@babylonjs/core/Cameras/Inputs/arcRotateCameraPointersInput.js";
|
|
2
|
+
import "@babylonjs/core/Engines/Extensions/engine.webVR.js";
|
|
3
|
+
/**
|
|
4
|
+
* This class exists to workaround a severe touch input issue that exists on at least iOS 13.4 in
|
|
5
|
+
* Babylon release 4.1.0 and possibly later.
|
|
6
|
+
*
|
|
7
|
+
* The main workaround is marked with "--- START OF WORKAROUND ---" in the source below.
|
|
8
|
+
*
|
|
9
|
+
* Most of the code below is copied from the Babylon source class BaseCameraPointersInput.ts,
|
|
10
|
+
* which ArcRotateCameraPointersInput extends. Some additional private support code from
|
|
11
|
+
* BaseCameraPointersInput is also included and suffixed with "CfgPatch".
|
|
12
|
+
*
|
|
13
|
+
* @warning: DO NOT do any other changes to this file! They WILL be lost when this workaround is no
|
|
14
|
+
* longer needed.
|
|
15
|
+
*
|
|
16
|
+
* @todo Every time the babylon module is updated to a new release, test if the workaround is still
|
|
17
|
+
* needed. If not, simply remove this file and update CfgOrbitalCamera.ts to not use it.
|
|
18
|
+
*/
|
|
19
|
+
export declare class CfgArcRotateCameraPointersInput extends ArcRotateCameraPointersInput {
|
|
20
|
+
attachControl(noPreventDefault?: boolean): void;
|
|
21
|
+
detachControl(ignored?: any): void;
|
|
22
|
+
private _observerCfgPatch;
|
|
23
|
+
private _onLostFocusCfgPatch;
|
|
24
|
+
private _pointA;
|
|
25
|
+
private _pointB;
|
|
26
|
+
}
|
|
27
27
|
//# sourceMappingURL=CfgArcRotateCameraPointersInput.d.ts.map
|