@angular/cdk 11.0.0-rc.4 → 11.0.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (82) hide show
  1. package/a11y/focus-trap/focus-trap.d.ts +8 -8
  2. package/a11y/index.metadata.json +1 -1
  3. package/bundles/cdk-a11y.umd.js +18 -13
  4. package/bundles/cdk-a11y.umd.js.map +1 -1
  5. package/bundles/cdk-a11y.umd.min.js +7 -7
  6. package/bundles/cdk-a11y.umd.min.js.map +1 -1
  7. package/bundles/cdk-coercion.umd.js +5 -5
  8. package/bundles/cdk-coercion.umd.js.map +1 -1
  9. package/bundles/cdk-coercion.umd.min.js.map +1 -1
  10. package/bundles/cdk-collections.umd.js +5 -5
  11. package/bundles/cdk-collections.umd.js.map +1 -1
  12. package/bundles/cdk-collections.umd.min.js +1 -1
  13. package/bundles/cdk-collections.umd.min.js.map +1 -1
  14. package/bundles/cdk-drag-drop.umd.js +43 -11
  15. package/bundles/cdk-drag-drop.umd.js.map +1 -1
  16. package/bundles/cdk-drag-drop.umd.min.js +8 -8
  17. package/bundles/cdk-drag-drop.umd.min.js.map +1 -1
  18. package/bundles/cdk-observers.umd.js +3 -4
  19. package/bundles/cdk-observers.umd.js.map +1 -1
  20. package/bundles/cdk-observers.umd.min.js +1 -1
  21. package/bundles/cdk-observers.umd.min.js.map +1 -1
  22. package/bundles/cdk-overlay.umd.js +5 -5
  23. package/bundles/cdk-overlay.umd.js.map +1 -1
  24. package/bundles/cdk-overlay.umd.min.js +1 -1
  25. package/bundles/cdk-overlay.umd.min.js.map +1 -1
  26. package/bundles/cdk-portal.umd.js +5 -5
  27. package/bundles/cdk-portal.umd.js.map +1 -1
  28. package/bundles/cdk-portal.umd.min.js +1 -1
  29. package/bundles/cdk-portal.umd.min.js.map +1 -1
  30. package/bundles/cdk-scrolling.umd.js +5 -5
  31. package/bundles/cdk-scrolling.umd.js.map +1 -1
  32. package/bundles/cdk-scrolling.umd.min.js +2 -2
  33. package/bundles/cdk-scrolling.umd.min.js.map +1 -1
  34. package/bundles/cdk-table.umd.js +5 -5
  35. package/bundles/cdk-table.umd.js.map +1 -1
  36. package/bundles/cdk-table.umd.min.js +1 -1
  37. package/bundles/cdk-table.umd.min.js.map +1 -1
  38. package/bundles/cdk-testing-protractor.umd.js +5 -5
  39. package/bundles/cdk-testing-protractor.umd.js.map +1 -1
  40. package/bundles/cdk-testing-protractor.umd.min.js +1 -1
  41. package/bundles/cdk-testing-protractor.umd.min.js.map +1 -1
  42. package/bundles/cdk-testing-testbed.umd.js +5 -5
  43. package/bundles/cdk-testing-testbed.umd.js.map +1 -1
  44. package/bundles/cdk-testing-testbed.umd.min.js +1 -1
  45. package/bundles/cdk-testing-testbed.umd.min.js.map +1 -1
  46. package/bundles/cdk-testing.umd.js +5 -5
  47. package/bundles/cdk-testing.umd.js.map +1 -1
  48. package/bundles/cdk-testing.umd.min.js +1 -1
  49. package/bundles/cdk-testing.umd.min.js.map +1 -1
  50. package/bundles/cdk-tree.umd.js +5 -5
  51. package/bundles/cdk-tree.umd.js.map +1 -1
  52. package/bundles/cdk-tree.umd.min.js +2 -2
  53. package/bundles/cdk-tree.umd.min.js.map +1 -1
  54. package/bundles/cdk.umd.js +1 -1
  55. package/bundles/cdk.umd.js.map +1 -1
  56. package/bundles/cdk.umd.min.js +1 -1
  57. package/bundles/cdk.umd.min.js.map +1 -1
  58. package/drag-drop/drag-ref.d.ts +13 -0
  59. package/drag-drop/index.metadata.json +1 -1
  60. package/esm2015/a11y/focus-trap/focus-trap.js +14 -9
  61. package/esm2015/drag-drop/drag-ref.js +39 -8
  62. package/esm2015/observers/observe-content.js +3 -4
  63. package/esm2015/version.js +1 -1
  64. package/fesm2015/a11y.js +13 -8
  65. package/fesm2015/a11y.js.map +1 -1
  66. package/fesm2015/cdk.js +1 -1
  67. package/fesm2015/cdk.js.map +1 -1
  68. package/fesm2015/drag-drop.js +37 -6
  69. package/fesm2015/drag-drop.js.map +1 -1
  70. package/fesm2015/observers.js +2 -3
  71. package/fesm2015/observers.js.map +1 -1
  72. package/observers/index.metadata.json +1 -1
  73. package/observers/observe-content.d.ts +2 -2
  74. package/package.json +3 -3
  75. package/schematics/migration.json +5 -0
  76. package/schematics/ng-add/index.js +1 -1
  77. package/schematics/ng-update/devkit-file-system.d.ts +1 -0
  78. package/schematics/ng-update/devkit-file-system.js +20 -13
  79. package/schematics/ng-update/index.d.ts +2 -0
  80. package/schematics/ng-update/index.js +7 -2
  81. package/schematics/update-tool/target-version.d.ts +2 -1
  82. package/schematics/update-tool/target-version.js +2 -1
@@ -43,7 +43,7 @@ var f=function(){function t(t,e,r,i){var a=this;this.elementRef=t,this.scrollDis
43
43
  OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
44
44
  PERFORMANCE OF THIS SOFTWARE.
45
45
  ***************************************************************************** */
46
- var g=function(t,e){return(g=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var r in e)e.hasOwnProperty(r)&&(t[r]=e[r])})(t,e)},_=function(){function t(t,e,r){var o=this;this._platform=t,this._change=new n.Subject,this._changeListener=function(t){o._change.next(t)},this._document=r,e.runOutsideAngular((function(){if(t.isBrowser){var e=o._getWindow();e.addEventListener("resize",o._changeListener),e.addEventListener("orientationchange",o._changeListener)}o.change().subscribe((function(){return o._updateViewportSize()}))}))}return t.prototype.ngOnDestroy=function(){if(this._platform.isBrowser){var t=this._getWindow();t.removeEventListener("resize",this._changeListener),t.removeEventListener("orientationchange",this._changeListener)}this._change.complete()},t.prototype.getViewportSize=function(){this._viewportSize||this._updateViewportSize();var t={width:this._viewportSize.width,height:this._viewportSize.height};return this._platform.isBrowser||(this._viewportSize=null),t},t.prototype.getViewportRect=function(){var t=this.getViewportScrollPosition(),e=this.getViewportSize(),r=e.width,n=e.height;return{top:t.top,left:t.left,bottom:t.top+n,right:t.left+r,height:n,width:r}},t.prototype.getViewportScrollPosition=function(){if(!this._platform.isBrowser)return{top:0,left:0};var t=this._document,e=this._getWindow(),r=t.documentElement,n=r.getBoundingClientRect();return{top:-n.top||t.body.scrollTop||e.scrollY||r.scrollTop||0,left:-n.left||t.body.scrollLeft||e.scrollX||r.scrollLeft||0}},t.prototype.change=function(t){return void 0===t&&(t=20),t>0?this._change.pipe(o.auditTime(t)):this._change},t.prototype._getWindow=function(){return this._document.defaultView||window},t.prototype._updateViewportSize=function(){var t=this._getWindow();this._viewportSize=this._platform.isBrowser?{width:t.innerWidth,height:t.innerHeight}:{width:0,height:0}},t}();_.ɵprov=r.ɵɵdefineInjectable({factory:function t(){return new _(r.ɵɵinject(i.Platform),r.ɵɵinject(r.NgZone),r.ɵɵinject(a.DOCUMENT,8))},token:_,providedIn:"root"}),_.decorators=[{type:r.Injectable,args:[{providedIn:"root"}]}],_.ctorParameters=function(){return[{type:i.Platform},{type:r.NgZone},{type:void 0,decorators:[{type:r.Optional},{type:r.Inject,args:[a.DOCUMENT]}]}]};var m="undefined"!=typeof requestAnimationFrame?n.animationFrameScheduler:n.asapScheduler,y=function(t){function e(e,r,o,i,a,s,l){var c=t.call(this,e,s,o,a)||this;return c.elementRef=e,c._changeDetectorRef=r,c._scrollStrategy=i,c._detachedSubject=new n.Subject,c._renderedRangeSubject=new n.Subject,c._orientation="vertical",c.scrolledIndexChange=new n.Observable((function(t){return c._scrollStrategy.scrolledIndexChange.subscribe((function(e){return Promise.resolve().then((function(){return c.ngZone.run((function(){return t.next(e)}))}))}))})),c.renderedRangeStream=c._renderedRangeSubject,c._totalContentSize=0,c._totalContentWidth="",c._totalContentHeight="",c._renderedRange={start:0,end:0},c._dataLength=0,c._viewportSize=0,c._renderedContentOffset=0,c._renderedContentOffsetNeedsRewrite=!1,c._isChangeDetectionPending=!1,c._runAfterChangeDetection=[],c._viewportChanges=n.Subscription.EMPTY,c._viewportChanges=l.change().subscribe((function(){c.checkViewportSize()})),c}return function r(t,e){function r(){this.constructor=t}g(t,e),t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)}(e,t),Object.defineProperty(e.prototype,"orientation",{get:function(){return this._orientation},set:function(t){this._orientation!==t&&(this._orientation=t,this._calculateSpacerSize())},enumerable:!1,configurable:!0}),e.prototype.ngOnInit=function(){var e=this;t.prototype.ngOnInit.call(this),this.ngZone.runOutsideAngular((function(){return Promise.resolve().then((function(){e._measureViewportSize(),e._scrollStrategy.attach(e),e.elementScrolled().pipe(o.startWith(null),o.auditTime(0,m)).subscribe((function(){return e._scrollStrategy.onContentScrolled()})),e._markChangeDetectionNeeded()}))}))},e.prototype.ngOnDestroy=function(){this.detach(),this._scrollStrategy.detach(),this._renderedRangeSubject.complete(),this._detachedSubject.complete(),this._viewportChanges.unsubscribe(),t.prototype.ngOnDestroy.call(this)},e.prototype.attach=function(t){var e=this;this.ngZone.runOutsideAngular((function(){e._forOf=t,e._forOf.dataStream.pipe(o.takeUntil(e._detachedSubject)).subscribe((function(t){var r=t.length;r!==e._dataLength&&(e._dataLength=r,e._scrollStrategy.onDataLengthChanged()),e._doChangeDetection()}))}))},e.prototype.detach=function(){this._forOf=null,this._detachedSubject.next()},e.prototype.getDataLength=function(){return this._dataLength},e.prototype.getViewportSize=function(){return this._viewportSize},e.prototype.getRenderedRange=function(){return this._renderedRange},e.prototype.setTotalContentSize=function(t){this._totalContentSize!==t&&(this._totalContentSize=t,this._calculateSpacerSize(),this._markChangeDetectionNeeded())},e.prototype.setRenderedRange=function(t){var e=this;(function r(t,e){return t.start==e.start&&t.end==e.end})(this._renderedRange,t)||(this._renderedRangeSubject.next(this._renderedRange=t),this._markChangeDetectionNeeded((function(){return e._scrollStrategy.onContentRendered()})))},e.prototype.getOffsetToRenderedContentStart=function(){return this._renderedContentOffsetNeedsRewrite?null:this._renderedContentOffset},e.prototype.setRenderedContentOffset=function(t,e){var r=this;void 0===e&&(e="to-start");var n="horizontal"==this.orientation,o=n?"X":"Y",i="translate"+o+"("+Number((n&&this.dir&&"rtl"==this.dir.value?-1:1)*t)+"px)";this._renderedContentOffset=t,"to-end"===e&&(i+=" translate"+o+"(-100%)",this._renderedContentOffsetNeedsRewrite=!0),this._renderedContentTransform!=i&&(this._renderedContentTransform=i,this._markChangeDetectionNeeded((function(){r._renderedContentOffsetNeedsRewrite?(r._renderedContentOffset-=r.measureRenderedContentSize(),r._renderedContentOffsetNeedsRewrite=!1,r.setRenderedContentOffset(r._renderedContentOffset)):r._scrollStrategy.onRenderedOffsetChanged()})))},e.prototype.scrollToOffset=function(t,e){void 0===e&&(e="auto");var r={behavior:e};"horizontal"===this.orientation?r.start=t:r.top=t,this.scrollTo(r)},e.prototype.scrollToIndex=function(t,e){void 0===e&&(e="auto"),this._scrollStrategy.scrollToIndex(t,e)},e.prototype.measureScrollOffset=function(e){return t.prototype.measureScrollOffset.call(this,e||("horizontal"===this.orientation?"start":"top"))},e.prototype.measureRenderedContentSize=function(){var t=this._contentWrapper.nativeElement;return"horizontal"===this.orientation?t.offsetWidth:t.offsetHeight},e.prototype.measureRangeSize=function(t){return this._forOf?this._forOf.measureRangeSize(t,this.orientation):0},e.prototype.checkViewportSize=function(){this._measureViewportSize(),this._scrollStrategy.onDataLengthChanged()},e.prototype._measureViewportSize=function(){var t=this.elementRef.nativeElement;this._viewportSize="horizontal"===this.orientation?t.clientWidth:t.clientHeight},e.prototype._markChangeDetectionNeeded=function(t){var e=this;t&&this._runAfterChangeDetection.push(t),this._isChangeDetectionPending||(this._isChangeDetectionPending=!0,this.ngZone.runOutsideAngular((function(){return Promise.resolve().then((function(){e._doChangeDetection()}))})))},e.prototype._doChangeDetection=function(){var t,e,r=this;this._isChangeDetectionPending=!1,this._contentWrapper.nativeElement.style.transform=this._renderedContentTransform,this.ngZone.run((function(){return r._changeDetectorRef.markForCheck()}));var n=this._runAfterChangeDetection;this._runAfterChangeDetection=[];try{for(var o=function i(t){var e="function"==typeof Symbol&&Symbol.iterator,r=e&&t[e],n=0;if(r)return r.call(t);if(t&&"number"==typeof t.length)return{next:function(){return t&&n>=t.length&&(t=void 0),{value:t&&t[n++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")}(n),a=o.next();!a.done;a=o.next())(0,a.value)()}catch(e){t={error:e}}finally{try{a&&!a.done&&(e=o.return)&&e.call(o)}finally{if(t)throw t.error}}},e.prototype._calculateSpacerSize=function(){this._totalContentHeight="horizontal"===this.orientation?"":this._totalContentSize+"px",this._totalContentWidth="horizontal"===this.orientation?this._totalContentSize+"px":""},e}(f);function v(t,e,r){if(!r.getBoundingClientRect)return 0;var n=r.getBoundingClientRect();return"horizontal"===t?"start"===e?n.left:n.right:"start"===e?n.top:n.bottom}y.decorators=[{type:r.Component,args:[{selector:"cdk-virtual-scroll-viewport",template:'\x3c!--\n Wrap the rendered content in an element that will be used to offset it based on the scroll\n position.\n--\x3e\n<div #contentWrapper class="cdk-virtual-scroll-content-wrapper">\n <ng-content></ng-content>\n</div>\n\x3c!--\n Spacer used to force the scrolling container to the correct size for the *total* number of items\n so that the scrollbar captures the size of the entire data set.\n--\x3e\n<div class="cdk-virtual-scroll-spacer"\n [style.width]="_totalContentWidth" [style.height]="_totalContentHeight"></div>\n',host:{class:"cdk-virtual-scroll-viewport","[class.cdk-virtual-scroll-orientation-horizontal]":'orientation === "horizontal"',"[class.cdk-virtual-scroll-orientation-vertical]":'orientation !== "horizontal"'},encapsulation:r.ViewEncapsulation.None,changeDetection:r.ChangeDetectionStrategy.OnPush,providers:[{provide:f,useExisting:y}],styles:["cdk-virtual-scroll-viewport{display:block;position:relative;overflow:auto;contain:strict;transform:translateZ(0);will-change:scroll-position;-webkit-overflow-scrolling:touch}.cdk-virtual-scroll-content-wrapper{position:absolute;top:0;left:0;contain:content}[dir=rtl] .cdk-virtual-scroll-content-wrapper{right:0;left:auto}.cdk-virtual-scroll-orientation-horizontal .cdk-virtual-scroll-content-wrapper{min-height:100%}.cdk-virtual-scroll-orientation-horizontal .cdk-virtual-scroll-content-wrapper>dl:not([cdkVirtualFor]),.cdk-virtual-scroll-orientation-horizontal .cdk-virtual-scroll-content-wrapper>ol:not([cdkVirtualFor]),.cdk-virtual-scroll-orientation-horizontal .cdk-virtual-scroll-content-wrapper>table:not([cdkVirtualFor]),.cdk-virtual-scroll-orientation-horizontal .cdk-virtual-scroll-content-wrapper>ul:not([cdkVirtualFor]){padding-left:0;padding-right:0;margin-left:0;margin-right:0;border-left-width:0;border-right-width:0;outline:none}.cdk-virtual-scroll-orientation-vertical .cdk-virtual-scroll-content-wrapper{min-width:100%}.cdk-virtual-scroll-orientation-vertical .cdk-virtual-scroll-content-wrapper>dl:not([cdkVirtualFor]),.cdk-virtual-scroll-orientation-vertical .cdk-virtual-scroll-content-wrapper>ol:not([cdkVirtualFor]),.cdk-virtual-scroll-orientation-vertical .cdk-virtual-scroll-content-wrapper>table:not([cdkVirtualFor]),.cdk-virtual-scroll-orientation-vertical .cdk-virtual-scroll-content-wrapper>ul:not([cdkVirtualFor]){padding-top:0;padding-bottom:0;margin-top:0;margin-bottom:0;border-top-width:0;border-bottom-width:0;outline:none}.cdk-virtual-scroll-spacer{position:absolute;top:0;left:0;height:1px;width:1px;transform-origin:0 0}[dir=rtl] .cdk-virtual-scroll-spacer{right:0;left:auto;transform-origin:100% 0}\n"]}]}],y.ctorParameters=function(){return[{type:r.ElementRef},{type:r.ChangeDetectorRef},{type:r.NgZone},{type:void 0,decorators:[{type:r.Optional},{type:r.Inject,args:[c]}]},{type:s.Directionality,decorators:[{type:r.Optional}]},{type:p},{type:_}]},y.propDecorators={orientation:[{type:r.Input}],scrolledIndexChange:[{type:r.Output}],_contentWrapper:[{type:r.ViewChild,args:["contentWrapper",{static:!0}]}]};var S,w,b=function(){function t(t,e,r,i,a,s){var l=this;this._viewContainerRef=t,this._template=e,this._differs=r,this._viewRepeater=i,this._viewport=a,this.viewChange=new n.Subject,this._dataSourceChanges=new n.Subject,this.dataStream=this._dataSourceChanges.pipe(o.startWith(null),o.pairwise(),o.switchMap((function(t){var e=function r(t,e){var r="function"==typeof Symbol&&t[Symbol.iterator];if(!r)return t;var n,o,i=r.call(t),a=[];try{for(;(void 0===e||e-- >0)&&!(n=i.next()).done;)a.push(n.value)}catch(t){o={error:t}}finally{try{n&&!n.done&&(r=i.return)&&r.call(i)}finally{if(o)throw o.error}}return a}(t,2);return l._changeDataSource(e[0],e[1])})),o.shareReplay(1)),this._differ=null,this._needsUpdate=!1,this._destroyed=new n.Subject,this.dataStream.subscribe((function(t){l._data=t,l._onRenderedDataChange()})),this._viewport.renderedRangeStream.pipe(o.takeUntil(this._destroyed)).subscribe((function(t){l._renderedRange=t,s.run((function(){return l.viewChange.next(l._renderedRange)})),l._onRenderedDataChange()})),this._viewport.attach(this)}return Object.defineProperty(t.prototype,"cdkVirtualForOf",{get:function(){return this._cdkVirtualForOf},set:function(t){this._cdkVirtualForOf=t,l.isDataSource(t)?this._dataSourceChanges.next(t):this._dataSourceChanges.next(new l.ArrayDataSource(n.isObservable(t)?t:Array.from(t||[])))},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"cdkVirtualForTrackBy",{get:function(){return this._cdkVirtualForTrackBy},set:function(t){var e=this;this._needsUpdate=!0,this._cdkVirtualForTrackBy=t?function(r,n){return t(r+(e._renderedRange?e._renderedRange.start:0),n)}:void 0},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"cdkVirtualForTemplate",{set:function(t){t&&(this._needsUpdate=!0,this._template=t)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"cdkVirtualForTemplateCacheSize",{get:function(){return this._viewRepeater.viewCacheSize},set:function(t){this._viewRepeater.viewCacheSize=e.coerceNumberProperty(t)},enumerable:!1,configurable:!0}),t.prototype.measureRangeSize=function(t,e){if(t.start>=t.end)return 0;for(var r,n,o=t.start-this._renderedRange.start,i=t.end-t.start,a=0;a<i;a++)if((s=this._viewContainerRef.get(a+o))&&s.rootNodes.length){r=n=s.rootNodes[0];break}for(a=i-1;a>-1;a--){var s;if((s=this._viewContainerRef.get(a+o))&&s.rootNodes.length){n=s.rootNodes[s.rootNodes.length-1];break}}return r&&n?v(e,"end",n)-v(e,"start",r):0},t.prototype.ngDoCheck=function(){if(this._differ&&this._needsUpdate){var t=this._differ.diff(this._renderedItems);t?this._applyChanges(t):this._updateContext(),this._needsUpdate=!1}},t.prototype.ngOnDestroy=function(){this._viewport.detach(),this._dataSourceChanges.next(void 0),this._dataSourceChanges.complete(),this.viewChange.complete(),this._destroyed.next(),this._destroyed.complete(),this._viewRepeater.detach()},t.prototype._onRenderedDataChange=function(){this._renderedRange&&(this._renderedItems=this._data.slice(this._renderedRange.start,this._renderedRange.end),this._differ||(this._differ=this._differs.find(this._renderedItems).create(this.cdkVirtualForTrackBy)),this._needsUpdate=!0)},t.prototype._changeDataSource=function(t,e){return t&&t.disconnect(this),this._needsUpdate=!0,e?e.connect(this):n.of()},t.prototype._updateContext=function(){for(var t=this._data.length,e=this._viewContainerRef.length;e--;){var r=this._viewContainerRef.get(e);r.context.index=this._renderedRange.start+e,r.context.count=t,this._updateComputedContextProperties(r.context),r.detectChanges()}},t.prototype._applyChanges=function(t){var e=this;this._viewRepeater.applyChanges(t,this._viewContainerRef,(function(t,r,n){return e._getEmbeddedViewArgs(t,n)}),(function(t){return t.item})),t.forEachIdentityChange((function(t){e._viewContainerRef.get(t.currentIndex).context.$implicit=t.item}));for(var r=this._data.length,n=this._viewContainerRef.length;n--;){var o=this._viewContainerRef.get(n);o.context.index=this._renderedRange.start+n,o.context.count=r,this._updateComputedContextProperties(o.context)}},t.prototype._updateComputedContextProperties=function(t){t.first=0===t.index,t.last=t.index===t.count-1,t.even=t.index%2==0,t.odd=!t.even},t.prototype._getEmbeddedViewArgs=function(t,e){return{templateRef:this._template,context:{$implicit:t.item,cdkVirtualForOf:this._cdkVirtualForOf,index:-1,count:-1,first:!1,last:!1,odd:!1,even:!1},index:e}},t}();b.decorators=[{type:r.Directive,args:[{selector:"[cdkVirtualFor][cdkVirtualForOf]",providers:[{provide:l._VIEW_REPEATER_STRATEGY,useClass:l._RecycleViewRepeaterStrategy}]}]}],b.ctorParameters=function(){return[{type:r.ViewContainerRef},{type:r.TemplateRef},{type:r.IterableDiffers},{type:l._RecycleViewRepeaterStrategy,decorators:[{type:r.Inject,args:[l._VIEW_REPEATER_STRATEGY]}]},{type:y,decorators:[{type:r.SkipSelf}]},{type:r.NgZone}]},b.propDecorators={cdkVirtualForOf:[{type:r.Input}],cdkVirtualForTrackBy:[{type:r.Input}],cdkVirtualForTemplate:[{type:r.Input}],cdkVirtualForTemplateCacheSize:[{type:r.Input}]},(S=function S(){}).decorators=[{type:r.NgModule,args:[{exports:[f],declarations:[f]}]}],(w=function w(){}).decorators=[{type:r.NgModule,args:[{imports:[s.BidiModule,i.PlatformModule,S],exports:[s.BidiModule,S,h,b,y],declarations:[h,b,y]}]}],
46
+ var g=function(t,e){return(g=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r])})(t,e)},_=function(){function t(t,e,r){var o=this;this._platform=t,this._change=new n.Subject,this._changeListener=function(t){o._change.next(t)},this._document=r,e.runOutsideAngular((function(){if(t.isBrowser){var e=o._getWindow();e.addEventListener("resize",o._changeListener),e.addEventListener("orientationchange",o._changeListener)}o.change().subscribe((function(){return o._updateViewportSize()}))}))}return t.prototype.ngOnDestroy=function(){if(this._platform.isBrowser){var t=this._getWindow();t.removeEventListener("resize",this._changeListener),t.removeEventListener("orientationchange",this._changeListener)}this._change.complete()},t.prototype.getViewportSize=function(){this._viewportSize||this._updateViewportSize();var t={width:this._viewportSize.width,height:this._viewportSize.height};return this._platform.isBrowser||(this._viewportSize=null),t},t.prototype.getViewportRect=function(){var t=this.getViewportScrollPosition(),e=this.getViewportSize(),r=e.width,n=e.height;return{top:t.top,left:t.left,bottom:t.top+n,right:t.left+r,height:n,width:r}},t.prototype.getViewportScrollPosition=function(){if(!this._platform.isBrowser)return{top:0,left:0};var t=this._document,e=this._getWindow(),r=t.documentElement,n=r.getBoundingClientRect();return{top:-n.top||t.body.scrollTop||e.scrollY||r.scrollTop||0,left:-n.left||t.body.scrollLeft||e.scrollX||r.scrollLeft||0}},t.prototype.change=function(t){return void 0===t&&(t=20),t>0?this._change.pipe(o.auditTime(t)):this._change},t.prototype._getWindow=function(){return this._document.defaultView||window},t.prototype._updateViewportSize=function(){var t=this._getWindow();this._viewportSize=this._platform.isBrowser?{width:t.innerWidth,height:t.innerHeight}:{width:0,height:0}},t}();_.ɵprov=r.ɵɵdefineInjectable({factory:function t(){return new _(r.ɵɵinject(i.Platform),r.ɵɵinject(r.NgZone),r.ɵɵinject(a.DOCUMENT,8))},token:_,providedIn:"root"}),_.decorators=[{type:r.Injectable,args:[{providedIn:"root"}]}],_.ctorParameters=function(){return[{type:i.Platform},{type:r.NgZone},{type:void 0,decorators:[{type:r.Optional},{type:r.Inject,args:[a.DOCUMENT]}]}]};var m="undefined"!=typeof requestAnimationFrame?n.animationFrameScheduler:n.asapScheduler,y=function(t){function e(e,r,o,i,a,s,l){var c=t.call(this,e,s,o,a)||this;return c.elementRef=e,c._changeDetectorRef=r,c._scrollStrategy=i,c._detachedSubject=new n.Subject,c._renderedRangeSubject=new n.Subject,c._orientation="vertical",c.scrolledIndexChange=new n.Observable((function(t){return c._scrollStrategy.scrolledIndexChange.subscribe((function(e){return Promise.resolve().then((function(){return c.ngZone.run((function(){return t.next(e)}))}))}))})),c.renderedRangeStream=c._renderedRangeSubject,c._totalContentSize=0,c._totalContentWidth="",c._totalContentHeight="",c._renderedRange={start:0,end:0},c._dataLength=0,c._viewportSize=0,c._renderedContentOffset=0,c._renderedContentOffsetNeedsRewrite=!1,c._isChangeDetectionPending=!1,c._runAfterChangeDetection=[],c._viewportChanges=n.Subscription.EMPTY,c._viewportChanges=l.change().subscribe((function(){c.checkViewportSize()})),c}return function r(t,e){function r(){this.constructor=t}g(t,e),t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)}(e,t),Object.defineProperty(e.prototype,"orientation",{get:function(){return this._orientation},set:function(t){this._orientation!==t&&(this._orientation=t,this._calculateSpacerSize())},enumerable:!1,configurable:!0}),e.prototype.ngOnInit=function(){var e=this;t.prototype.ngOnInit.call(this),this.ngZone.runOutsideAngular((function(){return Promise.resolve().then((function(){e._measureViewportSize(),e._scrollStrategy.attach(e),e.elementScrolled().pipe(o.startWith(null),o.auditTime(0,m)).subscribe((function(){return e._scrollStrategy.onContentScrolled()})),e._markChangeDetectionNeeded()}))}))},e.prototype.ngOnDestroy=function(){this.detach(),this._scrollStrategy.detach(),this._renderedRangeSubject.complete(),this._detachedSubject.complete(),this._viewportChanges.unsubscribe(),t.prototype.ngOnDestroy.call(this)},e.prototype.attach=function(t){var e=this;this.ngZone.runOutsideAngular((function(){e._forOf=t,e._forOf.dataStream.pipe(o.takeUntil(e._detachedSubject)).subscribe((function(t){var r=t.length;r!==e._dataLength&&(e._dataLength=r,e._scrollStrategy.onDataLengthChanged()),e._doChangeDetection()}))}))},e.prototype.detach=function(){this._forOf=null,this._detachedSubject.next()},e.prototype.getDataLength=function(){return this._dataLength},e.prototype.getViewportSize=function(){return this._viewportSize},e.prototype.getRenderedRange=function(){return this._renderedRange},e.prototype.setTotalContentSize=function(t){this._totalContentSize!==t&&(this._totalContentSize=t,this._calculateSpacerSize(),this._markChangeDetectionNeeded())},e.prototype.setRenderedRange=function(t){var e=this;(function r(t,e){return t.start==e.start&&t.end==e.end})(this._renderedRange,t)||(this._renderedRangeSubject.next(this._renderedRange=t),this._markChangeDetectionNeeded((function(){return e._scrollStrategy.onContentRendered()})))},e.prototype.getOffsetToRenderedContentStart=function(){return this._renderedContentOffsetNeedsRewrite?null:this._renderedContentOffset},e.prototype.setRenderedContentOffset=function(t,e){var r=this;void 0===e&&(e="to-start");var n="horizontal"==this.orientation,o=n?"X":"Y",i="translate"+o+"("+Number((n&&this.dir&&"rtl"==this.dir.value?-1:1)*t)+"px)";this._renderedContentOffset=t,"to-end"===e&&(i+=" translate"+o+"(-100%)",this._renderedContentOffsetNeedsRewrite=!0),this._renderedContentTransform!=i&&(this._renderedContentTransform=i,this._markChangeDetectionNeeded((function(){r._renderedContentOffsetNeedsRewrite?(r._renderedContentOffset-=r.measureRenderedContentSize(),r._renderedContentOffsetNeedsRewrite=!1,r.setRenderedContentOffset(r._renderedContentOffset)):r._scrollStrategy.onRenderedOffsetChanged()})))},e.prototype.scrollToOffset=function(t,e){void 0===e&&(e="auto");var r={behavior:e};"horizontal"===this.orientation?r.start=t:r.top=t,this.scrollTo(r)},e.prototype.scrollToIndex=function(t,e){void 0===e&&(e="auto"),this._scrollStrategy.scrollToIndex(t,e)},e.prototype.measureScrollOffset=function(e){return t.prototype.measureScrollOffset.call(this,e||("horizontal"===this.orientation?"start":"top"))},e.prototype.measureRenderedContentSize=function(){var t=this._contentWrapper.nativeElement;return"horizontal"===this.orientation?t.offsetWidth:t.offsetHeight},e.prototype.measureRangeSize=function(t){return this._forOf?this._forOf.measureRangeSize(t,this.orientation):0},e.prototype.checkViewportSize=function(){this._measureViewportSize(),this._scrollStrategy.onDataLengthChanged()},e.prototype._measureViewportSize=function(){var t=this.elementRef.nativeElement;this._viewportSize="horizontal"===this.orientation?t.clientWidth:t.clientHeight},e.prototype._markChangeDetectionNeeded=function(t){var e=this;t&&this._runAfterChangeDetection.push(t),this._isChangeDetectionPending||(this._isChangeDetectionPending=!0,this.ngZone.runOutsideAngular((function(){return Promise.resolve().then((function(){e._doChangeDetection()}))})))},e.prototype._doChangeDetection=function(){var t,e,r=this;this._isChangeDetectionPending=!1,this._contentWrapper.nativeElement.style.transform=this._renderedContentTransform,this.ngZone.run((function(){return r._changeDetectorRef.markForCheck()}));var n=this._runAfterChangeDetection;this._runAfterChangeDetection=[];try{for(var o=function i(t){var e="function"==typeof Symbol&&Symbol.iterator,r=e&&t[e],n=0;if(r)return r.call(t);if(t&&"number"==typeof t.length)return{next:function(){return t&&n>=t.length&&(t=void 0),{value:t&&t[n++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")}(n),a=o.next();!a.done;a=o.next())(0,a.value)()}catch(e){t={error:e}}finally{try{a&&!a.done&&(e=o.return)&&e.call(o)}finally{if(t)throw t.error}}},e.prototype._calculateSpacerSize=function(){this._totalContentHeight="horizontal"===this.orientation?"":this._totalContentSize+"px",this._totalContentWidth="horizontal"===this.orientation?this._totalContentSize+"px":""},e}(f);function v(t,e,r){if(!r.getBoundingClientRect)return 0;var n=r.getBoundingClientRect();return"horizontal"===t?"start"===e?n.left:n.right:"start"===e?n.top:n.bottom}y.decorators=[{type:r.Component,args:[{selector:"cdk-virtual-scroll-viewport",template:'\x3c!--\n Wrap the rendered content in an element that will be used to offset it based on the scroll\n position.\n--\x3e\n<div #contentWrapper class="cdk-virtual-scroll-content-wrapper">\n <ng-content></ng-content>\n</div>\n\x3c!--\n Spacer used to force the scrolling container to the correct size for the *total* number of items\n so that the scrollbar captures the size of the entire data set.\n--\x3e\n<div class="cdk-virtual-scroll-spacer"\n [style.width]="_totalContentWidth" [style.height]="_totalContentHeight"></div>\n',host:{class:"cdk-virtual-scroll-viewport","[class.cdk-virtual-scroll-orientation-horizontal]":'orientation === "horizontal"',"[class.cdk-virtual-scroll-orientation-vertical]":'orientation !== "horizontal"'},encapsulation:r.ViewEncapsulation.None,changeDetection:r.ChangeDetectionStrategy.OnPush,providers:[{provide:f,useExisting:y}],styles:["cdk-virtual-scroll-viewport{display:block;position:relative;overflow:auto;contain:strict;transform:translateZ(0);will-change:scroll-position;-webkit-overflow-scrolling:touch}.cdk-virtual-scroll-content-wrapper{position:absolute;top:0;left:0;contain:content}[dir=rtl] .cdk-virtual-scroll-content-wrapper{right:0;left:auto}.cdk-virtual-scroll-orientation-horizontal .cdk-virtual-scroll-content-wrapper{min-height:100%}.cdk-virtual-scroll-orientation-horizontal .cdk-virtual-scroll-content-wrapper>dl:not([cdkVirtualFor]),.cdk-virtual-scroll-orientation-horizontal .cdk-virtual-scroll-content-wrapper>ol:not([cdkVirtualFor]),.cdk-virtual-scroll-orientation-horizontal .cdk-virtual-scroll-content-wrapper>table:not([cdkVirtualFor]),.cdk-virtual-scroll-orientation-horizontal .cdk-virtual-scroll-content-wrapper>ul:not([cdkVirtualFor]){padding-left:0;padding-right:0;margin-left:0;margin-right:0;border-left-width:0;border-right-width:0;outline:none}.cdk-virtual-scroll-orientation-vertical .cdk-virtual-scroll-content-wrapper{min-width:100%}.cdk-virtual-scroll-orientation-vertical .cdk-virtual-scroll-content-wrapper>dl:not([cdkVirtualFor]),.cdk-virtual-scroll-orientation-vertical .cdk-virtual-scroll-content-wrapper>ol:not([cdkVirtualFor]),.cdk-virtual-scroll-orientation-vertical .cdk-virtual-scroll-content-wrapper>table:not([cdkVirtualFor]),.cdk-virtual-scroll-orientation-vertical .cdk-virtual-scroll-content-wrapper>ul:not([cdkVirtualFor]){padding-top:0;padding-bottom:0;margin-top:0;margin-bottom:0;border-top-width:0;border-bottom-width:0;outline:none}.cdk-virtual-scroll-spacer{position:absolute;top:0;left:0;height:1px;width:1px;transform-origin:0 0}[dir=rtl] .cdk-virtual-scroll-spacer{right:0;left:auto;transform-origin:100% 0}\n"]}]}],y.ctorParameters=function(){return[{type:r.ElementRef},{type:r.ChangeDetectorRef},{type:r.NgZone},{type:void 0,decorators:[{type:r.Optional},{type:r.Inject,args:[c]}]},{type:s.Directionality,decorators:[{type:r.Optional}]},{type:p},{type:_}]},y.propDecorators={orientation:[{type:r.Input}],scrolledIndexChange:[{type:r.Output}],_contentWrapper:[{type:r.ViewChild,args:["contentWrapper",{static:!0}]}]};var S,b,w=function(){function t(t,e,r,i,a,s){var l=this;this._viewContainerRef=t,this._template=e,this._differs=r,this._viewRepeater=i,this._viewport=a,this.viewChange=new n.Subject,this._dataSourceChanges=new n.Subject,this.dataStream=this._dataSourceChanges.pipe(o.startWith(null),o.pairwise(),o.switchMap((function(t){var e=function r(t,e){var r="function"==typeof Symbol&&t[Symbol.iterator];if(!r)return t;var n,o,i=r.call(t),a=[];try{for(;(void 0===e||e-- >0)&&!(n=i.next()).done;)a.push(n.value)}catch(t){o={error:t}}finally{try{n&&!n.done&&(r=i.return)&&r.call(i)}finally{if(o)throw o.error}}return a}(t,2);return l._changeDataSource(e[0],e[1])})),o.shareReplay(1)),this._differ=null,this._needsUpdate=!1,this._destroyed=new n.Subject,this.dataStream.subscribe((function(t){l._data=t,l._onRenderedDataChange()})),this._viewport.renderedRangeStream.pipe(o.takeUntil(this._destroyed)).subscribe((function(t){l._renderedRange=t,s.run((function(){return l.viewChange.next(l._renderedRange)})),l._onRenderedDataChange()})),this._viewport.attach(this)}return Object.defineProperty(t.prototype,"cdkVirtualForOf",{get:function(){return this._cdkVirtualForOf},set:function(t){this._cdkVirtualForOf=t,l.isDataSource(t)?this._dataSourceChanges.next(t):this._dataSourceChanges.next(new l.ArrayDataSource(n.isObservable(t)?t:Array.from(t||[])))},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"cdkVirtualForTrackBy",{get:function(){return this._cdkVirtualForTrackBy},set:function(t){var e=this;this._needsUpdate=!0,this._cdkVirtualForTrackBy=t?function(r,n){return t(r+(e._renderedRange?e._renderedRange.start:0),n)}:void 0},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"cdkVirtualForTemplate",{set:function(t){t&&(this._needsUpdate=!0,this._template=t)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"cdkVirtualForTemplateCacheSize",{get:function(){return this._viewRepeater.viewCacheSize},set:function(t){this._viewRepeater.viewCacheSize=e.coerceNumberProperty(t)},enumerable:!1,configurable:!0}),t.prototype.measureRangeSize=function(t,e){if(t.start>=t.end)return 0;for(var r,n,o=t.start-this._renderedRange.start,i=t.end-t.start,a=0;a<i;a++)if((s=this._viewContainerRef.get(a+o))&&s.rootNodes.length){r=n=s.rootNodes[0];break}for(a=i-1;a>-1;a--){var s;if((s=this._viewContainerRef.get(a+o))&&s.rootNodes.length){n=s.rootNodes[s.rootNodes.length-1];break}}return r&&n?v(e,"end",n)-v(e,"start",r):0},t.prototype.ngDoCheck=function(){if(this._differ&&this._needsUpdate){var t=this._differ.diff(this._renderedItems);t?this._applyChanges(t):this._updateContext(),this._needsUpdate=!1}},t.prototype.ngOnDestroy=function(){this._viewport.detach(),this._dataSourceChanges.next(void 0),this._dataSourceChanges.complete(),this.viewChange.complete(),this._destroyed.next(),this._destroyed.complete(),this._viewRepeater.detach()},t.prototype._onRenderedDataChange=function(){this._renderedRange&&(this._renderedItems=this._data.slice(this._renderedRange.start,this._renderedRange.end),this._differ||(this._differ=this._differs.find(this._renderedItems).create(this.cdkVirtualForTrackBy)),this._needsUpdate=!0)},t.prototype._changeDataSource=function(t,e){return t&&t.disconnect(this),this._needsUpdate=!0,e?e.connect(this):n.of()},t.prototype._updateContext=function(){for(var t=this._data.length,e=this._viewContainerRef.length;e--;){var r=this._viewContainerRef.get(e);r.context.index=this._renderedRange.start+e,r.context.count=t,this._updateComputedContextProperties(r.context),r.detectChanges()}},t.prototype._applyChanges=function(t){var e=this;this._viewRepeater.applyChanges(t,this._viewContainerRef,(function(t,r,n){return e._getEmbeddedViewArgs(t,n)}),(function(t){return t.item})),t.forEachIdentityChange((function(t){e._viewContainerRef.get(t.currentIndex).context.$implicit=t.item}));for(var r=this._data.length,n=this._viewContainerRef.length;n--;){var o=this._viewContainerRef.get(n);o.context.index=this._renderedRange.start+n,o.context.count=r,this._updateComputedContextProperties(o.context)}},t.prototype._updateComputedContextProperties=function(t){t.first=0===t.index,t.last=t.index===t.count-1,t.even=t.index%2==0,t.odd=!t.even},t.prototype._getEmbeddedViewArgs=function(t,e){return{templateRef:this._template,context:{$implicit:t.item,cdkVirtualForOf:this._cdkVirtualForOf,index:-1,count:-1,first:!1,last:!1,odd:!1,even:!1},index:e}},t}();w.decorators=[{type:r.Directive,args:[{selector:"[cdkVirtualFor][cdkVirtualForOf]",providers:[{provide:l._VIEW_REPEATER_STRATEGY,useClass:l._RecycleViewRepeaterStrategy}]}]}],w.ctorParameters=function(){return[{type:r.ViewContainerRef},{type:r.TemplateRef},{type:r.IterableDiffers},{type:l._RecycleViewRepeaterStrategy,decorators:[{type:r.Inject,args:[l._VIEW_REPEATER_STRATEGY]}]},{type:y,decorators:[{type:r.SkipSelf}]},{type:r.NgZone}]},w.propDecorators={cdkVirtualForOf:[{type:r.Input}],cdkVirtualForTrackBy:[{type:r.Input}],cdkVirtualForTemplate:[{type:r.Input}],cdkVirtualForTemplateCacheSize:[{type:r.Input}]},(S=function S(){}).decorators=[{type:r.NgModule,args:[{exports:[f],declarations:[f]}]}],(b=function b(){}).decorators=[{type:r.NgModule,args:[{imports:[s.BidiModule,i.PlatformModule,S],exports:[s.BidiModule,S,h,w,y],declarations:[h,w,y]}]}],
47
47
  /**
48
48
  * @license
49
49
  * Copyright Google LLC All Rights Reserved.
@@ -51,4 +51,4 @@ var g=function(t,e){return(g=Object.setPrototypeOf||{__proto__:[]}instanceof Arr
51
51
  * Use of this source code is governed by an MIT-style license that can be
52
52
  * found in the LICENSE file at https://angular.io/license
53
53
  */
54
- t.CdkFixedSizeVirtualScroll=h,t.CdkScrollable=f,t.CdkScrollableModule=S,t.CdkVirtualForOf=b,t.CdkVirtualScrollViewport=y,t.DEFAULT_RESIZE_TIME=20,t.DEFAULT_SCROLL_TIME=20,t.FixedSizeVirtualScrollStrategy=d,t.ScrollDispatcher=p,t.ScrollingModule=w,t.VIRTUAL_SCROLL_STRATEGY=c,t.ViewportRuler=_,t._fixedSizeVirtualScrollStrategyFactory=u,Object.defineProperty(t,"__esModule",{value:!0})}));
54
+ t.CdkFixedSizeVirtualScroll=h,t.CdkScrollable=f,t.CdkScrollableModule=S,t.CdkVirtualForOf=w,t.CdkVirtualScrollViewport=y,t.DEFAULT_RESIZE_TIME=20,t.DEFAULT_SCROLL_TIME=20,t.FixedSizeVirtualScrollStrategy=d,t.ScrollDispatcher=p,t.ScrollingModule=b,t.VIRTUAL_SCROLL_STRATEGY=c,t.ViewportRuler=_,t._fixedSizeVirtualScrollStrategyFactory=u,Object.defineProperty(t,"__esModule",{value:!0})}));