@lvce-editor/renderer-process 10.10.0 → 10.11.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/rendererProcessMain.js +100 -61
- package/package.json +1 -1
|
@@ -1924,7 +1924,7 @@ const setOffsetX = (state, offsetX) => {
|
|
|
1924
1924
|
setXAndYTransform($ColorPickerSliderThumb, offsetX, 0);
|
|
1925
1925
|
applyUidWorkaround($Viewlet);
|
|
1926
1926
|
};
|
|
1927
|
-
const appendWidget$
|
|
1927
|
+
const appendWidget$3 = state => {
|
|
1928
1928
|
const {
|
|
1929
1929
|
$Viewlet
|
|
1930
1930
|
} = state;
|
|
@@ -1934,7 +1934,7 @@ const appendWidget$2 = state => {
|
|
|
1934
1934
|
const ViewletColorPicker = {
|
|
1935
1935
|
__proto__: null,
|
|
1936
1936
|
Events: ViewletColorPickerEvents,
|
|
1937
|
-
appendWidget: appendWidget$
|
|
1937
|
+
appendWidget: appendWidget$3,
|
|
1938
1938
|
setColor,
|
|
1939
1939
|
setOffsetX
|
|
1940
1940
|
};
|
|
@@ -2318,7 +2318,7 @@ const attachEvents$b = state => {
|
|
|
2318
2318
|
// TODO show should be passed active cursor position
|
|
2319
2319
|
// this would make this function easier to test as it would avoid dependency on globals of other files
|
|
2320
2320
|
|
|
2321
|
-
const setDom$
|
|
2321
|
+
const setDom$b = (state, dom) => {
|
|
2322
2322
|
const {
|
|
2323
2323
|
$ListItems,
|
|
2324
2324
|
$Viewlet
|
|
@@ -2365,7 +2365,7 @@ const ViewletEditorCompletion = {
|
|
|
2365
2365
|
handleError: handleError$8,
|
|
2366
2366
|
setBounds: setBounds$7,
|
|
2367
2367
|
setContentHeight,
|
|
2368
|
-
setDom: setDom$
|
|
2368
|
+
setDom: setDom$b,
|
|
2369
2369
|
setNegativeMargin,
|
|
2370
2370
|
setScrollBar: setScrollBar$2,
|
|
2371
2371
|
setSize,
|
|
@@ -2394,7 +2394,7 @@ const create$I = () => {
|
|
|
2394
2394
|
const attachEvents$a = state => {
|
|
2395
2395
|
// TODO
|
|
2396
2396
|
};
|
|
2397
|
-
const setDom$
|
|
2397
|
+
const setDom$a = (state, dom) => {
|
|
2398
2398
|
const {
|
|
2399
2399
|
$Viewlet
|
|
2400
2400
|
} = state;
|
|
@@ -2403,7 +2403,7 @@ const setDom$9 = (state, dom) => {
|
|
|
2403
2403
|
$Viewlet.replaceChildren(...$Root.firstChild.childNodes);
|
|
2404
2404
|
append$1($Viewlet);
|
|
2405
2405
|
};
|
|
2406
|
-
const appendWidget$
|
|
2406
|
+
const appendWidget$2 = state => {
|
|
2407
2407
|
const {
|
|
2408
2408
|
$Viewlet
|
|
2409
2409
|
} = state;
|
|
@@ -2422,16 +2422,71 @@ const setBounds$6 = (state, x, y, width, height) => {
|
|
|
2422
2422
|
const ViewletEditorCompletionDetails = {
|
|
2423
2423
|
__proto__: null,
|
|
2424
2424
|
Events: ViewletEditorCompletionDetailsEvents,
|
|
2425
|
-
appendWidget: appendWidget$
|
|
2425
|
+
appendWidget: appendWidget$2,
|
|
2426
2426
|
attachEvents: attachEvents$a,
|
|
2427
2427
|
create: create$I,
|
|
2428
2428
|
dispose: dispose$j,
|
|
2429
2429
|
setBounds: setBounds$6,
|
|
2430
|
-
setDom: setDom$
|
|
2430
|
+
setDom: setDom$a
|
|
2431
2431
|
};
|
|
2432
2432
|
|
|
2433
2433
|
const rememberFocus = rememberFocus$1;
|
|
2434
2434
|
|
|
2435
|
+
const returnValue$9 = true;
|
|
2436
|
+
const handleSashPointerDown$2 = create$K(event => {
|
|
2437
|
+
const {
|
|
2438
|
+
clientX,
|
|
2439
|
+
clientY
|
|
2440
|
+
} = event;
|
|
2441
|
+
return ['handleSashPointerDown', clientX, clientY];
|
|
2442
|
+
}, event => {
|
|
2443
|
+
const {
|
|
2444
|
+
clientX,
|
|
2445
|
+
clientY
|
|
2446
|
+
} = event;
|
|
2447
|
+
return ['handleSashPointerMove', clientX, clientY];
|
|
2448
|
+
}, event => {
|
|
2449
|
+
const {
|
|
2450
|
+
clientX,
|
|
2451
|
+
clientY
|
|
2452
|
+
} = event;
|
|
2453
|
+
return ['handleSashPointerUp', clientX, clientY];
|
|
2454
|
+
});
|
|
2455
|
+
|
|
2456
|
+
const ViewletEditorHoverEvents = {
|
|
2457
|
+
__proto__: null,
|
|
2458
|
+
handleSashPointerDown: handleSashPointerDown$2,
|
|
2459
|
+
returnValue: returnValue$9
|
|
2460
|
+
};
|
|
2461
|
+
|
|
2462
|
+
const setBounds$5 = (state, x, y, width, height) => {
|
|
2463
|
+
const {
|
|
2464
|
+
$Viewlet
|
|
2465
|
+
} = state;
|
|
2466
|
+
setWidth($Viewlet, width);
|
|
2467
|
+
setXAndYTransform($Viewlet, x, -y);
|
|
2468
|
+
};
|
|
2469
|
+
const appendWidget$1 = state => {
|
|
2470
|
+
const {
|
|
2471
|
+
$Viewlet
|
|
2472
|
+
} = state;
|
|
2473
|
+
append$1($Viewlet);
|
|
2474
|
+
};
|
|
2475
|
+
const setDom$9 = (state, dom) => {
|
|
2476
|
+
const {
|
|
2477
|
+
$Viewlet
|
|
2478
|
+
} = state;
|
|
2479
|
+
rememberFocus($Viewlet, dom, ViewletEditorHoverEvents, 0);
|
|
2480
|
+
};
|
|
2481
|
+
|
|
2482
|
+
const ViewletEditorHover = {
|
|
2483
|
+
__proto__: null,
|
|
2484
|
+
Events: ViewletEditorHoverEvents,
|
|
2485
|
+
appendWidget: appendWidget$1,
|
|
2486
|
+
setBounds: setBounds$5,
|
|
2487
|
+
setDom: setDom$9
|
|
2488
|
+
};
|
|
2489
|
+
|
|
2435
2490
|
const handleInput$7 = event => {
|
|
2436
2491
|
const {
|
|
2437
2492
|
target
|
|
@@ -2477,7 +2532,22 @@ const handleReplaceFocus = event => {
|
|
|
2477
2532
|
const handleFocus$b = event => {
|
|
2478
2533
|
return ['FindWidget.handleFocus'];
|
|
2479
2534
|
};
|
|
2480
|
-
const
|
|
2535
|
+
const handleToggleReplaceFocus = event => {
|
|
2536
|
+
return ['FindWidget.handleToggleReplaceFocus'];
|
|
2537
|
+
};
|
|
2538
|
+
const handleFocusPrevious = event => {
|
|
2539
|
+
return ['FindWidget.handleFocusPrevious'];
|
|
2540
|
+
};
|
|
2541
|
+
const handleFocusNext = event => {
|
|
2542
|
+
return ['FindWidget.handleFocusNext'];
|
|
2543
|
+
};
|
|
2544
|
+
const handleFocusClose = event => {
|
|
2545
|
+
return ['FindWidget.handleFocusClose'];
|
|
2546
|
+
};
|
|
2547
|
+
const handleFocusReplaceAll = event => {
|
|
2548
|
+
return ['FindWidget.handleFocusReplaceAll'];
|
|
2549
|
+
};
|
|
2550
|
+
const returnValue$8 = true;
|
|
2481
2551
|
|
|
2482
2552
|
const ViewletFindWidgetEvents = {
|
|
2483
2553
|
__proto__: null,
|
|
@@ -2488,11 +2558,16 @@ const ViewletFindWidgetEvents = {
|
|
|
2488
2558
|
handleClickReplaceAll,
|
|
2489
2559
|
handleClickToggleReplace,
|
|
2490
2560
|
handleFocus: handleFocus$b,
|
|
2561
|
+
handleFocusClose,
|
|
2562
|
+
handleFocusNext,
|
|
2563
|
+
handleFocusPrevious,
|
|
2564
|
+
handleFocusReplaceAll,
|
|
2491
2565
|
handleInput: handleInput$7,
|
|
2492
2566
|
handleInputBlur,
|
|
2493
2567
|
handleReplaceFocus,
|
|
2494
2568
|
handleReplaceInput: handleReplaceInput$1,
|
|
2495
|
-
|
|
2569
|
+
handleToggleReplaceFocus,
|
|
2570
|
+
returnValue: returnValue$8
|
|
2496
2571
|
};
|
|
2497
2572
|
|
|
2498
2573
|
const create$H = () => {
|
|
@@ -2504,6 +2579,9 @@ const create$H = () => {
|
|
|
2504
2579
|
};
|
|
2505
2580
|
};
|
|
2506
2581
|
const focus$i = (state, key, source) => {
|
|
2582
|
+
if (!key) {
|
|
2583
|
+
return;
|
|
2584
|
+
}
|
|
2507
2585
|
if (source !== /* script */2) {
|
|
2508
2586
|
return;
|
|
2509
2587
|
}
|
|
@@ -2512,6 +2590,7 @@ const focus$i = (state, key, source) => {
|
|
|
2512
2590
|
} = state;
|
|
2513
2591
|
const $Element = $Viewlet.querySelector(key);
|
|
2514
2592
|
if (!$Element) {
|
|
2593
|
+
console.warn(`element not found: ${key}`);
|
|
2515
2594
|
return;
|
|
2516
2595
|
}
|
|
2517
2596
|
$Element.focus();
|
|
@@ -2539,7 +2618,7 @@ const setDom$8 = (state, dom) => {
|
|
|
2539
2618
|
} = state;
|
|
2540
2619
|
rememberFocus($Viewlet, dom, ViewletFindWidgetEvents, 0);
|
|
2541
2620
|
};
|
|
2542
|
-
const setBounds$
|
|
2621
|
+
const setBounds$4 = (state, x, y, width, height) => {
|
|
2543
2622
|
const {
|
|
2544
2623
|
$Viewlet
|
|
2545
2624
|
} = state;
|
|
@@ -2553,7 +2632,7 @@ const ViewletFindWidget = {
|
|
|
2553
2632
|
appendWidget,
|
|
2554
2633
|
create: create$H,
|
|
2555
2634
|
focus: focus$i,
|
|
2556
|
-
setBounds: setBounds$
|
|
2635
|
+
setBounds: setBounds$4,
|
|
2557
2636
|
setDom: setDom$8,
|
|
2558
2637
|
setValue: setValue$4
|
|
2559
2638
|
};
|
|
@@ -2961,6 +3040,7 @@ const main = async () => {
|
|
|
2961
3040
|
state$6.modules[EditorCompletionDetails] = ViewletEditorCompletionDetails;
|
|
2962
3041
|
state$6.modules[ColorPicker] = ViewletColorPicker;
|
|
2963
3042
|
state$6.modules[FindWidget] = ViewletFindWidget;
|
|
3043
|
+
state$6.modules[EditorHover] = ViewletEditorHover;
|
|
2964
3044
|
setLoad(load$2);
|
|
2965
3045
|
// TODO this is discovered very late
|
|
2966
3046
|
await launchWorkers();
|
|
@@ -5835,7 +5915,7 @@ const sendMultiple = commands => {
|
|
|
5835
5915
|
case 'Viewlet.setBounds':
|
|
5836
5916
|
{
|
|
5837
5917
|
// @ts-expect-error
|
|
5838
|
-
setBounds$
|
|
5918
|
+
setBounds$3(viewletId, method, ...args);
|
|
5839
5919
|
break;
|
|
5840
5920
|
}
|
|
5841
5921
|
case 'Viewlet.create':
|
|
@@ -6045,7 +6125,7 @@ const getFn = command => {
|
|
|
6045
6125
|
case 'Viewlet.setDom2':
|
|
6046
6126
|
return setDom2;
|
|
6047
6127
|
case 'Viewlet.setBounds':
|
|
6048
|
-
return setBounds$
|
|
6128
|
+
return setBounds$3;
|
|
6049
6129
|
case 'Viewlet.ariaAnnounce':
|
|
6050
6130
|
return ariaAnnounce;
|
|
6051
6131
|
case 'Viewlet.append':
|
|
@@ -6085,7 +6165,7 @@ const show = id => {
|
|
|
6085
6165
|
instance.factory.focus(instance.state);
|
|
6086
6166
|
}
|
|
6087
6167
|
};
|
|
6088
|
-
const setBounds$
|
|
6168
|
+
const setBounds$3 = (id, left, top, width, height) => {
|
|
6089
6169
|
const instance = state$6.instances[id];
|
|
6090
6170
|
if (!instance) {
|
|
6091
6171
|
return;
|
|
@@ -6109,7 +6189,7 @@ const Commands$9 = {
|
|
|
6109
6189
|
removeKeyBindings: removeKeyBindings,
|
|
6110
6190
|
send: invoke,
|
|
6111
6191
|
sendMultiple: sendMultiple,
|
|
6112
|
-
setBounds: setBounds$
|
|
6192
|
+
setBounds: setBounds$3,
|
|
6113
6193
|
show: show
|
|
6114
6194
|
};
|
|
6115
6195
|
|
|
@@ -6486,7 +6566,7 @@ const handleContextMenu$b = event => {
|
|
|
6486
6566
|
} = event;
|
|
6487
6567
|
return ['handleContextMenu', button, clientX, clientY];
|
|
6488
6568
|
};
|
|
6489
|
-
const returnValue$
|
|
6569
|
+
const returnValue$7 = true;
|
|
6490
6570
|
|
|
6491
6571
|
const ViewletActivityBarEvents = {
|
|
6492
6572
|
__proto__: null,
|
|
@@ -6494,7 +6574,7 @@ const ViewletActivityBarEvents = {
|
|
|
6494
6574
|
handleContextMenu: handleContextMenu$b,
|
|
6495
6575
|
handleFocus: handleFocus$a,
|
|
6496
6576
|
handleMouseDown: handleMouseDown$2,
|
|
6497
|
-
returnValue: returnValue$
|
|
6577
|
+
returnValue: returnValue$7
|
|
6498
6578
|
};
|
|
6499
6579
|
|
|
6500
6580
|
const Events$b = ViewletActivityBarEvents;
|
|
@@ -6835,7 +6915,7 @@ const setDom$4 = (state, dom) => {
|
|
|
6835
6915
|
} = state;
|
|
6836
6916
|
renderInto($Viewlet, dom);
|
|
6837
6917
|
};
|
|
6838
|
-
const setBounds$
|
|
6918
|
+
const setBounds$2 = (state, x, y, width, height) => {
|
|
6839
6919
|
const {
|
|
6840
6920
|
$Viewlet
|
|
6841
6921
|
} = state;
|
|
@@ -6845,51 +6925,10 @@ const setBounds$3 = (state, x, y, width, height) => {
|
|
|
6845
6925
|
const ViewletEditorError = {
|
|
6846
6926
|
__proto__: null,
|
|
6847
6927
|
create: create$o,
|
|
6848
|
-
setBounds: setBounds$
|
|
6928
|
+
setBounds: setBounds$2,
|
|
6849
6929
|
setDom: setDom$4
|
|
6850
6930
|
};
|
|
6851
6931
|
|
|
6852
|
-
const returnValue$7 = true;
|
|
6853
|
-
const handleSashPointerDown$2 = create$K(event => {
|
|
6854
|
-
const {
|
|
6855
|
-
clientX,
|
|
6856
|
-
clientY
|
|
6857
|
-
} = event;
|
|
6858
|
-
return ['handleSashPointerDown', clientX, clientY];
|
|
6859
|
-
}, event => {
|
|
6860
|
-
const {
|
|
6861
|
-
clientX,
|
|
6862
|
-
clientY
|
|
6863
|
-
} = event;
|
|
6864
|
-
return ['handleSashPointerMove', clientX, clientY];
|
|
6865
|
-
}, event => {
|
|
6866
|
-
const {
|
|
6867
|
-
clientX,
|
|
6868
|
-
clientY
|
|
6869
|
-
} = event;
|
|
6870
|
-
return ['handleSashPointerUp', clientX, clientY];
|
|
6871
|
-
});
|
|
6872
|
-
|
|
6873
|
-
const ViewletEditorHoverEvents = {
|
|
6874
|
-
__proto__: null,
|
|
6875
|
-
handleSashPointerDown: handleSashPointerDown$2,
|
|
6876
|
-
returnValue: returnValue$7
|
|
6877
|
-
};
|
|
6878
|
-
|
|
6879
|
-
const setBounds$2 = (state, x, y, width, height) => {
|
|
6880
|
-
const {
|
|
6881
|
-
$Viewlet
|
|
6882
|
-
} = state;
|
|
6883
|
-
setWidth($Viewlet, width);
|
|
6884
|
-
setXAndYTransform($Viewlet, x, -y);
|
|
6885
|
-
};
|
|
6886
|
-
|
|
6887
|
-
const ViewletEditorHover = {
|
|
6888
|
-
__proto__: null,
|
|
6889
|
-
Events: ViewletEditorHoverEvents,
|
|
6890
|
-
setBounds: setBounds$2
|
|
6891
|
-
};
|
|
6892
|
-
|
|
6893
6932
|
const LeftClick = 0;
|
|
6894
6933
|
const RightClick = 2;
|
|
6895
6934
|
|