(cb)
| 318 | } |
| 319 | |
| 320 | updateSimpleFrame(cb) { |
| 321 | const { end } = this.getStartAndEnd(); |
| 322 | const itemEls = this.items.children; |
| 323 | let elEnd = 0; |
| 324 | |
| 325 | if (itemEls.length) { |
| 326 | const { axis } = this.props; |
| 327 | const firstItemEl = itemEls[0]; |
| 328 | const lastItemEl = itemEls[itemEls.length - 1]; |
| 329 | elEnd = |
| 330 | this.getOffset(lastItemEl) + |
| 331 | lastItemEl[OFFSET_SIZE_KEYS[axis]] - |
| 332 | this.getOffset(firstItemEl); |
| 333 | } |
| 334 | |
| 335 | if (elEnd > end) return cb(); |
| 336 | |
| 337 | const { pageSize, length } = this.props; |
| 338 | const size = Math.min(this.state.size + pageSize, length); |
| 339 | this.maybeSetState({ size }, cb); |
| 340 | } |
| 341 | |
| 342 | updateVariableFrame(cb) { |
| 343 | if (!this.props.itemSizeGetter) this.cacheSizes(); |
no test coverage detected