@lvce-editor/explorer-view 3.22.0 → 3.24.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.
|
@@ -2512,6 +2512,9 @@ const copyRelativePath = async state => {
|
|
|
2512
2512
|
// of visible items needed, e.g. when not scrolled 5 items with
|
|
2513
2513
|
// 20px fill 100px but when scrolled 6 items are needed
|
|
2514
2514
|
const getNumberOfVisibleItems = (listHeight, itemHeight) => {
|
|
2515
|
+
if (listHeight <= 0 || itemHeight <= 0) {
|
|
2516
|
+
return 0;
|
|
2517
|
+
}
|
|
2515
2518
|
return Math.ceil(listHeight / itemHeight) + 1;
|
|
2516
2519
|
};
|
|
2517
2520
|
|
|
@@ -5014,15 +5017,6 @@ const restoreExpandedState = async (savedState, root, pathSeparator, excluded) =
|
|
|
5014
5017
|
return dirents;
|
|
5015
5018
|
};
|
|
5016
5019
|
|
|
5017
|
-
// TODO viewlet should only have create and refresh functions
|
|
5018
|
-
// every thing else can be in a separate module <viewlet>.lazy.js
|
|
5019
|
-
// and <viewlet>.ipc.js
|
|
5020
|
-
|
|
5021
|
-
// viewlet: creating | refreshing | done | disposed
|
|
5022
|
-
// TODO recycle viewlets (maybe)
|
|
5023
|
-
|
|
5024
|
-
// TODO instead of root string, there should be a root dirent
|
|
5025
|
-
|
|
5026
5020
|
const getPathSeparator = root => {
|
|
5027
5021
|
return getPathSeparator$1(root);
|
|
5028
5022
|
};
|