@ndmspc/ndmvr 1.2.0-rc.6 → 1.2.0-rc.8

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.
Files changed (2) hide show
  1. package/dist/ndmvr.es.js +103 -13
  2. package/package.json +1 -1
package/dist/ndmvr.es.js CHANGED
@@ -3375,7 +3375,7 @@ var Qo = {
3375
3375
  default: {
3376
3376
  title: "Default mode",
3377
3377
  ariaLabel: "Enable default mode",
3378
- icon: "MousePointer2",
3378
+ icon: "",
3379
3379
  histogramEvents: {
3380
3380
  mouseclick: "default",
3381
3381
  mousedbclick: "default",
@@ -3384,10 +3384,10 @@ var Qo = {
3384
3384
  mousemove: "default"
3385
3385
  },
3386
3386
  baseEvents: {
3387
- onEnter: () => console.log("Entered default mode"),
3388
- onClick: () => console.log("Clicked in default mode"),
3389
- onHover: () => console.log("Hovered over default mode"),
3390
- onExit: () => console.log("Exited default mode")
3387
+ onClick: "default",
3388
+ onEnter: "default",
3389
+ onHover: "default",
3390
+ onExit: "default"
3391
3391
  }
3392
3392
  },
3393
3393
  modify: {
@@ -3402,10 +3402,100 @@ var Qo = {
3402
3402
  mousemove: null
3403
3403
  },
3404
3404
  baseEvents: {
3405
- onEnter: () => console.log("Entered modify mode"),
3406
- onClick: () => console.log("Clicked in modify mode"),
3407
- onHover: () => console.log("Hovered over modify mode"),
3408
- onExit: () => console.log("Exited modify mode")
3405
+ onClick: "default",
3406
+ onEnter: "default",
3407
+ onHover: "default",
3408
+ onExit: "default"
3409
+ }
3410
+ },
3411
+ scaleBy: {
3412
+ title: "Scale By mode",
3413
+ ariaLabel: "Enable scale by mode",
3414
+ icon: "Scale3D",
3415
+ histogramEvents: {
3416
+ mouseclick: null,
3417
+ mousedbclick: null,
3418
+ shiftmouseclick: null,
3419
+ shiftmousedbclick: null,
3420
+ mousemove: null
3421
+ },
3422
+ baseEvents: {
3423
+ onEnter: "default",
3424
+ onClick: () => {
3425
+ let e = k().getValue();
3426
+ e?.config?.histogram?.scale?.scaleBy && (e.config.histogram.scale.scaleBy === "value" ? e.config.histogram.scale.scaleBy = "error" : e.config.histogram.scale.scaleBy = "value", console.log("Updated config: cfg=", e), k().next(e));
3427
+ },
3428
+ onHover: "default",
3429
+ onExit: "default"
3430
+ }
3431
+ },
3432
+ colorBy: {
3433
+ title: "Color By mode",
3434
+ ariaLabel: "Enable color by mode",
3435
+ icon: "Palette",
3436
+ histogramEvents: {
3437
+ mouseclick: null,
3438
+ mousedbclick: null,
3439
+ shiftmouseclick: null,
3440
+ shiftmousedbclick: null,
3441
+ mousemove: null
3442
+ },
3443
+ baseEvents: {
3444
+ onEnter: "default",
3445
+ onClick: () => {
3446
+ let e = k().getValue();
3447
+ e?.config?.histogram?.color?.colorBy && (e.config.histogram.color.colorBy === "error" ? e.config.histogram.color.colorBy = "value" : e.config.histogram.color.colorBy = "error", console.log("Updated config: cfg=", e), k().next(e));
3448
+ },
3449
+ onHover: "default",
3450
+ onExit: "default"
3451
+ }
3452
+ },
3453
+ layers: {
3454
+ title: "Layers mode",
3455
+ ariaLabel: "Enable layers mode",
3456
+ icon: "Layers",
3457
+ histogramEvents: {
3458
+ mouseclick: null,
3459
+ mousedbclick: null,
3460
+ shiftmouseclick: null,
3461
+ shiftmousedbclick: null,
3462
+ mousemove: null
3463
+ },
3464
+ baseEvents: {
3465
+ onEnter: "default",
3466
+ onClick: () => {
3467
+ console.log("Clicked in layers mode");
3468
+ let e = F("pad1").getValue();
3469
+ console.log("Current state: ", e), e?.currentLayer ? (e.currentLayer += 1, e.currentLayer > e.availableAxes.length - e.sets.length && (e.currentLayer = 1)) : e.currentLayer = 2, window.dispatchEvent(new KeyboardEvent("keydown", {
3470
+ key: e.currentLayer.toString(),
3471
+ code: "Numpad" + e.currentLayer.toString(),
3472
+ bubbles: !0,
3473
+ cancelable: !0
3474
+ })), F("pad1").next(e);
3475
+ },
3476
+ onHover: "default",
3477
+ onExit: "default"
3478
+ }
3479
+ },
3480
+ outline: {
3481
+ title: "Outline mode",
3482
+ ariaLabel: "Enable outline mode",
3483
+ icon: "SquareDashed",
3484
+ histogramEvents: {
3485
+ mouseclick: null,
3486
+ mousedbclick: null,
3487
+ shiftmouseclick: null,
3488
+ shiftmousedbclick: null,
3489
+ mousemove: null
3490
+ },
3491
+ baseEvents: {
3492
+ onEnter: "default",
3493
+ onClick: () => {
3494
+ let e = k().getValue(), t = F("pad1").getValue();
3495
+ console.log("Current config: ", e), e?.config?.histogram?.wireframe && (e.config.histogram.wireframe.display.start = e.config.histogram.wireframe.display.start + 1, (e.config.histogram.wireframe.display.start >= e.config.histogram.wireframe.display.end || e.config.histogram.wireframe.display.start >= t.availableAxes.length + 1) && (e.config.histogram.wireframe.display.start = 0), console.log("Updated config: start=", e.config.histogram.wireframe.display.start, "end=", e.config.histogram.wireframe.display.end), k().next(e));
3496
+ },
3497
+ onHover: "default",
3498
+ onExit: "default"
3409
3499
  }
3410
3500
  }
3411
3501
  }, $o = Ua((e, t) => ({
@@ -64155,7 +64245,7 @@ function SW(e) {
64155
64245
  function CW(e) {
64156
64246
  let n = t(e);
64157
64247
  console.log("Fetched object:", n), N().next({
64158
- id: "histogram1",
64248
+ id: "pad1",
64159
64249
  opts: { render: "" },
64160
64250
  obj: n
64161
64251
  });
@@ -64179,12 +64269,12 @@ function EW(e) {
64179
64269
  if (console.log("Received data:", e), typeof e != "string" || !e.startsWith("{")) return;
64180
64270
  let n = t(e);
64181
64271
  if (console.log("Received object:", n), n.arr && n.arr.length > 0) for (let e = 0; e < n.arr.length; e++) n.arr[e]._typename.startsWith("TH1") || n.arr[e]._typename.startsWith("TH2"), N().next({
64182
- id: `histogram${e + 1}`,
64272
+ id: `pad${e + 1}`,
64183
64273
  opts: { render: "nested" },
64184
64274
  obj: n.arr[e]
64185
64275
  });
64186
64276
  else n._typename && N().next({
64187
- id: "histogram1",
64277
+ id: "pad1",
64188
64278
  opts: { render: "" },
64189
64279
  obj: n
64190
64280
  });
@@ -64230,4 +64320,4 @@ function DW(e) {
64230
64320
  ] }), t[13] = s, t[14] = y, t[15] = b, t[16] = x, t[17] = S) : S = t[17], S;
64231
64321
  }
64232
64322
  //#endregion
64233
- export { bl as BinInfo, Ia as CameraSync, Nc as CanvasComponent, ys as Controllers, cl as Demo, ms as DesktopController, Ol as DrawOptions, _W as HelperTips, Mc as HistogramWrapper, hl as HttpConnectionMenu, bW as IframeCernboxService, yW as IframeService, Fa as JsrootEnv, is as Menu, gW as NdmspcDefaultBrowserEnv, uW as NdmspcEnv, DW as NdmspcNavigator, Rc as NdmvrContent, Td as NdmvrEnv, ud as SettingsPanel, ps as VRController, ml as WsConnectionMenu, S as binInfoSubjectGet, w as brokerManagerGet, E as canvasSubjectGet, O as configSubjectGet, A as functionSubjectGet, M as histogramSubjectGet, P as stateSubjectGet, vd as store, xW as useNdmspcConfig, TW as useNdmspcWebsocket, $o as useSceneModeStore };
64323
+ export { bl as BinInfo, Ia as CameraSync, Nc as CanvasComponent, ys as Controllers, cl as Demo, ms as DesktopController, Ol as DrawOptions, _W as HelperTips, Mc as HistogramWrapper, hl as HttpConnectionMenu, bW as IframeCernboxService, yW as IframeService, Fa as JsrootEnv, is as Menu, gW as NdmspcDefaultBrowserEnv, uW as NdmspcEnv, DW as NdmspcNavigator, Rc as NdmvrContent, Td as NdmvrEnv, ud as SettingsPanel, ps as VRController, ml as WsConnectionMenu, S as binInfoSubjectGet, w as brokerManagerGet, E as canvasSubjectGet, O as configSubjectGet, Qo as defaultSceneModesConfig, A as functionSubjectGet, M as histogramSubjectGet, P as stateSubjectGet, vd as store, xW as useNdmspcConfig, TW as useNdmspcWebsocket, $o as useSceneModeStore };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ndmspc/ndmvr",
3
- "version": "1.2.0-rc.6",
3
+ "version": "1.2.0-rc.8",
4
4
  "description": "NDMVR React three fiber components",
5
5
  "author": "NDMSPC community",
6
6
  "repository": {