aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorbobzel <zzzman@gmail.com>2023-10-16 16:38:06 -0400
committerbobzel <zzzman@gmail.com>2023-10-16 16:38:06 -0400
commitabf40af6dd617de6486a97e8b5f276db232119ed (patch)
treea500eae2c650de054f14ab04430272c9f2fb2a15
parentf6337ba3244f2d7270dccb6b319c047e608c6a72 (diff)
fixed deleting docs
-rw-r--r--src/client/views/collections/collectionFreeForm/CollectionFreeFormView.tsx4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/client/views/collections/collectionFreeForm/CollectionFreeFormView.tsx b/src/client/views/collections/collectionFreeForm/CollectionFreeFormView.tsx
index 3f23ee15a..bfc61f601 100644
--- a/src/client/views/collections/collectionFreeForm/CollectionFreeFormView.tsx
+++ b/src/client/views/collections/collectionFreeForm/CollectionFreeFormView.tsx
@@ -1511,10 +1511,12 @@ export class CollectionFreeFormView extends CollectionSubView<Partial<collection
}
@observable _numLoaded = 1;
+ _lastPoolSize = 0;
get doLayoutComputation() {
const { newPool, computedElementData } = this.doInternalLayoutComputation;
const array = Array.from(newPool.entries());
- let somethingChanged = false;
+ let somethingChanged = array.length !== this._lastPoolSize;
+ this._lastPoolSize = array.length;
runInAction(() => {
for (const entry of array) {
const lastPos = this._cachedPool.get(entry[0]); // last computed pos