zakeke-configurator-react 0.0.228 → 0.0.229

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.
@@ -1,6 +1,6 @@
1
- import { IDisposable } from "../Interfaces/IDisposable";
2
- import { TryOnFineTuningSettings } from "../Interfaces/ITryOn";
3
- import { Nullable } from "../types";
1
+ import { IDisposable } from '../Interfaces/IDisposable';
2
+ import { TryOnFineTuningSettings } from '../Interfaces/ITryOn';
3
+ import { Nullable } from '../types';
4
4
  export type WorldExtends = {
5
5
  min: BABYLON.Vector3;
6
6
  max: BABYLON.Vector3;
@@ -53,7 +53,7 @@ export declare class SceneHelper implements IDisposable {
53
53
  static whenMaterialIsReadyForSubMeshAsync(material: BABYLON.Material, mesh: BABYLON.AbstractMesh, subMesh: BABYLON.SubMesh): Promise<void>;
54
54
  private static getMeshGeometry;
55
55
  private static checkMeshIsReady;
56
- static checkAllMeshesAreReady(meshes: BABYLON.AbstractMesh[], callback?: (meshID: string) => Promise<void>): Promise<boolean>;
56
+ static checkAllMeshesAreReady(meshes: BABYLON.AbstractMesh[]): boolean;
57
57
  static whenAllMeshesAreReadyAsync(meshes: BABYLON.AbstractMesh[]): Promise<void>;
58
58
  static whenAllVisibleMeshesAreReadyAsync(meshes: BABYLON.AbstractMesh[]): Promise<void>;
59
59
  static whenMeshIsReadyAsync(mesh: BABYLON.AbstractMesh): Promise<void>;
@@ -1,19 +1,19 @@
1
- export interface IScenePreviewOptions {
2
- width?: number;
3
- height?: number;
4
- crop?: boolean;
5
- camera: {
6
- position: BABYLON.Vector3;
7
- target: BABYLON.Vector3;
8
- };
9
- zkScene?: Zakeke.Scene;
10
- zkModel?: MPlaza.Model;
11
- zkDesign?: MPlaza.Design | null;
12
- meshesWithCustomizationIds?: string[];
13
- }
14
- export declare class ScenePreviewData {
15
- previewFile: string;
16
- }
17
- export declare class ScenesPreview {
18
- static getPreviewsAsync(scene: BABYLON.Scene, rootUrl: string, options: IScenePreviewOptions): Promise<ScenePreviewData>;
19
- }
1
+ export interface IScenePreviewOptions {
2
+ width?: number;
3
+ height?: number;
4
+ crop?: boolean;
5
+ camera: {
6
+ position: BABYLON.Vector3;
7
+ target: BABYLON.Vector3;
8
+ };
9
+ zkScene?: Zakeke.Scene;
10
+ zkModel?: MPlaza.Model;
11
+ zkDesign?: MPlaza.Design | null;
12
+ meshesWithCustomizationIds?: string[];
13
+ }
14
+ export declare class ScenePreviewData {
15
+ previewFile: string;
16
+ }
17
+ export declare class ScenesPreview {
18
+ static getPreviewsAsync(scene: BABYLON.Scene, rootUrl: string, options: IScenePreviewOptions): Promise<ScenePreviewData>;
19
+ }
@@ -1 +1 @@
1
- export declare function makeCubeWorldUV(positions: number[], normals: number[], indices: number[]): number[][];
1
+ export declare function makeCubeWorldUV(positions: number[], normals: number[], indices: number[]): number[][];
@@ -1,109 +1,109 @@
1
- import { FunctionComponent } from "react";
2
- import { TryOnFineTuningMazingSettings, TryOnGenericFineTuningSettings, TryOnProduct, TryOnProvider, TryOnSeller, TryOnType } from "../models";
3
- export declare function parseJSON(json: string): any;
4
- export declare enum TryOnMode {
5
- Undefined = 0,
6
- TryOn = 1,
7
- PDTool = 2
8
- }
9
- export interface TryOnViewerProps {
10
- mode: TryOnMode;
11
- onTimeout?: (value: boolean) => void;
12
- onPDUpdated?: (pd: number) => void;
13
- onClose?: () => void;
14
- }
15
- export interface VTryOnViewerProps {
16
- className?: string;
17
- provider: TryOnProvider;
18
- type: TryOnType;
19
- obj: Blob;
20
- settings?: TryOnGenericFineTuningSettings;
21
- product: TryOnProduct;
22
- customer: TryOnSeller;
23
- onReady?: () => void;
24
- onClose?: () => void;
25
- }
26
- export interface TryOnPDToolProps {
27
- className?: string;
28
- provider: TryOnProvider;
29
- product: TryOnProduct;
30
- customer: TryOnSeller;
31
- onReady?: () => void;
32
- onPDUpdated?: (pd: number) => void;
33
- onClose?: () => void;
34
- }
35
- export declare const TryOnViewerComponent: FunctionComponent<TryOnViewerProps>;
36
- export declare const VTryOnViewerComponent: FunctionComponent<VTryOnViewerProps>;
37
- export declare const TryOnPDToolComponent: FunctionComponent<TryOnPDToolProps>;
38
- export declare enum MazingTryOnState {
39
- Start = "",
40
- WaitingAuthentication = "WAITING_AUTH",
41
- AuthSuccessful = "AUTH_SUCCESS",
42
- TryOnLoaded = "MODEL_LOADED",
43
- AuthError = "AUTH_ERROR",
44
- WebcamError = "WEBCAM_ERROR",
45
- ScreenShotTaken = "SCREENSHOT_TAKEN",
46
- WebcamStopped = "WEBCAM_STOPPED"
47
- }
48
- export declare enum MazingTryOnOutMessage {
49
- StartAuthenticationTryOn = "AUTH_TRY_ON",
50
- LoadTryOn = "LOAD_MODEL",
51
- TakeScreenshot = "TAKE_SCREENSHOT",
52
- StopWebcam = "STOP_WEBCAM"
53
- }
54
- export declare enum MazingPDState {
55
- Start = "",
56
- WaitingAuthentication = "WAITING_AUTH",
57
- AuthSuccessful = "AUTH_SUCCESS",
58
- PDLoaded = "PD_LOADED",
59
- PDUpdated = "NEW_PD",
60
- AuthError = "AUTH_ERROR",
61
- PDDataNotFoundError = "PD_ERROR",
62
- WebcamError = "WEBCAM_ERROR",
63
- PDCountdown = "PD_COUNTDOWN",
64
- PDCountdownEnd = "PD_COUNTDOWN_END",
65
- WebcamStopped = "WEBCAM_STOPPED"
66
- }
67
- export declare enum MazingPDOutMessage {
68
- StartAuthenticationPD = "AUTH_TRY_ON",
69
- LoadPD = "LOAD_PD",
70
- StartPD = "START_PD",
71
- StopWebcam = "STOP_WEBCAM"
72
- }
73
- export interface MazingTryOnInMessage {
74
- type: MazingFrameState;
75
- value: any;
76
- }
77
- export interface MazingFrameProps {
78
- className?: string;
79
- outMessageHandler: (e: MessageEvent<any>) => void;
80
- onReady?: (w: Window) => void;
81
- }
82
- export interface MazingTryOnProps {
83
- className?: string;
84
- obj: Blob;
85
- product: TryOnProduct;
86
- customer: TryOnSeller;
87
- fineTuningSettings?: TryOnFineTuningMazingSettings;
88
- initialState?: MazingTryOnInMessage;
89
- closeFlag: boolean;
90
- onReady?: () => void;
91
- onReadyToShow?: () => void;
92
- onClosed?: () => void;
93
- }
94
- export interface MazingPDProps {
95
- className?: string;
96
- product: TryOnProduct;
97
- customer: TryOnSeller;
98
- initialState?: MazingTryOnInMessage;
99
- closeFlag: boolean;
100
- onReady?: () => void;
101
- onReadyToShow?: () => void;
102
- onPDUpdated?: (pd: number) => void;
103
- onClosed?: () => void;
104
- onClose?: () => void;
105
- }
106
- export type MazingFrameState = MazingTryOnState | MazingPDState;
107
- export declare const MazingFrameComponent: (props: MazingFrameProps) => JSX.Element;
108
- export declare const MazingTryOnComponent: FunctionComponent<MazingTryOnProps>;
109
- export declare const MazingPDToolComponent: FunctionComponent<MazingPDProps>;
1
+ import { FunctionComponent } from "react";
2
+ import { TryOnFineTuningMazingSettings, TryOnGenericFineTuningSettings, TryOnProduct, TryOnProvider, TryOnSeller, TryOnType } from "../models";
3
+ export declare function parseJSON(json: string): any;
4
+ export declare enum TryOnMode {
5
+ Undefined = 0,
6
+ TryOn = 1,
7
+ PDTool = 2
8
+ }
9
+ export interface TryOnViewerProps {
10
+ mode: TryOnMode;
11
+ onTimeout?: (value: boolean) => void;
12
+ onPDUpdated?: (pd: number) => void;
13
+ onClose?: () => void;
14
+ }
15
+ export interface VTryOnViewerProps {
16
+ className?: string;
17
+ provider: TryOnProvider;
18
+ type: TryOnType;
19
+ obj: Blob;
20
+ settings?: TryOnGenericFineTuningSettings;
21
+ product: TryOnProduct;
22
+ customer: TryOnSeller;
23
+ onReady?: () => void;
24
+ onClose?: () => void;
25
+ }
26
+ export interface TryOnPDToolProps {
27
+ className?: string;
28
+ provider: TryOnProvider;
29
+ product: TryOnProduct;
30
+ customer: TryOnSeller;
31
+ onReady?: () => void;
32
+ onPDUpdated?: (pd: number) => void;
33
+ onClose?: () => void;
34
+ }
35
+ export declare const TryOnViewerComponent: FunctionComponent<TryOnViewerProps>;
36
+ export declare const VTryOnViewerComponent: FunctionComponent<VTryOnViewerProps>;
37
+ export declare const TryOnPDToolComponent: FunctionComponent<TryOnPDToolProps>;
38
+ export declare enum MazingTryOnState {
39
+ Start = "",
40
+ WaitingAuthentication = "WAITING_AUTH",
41
+ AuthSuccessful = "AUTH_SUCCESS",
42
+ TryOnLoaded = "MODEL_LOADED",
43
+ AuthError = "AUTH_ERROR",
44
+ WebcamError = "WEBCAM_ERROR",
45
+ ScreenShotTaken = "SCREENSHOT_TAKEN",
46
+ WebcamStopped = "WEBCAM_STOPPED"
47
+ }
48
+ export declare enum MazingTryOnOutMessage {
49
+ StartAuthenticationTryOn = "AUTH_TRY_ON",
50
+ LoadTryOn = "LOAD_MODEL",
51
+ TakeScreenshot = "TAKE_SCREENSHOT",
52
+ StopWebcam = "STOP_WEBCAM"
53
+ }
54
+ export declare enum MazingPDState {
55
+ Start = "",
56
+ WaitingAuthentication = "WAITING_AUTH",
57
+ AuthSuccessful = "AUTH_SUCCESS",
58
+ PDLoaded = "PD_LOADED",
59
+ PDUpdated = "NEW_PD",
60
+ AuthError = "AUTH_ERROR",
61
+ PDDataNotFoundError = "PD_ERROR",
62
+ WebcamError = "WEBCAM_ERROR",
63
+ PDCountdown = "PD_COUNTDOWN",
64
+ PDCountdownEnd = "PD_COUNTDOWN_END",
65
+ WebcamStopped = "WEBCAM_STOPPED"
66
+ }
67
+ export declare enum MazingPDOutMessage {
68
+ StartAuthenticationPD = "AUTH_TRY_ON",
69
+ LoadPD = "LOAD_PD",
70
+ StartPD = "START_PD",
71
+ StopWebcam = "STOP_WEBCAM"
72
+ }
73
+ export interface MazingTryOnInMessage {
74
+ type: MazingFrameState;
75
+ value: any;
76
+ }
77
+ export interface MazingFrameProps {
78
+ className?: string;
79
+ outMessageHandler: (e: MessageEvent<any>) => void;
80
+ onReady?: (w: Window) => void;
81
+ }
82
+ export interface MazingTryOnProps {
83
+ className?: string;
84
+ obj: Blob;
85
+ product: TryOnProduct;
86
+ customer: TryOnSeller;
87
+ fineTuningSettings?: TryOnFineTuningMazingSettings;
88
+ initialState?: MazingTryOnInMessage;
89
+ closeFlag: boolean;
90
+ onReady?: () => void;
91
+ onReadyToShow?: () => void;
92
+ onClosed?: () => void;
93
+ }
94
+ export interface MazingPDProps {
95
+ className?: string;
96
+ product: TryOnProduct;
97
+ customer: TryOnSeller;
98
+ initialState?: MazingTryOnInMessage;
99
+ closeFlag: boolean;
100
+ onReady?: () => void;
101
+ onReadyToShow?: () => void;
102
+ onPDUpdated?: (pd: number) => void;
103
+ onClosed?: () => void;
104
+ onClose?: () => void;
105
+ }
106
+ export type MazingFrameState = MazingTryOnState | MazingPDState;
107
+ export declare const MazingFrameComponent: (props: MazingFrameProps) => JSX.Element;
108
+ export declare const MazingTryOnComponent: FunctionComponent<MazingTryOnProps>;
109
+ export declare const MazingPDToolComponent: FunctionComponent<MazingPDProps>;