@lvce-editor/renderer-process 30.21.1 → 30.21.2

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.
@@ -3913,7 +3913,7 @@ const getLevel = $Menu => {
3913
3913
  // @ts-expect-error
3914
3914
  return state$4.$$Menus.indexOf($Menu);
3915
3915
  };
3916
- const handleMouseDown$2 = event => {
3916
+ const handleMouseDown$4 = event => {
3917
3917
  const $Target = event.target;
3918
3918
  const $Menu = $Target.closest('.Menu');
3919
3919
  const index = findIndex($Menu, $Target);
@@ -3990,7 +3990,7 @@ const create$Menu$1 = () => {
3990
3990
  $Menu.tabIndex = -1;
3991
3991
  // $ContextMenu.onmousedown = contextMenuHandleMouseDown
3992
3992
  // TODO mousedown vs click? (click is usually better but mousedown is faster, why wait 100ms?)
3993
- $Menu.addEventListener(MouseDown, handleMouseDown$2);
3993
+ $Menu.addEventListener(MouseDown, handleMouseDown$4);
3994
3994
  $Menu.addEventListener(MouseEnter, handleMouseEnter, {
3995
3995
  capture: true
3996
3996
  });
@@ -5096,7 +5096,7 @@ const getNodeIndex = $Node => {
5096
5096
  const get$ItemFromEvent = event => {
5097
5097
  return event.target.closest?.('.ActivityBarItem');
5098
5098
  };
5099
- const handleMouseDown$1 = event => {
5099
+ const handleMouseDown$3 = event => {
5100
5100
  const {
5101
5101
  button,
5102
5102
  clientX,
@@ -5136,7 +5136,7 @@ const ViewletActivityBarEvents = {
5136
5136
  handleBlur: handleBlur$7,
5137
5137
  handleContextMenu: handleContextMenu$6,
5138
5138
  handleFocus: handleFocus$8,
5139
- handleMouseDown: handleMouseDown$1,
5139
+ handleMouseDown: handleMouseDown$3,
5140
5140
  returnValue: returnValue$8
5141
5141
  };
5142
5142
 
@@ -5219,7 +5219,7 @@ forwardViewletCommand('handleListBlur');
5219
5219
  forwardViewletCommand('handleListFocus');
5220
5220
  const handleMenuClick$1 = forwardViewletCommand('handleMenuClick');
5221
5221
  const handleMenuMouseOver$1 = forwardViewletCommand('handleMenuMouseOver');
5222
- forwardViewletCommand('handleMouseDown');
5222
+ const handleMouseDown$2 = forwardViewletCommand('handleMouseDown');
5223
5223
  forwardViewletCommand('handleMouseMove');
5224
5224
  const handleMouseOut$1 = forwardViewletCommand('handleMouseOut');
5225
5225
  const handleMouseOver$1 = forwardViewletCommand('handleMouseOver');
@@ -7552,7 +7552,7 @@ const handleClickTab$1 = (target, uid) => {
7552
7552
  const index = getNodeIndex(target);
7553
7553
  selectIndex(uid, index);
7554
7554
  };
7555
- const handleClickAction$1 = (target, uid) => {
7555
+ const handleClickAction$1 = target => {
7556
7556
  const index = getNodeIndex(target);
7557
7557
  const {
7558
7558
  command
@@ -7562,7 +7562,8 @@ const handleClickAction$1 = (target, uid) => {
7562
7562
  console.info('[panel] action command not found');
7563
7563
  return;
7564
7564
  }
7565
- handleClickAction$2(uid, index, command);
7565
+ const childUid = get(target);
7566
+ handleClickAction$2(childUid, index, command);
7566
7567
  };
7567
7568
  const handleHeaderClick$1 = event => {
7568
7569
  const {
@@ -7575,7 +7576,7 @@ const handleHeaderClick$1 = event => {
7575
7576
  }
7576
7577
  const action = target.closest?.('.IconButton[data-command]');
7577
7578
  if (action) {
7578
- handleClickAction$1(action, uid);
7579
+ handleClickAction$1(action);
7579
7580
  }
7580
7581
  };
7581
7582
 
@@ -8110,10 +8111,26 @@ const handleClickTab = event => {
8110
8111
  const shouldDelete = Boolean(target.closest?.('.TerminalTabDeleteButton'));
8111
8112
  handleClickTab$2(uid, index, shouldDelete);
8112
8113
  };
8114
+ const handleMouseDown$1 = event => {
8115
+ const uid = fromEvent(event);
8116
+ const {
8117
+ target
8118
+ } = event;
8119
+ const terminal = target.closest?.('.XtermTerminal');
8120
+ if (!terminal) {
8121
+ return;
8122
+ }
8123
+ const terminalUid = get(terminal);
8124
+ if (!terminalUid) {
8125
+ return;
8126
+ }
8127
+ handleMouseDown$2(uid, terminalUid);
8128
+ };
8113
8129
 
8114
8130
  const ViewletTerminalsEvents = {
8115
8131
  __proto__: null,
8116
- handleClickTab
8132
+ handleClickTab,
8133
+ handleMouseDown: handleMouseDown$1
8117
8134
  };
8118
8135
 
8119
8136
  const Events$1 = ViewletTerminalsEvents;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@lvce-editor/renderer-process",
3
- "version": "30.21.1",
3
+ "version": "30.21.2",
4
4
  "keywords": [
5
5
  "lvce-editor",
6
6
  "renderer-process"