@infinite-list/data-model
Advanced tools
Comparing version 0.1.2 to 0.1.3
{ | ||
"name": "@infinite-list/data-model", | ||
"version": "0.1.2", | ||
"version": "0.1.3", | ||
"files": [ | ||
@@ -5,0 +5,0 @@ "dist", |
@@ -877,7 +877,8 @@ import noop from '@x-oasis/noop'; | ||
const itemMeta = this.getItemMeta(item, index); | ||
const currentIndex = itemMeta?.getIndexInfo().index || -1; | ||
if (!itemMeta) return; | ||
const currentIndex = itemMeta.getIndexInfo().index; | ||
const lastTokenIndex = spaceStateResult.length - 1; | ||
const lastToken = spaceStateResult[lastTokenIndex]; | ||
const itemKey = itemMeta.getKey(); | ||
const itemLayout = itemMeta?.getLayout(); | ||
const itemLayout = itemMeta.getLayout(); | ||
const isSticky = this.stickyHeaderIndices.indexOf(index) !== -1; | ||
@@ -1044,43 +1045,3 @@ const isSpace = | ||
} else { | ||
// if (recycleEnabled) { | ||
// if (visibleStartIndex > 0) { | ||
// spaceStateResult.push({ | ||
// key: 'spacer_before', | ||
// length: this.getIndexKeyOffset(visibleStartIndex, true), | ||
// isSpace: true, | ||
// isSticky: false, | ||
// item: null, | ||
// position: 'buffered', | ||
// }); | ||
// } | ||
// for (let index = visibleStartIndex; index <= visibleEndIndex; index++) { | ||
// const item = data[index]; | ||
// if (item) | ||
// this.hydrateSpaceStateToken( | ||
// spaceStateResult, | ||
// item, | ||
// index, | ||
// 'buffered' | ||
// ); | ||
// } | ||
// if ( | ||
// visibleEndIndex < data.length - 1 && | ||
// typeof this.getTotalLength() === 'number' | ||
// ) { | ||
// spaceStateResult.push({ | ||
// key: 'spacer_after', | ||
// length: | ||
// (this.getTotalLength() as number) - | ||
// this.getIndexKeyOffset(visibleEndIndex + 1, true), | ||
// isSpace: true, | ||
// isSticky: false, | ||
// item: null, | ||
// position: 'buffered', | ||
// }); | ||
// } | ||
// } else { | ||
spaceStateResult = this.resolveSpaceState(state); | ||
// } | ||
} | ||
@@ -1087,0 +1048,0 @@ |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
1467267
15813