@pilotdev/pilot-web-3d 23.0.7 → 23.0.10

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.
Files changed (3) hide show
  1. package/README.md +0 -4
  2. package/index.d.ts +174 -196
  3. package/package.json +1 -1
package/README.md CHANGED
@@ -3,7 +3,3 @@
3
3
 
4
4
  # Summary
5
5
  This package contains type definitions for Ascon **PilotWeb3D** component (https://pilotcloud.ascon.net/).
6
-
7
- ### Additional Details
8
- * Last updated: Thu, 15 Nov 2022 16:10:25 GMT
9
- * Global values: `PilotWeb3d`
package/index.d.ts CHANGED
@@ -26,12 +26,16 @@ export enum UpdateType {
26
26
  }
27
27
  export const zeroGuid = "00000000-0000-0000-0000-000000000000";
28
28
  export class Color {
29
- r: number;
30
- g: number;
31
- b: number;
32
- a: number;
33
29
 
34
30
  constructor(r: number, g: number, b: number, a: number);
31
+ get r(): number;
32
+ set r(value: number);
33
+ get g(): number;
34
+ set g(value: number);
35
+ get b(): number;
36
+ set b(value: number);
37
+ get a(): number;
38
+ set a(value: number);
35
39
  static fromThreeColor(color: THREE.Color, alpha?: number): Color;
36
40
  static fromColorRepresentation(representation: THREE.ColorRepresentation): Color;
37
41
  static fromMaterial(material: THREE.Material): Color;
@@ -47,6 +51,7 @@ export abstract class ViewObject extends THREE.Object3D {
47
51
  protected _isHovered: boolean;
48
52
  protected _isVisible: boolean;
49
53
  protected _isHidden: boolean;
54
+ protected _isDecomposed: boolean;
50
55
  protected _originalColor: Color;
51
56
  /**
52
57
  * model element entity guid
@@ -58,6 +63,11 @@ export abstract class ViewObject extends THREE.Object3D {
58
63
  * @default zeroGuid
59
64
  */
60
65
  readonly modelGuid: string;
66
+ /**
67
+ * If true, applies this object's renderOrder as a groupOrder to its children.
68
+ * @default true
69
+ */
70
+ readonly isGroup: boolean;
61
71
 
62
72
  constructor(entityGuid?: string, modelGuid?: string, color?: Color);
63
73
  /**Mesh representation of the object */
@@ -68,6 +78,12 @@ export abstract class ViewObject extends THREE.Object3D {
68
78
  remove(...object: THREE.Object3D<THREE.Event>[]): this;
69
79
  updateMatrixWorld(force?: boolean): void;
70
80
  updateWorldMatrix(updateParents: boolean, updateChildren: boolean): void;
81
+ updateMatrix(): void;
82
+ applyMatrix4(matrix: THREE.Matrix4): void;
83
+ /** */
84
+ setDecomposed(value: boolean): void;
85
+ /**Check if object is decomposed: have valid position, quaternion, scale, up vectors */
86
+ isDecomposed(): boolean;
71
87
  /**Set visibility of this object */
72
88
  setVisible(iVal: boolean): void;
73
89
  /**Get visibility of this object */
@@ -125,13 +141,20 @@ export abstract class CustomMaterial extends THREE.ShaderMaterial {
125
141
 
126
142
  constructor();
127
143
  copy(source: CustomMaterial): this;
128
- protected customProgramCacheKeyCallback(): string;
129
- protected onBeforeRender(renderer: THREE.WebGLRenderer, scene: THREE.Scene, camera: THREE.Camera, geometry: THREE.BufferGeometry, material: THREE.Material, group: THREE.Group): void;
144
+ protected refreshUniforms(uniforms: {
145
+ [uniform: string]: THREE.IUniform;
146
+ }, material: CustomMaterial, renderer: THREE.WebGLRenderer): void;
130
147
  protected onBeforeCompileCallback(shader: THREE.Shader): void;
131
148
  protected refreshTransformUniform(map: THREE.Texture, uniform: THREE.IUniform): void;
149
+ protected onBeforeRender(renderer: THREE.WebGLRenderer, scene: THREE.Scene, camera: THREE.Camera, geometry: THREE.BufferGeometry, material: THREE.Material, group: THREE.Group): void;
132
150
  }
133
- export interface CustomMeshLambertMaterialParameters extends THREE.ShaderMaterialParameters, THREE.MeshLambertMaterialParameters {
151
+ export interface CustomMeshLambertMaterialParameters extends THREE.ShaderMaterialParameters {
134
152
  instancing?: boolean | undefined;
153
+ instancingColor?: boolean | undefined;
154
+ color?: THREE.ColorRepresentation | undefined;
155
+ emissive?: THREE.ColorRepresentation | undefined;
156
+ emissiveIntensity?: number | undefined;
157
+ fog?: boolean | undefined;
135
158
  }
136
159
  export class CustomMeshLambertMaterial extends CustomMaterial {
137
160
  type: string;
@@ -143,29 +166,14 @@ export class CustomMeshLambertMaterial extends CustomMaterial {
143
166
  get instancing(): boolean;
144
167
  set instancing(value: boolean);
145
168
  /**
146
- * @default new THREE.Color( 0xffffff )
147
- */
148
- color: THREE.Color;
149
- /**
150
- * @default null
151
- */
152
- bumpMap: THREE.Texture | null;
153
- /**
154
- * @default 1
155
- */
156
- bumpScale: number;
157
- /**
158
- * @default null
159
- */
160
- displacementMap: THREE.Texture | null;
161
- /**
162
- * @default 1
169
+ * @default false
163
170
  */
164
- displacementScale: number;
171
+ get instancingColor(): boolean;
172
+ set instancingColor(value: boolean);
165
173
  /**
166
- * @default 0
174
+ * @default new THREE.Color( 0xffffff )
167
175
  */
168
- displacementBias: number;
176
+ color: THREE.Color;
169
177
  /**
170
178
  * @default new THREE.Color( 0x000000 )
171
179
  */
@@ -174,83 +182,6 @@ export class CustomMeshLambertMaterial extends CustomMaterial {
174
182
  * @default 1
175
183
  */
176
184
  emissiveIntensity: number;
177
- /**
178
- * @default null
179
- */
180
- emissiveMap: THREE.Texture | null;
181
- /**
182
- * @default false
183
- */
184
- flatShading: boolean;
185
- /**
186
- * @default null
187
- */
188
- map: THREE.Texture | null;
189
- /**
190
- * @default null
191
- */
192
- lightMap: THREE.Texture | null;
193
- /**
194
- * @default 1
195
- */
196
- lightMapIntensity: number;
197
- /**
198
- * @default null
199
- */
200
- normalMap: THREE.Texture | null;
201
- normalMapType: THREE.NormalMapTypes;
202
- /**
203
- * @default new THREE.Vector2( 1, 1 )
204
- */
205
- normalScale: THREE.Vector2;
206
- /**
207
- * @default null
208
- */
209
- aoMap: THREE.Texture | null;
210
- /**
211
- * @default 1
212
- */
213
- aoMapIntensity: number;
214
- /**
215
- * @default null
216
- */
217
- specularMap: THREE.Texture | null;
218
- /**
219
- * @default null
220
- */
221
- alphaMap: THREE.Texture | null;
222
- /**
223
- * @default null
224
- */
225
- envMap: THREE.Texture | null;
226
- /**
227
- * @default THREE.MultiplyOperation
228
- */
229
- combine: THREE.Combine;
230
- /**
231
- * @default 1
232
- */
233
- reflectivity: number;
234
- /**
235
- * @default 0.98
236
- */
237
- refractionRatio: number;
238
- /**
239
- * @default false
240
- */
241
- wireframe: boolean;
242
- /**
243
- * @default 1
244
- */
245
- wireframeLinewidth: number;
246
- /**
247
- * @default 'round'
248
- */
249
- wireframeLinecap: string;
250
- /**
251
- * @default 'round'
252
- */
253
- wireframeLinejoin: string;
254
185
  /**
255
186
  * Whether the material is affected by fog. Default is true.
256
187
  * @default fog
@@ -259,11 +190,15 @@ export class CustomMeshLambertMaterial extends CustomMaterial {
259
190
  protected refreshUniformsCommon(uniforms: {
260
191
  [uniform: string]: THREE.IUniform;
261
192
  }, material: CustomMeshLambertMaterial, renderer: THREE.WebGLRenderer): void;
262
- protected onBeforeRender(renderer: THREE.WebGLRenderer, scene: THREE.Scene, camera: THREE.Camera, geometry: THREE.BufferGeometry, material: THREE.Material, group: THREE.Group): void;
193
+ protected refreshUniforms(uniforms: {
194
+ [uniform: string]: THREE.IUniform<any>;
195
+ }, material: CustomMaterial, renderer: THREE.WebGLRenderer): void;
263
196
  copy(source: CustomMeshLambertMaterial): this;
264
197
  }
265
- export interface CustomLineMaterialParameters extends THREE.ShaderMaterialParameters, THREE.LineBasicMaterialParameters {
198
+ export interface CustomLineMaterialParameters extends THREE.ShaderMaterialParameters {
266
199
  instancing?: boolean | undefined;
200
+ instancingColor?: boolean | undefined;
201
+ color?: THREE.ColorRepresentation | undefined;
267
202
  }
268
203
  export class CustomLineMaterial extends CustomMaterial {
269
204
  type: string;
@@ -275,70 +210,67 @@ export class CustomLineMaterial extends CustomMaterial {
275
210
  get instancing(): boolean;
276
211
  set instancing(value: boolean);
277
212
  /**
278
- * @default 0xffffff
279
- */
280
- color: THREE.Color;
281
- /**
282
- * Whether the material is affected by fog. Default is true.
283
- * @default true
284
- */
285
- fog: boolean;
286
- /**
287
- * @default 1
288
- */
289
- linewidth: number;
290
- /**
291
- * @default 'round'
292
- */
293
- linecap: string;
294
- /**
295
- * @default 'round'
213
+ * @default false
296
214
  */
297
- linejoin: string;
215
+ get instancingColor(): boolean;
216
+ set instancingColor(value: boolean);
298
217
  /**
299
- * @default null
218
+ * @default 0xffffff
300
219
  */
301
- map: THREE.Texture | null;
302
- protected refreshUniformsCommon(uniforms: {
220
+ color: THREE.Color;
221
+ copy(source: CustomLineMaterial): this;
222
+ protected refreshUniforms(uniforms: {
303
223
  [uniform: string]: THREE.IUniform;
304
224
  }, material: CustomLineMaterial, renderer: THREE.WebGLRenderer): void;
305
- protected onBeforeRender(renderer: THREE.WebGLRenderer, scene: THREE.Scene, camera: THREE.Camera, geometry: THREE.BufferGeometry, material: THREE.Material, group: THREE.Group): void;
306
- copy(source: CustomLineMaterial): this;
307
225
  }
308
226
  export interface MeshLineMaterialParameters extends THREE.ShaderMaterialParameters {
309
- alphaToCoverage?: boolean | undefined;
310
227
  color?: THREE.ColorRepresentation | undefined;
311
228
  dashed?: boolean | undefined;
312
229
  dashScale?: number | undefined;
313
230
  dashSize?: number | undefined;
314
231
  dashOffset?: number | undefined;
315
232
  gapSize?: number | undefined;
316
- linewidth?: number | undefined;
317
- resolution?: THREE.Vector2 | undefined;
318
- wireframe?: boolean | undefined;
319
233
  worldUnits?: boolean | undefined;
320
234
  }
321
235
  export class MeshLineMaterial extends CustomMaterial {
322
236
  type: string;
323
237
 
324
238
  constructor(parameters: MeshLineMaterialParameters);
325
- get color(): THREE.Color;
326
- set color(value: THREE.ColorRepresentation);
239
+ /**
240
+ * @default false
241
+ */
327
242
  get worldUnits(): boolean;
328
243
  set worldUnits(value: boolean);
244
+ /**
245
+ * @default false
246
+ */
329
247
  get dashed(): boolean;
330
248
  set dashed(value: boolean);
331
- get dashScale(): number;
332
- set dashScale(value: number);
333
- get dashSize(): number;
334
- set dashSize(value: number);
335
- get dashOffset(): number;
336
- set dashOffset(value: number);
337
- get gapSize(): number;
338
- set gapSize(value: number);
339
249
  get resolution(): THREE.Vector2;
340
- set resolution(value: THREE.Vector2);
341
- onBeforeRender(renderer: THREE.WebGLRenderer, scene: THREE.Scene, camera: THREE.Camera, geometry: THREE.BufferGeometry, material: THREE.Material, group: THREE.Group): void;
250
+ /**
251
+ * @default 0xffffff
252
+ */
253
+ color: THREE.Color;
254
+ /**
255
+ * @default 1
256
+ */
257
+ dashScale: number;
258
+ /**
259
+ * @default 1
260
+ */
261
+ dashSize: number;
262
+ /**
263
+ * @default 0
264
+ */
265
+ dashOffset: number;
266
+ /**
267
+ * @default 1
268
+ */
269
+ gapSize: number;
270
+ copy(source: MeshLineMaterial): this;
271
+ protected refreshUniforms(uniforms: {
272
+ [uniform: string]: THREE.IUniform<any>;
273
+ }, material: CustomMaterial, renderer: THREE.WebGLRenderer): void;
342
274
  }
343
275
  export interface CustomPointMaterialParameters extends THREE.ShaderMaterialParameters, THREE.PointsMaterialParameters {
344
276
  }
@@ -366,16 +298,13 @@ export class CustomPointMaterial extends CustomMaterial {
366
298
  * @default true
367
299
  */
368
300
  sizeAttenuation: boolean;
369
- /**
370
- * Whether the material is affected by fog. Default is true.
371
- * @default fog
372
- */
373
- fog: boolean;
301
+ copy(source: CustomPointMaterial): this;
374
302
  protected refreshUniformsCommon(uniforms: {
375
303
  [uniform: string]: THREE.IUniform;
376
304
  }, material: CustomPointMaterial, renderer: THREE.WebGLRenderer): void;
377
- protected onBeforeRender(renderer: THREE.WebGLRenderer, scene: THREE.Scene, camera: THREE.Camera, geometry: THREE.BufferGeometry, material: THREE.Material, group: THREE.Group): void;
378
- copy(source: CustomPointMaterial): this;
305
+ protected refreshUniforms(uniforms: {
306
+ [uniform: string]: THREE.IUniform<any>;
307
+ }, material: CustomMaterial, renderer: THREE.WebGLRenderer): void;
379
308
  }
380
309
  export namespace Viewer3DIcons {
381
310
  const VIEWER_SETTINGS_ICON: string;
@@ -409,6 +338,7 @@ export namespace Viewer2DIcons {
409
338
  const REMARK_CIRCLE_ICON: string;
410
339
  const ZOOM_IN: string;
411
340
  const ZOOM_OUT: string;
341
+ const FIT_WIDTH: string;
412
342
  }
413
343
  export class MeshLineGeometry extends THREE.InstancedBufferGeometry {
414
344
  type: string;
@@ -478,6 +408,7 @@ export class RenderEventTypes {
478
408
  static RENDER_CLICK_EVENT: string;
479
409
  static RENDER_HOVER_EVENT: string;
480
410
  static RENDER_DOUBLE_CLICK_EVENT: string;
411
+ static RENDER_DELETE_EVENT: string;
481
412
  }
482
413
  export class SelectionChangedEvent extends Event {
483
414
  selectedIds: ModelElementIds[];
@@ -497,6 +428,11 @@ export class HoverEvent extends Event {
497
428
 
498
429
  constructor(type: string, modelId: string, modelElementId: string);
499
430
  }
431
+ export class DeleteEvent extends Event {
432
+ deletedIds: ModelElementIds[];
433
+
434
+ constructor(type: string, deletedIds?: ModelElementIds[]);
435
+ }
500
436
  export class GlobalEvents {
501
437
  static events: EventsDispatcherCore;
502
438
  }
@@ -998,7 +934,7 @@ export class ModelElementTree {
998
934
  * Gets the root element of the model part
999
935
  * @returns {ModelElement} - model element instance
1000
936
  */
1001
- getRootElement(): ModelElement;
937
+ getRootElement(): ModelElement | undefined;
1002
938
  /**
1003
939
  * Gets all elements of the model part
1004
940
  * @returns array of the model elements
@@ -1009,7 +945,7 @@ export class ModelElementTree {
1009
945
  * @param { string } id - model element id
1010
946
  * @returns model element;
1011
947
  */
1012
- getElement(id: string): ModelElement;
948
+ getElement(id: string): ModelElement | undefined;
1013
949
  /**
1014
950
  * Checks given element is viewable
1015
951
  * @param {string|ModelElement} element - element id or element instance
@@ -1103,7 +1039,6 @@ export interface CustomSpriteMaterialParameters extends THREE.ShaderMaterialPara
1103
1039
  alphaMap?: THREE.Texture | null | undefined;
1104
1040
  rotation?: number | undefined;
1105
1041
  sizeAttenuation?: boolean | undefined;
1106
- fog?: boolean | undefined;
1107
1042
  center?: THREE.Vector2 | undefined;
1108
1043
  discreteClipping?: boolean | undefined;
1109
1044
  offset?: THREE.Vector2 | undefined;
@@ -1113,6 +1048,12 @@ export class CustomSpriteMaterial extends CustomMaterial {
1113
1048
  readonly isSpriteMaterial: true;
1114
1049
 
1115
1050
  constructor(parameters?: CustomSpriteMaterialParameters);
1051
+ /**
1052
+ * @default true
1053
+ */
1054
+ get discreteClipping(): boolean;
1055
+ set discreteClipping(value: boolean);
1056
+ get resolution(): THREE.Vector2;
1116
1057
  /**
1117
1058
  * @default new THREE.Color( 0xffffff )
1118
1059
  */
@@ -1133,15 +1074,6 @@ export class CustomSpriteMaterial extends CustomMaterial {
1133
1074
  * @default true
1134
1075
  */
1135
1076
  sizeAttenuation: boolean;
1136
- /**
1137
- * @default true
1138
- */
1139
- transparent: boolean;
1140
- /**
1141
- * Whether the material is affected by fog. Default is true.
1142
- * @default fog
1143
- */
1144
- fog: boolean;
1145
1077
  /**
1146
1078
  * @default new THREE.Vector2(0.5, 0.5)
1147
1079
  */
@@ -1150,18 +1082,13 @@ export class CustomSpriteMaterial extends CustomMaterial {
1150
1082
  * @default new THREE.Vector2(0.0, 0.0)
1151
1083
  */
1152
1084
  offset: THREE.Vector2;
1153
- /**
1154
- * @default true
1155
- */
1156
- get discreteClipping(): boolean;
1157
- set discreteClipping(value: boolean);
1158
- get resolution(): THREE.Vector2;
1159
- set resolution(value: THREE.Vector2);
1085
+ copy(source: CustomSpriteMaterial): this;
1160
1086
  protected refreshUniformsCommon(uniforms: {
1161
1087
  [uniform: string]: THREE.IUniform;
1162
1088
  }, material: CustomSpriteMaterial, renderer: THREE.WebGLRenderer): void;
1163
- protected onBeforeRender(renderer: THREE.WebGLRenderer, scene: THREE.Scene, camera: THREE.Camera, geometry: THREE.BufferGeometry, material: THREE.Material, group: THREE.Group): void;
1164
- copy(source: CustomSpriteMaterial): this;
1089
+ protected refreshUniforms(uniforms: {
1090
+ [uniform: string]: THREE.IUniform<any>;
1091
+ }, material: CustomMaterial, renderer: THREE.WebGLRenderer): void;
1165
1092
  }
1166
1093
 
1167
1094
  export class SettingsNames {
@@ -1252,16 +1179,27 @@ export class CoreEventTypes {
1252
1179
  static VIEWER_MOUSE_MOVE_EVENT: string;
1253
1180
  static VIEWER_MOUSE_UP_EVENT: string;
1254
1181
  static VIEWER_MOUSE_LONG_TOUCH_EVENT: string;
1182
+ static VIEWER_MOUSE_WHEEL: string;
1183
+ static VIEWER_TOUCHSTART_EVENT: string;
1184
+ static VIEWER_TOUCHEND_EVENT: string;
1255
1185
  static SETTING_CHANGED_EVENT: string;
1256
1186
  static SETTING_RESET_EVENT: string;
1257
1187
  static SETTING_LANGUAGE_CHANGED_EVENT: string;
1258
1188
  static SETTING_THEME_CHANGED_EVENT: string;
1259
1189
  }
1190
+ export namespace ControlState {
1191
+ enum State {
1192
+ ACTIVE = 0,
1193
+ INACTIVE = 1,
1194
+ DISABLED = 2
1195
+ }
1196
+ }
1260
1197
  export interface IControl {
1261
1198
  container: HTMLElement;
1262
1199
  getId(): string;
1263
1200
  setToolTip(tooltipText: string): void;
1264
1201
  setText(text: string): void;
1202
+ setState(state: ControlState.State): void;
1265
1203
  }
1266
1204
  export class Control implements IControl {
1267
1205
  container: HTMLElement;
@@ -1272,6 +1210,7 @@ export class Control implements IControl {
1272
1210
  getId(): string;
1273
1211
  setToolTip(tooltipText: string): void;
1274
1212
  setText(text: string): void;
1213
+ setState(state: ControlState.State): void;
1275
1214
  }
1276
1215
  export interface IMenu {
1277
1216
  controls: IControl[];
@@ -1305,12 +1244,15 @@ export class ExtensionBase {
1305
1244
  * @returns {string} Returns the name of the extension.
1306
1245
  */
1307
1246
  getName(): string;
1247
+ addCursorPhantomFromSvg(template: string): void;
1248
+ removeCursorPhantom(): void;
1308
1249
  onMouseDown(event: MouseEvent): void;
1309
1250
  onMouseMove(event: MouseEvent): void;
1310
1251
  onMouseUp(event: MouseEvent): void;
1311
1252
  onMouseLongTouch(event: MouseEvent): void;
1312
1253
  onToolbarCreated(toolbar: Toolbar): void;
1313
- protected bindDomEvents(): void;
1254
+ onTouchStart(event: TouchEvent): void;
1255
+ onTouchEnd(event: TouchEvent): void;
1314
1256
  }
1315
1257
  export class ExtensionManager {
1316
1258
  registerExtensionType(extensionId: string, extension: typeof ExtensionBase): boolean;
@@ -2730,6 +2672,7 @@ export class EventTypes extends CoreEventTypes {
2730
2672
  static RENDER_CLICK_EVENT: string;
2731
2673
  static RENDER_HOVER_EVENT: string;
2732
2674
  static RENDER_DOUBLE_CLICK_EVENT: string;
2675
+ static RENDER_DELETE_EVENT: string;
2733
2676
  }
2734
2677
  export class ModelPartEvent extends Event {
2735
2678
  modelPartId: string;
@@ -2765,7 +2708,7 @@ export class Viewer3D extends ViewerBase {
2765
2708
  * @param onSuccessCallback
2766
2709
  * @param onErrorCallback
2767
2710
  */
2768
- loadModelPart(buffer: ArrayBuffer, options: ModelLoadingOptions, onSuccessCallback: SuccessCallback, onErrorCallback: ErrorCallback): void;
2711
+ loadModelPart(data: ArrayBuffer | string, options: ModelLoadingOptions, onSuccessCallback: SuccessCallback, onErrorCallback: ErrorCallback): void;
2769
2712
  /**
2770
2713
  * unloads model part from the viewer
2771
2714
  * @param modelPart - model part id or model part instance
@@ -2932,6 +2875,7 @@ export interface LabelSpriteParameters {
2932
2875
  }
2933
2876
  export class LabelSprite extends THREE.Sprite {
2934
2877
  readonly extraHeightFactor = 1.4;
2878
+ material: CustomSpriteMaterial;
2935
2879
 
2936
2880
  constructor(parameters: LabelSpriteParameters);
2937
2881
  get sizeAttenuation(): boolean;
@@ -2982,6 +2926,7 @@ export class LabelSprite extends THREE.Sprite {
2982
2926
  */
2983
2927
  get textPadding(): THREE.Vector4Tuple;
2984
2928
  set textPadding(value: THREE.Vector4Tuple);
2929
+ raycast(raycaster: THREE.Raycaster, intersects: THREE.Intersection<THREE.Object3D<THREE.Event>>[]): void;
2985
2930
  dispose(): void;
2986
2931
  }
2987
2932
  export interface MeshPointMaterialParameters extends THREE.ShaderMaterialParameters {
@@ -2991,22 +2936,20 @@ export interface MeshPointMaterialParameters extends THREE.ShaderMaterialParamet
2991
2936
  export class MeshPointMaterial extends CustomMaterial {
2992
2937
 
2993
2938
  constructor(parameters?: MeshPointMaterialParameters);
2994
- /**
2995
- * @default true
2996
- */
2997
- sizeAttenuation: boolean;
2998
2939
  /**
2999
2940
  * @default true
3000
2941
  */
3001
2942
  get discreteClipping(): boolean;
3002
2943
  set discreteClipping(value: boolean);
3003
2944
  get resolution(): THREE.Vector2;
3004
- set resolution(value: THREE.Vector2);
3005
- protected refreshUniformsCommon(uniforms: {
3006
- [uniform: string]: THREE.IUniform;
3007
- }, material: MeshPointMaterial, renderer: THREE.WebGLRenderer): void;
3008
- protected onBeforeRender(renderer: THREE.WebGLRenderer, scene: THREE.Scene, camera: THREE.Camera, geometry: THREE.BufferGeometry, material: THREE.Material, group: THREE.Group): void;
2945
+ /**
2946
+ * @default true
2947
+ */
2948
+ sizeAttenuation: boolean;
3009
2949
  copy(source: MeshPointMaterial): this;
2950
+ protected refreshUniforms(uniforms: {
2951
+ [uniform: string]: THREE.IUniform<any>;
2952
+ }, material: CustomMaterial, renderer: THREE.WebGLRenderer): void;
3010
2953
  }
3011
2954
  export interface MeshPointParamter {
3012
2955
  point?: THREE.Vector3;
@@ -3037,16 +2980,22 @@ export class MeshPoints extends THREE.Mesh {
3037
2980
  dispose(): void;
3038
2981
  raycast(raycaster: THREE.Raycaster, intersects: THREE.Intersection<THREE.Object3D<THREE.Event>>[]): void;
3039
2982
  }
2983
+ export class DeviceEventHandler {
2984
+ static isMobile: boolean;
2985
+ static eventStartType: string;
2986
+ static eventProcessType: string;
2987
+ static eventEndType: string;
2988
+ }
3040
2989
  export interface IWindowStyle {
3041
2990
  width: string;
3042
2991
  height: string;
3043
2992
  left: string;
3044
- right: string;
3045
2993
  top: string;
3046
2994
  }
3047
2995
  export interface IWindowStateOptions {
3048
2996
  saveKey: string;
3049
- restoreWindowSize: boolean;
2997
+ restoreWindowSize?: boolean;
2998
+ restoreWindowPosition?: boolean;
3050
2999
  }
3051
3000
  export class WindowStater {
3052
3001
  get windowStylesState(): IWindowStyle;
@@ -3064,13 +3013,6 @@ export class Dragger {
3064
3013
  constructor(allowedDraggableElement: HTMLElement, draggableContainer: HTMLElement, containerToRestriction: HTMLElement, windowStater?: WindowStater);
3065
3014
  get windowState(): IWindowStyle | null;
3066
3015
  }
3067
- export namespace ControlState {
3068
- enum State {
3069
- ACTIVE = 0,
3070
- INACTIVE = 1,
3071
- DISABLED = 2
3072
- }
3073
- }
3074
3016
  export class Button extends Control {
3075
3017
 
3076
3018
  constructor(id: string);
@@ -3106,6 +3048,7 @@ export class SubMenu implements IMenu {
3106
3048
  readonly controls: IControl[];
3107
3049
  set selectedIndex(value: number);
3108
3050
  get selectedIndex(): number;
3051
+ setEnabled(index: number, value: boolean): void;
3109
3052
  addControl(control: IControl, index?: number): void;
3110
3053
  removeControl(index?: number): void;
3111
3054
  clearList(): void;
@@ -3127,6 +3070,40 @@ export class ComboButton extends Control {
3127
3070
  setText(text: string): void;
3128
3071
  setFromSvgTemlate(template: string): void;
3129
3072
  }
3073
+ export class Checkbox {
3074
+
3075
+ constructor(id: string, checked: boolean, disabled: boolean, placeholder: string);
3076
+ get checked(): boolean;
3077
+ set checked(value: boolean);
3078
+ get disabled(): boolean;
3079
+ set disabled(value: boolean);
3080
+ get label(): HTMLLabelElement;
3081
+ onChange(value: boolean): void;
3082
+ createElement(): Element;
3083
+ }
3084
+ interface ISelectItem {
3085
+ text: string;
3086
+ value: string;
3087
+ }
3088
+ export class Select {
3089
+
3090
+ constructor(id: string, items: ISelectItem[], placeholder: string);
3091
+ get select(): HTMLElement;
3092
+ get disabled(): boolean;
3093
+ set disabled(value: boolean);
3094
+ get selectedIndex(): number;
3095
+ set selectedIndex(value: number);
3096
+ get placeholder(): string;
3097
+ set placeholder(value: string);
3098
+ get label(): HTMLElement;
3099
+ get previousSelectedIndex(): number;
3100
+ onChange({ index, value }: {
3101
+ index: any;
3102
+ value: any;
3103
+ }): void;
3104
+ update(array: ISelectItem[], selectedIndex?: number): void;
3105
+ }
3106
+ export {};
3130
3107
  interface ElementClass {
3131
3108
  panelClassName?: string;
3132
3109
  contentClassName?: string;
@@ -3142,13 +3119,14 @@ export class Dialog extends Control {
3142
3119
  setDialogContent(value: HTMLElement): Dialog;
3143
3120
  setHeader(value: HTMLElement): Dialog;
3144
3121
  setCaption(value: string): Dialog;
3145
- setIcon(iconClassName: string): Dialog;
3122
+ setSvgIcon(template: string): Dialog;
3146
3123
  setFooter(value: HTMLElement): Dialog;
3147
3124
  setDialogElementClassNames(value: ElementClass): Dialog;
3148
3125
  setResizable(value: boolean): Dialog;
3149
3126
  setWindowOptions(value: IWindowStateOptions): Dialog;
3150
3127
  setDraggable(value: boolean): Dialog;
3151
- openDialog(): HTMLElement;
3128
+ setCloseble(value: boolean): Dialog;
3129
+ openDialog(x?: number, y?: number): HTMLElement;
3152
3130
  destroyDialog(): void;
3153
3131
  isDialogShown(): boolean;
3154
3132
  subscribe(fn: (state: boolean) => void): void;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pilotdev/pilot-web-3d",
3
- "version": "23.0.7",
3
+ "version": "23.0.10",
4
4
  "description": "TypeScript definitions for ASCON PilotWeb3D component",
5
5
  "main": "",
6
6
  "types": "index.d.ts",