@lvce-editor/text-search-worker 6.8.0 → 6.9.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.
@@ -1795,7 +1795,6 @@ const diffChildren = (oldChildren, newChildren, patches) => {
1795
1795
  patches.push({
1796
1796
  type: NavigateParent
1797
1797
  });
1798
- currentChildIndex = -1;
1799
1798
  }
1800
1799
  // Add remove patches in reverse order (highest index first)
1801
1800
  // This ensures indices remain valid as we remove
@@ -3112,16 +3111,27 @@ const handleUpdateEmpty = (state, update) => {
3112
3111
  ...state,
3113
3112
  ...update
3114
3113
  };
3114
+ const headerHeight = getTopHeight(partialNewState.flags);
3115
3115
  return {
3116
3116
  ...partialNewState,
3117
+ collapsedPaths: [],
3117
3118
  deltaY: 0,
3119
+ fileCount: 0,
3120
+ finalDeltaY: 0,
3121
+ headerHeight,
3122
+ icons: [],
3118
3123
  items: [],
3124
+ limitHit: false,
3125
+ limitHitWarning: '',
3119
3126
  listItems: [],
3120
3127
  loaded: true,
3121
3128
  matchCount: 0,
3122
3129
  maxLineY: 0,
3123
3130
  message: '',
3124
3131
  minLineY: 0,
3132
+ scrollBarHeight: 0,
3133
+ scrollBarY: 0,
3134
+ searchId: '',
3125
3135
  searchInputErrorMessage: ''
3126
3136
  };
3127
3137
  };
@@ -5119,8 +5129,8 @@ const createViewModel = state => {
5119
5129
  } = state;
5120
5130
  const displayResults = getDisplayResults(listItems, itemHeight, fileCount, value, minLineY, maxLineY, replacement, icons, listFocusedIndex, collapsedPaths, renderFolderPaths || false, items);
5121
5131
  const focusOutline = listFocused && listFocusedIndex === -1;
5122
- const scrollBarValue = deltaY / finalDeltaY * 100;
5123
- const scrollBarY = getScrollBarY$1(deltaY, finalDeltaY, height - headerHeight, scrollBarHeight);
5132
+ const scrollBarValue = finalDeltaY === 0 ? 0 : deltaY / finalDeltaY * 100;
5133
+ const scrollBarY = finalDeltaY === 0 ? 0 : getScrollBarY$1(deltaY, finalDeltaY, height - headerHeight, scrollBarHeight);
5124
5134
  return {
5125
5135
  deltaY,
5126
5136
  displayResults,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@lvce-editor/text-search-worker",
3
- "version": "6.8.0",
3
+ "version": "6.9.0",
4
4
  "description": "Text Search Worker",
5
5
  "keywords": [
6
6
  "text-search"