forked from mystiq/hydrogen-web
Improve comment
Signed-off-by: RMidhunSuresh <rmidhunsuresh@gmail.com>
This commit is contained in:
parent
96e2bb0b1a
commit
9a00143623
1 changed files with 4 additions and 2 deletions
|
@ -45,8 +45,10 @@ class ItemRange {
|
||||||
|
|
||||||
normalize(idx) {
|
normalize(idx) {
|
||||||
/*
|
/*
|
||||||
Since we don't render the entire list, the index we use to do dom
|
map index from list to index in rendered range
|
||||||
manipulation or access childInstances will be different.
|
eg: if the index range of this._list is [0, 200] and we have rendered
|
||||||
|
elements in range [50, 60] then index 50 in list must map to index 0
|
||||||
|
in DOM tree/childInstance array.
|
||||||
*/
|
*/
|
||||||
return idx - this.topCount;
|
return idx - this.topCount;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue