From b2167810eaacfd658d1b2e212218a1c309c3a67b Mon Sep 17 00:00:00 2001 From: Rob Eisenberg Date: Wed, 22 Jun 2016 11:32:15 -0400 Subject: [PATCH] chore(all): update build --- dist/amd/array-virtual-repeat-strategy.js | 2 +- ...{view-strategy.js => template-strategy.js} | 34 +++++----- dist/amd/utilities.js | 4 +- dist/amd/virtual-repeat.js | 20 +++--- dist/aurelia-ui-virtualization.d.ts | 48 ++------------ dist/aurelia-ui-virtualization.js | 34 +++++----- .../commonjs/array-virtual-repeat-strategy.js | 2 +- ...{view-strategy.js => template-strategy.js} | 34 +++++----- dist/commonjs/utilities.js | 4 +- dist/commonjs/virtual-repeat.js | 20 +++--- dist/es2015/array-virtual-repeat-strategy.js | 2 +- ...{view-strategy.js => template-strategy.js} | 6 +- dist/es2015/utilities.js | 4 +- dist/es2015/virtual-repeat.js | 20 +++--- .../array-virtual-repeat-strategy.js | 2 +- ...{view-strategy.js => template-strategy.js} | 32 +++++----- dist/native-modules/utilities.js | 4 +- dist/native-modules/virtual-repeat.js | 20 +++--- dist/system/array-virtual-repeat-strategy.js | 2 +- ...{view-strategy.js => template-strategy.js} | 38 ++++++------ dist/system/utilities.js | 4 +- dist/system/virtual-repeat.js | 26 ++++---- dist/temp/aurelia-ui-virtualization.js | 62 +++++++++---------- doc/api.json | 2 +- 24 files changed, 194 insertions(+), 232 deletions(-) rename dist/amd/{view-strategy.js => template-strategy.js} (74%) rename dist/commonjs/{view-strategy.js => template-strategy.js} (73%) rename dist/es2015/{view-strategy.js => template-strategy.js} (94%) rename dist/native-modules/{view-strategy.js => template-strategy.js} (74%) rename dist/system/{view-strategy.js => template-strategy.js} (73%) diff --git a/dist/amd/array-virtual-repeat-strategy.js b/dist/amd/array-virtual-repeat-strategy.js index 3ae27ed..ff0d97c 100644 --- a/dist/amd/array-virtual-repeat-strategy.js +++ b/dist/amd/array-virtual-repeat-strategy.js @@ -274,7 +274,7 @@ define(['exports', 'aurelia-templating-resources', './utilities'], function (exp var addIndex = splice.index; var end = splice.index + splice.addedCount; for (; addIndex < end; ++addIndex) { - var hasDistanceToBottomViewPort = (0, _utilities.getElementDistanceToBottomViewPort)(repeat.viewStrategy.getLastElement(repeat.bottomBuffer)) > 0; + var hasDistanceToBottomViewPort = (0, _utilities.getElementDistanceToBottomViewPort)(repeat.templateStrategy.getLastElement(repeat.bottomBuffer)) > 0; if (repeat.viewCount() === 0 || !this._isIndexBeforeViewSlot(repeat, viewSlot, addIndex) && !this._isIndexAfterViewSlot(repeat, viewSlot, addIndex) || hasDistanceToBottomViewPort) { var overrideContext = (0, _aureliaTemplatingResources.createFullOverrideContext)(repeat, array[addIndex], addIndex, arrayLength); repeat.insertView(addIndex, overrideContext.bindingContext, overrideContext); diff --git a/dist/amd/view-strategy.js b/dist/amd/template-strategy.js similarity index 74% rename from dist/amd/view-strategy.js rename to dist/amd/template-strategy.js index 3e1d9c6..162d844 100644 --- a/dist/amd/view-strategy.js +++ b/dist/amd/template-strategy.js @@ -4,23 +4,23 @@ define(['exports', 'aurelia-pal', 'aurelia-templating', './utilities'], function Object.defineProperty(exports, "__esModule", { value: true }); - exports.DefaultViewStrategy = exports.TableStrategy = exports.ViewStrategyLocator = undefined; + exports.DefaultTemplateStrategy = exports.TableStrategy = exports.TemplateStrategyLocator = undefined; - var ViewStrategyLocator = exports.ViewStrategyLocator = function () { - function ViewStrategyLocator() { + var TemplateStrategyLocator = exports.TemplateStrategyLocator = function () { + function TemplateStrategyLocator() { } - ViewStrategyLocator.prototype.getStrategy = function getStrategy(element) { + TemplateStrategyLocator.prototype.getStrategy = function getStrategy(element) { if (element.parentNode && element.parentNode.localName === 'tbody') { return new TableStrategy(); } - return new DefaultViewStrategy(); + return new DefaultTemplateStrategy(); }; - return ViewStrategyLocator; + return TemplateStrategyLocator; }(); var TableStrategy = exports.TableStrategy = function () { @@ -90,52 +90,52 @@ define(['exports', 'aurelia-pal', 'aurelia-templating', './utilities'], function return TableStrategy; }(); - var DefaultViewStrategy = exports.DefaultViewStrategy = function () { - function DefaultViewStrategy() { + var DefaultTemplateStrategy = exports.DefaultTemplateStrategy = function () { + function DefaultTemplateStrategy() { } - DefaultViewStrategy.prototype.getScrollContainer = function getScrollContainer(element) { + DefaultTemplateStrategy.prototype.getScrollContainer = function getScrollContainer(element) { return element.parentNode; }; - DefaultViewStrategy.prototype.moveViewFirst = function moveViewFirst(view, topBuffer) { + DefaultTemplateStrategy.prototype.moveViewFirst = function moveViewFirst(view, topBuffer) { (0, _utilities.insertBeforeNode)(view, _aureliaPal.DOM.nextElementSibling(topBuffer)); }; - DefaultViewStrategy.prototype.moveViewLast = function moveViewLast(view, bottomBuffer) { + DefaultTemplateStrategy.prototype.moveViewLast = function moveViewLast(view, bottomBuffer) { var previousSibling = bottomBuffer.previousSibling; var referenceNode = previousSibling.nodeType === 8 && previousSibling.data === 'anchor' ? previousSibling : bottomBuffer; (0, _utilities.insertBeforeNode)(view, referenceNode); }; - DefaultViewStrategy.prototype.createTopBufferElement = function createTopBufferElement(element) { + DefaultTemplateStrategy.prototype.createTopBufferElement = function createTopBufferElement(element) { var elementName = element.parentNode.localName === 'ul' ? 'li' : 'div'; var buffer = _aureliaPal.DOM.createElement(elementName); element.parentNode.insertBefore(buffer, element); return buffer; }; - DefaultViewStrategy.prototype.createBottomBufferElement = function createBottomBufferElement(element) { + DefaultTemplateStrategy.prototype.createBottomBufferElement = function createBottomBufferElement(element) { var elementName = element.parentNode.localName === 'ul' ? 'li' : 'div'; var buffer = _aureliaPal.DOM.createElement(elementName); element.parentNode.insertBefore(buffer, element.nextSibling); return buffer; }; - DefaultViewStrategy.prototype.removeBufferElements = function removeBufferElements(element, topBuffer, bottomBuffer) { + DefaultTemplateStrategy.prototype.removeBufferElements = function removeBufferElements(element, topBuffer, bottomBuffer) { element.parentNode.removeChild(topBuffer); element.parentNode.removeChild(bottomBuffer); }; - DefaultViewStrategy.prototype.getFirstElement = function getFirstElement(topBuffer) { + DefaultTemplateStrategy.prototype.getFirstElement = function getFirstElement(topBuffer) { return _aureliaPal.DOM.nextElementSibling(topBuffer); }; - DefaultViewStrategy.prototype.getLastElement = function getLastElement(bottomBuffer) { + DefaultTemplateStrategy.prototype.getLastElement = function getLastElement(bottomBuffer) { return bottomBuffer.previousElementSibling; }; - return DefaultViewStrategy; + return DefaultTemplateStrategy; }(); }); \ No newline at end of file diff --git a/dist/amd/utilities.js b/dist/amd/utilities.js index 00ec3af..3f0bbcc 100644 --- a/dist/amd/utilities.js +++ b/dist/amd/utilities.js @@ -47,10 +47,10 @@ define(['exports', 'aurelia-templating-resources', 'aurelia-templating'], functi view.bindingContext[repeat.local] = items[index]; if (moveToBottom) { viewSlot.children.push(viewSlot.children.shift()); - repeat.viewStrategy.moveViewLast(view, repeat.bottomBuffer); + repeat.templateStrategy.moveViewLast(view, repeat.bottomBuffer); } else { viewSlot.children.unshift(viewSlot.children.splice(-1, 1)[0]); - repeat.viewStrategy.moveViewFirst(view, repeat.topBuffer); + repeat.templateStrategy.moveViewFirst(view, repeat.topBuffer); } } diff --git a/dist/amd/virtual-repeat.js b/dist/amd/virtual-repeat.js index 20a7e92..599fd2a 100644 --- a/dist/amd/virtual-repeat.js +++ b/dist/amd/virtual-repeat.js @@ -1,4 +1,4 @@ -define(['exports', 'aurelia-dependency-injection', 'aurelia-binding', 'aurelia-templating', 'aurelia-templating-resources', 'aurelia-pal', './utilities', './dom-helper', './virtual-repeat-strategy-locator', './view-strategy'], function (exports, _aureliaDependencyInjection, _aureliaBinding, _aureliaTemplating, _aureliaTemplatingResources, _aureliaPal, _utilities, _domHelper, _virtualRepeatStrategyLocator, _viewStrategy) { +define(['exports', 'aurelia-dependency-injection', 'aurelia-binding', 'aurelia-templating', 'aurelia-templating-resources', 'aurelia-pal', './utilities', './dom-helper', './virtual-repeat-strategy-locator', './template-strategy'], function (exports, _aureliaDependencyInjection, _aureliaBinding, _aureliaTemplating, _aureliaTemplatingResources, _aureliaPal, _utilities, _domHelper, _virtualRepeatStrategyLocator, _templateStrategy) { 'use strict'; Object.defineProperty(exports, "__esModule", { @@ -77,10 +77,10 @@ define(['exports', 'aurelia-dependency-injection', 'aurelia-binding', 'aurelia-t var _dec, _dec2, _class, _desc, _value, _class2, _descriptor, _descriptor2; - var VirtualRepeat = exports.VirtualRepeat = (_dec = (0, _aureliaTemplating.customAttribute)('virtual-repeat'), _dec2 = (0, _aureliaDependencyInjection.inject)(_aureliaPal.DOM.Element, _aureliaTemplating.BoundViewFactory, _aureliaTemplating.TargetInstruction, _aureliaTemplating.ViewSlot, _aureliaTemplating.ViewResources, _aureliaBinding.ObserverLocator, _virtualRepeatStrategyLocator.VirtualRepeatStrategyLocator, _viewStrategy.ViewStrategyLocator, _domHelper.DomHelper), _dec(_class = (0, _aureliaTemplating.templateController)(_class = _dec2(_class = (_class2 = function (_AbstractRepeater) { + var VirtualRepeat = exports.VirtualRepeat = (_dec = (0, _aureliaTemplating.customAttribute)('virtual-repeat'), _dec2 = (0, _aureliaDependencyInjection.inject)(_aureliaPal.DOM.Element, _aureliaTemplating.BoundViewFactory, _aureliaTemplating.TargetInstruction, _aureliaTemplating.ViewSlot, _aureliaTemplating.ViewResources, _aureliaBinding.ObserverLocator, _virtualRepeatStrategyLocator.VirtualRepeatStrategyLocator, _templateStrategy.TemplateStrategyLocator, _domHelper.DomHelper), _dec(_class = (0, _aureliaTemplating.templateController)(_class = _dec2(_class = (_class2 = function (_AbstractRepeater) { _inherits(VirtualRepeat, _AbstractRepeater); - function VirtualRepeat(element, viewFactory, instruction, viewSlot, viewResources, observerLocator, strategyLocator, viewStrategyLocator, domHelper) { + function VirtualRepeat(element, viewFactory, instruction, viewSlot, viewResources, observerLocator, strategyLocator, templateStrategyLocator, domHelper) { var _this = _possibleConstructorReturn(this, _AbstractRepeater.call(this, { @@ -115,7 +115,7 @@ define(['exports', 'aurelia-dependency-injection', 'aurelia-binding', 'aurelia-t _this.lookupFunctions = viewResources.lookupFunctions; _this.observerLocator = observerLocator; _this.strategyLocator = strategyLocator; - _this.viewStrategyLocator = viewStrategyLocator; + _this.templateStrategyLocator = templateStrategyLocator; _this.sourceExpression = (0, _aureliaTemplatingResources.getItemsSourceExpression)(_this.instruction, 'virtual-repeat.for'); _this.isOneTime = (0, _aureliaTemplatingResources.isOneTime)(_this.sourceExpression); _this.domHelper = domHelper; @@ -128,10 +128,10 @@ define(['exports', 'aurelia-dependency-injection', 'aurelia-binding', 'aurelia-t this._isAttached = true; var element = this.element; this._itemsLength = this.items.length; - this.viewStrategy = this.viewStrategyLocator.getStrategy(element); - this.scrollContainer = this.viewStrategy.getScrollContainer(element); - this.topBuffer = this.viewStrategy.createTopBufferElement(element); - this.bottomBuffer = this.viewStrategy.createBottomBufferElement(element); + this.templateStrategy = this.templateStrategyLocator.getStrategy(element); + this.scrollContainer = this.templateStrategy.getScrollContainer(element); + this.topBuffer = this.templateStrategy.createTopBufferElement(element); + this.bottomBuffer = this.templateStrategy.createBottomBufferElement(element); this.itemsChanged(); this.scrollListener = function () { return _this2._onScroll(); @@ -145,7 +145,7 @@ define(['exports', 'aurelia-dependency-injection', 'aurelia-binding', 'aurelia-t } }, 500); - this.distanceToTop = this.domHelper.getElementDistanceToTopOfDocument(this.viewStrategy.getFirstElement(this.topBuffer)); + this.distanceToTop = this.domHelper.getElementDistanceToTopOfDocument(this.templateStrategy.getFirstElement(this.topBuffer)); if (this.domHelper.hasOverflowScroll(this.scrollContainer)) { this._fixedHeightContainer = true; this.scrollContainer.addEventListener('scroll', this.scrollListener); @@ -176,7 +176,7 @@ define(['exports', 'aurelia-dependency-injection', 'aurelia-binding', 'aurelia-t this._isAttached = false; this._ticking = false; this._hasCalculatedSizes = false; - this.viewStrategy.removeBufferElements(this.element, this.topBuffer, this.bottomBuffer); + this.templateStrategy.removeBufferElements(this.element, this.topBuffer, this.bottomBuffer); this.isLastIndex = false; this.scrollContainer = null; this.scrollContainerHeight = null; diff --git a/dist/aurelia-ui-virtualization.d.ts b/dist/aurelia-ui-virtualization.d.ts index 4ea08ec..7c3d897 100644 --- a/dist/aurelia-ui-virtualization.d.ts +++ b/dist/aurelia-ui-virtualization.d.ts @@ -29,7 +29,7 @@ import { import { ObserverLocator } from 'aurelia-binding'; -export declare interface ViewStrategy { +export declare interface TemplateStrategy { getScrollContainer(element: Element): Element; moveViewFirst(view: View, topBuffer: Element): void; moveViewLast(view: View, bottomBuffer: Element): void; @@ -70,8 +70,6 @@ export declare class ArrayVirtualRepeatStrategy extends ArrayRepeatStrategy { * @param items The new array instance. */ instanceChanged(repeat: VirtualRepeat, items: Array): void; - _standardProcessInstanceChanged(repeat: VirtualRepeat, items: Array): void; - _inPlaceProcessItems(repeat: VirtualRepeat, items: Array): void; /** * Handle the repeat's collection instance mutating. @@ -80,16 +78,9 @@ export declare class ArrayVirtualRepeatStrategy extends ArrayRepeatStrategy { * @param splices Records of array changes. */ instanceMutated(repeat: VirtualRepeat, array: Array, splices: any): void; - _standardProcessInstanceMutated(repeat: VirtualRepeat, array: Array, splices: any): void; - _runSplices(repeat: VirtualRepeat, array: Array, splices: any): any; - _removeViewAt(repeat: VirtualRepeat, collectionIndex: number, returnToCache: boolean, j: number, removedLength: number): any; - _isIndexBeforeViewSlot(repeat: VirtualRepeat, viewSlot: ViewSlot, index: number): number; - _isIndexAfterViewSlot(repeat: VirtualRepeat, viewSlot: ViewSlot, index: number): number; - _getViewIndex(repeat: VirtualRepeat, viewSlot: ViewSlot, index: number): number; - _handleAddedSplices(repeat: VirtualRepeat, array: Array, splices: any): void; } -export declare class ViewStrategyLocator { - getStrategy(element: Element): ViewStrategy; +export declare class TemplateStrategyLocator { + getStrategy(element: Element): TemplateStrategy; } export declare class TableStrategy { tableCssReset: any; @@ -102,7 +93,7 @@ export declare class TableStrategy { getFirstElement(topBuffer: Element): Element; getLastElement(bottomBuffer: Element): Element; } -export declare class DefaultViewStrategy { +export declare class DefaultTemplateStrategy { getScrollContainer(element: Element): Element; moveViewFirst(view: View, topBuffer: Element): void; moveViewLast(view: View, bottomBuffer: Element): void; @@ -116,24 +107,9 @@ export declare class VirtualRepeatStrategyLocator extends RepeatStrategyLocator constructor(); } export declare class VirtualRepeat extends AbstractRepeater { - _first: any; - _previousFirst: any; - _viewsLength: any; - _lastRebind: any; - _topBufferHeight: any; - _bottomBufferHeight: any; - _bufferSize: any; - _scrollingDown: any; - _scrollingUp: any; - _switchedDirection: any; - _isAttached: any; - _ticking: any; - _fixedHeightContainer: any; - _hasCalculatedSizes: any; - _isAtTop: any; items: any; local: any; - constructor(element: Element, viewFactory: BoundViewFactory, instruction: TargetInstruction, viewSlot: ViewSlot, viewResources: ViewResources, observerLocator: ObserverLocator, strategyLocator: VirtualRepeatStrategyLocator, viewStrategyLocator: ViewStrategyLocator, domHelper: DomHelper); + constructor(element: Element, viewFactory: BoundViewFactory, instruction: TargetInstruction, viewSlot: ViewSlot, viewResources: ViewResources, observerLocator: ObserverLocator, strategyLocator: VirtualRepeatStrategyLocator, templateStrategyLocator: TemplateStrategyLocator, domHelper: DomHelper); attached(): void; bind(bindingContext?: any, overrideContext?: any): void; call(context?: any, changes?: any): void; @@ -142,20 +118,6 @@ export declare class VirtualRepeat extends AbstractRepeater { unbind(): void; handleCollectionMutated(collection?: any, changes?: any): void; handleInnerCollectionMutated(collection?: any, changes?: any): void; - _onScroll(): void; - _handleScroll(): void; - _checkScrolling(): void; - _adjustBufferHeights(): void; - _unsubscribeCollection(): void; - _moveViews(length: number): number; - _getIndexOfLastView(): number; - _getLastViewItem(): any; - _getIndexOfFirstView(): number; - _calcInitialHeights(itemsLength: number): any; - _calcScrollHeight(element: Element): number; - _observeInnerCollection(): boolean; - _getInnerCollection(): any; - _observeCollection(): void; // @override AbstractRepeater viewCount(): any; diff --git a/dist/aurelia-ui-virtualization.js b/dist/aurelia-ui-virtualization.js index 88c7189..9610262 100644 --- a/dist/aurelia-ui-virtualization.js +++ b/dist/aurelia-ui-virtualization.js @@ -60,10 +60,10 @@ export function rebindAndMoveView(repeat: VirtualRepeat, view: View, index: numb view.bindingContext[repeat.local] = items[index]; if (moveToBottom) { viewSlot.children.push(viewSlot.children.shift()); - repeat.viewStrategy.moveViewLast(view, repeat.bottomBuffer); + repeat.templateStrategy.moveViewLast(view, repeat.bottomBuffer); } else { viewSlot.children.unshift(viewSlot.children.splice(-1, 1)[0]); - repeat.viewStrategy.moveViewFirst(view, repeat.topBuffer); + repeat.templateStrategy.moveViewFirst(view, repeat.topBuffer); } } @@ -326,7 +326,7 @@ export class ArrayVirtualRepeatStrategy extends ArrayRepeatStrategy { let addIndex = splice.index; let end = splice.index + splice.addedCount; for (; addIndex < end; ++addIndex) { - let hasDistanceToBottomViewPort = getElementDistanceToBottomViewPort(repeat.viewStrategy.getLastElement(repeat.bottomBuffer)) > 0; + let hasDistanceToBottomViewPort = getElementDistanceToBottomViewPort(repeat.templateStrategy.getLastElement(repeat.bottomBuffer)) > 0; if (repeat.viewCount() === 0 || (!this._isIndexBeforeViewSlot(repeat, viewSlot, addIndex) && !this._isIndexAfterViewSlot(repeat, viewSlot, addIndex)) || hasDistanceToBottomViewPort) { let overrideContext = createFullOverrideContext(repeat, array[addIndex], addIndex, arrayLength); repeat.insertView(addIndex, overrideContext.bindingContext, overrideContext); @@ -354,7 +354,7 @@ export class ArrayVirtualRepeatStrategy extends ArrayRepeatStrategy { } } -interface ViewStrategy { +interface TemplateStrategy { getScrollContainer(element: Element): Element; moveViewFirst(view: View, topBuffer: Element): void; moveViewLast(view: View, bottomBuffer: Element): void; @@ -365,12 +365,12 @@ interface ViewStrategy { getLastView(bottomBuffer: Element): Element; } -export class ViewStrategyLocator { - getStrategy(element: Element): ViewStrategy { +export class TemplateStrategyLocator { + getStrategy(element: Element): TemplateStrategy { if (element.parentNode && element.parentNode.localName === 'tbody') { return new TableStrategy(); } - return new DefaultViewStrategy(); + return new DefaultTemplateStrategy(); } } @@ -435,7 +435,7 @@ export class TableStrategy { } } -export class DefaultViewStrategy { +export class DefaultTemplateStrategy { getScrollContainer(element: Element): Element { return element.parentNode; } @@ -490,7 +490,7 @@ export class VirtualRepeatStrategyLocator extends RepeatStrategyLocator { @customAttribute('virtual-repeat') @templateController -@inject(DOM.Element, BoundViewFactory, TargetInstruction, ViewSlot, ViewResources, ObserverLocator, VirtualRepeatStrategyLocator, ViewStrategyLocator, DomHelper) +@inject(DOM.Element, BoundViewFactory, TargetInstruction, ViewSlot, ViewResources, ObserverLocator, VirtualRepeatStrategyLocator, TemplateStrategyLocator, DomHelper) export class VirtualRepeat extends AbstractRepeater { _first = 0; _previousFirst = 0; @@ -518,7 +518,7 @@ export class VirtualRepeat extends AbstractRepeater { viewResources: ViewResources, observerLocator: ObserverLocator, strategyLocator: VirtualRepeatStrategyLocator, - viewStrategyLocator: ViewStrategyLocator, + templateStrategyLocator: TemplateStrategyLocator, domHelper: DomHelper) { super({ local: 'item', @@ -532,7 +532,7 @@ export class VirtualRepeat extends AbstractRepeater { this.lookupFunctions = viewResources.lookupFunctions; this.observerLocator = observerLocator; this.strategyLocator = strategyLocator; - this.viewStrategyLocator = viewStrategyLocator; + this.templateStrategyLocator = templateStrategyLocator; this.sourceExpression = getItemsSourceExpression(this.instruction, 'virtual-repeat.for'); this.isOneTime = isOneTime(this.sourceExpression); this.domHelper = domHelper; @@ -542,10 +542,10 @@ export class VirtualRepeat extends AbstractRepeater { this._isAttached = true; let element = this.element; this._itemsLength = this.items.length; - this.viewStrategy = this.viewStrategyLocator.getStrategy(element); - this.scrollContainer = this.viewStrategy.getScrollContainer(element); - this.topBuffer = this.viewStrategy.createTopBufferElement(element); - this.bottomBuffer = this.viewStrategy.createBottomBufferElement(element); + this.templateStrategy = this.templateStrategyLocator.getStrategy(element); + this.scrollContainer = this.templateStrategy.getScrollContainer(element); + this.topBuffer = this.templateStrategy.createTopBufferElement(element); + this.bottomBuffer = this.templateStrategy.createBottomBufferElement(element); this.itemsChanged(); this.scrollListener = () => this._onScroll(); @@ -557,7 +557,7 @@ export class VirtualRepeat extends AbstractRepeater { } }, 500); - this.distanceToTop = this.domHelper.getElementDistanceToTopOfDocument(this.viewStrategy.getFirstElement(this.topBuffer)); + this.distanceToTop = this.domHelper.getElementDistanceToTopOfDocument(this.templateStrategy.getFirstElement(this.topBuffer)); if (this.domHelper.hasOverflowScroll(this.scrollContainer)) { this._fixedHeightContainer = true; this.scrollContainer.addEventListener('scroll', this.scrollListener); @@ -588,7 +588,7 @@ export class VirtualRepeat extends AbstractRepeater { this._isAttached = false; this._ticking = false; this._hasCalculatedSizes = false; - this.viewStrategy.removeBufferElements(this.element, this.topBuffer, this.bottomBuffer); + this.templateStrategy.removeBufferElements(this.element, this.topBuffer, this.bottomBuffer); this.isLastIndex = false; this.scrollContainer = null; this.scrollContainerHeight = null; diff --git a/dist/commonjs/array-virtual-repeat-strategy.js b/dist/commonjs/array-virtual-repeat-strategy.js index 591f331..5e5916e 100644 --- a/dist/commonjs/array-virtual-repeat-strategy.js +++ b/dist/commonjs/array-virtual-repeat-strategy.js @@ -257,7 +257,7 @@ var ArrayVirtualRepeatStrategy = exports.ArrayVirtualRepeatStrategy = function ( var addIndex = splice.index; var end = splice.index + splice.addedCount; for (; addIndex < end; ++addIndex) { - var hasDistanceToBottomViewPort = (0, _utilities.getElementDistanceToBottomViewPort)(repeat.viewStrategy.getLastElement(repeat.bottomBuffer)) > 0; + var hasDistanceToBottomViewPort = (0, _utilities.getElementDistanceToBottomViewPort)(repeat.templateStrategy.getLastElement(repeat.bottomBuffer)) > 0; if (repeat.viewCount() === 0 || !this._isIndexBeforeViewSlot(repeat, viewSlot, addIndex) && !this._isIndexAfterViewSlot(repeat, viewSlot, addIndex) || hasDistanceToBottomViewPort) { var overrideContext = (0, _aureliaTemplatingResources.createFullOverrideContext)(repeat, array[addIndex], addIndex, arrayLength); repeat.insertView(addIndex, overrideContext.bindingContext, overrideContext); diff --git a/dist/commonjs/view-strategy.js b/dist/commonjs/template-strategy.js similarity index 73% rename from dist/commonjs/view-strategy.js rename to dist/commonjs/template-strategy.js index c6754ea..4df5160 100644 --- a/dist/commonjs/view-strategy.js +++ b/dist/commonjs/template-strategy.js @@ -3,7 +3,7 @@ Object.defineProperty(exports, "__esModule", { value: true }); -exports.DefaultViewStrategy = exports.TableStrategy = exports.ViewStrategyLocator = undefined; +exports.DefaultTemplateStrategy = exports.TableStrategy = exports.TemplateStrategyLocator = undefined; var _aureliaPal = require('aurelia-pal'); @@ -13,19 +13,19 @@ var _utilities = require('./utilities'); -var ViewStrategyLocator = exports.ViewStrategyLocator = function () { - function ViewStrategyLocator() { +var TemplateStrategyLocator = exports.TemplateStrategyLocator = function () { + function TemplateStrategyLocator() { } - ViewStrategyLocator.prototype.getStrategy = function getStrategy(element) { + TemplateStrategyLocator.prototype.getStrategy = function getStrategy(element) { if (element.parentNode && element.parentNode.localName === 'tbody') { return new TableStrategy(); } - return new DefaultViewStrategy(); + return new DefaultTemplateStrategy(); }; - return ViewStrategyLocator; + return TemplateStrategyLocator; }(); var TableStrategy = exports.TableStrategy = function () { @@ -95,51 +95,51 @@ var TableStrategy = exports.TableStrategy = function () { return TableStrategy; }(); -var DefaultViewStrategy = exports.DefaultViewStrategy = function () { - function DefaultViewStrategy() { +var DefaultTemplateStrategy = exports.DefaultTemplateStrategy = function () { + function DefaultTemplateStrategy() { } - DefaultViewStrategy.prototype.getScrollContainer = function getScrollContainer(element) { + DefaultTemplateStrategy.prototype.getScrollContainer = function getScrollContainer(element) { return element.parentNode; }; - DefaultViewStrategy.prototype.moveViewFirst = function moveViewFirst(view, topBuffer) { + DefaultTemplateStrategy.prototype.moveViewFirst = function moveViewFirst(view, topBuffer) { (0, _utilities.insertBeforeNode)(view, _aureliaPal.DOM.nextElementSibling(topBuffer)); }; - DefaultViewStrategy.prototype.moveViewLast = function moveViewLast(view, bottomBuffer) { + DefaultTemplateStrategy.prototype.moveViewLast = function moveViewLast(view, bottomBuffer) { var previousSibling = bottomBuffer.previousSibling; var referenceNode = previousSibling.nodeType === 8 && previousSibling.data === 'anchor' ? previousSibling : bottomBuffer; (0, _utilities.insertBeforeNode)(view, referenceNode); }; - DefaultViewStrategy.prototype.createTopBufferElement = function createTopBufferElement(element) { + DefaultTemplateStrategy.prototype.createTopBufferElement = function createTopBufferElement(element) { var elementName = element.parentNode.localName === 'ul' ? 'li' : 'div'; var buffer = _aureliaPal.DOM.createElement(elementName); element.parentNode.insertBefore(buffer, element); return buffer; }; - DefaultViewStrategy.prototype.createBottomBufferElement = function createBottomBufferElement(element) { + DefaultTemplateStrategy.prototype.createBottomBufferElement = function createBottomBufferElement(element) { var elementName = element.parentNode.localName === 'ul' ? 'li' : 'div'; var buffer = _aureliaPal.DOM.createElement(elementName); element.parentNode.insertBefore(buffer, element.nextSibling); return buffer; }; - DefaultViewStrategy.prototype.removeBufferElements = function removeBufferElements(element, topBuffer, bottomBuffer) { + DefaultTemplateStrategy.prototype.removeBufferElements = function removeBufferElements(element, topBuffer, bottomBuffer) { element.parentNode.removeChild(topBuffer); element.parentNode.removeChild(bottomBuffer); }; - DefaultViewStrategy.prototype.getFirstElement = function getFirstElement(topBuffer) { + DefaultTemplateStrategy.prototype.getFirstElement = function getFirstElement(topBuffer) { return _aureliaPal.DOM.nextElementSibling(topBuffer); }; - DefaultViewStrategy.prototype.getLastElement = function getLastElement(bottomBuffer) { + DefaultTemplateStrategy.prototype.getLastElement = function getLastElement(bottomBuffer) { return bottomBuffer.previousElementSibling; }; - return DefaultViewStrategy; + return DefaultTemplateStrategy; }(); \ No newline at end of file diff --git a/dist/commonjs/utilities.js b/dist/commonjs/utilities.js index 03eecb9..a616fd5 100644 --- a/dist/commonjs/utilities.js +++ b/dist/commonjs/utilities.js @@ -51,10 +51,10 @@ function rebindAndMoveView(repeat, view, index, moveToBottom) { view.bindingContext[repeat.local] = items[index]; if (moveToBottom) { viewSlot.children.push(viewSlot.children.shift()); - repeat.viewStrategy.moveViewLast(view, repeat.bottomBuffer); + repeat.templateStrategy.moveViewLast(view, repeat.bottomBuffer); } else { viewSlot.children.unshift(viewSlot.children.splice(-1, 1)[0]); - repeat.viewStrategy.moveViewFirst(view, repeat.topBuffer); + repeat.templateStrategy.moveViewFirst(view, repeat.topBuffer); } } diff --git a/dist/commonjs/virtual-repeat.js b/dist/commonjs/virtual-repeat.js index b32df35..5791dd1 100644 --- a/dist/commonjs/virtual-repeat.js +++ b/dist/commonjs/virtual-repeat.js @@ -23,7 +23,7 @@ var _domHelper = require('./dom-helper'); var _virtualRepeatStrategyLocator = require('./virtual-repeat-strategy-locator'); -var _viewStrategy = require('./view-strategy'); +var _templateStrategy = require('./template-strategy'); function _initDefineProp(target, property, descriptor, context) { if (!descriptor) return; @@ -74,10 +74,10 @@ function _initializerWarningHelper(descriptor, context) { throw new Error('Decorating class property failed. Please ensure that transform-class-properties is enabled.'); } -var VirtualRepeat = exports.VirtualRepeat = (_dec = (0, _aureliaTemplating.customAttribute)('virtual-repeat'), _dec2 = (0, _aureliaDependencyInjection.inject)(_aureliaPal.DOM.Element, _aureliaTemplating.BoundViewFactory, _aureliaTemplating.TargetInstruction, _aureliaTemplating.ViewSlot, _aureliaTemplating.ViewResources, _aureliaBinding.ObserverLocator, _virtualRepeatStrategyLocator.VirtualRepeatStrategyLocator, _viewStrategy.ViewStrategyLocator, _domHelper.DomHelper), _dec(_class = (0, _aureliaTemplating.templateController)(_class = _dec2(_class = (_class2 = function (_AbstractRepeater) { +var VirtualRepeat = exports.VirtualRepeat = (_dec = (0, _aureliaTemplating.customAttribute)('virtual-repeat'), _dec2 = (0, _aureliaDependencyInjection.inject)(_aureliaPal.DOM.Element, _aureliaTemplating.BoundViewFactory, _aureliaTemplating.TargetInstruction, _aureliaTemplating.ViewSlot, _aureliaTemplating.ViewResources, _aureliaBinding.ObserverLocator, _virtualRepeatStrategyLocator.VirtualRepeatStrategyLocator, _templateStrategy.TemplateStrategyLocator, _domHelper.DomHelper), _dec(_class = (0, _aureliaTemplating.templateController)(_class = _dec2(_class = (_class2 = function (_AbstractRepeater) { _inherits(VirtualRepeat, _AbstractRepeater); - function VirtualRepeat(element, viewFactory, instruction, viewSlot, viewResources, observerLocator, strategyLocator, viewStrategyLocator, domHelper) { + function VirtualRepeat(element, viewFactory, instruction, viewSlot, viewResources, observerLocator, strategyLocator, templateStrategyLocator, domHelper) { var _this = _possibleConstructorReturn(this, _AbstractRepeater.call(this, { @@ -112,7 +112,7 @@ var VirtualRepeat = exports.VirtualRepeat = (_dec = (0, _aureliaTemplating.custo _this.lookupFunctions = viewResources.lookupFunctions; _this.observerLocator = observerLocator; _this.strategyLocator = strategyLocator; - _this.viewStrategyLocator = viewStrategyLocator; + _this.templateStrategyLocator = templateStrategyLocator; _this.sourceExpression = (0, _aureliaTemplatingResources.getItemsSourceExpression)(_this.instruction, 'virtual-repeat.for'); _this.isOneTime = (0, _aureliaTemplatingResources.isOneTime)(_this.sourceExpression); _this.domHelper = domHelper; @@ -125,10 +125,10 @@ var VirtualRepeat = exports.VirtualRepeat = (_dec = (0, _aureliaTemplating.custo this._isAttached = true; var element = this.element; this._itemsLength = this.items.length; - this.viewStrategy = this.viewStrategyLocator.getStrategy(element); - this.scrollContainer = this.viewStrategy.getScrollContainer(element); - this.topBuffer = this.viewStrategy.createTopBufferElement(element); - this.bottomBuffer = this.viewStrategy.createBottomBufferElement(element); + this.templateStrategy = this.templateStrategyLocator.getStrategy(element); + this.scrollContainer = this.templateStrategy.getScrollContainer(element); + this.topBuffer = this.templateStrategy.createTopBufferElement(element); + this.bottomBuffer = this.templateStrategy.createBottomBufferElement(element); this.itemsChanged(); this.scrollListener = function () { return _this2._onScroll(); @@ -142,7 +142,7 @@ var VirtualRepeat = exports.VirtualRepeat = (_dec = (0, _aureliaTemplating.custo } }, 500); - this.distanceToTop = this.domHelper.getElementDistanceToTopOfDocument(this.viewStrategy.getFirstElement(this.topBuffer)); + this.distanceToTop = this.domHelper.getElementDistanceToTopOfDocument(this.templateStrategy.getFirstElement(this.topBuffer)); if (this.domHelper.hasOverflowScroll(this.scrollContainer)) { this._fixedHeightContainer = true; this.scrollContainer.addEventListener('scroll', this.scrollListener); @@ -173,7 +173,7 @@ var VirtualRepeat = exports.VirtualRepeat = (_dec = (0, _aureliaTemplating.custo this._isAttached = false; this._ticking = false; this._hasCalculatedSizes = false; - this.viewStrategy.removeBufferElements(this.element, this.topBuffer, this.bottomBuffer); + this.templateStrategy.removeBufferElements(this.element, this.topBuffer, this.bottomBuffer); this.isLastIndex = false; this.scrollContainer = null; this.scrollContainerHeight = null; diff --git a/dist/es2015/array-virtual-repeat-strategy.js b/dist/es2015/array-virtual-repeat-strategy.js index f6816ad..291f703 100644 --- a/dist/es2015/array-virtual-repeat-strategy.js +++ b/dist/es2015/array-virtual-repeat-strategy.js @@ -225,7 +225,7 @@ export let ArrayVirtualRepeatStrategy = class ArrayVirtualRepeatStrategy extends let addIndex = splice.index; let end = splice.index + splice.addedCount; for (; addIndex < end; ++addIndex) { - let hasDistanceToBottomViewPort = getElementDistanceToBottomViewPort(repeat.viewStrategy.getLastElement(repeat.bottomBuffer)) > 0; + let hasDistanceToBottomViewPort = getElementDistanceToBottomViewPort(repeat.templateStrategy.getLastElement(repeat.bottomBuffer)) > 0; if (repeat.viewCount() === 0 || !this._isIndexBeforeViewSlot(repeat, viewSlot, addIndex) && !this._isIndexAfterViewSlot(repeat, viewSlot, addIndex) || hasDistanceToBottomViewPort) { let overrideContext = createFullOverrideContext(repeat, array[addIndex], addIndex, arrayLength); repeat.insertView(addIndex, overrideContext.bindingContext, overrideContext); diff --git a/dist/es2015/view-strategy.js b/dist/es2015/template-strategy.js similarity index 94% rename from dist/es2015/view-strategy.js rename to dist/es2015/template-strategy.js index 2827d75..124aa00 100644 --- a/dist/es2015/view-strategy.js +++ b/dist/es2015/template-strategy.js @@ -2,12 +2,12 @@ import { DOM } from 'aurelia-pal'; import { View } from 'aurelia-templating'; import { insertBeforeNode } from './utilities'; -export let ViewStrategyLocator = class ViewStrategyLocator { +export let TemplateStrategyLocator = class TemplateStrategyLocator { getStrategy(element) { if (element.parentNode && element.parentNode.localName === 'tbody') { return new TableStrategy(); } - return new DefaultViewStrategy(); + return new DefaultTemplateStrategy(); } }; @@ -74,7 +74,7 @@ export let TableStrategy = class TableStrategy { } }; -export let DefaultViewStrategy = class DefaultViewStrategy { +export let DefaultTemplateStrategy = class DefaultTemplateStrategy { getScrollContainer(element) { return element.parentNode; } diff --git a/dist/es2015/utilities.js b/dist/es2015/utilities.js index 5a4354c..a724658 100644 --- a/dist/es2015/utilities.js +++ b/dist/es2015/utilities.js @@ -37,10 +37,10 @@ export function rebindAndMoveView(repeat, view, index, moveToBottom) { view.bindingContext[repeat.local] = items[index]; if (moveToBottom) { viewSlot.children.push(viewSlot.children.shift()); - repeat.viewStrategy.moveViewLast(view, repeat.bottomBuffer); + repeat.templateStrategy.moveViewLast(view, repeat.bottomBuffer); } else { viewSlot.children.unshift(viewSlot.children.splice(-1, 1)[0]); - repeat.viewStrategy.moveViewFirst(view, repeat.topBuffer); + repeat.templateStrategy.moveViewFirst(view, repeat.topBuffer); } } diff --git a/dist/es2015/virtual-repeat.js b/dist/es2015/virtual-repeat.js index b7a1d22..c2bd0f7 100644 --- a/dist/es2015/virtual-repeat.js +++ b/dist/es2015/virtual-repeat.js @@ -51,10 +51,10 @@ import { DOM } from 'aurelia-pal'; import { getStyleValue, calcOuterHeight, rebindAndMoveView } from './utilities'; import { DomHelper } from './dom-helper'; import { VirtualRepeatStrategyLocator } from './virtual-repeat-strategy-locator'; -import { ViewStrategyLocator } from './view-strategy'; +import { TemplateStrategyLocator } from './template-strategy'; -export let VirtualRepeat = (_dec = customAttribute('virtual-repeat'), _dec2 = inject(DOM.Element, BoundViewFactory, TargetInstruction, ViewSlot, ViewResources, ObserverLocator, VirtualRepeatStrategyLocator, ViewStrategyLocator, DomHelper), _dec(_class = templateController(_class = _dec2(_class = (_class2 = class VirtualRepeat extends AbstractRepeater { - constructor(element, viewFactory, instruction, viewSlot, viewResources, observerLocator, strategyLocator, viewStrategyLocator, domHelper) { +export let VirtualRepeat = (_dec = customAttribute('virtual-repeat'), _dec2 = inject(DOM.Element, BoundViewFactory, TargetInstruction, ViewSlot, ViewResources, ObserverLocator, VirtualRepeatStrategyLocator, TemplateStrategyLocator, DomHelper), _dec(_class = templateController(_class = _dec2(_class = (_class2 = class VirtualRepeat extends AbstractRepeater { + constructor(element, viewFactory, instruction, viewSlot, viewResources, observerLocator, strategyLocator, templateStrategyLocator, domHelper) { super({ local: 'item', viewsRequireLifecycle: viewsRequireLifecycle(viewFactory) @@ -87,7 +87,7 @@ export let VirtualRepeat = (_dec = customAttribute('virtual-repeat'), _dec2 = in this.lookupFunctions = viewResources.lookupFunctions; this.observerLocator = observerLocator; this.strategyLocator = strategyLocator; - this.viewStrategyLocator = viewStrategyLocator; + this.templateStrategyLocator = templateStrategyLocator; this.sourceExpression = getItemsSourceExpression(this.instruction, 'virtual-repeat.for'); this.isOneTime = isOneTime(this.sourceExpression); this.domHelper = domHelper; @@ -97,10 +97,10 @@ export let VirtualRepeat = (_dec = customAttribute('virtual-repeat'), _dec2 = in this._isAttached = true; let element = this.element; this._itemsLength = this.items.length; - this.viewStrategy = this.viewStrategyLocator.getStrategy(element); - this.scrollContainer = this.viewStrategy.getScrollContainer(element); - this.topBuffer = this.viewStrategy.createTopBufferElement(element); - this.bottomBuffer = this.viewStrategy.createBottomBufferElement(element); + this.templateStrategy = this.templateStrategyLocator.getStrategy(element); + this.scrollContainer = this.templateStrategy.getScrollContainer(element); + this.topBuffer = this.templateStrategy.createTopBufferElement(element); + this.bottomBuffer = this.templateStrategy.createBottomBufferElement(element); this.itemsChanged(); this.scrollListener = () => this._onScroll(); @@ -112,7 +112,7 @@ export let VirtualRepeat = (_dec = customAttribute('virtual-repeat'), _dec2 = in } }, 500); - this.distanceToTop = this.domHelper.getElementDistanceToTopOfDocument(this.viewStrategy.getFirstElement(this.topBuffer)); + this.distanceToTop = this.domHelper.getElementDistanceToTopOfDocument(this.templateStrategy.getFirstElement(this.topBuffer)); if (this.domHelper.hasOverflowScroll(this.scrollContainer)) { this._fixedHeightContainer = true; this.scrollContainer.addEventListener('scroll', this.scrollListener); @@ -143,7 +143,7 @@ export let VirtualRepeat = (_dec = customAttribute('virtual-repeat'), _dec2 = in this._isAttached = false; this._ticking = false; this._hasCalculatedSizes = false; - this.viewStrategy.removeBufferElements(this.element, this.topBuffer, this.bottomBuffer); + this.templateStrategy.removeBufferElements(this.element, this.topBuffer, this.bottomBuffer); this.isLastIndex = false; this.scrollContainer = null; this.scrollContainerHeight = null; diff --git a/dist/native-modules/array-virtual-repeat-strategy.js b/dist/native-modules/array-virtual-repeat-strategy.js index e50224d..5eef7ae 100644 --- a/dist/native-modules/array-virtual-repeat-strategy.js +++ b/dist/native-modules/array-virtual-repeat-strategy.js @@ -249,7 +249,7 @@ export var ArrayVirtualRepeatStrategy = function (_ArrayRepeatStrategy) { var addIndex = splice.index; var end = splice.index + splice.addedCount; for (; addIndex < end; ++addIndex) { - var hasDistanceToBottomViewPort = getElementDistanceToBottomViewPort(repeat.viewStrategy.getLastElement(repeat.bottomBuffer)) > 0; + var hasDistanceToBottomViewPort = getElementDistanceToBottomViewPort(repeat.templateStrategy.getLastElement(repeat.bottomBuffer)) > 0; if (repeat.viewCount() === 0 || !this._isIndexBeforeViewSlot(repeat, viewSlot, addIndex) && !this._isIndexAfterViewSlot(repeat, viewSlot, addIndex) || hasDistanceToBottomViewPort) { var overrideContext = createFullOverrideContext(repeat, array[addIndex], addIndex, arrayLength); repeat.insertView(addIndex, overrideContext.bindingContext, overrideContext); diff --git a/dist/native-modules/view-strategy.js b/dist/native-modules/template-strategy.js similarity index 74% rename from dist/native-modules/view-strategy.js rename to dist/native-modules/template-strategy.js index c759935..bfab251 100644 --- a/dist/native-modules/view-strategy.js +++ b/dist/native-modules/template-strategy.js @@ -4,19 +4,19 @@ import { DOM } from 'aurelia-pal'; import { View } from 'aurelia-templating'; import { insertBeforeNode } from './utilities'; -export var ViewStrategyLocator = function () { - function ViewStrategyLocator() { +export var TemplateStrategyLocator = function () { + function TemplateStrategyLocator() { } - ViewStrategyLocator.prototype.getStrategy = function getStrategy(element) { + TemplateStrategyLocator.prototype.getStrategy = function getStrategy(element) { if (element.parentNode && element.parentNode.localName === 'tbody') { return new TableStrategy(); } - return new DefaultViewStrategy(); + return new DefaultTemplateStrategy(); }; - return ViewStrategyLocator; + return TemplateStrategyLocator; }(); export var TableStrategy = function () { @@ -86,51 +86,51 @@ export var TableStrategy = function () { return TableStrategy; }(); -export var DefaultViewStrategy = function () { - function DefaultViewStrategy() { +export var DefaultTemplateStrategy = function () { + function DefaultTemplateStrategy() { } - DefaultViewStrategy.prototype.getScrollContainer = function getScrollContainer(element) { + DefaultTemplateStrategy.prototype.getScrollContainer = function getScrollContainer(element) { return element.parentNode; }; - DefaultViewStrategy.prototype.moveViewFirst = function moveViewFirst(view, topBuffer) { + DefaultTemplateStrategy.prototype.moveViewFirst = function moveViewFirst(view, topBuffer) { insertBeforeNode(view, DOM.nextElementSibling(topBuffer)); }; - DefaultViewStrategy.prototype.moveViewLast = function moveViewLast(view, bottomBuffer) { + DefaultTemplateStrategy.prototype.moveViewLast = function moveViewLast(view, bottomBuffer) { var previousSibling = bottomBuffer.previousSibling; var referenceNode = previousSibling.nodeType === 8 && previousSibling.data === 'anchor' ? previousSibling : bottomBuffer; insertBeforeNode(view, referenceNode); }; - DefaultViewStrategy.prototype.createTopBufferElement = function createTopBufferElement(element) { + DefaultTemplateStrategy.prototype.createTopBufferElement = function createTopBufferElement(element) { var elementName = element.parentNode.localName === 'ul' ? 'li' : 'div'; var buffer = DOM.createElement(elementName); element.parentNode.insertBefore(buffer, element); return buffer; }; - DefaultViewStrategy.prototype.createBottomBufferElement = function createBottomBufferElement(element) { + DefaultTemplateStrategy.prototype.createBottomBufferElement = function createBottomBufferElement(element) { var elementName = element.parentNode.localName === 'ul' ? 'li' : 'div'; var buffer = DOM.createElement(elementName); element.parentNode.insertBefore(buffer, element.nextSibling); return buffer; }; - DefaultViewStrategy.prototype.removeBufferElements = function removeBufferElements(element, topBuffer, bottomBuffer) { + DefaultTemplateStrategy.prototype.removeBufferElements = function removeBufferElements(element, topBuffer, bottomBuffer) { element.parentNode.removeChild(topBuffer); element.parentNode.removeChild(bottomBuffer); }; - DefaultViewStrategy.prototype.getFirstElement = function getFirstElement(topBuffer) { + DefaultTemplateStrategy.prototype.getFirstElement = function getFirstElement(topBuffer) { return DOM.nextElementSibling(topBuffer); }; - DefaultViewStrategy.prototype.getLastElement = function getLastElement(bottomBuffer) { + DefaultTemplateStrategy.prototype.getLastElement = function getLastElement(bottomBuffer) { return bottomBuffer.previousElementSibling; }; - return DefaultViewStrategy; + return DefaultTemplateStrategy; }(); \ No newline at end of file diff --git a/dist/native-modules/utilities.js b/dist/native-modules/utilities.js index b0f6c57..90f76ce 100644 --- a/dist/native-modules/utilities.js +++ b/dist/native-modules/utilities.js @@ -37,10 +37,10 @@ export function rebindAndMoveView(repeat, view, index, moveToBottom) { view.bindingContext[repeat.local] = items[index]; if (moveToBottom) { viewSlot.children.push(viewSlot.children.shift()); - repeat.viewStrategy.moveViewLast(view, repeat.bottomBuffer); + repeat.templateStrategy.moveViewLast(view, repeat.bottomBuffer); } else { viewSlot.children.unshift(viewSlot.children.splice(-1, 1)[0]); - repeat.viewStrategy.moveViewFirst(view, repeat.topBuffer); + repeat.templateStrategy.moveViewFirst(view, repeat.topBuffer); } } diff --git a/dist/native-modules/virtual-repeat.js b/dist/native-modules/virtual-repeat.js index ab37b31..eb1ab6b 100644 --- a/dist/native-modules/virtual-repeat.js +++ b/dist/native-modules/virtual-repeat.js @@ -57,12 +57,12 @@ import { DOM } from 'aurelia-pal'; import { getStyleValue, calcOuterHeight, rebindAndMoveView } from './utilities'; import { DomHelper } from './dom-helper'; import { VirtualRepeatStrategyLocator } from './virtual-repeat-strategy-locator'; -import { ViewStrategyLocator } from './view-strategy'; +import { TemplateStrategyLocator } from './template-strategy'; -export var VirtualRepeat = (_dec = customAttribute('virtual-repeat'), _dec2 = inject(DOM.Element, BoundViewFactory, TargetInstruction, ViewSlot, ViewResources, ObserverLocator, VirtualRepeatStrategyLocator, ViewStrategyLocator, DomHelper), _dec(_class = templateController(_class = _dec2(_class = (_class2 = function (_AbstractRepeater) { +export var VirtualRepeat = (_dec = customAttribute('virtual-repeat'), _dec2 = inject(DOM.Element, BoundViewFactory, TargetInstruction, ViewSlot, ViewResources, ObserverLocator, VirtualRepeatStrategyLocator, TemplateStrategyLocator, DomHelper), _dec(_class = templateController(_class = _dec2(_class = (_class2 = function (_AbstractRepeater) { _inherits(VirtualRepeat, _AbstractRepeater); - function VirtualRepeat(element, viewFactory, instruction, viewSlot, viewResources, observerLocator, strategyLocator, viewStrategyLocator, domHelper) { + function VirtualRepeat(element, viewFactory, instruction, viewSlot, viewResources, observerLocator, strategyLocator, templateStrategyLocator, domHelper) { var _this = _possibleConstructorReturn(this, _AbstractRepeater.call(this, { @@ -97,7 +97,7 @@ export var VirtualRepeat = (_dec = customAttribute('virtual-repeat'), _dec2 = in _this.lookupFunctions = viewResources.lookupFunctions; _this.observerLocator = observerLocator; _this.strategyLocator = strategyLocator; - _this.viewStrategyLocator = viewStrategyLocator; + _this.templateStrategyLocator = templateStrategyLocator; _this.sourceExpression = getItemsSourceExpression(_this.instruction, 'virtual-repeat.for'); _this.isOneTime = isOneTime(_this.sourceExpression); _this.domHelper = domHelper; @@ -110,10 +110,10 @@ export var VirtualRepeat = (_dec = customAttribute('virtual-repeat'), _dec2 = in this._isAttached = true; var element = this.element; this._itemsLength = this.items.length; - this.viewStrategy = this.viewStrategyLocator.getStrategy(element); - this.scrollContainer = this.viewStrategy.getScrollContainer(element); - this.topBuffer = this.viewStrategy.createTopBufferElement(element); - this.bottomBuffer = this.viewStrategy.createBottomBufferElement(element); + this.templateStrategy = this.templateStrategyLocator.getStrategy(element); + this.scrollContainer = this.templateStrategy.getScrollContainer(element); + this.topBuffer = this.templateStrategy.createTopBufferElement(element); + this.bottomBuffer = this.templateStrategy.createBottomBufferElement(element); this.itemsChanged(); this.scrollListener = function () { return _this2._onScroll(); @@ -127,7 +127,7 @@ export var VirtualRepeat = (_dec = customAttribute('virtual-repeat'), _dec2 = in } }, 500); - this.distanceToTop = this.domHelper.getElementDistanceToTopOfDocument(this.viewStrategy.getFirstElement(this.topBuffer)); + this.distanceToTop = this.domHelper.getElementDistanceToTopOfDocument(this.templateStrategy.getFirstElement(this.topBuffer)); if (this.domHelper.hasOverflowScroll(this.scrollContainer)) { this._fixedHeightContainer = true; this.scrollContainer.addEventListener('scroll', this.scrollListener); @@ -158,7 +158,7 @@ export var VirtualRepeat = (_dec = customAttribute('virtual-repeat'), _dec2 = in this._isAttached = false; this._ticking = false; this._hasCalculatedSizes = false; - this.viewStrategy.removeBufferElements(this.element, this.topBuffer, this.bottomBuffer); + this.templateStrategy.removeBufferElements(this.element, this.topBuffer, this.bottomBuffer); this.isLastIndex = false; this.scrollContainer = null; this.scrollContainerHeight = null; diff --git a/dist/system/array-virtual-repeat-strategy.js b/dist/system/array-virtual-repeat-strategy.js index 3aaca72..0eaaa8d 100644 --- a/dist/system/array-virtual-repeat-strategy.js +++ b/dist/system/array-virtual-repeat-strategy.js @@ -283,7 +283,7 @@ System.register(['aurelia-templating-resources', './utilities'], function (_expo var addIndex = splice.index; var end = splice.index + splice.addedCount; for (; addIndex < end; ++addIndex) { - var hasDistanceToBottomViewPort = getElementDistanceToBottomViewPort(repeat.viewStrategy.getLastElement(repeat.bottomBuffer)) > 0; + var hasDistanceToBottomViewPort = getElementDistanceToBottomViewPort(repeat.templateStrategy.getLastElement(repeat.bottomBuffer)) > 0; if (repeat.viewCount() === 0 || !this._isIndexBeforeViewSlot(repeat, viewSlot, addIndex) && !this._isIndexAfterViewSlot(repeat, viewSlot, addIndex) || hasDistanceToBottomViewPort) { var overrideContext = createFullOverrideContext(repeat, array[addIndex], addIndex, arrayLength); repeat.insertView(addIndex, overrideContext.bindingContext, overrideContext); diff --git a/dist/system/view-strategy.js b/dist/system/template-strategy.js similarity index 73% rename from dist/system/view-strategy.js rename to dist/system/template-strategy.js index fcee704..57e9a47 100644 --- a/dist/system/view-strategy.js +++ b/dist/system/template-strategy.js @@ -3,7 +3,7 @@ System.register(['aurelia-pal', 'aurelia-templating', './utilities'], function (_export, _context) { "use strict"; - var DOM, View, insertBeforeNode, ViewStrategyLocator, TableStrategy, DefaultViewStrategy; + var DOM, View, insertBeforeNode, TemplateStrategyLocator, TableStrategy, DefaultTemplateStrategy; @@ -16,22 +16,22 @@ System.register(['aurelia-pal', 'aurelia-templating', './utilities'], function ( insertBeforeNode = _utilities.insertBeforeNode; }], execute: function () { - _export('ViewStrategyLocator', ViewStrategyLocator = function () { - function ViewStrategyLocator() { + _export('TemplateStrategyLocator', TemplateStrategyLocator = function () { + function TemplateStrategyLocator() { } - ViewStrategyLocator.prototype.getStrategy = function getStrategy(element) { + TemplateStrategyLocator.prototype.getStrategy = function getStrategy(element) { if (element.parentNode && element.parentNode.localName === 'tbody') { return new TableStrategy(); } - return new DefaultViewStrategy(); + return new DefaultTemplateStrategy(); }; - return ViewStrategyLocator; + return TemplateStrategyLocator; }()); - _export('ViewStrategyLocator', ViewStrategyLocator); + _export('TemplateStrategyLocator', TemplateStrategyLocator); _export('TableStrategy', TableStrategy = function () { function TableStrategy() { @@ -102,56 +102,56 @@ System.register(['aurelia-pal', 'aurelia-templating', './utilities'], function ( _export('TableStrategy', TableStrategy); - _export('DefaultViewStrategy', DefaultViewStrategy = function () { - function DefaultViewStrategy() { + _export('DefaultTemplateStrategy', DefaultTemplateStrategy = function () { + function DefaultTemplateStrategy() { } - DefaultViewStrategy.prototype.getScrollContainer = function getScrollContainer(element) { + DefaultTemplateStrategy.prototype.getScrollContainer = function getScrollContainer(element) { return element.parentNode; }; - DefaultViewStrategy.prototype.moveViewFirst = function moveViewFirst(view, topBuffer) { + DefaultTemplateStrategy.prototype.moveViewFirst = function moveViewFirst(view, topBuffer) { insertBeforeNode(view, DOM.nextElementSibling(topBuffer)); }; - DefaultViewStrategy.prototype.moveViewLast = function moveViewLast(view, bottomBuffer) { + DefaultTemplateStrategy.prototype.moveViewLast = function moveViewLast(view, bottomBuffer) { var previousSibling = bottomBuffer.previousSibling; var referenceNode = previousSibling.nodeType === 8 && previousSibling.data === 'anchor' ? previousSibling : bottomBuffer; insertBeforeNode(view, referenceNode); }; - DefaultViewStrategy.prototype.createTopBufferElement = function createTopBufferElement(element) { + DefaultTemplateStrategy.prototype.createTopBufferElement = function createTopBufferElement(element) { var elementName = element.parentNode.localName === 'ul' ? 'li' : 'div'; var buffer = DOM.createElement(elementName); element.parentNode.insertBefore(buffer, element); return buffer; }; - DefaultViewStrategy.prototype.createBottomBufferElement = function createBottomBufferElement(element) { + DefaultTemplateStrategy.prototype.createBottomBufferElement = function createBottomBufferElement(element) { var elementName = element.parentNode.localName === 'ul' ? 'li' : 'div'; var buffer = DOM.createElement(elementName); element.parentNode.insertBefore(buffer, element.nextSibling); return buffer; }; - DefaultViewStrategy.prototype.removeBufferElements = function removeBufferElements(element, topBuffer, bottomBuffer) { + DefaultTemplateStrategy.prototype.removeBufferElements = function removeBufferElements(element, topBuffer, bottomBuffer) { element.parentNode.removeChild(topBuffer); element.parentNode.removeChild(bottomBuffer); }; - DefaultViewStrategy.prototype.getFirstElement = function getFirstElement(topBuffer) { + DefaultTemplateStrategy.prototype.getFirstElement = function getFirstElement(topBuffer) { return DOM.nextElementSibling(topBuffer); }; - DefaultViewStrategy.prototype.getLastElement = function getLastElement(bottomBuffer) { + DefaultTemplateStrategy.prototype.getLastElement = function getLastElement(bottomBuffer) { return bottomBuffer.previousElementSibling; }; - return DefaultViewStrategy; + return DefaultTemplateStrategy; }()); - _export('DefaultViewStrategy', DefaultViewStrategy); + _export('DefaultTemplateStrategy', DefaultTemplateStrategy); } }; }); \ No newline at end of file diff --git a/dist/system/utilities.js b/dist/system/utilities.js index 7c20522..65dfe12 100644 --- a/dist/system/utilities.js +++ b/dist/system/utilities.js @@ -53,10 +53,10 @@ System.register(['aurelia-templating-resources', 'aurelia-templating'], function view.bindingContext[repeat.local] = items[index]; if (moveToBottom) { viewSlot.children.push(viewSlot.children.shift()); - repeat.viewStrategy.moveViewLast(view, repeat.bottomBuffer); + repeat.templateStrategy.moveViewLast(view, repeat.bottomBuffer); } else { viewSlot.children.unshift(viewSlot.children.splice(-1, 1)[0]); - repeat.viewStrategy.moveViewFirst(view, repeat.topBuffer); + repeat.templateStrategy.moveViewFirst(view, repeat.topBuffer); } } diff --git a/dist/system/virtual-repeat.js b/dist/system/virtual-repeat.js index 5c2cec4..47228f4 100644 --- a/dist/system/virtual-repeat.js +++ b/dist/system/virtual-repeat.js @@ -1,9 +1,9 @@ 'use strict'; -System.register(['aurelia-dependency-injection', 'aurelia-binding', 'aurelia-templating', 'aurelia-templating-resources', 'aurelia-pal', './utilities', './dom-helper', './virtual-repeat-strategy-locator', './view-strategy'], function (_export, _context) { +System.register(['aurelia-dependency-injection', 'aurelia-binding', 'aurelia-templating', 'aurelia-templating-resources', 'aurelia-pal', './utilities', './dom-helper', './virtual-repeat-strategy-locator', './template-strategy'], function (_export, _context) { "use strict"; - var inject, ObserverLocator, BoundViewFactory, ViewSlot, ViewResources, TargetInstruction, customAttribute, bindable, templateController, View, AbstractRepeater, getItemsSourceExpression, isOneTime, unwrapExpression, updateOneTimeBinding, viewsRequireLifecycle, DOM, getStyleValue, calcOuterHeight, rebindAndMoveView, DomHelper, VirtualRepeatStrategyLocator, ViewStrategyLocator, _dec, _dec2, _class, _desc, _value, _class2, _descriptor, _descriptor2, VirtualRepeat; + var inject, ObserverLocator, BoundViewFactory, ViewSlot, ViewResources, TargetInstruction, customAttribute, bindable, templateController, View, AbstractRepeater, getItemsSourceExpression, isOneTime, unwrapExpression, updateOneTimeBinding, viewsRequireLifecycle, DOM, getStyleValue, calcOuterHeight, rebindAndMoveView, DomHelper, VirtualRepeatStrategyLocator, TemplateStrategyLocator, _dec, _dec2, _class, _desc, _value, _class2, _descriptor, _descriptor2, VirtualRepeat; function _initDefineProp(target, property, descriptor, context) { if (!descriptor) return; @@ -105,14 +105,14 @@ System.register(['aurelia-dependency-injection', 'aurelia-binding', 'aurelia-tem DomHelper = _domHelper.DomHelper; }, function (_virtualRepeatStrategyLocator) { VirtualRepeatStrategyLocator = _virtualRepeatStrategyLocator.VirtualRepeatStrategyLocator; - }, function (_viewStrategy) { - ViewStrategyLocator = _viewStrategy.ViewStrategyLocator; + }, function (_templateStrategy) { + TemplateStrategyLocator = _templateStrategy.TemplateStrategyLocator; }], execute: function () { - _export('VirtualRepeat', VirtualRepeat = (_dec = customAttribute('virtual-repeat'), _dec2 = inject(DOM.Element, BoundViewFactory, TargetInstruction, ViewSlot, ViewResources, ObserverLocator, VirtualRepeatStrategyLocator, ViewStrategyLocator, DomHelper), _dec(_class = templateController(_class = _dec2(_class = (_class2 = function (_AbstractRepeater) { + _export('VirtualRepeat', VirtualRepeat = (_dec = customAttribute('virtual-repeat'), _dec2 = inject(DOM.Element, BoundViewFactory, TargetInstruction, ViewSlot, ViewResources, ObserverLocator, VirtualRepeatStrategyLocator, TemplateStrategyLocator, DomHelper), _dec(_class = templateController(_class = _dec2(_class = (_class2 = function (_AbstractRepeater) { _inherits(VirtualRepeat, _AbstractRepeater); - function VirtualRepeat(element, viewFactory, instruction, viewSlot, viewResources, observerLocator, strategyLocator, viewStrategyLocator, domHelper) { + function VirtualRepeat(element, viewFactory, instruction, viewSlot, viewResources, observerLocator, strategyLocator, templateStrategyLocator, domHelper) { var _this = _possibleConstructorReturn(this, _AbstractRepeater.call(this, { @@ -147,7 +147,7 @@ System.register(['aurelia-dependency-injection', 'aurelia-binding', 'aurelia-tem _this.lookupFunctions = viewResources.lookupFunctions; _this.observerLocator = observerLocator; _this.strategyLocator = strategyLocator; - _this.viewStrategyLocator = viewStrategyLocator; + _this.templateStrategyLocator = templateStrategyLocator; _this.sourceExpression = getItemsSourceExpression(_this.instruction, 'virtual-repeat.for'); _this.isOneTime = isOneTime(_this.sourceExpression); _this.domHelper = domHelper; @@ -160,10 +160,10 @@ System.register(['aurelia-dependency-injection', 'aurelia-binding', 'aurelia-tem this._isAttached = true; var element = this.element; this._itemsLength = this.items.length; - this.viewStrategy = this.viewStrategyLocator.getStrategy(element); - this.scrollContainer = this.viewStrategy.getScrollContainer(element); - this.topBuffer = this.viewStrategy.createTopBufferElement(element); - this.bottomBuffer = this.viewStrategy.createBottomBufferElement(element); + this.templateStrategy = this.templateStrategyLocator.getStrategy(element); + this.scrollContainer = this.templateStrategy.getScrollContainer(element); + this.topBuffer = this.templateStrategy.createTopBufferElement(element); + this.bottomBuffer = this.templateStrategy.createBottomBufferElement(element); this.itemsChanged(); this.scrollListener = function () { return _this2._onScroll(); @@ -177,7 +177,7 @@ System.register(['aurelia-dependency-injection', 'aurelia-binding', 'aurelia-tem } }, 500); - this.distanceToTop = this.domHelper.getElementDistanceToTopOfDocument(this.viewStrategy.getFirstElement(this.topBuffer)); + this.distanceToTop = this.domHelper.getElementDistanceToTopOfDocument(this.templateStrategy.getFirstElement(this.topBuffer)); if (this.domHelper.hasOverflowScroll(this.scrollContainer)) { this._fixedHeightContainer = true; this.scrollContainer.addEventListener('scroll', this.scrollListener); @@ -208,7 +208,7 @@ System.register(['aurelia-dependency-injection', 'aurelia-binding', 'aurelia-tem this._isAttached = false; this._ticking = false; this._hasCalculatedSizes = false; - this.viewStrategy.removeBufferElements(this.element, this.topBuffer, this.bottomBuffer); + this.templateStrategy.removeBufferElements(this.element, this.topBuffer, this.bottomBuffer); this.isLastIndex = false; this.scrollContainer = null; this.scrollContainerHeight = null; diff --git a/dist/temp/aurelia-ui-virtualization.js b/dist/temp/aurelia-ui-virtualization.js index 521eaae..6129588 100644 --- a/dist/temp/aurelia-ui-virtualization.js +++ b/dist/temp/aurelia-ui-virtualization.js @@ -3,7 +3,7 @@ Object.defineProperty(exports, "__esModule", { value: true }); -exports.VirtualRepeat = exports.VirtualRepeatStrategyLocator = exports.DefaultViewStrategy = exports.TableStrategy = exports.ViewStrategyLocator = exports.ArrayVirtualRepeatStrategy = exports.DomHelper = undefined; +exports.VirtualRepeat = exports.VirtualRepeatStrategyLocator = exports.DefaultTemplateStrategy = exports.TableStrategy = exports.TemplateStrategyLocator = exports.ArrayVirtualRepeatStrategy = exports.DomHelper = undefined; var _dec, _dec2, _class2, _desc, _value, _class3, _descriptor, _descriptor2; @@ -132,10 +132,10 @@ function rebindAndMoveView(repeat, view, index, moveToBottom) { view.bindingContext[repeat.local] = items[index]; if (moveToBottom) { viewSlot.children.push(viewSlot.children.shift()); - repeat.viewStrategy.moveViewLast(view, repeat.bottomBuffer); + repeat.templateStrategy.moveViewLast(view, repeat.bottomBuffer); } else { viewSlot.children.unshift(viewSlot.children.splice(-1, 1)[0]); - repeat.viewStrategy.moveViewFirst(view, repeat.topBuffer); + repeat.templateStrategy.moveViewFirst(view, repeat.topBuffer); } } @@ -397,7 +397,7 @@ var ArrayVirtualRepeatStrategy = exports.ArrayVirtualRepeatStrategy = function ( var addIndex = splice.index; var end = splice.index + splice.addedCount; for (; addIndex < end; ++addIndex) { - var hasDistanceToBottomViewPort = getElementDistanceToBottomViewPort(repeat.viewStrategy.getLastElement(repeat.bottomBuffer)) > 0; + var hasDistanceToBottomViewPort = getElementDistanceToBottomViewPort(repeat.templateStrategy.getLastElement(repeat.bottomBuffer)) > 0; if (repeat.viewCount() === 0 || !this._isIndexBeforeViewSlot(repeat, viewSlot, addIndex) && !this._isIndexAfterViewSlot(repeat, viewSlot, addIndex) || hasDistanceToBottomViewPort) { var overrideContext = (0, _aureliaTemplatingResources.createFullOverrideContext)(repeat, array[addIndex], addIndex, arrayLength); repeat.insertView(addIndex, overrideContext.bindingContext, overrideContext); @@ -427,19 +427,19 @@ var ArrayVirtualRepeatStrategy = exports.ArrayVirtualRepeatStrategy = function ( return ArrayVirtualRepeatStrategy; }(_aureliaTemplatingResources.ArrayRepeatStrategy); -var ViewStrategyLocator = exports.ViewStrategyLocator = function () { - function ViewStrategyLocator() { - _classCallCheck(this, ViewStrategyLocator); +var TemplateStrategyLocator = exports.TemplateStrategyLocator = function () { + function TemplateStrategyLocator() { + _classCallCheck(this, TemplateStrategyLocator); } - ViewStrategyLocator.prototype.getStrategy = function getStrategy(element) { + TemplateStrategyLocator.prototype.getStrategy = function getStrategy(element) { if (element.parentNode && element.parentNode.localName === 'tbody') { return new TableStrategy(); } - return new DefaultViewStrategy(); + return new DefaultTemplateStrategy(); }; - return ViewStrategyLocator; + return TemplateStrategyLocator; }(); var TableStrategy = exports.TableStrategy = function () { @@ -509,53 +509,53 @@ var TableStrategy = exports.TableStrategy = function () { return TableStrategy; }(); -var DefaultViewStrategy = exports.DefaultViewStrategy = function () { - function DefaultViewStrategy() { - _classCallCheck(this, DefaultViewStrategy); +var DefaultTemplateStrategy = exports.DefaultTemplateStrategy = function () { + function DefaultTemplateStrategy() { + _classCallCheck(this, DefaultTemplateStrategy); } - DefaultViewStrategy.prototype.getScrollContainer = function getScrollContainer(element) { + DefaultTemplateStrategy.prototype.getScrollContainer = function getScrollContainer(element) { return element.parentNode; }; - DefaultViewStrategy.prototype.moveViewFirst = function moveViewFirst(view, topBuffer) { + DefaultTemplateStrategy.prototype.moveViewFirst = function moveViewFirst(view, topBuffer) { insertBeforeNode(view, _aureliaPal.DOM.nextElementSibling(topBuffer)); }; - DefaultViewStrategy.prototype.moveViewLast = function moveViewLast(view, bottomBuffer) { + DefaultTemplateStrategy.prototype.moveViewLast = function moveViewLast(view, bottomBuffer) { var previousSibling = bottomBuffer.previousSibling; var referenceNode = previousSibling.nodeType === 8 && previousSibling.data === 'anchor' ? previousSibling : bottomBuffer; insertBeforeNode(view, referenceNode); }; - DefaultViewStrategy.prototype.createTopBufferElement = function createTopBufferElement(element) { + DefaultTemplateStrategy.prototype.createTopBufferElement = function createTopBufferElement(element) { var elementName = element.parentNode.localName === 'ul' ? 'li' : 'div'; var buffer = _aureliaPal.DOM.createElement(elementName); element.parentNode.insertBefore(buffer, element); return buffer; }; - DefaultViewStrategy.prototype.createBottomBufferElement = function createBottomBufferElement(element) { + DefaultTemplateStrategy.prototype.createBottomBufferElement = function createBottomBufferElement(element) { var elementName = element.parentNode.localName === 'ul' ? 'li' : 'div'; var buffer = _aureliaPal.DOM.createElement(elementName); element.parentNode.insertBefore(buffer, element.nextSibling); return buffer; }; - DefaultViewStrategy.prototype.removeBufferElements = function removeBufferElements(element, topBuffer, bottomBuffer) { + DefaultTemplateStrategy.prototype.removeBufferElements = function removeBufferElements(element, topBuffer, bottomBuffer) { element.parentNode.removeChild(topBuffer); element.parentNode.removeChild(bottomBuffer); }; - DefaultViewStrategy.prototype.getFirstElement = function getFirstElement(topBuffer) { + DefaultTemplateStrategy.prototype.getFirstElement = function getFirstElement(topBuffer) { return _aureliaPal.DOM.nextElementSibling(topBuffer); }; - DefaultViewStrategy.prototype.getLastElement = function getLastElement(bottomBuffer) { + DefaultTemplateStrategy.prototype.getLastElement = function getLastElement(bottomBuffer) { return bottomBuffer.previousElementSibling; }; - return DefaultViewStrategy; + return DefaultTemplateStrategy; }(); var VirtualRepeatStrategyLocator = exports.VirtualRepeatStrategyLocator = function (_RepeatStrategyLocato) { @@ -578,10 +578,10 @@ var VirtualRepeatStrategyLocator = exports.VirtualRepeatStrategyLocator = functi return VirtualRepeatStrategyLocator; }(_aureliaTemplatingResources.RepeatStrategyLocator); -var VirtualRepeat = exports.VirtualRepeat = (_dec = (0, _aureliaTemplating.customAttribute)('virtual-repeat'), _dec2 = (0, _aureliaDependencyInjection.inject)(_aureliaPal.DOM.Element, _aureliaTemplating.BoundViewFactory, _aureliaTemplating.TargetInstruction, _aureliaTemplating.ViewSlot, _aureliaTemplating.ViewResources, _aureliaBinding.ObserverLocator, VirtualRepeatStrategyLocator, ViewStrategyLocator, DomHelper), _dec(_class2 = (0, _aureliaTemplating.templateController)(_class2 = _dec2(_class2 = (_class3 = function (_AbstractRepeater) { +var VirtualRepeat = exports.VirtualRepeat = (_dec = (0, _aureliaTemplating.customAttribute)('virtual-repeat'), _dec2 = (0, _aureliaDependencyInjection.inject)(_aureliaPal.DOM.Element, _aureliaTemplating.BoundViewFactory, _aureliaTemplating.TargetInstruction, _aureliaTemplating.ViewSlot, _aureliaTemplating.ViewResources, _aureliaBinding.ObserverLocator, VirtualRepeatStrategyLocator, TemplateStrategyLocator, DomHelper), _dec(_class2 = (0, _aureliaTemplating.templateController)(_class2 = _dec2(_class2 = (_class3 = function (_AbstractRepeater) { _inherits(VirtualRepeat, _AbstractRepeater); - function VirtualRepeat(element, viewFactory, instruction, viewSlot, viewResources, observerLocator, strategyLocator, viewStrategyLocator, domHelper) { + function VirtualRepeat(element, viewFactory, instruction, viewSlot, viewResources, observerLocator, strategyLocator, templateStrategyLocator, domHelper) { _classCallCheck(this, VirtualRepeat); var _this5 = _possibleConstructorReturn(this, _AbstractRepeater.call(this, { @@ -616,7 +616,7 @@ var VirtualRepeat = exports.VirtualRepeat = (_dec = (0, _aureliaTemplating.custo _this5.lookupFunctions = viewResources.lookupFunctions; _this5.observerLocator = observerLocator; _this5.strategyLocator = strategyLocator; - _this5.viewStrategyLocator = viewStrategyLocator; + _this5.templateStrategyLocator = templateStrategyLocator; _this5.sourceExpression = (0, _aureliaTemplatingResources.getItemsSourceExpression)(_this5.instruction, 'virtual-repeat.for'); _this5.isOneTime = (0, _aureliaTemplatingResources.isOneTime)(_this5.sourceExpression); _this5.domHelper = domHelper; @@ -629,10 +629,10 @@ var VirtualRepeat = exports.VirtualRepeat = (_dec = (0, _aureliaTemplating.custo this._isAttached = true; var element = this.element; this._itemsLength = this.items.length; - this.viewStrategy = this.viewStrategyLocator.getStrategy(element); - this.scrollContainer = this.viewStrategy.getScrollContainer(element); - this.topBuffer = this.viewStrategy.createTopBufferElement(element); - this.bottomBuffer = this.viewStrategy.createBottomBufferElement(element); + this.templateStrategy = this.templateStrategyLocator.getStrategy(element); + this.scrollContainer = this.templateStrategy.getScrollContainer(element); + this.topBuffer = this.templateStrategy.createTopBufferElement(element); + this.bottomBuffer = this.templateStrategy.createBottomBufferElement(element); this.itemsChanged(); this.scrollListener = function () { return _this6._onScroll(); @@ -646,7 +646,7 @@ var VirtualRepeat = exports.VirtualRepeat = (_dec = (0, _aureliaTemplating.custo } }, 500); - this.distanceToTop = this.domHelper.getElementDistanceToTopOfDocument(this.viewStrategy.getFirstElement(this.topBuffer)); + this.distanceToTop = this.domHelper.getElementDistanceToTopOfDocument(this.templateStrategy.getFirstElement(this.topBuffer)); if (this.domHelper.hasOverflowScroll(this.scrollContainer)) { this._fixedHeightContainer = true; this.scrollContainer.addEventListener('scroll', this.scrollListener); @@ -677,7 +677,7 @@ var VirtualRepeat = exports.VirtualRepeat = (_dec = (0, _aureliaTemplating.custo this._isAttached = false; this._ticking = false; this._hasCalculatedSizes = false; - this.viewStrategy.removeBufferElements(this.element, this.topBuffer, this.bottomBuffer); + this.templateStrategy.removeBufferElements(this.element, this.topBuffer, this.bottomBuffer); this.isLastIndex = false; this.scrollContainer = null; this.scrollContainerHeight = null; diff --git a/doc/api.json b/doc/api.json index 399430e..51b4416 100644 --- a/doc/api.json +++ b/doc/api.json @@ -1 +1 @@ -{"name":"aurelia-ui-virtualization","children":[{"id":38,"name":"ArrayVirtualRepeatStrategy","kind":128,"kindString":"Class","flags":{"isExported":true},"comment":{"shortText":"A strategy for repeating a template over an array."},"children":[{"id":86,"name":"_getViewIndex","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":87,"name":"_getViewIndex","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":88,"name":"repeat","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"VirtualRepeat","id":176}},{"id":89,"name":"viewSlot","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"ViewSlot"}},{"id":90,"name":"index","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"instrinct","name":"number"}}],"type":{"type":"instrinct","name":"number"}}]},{"id":91,"name":"_handleAddedSplices","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":92,"name":"_handleAddedSplices","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":93,"name":"repeat","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"VirtualRepeat","id":176}},{"id":94,"name":"array","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Array","typeArguments":[{"type":"instrinct","name":"any"}]}},{"id":95,"name":"splices","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"instrinct","name":"any"}}],"type":{"type":"instrinct","name":"void"},"overwrites":{"type":"reference","name":"ArrayRepeatStrategy._handleAddedSplices"}}],"overwrites":{"type":"reference","name":"ArrayRepeatStrategy._handleAddedSplices"}},{"id":50,"name":"_inPlaceProcessItems","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":51,"name":"_inPlaceProcessItems","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":52,"name":"repeat","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"VirtualRepeat","id":176}},{"id":53,"name":"items","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Array","typeArguments":[{"type":"instrinct","name":"any"}]}}],"type":{"type":"instrinct","name":"void"},"overwrites":{"type":"reference","name":"ArrayRepeatStrategy._inPlaceProcessItems"}}],"overwrites":{"type":"reference","name":"ArrayRepeatStrategy._inPlaceProcessItems"}},{"id":81,"name":"_isIndexAfterViewSlot","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":82,"name":"_isIndexAfterViewSlot","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":83,"name":"repeat","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"VirtualRepeat","id":176}},{"id":84,"name":"viewSlot","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"ViewSlot"}},{"id":85,"name":"index","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"instrinct","name":"number"}}],"type":{"type":"instrinct","name":"number"}}]},{"id":76,"name":"_isIndexBeforeViewSlot","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":77,"name":"_isIndexBeforeViewSlot","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":78,"name":"repeat","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"VirtualRepeat","id":176}},{"id":79,"name":"viewSlot","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"ViewSlot"}},{"id":80,"name":"index","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"instrinct","name":"number"}}],"type":{"type":"instrinct","name":"number"}}]},{"id":69,"name":"_removeViewAt","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":70,"name":"_removeViewAt","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":71,"name":"repeat","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"VirtualRepeat","id":176}},{"id":72,"name":"collectionIndex","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"instrinct","name":"number"}},{"id":73,"name":"returnToCache","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"instrinct","name":"boolean"}},{"id":74,"name":"j","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"instrinct","name":"number"}},{"id":75,"name":"removedLength","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"instrinct","name":"number"}}],"type":{"type":"instrinct","name":"any"}}]},{"id":64,"name":"_runSplices","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":65,"name":"_runSplices","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":66,"name":"repeat","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"VirtualRepeat","id":176}},{"id":67,"name":"array","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Array","typeArguments":[{"type":"instrinct","name":"any"}]}},{"id":68,"name":"splices","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"instrinct","name":"any"}}],"type":{"type":"instrinct","name":"any"},"overwrites":{"type":"reference","name":"ArrayRepeatStrategy._runSplices"}}],"overwrites":{"type":"reference","name":"ArrayRepeatStrategy._runSplices"}},{"id":46,"name":"_standardProcessInstanceChanged","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":47,"name":"_standardProcessInstanceChanged","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":48,"name":"repeat","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"VirtualRepeat","id":176}},{"id":49,"name":"items","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Array","typeArguments":[{"type":"instrinct","name":"any"}]}}],"type":{"type":"instrinct","name":"void"},"overwrites":{"type":"reference","name":"ArrayRepeatStrategy._standardProcessInstanceChanged"}}],"overwrites":{"type":"reference","name":"ArrayRepeatStrategy._standardProcessInstanceChanged"}},{"id":59,"name":"_standardProcessInstanceMutated","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":60,"name":"_standardProcessInstanceMutated","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":61,"name":"repeat","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"VirtualRepeat","id":176}},{"id":62,"name":"array","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Array","typeArguments":[{"type":"instrinct","name":"any"}]}},{"id":63,"name":"splices","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"instrinct","name":"any"}}],"type":{"type":"instrinct","name":"void"},"overwrites":{"type":"reference","name":"ArrayRepeatStrategy._standardProcessInstanceMutated"}}],"overwrites":{"type":"reference","name":"ArrayRepeatStrategy._standardProcessInstanceMutated"}},{"id":39,"name":"createFirstItem","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":40,"name":"createFirstItem","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":41,"name":"repeat","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"VirtualRepeat","id":176}}],"type":{"type":"instrinct","name":"void"}}]},{"id":96,"name":"getCollectionObserver","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":97,"name":"getCollectionObserver","kind":4096,"kindString":"Call signature","flags":{},"comment":{"shortText":"Gets an observer for the specified collection."},"parameters":[{"id":98,"name":"observerLocator","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"comment":{"text":"The observer locator instance."},"type":{"type":"instrinct","name":"any"}},{"id":99,"name":"items","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"comment":{"text":"The items to be observed.\n"},"type":{"type":"instrinct","name":"any"}}],"type":{"type":"instrinct","name":"any"},"inheritedFrom":{"type":"reference","name":"ArrayRepeatStrategy.getCollectionObserver"}}],"inheritedFrom":{"type":"reference","name":"ArrayRepeatStrategy.getCollectionObserver"}},{"id":42,"name":"instanceChanged","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":43,"name":"instanceChanged","kind":4096,"kindString":"Call signature","flags":{},"comment":{"shortText":"Handle the repeat's collection instance changing."},"parameters":[{"id":44,"name":"repeat","kind":32768,"kindString":"Parameter","flags":{},"comment":{"text":"The repeater instance."},"type":{"type":"reference","name":"VirtualRepeat","id":176}},{"id":45,"name":"items","kind":32768,"kindString":"Parameter","flags":{},"comment":{"text":"The new array instance.\n"},"type":{"type":"reference","name":"Array","typeArguments":[{"type":"instrinct","name":"any"}]}}],"type":{"type":"instrinct","name":"void"},"overwrites":{"type":"reference","name":"ArrayRepeatStrategy.instanceChanged"}}],"overwrites":{"type":"reference","name":"ArrayRepeatStrategy.instanceChanged"}},{"id":54,"name":"instanceMutated","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":55,"name":"instanceMutated","kind":4096,"kindString":"Call signature","flags":{},"comment":{"shortText":"Handle the repeat's collection instance mutating."},"parameters":[{"id":56,"name":"repeat","kind":32768,"kindString":"Parameter","flags":{},"comment":{"text":"The repeat instance."},"type":{"type":"reference","name":"VirtualRepeat","id":176}},{"id":57,"name":"array","kind":32768,"kindString":"Parameter","flags":{},"comment":{"text":"The modified array."},"type":{"type":"reference","name":"Array","typeArguments":[{"type":"instrinct","name":"any"}]}},{"id":58,"name":"splices","kind":32768,"kindString":"Parameter","flags":{},"comment":{"text":"Records of array changes.\n"},"type":{"type":"instrinct","name":"any"}}],"type":{"type":"instrinct","name":"void"},"overwrites":{"type":"reference","name":"ArrayRepeatStrategy.instanceMutated"}}],"overwrites":{"type":"reference","name":"ArrayRepeatStrategy.instanceMutated"}}],"groups":[{"title":"Methods","kind":2048,"children":[86,91,50,81,76,69,64,46,59,39,96,42,54]}],"extendedTypes":[{"type":"reference","name":"ArrayRepeatStrategy"}]},{"id":134,"name":"DefaultViewStrategy","kind":128,"kindString":"Class","flags":{"isExported":true},"children":[{"id":149,"name":"createBottomBufferElement","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":150,"name":"createBottomBufferElement","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":151,"name":"element","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}}],"type":{"type":"reference","name":"Element"}}]},{"id":146,"name":"createTopBufferElement","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":147,"name":"createTopBufferElement","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":148,"name":"element","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}}],"type":{"type":"reference","name":"Element"}}]},{"id":157,"name":"getFirstElement","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":158,"name":"getFirstElement","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":159,"name":"topBuffer","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}}],"type":{"type":"reference","name":"Element"}}]},{"id":160,"name":"getLastElement","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":161,"name":"getLastElement","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":162,"name":"bottomBuffer","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}}],"type":{"type":"reference","name":"Element"}}]},{"id":135,"name":"getScrollContainer","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":136,"name":"getScrollContainer","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":137,"name":"element","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}}],"type":{"type":"reference","name":"Element"}}]},{"id":138,"name":"moveViewFirst","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":139,"name":"moveViewFirst","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":140,"name":"view","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"View"}},{"id":141,"name":"topBuffer","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}}],"type":{"type":"instrinct","name":"void"}}]},{"id":142,"name":"moveViewLast","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":143,"name":"moveViewLast","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":144,"name":"view","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"View"}},{"id":145,"name":"bottomBuffer","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}}],"type":{"type":"instrinct","name":"void"}}]},{"id":152,"name":"removeBufferElements","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":153,"name":"removeBufferElements","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":154,"name":"element","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}},{"id":155,"name":"topBuffer","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}},{"id":156,"name":"bottomBuffer","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}}],"type":{"type":"instrinct","name":"void"}}]}],"groups":[{"title":"Methods","kind":2048,"children":[149,146,157,160,135,138,142,152]}]},{"id":31,"name":"DomHelper","kind":128,"kindString":"Class","flags":{"isExported":true},"children":[{"id":32,"name":"getElementDistanceToTopOfDocument","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":33,"name":"getElementDistanceToTopOfDocument","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":34,"name":"element","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}}],"type":{"type":"instrinct","name":"number"}}]},{"id":35,"name":"hasOverflowScroll","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":36,"name":"hasOverflowScroll","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":37,"name":"element","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}}],"type":{"type":"instrinct","name":"boolean"}}]}],"groups":[{"title":"Methods","kind":2048,"children":[32,35]}]},{"id":104,"name":"TableStrategy","kind":128,"kindString":"Class","flags":{"isExported":true},"children":[{"id":105,"name":"tableCssReset","kind":1024,"kindString":"Property","flags":{"isExported":true},"type":{"type":"instrinct","name":"any"}},{"id":120,"name":"createBottomBufferElement","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":121,"name":"createBottomBufferElement","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":122,"name":"element","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}}],"type":{"type":"reference","name":"Element"}}]},{"id":117,"name":"createTopBufferElement","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":118,"name":"createTopBufferElement","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":119,"name":"element","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}}],"type":{"type":"reference","name":"Element"}}]},{"id":128,"name":"getFirstElement","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":129,"name":"getFirstElement","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":130,"name":"topBuffer","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}}],"type":{"type":"reference","name":"Element"}}]},{"id":131,"name":"getLastElement","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":132,"name":"getLastElement","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":133,"name":"bottomBuffer","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}}],"type":{"type":"reference","name":"Element"}}]},{"id":106,"name":"getScrollContainer","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":107,"name":"getScrollContainer","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":108,"name":"element","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}}],"type":{"type":"reference","name":"Element"}}]},{"id":109,"name":"moveViewFirst","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":110,"name":"moveViewFirst","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":111,"name":"view","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"View"}},{"id":112,"name":"topBuffer","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}}],"type":{"type":"instrinct","name":"void"}}]},{"id":113,"name":"moveViewLast","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":114,"name":"moveViewLast","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":115,"name":"view","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"View"}},{"id":116,"name":"bottomBuffer","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}}],"type":{"type":"instrinct","name":"void"}}]},{"id":123,"name":"removeBufferElements","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":124,"name":"removeBufferElements","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":125,"name":"element","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}},{"id":126,"name":"topBuffer","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}},{"id":127,"name":"bottomBuffer","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}}],"type":{"type":"instrinct","name":"void"}}]}],"groups":[{"title":"Properties","kind":1024,"children":[105]},{"title":"Methods","kind":2048,"children":[120,117,128,131,106,109,113,123]}]},{"id":100,"name":"ViewStrategyLocator","kind":128,"kindString":"Class","flags":{"isExported":true},"children":[{"id":101,"name":"getStrategy","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":102,"name":"getStrategy","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":103,"name":"element","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}}],"type":{"type":"reference","name":"ViewStrategy","id":2}}]}],"groups":[{"title":"Methods","kind":2048,"children":[101]}]},{"id":176,"name":"VirtualRepeat","kind":128,"kindString":"Class","flags":{"isExported":true},"children":[{"id":194,"name":"constructor","kind":512,"kindString":"Constructor","flags":{"isExported":true},"signatures":[{"id":195,"name":"new VirtualRepeat","kind":16384,"kindString":"Constructor signature","flags":{},"parameters":[{"id":196,"name":"element","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}},{"id":197,"name":"viewFactory","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"BoundViewFactory"}},{"id":198,"name":"instruction","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"TargetInstruction"}},{"id":199,"name":"viewSlot","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"ViewSlot"}},{"id":200,"name":"viewResources","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"ViewResources"}},{"id":201,"name":"observerLocator","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"ObserverLocator"}},{"id":202,"name":"strategyLocator","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"VirtualRepeatStrategyLocator","id":163}},{"id":203,"name":"viewStrategyLocator","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"ViewStrategyLocator","id":100}},{"id":204,"name":"domHelper","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"DomHelper","id":31}}],"type":{"type":"reference","name":"VirtualRepeat","id":176},"overwrites":{"type":"reference","name":"AbstractRepeater.__constructor"}}],"overwrites":{"type":"reference","name":"AbstractRepeater.__constructor"}},{"id":182,"name":"_bottomBufferHeight","kind":1024,"kindString":"Property","flags":{"isExported":true},"type":{"type":"instrinct","name":"any"}},{"id":183,"name":"_bufferSize","kind":1024,"kindString":"Property","flags":{"isExported":true},"type":{"type":"instrinct","name":"any"}},{"id":177,"name":"_first","kind":1024,"kindString":"Property","flags":{"isExported":true},"type":{"type":"instrinct","name":"any"}},{"id":189,"name":"_fixedHeightContainer","kind":1024,"kindString":"Property","flags":{"isExported":true},"type":{"type":"instrinct","name":"any"}},{"id":190,"name":"_hasCalculatedSizes","kind":1024,"kindString":"Property","flags":{"isExported":true},"type":{"type":"instrinct","name":"any"}},{"id":191,"name":"_isAtTop","kind":1024,"kindString":"Property","flags":{"isExported":true},"type":{"type":"instrinct","name":"any"}},{"id":187,"name":"_isAttached","kind":1024,"kindString":"Property","flags":{"isExported":true},"type":{"type":"instrinct","name":"any"}},{"id":180,"name":"_lastRebind","kind":1024,"kindString":"Property","flags":{"isExported":true},"type":{"type":"instrinct","name":"any"}},{"id":178,"name":"_previousFirst","kind":1024,"kindString":"Property","flags":{"isExported":true},"type":{"type":"instrinct","name":"any"}},{"id":184,"name":"_scrollingDown","kind":1024,"kindString":"Property","flags":{"isExported":true},"type":{"type":"instrinct","name":"any"}},{"id":185,"name":"_scrollingUp","kind":1024,"kindString":"Property","flags":{"isExported":true},"type":{"type":"instrinct","name":"any"}},{"id":186,"name":"_switchedDirection","kind":1024,"kindString":"Property","flags":{"isExported":true},"type":{"type":"instrinct","name":"any"}},{"id":188,"name":"_ticking","kind":1024,"kindString":"Property","flags":{"isExported":true},"type":{"type":"instrinct","name":"any"}},{"id":181,"name":"_topBufferHeight","kind":1024,"kindString":"Property","flags":{"isExported":true},"type":{"type":"instrinct","name":"any"}},{"id":179,"name":"_viewsLength","kind":1024,"kindString":"Property","flags":{"isExported":true},"type":{"type":"instrinct","name":"any"}},{"id":192,"name":"items","kind":1024,"kindString":"Property","flags":{"isExported":true},"type":{"type":"instrinct","name":"any"}},{"id":193,"name":"local","kind":1024,"kindString":"Property","flags":{"isExported":true},"type":{"type":"instrinct","name":"any"}},{"id":235,"name":"_adjustBufferHeights","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":236,"name":"_adjustBufferHeights","kind":4096,"kindString":"Call signature","flags":{},"type":{"type":"instrinct","name":"void"}}]},{"id":248,"name":"_calcInitialHeights","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":249,"name":"_calcInitialHeights","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":250,"name":"itemsLength","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"instrinct","name":"number"}}],"type":{"type":"instrinct","name":"any"}}]},{"id":251,"name":"_calcScrollHeight","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":252,"name":"_calcScrollHeight","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":253,"name":"element","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}}],"type":{"type":"instrinct","name":"number"}}]},{"id":233,"name":"_checkScrolling","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":234,"name":"_checkScrolling","kind":4096,"kindString":"Call signature","flags":{},"type":{"type":"instrinct","name":"void"}}]},{"id":246,"name":"_getIndexOfFirstView","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":247,"name":"_getIndexOfFirstView","kind":4096,"kindString":"Call signature","flags":{},"type":{"type":"instrinct","name":"number"}}]},{"id":242,"name":"_getIndexOfLastView","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":243,"name":"_getIndexOfLastView","kind":4096,"kindString":"Call signature","flags":{},"type":{"type":"instrinct","name":"number"}}]},{"id":256,"name":"_getInnerCollection","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":257,"name":"_getInnerCollection","kind":4096,"kindString":"Call signature","flags":{},"type":{"type":"instrinct","name":"any"}}]},{"id":244,"name":"_getLastViewItem","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":245,"name":"_getLastViewItem","kind":4096,"kindString":"Call signature","flags":{},"type":{"type":"instrinct","name":"any"}}]},{"id":231,"name":"_handleScroll","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":232,"name":"_handleScroll","kind":4096,"kindString":"Call signature","flags":{},"type":{"type":"instrinct","name":"void"}}]},{"id":239,"name":"_moveViews","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":240,"name":"_moveViews","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":241,"name":"length","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"instrinct","name":"number"}}],"type":{"type":"instrinct","name":"number"}}]},{"id":258,"name":"_observeCollection","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":259,"name":"_observeCollection","kind":4096,"kindString":"Call signature","flags":{},"type":{"type":"instrinct","name":"void"}}]},{"id":254,"name":"_observeInnerCollection","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":255,"name":"_observeInnerCollection","kind":4096,"kindString":"Call signature","flags":{},"type":{"type":"instrinct","name":"boolean"}}]},{"id":229,"name":"_onScroll","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":230,"name":"_onScroll","kind":4096,"kindString":"Call signature","flags":{},"type":{"type":"instrinct","name":"void"}}]},{"id":237,"name":"_unsubscribeCollection","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":238,"name":"_unsubscribeCollection","kind":4096,"kindString":"Call signature","flags":{},"type":{"type":"instrinct","name":"void"}}]},{"id":267,"name":"addView","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":268,"name":"addView","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":269,"name":"bindingContext","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"instrinct","name":"any"}},{"id":270,"name":"overrideContext","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"instrinct","name":"any"}}],"type":{"type":"instrinct","name":"any"},"overwrites":{"type":"reference","name":"AbstractRepeater.addView"}}],"overwrites":{"type":"reference","name":"AbstractRepeater.addView"}},{"id":205,"name":"attached","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":206,"name":"attached","kind":4096,"kindString":"Call signature","flags":{},"type":{"type":"instrinct","name":"void"}}]},{"id":207,"name":"bind","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":208,"name":"bind","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":209,"name":"bindingContext","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"instrinct","name":"any"}},{"id":210,"name":"overrideContext","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"instrinct","name":"any"}}],"type":{"type":"instrinct","name":"void"}}]},{"id":211,"name":"call","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":212,"name":"call","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":213,"name":"context","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"instrinct","name":"any"}},{"id":214,"name":"changes","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"instrinct","name":"any"}}],"type":{"type":"instrinct","name":"void"}}]},{"id":215,"name":"detached","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":216,"name":"detached","kind":4096,"kindString":"Call signature","flags":{},"type":{"type":"instrinct","name":"void"}}]},{"id":221,"name":"handleCollectionMutated","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":222,"name":"handleCollectionMutated","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":223,"name":"collection","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"instrinct","name":"any"}},{"id":224,"name":"changes","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"instrinct","name":"any"}}],"type":{"type":"instrinct","name":"void"}}]},{"id":225,"name":"handleInnerCollectionMutated","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":226,"name":"handleInnerCollectionMutated","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":227,"name":"collection","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"instrinct","name":"any"}},{"id":228,"name":"changes","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"instrinct","name":"any"}}],"type":{"type":"instrinct","name":"void"}}]},{"id":271,"name":"insertView","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":272,"name":"insertView","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":273,"name":"index","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"instrinct","name":"any"}},{"id":274,"name":"bindingContext","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"instrinct","name":"any"}},{"id":275,"name":"overrideContext","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"instrinct","name":"any"}}],"type":{"type":"instrinct","name":"any"},"overwrites":{"type":"reference","name":"AbstractRepeater.insertView"}}],"overwrites":{"type":"reference","name":"AbstractRepeater.insertView"}},{"id":217,"name":"itemsChanged","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":218,"name":"itemsChanged","kind":4096,"kindString":"Call signature","flags":{},"type":{"type":"instrinct","name":"void"}}]},{"id":288,"name":"matcher","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":289,"name":"matcher","kind":4096,"kindString":"Call signature","flags":{},"comment":{"shortText":"Returns the matcher function to be used by the repeater, or null if strict matching is to be performed.","returns":"The requested matcher function.\n"},"type":{"type":"instrinct","name":"any"},"inheritedFrom":{"type":"reference","name":"AbstractRepeater.matcher"}}],"inheritedFrom":{"type":"reference","name":"AbstractRepeater.matcher"}},{"id":290,"name":"moveView","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":291,"name":"moveView","kind":4096,"kindString":"Call signature","flags":{},"comment":{"shortText":"Moves a view across the repeater."},"parameters":[{"id":292,"name":"sourceIndex","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"comment":{"shortText":"The index where the view should be placed at.\n"},"type":{"type":"instrinct","name":"any"}},{"id":293,"name":"targetIndex","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"instrinct","name":"any"}}],"type":{"type":"instrinct","name":"any"},"inheritedFrom":{"type":"reference","name":"AbstractRepeater.moveView"}}],"inheritedFrom":{"type":"reference","name":"AbstractRepeater.moveView"}},{"id":276,"name":"removeAllViews","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":277,"name":"removeAllViews","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":278,"name":"returnToCache","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"instrinct","name":"any"}},{"id":279,"name":"skipAnimation","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"instrinct","name":"any"}}],"type":{"type":"instrinct","name":"any"},"overwrites":{"type":"reference","name":"AbstractRepeater.removeAllViews"}}],"overwrites":{"type":"reference","name":"AbstractRepeater.removeAllViews"}},{"id":280,"name":"removeView","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":281,"name":"removeView","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":282,"name":"index","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"instrinct","name":"any"}},{"id":283,"name":"returnToCache","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"instrinct","name":"any"}},{"id":284,"name":"skipAnimation","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"instrinct","name":"any"}}],"type":{"type":"instrinct","name":"any"},"overwrites":{"type":"reference","name":"AbstractRepeater.removeView"}}],"overwrites":{"type":"reference","name":"AbstractRepeater.removeView"}},{"id":294,"name":"removeViews","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":295,"name":"removeViews","kind":4096,"kindString":"Call signature","flags":{},"comment":{"shortText":"Removes an array of Views from the repeater.","returns":"\n"},"parameters":[{"id":296,"name":"viewsToRemove","kind":32768,"kindString":"Parameter","flags":{},"comment":{"text":"The array of views to be removed."},"type":{"type":"reference","name":"Array","typeArguments":[{"type":"reference","name":"View"}]}},{"id":297,"name":"returnToCache","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"comment":{"text":"Should the view be returned to the view cache?"},"type":{"type":"instrinct","name":"boolean"}},{"id":298,"name":"skipAnimation","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"comment":{"text":"Should the removal animation be skipped?"},"type":{"type":"instrinct","name":"boolean"}}],"type":{"type":"instrinct","name":"any"},"inheritedFrom":{"type":"reference","name":"AbstractRepeater.removeViews"}}],"inheritedFrom":{"type":"reference","name":"AbstractRepeater.removeViews"}},{"id":219,"name":"unbind","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":220,"name":"unbind","kind":4096,"kindString":"Call signature","flags":{},"type":{"type":"instrinct","name":"void"}}]},{"id":285,"name":"updateBindings","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":286,"name":"updateBindings","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":287,"name":"view","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"View"}}],"type":{"type":"instrinct","name":"any"},"overwrites":{"type":"reference","name":"AbstractRepeater.updateBindings"}}],"overwrites":{"type":"reference","name":"AbstractRepeater.updateBindings"}},{"id":264,"name":"view","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":265,"name":"view","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":266,"name":"index","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"instrinct","name":"any"}}],"type":{"type":"instrinct","name":"any"},"overwrites":{"type":"reference","name":"AbstractRepeater.view"}}],"overwrites":{"type":"reference","name":"AbstractRepeater.view"}},{"id":260,"name":"viewCount","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":261,"name":"viewCount","kind":4096,"kindString":"Call signature","flags":{},"type":{"type":"instrinct","name":"any"},"overwrites":{"type":"reference","name":"AbstractRepeater.viewCount"}}],"overwrites":{"type":"reference","name":"AbstractRepeater.viewCount"}},{"id":262,"name":"views","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":263,"name":"views","kind":4096,"kindString":"Call signature","flags":{},"type":{"type":"instrinct","name":"any"},"overwrites":{"type":"reference","name":"AbstractRepeater.views"}}],"overwrites":{"type":"reference","name":"AbstractRepeater.views"}}],"groups":[{"title":"Constructors","kind":512,"children":[194]},{"title":"Properties","kind":1024,"children":[182,183,177,189,190,191,187,180,178,184,185,186,188,181,179,192,193]},{"title":"Methods","kind":2048,"children":[235,248,251,233,246,242,256,244,231,239,258,254,229,237,267,205,207,211,215,221,225,271,217,288,290,276,280,294,219,285,264,260,262]}],"extendedTypes":[{"type":"reference","name":"AbstractRepeater"}]},{"id":163,"name":"VirtualRepeatStrategyLocator","kind":128,"kindString":"Class","flags":{"isExported":true},"children":[{"id":164,"name":"constructor","kind":512,"kindString":"Constructor","flags":{"isExported":true},"signatures":[{"id":165,"name":"new VirtualRepeatStrategyLocator","kind":16384,"kindString":"Constructor signature","flags":{},"type":{"type":"reference","name":"VirtualRepeatStrategyLocator","id":163},"overwrites":{"type":"reference","name":"RepeatStrategyLocator.__constructor"}}],"overwrites":{"type":"reference","name":"RepeatStrategyLocator.__constructor"}},{"id":166,"name":"addStrategy","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":167,"name":"addStrategy","kind":4096,"kindString":"Call signature","flags":{},"comment":{"shortText":"Adds a repeat strategy to be located when repeating a template over different collection types."},"parameters":[{"id":168,"name":"matcher","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reflection","declaration":{"id":169,"name":"__type","kind":65536,"kindString":"Type literal","flags":{},"signatures":[{"id":170,"name":"__call","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":171,"name":"items","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"instrinct","name":"any"}}],"type":{"type":"instrinct","name":"boolean"}}]}}},{"id":172,"name":"strategy","kind":32768,"kindString":"Parameter","flags":{},"comment":{"text":"A repeat strategy that can iterate a specific collection type.\n"},"type":{"type":"reference","name":"RepeatStrategy"}}],"type":{"type":"instrinct","name":"any"},"inheritedFrom":{"type":"reference","name":"RepeatStrategyLocator.addStrategy"}}],"inheritedFrom":{"type":"reference","name":"RepeatStrategyLocator.addStrategy"}},{"id":173,"name":"getStrategy","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":174,"name":"getStrategy","kind":4096,"kindString":"Call signature","flags":{},"comment":{"shortText":"Gets the best strategy to handle iteration."},"parameters":[{"id":175,"name":"items","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"instrinct","name":"any"}}],"type":{"type":"reference","name":"RepeatStrategy"},"inheritedFrom":{"type":"reference","name":"RepeatStrategyLocator.getStrategy"}}],"inheritedFrom":{"type":"reference","name":"RepeatStrategyLocator.getStrategy"}}],"groups":[{"title":"Constructors","kind":512,"children":[164]},{"title":"Methods","kind":2048,"children":[166,173]}],"extendedTypes":[{"type":"reference","name":"RepeatStrategyLocator"}]},{"id":2,"name":"ViewStrategy","kind":256,"kindString":"Interface","flags":{"isExported":true},"children":[{"id":17,"name":"createBottomBufferElement","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":18,"name":"createBottomBufferElement","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":19,"name":"element","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}}],"type":{"type":"reference","name":"Element"}}]},{"id":14,"name":"createTopBufferElement","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":15,"name":"createTopBufferElement","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":16,"name":"element","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}}],"type":{"type":"reference","name":"Element"}}]},{"id":25,"name":"getFirstElement","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":26,"name":"getFirstElement","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":27,"name":"topBuffer","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}}],"type":{"type":"reference","name":"Element"}}]},{"id":28,"name":"getLastView","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":29,"name":"getLastView","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":30,"name":"bottomBuffer","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}}],"type":{"type":"reference","name":"Element"}}]},{"id":3,"name":"getScrollContainer","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":4,"name":"getScrollContainer","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":5,"name":"element","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}}],"type":{"type":"reference","name":"Element"}}]},{"id":6,"name":"moveViewFirst","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":7,"name":"moveViewFirst","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":8,"name":"view","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"View"}},{"id":9,"name":"topBuffer","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}}],"type":{"type":"instrinct","name":"void"}}]},{"id":10,"name":"moveViewLast","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":11,"name":"moveViewLast","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":12,"name":"view","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"View"}},{"id":13,"name":"bottomBuffer","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}}],"type":{"type":"instrinct","name":"void"}}]},{"id":20,"name":"removeBufferElements","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":21,"name":"removeBufferElements","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":22,"name":"element","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}},{"id":23,"name":"topBuffer","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}},{"id":24,"name":"bottomBuffer","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}}],"type":{"type":"instrinct","name":"void"}}]}],"groups":[{"title":"Methods","kind":2048,"children":[17,14,25,28,3,6,10,20]}]},{"id":299,"name":"calcOuterHeight","kind":64,"kindString":"Function","flags":{"isExported":true},"signatures":[{"id":300,"name":"calcOuterHeight","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":301,"name":"element","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}}],"type":{"type":"instrinct","name":"number"}}]},{"id":320,"name":"getElementDistanceToBottomViewPort","kind":64,"kindString":"Function","flags":{"isExported":true},"signatures":[{"id":321,"name":"getElementDistanceToBottomViewPort","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":322,"name":"element","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}}],"type":{"type":"instrinct","name":"number"}}]},{"id":323,"name":"getElementDistanceToTopViewPort","kind":64,"kindString":"Function","flags":{"isExported":true},"signatures":[{"id":324,"name":"getElementDistanceToTopViewPort","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":325,"name":"element","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}}],"type":{"type":"instrinct","name":"number"}}]},{"id":316,"name":"getStyleValue","kind":64,"kindString":"Function","flags":{"isExported":true},"signatures":[{"id":317,"name":"getStyleValue","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":318,"name":"element","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}},{"id":319,"name":"style","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"instrinct","name":"string"}}],"type":{"type":"instrinct","name":"any"}}]},{"id":302,"name":"insertBeforeNode","kind":64,"kindString":"Function","flags":{"isExported":true},"signatures":[{"id":303,"name":"insertBeforeNode","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":304,"name":"view","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"View"}},{"id":305,"name":"bottomBuffer","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"instrinct","name":"number"}}],"type":{"type":"instrinct","name":"void"}}]},{"id":310,"name":"rebindAndMoveView","kind":64,"kindString":"Function","flags":{"isExported":true},"signatures":[{"id":311,"name":"rebindAndMoveView","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":312,"name":"repeat","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"VirtualRepeat","id":176}},{"id":313,"name":"view","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"View"}},{"id":314,"name":"index","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"instrinct","name":"number"}},{"id":315,"name":"moveToBottom","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"instrinct","name":"boolean"}}],"type":{"type":"instrinct","name":"void"}}]},{"id":306,"name":"updateVirtualOverrideContexts","kind":64,"kindString":"Function","flags":{"isExported":true},"signatures":[{"id":307,"name":"updateVirtualOverrideContexts","kind":4096,"kindString":"Call signature","flags":{},"comment":{"shortText":"Update the override context."},"parameters":[{"id":308,"name":"repeat","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"VirtualRepeat","id":176}},{"id":309,"name":"startIndex","kind":32768,"kindString":"Parameter","flags":{},"comment":{"text":"index in collection where to start updating.\n"},"type":{"type":"instrinct","name":"number"}}],"type":{"type":"instrinct","name":"void"}}]}],"groups":[{"title":"Classes","kind":128,"children":[38,134,31,104,100,176,163]},{"title":"Interfaces","kind":256,"children":[2]},{"title":"Functions","kind":64,"children":[299,320,323,316,302,310,306]}]} \ No newline at end of file +{"name":"aurelia-ui-virtualization","children":[{"id":38,"name":"ArrayVirtualRepeatStrategy","kind":128,"kindString":"Class","flags":{"isExported":true},"comment":{"shortText":"A strategy for repeating a template over an array."},"children":[{"id":39,"name":"createFirstItem","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":40,"name":"createFirstItem","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":41,"name":"repeat","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"VirtualRepeat","id":131}}],"type":{"type":"instrinct","name":"void"}}]},{"id":51,"name":"getCollectionObserver","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":52,"name":"getCollectionObserver","kind":4096,"kindString":"Call signature","flags":{},"comment":{"shortText":"Gets an observer for the specified collection."},"parameters":[{"id":53,"name":"observerLocator","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"comment":{"text":"The observer locator instance."},"type":{"type":"instrinct","name":"any"}},{"id":54,"name":"items","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"comment":{"text":"The items to be observed.\n"},"type":{"type":"instrinct","name":"any"}}],"type":{"type":"instrinct","name":"any"},"inheritedFrom":{"type":"reference","name":"ArrayRepeatStrategy.getCollectionObserver"}}],"inheritedFrom":{"type":"reference","name":"ArrayRepeatStrategy.getCollectionObserver"}},{"id":42,"name":"instanceChanged","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":43,"name":"instanceChanged","kind":4096,"kindString":"Call signature","flags":{},"comment":{"shortText":"Handle the repeat's collection instance changing."},"parameters":[{"id":44,"name":"repeat","kind":32768,"kindString":"Parameter","flags":{},"comment":{"text":"The repeater instance."},"type":{"type":"reference","name":"VirtualRepeat","id":131}},{"id":45,"name":"items","kind":32768,"kindString":"Parameter","flags":{},"comment":{"text":"The new array instance.\n"},"type":{"type":"reference","name":"Array","typeArguments":[{"type":"instrinct","name":"any"}]}}],"type":{"type":"instrinct","name":"void"},"overwrites":{"type":"reference","name":"ArrayRepeatStrategy.instanceChanged"}}],"overwrites":{"type":"reference","name":"ArrayRepeatStrategy.instanceChanged"}},{"id":46,"name":"instanceMutated","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":47,"name":"instanceMutated","kind":4096,"kindString":"Call signature","flags":{},"comment":{"shortText":"Handle the repeat's collection instance mutating."},"parameters":[{"id":48,"name":"repeat","kind":32768,"kindString":"Parameter","flags":{},"comment":{"text":"The repeat instance."},"type":{"type":"reference","name":"VirtualRepeat","id":131}},{"id":49,"name":"array","kind":32768,"kindString":"Parameter","flags":{},"comment":{"text":"The modified array."},"type":{"type":"reference","name":"Array","typeArguments":[{"type":"instrinct","name":"any"}]}},{"id":50,"name":"splices","kind":32768,"kindString":"Parameter","flags":{},"comment":{"text":"Records of array changes.\n"},"type":{"type":"instrinct","name":"any"}}],"type":{"type":"instrinct","name":"void"},"overwrites":{"type":"reference","name":"ArrayRepeatStrategy.instanceMutated"}}],"overwrites":{"type":"reference","name":"ArrayRepeatStrategy.instanceMutated"}}],"groups":[{"title":"Methods","kind":2048,"children":[39,51,42,46]}],"extendedTypes":[{"type":"reference","name":"ArrayRepeatStrategy"}]},{"id":89,"name":"DefaultTemplateStrategy","kind":128,"kindString":"Class","flags":{"isExported":true},"children":[{"id":104,"name":"createBottomBufferElement","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":105,"name":"createBottomBufferElement","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":106,"name":"element","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}}],"type":{"type":"reference","name":"Element"}}]},{"id":101,"name":"createTopBufferElement","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":102,"name":"createTopBufferElement","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":103,"name":"element","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}}],"type":{"type":"reference","name":"Element"}}]},{"id":112,"name":"getFirstElement","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":113,"name":"getFirstElement","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":114,"name":"topBuffer","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}}],"type":{"type":"reference","name":"Element"}}]},{"id":115,"name":"getLastElement","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":116,"name":"getLastElement","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":117,"name":"bottomBuffer","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}}],"type":{"type":"reference","name":"Element"}}]},{"id":90,"name":"getScrollContainer","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":91,"name":"getScrollContainer","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":92,"name":"element","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}}],"type":{"type":"reference","name":"Element"}}]},{"id":93,"name":"moveViewFirst","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":94,"name":"moveViewFirst","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":95,"name":"view","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"View"}},{"id":96,"name":"topBuffer","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}}],"type":{"type":"instrinct","name":"void"}}]},{"id":97,"name":"moveViewLast","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":98,"name":"moveViewLast","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":99,"name":"view","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"View"}},{"id":100,"name":"bottomBuffer","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}}],"type":{"type":"instrinct","name":"void"}}]},{"id":107,"name":"removeBufferElements","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":108,"name":"removeBufferElements","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":109,"name":"element","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}},{"id":110,"name":"topBuffer","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}},{"id":111,"name":"bottomBuffer","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}}],"type":{"type":"instrinct","name":"void"}}]}],"groups":[{"title":"Methods","kind":2048,"children":[104,101,112,115,90,93,97,107]}]},{"id":31,"name":"DomHelper","kind":128,"kindString":"Class","flags":{"isExported":true},"children":[{"id":32,"name":"getElementDistanceToTopOfDocument","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":33,"name":"getElementDistanceToTopOfDocument","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":34,"name":"element","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}}],"type":{"type":"instrinct","name":"number"}}]},{"id":35,"name":"hasOverflowScroll","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":36,"name":"hasOverflowScroll","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":37,"name":"element","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}}],"type":{"type":"instrinct","name":"boolean"}}]}],"groups":[{"title":"Methods","kind":2048,"children":[32,35]}]},{"id":59,"name":"TableStrategy","kind":128,"kindString":"Class","flags":{"isExported":true},"children":[{"id":60,"name":"tableCssReset","kind":1024,"kindString":"Property","flags":{"isExported":true},"type":{"type":"instrinct","name":"any"}},{"id":75,"name":"createBottomBufferElement","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":76,"name":"createBottomBufferElement","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":77,"name":"element","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}}],"type":{"type":"reference","name":"Element"}}]},{"id":72,"name":"createTopBufferElement","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":73,"name":"createTopBufferElement","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":74,"name":"element","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}}],"type":{"type":"reference","name":"Element"}}]},{"id":83,"name":"getFirstElement","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":84,"name":"getFirstElement","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":85,"name":"topBuffer","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}}],"type":{"type":"reference","name":"Element"}}]},{"id":86,"name":"getLastElement","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":87,"name":"getLastElement","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":88,"name":"bottomBuffer","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}}],"type":{"type":"reference","name":"Element"}}]},{"id":61,"name":"getScrollContainer","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":62,"name":"getScrollContainer","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":63,"name":"element","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}}],"type":{"type":"reference","name":"Element"}}]},{"id":64,"name":"moveViewFirst","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":65,"name":"moveViewFirst","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":66,"name":"view","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"View"}},{"id":67,"name":"topBuffer","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}}],"type":{"type":"instrinct","name":"void"}}]},{"id":68,"name":"moveViewLast","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":69,"name":"moveViewLast","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":70,"name":"view","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"View"}},{"id":71,"name":"bottomBuffer","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}}],"type":{"type":"instrinct","name":"void"}}]},{"id":78,"name":"removeBufferElements","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":79,"name":"removeBufferElements","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":80,"name":"element","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}},{"id":81,"name":"topBuffer","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}},{"id":82,"name":"bottomBuffer","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}}],"type":{"type":"instrinct","name":"void"}}]}],"groups":[{"title":"Properties","kind":1024,"children":[60]},{"title":"Methods","kind":2048,"children":[75,72,83,86,61,64,68,78]}]},{"id":55,"name":"TemplateStrategyLocator","kind":128,"kindString":"Class","flags":{"isExported":true},"children":[{"id":56,"name":"getStrategy","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":57,"name":"getStrategy","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":58,"name":"element","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}}],"type":{"type":"reference","name":"TemplateStrategy","id":2}}]}],"groups":[{"title":"Methods","kind":2048,"children":[56]}]},{"id":131,"name":"VirtualRepeat","kind":128,"kindString":"Class","flags":{"isExported":true},"children":[{"id":134,"name":"constructor","kind":512,"kindString":"Constructor","flags":{"isExported":true},"signatures":[{"id":135,"name":"new VirtualRepeat","kind":16384,"kindString":"Constructor signature","flags":{},"parameters":[{"id":136,"name":"element","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}},{"id":137,"name":"viewFactory","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"BoundViewFactory"}},{"id":138,"name":"instruction","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"TargetInstruction"}},{"id":139,"name":"viewSlot","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"ViewSlot"}},{"id":140,"name":"viewResources","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"ViewResources"}},{"id":141,"name":"observerLocator","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"ObserverLocator"}},{"id":142,"name":"strategyLocator","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"VirtualRepeatStrategyLocator","id":118}},{"id":143,"name":"templateStrategyLocator","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"TemplateStrategyLocator","id":55}},{"id":144,"name":"domHelper","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"DomHelper","id":31}}],"type":{"type":"reference","name":"VirtualRepeat","id":131},"overwrites":{"type":"reference","name":"AbstractRepeater.__constructor"}}],"overwrites":{"type":"reference","name":"AbstractRepeater.__constructor"}},{"id":132,"name":"items","kind":1024,"kindString":"Property","flags":{"isExported":true},"type":{"type":"instrinct","name":"any"}},{"id":133,"name":"local","kind":1024,"kindString":"Property","flags":{"isExported":true},"type":{"type":"instrinct","name":"any"}},{"id":176,"name":"addView","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":177,"name":"addView","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":178,"name":"bindingContext","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"instrinct","name":"any"}},{"id":179,"name":"overrideContext","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"instrinct","name":"any"}}],"type":{"type":"instrinct","name":"any"},"overwrites":{"type":"reference","name":"AbstractRepeater.addView"}}],"overwrites":{"type":"reference","name":"AbstractRepeater.addView"}},{"id":145,"name":"attached","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":146,"name":"attached","kind":4096,"kindString":"Call signature","flags":{},"type":{"type":"instrinct","name":"void"}}]},{"id":147,"name":"bind","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":148,"name":"bind","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":149,"name":"bindingContext","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"instrinct","name":"any"}},{"id":150,"name":"overrideContext","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"instrinct","name":"any"}}],"type":{"type":"instrinct","name":"void"}}]},{"id":151,"name":"call","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":152,"name":"call","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":153,"name":"context","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"instrinct","name":"any"}},{"id":154,"name":"changes","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"instrinct","name":"any"}}],"type":{"type":"instrinct","name":"void"}}]},{"id":155,"name":"detached","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":156,"name":"detached","kind":4096,"kindString":"Call signature","flags":{},"type":{"type":"instrinct","name":"void"}}]},{"id":161,"name":"handleCollectionMutated","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":162,"name":"handleCollectionMutated","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":163,"name":"collection","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"instrinct","name":"any"}},{"id":164,"name":"changes","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"instrinct","name":"any"}}],"type":{"type":"instrinct","name":"void"}}]},{"id":165,"name":"handleInnerCollectionMutated","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":166,"name":"handleInnerCollectionMutated","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":167,"name":"collection","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"instrinct","name":"any"}},{"id":168,"name":"changes","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"instrinct","name":"any"}}],"type":{"type":"instrinct","name":"void"}}]},{"id":180,"name":"insertView","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":181,"name":"insertView","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":182,"name":"index","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"instrinct","name":"any"}},{"id":183,"name":"bindingContext","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"instrinct","name":"any"}},{"id":184,"name":"overrideContext","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"instrinct","name":"any"}}],"type":{"type":"instrinct","name":"any"},"overwrites":{"type":"reference","name":"AbstractRepeater.insertView"}}],"overwrites":{"type":"reference","name":"AbstractRepeater.insertView"}},{"id":157,"name":"itemsChanged","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":158,"name":"itemsChanged","kind":4096,"kindString":"Call signature","flags":{},"type":{"type":"instrinct","name":"void"}}]},{"id":197,"name":"matcher","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":198,"name":"matcher","kind":4096,"kindString":"Call signature","flags":{},"comment":{"shortText":"Returns the matcher function to be used by the repeater, or null if strict matching is to be performed.","returns":"The requested matcher function.\n"},"type":{"type":"instrinct","name":"any"},"inheritedFrom":{"type":"reference","name":"AbstractRepeater.matcher"}}],"inheritedFrom":{"type":"reference","name":"AbstractRepeater.matcher"}},{"id":199,"name":"moveView","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":200,"name":"moveView","kind":4096,"kindString":"Call signature","flags":{},"comment":{"shortText":"Moves a view across the repeater."},"parameters":[{"id":201,"name":"sourceIndex","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"comment":{"shortText":"The index where the view should be placed at.\n"},"type":{"type":"instrinct","name":"any"}},{"id":202,"name":"targetIndex","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"instrinct","name":"any"}}],"type":{"type":"instrinct","name":"any"},"inheritedFrom":{"type":"reference","name":"AbstractRepeater.moveView"}}],"inheritedFrom":{"type":"reference","name":"AbstractRepeater.moveView"}},{"id":185,"name":"removeAllViews","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":186,"name":"removeAllViews","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":187,"name":"returnToCache","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"instrinct","name":"any"}},{"id":188,"name":"skipAnimation","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"instrinct","name":"any"}}],"type":{"type":"instrinct","name":"any"},"overwrites":{"type":"reference","name":"AbstractRepeater.removeAllViews"}}],"overwrites":{"type":"reference","name":"AbstractRepeater.removeAllViews"}},{"id":189,"name":"removeView","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":190,"name":"removeView","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":191,"name":"index","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"instrinct","name":"any"}},{"id":192,"name":"returnToCache","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"instrinct","name":"any"}},{"id":193,"name":"skipAnimation","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"instrinct","name":"any"}}],"type":{"type":"instrinct","name":"any"},"overwrites":{"type":"reference","name":"AbstractRepeater.removeView"}}],"overwrites":{"type":"reference","name":"AbstractRepeater.removeView"}},{"id":203,"name":"removeViews","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":204,"name":"removeViews","kind":4096,"kindString":"Call signature","flags":{},"comment":{"shortText":"Removes an array of Views from the repeater.","returns":"\n"},"parameters":[{"id":205,"name":"viewsToRemove","kind":32768,"kindString":"Parameter","flags":{},"comment":{"text":"The array of views to be removed."},"type":{"type":"reference","name":"Array","typeArguments":[{"type":"reference","name":"View"}]}},{"id":206,"name":"returnToCache","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"comment":{"text":"Should the view be returned to the view cache?"},"type":{"type":"instrinct","name":"boolean"}},{"id":207,"name":"skipAnimation","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"comment":{"text":"Should the removal animation be skipped?"},"type":{"type":"instrinct","name":"boolean"}}],"type":{"type":"instrinct","name":"any"},"inheritedFrom":{"type":"reference","name":"AbstractRepeater.removeViews"}}],"inheritedFrom":{"type":"reference","name":"AbstractRepeater.removeViews"}},{"id":159,"name":"unbind","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":160,"name":"unbind","kind":4096,"kindString":"Call signature","flags":{},"type":{"type":"instrinct","name":"void"}}]},{"id":194,"name":"updateBindings","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":195,"name":"updateBindings","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":196,"name":"view","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"View"}}],"type":{"type":"instrinct","name":"any"},"overwrites":{"type":"reference","name":"AbstractRepeater.updateBindings"}}],"overwrites":{"type":"reference","name":"AbstractRepeater.updateBindings"}},{"id":173,"name":"view","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":174,"name":"view","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":175,"name":"index","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"instrinct","name":"any"}}],"type":{"type":"instrinct","name":"any"},"overwrites":{"type":"reference","name":"AbstractRepeater.view"}}],"overwrites":{"type":"reference","name":"AbstractRepeater.view"}},{"id":169,"name":"viewCount","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":170,"name":"viewCount","kind":4096,"kindString":"Call signature","flags":{},"type":{"type":"instrinct","name":"any"},"overwrites":{"type":"reference","name":"AbstractRepeater.viewCount"}}],"overwrites":{"type":"reference","name":"AbstractRepeater.viewCount"}},{"id":171,"name":"views","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":172,"name":"views","kind":4096,"kindString":"Call signature","flags":{},"type":{"type":"instrinct","name":"any"},"overwrites":{"type":"reference","name":"AbstractRepeater.views"}}],"overwrites":{"type":"reference","name":"AbstractRepeater.views"}}],"groups":[{"title":"Constructors","kind":512,"children":[134]},{"title":"Properties","kind":1024,"children":[132,133]},{"title":"Methods","kind":2048,"children":[176,145,147,151,155,161,165,180,157,197,199,185,189,203,159,194,173,169,171]}],"extendedTypes":[{"type":"reference","name":"AbstractRepeater"}]},{"id":118,"name":"VirtualRepeatStrategyLocator","kind":128,"kindString":"Class","flags":{"isExported":true},"children":[{"id":119,"name":"constructor","kind":512,"kindString":"Constructor","flags":{"isExported":true},"signatures":[{"id":120,"name":"new VirtualRepeatStrategyLocator","kind":16384,"kindString":"Constructor signature","flags":{},"type":{"type":"reference","name":"VirtualRepeatStrategyLocator","id":118},"overwrites":{"type":"reference","name":"RepeatStrategyLocator.__constructor"}}],"overwrites":{"type":"reference","name":"RepeatStrategyLocator.__constructor"}},{"id":121,"name":"addStrategy","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":122,"name":"addStrategy","kind":4096,"kindString":"Call signature","flags":{},"comment":{"shortText":"Adds a repeat strategy to be located when repeating a template over different collection types."},"parameters":[{"id":123,"name":"matcher","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reflection","declaration":{"id":124,"name":"__type","kind":65536,"kindString":"Type literal","flags":{},"signatures":[{"id":125,"name":"__call","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":126,"name":"items","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"instrinct","name":"any"}}],"type":{"type":"instrinct","name":"boolean"}}]}}},{"id":127,"name":"strategy","kind":32768,"kindString":"Parameter","flags":{},"comment":{"text":"A repeat strategy that can iterate a specific collection type.\n"},"type":{"type":"reference","name":"RepeatStrategy"}}],"type":{"type":"instrinct","name":"any"},"inheritedFrom":{"type":"reference","name":"RepeatStrategyLocator.addStrategy"}}],"inheritedFrom":{"type":"reference","name":"RepeatStrategyLocator.addStrategy"}},{"id":128,"name":"getStrategy","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":129,"name":"getStrategy","kind":4096,"kindString":"Call signature","flags":{},"comment":{"shortText":"Gets the best strategy to handle iteration."},"parameters":[{"id":130,"name":"items","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"instrinct","name":"any"}}],"type":{"type":"reference","name":"RepeatStrategy"},"inheritedFrom":{"type":"reference","name":"RepeatStrategyLocator.getStrategy"}}],"inheritedFrom":{"type":"reference","name":"RepeatStrategyLocator.getStrategy"}}],"groups":[{"title":"Constructors","kind":512,"children":[119]},{"title":"Methods","kind":2048,"children":[121,128]}],"extendedTypes":[{"type":"reference","name":"RepeatStrategyLocator"}]},{"id":2,"name":"TemplateStrategy","kind":256,"kindString":"Interface","flags":{"isExported":true},"children":[{"id":17,"name":"createBottomBufferElement","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":18,"name":"createBottomBufferElement","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":19,"name":"element","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}}],"type":{"type":"reference","name":"Element"}}]},{"id":14,"name":"createTopBufferElement","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":15,"name":"createTopBufferElement","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":16,"name":"element","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}}],"type":{"type":"reference","name":"Element"}}]},{"id":25,"name":"getFirstElement","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":26,"name":"getFirstElement","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":27,"name":"topBuffer","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}}],"type":{"type":"reference","name":"Element"}}]},{"id":28,"name":"getLastView","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":29,"name":"getLastView","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":30,"name":"bottomBuffer","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}}],"type":{"type":"reference","name":"Element"}}]},{"id":3,"name":"getScrollContainer","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":4,"name":"getScrollContainer","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":5,"name":"element","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}}],"type":{"type":"reference","name":"Element"}}]},{"id":6,"name":"moveViewFirst","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":7,"name":"moveViewFirst","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":8,"name":"view","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"View"}},{"id":9,"name":"topBuffer","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}}],"type":{"type":"instrinct","name":"void"}}]},{"id":10,"name":"moveViewLast","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":11,"name":"moveViewLast","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":12,"name":"view","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"View"}},{"id":13,"name":"bottomBuffer","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}}],"type":{"type":"instrinct","name":"void"}}]},{"id":20,"name":"removeBufferElements","kind":2048,"kindString":"Method","flags":{"isExported":true},"signatures":[{"id":21,"name":"removeBufferElements","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":22,"name":"element","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}},{"id":23,"name":"topBuffer","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}},{"id":24,"name":"bottomBuffer","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}}],"type":{"type":"instrinct","name":"void"}}]}],"groups":[{"title":"Methods","kind":2048,"children":[17,14,25,28,3,6,10,20]}]},{"id":208,"name":"calcOuterHeight","kind":64,"kindString":"Function","flags":{"isExported":true},"signatures":[{"id":209,"name":"calcOuterHeight","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":210,"name":"element","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}}],"type":{"type":"instrinct","name":"number"}}]},{"id":229,"name":"getElementDistanceToBottomViewPort","kind":64,"kindString":"Function","flags":{"isExported":true},"signatures":[{"id":230,"name":"getElementDistanceToBottomViewPort","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":231,"name":"element","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}}],"type":{"type":"instrinct","name":"number"}}]},{"id":232,"name":"getElementDistanceToTopViewPort","kind":64,"kindString":"Function","flags":{"isExported":true},"signatures":[{"id":233,"name":"getElementDistanceToTopViewPort","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":234,"name":"element","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}}],"type":{"type":"instrinct","name":"number"}}]},{"id":225,"name":"getStyleValue","kind":64,"kindString":"Function","flags":{"isExported":true},"signatures":[{"id":226,"name":"getStyleValue","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":227,"name":"element","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"Element"}},{"id":228,"name":"style","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"instrinct","name":"string"}}],"type":{"type":"instrinct","name":"any"}}]},{"id":211,"name":"insertBeforeNode","kind":64,"kindString":"Function","flags":{"isExported":true},"signatures":[{"id":212,"name":"insertBeforeNode","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":213,"name":"view","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"View"}},{"id":214,"name":"bottomBuffer","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"instrinct","name":"number"}}],"type":{"type":"instrinct","name":"void"}}]},{"id":219,"name":"rebindAndMoveView","kind":64,"kindString":"Function","flags":{"isExported":true},"signatures":[{"id":220,"name":"rebindAndMoveView","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":221,"name":"repeat","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"VirtualRepeat","id":131}},{"id":222,"name":"view","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"View"}},{"id":223,"name":"index","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"instrinct","name":"number"}},{"id":224,"name":"moveToBottom","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"instrinct","name":"boolean"}}],"type":{"type":"instrinct","name":"void"}}]},{"id":215,"name":"updateVirtualOverrideContexts","kind":64,"kindString":"Function","flags":{"isExported":true},"signatures":[{"id":216,"name":"updateVirtualOverrideContexts","kind":4096,"kindString":"Call signature","flags":{},"comment":{"shortText":"Update the override context."},"parameters":[{"id":217,"name":"repeat","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","name":"VirtualRepeat","id":131}},{"id":218,"name":"startIndex","kind":32768,"kindString":"Parameter","flags":{},"comment":{"text":"index in collection where to start updating.\n"},"type":{"type":"instrinct","name":"number"}}],"type":{"type":"instrinct","name":"void"}}]}],"groups":[{"title":"Classes","kind":128,"children":[38,89,31,59,55,131,118]},{"title":"Interfaces","kind":256,"children":[2]},{"title":"Functions","kind":64,"children":[208,229,232,225,211,219,215]}]} \ No newline at end of file