@inditextech/weave-sdk 3.7.2 → 3.8.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.
package/dist/sdk.js CHANGED
@@ -15102,6 +15102,9 @@ var WeaveStore = class {
15102
15102
  getStateJson() {
15103
15103
  return JSON.parse(JSON.stringify(this.state, void 0, 2));
15104
15104
  }
15105
+ getRoomId() {
15106
+ return this.roomId;
15107
+ }
15105
15108
  getStateSnapshot() {
15106
15109
  const doc = this.getDocument();
15107
15110
  return yjs_default.encodeStateAsUpdate(doc);
@@ -18678,7 +18681,6 @@ var WeaveNodesSelectionPlugin = class extends WeavePlugin {
18678
18681
  "bottom-right"
18679
18682
  ];
18680
18683
  this.taps = 0;
18681
- this.isCtrlMetaPressed = false;
18682
18684
  this.isSpaceKeyPressed = false;
18683
18685
  this.isDoubleTap = false;
18684
18686
  this.tapStart = null;
@@ -18778,12 +18780,12 @@ var WeaveNodesSelectionPlugin = class extends WeavePlugin {
18778
18780
  }
18779
18781
  };
18780
18782
  stage.on("pointermove", (0, import_throttle.default)(handlePointerMoveInit, DEFAULT_THROTTLE_MS));
18781
- tr.on("transformstart", () => {
18783
+ tr.on("transformstart", (e) => {
18782
18784
  this.transformInProcess = true;
18783
18785
  this.triggerSelectedNodesEvent();
18784
18786
  const selectedNodes$1 = tr.nodes();
18785
18787
  for (const node of selectedNodes$1) {
18786
- node.handleMouseout();
18788
+ node.handleMouseout(e);
18787
18789
  if (node.getAttrs().strokeScaleEnabled !== false) {
18788
18790
  node.setAttr("strokeScaleEnabled", false);
18789
18791
  node.setAttr("_revertStrokeScaleEnabled", true);
@@ -18795,7 +18797,7 @@ var WeaveNodesSelectionPlugin = class extends WeavePlugin {
18795
18797
  });
18796
18798
  });
18797
18799
  let nodeHovered = void 0;
18798
- tr.on("mousemove", () => {
18800
+ tr.on("mousemove", (e) => {
18799
18801
  if (this.dragInProcess) return;
18800
18802
  const pointerPos = stage.getPointerPosition();
18801
18803
  if (!pointerPos) return;
@@ -18805,13 +18807,13 @@ var WeaveNodesSelectionPlugin = class extends WeavePlugin {
18805
18807
  if (shape) {
18806
18808
  const targetNode = this.instance.getInstanceRecursive(shape);
18807
18809
  if (targetNode && targetNode !== nodeHovered) {
18808
- this.instance.getStage().handleMouseover();
18809
- nodeHovered?.handleMouseout?.();
18810
- targetNode?.handleMouseover?.();
18810
+ this.instance.getStage().handleMouseover(e);
18811
+ nodeHovered?.handleMouseout?.(e);
18812
+ targetNode?.handleMouseover?.(e);
18811
18813
  nodeHovered = targetNode;
18812
18814
  }
18813
- targetNode?.handleMouseover?.();
18814
- } else nodeHovered?.handleMouseout?.();
18815
+ targetNode?.handleMouseover?.(e);
18816
+ } else nodeHovered?.handleMouseout?.(e);
18815
18817
  });
18816
18818
  tr.on("mouseover", () => {
18817
18819
  const nodesSelected = tr.nodes();
@@ -18820,16 +18822,16 @@ var WeaveNodesSelectionPlugin = class extends WeavePlugin {
18820
18822
  stage.container().style.cursor = node.defineMousePointer() ?? "grab";
18821
18823
  } else stage.container().style.cursor = "grab";
18822
18824
  });
18823
- tr.on("mouseout", () => {
18824
- this.instance.getStage().handleMouseover?.();
18825
+ tr.on("mouseout", (e) => {
18826
+ this.instance.getStage().handleMouseover?.(e);
18825
18827
  nodeHovered = void 0;
18826
18828
  });
18827
- window.addEventListener("mouseout", () => {
18829
+ window.addEventListener("mouseout", (e) => {
18828
18830
  if (nodeHovered) {
18829
- nodeHovered.handleMouseout();
18831
+ nodeHovered.handleMouseout(e);
18830
18832
  nodeHovered = void 0;
18831
18833
  }
18832
- this.instance.getStage().handleMouseover?.();
18834
+ this.instance.getStage().handleMouseover?.(e);
18833
18835
  }, { signal: this.instance.getEventsController()?.signal });
18834
18836
  const handleTransform = (e) => {
18835
18837
  const moved = this.checkMoved(e);
@@ -18869,6 +18871,8 @@ var WeaveNodesSelectionPlugin = class extends WeavePlugin {
18869
18871
  let selectedNodes = [];
18870
18872
  tr.on("dragstart", (e) => {
18871
18873
  this.dragInProcess = true;
18874
+ let isWheelMousePressed = false;
18875
+ if (e.evt.button === 1) isWheelMousePressed = true;
18872
18876
  const mainLayer = this.instance.getMainLayer();
18873
18877
  if (!mainLayer) return;
18874
18878
  initialPos = {
@@ -18880,7 +18884,7 @@ var WeaveNodesSelectionPlugin = class extends WeavePlugin {
18880
18884
  this.saveDragSelectedNodes();
18881
18885
  if (this.getDragSelectedNodes().length > 1) this.setNodesOpacityOnDrag();
18882
18886
  selectedNodes = tr.nodes();
18883
- if (stage$1.isMouseWheelPressed()) {
18887
+ if (isWheelMousePressed) {
18884
18888
  e.cancelBubble = true;
18885
18889
  e.target.stopDrag();
18886
18890
  return;
@@ -18904,13 +18908,14 @@ var WeaveNodesSelectionPlugin = class extends WeavePlugin {
18904
18908
  x: e.target.x(),
18905
18909
  y: e.target.y()
18906
18910
  };
18911
+ let isWheelMousePressed = false;
18912
+ if (e.evt.button === 1) isWheelMousePressed = true;
18907
18913
  e.cancelBubble = true;
18908
18914
  if (initialPos) {
18909
18915
  const moved = this.checkMovedDrag(initialPos, actualPos);
18910
18916
  if (moved) this.getContextMenuPlugin()?.cancelLongPressTimer();
18911
18917
  }
18912
- const stage$1 = this.instance.getStage();
18913
- if (stage$1.isMouseWheelPressed()) {
18918
+ if (isWheelMousePressed) {
18914
18919
  e.cancelBubble = true;
18915
18920
  e.target.stopDrag();
18916
18921
  return;
@@ -19020,16 +19025,6 @@ var WeaveNodesSelectionPlugin = class extends WeavePlugin {
19020
19025
  tr.forceUpdate();
19021
19026
  }
19022
19027
  });
19023
- this.instance.addEventListener("onRender", () => {
19024
- const point = stage.getPointerPosition();
19025
- if (point) {
19026
- const ele = this.instance.getTargetingManager().pointIntersectsElement(point);
19027
- if (ele) {
19028
- const realEle = this.instance.getTargetingManager().resolveNode(ele);
19029
- realEle?.handleMouseover();
19030
- }
19031
- }
19032
- });
19033
19028
  this.instance.addEventListener("onNodesChange", () => {
19034
19029
  const currentSelectedNodes = tr.nodes();
19035
19030
  const unselectedNodes = this.prevSelectedNodes.filter((node) => !currentSelectedNodes.map((node1) => node1.getAttrs().id).includes(node.getAttrs().id));
@@ -19236,12 +19231,7 @@ var WeaveNodesSelectionPlugin = class extends WeavePlugin {
19236
19231
  initEvents() {
19237
19232
  this.selecting = false;
19238
19233
  const stage = this.instance.getStage();
19239
- window.addEventListener("blur", () => {
19240
- this.isCtrlMetaPressed = false;
19241
- this.isSpaceKeyPressed = false;
19242
- }, { signal: this.instance.getEventsController()?.signal });
19243
19234
  stage.container().addEventListener("keydown", (e) => {
19244
- if (e.ctrlKey || e.metaKey) this.isCtrlMetaPressed = true;
19245
19235
  if (e.code === "Space") this.isSpaceKeyPressed = true;
19246
19236
  if (e.code === "Backspace" || e.code === "Delete") {
19247
19237
  Promise.resolve().then(() => {
@@ -19251,7 +19241,6 @@ var WeaveNodesSelectionPlugin = class extends WeavePlugin {
19251
19241
  }
19252
19242
  }, { signal: this.instance.getEventsController()?.signal });
19253
19243
  stage.container().addEventListener("keyup", (e) => {
19254
- if (!(e.ctrlKey || e.metaKey)) this.isCtrlMetaPressed = false;
19255
19244
  if (e.code === "Space") this.isSpaceKeyPressed = false;
19256
19245
  }, { signal: this.instance.getEventsController()?.signal });
19257
19246
  stage.on("pointerdown", (e) => {
@@ -19303,7 +19292,8 @@ var WeaveNodesSelectionPlugin = class extends WeavePlugin {
19303
19292
  this.selectionRectangle.width(0);
19304
19293
  this.selectionRectangle.height(0);
19305
19294
  this.selecting = true;
19306
- if (this.isCtrlMetaPressed) {
19295
+ const isCtrlOrMetaPressed = e.evt.ctrlKey || e.evt.metaKey;
19296
+ if (isCtrlOrMetaPressed) {
19307
19297
  const nodesSelected = this.tr.nodes();
19308
19298
  for (const node of nodesSelected) node.fire("onSelectionCleared", { bubbles: true });
19309
19299
  }
@@ -19523,7 +19513,8 @@ var WeaveNodesSelectionPlugin = class extends WeavePlugin {
19523
19513
  nodeTargeted.dblClick();
19524
19514
  return;
19525
19515
  }
19526
- if (stage.isCmdCtrlPressed()) return;
19516
+ const isCtrlOrCmdPressed = e.evt.ctrlKey || e.evt.metaKey;
19517
+ if (isCtrlOrCmdPressed) return;
19527
19518
  if (!metaPressed) {
19528
19519
  this.tr.nodes([nodeTargeted]);
19529
19520
  this.tr.show();
@@ -20165,11 +20156,6 @@ const MOVE_TOOL_STATE = {
20165
20156
 
20166
20157
  //#endregion
20167
20158
  //#region src/nodes/node.ts
20168
- const augmentKonvaStageClass = () => {
20169
- Konva.Stage.prototype.isMouseWheelPressed = function() {
20170
- return false;
20171
- };
20172
- };
20173
20159
  const augmentKonvaNodeClass = (config) => {
20174
20160
  const { transform } = config ?? {};
20175
20161
  Konva.Node.prototype.getTransformerProperties = function() {
@@ -20476,6 +20462,8 @@ var WeaveNode = class {
20476
20462
  node.off("dragstart");
20477
20463
  node.on("dragstart", (e) => {
20478
20464
  const nodeTarget = e.target;
20465
+ let isWheelMousePressed = false;
20466
+ if (e.evt.button === 1) isWheelMousePressed = true;
20479
20467
  e.cancelBubble = true;
20480
20468
  this.getNodesSelectionFeedbackPlugin()?.hideSelectionHalo(nodeTarget);
20481
20469
  this.getSelectionPlugin()?.saveDragSelectedNodes();
@@ -20496,7 +20484,7 @@ var WeaveNode = class {
20496
20484
  return;
20497
20485
  }
20498
20486
  this.instance.emitEvent("onDrag", nodeTarget);
20499
- if (stage.isMouseWheelPressed()) {
20487
+ if (isWheelMousePressed) {
20500
20488
  e.cancelBubble = true;
20501
20489
  nodeTarget.stopDrag();
20502
20490
  }
@@ -20513,6 +20501,7 @@ var WeaveNode = class {
20513
20501
  originalNode = realNodeTarget.clone();
20514
20502
  originalContainer = realNodeTarget.getParent();
20515
20503
  if (originalContainer?.getAttrs().nodeId) originalContainer = stage.findOne(`#${originalContainer.getAttrs().nodeId}`);
20504
+ realNodeTarget.fire("nodeDragStart", { node: realNodeTarget });
20516
20505
  if (e.evt?.altKey) {
20517
20506
  nodeTarget.setAttrs({ isCloneOrigin: true });
20518
20507
  nodeTarget.setAttrs({ isCloned: false });
@@ -20541,19 +20530,20 @@ var WeaveNode = class {
20541
20530
  });
20542
20531
  const handleDragMove = (e) => {
20543
20532
  const nodeTarget = e.target;
20533
+ let isWheelMousePressed = false;
20534
+ if (e.evt.button === 1) isWheelMousePressed = true;
20544
20535
  e.cancelBubble = true;
20545
20536
  if (e.evt?.buttons === 0) {
20546
20537
  nodeTarget.stopDrag();
20547
20538
  return;
20548
20539
  }
20549
20540
  this.didMove = true;
20550
- const stage$1 = this.instance.getStage();
20551
20541
  const isErasing = this.instance.getActiveAction() === "eraseTool";
20552
20542
  if (isErasing) {
20553
20543
  nodeTarget.stopDrag();
20554
20544
  return;
20555
20545
  }
20556
- if (stage$1.isMouseWheelPressed()) {
20546
+ if (isWheelMousePressed) {
20557
20547
  e.cancelBubble = true;
20558
20548
  nodeTarget.stopDrag();
20559
20549
  return;
@@ -20667,11 +20657,11 @@ var WeaveNode = class {
20667
20657
  originalPosition = realNodeTarget.getAbsolutePosition();
20668
20658
  });
20669
20659
  if (!node.getAttrs().overridesMouseControl) {
20670
- node.handleMouseover = () => {
20671
- this.handleMouseOver(node);
20660
+ node.handleMouseover = (e) => {
20661
+ this.handleMouseOver(e, node);
20672
20662
  };
20673
- node.handleMouseout = () => {
20674
- this.handleMouseout(node);
20663
+ node.handleMouseout = (e) => {
20664
+ this.handleMouseout(e, node);
20675
20665
  };
20676
20666
  }
20677
20667
  node.on("xChange yChange", () => {
@@ -20699,20 +20689,21 @@ var WeaveNode = class {
20699
20689
  };
20700
20690
  node.on("pointerover", (e) => {
20701
20691
  const realNodeTarget = this.getRealSelectedNode(e.target);
20702
- realNodeTarget?.handleMouseover?.();
20703
- const doCancelBubble = this.handleMouseOver(e.target);
20692
+ realNodeTarget?.handleMouseover?.(e);
20693
+ const doCancelBubble = this.handleMouseOver(e, e.target);
20704
20694
  if (doCancelBubble) e.cancelBubble = true;
20705
20695
  });
20706
20696
  node.on("pointerleave", (e) => {
20707
20697
  const realNodeTarget = this.getRealSelectedNode(e.target);
20708
- realNodeTarget?.handleMouseout?.();
20709
- this.handleMouseout(e.target);
20698
+ realNodeTarget?.handleMouseout?.(e);
20699
+ this.handleMouseout(e, e.target);
20710
20700
  });
20711
20701
  }
20712
20702
  }
20713
- handleMouseOver(node) {
20703
+ handleMouseOver(e, node) {
20714
20704
  const stage = this.instance.getStage();
20715
- if (stage?.isCmdCtrlPressed?.()) return false;
20705
+ const isCtrlOrMetaPressed = e.evt.ctrlKey || e.evt.metaKey;
20706
+ if (isCtrlOrMetaPressed) return false;
20716
20707
  const user = this.instance.getStore().getUser();
20717
20708
  const activeAction = this.instance.getActiveAction();
20718
20709
  const isNodeSelectionEnabled = this.getSelectionPlugin()?.isEnabled();
@@ -20746,9 +20737,9 @@ var WeaveNode = class {
20746
20737
  else this.hideHoverState();
20747
20738
  return cancelBubble;
20748
20739
  }
20749
- handleMouseout(node) {
20750
- const stage = this.instance.getStage();
20751
- if (stage?.isCmdCtrlPressed?.()) return;
20740
+ handleMouseout(e, node) {
20741
+ const isCtrlOrMetaPressed = e.evt.ctrlKey || e.evt.metaKey;
20742
+ if (isCtrlOrMetaPressed) return;
20752
20743
  const realNode = this.instance.getInstanceRecursive(node);
20753
20744
  if (realNode) this.hideHoverState();
20754
20745
  }
@@ -22022,7 +22013,7 @@ var WeaveRegisterManager = class {
22022
22013
 
22023
22014
  //#endregion
22024
22015
  //#region package.json
22025
- var version = "3.7.2";
22016
+ var version = "3.8.0";
22026
22017
 
22027
22018
  //#endregion
22028
22019
  //#region src/managers/setup.ts
@@ -23468,7 +23459,6 @@ var Weave = class {
23468
23459
  this.status = WEAVE_INSTANCE_STATUS.STARTING;
23469
23460
  this.emitEvent("onInstanceStatus", this.status);
23470
23461
  await this.registerManager.registerNodesHandlers();
23471
- this.augmentKonvaStageClass();
23472
23462
  this.augmentKonvaNodeClass();
23473
23463
  this.registerManager.registerPlugins();
23474
23464
  this.registerManager.registerActionsHandlers();
@@ -23540,9 +23530,6 @@ var Weave = class {
23540
23530
  getConfiguration() {
23541
23531
  return this.config;
23542
23532
  }
23543
- augmentKonvaStageClass() {
23544
- augmentKonvaStageClass();
23545
- }
23546
23533
  augmentKonvaNodeClass(config) {
23547
23534
  augmentKonvaNodeClass(config);
23548
23535
  }
@@ -24315,8 +24302,6 @@ const setupUpscaleStage = (instance, stage) => {
24315
24302
  var WeaveStageNode = class extends WeaveNode {
24316
24303
  nodeType = WEAVE_STAGE_NODE_TYPE;
24317
24304
  stageFocused = false;
24318
- wheelMousePressed = false;
24319
- isCmdCtrlPressed = false;
24320
24305
  globalEventsInitialized = false;
24321
24306
  initialize = void 0;
24322
24307
  onRender(props) {
@@ -24325,9 +24310,7 @@ var WeaveStageNode = class extends WeaveNode {
24325
24310
  mode: "default"
24326
24311
  });
24327
24312
  setupUpscaleStage(this.instance, stage);
24328
- this.wheelMousePressed = false;
24329
24313
  stage.isFocused = () => this.stageFocused;
24330
- stage.isMouseWheelPressed = () => this.wheelMousePressed;
24331
24314
  stage.position({
24332
24315
  x: 0,
24333
24316
  y: 0
@@ -24363,8 +24346,7 @@ var WeaveStageNode = class extends WeaveNode {
24363
24346
  };
24364
24347
  stage.handleMouseout = function() {};
24365
24348
  stage.mode(WEAVE_STAGE_DEFAULT_MODE);
24366
- stage.on("pointerdown", (e) => {
24367
- if (e.evt.button === 1) this.wheelMousePressed = true;
24349
+ stage.on("pointerdown", () => {
24368
24350
  if (!this.instance.isServerSide() && [MOVE_TOOL_ACTION_NAME].includes(this.instance.getActiveAction() ?? "")) stage.container().style.cursor = "grabbing";
24369
24351
  });
24370
24352
  stage.on("pointermove", (e) => {
@@ -24378,9 +24360,8 @@ var WeaveStageNode = class extends WeaveNode {
24378
24360
  stage$1.container().style.cursor = "default";
24379
24361
  }
24380
24362
  });
24381
- stage.on("pointerup", (e) => {
24363
+ stage.on("pointerup", () => {
24382
24364
  const activeAction = this.instance.getActiveAction();
24383
- if (e.evt.button === 1) this.wheelMousePressed = false;
24384
24365
  if (!this.instance.isServerSide() && [MOVE_TOOL_ACTION_NAME].includes(activeAction ?? "")) stage.container().style.cursor = "grab";
24385
24366
  });
24386
24367
  stage.on("pointerover", (e) => {
@@ -24392,7 +24373,6 @@ var WeaveStageNode = class extends WeaveNode {
24392
24373
  this.hideHoverState();
24393
24374
  if (!this.instance.isServerSide()) stage.container().style.cursor = "default";
24394
24375
  });
24395
- stage.isCmdCtrlPressed = () => this.isCmdCtrlPressed;
24396
24376
  this.setupEvents();
24397
24377
  return stage;
24398
24378
  }
@@ -24400,12 +24380,8 @@ var WeaveStageNode = class extends WeaveNode {
24400
24380
  setupEvents() {
24401
24381
  if (this.globalEventsInitialized) return;
24402
24382
  if (this.instance.isServerSide()) return;
24403
- window.addEventListener("blur", () => {
24404
- this.isCmdCtrlPressed = false;
24405
- }, { signal: this.instance.getEventsController()?.signal });
24406
24383
  window.addEventListener("keydown", (e) => {
24407
24384
  if (this.isOnlyCtrlOrMeta(e)) {
24408
- this.isCmdCtrlPressed = true;
24409
24385
  this.instance.getStage().container().style.cursor = "default";
24410
24386
  const transformer = this.getSelectionPlugin()?.getTransformer();
24411
24387
  if (!transformer) return;
@@ -24416,7 +24392,6 @@ var WeaveStageNode = class extends WeaveNode {
24416
24392
  }, { signal: this.instance.getEventsController()?.signal });
24417
24393
  window.addEventListener("keyup", (e) => {
24418
24394
  if (!(e.ctrlKey || e.metaKey)) {
24419
- this.isCmdCtrlPressed = false;
24420
24395
  this.instance.getStage().container().style.cursor = "default";
24421
24396
  const transformer = this.getSelectionPlugin()?.getTransformer();
24422
24397
  if (!transformer) return;
@@ -25097,28 +25072,12 @@ var WeaveTextNode = class extends WeaveNode {
25097
25072
  }
25098
25073
  initialize() {
25099
25074
  this.keyPressHandler = void 0;
25100
- this.eventsInitialized = false;
25101
- this.isCtrlMetaPressed = false;
25102
25075
  this.textAreaSuperContainer = null;
25103
25076
  this.textAreaContainer = null;
25104
25077
  this.textArea = null;
25105
25078
  this.editing = false;
25106
25079
  this.textArea = null;
25107
25080
  }
25108
- initEvents() {
25109
- if (!this.eventsInitialized && !globalThis._weave_isServerSide) {
25110
- window.addEventListener("blur", () => {
25111
- this.isCtrlMetaPressed = false;
25112
- }, { signal: this.instance.getEventsController()?.signal });
25113
- window.addEventListener("keydown", (e) => {
25114
- if (e.ctrlKey || e.metaKey) this.isCtrlMetaPressed = true;
25115
- }, { signal: this.instance.getEventsController()?.signal });
25116
- window.addEventListener("keyup", (e) => {
25117
- if (!(e.ctrlKey || e.metaKey)) this.isCtrlMetaPressed = false;
25118
- }, { signal: this.instance.getEventsController()?.signal });
25119
- this.eventsInitialized = true;
25120
- }
25121
- }
25122
25081
  updateNode(nodeInstance) {
25123
25082
  const actNode = this.instance.getStage().findOne(`#${nodeInstance.id()}`);
25124
25083
  if (actNode) {
@@ -25154,7 +25113,6 @@ var WeaveTextNode = class extends WeaveNode {
25154
25113
  }
25155
25114
  }
25156
25115
  onRender(props) {
25157
- this.initEvents();
25158
25116
  const text = new Konva.Text({
25159
25117
  ...props,
25160
25118
  name: "node",
@@ -25221,6 +25179,7 @@ var WeaveTextNode = class extends WeaveNode {
25221
25179
  text.setAttr("triggerEditMode", this.triggerEditMode.bind(this));
25222
25180
  let actualAnchor = void 0;
25223
25181
  text.on("transformstart", (e) => {
25182
+ const isCtrlOrMetaPressed = e.evt.ctrlKey || e.evt.metaKey;
25224
25183
  this.instance.emitEvent("onTransform", e.target);
25225
25184
  actualAnchor = this.getNodesSelectionPlugin()?.getTransformer()?.getActiveAnchor();
25226
25185
  if (text.getAttrs().layout === TEXT_LAYOUT.SMART && [
@@ -25228,7 +25187,7 @@ var WeaveTextNode = class extends WeaveNode {
25228
25187
  "top-right",
25229
25188
  "bottom-left",
25230
25189
  "bottom-right"
25231
- ].includes(actualAnchor ?? "") || text.getAttrs().layout === TEXT_LAYOUT.FIXED && this.isCtrlMetaPressed) this.getNodesSelectionPlugin()?.getTransformer()?.keepRatio(true);
25190
+ ].includes(actualAnchor ?? "") || text.getAttrs().layout === TEXT_LAYOUT.FIXED && isCtrlOrMetaPressed) this.getNodesSelectionPlugin()?.getTransformer()?.keepRatio(true);
25232
25191
  else this.getNodesSelectionPlugin()?.getTransformer()?.keepRatio(false);
25233
25192
  if ([TEXT_LAYOUT.AUTO_HEIGHT, TEXT_LAYOUT.SMART].includes(text.getAttrs().layout) && ["middle-right", "middle-left"].includes(actualAnchor ?? "")) {
25234
25193
  text.wrap("word");
@@ -26140,7 +26099,8 @@ var WeaveImageCrop = class WeaveImageCrop {
26140
26099
  this.onClose();
26141
26100
  const utilityLayer = this.instance.getUtilityLayer();
26142
26101
  utilityLayer?.destroyChildren();
26143
- if (stage.isCmdCtrlPressed() && utilityLayer) {
26102
+ const isCtrlOrMetaPressed = e.ctrlKey || e.metaKey;
26103
+ if (isCtrlOrMetaPressed && utilityLayer) {
26144
26104
  this.node.renderCropMode(utilityLayer, this.image);
26145
26105
  utilityLayer.show();
26146
26106
  }
@@ -26676,23 +26636,36 @@ var WeaveImageNode = class extends WeaveNode {
26676
26636
  if (this.imageCrop) this.closeCrop(image, WEAVE_IMAGE_CROP_END_TYPE.CANCEL);
26677
26637
  }
26678
26638
  });
26639
+ image.on("nodeDragStart", () => {
26640
+ const utilityLayer = this.instance.getUtilityLayer();
26641
+ if (!utilityLayer) return;
26642
+ const nodes = utilityLayer?.find(".cropMode") ?? [];
26643
+ nodes.forEach((n) => {
26644
+ n.destroy();
26645
+ });
26646
+ const transformer = this.getSelectionPlugin()?.getTransformer();
26647
+ if (!transformer) return;
26648
+ transformer.show();
26649
+ });
26679
26650
  if (this.config.cropMode.enabled && this.config.cropMode.triggers.ctrlCmd) {
26680
26651
  image.on("onCmdCtrlPressed", () => {
26652
+ const utilityLayer = this.instance.getUtilityLayer();
26653
+ if (!utilityLayer) return;
26654
+ if (image.isDragging()) return;
26681
26655
  const transformer = this.getSelectionPlugin()?.getTransformer();
26682
26656
  if (!transformer) return;
26683
26657
  transformer.hide();
26684
- const utilityLayer = this.instance.getUtilityLayer();
26685
- if (!utilityLayer) return;
26686
26658
  utilityLayer?.destroyChildren();
26687
26659
  this.renderCropMode(utilityLayer, image);
26688
26660
  utilityLayer?.show();
26689
26661
  });
26690
26662
  image.on("onCmdCtrlReleased", () => {
26663
+ const utilityLayer = this.instance.getUtilityLayer();
26664
+ if (!utilityLayer) return;
26665
+ if (image.isDragging()) return;
26691
26666
  const transformer = this.getSelectionPlugin()?.getTransformer();
26692
26667
  if (!transformer) return;
26693
26668
  transformer.show();
26694
- const utilityLayer = this.instance.getUtilityLayer();
26695
- if (!utilityLayer) return;
26696
26669
  utilityLayer?.destroyChildren();
26697
26670
  });
26698
26671
  }
@@ -26751,6 +26724,7 @@ var WeaveImageNode = class extends WeaveNode {
26751
26724
  fill: "transparent",
26752
26725
  strokeScaleEnabled: false,
26753
26726
  strokeWidth: 2,
26727
+ name: "cropMode",
26754
26728
  stroke: "#1a1aff",
26755
26729
  draggable: false,
26756
26730
  listening: false,
@@ -26811,6 +26785,7 @@ var WeaveImageNode = class extends WeaveNode {
26811
26785
  }));
26812
26786
  const anchor = new Konva.Rect({
26813
26787
  draggable: false,
26788
+ name: "cropMode",
26814
26789
  rotation: node.rotation()
26815
26790
  });
26816
26791
  this.config.cropMode.selection.anchorStyleFunc(anchor, position);
@@ -27254,7 +27229,10 @@ var WeaveImageNode = class extends WeaveNode {
27254
27229
  const isMoveContainer = nodeInstance.getAttr("onMoveContainer");
27255
27230
  nodeInstance.setAttr("onMoveContainer", void 0);
27256
27231
  const utilityLayer = this.instance.getUtilityLayer();
27257
- utilityLayer?.destroyChildren();
27232
+ const nodes = utilityLayer?.find(".cropMode") ?? [];
27233
+ nodes.forEach((n) => {
27234
+ n.destroy();
27235
+ });
27258
27236
  if (this.imageTryoutIds[nodeId]) {
27259
27237
  clearTimeout(this.imageTryoutIds[nodeId]);
27260
27238
  delete this.imageTryoutIds[nodeId];
@@ -29859,16 +29837,16 @@ var WeaveVideoNode = class extends WeaveNode {
29859
29837
  }
29860
29838
  if (isServer()) this.instance.updateNode(this.serialize(videoGroup));
29861
29839
  const defaultHandleMouseover = videoGroup.handleMouseover;
29862
- videoGroup.handleMouseover = () => {
29863
- defaultHandleMouseover.call(this);
29840
+ videoGroup.handleMouseover = (e) => {
29841
+ defaultHandleMouseover.call(this, e);
29864
29842
  if (this.config.style.track.onlyOnHover && this.videoState[id].loaded) {
29865
29843
  const videoProgress = videoGroup.findOne(`#${id}-video-progress`);
29866
29844
  videoProgress?.show();
29867
29845
  }
29868
29846
  };
29869
29847
  const defaultHandleMouseout = videoGroup.handleMouseout;
29870
- videoGroup.handleMouseout = () => {
29871
- defaultHandleMouseout.call(this);
29848
+ videoGroup.handleMouseout = (e) => {
29849
+ defaultHandleMouseout.call(e, this);
29872
29850
  if (this.config.style.track.onlyOnHover && this.videoState[id].loaded && !this.videoState[id].paused) {
29873
29851
  const videoProgress = videoGroup.findOne(`#${id}-video-progress`);
29874
29852
  videoProgress?.hide();
@@ -32138,7 +32116,6 @@ var WeaveStageZoomPlugin = class extends WeavePlugin {
32138
32116
  this.zooming = false;
32139
32117
  this.isTrackpad = false;
32140
32118
  this.zoomVelocity = 0;
32141
- this.isCtrlOrMetaPressed = false;
32142
32119
  this.updatedMinimumZoom = false;
32143
32120
  this.actualStep = this.config.zoomSteps.findIndex((step) => step === this.config.defaultZoom);
32144
32121
  this.actualScale = this.config.zoomSteps[this.actualStep];
@@ -32449,15 +32426,6 @@ var WeaveStageZoomPlugin = class extends WeavePlugin {
32449
32426
  };
32450
32427
  }
32451
32428
  initEvents() {
32452
- window.addEventListener("blur", () => {
32453
- this.isCtrlOrMetaPressed = false;
32454
- }, { signal: this.instance.getEventsController()?.signal });
32455
- window.addEventListener("keydown", (e) => {
32456
- if (e.ctrlKey || e.metaKey) this.isCtrlOrMetaPressed = true;
32457
- }, { signal: this.instance.getEventsController()?.signal });
32458
- window.addEventListener("keyup", (e) => {
32459
- if (!(e.ctrlKey || e.metaKey)) this.isCtrlOrMetaPressed = false;
32460
- }, { signal: this.instance.getEventsController()?.signal });
32461
32429
  const stage = this.instance.getStage();
32462
32430
  let lastCenter = null;
32463
32431
  let lastDist = 0;
@@ -32539,7 +32507,8 @@ var WeaveStageZoomPlugin = class extends WeavePlugin {
32539
32507
  });
32540
32508
  let doZoom = false;
32541
32509
  const handleWheelImmediate = (e) => {
32542
- const performZoom = this.isCtrlOrMetaPressed || !this.isCtrlOrMetaPressed && e.ctrlKey && e.deltaMode === 0;
32510
+ const isCtrlOrMetaPressed = e.ctrlKey || e.metaKey;
32511
+ const performZoom = isCtrlOrMetaPressed || !isCtrlOrMetaPressed && e.ctrlKey && e.deltaMode === 0;
32543
32512
  const mouseX = e.clientX;
32544
32513
  const mouseY = e.clientY;
32545
32514
  let elementUnderMouse = document.elementFromPoint(mouseX, mouseY);
@@ -38143,7 +38112,6 @@ var WeaveStagePanningPlugin = class extends WeavePlugin {
38143
38112
  this.moveToolActive = false;
38144
38113
  this.isMouseLeftButtonPressed = false;
38145
38114
  this.isMouseMiddleButtonPressed = false;
38146
- this.isCtrlOrMetaPressed = false;
38147
38115
  this.isSpaceKeyPressed = false;
38148
38116
  this.previousPointer = null;
38149
38117
  this.currentPointer = null;
@@ -38172,11 +38140,7 @@ var WeaveStagePanningPlugin = class extends WeavePlugin {
38172
38140
  }
38173
38141
  initEvents() {
38174
38142
  const stage = this.instance.getStage();
38175
- window.addEventListener("blur", () => {
38176
- this.isCtrlOrMetaPressed = false;
38177
- }, { signal: this.instance.getEventsController()?.signal });
38178
38143
  window.addEventListener("keydown", (e) => {
38179
- if (e.ctrlKey || e.metaKey) this.isCtrlOrMetaPressed = true;
38180
38144
  if (e.code === "Space") {
38181
38145
  this.getContextMenuPlugin()?.disable();
38182
38146
  this.getNodesSelectionPlugin()?.disable();
@@ -38187,7 +38151,6 @@ var WeaveStagePanningPlugin = class extends WeavePlugin {
38187
38151
  }
38188
38152
  }, { signal: this.instance.getEventsController()?.signal });
38189
38153
  window.addEventListener("keyup", (e) => {
38190
- if (e.key === "Meta" || e.key === "Control") this.isCtrlOrMetaPressed = false;
38191
38154
  if (e.code === "Space") {
38192
38155
  this.getContextMenuPlugin()?.enable();
38193
38156
  this.getNodesSelectionPlugin()?.enable();
@@ -38254,7 +38217,8 @@ var WeaveStagePanningPlugin = class extends WeavePlugin {
38254
38217
  this.cleanupEdgeMoveIntervals();
38255
38218
  });
38256
38219
  const handleWheel = (e) => {
38257
- const performPanning = !this.isCtrlOrMetaPressed && !e.ctrlKey;
38220
+ const isCtrlOrMetaPressed = e.ctrlKey || e.metaKey;
38221
+ const performPanning = !isCtrlOrMetaPressed && !e.ctrlKey;
38258
38222
  const mouseX = e.clientX;
38259
38223
  const mouseY = e.clientY;
38260
38224
  let elementUnderMouse = document.elementFromPoint(mouseX, mouseY);
@@ -38262,7 +38226,7 @@ var WeaveStagePanningPlugin = class extends WeavePlugin {
38262
38226
  const shadowHost = getTopmostShadowHost(stage.container());
38263
38227
  if (shadowHost) elementUnderMouse = shadowHost.elementFromPoint(mouseX, mouseY);
38264
38228
  }
38265
- if (!this.enabled || this.isCtrlOrMetaPressed || e.buttons === 4 || !performPanning || this.instance.getClosestParentWithWeaveId(elementUnderMouse) !== stage.container()) return;
38229
+ if (!this.enabled || isCtrlOrMetaPressed || e.buttons === 4 || !performPanning || this.instance.getClosestParentWithWeaveId(elementUnderMouse) !== stage.container()) return;
38266
38230
  this.getContextMenuPlugin()?.cancelLongPressTimer();
38267
38231
  stage.x(stage.x() - e.deltaX);
38268
38232
  stage.y(stage.y() - e.deltaY);
@@ -40519,7 +40483,16 @@ var WeaveCommentsRendererPlugin = class extends WeavePlugin {
40519
40483
  //#endregion
40520
40484
  //#region src/plugins/stage-keyboard-move/constants.ts
40521
40485
  const WEAVE_STAGE_KEYBOARD_MOVE_KEY = "stageKeyboardMove";
40522
- const WEAVE_STAGE_KEYBOARD_MOVE_DEFAULT_CONFIG = { movementDelta: 5 };
40486
+ const WEAVE_STAGE_KEYBOARD_MOVE_DEFAULT_CONFIG = {
40487
+ movementDelta: 1,
40488
+ shiftMovementDelta: 10
40489
+ };
40490
+ const WEAVE_STAGE_KEYBOARD_MOVE_ORIENTATION = {
40491
+ ["UP"]: "up",
40492
+ ["DOWN"]: "down",
40493
+ ["LEFT"]: "left",
40494
+ ["RIGHT"]: "right"
40495
+ };
40523
40496
 
40524
40497
  //#endregion
40525
40498
  //#region src/plugins/stage-keyboard-move/stage-keyboard-move.ts
@@ -40534,25 +40507,31 @@ var WeaveStageKeyboardMovePlugin = class extends WeavePlugin {
40534
40507
  getName() {
40535
40508
  return WEAVE_STAGE_KEYBOARD_MOVE_KEY;
40536
40509
  }
40537
- handleNodesMovement(movementOrientation) {
40510
+ handleNodesMovement(movementOrientation, { isShiftPressed }) {
40538
40511
  const nodesSelectionPlugin = this.instance.getPlugin("nodesSelection");
40539
40512
  if (nodesSelectionPlugin) {
40540
40513
  const selectedNodes = nodesSelectionPlugin.getSelectedNodes();
40514
+ const movementDelta = isShiftPressed ? this.config.shiftMovementDelta : this.config.movementDelta;
40541
40515
  for (const node of selectedNodes) {
40542
40516
  switch (movementOrientation) {
40543
- case "up":
40544
- node.y(node.y() - this.config.movementDelta);
40517
+ case WEAVE_STAGE_KEYBOARD_MOVE_ORIENTATION.UP:
40518
+ node.y(node.y() - movementDelta);
40545
40519
  break;
40546
- case "down":
40547
- node.y(node.y() + this.config.movementDelta);
40520
+ case WEAVE_STAGE_KEYBOARD_MOVE_ORIENTATION.DOWN:
40521
+ node.y(node.y() + movementDelta);
40548
40522
  break;
40549
- case "left":
40550
- node.x(node.x() - this.config.movementDelta);
40523
+ case WEAVE_STAGE_KEYBOARD_MOVE_ORIENTATION.LEFT:
40524
+ node.x(node.x() - movementDelta);
40551
40525
  break;
40552
- case "right":
40553
- node.x(node.x() + this.config.movementDelta);
40526
+ case WEAVE_STAGE_KEYBOARD_MOVE_ORIENTATION.RIGHT:
40527
+ node.x(node.x() + movementDelta);
40554
40528
  break;
40555
40529
  }
40530
+ this.instance.emitEvent("onNodeKeyboardMove", {
40531
+ node,
40532
+ orientation: movementOrientation,
40533
+ delta: movementDelta
40534
+ });
40556
40535
  const nodeHandler = this.instance.getNodeHandler(node.getAttrs().nodeType);
40557
40536
  if (!nodeHandler) break;
40558
40537
  this.instance.updateNode(nodeHandler.serialize(node));
@@ -40561,10 +40540,11 @@ var WeaveStageKeyboardMovePlugin = class extends WeavePlugin {
40561
40540
  }
40562
40541
  onInit() {
40563
40542
  window.addEventListener("keydown", (e) => {
40564
- if (e.code === "ArrowUp" && e.shiftKey) this.handleNodesMovement("up");
40565
- if (e.code === "ArrowLeft" && e.shiftKey) this.handleNodesMovement("left");
40566
- if (e.code === "ArrowRight" && e.shiftKey) this.handleNodesMovement("right");
40567
- if (e.code === "ArrowDown" && e.shiftKey) this.handleNodesMovement("down");
40543
+ const isShiftPressed = e.shiftKey || e.code === "Shift";
40544
+ if (e.code === "ArrowUp") this.handleNodesMovement(WEAVE_STAGE_KEYBOARD_MOVE_ORIENTATION.UP, { isShiftPressed });
40545
+ if (e.code === "ArrowLeft") this.handleNodesMovement(WEAVE_STAGE_KEYBOARD_MOVE_ORIENTATION.LEFT, { isShiftPressed });
40546
+ if (e.code === "ArrowRight") this.handleNodesMovement(WEAVE_STAGE_KEYBOARD_MOVE_ORIENTATION.RIGHT, { isShiftPressed });
40547
+ if (e.code === "ArrowDown") this.handleNodesMovement(WEAVE_STAGE_KEYBOARD_MOVE_ORIENTATION.DOWN, { isShiftPressed });
40568
40548
  }, { signal: this.instance.getEventsController()?.signal });
40569
40549
  }
40570
40550
  enable() {
@@ -40622,4 +40602,4 @@ function getJSONFromYjsBinary(actualState) {
40622
40602
  }
40623
40603
 
40624
40604
  //#endregion
40625
- export { ALIGN_NODES_ALIGN_TO, ALIGN_NODES_TOOL_ACTION_NAME, ALIGN_NODES_TOOL_STATE, BRUSH_TOOL_ACTION_NAME, BRUSH_TOOL_DEFAULT_CONFIG, BRUSH_TOOL_STATE, CONNECTOR_TOOL_ACTION_NAME, CONNECTOR_TOOL_DEFAULT_CONFIG, CONNECTOR_TOOL_STATE, COPY_PASTE_NODES_PLUGIN_STATE, ELLIPSE_TOOL_ACTION_NAME, ELLIPSE_TOOL_STATE, ERASER_TOOL_ACTION_NAME, ERASER_TOOL_STATE, FRAME_TOOL_ACTION_NAME, FRAME_TOOL_STATE, GUIDE_DISTANCE_LINE_DEFAULT_CONFIG, GUIDE_ENTER_SNAPPING_TOLERANCE, GUIDE_EXIT_SNAPPING_TOLERANCE, GUIDE_HORIZONTAL_LINE_NAME, GUIDE_LINE_DEFAULT_CONFIG, GUIDE_LINE_DRAG_SNAPPING_THRESHOLD, GUIDE_LINE_NAME, GUIDE_LINE_TRANSFORM_SNAPPING_THRESHOLD, GUIDE_ORIENTATION, GUIDE_VERTICAL_LINE_NAME, LINE_TOOL_ACTION_NAME, LINE_TOOL_DEFAULT_CONFIG, LINE_TOOL_STATE, MEASURE_TOOL_ACTION_NAME, MEASURE_TOOL_STATE, MOVE_TOOL_ACTION_NAME, MOVE_TOOL_STATE, NODE_SNAP, NODE_SNAP_HORIZONTAL, NODE_SNAP_VERTICAL, PEN_TOOL_ACTION_NAME, PEN_TOOL_STATE, RECTANGLE_TOOL_ACTION_NAME, RECTANGLE_TOOL_STATE, REGULAR_POLYGON_TOOL_ACTION_NAME, REGULAR_POLYGON_TOOL_STATE, SELECTION_TOOL_ACTION_NAME, SELECTION_TOOL_STATE, STAGE_MINIMAP_DEFAULT_CONFIG, STAR_TOOL_ACTION_NAME, STAR_TOOL_STATE, TEXT_LAYOUT, TEXT_TOOL_ACTION_NAME, TEXT_TOOL_STATE, VIDEO_TOOL_ACTION_NAME, VIDEO_TOOL_STATE, WEAVE_ARROW_NODE_TYPE, WEAVE_ARROW_TOOL_ACTION_NAME, WEAVE_ARROW_TOOL_STATE, WEAVE_COMMENTS_RENDERER_KEY, WEAVE_COMMENTS_TOOL_LAYER_ID, WEAVE_COMMENT_CREATE_ACTION, WEAVE_COMMENT_NODE_ACTION, WEAVE_COMMENT_NODE_DEFAULTS, WEAVE_COMMENT_NODE_TYPE, WEAVE_COMMENT_STATUS, WEAVE_COMMENT_TOOL_ACTION_NAME, WEAVE_COMMENT_TOOL_DEFAULT_CONFIG, WEAVE_COMMENT_TOOL_STATE, WEAVE_COMMENT_VIEW_ACTION, WEAVE_CONNECTOR_NODE_ANCHOR_ORIGIN, WEAVE_CONNECTOR_NODE_DECORATOR_TYPE, WEAVE_CONNECTOR_NODE_DEFAULT_CONFIG, WEAVE_CONNECTOR_NODE_LINE_ORIGIN, WEAVE_CONNECTOR_NODE_LINE_TYPE, WEAVE_CONNECTOR_NODE_TYPE, WEAVE_COPY_PASTE_CONFIG_DEFAULT, WEAVE_COPY_PASTE_NODES_KEY, WEAVE_COPY_PASTE_PASTE_CATCHER_ID, WEAVE_COPY_PASTE_PASTE_MODES, WEAVE_DEFAULT_USER_INFO_FUNCTION, WEAVE_ELLIPSE_NODE_TYPE, WEAVE_FRAME_DEFAULT_BACKGROUND_COLOR, WEAVE_FRAME_NODE_DEFAULT_CONFIG, WEAVE_FRAME_NODE_DEFAULT_PROPS, WEAVE_FRAME_NODE_TYPE, WEAVE_GRID_DEFAULT_CONFIG, WEAVE_GRID_DOT_TYPES, WEAVE_GRID_LAYER_ID, WEAVE_GRID_TYPES, WEAVE_GROUP_NODE_TYPE, WEAVE_IMAGES_TOOL_ACTION_NAME, WEAVE_IMAGES_TOOL_DEFAULT_CONFIG, WEAVE_IMAGES_TOOL_STATE, WEAVE_IMAGES_TOOL_UPLOAD_TYPE, WEAVE_IMAGE_CROP_ANCHOR_POSITION, WEAVE_IMAGE_CROP_END_TYPE, WEAVE_IMAGE_DEFAULT_CONFIG, WEAVE_IMAGE_NODE_TYPE, WEAVE_IMAGE_TOOL_ACTION_NAME, WEAVE_IMAGE_TOOL_CONFIG_DEFAULT, WEAVE_IMAGE_TOOL_STATE, WEAVE_IMAGE_TOOL_UPLOAD_TYPE, WEAVE_LAYER_NODE_TYPE, WEAVE_LINE_NODE_DEFAULT_CONFIG, WEAVE_LINE_NODE_TYPE, WEAVE_MEASURE_NODE_DEFAULT_CONFIG, WEAVE_MEASURE_NODE_TYPE, WEAVE_MEASURE_TOOL_DEFAULT_CONFIG, WEAVE_NODES_DISTANCE_SNAPPING_PLUGIN_KEY, WEAVE_NODES_EDGE_SNAPPING_PLUGIN_KEY, WEAVE_NODES_MULTI_SELECTION_FEEDBACK_PLUGIN_DEFAULT_CONFIG, WEAVE_NODES_MULTI_SELECTION_FEEDBACK_PLUGIN_KEY, WEAVE_NODES_MULTI_SELECTION_FEEDBACK_PLUGIN_LAYER_ID, WEAVE_NODES_SELECTION_DEFAULT_CONFIG, WEAVE_NODES_SELECTION_KEY, WEAVE_NODES_SELECTION_LAYER_ID, WEAVE_RECTANGLE_NODE_TYPE, WEAVE_REGULAR_POLYGON_NODE_TYPE, WEAVE_STAGE_DEFAULT_MODE, WEAVE_STAGE_DROP_AREA_KEY, WEAVE_STAGE_GRID_PLUGIN_KEY, WEAVE_STAGE_IMAGE_CROPPING_MODE, WEAVE_STAGE_KEYBOARD_MOVE_DEFAULT_CONFIG, WEAVE_STAGE_KEYBOARD_MOVE_KEY, WEAVE_STAGE_MINIMAP_KEY, WEAVE_STAGE_NODE_TYPE, WEAVE_STAGE_PANNING_DEFAULT_CONFIG, WEAVE_STAGE_PANNING_KEY, WEAVE_STAGE_PANNING_THROTTLE_MS, WEAVE_STAGE_TEXT_EDITION_MODE, WEAVE_STAGE_ZOOM_DEFAULT_CONFIG, WEAVE_STAGE_ZOOM_KEY, WEAVE_STAGE_ZOOM_TYPE, WEAVE_STAR_NODE_TYPE, WEAVE_STROKE_NODE_DEFAULT_CONFIG, WEAVE_STROKE_NODE_TYPE, WEAVE_STROKE_SINGLE_NODE_DEFAULT_CONFIG, WEAVE_STROKE_SINGLE_NODE_TIP_SIDE, WEAVE_STROKE_SINGLE_NODE_TIP_TYPE, WEAVE_STROKE_SINGLE_NODE_TYPE, WEAVE_STROKE_TOOL_ACTION_NAME, WEAVE_STROKE_TOOL_ACTION_NAME_ALIASES, WEAVE_STROKE_TOOL_DEFAULT_CONFIG, WEAVE_STROKE_TOOL_STATE, WEAVE_TEXT_NODE_DEFAULT_CONFIG, WEAVE_TEXT_NODE_TYPE, WEAVE_USERS_POINTERS_CONFIG_DEFAULT_PROPS, WEAVE_USERS_POINTERS_KEY, WEAVE_USERS_PRESENCE_CONFIG_DEFAULT_PROPS, WEAVE_USERS_PRESENCE_PLUGIN_KEY, WEAVE_USERS_SELECTION_KEY, WEAVE_USER_POINTER_KEY, WEAVE_USER_PRESENCE_KEY, WEAVE_USER_SELECTION_KEY, WEAVE_VIDEO_DEFAULT_CONFIG, WEAVE_VIDEO_NODE_TYPE, Weave, WeaveAction, WeaveAlignNodesToolAction, WeaveArrowNode, WeaveArrowToolAction, WeaveBrushToolAction, WeaveCommentNode, WeaveCommentToolAction, WeaveCommentsRendererPlugin, WeaveConnectedUsersPlugin, WeaveConnectorNode, WeaveConnectorToolAction, WeaveContextMenuPlugin, WeaveCopyPasteNodesPlugin, WeaveEllipseNode, WeaveEllipseToolAction, WeaveEraserToolAction, WeaveExportNodesToolAction, WeaveExportStageToolAction, WeaveFitToScreenToolAction, WeaveFitToSelectionToolAction, WeaveFrameNode, WeaveFrameToolAction, WeaveGroupNode, WeaveImageNode, WeaveImageToolAction, WeaveImagesToolAction, WeaveLayerNode, WeaveLineNode, WeaveLineToolAction, WeaveMeasureNode, WeaveMeasureToolAction, WeaveMoveToolAction, WeaveNode, WeaveNodesDistanceSnappingPlugin, WeaveNodesEdgeSnappingPlugin, WeaveNodesMultiSelectionFeedbackPlugin, WeaveNodesSelectionPlugin, WeavePenToolAction, WeavePlugin, WeaveRectangleNode, WeaveRectangleToolAction, WeaveRegularPolygonNode, WeaveRegularPolygonToolAction, WeaveRenderer, WeaveSelectionToolAction, WeaveStageDropAreaPlugin, WeaveStageGridPlugin, WeaveStageKeyboardMovePlugin, WeaveStageMinimapPlugin, WeaveStageNode, WeaveStagePanningPlugin, WeaveStageResizePlugin, WeaveStageZoomPlugin, WeaveStarNode, WeaveStarToolAction, WeaveStore, WeaveStrokeNode, WeaveStrokeSingleNode, WeaveStrokeToolAction, WeaveTextNode, WeaveTextToolAction, WeaveUsersPointersPlugin, WeaveUsersPresencePlugin, WeaveUsersSelectionPlugin, WeaveVideoNode, WeaveVideoToolAction, WeaveZoomInToolAction, WeaveZoomOutToolAction, canComposite, clearContainerTargets, containerOverCursor, containsNodeDeep, defaultInitialState, downscaleImageFile, downscaleImageFromURL, getBoundingBox, getDownscaleRatio, getExportBoundingBox, getImageSizeFromFile, getJSONFromYjsBinary, getPositionRelativeToContainerOnPosition, getSelectedNodesMetadata, getStageClickPoint, getTargetAndSkipNodes, getTargetedNode, getTopmostShadowHost, getVisibleNodes, getVisibleNodesInViewport, hasFrames, hasImages, intersectArrays, isArray, isIOS, isInShadowDOM, isNodeInSelection, isObject, isServer, loadImageSource, mapJsonToYjsArray, mapJsonToYjsElements, mapJsonToYjsMap, memoize, mergeExceptArrays, moveNodeToContainer, moveNodeToContainerNT, resetScale, weavejsToYjsBinary };
40605
+ export { ALIGN_NODES_ALIGN_TO, ALIGN_NODES_TOOL_ACTION_NAME, ALIGN_NODES_TOOL_STATE, BRUSH_TOOL_ACTION_NAME, BRUSH_TOOL_DEFAULT_CONFIG, BRUSH_TOOL_STATE, CONNECTOR_TOOL_ACTION_NAME, CONNECTOR_TOOL_DEFAULT_CONFIG, CONNECTOR_TOOL_STATE, COPY_PASTE_NODES_PLUGIN_STATE, ELLIPSE_TOOL_ACTION_NAME, ELLIPSE_TOOL_STATE, ERASER_TOOL_ACTION_NAME, ERASER_TOOL_STATE, FRAME_TOOL_ACTION_NAME, FRAME_TOOL_STATE, GUIDE_DISTANCE_LINE_DEFAULT_CONFIG, GUIDE_ENTER_SNAPPING_TOLERANCE, GUIDE_EXIT_SNAPPING_TOLERANCE, GUIDE_HORIZONTAL_LINE_NAME, GUIDE_LINE_DEFAULT_CONFIG, GUIDE_LINE_DRAG_SNAPPING_THRESHOLD, GUIDE_LINE_NAME, GUIDE_LINE_TRANSFORM_SNAPPING_THRESHOLD, GUIDE_ORIENTATION, GUIDE_VERTICAL_LINE_NAME, LINE_TOOL_ACTION_NAME, LINE_TOOL_DEFAULT_CONFIG, LINE_TOOL_STATE, MEASURE_TOOL_ACTION_NAME, MEASURE_TOOL_STATE, MOVE_TOOL_ACTION_NAME, MOVE_TOOL_STATE, NODE_SNAP, NODE_SNAP_HORIZONTAL, NODE_SNAP_VERTICAL, PEN_TOOL_ACTION_NAME, PEN_TOOL_STATE, RECTANGLE_TOOL_ACTION_NAME, RECTANGLE_TOOL_STATE, REGULAR_POLYGON_TOOL_ACTION_NAME, REGULAR_POLYGON_TOOL_STATE, SELECTION_TOOL_ACTION_NAME, SELECTION_TOOL_STATE, STAGE_MINIMAP_DEFAULT_CONFIG, STAR_TOOL_ACTION_NAME, STAR_TOOL_STATE, TEXT_LAYOUT, TEXT_TOOL_ACTION_NAME, TEXT_TOOL_STATE, VIDEO_TOOL_ACTION_NAME, VIDEO_TOOL_STATE, WEAVE_ARROW_NODE_TYPE, WEAVE_ARROW_TOOL_ACTION_NAME, WEAVE_ARROW_TOOL_STATE, WEAVE_COMMENTS_RENDERER_KEY, WEAVE_COMMENTS_TOOL_LAYER_ID, WEAVE_COMMENT_CREATE_ACTION, WEAVE_COMMENT_NODE_ACTION, WEAVE_COMMENT_NODE_DEFAULTS, WEAVE_COMMENT_NODE_TYPE, WEAVE_COMMENT_STATUS, WEAVE_COMMENT_TOOL_ACTION_NAME, WEAVE_COMMENT_TOOL_DEFAULT_CONFIG, WEAVE_COMMENT_TOOL_STATE, WEAVE_COMMENT_VIEW_ACTION, WEAVE_CONNECTOR_NODE_ANCHOR_ORIGIN, WEAVE_CONNECTOR_NODE_DECORATOR_TYPE, WEAVE_CONNECTOR_NODE_DEFAULT_CONFIG, WEAVE_CONNECTOR_NODE_LINE_ORIGIN, WEAVE_CONNECTOR_NODE_LINE_TYPE, WEAVE_CONNECTOR_NODE_TYPE, WEAVE_COPY_PASTE_CONFIG_DEFAULT, WEAVE_COPY_PASTE_NODES_KEY, WEAVE_COPY_PASTE_PASTE_CATCHER_ID, WEAVE_COPY_PASTE_PASTE_MODES, WEAVE_DEFAULT_USER_INFO_FUNCTION, WEAVE_ELLIPSE_NODE_TYPE, WEAVE_FRAME_DEFAULT_BACKGROUND_COLOR, WEAVE_FRAME_NODE_DEFAULT_CONFIG, WEAVE_FRAME_NODE_DEFAULT_PROPS, WEAVE_FRAME_NODE_TYPE, WEAVE_GRID_DEFAULT_CONFIG, WEAVE_GRID_DOT_TYPES, WEAVE_GRID_LAYER_ID, WEAVE_GRID_TYPES, WEAVE_GROUP_NODE_TYPE, WEAVE_IMAGES_TOOL_ACTION_NAME, WEAVE_IMAGES_TOOL_DEFAULT_CONFIG, WEAVE_IMAGES_TOOL_STATE, WEAVE_IMAGES_TOOL_UPLOAD_TYPE, WEAVE_IMAGE_CROP_ANCHOR_POSITION, WEAVE_IMAGE_CROP_END_TYPE, WEAVE_IMAGE_DEFAULT_CONFIG, WEAVE_IMAGE_NODE_TYPE, WEAVE_IMAGE_TOOL_ACTION_NAME, WEAVE_IMAGE_TOOL_CONFIG_DEFAULT, WEAVE_IMAGE_TOOL_STATE, WEAVE_IMAGE_TOOL_UPLOAD_TYPE, WEAVE_LAYER_NODE_TYPE, WEAVE_LINE_NODE_DEFAULT_CONFIG, WEAVE_LINE_NODE_TYPE, WEAVE_MEASURE_NODE_DEFAULT_CONFIG, WEAVE_MEASURE_NODE_TYPE, WEAVE_MEASURE_TOOL_DEFAULT_CONFIG, WEAVE_NODES_DISTANCE_SNAPPING_PLUGIN_KEY, WEAVE_NODES_EDGE_SNAPPING_PLUGIN_KEY, WEAVE_NODES_MULTI_SELECTION_FEEDBACK_PLUGIN_DEFAULT_CONFIG, WEAVE_NODES_MULTI_SELECTION_FEEDBACK_PLUGIN_KEY, WEAVE_NODES_MULTI_SELECTION_FEEDBACK_PLUGIN_LAYER_ID, WEAVE_NODES_SELECTION_DEFAULT_CONFIG, WEAVE_NODES_SELECTION_KEY, WEAVE_NODES_SELECTION_LAYER_ID, WEAVE_RECTANGLE_NODE_TYPE, WEAVE_REGULAR_POLYGON_NODE_TYPE, WEAVE_STAGE_DEFAULT_MODE, WEAVE_STAGE_DROP_AREA_KEY, WEAVE_STAGE_GRID_PLUGIN_KEY, WEAVE_STAGE_IMAGE_CROPPING_MODE, WEAVE_STAGE_KEYBOARD_MOVE_DEFAULT_CONFIG, WEAVE_STAGE_KEYBOARD_MOVE_KEY, WEAVE_STAGE_KEYBOARD_MOVE_ORIENTATION, WEAVE_STAGE_MINIMAP_KEY, WEAVE_STAGE_NODE_TYPE, WEAVE_STAGE_PANNING_DEFAULT_CONFIG, WEAVE_STAGE_PANNING_KEY, WEAVE_STAGE_PANNING_THROTTLE_MS, WEAVE_STAGE_TEXT_EDITION_MODE, WEAVE_STAGE_ZOOM_DEFAULT_CONFIG, WEAVE_STAGE_ZOOM_KEY, WEAVE_STAGE_ZOOM_TYPE, WEAVE_STAR_NODE_TYPE, WEAVE_STROKE_NODE_DEFAULT_CONFIG, WEAVE_STROKE_NODE_TYPE, WEAVE_STROKE_SINGLE_NODE_DEFAULT_CONFIG, WEAVE_STROKE_SINGLE_NODE_TIP_SIDE, WEAVE_STROKE_SINGLE_NODE_TIP_TYPE, WEAVE_STROKE_SINGLE_NODE_TYPE, WEAVE_STROKE_TOOL_ACTION_NAME, WEAVE_STROKE_TOOL_ACTION_NAME_ALIASES, WEAVE_STROKE_TOOL_DEFAULT_CONFIG, WEAVE_STROKE_TOOL_STATE, WEAVE_TEXT_NODE_DEFAULT_CONFIG, WEAVE_TEXT_NODE_TYPE, WEAVE_USERS_POINTERS_CONFIG_DEFAULT_PROPS, WEAVE_USERS_POINTERS_KEY, WEAVE_USERS_PRESENCE_CONFIG_DEFAULT_PROPS, WEAVE_USERS_PRESENCE_PLUGIN_KEY, WEAVE_USERS_SELECTION_KEY, WEAVE_USER_POINTER_KEY, WEAVE_USER_PRESENCE_KEY, WEAVE_USER_SELECTION_KEY, WEAVE_VIDEO_DEFAULT_CONFIG, WEAVE_VIDEO_NODE_TYPE, Weave, WeaveAction, WeaveAlignNodesToolAction, WeaveArrowNode, WeaveArrowToolAction, WeaveBrushToolAction, WeaveCommentNode, WeaveCommentToolAction, WeaveCommentsRendererPlugin, WeaveConnectedUsersPlugin, WeaveConnectorNode, WeaveConnectorToolAction, WeaveContextMenuPlugin, WeaveCopyPasteNodesPlugin, WeaveEllipseNode, WeaveEllipseToolAction, WeaveEraserToolAction, WeaveExportNodesToolAction, WeaveExportStageToolAction, WeaveFitToScreenToolAction, WeaveFitToSelectionToolAction, WeaveFrameNode, WeaveFrameToolAction, WeaveGroupNode, WeaveImageNode, WeaveImageToolAction, WeaveImagesToolAction, WeaveLayerNode, WeaveLineNode, WeaveLineToolAction, WeaveMeasureNode, WeaveMeasureToolAction, WeaveMoveToolAction, WeaveNode, WeaveNodesDistanceSnappingPlugin, WeaveNodesEdgeSnappingPlugin, WeaveNodesMultiSelectionFeedbackPlugin, WeaveNodesSelectionPlugin, WeavePenToolAction, WeavePlugin, WeaveRectangleNode, WeaveRectangleToolAction, WeaveRegularPolygonNode, WeaveRegularPolygonToolAction, WeaveRenderer, WeaveSelectionToolAction, WeaveStageDropAreaPlugin, WeaveStageGridPlugin, WeaveStageKeyboardMovePlugin, WeaveStageMinimapPlugin, WeaveStageNode, WeaveStagePanningPlugin, WeaveStageResizePlugin, WeaveStageZoomPlugin, WeaveStarNode, WeaveStarToolAction, WeaveStore, WeaveStrokeNode, WeaveStrokeSingleNode, WeaveStrokeToolAction, WeaveTextNode, WeaveTextToolAction, WeaveUsersPointersPlugin, WeaveUsersPresencePlugin, WeaveUsersSelectionPlugin, WeaveVideoNode, WeaveVideoToolAction, WeaveZoomInToolAction, WeaveZoomOutToolAction, canComposite, clearContainerTargets, containerOverCursor, containsNodeDeep, defaultInitialState, downscaleImageFile, downscaleImageFromURL, getBoundingBox, getDownscaleRatio, getExportBoundingBox, getImageSizeFromFile, getJSONFromYjsBinary, getPositionRelativeToContainerOnPosition, getSelectedNodesMetadata, getStageClickPoint, getTargetAndSkipNodes, getTargetedNode, getTopmostShadowHost, getVisibleNodes, getVisibleNodesInViewport, hasFrames, hasImages, intersectArrays, isArray, isIOS, isInShadowDOM, isNodeInSelection, isObject, isServer, loadImageSource, mapJsonToYjsArray, mapJsonToYjsElements, mapJsonToYjsMap, memoize, mergeExceptArrays, moveNodeToContainer, moveNodeToContainerNT, resetScale, weavejsToYjsBinary };