@abi-software/scaffoldvuer 1.15.1 → 1.15.4

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.
@@ -32283,7 +32283,7 @@ const a5 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
32283
32283
  /* 2 */
32284
32284
  /***/
32285
32285
  (o) => {
32286
- o.exports = /* @__PURE__ */ JSON.parse('{"name":"zincjs","version":"1.18.5","description":"ZincJS (Web-based-Zinc-Visualisation)","main":"build/zinc.js","directories":{"doc":"docs"},"files":["package.json","LICENSE","README.md","src/*","build/zinc.js","build/zinc.frontend.js","build/zinc.js.map","webpack.config.js"],"scripts":{"build-bundle":"webpack --config webpack.frontend.js; webpack --config webpack.backend.js","build-backend":"webpack --config webpack.backend.js","test":"npm --prefix ./test install && npm --prefix ./test run test-ci","changelog":"auto-changelog -p --output CHANGELOG.md --template keepachangelog","jsdoc":"jsdoc -c jsdoc_conf.json","version":"npm run build-bundle;npm run jsdoc;npm run changelog; git add CHANGELOG.md docs","release:beta":"npm version prerelease --preid=beta; npm publish --tag beta","release:minor":"npm version minor; npm publish","release:patch":"npm version patch; npm publish"},"repository":{"type":"git","url":"git+https://github.com/alan-wu/ZincJS.git"},"keywords":["library","webgl","3d","zincjs"],"author":"Alan Wu <alan.wu@auckland.ac.nz>","license":"MIT","bugs":{"url":"https://github.com/alan-wu/ZincJS/issues"},"homepage":"http://alan-wu.github.io/ZincJS/","devDependencies":{"@babel/core":"^7.23.9","@babel/preset-env":"^7.23.9","auto-changelog":"^2.4.0","babel-loader":"^9.1.3","babel-preset-minify":"^0.5.1","file-loader":"^6.2.0","jsdoc":"^4.0.2","raw-loader":"^4.0.2","webpack":"^5.90.3","webpack-cli":"^5.1.4","webpack-node-externals":"^3.0.0"},"dependencies":{"css-element-queries":"^1.2.2","lodash":"^4.17.19","promise-polyfill":"^8.1.3","three":"^0.130.1","three-spritetext":"1.6.2","url-loader":"^4.1.1","url-polyfill":"^1.1.7","webworkify-webpack":"^2.1.5"}}');
32286
+ o.exports = /* @__PURE__ */ JSON.parse('{"name":"zincjs","version":"1.18.8","description":"ZincJS (Web-based-Zinc-Visualisation)","main":"build/zinc.js","directories":{"doc":"docs"},"files":["package.json","LICENSE","README.md","src/*","build/zinc.js","build/zinc.frontend.js","build/zinc.js.map","webpack.config.js"],"scripts":{"build-bundle":"webpack --config webpack.frontend.js; webpack --config webpack.backend.js","build-backend":"webpack --config webpack.backend.js","test":"npm --prefix ./test install && npm --prefix ./test run test-ci","changelog":"auto-changelog -p --output CHANGELOG.md --template keepachangelog","jsdoc":"jsdoc -c jsdoc_conf.json","version":"npm run build-bundle;npm run jsdoc;npm run changelog; git add CHANGELOG.md docs","release:beta":"npm version prerelease --preid=beta; npm publish --tag beta","release:minor":"npm version minor; npm publish","release:patch":"npm version patch; npm publish"},"repository":{"type":"git","url":"git+https://github.com/alan-wu/ZincJS.git"},"keywords":["library","webgl","3d","zincjs"],"author":"Alan Wu <alan.wu@auckland.ac.nz>","license":"MIT","bugs":{"url":"https://github.com/alan-wu/ZincJS/issues"},"homepage":"http://alan-wu.github.io/ZincJS/","devDependencies":{"@babel/core":"^7.23.9","@babel/preset-env":"^7.23.9","auto-changelog":"^2.4.0","babel-loader":"^9.1.3","babel-preset-minify":"^0.5.1","file-loader":"^6.2.0","jsdoc":"^4.0.2","raw-loader":"^4.0.2","webpack":"^5.90.3","webpack-cli":"^5.1.4","webpack-node-externals":"^3.0.0"},"dependencies":{"css-element-queries":"^1.2.2","lodash":"^4.17.19","promise-polyfill":"^8.1.3","three":"^0.130.1","three-spritetext":"1.6.2","url-loader":"^4.1.1","url-polyfill":"^1.1.7","webworkify-webpack":"^2.1.5"}}');
32287
32287
  },
32288
32288
  /* 3 */
32289
32289
  /***/
@@ -33565,7 +33565,11 @@ const a5 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
33565
33565
  }, this.setLabel = (M) => {
33566
33566
  M && (typeof M == "string" || M instanceof String) && (v = M, this.morph && (this.morph.name = M));
33567
33567
  }, this.showLabel = (M) => {
33568
- y && (g = y.getPosition(), this.group.remove(y.getSprite()), y.dispose(), y = void 0), v && (typeof v == "string" || v instanceof String) && (y = new (c(17)).Label(v, M), y.setPosition(g[0], g[1], g[2]), this.group.add(y.getSprite()));
33568
+ if (y && (g = y.getPosition(), this.group.remove(y.getSprite()), y.dispose(), y = void 0), v && (typeof v == "string" || v instanceof String)) {
33569
+ y = new (c(17)).Label(v, M), y.setPosition(g[0], g[1], g[2]);
33570
+ var w = y.getSprite();
33571
+ w.material.alphaTest = 0.5, w.material.transparent = !0, w.material.depthWrite = !1, this.group.add(y.getSprite());
33572
+ }
33569
33573
  }, this.hideLabel = () => {
33570
33574
  y && (g = y.getPosition(), this.group.remove(y.getSprite()), y.dispose(), y = void 0);
33571
33575
  }, this.getLabel = () => v, this.getMesh = () => this.morph, this.setTransformation = (M, w, S, x) => {
@@ -33696,7 +33700,7 @@ const a5 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
33696
33700
  $(H);
33697
33701
  }
33698
33702
  };
33699
- this.showLabel = () => {
33703
+ this.getLabel = (k) => M && M.length > k ? M[k] : void 0, this.showLabel = () => {
33700
33704
  for (var k = 0; k < f.length; k++) f[k].showLabel(this.morph.material ? this.morph.material.color : void 0);
33701
33705
  }, this.hideLabel = () => {
33702
33706
  for (var k = 0; k < f.length; k++) f[k].hideLabel();
@@ -40875,29 +40879,29 @@ Kt.prototype.getIntersectedObject = function(n) {
40875
40879
  return t > -1 || (t = e.indexOf(2), t = t > -1 ? t : e.indexOf(3)), n[t];
40876
40880
  }
40877
40881
  };
40878
- Kt.prototype.getAnnotationsFromObjects = function(n) {
40879
- const e = [];
40880
- for (var t = 0; t < n.length; t++) {
40881
- const i = n[t].userData;
40882
- let r;
40883
- if (i) {
40884
- if (i.isGlyph || i.isGlyphset) {
40885
- let s = i;
40886
- i.isGlyph && (s = i.getGlyphset()), r = s.userData ? s.userData.annotation : void 0, r && r.data && (n[t].name && n[t].name != "" ? r.data.id = n[t].name : r.data.id = s.groupName);
40882
+ Kt.prototype.getAnnotationsFromObjects = function(n, e) {
40883
+ const t = [];
40884
+ for (var i = 0; i < n.length; i++) {
40885
+ const r = n[i].userData;
40886
+ let s;
40887
+ if (r) {
40888
+ if (r.isGlyph || r.isGlyphset) {
40889
+ let o = r;
40890
+ r.isGlyph && (o = r.getGlyphset()), s = o.userData ? o.userData.annotation : void 0, s && s.data && (e && "instanceId" in e ? s.data.id = o.getLabel(e.instanceId) : n[i].name && n[i].name != "" ? s.data.id = n[i].name : s.data.id = o.groupName);
40887
40891
  } else
40888
- r = i.userData ? i.userData.annotation : void 0, r && r.data && (r.data.id = n[t].name);
40889
- r && (r.data.anatomicalId = i.anatomicalId, r.data.isNerves = i.userData.isNerves, r.data.zincObject = i);
40892
+ s = r.userData ? r.userData.annotation : void 0, s && s.data && (s.data.id = n[i].name);
40893
+ s && (s.data.anatomicalId = r.anatomicalId, s.data.isNerves = r.userData.isNerves, s.data.zincObject = r);
40890
40894
  }
40891
- r && e.push(r);
40895
+ s && t.push(s);
40892
40896
  }
40893
- return e;
40897
+ return t;
40894
40898
  };
40895
40899
  Kt.prototype.setHighlightedByObjects = function(n, e, t, i) {
40896
40900
  const r = xp(n), s = this.graphicsHighlight.setHighlighted(n);
40897
40901
  if (i) {
40898
40902
  let o = sl.MOVE;
40899
40903
  s && (o = sl.HIGHLIGHTED);
40900
- const a = this.getAnnotationsFromObjects(n);
40904
+ const a = this.getAnnotationsFromObjects(n, t);
40901
40905
  a.length > 0 && (a[0].coords = e, a[0].extraData = t), this.publishChanges(a, o, r);
40902
40906
  }
40903
40907
  return s;
@@ -40921,7 +40925,7 @@ Kt.prototype.setSelectedByObjects = function(n, e, t, i) {
40921
40925
  if (this.selectObjectOnPick ? r = this.graphicsHighlight.setSelected(n) : r = !0, r || this.ignorePreviousSelected) {
40922
40926
  const s = xp(n);
40923
40927
  if (this.selectObjectOnPick && this.setupLiveCoordinates(s), i) {
40924
- const o = sl.SELECTED, a = this.getAnnotationsFromObjects(n);
40928
+ const o = sl.SELECTED, a = this.getAnnotationsFromObjects(n, t);
40925
40929
  a.length > 0 && (a[0].coords = e, a[0].extraData = t), this.publishChanges(a, o, s);
40926
40930
  }
40927
40931
  }
@@ -41076,7 +41080,8 @@ const W5 = function() {
41076
41080
  _ = T.name;
41077
41081
  else {
41078
41082
  const R = e.getAnnotationsFromObjects(
41079
- [T]
41083
+ [T],
41084
+ void 0
41080
41085
  );
41081
41086
  R && R[0] && (_ = R[0].data.group);
41082
41087
  }
@@ -41092,7 +41097,8 @@ const W5 = function() {
41092
41097
  C ? C.point.z : 0
41093
41098
  ],
41094
41099
  intersected: C,
41095
- intersects: A
41100
+ intersects: A,
41101
+ instanceId: C != null && C.instanceId ? C.instanceId : -1
41096
41102
  }, I = { x: _, y: T };
41097
41103
  if (R.id) {
41098
41104
  b.threeID = (D = R.object) == null ? void 0 : D.id, R.object.userData.isGlyph ? R.object.name ? e.setSelectedByObjects(
@@ -41120,7 +41126,8 @@ const W5 = function() {
41120
41126
  C ? C.point.x : 0,
41121
41127
  C ? C.point.y : 0,
41122
41128
  C ? C.point.z : 0
41123
- ]
41129
+ ],
41130
+ instanceId: C != null && C.instanceId ? C.instanceId : -1
41124
41131
  }, I = { x: _, y: T };
41125
41132
  if (R.id) {
41126
41133
  b.threeID = (D = R.object) == null ? void 0 : D.id, e.displayArea.style.cursor = "pointer", e.setHighlightedByObjects([R.object], I, b, !0);