@vaadin/component-base
Advanced tools
Comparing version 24.3.10 to 24.3.11
{ | ||
"name": "@vaadin/component-base", | ||
"version": "24.3.10", | ||
"version": "24.3.11", | ||
"publishConfig": { | ||
@@ -45,3 +45,3 @@ "access": "public" | ||
}, | ||
"gitHead": "32a4f327e78490074eaefa768f58857b83ca6278" | ||
"gitHead": "890abeb0937416074456782aa90ed92c1bfe9cac" | ||
} |
@@ -12,3 +12,3 @@ /** | ||
get() { | ||
return '24.3.10'; | ||
return '24.3.11'; | ||
}, | ||
@@ -15,0 +15,0 @@ }); |
@@ -85,2 +85,6 @@ /** | ||
get _maxVirtualIndexOffset() { | ||
return this.size - this._virtualCount; | ||
} | ||
__hasPlaceholders() { | ||
@@ -110,3 +114,3 @@ return this.__getVisibleElements().some((el) => el.__virtualizerPlaceholder); | ||
targetVirtualIndex = this._virtualCount - (this.size - index); | ||
this._vidxOffset = this.size - this._virtualCount; | ||
this._vidxOffset = this._maxVirtualIndexOffset; | ||
} else if (targetVirtualIndex < visibleElementCount) { | ||
@@ -724,2 +728,4 @@ if (index < OFFSET_ADJUST_MIN_THRESHOLD) { | ||
_adjustVirtualIndexOffset(delta) { | ||
const maxOffset = this._maxVirtualIndexOffset; | ||
if (this._virtualCount >= this.size) { | ||
@@ -731,5 +737,4 @@ this._vidxOffset = 0; | ||
// Process a large scroll position change | ||
const scale = this._scrollTop / (this.scrollTarget.scrollHeight - this.scrollTarget.offsetHeight); | ||
const offset = scale * this.size; | ||
this._vidxOffset = Math.round(offset - scale * this._virtualCount); | ||
const scale = this._scrollTop / (this.scrollTarget.scrollHeight - this.scrollTarget.clientHeight); | ||
this._vidxOffset = Math.round(scale * maxOffset); | ||
} else { | ||
@@ -753,3 +758,2 @@ // Make sure user can always swipe/wheel scroll to the start and end | ||
// Near end | ||
const maxOffset = this.size - this._virtualCount; | ||
if (this._scrollTop >= this._maxScrollTop && this._maxScrollTop > 0) { | ||
@@ -756,0 +760,0 @@ this._vidxOffset = maxOffset; |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
209403
6238