@danielgindi/virtual-list-helper 1.0.4 → 1.0.5

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.
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * @danielgindi/virtual-list-helper 1.0.4
2
+ * @danielgindi/virtual-list-helper 1.0.5
3
3
  * git://github.com/danielgindi/virtual-list-helper.git
4
4
  */
5
5
  'use strict';
@@ -5622,10 +5622,12 @@ var hasOwnProperty = Object.prototype.hasOwnProperty;var VirtualListHelper = /*#
5622
5622
 
5623
5623
  // Put calculated height into cache, and invalidate positions if it's different
5624
5624
  var cachedItemHeight = p.cachedItemHeights[index];
5625
- if (!(cachedItemHeight === itemHeight ||
5626
- cachedItemHeight === undefined && p.cachedItemEstimatedHeights[index] === itemHeight)) {
5627
-
5625
+ if (cachedItemHeight !== itemHeight) {
5628
5626
  p.cachedItemHeights[index] = itemHeight;
5627
+ }
5628
+
5629
+ if (cachedItemHeight !== undefined && itemHeight !== cachedItemHeight ||
5630
+ cachedItemHeight === undefined && itemHeight !== p.cachedItemEstimatedHeights[index]) {
5629
5631
  this._setItemPositionsNeedsUpdate(index + 1);
5630
5632
  }
5631
5633