@roomle/web-sdk 2.85.0-alpha.1 → 2.85.0-bo-mvp.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/.releaserc.json +5 -0
- package/lib/{TextGeometry-def07ca8.js → TextGeometry-64e47e97.js} +2 -2
- package/lib/{TextGeometry-def07ca8.js.map → TextGeometry-64e47e97.js.map} +1 -1
- package/lib/{TextGeometry-028ef3cf.nomodule.js → TextGeometry-6c37ac59.nomodule.js} +2 -2
- package/lib/{TextGeometry-028ef3cf.nomodule.js.map → TextGeometry-6c37ac59.nomodule.js.map} +1 -1
- package/lib/{banana-for-scale-1ab56953.nomodule.js → banana-for-scale-3f718399.nomodule.js} +2 -2
- package/lib/{banana-for-scale-1ab56953.nomodule.js.map → banana-for-scale-3f718399.nomodule.js.map} +1 -1
- package/lib/{banana-for-scale-034cc5dc.js → banana-for-scale-f6321e3c.js} +2 -2
- package/lib/{banana-for-scale-034cc5dc.js.map → banana-for-scale-f6321e3c.js.map} +1 -1
- package/lib/{budgeteer-measure-e4c7fe1a.js → budgeteer-measure-a84ddf03.js} +2 -2
- package/lib/{budgeteer-measure-e4c7fe1a.js.map → budgeteer-measure-a84ddf03.js.map} +1 -1
- package/lib/budgeteer-measure.nomodule.js +1 -1
- package/lib/camera-behaviour-b62c2673.js +2 -0
- package/lib/{camera-behaviour-f1fc8341.js.map → camera-behaviour-b62c2673.js.map} +1 -1
- package/lib/camera-behaviour-e7f9d0fc.nomodule.js +2 -0
- package/lib/{camera-behaviour-c471cf80.nomodule.js.map → camera-behaviour-e7f9d0fc.nomodule.js.map} +1 -1
- package/lib/{component-dimensioning-85cc876e.js → component-dimensioning-68ef159c.js} +2 -2
- package/lib/component-dimensioning-68ef159c.js.map +1 -0
- package/lib/{component-dimensioning-68525959.nomodule.js → component-dimensioning-f2164275.nomodule.js} +2 -2
- package/lib/component-dimensioning-f2164275.nomodule.js.map +1 -0
- package/lib/{component-raycast-helper-13725a70.js → component-raycast-helper-3503275a.js} +2 -2
- package/lib/component-raycast-helper-3503275a.js.map +1 -0
- package/lib/{component-raycast-helper-210b2bd1.nomodule.js → component-raycast-helper-82a6ba14.nomodule.js} +2 -2
- package/lib/component-raycast-helper-82a6ba14.nomodule.js.map +1 -0
- package/lib/configurator-0ba8527f.js +2 -0
- package/lib/configurator-0ba8527f.js.map +1 -0
- package/lib/configurator-bdafffd3.nomodule.js +2 -0
- package/lib/configurator-bdafffd3.nomodule.js.map +1 -0
- package/lib/configurator-main-d0f80aa1.js +2 -0
- package/lib/configurator-main-d0f80aa1.js.map +1 -0
- package/lib/configurator-main.nomodule.js +1 -1
- package/lib/{continuous-drawing-helper-b476ae1f.nomodule.js → continuous-drawing-helper-2aa3d564.nomodule.js} +2 -2
- package/lib/continuous-drawing-helper-2aa3d564.nomodule.js.map +1 -0
- package/lib/{continuous-drawing-helper-53c52537.js → continuous-drawing-helper-410e6138.js} +2 -2
- package/lib/continuous-drawing-helper-410e6138.js.map +1 -0
- package/lib/definitions/common-core/src/configurator-kernel-access.d.ts +5 -2
- package/lib/definitions/common-core/src/utils/shims.d.ts +10 -0
- package/lib/definitions/configurator-core/src/export/production-manager-export.d.ts +35 -0
- package/lib/definitions/configurator-core/src/roomle-configurator.d.ts +10 -0
- package/lib/definitions/configurator-core/src/static-files/geometries.d.ts +1 -0
- package/lib/definitions/configurator-core/src/utils/export-helper.d.ts +38 -0
- package/lib/definitions/configurator-core/src/webgl/configurator-scene-manager.d.ts +4 -0
- package/lib/definitions/planner-core/src/external-object-api-callbacks.d.ts +119 -0
- package/lib/definitions/planner-core/src/external-object-api.d.ts +83 -0
- package/lib/definitions/planner-core/src/roomle-planner-external-object.d.ts +44 -0
- package/lib/definitions/planner-core/src/roomle-planner-ui-callback.d.ts +62 -0
- package/lib/definitions/planner-core/src/roomle-planner.d.ts +15 -2
- package/lib/definitions/planner-core/src/services/planner-kernel-access.d.ts +18 -4
- package/lib/definitions/planner-core/src/utils/map-to-ui-plan-objects.d.ts +1 -1
- package/lib/definitions/planner-core/src/view-model/plan-view-model.d.ts +1 -0
- package/lib/definitions/planner-core/src/webgl/planner-scene-manager.d.ts +2 -0
- package/lib/definitions/typings/kernel.d.ts +20 -4
- package/lib/definitions/typings/planner.d.ts +1 -1
- package/lib/{dimensioning-helper-6b964e3b.js → dimensioning-helper-7b967027.js} +2 -2
- package/lib/{dimensioning-helper-6b964e3b.js.map → dimensioning-helper-7b967027.js.map} +1 -1
- package/lib/{dimensioning-helper-8de4a0b8.nomodule.js → dimensioning-helper-a2b1a06e.nomodule.js} +2 -2
- package/lib/{dimensioning-helper-8de4a0b8.nomodule.js.map → dimensioning-helper-a2b1a06e.nomodule.js.map} +1 -1
- package/lib/glb-viewer-447286f6.nomodule.js +2 -0
- package/lib/glb-viewer-447286f6.nomodule.js.map +1 -0
- package/lib/glb-viewer-bac266f6.js +2 -0
- package/lib/glb-viewer-bac266f6.js.map +1 -0
- package/lib/{glb-viewer-camera-behaviour-57f593d4.nomodule.js → glb-viewer-camera-behaviour-89e58c94.nomodule.js} +2 -2
- package/lib/glb-viewer-camera-behaviour-89e58c94.nomodule.js.map +1 -0
- package/lib/{glb-viewer-camera-behaviour-65583e34.js → glb-viewer-camera-behaviour-9c8aa9e8.js} +2 -2
- package/lib/glb-viewer-camera-behaviour-9c8aa9e8.js.map +1 -0
- package/lib/glb-viewer-main-93b7b987.js +2 -0
- package/lib/glb-viewer-main-93b7b987.js.map +1 -0
- package/lib/glb-viewer-main.nomodule.js +1 -1
- package/lib/{default-light-setting-6bc84cb1.js → jszip.min-086ab68b.js} +2 -2
- package/lib/jszip.min-086ab68b.js.map +1 -0
- package/lib/{default-light-setting-94a0efa3.nomodule.js → jszip.min-d3d3c14a.nomodule.js} +2 -2
- package/lib/jszip.min-d3d3c14a.nomodule.js.map +1 -0
- package/lib/legacy/{TextGeometry-c00b7ecb.legacy.js → TextGeometry-50d12ddd.legacy.js} +2 -2
- package/lib/legacy/{TextGeometry-c00b7ecb.legacy.js.map → TextGeometry-50d12ddd.legacy.js.map} +1 -1
- package/lib/legacy/{banana-for-scale-0e914a45.legacy.js → banana-for-scale-a1cedf0b.legacy.js} +2 -2
- package/lib/legacy/{banana-for-scale-0e914a45.legacy.js.map → banana-for-scale-a1cedf0b.legacy.js.map} +1 -1
- package/lib/legacy/budgeteer-measure.legacy.js +1 -1
- package/lib/legacy/camera-behaviour-60b2a3b7.legacy.js +2 -0
- package/lib/legacy/{camera-behaviour-4128d879.legacy.js.map → camera-behaviour-60b2a3b7.legacy.js.map} +1 -1
- package/lib/legacy/{component-dimensioning-cf81879e.legacy.js → component-dimensioning-982f167d.legacy.js} +2 -2
- package/lib/legacy/component-dimensioning-982f167d.legacy.js.map +1 -0
- package/lib/legacy/{component-raycast-helper-009d1f45.legacy.js → component-raycast-helper-bcb78fc3.legacy.js} +2 -2
- package/lib/legacy/component-raycast-helper-bcb78fc3.legacy.js.map +1 -0
- package/lib/legacy/configurator-deb44981.legacy.js +2 -0
- package/lib/legacy/configurator-deb44981.legacy.js.map +1 -0
- package/lib/legacy/configurator-main.legacy.js +1 -1
- package/lib/legacy/{continuous-drawing-helper-17338404.legacy.js → continuous-drawing-helper-658bf83c.legacy.js} +2 -2
- package/lib/legacy/continuous-drawing-helper-658bf83c.legacy.js.map +1 -0
- package/lib/legacy/{dimensioning-helper-42a663eb.legacy.js → dimensioning-helper-8a4098f2.legacy.js} +2 -2
- package/lib/legacy/{dimensioning-helper-42a663eb.legacy.js.map → dimensioning-helper-8a4098f2.legacy.js.map} +1 -1
- package/lib/legacy/glb-viewer-24f02f48.legacy.js +2 -0
- package/lib/legacy/glb-viewer-24f02f48.legacy.js.map +1 -0
- package/lib/legacy/{glb-viewer-camera-behaviour-f9d7a62e.legacy.js → glb-viewer-camera-behaviour-67db97b4.legacy.js} +2 -2
- package/lib/legacy/glb-viewer-camera-behaviour-67db97b4.legacy.js.map +1 -0
- package/lib/legacy/glb-viewer-main.legacy.js +1 -1
- package/lib/legacy/{default-light-setting-16629396.legacy.js → jszip.min-b56dddd5.legacy.js} +2 -2
- package/lib/legacy/jszip.min-b56dddd5.legacy.js.map +1 -0
- package/lib/legacy/{main-thread-to-worker-a28094cc.legacy.js → main-thread-to-worker-f02de9c2.legacy.js} +3 -3
- package/lib/legacy/{main-thread-to-worker-a28094cc.legacy.js.map → main-thread-to-worker-f02de9c2.legacy.js.map} +1 -1
- package/lib/legacy/{material-viewer-5d15bc6c.legacy.js → material-viewer-59ae1919.legacy.js} +2 -2
- package/lib/legacy/material-viewer-59ae1919.legacy.js.map +1 -0
- package/lib/legacy/material-viewer-main.legacy.js +1 -1
- package/lib/legacy/planner-e62be31e.legacy.js +2 -0
- package/lib/legacy/{planner-26085930.legacy.js.map → planner-e62be31e.legacy.js.map} +1 -1
- package/lib/legacy/planner-main.legacy.js +1 -1
- package/lib/legacy/{query-params-helper-81aac523.legacy.js → query-params-helper-0f7e3d70.legacy.js} +2 -2
- package/lib/legacy/query-params-helper-0f7e3d70.legacy.js.map +1 -0
- package/lib/legacy/roomle-configurator-92b03dab.legacy.js +2 -0
- package/lib/legacy/roomle-configurator-92b03dab.legacy.js.map +1 -0
- package/lib/legacy/roomle-dependency-injection-b98cdb69.legacy.js +9 -0
- package/lib/legacy/roomle-dependency-injection-b98cdb69.legacy.js.map +1 -0
- package/lib/legacy/roomle-sdk.legacy.js +1 -1
- package/lib/legacy/{script-loader-161d337b.legacy.js → script-loader-9e64fd9d.legacy.js} +2 -2
- package/lib/legacy/script-loader-9e64fd9d.legacy.js.map +1 -0
- package/lib/{static/ConfiguratorKernel-b905729404ced494.wasm → legacy/static/ConfiguratorKernel-c36864a2ba89c903.wasm} +0 -0
- package/lib/legacy/static/RoomleCore-f1650d50c2ddec11.wasm +0 -0
- package/lib/{static/RoomleToolsCore-256566b6e8ee3a5f.wasm → legacy/static/RoomleToolsCore-72a3331cc11a3792.wasm} +0 -0
- package/lib/legacy/static/monkey-0ab775bb33780513.obj +7966 -0
- package/lib/legacy/{stats-helper-70f3a803.legacy.js → stats-helper-6e74e274.legacy.js} +2 -2
- package/lib/legacy/stats-helper-6e74e274.legacy.js.map +1 -0
- package/lib/legacy/{tools-core-fb6f2cc3.legacy.js → tools-core-a8b3b84e.legacy.js} +2 -2
- package/lib/legacy/tools-core-a8b3b84e.legacy.js.map +1 -0
- package/lib/{main-thread-to-worker-1a58abb6.nomodule.js → main-thread-to-worker-a33146dd.nomodule.js} +2 -2
- package/lib/{main-thread-to-worker-1a58abb6.nomodule.js.map → main-thread-to-worker-a33146dd.nomodule.js.map} +1 -1
- package/lib/{main-thread-to-worker-554053aa.js → main-thread-to-worker-af604b88.js} +2 -2
- package/lib/{main-thread-to-worker-554053aa.js.map → main-thread-to-worker-af604b88.js.map} +1 -1
- package/lib/{material-viewer-4ee66cc0.js → material-viewer-7f5e40c0.js} +2 -2
- package/lib/material-viewer-7f5e40c0.js.map +1 -0
- package/lib/{material-viewer-4e7f4777.nomodule.js → material-viewer-c2df56dd.nomodule.js} +2 -2
- package/lib/material-viewer-c2df56dd.nomodule.js.map +1 -0
- package/lib/material-viewer-main-9d3ef5a3.js +2 -0
- package/lib/material-viewer-main-9d3ef5a3.js.map +1 -0
- package/lib/material-viewer-main.nomodule.js +1 -1
- package/lib/planner-83e4b63b.nomodule.js +2 -0
- package/lib/{planner-56a2218e.nomodule.js.map → planner-83e4b63b.nomodule.js.map} +1 -1
- package/lib/planner-dfc8606b.js +2 -0
- package/lib/{planner-39fa9725.js.map → planner-dfc8606b.js.map} +1 -1
- package/lib/planner-main-f7020b51.js +2 -0
- package/lib/planner-main-f7020b51.js.map +1 -0
- package/lib/planner-main.nomodule.js +1 -1
- package/lib/{query-params-helper-a5a14aba.js → query-params-helper-15c8e313.js} +2 -2
- package/lib/query-params-helper-15c8e313.js.map +1 -0
- package/lib/{query-params-helper-a2901800.nomodule.js → query-params-helper-ff314078.nomodule.js} +2 -2
- package/lib/query-params-helper-ff314078.nomodule.js.map +1 -0
- package/lib/roomle-configurator-6ee41f13.nomodule.js +2 -0
- package/lib/roomle-configurator-6ee41f13.nomodule.js.map +1 -0
- package/lib/roomle-configurator-a2fabb1a.js +2 -0
- package/lib/roomle-configurator-a2fabb1a.js.map +1 -0
- package/lib/{roomle-dependency-injection-8c2de058.nomodule.js → roomle-dependency-injection-11d4372b.nomodule.js} +3 -3
- package/lib/roomle-dependency-injection-11d4372b.nomodule.js.map +1 -0
- package/lib/{roomle-dependency-injection-410ef785.js → roomle-dependency-injection-b0f42112.js} +3 -3
- package/lib/roomle-dependency-injection-b0f42112.js.map +1 -0
- package/lib/{roomle-sdk-a2fef129.js → roomle-sdk-62df1d13.js} +2 -2
- package/lib/roomle-sdk-62df1d13.js.map +1 -0
- package/lib/roomle-sdk.nomodule.js +1 -1
- package/lib/{script-loader-1ab763ef.js → script-loader-9396ec24.js} +2 -2
- package/lib/script-loader-9396ec24.js.map +1 -0
- package/lib/{script-loader-2e2919cf.nomodule.js → script-loader-eb097908.nomodule.js} +2 -2
- package/lib/script-loader-eb097908.nomodule.js.map +1 -0
- package/lib/{legacy/static/ConfiguratorKernel-b905729404ced494.wasm → static/ConfiguratorKernel-c36864a2ba89c903.wasm} +0 -0
- package/lib/static/RoomleCore-f1650d50c2ddec11.wasm +0 -0
- package/lib/{legacy/static/RoomleToolsCore-256566b6e8ee3a5f.wasm → static/RoomleToolsCore-72a3331cc11a3792.wasm} +0 -0
- package/lib/static/monkey-0ab775bb33780513.obj +7966 -0
- package/lib/{stats-helper-466a0083.js → stats-helper-69d4af91.js} +2 -2
- package/lib/stats-helper-69d4af91.js.map +1 -0
- package/lib/{stats-helper-81acfbd7.nomodule.js → stats-helper-92615332.nomodule.js} +2 -2
- package/lib/stats-helper-92615332.nomodule.js.map +1 -0
- package/lib/{tools-core-5452b585.nomodule.js → tools-core-897210a8.nomodule.js} +2 -2
- package/lib/tools-core-897210a8.nomodule.js.map +1 -0
- package/lib/{tools-core-bebf51be.js → tools-core-dd988536.js} +2 -2
- package/lib/tools-core-dd988536.js.map +1 -0
- package/package.json +2 -2
- package/lib/camera-behaviour-c471cf80.nomodule.js +0 -2
- package/lib/camera-behaviour-f1fc8341.js +0 -2
- package/lib/component-dimensioning-68525959.nomodule.js.map +0 -1
- package/lib/component-dimensioning-85cc876e.js.map +0 -1
- package/lib/component-raycast-helper-13725a70.js.map +0 -1
- package/lib/component-raycast-helper-210b2bd1.nomodule.js.map +0 -1
- package/lib/configurator-2fa43928.js +0 -2
- package/lib/configurator-2fa43928.js.map +0 -1
- package/lib/configurator-e41974af.nomodule.js +0 -2
- package/lib/configurator-e41974af.nomodule.js.map +0 -1
- package/lib/configurator-main-fa603285.js +0 -2
- package/lib/configurator-main-fa603285.js.map +0 -1
- package/lib/continuous-drawing-helper-53c52537.js.map +0 -1
- package/lib/continuous-drawing-helper-b476ae1f.nomodule.js.map +0 -1
- package/lib/default-light-setting-6bc84cb1.js.map +0 -1
- package/lib/default-light-setting-94a0efa3.nomodule.js.map +0 -1
- package/lib/glb-viewer-3586996a.js +0 -2
- package/lib/glb-viewer-3586996a.js.map +0 -1
- package/lib/glb-viewer-6ad3eb53.nomodule.js +0 -2
- package/lib/glb-viewer-6ad3eb53.nomodule.js.map +0 -1
- package/lib/glb-viewer-camera-behaviour-57f593d4.nomodule.js.map +0 -1
- package/lib/glb-viewer-camera-behaviour-65583e34.js.map +0 -1
- package/lib/glb-viewer-main-61add308.js +0 -2
- package/lib/glb-viewer-main-61add308.js.map +0 -1
- package/lib/legacy/camera-behaviour-4128d879.legacy.js +0 -2
- package/lib/legacy/component-dimensioning-cf81879e.legacy.js.map +0 -1
- package/lib/legacy/component-raycast-helper-009d1f45.legacy.js.map +0 -1
- package/lib/legacy/configurator-0be503c2.legacy.js +0 -2
- package/lib/legacy/configurator-0be503c2.legacy.js.map +0 -1
- package/lib/legacy/continuous-drawing-helper-17338404.legacy.js.map +0 -1
- package/lib/legacy/default-light-setting-16629396.legacy.js.map +0 -1
- package/lib/legacy/glb-viewer-6bda8901.legacy.js +0 -2
- package/lib/legacy/glb-viewer-6bda8901.legacy.js.map +0 -1
- package/lib/legacy/glb-viewer-camera-behaviour-f9d7a62e.legacy.js.map +0 -1
- package/lib/legacy/material-viewer-5d15bc6c.legacy.js.map +0 -1
- package/lib/legacy/planner-26085930.legacy.js +0 -2
- package/lib/legacy/query-params-helper-81aac523.legacy.js.map +0 -1
- package/lib/legacy/roomle-configurator-801dfd28.legacy.js +0 -2
- package/lib/legacy/roomle-configurator-801dfd28.legacy.js.map +0 -1
- package/lib/legacy/roomle-dependency-injection-b6633659.legacy.js +0 -9
- package/lib/legacy/roomle-dependency-injection-b6633659.legacy.js.map +0 -1
- package/lib/legacy/script-loader-161d337b.legacy.js.map +0 -1
- package/lib/legacy/static/RoomleCore-3e498b4dbab73c95.wasm +0 -0
- package/lib/legacy/stats-helper-70f3a803.legacy.js.map +0 -1
- package/lib/legacy/tools-core-fb6f2cc3.legacy.js.map +0 -1
- package/lib/material-viewer-4e7f4777.nomodule.js.map +0 -1
- package/lib/material-viewer-4ee66cc0.js.map +0 -1
- package/lib/material-viewer-main-63b64a51.js +0 -2
- package/lib/material-viewer-main-63b64a51.js.map +0 -1
- package/lib/planner-39fa9725.js +0 -2
- package/lib/planner-56a2218e.nomodule.js +0 -2
- package/lib/planner-main-8123556f.js +0 -2
- package/lib/planner-main-8123556f.js.map +0 -1
- package/lib/query-params-helper-a2901800.nomodule.js.map +0 -1
- package/lib/query-params-helper-a5a14aba.js.map +0 -1
- package/lib/roomle-configurator-21764f93.nomodule.js +0 -2
- package/lib/roomle-configurator-21764f93.nomodule.js.map +0 -1
- package/lib/roomle-configurator-7d84bc6f.js +0 -2
- package/lib/roomle-configurator-7d84bc6f.js.map +0 -1
- package/lib/roomle-dependency-injection-410ef785.js.map +0 -1
- package/lib/roomle-dependency-injection-8c2de058.nomodule.js.map +0 -1
- package/lib/roomle-sdk-a2fef129.js.map +0 -1
- package/lib/script-loader-1ab763ef.js.map +0 -1
- package/lib/script-loader-2e2919cf.nomodule.js.map +0 -1
- package/lib/static/RoomleCore-3e498b4dbab73c95.wasm +0 -0
- package/lib/stats-helper-466a0083.js.map +0 -1
- package/lib/stats-helper-81acfbd7.nomodule.js.map +0 -1
- package/lib/tools-core-5452b585.nomodule.js.map +0 -1
- package/lib/tools-core-bebf51be.js.map +0 -1
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
import type { ExternalObjectApiConfiguration } from './external-object-api';
|
|
2
|
+
export interface TcAPI {
|
|
3
|
+
/**
|
|
4
|
+
* Sets properties that effect the representation of the objects such as the material mapping
|
|
5
|
+
* and completely overwrites the default settings.
|
|
6
|
+
* @param propertiesJson The properties JSON as string or object.
|
|
7
|
+
*/
|
|
8
|
+
loadTCProperties(propertiesJson: string | ExternalObjectApiConfiguration): void;
|
|
9
|
+
/**
|
|
10
|
+
* Loads the master data json and defines which attributes are displayed in the UI
|
|
11
|
+
* of the PoS system and how they are displayed.
|
|
12
|
+
* @param masterDataJson The master data JSON as string or object.
|
|
13
|
+
*/
|
|
14
|
+
loadTCMasterData(masterDataJson: string | object): void;
|
|
15
|
+
/**
|
|
16
|
+
* Loads all groups of root modules defined in the article-data-json and adds them to the plan.
|
|
17
|
+
* @param articleJson The article data JSON as string or object.
|
|
18
|
+
*/
|
|
19
|
+
loadTCArticles(articleJson: string): Promise<void>;
|
|
20
|
+
/**
|
|
21
|
+
* Removes the specified group of root modules completely from the plan.
|
|
22
|
+
* @param groupId The unique ID of the group of root modules.
|
|
23
|
+
*/
|
|
24
|
+
removeTCArticle(groupId: string): Promise<void>;
|
|
25
|
+
/**
|
|
26
|
+
* Always switches to planning mode and selects an root module group.
|
|
27
|
+
* In planning mode, only a root module or a group of root modules can be selected, but not a sub-module.
|
|
28
|
+
* @param groupId The unique ID of the group of root modules.
|
|
29
|
+
*/
|
|
30
|
+
selectTCArticle(groupId: string): Promise<void>;
|
|
31
|
+
/**
|
|
32
|
+
* Always switches to configuration mode and selects a root module or sub-module.
|
|
33
|
+
* @param groupId The unique ID of the group of root modules.
|
|
34
|
+
* @param moduleId The ID of the root module or sub-module.
|
|
35
|
+
*/
|
|
36
|
+
selectTCModule(groupId: string, moduleId: string): Promise<void>;
|
|
37
|
+
/**
|
|
38
|
+
* Opens or closes the geometry (e.g. drawers and doors) of all modules in a group.
|
|
39
|
+
* @param groupId The unique ID of the group of root modules.
|
|
40
|
+
* @param open If true, the modules are opened, if false, they are closed.
|
|
41
|
+
* @param animate If true the opening or closing is animated.
|
|
42
|
+
*/
|
|
43
|
+
openCloseTCArticle(groupId: string, open: boolean, animate: boolean): Promise<void>;
|
|
44
|
+
}
|
|
@@ -150,6 +150,68 @@ export default class RoomlePlannerUiCallback extends UiCallback {
|
|
|
150
150
|
* @param floorAreasData An array of objects, each representing the area and related data for each room within the floor plan.
|
|
151
151
|
*/
|
|
152
152
|
onFloorPlanAreasUpdated: (floorAreasData: FloorAreaDataTransferable[]) => void;
|
|
153
|
+
/**
|
|
154
|
+
* Callback invoked when the selection of a component has been canceled.
|
|
155
|
+
*/
|
|
156
|
+
onComponentSelectionCancel: () => void;
|
|
157
|
+
/**
|
|
158
|
+
* Callback invoked when a plan snapshot is saved.
|
|
159
|
+
* @param planId The ID of the plan snapshot.
|
|
160
|
+
*/
|
|
161
|
+
onPlanSnapshotCreated: (planId: string) => void;
|
|
162
|
+
/**
|
|
163
|
+
* Callback invoked when an object is started to be configured.
|
|
164
|
+
*/
|
|
165
|
+
onStartConfiguring: () => Promise<void>;
|
|
166
|
+
/**
|
|
167
|
+
* Callback invoked when configuration is finished.
|
|
168
|
+
*/
|
|
169
|
+
onBackToPlanner: () => Promise<void>;
|
|
170
|
+
/**
|
|
171
|
+
* Callback invoked when the selection of an external component has changed.
|
|
172
|
+
* @param groupId The ID of the plan object to which the external component is attached.
|
|
173
|
+
* @param moduleId The ID of the selected external component.
|
|
174
|
+
*/
|
|
175
|
+
onExternalComponentSelectionChanged: (groupId: string, moduleId: string | null) => void;
|
|
176
|
+
/**
|
|
177
|
+
* Callback invoked when the attribute value of an external component has changed.
|
|
178
|
+
* @param groupId The ID of the plan object to which the external component is attached.
|
|
179
|
+
* @param moduleId The module ID of the selected external component.
|
|
180
|
+
* @param attrId The id of the changed attribute.
|
|
181
|
+
* @param value The new value of the changed attribute.
|
|
182
|
+
*/
|
|
183
|
+
onExternalComponentParameterChanged: (groupId: string, moduleId: string, attrId: string, value: string) => void;
|
|
184
|
+
/**
|
|
185
|
+
* Callback invoked when an external object is created.
|
|
186
|
+
* @param groupId The ID of the new external object.
|
|
187
|
+
* @param configuration The serialized article data Json.
|
|
188
|
+
*/
|
|
189
|
+
onExternalPlanObjectCreated: (groupId: string, configuration: string) => void;
|
|
190
|
+
/**
|
|
191
|
+
* Callback invoked when an external object has been changed (undo/redo).
|
|
192
|
+
* @param planObjectId The ID of the plan object to which the external component is attached.
|
|
193
|
+
* @param groupId The ID of the new external object.
|
|
194
|
+
* @param configuration The serialized article data Json.
|
|
195
|
+
*/
|
|
196
|
+
onExternalPlanObjectChanged: (groupId: string, configuration: string) => void;
|
|
197
|
+
/**
|
|
198
|
+
* Callback invoked when an external object is deleted.
|
|
199
|
+
* @param groupId The ID of the external object to be removed.
|
|
200
|
+
*/
|
|
201
|
+
onExternalPlanObjectRemoved: (articleId: string) => void;
|
|
202
|
+
/**
|
|
203
|
+
* Callback invoked when a root module or sub-module of an external object is deleted.
|
|
204
|
+
* @param groupId The ID of the external object that is the owner of the module.
|
|
205
|
+
* @param moduleId The ID of the module to be removed.
|
|
206
|
+
*/
|
|
207
|
+
onExternalPlanComponentRemoved: (groupId: string, moduleId: string) => void;
|
|
208
|
+
/**
|
|
209
|
+
* Callback invoked when a module is added to an external object.
|
|
210
|
+
* @param groupId The ID of the external object to which the module is added.
|
|
211
|
+
* @param parentModuleId The ID of th module to which the module is added. If the new module is a root module, this argument is null.
|
|
212
|
+
* @param moduleName The name of the module to be added. This must be one of the "allowedChildModules" of the parent module.
|
|
213
|
+
*/
|
|
214
|
+
onExternalPlanComponentAdded: (groupId: string, parentModuleId: string | null, moduleName: string) => void;
|
|
153
215
|
/**
|
|
154
216
|
* This callback is invoked when the context of the planner changes
|
|
155
217
|
* For example when it switches from planner to configurator, or from planner to viewer
|
|
@@ -22,6 +22,9 @@ import type WallPlanElementViewModel from './view-model/wall-plan-element-view-m
|
|
|
22
22
|
import type ConfiguratorContext from '../../common-core/src/webgl/configurator-context';
|
|
23
23
|
import type { PlanObject } from '../../typings/planner';
|
|
24
24
|
import type IdbManager from '../../common-core/src/services/idb-manager';
|
|
25
|
+
import type { TcAPI } from './roomle-planner-external-object';
|
|
26
|
+
import type { ExternalObjectApiConfiguration } from './external-object-api';
|
|
27
|
+
export type ID_TYPE = 'rml_id' | 'tc_id' | 'rml_serialized' | 'tc_serialized';
|
|
25
28
|
export interface RoomlePlannerCallback {
|
|
26
29
|
switchToConfigurator: () => Promise<Configurator>;
|
|
27
30
|
switchToViewer: () => Promise<GlbViewer>;
|
|
@@ -57,7 +60,7 @@ export interface BatchPaintMaterial {
|
|
|
57
60
|
rgbValue?: number;
|
|
58
61
|
catalogItemId?: RapiId;
|
|
59
62
|
}
|
|
60
|
-
export default class RoomlePlanner implements KernelAccessCallbackI, RoomlePlannerCallback, GlobalAPI, Context, KernelUtilityForUi, ExternalEmbeddable<RoomlePlannerUiCallback>, RubensAPI {
|
|
63
|
+
export default class RoomlePlanner implements KernelAccessCallbackI, RoomlePlannerCallback, GlobalAPI, Context, KernelUtilityForUi, ExternalEmbeddable<RoomlePlannerUiCallback>, RubensAPI, TcAPI {
|
|
61
64
|
_creator_: string;
|
|
62
65
|
private _configuratorContext;
|
|
63
66
|
private _domHelper;
|
|
@@ -222,7 +225,7 @@ export default class RoomlePlanner implements KernelAccessCallbackI, RoomlePlann
|
|
|
222
225
|
* Disable the selection of multiple elements.
|
|
223
226
|
*/
|
|
224
227
|
disableMultiselect(): void;
|
|
225
|
-
dragInObject(
|
|
228
|
+
dragInObject(idOrSerializedConfigString: string, dragEvent: DragEvent, type?: ID_TYPE): Promise<RuntimeId>;
|
|
226
229
|
/**
|
|
227
230
|
* enable snapping of object to object and object to wall
|
|
228
231
|
*/
|
|
@@ -338,6 +341,16 @@ export default class RoomlePlanner implements KernelAccessCallbackI, RoomlePlann
|
|
|
338
341
|
*/
|
|
339
342
|
preparePerspectiveImageOf(runtimeId: RuntimeId, options?: PrepareImageOptions): Promise<import("../../common-core/src/common-interfaces").Base64Image>;
|
|
340
343
|
generateTCExport(planObjectIds?: string[]): Promise<any>;
|
|
344
|
+
loadTCProperties(propertiesJson: string | ExternalObjectApiConfiguration): void;
|
|
345
|
+
loadTCMasterData(masterDataJson: string | object): void;
|
|
346
|
+
loadTCArticles(articleJson: string): Promise<void>;
|
|
347
|
+
private _selectKernelComponent;
|
|
348
|
+
removeTCArticle(groupId: string): Promise<void>;
|
|
349
|
+
selectTCModule(groupId: string, moduleId: string): Promise<void>;
|
|
350
|
+
_selectTCArticle(groupId: string, switchToPlanner: boolean): Promise<void>;
|
|
351
|
+
_selectTCModule(groupId: string, moduleId: string, selectPlanObject: boolean, switchToConfigurator: boolean): Promise<void>;
|
|
352
|
+
selectTCArticle(groupId: string): Promise<void>;
|
|
353
|
+
openCloseTCArticle(groupId: string, open: boolean, animate: boolean): Promise<void>;
|
|
341
354
|
enableMeasurementLineDrawing(): void;
|
|
342
355
|
disableMeasurementLineDrawing(): void;
|
|
343
356
|
setObjectToWallMeasurementLength(planElementId: number, measurementId: number, length: number): void;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import type { KernelEnum, RuntimeId } from '../../../typings/kernel';
|
|
1
|
+
import type { KernelComponent, KernelEnum, RuntimeId, PlanObject as ConfiguratorPlanObject } from '../../../typings/kernel';
|
|
2
2
|
import type PlanObjectViewModel from '../../../common-core/src/view-model/plan-object-view-model';
|
|
3
3
|
import type { KernelObject, Plan, PlanElement, PlanInteractionHandler, PlanModelViewHelper, PlanObject } from '../../../typings/planner';
|
|
4
|
-
import type { RapiConfiguration, RapiItem } from '../../../typings/rapi-types';
|
|
4
|
+
import type { RapiConfiguration, RapiItem, RapiPlanSnapshotPostData } from '../../../typings/rapi-types';
|
|
5
5
|
import type RoomlePlannerUiCallback from '../roomle-planner-ui-callback';
|
|
6
6
|
import type PlanElementViewModel from '../../../common-core/src/view-model/plan-element-view-model';
|
|
7
7
|
import type { Position3 } from '../../../common-core/src/common-interfaces';
|
|
@@ -57,14 +57,15 @@ export default class PlannerKernelAccess extends ConfiguratorKernelAccess {
|
|
|
57
57
|
planElement3dMeshChanged(plan: Plan, element: PlanElement): void;
|
|
58
58
|
private _onStaticItemAdded;
|
|
59
59
|
private _onConfigurableItemAdded;
|
|
60
|
+
private _onConfigurableItemRemoved;
|
|
60
61
|
private _onConfigurableConstructionItemAdded;
|
|
61
62
|
planElementAdded(plan: Plan, element: PlanElement): Promise<void>;
|
|
62
63
|
planElementChanged(plan: Plan, element: KernelObject): void;
|
|
63
64
|
planHistoryStateChanged(): void;
|
|
64
65
|
planObjectConfigurationCreated(_plan: Plan, _element: PlanObject): void;
|
|
66
|
+
externalObjectConfigurationChanged(plan: Plan, planObject: PlanObject, configuration: string): void;
|
|
67
|
+
externalObjectConfigurationDeleted(plan: Plan, planObject: PlanObject, uniqueId: string): void;
|
|
65
68
|
planObjectConfigurationLoaded(plan: Plan, element: PlanElement, success: boolean): void;
|
|
66
|
-
externalObjectConfigurationChanged(_plan: Plan, _planObject: PlanObject, _configuration: string): void;
|
|
67
|
-
externalObjectConfigurationDeleted(_plan: Plan, _planObject: PlanObject, _uniqueId: string): void;
|
|
68
69
|
requestCatalogItem(_catalogItemId: string): void;
|
|
69
70
|
startedDrawing(): void;
|
|
70
71
|
stoppedDrawing(): void;
|
|
@@ -79,4 +80,17 @@ export default class PlannerKernelAccess extends ConfiguratorKernelAccess {
|
|
|
79
80
|
coupleReferences(jsObject: any, coreReference: KernelObject): void;
|
|
80
81
|
private _decoupleReferences;
|
|
81
82
|
isConstructionPlanElement(planElement: PlanElement): boolean;
|
|
83
|
+
planObjectSelectionChanged(planObjectId: number): void;
|
|
84
|
+
protected _externalPlanObjectCreated(planObject: PlanObject): void;
|
|
85
|
+
protected _externalPlanObjectRemoved(planObject: PlanObject): void;
|
|
86
|
+
protected _componentSelectionChanged(planObject: ConfiguratorPlanObject, component: KernelComponent, planComponentSelection: boolean): void;
|
|
87
|
+
protected _externalObjectParameterChanged(objectOrComponentId: number, parameterKey: string, value: string): void;
|
|
88
|
+
protected _externalObjectConfigurationChanged(objectId: number, configuration: string): void;
|
|
89
|
+
protected _externalObjectConfigurationDeleted(uniqueId: string): void;
|
|
90
|
+
planSnapshotCreated(planSnapshot: RapiPlanSnapshotPostData): void;
|
|
91
|
+
requestDeleteComponents(componentIds: number[]): void;
|
|
92
|
+
requestDeleteComponent(componentId: number): void;
|
|
93
|
+
requestDeletePlanComponent(componentId: number): void;
|
|
94
|
+
private _externalPlanComponentDeleted;
|
|
95
|
+
dockExternalObjectComponent(parentId: number, parentDockId: number, childId: number, childDockId: number): void;
|
|
82
96
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type
|
|
1
|
+
import { type UiPlanObject } from '../../../typings/kernel';
|
|
2
2
|
import type PlannerKernelAccess from '../services/planner-kernel-access';
|
|
3
3
|
import type RapiAccess from '../../../common-core/src/rapi-access';
|
|
4
4
|
export declare const mapToUiPlanObjects: (planObjects: any, plannerKernelAccess: PlannerKernelAccess, rapiAccess: RapiAccess) => Promise<UiPlanObject[]>;
|
|
@@ -54,6 +54,7 @@ export default class PlanViewModel extends ConfiguratorViewModel implements Plan
|
|
|
54
54
|
addPlanElementViewModel(planElementViewModel: PlanElementViewModel): void;
|
|
55
55
|
private _handleConfiguratorPlanObjectViewModel;
|
|
56
56
|
private _linkPlanObjectViewModelAndComponent;
|
|
57
|
+
private _detachPlanObjectViewModelFromComponent;
|
|
57
58
|
private _handleConfiguratorConstructionPlanObjectViewModel;
|
|
58
59
|
private _handleConstructionPlanObjectViewModel;
|
|
59
60
|
private _handleStaticPlanObjectViewModel;
|
|
@@ -53,6 +53,7 @@ export default class PlannerSceneManager extends ConfiguratorSceneManager implem
|
|
|
53
53
|
private _paperBackground;
|
|
54
54
|
private _debugSpheres;
|
|
55
55
|
constructor(creator: string, offset: CanvasOffset, plannerCallback: RoomlePlannerCallback, mode: Enumify<typeof CAMERA_TYPE>);
|
|
56
|
+
get configuratorContext(): import("../../../common-core/src/webgl/configurator-context").default;
|
|
56
57
|
planCleared(): void;
|
|
57
58
|
planHistoryStateChanged(): void;
|
|
58
59
|
protected _getViewModel(): PlanViewModel;
|
|
@@ -193,5 +194,6 @@ export default class PlannerSceneManager extends ConfiguratorSceneManager implem
|
|
|
193
194
|
setMeasurementLineLength(measurementId: number, length: number, wallDirection: string): void;
|
|
194
195
|
protected setEventHandlerObject(object: Object3D): void;
|
|
195
196
|
protected _readyForRender(): void;
|
|
197
|
+
protected notifyPlannerOnComponentSelectionCancel(): void;
|
|
196
198
|
}
|
|
197
199
|
export {};
|
|
@@ -385,14 +385,30 @@ export interface KernelVariant {
|
|
|
385
385
|
parameterValues: KernelParameterValue[];
|
|
386
386
|
}
|
|
387
387
|
export interface KernelExternalObjectDocking {
|
|
388
|
-
|
|
388
|
+
groupId: string;
|
|
389
389
|
parentModuleId: string;
|
|
390
390
|
moduleName: string;
|
|
391
391
|
}
|
|
392
392
|
export declare const enum ExportType {
|
|
393
393
|
TC = 0,
|
|
394
394
|
IMOSiX = 1,
|
|
395
|
-
|
|
395
|
+
HOMAGiX = 2,
|
|
396
|
+
BlueOceanPoC = 3
|
|
397
|
+
}
|
|
398
|
+
export interface HomagIxArticleData {
|
|
399
|
+
name: string;
|
|
400
|
+
count: number;
|
|
401
|
+
position: {
|
|
402
|
+
x: number;
|
|
403
|
+
y: number;
|
|
404
|
+
z: number;
|
|
405
|
+
};
|
|
406
|
+
rotation: {
|
|
407
|
+
x: number;
|
|
408
|
+
y: number;
|
|
409
|
+
z: number;
|
|
410
|
+
};
|
|
411
|
+
attributes: string;
|
|
396
412
|
}
|
|
397
413
|
export interface ConfigurationExporter {
|
|
398
414
|
new (): ConfigurationExporter;
|
|
@@ -404,6 +420,8 @@ export interface ConfiguratorKernelClass {
|
|
|
404
420
|
setUpdateCallbacksOnlyIfGeometryIsReady(onlyUpdateIfReady: boolean): void;
|
|
405
421
|
useHDGeometry(requestUseHDGeometry: boolean): void;
|
|
406
422
|
useEnvironmentGeometry(requestEnvironmentGeometry: boolean): void;
|
|
423
|
+
setEnvironmentVariable(key: string, value: any): void;
|
|
424
|
+
setLevel(restrictionLevel: number): void;
|
|
407
425
|
setDockInsertPreviewBoxParameters(thickness: number, protruding: number, intruding: number, bevelSize: number): void;
|
|
408
426
|
clearScene(): void;
|
|
409
427
|
clearAll(): void;
|
|
@@ -427,8 +445,6 @@ export interface ConfiguratorKernelClass {
|
|
|
427
445
|
getPlanComponentAnimations(planComponentId: number): KernelAnimation[];
|
|
428
446
|
setComponentParameter(componentId: number, parameterKey: string, value: string): void;
|
|
429
447
|
setPlanComponentParameters(componentIds: any, parameterKey: string, value: string): void;
|
|
430
|
-
setEnvironmentVariable(key: string, value: any): void;
|
|
431
|
-
setLevel(restrictionLevel: number): void;
|
|
432
448
|
getPlanObjectParameters(planObjectId: number): KernelParameter[];
|
|
433
449
|
getPlanObjectAnimations(planObjectId: number): KernelAnimation[];
|
|
434
450
|
setPlanObjectParameter(planObjectId: number, parameterKey: string, value: string): void;
|
|
@@ -247,7 +247,7 @@ export interface PlanModelViewHelper {
|
|
|
247
247
|
getPlanObject(plan: Plan, aRuntimeId: number): KernelPlanObject;
|
|
248
248
|
getRootPlanObjectId(plan: Plan, aRuntimeId: number): number;
|
|
249
249
|
getObjectComponent(plan: Plan, aComponentOrConfigurationId: number): KernelPlanObjectComponent;
|
|
250
|
-
getExternalObjectComponent(plan: Plan,
|
|
250
|
+
getExternalObjectComponent(plan: Plan, groupId: string, moduleId: string): KernelPlanObjectComponent;
|
|
251
251
|
requestMesh3d(element: PlanElement): void;
|
|
252
252
|
}
|
|
253
253
|
export interface PlanNode extends KernelObject {
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{aT as normalizeRotation,H as dispose,_ as __decorate,i as inject,j as AsyncGuard,aU as AsyncDependencyLoader,aa as convertToTHREE}from"./roomle-dependency-injection-410ef785.js";import{O as Object3D,a as Vector3,h as MeshBasicMaterial,w as DoubleSide,bn as MeshPhongMaterial,B as BufferGeometry,z as Mesh,Q as Quaternion,b8 as PlaneGeometry,K as Group,u as LineBasicMaterial,G as Line,b as BufferAttribute,bG as Line3,ad as Box3}from"./main-thread-to-worker-554053aa.js";import{T as TextGeometry}from"./TextGeometry-def07ca8.js";const PLANE_MATERIAL="component_dimensioning_plane_material",TEXT_MATERIAL="component_dimensioning_text_material";class TextWithBackground extends Object3D{constructor(e){super(),this._label="",this._parameters={font:null,size:.1,height:.001,curveSegments:2,bevelEnabled:!0,bevelThickness:.001,bevelSize:.001},this.topDown=!1,this._parameters.font=e,this._position=new Vector3,this._initMaterials(),this._init(),this._update()}_initMaterials(){this._cacheHolder.materialCache.has(PLANE_MATERIAL)?this._planeMaterial=this._cacheHolder.materialCache.get(PLANE_MATERIAL):(this._planeMaterial=new MeshBasicMaterial({color:16777215,side:DoubleSide,opacity:.8,transparent:!0}),this._cacheHolder.materialCache.set(PLANE_MATERIAL,this._planeMaterial)),this._cacheHolder.materialCache.has(TEXT_MATERIAL)?this._textMaterial=this._cacheHolder.materialCache.get(TEXT_MATERIAL):(this._textMaterial=new MeshPhongMaterial({color:3618615}),this._cacheHolder.materialCache.set(TEXT_MATERIAL,this._textMaterial))}_init(){let e=new BufferGeometry;this._text=new Mesh(e,this._textMaterial),this._text.userData.ignoreComponentRaycast=!0,this._text.name="text with background text "+this._label,this._plane=new Mesh(e,this._planeMaterial),this._plane.userData.ignoreComponentRaycast=!0,this._plane.name="text with background plane "+this._label,this._textGeometry=new TextGeometry(this._label,this._parameters),this._textGeometry.computeBoundingBox(),this._text.geometry=this._textGeometry,this.add(this._text),this.add(this._plane)}update(e,t,i){this._position.copy(e),this._cameraPosition=i,this._label=t;const s=this.getWorldPosition(new Vector3),n=this._cameraPosition.distanceTo(s),o=Math.max(.01,n/150),h=Math.max(5e-4,n/5e3);this._parameters.bevelThickness=h,this._parameters.bevelSize=h,this._parameters.size=o,this._textGeometry=new TextGeometry(this._label,this._parameters),this._textGeometry.computeBoundingBox(),this._text.geometry=this._textGeometry,this._update()}_update(){if(this.topDown){let e=new Quaternion;e.setFromAxisAngle(new Vector3(-1,0,0),Math.PI/2),this._updateText(this._textGeometry,e,new Vector3)}else if(this._updateText(this._textGeometry,new Quaternion,new Vector3),this._cameraPosition){const e=this.getWorldPosition(new Vector3),t=normalizeRotation(Math.atan2(this._cameraPosition.x-e.x,this._cameraPosition.z-e.z)-this.parent.rotation.y);this._text.rotation.y=t,this._plane.rotation.y=t}}_updateText(e,t,i){let s=new Vector3;s.copy(this._position),i.x*=this._getXSign(),s.add(i);let n=e.boundingBox.getSize(new Vector3);e.center(),this._text.position.copy(s),t&&this._text.quaternion.copy(t);let o=new PlaneGeometry(n.x+.02,n.y+.02,32);o.center(),this._plane.geometry=o,this._plane.position.copy(s),t&&this._plane.quaternion.copy(t)}_getXSign(){return!this._cameraPosition||this._cameraPosition.x>=0?1:-1}dispose(){dispose(this)}}__decorate([inject],TextWithBackground.prototype,"_cacheHolder",void 0);class DimensioningHelper{constructor(e){this._objectRotation=0,this._cameraPosition=new Vector3,this._topDimensions=!1,this._initialized=new AsyncGuard,this._enabled=!1,this._dimensionsVisible=!1,this._dimensionLineGroup=new Group,this._dimensionTextGroup=new Object3D,this._creator_=e,this._lineMaterial=new LineBasicMaterial({color:3618615,linewidth:2});let t=new BufferGeometry;this._widthLine=new Line(t,this._lineMaterial),this._widthLine.userData.ignoreComponentRaycast=!0,this._widthLine.name="dimension width line",this._dimensionLineGroup.add(this._widthLine),this._heightLine=new Line(t,this._lineMaterial),this._heightLine.userData.ignoreComponentRaycast=!0,this._heightLine.name="dimension height line",this._dimensionLineGroup.add(this._heightLine),this._depthLine=new Line(t,this._lineMaterial),this._depthLine.userData.ignoreComponentRaycast=!0,this._depthLine.name="dimension depth line",this._dimensionLineGroup.add(this._depthLine),this._planeMaterial=new MeshBasicMaterial({color:16777215,side:DoubleSide,opacity:.8,transparent:!0}),AsyncDependencyLoader.loadFont("static/lato_regular_sub-d4b30187185acc59.json").then(e=>{this._font=e,this._loaded()})}_loaded(){this.update(!1),this.addToObject(this._object),this.addToUiScene(this._uiScene),this._initialized.resolve()}_performUpdate(e){this._enabled&&(this._dimensions||e)&&this._font&&(this._updateHeight(),this._updateWidth(),this._updateDepth())}_updateWidth(){let e=new BufferGeometry,t=this._getWidthEdge(),i=[t.start.x,t.start.y,t.start.z,t.end.x,t.end.y,t.end.z];e.setAttribute("position",new BufferAttribute(new Float32Array(i),3)),this._widthLine.geometry.dispose(),this._widthLine.geometry=e;let s=t.getCenter(new Vector3);this._widthText||(this._widthText=new TextWithBackground(this._font),this._dimensionTextGroup.add(this._widthText)),this._widthText.topDown=this._topDimensions;const n=this._unitFormatter.formatMMValueToUnitString(1e3*this._dimensions.x);this._widthText.update(s,n,this._cameraPosition)}_updateHeight(){let e=new BufferGeometry,t=this._getHeightEdge(),i=[t.start.x,t.start.y,t.start.z,t.end.x,t.end.y,t.end.z];e.setAttribute("position",new BufferAttribute(new Float32Array(i),3)),this._heightLine.geometry.dispose(),this._heightLine.geometry=e;let s=t.getCenter(new Vector3);this._heightText||(this._heightText=new TextWithBackground(this._font),this._dimensionTextGroup.add(this._heightText)),this._heightText.topDown=this._topDimensions;const n=this._unitFormatter.formatMMValueToUnitString(1e3*this._dimensions.y);this._heightText.update(s,n,this._cameraPosition)}_updateDepth(){let e=new BufferGeometry,t=this._getDepthEdge(),i=[t.start.x,t.start.y,t.start.z,t.end.x,t.end.y,t.end.z];e.setAttribute("position",new BufferAttribute(new Float32Array(i),3)),this._depthLine.geometry.dispose(),this._depthLine.geometry=e;let s=t.getCenter(new Vector3);this._depthText||(this._depthText=new TextWithBackground(this._font),this._dimensionTextGroup.add(this._depthText)),this._depthText.topDown=this._topDimensions;const n=this._unitFormatter.formatMMValueToUnitString(-1e3*this._dimensions.z);this._depthText.update(s,n,this._cameraPosition)}updateSize(e){this._origin=convertToTHREE(e.origin),this._dimensionLineGroup.position.x=this._origin.x-this._object.position.x,this._dimensionLineGroup.position.y=this._origin.y-this._object.position.y,this._dimensionLineGroup.position.z=this._origin.z-this._object.position.z,this._dimensions=convertToTHREE(e.size);const t=this._dimensionLineGroup.localToWorld(new Vector3);this._dimensionTextGroup.position.copy(t),this.update()}update(e=!1){this._enabled&&!this._dimensionsVisible&&(this._dimensionsVisible=!0,this._visibilityChangedCallback()),this._performUpdate(e)}addToObject(e){this._widthText&&this._widthLine&&this._heightText&&this._heightLine&&this._heightText&&this._heightLine&&e.add(this._dimensionLineGroup)}removeFromObject(e){e.remove(this._dimensionLineGroup),this.update()}addToUiScene(e){if(!(this._widthText&&this._heightText&&this._depthText&&this._object))return;const t=this._dimensionLineGroup.localToWorld(new Vector3);this._dimensionTextGroup.position.copy(t),this._dimensionTextGroup.rotation.y=this._objectRotation,e.add(this._dimensionTextGroup),this.update()}removeFromUiScene(e){e.remove(this._dimensionTextGroup),this.update()}_getWidthEdge(){const e=this._getRotation();return e>Math.PI/2||e<-Math.PI/2?new Line3(new Vector3(-.05,0,this._dimensions.z-.05),new Vector3(this._dimensions.x+.05,0,this._dimensions.z-.05)):new Line3(new Vector3(-.05,0,.05),new Vector3(this._dimensions.x+.05,0,.05))}_getDepthEdge(){return this._getRotation()>0?new Line3(new Vector3(.05+this._dimensions.x,0,.05),new Vector3(.05+this._dimensions.x,0,this._dimensions.z-.05)):new Line3(new Vector3(-.05,0,.05),new Vector3(-.05,0,this._dimensions.z-.05))}_getHeightEdge(){const e=this._getRotation();return e>0&&e<Math.PI/2?new Line3(new Vector3(-.05,0,.05),new Vector3(-.05,this._dimensions.y+.05,.05)):e>Math.PI/2?new Line3(new Vector3(-.05,0,this._dimensions.z-.05),new Vector3(-.05,this._dimensions.y+.05,this._dimensions.z-.05)):e<-Math.PI/2?new Line3(new Vector3(.05+this._dimensions.x,0,this._dimensions.z-.05),new Vector3(.05+this._dimensions.x,this._dimensions.y+.05,this._dimensions.z-.05)):new Line3(new Vector3(.05+this._dimensions.x,0,.05),new Vector3(.05+this._dimensions.x,this._dimensions.y+.05,.05))}onDimensionsVisibilityChanged(e){this._onChange=e}enableTopDimensions(){this._topDimensions=!0,this.enableDimensions(),this._heightLine.visible=!1,this._heightText.visible=!1,this.update(!0)}disableTopDimensions(){this._topDimensions=!1,this._heightLine.visible=!0,this._heightText.visible=!0,this.disableDimensions()}enableDimensions(){this._enabled=!0,this.update(!0),this.addToObject(this._object),this.addToUiScene(this._uiScene)}disableDimensions(){this._enabled=!1,this._dimensionsVisible&&(this._dimensionsVisible=!1,this._visibilityChangedCallback()),this.removeFromUiScene(this._uiScene),this.removeFromObject(this._object)}_visibilityChangedCallback(){this._onChange&&this._onChange(this._dimensionsVisible)}_clear(){this._lineMaterial.dispose(),this._planeMaterial.dispose(),this._widthLine.geometry.dispose(),this._heightLine.geometry.dispose(),this._depthLine.geometry.dispose(),this._heightText.dispose(),this._heightText.dispose(),this._depthText.dispose()}getBoundingBox(){const e=new Box3;return e.expandByObject(this._widthLine),e.expandByObject(this._widthText),e.expandByObject(this._heightLine),e.expandByObject(this._heightText),e.expandByObject(this._depthLine),e.expandByObject(this._depthText),e}setVisibility(e){this._dimensionLineGroup&&this._dimensionTextGroup&&(this._dimensionLineGroup.visible=e,this._dimensionTextGroup.visible=e)}moveCameraStart(e){this.setVisibility(!1),this._cameraPosition=e,this.update()}moveCameraEnd(e){this.setVisibility(!0),this._cameraPosition=e,this.update()}clearScene(e){this._clear()}setObject(e,t=0){this._object=e,this._objectRotation=t}setUiScene(e){this._uiScene=e}isInitialized(){return this._initialized.wait()}areDimensionsEnabled(){return this._enabled}_getRotation(){const e=this._object.getWorldPosition(new Vector3);return normalizeRotation(Math.atan2(this._cameraPosition.x-e.x,this._cameraPosition.z-e.z)-this._objectRotation)}}__decorate([inject],DimensioningHelper.prototype,"_unitFormatter",void 0);export{DimensioningHelper as default};
|
|
2
|
-
//# sourceMappingURL=dimensioning-helper-
|
|
1
|
+
import{aU as normalizeRotation,H as dispose,_ as __decorate,i as inject,j as AsyncGuard,aV as AsyncDependencyLoader,aa as convertToTHREE}from"./roomle-dependency-injection-b0f42112.js";import{O as Object3D,a as Vector3,h as MeshBasicMaterial,w as DoubleSide,bn as MeshPhongMaterial,B as BufferGeometry,z as Mesh,Q as Quaternion,b8 as PlaneGeometry,K as Group,u as LineBasicMaterial,G as Line,b as BufferAttribute,bH as Line3,ad as Box3}from"./main-thread-to-worker-af604b88.js";import{T as TextGeometry}from"./TextGeometry-64e47e97.js";const PLANE_MATERIAL="component_dimensioning_plane_material",TEXT_MATERIAL="component_dimensioning_text_material";class TextWithBackground extends Object3D{constructor(e){super(),this._label="",this._parameters={font:null,size:.1,height:.001,curveSegments:2,bevelEnabled:!0,bevelThickness:.001,bevelSize:.001},this.topDown=!1,this._parameters.font=e,this._position=new Vector3,this._initMaterials(),this._init(),this._update()}_initMaterials(){this._cacheHolder.materialCache.has(PLANE_MATERIAL)?this._planeMaterial=this._cacheHolder.materialCache.get(PLANE_MATERIAL):(this._planeMaterial=new MeshBasicMaterial({color:16777215,side:DoubleSide,opacity:.8,transparent:!0}),this._cacheHolder.materialCache.set(PLANE_MATERIAL,this._planeMaterial)),this._cacheHolder.materialCache.has(TEXT_MATERIAL)?this._textMaterial=this._cacheHolder.materialCache.get(TEXT_MATERIAL):(this._textMaterial=new MeshPhongMaterial({color:3618615}),this._cacheHolder.materialCache.set(TEXT_MATERIAL,this._textMaterial))}_init(){let e=new BufferGeometry;this._text=new Mesh(e,this._textMaterial),this._text.userData.ignoreComponentRaycast=!0,this._text.name="text with background text "+this._label,this._plane=new Mesh(e,this._planeMaterial),this._plane.userData.ignoreComponentRaycast=!0,this._plane.name="text with background plane "+this._label,this._textGeometry=new TextGeometry(this._label,this._parameters),this._textGeometry.computeBoundingBox(),this._text.geometry=this._textGeometry,this.add(this._text),this.add(this._plane)}update(e,t,i){this._position.copy(e),this._cameraPosition=i,this._label=t;const s=this.getWorldPosition(new Vector3),n=this._cameraPosition.distanceTo(s),o=Math.max(.01,n/150),h=Math.max(5e-4,n/5e3);this._parameters.bevelThickness=h,this._parameters.bevelSize=h,this._parameters.size=o,this._textGeometry=new TextGeometry(this._label,this._parameters),this._textGeometry.computeBoundingBox(),this._text.geometry=this._textGeometry,this._update()}_update(){if(this.topDown){let e=new Quaternion;e.setFromAxisAngle(new Vector3(-1,0,0),Math.PI/2),this._updateText(this._textGeometry,e,new Vector3)}else if(this._updateText(this._textGeometry,new Quaternion,new Vector3),this._cameraPosition){const e=this.getWorldPosition(new Vector3),t=normalizeRotation(Math.atan2(this._cameraPosition.x-e.x,this._cameraPosition.z-e.z)-this.parent.rotation.y);this._text.rotation.y=t,this._plane.rotation.y=t}}_updateText(e,t,i){let s=new Vector3;s.copy(this._position),i.x*=this._getXSign(),s.add(i);let n=e.boundingBox.getSize(new Vector3);e.center(),this._text.position.copy(s),t&&this._text.quaternion.copy(t);let o=new PlaneGeometry(n.x+.02,n.y+.02,32);o.center(),this._plane.geometry=o,this._plane.position.copy(s),t&&this._plane.quaternion.copy(t)}_getXSign(){return!this._cameraPosition||this._cameraPosition.x>=0?1:-1}dispose(){dispose(this)}}__decorate([inject],TextWithBackground.prototype,"_cacheHolder",void 0);class DimensioningHelper{constructor(e){this._objectRotation=0,this._cameraPosition=new Vector3,this._topDimensions=!1,this._initialized=new AsyncGuard,this._enabled=!1,this._dimensionsVisible=!1,this._dimensionLineGroup=new Group,this._dimensionTextGroup=new Object3D,this._creator_=e,this._lineMaterial=new LineBasicMaterial({color:3618615,linewidth:2});let t=new BufferGeometry;this._widthLine=new Line(t,this._lineMaterial),this._widthLine.userData.ignoreComponentRaycast=!0,this._widthLine.name="dimension width line",this._dimensionLineGroup.add(this._widthLine),this._heightLine=new Line(t,this._lineMaterial),this._heightLine.userData.ignoreComponentRaycast=!0,this._heightLine.name="dimension height line",this._dimensionLineGroup.add(this._heightLine),this._depthLine=new Line(t,this._lineMaterial),this._depthLine.userData.ignoreComponentRaycast=!0,this._depthLine.name="dimension depth line",this._dimensionLineGroup.add(this._depthLine),this._planeMaterial=new MeshBasicMaterial({color:16777215,side:DoubleSide,opacity:.8,transparent:!0}),AsyncDependencyLoader.loadFont("static/lato_regular_sub-d4b30187185acc59.json").then(e=>{this._font=e,this._loaded()})}_loaded(){this.update(!1),this.addToObject(this._object),this.addToUiScene(this._uiScene),this._initialized.resolve()}_performUpdate(e){this._enabled&&(this._dimensions||e)&&this._font&&(this._updateHeight(),this._updateWidth(),this._updateDepth())}_updateWidth(){let e=new BufferGeometry,t=this._getWidthEdge(),i=[t.start.x,t.start.y,t.start.z,t.end.x,t.end.y,t.end.z];e.setAttribute("position",new BufferAttribute(new Float32Array(i),3)),this._widthLine.geometry.dispose(),this._widthLine.geometry=e;let s=t.getCenter(new Vector3);this._widthText||(this._widthText=new TextWithBackground(this._font),this._dimensionTextGroup.add(this._widthText)),this._widthText.topDown=this._topDimensions;const n=this._unitFormatter.formatMMValueToUnitString(1e3*this._dimensions.x);this._widthText.update(s,n,this._cameraPosition)}_updateHeight(){let e=new BufferGeometry,t=this._getHeightEdge(),i=[t.start.x,t.start.y,t.start.z,t.end.x,t.end.y,t.end.z];e.setAttribute("position",new BufferAttribute(new Float32Array(i),3)),this._heightLine.geometry.dispose(),this._heightLine.geometry=e;let s=t.getCenter(new Vector3);this._heightText||(this._heightText=new TextWithBackground(this._font),this._dimensionTextGroup.add(this._heightText)),this._heightText.topDown=this._topDimensions;const n=this._unitFormatter.formatMMValueToUnitString(1e3*this._dimensions.y);this._heightText.update(s,n,this._cameraPosition)}_updateDepth(){let e=new BufferGeometry,t=this._getDepthEdge(),i=[t.start.x,t.start.y,t.start.z,t.end.x,t.end.y,t.end.z];e.setAttribute("position",new BufferAttribute(new Float32Array(i),3)),this._depthLine.geometry.dispose(),this._depthLine.geometry=e;let s=t.getCenter(new Vector3);this._depthText||(this._depthText=new TextWithBackground(this._font),this._dimensionTextGroup.add(this._depthText)),this._depthText.topDown=this._topDimensions;const n=this._unitFormatter.formatMMValueToUnitString(-1e3*this._dimensions.z);this._depthText.update(s,n,this._cameraPosition)}updateSize(e){this._origin=convertToTHREE(e.origin),this._dimensionLineGroup.position.x=this._origin.x-this._object.position.x,this._dimensionLineGroup.position.y=this._origin.y-this._object.position.y,this._dimensionLineGroup.position.z=this._origin.z-this._object.position.z,this._dimensions=convertToTHREE(e.size);const t=this._dimensionLineGroup.localToWorld(new Vector3);this._dimensionTextGroup.position.copy(t),this.update()}update(e=!1){this._enabled&&!this._dimensionsVisible&&(this._dimensionsVisible=!0,this._visibilityChangedCallback()),this._performUpdate(e)}addToObject(e){this._widthText&&this._widthLine&&this._heightText&&this._heightLine&&this._heightText&&this._heightLine&&e.add(this._dimensionLineGroup)}removeFromObject(e){e.remove(this._dimensionLineGroup),this.update()}addToUiScene(e){if(!(this._widthText&&this._heightText&&this._depthText&&this._object))return;const t=this._dimensionLineGroup.localToWorld(new Vector3);this._dimensionTextGroup.position.copy(t),this._dimensionTextGroup.rotation.y=this._objectRotation,e.add(this._dimensionTextGroup),this.update()}removeFromUiScene(e){e.remove(this._dimensionTextGroup),this.update()}_getWidthEdge(){const e=this._getRotation();return e>Math.PI/2||e<-Math.PI/2?new Line3(new Vector3(-.05,0,this._dimensions.z-.05),new Vector3(this._dimensions.x+.05,0,this._dimensions.z-.05)):new Line3(new Vector3(-.05,0,.05),new Vector3(this._dimensions.x+.05,0,.05))}_getDepthEdge(){return this._getRotation()>0?new Line3(new Vector3(.05+this._dimensions.x,0,.05),new Vector3(.05+this._dimensions.x,0,this._dimensions.z-.05)):new Line3(new Vector3(-.05,0,.05),new Vector3(-.05,0,this._dimensions.z-.05))}_getHeightEdge(){const e=this._getRotation();return e>0&&e<Math.PI/2?new Line3(new Vector3(-.05,0,.05),new Vector3(-.05,this._dimensions.y+.05,.05)):e>Math.PI/2?new Line3(new Vector3(-.05,0,this._dimensions.z-.05),new Vector3(-.05,this._dimensions.y+.05,this._dimensions.z-.05)):e<-Math.PI/2?new Line3(new Vector3(.05+this._dimensions.x,0,this._dimensions.z-.05),new Vector3(.05+this._dimensions.x,this._dimensions.y+.05,this._dimensions.z-.05)):new Line3(new Vector3(.05+this._dimensions.x,0,.05),new Vector3(.05+this._dimensions.x,this._dimensions.y+.05,.05))}onDimensionsVisibilityChanged(e){this._onChange=e}enableTopDimensions(){this._topDimensions=!0,this.enableDimensions(),this._heightLine.visible=!1,this._heightText.visible=!1,this.update(!0)}disableTopDimensions(){this._topDimensions=!1,this._heightLine.visible=!0,this._heightText.visible=!0,this.disableDimensions()}enableDimensions(){this._enabled=!0,this.update(!0),this.addToObject(this._object),this.addToUiScene(this._uiScene)}disableDimensions(){this._enabled=!1,this._dimensionsVisible&&(this._dimensionsVisible=!1,this._visibilityChangedCallback()),this.removeFromUiScene(this._uiScene),this.removeFromObject(this._object)}_visibilityChangedCallback(){this._onChange&&this._onChange(this._dimensionsVisible)}_clear(){this._lineMaterial.dispose(),this._planeMaterial.dispose(),this._widthLine.geometry.dispose(),this._heightLine.geometry.dispose(),this._depthLine.geometry.dispose(),this._heightText.dispose(),this._heightText.dispose(),this._depthText.dispose()}getBoundingBox(){const e=new Box3;return e.expandByObject(this._widthLine),e.expandByObject(this._widthText),e.expandByObject(this._heightLine),e.expandByObject(this._heightText),e.expandByObject(this._depthLine),e.expandByObject(this._depthText),e}setVisibility(e){this._dimensionLineGroup&&this._dimensionTextGroup&&(this._dimensionLineGroup.visible=e,this._dimensionTextGroup.visible=e)}moveCameraStart(e){this.setVisibility(!1),this._cameraPosition=e,this.update()}moveCameraEnd(e){this.setVisibility(!0),this._cameraPosition=e,this.update()}clearScene(e){this._clear()}setObject(e,t=0){this._object=e,this._objectRotation=t}setUiScene(e){this._uiScene=e}isInitialized(){return this._initialized.wait()}areDimensionsEnabled(){return this._enabled}_getRotation(){const e=this._object.getWorldPosition(new Vector3);return normalizeRotation(Math.atan2(this._cameraPosition.x-e.x,this._cameraPosition.z-e.z)-this._objectRotation)}}__decorate([inject],DimensioningHelper.prototype,"_unitFormatter",void 0);export{DimensioningHelper as default};
|
|
2
|
+
//# sourceMappingURL=dimensioning-helper-7b967027.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"dimensioning-helper-
|
|
1
|
+
{"version":3,"file":"dimensioning-helper-7b967027.js","sources":["../../packages/configurator-core/public/fonts/lato_regular_sub.json"],"sourcesContent":["export default \"static/lato_regular_sub-d4b30187185acc59.json\""],"names":[],"mappings":"w7IAAe"}
|
package/lib/{dimensioning-helper-8de4a0b8.nomodule.js → dimensioning-helper-a2b1a06e.nomodule.js}
RENAMED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
System.register(["./roomle-dependency-injection-
|
|
2
|
-
//# sourceMappingURL=dimensioning-helper-
|
|
1
|
+
System.register(["./roomle-dependency-injection-11d4372b.nomodule.js","./main-thread-to-worker-a33146dd.nomodule.js","./TextGeometry-6c37ac59.nomodule.js"],(function(t){var i,e,s,n,h,o,a,_,d,r,p,m,l,c,x,u,g,w,b,y,T,L,z;return{setters:[function(t){i=t.aU,e=t.H,s=t._,n=t.i,h=t.j,o=t.aV,a=t.aa},function(t){_=t.O,d=t.a,r=t.h,p=t.w,m=t.bn,l=t.B,c=t.z,x=t.Q,u=t.b8,g=t.K,w=t.u,b=t.G,y=t.b,T=t.bH,L=t.ad},function(t){z=t.T}],execute:function(){const G="component_dimensioning_plane_material",M="component_dimensioning_text_material";class j extends _{constructor(t){super(),this._label="",this._parameters={font:null,size:.1,height:.001,curveSegments:2,bevelEnabled:!0,bevelThickness:.001,bevelSize:.001},this.topDown=!1,this._parameters.font=t,this._position=new d,this._initMaterials(),this._init(),this._update()}_initMaterials(){this._cacheHolder.materialCache.has(G)?this._planeMaterial=this._cacheHolder.materialCache.get(G):(this._planeMaterial=new r({color:16777215,side:p,opacity:.8,transparent:!0}),this._cacheHolder.materialCache.set(G,this._planeMaterial)),this._cacheHolder.materialCache.has(M)?this._textMaterial=this._cacheHolder.materialCache.get(M):(this._textMaterial=new m({color:3618615}),this._cacheHolder.materialCache.set(M,this._textMaterial))}_init(){let t=new l;this._text=new c(t,this._textMaterial),this._text.userData.ignoreComponentRaycast=!0,this._text.name="text with background text "+this._label,this._plane=new c(t,this._planeMaterial),this._plane.userData.ignoreComponentRaycast=!0,this._plane.name="text with background plane "+this._label,this._textGeometry=new z(this._label,this._parameters),this._textGeometry.computeBoundingBox(),this._text.geometry=this._textGeometry,this.add(this._text),this.add(this._plane)}update(t,i,e){this._position.copy(t),this._cameraPosition=e,this._label=i;const s=this.getWorldPosition(new d),n=this._cameraPosition.distanceTo(s),h=Math.max(.01,n/150),o=Math.max(5e-4,n/5e3);this._parameters.bevelThickness=o,this._parameters.bevelSize=o,this._parameters.size=h,this._textGeometry=new z(this._label,this._parameters),this._textGeometry.computeBoundingBox(),this._text.geometry=this._textGeometry,this._update()}_update(){if(this.topDown){let t=new x;t.setFromAxisAngle(new d(-1,0,0),Math.PI/2),this._updateText(this._textGeometry,t,new d)}else if(this._updateText(this._textGeometry,new x,new d),this._cameraPosition){const t=this.getWorldPosition(new d),e=i(Math.atan2(this._cameraPosition.x-t.x,this._cameraPosition.z-t.z)-this.parent.rotation.y);this._text.rotation.y=e,this._plane.rotation.y=e}}_updateText(t,i,e){let s=new d;s.copy(this._position),e.x*=this._getXSign(),s.add(e);let n=t.boundingBox.getSize(new d);t.center(),this._text.position.copy(s),i&&this._text.quaternion.copy(i);let h=new u(n.x+.02,n.y+.02,32);h.center(),this._plane.geometry=h,this._plane.position.copy(s),i&&this._plane.quaternion.copy(i)}_getXSign(){return!this._cameraPosition||this._cameraPosition.x>=0?1:-1}dispose(){e(this)}}s([n],j.prototype,"_cacheHolder",void 0);class D{constructor(t){this._objectRotation=0,this._cameraPosition=new d,this._topDimensions=!1,this._initialized=new h,this._enabled=!1,this._dimensionsVisible=!1,this._dimensionLineGroup=new g,this._dimensionTextGroup=new _,this._creator_=t,this._lineMaterial=new w({color:3618615,linewidth:2});let i=new l;this._widthLine=new b(i,this._lineMaterial),this._widthLine.userData.ignoreComponentRaycast=!0,this._widthLine.name="dimension width line",this._dimensionLineGroup.add(this._widthLine),this._heightLine=new b(i,this._lineMaterial),this._heightLine.userData.ignoreComponentRaycast=!0,this._heightLine.name="dimension height line",this._dimensionLineGroup.add(this._heightLine),this._depthLine=new b(i,this._lineMaterial),this._depthLine.userData.ignoreComponentRaycast=!0,this._depthLine.name="dimension depth line",this._dimensionLineGroup.add(this._depthLine),this._planeMaterial=new r({color:16777215,side:p,opacity:.8,transparent:!0}),o.loadFont("static/lato_regular_sub-d4b30187185acc59.json").then(t=>{this._font=t,this._loaded()})}_loaded(){this.update(!1),this.addToObject(this._object),this.addToUiScene(this._uiScene),this._initialized.resolve()}_performUpdate(t){this._enabled&&(this._dimensions||t)&&this._font&&(this._updateHeight(),this._updateWidth(),this._updateDepth())}_updateWidth(){let t=new l,i=this._getWidthEdge(),e=[i.start.x,i.start.y,i.start.z,i.end.x,i.end.y,i.end.z];t.setAttribute("position",new y(new Float32Array(e),3)),this._widthLine.geometry.dispose(),this._widthLine.geometry=t;let s=i.getCenter(new d);this._widthText||(this._widthText=new j(this._font),this._dimensionTextGroup.add(this._widthText)),this._widthText.topDown=this._topDimensions;const n=this._unitFormatter.formatMMValueToUnitString(1e3*this._dimensions.x);this._widthText.update(s,n,this._cameraPosition)}_updateHeight(){let t=new l,i=this._getHeightEdge(),e=[i.start.x,i.start.y,i.start.z,i.end.x,i.end.y,i.end.z];t.setAttribute("position",new y(new Float32Array(e),3)),this._heightLine.geometry.dispose(),this._heightLine.geometry=t;let s=i.getCenter(new d);this._heightText||(this._heightText=new j(this._font),this._dimensionTextGroup.add(this._heightText)),this._heightText.topDown=this._topDimensions;const n=this._unitFormatter.formatMMValueToUnitString(1e3*this._dimensions.y);this._heightText.update(s,n,this._cameraPosition)}_updateDepth(){let t=new l,i=this._getDepthEdge(),e=[i.start.x,i.start.y,i.start.z,i.end.x,i.end.y,i.end.z];t.setAttribute("position",new y(new Float32Array(e),3)),this._depthLine.geometry.dispose(),this._depthLine.geometry=t;let s=i.getCenter(new d);this._depthText||(this._depthText=new j(this._font),this._dimensionTextGroup.add(this._depthText)),this._depthText.topDown=this._topDimensions;const n=this._unitFormatter.formatMMValueToUnitString(-1e3*this._dimensions.z);this._depthText.update(s,n,this._cameraPosition)}updateSize(t){this._origin=a(t.origin),this._dimensionLineGroup.position.x=this._origin.x-this._object.position.x,this._dimensionLineGroup.position.y=this._origin.y-this._object.position.y,this._dimensionLineGroup.position.z=this._origin.z-this._object.position.z,this._dimensions=a(t.size);const i=this._dimensionLineGroup.localToWorld(new d);this._dimensionTextGroup.position.copy(i),this.update()}update(t=!1){this._enabled&&!this._dimensionsVisible&&(this._dimensionsVisible=!0,this._visibilityChangedCallback()),this._performUpdate(t)}addToObject(t){this._widthText&&this._widthLine&&this._heightText&&this._heightLine&&this._heightText&&this._heightLine&&t.add(this._dimensionLineGroup)}removeFromObject(t){t.remove(this._dimensionLineGroup),this.update()}addToUiScene(t){if(!(this._widthText&&this._heightText&&this._depthText&&this._object))return;const i=this._dimensionLineGroup.localToWorld(new d);this._dimensionTextGroup.position.copy(i),this._dimensionTextGroup.rotation.y=this._objectRotation,t.add(this._dimensionTextGroup),this.update()}removeFromUiScene(t){t.remove(this._dimensionTextGroup),this.update()}_getWidthEdge(){const t=this._getRotation();return t>Math.PI/2||t<-Math.PI/2?new T(new d(-.05,0,this._dimensions.z-.05),new d(this._dimensions.x+.05,0,this._dimensions.z-.05)):new T(new d(-.05,0,.05),new d(this._dimensions.x+.05,0,.05))}_getDepthEdge(){return this._getRotation()>0?new T(new d(.05+this._dimensions.x,0,.05),new d(.05+this._dimensions.x,0,this._dimensions.z-.05)):new T(new d(-.05,0,.05),new d(-.05,0,this._dimensions.z-.05))}_getHeightEdge(){const t=this._getRotation();return t>0&&t<Math.PI/2?new T(new d(-.05,0,.05),new d(-.05,this._dimensions.y+.05,.05)):t>Math.PI/2?new T(new d(-.05,0,this._dimensions.z-.05),new d(-.05,this._dimensions.y+.05,this._dimensions.z-.05)):t<-Math.PI/2?new T(new d(.05+this._dimensions.x,0,this._dimensions.z-.05),new d(.05+this._dimensions.x,this._dimensions.y+.05,this._dimensions.z-.05)):new T(new d(.05+this._dimensions.x,0,.05),new d(.05+this._dimensions.x,this._dimensions.y+.05,.05))}onDimensionsVisibilityChanged(t){this._onChange=t}enableTopDimensions(){this._topDimensions=!0,this.enableDimensions(),this._heightLine.visible=!1,this._heightText.visible=!1,this.update(!0)}disableTopDimensions(){this._topDimensions=!1,this._heightLine.visible=!0,this._heightText.visible=!0,this.disableDimensions()}enableDimensions(){this._enabled=!0,this.update(!0),this.addToObject(this._object),this.addToUiScene(this._uiScene)}disableDimensions(){this._enabled=!1,this._dimensionsVisible&&(this._dimensionsVisible=!1,this._visibilityChangedCallback()),this.removeFromUiScene(this._uiScene),this.removeFromObject(this._object)}_visibilityChangedCallback(){this._onChange&&this._onChange(this._dimensionsVisible)}_clear(){this._lineMaterial.dispose(),this._planeMaterial.dispose(),this._widthLine.geometry.dispose(),this._heightLine.geometry.dispose(),this._depthLine.geometry.dispose(),this._heightText.dispose(),this._heightText.dispose(),this._depthText.dispose()}getBoundingBox(){const t=new L;return t.expandByObject(this._widthLine),t.expandByObject(this._widthText),t.expandByObject(this._heightLine),t.expandByObject(this._heightText),t.expandByObject(this._depthLine),t.expandByObject(this._depthText),t}setVisibility(t){this._dimensionLineGroup&&this._dimensionTextGroup&&(this._dimensionLineGroup.visible=t,this._dimensionTextGroup.visible=t)}moveCameraStart(t){this.setVisibility(!1),this._cameraPosition=t,this.update()}moveCameraEnd(t){this.setVisibility(!0),this._cameraPosition=t,this.update()}clearScene(t){this._clear()}setObject(t,i=0){this._object=t,this._objectRotation=i}setUiScene(t){this._uiScene=t}isInitialized(){return this._initialized.wait()}areDimensionsEnabled(){return this._enabled}_getRotation(){const t=this._object.getWorldPosition(new d);return i(Math.atan2(this._cameraPosition.x-t.x,this._cameraPosition.z-t.z)-this._objectRotation)}}t("default",D),s([n],D.prototype,"_unitFormatter",void 0)}}}));
|
|
2
|
+
//# sourceMappingURL=dimensioning-helper-a2b1a06e.nomodule.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"dimensioning-helper-
|
|
1
|
+
{"version":3,"file":"dimensioning-helper-a2b1a06e.nomodule.js","sources":["../../packages/configurator-core/public/fonts/lato_regular_sub.json"],"sourcesContent":["export default \"static/lato_regular_sub-d4b30187185acc59.json\""],"names":[],"mappings":"w4HAAe"}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
System.register(["./script-loader-eb097908.nomodule.js","./roomle-dependency-injection-11d4372b.nomodule.js","./camera-behaviour-e7f9d0fc.nomodule.js","./main-thread-to-worker-a33146dd.nomodule.js","./jszip.min-d3d3c14a.nomodule.js","./glb-viewer-camera-behaviour-89e58c94.nomodule.js","./query-params-helper-ff314078.nomodule.js"],(function(e){var t,r,i,n,a,s,o,h,c,d,l,u,m,_,p,g,v,w,f,b,C,S,L,B,M,y,I,x,G,E,j,O,F,D;return{setters:[function(e){t=e.S,r=e.M},function(e){i=e.aK,n=e.D,a=e.L,s=e.R,o=e.ae,h=e._,c=e.i,d=e.u,l=e.x,u=e.y,m=e.H,_=e.b},function(e){p=e.C,g=e.L,v=e.S,w=e.T},function(e){f=e.a,b=e.ad,C=e.ag,S=e.Q,L=e.A,B=e.C,M=e.aE,y=e.aR,I=e.bv,x=e.i,G=e.bj,E=e.N,j=e.bC},function(e){O=e.D,F=e.J},function(e){D=e.G},function(){}],execute:function(){const P=[new n("script-loader",t),new n("glb-input-manager",class extends i{},1),new n("logger",a),new n("rapi-access",s)];class z extends p{constructor(){super(...arguments),this.shouldIgnoreStandardBehavior=!1}adjust(e,t,r,i,n){let a=new f(-e.x/2,0,-e.z/2),s=new f(e.x/2,e.y,e.z/2);this._boundingBox=new b(a,s);let o=new C(-Math.PI/2+i,r,0,"ZYX"),h=(new S).setFromEuler(o);this._camera.updateProjectionMatrix(),this._camera.quaternion.copy(h),this._camera.position.copy(t)}_update(e){this.shouldIgnoreStandardBehavior?this._saveYawAndPitch():super._update(e)}animateCamera(e){return!!this.shouldIgnoreStandardBehavior||super.animateCamera(e)}}class A extends g{constructor(e,t){super(e,t),this._params={ambientLight:{color:"#ffffff"}},this._ambientLight=new L(new B(this._params.ambientLight.color),.5),this.addToScene()}addToScene(){this._scene.add(this._ambientLight)}removeFromScene(){this._scene.remove(this._ambientLight)}reload(){this.removeFromScene(),this.addToScene()}showGUI(){let e=o();if(e&&this._ambientLight){let t=e.addFolder("Ambient Light");t.add(this._ambientLight,"visible"),t.add(this._ambientLight,"intensity").min(0).max(5).step(.1),t.addColor(this._params.ambientLight,"color").onChange(e=>{this._ambientLight.color=new B(e)})}}}class U extends v{constructor(e,t){super(e,t,d.GLB,M.CAMERA_3D),this._itemsCount=0,this._standardSceneBackgroundColor=this._scene.background,this._initData.legacyLight&&(this._renderer.capabilities.maxTextures>8?this.loadDynamicLightSetting(l.createDynamicLightSettingSource(null,u.CAMERA)):(console.warn("this device has a maximum of 8 texture units thus we are using a simpler light setting"),this._lightSetting=new A(this._scene)))}createCameraControl(e,t){this._changeCameraBehaviour(new D(new z(this._creator_,this._getInputManager(),new f(-1,1,1)),this._cameraBehaviourState))}_getInputManager(){return this._glbInputManager}async loadStaticItem(e,t){const r=await this._rapiAccess.getItem(e);if(r.configuration)return Promise.reject();const i=y(r);return i?this.loadGLB(i,!0,void 0,t):Promise.reject(new Error("GLB Url not detected"))}loadGLB(e,t=!0,r=new f(1,1,1),i){return this.clearScene(),new Promise((n,a)=>{this._loadGLB(e,new f(0,0,0),0,void 0,r,void 0,void 0,i).then(e=>{this._currentGLB=e,this._scene.add(this._currentGLB);let r=(new b).setFromObject(this._currentGLB);t&&this.cameraBehaviour.cameraControl instanceof z&&this.glbViewerCameraBehaviour.updateCameraOnItemLoaded(r),this._updateBounds(r,null,!0),n()},a)})}preparePerspectiveImage(e,t,r){return new Promise(i=>{var n,a;t||(t=1e3),r||(r=1e3),e||((e=new I({antialias:!0})).setSize(t,r),e.outputColorSpace=x,e.autoClear=!1,e.shadowMap.enabled=!0,e.shadowMap.type=G);let s=this.cameraBehaviour.cameraControl.getCamera().clone();s instanceof E&&(s.aspect=t/r,s.updateProjectionMatrix()),null===(n=this._lightSetting)||void 0===n||n.removeFromScene();let o=new O(this._scene);e.render(this._scene,s);let h=e.domElement.toDataURL();e.domElement.toBlob(e=>{i({image:h,width:t,height:r,blob:e})},"image/png"),o.removeFromScene(),null===(a=this._lightSetting)||void 0===a||a.addToScene()})}adjustCamera(e,t,r,i){if(this.cameraBehaviour.cameraControl instanceof z){let n=(new b).setFromObject(this._scene).getSize(new f);this.cameraBehaviour.cameraControl.adjust(n,e,t,r,i),this._requestRender()}}onStart(e){this._itemsCount=e,this._scene.background=null,this.cameraBehaviour.cameraControl instanceof z&&(this.cameraBehaviour.cameraControl.shouldIgnoreStandardBehavior=!0)}onElementFinished(e){this._itemsCount,Math.round(100/this._itemsCount*e)}onFinished(e){this._scene.background=this._standardSceneBackgroundColor,this.cameraBehaviour.cameraControl instanceof z&&(this.cameraBehaviour.cameraControl.shouldIgnoreStandardBehavior=!1)}clearScene(){this._currentGLB&&(this._scene.remove(this._currentGLB),m(this._currentGLB),this._currentGLB=null),super.clearScene()}enableHD(){super.enableHD()}sceneChanged(){}getBounds(){return this._currentGLB?(new b).setFromObject(this._currentGLB):null}get glbViewerCameraBehaviour(){return this.cameraBehaviour}getGeometryBounds(){return null}cameraBehaviourChanged(){super.cameraBehaviourChanged(),this.cameraBehaviour.cameraControl.addEventListener(3,()=>{this._requestRender()},this),this.cameraBehaviour.cameraControl.addEventListener(4,()=>{this._requestRender()},this)}}h([c],U.prototype,"_glbInputManager",void 0),h([c],U.prototype,"_rapiAccess",void 0);class R{constructor(e,t,r){this._prefix="https://furniture.roomle.com/3d/glb/",this._listeners=new Set,this._finishedItems=0,this._sceneManager=e,this._renderer=new I({antialias:!0,alpha:!0}),this._width=t,this._height=r,this._renderer.setSize(t,r),this._renderer.setClearColor(16777215,0),this._renderer.outputColorSpace=x}addListener(e){this._listeners.add(e)}removeListener(e){this._listeners.delete(e)}start(e){return this._entries=[],e.forEach(e=>{this._entries.push(this._transform(e))}),this._finishedItems=0,this._listeners.forEach(e=>e.onStart(this._entries.length)),this._zip=new window.JSZip,this._doNextEntry(),new Promise(e=>{this._resolve=e})}_transform(e){return{name:e.path.replace(".glb",".png"),url:this._prefix+e.path,position:new f(e.camera.position.x,e.camera.position.z,-e.camera.position.y),fov:2*e.camera.fieldOfView,yaw:e.camera.rotation.z,pitch:e.camera.rotation.x}}_doNextEntry(){0===this._entries.length?(this._listeners.forEach(e=>e.onFinished(this._zip)),this._resolve(this._zip)):this._processEntry(this._entries[0])}_processEntry(e){this._sceneManager.loadGLB(e.url,!1,void 0).then(()=>{this._sceneManager.adjustCamera(e.position,e.yaw,e.pitch,e.fov),this._sceneManager.preparePerspectiveImage(this._renderer,this._width,this._height).then(t=>{this._entryFinished(e,t)})})}_entryFinished(e,t){let r=this._entries.indexOf(e);r>-1&&this._entries.splice(r,1),this._finishedItems++,this._listeners.forEach(e=>e.onElementFinished(this._finishedItems)),this._zip.file(e.name,t.blob),this._doNextEntry()}}class k{constructor(e){this._currentIdOrUrl=null,this._creator_=e}setCameraOffset(e){this._sceneManager.setCameraOffset(e)}getCameraOffset(){return this._sceneManager.getCameraOffset()}init(e,t){return this.setOverrides(t),this._domHelper.setDomElement(e),this._sceneManager?(this._lifeCycleManager.resume(),Promise.resolve()):new Promise(this._initPromiseCallback.bind(this))}_initPromiseCallback(e,t){Promise.all([this._scriptLoader.fetch(w,{id:"tween-js"})]).then(()=>{this._sceneManager=new U(this._creator_,{left:0,top:1,right:1,bottom:0}),this._sceneManager.enableHD(),e()})}clearScene(){this._sceneManager.clearScene()}loadGLB(e,t=1,r){return this._currentIdOrUrl=e,this._rapiAccess.trackView(e),this._sceneManager.loadGLB(e,!0,new f(t,t,t),r)}loadStaticItem(e,t){return this._currentIdOrUrl=e,this._rapiAccess.trackView(e),this._sceneManager.loadStaticItem(e,t)}getCurrentId(){return this._currentIdOrUrl}loadSceneSetting(e){return this._sceneManager.loadSceneSettings(e)}preparePerspectiveImage(){return this._sceneManager.preparePerspectiveImage()}processRenderList(e,t=320,r=320){let i=JSON.parse(e);this._scriptLoader.fetch(F,{id:"jszip-js"}).then(()=>{let e=new R(this._sceneManager,t,r);e.addListener(this._sceneManager),e.start(i.items).then(t=>{t.generateAsync({type:"blob"}).then(t=>{j("content.zip",URL.createObjectURL(t)),e.removeListener(this._sceneManager)})})})}setOverrides(e){e&&(this._initData.setOverrides(e),this._globalInitData.setOverrides(e))}updateSize(){this._sceneManager.updateCamera()}getMain(){}resumeTest(e){this._domHelper.setDomElement(e),this._lifeCycleManager.resume()}pauseTest(){this._lifeCycleManager.pause()}showGUI(){this._sceneManager.showGUI()}get callbacks(){return{}}getScene(){return this._sceneManager.getScene()}updateScene(){this._sceneManager.updateScene()}getUnitFormatter(){return this._unitFormatter}getStorage(){return this._idbManager}setEnvironmentMap(e){const{url:t,intensity:r,rotation:i,maxLightSources:n}=e;this._sceneManager.setEnvironmentMap(t,r,i,n)}}h([c],k.prototype,"_rapiAccess",void 0),h([c],k.prototype,"_domHelper",void 0),h([c],k.prototype,"_scriptLoader",void 0),h([c],k.prototype,"_lifeCycleManager",void 0),h([c],k.prototype,"_initData",void 0),h([c],k.prototype,"_globalInitData",void 0),h([c],k.prototype,"_unitFormatter",void 0),h([c],k.prototype,"_idbManager",void 0),e("GlbViewer",class extends r{setupGlobals(){}setupDependencies(){_.setup(P),this.lookup("logger",this._context)}cleanUpGlobals(){throw new Error("Method not implemented.")}cleanUpDependencies(){throw new Error("Method not implemented.")}bootFinished(){this._viewer=new k(this._context),window.RoomleGLBViewer||(window.RoomleGLBViewer=this._viewer)}getApi(){return this._viewer}getContextName(){return"glb-viewer"}})}}}));
|
|
2
|
+
//# sourceMappingURL=glb-viewer-447286f6.nomodule.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"glb-viewer-447286f6.nomodule.js","sources":[],"sourcesContent":[],"names":[],"mappings":""}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{S as ScriptLoader,M as Main}from"./script-loader-9396ec24.js";import{aK as InputManager,D as DependencyInjectionAssignment,L as Logger,R as RapiAccess,ae as getGUI,_ as __decorate,i as inject,u as CANVAS_ID,x as DynamicLightSettingLoader,y as PREDEFINED_LIGHTSETTING,H as dispose,b as RoomleDependencyInjection}from"./roomle-dependency-injection-b0f42112.js";import{C as CameraControl3D,L as LightSetting,S as SceneManager,T as TWEEN_FILE_NAME}from"./camera-behaviour-b62c2673.js";import{a as Vector3,ad as Box3,ag as Euler,Q as Quaternion,A as AmbientLight,C as Color,aE as CAMERA_TYPE,aR as getGlbUrl,bv as WebGLRenderer,i as SRGBColorSpace,bj as BasicShadowMap,N as PerspectiveCamera,bC as download}from"./main-thread-to-worker-af604b88.js";import{D as DefaultLightSetting,J as JS_ZIP_FILE_NAME}from"./jszip.min-086ab68b.js";import{G as GlbViewerCameraBehaviour}from"./glb-viewer-camera-behaviour-9c8aa9e8.js";import"./query-params-helper-15c8e313.js";const INJECTABLES=[new DependencyInjectionAssignment("script-loader",ScriptLoader),new DependencyInjectionAssignment("glb-input-manager",class extends InputManager{},1),new DependencyInjectionAssignment("logger",Logger),new DependencyInjectionAssignment("rapi-access",RapiAccess)];class AdjustableCameraControl3D extends CameraControl3D{constructor(){super(...arguments),this.shouldIgnoreStandardBehavior=!1}adjust(e,t,r,a,i){let n=new Vector3(-e.x/2,0,-e.z/2),s=new Vector3(e.x/2,e.y,e.z/2);this._boundingBox=new Box3(n,s);let o=new Euler(-Math.PI/2+a,r,0,"ZYX"),c=(new Quaternion).setFromEuler(o);this._camera.updateProjectionMatrix(),this._camera.quaternion.copy(c),this._camera.position.copy(t)}_update(e){this.shouldIgnoreStandardBehavior?this._saveYawAndPitch():super._update(e)}animateCamera(e){return!!this.shouldIgnoreStandardBehavior||super.animateCamera(e)}}class GLBViewerLightSetting extends LightSetting{constructor(e,t){super(e,t),this._params={ambientLight:{color:"#ffffff"}},this._ambientLight=new AmbientLight(new Color(this._params.ambientLight.color),.5),this.addToScene()}addToScene(){this._scene.add(this._ambientLight)}removeFromScene(){this._scene.remove(this._ambientLight)}reload(){this.removeFromScene(),this.addToScene()}showGUI(){let e=getGUI();if(e&&this._ambientLight){let t=e.addFolder("Ambient Light");t.add(this._ambientLight,"visible"),t.add(this._ambientLight,"intensity").min(0).max(5).step(.1),t.addColor(this._params.ambientLight,"color").onChange(e=>{this._ambientLight.color=new Color(e)})}}}class GLBViewerSceneManager extends SceneManager{constructor(e,t){super(e,t,CANVAS_ID.GLB,CAMERA_TYPE.CAMERA_3D),this._itemsCount=0,this._standardSceneBackgroundColor=this._scene.background,this._initData.legacyLight&&(this._renderer.capabilities.maxTextures>8?this.loadDynamicLightSetting(DynamicLightSettingLoader.createDynamicLightSettingSource(null,PREDEFINED_LIGHTSETTING.CAMERA)):(console.warn("this device has a maximum of 8 texture units thus we are using a simpler light setting"),this._lightSetting=new GLBViewerLightSetting(this._scene)))}createCameraControl(e,t){this._changeCameraBehaviour(new GlbViewerCameraBehaviour(new AdjustableCameraControl3D(this._creator_,this._getInputManager(),new Vector3(-1,1,1)),this._cameraBehaviourState))}_getInputManager(){return this._glbInputManager}async loadStaticItem(e,t){const r=await this._rapiAccess.getItem(e);if(r.configuration)return Promise.reject();const a=getGlbUrl(r);return a?this.loadGLB(a,!0,void 0,t):Promise.reject(new Error("GLB Url not detected"))}loadGLB(e,t=!0,r=new Vector3(1,1,1),a){return this.clearScene(),new Promise((i,n)=>{this._loadGLB(e,new Vector3(0,0,0),0,void 0,r,void 0,void 0,a).then(e=>{this._currentGLB=e,this._scene.add(this._currentGLB);let r=(new Box3).setFromObject(this._currentGLB);t&&this.cameraBehaviour.cameraControl instanceof AdjustableCameraControl3D&&this.glbViewerCameraBehaviour.updateCameraOnItemLoaded(r),this._updateBounds(r,null,!0),i()},n)})}preparePerspectiveImage(e,t,r){return new Promise(a=>{var i,n;t||(t=1e3),r||(r=1e3),e||((e=new WebGLRenderer({antialias:!0})).setSize(t,r),e.outputColorSpace=SRGBColorSpace,e.autoClear=!1,e.shadowMap.enabled=!0,e.shadowMap.type=BasicShadowMap);let s=this.cameraBehaviour.cameraControl.getCamera().clone();s instanceof PerspectiveCamera&&(s.aspect=t/r,s.updateProjectionMatrix()),null===(i=this._lightSetting)||void 0===i||i.removeFromScene();let o=new DefaultLightSetting(this._scene);e.render(this._scene,s);let c=e.domElement.toDataURL();e.domElement.toBlob(e=>{a({image:c,width:t,height:r,blob:e})},"image/png"),o.removeFromScene(),null===(n=this._lightSetting)||void 0===n||n.addToScene()})}adjustCamera(e,t,r,a){if(this.cameraBehaviour.cameraControl instanceof AdjustableCameraControl3D){let i=(new Box3).setFromObject(this._scene).getSize(new Vector3);this.cameraBehaviour.cameraControl.adjust(i,e,t,r,a),this._requestRender()}}onStart(e){this._itemsCount=e,this._scene.background=null,this.cameraBehaviour.cameraControl instanceof AdjustableCameraControl3D&&(this.cameraBehaviour.cameraControl.shouldIgnoreStandardBehavior=!0)}onElementFinished(e){this._itemsCount,Math.round(100/this._itemsCount*e)}onFinished(e){this._scene.background=this._standardSceneBackgroundColor,this.cameraBehaviour.cameraControl instanceof AdjustableCameraControl3D&&(this.cameraBehaviour.cameraControl.shouldIgnoreStandardBehavior=!1)}clearScene(){this._currentGLB&&(this._scene.remove(this._currentGLB),dispose(this._currentGLB),this._currentGLB=null),super.clearScene()}enableHD(){super.enableHD()}sceneChanged(){}getBounds(){return this._currentGLB?(new Box3).setFromObject(this._currentGLB):null}get glbViewerCameraBehaviour(){return this.cameraBehaviour}getGeometryBounds(){return null}cameraBehaviourChanged(){super.cameraBehaviourChanged(),this.cameraBehaviour.cameraControl.addEventListener(3,()=>{this._requestRender()},this),this.cameraBehaviour.cameraControl.addEventListener(4,()=>{this._requestRender()},this)}}__decorate([inject],GLBViewerSceneManager.prototype,"_glbInputManager",void 0),__decorate([inject],GLBViewerSceneManager.prototype,"_rapiAccess",void 0);class GLBRenderWorker{constructor(e,t,r){this._prefix="https://furniture.roomle.com/3d/glb/",this._listeners=new Set,this._finishedItems=0,this._sceneManager=e,this._renderer=new WebGLRenderer({antialias:!0,alpha:!0}),this._width=t,this._height=r,this._renderer.setSize(t,r),this._renderer.setClearColor(16777215,0),this._renderer.outputColorSpace=SRGBColorSpace}addListener(e){this._listeners.add(e)}removeListener(e){this._listeners.delete(e)}start(e){return this._entries=[],e.forEach(e=>{this._entries.push(this._transform(e))}),this._finishedItems=0,this._listeners.forEach(e=>e.onStart(this._entries.length)),this._zip=new window.JSZip,this._doNextEntry(),new Promise(e=>{this._resolve=e})}_transform(e){return{name:e.path.replace(".glb",".png"),url:this._prefix+e.path,position:new Vector3(e.camera.position.x,e.camera.position.z,-e.camera.position.y),fov:2*e.camera.fieldOfView,yaw:e.camera.rotation.z,pitch:e.camera.rotation.x}}_doNextEntry(){0===this._entries.length?(this._listeners.forEach(e=>e.onFinished(this._zip)),this._resolve(this._zip)):this._processEntry(this._entries[0])}_processEntry(e){this._sceneManager.loadGLB(e.url,!1,void 0).then(()=>{this._sceneManager.adjustCamera(e.position,e.yaw,e.pitch,e.fov),this._sceneManager.preparePerspectiveImage(this._renderer,this._width,this._height).then(t=>{this._entryFinished(e,t)})})}_entryFinished(e,t){let r=this._entries.indexOf(e);r>-1&&this._entries.splice(r,1),this._finishedItems++,this._listeners.forEach(e=>e.onElementFinished(this._finishedItems)),this._zip.file(e.name,t.blob),this._doNextEntry()}}class RoomleGLBViewer{constructor(e){this._currentIdOrUrl=null,this._creator_=e}setCameraOffset(e){this._sceneManager.setCameraOffset(e)}getCameraOffset(){return this._sceneManager.getCameraOffset()}init(e,t){return this.setOverrides(t),this._domHelper.setDomElement(e),this._sceneManager?(this._lifeCycleManager.resume(),Promise.resolve()):new Promise(this._initPromiseCallback.bind(this))}_initPromiseCallback(e,t){Promise.all([this._scriptLoader.fetch(TWEEN_FILE_NAME,{id:"tween-js"})]).then(()=>{this._sceneManager=new GLBViewerSceneManager(this._creator_,{left:0,top:1,right:1,bottom:0}),this._sceneManager.enableHD(),e()})}clearScene(){this._sceneManager.clearScene()}loadGLB(e,t=1,r){return this._currentIdOrUrl=e,this._rapiAccess.trackView(e),this._sceneManager.loadGLB(e,!0,new Vector3(t,t,t),r)}loadStaticItem(e,t){return this._currentIdOrUrl=e,this._rapiAccess.trackView(e),this._sceneManager.loadStaticItem(e,t)}getCurrentId(){return this._currentIdOrUrl}loadSceneSetting(e){return this._sceneManager.loadSceneSettings(e)}preparePerspectiveImage(){return this._sceneManager.preparePerspectiveImage()}processRenderList(e,t=320,r=320){let a=JSON.parse(e);this._scriptLoader.fetch(JS_ZIP_FILE_NAME,{id:"jszip-js"}).then(()=>{let e=new GLBRenderWorker(this._sceneManager,t,r);e.addListener(this._sceneManager),e.start(a.items).then(t=>{t.generateAsync({type:"blob"}).then(t=>{download("content.zip",URL.createObjectURL(t)),e.removeListener(this._sceneManager)})})})}setOverrides(e){e&&(this._initData.setOverrides(e),this._globalInitData.setOverrides(e))}updateSize(){this._sceneManager.updateCamera()}getMain(){}resumeTest(e){this._domHelper.setDomElement(e),this._lifeCycleManager.resume()}pauseTest(){this._lifeCycleManager.pause()}showGUI(){this._sceneManager.showGUI()}get callbacks(){return{}}getScene(){return this._sceneManager.getScene()}updateScene(){this._sceneManager.updateScene()}getUnitFormatter(){return this._unitFormatter}getStorage(){return this._idbManager}setEnvironmentMap(e){const{url:t,intensity:r,rotation:a,maxLightSources:i}=e;this._sceneManager.setEnvironmentMap(t,r,a,i)}}__decorate([inject],RoomleGLBViewer.prototype,"_rapiAccess",void 0),__decorate([inject],RoomleGLBViewer.prototype,"_domHelper",void 0),__decorate([inject],RoomleGLBViewer.prototype,"_scriptLoader",void 0),__decorate([inject],RoomleGLBViewer.prototype,"_lifeCycleManager",void 0),__decorate([inject],RoomleGLBViewer.prototype,"_initData",void 0),__decorate([inject],RoomleGLBViewer.prototype,"_globalInitData",void 0),__decorate([inject],RoomleGLBViewer.prototype,"_unitFormatter",void 0),__decorate([inject],RoomleGLBViewer.prototype,"_idbManager",void 0);class GlbViewer extends Main{setupGlobals(){}setupDependencies(){RoomleDependencyInjection.setup(INJECTABLES),this.lookup("logger",this._context)}cleanUpGlobals(){throw new Error("Method not implemented.")}cleanUpDependencies(){throw new Error("Method not implemented.")}bootFinished(){this._viewer=new RoomleGLBViewer(this._context),window.RoomleGLBViewer||(window.RoomleGLBViewer=this._viewer)}getApi(){return this._viewer}getContextName(){return"glb-viewer"}}export{GlbViewer};
|
|
2
|
+
//# sourceMappingURL=glb-viewer-bac266f6.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"glb-viewer-bac266f6.js","sources":[],"sourcesContent":[],"names":[],"mappings":""}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
System.register(["./camera-behaviour-
|
|
2
|
-
//# sourceMappingURL=glb-viewer-camera-behaviour-
|
|
1
|
+
System.register(["./camera-behaviour-e7f9d0fc.nomodule.js"],(function(e){var t;return{setters:[function(e){t=e.b}],execute:function(){e("G",class extends t{get cameraControl(){return this._cameraControl}updateCameraOnItemLoaded(e){this.cameraControl.updateAndReset(e,!1)}})}}}));
|
|
2
|
+
//# sourceMappingURL=glb-viewer-camera-behaviour-89e58c94.nomodule.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"glb-viewer-camera-behaviour-89e58c94.nomodule.js","sources":[],"sourcesContent":[],"names":[],"mappings":""}
|
package/lib/{glb-viewer-camera-behaviour-65583e34.js → glb-viewer-camera-behaviour-9c8aa9e8.js}
RENAMED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{b as CameraBehaviour}from"./camera-behaviour-
|
|
2
|
-
//# sourceMappingURL=glb-viewer-camera-behaviour-
|
|
1
|
+
import{b as CameraBehaviour}from"./camera-behaviour-b62c2673.js";class GlbViewerCameraBehaviour extends CameraBehaviour{get cameraControl(){return this._cameraControl}updateCameraOnItemLoaded(a){this.cameraControl.updateAndReset(a,!1)}}export{GlbViewerCameraBehaviour as G};
|
|
2
|
+
//# sourceMappingURL=glb-viewer-camera-behaviour-9c8aa9e8.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"glb-viewer-camera-behaviour-9c8aa9e8.js","sources":[],"sourcesContent":[],"names":[],"mappings":""}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{GlbViewer}from"./glb-viewer-bac266f6.js";import"./script-loader-9396ec24.js";import"./query-params-helper-15c8e313.js";import"./main-thread-to-worker-af604b88.js";import"./roomle-dependency-injection-b0f42112.js";import"./camera-behaviour-b62c2673.js";import"./jszip.min-086ab68b.js";import"./glb-viewer-camera-behaviour-9c8aa9e8.js";(new GlbViewer).boot();
|
|
2
|
+
//# sourceMappingURL=glb-viewer-main-93b7b987.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"glb-viewer-main-93b7b987.js","sources":[],"sourcesContent":[],"names":[],"mappings":""}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
System.register(["./glb-viewer-
|
|
1
|
+
System.register(["./glb-viewer-447286f6.nomodule.js","./script-loader-eb097908.nomodule.js","./query-params-helper-ff314078.nomodule.js","./main-thread-to-worker-a33146dd.nomodule.js","./roomle-dependency-injection-11d4372b.nomodule.js","./camera-behaviour-e7f9d0fc.nomodule.js","./jszip.min-d3d3c14a.nomodule.js","./glb-viewer-camera-behaviour-89e58c94.nomodule.js"],(function(){var e;return{setters:[function(n){e=n.GlbViewer},function(){},function(){},function(){},function(){},function(){},function(){},function(){}],execute:function(){(new e).boot()}}}));
|
|
2
2
|
//# sourceMappingURL=glb-viewer-main.nomodule.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{L as LightSetting}from"./camera-behaviour-
|
|
2
|
-
//# sourceMappingURL=
|
|
1
|
+
import{L as LightSetting}from"./camera-behaviour-b62c2673.js";import{ae as getGUI}from"./roomle-dependency-injection-b0f42112.js";import{D as DirectionalLight,C as Color,V as Vector2,a as Vector3,A as AmbientLight}from"./main-thread-to-worker-af604b88.js";class DefaultLightSetting extends LightSetting{constructor(i,t){super(i,t),this._params={ambientLight:{color:"#ffffff"},mainDirLight:{position:{x:-3,y:4,z:4},color:"#ffffff"},secondDirLight:{position:{x:3,y:4,z:3},color:"#ffffff"}},this._mainDirectionalLight=new DirectionalLight(new Color(this._params.mainDirLight.color),.8),this._mainDirectionalLight.position.set(this._params.mainDirLight.position.x,this._params.mainDirLight.position.y,this._params.mainDirLight.position.z),this._mainDirectionalLight.layers.set(1),this._mainDirectionalLight.castShadow=!0,this._mainDirectionalLight.shadow.camera.near=.1,this._mainDirectionalLight.shadow.camera.far=100,this._mainDirectionalLight.shadow.mapSize=new Vector2(1024,1024),this._mainDirectionalLight.visible=!0,this._mainDirectionalLight.lookAt(new Vector3(0,0,0)),this._secondDirectionalLight=new DirectionalLight(new Color(this._params.secondDirLight.color),.2),this._secondDirectionalLight.position.set(this._params.secondDirLight.position.x,this._params.secondDirLight.position.y,this._params.secondDirLight.position.z),this._secondDirectionalLight.layers.set(1),this._secondDirectionalLight.castShadow=!1,this._secondDirectionalLight.shadow.camera.near=.1,this._secondDirectionalLight.shadow.camera.far=100,this._secondDirectionalLight.shadow.mapSize=new Vector2(1024,1024),this._secondDirectionalLight.visible=!0,this._secondDirectionalLight.lookAt(new Vector3(0,0,0)),this._ambientLight=new AmbientLight(new Color(this._params.ambientLight.color),.5),this._ambientLight.layers.set(1),this.addToScene()}needsBounds(){return!0}updateBounds(i){const t=i.getSize(new Vector3),a=Math.max(Math.max(t.x,t.y),t.z)+1,o=a/2;this._mainDirectionalLight.shadow.camera.top=o,this._mainDirectionalLight.shadow.camera.bottom=-o,this._mainDirectionalLight.shadow.camera.left=-o,this._mainDirectionalLight.shadow.camera.right=o,this._mainDirectionalLight.shadow.camera.near=.01,this._mainDirectionalLight.shadow.camera.far=4*a,this._mainDirectionalLight.shadow.camera.updateProjectionMatrix(),this._secondDirectionalLight.shadow.camera.top=o,this._secondDirectionalLight.shadow.camera.bottom=-o,this._secondDirectionalLight.shadow.camera.left=-o,this._secondDirectionalLight.shadow.camera.right=o,this._secondDirectionalLight.shadow.camera.near=.01,this._secondDirectionalLight.shadow.camera.far=4*a,this._secondDirectionalLight.shadow.camera.updateProjectionMatrix()}addToScene(){this._scene.add(this._mainDirectionalLight),this._scene.add(this._secondDirectionalLight),this._scene.add(this._ambientLight)}removeFromScene(){this._scene.remove(this._mainDirectionalLight),this._scene.remove(this._secondDirectionalLight),this._scene.remove(this._ambientLight)}reload(){this.removeFromScene(),this.addToScene()}showGUI(){let i=getGUI();if(i){if(this._ambientLight){let t=i.addFolder("Ambient Light");t.add(this._ambientLight,"visible"),t.add(this._ambientLight,"intensity").min(0).max(5).step(.1),t.addColor(this._params.ambientLight,"color").onChange(i=>this._ambientLight.color=new Color(i))}if(this._mainDirectionalLight){let t=i.addFolder("Main Directional Light");t.add(this._mainDirectionalLight,"visible"),t.add(this._mainDirectionalLight,"intensity").min(0).max(10).step(.1),t.add(this._mainDirectionalLight,"castShadow"),t.addColor(this._params.mainDirLight,"color").onChange(i=>this._mainDirectionalLight.color=new Color(i)),t.add(this._mainDirectionalLight.position,"x").min(-10).max(10).step(.1).onChange(()=>this._mainDirectionalLight.lookAt(new Vector3(0,0,0))),t.add(this._mainDirectionalLight.position,"y").min(-10).max(50).step(.1).onChange(()=>this._mainDirectionalLight.lookAt(new Vector3(0,0,0))),t.add(this._mainDirectionalLight.position,"z").min(-10).max(10).step(.1).onChange(()=>this._mainDirectionalLight.lookAt(new Vector3(0,0,0)))}if(this._secondDirectionalLight){let t=i.addFolder("Second Directional Light");t.add(this._secondDirectionalLight,"visible"),t.add(this._secondDirectionalLight,"intensity").min(0).max(10).step(.1),t.add(this._secondDirectionalLight,"castShadow"),t.addColor(this._params.mainDirLight,"color").onChange(i=>this._mainDirectionalLight.color=new Color(i)),t.add(this._secondDirectionalLight.position,"x").min(-10).max(10).step(.1).onChange(()=>this._mainDirectionalLight.lookAt(new Vector3(0,0,0))),t.add(this._secondDirectionalLight.position,"y").min(-10).max(50).step(.1).onChange(()=>this._mainDirectionalLight.lookAt(new Vector3(0,0,0))),t.add(this._secondDirectionalLight.position,"z").min(-10).max(10).step(.1).onChange(()=>this._mainDirectionalLight.lookAt(new Vector3(0,0,0)))}}}}var JS_ZIP_FILE_NAME="static/jszip.min-c96375d50e72b199.js";export{DefaultLightSetting as D,JS_ZIP_FILE_NAME as J};
|
|
2
|
+
//# sourceMappingURL=jszip.min-086ab68b.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"jszip.min-086ab68b.js","sources":["../../node_modules/jszip/dist/jszip.min.js"],"sourcesContent":["export default \"static/jszip.min-c96375d50e72b199.js\""],"names":["JS_ZIP_FILE_NAME"],"mappings":"ouJAAA,IAAeA,iBAAA"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
System.register(["./camera-behaviour-
|
|
2
|
-
//# sourceMappingURL=
|
|
1
|
+
System.register(["./camera-behaviour-e7f9d0fc.nomodule.js","./roomle-dependency-injection-11d4372b.nomodule.js","./main-thread-to-worker-a33146dd.nomodule.js"],(function(i){var t,a,e,n,o,s,h;return{setters:[function(i){t=i.L},function(i){a=i.ae},function(i){e=i.D,n=i.C,o=i.V,s=i.a,h=i.A}],execute:function(){i("D",class extends t{constructor(i,t){super(i,t),this._params={ambientLight:{color:"#ffffff"},mainDirLight:{position:{x:-3,y:4,z:4},color:"#ffffff"},secondDirLight:{position:{x:3,y:4,z:3},color:"#ffffff"}},this._mainDirectionalLight=new e(new n(this._params.mainDirLight.color),.8),this._mainDirectionalLight.position.set(this._params.mainDirLight.position.x,this._params.mainDirLight.position.y,this._params.mainDirLight.position.z),this._mainDirectionalLight.layers.set(1),this._mainDirectionalLight.castShadow=!0,this._mainDirectionalLight.shadow.camera.near=.1,this._mainDirectionalLight.shadow.camera.far=100,this._mainDirectionalLight.shadow.mapSize=new o(1024,1024),this._mainDirectionalLight.visible=!0,this._mainDirectionalLight.lookAt(new s(0,0,0)),this._secondDirectionalLight=new e(new n(this._params.secondDirLight.color),.2),this._secondDirectionalLight.position.set(this._params.secondDirLight.position.x,this._params.secondDirLight.position.y,this._params.secondDirLight.position.z),this._secondDirectionalLight.layers.set(1),this._secondDirectionalLight.castShadow=!1,this._secondDirectionalLight.shadow.camera.near=.1,this._secondDirectionalLight.shadow.camera.far=100,this._secondDirectionalLight.shadow.mapSize=new o(1024,1024),this._secondDirectionalLight.visible=!0,this._secondDirectionalLight.lookAt(new s(0,0,0)),this._ambientLight=new h(new n(this._params.ambientLight.color),.5),this._ambientLight.layers.set(1),this.addToScene()}needsBounds(){return!0}updateBounds(i){const t=i.getSize(new s),a=Math.max(Math.max(t.x,t.y),t.z)+1,e=a/2;this._mainDirectionalLight.shadow.camera.top=e,this._mainDirectionalLight.shadow.camera.bottom=-e,this._mainDirectionalLight.shadow.camera.left=-e,this._mainDirectionalLight.shadow.camera.right=e,this._mainDirectionalLight.shadow.camera.near=.01,this._mainDirectionalLight.shadow.camera.far=4*a,this._mainDirectionalLight.shadow.camera.updateProjectionMatrix(),this._secondDirectionalLight.shadow.camera.top=e,this._secondDirectionalLight.shadow.camera.bottom=-e,this._secondDirectionalLight.shadow.camera.left=-e,this._secondDirectionalLight.shadow.camera.right=e,this._secondDirectionalLight.shadow.camera.near=.01,this._secondDirectionalLight.shadow.camera.far=4*a,this._secondDirectionalLight.shadow.camera.updateProjectionMatrix()}addToScene(){this._scene.add(this._mainDirectionalLight),this._scene.add(this._secondDirectionalLight),this._scene.add(this._ambientLight)}removeFromScene(){this._scene.remove(this._mainDirectionalLight),this._scene.remove(this._secondDirectionalLight),this._scene.remove(this._ambientLight)}reload(){this.removeFromScene(),this.addToScene()}showGUI(){let i=a();if(i){if(this._ambientLight){let t=i.addFolder("Ambient Light");t.add(this._ambientLight,"visible"),t.add(this._ambientLight,"intensity").min(0).max(5).step(.1),t.addColor(this._params.ambientLight,"color").onChange(i=>this._ambientLight.color=new n(i))}if(this._mainDirectionalLight){let t=i.addFolder("Main Directional Light");t.add(this._mainDirectionalLight,"visible"),t.add(this._mainDirectionalLight,"intensity").min(0).max(10).step(.1),t.add(this._mainDirectionalLight,"castShadow"),t.addColor(this._params.mainDirLight,"color").onChange(i=>this._mainDirectionalLight.color=new n(i)),t.add(this._mainDirectionalLight.position,"x").min(-10).max(10).step(.1).onChange(()=>this._mainDirectionalLight.lookAt(new s(0,0,0))),t.add(this._mainDirectionalLight.position,"y").min(-10).max(50).step(.1).onChange(()=>this._mainDirectionalLight.lookAt(new s(0,0,0))),t.add(this._mainDirectionalLight.position,"z").min(-10).max(10).step(.1).onChange(()=>this._mainDirectionalLight.lookAt(new s(0,0,0)))}if(this._secondDirectionalLight){let t=i.addFolder("Second Directional Light");t.add(this._secondDirectionalLight,"visible"),t.add(this._secondDirectionalLight,"intensity").min(0).max(10).step(.1),t.add(this._secondDirectionalLight,"castShadow"),t.addColor(this._params.mainDirLight,"color").onChange(i=>this._mainDirectionalLight.color=new n(i)),t.add(this._secondDirectionalLight.position,"x").min(-10).max(10).step(.1).onChange(()=>this._mainDirectionalLight.lookAt(new s(0,0,0))),t.add(this._secondDirectionalLight.position,"y").min(-10).max(50).step(.1).onChange(()=>this._mainDirectionalLight.lookAt(new s(0,0,0))),t.add(this._secondDirectionalLight.position,"z").min(-10).max(10).step(.1).onChange(()=>this._mainDirectionalLight.lookAt(new s(0,0,0)))}}}}),i("J","static/jszip.min-c96375d50e72b199.js")}}}));
|
|
2
|
+
//# sourceMappingURL=jszip.min-d3d3c14a.nomodule.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"jszip.min-d3d3c14a.nomodule.js","sources":["../../node_modules/jszip/dist/jszip.min.js"],"sourcesContent":["export default \"static/jszip.min-c96375d50e72b199.js\""],"names":["exports"],"mappings":"0nJAAeA,EAAA,IAAA"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
System.register(["./main-thread-to-worker-
|
|
2
|
-
//# sourceMappingURL=TextGeometry-
|
|
1
|
+
System.register(["./main-thread-to-worker-f02de9c2.legacy.js"],(function(e){var t,i,n,h,o,r;return{setters:[function(e){t=e._,i=e.e,n=e.f,h=e.c0,o=e.h,r=e.c1}],execute:function(){e("T",function(e){t(d,e);var r=i(d);function d(e){var t,i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};n(this,d);var o=i.font;if(void 0===o)t=r.call(this);else{var s=o.generateShapes(e,i.size);void 0===i.depth&&void 0!==i.height&&console.warn("THREE.TextGeometry: .height is now depreciated. Please use .depth instead"),i.depth=void 0!==i.depth?i.depth:void 0!==i.height?i.height:50,void 0===i.bevelThickness&&(i.bevelThickness=10),void 0===i.bevelSize&&(i.bevelSize=8),void 0===i.bevelEnabled&&(i.bevelEnabled=!1),t=r.call(this,s,i)}return t.type="TextGeometry",h(t)}return o(d)}(r))}}}));
|
|
2
|
+
//# sourceMappingURL=TextGeometry-50d12ddd.legacy.js.map
|