@lvce-editor/editor-worker 19.68.2 → 19.68.3
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/editorWorkerMain.js +24 -6
- package/package.json +1 -1
package/dist/editorWorkerMain.js
CHANGED
|
@@ -5910,7 +5910,7 @@ const isEqual$3 = (oldState, newState) => {
|
|
|
5910
5910
|
};
|
|
5911
5911
|
|
|
5912
5912
|
const isEqual$2 = (oldState, newState) => {
|
|
5913
|
-
return oldState.breadcrumbFileIcon === newState.breadcrumbFileIcon && oldState.breadcrumbsEnabled === newState.breadcrumbsEnabled && oldState.breakPoints === newState.breakPoints && oldState.bracketMatchInfos === newState.bracketMatchInfos && oldState.cursorInfos === newState.cursorInfos && oldState.diagnostics === newState.diagnostics && oldState.documentSymbols === newState.documentSymbols && oldState.endOfLineDecorations === newState.endOfLineDecorations && oldState.focused === newState.focused && oldState.gutterDecorations === newState.gutterDecorations && oldState.highlightActiveLineNumber === newState.highlightActiveLineNumber && oldState.highlightedLine === newState.highlightedLine && oldState.problemsHighlightedRow === newState.problemsHighlightedRow && oldState.lineNumbers === newState.lineNumbers && oldState.loadError === newState.loadError && oldState.textInfos === newState.textInfos && oldState.visibleViewLineIndices === newState.visibleViewLineIndices && oldState.differences === newState.differences && oldState.initial === newState.initial && oldState.selectionInfos === newState.selectionInfos && oldState.selections === newState.selections && oldState.workspaceUri === newState.workspaceUri;
|
|
5913
|
+
return oldState.breadcrumbFileIcon === newState.breadcrumbFileIcon && oldState.breadcrumbsEnabled === newState.breadcrumbsEnabled && oldState.breakPoints === newState.breakPoints && oldState.bracketMatchInfos === newState.bracketMatchInfos && oldState.cursorInfos === newState.cursorInfos && oldState.diagnostics === newState.diagnostics && oldState.documentSymbols === newState.documentSymbols && oldState.endOfLineDecorations === newState.endOfLineDecorations && oldState.focused === newState.focused && oldState.gutterDecorations === newState.gutterDecorations && oldState.highlightActiveLineNumber === newState.highlightActiveLineNumber && oldState.highlightedLine === newState.highlightedLine && oldState.problemsHighlightedRow === newState.problemsHighlightedRow && oldState.lineNumbers === newState.lineNumbers && oldState.loadError === newState.loadError && oldState.textInfos === newState.textInfos && oldState.visibleViewLineIndices === newState.visibleViewLineIndices && oldState.differences === newState.differences && oldState.initial === newState.initial && oldState.scrollBarHeight === newState.scrollBarHeight && oldState.width === newState.width && oldState.longestLineWidth === newState.longestLineWidth && oldState.minimumSliderSize === newState.minimumSliderSize && oldState.selectionInfos === newState.selectionInfos && oldState.selections === newState.selections && oldState.workspaceUri === newState.workspaceUri;
|
|
5914
5914
|
};
|
|
5915
5915
|
|
|
5916
5916
|
const isEqual$1 = (oldState, newState) => {
|
|
@@ -16496,8 +16496,16 @@ const horizontalScrollBarThumbNode = {
|
|
|
16496
16496
|
className: mergeClassNames('ScrollBarThumb', 'ScrollBarThumbHorizontal'),
|
|
16497
16497
|
type: Div
|
|
16498
16498
|
};
|
|
16499
|
-
const getScrollBarVirtualDom = () => {
|
|
16500
|
-
|
|
16499
|
+
const getScrollBarVirtualDom = (scrollBarHeight, scrollBarWidth) => {
|
|
16500
|
+
const hasVerticalThumb = scrollBarHeight > 0;
|
|
16501
|
+
const hasHorizontalThumb = scrollBarWidth > 0;
|
|
16502
|
+
return [{
|
|
16503
|
+
...verticalScrollBarNode,
|
|
16504
|
+
childCount: hasVerticalThumb ? 1 : 0
|
|
16505
|
+
}, ...(hasVerticalThumb ? [verticalScrollBarThumbNode] : []), {
|
|
16506
|
+
...horizontalScrollBarNode,
|
|
16507
|
+
childCount: hasHorizontalThumb ? 1 : 0
|
|
16508
|
+
}, ...(hasHorizontalThumb ? [horizontalScrollBarThumbNode] : [])];
|
|
16501
16509
|
};
|
|
16502
16510
|
|
|
16503
16511
|
const editorContentNode = {
|
|
@@ -16521,6 +16529,8 @@ const getEditorContentVirtualDom = ({
|
|
|
16521
16529
|
problemsHighlightedRow = -1,
|
|
16522
16530
|
roundedSelection = false,
|
|
16523
16531
|
scrollBarDiagnostics = [],
|
|
16532
|
+
scrollBarHeight = 0,
|
|
16533
|
+
scrollBarWidth = 0,
|
|
16524
16534
|
selectionInfos = [],
|
|
16525
16535
|
textInfos,
|
|
16526
16536
|
visibleLineIndices = [],
|
|
@@ -16529,7 +16539,7 @@ const getEditorContentVirtualDom = ({
|
|
|
16529
16539
|
return [{
|
|
16530
16540
|
...editorContentNode,
|
|
16531
16541
|
className: breadcrumbsEnabled ? 'EditorContent EditorBreadcrumbsOffset' : 'EditorContent'
|
|
16532
|
-
}, ...getEditorInputVirtualDom(), ...getEditorLayersVirtualDom(selectionInfos, textInfos, differences, lineNumbers, highlightedLine, cursorInfos, diagnostics, visibleLineIndices, endOfLineDecorations, bracketMatchInfos, focused, visibleViewLineIndices, problemsHighlightedRow, roundedSelection), ...getEditorScrollBarDiagnosticsVirtualDom(scrollBarDiagnostics), ...getScrollBarVirtualDom()];
|
|
16542
|
+
}, ...getEditorInputVirtualDom(), ...getEditorLayersVirtualDom(selectionInfos, textInfos, differences, lineNumbers, highlightedLine, cursorInfos, diagnostics, visibleLineIndices, endOfLineDecorations, bracketMatchInfos, focused, visibleViewLineIndices, problemsHighlightedRow, roundedSelection), ...getEditorScrollBarDiagnosticsVirtualDom(scrollBarDiagnostics), ...getScrollBarVirtualDom(scrollBarHeight, scrollBarWidth)];
|
|
16533
16543
|
};
|
|
16534
16544
|
|
|
16535
16545
|
const getGutterInfoVirtualDom = (gutterInfo, activeLineNumber) => {
|
|
@@ -16695,6 +16705,8 @@ const getEditorVirtualDom = ({
|
|
|
16695
16705
|
problemsHighlightedRow = -1,
|
|
16696
16706
|
roundedSelection = false,
|
|
16697
16707
|
scrollBarDiagnostics = [],
|
|
16708
|
+
scrollBarHeight = 0,
|
|
16709
|
+
scrollBarWidth = 0,
|
|
16698
16710
|
selectionInfos = [],
|
|
16699
16711
|
selections = new Uint32Array(),
|
|
16700
16712
|
textInfos,
|
|
@@ -16750,6 +16762,8 @@ const getEditorVirtualDom = ({
|
|
|
16750
16762
|
problemsHighlightedRow,
|
|
16751
16763
|
roundedSelection,
|
|
16752
16764
|
scrollBarDiagnostics,
|
|
16765
|
+
scrollBarHeight,
|
|
16766
|
+
scrollBarWidth,
|
|
16753
16767
|
selectionInfos,
|
|
16754
16768
|
textInfos: combineWhitespaceTokens$1 ? textInfos.map(combineWhitespaceTokens) : textInfos,
|
|
16755
16769
|
visibleLineIndices: visibleLineIndices || [],
|
|
@@ -16773,8 +16787,11 @@ const getDom = state => {
|
|
|
16773
16787
|
const {
|
|
16774
16788
|
diagnostics = [],
|
|
16775
16789
|
initial,
|
|
16790
|
+
longestLineWidth,
|
|
16791
|
+
minimumSliderSize,
|
|
16776
16792
|
textInfos,
|
|
16777
|
-
visualDecorations = []
|
|
16793
|
+
visualDecorations = [],
|
|
16794
|
+
width
|
|
16778
16795
|
} = state;
|
|
16779
16796
|
if (initial && textInfos.length === 0) {
|
|
16780
16797
|
return [];
|
|
@@ -16782,7 +16799,8 @@ const getDom = state => {
|
|
|
16782
16799
|
return getEditorVirtualDom({
|
|
16783
16800
|
...state,
|
|
16784
16801
|
diagnostics: visualDecorations,
|
|
16785
|
-
scrollBarDiagnostics: getScrollBarDiagnostics(state, diagnostics)
|
|
16802
|
+
scrollBarDiagnostics: getScrollBarDiagnostics(state, diagnostics),
|
|
16803
|
+
scrollBarWidth: getScrollBarSize(width, longestLineWidth, minimumSliderSize)
|
|
16786
16804
|
});
|
|
16787
16805
|
};
|
|
16788
16806
|
const mergeConflictsEqual = (oldState, newState) => {
|