@thatopen/components 3.2.5 → 3.2.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.cjs +26 -19
- package/dist/index.d.ts +11 -7
- package/dist/index.min.cjs +2 -2
- package/dist/index.min.mjs +2 -2
- package/dist/index.mjs +26 -19
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -3540,8 +3540,8 @@ const _IfcLoader = class _IfcLoader extends Component {
|
|
|
3540
3540
|
* Loads an IFC file and processes it for 3D visualization.
|
|
3541
3541
|
*
|
|
3542
3542
|
* @param data - The Uint8Array containing the IFC file data.
|
|
3543
|
-
* @param coordinate -
|
|
3544
|
-
* @param name -
|
|
3543
|
+
* @param coordinate - Boolean indicating whether to coordinate the loaded IFC data. Default is true.
|
|
3544
|
+
* @param name - Name for the fragments model.
|
|
3545
3545
|
* @param config - Optional extra data for loading the IFC.
|
|
3546
3546
|
*
|
|
3547
3547
|
* @returns A Promise that resolves to the FragmentsModel containing the loaded and processed IFC data.
|
|
@@ -11969,6 +11969,14 @@ class OrthoPerspectiveCamera extends SimpleCamera {
|
|
|
11969
11969
|
this.disableUserInput();
|
|
11970
11970
|
}
|
|
11971
11971
|
}
|
|
11972
|
+
/**
|
|
11973
|
+
* Adds a custom {@link NavigationMode} to the camera that can be used using the {@link OrthoPerspectiveCamera.set} method.
|
|
11974
|
+
*
|
|
11975
|
+
* @param mode - The custom {@link NavigationMode} to add.
|
|
11976
|
+
*/
|
|
11977
|
+
addCustomNavigationMode(mode) {
|
|
11978
|
+
this._navigationModes.set(mode.id, mode);
|
|
11979
|
+
}
|
|
11972
11980
|
disableUserInput() {
|
|
11973
11981
|
this._userInputButtons.left = this.controls.mouseButtons.left;
|
|
11974
11982
|
this._userInputButtons.right = this.controls.mouseButtons.right;
|
|
@@ -17624,6 +17632,7 @@ const _Clipper = class _Clipper extends Component {
|
|
|
17624
17632
|
plane.world.renderer.setPlane(false, plane.three);
|
|
17625
17633
|
plane.dispose();
|
|
17626
17634
|
this.updateMaterialsAndPlanes();
|
|
17635
|
+
this.onAfterDelete.trigger(plane);
|
|
17627
17636
|
});
|
|
17628
17637
|
}
|
|
17629
17638
|
/** {@link Disposable.dispose} */
|
|
@@ -20802,7 +20811,7 @@ class IDSSpecification {
|
|
|
20802
20811
|
return xml;
|
|
20803
20812
|
}
|
|
20804
20813
|
}
|
|
20805
|
-
const getParameterValue = (property
|
|
20814
|
+
const getParameterValue = (property) => {
|
|
20806
20815
|
if (!property)
|
|
20807
20816
|
return void 0;
|
|
20808
20817
|
const result = {};
|
|
@@ -20820,7 +20829,13 @@ const getParameterValue = (property, parseNumericString = true) => {
|
|
|
20820
20829
|
if ("enumeration" in restriction) {
|
|
20821
20830
|
result.type = "enumeration";
|
|
20822
20831
|
const enumeration = restriction.enumeration.map(
|
|
20823
|
-
({ value }) =>
|
|
20832
|
+
({ value }) => {
|
|
20833
|
+
if (restriction.base.includes("string"))
|
|
20834
|
+
return String(value);
|
|
20835
|
+
if (restriction.base.includes("integer") || restriction.base.includes("double"))
|
|
20836
|
+
return Number(value);
|
|
20837
|
+
return value;
|
|
20838
|
+
}
|
|
20824
20839
|
);
|
|
20825
20840
|
result.parameter = enumeration;
|
|
20826
20841
|
}
|
|
@@ -20914,19 +20929,19 @@ const createMaterialFacets = (components, elements) => {
|
|
|
20914
20929
|
}
|
|
20915
20930
|
return facets;
|
|
20916
20931
|
};
|
|
20917
|
-
const createPropertyFacets = (components, elements
|
|
20932
|
+
const createPropertyFacets = (components, elements) => {
|
|
20918
20933
|
const facets = [];
|
|
20919
20934
|
for (const element of elements) {
|
|
20920
20935
|
const psetParameter = element.propertySet;
|
|
20921
20936
|
const baseNameParameter = element.baseName;
|
|
20922
|
-
const pset = getParameterValue(psetParameter
|
|
20923
|
-
const baseName = getParameterValue(baseNameParameter
|
|
20937
|
+
const pset = getParameterValue(psetParameter);
|
|
20938
|
+
const baseName = getParameterValue(baseNameParameter);
|
|
20924
20939
|
if (!(baseName && pset))
|
|
20925
20940
|
continue;
|
|
20926
20941
|
const facet = new IDSProperty(components, pset, baseName);
|
|
20927
20942
|
if (element.cardinality)
|
|
20928
20943
|
facet.cardinality = element.cardinality;
|
|
20929
|
-
const value = getParameterValue(element.value
|
|
20944
|
+
const value = getParameterValue(element.value);
|
|
20930
20945
|
facet.value = value;
|
|
20931
20946
|
facet.dataType = element.dataType;
|
|
20932
20947
|
facet.uri = element.uri;
|
|
@@ -21037,7 +21052,7 @@ const _IDSSpecifications = class _IDSSpecifications extends Component {
|
|
|
21037
21052
|
*
|
|
21038
21053
|
* @returns An array of IDSSpecification instances created from the parsed data.
|
|
21039
21054
|
*/
|
|
21040
|
-
load(data
|
|
21055
|
+
load(data) {
|
|
21041
21056
|
const result = [];
|
|
21042
21057
|
const ids = _IDSSpecifications.xmlParser.parse(data).ids;
|
|
21043
21058
|
const { specifications, info } = ids;
|
|
@@ -21077,11 +21092,7 @@ const _IDSSpecifications = class _IDSSpecifications extends Component {
|
|
|
21077
21092
|
applicabilities.push(...facets2);
|
|
21078
21093
|
}
|
|
21079
21094
|
if (facetName === "property") {
|
|
21080
|
-
const facets2 = createPropertyFacets(
|
|
21081
|
-
this.components,
|
|
21082
|
-
elements,
|
|
21083
|
-
config.parseNumericString
|
|
21084
|
-
);
|
|
21095
|
+
const facets2 = createPropertyFacets(this.components, elements);
|
|
21085
21096
|
applicabilities.push(...facets2);
|
|
21086
21097
|
}
|
|
21087
21098
|
if (facetName === "partOf") {
|
|
@@ -21119,11 +21130,7 @@ const _IDSSpecifications = class _IDSSpecifications extends Component {
|
|
|
21119
21130
|
reqs.push(...facets2);
|
|
21120
21131
|
}
|
|
21121
21132
|
if (facetName === "property") {
|
|
21122
|
-
const facets2 = createPropertyFacets(
|
|
21123
|
-
this.components,
|
|
21124
|
-
elements,
|
|
21125
|
-
config.parseNumericString
|
|
21126
|
-
);
|
|
21133
|
+
const facets2 = createPropertyFacets(this.components, elements);
|
|
21127
21134
|
reqs.push(...facets2);
|
|
21128
21135
|
}
|
|
21129
21136
|
if (facetName === "partOf") {
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@thatopen/components",
|
|
3
3
|
"description": "Collection of core functionalities to author BIM apps.",
|
|
4
|
-
"version": "3.2.
|
|
4
|
+
"version": "3.2.7",
|
|
5
5
|
"author": "That Open Company",
|
|
6
6
|
"contributors": [
|
|
7
7
|
"Antonio Gonzalez Viegas (https://github.com/agviegas)",
|