iflow-engine-base 1.0.10 → 1.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -952,7 +952,7 @@ function er(r) {
952
952
  ].map((j) => new E.Vector3().copy(C).add(j)).map((j) => r.worldToScreen.worldToScreen(j));
953
953
  r.catchSvg.innerHTML = "";
954
954
  const ee = document.createElementNS("http://www.w3.org/2000/svg", "polygon");
955
- ee.setAttribute("class", "catchFace"), ee.setAttribute("points", H.map((j) => `${j.x + r.reactBoundingClientRect.left},${j.y + r.reactBoundingClientRect.top}`).join(" ")), ee.setAttribute("fill", "rgba(1, 238, 255, 0.2)"), ee.setAttribute("stroke", "rgb(0, 255, 247)"), ee.setAttribute("stroke-width", "1"), r.catchSvg.appendChild(ee);
955
+ ee.setAttribute("class", "catchFace"), ee.setAttribute("points", H.map((j) => `${j.x + 0},${j.y + 0}`).join(" ")), ee.setAttribute("fill", "rgba(1, 238, 255, 0.2)"), ee.setAttribute("stroke", "rgb(0, 255, 247)"), ee.setAttribute("stroke-width", "1"), r.catchSvg.appendChild(ee);
956
956
  }
957
957
  return p[0];
958
958
  function b(C, P, R) {
@@ -7513,7 +7513,7 @@ function Xh(r, e, t, n) {
7513
7513
  let i = 0, o = 0, s = 0, a = r.models.find((p) => p.url == t), l = e.circularMeps, h = e.rectMeps.filter((p) => p.type === "风管"), c = e.rectMeps.filter((p) => p.type === "桥架"), u = e.ellipseMeps, d = r.scene;
7514
7514
  if (new E.MeshBasicMaterial(), new E.BufferGeometry(), l && l.length) {
7515
7515
  let p = [], f = 0;
7516
- for (let m of l) {
7516
+ for (let m of l)
7517
7517
  m.color = new E.Color(`rgb(${m.color})`), m.position = {
7518
7518
  x: m.startPoint.X * 0.3048 + i,
7519
7519
  y: m.startPoint.Z * 0.3048 + o,
@@ -7522,12 +7522,9 @@ function Xh(r, e, t, n) {
7522
7522
  x: 0,
7523
7523
  y: 0,
7524
7524
  z: 0
7525
- };
7526
- debugger;
7527
- m.indexes = [
7525
+ }, m.indexes = [
7528
7526
  [r.scene.children.length, f++, 0, 0]
7529
7527
  ], a.nodesMap.set(Number(m.id), m), p.push(m);
7530
- }
7531
7528
  Qn("Circle", d, p, t);
7532
7529
  }
7533
7530
  if (h && h.length) {
@@ -12064,7 +12061,7 @@ class lf {
12064
12061
  volumeAnnotation: []
12065
12062
  };
12066
12063
  constructor(e) {
12067
- this.engine = e, this.clearHeightMeasure = new Qu(e), this.distanceMeasure = new ef(e), this.clearDistanceMeasure = new tf(e), this.elevationMeasure = new nf(e), this.pointMeasure = new sf(e), this.angleMeasure = new rf(e), this.areaMeasure = new of(e), this.slopeMeasure = new af(e), this.tools = new bt(e), this.annotationContainer = document.createElement("div"), this.annotationContainer.className = "annotation-container", e.container.parentElement.appendChild(this.annotationContainer);
12064
+ this.engine = e, this.clearHeightMeasure = new Qu(e), this.distanceMeasure = new ef(e), this.clearDistanceMeasure = new tf(e), this.elevationMeasure = new nf(e), this.pointMeasure = new sf(e), this.angleMeasure = new rf(e), this.areaMeasure = new of(e), this.slopeMeasure = new af(e), this.tools = new bt(e), this.annotationContainer = document.createElement("div"), this.annotationContainer.className = "annotation-container", e.container.appendChild(this.annotationContainer);
12068
12065
  }
12069
12066
  active() {
12070
12067
  this.isActive = !0, this.tools.active();
@@ -16786,7 +16783,7 @@ class hp {
16786
16783
  constructor(e) {
16787
16784
  if (this.options = e, this.container = document.getElementById(e.containerId), !this.container)
16788
16785
  throw new Error(`Container ${e.containerId} not found`);
16789
- this.ai = new cp(this), this.deviceModule = new Bl(this), this.DeviceType = this.deviceModule.getDeviceType(), this.cameraModule = new Ll(this), this.sceneModule = new Dl(this), this.scene = this.sceneModule.scene, this.renderModule = new Il(this), this.renderer = this.renderModule.createRenderer(), this.camera = this.cameraModule.orthographicCamera, this.scene.camera = this.camera, this.controlModule = new Yl(this), this.controlModule.switchDefaultMode(), this.controls = this.controlModule.orbitControls, this.composerModule = new uc(this), this.composerModule.init(), this.events = new Nu(), this.engineStatus = new Iu(this), this.engineStatus.init(), this.loaderModule = new Bu(this), this.lightModule = new zu(this), this.lightModule.init(), this.viewCube = new Zu(this), this.viewCube.init(), this.octreeBox = Yu(this), this.rangeScale = new $u(this), this.rangeScale.init(), this.clipping = new np(this), this.clipping.init(), this.setting = new Ju(this), this.setting.init(), this.handelBehaved = er(this), this.modelMapperBatch = new op(this), this.measure = new lf(this), this.modelToolModule = new Uu(this), this.modelProperties = new rp(this), this.interactionModule = new Ou(this), this.interactionModule.init(), this.interactionModule.active(), this.modelEdge = new ap(this), this.modelTree = new ip(this), this.engineInfo = new sp(this), this.worldToScreen = new Ge(this.camera, this.renderer, this.scene), this.reactBoundingClientRect = this.container.getBoundingClientRect(), this.stats = new Hu(), this.stats.showPanel(0), this.stats.dom.style.position = "absolute", this.stats.dom.style.top = "0px", this.stats.dom.style.left = "0px", this.stats.dom.style.zIndex = "1000", this.container.appendChild(this.stats.dom);
16786
+ this.ai = new cp(this), this.deviceModule = new Bl(this), this.DeviceType = this.deviceModule.getDeviceType(), this.cameraModule = new Ll(this), this.sceneModule = new Dl(this), this.scene = this.sceneModule.scene, this.renderModule = new Il(this), this.renderer = this.renderModule.createRenderer(), this.camera = this.cameraModule.orthographicCamera, this.scene.camera = this.camera, this.controlModule = new Yl(this), this.controlModule.switchDefaultMode(), this.controls = this.controlModule.orbitControls, this.composerModule = new uc(this), this.composerModule.init(), this.events = new Nu(), this.engineStatus = new Iu(this), this.engineStatus.init(), this.loaderModule = new Bu(this), this.lightModule = new zu(this), this.lightModule.init(), this.viewCube = new Zu(this), this.viewCube.init(), this.octreeBox = Yu(this), this.rangeScale = new $u(this), this.rangeScale.init(), this.clipping = new np(this), this.clipping.init(), this.setting = new Ju(this), this.setting.init(), this.handelBehaved = er(this), this.modelMapperBatch = new op(this), this.measure = new lf(this), this.modelToolModule = new Uu(this), this.modelProperties = new rp(this), this.interactionModule = new Ou(this), this.interactionModule.init(), this.interactionModule.active(), this.modelEdge = new ap(this), this.modelTree = new ip(this), this.engineInfo = new sp(this), this.worldToScreen = new Ge(this.camera, this.renderer, this.scene), this.stats = new Hu(), this.stats.showPanel(0), this.stats.dom.style.position = "absolute", this.stats.dom.style.top = "0px", this.stats.dom.style.left = "0px", this.stats.dom.style.zIndex = "1000", this.container.appendChild(this.stats.dom);
16790
16787
  let t = document.createElementNS("http://www.w3.org/2000/svg", "svg");
16791
16788
  t.style.position = "absolute", t.style.width = "100%", t.style.height = "100%", t.style.zIndex = "1000", t.style.left = "0px", t.style.top = "0px", t.style.pointerEvents = "none";
16792
16789
  const n = this.renderer?.domElement.width || 1920, i = this.renderer?.domElement.height || 1080;
@@ -16834,7 +16831,7 @@ class hp {
16834
16831
  handleWindowResize(e, t) {
16835
16832
  if (!this.container || !this.renderer || !this.camera)
16836
16833
  return;
16837
- if (this.reactBoundingClientRect = this.container.getBoundingClientRect(), e === void 0 || t === void 0) {
16834
+ if (e === void 0 || t === void 0) {
16838
16835
  const i = this.deviceModule.getContainerSize();
16839
16836
  e = e ?? i.width, t = t ?? i.height;
16840
16837
  }