@procore/bim-webviewer-sdk 15.1.0 → 15.2.0-rc.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.
Files changed (28) hide show
  1. package/CHANGELOG.md +15 -0
  2. package/dist/Procore.Bim.Webviewer.d.ts +92 -26
  3. package/dist/Procore.Bim.Webviewer.js +1 -1
  4. package/dist/types/src/Webviewer.d.ts +40 -25
  5. package/dist/types/src/api/analytic_events/analyticKeys.d.ts +3 -0
  6. package/dist/types/src/api/types/Model.d.ts +0 -21
  7. package/dist/types/src/api/types/ModelRevision.d.ts +9 -0
  8. package/dist/types/src/api/types/Viewpoint.d.ts +15 -0
  9. package/dist/types/src/components/Tool.d.ts +19 -0
  10. package/dist/types/src/components/ToolBarComponent/ToolBarComponent.d.ts +31 -5
  11. package/dist/types/src/components/ToolBarTools.d.ts +17 -16
  12. package/dist/types/src/components/ViewpointManager/ViewpointManager.d.ts +10 -2
  13. package/dist/types/src/components/ViewpointManager/__tests__/fixtures.d.ts +5 -1
  14. package/dist/types/src/components/WindowModelObjectComponent/WindowModelObjectComponent.d.ts +1 -1
  15. package/dist/types/src/components/WindowSettingsComponent.d.ts +1 -1
  16. package/dist/types/src/components/WindowTreeViewComponent.d.ts +4 -4
  17. package/dist/types/src/components/WindowViewPropertiesComponent/WindowViewPropertiesComponent.d.ts +1 -1
  18. package/dist/types/src/controllers/CacheController.d.ts +2 -1
  19. package/dist/types/src/procoregl/HiddenNodeServices/HiddenNodeServices.d.ts +1 -1
  20. package/dist/types/src/sdk.d.ts +12 -3
  21. package/dist/types/src/types/WebviewerOptions.d.ts +3 -2
  22. package/dist/types/src/utils/ApiMetaData/ApiMetaData.d.ts +1 -1
  23. package/dist/types/src/utils/ApiMetaData/__tests__/mocks.d.ts +1 -1
  24. package/dist/types/src/utils/Enums.d.ts +13 -12
  25. package/dist/types/src/viewpoint/ViewpointFactory.d.ts +5 -1
  26. package/dist/types/src/viewpoint/types.d.ts +5 -1
  27. package/package.json +1 -1
  28. package/dist/types/src/components/ToolEnum.d.ts +0 -4
@@ -5,39 +5,54 @@ import { ObjectFilter } from './types/ObjectFilter';
5
5
  import { PublicNode } from './types/PublicNode';
6
6
  import { NavigationMode } from './navigation/NavigationModes';
7
7
  import { SectionDataAutodeskFormat, SectionDataProcoreFormat } from './sectioning/SectionController';
8
- import type { Viewpoint, Visibility } from './api/types/Model';
8
+ import type { Viewpoint, Visibility } from './api/types/Viewpoint';
9
9
  import type { CssColor } from './components/Markup/SvgRenderer';
10
10
  import { RenderMode } from './utils/constants';
11
11
  export declare class Webviewer {
12
12
  options: Options;
13
13
  static readonly tools: {
14
- [key: string]: import("./types/WebviewerOptions").Tool;
14
+ readonly ALL: 0;
15
+ readonly BOTTOMTOOL: 1;
16
+ readonly FLOORPLAN: 2;
17
+ readonly OBJECTMODELTREE: 3;
18
+ readonly MODELVIEWS: 4;
19
+ readonly COACHMARKS: 5;
20
+ readonly COACHMARKSHIDDEN: 6;
21
+ readonly COACHMARKSECTION: 7;
22
+ readonly MEASUREMENT_SD: 8;
23
+ readonly SETTINGS: 9;
24
+ readonly CONTEXTMENU: 10;
25
+ readonly COACHMARKSFOV: 11;
26
+ readonly VIEW_PROPERTIES: 12;
27
+ readonly LOADING: 13;
28
+ readonly XRAY_MODE: 14;
29
+ readonly SECTION_BOX: 15;
15
30
  };
16
31
  static readonly toolbar_enum: {
17
- NONE: number;
18
- HOME: number;
19
- NAV_DEFAULT: number;
20
- NAV_FLY: number;
21
- NAV_ORBIT: number;
22
- OBJECT: number;
23
- PREMEASURE: number;
24
- MEASURE: number;
25
- SETTING: number;
26
- VIEW: number;
27
- PROPERTIES: number;
28
- CONTEXT_MENU: number;
29
- XRAY_MODE: number;
30
- SECTION_BOX: number;
32
+ readonly NONE: 0;
33
+ readonly HOME: 1;
34
+ readonly NAV_DEFAULT: 2;
35
+ readonly NAV_FLY: 3;
36
+ readonly NAV_ORBIT: 4;
37
+ readonly OBJECT: 5;
38
+ readonly PREMEASURE: 6;
39
+ readonly MEASURE: 7;
40
+ readonly SETTING: 8;
41
+ readonly VIEW: 9;
42
+ readonly PROPERTIES: 10;
43
+ readonly CONTEXT_MENU: 11;
44
+ readonly XRAY_MODE: 12;
45
+ readonly SECTION_BOX: 13;
46
+ };
47
+ static readonly action: {
48
+ readonly NONE: -1;
49
+ readonly PAN: 1;
50
+ readonly KEYMOVE: 2;
51
+ readonly ROTATE: 3;
52
+ readonly FLY: 4;
53
+ readonly ORBIT: 5;
54
+ readonly STRAFE: 6;
31
55
  };
32
- static readonly action: Readonly<{
33
- NONE: -1;
34
- PAN: 1;
35
- KEYMOVE: 2;
36
- ROTATE: 3;
37
- FLY: 4;
38
- ORBIT: 5;
39
- STRAFE: 6;
40
- }>;
41
56
  events: {
42
57
  addEventListener: (eventName: string, callback: any) => void;
43
58
  removeEventListener: (eventName: string, callback: any) => void;
@@ -67,6 +67,7 @@ export declare const SECTION_BOX_ORIGIN: {
67
67
  readonly OBJECT_TREE: "object_tree";
68
68
  readonly OBJECT_TREE_ACTIONS: "object_tree_actions";
69
69
  readonly SDK: "sdk";
70
+ readonly SDK_VIEWPOINT: "sdk_viewpoint";
70
71
  readonly TOOLBAR: "toolbar";
71
72
  readonly COACHMARK_SECTIONING: "coachmark_sectioning";
72
73
  readonly VIEWS: "views";
@@ -111,6 +112,8 @@ export declare const RENDER_MODE_ORIGIN: {
111
112
  readonly OBJECT_TREE: "object_tree";
112
113
  readonly OBJECT_TREE_ACTIONS: "object_tree_actions";
113
114
  readonly SDK: "sdk";
115
+ readonly SDK_VIEWPOINT: "sdk_viewpoint";
114
116
  readonly TOOLBAR: "toolbar";
115
117
  readonly HOTKEY: "hotkey";
116
118
  };
119
+ export type RenderModeOrigin = (typeof RENDER_MODE_ORIGIN)[keyof typeof RENDER_MODE_ORIGIN];
@@ -1,24 +1,3 @@
1
- export type Visibility = {
2
- default_visibility: boolean;
3
- exceptions: {
4
- object_ids: number[];
5
- object_ranges: [number, number][];
6
- };
7
- };
8
- export type Viewpoint = {
9
- camera_data: string;
10
- sections_data: string;
11
- redlines_data: string;
12
- visibility?: Visibility;
13
- };
14
- export type ModelRevisionViewpoint = Viewpoint & {
15
- primary: boolean;
16
- };
17
1
  export type Model = {
18
2
  id: number;
19
3
  };
20
- export type ModelRevision = {
21
- id: number;
22
- revision: number;
23
- viewpoints: ModelRevisionViewpoint[];
24
- };
@@ -0,0 +1,9 @@
1
+ import { Viewpoint } from './Viewpoint';
2
+ export type ModelRevisionViewpoint = Viewpoint & {
3
+ primary: boolean;
4
+ };
5
+ export type ModelRevision = {
6
+ id: number;
7
+ revision: number;
8
+ viewpoints: ModelRevisionViewpoint[];
9
+ };
@@ -0,0 +1,15 @@
1
+ import { RenderMode } from '../../utils/constants';
2
+ export type Visibility = {
3
+ default_visibility: boolean;
4
+ exceptions: {
5
+ object_ids: number[];
6
+ object_ranges: [number, number][];
7
+ };
8
+ };
9
+ export type Viewpoint = {
10
+ camera_data: string;
11
+ sections_data: string;
12
+ redlines_data: string;
13
+ visibility?: Visibility | null;
14
+ render_mode?: RenderMode | null;
15
+ };
@@ -0,0 +1,19 @@
1
+ export declare const TOOL: {
2
+ readonly ALL: 0;
3
+ readonly BOTTOMTOOL: 1;
4
+ readonly FLOORPLAN: 2;
5
+ readonly OBJECTMODELTREE: 3;
6
+ readonly MODELVIEWS: 4;
7
+ readonly COACHMARKS: 5;
8
+ readonly COACHMARKSHIDDEN: 6;
9
+ readonly COACHMARKSECTION: 7;
10
+ readonly MEASUREMENT_SD: 8;
11
+ readonly SETTINGS: 9;
12
+ readonly CONTEXTMENU: 10;
13
+ readonly COACHMARKSFOV: 11;
14
+ readonly VIEW_PROPERTIES: 12;
15
+ readonly LOADING: 13;
16
+ readonly XRAY_MODE: 14;
17
+ readonly SECTION_BOX: 15;
18
+ };
19
+ export type Tool = (typeof TOOL)[keyof typeof TOOL];
@@ -11,22 +11,48 @@ export class ToolBarComponent {
11
11
  toolbarElement: HTMLDivElement | null;
12
12
  toolbarMarginTop: number;
13
13
  toolStringMap: Readonly<{
14
- [x: number]: any;
14
+ 9: any;
15
+ 5: any;
16
+ 10: any;
17
+ 6: any;
18
+ 1: any;
19
+ 8: any;
20
+ 2: any;
21
+ 3: any;
22
+ 4: any;
23
+ 12: any;
24
+ 13: any;
15
25
  }>;
16
26
  toolIconMap: Readonly<{
17
- [x: number]: "nav-icon-views" | "nav-icon-objects" | "nav-icon-properties" | "nav-icon-measure" | "nav-icon-cursor-home" | "nav-icon-settings" | "nav-icon-cursor-default" | "nav-icon-cursor-fly" | "nav-icon-cursor-orbit" | "nav-icon-xray-mode" | "nav-icon-section-box";
27
+ 9: "nav-icon-views";
28
+ 5: "nav-icon-objects";
29
+ 10: "nav-icon-properties";
30
+ 6: "nav-icon-measure";
31
+ 1: "nav-icon-cursor-home";
32
+ 8: "nav-icon-settings";
33
+ 2: "nav-icon-cursor-default";
34
+ 3: "nav-icon-cursor-fly";
35
+ 4: "nav-icon-cursor-orbit";
36
+ 12: "nav-icon-xray-mode";
37
+ 13: "nav-icon-section-box";
18
38
  }>;
19
39
  toolEnumMap: Readonly<{
20
- [x: number]: number;
40
+ 4: 9;
41
+ 3: 5;
42
+ 12: 10;
43
+ 8: 6;
44
+ 15: 13;
45
+ 14: 12;
46
+ 9: 8;
21
47
  }>;
22
48
  toolTip: HTMLDivElement;
23
49
  toolTimeout: NodeJS.Timeout | null;
24
50
  createTools(): void;
25
51
  createToolTip(): HTMLDivElement;
26
52
  setEdges(toolbar: any): void;
27
- getToolIcon(tool: any): "nav-icon-views" | "nav-icon-objects" | "nav-icon-properties" | "nav-icon-measure" | "nav-icon-cursor-home" | "nav-icon-settings" | "nav-icon-cursor-default" | "nav-icon-cursor-fly" | "nav-icon-cursor-orbit" | "nav-icon-xray-mode" | "nav-icon-section-box";
53
+ getToolIcon(tool: any): any;
28
54
  getToolText(tool: any): any;
29
- getToolBarEnum(tool: any): number;
55
+ getToolBarEnum(tool: any): any;
30
56
  getToolId(tool: any): string;
31
57
  createToolBarButton(tool: any, clickFunction?: null): HTMLDivElement;
32
58
  createDividerLine(id: any): HTMLDivElement;
@@ -1,16 +1,17 @@
1
- export namespace ToolBarTools {
2
- const NONE: number;
3
- const HOME: number;
4
- const NAV_DEFAULT: number;
5
- const NAV_FLY: number;
6
- const NAV_ORBIT: number;
7
- const OBJECT: number;
8
- const PREMEASURE: number;
9
- const MEASURE: number;
10
- const SETTING: number;
11
- const VIEW: number;
12
- const PROPERTIES: number;
13
- const CONTEXT_MENU: number;
14
- const XRAY_MODE: number;
15
- const SECTION_BOX: number;
16
- }
1
+ export declare const TOOL_BAR_TOOLS: {
2
+ readonly NONE: 0;
3
+ readonly HOME: 1;
4
+ readonly NAV_DEFAULT: 2;
5
+ readonly NAV_FLY: 3;
6
+ readonly NAV_ORBIT: 4;
7
+ readonly OBJECT: 5;
8
+ readonly PREMEASURE: 6;
9
+ readonly MEASURE: 7;
10
+ readonly SETTING: 8;
11
+ readonly VIEW: 9;
12
+ readonly PROPERTIES: 10;
13
+ readonly CONTEXT_MENU: 11;
14
+ readonly XRAY_MODE: 12;
15
+ readonly SECTION_BOX: 13;
16
+ };
17
+ export type ToolBarTools = (typeof TOOL_BAR_TOOLS)[keyof typeof TOOL_BAR_TOOLS];
@@ -1,7 +1,12 @@
1
1
  import type { Markup } from '../Markup';
2
2
  import type { RenderControllerProxy } from '../../controllers/RenderControllerProxy';
3
3
  import type { SectionBoxDisplayManager } from '../../sectioning/SectionBoxDisplayManager';
4
- import type { Viewpoint, Visibility } from '../../api/types/Model';
4
+ import type { Viewpoint, Visibility } from '../../api/types/Viewpoint';
5
+ import type { RenderModeOrigin, SectionBoxOrigin } from '../../api/analytic_events/analyticKeys';
6
+ type ViewpointOrigins = {
7
+ sectionBox?: SectionBoxOrigin;
8
+ renderMode?: RenderModeOrigin;
9
+ };
5
10
  export declare class ViewpointManager {
6
11
  private renderController;
7
12
  private sectionBoxDisplayManager;
@@ -14,7 +19,10 @@ export declare class ViewpointManager {
14
19
  activateHomeViewpoint: () => Promise<void>;
15
20
  private activateViewpoint;
16
21
  getViewpoint(): Promise<Viewpoint>;
17
- setViewpoint(viewpoint: Viewpoint): Promise<void>;
22
+ setViewpoint(viewpoint: Viewpoint, options?: {
23
+ origins?: ViewpointOrigins;
24
+ }): Promise<void>;
18
25
  setVisibility(visibility: Visibility): Promise<void>;
19
26
  getVisibility(): Promise<Visibility>;
20
27
  }
28
+ export {};
@@ -1,10 +1,14 @@
1
- import type { Viewpoint } from '../../../api/types/Model';
1
+ import type { Viewpoint } from '../../../api/types/Viewpoint';
2
2
  import type { InternalViewpoint } from '../../../viewpoint/types';
3
3
  export declare const VIEWPOINT: Viewpoint;
4
4
  export declare const VIEWPOINT_NO_SECTION: Viewpoint;
5
5
  export declare const VIEWPOINT_NO_REDLINES: Viewpoint;
6
+ export declare const VIEWPOINT_NOTHING_HIDDEN: Viewpoint;
7
+ export declare const VIEWPOINT_NO_RENDER_MODE: Viewpoint;
6
8
  export declare const INTERNAL_VIEWPOINT: InternalViewpoint;
7
9
  export declare const INTERNAL_VIEWPOINT_NO_SECTION: InternalViewpoint;
8
10
  export declare const INTERNAL_VIEWPOINT_NO_REDLINES: InternalViewpoint;
11
+ export declare const INTERNAL_VIEWPOINT_NOTHING_HIDDEN: InternalViewpoint;
12
+ export declare const INTERNAL_VIEWPOINT_NO_RENDER_MODE: InternalViewpoint;
9
13
  export declare const homeViewpoint: InternalViewpoint;
10
14
  export declare const homeViewpointWithoutRedlinesOrSections: InternalViewpoint;
@@ -1,7 +1,7 @@
1
1
  export function WindowModelObjectComponent(options: any, renderController: any, apiController: any, contextMenuEnabled: any): void;
2
2
  export class WindowModelObjectComponent {
3
3
  constructor(options: any, renderController: any, apiController: any, contextMenuEnabled: any);
4
- toolId: import("../../sdk").Tool;
4
+ toolId: 3;
5
5
  onhideupdate: () => Promise<void>;
6
6
  onselectedupdated: (selectedNodeIds: any) => Promise<void>;
7
7
  onobjectselectedfrommodel: (payload: any) => Promise<void>;
@@ -1,7 +1,7 @@
1
1
  export function WindowSettingsComponent(options: any, pubsub: any, settings: any): void;
2
2
  export class WindowSettingsComponent {
3
3
  constructor(options: any, pubsub: any, settings: any);
4
- toolId: import("../sdk").Tool;
4
+ toolId: 9;
5
5
  settings: any;
6
6
  clickEvent: (e: any) => void;
7
7
  dispose(): void;
@@ -1,10 +1,10 @@
1
- export function WindowTreeViewComponent(options: any, api: any, render: any, sectionBoxDisplayManager: any): void;
1
+ export function WindowTreeViewComponent(options: any, api: any, render: any, viewpointManager: any): void;
2
2
  export class WindowTreeViewComponent {
3
- constructor(options: any, api: any, render: any, sectionBoxDisplayManager: any);
4
- toolId: import("../sdk").Tool;
3
+ constructor(options: any, api: any, render: any, viewpointManager: any);
4
+ toolId: 4;
5
5
  api: any;
6
6
  render: any;
7
- sectionBoxDisplayManager: any;
7
+ viewpointManager: any;
8
8
  tree: {};
9
9
  folderLevels: {};
10
10
  viewpointsDict: {};
@@ -1,7 +1,7 @@
1
1
  export function WindowViewPropertiesComponent(options: any, render: any): void;
2
2
  export class WindowViewPropertiesComponent {
3
3
  constructor(options: any, render: any);
4
- toolId: import("../../sdk").Tool;
4
+ toolId: 12;
5
5
  render: any;
6
6
  viewPropertiesId: string;
7
7
  searchTerm: string;
@@ -1,6 +1,7 @@
1
1
  import { GeometryBundle } from '../types/WebviewerOptions';
2
2
  import { FileVersion, PropertiesFile } from '../api/types/FileExtraction';
3
- import { Model, ModelRevision } from '../api/types/Model';
3
+ import { Model } from '../api/types/Model';
4
+ import { ModelRevision } from '../api/types/ModelRevision';
4
5
  export type FileVersionStoreItem = {
5
6
  fileId: FileVersion['file_id'];
6
7
  fileVersionId: FileVersion['id'];
@@ -1,6 +1,6 @@
1
1
  import type { PWF } from '../../pwfreader/PWF';
2
2
  import type { InternalNode, ObjectTree } from '../ObjectTree';
3
- import type { Visibility } from '../../api/types/Model';
3
+ import type { Visibility } from '../../api/types/Viewpoint';
4
4
  export declare class HiddenNodeServices {
5
5
  private hiddenObjectCount;
6
6
  private hiddenMeshnodeIndices;
@@ -6,9 +6,11 @@ export { Cache };
6
6
  export { Webviewer } from './Webviewer';
7
7
  export { BenchmarkReporter as Benchmark } from './utils/Benchmark';
8
8
  export { TestRoutineRecorder } from './utils/Benchmark';
9
- export type { Options, Tool, GeometryBundle, FileExtractionModePwfV1OverrideOptions, FileExtractionModePwfV2OverrideOptions, FileExtractionModeOptions, ModelRevisionModePwfV2Options, ModelRevisionModePwfV1Options, PwfV1Bundle, PwfV2Bundle, CommonOptions, FeatureFlags, } from './types/WebviewerOptions';
9
+ export type { Options, GeometryBundle, FileExtractionModePwfV1OverrideOptions, FileExtractionModePwfV2OverrideOptions, FileExtractionModeOptions, ModelRevisionModePwfV2Options, ModelRevisionModePwfV1Options, PwfV1Bundle, PwfV2Bundle, CommonOptions, FeatureFlags, } from './types/WebviewerOptions';
10
10
  export type { GeometryFile, FileExtraction, BimFileUpload, FileExtractionItem, WebFormatExtractionItem, PropertiesExtractionItem, FileVersion, Attachment, PropertiesFile, } from './api/types/FileExtraction';
11
- export type { Viewpoint, Visibility, Model, ModelRevision, ModelRevisionViewpoint, } from './api/types/Model';
11
+ export type { Model } from './api/types/Model';
12
+ export type { ModelRevision, ModelRevisionViewpoint, } from './api/types/ModelRevision';
13
+ export type { Viewpoint, Visibility } from './api/types/Viewpoint';
12
14
  export type { Project } from './api/types/Project';
13
15
  export type { Vector2, Vector3, BoundingBox } from './types/Math';
14
16
  export type { CssColor, RGB, RGBA, HEX } from './components/Markup/SvgRenderer';
@@ -20,6 +22,13 @@ export type { ObjectFilter, FilterField } from './types/ObjectFilter';
20
22
  export { FILTER_FIELD } from './types/ObjectFilter';
21
23
  export type { NavigationMode } from './navigation/NavigationModes';
22
24
  export { NAV_MODE } from './navigation/NavigationModes';
23
- export { RenderMode, RENDER_MODE } from './utils/constants';
25
+ export { RENDER_MODE } from './utils/constants';
26
+ export type { RenderMode } from './utils/constants';
27
+ export { TOOL } from './components/Tool';
28
+ export type { Tool } from './components/Tool';
29
+ export { TOOL_BAR_TOOLS } from './components/ToolBarTools';
30
+ export type { ToolBarTools } from './components/ToolBarTools';
31
+ export { ACTION } from './utils/Enums';
32
+ export type { Action } from './utils/Enums';
24
33
  declare const version: string;
25
34
  export { version };
@@ -1,7 +1,8 @@
1
1
  import { Project } from '../api/types/Project';
2
2
  import { FileExtraction, GeometryFile } from '../api/types/FileExtraction';
3
- import { Model, ModelRevision } from '../api/types/Model';
4
- export type Tool = 0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15;
3
+ import { Model } from '../api/types/Model';
4
+ import { ModelRevision } from '../api/types/ModelRevision';
5
+ import type { Tool } from '../components/Tool';
5
6
  export type FeatureFlags = Partial<{
6
7
  enableObjectTreeSearch: boolean;
7
8
  }>;
@@ -1,5 +1,5 @@
1
1
  import { PropertiesFile, FileVersion, Attachment } from '../../api/types/FileExtraction';
2
- import { ModelRevision } from '../../api/types/Model';
2
+ import { ModelRevision } from '../../api/types/ModelRevision';
3
3
  import * as FileExtractions from '../../api/bim_file_extractions';
4
4
  import * as BimModelRevisions from '../../api/bim_model_revisions';
5
5
  import { Options, GeometryBundle } from '../../types/WebviewerOptions';
@@ -1,6 +1,6 @@
1
1
  import type { FileExtractionModePwfV2OverrideOptions, FileExtractionModePwfV1OverrideOptions, FileExtractionModeOptions, ModelRevisionModePwfV2Options, ModelRevisionModePwfV1Options } from '../../../types/WebviewerOptions';
2
2
  import { FileExtraction } from '../../../api/types/FileExtraction';
3
- import { ModelRevision, ModelRevisionViewpoint } from '../../../api/types/Model';
3
+ import { ModelRevision, ModelRevisionViewpoint } from '../../../api/types/ModelRevision';
4
4
  import { InternalViewpoint } from '../../../viewpoint/types';
5
5
  export declare const projectId = 4;
6
6
  export declare const companyId = 1;
@@ -1,4 +1,4 @@
1
- export const keys: Readonly<{
1
+ export declare const keys: Readonly<{
2
2
  NONE: -1;
3
3
  LEFT: 37;
4
4
  UP: 38;
@@ -34,21 +34,22 @@ export const keys: Readonly<{
34
34
  SA: 203;
35
35
  X: 88;
36
36
  }>;
37
- export const Action: Readonly<{
38
- NONE: -1;
39
- PAN: 1;
40
- KEYMOVE: 2;
41
- ROTATE: 3;
42
- FLY: 4;
43
- ORBIT: 5;
44
- STRAFE: 6;
45
- }>;
46
- export const UnhideObjectOrigin: Readonly<{
37
+ export declare const ACTION: {
38
+ readonly NONE: -1;
39
+ readonly PAN: 1;
40
+ readonly KEYMOVE: 2;
41
+ readonly ROTATE: 3;
42
+ readonly FLY: 4;
43
+ readonly ORBIT: 5;
44
+ readonly STRAFE: 6;
45
+ };
46
+ export type Action = (typeof ACTION)[keyof typeof ACTION];
47
+ export declare const UnhideObjectOrigin: Readonly<{
47
48
  COACHMARKHIDDEN: "coachmark_hidden";
48
49
  OBJECTTREE: "object_tree";
49
50
  OBJECTTREE_ALLOBJECTS: "object_tree_all_objects";
50
51
  }>;
51
- export const ToolOrigin: Readonly<{
52
+ export declare const ToolOrigin: Readonly<{
52
53
  KEYBOARD: "keyboard";
53
54
  TOOLBAR: "toolbar";
54
55
  API: "api";
@@ -1,11 +1,15 @@
1
1
  import { InternalViewpoint, RedlinesData, AutodeskRedlineCollection, CameraData, AutodeskCommonCamera } from './types';
2
- import { Viewpoint } from '../api/types/Model';
2
+ import { Viewpoint, Visibility } from '../api/types/Viewpoint';
3
+ import type { RenderMode } from '../utils/constants';
3
4
  export declare function calculateFieldOfViewFromVerticalExtent(verticalExtent: number, targetDistance: number): number;
5
+ export declare const NULL_VISIBILITY: Visibility;
4
6
  export declare class ViewpointFactory {
5
7
  static createViewpoint(viewpoint: Viewpoint): InternalViewpoint;
6
8
  private static getCameraData;
7
9
  private static getSectionsData;
8
10
  private static getRedlinesData;
11
+ static getVisibility(viewpoint: Viewpoint): Visibility;
12
+ static getRenderMode(viewpoint: Viewpoint): RenderMode;
9
13
  static convertFromAutodeskCommonCamera(autodeskCameraData: AutodeskCommonCamera): CameraData;
10
14
  static convertFromAutodeskRedlineCollection(autodeskMarkup: AutodeskRedlineCollection): RedlinesData;
11
15
  static getUnit(viewpoint: InternalViewpoint): string;
@@ -1,4 +1,6 @@
1
- import { BcfCameraOrthogonal, BcfCameraPerspective } from '../types/BcfCamera';
1
+ import type { Visibility } from '../api/types/Viewpoint';
2
+ import type { RenderMode } from '../utils/constants';
3
+ import type { BcfCameraOrthogonal, BcfCameraPerspective } from '../types/BcfCamera';
2
4
  export type CameraData = {
3
5
  perspective_camera?: BcfCameraPerspective;
4
6
  orthogonal_camera?: BcfCameraOrthogonal;
@@ -116,4 +118,6 @@ export type InternalViewpoint = {
116
118
  camera_data: CameraData;
117
119
  sections_data: Record<string, unknown> | Array<Record<string, unknown>> | null;
118
120
  redlines_data: RedlinesData | null;
121
+ visibility: Visibility;
122
+ render_mode: RenderMode;
119
123
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@procore/bim-webviewer-sdk",
3
- "version": "15.1.0",
3
+ "version": "15.2.0-rc.0",
4
4
  "description": "Procore BIM Webviewer SDK",
5
5
  "main": "dist/Procore.Bim.Webviewer.js",
6
6
  "types": "dist/Procore.Bim.Webviewer.d.ts",
@@ -1,4 +0,0 @@
1
- import { Tool } from '../types/WebviewerOptions';
2
- export declare const ToolEnum: {
3
- [key: string]: Tool;
4
- };