@nebula-spatial/viewer 0.2.0 → 0.2.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/dist/types.d.ts CHANGED
@@ -2,6 +2,11 @@ import type { Box3, ColorRepresentation, Object3D, Vector3 } from 'three';
2
2
  import type { CadViewerCapability, CameraStateStore, ViewerUiOptions } from './cad/types';
3
3
  export type { CadBlockModel, CadDocumentHandle, CadFontResolver, CadResolvedTextFont, CadHudModel, CadInspectorModel, CadLayerModel, CadLoadSource, CadOpenOptions, CadTextDetails, CadTextSelection, CadTextSelectionId, CadViewerCapability, ResolveTextFont, CadViewerEventMap, CameraStateStore, ViewerUiOptions, ViewerUiParts, ViewerUiPreset, ViewerUiTheme, } from './cad/types';
4
4
  export type ViewerViewMode = '2d' | '3d';
5
+ export type ViewerEnvironment = 'room' | {
6
+ /** Load an external equirectangular HDR texture for image-based lighting. */
7
+ readonly type: 'hdr';
8
+ readonly url: string;
9
+ };
5
10
  export interface ViewerDocumentRect {
6
11
  readonly minX: number;
7
12
  readonly minY: number;
@@ -41,6 +46,8 @@ export interface ViewerOptions {
41
46
  alpha?: boolean;
42
47
  powerPreference?: WebGLPowerPreference;
43
48
  initialViewMode?: ViewerViewMode;
49
+ /** Image-based lighting environment. Defaults to the built-in room environment. */
50
+ environment?: ViewerEnvironment;
44
51
  autoSelectOnPick?: boolean;
45
52
  pointerPick?: boolean;
46
53
  cameraStateStore?: CameraStateStore | false;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@nebula-spatial/viewer",
3
- "version": "0.2.0",
3
+ "version": "0.2.1",
4
4
  "description": "Read-only Three.js viewer facade",
5
5
  "license": "ISC",
6
6
  "engines": {
@@ -36,7 +36,7 @@
36
36
  "prepack": "npm run build"
37
37
  },
38
38
  "dependencies": {
39
- "@nebula-spatial/cad-loader": "^0.2.0"
39
+ "@nebula-spatial/cad-loader": "^0.2.1"
40
40
  },
41
41
  "peerDependencies": {
42
42
  "three": "0.182.0"