@thatopen/components 2.1.22 → 2.1.23

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.mjs CHANGED
@@ -5,7 +5,7 @@ import * as A from "three";
5
5
  import { BufferAttribute as yn, Vector3 as M, Vector2 as fe, Plane as Ai, Line3 as yt, Triangle as ue, Sphere as jn, Matrix4 as Pt, Box3 as gt, BackSide as qn, DoubleSide as Pn, FrontSide as Mi, Mesh as v, Ray as Kn, Raycaster as $n, Quaternion as Lt, Object3D as ri, Euler as Jn, MeshBasicMaterial as wn, LineBasicMaterial as to, CylinderGeometry as ct, BoxGeometry as rt, BufferGeometry as Di, Float32BufferAttribute as Ui, OctahedronGeometry as Ze, Line as Dt, SphereGeometry as eo, TorusGeometry as Re, PlaneGeometry as so } from "three";
6
6
  import * as Vt from "@thatopen/fragments";
7
7
  import { Serializer as io } from "@thatopen/fragments";
8
- import * as U from "web-ifc";
8
+ import * as D from "web-ifc";
9
9
  const Mn = 0, no = 1, oo = 2, xi = 2, Ys = 1.25, bi = 1, Cs = 6 * 4 + 4 + 4, Us = 65535, ro = Math.pow(2, -24), Vs = Symbol("SKIP_GENERATION");
10
10
  function ao(l) {
11
11
  return l.index ? l.index.count : l.attributes.position.count;
@@ -97,8 +97,8 @@ function Gs(l, s, t, e, i = null) {
97
97
  for (let F = s * 6, g = (s + t) * 6; F < g; F += 6) {
98
98
  const p = l[F + 0], m = l[F + 1], O = p - m, S = p + m;
99
99
  O < o && (o = O), S > a && (a = S), T && p < E && (E = p), T && p > f && (f = p);
100
- const _ = l[F + 2], N = l[F + 3], y = _ - N, D = _ + N;
101
- y < n && (n = y), D > c && (c = D), T && _ < d && (d = _), T && _ > C && (C = _);
100
+ const _ = l[F + 2], N = l[F + 3], y = _ - N, U = _ + N;
101
+ y < n && (n = y), U > c && (c = U), T && _ < d && (d = _), T && _ > C && (C = _);
102
102
  const P = l[F + 4], x = l[F + 5], b = P - x, B = P + x;
103
103
  b < r && (r = b), B > h && (h = B), T && P < I && (I = P), T && P > R && (R = P);
104
104
  }
@@ -192,9 +192,9 @@ function po(l, s, t, e, i, o) {
192
192
  const m = T[p], O = m.count, S = i - m.count, _ = m.leftCacheBounds, N = m.rightCacheBounds;
193
193
  let y = 0;
194
194
  O !== 0 && (y = Fe(_) / a);
195
- let D = 0;
196
- S !== 0 && (D = Fe(N) / a);
197
- const P = bi + Ys * (y * O + D * S);
195
+ let U = 0;
196
+ S !== 0 && (U = Fe(N) / a);
197
+ const P = bi + Ys * (y * O + U * S);
198
198
  P < c && (n = d, c = P, r = m.candidate);
199
199
  }
200
200
  } else {
@@ -223,9 +223,9 @@ function po(l, s, t, e, i, o) {
223
223
  m !== 0 && (F === 0 ? Bi(O, je) : Yi(O, je, je)), F += m;
224
224
  let N = 0, y = 0;
225
225
  F !== 0 && (N = Fe(je) / a);
226
- const D = i - F;
227
- D !== 0 && (y = Fe(_) / a);
228
- const P = bi + Ys * (N * F + y * D);
226
+ const U = i - F;
227
+ U !== 0 && (y = Fe(_) / a);
228
+ const P = bi + Ys * (N * F + y * U);
229
229
  P < c && (n = d, c = P, r = p.candidate);
230
230
  }
231
231
  }
@@ -319,8 +319,8 @@ function Fo(l, s) {
319
319
  F(m + O), p.offset = m, p.count = O;
320
320
  else {
321
321
  p.splitAxis = N.axis;
322
- const D = new qe(), P = m, x = y - m;
323
- p.left = D, D.boundingData = new Float32Array(6), Gs(f, P, x, D.boundingData, I), g(D, P, x, I, _ + 1);
322
+ const U = new qe(), P = m, x = y - m;
323
+ p.left = U, U.boundingData = new Float32Array(6), Gs(f, P, x, U.boundingData, I), g(U, P, x, I, _ + 1);
324
324
  const b = new qe(), B = y, H = O - x;
325
325
  p.right = b, b.boundingData = new Float32Array(6), Gs(f, B, H, b.boundingData, I), g(b, B, H, I, _ + 1);
326
326
  }
@@ -521,21 +521,21 @@ At.prototype.intersectsTriangle = function() {
521
521
  const m = this.satBounds, O = this.satAxes;
522
522
  t[0] = R.a, t[1] = R.b, t[2] = R.c;
523
523
  for (let N = 0; N < 4; N++) {
524
- const y = m[N], D = O[N];
525
- if (e.setFromPoints(D, t), y.isSeparated(e))
524
+ const y = m[N], U = O[N];
525
+ if (e.setFromPoints(U, t), y.isSeparated(e))
526
526
  return !1;
527
527
  }
528
528
  const S = R.satBounds, _ = R.satAxes;
529
529
  s[0] = this.a, s[1] = this.b, s[2] = this.c;
530
530
  for (let N = 0; N < 4; N++) {
531
- const y = S[N], D = _[N];
532
- if (e.setFromPoints(D, s), y.isSeparated(e))
531
+ const y = S[N], U = _[N];
532
+ if (e.setFromPoints(U, s), y.isSeparated(e))
533
533
  return !1;
534
534
  }
535
535
  for (let N = 0; N < 4; N++) {
536
536
  const y = O[N];
537
- for (let D = 0; D < 4; D++) {
538
- const P = _[D];
537
+ for (let U = 0; U < 4; U++) {
538
+ const P = _[U];
539
539
  if (o.crossVectors(y, P), e.setFromPoints(o, s), i.setFromPoints(o, t), e.isSeparated(i))
540
540
  return !1;
541
541
  }
@@ -556,8 +556,8 @@ At.prototype.intersectsTriangle = function() {
556
556
  let x = d.start;
557
557
  d.start = d.end, d.end = x;
558
558
  }
559
- const S = E.start.dot(r), _ = E.end.dot(r), N = d.start.dot(r), y = d.end.dot(r), D = _ < N, P = S < y;
560
- return S !== y && N !== _ && D === P ? !1 : (T && (c.subVectors(E.start, d.start), c.dot(r) > 0 ? T.start.copy(E.start) : T.start.copy(d.start), c.subVectors(E.end, d.end), c.dot(r) < 0 ? T.end.copy(E.end) : T.end.copy(d.end)), !0);
559
+ const S = E.start.dot(r), _ = E.end.dot(r), N = d.start.dot(r), y = d.end.dot(r), U = _ < N, P = S < y;
560
+ return S !== y && N !== _ && U === P ? !1 : (T && (c.subVectors(E.start, d.start), c.dot(r) > 0 ? T.start.copy(E.start) : T.start.copy(d.start), c.subVectors(E.end, d.end), c.dot(r) < 0 ? T.end.copy(E.end) : T.end.copy(d.end)), !0);
561
561
  }
562
562
  };
563
563
  }();
@@ -697,8 +697,8 @@ at.prototype.distanceToBox = function() {
697
697
  for (let F = 0; F <= 1; F++) {
698
698
  const g = (R + 1) % 3, p = (R + 2) % 3, m = T << g | F << p, O = 1 << R | T << g | F << p, S = I[m], _ = I[O];
699
699
  s[C].set(S, _);
700
- const y = l[R], D = l[g], P = l[p], x = t[C], b = x.start, B = x.end;
701
- b[y] = E[y], b[D] = T ? E[D] : d[D], b[P] = F ? E[P] : d[D], B[y] = d[y], B[D] = T ? E[D] : d[D], B[P] = F ? E[P] : d[D], C++;
700
+ const y = l[R], U = l[g], P = l[p], x = t[C], b = x.start, B = x.end;
701
+ b[y] = E[y], b[U] = T ? E[U] : d[U], b[P] = F ? E[P] : d[U], B[y] = d[y], B[U] = T ? E[U] : d[U], B[P] = F ? E[P] : d[U], C++;
702
702
  }
703
703
  for (let R = 0; R <= 1; R++)
704
704
  for (let T = 0; T <= 1; T++)
@@ -792,7 +792,7 @@ function ai(l, s, t, e, i = null, o = 0, n = 0) {
792
792
  for (; !dt(B, x); )
793
793
  P = pt(P), B = P * 2;
794
794
  return Et(P, b);
795
- }, D = function(P) {
795
+ }, U = function(P) {
796
796
  const { uint16Array: x, uint32Array: b } = Z;
797
797
  let B = P * 2;
798
798
  for (; !dt(B, x); )
@@ -810,7 +810,7 @@ function ai(l, s, t, e, i = null, o = 0, n = 0) {
810
810
  const p = dt(f * 2, a), m = t(F, p, R, n + 1, o + f);
811
811
  let O;
812
812
  if (m === xi) {
813
- const P = y(f), b = D(f) - P;
813
+ const P = y(f), b = U(f) - P;
814
814
  O = e(P, b, !0, n + 1, o + f, F);
815
815
  } else
816
816
  O = m && ai(
@@ -828,7 +828,7 @@ function ai(l, s, t, e, i = null, o = 0, n = 0) {
828
828
  const S = dt(C * 2, a), _ = t(g, S, T, n + 1, o + C);
829
829
  let N;
830
830
  if (_ === xi) {
831
- const P = y(C), b = D(C) - P;
831
+ const P = y(C), b = U(C) - P;
832
832
  N = e(P, b, !0, n + 1, o + C, g);
833
833
  } else
834
834
  N = _ && ai(
@@ -935,8 +935,8 @@ function xo(l, s = null) {
935
935
  const T = n[d + 6], F = r[C + 14];
936
936
  let g = 1 / 0, p = 1 / 0, m = 1 / 0, O = -1 / 0, S = -1 / 0, _ = -1 / 0;
937
937
  for (let N = 3 * T, y = 3 * (T + F); N < y; N++) {
938
- let D = e[N];
939
- const P = i.getX(D), x = i.getY(D), b = i.getZ(D);
938
+ let U = e[N];
939
+ const P = i.getX(U), x = i.getY(U), b = i.getZ(U);
940
940
  P < g && (g = P), P > O && (O = P), x < p && (p = x), x > S && (S = x), b < m && (m = b), b > _ && (_ = b);
941
941
  }
942
942
  return a[d + 0] !== g || a[d + 1] !== p || a[d + 2] !== m || a[d + 3] !== O || a[d + 4] !== S || a[d + 5] !== _ ? (a[d + 0] = g, a[d + 1] = p, a[d + 2] = m, a[d + 3] = O, a[d + 4] = S, a[d + 5] = _, !0) : !1;
@@ -947,9 +947,9 @@ function xo(l, s = null) {
947
947
  const _ = m || O, N = m || S;
948
948
  let y = !1;
949
949
  _ && (y = E(T, I, m));
950
- let D = !1;
951
- N && (D = E(F, I, m));
952
- const P = y || D;
950
+ let U = !1;
951
+ N && (U = E(F, I, m));
952
+ const P = y || U;
953
953
  if (P)
954
954
  for (let x = 0; x < 3; x++) {
955
955
  const b = T + x, B = F + x, H = a[b], q = a[b + 3], st = a[B], Q = a[B + 3];
@@ -1083,7 +1083,7 @@ function Zo(l, s, t, e = {}, i = {}, o = 0, n = 1 / 0) {
1083
1083
  boundsTraverseOrder: (_) => Oe.distanceToBox(_),
1084
1084
  intersectsBounds: (_, N, y) => y < F && y < n,
1085
1085
  intersectsRange: (_, N) => {
1086
- for (let y = _, D = _ + N; y < D; y++) {
1086
+ for (let y = _, U = _ + N; y < U; y++) {
1087
1087
  tt(I, 3 * y, E, h), I.a.applyMatrix4(t), I.b.applyMatrix4(t), I.c.applyMatrix4(t), I.needsUpdate = !0;
1088
1088
  for (let P = m, x = m + O; P < x; P++) {
1089
1089
  tt(d, 3 * P, c, a), d.needsUpdate = !0;
@@ -1098,7 +1098,7 @@ function Zo(l, s, t, e = {}, i = {}, o = 0, n = 1 / 0) {
1098
1098
  const S = Ce(s);
1099
1099
  for (let _ = 0, N = S; _ < N; _++) {
1100
1100
  tt(I, 3 * _, E, h), I.a.applyMatrix4(t), I.b.applyMatrix4(t), I.c.applyMatrix4(t), I.needsUpdate = !0;
1101
- for (let y = m, D = m + O; y < D; y++) {
1101
+ for (let y = m, U = m + O; y < U; y++) {
1102
1102
  tt(d, 3 * y, c, a), d.needsUpdate = !0;
1103
1103
  const P = d.distanceToTriangle(I, f, R);
1104
1104
  if (P < F && (C.copy(f), T && T.copy(R), F = P, g = y, p = _), P < o)
@@ -1123,9 +1123,9 @@ function Qo(l, s = null) {
1123
1123
  const T = n[d + 6], F = r[C + 14];
1124
1124
  let g = 1 / 0, p = 1 / 0, m = 1 / 0, O = -1 / 0, S = -1 / 0, _ = -1 / 0;
1125
1125
  for (let N = T, y = T + F; N < y; N++) {
1126
- const D = 3 * l.resolveTriangleIndex(N);
1126
+ const U = 3 * l.resolveTriangleIndex(N);
1127
1127
  for (let P = 0; P < 3; P++) {
1128
- let x = D + P;
1128
+ let x = U + P;
1129
1129
  x = e ? e[x] : x;
1130
1130
  const b = i.getX(x), B = i.getY(x), H = i.getZ(x);
1131
1131
  b < g && (g = b), b > O && (O = b), B < p && (p = B), B > S && (S = B), H < m && (m = H), H > _ && (_ = H);
@@ -1139,9 +1139,9 @@ function Qo(l, s = null) {
1139
1139
  const _ = m || O, N = m || S;
1140
1140
  let y = !1;
1141
1141
  _ && (y = E(T, I, m));
1142
- let D = !1;
1143
- N && (D = E(F, I, m));
1144
- const P = y || D;
1142
+ let U = !1;
1143
+ N && (U = E(F, I, m));
1144
+ const P = y || U;
1145
1145
  if (P)
1146
1146
  for (let x = 0; x < 3; x++) {
1147
1147
  const b = T + x, B = F + x, H = a[b], q = a[b + 3], st = a[B], Q = a[B + 3];
@@ -1248,7 +1248,7 @@ function ir(l, s, t, e = {}, i = {}, o = 0, n = 1 / 0) {
1248
1248
  boundsTraverseOrder: (_) => _e.distanceToBox(_),
1249
1249
  intersectsBounds: (_, N, y) => y < F && y < n,
1250
1250
  intersectsRange: (_, N) => {
1251
- for (let y = _, D = _ + N; y < D; y++) {
1251
+ for (let y = _, U = _ + N; y < U; y++) {
1252
1252
  const P = S.resolveTriangleIndex(y);
1253
1253
  tt(I, 3 * P, E, h), I.a.applyMatrix4(t), I.b.applyMatrix4(t), I.c.applyMatrix4(t), I.needsUpdate = !0;
1254
1254
  for (let x = m, b = m + O; x < b; x++) {
@@ -1265,7 +1265,7 @@ function ir(l, s, t, e = {}, i = {}, o = 0, n = 1 / 0) {
1265
1265
  const S = Ce(s);
1266
1266
  for (let _ = 0, N = S; _ < N; _++) {
1267
1267
  tt(I, 3 * _, E, h), I.a.applyMatrix4(t), I.b.applyMatrix4(t), I.c.applyMatrix4(t), I.needsUpdate = !0;
1268
- for (let y = m, D = m + O; y < D; y++) {
1268
+ for (let y = m, U = m + O; y < U; y++) {
1269
1269
  const P = l.resolveTriangleIndex(y);
1270
1270
  tt(d, 3 * P, c, a), d.needsUpdate = !0;
1271
1271
  const x = d.distanceToTriangle(I, f, R);
@@ -1342,8 +1342,8 @@ function Tt(l, s, t, e, i, o = 0, n = 0, r = 0, a = 0, c = null, h = !1) {
1342
1342
  K(s, R, _), _.applyMatrix4(t);
1343
1343
  const N = pt(l), y = Ct(l, f);
1344
1344
  K(N, I, ae), K(y, I, ce);
1345
- const D = _.intersectsBox(ae), P = _.intersectsBox(ce);
1346
- S = D && Tt(
1345
+ const U = _.intersectsBox(ae), P = _.intersectsBox(ce);
1346
+ S = U && Tt(
1347
1347
  s,
1348
1348
  N,
1349
1349
  e,
@@ -1371,8 +1371,8 @@ function Tt(l, s, t, e, i, o = 0, n = 0, r = 0, a = 0, c = null, h = !1) {
1371
1371
  } else {
1372
1372
  const _ = pt(s), N = Ct(s, T);
1373
1373
  K(_, R, Xs), K(N, R, Zs);
1374
- const y = c.intersectsBox(Xs), D = c.intersectsBox(Zs);
1375
- if (y && D)
1374
+ const y = c.intersectsBox(Xs), U = c.intersectsBox(Zs);
1375
+ if (y && U)
1376
1376
  S = Tt(
1377
1377
  l,
1378
1378
  _,
@@ -1445,7 +1445,7 @@ function Tt(l, s, t, e, i, o = 0, n = 0, r = 0, a = 0, c = null, h = !1) {
1445
1445
  !h
1446
1446
  ), vt.releasePrimitive(P);
1447
1447
  }
1448
- else if (D)
1448
+ else if (U)
1449
1449
  if (m)
1450
1450
  S = Tt(
1451
1451
  l,
@@ -2529,14 +2529,14 @@ function Fr(l) {
2529
2529
  O.elements[0] = R, O.elements[1] = T, O.elements[2] = F, O.elements[3] = T, O.elements[4] = g, O.elements[5] = p, O.elements[6] = F, O.elements[7] = p, O.elements[8] = m, Rr(O, e);
2530
2530
  const S = e.unitary, _ = new A.Vector3(), N = new A.Vector3(), y = new A.Vector3();
2531
2531
  S.extractBasis(_, N, y);
2532
- let D = -1 / 0, P = -1 / 0, x = -1 / 0, b = 1 / 0, B = 1 / 0, H = 1 / 0;
2532
+ let U = -1 / 0, P = -1 / 0, x = -1 / 0, b = 1 / 0, B = 1 / 0, H = 1 / 0;
2533
2533
  for (let it = 0, Xt = s.length; it < Xt; it++) {
2534
2534
  const J = s[it];
2535
- D = Math.max(_.dot(J), D), P = Math.max(N.dot(J), P), x = Math.max(y.dot(J), x), b = Math.min(_.dot(J), b), B = Math.min(N.dot(J), B), H = Math.min(y.dot(J), H);
2535
+ U = Math.max(_.dot(J), U), P = Math.max(N.dot(J), P), x = Math.max(y.dot(J), x), b = Math.min(_.dot(J), b), B = Math.min(N.dot(J), B), H = Math.min(y.dot(J), H);
2536
2536
  }
2537
- _.multiplyScalar(0.5 * (b + D)), N.multiplyScalar(0.5 * (B + P)), y.multiplyScalar(0.5 * (H + x));
2537
+ _.multiplyScalar(0.5 * (b + U)), N.multiplyScalar(0.5 * (B + P)), y.multiplyScalar(0.5 * (H + x));
2538
2538
  const q = new A.Vector3(), st = new A.Vector3(), Q = new A.Matrix3();
2539
- q.add(_).add(N).add(y), st.x = D - b, st.y = P - B, st.z = x - H, st.multiplyScalar(0.5), Q.copy(S);
2539
+ q.add(_).add(N).add(y), st.x = U - b, st.y = P - B, st.z = x - H, st.multiplyScalar(0.5), Q.copy(S);
2540
2540
  const { x: Ht, y: Wt, z: kt } = st, ke = new A.Matrix4();
2541
2541
  ke.makeScale(Ht * 2, Wt * 2, kt * 2);
2542
2542
  const Te = new A.Matrix4();
@@ -3091,7 +3091,7 @@ const As = class As {
3091
3091
  /**
3092
3092
  * The version of the @thatopen/components library.
3093
3093
  */
3094
- u(As, "release", "2.1.22");
3094
+ u(As, "release", "2.1.23");
3095
3095
  let pi = As;
3096
3096
  class gr extends _i {
3097
3097
  constructor() {
@@ -3412,8 +3412,8 @@ function an(l, s, t, e, i = 1 / 0, o, n) {
3412
3412
  h = l.x - I, E = l.y - f, d = l.z - C;
3413
3413
  const O = (t.x + r * I) * o, S = (t.y + r * f) * o, _ = (t.z + r * C) * o;
3414
3414
  t.x = (t.x - r * O) * c, t.y = (t.y - r * S) * c, t.z = (t.z - r * _) * c, n.x = h + (I + O) * c, n.y = E + (f + S) * c, n.z = d + (C + _) * c;
3415
- const N = R - l.x, y = T - l.y, D = F - l.z, P = n.x - R, x = n.y - T, b = n.z - F;
3416
- return N * P + y * x + D * b > 0 && (n.x = R, n.y = T, n.z = F, t.x = (n.x - R) / o, t.y = (n.y - T) / o, t.z = (n.z - F) / o), n;
3415
+ const N = R - l.x, y = T - l.y, U = F - l.z, P = n.x - R, x = n.y - T, b = n.z - F;
3416
+ return N * P + y * x + U * b > 0 && (n.x = R, n.y = T, n.z = F, t.x = (n.x - R) / o, t.y = (n.y - T) / o, t.z = (n.z - F) / o), n;
3417
3417
  }
3418
3418
  function $s(l, s) {
3419
3419
  s.set(0, 0), l.forEach((t) => {
@@ -3562,8 +3562,8 @@ class ot extends Sr {
3562
3562
  }, this._enabled = !0, this._state = L.NONE, this._viewport = null, this._changedDolly = 0, this._changedZoom = 0, this._hasRested = !0, this._boundaryEnclosesCamera = !1, this._needsUpdate = !0, this._updatedLastTime = !1, this._elementRect = new DOMRect(), this._isDragging = !1, this._dragNeedsUpdate = !0, this._activePointers = [], this._lockedPointer = null, this._interactiveArea = new DOMRect(0, 0, 1, 1), this._isUserControllingRotate = !1, this._isUserControllingDolly = !1, this._isUserControllingTruck = !1, this._isUserControllingOffset = !1, this._isUserControllingZoom = !1, this._lastDollyDirection = le.NONE, this._thetaVelocity = { value: 0 }, this._phiVelocity = { value: 0 }, this._radiusVelocity = { value: 0 }, this._targetVelocity = new Y.Vector3(), this._focalOffsetVelocity = new Y.Vector3(), this._zoomVelocity = { value: 0 }, this._truckInternal = (p, m, O) => {
3563
3563
  let S, _;
3564
3564
  if (Zt(this._camera)) {
3565
- const N = G.copy(this._camera.position).sub(this._target), y = this._camera.getEffectiveFOV() * Ne, D = N.length() * Math.tan(y * 0.5);
3566
- S = this.truckSpeed * p * D / this._elementRect.height, _ = this.truckSpeed * m * D / this._elementRect.height;
3565
+ const N = G.copy(this._camera.position).sub(this._target), y = this._camera.getEffectiveFOV() * Ne, U = N.length() * Math.tan(y * 0.5);
3566
+ S = this.truckSpeed * p * U / this._elementRect.height, _ = this.truckSpeed * m * U / this._elementRect.height;
3567
3567
  } else if (bt(this._camera)) {
3568
3568
  const N = this._camera;
3569
3569
  S = p * (N.right - N.left) / N.zoom / this._elementRect.width, _ = m * (N.top - N.bottom) / N.zoom / this._elementRect.height;
@@ -3574,8 +3574,8 @@ class ot extends Sr {
3574
3574
  const O = he * this.azimuthRotateSpeed * p / this._elementRect.height, S = he * this.polarRotateSpeed * m / this._elementRect.height;
3575
3575
  this.rotate(O, S, !0);
3576
3576
  }, this._dollyInternal = (p, m, O) => {
3577
- const S = Math.pow(0.95, -p * this.dollySpeed), _ = this._sphericalEnd.radius, N = this._sphericalEnd.radius * S, y = mt(N, this.minDistance, this.maxDistance), D = y - N;
3578
- this.infinityDolly && this.dollyToCursor ? this._dollyToNoClamp(N, !0) : this.infinityDolly && !this.dollyToCursor ? (this.dollyInFixed(D, !0), this._dollyToNoClamp(y, !0)) : this._dollyToNoClamp(y, !0), this.dollyToCursor && (this._changedDolly += (this.infinityDolly ? N : y) - _, this._dollyControlCoord.set(m, O)), this._lastDollyDirection = Math.sign(-p);
3577
+ const S = Math.pow(0.95, -p * this.dollySpeed), _ = this._sphericalEnd.radius, N = this._sphericalEnd.radius * S, y = mt(N, this.minDistance, this.maxDistance), U = y - N;
3578
+ this.infinityDolly && this.dollyToCursor ? this._dollyToNoClamp(N, !0) : this.infinityDolly && !this.dollyToCursor ? (this.dollyInFixed(U, !0), this._dollyToNoClamp(y, !0)) : this._dollyToNoClamp(y, !0), this.dollyToCursor && (this._changedDolly += (this.infinityDolly ? N : y) - _, this._dollyControlCoord.set(m, O)), this._lastDollyDirection = Math.sign(-p);
3579
3579
  }, this._zoomInternal = (p, m, O) => {
3580
3580
  const S = Math.pow(0.95, p * this.dollySpeed), _ = this._zoom, N = this._zoom * S;
3581
3581
  this.zoomTo(N, !0), this.dollyToCursor && (this._changedZoom += N - _, this._dollyControlCoord.set(m, O));
@@ -3694,8 +3694,8 @@ class ot extends Sr {
3694
3694
  if (!this._domElement || !this._enabled || this.mouseButtons.wheel === L.NONE)
3695
3695
  return;
3696
3696
  if (this._interactiveArea.left !== 0 || this._interactiveArea.top !== 0 || this._interactiveArea.width !== 1 || this._interactiveArea.height !== 1) {
3697
- const N = this._domElement.getBoundingClientRect(), y = p.clientX / N.width, D = p.clientY / N.height;
3698
- if (y < this._interactiveArea.left || y > this._interactiveArea.right || D < this._interactiveArea.top || D > this._interactiveArea.bottom)
3697
+ const N = this._domElement.getBoundingClientRect(), y = p.clientX / N.width, U = p.clientY / N.height;
3698
+ if (y < this._interactiveArea.left || y > this._interactiveArea.right || U < this._interactiveArea.top || U > this._interactiveArea.bottom)
3699
3699
  return;
3700
3700
  }
3701
3701
  if (p.preventDefault(), this.dollyToCursor || this.mouseButtons.wheel === L.ROTATE || this.mouseButtons.wheel === L.TRUCK) {
@@ -3771,10 +3771,10 @@ class ot extends Sr {
3771
3771
  (this._state & L.DOLLY) === L.DOLLY ? (this._dollyInternal(y * S * ds, _, N), this._isUserControllingDolly = !0) : (this._zoomInternal(y * S * ds, _, N), this._isUserControllingZoom = !0);
3772
3772
  }
3773
3773
  if ((this._state & L.TOUCH_DOLLY) === L.TOUCH_DOLLY || (this._state & L.TOUCH_ZOOM) === L.TOUCH_ZOOM || (this._state & L.TOUCH_DOLLY_TRUCK) === L.TOUCH_DOLLY_TRUCK || (this._state & L.TOUCH_ZOOM_TRUCK) === L.TOUCH_ZOOM_TRUCK || (this._state & L.TOUCH_DOLLY_OFFSET) === L.TOUCH_DOLLY_OFFSET || (this._state & L.TOUCH_ZOOM_OFFSET) === L.TOUCH_ZOOM_OFFSET || (this._state & L.TOUCH_DOLLY_ROTATE) === L.TOUCH_DOLLY_ROTATE || (this._state & L.TOUCH_ZOOM_ROTATE) === L.TOUCH_ZOOM_ROTATE) {
3774
- const _ = lt.x - this._activePointers[1].clientX, N = lt.y - this._activePointers[1].clientY, y = Math.sqrt(_ * _ + N * N), D = o.y - y;
3774
+ const _ = lt.x - this._activePointers[1].clientX, N = lt.y - this._activePointers[1].clientY, y = Math.sqrt(_ * _ + N * N), U = o.y - y;
3775
3775
  o.set(0, y);
3776
3776
  const P = this.dollyToCursor ? (i.x - this._elementRect.x) / this._elementRect.width * 2 - 1 : 0, x = this.dollyToCursor ? (i.y - this._elementRect.y) / this._elementRect.height * -2 + 1 : 0;
3777
- (this._state & L.TOUCH_DOLLY) === L.TOUCH_DOLLY || (this._state & L.TOUCH_DOLLY_ROTATE) === L.TOUCH_DOLLY_ROTATE || (this._state & L.TOUCH_DOLLY_TRUCK) === L.TOUCH_DOLLY_TRUCK || (this._state & L.TOUCH_DOLLY_OFFSET) === L.TOUCH_DOLLY_OFFSET ? (this._dollyInternal(D * ds, P, x), this._isUserControllingDolly = !0) : (this._zoomInternal(D * ds, P, x), this._isUserControllingZoom = !0);
3777
+ (this._state & L.TOUCH_DOLLY) === L.TOUCH_DOLLY || (this._state & L.TOUCH_DOLLY_ROTATE) === L.TOUCH_DOLLY_ROTATE || (this._state & L.TOUCH_DOLLY_TRUCK) === L.TOUCH_DOLLY_TRUCK || (this._state & L.TOUCH_DOLLY_OFFSET) === L.TOUCH_DOLLY_OFFSET ? (this._dollyInternal(U * ds, P, x), this._isUserControllingDolly = !0) : (this._zoomInternal(U * ds, P, x), this._isUserControllingZoom = !0);
3778
3778
  }
3779
3779
  ((this._state & L.TRUCK) === L.TRUCK || (this._state & L.TOUCH_TRUCK) === L.TOUCH_TRUCK || (this._state & L.TOUCH_DOLLY_TRUCK) === L.TOUCH_DOLLY_TRUCK || (this._state & L.TOUCH_ZOOM_TRUCK) === L.TOUCH_ZOOM_TRUCK) && (this._truckInternal(O, S, !1), this._isUserControllingTruck = !0), ((this._state & L.OFFSET) === L.OFFSET || (this._state & L.TOUCH_OFFSET) === L.TOUCH_OFFSET || (this._state & L.TOUCH_DOLLY_OFFSET) === L.TOUCH_DOLLY_OFFSET || (this._state & L.TOUCH_ZOOM_OFFSET) === L.TOUCH_ZOOM_OFFSET) && (this._truckInternal(O, S, !0), this._isUserControllingOffset = !0), this.dispatchEvent({ type: "control" });
3780
3780
  }, T = () => {
@@ -6280,7 +6280,7 @@ class Hr extends ri {
6280
6280
  E: [
6281
6281
  [new v(new Re(0.75, 0.1, 2, 24), e)]
6282
6282
  ]
6283
- }, D = {
6283
+ }, U = {
6284
6284
  X: [
6285
6285
  [new v(R, o), [0.5, 0, 0], [0, 0, -Math.PI / 2]],
6286
6286
  [new v(F, o), [0, 0, 0], [0, 0, -Math.PI / 2]],
@@ -6355,7 +6355,7 @@ class Hr extends ri {
6355
6355
  }
6356
6356
  return H;
6357
6357
  }
6358
- this.gizmo = {}, this.picker = {}, this.helper = {}, this.add(this.gizmo.translate = b(m)), this.add(this.gizmo.rotate = b(_)), this.add(this.gizmo.scale = b(D)), this.add(this.picker.translate = b(O)), this.add(this.picker.rotate = b(y)), this.add(this.picker.scale = b(P)), this.add(this.helper.translate = b(S)), this.add(this.helper.rotate = b(N)), this.add(this.helper.scale = b(x)), this.picker.translate.visible = !1, this.picker.rotate.visible = !1, this.picker.scale.visible = !1;
6358
+ this.gizmo = {}, this.picker = {}, this.helper = {}, this.add(this.gizmo.translate = b(m)), this.add(this.gizmo.rotate = b(_)), this.add(this.gizmo.scale = b(U)), this.add(this.picker.translate = b(O)), this.add(this.picker.rotate = b(y)), this.add(this.picker.scale = b(P)), this.add(this.helper.translate = b(S)), this.add(this.helper.rotate = b(N)), this.add(this.helper.scale = b(x)), this.picker.translate.visible = !1, this.picker.rotate.visible = !1, this.picker.scale.visible = !1;
6359
6359
  }
6360
6360
  // updateMatrixWorld will update transformations and appearance of individual handles
6361
6361
  updateMatrixWorld(s) {
@@ -7289,81 +7289,102 @@ class la extends He {
7289
7289
  }
7290
7290
  const qr = /* @__PURE__ */ new Map([
7291
7291
  [
7292
- U.IFCRELAGGREGATES,
7292
+ D.IFCRELAGGREGATES,
7293
7293
  {
7294
7294
  forRelated: "Decomposes",
7295
7295
  forRelating: "IsDecomposedBy"
7296
7296
  }
7297
7297
  ],
7298
7298
  [
7299
- U.IFCRELASSOCIATESMATERIAL,
7299
+ D.IFCRELASSOCIATESMATERIAL,
7300
7300
  {
7301
7301
  forRelated: "HasAssociations",
7302
7302
  forRelating: "AssociatedTo"
7303
7303
  }
7304
7304
  ],
7305
7305
  [
7306
- U.IFCRELASSOCIATESCLASSIFICATION,
7306
+ D.IFCRELASSOCIATESCLASSIFICATION,
7307
7307
  {
7308
7308
  forRelated: "HasAssociations",
7309
7309
  forRelating: "ClassificationForObjects"
7310
7310
  }
7311
7311
  ],
7312
7312
  [
7313
- U.IFCRELASSIGNSTOGROUP,
7313
+ D.IFCRELASSIGNSTOGROUP,
7314
7314
  {
7315
7315
  forRelated: "HasAssignments",
7316
7316
  forRelating: "IsGroupedBy"
7317
7317
  }
7318
7318
  ],
7319
7319
  [
7320
- U.IFCRELDEFINESBYPROPERTIES,
7320
+ D.IFCRELDEFINESBYPROPERTIES,
7321
7321
  {
7322
7322
  forRelated: "IsDefinedBy",
7323
7323
  forRelating: "DefinesOcurrence"
7324
7324
  }
7325
7325
  ],
7326
7326
  [
7327
- U.IFCRELDEFINESBYTYPE,
7327
+ D.IFCRELDEFINESBYTYPE,
7328
7328
  {
7329
7329
  forRelated: "IsTypedBy",
7330
7330
  forRelating: "Types"
7331
7331
  }
7332
7332
  ],
7333
7333
  [
7334
- U.IFCRELDEFINESBYTEMPLATE,
7334
+ D.IFCRELDEFINESBYTEMPLATE,
7335
7335
  {
7336
7336
  forRelated: "IsDefinedBy",
7337
7337
  forRelating: "Defines"
7338
7338
  }
7339
7339
  ],
7340
7340
  [
7341
- U.IFCRELCONTAINEDINSPATIALSTRUCTURE,
7341
+ D.IFCRELCONTAINEDINSPATIALSTRUCTURE,
7342
7342
  {
7343
7343
  forRelated: "ContainedInStructure",
7344
7344
  forRelating: "ContainsElements"
7345
7345
  }
7346
7346
  ],
7347
7347
  [
7348
- U.IFCRELFLOWCONTROLELEMENTS,
7348
+ D.IFCRELFLOWCONTROLELEMENTS,
7349
7349
  {
7350
7350
  forRelated: "AssignedToFlowElement",
7351
7351
  forRelating: "HasControlElements"
7352
7352
  }
7353
7353
  ],
7354
7354
  [
7355
- U.IFCRELCONNECTSELEMENTS,
7355
+ D.IFCRELCONNECTSELEMENTS,
7356
7356
  {
7357
7357
  forRelated: "ConnectedFrom",
7358
7358
  forRelating: "ConnectedTo"
7359
7359
  }
7360
7360
  ],
7361
7361
  [
7362
- U.IFCRELASSIGNSTOPRODUCT,
7362
+ D.IFCRELASSIGNSTOPRODUCT,
7363
7363
  {
7364
7364
  forRelated: "HasAssignments",
7365
7365
  forRelating: "ReferencedBy"
7366
7366
  }
7367
+ ],
7368
+ [
7369
+ D.IFCRELDECLARES,
7370
+ {
7371
+ forRelated: "HasContext",
7372
+ forRelating: "Declares"
7373
+ }
7374
+ ],
7375
+ [
7376
+ D.IFCRELASSIGNSTOCONTROL,
7377
+ {
7378
+ forRelated: "HasAssignments",
7379
+ forRelating: "Controls"
7380
+ }
7381
+ ],
7382
+ [
7383
+ D.IFCRELNESTS,
7384
+ {
7385
+ forRelated: "Nests",
7386
+ forRelating: "IsNestedBy"
7387
+ }
7367
7388
  ]
7368
7389
  ]), Ve = class Ve extends et {
7369
7390
  constructor(t) {
@@ -7410,20 +7431,28 @@ const qr = /* @__PURE__ */ new Map([
7410
7431
  "AssignedToFlowElement",
7411
7432
  "ConnectedTo",
7412
7433
  "ConnectedFrom",
7413
- "ReferencedBy"
7434
+ "ReferencedBy",
7435
+ "Declares",
7436
+ "HasContext",
7437
+ "Controls",
7438
+ "IsNestedBy",
7439
+ "Nests"
7414
7440
  ]);
7415
7441
  u(this, "_ifcRels", [
7416
- U.IFCRELAGGREGATES,
7417
- U.IFCRELASSOCIATESMATERIAL,
7418
- U.IFCRELASSOCIATESCLASSIFICATION,
7419
- U.IFCRELASSIGNSTOGROUP,
7420
- U.IFCRELDEFINESBYPROPERTIES,
7421
- U.IFCRELDEFINESBYTYPE,
7422
- U.IFCRELDEFINESBYTEMPLATE,
7423
- U.IFCRELCONTAINEDINSPATIALSTRUCTURE,
7424
- U.IFCRELFLOWCONTROLELEMENTS,
7425
- U.IFCRELCONNECTSELEMENTS,
7426
- U.IFCRELASSIGNSTOPRODUCT
7442
+ D.IFCRELAGGREGATES,
7443
+ D.IFCRELASSOCIATESMATERIAL,
7444
+ D.IFCRELASSOCIATESCLASSIFICATION,
7445
+ D.IFCRELASSIGNSTOGROUP,
7446
+ D.IFCRELDEFINESBYPROPERTIES,
7447
+ D.IFCRELDEFINESBYTYPE,
7448
+ D.IFCRELDEFINESBYTEMPLATE,
7449
+ D.IFCRELCONTAINEDINSPATIALSTRUCTURE,
7450
+ D.IFCRELFLOWCONTROLELEMENTS,
7451
+ D.IFCRELCONNECTSELEMENTS,
7452
+ D.IFCRELASSIGNSTOPRODUCT,
7453
+ D.IFCRELDECLARES,
7454
+ D.IFCRELASSIGNSTOCONTROL,
7455
+ D.IFCRELNESTS
7427
7456
  ]);
7428
7457
  u(this, "onFragmentsDisposed", (t) => {
7429
7458
  delete this.relationMaps[t.groupID];
@@ -8311,11 +8340,11 @@ const Yn = /* @__PURE__ */ new Set([
8311
8340
  */
8312
8341
  async export(t, e, i = !1, o = !0) {
8313
8342
  const n = {}, r = new Set(t.GetIfcEntityList(e)), a = /* @__PURE__ */ new Set([
8314
- U.IFCPROJECT,
8315
- U.IFCSITE,
8316
- U.IFCBUILDING,
8317
- U.IFCBUILDINGSTOREY,
8318
- U.IFCSPACE
8343
+ D.IFCPROJECT,
8344
+ D.IFCSITE,
8345
+ D.IFCBUILDING,
8346
+ D.IFCBUILDINGSTOREY,
8347
+ D.IFCSPACE
8319
8348
  ]);
8320
8349
  for (const c of a)
8321
8350
  r.add(c);
@@ -9632,7 +9661,7 @@ const Vn = {
9632
9661
  class Kt {
9633
9662
  static async getUnits(s) {
9634
9663
  var n, r, a;
9635
- const { IFCUNITASSIGNMENT: t } = U, e = await s.getAllPropertiesOfType(t);
9664
+ const { IFCUNITASSIGNMENT: t } = D, e = await s.getAllPropertiesOfType(t);
9636
9665
  if (!e)
9637
9666
  return 1;
9638
9667
  const i = Object.keys(e), o = e[parseInt(i[0], 10)];
@@ -9683,19 +9712,19 @@ class Kt {
9683
9712
  static async getQsetQuantities(s, t, e) {
9684
9713
  const o = e ?? (() => {
9685
9714
  }), n = await s.getProperties(t);
9686
- return !n || n.type !== U.IFCELEMENTQUANTITY ? null : (n.Quantities ?? [{}]).map((c) => (c.value && o(c.value), c.value)).filter((c) => c !== null);
9715
+ return !n || n.type !== D.IFCELEMENTQUANTITY ? null : (n.Quantities ?? [{}]).map((c) => (c.value && o(c.value), c.value)).filter((c) => c !== null);
9687
9716
  }
9688
9717
  static async getPsetProps(s, t, e) {
9689
9718
  const o = e ?? (() => {
9690
9719
  }), n = await s.getProperties(t);
9691
- return !n || n.type !== U.IFCPROPERTYSET ? null : (n.HasProperties ?? [{}]).map((c) => (c.value && o(c.value), c.value)).filter((c) => c !== null);
9720
+ return !n || n.type !== D.IFCPROPERTYSET ? null : (n.HasProperties ?? [{}]).map((c) => (c.value && o(c.value), c.value)).filter((c) => c !== null);
9692
9721
  }
9693
9722
  static async getPsetRel(s, t) {
9694
9723
  var r;
9695
9724
  if (!await s.getProperties(t))
9696
9725
  return null;
9697
9726
  const i = await s.getAllPropertiesOfType(
9698
- U.IFCRELDEFINESBYPROPERTIES
9727
+ D.IFCRELDEFINESBYPROPERTIES
9699
9728
  );
9700
9729
  if (!i)
9701
9730
  return null;
@@ -9786,7 +9815,7 @@ class $r {
9786
9815
  try {
9787
9816
  const e = s.GetLineIDsWithType(
9788
9817
  0,
9789
- U.IFCUNITASSIGNMENT
9818
+ D.IFCUNITASSIGNMENT
9790
9819
  ).get(0), i = s.GetLine(0, e);
9791
9820
  for (const o of i.Units) {
9792
9821
  if (!o || o.value === null || o.value === void 0)
@@ -9833,11 +9862,11 @@ class Gn {
9833
9862
  try {
9834
9863
  const t = s.GetLineIDsWithType(
9835
9864
  0,
9836
- U.IFCRELCONTAINEDINSPATIALSTRUCTURE
9837
- ), e = /* @__PURE__ */ new Set(), i = s.GetLineIDsWithType(0, U.IFCSPACE);
9865
+ D.IFCRELCONTAINEDINSPATIALSTRUCTURE
9866
+ ), e = /* @__PURE__ */ new Set(), i = s.GetLineIDsWithType(0, D.IFCSPACE);
9838
9867
  for (let c = 0; c < i.size(); c++)
9839
9868
  e.add(i.get(c));
9840
- const o = s.GetLineIDsWithType(0, U.IFCRELAGGREGATES), n = o.size();
9869
+ const o = s.GetLineIDsWithType(0, D.IFCRELAGGREGATES), n = o.size();
9841
9870
  for (let c = 0; c < n; c++) {
9842
9871
  const h = o.get(c), E = s.GetLine(0, h);
9843
9872
  if (!E || !E.RelatingObject || !E.RelatedObjects)
@@ -9900,14 +9929,14 @@ class yi {
9900
9929
  * Generate the geometry for categories that are not included by default,
9901
9930
  * like IFCSPACE.
9902
9931
  */
9903
- u(this, "optionalCategories", [U.IFCSPACE]);
9932
+ u(this, "optionalCategories", [D.IFCSPACE]);
9904
9933
  /** Whether to use the coordination data coming from the IFC files. */
9905
9934
  u(this, "coordinate", !0);
9906
9935
  /** Path of the WASM for [web-ifc](https://github.com/ThatOpen/engine_web-ifc). */
9907
9936
  u(this, "wasm", {
9908
9937
  path: "",
9909
9938
  absolute: !1,
9910
- logLevel: U.LogLevel.LOG_LEVEL_OFF
9939
+ logLevel: D.LogLevel.LOG_LEVEL_OFF
9911
9940
  });
9912
9941
  /** List of categories that won't be converted to fragments. */
9913
9942
  u(this, "excludedCategories", /* @__PURE__ */ new Set());
@@ -9992,7 +10021,7 @@ class zn {
9992
10021
  class Hn {
9993
10022
  getNameInfo(s) {
9994
10023
  var E;
9995
- const t = {}, { arguments: e } = s.GetHeaderLine(0, U.FILE_NAME) || {};
10024
+ const t = {}, { arguments: e } = s.GetHeaderLine(0, D.FILE_NAME) || {};
9996
10025
  if (!e)
9997
10026
  return t;
9998
10027
  const [
@@ -10013,7 +10042,7 @@ class Hn {
10013
10042
  }
10014
10043
  getDescriptionInfo(s) {
10015
10044
  var n;
10016
- const t = {}, { arguments: e } = s.GetHeaderLine(0, U.FILE_DESCRIPTION) || {};
10045
+ const t = {}, { arguments: e } = s.GetHeaderLine(0, D.FILE_DESCRIPTION) || {};
10017
10046
  if (!e)
10018
10047
  return t;
10019
10048
  const [i, o] = e;
@@ -10027,15 +10056,15 @@ class Hn {
10027
10056
  class Wn {
10028
10057
  static get(s, t) {
10029
10058
  const e = [
10030
- U.IFCPROJECT,
10031
- U.IFCSITE,
10032
- U.IFCBUILDING,
10033
- U.IFCBUILDINGSTOREY,
10034
- U.IFCSPACE,
10035
- U.IFCROAD,
10036
- U.IFCFACILITY,
10037
- U.IFCFACILITYPART,
10038
- U.IFCBRIDGE
10059
+ D.IFCPROJECT,
10060
+ D.IFCSITE,
10061
+ D.IFCBUILDING,
10062
+ D.IFCBUILDINGSTOREY,
10063
+ D.IFCSPACE,
10064
+ D.IFCROAD,
10065
+ D.IFCFACILITY,
10066
+ D.IFCFACILITYPART,
10067
+ D.IFCBRIDGE
10039
10068
  ], i = s.data;
10040
10069
  for (const o of e) {
10041
10070
  const n = t.GetLineIDsWithType(0, o), r = n.size();
@@ -10067,7 +10096,7 @@ const Ge = class Ge extends et {
10067
10096
  /**
10068
10097
  * The instance of the Web-IFC library used for handling IFC data.
10069
10098
  */
10070
- u(this, "webIfc", new U.IfcAPI());
10099
+ u(this, "webIfc", new D.IfcAPI());
10071
10100
  /** {@link Component.enabled} */
10072
10101
  u(this, "enabled", !0);
10073
10102
  u(this, "_material", new A.MeshLambertMaterial());
@@ -10080,7 +10109,7 @@ const Ge = class Ge extends et {
10080
10109
  transparent: !0,
10081
10110
  opacity: 0.5
10082
10111
  }));
10083
- this.components.add(Ge.uuid, this), this.settings.excludedCategories.add(U.IFCOPENINGELEMENT);
10112
+ this.components.add(Ge.uuid, this), this.settings.excludedCategories.add(D.IFCOPENINGELEMENT);
10084
10113
  }
10085
10114
  /** {@link Disposable.dispose} */
10086
10115
  dispose() {
@@ -10183,7 +10212,7 @@ const Ge = class Ge extends et {
10183
10212
  this.webIfc.Dispose();
10184
10213
  } catch {
10185
10214
  }
10186
- this.webIfc = null, this.webIfc = new U.IfcAPI(), this._visitedFragments.clear(), this._fragmentInstances.clear();
10215
+ this.webIfc = null, this.webIfc = new D.IfcAPI(), this._visitedFragments.clear(), this._fragmentInstances.clear();
10187
10216
  }
10188
10217
  async getAllGeometries() {
10189
10218
  this._spatialTree.setUp(this.webIfc);
@@ -10198,7 +10227,7 @@ const Ge = class Ge extends et {
10198
10227
  };
10199
10228
  const i = [];
10200
10229
  for (const n of t) {
10201
- if (!this.webIfc.IsIfcElement(n) && n !== U.IFCSPACE)
10230
+ if (!this.webIfc.IsIfcElement(n) && n !== D.IFCSPACE)
10202
10231
  continue;
10203
10232
  const r = this.settings.includedCategories;
10204
10233
  if (r.size > 0 && !r.has(n))
@@ -10405,7 +10434,7 @@ const Bt = class Bt extends et {
10405
10434
  * @throws Will throw an error if no OwnerHistory is found in the model.
10406
10435
  */
10407
10436
  async newPset(t, e, i) {
10408
- const o = Bt.getIFCSchema(t), { ownerHistoryHandle: n } = await this.getOwnerHistory(t), r = this.newGUID(t), a = new U[o].IfcLabel(e), c = i ? new U[o].IfcText(i) : null, h = new U[o].IfcPropertySet(
10437
+ const o = Bt.getIFCSchema(t), { ownerHistoryHandle: n } = await this.getOwnerHistory(t), r = this.newGUID(t), a = new D[o].IfcLabel(e), c = i ? new D[o].IfcText(i) : null, h = new D[o].IfcPropertySet(
10409
10438
  r,
10410
10439
  n,
10411
10440
  a,
@@ -10413,13 +10442,13 @@ const Bt = class Bt extends et {
10413
10442
  []
10414
10443
  );
10415
10444
  h.expressID = this.increaseMaxID(t);
10416
- const E = this.newGUID(t), d = new U[o].IfcRelDefinesByProperties(
10445
+ const E = this.newGUID(t), d = new D[o].IfcRelDefinesByProperties(
10417
10446
  E,
10418
10447
  n,
10419
10448
  null,
10420
10449
  null,
10421
10450
  [],
10422
- new U.Handle(h.expressID)
10451
+ new D.Handle(h.expressID)
10423
10452
  );
10424
10453
  return d.expressID = this.increaseMaxID(t), await this.setData(t, h, d), { pset: h, rel: d };
10425
10454
  }
@@ -10438,7 +10467,7 @@ const Bt = class Bt extends et {
10438
10467
  async removePset(t, ...e) {
10439
10468
  for (const i of e) {
10440
10469
  const o = await t.getProperties(i);
10441
- if ((o == null ? void 0 : o.type) !== U.IFCPROPERTYSET)
10470
+ if ((o == null ? void 0 : o.type) !== D.IFCPROPERTYSET)
10442
10471
  continue;
10443
10472
  const n = await Kt.getPsetRel(t, i);
10444
10473
  if (n && (await t.setProperties(n, null), this.registerChange(t, n)), o) {
@@ -10510,7 +10539,7 @@ const Bt = class Bt extends et {
10510
10539
  */
10511
10540
  async removePsetProp(t, e, i) {
10512
10541
  const o = await t.getProperties(e), n = await t.getProperties(i);
10513
- !o || !n || o.type === U.IFCPROPERTYSET && n && (o.HasProperties = o.HasProperties.filter((r) => r.value !== i), await t.setProperties(i, null), this.registerChange(t, e, i));
10542
+ !o || !n || o.type === D.IFCPROPERTYSET && n && (o.HasProperties = o.HasProperties.filter((r) => r.value !== i), await t.setProperties(i, null), this.registerChange(t, e, i));
10514
10543
  }
10515
10544
  async addElementToPset(t, e, ...i) {
10516
10545
  const o = await Kt.getPsetRel(t, e);
@@ -10520,7 +10549,7 @@ const Bt = class Bt extends et {
10520
10549
  if (!n)
10521
10550
  return;
10522
10551
  for (const a of i) {
10523
- const c = new U.Handle(a);
10552
+ const c = new D.Handle(a);
10524
10553
  n.RelatedObjects.push(c), this.onElementToPset.trigger({
10525
10554
  model: t,
10526
10555
  psetID: e,
@@ -10551,7 +10580,7 @@ const Bt = class Bt extends et {
10551
10580
  for (const n of i) {
10552
10581
  if (o.HasProperties.includes(n))
10553
10582
  continue;
10554
- const r = new U.Handle(n);
10583
+ const r = new D.Handle(n);
10555
10584
  o.HasProperties.push(r), this.onPropToPset.trigger({ model: t, psetID: e, propID: n });
10556
10585
  }
10557
10586
  this.registerChange(t, e);
@@ -10630,15 +10659,15 @@ const Bt = class Bt extends et {
10630
10659
  }
10631
10660
  newGUID(t) {
10632
10661
  const e = Bt.getIFCSchema(t);
10633
- return new U[e].IfcGloballyUniqueId(ze.create());
10662
+ return new D[e].IfcGloballyUniqueId(ze.create());
10634
10663
  }
10635
10664
  async getOwnerHistory(t) {
10636
10665
  const e = await t.getAllPropertiesOfType(
10637
- U.IFCOWNERHISTORY
10666
+ D.IFCOWNERHISTORY
10638
10667
  );
10639
10668
  if (!e)
10640
10669
  throw new Error("No OwnerHistory was found.");
10641
- const i = Object.keys(e).map((r) => parseInt(r, 10)), o = e[i[0]], n = new U.Handle(o.expressID);
10670
+ const i = Object.keys(e).map((r) => parseInt(r, 10)), o = e[i[0]], n = new D.Handle(o.expressID);
10642
10671
  return { ownerHistory: o, ownerHistoryHandle: n };
10643
10672
  }
10644
10673
  registerChange(t, ...e) {
@@ -10647,7 +10676,7 @@ const Bt = class Bt extends et {
10647
10676
  this.changeMap[t.uuid].add(i), this.onDataChanged.trigger({ model: t, expressID: i });
10648
10677
  }
10649
10678
  async newSingleProperty(t, e, i, o) {
10650
- const n = Bt.getIFCSchema(t), r = new U[n].IfcIdentifier(i), a = new U[n][e](o), c = new U[n].IfcPropertySingleValue(
10679
+ const n = Bt.getIFCSchema(t), r = new D[n].IfcIdentifier(i), a = new D[n][e](o), c = new D[n].IfcPropertySingleValue(
10651
10680
  r,
10652
10681
  null,
10653
10682
  a,
@@ -11194,7 +11223,7 @@ const Ms = class Ms extends et {
11194
11223
  /**
11195
11224
  * The WebIFC API instance used for IFC file processing.
11196
11225
  */
11197
- u(this, "webIfc", new U.IfcAPI());
11226
+ u(this, "webIfc", new D.IfcAPI());
11198
11227
  u(this, "_spatialTree", new Gn());
11199
11228
  u(this, "_metaData", new Hn());
11200
11229
  u(this, "_visitedGeometries", /* @__PURE__ */ new Map());
@@ -11205,7 +11234,7 @@ const Ms = class Ms extends et {
11205
11234
  u(this, "_groupSerializer", new Vt.Serializer());
11206
11235
  u(this, "_assets", []);
11207
11236
  u(this, "_meshesWithHoles", /* @__PURE__ */ new Set());
11208
- this.components.add(Ms.uuid, this), this.settings.excludedCategories.add(U.IFCOPENINGELEMENT);
11237
+ this.components.add(Ms.uuid, this), this.settings.excludedCategories.add(D.IFCOPENINGELEMENT);
11209
11238
  }
11210
11239
  /** {@link Disposable.dispose} */
11211
11240
  dispose() {
@@ -11266,7 +11295,7 @@ const Ms = class Ms extends et {
11266
11295
  };
11267
11296
  let r = 0, a = 0;
11268
11297
  for (const C of i) {
11269
- if (!this.webIfc.IsIfcElement(C) && C !== U.IFCSPACE || this.settings.excludedCategories.has(C))
11298
+ if (!this.webIfc.IsIfcElement(C) && C !== D.IFCSPACE || this.settings.excludedCategories.has(C))
11270
11299
  continue;
11271
11300
  const R = this.webIfc.GetLineIDsWithType(0, C), T = R.size();
11272
11301
  for (let F = 0; F < T; F++) {
@@ -11306,7 +11335,7 @@ const Ms = class Ms extends et {
11306
11335
  this.webIfc.Dispose();
11307
11336
  } catch {
11308
11337
  }
11309
- this.webIfc = null, this.webIfc = new U.IfcAPI(), this._visitedGeometries.clear(), this._geometries.clear(), this._assets = [], this._meshesWithHoles.clear();
11338
+ this.webIfc = null, this.webIfc = new D.IfcAPI(), this._visitedGeometries.clear(), this._geometries.clear(), this._assets = [], this._meshesWithHoles.clear();
11310
11339
  }
11311
11340
  getMesh(t, e, i) {
11312
11341
  const o = e.geometries.size(), n = e.expressID, r = { id: n, geometries: [] };
@@ -11411,7 +11440,7 @@ class ea extends et {
11411
11440
  /**
11412
11441
  * An instance of the IfcAPI class from the Web-IFC library, which provides methods for reading and processing IFC data.
11413
11442
  */
11414
- u(this, "webIfc", new U.IfcAPI());
11443
+ u(this, "webIfc", new D.IfcAPI());
11415
11444
  }
11416
11445
  /** {@link Disposable.dispose} */
11417
11446
  async dispose() {
@@ -11445,11 +11474,11 @@ class ea extends et {
11445
11474
  }
11446
11475
  async streamAllProperties() {
11447
11476
  const { propertiesSize: t } = this.settings, e = new Set(this.webIfc.GetIfcEntityList(0)), i = /* @__PURE__ */ new Set([
11448
- U.IFCPROJECT,
11449
- U.IFCSITE,
11450
- U.IFCBUILDING,
11451
- U.IFCBUILDINGSTOREY,
11452
- U.IFCSPACE
11477
+ D.IFCPROJECT,
11478
+ D.IFCSITE,
11479
+ D.IFCBUILDING,
11480
+ D.IFCBUILDINGSTOREY,
11481
+ D.IFCSPACE
11453
11482
  ]);
11454
11483
  for (const c of i)
11455
11484
  e.add(c);
@@ -11493,7 +11522,7 @@ class ea extends et {
11493
11522
  await this.onIndicesStreamed.trigger(a);
11494
11523
  }
11495
11524
  cleanUp() {
11496
- this.webIfc.Dispose(), this.webIfc = null, this.webIfc = new U.IfcAPI();
11525
+ this.webIfc.Dispose(), this.webIfc = null, this.webIfc = new D.IfcAPI();
11497
11526
  }
11498
11527
  }
11499
11528
  /**
@@ -11583,11 +11612,11 @@ const Ds = class Ds extends et {
11583
11612
  O.add(m);
11584
11613
  }
11585
11614
  for (const m of T) {
11586
- const O = E.get(m), { edges: S, indices: _ } = O, N = E.get(R), { edges: y, indices: D } = N;
11615
+ const O = E.get(m), { edges: S, indices: _ } = O, N = E.get(R), { edges: y, indices: U } = N;
11587
11616
  for (const P of S)
11588
11617
  y.add(P), h.set(P, R);
11589
11618
  for (const P of _)
11590
- D.add(P);
11619
+ U.add(P);
11591
11620
  E.delete(m);
11592
11621
  }
11593
11622
  }