New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@progress/kendo-angular-popup

Package Overview
Dependencies
Maintainers
1
Versions
939
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@progress/kendo-angular-popup - npm Package Compare versions

Comparing version 2.0.2 to 2.1.0-dev.201803161304

dist/es/models/popup-animation.interface.js

2

dist/cdn/js/kendo-angular-popup.js

@@ -1,1 +0,1 @@

!function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e(require("tslib"),require("@angular/core"),require("rxjs/observable/fromPromise"),require("rxjs/observable/fromEvent"),require("rxjs/operators/auditTime"),require("rxjs/observable/merge"),require("@angular/common")):"function"==typeof define&&define.amd?define(["tslib","@angular/core","rxjs/observable/fromPromise","rxjs/observable/fromEvent","rxjs/operators/auditTime","rxjs/observable/merge","@angular/common"],e):"object"==typeof exports?exports.KendoAngularPopup=e(require("tslib"),require("@angular/core"),require("rxjs/observable/fromPromise"),require("rxjs/observable/fromEvent"),require("rxjs/operators/auditTime"),require("rxjs/observable/merge"),require("@angular/common")):t.KendoAngularPopup=e(t.tslib,t["@angular/core"],t["rxjs/observable/fromPromise"],t["rxjs/observable/fromEvent"],t["rxjs/operators/auditTime"],t["rxjs/observable/merge"],t["@angular/common"])}(this,function(t,e,n,o,i,r,s){return function(t){function e(o){if(n[o])return n[o].exports;var i=n[o]={exports:{},id:o,loaded:!1};return t[o].call(i.exports,i,i.exports,e),i.loaded=!0,i.exports}var n={};return e.m=t,e.c=n,e.p="",e(0)}([function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=n(1);e.PopupService=o.PopupService,e.POPUP_CONTAINER=o.POPUP_CONTAINER;var i=n(4);e.PopupComponent=i.PopupComponent;var r=n(16);e.PopupModule=r.PopupModule},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=n(2),i=n(3),r=n(4);e.POPUP_CONTAINER=new i.InjectionToken("Popup Container");var s=function(){function t(t,e,n,o){this.applicationRef=t,this.componentFactoryResolver=e,this.injector=n,this.container=o}return Object.defineProperty(t.prototype,"rootViewContainer",{get:function(){var t=this.applicationRef.components||[];if(t[0])return t[0];throw new Error("\n View Container not found! Inject the POPUP_CONTAINER or define a specific ViewContainerRef via the appendTo option.\n See http://www.telerik.com/kendo-angular-ui/components/popup/api/POPUP_CONTAINER/ for more details.\n ")},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"rootViewContainerNode",{get:function(){return this.container?this.container.nativeElement:this.getComponentRootNode(this.rootViewContainer)},enumerable:!0,configurable:!0}),t.prototype.open=function(t){void 0===t&&(t={});var e=this.contentFrom(t.content),n=e.component,o=e.nodes,i=this.appendPopup(o,t.appendTo),r=i.instance;return this.projectComponentInputs(i,t),i.changeDetectorRef.detectChanges(),n&&n.changeDetectorRef.detectChanges(),{close:function(){n?n.destroy():(i.instance.content=null,i.changeDetectorRef.detectChanges()),i.destroy()},content:n,popup:i,popupAnchorViewportLeave:r.anchorViewportLeave,popupClose:r.close,popupElement:this.getComponentRootNode(i),popupOpen:r.open}},t.prototype.appendPopup=function(t,e){var n=this.createComponent(r.PopupComponent,t,e);return e||this.rootViewContainerNode.appendChild(this.getComponentRootNode(n)),n},t.prototype.getComponentRootNode=function(t){return t.hostView.rootNodes[0]},t.prototype.getComponentFactory=function(t){return this.componentFactoryResolver.resolveComponentFactory(t)},t.prototype.createComponent=function(t,e,n){var o=this.getComponentFactory(t);if(n)return n.createComponent(o,void 0,this.injector,e);var i=o.create(this.injector,e);return this.applicationRef.attachView(i.hostView),i},t.prototype.projectComponentInputs=function(t,e){return Object.getOwnPropertyNames(e).filter(function(t){return"content"!==t||e.content instanceof i.TemplateRef}).map(function(n){t.instance[n]=e[n]}),t},t.prototype.contentFrom=function(t){if(!t||t instanceof i.TemplateRef)return{component:null,nodes:[[]]};var e=this.createComponent(t),n=e?[e.location.nativeElement]:[];return{component:e,nodes:[n]}},t=o.__decorate([i.Injectable(),o.__param(3,i.Inject(e.POPUP_CONTAINER)),o.__param(3,i.Optional()),o.__metadata("design:paramtypes",[i.ApplicationRef,i.ComponentFactoryResolver,i.Injector,i.ElementRef])],t)}();e.PopupService=s},function(e,n){e.exports=t},function(t,n){t.exports=e},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=n(2),i=n(3),r=n(5),s=n(6),a=n(7),l=n(10),c=n(11),p=n(14),u=n(9),f={left:-1e4,top:0},d="k-animation-container",h="k-animation-container-fixed",m=function(){function t(t,e,n,o,r,s,a,l,c){this.container=t,this._alignService=e,this.domService=n,this._cdr=o,this._positionService=r,this._resizeService=s,this._scrollableService=a,this._renderer=l,this._zone=c,this.animate=!0,this.anchorAlign={horizontal:"left",vertical:"bottom"},this.collision={horizontal:"fit",vertical:"flip"},this.popupAlign={horizontal:"left",vertical:"top"},this.copyAnchorStyles=!1,this.positionMode="fixed",this.offset=f,this.anchorViewportLeave=new i.EventEmitter,this.close=new i.EventEmitter,this.open=new i.EventEmitter,this.direction="down",this.resolvedPromise=Promise.resolve(null),this._renderer.addClass(t.nativeElement,d),this.updateFixedClass()}return t.prototype.ngOnInit=function(){this.repositionCallback=this.reposition.bind(this),this._resizeService.subscribe(this.repositionCallback),this._scrollableService.forElement(this.anchor||this.container).subscribe(this.onScroll.bind(this)),this.currentOffset=f,this.setZIndex(),this.copyFontStyles(),this.updateFixedClass()},t.prototype.ngOnChanges=function(t){t.copyAnchorStyles&&this.copyFontStyles(),t.positionMode&&this.updateFixedClass()},t.prototype.ngAfterViewInit=function(){this.reposition()},t.prototype.ngAfterViewChecked=function(){var t=this;this._zone.runOutsideAngular(function(){t.repositionSubscription&&t.repositionSubscription.unsubscribe(),t.repositionSubscription=r.fromPromise(t.resolvedPromise).subscribe(t.repositionCallback)})},t.prototype.ngOnDestroy=function(){this.anchorViewportLeave.complete(),this.close.emit(),this.close.complete(),this._resizeService.unsubscribe(),this._scrollableService.unsubscribe(),this.repositionSubscription&&this.repositionSubscription.unsubscribe()},t.prototype.triggerOpen=function(t){this._renderer.addClass(this.container.nativeElement,"k-animation-container-shown"),this.open.emit(),this.open.complete()},Object.defineProperty(t.prototype,"currentOffset",{get:function(){return this._currentOffset},set:function(t){this._currentOffset&&!u.isDifferentOffset(this._currentOffset,t)||(this.setContainerStyle("left",t.left+"px"),this.setContainerStyle("top",t.top+"px"),this._currentOffset=t)},enumerable:!0,configurable:!0}),t.prototype.setZIndex=function(){this.anchor&&this.setContainerStyle("z-index",String(this.domService.zIndex(this.anchor,this.container)))},t.prototype.reposition=function(){if(u.isDocumentAvailable()){var t=this.position(),e=t.flipped,n=t.offset,o=this.getDirection(e);this.currentOffset=n,this.direction!==o&&(this.direction=o,this._cdr.detectChanges())}},t.prototype.position=function(){var t=this._alignService.alignElement({anchor:this.anchor,anchorAlign:this.anchorAlign,element:this.container,elementAlign:this.popupAlign,offset:this.offset,positionMode:this.positionMode});return this._positionService.positionElement({anchor:this.anchor,anchorAlign:this.anchorAlign,collisions:this.collision,currentLocation:t,element:this.container,elementAlign:this.popupAlign})},t.prototype.getDirection=function(t){return this.animate?t?"up":"down":"none"},t.prototype.onScroll=function(t){var e=this,n=this.anchorViewportLeave.observers.length;t||!n?this.reposition():n&&this._zone.run(function(){e.anchorViewportLeave.emit()})},t.prototype.copyFontStyles=function(){var t=this;this.anchor&&this.copyAnchorStyles&&this.domService.getFontStyles(this.anchor).forEach(function(e){return t.setContainerStyle(e.key,e.value)})},t.prototype.updateFixedClass=function(){var t="fixed"===this.positionMode?"addClass":"removeClass";this._renderer[t](this.container.nativeElement,h)},t.prototype.setContainerStyle=function(t,e){this._renderer.setStyle(this.container.nativeElement,t,e)},o.__decorate([i.Input(),o.__metadata("design:type",Boolean)],t.prototype,"animate",void 0),o.__decorate([i.Input(),o.__metadata("design:type",i.ElementRef)],t.prototype,"anchor",void 0),o.__decorate([i.Input(),o.__metadata("design:type",Object)],t.prototype,"anchorAlign",void 0),o.__decorate([i.Input(),o.__metadata("design:type",Object)],t.prototype,"collision",void 0),o.__decorate([i.Input(),o.__metadata("design:type",Object)],t.prototype,"popupAlign",void 0),o.__decorate([i.Input(),o.__metadata("design:type",Boolean)],t.prototype,"copyAnchorStyles",void 0),o.__decorate([i.Input(),o.__metadata("design:type",Object)],t.prototype,"popupClass",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"positionMode",void 0),o.__decorate([i.Input(),o.__metadata("design:type",Object)],t.prototype,"offset",void 0),o.__decorate([i.Output(),o.__metadata("design:type",i.EventEmitter)],t.prototype,"anchorViewportLeave",void 0),o.__decorate([i.Output(),o.__metadata("design:type",i.EventEmitter)],t.prototype,"close",void 0),o.__decorate([i.Output(),o.__metadata("design:type",i.EventEmitter)],t.prototype,"open",void 0),t=o.__decorate([i.Component({animations:[i.trigger("toggle",[i.transition("void => down, up => down",[i.style({transform:"translateY(-100%)"}),i.animate("0.1s ease-in",i.style({transform:"translateY(0)"}))]),i.transition("down => void",[i.style({transform:"translateY(0)"}),i.animate("0.1s ease-in",i.style({transform:"translateY(-100%)"}))]),i.transition("void => up, down => up",[i.style({transform:"translateY(100%)"}),i.animate("0.1s ease-in",i.style({transform:"translateY(0)"}))]),i.transition("up => void",[i.style({transform:"translateY(0)"}),i.animate("0.1s ease-in",i.style({transform:"translateY(100%)"}))])])],exportAs:"kendo-popup",providers:[s.AlignService,a.DOMService,l.PositionService,c.ResizeService,p.ScrollableService],selector:"kendo-popup",template:'\n <div class="k-popup" [ngClass]="popupClass" [@toggle]="direction" (@toggle.done)="triggerOpen($event)">\n <ng-content></ng-content>\n <ng-template [ngTemplateOutlet]="content" [ngIf]="content"></ng-template>\n </div>\n '}),o.__metadata("design:paramtypes",[i.ElementRef,s.AlignService,a.DOMService,i.ChangeDetectorRef,l.PositionService,c.ResizeService,p.ScrollableService,i.Renderer2,i.NgZone])],t)}();e.PopupComponent=m},function(t,e){t.exports=n},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=n(2),i=n(3),r=n(7),s=n(9),a=function(){function t(t){this._dom=t}return t.prototype.alignElement=function(t){var e=t.anchor,n=t.element,o=t.anchorAlign,i=t.elementAlign,r=t.offset,s=t.positionMode,a="fixed"===s||!this._dom.hasOffsetParent(n),l=a?this.absoluteRect(e,n,r):this.relativeRect(e,n,r);return this._dom.align({anchorAlign:o,anchorRect:l,elementAlign:i,elementRect:this._dom.offset(n)})},t.prototype.absoluteRect=function(t,e,n){return this._dom.removeScroll(this._dom.addScroll(s.removeStackingOffset(s.eitherRect(this._dom.offset(t),n),this._dom.stackingElementOffset(e)),this._dom.stackingElementScroll(e)),this.elementScrollPosition(t,e))},t.prototype.elementScrollPosition=function(t,e){return t?{x:0,y:0}:this._dom.scrollPosition(e)},t.prototype.relativeRect=function(t,e,n){return s.eitherRect(this._dom.position(t,e),n)},t=o.__decorate([i.Injectable(),o.__metadata("design:paramtypes",[r.DOMService])],t)}();e.AlignService=a},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=n(2),i=n(3),r=n(8),s=n(9),a=["font-size","font-family","font-stretch","font-style","font-weight","line-height"],l=function(){function t(){}return t.prototype.addOffset=function(t,e){return{left:t.left+e.left,top:t.top+e.top}},t.prototype.addScroll=function(t,e){return r.addScroll(t,e)},t.prototype.align=function(t){return r.align(t)},t.prototype.boundingOffset=function(t){return r.boundingOffset(this.nativeElement(t))},t.prototype.getFontStyles=function(t){var e=this.getWindow();if(!e||!t)return[];var n=e.getComputedStyle(this.nativeElement(t));return a.map(function(t){return{key:t,value:n[t]}})},t.prototype.getWindow=function(){return s.isWindowAvailable()?window:null},t.prototype.hasOffsetParent=function(t){return!!t&&!!this.nativeElement(t).offsetParent},t.prototype.offset=function(t){return t?r.offset(this.nativeElement(t)):null},t.prototype.offsetAtPoint=function(t,e){if(!t)return null;var n=this.nativeElement(t),o=n.style,i=o.left,s=o.top;n.style.left=e.left+"px",n.style.top=e.top+"px";var a=r.offset(n);return n.style.left=i,n.style.top=s,a},t.prototype.nativeElement=function(t){return t?t.nativeElement||t:null},t.prototype.position=function(t,e){return t&&e?r.positionWithScroll(this.nativeElement(t),this.nativeElement(e)):null},t.prototype.removeScroll=function(t,e){return r.removeScroll(t,e)},t.prototype.restrictToView=function(t){return r.restrictToView(t)},t.prototype.scrollPosition=function(t){return r.scrollPosition(this.nativeElement(t))},t.prototype.scrollableParents=function(t){return s.scrollableParents(this.nativeElement(t))},t.prototype.stackingElementOffset=function(t){var e=this.getRelativeContextElement(t);return e?r.offset(e):null},t.prototype.stackingElementScroll=function(t){var e=this.getRelativeContextElement(t);return e?{x:e.scrollLeft,y:e.scrollTop}:{x:0,y:0}},t.prototype.getRelativeContextElement=function(t){if(!t||!s.HAS_RELATIVE_STACKING_CONTEXT)return null;for(var e=this.nativeElement(t).parentElement;e;){if("none"!==window.getComputedStyle(e).transform)return e;e=e.parentElement}return null},t.prototype.useRelativePosition=function(t){return!!this.getRelativeContextElement(t)},t.prototype.windowViewPort=function(t){return r.getWindowViewPort(this.nativeElement(t))},t.prototype.zIndex=function(t,e){return s.zIndex(this.nativeElement(t),this.nativeElement(e))},t.prototype.zoomLevel=function(){return s.isDocumentAvailable()&&s.isWindowAvailable()?parseFloat((document.documentElement.clientWidth/window.innerWidth).toFixed(2))||1:1},t.prototype.isZoomed=function(){return this.zoomLevel()>1},t=o.__decorate([i.Injectable()],t)}();e.DOMService=l},function(t,e){"use strict";function n(t,e){return{top:t.top+e.y,left:t.left+e.x,height:t.height,width:t.width}}function o(t,e,n){var o=t.top,i=t.left;return n&&(i=0,o=0),{top:o+e.top,left:i+e.left,height:t.height,width:t.width}}function i(t){var e=u(t),n=g(t);return{x:n.pageXOffset||e.scrollLeft||0,y:n.pageYOffset||e.scrollTop||0}}function r(t){var e=f(t);return e?y(e):{x:0,y:0}}function s(t,e){return{top:t.top-e.y,left:t.left-e.x,height:t.height,width:t.width}}function a(t){var e=g(t);return{height:e.innerHeight,width:e.innerWidth}}Object.defineProperty(e,"__esModule",{value:!0});var l={bottom:"bottom",center:"center",middle:"middle",left:"left",right:"right",top:"top"},c=function(t){var e=t.anchorRect,n=t.anchorAlign,o=t.elementRect,i=t.elementAlign,r=n.horizontal,s=n.vertical,a=i.horizontal,c=i.vertical,p=e.top,u=e.left;return s===l.bottom&&(p+=e.height),s!==l.center&&s!==l.middle||(p+=Math.round(e.height/2)),c===l.bottom&&(p-=o.height),c!==l.center&&c!==l.middle||(p-=Math.round(o.height/2)),r===l.right&&(u+=e.width),r!==l.center&&r!==l.middle||(u+=Math.round(e.width/2)),a===l.right&&(u-=o.width),a!==l.center&&a!==l.middle||(u-=Math.round(o.width/2)),{top:p,left:u}},p=function(t){if(!t.getBoundingClientRect)return{bottom:t.innerHeight,left:0,right:t.innerWidth,top:0};var e=t.getBoundingClientRect(),n=e.bottom,o=e.left,i=e.right,r=e.top;return{bottom:n,left:o,right:i,top:r}},u=function(t){return t.ownerDocument.documentElement},f=function(t){for(var e=t.offsetParent;e&&"static"===e.style.position;)e=e.offsetParent;return e||u(t)},d=function(t){return f(t)===t.ownerDocument.body},h=function(t){var e=t.style,n=e.display,o=e.left,i=e.position;t.style.display="",t.style.left="-10000px",t.style.position="absolute";var r=t.getBoundingClientRect();return t.style.display=n,t.style.left=o,t.style.position=i,r},m=function(t){var e=t.getBoundingClientRect(),n=e.left,o=e.top;return e.height||e.width||(e=h(t)),{top:o,left:n,height:e.height,width:e.width}},v=function(t,e){for(var n=[],o=t.parentNode;o&&(n.push(o),o!==e);)o=o.parentNode;return n},g=function(t){return t.ownerDocument.defaultView},y=function(t){return t===(t.ownerDocument||{}).body?i(t):{x:t.scrollLeft,y:t.scrollTop}},b=function(t,e){var n=g(t),o=n.getComputedStyle(t),i=m(t),r=e||f(t),s=t.ownerDocument,a=r!==s.body&&r!==s.documentElement,l={top:0,left:0};if("fixed"!==o.position&&a){var c=n.getComputedStyle(r);l=m(r),l.top+=parseInt(c.borderTopWidth,10),l.left+=parseInt(c.borderLeftWidth,10)}return{top:i.top-l.top-parseInt(o.marginTop,10),left:i.left-l.left-parseInt(o.marginLeft,10),height:i.height,width:i.width}},_=function(t,e){return t?y(t):r(e)},w=function(t,e){var n=e?f(e):null,o=b(t,n),i=o.top,r=o.left,s=o.height,a=o.width,l=_(n,t),c=l.x,p=l.y;return{top:i+p,left:r+c,height:s,width:a}},S={fit:"fit",flip:"flip"},P=function(t,e,n){var o=0;return t+e>n&&(o=n-(t+e)),t<0&&(o=-t),o},E=function(t){var e=t.offset,n=t.size,o=t.anchorSize,i=t.viewPortSize,r=t.anchorAlignPoint,s=t.elementAlignPoint,a=0,c=s===l.center||s===l.middle,p=r===l.center||r===l.middle;return s!==r&&!c&&!p&&e>-1&&(e+n>i&&(a+=-(o+n)),e+a<0&&(a+=o+n)),a},O=function(t){var e=t.anchorRect,n=t.anchorAlign,o=t.elementRect,i=t.elementAlign,r=t.collisions,s=t.viewPort,a=o.top,l=o.left,c=o.height,p=o.width,u=s.height,f=s.width,d=0,h=0,m=r.horizontal===S.flip,v=r.vertical===S.flip;return r.vertical===S.fit&&(h+=P(a,c,u)),r.horizontal===S.fit&&(d+=P(l,p,f)),v&&(h+=E({offset:a,size:c,anchorSize:e.height,viewPortSize:u,anchorAlignPoint:n.vertical,elementAlignPoint:i.vertical})),m&&(d+=E({offset:l,size:p,anchorSize:e.width,viewPortSize:f,anchorAlignPoint:n.horizontal,elementAlignPoint:i.horizontal})),{flipped:m&&0!==d||v&&0!==h,offset:{left:d,top:h}}},C=function(t){for(var e=[],n=t.parentNode.firstElementChild;n;)n!==t&&e.push(n),n=n.nextElementSibling;return e},A=function(t,e){for(var n,o,i=v(t),r=e;r&&(n=C(r),!(o=i.reduce(function(t,e){return t.concat(n.filter(function(t){return t===e}))},[])[0]));)r=r.parentElement;return o};e.align=c,e.addScroll=n,e.applyLocationOffset=o,e.boundingOffset=p,e.isBodyOffset=d,e.offsetParent=f,e.offset=m,e.parents=v,e.parentScrollPosition=r,e.position=b,e.positionWithScroll=w,e.removeScroll=s,e.restrictToView=O,e.scrollPosition=i,e.siblingContainer=A,e.siblings=C,e.getDocumentElement=u,e.getWindow=g,e.getWindowViewPort=a,e.AlignPoint=l,e.Collision=S},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=n(8);e.eitherRect=function(t,e){return t?t:{height:0,left:e.left,top:e.top,width:0}},e.replaceOffset=function(t,e){if(!e)return t;var n={height:t.height,left:e.left,top:e.top,width:t.width};return n},e.removeStackingOffset=function(t,e){if(!e)return t;var n={height:t.height,left:t.left-e.left,top:t.top-e.top,width:t.width};return n},e.isDifferentOffset=function(t,e){var n=t.left,o=t.top,i=e.left,r=e.top;return Math.abs(n-i)>=1||Math.abs(o-r)>=1},e.isDocumentAvailable=function(){return"undefined"!=typeof document&&!!document.body},e.isWindowAvailable=function(){return"undefined"!=typeof window},e.hasBoundingRect=function(t){return!!t.getBoundingClientRect},e.OVERFLOW_REGEXP=/auto|scroll/;var i=function(t){return""+t.style.overflow+t.style.overflowX+t.style.overflowY},r=function(t){var e=window.getComputedStyle(t);return""+e.overflow+e.overflowX+e.overflowY},s=function(t){return i(t)||r(t)};e.scrollableParents=function(t){var n=[];if(!e.isDocumentAvailable()||!e.isWindowAvailable())return n;for(var o=t.parentElement;o;)e.OVERFLOW_REGEXP.test(s(o))&&n.push(o),o=o.parentElement;return n.push(window),n},e.FRAME_DURATION=1e3/60,e.hasRelativeStackingContext=function(){if(!e.isDocumentAvailable())return!1;var t=10,n=document.createElement("div");n.style.transform="matrix(10, 0, 0, 10, 0, 0)",n.innerHTML='<div style="position: fixed; top: '+t+'px;">child</div>',document.body.appendChild(n);var o=n.children[0].getBoundingClientRect().top!==t;return document.body.removeChild(n),o},e.HAS_RELATIVE_STACKING_CONTEXT=e.hasRelativeStackingContext(),e.zIndex=function(t,n){if(!t||!e.isDocumentAvailable()||!e.isWindowAvailable())return null;var i=o.siblingContainer(t,n);if(!i)return null;var r=[t].concat(o.parents(t,i)).reduce(function(t,e){var n=e.style.zIndex||window.getComputedStyle(e).zIndex,o=parseInt(n,10);return o>t?o:t},0);return r?r+1:null}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=n(2),i=n(3),r=n(7),s=n(9),a=function(){function t(t){this._dom=t}return t.prototype.positionElement=function(t){var e=t.anchor,n=t.currentLocation,o=t.element,i=t.anchorAlign,r=t.elementAlign,a=t.collisions,l=this._dom,c=l.restrictToView({anchorAlign:i,anchorRect:s.eitherRect(l.offset(e),n),collisions:a,elementAlign:r,elementRect:l.offsetAtPoint(o,n),viewPort:t.viewPort||l.windowViewPort(o)});return{flipped:c.flipped,offset:l.addOffset(n,c.offset)}},t=o.__decorate([i.Injectable(),o.__metadata("design:paramtypes",[r.DOMService])],t)}();e.PositionService=a},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=n(2),i=n(3),r=n(12),s=n(13),a=n(9),l=n(7),c=function(){function t(t,e){this._dom=t,this._zone=e}return t.prototype.subscribe=function(t){var e=this;a.isDocumentAvailable()&&this._zone.runOutsideAngular(function(){e.subscription=r.fromEvent(e._dom.getWindow(),"resize").pipe(s.auditTime(a.FRAME_DURATION)).subscribe(function(){return t()})})},t.prototype.unsubscribe=function(){this.subscription&&this.subscription.unsubscribe()},t.prototype.isUnsubscribed=function(){return this.subscription&&this.subscription.closed},t=o.__decorate([i.Injectable(),o.__metadata("design:paramtypes",[l.DOMService,i.NgZone])],t)}();e.ResizeService=c},function(t,e){t.exports=o},function(t,e){t.exports=i},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=n(2),i=n(3),r=n(12),s=n(15),a=n(13),l=n(7),c=n(9);e.THRESHOLD_DIFF=1;var p=function(){function t(t,e){this._dom=t,this._zone=e}return t.prototype.forElement=function(t){return this.unsubscribe(),this.element=t,this},t.prototype.subscribe=function(t){var e=this;if(t&&c.isDocumentAvailable()&&this.element){var n=this._dom.nativeElement(this.element),o=this._dom.scrollableParents(this.element);this._zone.runOutsideAngular(function(){var i=o.map(function(t){return r.fromEvent(t,"scroll").pipe(a.auditTime(c.FRAME_DURATION))}),l=function(o){t(e.isVisible(n,o.target))};e.subscription=s.merge.apply(void 0,i).subscribe(l)})}},t.prototype.unsubscribe=function(){this.subscription&&this.subscription.unsubscribe()},t.prototype.isVisible=function(t,n){var o=this._dom.boundingOffset(t),i=this._dom.boundingOffset(n);return!(i.top-o.bottom>e.THRESHOLD_DIFF)&&(!(i.bottom-o.bottom<-e.THRESHOLD_DIFF)&&(!(i.right-o.right<-e.THRESHOLD_DIFF)&&!(i.left-o.left>e.THRESHOLD_DIFF)))},t=o.__decorate([i.Injectable(),o.__metadata("design:paramtypes",[l.DOMService,i.NgZone])],t)}();e.ScrollableService=p},function(t,e){t.exports=r},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=n(2),i=n(3),r=n(17),s=n(4),a=n(1),l=[s.PopupComponent],c=function(){function t(){}return t=o.__decorate([i.NgModule({declarations:[l],entryComponents:[l],exports:[l],imports:[r.CommonModule],providers:[a.PopupService]})],t)}();e.PopupModule=c},function(t,e){t.exports=s}])});
!function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e(require("tslib"),require("@angular/core"),require("rxjs/observable/fromPromise"),require("rxjs/observable/fromEvent"),require("rxjs/operators/auditTime"),require("rxjs/observable/merge"),require("@angular/animations"),require("@angular/common")):"function"==typeof define&&define.amd?define(["tslib","@angular/core","rxjs/observable/fromPromise","rxjs/observable/fromEvent","rxjs/operators/auditTime","rxjs/observable/merge","@angular/animations","@angular/common"],e):"object"==typeof exports?exports.KendoAngularPopup=e(require("tslib"),require("@angular/core"),require("rxjs/observable/fromPromise"),require("rxjs/observable/fromEvent"),require("rxjs/operators/auditTime"),require("rxjs/observable/merge"),require("@angular/animations"),require("@angular/common")):t.KendoAngularPopup=e(t.tslib,t["@angular/core"],t["rxjs/observable/fromPromise"],t["rxjs/observable/fromEvent"],t["rxjs/operators/auditTime"],t["rxjs/observable/merge"],t["@angular/animations"],t["@angular/common"])}(this,function(t,e,n,o,i,r,s,a){return function(t){function e(o){if(n[o])return n[o].exports;var i=n[o]={exports:{},id:o,loaded:!1};return t[o].call(i.exports,i,i.exports,e),i.loaded=!0,i.exports}var n={};return e.m=t,e.c=n,e.p="",e(0)}([function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=n(1);e.PopupService=o.PopupService,e.POPUP_CONTAINER=o.POPUP_CONTAINER;var i=n(4);e.PopupComponent=i.PopupComponent;var r=n(18);e.PopupModule=r.PopupModule},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=n(2),i=n(3),r=n(4);e.POPUP_CONTAINER=new i.InjectionToken("Popup Container");var s=function(){function t(t,e,n,o){this.applicationRef=t,this.componentFactoryResolver=e,this.injector=n,this.container=o}return Object.defineProperty(t.prototype,"rootViewContainer",{get:function(){var t=this.applicationRef.components||[];if(t[0])return t[0];throw new Error("\n View Container not found! Inject the POPUP_CONTAINER or define a specific ViewContainerRef via the appendTo option.\n See http://www.telerik.com/kendo-angular-ui/components/popup/api/POPUP_CONTAINER/ for more details.\n ")},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"rootViewContainerNode",{get:function(){return this.container?this.container.nativeElement:this.getComponentRootNode(this.rootViewContainer)},enumerable:!0,configurable:!0}),t.prototype.open=function(t){void 0===t&&(t={});var e=this.contentFrom(t.content),n=e.component,o=e.nodes,i=this.appendPopup(o,t.appendTo),r=i.instance;return this.projectComponentInputs(i,t),i.changeDetectorRef.detectChanges(),n&&n.changeDetectorRef.detectChanges(),{close:function(){n?n.destroy():(i.instance.content=null,i.changeDetectorRef.detectChanges()),i.destroy()},content:n,popup:i,popupAnchorViewportLeave:r.anchorViewportLeave,popupClose:r.close,popupElement:this.getComponentRootNode(i),popupOpen:r.open}},t.prototype.appendPopup=function(t,e){var n=this.createComponent(r.PopupComponent,t,e);return e||this.rootViewContainerNode.appendChild(this.getComponentRootNode(n)),n},t.prototype.getComponentRootNode=function(t){return t.hostView.rootNodes[0]},t.prototype.getComponentFactory=function(t){return this.componentFactoryResolver.resolveComponentFactory(t)},t.prototype.createComponent=function(t,e,n){var o=this.getComponentFactory(t);if(n)return n.createComponent(o,void 0,this.injector,e);var i=o.create(this.injector,e);return this.applicationRef.attachView(i.hostView),i},t.prototype.projectComponentInputs=function(t,e){return Object.getOwnPropertyNames(e).filter(function(t){return"content"!==t||e.content instanceof i.TemplateRef}).map(function(n){t.instance[n]=e[n]}),t},t.prototype.contentFrom=function(t){if(!t||t instanceof i.TemplateRef)return{component:null,nodes:[[]]};var e=this.createComponent(t),n=e?[e.location.nativeElement]:[];return{component:e,nodes:[n]}},t=o.__decorate([i.Injectable(),o.__param(3,i.Inject(e.POPUP_CONTAINER)),o.__param(3,i.Optional()),o.__metadata("design:paramtypes",[i.ApplicationRef,i.ComponentFactoryResolver,i.Injector,i.ElementRef])],t)}();e.PopupService=s},function(e,n){e.exports=t},function(t,n){t.exports=e},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=n(2),i=n(3),r=n(5),s=n(6),a=n(7),l=n(10),c=n(11),p=n(14),u=n(16),f=n(9),d={left:-1e4,top:0},h="k-animation-container",m="k-animation-container-fixed",v=function(t){return t.observers.length>0},y=function(){function t(t,e,n,o,r,s,a,l,c){this.container=t,this._alignService=e,this.domService=n,this._positionService=o,this._resizeService=r,this._scrollableService=s,this.animationService=a,this._renderer=l,this._zone=c,this.animate=!0,this.anchorAlign={horizontal:"left",vertical:"bottom"},this.collision={horizontal:"fit",vertical:"flip"},this.popupAlign={horizontal:"left",vertical:"top"},this.copyAnchorStyles=!1,this.positionMode="fixed",this.offset=d,this.anchorViewportLeave=new i.EventEmitter,this.close=new i.EventEmitter,this.open=new i.EventEmitter,this.resolvedPromise=Promise.resolve(null),this._renderer.addClass(t.nativeElement,h),this.updateFixedClass()}return t.prototype.ngOnInit=function(){this.repositionCallback=this.reposition.bind(this),this._resizeService.subscribe(this.repositionCallback),this.animationSubscriptions=this.animationService.start.subscribe(this.onAnimationStart.bind(this)).add(this.animationService.end.subscribe(this.onAnimationEnd.bind(this))),this._scrollableService.forElement(this.anchor||this.container).subscribe(this.onScroll.bind(this)),this.currentOffset=d,this.setZIndex(),this.copyFontStyles(),this.updateFixedClass()},t.prototype.ngOnChanges=function(t){t.copyAnchorStyles&&this.copyFontStyles(),t.positionMode&&this.updateFixedClass()},t.prototype.ngAfterViewChecked=function(){var t=this;this._zone.runOutsideAngular(function(){t.repositionSubscription&&t.repositionSubscription.unsubscribe(),t.repositionSubscription=r.fromPromise(t.resolvedPromise).subscribe(t.repositionCallback)})},t.prototype.ngOnDestroy=function(){this.anchorViewportLeave.complete(),this.close.emit(),this.close.complete(),this._resizeService.unsubscribe(),this._scrollableService.unsubscribe(),this.repositionSubscription&&this.repositionSubscription.unsubscribe(),this.animationSubscriptions.unsubscribe()},t.prototype.onAnimationStart=function(){this._renderer.removeClass(this.container.nativeElement,"k-animation-container-shown")},t.prototype.onAnimationEnd=function(){this._renderer.addClass(this.container.nativeElement,"k-animation-container-shown"),this.open.emit(),this.open.complete()},Object.defineProperty(t.prototype,"currentOffset",{get:function(){return this._currentOffset},set:function(t){this._currentOffset&&!f.isDifferentOffset(this._currentOffset,t)||(this.setContainerStyle("left",t.left+"px"),this.setContainerStyle("top",t.top+"px"),this._currentOffset=t)},enumerable:!0,configurable:!0}),t.prototype.setZIndex=function(){this.anchor&&this.setContainerStyle("z-index",String(this.domService.zIndex(this.anchor,this.container)))},t.prototype.reposition=function(){if(f.isDocumentAvailable()){var t=this.position(),e=t.flip,n=t.offset;this.currentOffset=n,this.animationService.play(this.contentContainer.nativeElement,this.animate,e)}},t.prototype.position=function(){var t=this._alignService.alignElement({anchor:this.anchor,anchorAlign:this.anchorAlign,element:this.container,elementAlign:this.popupAlign,offset:this.offset,positionMode:this.positionMode});return this._positionService.positionElement({anchor:this.anchor,anchorAlign:this.anchorAlign,collisions:this.collision,currentLocation:t,element:this.container,elementAlign:this.popupAlign})},t.prototype.onScroll=function(t){var e=this,n=v(this.anchorViewportLeave);t||!n?this.reposition():n&&this._zone.run(function(){e.anchorViewportLeave.emit()})},t.prototype.copyFontStyles=function(){var t=this;this.anchor&&this.copyAnchorStyles&&this.domService.getFontStyles(this.anchor).forEach(function(e){return t.setContainerStyle(e.key,e.value)})},t.prototype.updateFixedClass=function(){var t="fixed"===this.positionMode?"addClass":"removeClass";this._renderer[t](this.container.nativeElement,m)},t.prototype.setContainerStyle=function(t,e){this._renderer.setStyle(this.container.nativeElement,t,e)},o.__decorate([i.Input(),o.__metadata("design:type",Object)],t.prototype,"animate",void 0),o.__decorate([i.Input(),o.__metadata("design:type",i.ElementRef)],t.prototype,"anchor",void 0),o.__decorate([i.Input(),o.__metadata("design:type",Object)],t.prototype,"anchorAlign",void 0),o.__decorate([i.Input(),o.__metadata("design:type",Object)],t.prototype,"collision",void 0),o.__decorate([i.Input(),o.__metadata("design:type",Object)],t.prototype,"popupAlign",void 0),o.__decorate([i.Input(),o.__metadata("design:type",Boolean)],t.prototype,"copyAnchorStyles",void 0),o.__decorate([i.Input(),o.__metadata("design:type",Object)],t.prototype,"popupClass",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"positionMode",void 0),o.__decorate([i.Input(),o.__metadata("design:type",Object)],t.prototype,"offset",void 0),o.__decorate([i.Output(),o.__metadata("design:type",i.EventEmitter)],t.prototype,"anchorViewportLeave",void 0),o.__decorate([i.Output(),o.__metadata("design:type",i.EventEmitter)],t.prototype,"close",void 0),o.__decorate([i.Output(),o.__metadata("design:type",i.EventEmitter)],t.prototype,"open",void 0),o.__decorate([i.ViewChild("container"),o.__metadata("design:type",i.ElementRef)],t.prototype,"contentContainer",void 0),t=o.__decorate([i.Component({exportAs:"kendo-popup",providers:[s.AlignService,u.AnimationService,a.DOMService,l.PositionService,c.ResizeService,p.ScrollableService],selector:"kendo-popup",template:'\n <div class="k-popup" [ngClass]="popupClass" #container>\n <ng-content></ng-content>\n <ng-template [ngTemplateOutlet]="content" [ngIf]="content"></ng-template>\n </div>\n '}),o.__metadata("design:paramtypes",[i.ElementRef,s.AlignService,a.DOMService,l.PositionService,c.ResizeService,p.ScrollableService,u.AnimationService,i.Renderer2,i.NgZone])],t)}();e.PopupComponent=y},function(t,e){t.exports=n},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=n(2),i=n(3),r=n(7),s=n(9),a=function(){function t(t){this._dom=t}return t.prototype.alignElement=function(t){var e=t.anchor,n=t.element,o=t.anchorAlign,i=t.elementAlign,r=t.offset,s=t.positionMode,a="fixed"===s||!this._dom.hasOffsetParent(n),l=a?this.absoluteRect(e,n,r):this.relativeRect(e,n,r);return this._dom.align({anchorAlign:o,anchorRect:l,elementAlign:i,elementRect:this._dom.offset(n)})},t.prototype.absoluteRect=function(t,e,n){return this._dom.removeScroll(this._dom.addScroll(s.removeStackingOffset(s.eitherRect(this._dom.offset(t),n),this._dom.stackingElementOffset(e)),this._dom.stackingElementScroll(e)),this.elementScrollPosition(t,e))},t.prototype.elementScrollPosition=function(t,e){return t?{x:0,y:0}:this._dom.scrollPosition(e)},t.prototype.relativeRect=function(t,e,n){return s.eitherRect(this._dom.position(t,e),n)},t=o.__decorate([i.Injectable(),o.__metadata("design:paramtypes",[r.DOMService])],t)}();e.AlignService=a},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=n(2),i=n(3),r=n(8),s=n(9),a=["font-size","font-family","font-stretch","font-style","font-weight","line-height"],l=function(){function t(){}return t.prototype.addOffset=function(t,e){return{left:t.left+e.left,top:t.top+e.top}},t.prototype.addScroll=function(t,e){return r.addScroll(t,e)},t.prototype.align=function(t){return r.align(t)},t.prototype.boundingOffset=function(t){return r.boundingOffset(this.nativeElement(t))},t.prototype.getFontStyles=function(t){var e=this.getWindow();if(!e||!t)return[];var n=e.getComputedStyle(this.nativeElement(t));return a.map(function(t){return{key:t,value:n[t]}})},t.prototype.getWindow=function(){return s.isWindowAvailable()?window:null},t.prototype.hasOffsetParent=function(t){return!!t&&!!this.nativeElement(t).offsetParent},t.prototype.offset=function(t){return t?r.offset(this.nativeElement(t)):null},t.prototype.offsetAtPoint=function(t,e){if(!t)return null;var n=this.nativeElement(t),o=n.style,i=o.left,s=o.top;n.style.left=e.left+"px",n.style.top=e.top+"px";var a=r.offset(n);return n.style.left=i,n.style.top=s,a},t.prototype.nativeElement=function(t){return t?t.nativeElement||t:null},t.prototype.position=function(t,e){return t&&e?r.positionWithScroll(this.nativeElement(t),this.nativeElement(e)):null},t.prototype.removeScroll=function(t,e){return r.removeScroll(t,e)},t.prototype.restrictToView=function(t){return r.restrictToView(t)},t.prototype.scrollPosition=function(t){return r.scrollPosition(this.nativeElement(t))},t.prototype.scrollableParents=function(t){return s.scrollableParents(this.nativeElement(t))},t.prototype.stackingElementOffset=function(t){var e=this.getRelativeContextElement(t);return e?r.offset(e):null},t.prototype.stackingElementScroll=function(t){var e=this.getRelativeContextElement(t);return e?{x:e.scrollLeft,y:e.scrollTop}:{x:0,y:0}},t.prototype.getRelativeContextElement=function(t){if(!t||!s.HAS_RELATIVE_STACKING_CONTEXT)return null;for(var e=this.nativeElement(t).parentElement;e;){if("none"!==window.getComputedStyle(e).transform)return e;e=e.parentElement}return null},t.prototype.useRelativePosition=function(t){return!!this.getRelativeContextElement(t)},t.prototype.windowViewPort=function(t){return r.getWindowViewPort(this.nativeElement(t))},t.prototype.zIndex=function(t,e){return s.zIndex(this.nativeElement(t),this.nativeElement(e))},t.prototype.zoomLevel=function(){return s.isDocumentAvailable()&&s.isWindowAvailable()?parseFloat((document.documentElement.clientWidth/window.innerWidth).toFixed(2))||1:1},t.prototype.isZoomed=function(){return this.zoomLevel()>1},t=o.__decorate([i.Injectable()],t)}();e.DOMService=l},function(t,e){"use strict";function n(t,e){return{top:t.top+e.y,left:t.left+e.x,height:t.height,width:t.width}}function o(t,e,n){var o=t.top,i=t.left;return n&&(i=0,o=0),{top:o+e.top,left:i+e.left,height:t.height,width:t.width}}function i(t){var e=u(t),n=y(t);return{x:n.pageXOffset||e.scrollLeft||0,y:n.pageYOffset||e.scrollTop||0}}function r(t){var e=f(t);return e?g(e):{x:0,y:0}}function s(t,e){return{top:t.top-e.y,left:t.left-e.x,height:t.height,width:t.width}}function a(t){var e=y(t);return{height:e.innerHeight,width:e.innerWidth}}Object.defineProperty(e,"__esModule",{value:!0});var l={bottom:"bottom",center:"center",middle:"middle",left:"left",right:"right",top:"top"},c=function(t){var e=t.anchorRect,n=t.anchorAlign,o=t.elementRect,i=t.elementAlign,r=n.horizontal,s=n.vertical,a=i.horizontal,c=i.vertical,p=e.top,u=e.left;return s===l.bottom&&(p+=e.height),s!==l.center&&s!==l.middle||(p+=Math.round(e.height/2)),c===l.bottom&&(p-=o.height),c!==l.center&&c!==l.middle||(p-=Math.round(o.height/2)),r===l.right&&(u+=e.width),r!==l.center&&r!==l.middle||(u+=Math.round(e.width/2)),a===l.right&&(u-=o.width),a!==l.center&&a!==l.middle||(u-=Math.round(o.width/2)),{top:p,left:u}},p=function(t){if(!t.getBoundingClientRect)return{bottom:t.innerHeight,left:0,right:t.innerWidth,top:0};var e=t.getBoundingClientRect(),n=e.bottom,o=e.left,i=e.right,r=e.top;return{bottom:n,left:o,right:i,top:r}},u=function(t){return t.ownerDocument.documentElement},f=function(t){for(var e=t.offsetParent;e&&"static"===e.style.position;)e=e.offsetParent;return e||u(t)},d=function(t){return f(t)===t.ownerDocument.body},h=function(t){var e=t.style,n=e.display,o=e.left,i=e.position;t.style.display="",t.style.left="-10000px",t.style.position="absolute";var r=t.getBoundingClientRect();return t.style.display=n,t.style.left=o,t.style.position=i,r},m=function(t){var e=t.getBoundingClientRect(),n=e.left,o=e.top;return e.height||e.width||(e=h(t)),{top:o,left:n,height:e.height,width:e.width}},v=function(t,e){for(var n=[],o=t.parentNode;o&&(n.push(o),o!==e);)o=o.parentNode;return n},y=function(t){return t.ownerDocument.defaultView},g=function(t){return t===(t.ownerDocument||{}).body?i(t):{x:t.scrollLeft,y:t.scrollTop}},b=function(t,e){var n=y(t),o=n.getComputedStyle(t),i=m(t),r=e||f(t),s=t.ownerDocument,a=r!==s.body&&r!==s.documentElement,l={top:0,left:0};if("fixed"!==o.position&&a){var c=n.getComputedStyle(r);l=m(r),l.top+=parseInt(c.borderTopWidth,10),l.left+=parseInt(c.borderLeftWidth,10)}return{top:i.top-l.top-parseInt(o.marginTop,10),left:i.left-l.left-parseInt(o.marginLeft,10),height:i.height,width:i.width}},_=function(t,e){return t?g(t):r(e)},S=function(t,e){var n=e?f(e):null,o=b(t,n),i=o.top,r=o.left,s=o.height,a=o.width,l=_(n,t),c=l.x,p=l.y;return{top:i+p,left:r+c,height:s,width:a}},w={fit:"fit",flip:"flip"},E=function(t,e,n){var o=0;return t+e>n&&(o=n-(t+e)),t<0&&(o=-t),o},P=function(t){var e=t.offset,n=t.size,o=t.anchorSize,i=t.viewPortSize,r=t.anchorAlignPoint,s=t.elementAlignPoint,a=0,c=s===l.center||s===l.middle,p=r===l.center||r===l.middle;return s!==r&&!c&&!p&&e>-1&&(e+n>i&&(a+=-(o+n)),e+a<0&&(a+=o+n)),a},O=function(t){var e=t.anchorRect,n=t.anchorAlign,o=t.elementRect,i=t.elementAlign,r=t.collisions,s=t.viewPort,a=o.top,l=o.left,c=o.height,p=o.width,u=s.height,f=s.width,d=0,h=0,m=r.horizontal===w.flip,v=r.vertical===w.flip;r.vertical===w.fit&&(h+=E(a,c,u)),r.horizontal===w.fit&&(d+=E(l,p,f)),v&&(h+=P({offset:a,size:c,anchorSize:e.height,viewPortSize:u,anchorAlignPoint:n.vertical,elementAlignPoint:i.vertical})),m&&(d+=P({offset:l,size:p,anchorSize:e.width,viewPortSize:f,anchorAlignPoint:n.horizontal,elementAlignPoint:i.horizontal}));var y=m&&0!==d,g=v&&0!==h;return{flipped:y||g,flip:{horizontal:y,vertical:g},offset:{left:d,top:h}}},C=function(t){for(var e=[],n=t.parentNode.firstElementChild;n;)n!==t&&e.push(n),n=n.nextElementSibling;return e},A=function(t,e){for(var n,o,i=v(t),r=e;r&&(n=C(r),!(o=i.reduce(function(t,e){return t.concat(n.filter(function(t){return t===e}))},[])[0]));)r=r.parentElement;return o};e.align=c,e.addScroll=n,e.applyLocationOffset=o,e.boundingOffset=p,e.isBodyOffset=d,e.offsetParent=f,e.offset=m,e.parents=v,e.parentScrollPosition=r,e.position=b,e.positionWithScroll=S,e.removeScroll=s,e.restrictToView=O,e.scrollPosition=i,e.siblingContainer=A,e.siblings=C,e.getDocumentElement=u,e.getWindow=y,e.getWindowViewPort=a,e.AlignPoint=l,e.Collision=w},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=n(8);e.eitherRect=function(t,e){return t?t:{height:0,left:e.left,top:e.top,width:0}},e.replaceOffset=function(t,e){if(!e)return t;var n={height:t.height,left:e.left,top:e.top,width:t.width};return n},e.removeStackingOffset=function(t,e){if(!e)return t;var n={height:t.height,left:t.left-e.left,top:t.top-e.top,width:t.width};return n},e.isDifferentOffset=function(t,e){var n=t.left,o=t.top,i=e.left,r=e.top;return Math.abs(n-i)>=1||Math.abs(o-r)>=1},e.isDocumentAvailable=function(){return"undefined"!=typeof document&&!!document.body},e.isWindowAvailable=function(){return"undefined"!=typeof window},e.hasBoundingRect=function(t){return!!t.getBoundingClientRect},e.OVERFLOW_REGEXP=/auto|scroll/;var i=function(t){return""+t.style.overflow+t.style.overflowX+t.style.overflowY},r=function(t){var e=window.getComputedStyle(t);return""+e.overflow+e.overflowX+e.overflowY},s=function(t){return i(t)||r(t)};e.scrollableParents=function(t){var n=[];if(!e.isDocumentAvailable()||!e.isWindowAvailable())return n;for(var o=t.parentElement;o;)e.OVERFLOW_REGEXP.test(s(o))&&n.push(o),o=o.parentElement;return n.push(window),n},e.FRAME_DURATION=1e3/60,e.hasRelativeStackingContext=function(){if(!e.isDocumentAvailable())return!1;var t=10,n=document.createElement("div");n.style.transform="matrix(10, 0, 0, 10, 0, 0)",n.innerHTML='<div style="position: fixed; top: '+t+'px;">child</div>',document.body.appendChild(n);var o=n.children[0].getBoundingClientRect().top!==t;return document.body.removeChild(n),o},e.HAS_RELATIVE_STACKING_CONTEXT=e.hasRelativeStackingContext(),e.zIndex=function(t,n){if(!t||!e.isDocumentAvailable()||!e.isWindowAvailable())return null;var i=o.siblingContainer(t,n);if(!i)return null;var r=[t].concat(o.parents(t,i)).reduce(function(t,e){var n=e.style.zIndex||window.getComputedStyle(e).zIndex,o=parseInt(n,10);return o>t?o:t},0);return r?r+1:null}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=n(2),i=n(3),r=n(7),s=n(9),a=function(){function t(t){this._dom=t}return t.prototype.positionElement=function(t){var e=t.anchor,n=t.currentLocation,o=t.element,i=t.anchorAlign,r=t.elementAlign,a=t.collisions,l=this._dom,c=l.restrictToView({anchorAlign:i,anchorRect:s.eitherRect(l.offset(e),n),collisions:a,elementAlign:r,elementRect:l.offsetAtPoint(o,n),viewPort:t.viewPort||l.windowViewPort(o)});return{flip:c.flip,flipped:c.flipped,offset:l.addOffset(n,c.offset)}},t=o.__decorate([i.Injectable(),o.__metadata("design:paramtypes",[r.DOMService])],t)}();e.PositionService=a},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=n(2),i=n(3),r=n(12),s=n(13),a=n(9),l=n(7),c=function(){function t(t,e){this._dom=t,this._zone=e}return t.prototype.subscribe=function(t){var e=this;a.isDocumentAvailable()&&this._zone.runOutsideAngular(function(){e.subscription=r.fromEvent(e._dom.getWindow(),"resize").pipe(s.auditTime(a.FRAME_DURATION)).subscribe(function(){return t()})})},t.prototype.unsubscribe=function(){this.subscription&&this.subscription.unsubscribe()},t.prototype.isUnsubscribed=function(){return this.subscription&&this.subscription.closed},t=o.__decorate([i.Injectable(),o.__metadata("design:paramtypes",[l.DOMService,i.NgZone])],t)}();e.ResizeService=c},function(t,e){t.exports=o},function(t,e){t.exports=i},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=n(2),i=n(3),r=n(12),s=n(15),a=n(13),l=n(7),c=n(9);e.THRESHOLD_DIFF=1;var p=function(){function t(t,e){this._dom=t,this._zone=e}return t.prototype.forElement=function(t){return this.unsubscribe(),this.element=t,this},t.prototype.subscribe=function(t){var e=this;if(t&&c.isDocumentAvailable()&&this.element){var n=this._dom.nativeElement(this.element),o=this._dom.scrollableParents(this.element);this._zone.runOutsideAngular(function(){var i=o.map(function(t){return r.fromEvent(t,"scroll").pipe(a.auditTime(c.FRAME_DURATION))}),l=function(o){t(e.isVisible(n,o.target))};e.subscription=s.merge.apply(void 0,i).subscribe(l)})}},t.prototype.unsubscribe=function(){this.subscription&&this.subscription.unsubscribe()},t.prototype.isVisible=function(t,n){var o=this._dom.boundingOffset(t),i=this._dom.boundingOffset(n);return!(i.top-o.bottom>e.THRESHOLD_DIFF)&&(!(i.bottom-o.bottom<-e.THRESHOLD_DIFF)&&(!(i.right-o.right<-e.THRESHOLD_DIFF)&&!(i.left-o.left>e.THRESHOLD_DIFF)))},t=o.__decorate([i.Injectable(),o.__metadata("design:paramtypes",[l.DOMService,i.NgZone])],t)}();e.ScrollableService=p},function(t,e){t.exports=r},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=n(2),i=n(3),r=n(17),s="left",a="right",l="down",c="up",p="slide",u=100,f={};f.expand=function(t){var e,n=t===c||t===l?"scaleY":"scaleX",o=0,i=1;return e=t===l?"top":t===s?a:t===a?s:"bottom",{start:{transform:n+"("+o+")",transformOrigin:e},end:{transform:n+"("+i+")"}}},f.slide=function(t){var e=t===s||t===a?"translateX":"translateY",n=t===a||t===l?-100:100,o=0;return{start:{transform:e+"("+n+"%)"},end:{transform:e+"("+o+"%)"}}},f.fade=function(){return{start:{opacity:0},end:{opacity:1}}},f.zoom=function(){var t=0,e=1;return{start:{transform:"scale("+t+")"},end:{transform:"scale("+e+")"}}};var d=function(){function t(t){this.animationBuilder=t,this.start=new i.EventEmitter,this.end=new i.EventEmitter}return t.prototype.play=function(t,e,n){if(!this.flip||this.flip.horizontal!==n.horizontal||this.flip.vertical!==n.vertical){if(this.flip=n,!e)return void this.end.emit();var o=e.type||p,r=f[o];if(r){var s=this.getDirection(n,e),a=r(s);this.playStates(t,a,e)}else if(i.isDevMode())throw new Error('Unsupported animation type: "'+o+'". The supported types are slide, expand, fade and zoom.')}},t.prototype.ngOnDestroy=function(){this.stopPlayer()},t.prototype.playStates=function(t,e,n){var o=this;this.stopPlayer();var i=n.duration||u,s=this.animationBuilder.build([r.style(e.start),r.animate(i+"ms ease-in",r.style(e.end))]),a=this.player=s.create(t);a.onDone(function(){o.end.emit(),o.stopPlayer()}),this.start.emit(),a.play()},t.prototype.getDirection=function(t,e){var n=e.direction||l;return t.horizontal&&(n===s?n=a:n===a&&(n=s)),t.vertical&&(n===l?n=c:n===c&&(n=l)),n},t.prototype.stopPlayer=function(){this.player&&(this.player.destroy(),this.player=null)},t=o.__decorate([i.Injectable(),o.__metadata("design:paramtypes",[r.AnimationBuilder])],t)}();e.AnimationService=d},function(t,e){t.exports=s},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=n(2),i=n(3),r=n(19),s=n(4),a=n(1),l=[s.PopupComponent],c=function(){function t(){}return t=o.__decorate([i.NgModule({declarations:[l],entryComponents:[l],exports:[l],imports:[r.CommonModule],providers:[a.PopupService]})],t)}();e.PopupModule=c},function(t,e){t.exports=a}])});

@@ -6,5 +6,6 @@ /**

export { AlignService as ɵa } from './services/align.service';
export { AnimationService as ɵc } from './services/animation.service';
export { DOMService as ɵb } from './services/dom.service';
export { PositionService as ɵc } from './services/position.service';
export { ResizeService as ɵd } from './services/resize.service';
export { ScrollableService as ɵe } from './services/scrollable.service';
export { PositionService as ɵd } from './services/position.service';
export { ResizeService as ɵe } from './services/resize.service';
export { ScrollableService as ɵf } from './services/scrollable.service';
/**
* Type defining all possible position modes of the Popup.
* The type which defines all possible position modes of the Popup.
*/

@@ -1,2 +0,2 @@

import { ChangeDetectorRef, Component, ElementRef, EventEmitter, Input, Output, NgZone, Renderer2, trigger, style, transition, animate } from '@angular/core';
import { Component, ElementRef, EventEmitter, Input, Output, NgZone, Renderer2, ViewChild } from '@angular/core';
import { fromPromise } from 'rxjs/observable/fromPromise';

@@ -8,2 +8,3 @@ import { AlignService } from './services/align.service';

import { ScrollableService } from './services/scrollable.service';
import { AnimationService } from './services/animation.service';
import { isDifferentOffset, isDocumentAvailable } from './util';

@@ -13,2 +14,3 @@ var DEFAULT_OFFSET = { left: -10000, top: 0 };

var ANIMATION_CONTAINER_FIXED = 'k-animation-container-fixed';
var hasObservers = function (emitter) { return emitter.observers.length > 0; };
/**

@@ -34,10 +36,10 @@ * Represents the Kendo UI Popup component for Angular.

var PopupComponent = /** @class */ (function () {
function PopupComponent(container, _alignService, domService, _cdr, _positionService, _resizeService, _scrollableService, _renderer, _zone) {
function PopupComponent(container, _alignService, domService, _positionService, _resizeService, _scrollableService, animationService, _renderer, _zone) {
this.container = container;
this._alignService = _alignService;
this.domService = domService;
this._cdr = _cdr;
this._positionService = _positionService;
this._resizeService = _resizeService;
this._scrollableService = _scrollableService;
this.animationService = animationService;
this._renderer = _renderer;

@@ -48,4 +50,4 @@ this._zone = _zone;

*
* For more information about how to enable and disable them,
* refer to the section on [Popup animations]({% slug overview_popup %}#toc-animations).
* For more information about controlling the Popup animations,
* refer to the article on [animations]({% slug animations_popup %}).
*/

@@ -57,3 +59,3 @@ this.animate = true;

* For more information, refer to the section on
* [positioning]({% slug overview_popup %}#toc-position).
* [positioning]({% slug alignmentpositioning_popup %}#toc-positioning).
*/

@@ -64,4 +66,4 @@ this.anchorAlign = { horizontal: 'left', vertical: 'bottom' };

*
* For more information, refer to the section on
* [viewport boundary detection]({% slug overview_popup %}#toc-viewport-boundary-detection).
* For more information, refer to the article on
* [viewport boundary detection]({% slug viewportboundarydetection_popup %}).
*/

@@ -73,14 +75,16 @@ this.collision = { horizontal: 'fit', vertical: 'flip' };

* For more information, refer to the section on
* [positioning]({% slug overview_popup %}#toc-position).
* [positioning]({% slug alignmentpositioning_popup %}#toc-positioning).
*/
this.popupAlign = { horizontal: 'left', vertical: 'top' };
/**
* Controls whether the component should copy anchor styles.
* Controls whether the component will copy the `anchor` font styles.
*/
this.copyAnchorStyles = false;
/**
* Specifies the position mode of the component. By default the Popup uses *fixed* mode.
* Set the option to `absolute` to use an *absolute* positioning.
* Specifies the position mode of the component.
* By default, the Popup uses fixed positioning.
* To make the Popup acquire absolute positioning, set this option to `absolute`.
*
* > Use the 'absolute' positioning if mobile browsers with zoom support is targeted.
* > If you need to support mobile browsers with the zoom option,
* use the `absolute` positioning of the Popup.
*

@@ -184,3 +188,3 @@ * @example

* For more information, refer to the section on
* [aligning to specific absolute points]({% slug overview_popup %}#toc-align-to-absolute-points).
* [aligning to specific absolute points]({% slug alignmentpositioning_popup %}#toc-aligning-to-absolute-points).
*/

@@ -192,3 +196,3 @@ this.offset = DEFAULT_OFFSET;

* For more information, refer to the section on
* [closing the Popup after leaving the viewport]({% slug overview_popup %}#toc-closing-after-leaving-the-viewport).
* [closing the Popup after leaving the viewport]({% slug closing_popup %}#toc-after-leaving-the-viewport).
*/

@@ -204,6 +208,2 @@ this.anchorViewportLeave = new EventEmitter();

this.open = new EventEmitter();
/**
* @hidden
*/
this.direction = 'down';
this.resolvedPromise = Promise.resolve(null);

@@ -216,2 +216,4 @@ this._renderer.addClass(container.nativeElement, ANIMATION_CONTAINER);

this._resizeService.subscribe(this.repositionCallback);
this.animationSubscriptions = this.animationService.start.subscribe(this.onAnimationStart.bind(this))
.add(this.animationService.end.subscribe(this.onAnimationEnd.bind(this)));
this._scrollableService.forElement(this.anchor || this.container).subscribe(this.onScroll.bind(this));

@@ -231,6 +233,2 @@ this.currentOffset = DEFAULT_OFFSET;

};
PopupComponent.prototype.ngAfterViewInit = function () {
// positions the popup before the initial animation starts.
this.reposition();
};
PopupComponent.prototype.ngAfterViewChecked = function () {

@@ -258,7 +256,8 @@ var _this = this;

}
this.animationSubscriptions.unsubscribe();
};
/**
* @hidden
*/
PopupComponent.prototype.triggerOpen = function (_event) {
PopupComponent.prototype.onAnimationStart = function () {
this._renderer.removeClass(this.container.nativeElement, 'k-animation-container-shown');
};
PopupComponent.prototype.onAnimationEnd = function () {
this._renderer.addClass(this.container.nativeElement, 'k-animation-container-shown');

@@ -291,9 +290,5 @@ this.open.emit();

}
var _a = this.position(), flipped = _a.flipped, offset = _a.offset;
var newDirection = this.getDirection(flipped);
var _a = this.position(), flip = _a.flip, offset = _a.offset;
this.currentOffset = offset;
if (this.direction !== newDirection) {
this.direction = newDirection;
this._cdr.detectChanges();
}
this.animationService.play(this.contentContainer.nativeElement, this.animate, flip);
};

@@ -318,12 +313,9 @@ PopupComponent.prototype.position = function () {

};
PopupComponent.prototype.getDirection = function (flipped) {
return this.animate ? (flipped ? 'up' : 'down') : 'none';
};
PopupComponent.prototype.onScroll = function (isInViewPort) {
var _this = this;
var hasObservers = this.anchorViewportLeave.observers.length;
if (isInViewPort || !hasObservers) {
var hasLeaveObservers = hasObservers(this.anchorViewportLeave);
if (isInViewPort || !hasLeaveObservers) {
this.reposition();
}
else if (hasObservers) {
else if (hasLeaveObservers) {
this._zone.run(function () {

@@ -351,26 +343,6 @@ _this.anchorViewportLeave.emit();

{ type: Component, args: [{
animations: [
trigger('toggle', [
transition('void => down, up => down', [
style({ transform: 'translateY(-100%)' }),
animate('0.1s ease-in', style({ transform: 'translateY(0)' }))
]),
transition('down => void', [
style({ transform: 'translateY(0)' }),
animate('0.1s ease-in', style({ transform: 'translateY(-100%)' }))
]),
transition('void => up, down => up', [
style({ transform: 'translateY(100%)' }),
animate('0.1s ease-in', style({ transform: 'translateY(0)' }))
]),
transition('up => void', [
style({ transform: 'translateY(0)' }),
animate('0.1s ease-in', style({ transform: 'translateY(100%)' }))
])
])
],
exportAs: 'kendo-popup',
providers: [AlignService, DOMService, PositionService, ResizeService, ScrollableService],
providers: [AlignService, AnimationService, DOMService, PositionService, ResizeService, ScrollableService],
selector: 'kendo-popup',
template: "\n <div class=\"k-popup\" [ngClass]=\"popupClass\" [@toggle]=\"direction\" (@toggle.done)=\"triggerOpen($event)\">\n <ng-content></ng-content>\n <ng-template [ngTemplateOutlet]=\"content\" [ngIf]=\"content\"></ng-template>\n </div>\n "
template: "\n <div class=\"k-popup\" [ngClass]=\"popupClass\" #container>\n <ng-content></ng-content>\n <ng-template [ngTemplateOutlet]=\"content\" [ngIf]=\"content\"></ng-template>\n </div>\n "
},] },

@@ -383,6 +355,6 @@ ];

{ type: DOMService, },
{ type: ChangeDetectorRef, },
{ type: PositionService, },
{ type: ResizeService, },
{ type: ScrollableService, },
{ type: AnimationService, },
{ type: Renderer2, },

@@ -404,2 +376,3 @@ { type: NgZone, },

'open': [{ type: Output },],
'contentContainer': [{ type: ViewChild, args: ['container',] },],
};

@@ -406,0 +379,0 @@ return PopupComponent;

@@ -7,3 +7,3 @@ import { ApplicationRef, ComponentFactoryResolver, ElementRef, InjectionToken, Injectable, Injector, Inject, Optional, TemplateRef } from '@angular/core';

*
* > The POPUP_CONTAINER can be used only with the [PopupService]({% slug service_popup %}) class.
* > The `POPUP_CONTAINER` can be used only with the [`PopupService`]({% slug service_popup %}) class.
*

@@ -91,3 +91,2 @@ * @example

* Opens a Popup component.
*
* Created Popups are mounted in the DOM directly in the root application component.

@@ -94,0 +93,0 @@ *

@@ -23,2 +23,3 @@ import { Injectable } from '@angular/core';

return {
flip: result.flip,
flipped: result.flipped,

@@ -25,0 +26,0 @@ offset: dom.addOffset(currentLocation, result.offset)

@@ -6,5 +6,6 @@ /**

export { AlignService as ɵa } from './services/align.service';
export { AnimationService as ɵc } from './services/animation.service';
export { DOMService as ɵb } from './services/dom.service';
export { PositionService as ɵc } from './services/position.service';
export { ResizeService as ɵd } from './services/resize.service';
export { ScrollableService as ɵe } from './services/scrollable.service';
export { PositionService as ɵd } from './services/position.service';
export { ResizeService as ɵe } from './services/resize.service';
export { ScrollableService as ɵf } from './services/scrollable.service';

@@ -6,5 +6,6 @@ /**

export { AlignService as ɵa } from './services/align.service';
export { AnimationService as ɵc } from './services/animation.service';
export { DOMService as ɵb } from './services/dom.service';
export { PositionService as ɵc } from './services/position.service';
export { ResizeService as ɵd } from './services/resize.service';
export { ScrollableService as ɵe } from './services/scrollable.service';
export { PositionService as ɵd } from './services/position.service';
export { ResizeService as ɵe } from './services/resize.service';
export { ScrollableService as ɵf } from './services/scrollable.service';

@@ -1,1 +0,1 @@

{"__symbolic":"module","version":3,"metadata":{"Align":{"__symbolic":"interface"},"Collision":{"__symbolic":"interface"},"Offset":{"__symbolic":"interface"},"PopupSettings":{"__symbolic":"interface"},"PopupRef":{"__symbolic":"interface"},"PositionMode":{"__symbolic":"interface"},"PopupService":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Injectable"}}],"members":{"__ctor__":[{"__symbolic":"constructor","parameterDecorators":[null,null,null,[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Inject"},"arguments":[{"__symbolic":"reference","name":"POPUP_CONTAINER"}]},{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Optional"}}]],"parameters":[{"__symbolic":"reference","module":"@angular/core","name":"ApplicationRef"},{"__symbolic":"reference","module":"@angular/core","name":"ComponentFactoryResolver"},{"__symbolic":"reference","module":"@angular/core","name":"Injector"},{"__symbolic":"reference","module":"@angular/core","name":"ElementRef"}]}],"open":[{"__symbolic":"method"}],"appendPopup":[{"__symbolic":"method"}],"getComponentRootNode":[{"__symbolic":"method"}],"getComponentFactory":[{"__symbolic":"method"}],"createComponent":[{"__symbolic":"method"}],"projectComponentInputs":[{"__symbolic":"method"}],"contentFrom":[{"__symbolic":"method"}]}},"POPUP_CONTAINER":{"__symbolic":"new","expression":{"__symbolic":"reference","module":"@angular/core","name":"InjectionToken"},"arguments":["Popup Container"]},"PopupComponent":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Component"},"arguments":[{"animations":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"trigger"},"arguments":["toggle",[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"transition"},"arguments":["void => down, up => down",[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"style"},"arguments":[{"transform":"translateY(-100%)"}]},{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"animate"},"arguments":["0.1s ease-in",{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"style"},"arguments":[{"transform":"translateY(0)"}]}]}]]},{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"transition"},"arguments":["down => void",[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"style"},"arguments":[{"transform":"translateY(0)"}]},{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"animate"},"arguments":["0.1s ease-in",{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"style"},"arguments":[{"transform":"translateY(-100%)"}]}]}]]},{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"transition"},"arguments":["void => up, down => up",[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"style"},"arguments":[{"transform":"translateY(100%)"}]},{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"animate"},"arguments":["0.1s ease-in",{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"style"},"arguments":[{"transform":"translateY(0)"}]}]}]]},{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"transition"},"arguments":["up => void",[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"style"},"arguments":[{"transform":"translateY(0)"}]},{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"animate"},"arguments":["0.1s ease-in",{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"style"},"arguments":[{"transform":"translateY(100%)"}]}]}]]}]]}],"exportAs":"kendo-popup","providers":[{"__symbolic":"reference","name":"ɵa"},{"__symbolic":"reference","name":"ɵb"},{"__symbolic":"reference","name":"ɵc"},{"__symbolic":"reference","name":"ɵd"},{"__symbolic":"reference","name":"ɵe"}],"selector":"kendo-popup","template":"\n <div class=\"k-popup\" [ngClass]=\"popupClass\" [@toggle]=\"direction\" (@toggle.done)=\"triggerOpen($event)\">\n <ng-content></ng-content>\n <ng-template [ngTemplateOutlet]=\"content\" [ngIf]=\"content\"></ng-template>\n </div>\n "}]}],"members":{"animate":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input"}}]}],"anchor":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input"}}]}],"anchorAlign":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input"}}]}],"collision":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input"}}]}],"popupAlign":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input"}}]}],"copyAnchorStyles":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input"}}]}],"popupClass":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input"}}]}],"positionMode":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input"}}]}],"offset":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input"}}]}],"anchorViewportLeave":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Output"}}]}],"close":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Output"}}]}],"open":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Output"}}]}],"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"reference","module":"@angular/core","name":"ElementRef"},{"__symbolic":"reference","name":"ɵa"},{"__symbolic":"reference","name":"ɵb"},{"__symbolic":"reference","module":"@angular/core","name":"ChangeDetectorRef"},{"__symbolic":"reference","name":"ɵc"},{"__symbolic":"reference","name":"ɵd"},{"__symbolic":"reference","name":"ɵe"},{"__symbolic":"reference","module":"@angular/core","name":"Renderer2"},{"__symbolic":"reference","module":"@angular/core","name":"NgZone"}]}],"ngOnInit":[{"__symbolic":"method"}],"ngOnChanges":[{"__symbolic":"method"}],"ngAfterViewInit":[{"__symbolic":"method"}],"ngAfterViewChecked":[{"__symbolic":"method"}],"ngOnDestroy":[{"__symbolic":"method"}],"triggerOpen":[{"__symbolic":"method"}],"setZIndex":[{"__symbolic":"method"}],"reposition":[{"__symbolic":"method"}],"position":[{"__symbolic":"method"}],"getDirection":[{"__symbolic":"method"}],"onScroll":[{"__symbolic":"method"}],"copyFontStyles":[{"__symbolic":"method"}],"updateFixedClass":[{"__symbolic":"method"}],"setContainerStyle":[{"__symbolic":"method"}]}},"PopupModule":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"NgModule"},"arguments":[{"declarations":[[{"__symbolic":"reference","name":"PopupComponent"}]],"entryComponents":[[{"__symbolic":"reference","name":"PopupComponent"}]],"exports":[[{"__symbolic":"reference","name":"PopupComponent"}]],"imports":[{"__symbolic":"reference","module":"@angular/common","name":"CommonModule"}],"providers":[{"__symbolic":"reference","name":"PopupService"}]}]}],"members":{}},"ɵa":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Injectable"}}],"members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"reference","name":"ɵb"}]}],"alignElement":[{"__symbolic":"method"}],"absoluteRect":[{"__symbolic":"method"}],"elementScrollPosition":[{"__symbolic":"method"}],"relativeRect":[{"__symbolic":"method"}]}},"ɵb":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Injectable"}}],"members":{"addOffset":[{"__symbolic":"method"}],"addScroll":[{"__symbolic":"method"}],"align":[{"__symbolic":"method"}],"boundingOffset":[{"__symbolic":"method"}],"getFontStyles":[{"__symbolic":"method"}],"getWindow":[{"__symbolic":"method"}],"hasOffsetParent":[{"__symbolic":"method"}],"offset":[{"__symbolic":"method"}],"offsetAtPoint":[{"__symbolic":"method"}],"nativeElement":[{"__symbolic":"method"}],"position":[{"__symbolic":"method"}],"removeScroll":[{"__symbolic":"method"}],"restrictToView":[{"__symbolic":"method"}],"scrollPosition":[{"__symbolic":"method"}],"scrollableParents":[{"__symbolic":"method"}],"stackingElementOffset":[{"__symbolic":"method"}],"stackingElementScroll":[{"__symbolic":"method"}],"getRelativeContextElement":[{"__symbolic":"method"}],"useRelativePosition":[{"__symbolic":"method"}],"windowViewPort":[{"__symbolic":"method"}],"zIndex":[{"__symbolic":"method"}],"zoomLevel":[{"__symbolic":"method"}],"isZoomed":[{"__symbolic":"method"}]}},"ɵc":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Injectable"}}],"members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"reference","name":"ɵb"}]}],"positionElement":[{"__symbolic":"method"}]}},"ɵd":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Injectable"}}],"members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"reference","name":"ɵb"},{"__symbolic":"reference","module":"@angular/core","name":"NgZone"}]}],"subscribe":[{"__symbolic":"method"}],"unsubscribe":[{"__symbolic":"method"}],"isUnsubscribed":[{"__symbolic":"method"}]}},"ɵe":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Injectable"}}],"members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"reference","name":"ɵb"},{"__symbolic":"reference","module":"@angular/core","name":"NgZone"}]}],"forElement":[{"__symbolic":"method"}],"subscribe":[{"__symbolic":"method"}],"unsubscribe":[{"__symbolic":"method"}],"isVisible":[{"__symbolic":"method"}]}}},"origins":{"Align":"./models/align.interface","Collision":"./models/collision.interface","Offset":"./models/offset.interface","PopupSettings":"./models/popup-settings","PopupRef":"./models/popup-ref","PositionMode":"./models/position-mode","PopupService":"./popup.service","POPUP_CONTAINER":"./popup.service","PopupComponent":"./popup.component","PopupModule":"./popup.module","ɵa":"./services/align.service","ɵb":"./services/dom.service","ɵc":"./services/position.service","ɵd":"./services/resize.service","ɵe":"./services/scrollable.service"},"importAs":"@progress/kendo-angular-popup"}
{"__symbolic":"module","version":3,"metadata":{"Align":{"__symbolic":"interface"},"Collision":{"__symbolic":"interface"},"Offset":{"__symbolic":"interface"},"PopupSettings":{"__symbolic":"interface"},"PopupRef":{"__symbolic":"interface"},"PositionMode":{"__symbolic":"interface"},"PopupAnimation":{"__symbolic":"interface"},"PopupService":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Injectable"}}],"members":{"__ctor__":[{"__symbolic":"constructor","parameterDecorators":[null,null,null,[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Inject"},"arguments":[{"__symbolic":"reference","name":"POPUP_CONTAINER"}]},{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Optional"}}]],"parameters":[{"__symbolic":"reference","module":"@angular/core","name":"ApplicationRef"},{"__symbolic":"reference","module":"@angular/core","name":"ComponentFactoryResolver"},{"__symbolic":"reference","module":"@angular/core","name":"Injector"},{"__symbolic":"reference","module":"@angular/core","name":"ElementRef"}]}],"open":[{"__symbolic":"method"}],"appendPopup":[{"__symbolic":"method"}],"getComponentRootNode":[{"__symbolic":"method"}],"getComponentFactory":[{"__symbolic":"method"}],"createComponent":[{"__symbolic":"method"}],"projectComponentInputs":[{"__symbolic":"method"}],"contentFrom":[{"__symbolic":"method"}]}},"POPUP_CONTAINER":{"__symbolic":"new","expression":{"__symbolic":"reference","module":"@angular/core","name":"InjectionToken"},"arguments":["Popup Container"]},"PopupComponent":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Component"},"arguments":[{"exportAs":"kendo-popup","providers":[{"__symbolic":"reference","name":"ɵa"},{"__symbolic":"reference","name":"ɵc"},{"__symbolic":"reference","name":"ɵb"},{"__symbolic":"reference","name":"ɵd"},{"__symbolic":"reference","name":"ɵe"},{"__symbolic":"reference","name":"ɵf"}],"selector":"kendo-popup","template":"\n <div class=\"k-popup\" [ngClass]=\"popupClass\" #container>\n <ng-content></ng-content>\n <ng-template [ngTemplateOutlet]=\"content\" [ngIf]=\"content\"></ng-template>\n </div>\n "}]}],"members":{"animate":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input"}}]}],"anchor":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input"}}]}],"anchorAlign":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input"}}]}],"collision":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input"}}]}],"popupAlign":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input"}}]}],"copyAnchorStyles":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input"}}]}],"popupClass":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input"}}]}],"positionMode":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input"}}]}],"offset":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input"}}]}],"anchorViewportLeave":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Output"}}]}],"close":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Output"}}]}],"open":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Output"}}]}],"contentContainer":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"ViewChild"},"arguments":["container"]}]}],"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"reference","module":"@angular/core","name":"ElementRef"},{"__symbolic":"reference","name":"ɵa"},{"__symbolic":"reference","name":"ɵb"},{"__symbolic":"reference","name":"ɵd"},{"__symbolic":"reference","name":"ɵe"},{"__symbolic":"reference","name":"ɵf"},{"__symbolic":"reference","name":"ɵc"},{"__symbolic":"reference","module":"@angular/core","name":"Renderer2"},{"__symbolic":"reference","module":"@angular/core","name":"NgZone"}]}],"ngOnInit":[{"__symbolic":"method"}],"ngOnChanges":[{"__symbolic":"method"}],"ngAfterViewChecked":[{"__symbolic":"method"}],"ngOnDestroy":[{"__symbolic":"method"}],"onAnimationStart":[{"__symbolic":"method"}],"onAnimationEnd":[{"__symbolic":"method"}],"setZIndex":[{"__symbolic":"method"}],"reposition":[{"__symbolic":"method"}],"position":[{"__symbolic":"method"}],"onScroll":[{"__symbolic":"method"}],"copyFontStyles":[{"__symbolic":"method"}],"updateFixedClass":[{"__symbolic":"method"}],"setContainerStyle":[{"__symbolic":"method"}]}},"PopupModule":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"NgModule"},"arguments":[{"declarations":[[{"__symbolic":"reference","name":"PopupComponent"}]],"entryComponents":[[{"__symbolic":"reference","name":"PopupComponent"}]],"exports":[[{"__symbolic":"reference","name":"PopupComponent"}]],"imports":[{"__symbolic":"reference","module":"@angular/common","name":"CommonModule"}],"providers":[{"__symbolic":"reference","name":"PopupService"}]}]}],"members":{}},"ɵa":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Injectable"}}],"members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"reference","name":"ɵb"}]}],"alignElement":[{"__symbolic":"method"}],"absoluteRect":[{"__symbolic":"method"}],"elementScrollPosition":[{"__symbolic":"method"}],"relativeRect":[{"__symbolic":"method"}]}},"ɵb":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Injectable"}}],"members":{"addOffset":[{"__symbolic":"method"}],"addScroll":[{"__symbolic":"method"}],"align":[{"__symbolic":"method"}],"boundingOffset":[{"__symbolic":"method"}],"getFontStyles":[{"__symbolic":"method"}],"getWindow":[{"__symbolic":"method"}],"hasOffsetParent":[{"__symbolic":"method"}],"offset":[{"__symbolic":"method"}],"offsetAtPoint":[{"__symbolic":"method"}],"nativeElement":[{"__symbolic":"method"}],"position":[{"__symbolic":"method"}],"removeScroll":[{"__symbolic":"method"}],"restrictToView":[{"__symbolic":"method"}],"scrollPosition":[{"__symbolic":"method"}],"scrollableParents":[{"__symbolic":"method"}],"stackingElementOffset":[{"__symbolic":"method"}],"stackingElementScroll":[{"__symbolic":"method"}],"getRelativeContextElement":[{"__symbolic":"method"}],"useRelativePosition":[{"__symbolic":"method"}],"windowViewPort":[{"__symbolic":"method"}],"zIndex":[{"__symbolic":"method"}],"zoomLevel":[{"__symbolic":"method"}],"isZoomed":[{"__symbolic":"method"}]}},"ɵc":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Injectable"}}],"members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"reference","module":"@angular/animations","name":"AnimationBuilder"}]}],"play":[{"__symbolic":"method"}],"ngOnDestroy":[{"__symbolic":"method"}],"playStates":[{"__symbolic":"method"}],"getDirection":[{"__symbolic":"method"}],"stopPlayer":[{"__symbolic":"method"}]}},"ɵd":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Injectable"}}],"members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"reference","name":"ɵb"}]}],"positionElement":[{"__symbolic":"method"}]}},"ɵe":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Injectable"}}],"members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"reference","name":"ɵb"},{"__symbolic":"reference","module":"@angular/core","name":"NgZone"}]}],"subscribe":[{"__symbolic":"method"}],"unsubscribe":[{"__symbolic":"method"}],"isUnsubscribed":[{"__symbolic":"method"}]}},"ɵf":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Injectable"}}],"members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"reference","name":"ɵb"},{"__symbolic":"reference","module":"@angular/core","name":"NgZone"}]}],"forElement":[{"__symbolic":"method"}],"subscribe":[{"__symbolic":"method"}],"unsubscribe":[{"__symbolic":"method"}],"isVisible":[{"__symbolic":"method"}]}}},"origins":{"Align":"./models/align.interface","Collision":"./models/collision.interface","Offset":"./models/offset.interface","PopupSettings":"./models/popup-settings","PopupRef":"./models/popup-ref","PositionMode":"./models/position-mode","PopupAnimation":"./models/popup-animation.interface","PopupService":"./popup.service","POPUP_CONTAINER":"./popup.service","PopupComponent":"./popup.component","PopupModule":"./popup.module","ɵa":"./services/align.service","ɵb":"./services/dom.service","ɵc":"./services/animation.service","ɵd":"./services/position.service","ɵe":"./services/resize.service","ɵf":"./services/scrollable.service"},"importAs":"@progress/kendo-angular-popup"}

@@ -7,4 +7,5 @@ export { Align } from './models/align.interface';

export { PositionMode } from './models/position-mode';
export { PopupAnimation } from './models/popup-animation.interface';
export { PopupService, POPUP_CONTAINER } from './popup.service';
export { PopupComponent } from './popup.component';
export { PopupModule } from './popup.module';

@@ -10,5 +10,5 @@ import { AlignStrategy } from '@progress/kendo-popup-common';

* The available options are:
* - `left`&mdash;Uses the leftmost point of the anchor element.
* - `center`&mdash;Uses the center point of the anchor element.
* - `right`&mdash;Uses the rightmost point of the anchor element.
* - `left`&mdash;Uses the leftmost point of the `anchor` element.
* - `center`&mdash;Uses the center point of the `anchor` element.
* - `right`&mdash;Uses the rightmost point of the `anchor` element.
*/

@@ -20,7 +20,7 @@ horizontal: 'left' | 'center' | 'right';

* The available options are:
* - `top`&mdash;Uses the top point of the anchor element.
* - `center`&mdash;Uses the center point of the anchor element.
* - `bottom`&mdash;Uses the bottom point of the anchor element.
* - `top`&mdash;Uses the top point of the `anchor` element.
* - `center`&mdash;Uses the center point of the `anchor` element.
* - `bottom`&mdash;Uses the bottom point of the `anchor` element.
*/
vertical: 'top' | 'center' | 'bottom';
}

@@ -5,5 +5,5 @@ /**

* The available options are:
* - `fit`&mdash;Moves the Popup horizontally until it is fully displayed in the view port.
* - `fit`&mdash;Moves the Popup horizontally until it is fully displayed in the viewport.
* - `flip`&mdash;Flips the Popup position based on the origin and the position properties.
*/
export declare type CollisionType = 'fit' | 'flip';

@@ -32,3 +32,3 @@ import { ComponentRef, EventEmitter } from '@angular/core';

* For more information, refer to the section on
* [closing the Popup after leaving the viewport]({% slug overview_popup %}#toc-closing-after-leaving-the-viewport).
* [closing the Popup after leaving the viewport]({% slug closing_popup %}#toc-after-leaving-the-viewport).
*/

@@ -35,0 +35,0 @@ popupAnchorViewportLeave: EventEmitter<any>;

@@ -16,4 +16,4 @@ import { ElementRef, TemplateRef, ViewContainerRef } from '@angular/core';

*
* For more information, refer to the section on
* [animation control]({% slug overview_popup %}#toc-animations).
* For more information, refer to the article on
* [animations]({% slug animations_popup %}).
*/

@@ -32,4 +32,4 @@ animate?: boolean;

*
* For more information, refer to the section on
* [positioning]({% slug overview_popup %}#toc-position).
* For more information, refer to the article on
* [aligning and positioning]({% slug alignmentpositioning_popup %}).
*/

@@ -44,11 +44,13 @@ anchorAlign?: Align;

*
* For more information, refer to the section on the
* [viewport boundary detection]({% slug overview_popup %}#toc-viewport-boundary-detection).
* For more information, refer to the article on the
* [viewport boundary detection]({% slug viewportboundarydetection_popup %}).
*/
collision?: Collision;
/**
* Specifies the position mode of the component. By default the popup uses a *fixed* positioning.
* Set the option to `absolute` to use an *absolute* positioning.
* Specifies the position mode of the component.
* By default, the Popup uses fixed positioning.
* To make the Popup acquire absolute positioning, set this option to `absolute`.
*
* > Use the 'absolute' positioning if mobile browsers with zoom should be supported.
* > If you need to support mobile browsers with the zoom option,
* use the `absolute` positioning of the Popup.
*/

@@ -59,4 +61,4 @@ positionMode?: PositionMode;

*
* For more information, refer to the section on
* [positioning]({% slug overview_popup %}#toc-position).
* For more information, refer to the article on
* [aligning and positioning]({% slug alignmentpositioning_popup %}).
*/

@@ -69,4 +71,4 @@ popupAlign?: Align;

*
* For more information, refer to the section on
* [styling]({% slug overview_popup %}#toc-styling).
* For more information, refer to the article on
* [appearance]({% slug appearance_popup %}).
*/

@@ -76,3 +78,2 @@ popupClass?: string | Array<string> | Object;

* Specifies the absolute position of the element. The Popup opens next to that point.
*
* The pivot point of the Popup is defined by the `popupAlign` configuration option.

@@ -82,5 +83,5 @@ * The boundary detection is applied by using the window viewport.

* For more information, refer to the section on
* [aligning to specific absolute points]({% slug overview_popup %}#toc-align-to-absolute-points).
* [aligning to specific absolute points]({% slug alignmentpositioning_popup %}#toc-aligning-to-absolute-points).
*/
offset?: Offset;
}
/**
* Type defining all possible position modes of the Popup.
* The type which defines all possible position modes of the Popup.
*/
export declare type PositionMode = 'absolute' | 'fixed';
/**
* Type defining all possible position modes of the Popup.
* The type which defines all possible position modes of the Popup.
*/

@@ -7,3 +7,4 @@ import { OffsetPosition } from '@progress/kendo-popup-common';

flipped: boolean;
flip: any;
offset: OffsetPosition;
}

@@ -1,2 +0,2 @@

import { AfterViewInit, AfterViewChecked, ChangeDetectorRef, ElementRef, EventEmitter, OnInit, OnChanges, OnDestroy, NgZone, Renderer2, TemplateRef } from '@angular/core';
import { AfterViewChecked, ElementRef, EventEmitter, OnInit, OnChanges, OnDestroy, NgZone, Renderer2, TemplateRef } from '@angular/core';
import { Align } from './models/align.interface';

@@ -6,2 +6,3 @@ import { Collision } from './models/collision.interface';

import { PositionMode } from './models/position-mode';
import { PopupAnimation } from './models/popup-animation.interface';
import { AlignService } from './services/align.service';

@@ -12,2 +13,3 @@ import { DOMService } from './services/dom.service';

import { ScrollableService } from './services/scrollable.service';
import { AnimationService } from './services/animation.service';
/**

@@ -32,10 +34,10 @@ * Represents the Kendo UI Popup component for Angular.

*/
export declare class PopupComponent implements AfterViewInit, AfterViewChecked, OnInit, OnChanges, OnDestroy {
export declare class PopupComponent implements AfterViewChecked, OnInit, OnChanges, OnDestroy {
container: ElementRef;
private _alignService;
domService: DOMService;
private _cdr;
private _positionService;
private _resizeService;
private _scrollableService;
private animationService;
private _renderer;

@@ -46,11 +48,11 @@ private _zone;

*
* For more information about how to enable and disable them,
* refer to the section on [Popup animations]({% slug overview_popup %}#toc-animations).
* For more information about controlling the Popup animations,
* refer to the article on [animations]({% slug animations_popup %}).
*/
animate: boolean;
animate: boolean | PopupAnimation;
/**
* Specifies the element that will be used as an anchor. The Popup opens next to that element.
*
* For more information, refer to the section on the
* [aligning to specific components]({% slug overview_popup %}#toc-align-to-components).
* For more information, refer to the section on
* [aligning to specific components]({% slug alignmentpositioning_popup %}#toc-aligning-to-components).
*/

@@ -62,3 +64,3 @@ anchor: ElementRef;

* For more information, refer to the section on
* [positioning]({% slug overview_popup %}#toc-position).
* [positioning]({% slug alignmentpositioning_popup %}#toc-positioning).
*/

@@ -69,4 +71,4 @@ anchorAlign: Align;

*
* For more information, refer to the section on
* [viewport boundary detection]({% slug overview_popup %}#toc-viewport-boundary-detection).
* For more information, refer to the article on
* [viewport boundary detection]({% slug viewportboundarydetection_popup %}).
*/

@@ -78,23 +80,25 @@ collision: Collision;

* For more information, refer to the section on
* [positioning]({% slug overview_popup %}#toc-position).
* [positioning]({% slug alignmentpositioning_popup %}#toc-positioning).
*/
popupAlign: Align;
/**
* Controls whether the component should copy anchor styles.
* Controls whether the component will copy the `anchor` font styles.
*/
copyAnchorStyles: boolean;
/**
* Specifies a list of CSS classes to be added to the internal animated element.
* Specifies a list of CSS classes that will be added to the internal animated element.
*
* > For styling the content of the Popup, use this property binding.
* > To style the content of the Popup, use this property binding.
*
* For more information, refer to the section on
* [styling]({% slug overview_popup %}#toc-styling).
* For more information, refer to the article on
* [styling]({% slug appearance_popup %}).
*/
popupClass: string | Array<string> | Object;
/**
* Specifies the position mode of the component. By default the Popup uses *fixed* mode.
* Set the option to `absolute` to use an *absolute* positioning.
* Specifies the position mode of the component.
* By default, the Popup uses fixed positioning.
* To make the Popup acquire absolute positioning, set this option to `absolute`.
*
* > Use the 'absolute' positioning if mobile browsers with zoom support is targeted.
* > If you need to support mobile browsers with the zoom option,
* use the `absolute` positioning of the Popup.
*

@@ -198,3 +202,3 @@ * @example

* For more information, refer to the section on
* [aligning to specific absolute points]({% slug overview_popup %}#toc-align-to-absolute-points).
* [aligning to specific absolute points]({% slug alignmentpositioning_popup %}#toc-aligning-to-absolute-points).
*/

@@ -206,3 +210,3 @@ offset: Offset;

* For more information, refer to the section on
* [closing the Popup after leaving the viewport]({% slug overview_popup %}#toc-closing-after-leaving-the-viewport).
* [closing the Popup after leaving the viewport]({% slug closing_popup %}#toc-after-leaving-the-viewport).
*/

@@ -221,7 +225,7 @@ anchorViewportLeave: EventEmitter<any>;

*/
content: TemplateRef<any>;
contentContainer: ElementRef;
/**
* @hidden
*/
direction: string;
content: TemplateRef<any>;
private resolvedPromise;

@@ -231,12 +235,10 @@ private repositionSubscription;

private _currentOffset;
constructor(container: ElementRef, _alignService: AlignService, domService: DOMService, _cdr: ChangeDetectorRef, _positionService: PositionService, _resizeService: ResizeService, _scrollableService: ScrollableService, _renderer: Renderer2, _zone: NgZone);
private animationSubscriptions;
constructor(container: ElementRef, _alignService: AlignService, domService: DOMService, _positionService: PositionService, _resizeService: ResizeService, _scrollableService: ScrollableService, animationService: AnimationService, _renderer: Renderer2, _zone: NgZone);
ngOnInit(): void;
ngOnChanges(changes: any): void;
ngAfterViewInit(): void;
ngAfterViewChecked(): void;
ngOnDestroy(): void;
/**
* @hidden
*/
triggerOpen(_event: any): void;
private onAnimationStart();
private onAnimationEnd();
private currentOffset;

@@ -246,3 +248,2 @@ private setZIndex();

private position();
private getDirection(flipped);
private onScroll(isInViewPort);

@@ -249,0 +250,0 @@ private copyFontStyles();

@@ -1,2 +0,2 @@

import { ChangeDetectorRef, Component, ElementRef, EventEmitter, Input, Output, NgZone, Renderer2, trigger, style, transition, animate } from '@angular/core';
import { Component, ElementRef, EventEmitter, Input, Output, NgZone, Renderer2, ViewChild } from '@angular/core';
import { fromPromise } from 'rxjs/observable/fromPromise';

@@ -8,2 +8,3 @@ import { AlignService } from './services/align.service';

import { ScrollableService } from './services/scrollable.service';
import { AnimationService } from './services/animation.service';
import { isDifferentOffset, isDocumentAvailable } from './util';

@@ -13,2 +14,3 @@ const DEFAULT_OFFSET = { left: -10000, top: 0 };

const ANIMATION_CONTAINER_FIXED = 'k-animation-container-fixed';
const hasObservers = (emitter) => emitter.observers.length > 0;
/**

@@ -34,10 +36,10 @@ * Represents the Kendo UI Popup component for Angular.

export class PopupComponent {
constructor(container, _alignService, domService, _cdr, _positionService, _resizeService, _scrollableService, _renderer, _zone) {
constructor(container, _alignService, domService, _positionService, _resizeService, _scrollableService, animationService, _renderer, _zone) {
this.container = container;
this._alignService = _alignService;
this.domService = domService;
this._cdr = _cdr;
this._positionService = _positionService;
this._resizeService = _resizeService;
this._scrollableService = _scrollableService;
this.animationService = animationService;
this._renderer = _renderer;

@@ -48,4 +50,4 @@ this._zone = _zone;

*
* For more information about how to enable and disable them,
* refer to the section on [Popup animations]({% slug overview_popup %}#toc-animations).
* For more information about controlling the Popup animations,
* refer to the article on [animations]({% slug animations_popup %}).
*/

@@ -57,3 +59,3 @@ this.animate = true;

* For more information, refer to the section on
* [positioning]({% slug overview_popup %}#toc-position).
* [positioning]({% slug alignmentpositioning_popup %}#toc-positioning).
*/

@@ -64,4 +66,4 @@ this.anchorAlign = { horizontal: 'left', vertical: 'bottom' };

*
* For more information, refer to the section on
* [viewport boundary detection]({% slug overview_popup %}#toc-viewport-boundary-detection).
* For more information, refer to the article on
* [viewport boundary detection]({% slug viewportboundarydetection_popup %}).
*/

@@ -73,14 +75,16 @@ this.collision = { horizontal: 'fit', vertical: 'flip' };

* For more information, refer to the section on
* [positioning]({% slug overview_popup %}#toc-position).
* [positioning]({% slug alignmentpositioning_popup %}#toc-positioning).
*/
this.popupAlign = { horizontal: 'left', vertical: 'top' };
/**
* Controls whether the component should copy anchor styles.
* Controls whether the component will copy the `anchor` font styles.
*/
this.copyAnchorStyles = false;
/**
* Specifies the position mode of the component. By default the Popup uses *fixed* mode.
* Set the option to `absolute` to use an *absolute* positioning.
* Specifies the position mode of the component.
* By default, the Popup uses fixed positioning.
* To make the Popup acquire absolute positioning, set this option to `absolute`.
*
* > Use the 'absolute' positioning if mobile browsers with zoom support is targeted.
* > If you need to support mobile browsers with the zoom option,
* use the `absolute` positioning of the Popup.
*

@@ -184,3 +188,3 @@ * @example

* For more information, refer to the section on
* [aligning to specific absolute points]({% slug overview_popup %}#toc-align-to-absolute-points).
* [aligning to specific absolute points]({% slug alignmentpositioning_popup %}#toc-aligning-to-absolute-points).
*/

@@ -192,3 +196,3 @@ this.offset = DEFAULT_OFFSET;

* For more information, refer to the section on
* [closing the Popup after leaving the viewport]({% slug overview_popup %}#toc-closing-after-leaving-the-viewport).
* [closing the Popup after leaving the viewport]({% slug closing_popup %}#toc-after-leaving-the-viewport).
*/

@@ -204,6 +208,2 @@ this.anchorViewportLeave = new EventEmitter();

this.open = new EventEmitter();
/**
* @hidden
*/
this.direction = 'down';
this.resolvedPromise = Promise.resolve(null);

@@ -216,2 +216,4 @@ this._renderer.addClass(container.nativeElement, ANIMATION_CONTAINER);

this._resizeService.subscribe(this.repositionCallback);
this.animationSubscriptions = this.animationService.start.subscribe(this.onAnimationStart.bind(this))
.add(this.animationService.end.subscribe(this.onAnimationEnd.bind(this)));
this._scrollableService.forElement(this.anchor || this.container).subscribe(this.onScroll.bind(this));

@@ -231,6 +233,2 @@ this.currentOffset = DEFAULT_OFFSET;

}
ngAfterViewInit() {
// positions the popup before the initial animation starts.
this.reposition();
}
ngAfterViewChecked() {

@@ -257,7 +255,8 @@ this._zone.runOutsideAngular(() => {

}
this.animationSubscriptions.unsubscribe();
}
/**
* @hidden
*/
triggerOpen(_event) {
onAnimationStart() {
this._renderer.removeClass(this.container.nativeElement, 'k-animation-container-shown');
}
onAnimationEnd() {
this._renderer.addClass(this.container.nativeElement, 'k-animation-container-shown');

@@ -286,9 +285,5 @@ this.open.emit();

}
const { flipped, offset } = this.position();
const newDirection = this.getDirection(flipped);
const { flip, offset } = this.position();
this.currentOffset = offset;
if (this.direction !== newDirection) {
this.direction = newDirection;
this._cdr.detectChanges();
}
this.animationService.play(this.contentContainer.nativeElement, this.animate, flip);
}

@@ -313,11 +308,8 @@ position() {

}
getDirection(flipped) {
return this.animate ? (flipped ? 'up' : 'down') : 'none';
}
onScroll(isInViewPort) {
const hasObservers = this.anchorViewportLeave.observers.length;
if (isInViewPort || !hasObservers) {
const hasLeaveObservers = hasObservers(this.anchorViewportLeave);
if (isInViewPort || !hasLeaveObservers) {
this.reposition();
}
else if (hasObservers) {
else if (hasLeaveObservers) {
this._zone.run(() => {

@@ -345,27 +337,7 @@ this.anchorViewportLeave.emit();

{ type: Component, args: [{
animations: [
trigger('toggle', [
transition('void => down, up => down', [
style({ transform: 'translateY(-100%)' }),
animate('0.1s ease-in', style({ transform: 'translateY(0)' }))
]),
transition('down => void', [
style({ transform: 'translateY(0)' }),
animate('0.1s ease-in', style({ transform: 'translateY(-100%)' }))
]),
transition('void => up, down => up', [
style({ transform: 'translateY(100%)' }),
animate('0.1s ease-in', style({ transform: 'translateY(0)' }))
]),
transition('up => void', [
style({ transform: 'translateY(0)' }),
animate('0.1s ease-in', style({ transform: 'translateY(100%)' }))
])
])
],
exportAs: 'kendo-popup',
providers: [AlignService, DOMService, PositionService, ResizeService, ScrollableService],
providers: [AlignService, AnimationService, DOMService, PositionService, ResizeService, ScrollableService],
selector: 'kendo-popup',
template: `
<div class="k-popup" [ngClass]="popupClass" [@toggle]="direction" (@toggle.done)="triggerOpen($event)">
<div class="k-popup" [ngClass]="popupClass" #container>
<ng-content></ng-content>

@@ -382,6 +354,6 @@ <ng-template [ngTemplateOutlet]="content" [ngIf]="content"></ng-template>

{ type: DOMService, },
{ type: ChangeDetectorRef, },
{ type: PositionService, },
{ type: ResizeService, },
{ type: ScrollableService, },
{ type: AnimationService, },
{ type: Renderer2, },

@@ -403,2 +375,3 @@ { type: NgZone, },

'open': [{ type: Output },],
'contentContainer': [{ type: ViewChild, args: ['container',] },],
};

@@ -8,3 +8,3 @@ import { ApplicationRef, ComponentFactoryResolver, ElementRef, InjectionToken, Injector } from '@angular/core';

*
* > The POPUP_CONTAINER can be used only with the [PopupService]({% slug service_popup %}) class.
* > The `POPUP_CONTAINER` can be used only with the [`PopupService`]({% slug service_popup %}) class.
*

@@ -74,3 +74,2 @@ * @example

* Opens a Popup component.
*
* Created Popups are mounted in the DOM directly in the root application component.

@@ -77,0 +76,0 @@ *

@@ -7,3 +7,3 @@ import { ApplicationRef, ComponentFactoryResolver, ElementRef, InjectionToken, Injectable, Injector, Inject, Optional, TemplateRef } from '@angular/core';

*
* > The POPUP_CONTAINER can be used only with the [PopupService]({% slug service_popup %}) class.
* > The `POPUP_CONTAINER` can be used only with the [`PopupService`]({% slug service_popup %}) class.
*

@@ -86,3 +86,2 @@ * @example

* Opens a Popup component.
*
* Created Popups are mounted in the DOM directly in the root application component.

@@ -89,0 +88,0 @@ *

@@ -23,2 +23,3 @@ import { Injectable } from '@angular/core';

return {
flip: result.flip,
flipped: result.flipped,

@@ -25,0 +26,0 @@ offset: dom.addOffset(currentLocation, result.offset)

@@ -10,9 +10,11 @@ "use strict";

exports.ɵa = align_service_1.AlignService;
var animation_service_1 = require("./services/animation.service");
exports.ɵc = animation_service_1.AnimationService;
var dom_service_1 = require("./services/dom.service");
exports.ɵb = dom_service_1.DOMService;
var position_service_1 = require("./services/position.service");
exports.ɵc = position_service_1.PositionService;
exports.ɵd = position_service_1.PositionService;
var resize_service_1 = require("./services/resize.service");
exports.ɵd = resize_service_1.ResizeService;
exports.ɵe = resize_service_1.ResizeService;
var scrollable_service_1 = require("./services/scrollable.service");
exports.ɵe = scrollable_service_1.ScrollableService;
exports.ɵf = scrollable_service_1.ScrollableService;

@@ -10,9 +10,11 @@ "use strict";

exports.ɵa = align_service_1.AlignService;
var animation_service_1 = require("./services/animation.service");
exports.ɵc = animation_service_1.AnimationService;
var dom_service_1 = require("./services/dom.service");
exports.ɵb = dom_service_1.DOMService;
var position_service_1 = require("./services/position.service");
exports.ɵc = position_service_1.PositionService;
exports.ɵd = position_service_1.PositionService;
var resize_service_1 = require("./services/resize.service");
exports.ɵd = resize_service_1.ResizeService;
exports.ɵe = resize_service_1.ResizeService;
var scrollable_service_1 = require("./services/scrollable.service");
exports.ɵe = scrollable_service_1.ScrollableService;
exports.ɵf = scrollable_service_1.ScrollableService;
"use strict";
/**
* Type defining all possible position modes of the Popup.
* The type which defines all possible position modes of the Popup.
*/
Object.defineProperty(exports, "__esModule", { value: true });

@@ -10,2 +10,3 @@ "use strict";

var scrollable_service_1 = require("./services/scrollable.service");
var animation_service_1 = require("./services/animation.service");
var util_1 = require("./util");

@@ -15,2 +16,3 @@ var DEFAULT_OFFSET = { left: -10000, top: 0 };

var ANIMATION_CONTAINER_FIXED = 'k-animation-container-fixed';
var hasObservers = function (emitter) { return emitter.observers.length > 0; };
/**

@@ -36,10 +38,10 @@ * Represents the Kendo UI Popup component for Angular.

var PopupComponent = /** @class */ (function () {
function PopupComponent(container, _alignService, domService, _cdr, _positionService, _resizeService, _scrollableService, _renderer, _zone) {
function PopupComponent(container, _alignService, domService, _positionService, _resizeService, _scrollableService, animationService, _renderer, _zone) {
this.container = container;
this._alignService = _alignService;
this.domService = domService;
this._cdr = _cdr;
this._positionService = _positionService;
this._resizeService = _resizeService;
this._scrollableService = _scrollableService;
this.animationService = animationService;
this._renderer = _renderer;

@@ -50,4 +52,4 @@ this._zone = _zone;

*
* For more information about how to enable and disable them,
* refer to the section on [Popup animations]({% slug overview_popup %}#toc-animations).
* For more information about controlling the Popup animations,
* refer to the article on [animations]({% slug animations_popup %}).
*/

@@ -59,3 +61,3 @@ this.animate = true;

* For more information, refer to the section on
* [positioning]({% slug overview_popup %}#toc-position).
* [positioning]({% slug alignmentpositioning_popup %}#toc-positioning).
*/

@@ -66,4 +68,4 @@ this.anchorAlign = { horizontal: 'left', vertical: 'bottom' };

*
* For more information, refer to the section on
* [viewport boundary detection]({% slug overview_popup %}#toc-viewport-boundary-detection).
* For more information, refer to the article on
* [viewport boundary detection]({% slug viewportboundarydetection_popup %}).
*/

@@ -75,14 +77,16 @@ this.collision = { horizontal: 'fit', vertical: 'flip' };

* For more information, refer to the section on
* [positioning]({% slug overview_popup %}#toc-position).
* [positioning]({% slug alignmentpositioning_popup %}#toc-positioning).
*/
this.popupAlign = { horizontal: 'left', vertical: 'top' };
/**
* Controls whether the component should copy anchor styles.
* Controls whether the component will copy the `anchor` font styles.
*/
this.copyAnchorStyles = false;
/**
* Specifies the position mode of the component. By default the Popup uses *fixed* mode.
* Set the option to `absolute` to use an *absolute* positioning.
* Specifies the position mode of the component.
* By default, the Popup uses fixed positioning.
* To make the Popup acquire absolute positioning, set this option to `absolute`.
*
* > Use the 'absolute' positioning if mobile browsers with zoom support is targeted.
* > If you need to support mobile browsers with the zoom option,
* use the `absolute` positioning of the Popup.
*

@@ -186,3 +190,3 @@ * @example

* For more information, refer to the section on
* [aligning to specific absolute points]({% slug overview_popup %}#toc-align-to-absolute-points).
* [aligning to specific absolute points]({% slug alignmentpositioning_popup %}#toc-aligning-to-absolute-points).
*/

@@ -194,3 +198,3 @@ this.offset = DEFAULT_OFFSET;

* For more information, refer to the section on
* [closing the Popup after leaving the viewport]({% slug overview_popup %}#toc-closing-after-leaving-the-viewport).
* [closing the Popup after leaving the viewport]({% slug closing_popup %}#toc-after-leaving-the-viewport).
*/

@@ -206,6 +210,2 @@ this.anchorViewportLeave = new core_1.EventEmitter();

this.open = new core_1.EventEmitter();
/**
* @hidden
*/
this.direction = 'down';
this.resolvedPromise = Promise.resolve(null);

@@ -218,2 +218,4 @@ this._renderer.addClass(container.nativeElement, ANIMATION_CONTAINER);

this._resizeService.subscribe(this.repositionCallback);
this.animationSubscriptions = this.animationService.start.subscribe(this.onAnimationStart.bind(this))
.add(this.animationService.end.subscribe(this.onAnimationEnd.bind(this)));
this._scrollableService.forElement(this.anchor || this.container).subscribe(this.onScroll.bind(this));

@@ -233,6 +235,2 @@ this.currentOffset = DEFAULT_OFFSET;

};
PopupComponent.prototype.ngAfterViewInit = function () {
// positions the popup before the initial animation starts.
this.reposition();
};
PopupComponent.prototype.ngAfterViewChecked = function () {

@@ -260,7 +258,8 @@ var _this = this;

}
this.animationSubscriptions.unsubscribe();
};
/**
* @hidden
*/
PopupComponent.prototype.triggerOpen = function (_event) {
PopupComponent.prototype.onAnimationStart = function () {
this._renderer.removeClass(this.container.nativeElement, 'k-animation-container-shown');
};
PopupComponent.prototype.onAnimationEnd = function () {
this._renderer.addClass(this.container.nativeElement, 'k-animation-container-shown');

@@ -293,9 +292,5 @@ this.open.emit();

}
var _a = this.position(), flipped = _a.flipped, offset = _a.offset;
var newDirection = this.getDirection(flipped);
var _a = this.position(), flip = _a.flip, offset = _a.offset;
this.currentOffset = offset;
if (this.direction !== newDirection) {
this.direction = newDirection;
this._cdr.detectChanges();
}
this.animationService.play(this.contentContainer.nativeElement, this.animate, flip);
};

@@ -320,12 +315,9 @@ PopupComponent.prototype.position = function () {

};
PopupComponent.prototype.getDirection = function (flipped) {
return this.animate ? (flipped ? 'up' : 'down') : 'none';
};
PopupComponent.prototype.onScroll = function (isInViewPort) {
var _this = this;
var hasObservers = this.anchorViewportLeave.observers.length;
if (isInViewPort || !hasObservers) {
var hasLeaveObservers = hasObservers(this.anchorViewportLeave);
if (isInViewPort || !hasLeaveObservers) {
this.reposition();
}
else if (hasObservers) {
else if (hasLeaveObservers) {
this._zone.run(function () {

@@ -353,26 +345,6 @@ _this.anchorViewportLeave.emit();

{ type: core_1.Component, args: [{
animations: [
core_1.trigger('toggle', [
core_1.transition('void => down, up => down', [
core_1.style({ transform: 'translateY(-100%)' }),
core_1.animate('0.1s ease-in', core_1.style({ transform: 'translateY(0)' }))
]),
core_1.transition('down => void', [
core_1.style({ transform: 'translateY(0)' }),
core_1.animate('0.1s ease-in', core_1.style({ transform: 'translateY(-100%)' }))
]),
core_1.transition('void => up, down => up', [
core_1.style({ transform: 'translateY(100%)' }),
core_1.animate('0.1s ease-in', core_1.style({ transform: 'translateY(0)' }))
]),
core_1.transition('up => void', [
core_1.style({ transform: 'translateY(0)' }),
core_1.animate('0.1s ease-in', core_1.style({ transform: 'translateY(100%)' }))
])
])
],
exportAs: 'kendo-popup',
providers: [align_service_1.AlignService, dom_service_1.DOMService, position_service_1.PositionService, resize_service_1.ResizeService, scrollable_service_1.ScrollableService],
providers: [align_service_1.AlignService, animation_service_1.AnimationService, dom_service_1.DOMService, position_service_1.PositionService, resize_service_1.ResizeService, scrollable_service_1.ScrollableService],
selector: 'kendo-popup',
template: "\n <div class=\"k-popup\" [ngClass]=\"popupClass\" [@toggle]=\"direction\" (@toggle.done)=\"triggerOpen($event)\">\n <ng-content></ng-content>\n <ng-template [ngTemplateOutlet]=\"content\" [ngIf]=\"content\"></ng-template>\n </div>\n "
template: "\n <div class=\"k-popup\" [ngClass]=\"popupClass\" #container>\n <ng-content></ng-content>\n <ng-template [ngTemplateOutlet]=\"content\" [ngIf]=\"content\"></ng-template>\n </div>\n "
},] },

@@ -385,6 +357,6 @@ ];

{ type: dom_service_1.DOMService, },
{ type: core_1.ChangeDetectorRef, },
{ type: position_service_1.PositionService, },
{ type: resize_service_1.ResizeService, },
{ type: scrollable_service_1.ScrollableService, },
{ type: animation_service_1.AnimationService, },
{ type: core_1.Renderer2, },

@@ -406,2 +378,3 @@ { type: core_1.NgZone, },

'open': [{ type: core_1.Output },],
'contentContainer': [{ type: core_1.ViewChild, args: ['container',] },],
};

@@ -408,0 +381,0 @@ return PopupComponent;

@@ -9,3 +9,3 @@ "use strict";

*
* > The POPUP_CONTAINER can be used only with the [PopupService]({% slug service_popup %}) class.
* > The `POPUP_CONTAINER` can be used only with the [`PopupService`]({% slug service_popup %}) class.
*

@@ -93,3 +93,2 @@ * @example

* Opens a Popup component.
*
* Created Popups are mounted in the DOM directly in the root application component.

@@ -96,0 +95,0 @@ *

@@ -25,2 +25,3 @@ "use strict";

return {
flip: result.flip,
flipped: result.flipped,

@@ -27,0 +28,0 @@ offset: dom.addOffset(currentLocation, result.offset)

@@ -1,1 +0,1 @@

System.register("@progress/kendo-angular-popup",["tslib","rxjs/observable/fromPromise","@angular/core","@angular/common","@progress/kendo-popup-common","rxjs/observable/fromEvent","rxjs/operators/auditTime","rxjs/observable/merge"],function(t){var e,n,o,i,r,s,a,c;function p(t){return t.__useDefault?t.default:t}return{setters:[function(t){e=p(t)},function(t){n=p(t)},function(t){o=p(t)},function(t){i=p(t)},function(t){r=p(t)},function(t){s=p(t)},function(t){a=p(t)},function(t){c=p(t)}],execute:function(){!function(t){var e={};function n(o){if(e[o])return e[o].exports;var i=e[o]={exports:{},id:o,loaded:!1};return t[o].call(i.exports,i,i.exports,n),i.loaded=!0,i.exports}n.m=t,n.c=e,n.p="",n(0)}([function(e,n,o){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var i=o(1);n.PopupService=i.PopupService,n.POPUP_CONTAINER=i.POPUP_CONTAINER;var r=o(4);n.PopupComponent=r.PopupComponent;var s=o(16);n.PopupModule=s.PopupModule,function(e){for(var n in e)t(n,e[n])}(n)},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=n(2),i=n(3),r=n(4);e.POPUP_CONTAINER=new i.InjectionToken("Popup Container");var s=function(){function t(t,e,n,o){this.applicationRef=t,this.componentFactoryResolver=e,this.injector=n,this.container=o}return Object.defineProperty(t.prototype,"rootViewContainer",{get:function(){var t=this.applicationRef.components||[];if(t[0])return t[0];throw new Error("\n View Container not found! Inject the POPUP_CONTAINER or define a specific ViewContainerRef via the appendTo option.\n See http://www.telerik.com/kendo-angular-ui/components/popup/api/POPUP_CONTAINER/ for more details.\n ")},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"rootViewContainerNode",{get:function(){return this.container?this.container.nativeElement:this.getComponentRootNode(this.rootViewContainer)},enumerable:!0,configurable:!0}),t.prototype.open=function(t){void 0===t&&(t={});var e=this.contentFrom(t.content),n=e.component,o=e.nodes,i=this.appendPopup(o,t.appendTo),r=i.instance;return this.projectComponentInputs(i,t),i.changeDetectorRef.detectChanges(),n&&n.changeDetectorRef.detectChanges(),{close:function(){n?n.destroy():(i.instance.content=null,i.changeDetectorRef.detectChanges()),i.destroy()},content:n,popup:i,popupAnchorViewportLeave:r.anchorViewportLeave,popupClose:r.close,popupElement:this.getComponentRootNode(i),popupOpen:r.open}},t.prototype.appendPopup=function(t,e){var n=this.createComponent(r.PopupComponent,t,e);return e||this.rootViewContainerNode.appendChild(this.getComponentRootNode(n)),n},t.prototype.getComponentRootNode=function(t){return t.hostView.rootNodes[0]},t.prototype.getComponentFactory=function(t){return this.componentFactoryResolver.resolveComponentFactory(t)},t.prototype.createComponent=function(t,e,n){var o=this.getComponentFactory(t);if(n)return n.createComponent(o,void 0,this.injector,e);var i=o.create(this.injector,e);return this.applicationRef.attachView(i.hostView),i},t.prototype.projectComponentInputs=function(t,e){return Object.getOwnPropertyNames(e).filter(function(t){return"content"!==t||e.content instanceof i.TemplateRef}).map(function(n){t.instance[n]=e[n]}),t},t.prototype.contentFrom=function(t){if(!t||t instanceof i.TemplateRef)return{component:null,nodes:[[]]};var e=this.createComponent(t);return{component:e,nodes:[e?[e.location.nativeElement]:[]]}},t=o.__decorate([i.Injectable(),o.__param(3,i.Inject(e.POPUP_CONTAINER)),o.__param(3,i.Optional()),o.__metadata("design:paramtypes",[i.ApplicationRef,i.ComponentFactoryResolver,i.Injector,i.ElementRef])],t)}();e.PopupService=s},function(t,n){t.exports=e},function(t,e){t.exports=o},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=n(2),i=n(3),r=n(5),s=n(6),a=n(7),c=n(10),p=n(11),l=n(14),u=n(9),f={left:-1e4,top:0},d="k-animation-container",h=function(){function t(t,e,n,o,r,s,a,c,p){this.container=t,this._alignService=e,this.domService=n,this._cdr=o,this._positionService=r,this._resizeService=s,this._scrollableService=a,this._renderer=c,this._zone=p,this.animate=!0,this.anchorAlign={horizontal:"left",vertical:"bottom"},this.collision={horizontal:"fit",vertical:"flip"},this.popupAlign={horizontal:"left",vertical:"top"},this.copyAnchorStyles=!1,this.positionMode="fixed",this.offset=f,this.anchorViewportLeave=new i.EventEmitter,this.close=new i.EventEmitter,this.open=new i.EventEmitter,this.direction="down",this.resolvedPromise=Promise.resolve(null),this._renderer.addClass(t.nativeElement,d),this.updateFixedClass()}return t.prototype.ngOnInit=function(){this.repositionCallback=this.reposition.bind(this),this._resizeService.subscribe(this.repositionCallback),this._scrollableService.forElement(this.anchor||this.container).subscribe(this.onScroll.bind(this)),this.currentOffset=f,this.setZIndex(),this.copyFontStyles(),this.updateFixedClass()},t.prototype.ngOnChanges=function(t){t.copyAnchorStyles&&this.copyFontStyles(),t.positionMode&&this.updateFixedClass()},t.prototype.ngAfterViewInit=function(){this.reposition()},t.prototype.ngAfterViewChecked=function(){var t=this;this._zone.runOutsideAngular(function(){t.repositionSubscription&&t.repositionSubscription.unsubscribe(),t.repositionSubscription=r.fromPromise(t.resolvedPromise).subscribe(t.repositionCallback)})},t.prototype.ngOnDestroy=function(){this.anchorViewportLeave.complete(),this.close.emit(),this.close.complete(),this._resizeService.unsubscribe(),this._scrollableService.unsubscribe(),this.repositionSubscription&&this.repositionSubscription.unsubscribe()},t.prototype.triggerOpen=function(t){this._renderer.addClass(this.container.nativeElement,"k-animation-container-shown"),this.open.emit(),this.open.complete()},Object.defineProperty(t.prototype,"currentOffset",{get:function(){return this._currentOffset},set:function(t){this._currentOffset&&!u.isDifferentOffset(this._currentOffset,t)||(this.setContainerStyle("left",t.left+"px"),this.setContainerStyle("top",t.top+"px"),this._currentOffset=t)},enumerable:!0,configurable:!0}),t.prototype.setZIndex=function(){this.anchor&&this.setContainerStyle("z-index",String(this.domService.zIndex(this.anchor,this.container)))},t.prototype.reposition=function(){if(u.isDocumentAvailable()){var t=this.position(),e=t.flipped,n=t.offset,o=this.getDirection(e);this.currentOffset=n,this.direction!==o&&(this.direction=o,this._cdr.detectChanges())}},t.prototype.position=function(){var t=this._alignService.alignElement({anchor:this.anchor,anchorAlign:this.anchorAlign,element:this.container,elementAlign:this.popupAlign,offset:this.offset,positionMode:this.positionMode});return this._positionService.positionElement({anchor:this.anchor,anchorAlign:this.anchorAlign,collisions:this.collision,currentLocation:t,element:this.container,elementAlign:this.popupAlign})},t.prototype.getDirection=function(t){return this.animate?t?"up":"down":"none"},t.prototype.onScroll=function(t){var e=this,n=this.anchorViewportLeave.observers.length;t||!n?this.reposition():n&&this._zone.run(function(){e.anchorViewportLeave.emit()})},t.prototype.copyFontStyles=function(){var t=this;this.anchor&&this.copyAnchorStyles&&this.domService.getFontStyles(this.anchor).forEach(function(e){return t.setContainerStyle(e.key,e.value)})},t.prototype.updateFixedClass=function(){var t="fixed"===this.positionMode?"addClass":"removeClass";this._renderer[t](this.container.nativeElement,"k-animation-container-fixed")},t.prototype.setContainerStyle=function(t,e){this._renderer.setStyle(this.container.nativeElement,t,e)},o.__decorate([i.Input(),o.__metadata("design:type",Boolean)],t.prototype,"animate",void 0),o.__decorate([i.Input(),o.__metadata("design:type",i.ElementRef)],t.prototype,"anchor",void 0),o.__decorate([i.Input(),o.__metadata("design:type",Object)],t.prototype,"anchorAlign",void 0),o.__decorate([i.Input(),o.__metadata("design:type",Object)],t.prototype,"collision",void 0),o.__decorate([i.Input(),o.__metadata("design:type",Object)],t.prototype,"popupAlign",void 0),o.__decorate([i.Input(),o.__metadata("design:type",Boolean)],t.prototype,"copyAnchorStyles",void 0),o.__decorate([i.Input(),o.__metadata("design:type",Object)],t.prototype,"popupClass",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"positionMode",void 0),o.__decorate([i.Input(),o.__metadata("design:type",Object)],t.prototype,"offset",void 0),o.__decorate([i.Output(),o.__metadata("design:type",i.EventEmitter)],t.prototype,"anchorViewportLeave",void 0),o.__decorate([i.Output(),o.__metadata("design:type",i.EventEmitter)],t.prototype,"close",void 0),o.__decorate([i.Output(),o.__metadata("design:type",i.EventEmitter)],t.prototype,"open",void 0),t=o.__decorate([i.Component({animations:[i.trigger("toggle",[i.transition("void => down, up => down",[i.style({transform:"translateY(-100%)"}),i.animate("0.1s ease-in",i.style({transform:"translateY(0)"}))]),i.transition("down => void",[i.style({transform:"translateY(0)"}),i.animate("0.1s ease-in",i.style({transform:"translateY(-100%)"}))]),i.transition("void => up, down => up",[i.style({transform:"translateY(100%)"}),i.animate("0.1s ease-in",i.style({transform:"translateY(0)"}))]),i.transition("up => void",[i.style({transform:"translateY(0)"}),i.animate("0.1s ease-in",i.style({transform:"translateY(100%)"}))])])],exportAs:"kendo-popup",providers:[s.AlignService,a.DOMService,c.PositionService,p.ResizeService,l.ScrollableService],selector:"kendo-popup",template:'\n <div class="k-popup" [ngClass]="popupClass" [@toggle]="direction" (@toggle.done)="triggerOpen($event)">\n <ng-content></ng-content>\n <ng-template [ngTemplateOutlet]="content" [ngIf]="content"></ng-template>\n </div>\n '}),o.__metadata("design:paramtypes",[i.ElementRef,s.AlignService,a.DOMService,i.ChangeDetectorRef,c.PositionService,p.ResizeService,l.ScrollableService,i.Renderer2,i.NgZone])],t)}();e.PopupComponent=h},function(t,e){t.exports=n},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=n(2),i=n(3),r=n(7),s=n(9),a=function(){function t(t){this._dom=t}return t.prototype.alignElement=function(t){var e=t.anchor,n=t.element,o=t.anchorAlign,i=t.elementAlign,r=t.offset,s="fixed"===t.positionMode||!this._dom.hasOffsetParent(n)?this.absoluteRect(e,n,r):this.relativeRect(e,n,r);return this._dom.align({anchorAlign:o,anchorRect:s,elementAlign:i,elementRect:this._dom.offset(n)})},t.prototype.absoluteRect=function(t,e,n){return this._dom.removeScroll(this._dom.addScroll(s.removeStackingOffset(s.eitherRect(this._dom.offset(t),n),this._dom.stackingElementOffset(e)),this._dom.stackingElementScroll(e)),this.elementScrollPosition(t,e))},t.prototype.elementScrollPosition=function(t,e){return t?{x:0,y:0}:this._dom.scrollPosition(e)},t.prototype.relativeRect=function(t,e,n){return s.eitherRect(this._dom.position(t,e),n)},t=o.__decorate([i.Injectable(),o.__metadata("design:paramtypes",[r.DOMService])],t)}();e.AlignService=a},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=n(2),i=n(3),r=n(8),s=n(9),a=["font-size","font-family","font-stretch","font-style","font-weight","line-height"],c=function(){function t(){}return t.prototype.addOffset=function(t,e){return{left:t.left+e.left,top:t.top+e.top}},t.prototype.addScroll=function(t,e){return r.addScroll(t,e)},t.prototype.align=function(t){return r.align(t)},t.prototype.boundingOffset=function(t){return r.boundingOffset(this.nativeElement(t))},t.prototype.getFontStyles=function(t){var e=this.getWindow();if(!e||!t)return[];var n=e.getComputedStyle(this.nativeElement(t));return a.map(function(t){return{key:t,value:n[t]}})},t.prototype.getWindow=function(){return s.isWindowAvailable()?window:null},t.prototype.hasOffsetParent=function(t){return!!t&&!!this.nativeElement(t).offsetParent},t.prototype.offset=function(t){return t?r.offset(this.nativeElement(t)):null},t.prototype.offsetAtPoint=function(t,e){if(!t)return null;var n=this.nativeElement(t),o=n.style,i=o.left,s=o.top;n.style.left=e.left+"px",n.style.top=e.top+"px";var a=r.offset(n);return n.style.left=i,n.style.top=s,a},t.prototype.nativeElement=function(t){return t?t.nativeElement||t:null},t.prototype.position=function(t,e){return t&&e?r.positionWithScroll(this.nativeElement(t),this.nativeElement(e)):null},t.prototype.removeScroll=function(t,e){return r.removeScroll(t,e)},t.prototype.restrictToView=function(t){return r.restrictToView(t)},t.prototype.scrollPosition=function(t){return r.scrollPosition(this.nativeElement(t))},t.prototype.scrollableParents=function(t){return s.scrollableParents(this.nativeElement(t))},t.prototype.stackingElementOffset=function(t){var e=this.getRelativeContextElement(t);return e?r.offset(e):null},t.prototype.stackingElementScroll=function(t){var e=this.getRelativeContextElement(t);return e?{x:e.scrollLeft,y:e.scrollTop}:{x:0,y:0}},t.prototype.getRelativeContextElement=function(t){if(!t||!s.HAS_RELATIVE_STACKING_CONTEXT)return null;for(var e=this.nativeElement(t).parentElement;e;){if("none"!==window.getComputedStyle(e).transform)return e;e=e.parentElement}return null},t.prototype.useRelativePosition=function(t){return!!this.getRelativeContextElement(t)},t.prototype.windowViewPort=function(t){return r.getWindowViewPort(this.nativeElement(t))},t.prototype.zIndex=function(t,e){return s.zIndex(this.nativeElement(t),this.nativeElement(e))},t.prototype.zoomLevel=function(){return s.isDocumentAvailable()&&s.isWindowAvailable()&&parseFloat((document.documentElement.clientWidth/window.innerWidth).toFixed(2))||1},t.prototype.isZoomed=function(){return this.zoomLevel()>1},t=o.__decorate([i.Injectable()],t)}();e.DOMService=c},function(t,e){t.exports=r},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=n(8);e.eitherRect=function(t,e){return t||{height:0,left:e.left,top:e.top,width:0}},e.replaceOffset=function(t,e){return e?{height:t.height,left:e.left,top:e.top,width:t.width}:t},e.removeStackingOffset=function(t,e){return e?{height:t.height,left:t.left-e.left,top:t.top-e.top,width:t.width}:t},e.isDifferentOffset=function(t,e){var n=t.left,o=t.top,i=e.left,r=e.top;return Math.abs(n-i)>=1||Math.abs(o-r)>=1},e.isDocumentAvailable=function(){return"undefined"!=typeof document&&!!document.body},e.isWindowAvailable=function(){return"undefined"!=typeof window},e.hasBoundingRect=function(t){return!!t.getBoundingClientRect},e.OVERFLOW_REGEXP=/auto|scroll/;var i=function(t){return""+(o=t).style.overflow+o.style.overflowX+o.style.overflowY||(e=t,""+(n=window.getComputedStyle(e)).overflow+n.overflowX+n.overflowY);var e,n,o};e.scrollableParents=function(t){var n=[];if(!e.isDocumentAvailable()||!e.isWindowAvailable())return n;for(var o=t.parentElement;o;)e.OVERFLOW_REGEXP.test(i(o))&&n.push(o),o=o.parentElement;return n.push(window),n},e.FRAME_DURATION=1e3/60,e.hasRelativeStackingContext=function(){if(!e.isDocumentAvailable())return!1;var t=document.createElement("div");t.style.transform="matrix(10, 0, 0, 10, 0, 0)",t.innerHTML='<div style="position: fixed; top: 10px;">child</div>',document.body.appendChild(t);var n=10!==t.children[0].getBoundingClientRect().top;return document.body.removeChild(t),n},e.HAS_RELATIVE_STACKING_CONTEXT=e.hasRelativeStackingContext(),e.zIndex=function(t,n){if(!t||!e.isDocumentAvailable()||!e.isWindowAvailable())return null;var i=o.siblingContainer(t,n);if(!i)return null;var r=[t].concat(o.parents(t,i)).reduce(function(t,e){var n=e.style.zIndex||window.getComputedStyle(e).zIndex,o=parseInt(n,10);return o>t?o:t},0);return r?r+1:null}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=n(2),i=n(3),r=n(7),s=n(9),a=function(){function t(t){this._dom=t}return t.prototype.positionElement=function(t){var e=t.anchor,n=t.currentLocation,o=t.element,i=t.anchorAlign,r=t.elementAlign,a=t.collisions,c=this._dom,p=c.restrictToView({anchorAlign:i,anchorRect:s.eitherRect(c.offset(e),n),collisions:a,elementAlign:r,elementRect:c.offsetAtPoint(o,n),viewPort:t.viewPort||c.windowViewPort(o)});return{flipped:p.flipped,offset:c.addOffset(n,p.offset)}},t=o.__decorate([i.Injectable(),o.__metadata("design:paramtypes",[r.DOMService])],t)}();e.PositionService=a},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=n(2),i=n(3),r=n(12),s=n(13),a=n(9),c=n(7),p=function(){function t(t,e){this._dom=t,this._zone=e}return t.prototype.subscribe=function(t){var e=this;a.isDocumentAvailable()&&this._zone.runOutsideAngular(function(){e.subscription=r.fromEvent(e._dom.getWindow(),"resize").pipe(s.auditTime(a.FRAME_DURATION)).subscribe(function(){return t()})})},t.prototype.unsubscribe=function(){this.subscription&&this.subscription.unsubscribe()},t.prototype.isUnsubscribed=function(){return this.subscription&&this.subscription.closed},t=o.__decorate([i.Injectable(),o.__metadata("design:paramtypes",[c.DOMService,i.NgZone])],t)}();e.ResizeService=p},function(t,e){t.exports=s},function(t,e){t.exports=a},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=n(2),i=n(3),r=n(12),s=n(15),a=n(13),c=n(7),p=n(9);e.THRESHOLD_DIFF=1;var l=function(){function t(t,e){this._dom=t,this._zone=e}return t.prototype.forElement=function(t){return this.unsubscribe(),this.element=t,this},t.prototype.subscribe=function(t){var e=this;if(t&&p.isDocumentAvailable()&&this.element){var n=this._dom.nativeElement(this.element),o=this._dom.scrollableParents(this.element);this._zone.runOutsideAngular(function(){var i=o.map(function(t){return r.fromEvent(t,"scroll").pipe(a.auditTime(p.FRAME_DURATION))});e.subscription=s.merge.apply(void 0,i).subscribe(function(o){t(e.isVisible(n,o.target))})})}},t.prototype.unsubscribe=function(){this.subscription&&this.subscription.unsubscribe()},t.prototype.isVisible=function(t,n){var o=this._dom.boundingOffset(t),i=this._dom.boundingOffset(n);return!(i.top-o.bottom>e.THRESHOLD_DIFF)&&(!(i.bottom-o.bottom<-e.THRESHOLD_DIFF)&&(!(i.right-o.right<-e.THRESHOLD_DIFF)&&!(i.left-o.left>e.THRESHOLD_DIFF)))},t=o.__decorate([i.Injectable(),o.__metadata("design:paramtypes",[c.DOMService,i.NgZone])],t)}();e.ScrollableService=l},function(t,e){t.exports=c},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=n(2),i=n(3),r=n(17),s=n(4),a=n(1),c=[s.PopupComponent],p=function(){function t(){}return t=o.__decorate([i.NgModule({declarations:[c],entryComponents:[c],exports:[c],imports:[r.CommonModule],providers:[a.PopupService]})],t)}();e.PopupModule=p},function(t,e){t.exports=i}])}}});
System.register("@progress/kendo-angular-popup",["tslib","@angular/core","rxjs/observable/fromPromise","@angular/common","@progress/kendo-popup-common","rxjs/operators/auditTime","rxjs/observable/fromEvent","rxjs/observable/merge","@angular/animations"],function(s){var n,o,i,r,a,c,p,l,u;function e(t){return t.__useDefault?t.default:t}return{setters:[function(t){n=e(t)},function(t){o=e(t)},function(t){i=e(t)},function(t){r=e(t)},function(t){a=e(t)},function(t){c=e(t)},function(t){p=e(t)},function(t){l=e(t)},function(t){u=e(t)}],execute:function(){!function(n){var o={};function i(t){if(o[t])return o[t].exports;var e=o[t]={exports:{},id:t,loaded:!1};return n[t].call(e.exports,e,e.exports,i),e.loaded=!0,e.exports}i.m=n,i.c=o,i.p="",i(0)}([function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=n(1);e.PopupService=o.PopupService,e.POPUP_CONTAINER=o.POPUP_CONTAINER;var i=n(4);e.PopupComponent=i.PopupComponent;var r=n(18);e.PopupModule=r.PopupModule,function(t){for(var e in t)s(e,t[e])}(e)},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=n(2),i=n(3),r=n(4);e.POPUP_CONTAINER=new i.InjectionToken("Popup Container");var s=function(){function t(t,e,n,o){this.applicationRef=t,this.componentFactoryResolver=e,this.injector=n,this.container=o}return Object.defineProperty(t.prototype,"rootViewContainer",{get:function(){var t=this.applicationRef.components||[];if(t[0])return t[0];throw new Error("\n View Container not found! Inject the POPUP_CONTAINER or define a specific ViewContainerRef via the appendTo option.\n See http://www.telerik.com/kendo-angular-ui/components/popup/api/POPUP_CONTAINER/ for more details.\n ")},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"rootViewContainerNode",{get:function(){return this.container?this.container.nativeElement:this.getComponentRootNode(this.rootViewContainer)},enumerable:!0,configurable:!0}),t.prototype.open=function(t){void 0===t&&(t={});var e=this.contentFrom(t.content),n=e.component,o=e.nodes,i=this.appendPopup(o,t.appendTo),r=i.instance;return this.projectComponentInputs(i,t),i.changeDetectorRef.detectChanges(),n&&n.changeDetectorRef.detectChanges(),{close:function(){n?n.destroy():(i.instance.content=null,i.changeDetectorRef.detectChanges()),i.destroy()},content:n,popup:i,popupAnchorViewportLeave:r.anchorViewportLeave,popupClose:r.close,popupElement:this.getComponentRootNode(i),popupOpen:r.open}},t.prototype.appendPopup=function(t,e){var n=this.createComponent(r.PopupComponent,t,e);return e||this.rootViewContainerNode.appendChild(this.getComponentRootNode(n)),n},t.prototype.getComponentRootNode=function(t){return t.hostView.rootNodes[0]},t.prototype.getComponentFactory=function(t){return this.componentFactoryResolver.resolveComponentFactory(t)},t.prototype.createComponent=function(t,e,n){var o=this.getComponentFactory(t);if(n)return n.createComponent(o,void 0,this.injector,e);var i=o.create(this.injector,e);return this.applicationRef.attachView(i.hostView),i},t.prototype.projectComponentInputs=function(e,n){return Object.getOwnPropertyNames(n).filter(function(t){return"content"!==t||n.content instanceof i.TemplateRef}).map(function(t){e.instance[t]=n[t]}),e},t.prototype.contentFrom=function(t){if(!t||t instanceof i.TemplateRef)return{component:null,nodes:[[]]};var e=this.createComponent(t);return{component:e,nodes:[e?[e.location.nativeElement]:[]]}},t=o.__decorate([i.Injectable(),o.__param(3,i.Inject(e.POPUP_CONTAINER)),o.__param(3,i.Optional()),o.__metadata("design:paramtypes",[i.ApplicationRef,i.ComponentFactoryResolver,i.Injector,i.ElementRef])],t)}();e.PopupService=s},function(t,e){t.exports=n},function(t,e){t.exports=o},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=n(2),p=n(3),i=n(5),r=n(6),s=n(7),a=n(10),c=n(11),l=n(14),u=n(16),f=n(9),d={left:-1e4,top:0},h="k-animation-container",m=function(){function t(t,e,n,o,i,r,s,a,c){this.container=t,this._alignService=e,this.domService=n,this._positionService=o,this._resizeService=i,this._scrollableService=r,this.animationService=s,this._renderer=a,this._zone=c,this.animate=!0,this.anchorAlign={horizontal:"left",vertical:"bottom"},this.collision={horizontal:"fit",vertical:"flip"},this.popupAlign={horizontal:"left",vertical:"top"},this.copyAnchorStyles=!1,this.positionMode="fixed",this.offset=d,this.anchorViewportLeave=new p.EventEmitter,this.close=new p.EventEmitter,this.open=new p.EventEmitter,this.resolvedPromise=Promise.resolve(null),this._renderer.addClass(t.nativeElement,h),this.updateFixedClass()}return t.prototype.ngOnInit=function(){this.repositionCallback=this.reposition.bind(this),this._resizeService.subscribe(this.repositionCallback),this.animationSubscriptions=this.animationService.start.subscribe(this.onAnimationStart.bind(this)).add(this.animationService.end.subscribe(this.onAnimationEnd.bind(this))),this._scrollableService.forElement(this.anchor||this.container).subscribe(this.onScroll.bind(this)),this.currentOffset=d,this.setZIndex(),this.copyFontStyles(),this.updateFixedClass()},t.prototype.ngOnChanges=function(t){t.copyAnchorStyles&&this.copyFontStyles(),t.positionMode&&this.updateFixedClass()},t.prototype.ngAfterViewChecked=function(){var t=this;this._zone.runOutsideAngular(function(){t.repositionSubscription&&t.repositionSubscription.unsubscribe(),t.repositionSubscription=i.fromPromise(t.resolvedPromise).subscribe(t.repositionCallback)})},t.prototype.ngOnDestroy=function(){this.anchorViewportLeave.complete(),this.close.emit(),this.close.complete(),this._resizeService.unsubscribe(),this._scrollableService.unsubscribe(),this.repositionSubscription&&this.repositionSubscription.unsubscribe(),this.animationSubscriptions.unsubscribe()},t.prototype.onAnimationStart=function(){this._renderer.removeClass(this.container.nativeElement,"k-animation-container-shown")},t.prototype.onAnimationEnd=function(){this._renderer.addClass(this.container.nativeElement,"k-animation-container-shown"),this.open.emit(),this.open.complete()},Object.defineProperty(t.prototype,"currentOffset",{get:function(){return this._currentOffset},set:function(t){this._currentOffset&&!f.isDifferentOffset(this._currentOffset,t)||(this.setContainerStyle("left",t.left+"px"),this.setContainerStyle("top",t.top+"px"),this._currentOffset=t)},enumerable:!0,configurable:!0}),t.prototype.setZIndex=function(){this.anchor&&this.setContainerStyle("z-index",String(this.domService.zIndex(this.anchor,this.container)))},t.prototype.reposition=function(){if(f.isDocumentAvailable()){var t=this.position(),e=t.flip,n=t.offset;this.currentOffset=n,this.animationService.play(this.contentContainer.nativeElement,this.animate,e)}},t.prototype.position=function(){var t=this._alignService.alignElement({anchor:this.anchor,anchorAlign:this.anchorAlign,element:this.container,elementAlign:this.popupAlign,offset:this.offset,positionMode:this.positionMode});return this._positionService.positionElement({anchor:this.anchor,anchorAlign:this.anchorAlign,collisions:this.collision,currentLocation:t,element:this.container,elementAlign:this.popupAlign})},t.prototype.onScroll=function(t){var e=this,n=0<this.anchorViewportLeave.observers.length;t||!n?this.reposition():n&&this._zone.run(function(){e.anchorViewportLeave.emit()})},t.prototype.copyFontStyles=function(){var e=this;this.anchor&&this.copyAnchorStyles&&this.domService.getFontStyles(this.anchor).forEach(function(t){return e.setContainerStyle(t.key,t.value)})},t.prototype.updateFixedClass=function(){var t="fixed"===this.positionMode?"addClass":"removeClass";this._renderer[t](this.container.nativeElement,"k-animation-container-fixed")},t.prototype.setContainerStyle=function(t,e){this._renderer.setStyle(this.container.nativeElement,t,e)},o.__decorate([p.Input(),o.__metadata("design:type",Object)],t.prototype,"animate",void 0),o.__decorate([p.Input(),o.__metadata("design:type",p.ElementRef)],t.prototype,"anchor",void 0),o.__decorate([p.Input(),o.__metadata("design:type",Object)],t.prototype,"anchorAlign",void 0),o.__decorate([p.Input(),o.__metadata("design:type",Object)],t.prototype,"collision",void 0),o.__decorate([p.Input(),o.__metadata("design:type",Object)],t.prototype,"popupAlign",void 0),o.__decorate([p.Input(),o.__metadata("design:type",Boolean)],t.prototype,"copyAnchorStyles",void 0),o.__decorate([p.Input(),o.__metadata("design:type",Object)],t.prototype,"popupClass",void 0),o.__decorate([p.Input(),o.__metadata("design:type",String)],t.prototype,"positionMode",void 0),o.__decorate([p.Input(),o.__metadata("design:type",Object)],t.prototype,"offset",void 0),o.__decorate([p.Output(),o.__metadata("design:type",p.EventEmitter)],t.prototype,"anchorViewportLeave",void 0),o.__decorate([p.Output(),o.__metadata("design:type",p.EventEmitter)],t.prototype,"close",void 0),o.__decorate([p.Output(),o.__metadata("design:type",p.EventEmitter)],t.prototype,"open",void 0),o.__decorate([p.ViewChild("container"),o.__metadata("design:type",p.ElementRef)],t.prototype,"contentContainer",void 0),t=o.__decorate([p.Component({exportAs:"kendo-popup",providers:[r.AlignService,u.AnimationService,s.DOMService,a.PositionService,c.ResizeService,l.ScrollableService],selector:"kendo-popup",template:'\n <div class="k-popup" [ngClass]="popupClass" #container>\n <ng-content></ng-content>\n <ng-template [ngTemplateOutlet]="content" [ngIf]="content"></ng-template>\n </div>\n '}),o.__metadata("design:paramtypes",[p.ElementRef,r.AlignService,s.DOMService,a.PositionService,c.ResizeService,l.ScrollableService,u.AnimationService,p.Renderer2,p.NgZone])],t)}();e.PopupComponent=m},function(t,e){t.exports=i},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=n(2),i=n(3),r=n(7),s=n(9),a=function(){function t(t){this._dom=t}return t.prototype.alignElement=function(t){var e=t.anchor,n=t.element,o=t.anchorAlign,i=t.elementAlign,r=t.offset,s="fixed"===t.positionMode||!this._dom.hasOffsetParent(n)?this.absoluteRect(e,n,r):this.relativeRect(e,n,r);return this._dom.align({anchorAlign:o,anchorRect:s,elementAlign:i,elementRect:this._dom.offset(n)})},t.prototype.absoluteRect=function(t,e,n){return this._dom.removeScroll(this._dom.addScroll(s.removeStackingOffset(s.eitherRect(this._dom.offset(t),n),this._dom.stackingElementOffset(e)),this._dom.stackingElementScroll(e)),this.elementScrollPosition(t,e))},t.prototype.elementScrollPosition=function(t,e){return t?{x:0,y:0}:this._dom.scrollPosition(e)},t.prototype.relativeRect=function(t,e,n){return s.eitherRect(this._dom.position(t,e),n)},t=o.__decorate([i.Injectable(),o.__metadata("design:paramtypes",[r.DOMService])],t)}();e.AlignService=a},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=n(2),i=n(3),a=n(8),r=n(9),s=["font-size","font-family","font-stretch","font-style","font-weight","line-height"],c=function(){function t(){}return t.prototype.addOffset=function(t,e){return{left:t.left+e.left,top:t.top+e.top}},t.prototype.addScroll=function(t,e){return a.addScroll(t,e)},t.prototype.align=function(t){return a.align(t)},t.prototype.boundingOffset=function(t){return a.boundingOffset(this.nativeElement(t))},t.prototype.getFontStyles=function(t){var e=this.getWindow();if(!e||!t)return[];var n=e.getComputedStyle(this.nativeElement(t));return s.map(function(t){return{key:t,value:n[t]}})},t.prototype.getWindow=function(){return r.isWindowAvailable()?window:null},t.prototype.hasOffsetParent=function(t){return!!t&&!!this.nativeElement(t).offsetParent},t.prototype.offset=function(t){return t?a.offset(this.nativeElement(t)):null},t.prototype.offsetAtPoint=function(t,e){if(!t)return null;var n=this.nativeElement(t),o=n.style,i=o.left,r=o.top;n.style.left=e.left+"px",n.style.top=e.top+"px";var s=a.offset(n);return n.style.left=i,n.style.top=r,s},t.prototype.nativeElement=function(t){return t?t.nativeElement||t:null},t.prototype.position=function(t,e){return t&&e?a.positionWithScroll(this.nativeElement(t),this.nativeElement(e)):null},t.prototype.removeScroll=function(t,e){return a.removeScroll(t,e)},t.prototype.restrictToView=function(t){return a.restrictToView(t)},t.prototype.scrollPosition=function(t){return a.scrollPosition(this.nativeElement(t))},t.prototype.scrollableParents=function(t){return r.scrollableParents(this.nativeElement(t))},t.prototype.stackingElementOffset=function(t){var e=this.getRelativeContextElement(t);return e?a.offset(e):null},t.prototype.stackingElementScroll=function(t){var e=this.getRelativeContextElement(t);return e?{x:e.scrollLeft,y:e.scrollTop}:{x:0,y:0}},t.prototype.getRelativeContextElement=function(t){if(!t||!r.HAS_RELATIVE_STACKING_CONTEXT)return null;for(var e=this.nativeElement(t).parentElement;e;){if("none"!==window.getComputedStyle(e).transform)return e;e=e.parentElement}return null},t.prototype.useRelativePosition=function(t){return!!this.getRelativeContextElement(t)},t.prototype.windowViewPort=function(t){return a.getWindowViewPort(this.nativeElement(t))},t.prototype.zIndex=function(t,e){return r.zIndex(this.nativeElement(t),this.nativeElement(e))},t.prototype.zoomLevel=function(){return r.isDocumentAvailable()&&r.isWindowAvailable()&&parseFloat((document.documentElement.clientWidth/window.innerWidth).toFixed(2))||1},t.prototype.isZoomed=function(){return 1<this.zoomLevel()},t=o.__decorate([i.Injectable()],t)}();e.DOMService=c},function(t,e){t.exports=a},function(t,i,e){"use strict";Object.defineProperty(i,"__esModule",{value:!0});var r=e(8);i.eitherRect=function(t,e){return t||{height:0,left:e.left,top:e.top,width:0}},i.replaceOffset=function(t,e){return e?{height:t.height,left:e.left,top:e.top,width:t.width}:t},i.removeStackingOffset=function(t,e){return e?{height:t.height,left:t.left-e.left,top:t.top-e.top,width:t.width}:t},i.isDifferentOffset=function(t,e){var n=t.left,o=t.top,i=e.left,r=e.top;return 1<=Math.abs(n-i)||1<=Math.abs(o-r)},i.isDocumentAvailable=function(){return"undefined"!=typeof document&&!!document.body},i.isWindowAvailable=function(){return"undefined"!=typeof window},i.hasBoundingRect=function(t){return!!t.getBoundingClientRect},i.OVERFLOW_REGEXP=/auto|scroll/;var o=function(t){return""+(o=t).style.overflow+o.style.overflowX+o.style.overflowY||(e=t,""+(n=window.getComputedStyle(e)).overflow+n.overflowX+n.overflowY);var e,n,o};i.scrollableParents=function(t){var e=[];if(!i.isDocumentAvailable()||!i.isWindowAvailable())return e;for(var n=t.parentElement;n;)i.OVERFLOW_REGEXP.test(o(n))&&e.push(n),n=n.parentElement;return e.push(window),e},i.FRAME_DURATION=1e3/60,i.hasRelativeStackingContext=function(){if(!i.isDocumentAvailable())return!1;var t=document.createElement("div");t.style.transform="matrix(10, 0, 0, 10, 0, 0)",t.innerHTML='<div style="position: fixed; top: 10px;">child</div>',document.body.appendChild(t);var e=10!==t.children[0].getBoundingClientRect().top;return document.body.removeChild(t),e},i.HAS_RELATIVE_STACKING_CONTEXT=i.hasRelativeStackingContext(),i.zIndex=function(t,e){if(!t||!i.isDocumentAvailable()||!i.isWindowAvailable())return null;var n=r.siblingContainer(t,e);if(!n)return null;var o=[t].concat(r.parents(t,n)).reduce(function(t,e){var n=e.style.zIndex||window.getComputedStyle(e).zIndex,o=parseInt(n,10);return t<o?o:t},0);return o?o+1:null}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=n(2),i=n(3),r=n(7),p=n(9),s=function(){function t(t){this._dom=t}return t.prototype.positionElement=function(t){var e=t.anchor,n=t.currentLocation,o=t.element,i=t.anchorAlign,r=t.elementAlign,s=t.collisions,a=this._dom,c=a.restrictToView({anchorAlign:i,anchorRect:p.eitherRect(a.offset(e),n),collisions:s,elementAlign:r,elementRect:a.offsetAtPoint(o,n),viewPort:t.viewPort||a.windowViewPort(o)});return{flip:c.flip,flipped:c.flipped,offset:a.addOffset(n,c.offset)}},t=o.__decorate([i.Injectable(),o.__metadata("design:paramtypes",[r.DOMService])],t)}();e.PositionService=s},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=n(2),i=n(3),r=n(12),s=n(13),a=n(9),c=n(7),p=function(){function t(t,e){this._dom=t,this._zone=e}return t.prototype.subscribe=function(t){var e=this;a.isDocumentAvailable()&&this._zone.runOutsideAngular(function(){e.subscription=r.fromEvent(e._dom.getWindow(),"resize").pipe(s.auditTime(a.FRAME_DURATION)).subscribe(function(){return t()})})},t.prototype.unsubscribe=function(){this.subscription&&this.subscription.unsubscribe()},t.prototype.isUnsubscribed=function(){return this.subscription&&this.subscription.closed},t=o.__decorate([i.Injectable(),o.__metadata("design:paramtypes",[c.DOMService,i.NgZone])],t)}();e.ResizeService=p},function(t,e){t.exports=p},function(t,e){t.exports=c},function(t,i,e){"use strict";Object.defineProperty(i,"__esModule",{value:!0});var n=e(2),o=e(3),r=e(12),s=e(15),a=e(13),c=e(7),p=e(9);i.THRESHOLD_DIFF=1;var l=function(){function t(t,e){this._dom=t,this._zone=e}return t.prototype.forElement=function(t){return this.unsubscribe(),this.element=t,this},t.prototype.subscribe=function(e){var n=this;if(e&&p.isDocumentAvailable()&&this.element){var o=this._dom.nativeElement(this.element),i=this._dom.scrollableParents(this.element);this._zone.runOutsideAngular(function(){var t=i.map(function(t){return r.fromEvent(t,"scroll").pipe(a.auditTime(p.FRAME_DURATION))});n.subscription=s.merge.apply(void 0,t).subscribe(function(t){e(n.isVisible(o,t.target))})})}},t.prototype.unsubscribe=function(){this.subscription&&this.subscription.unsubscribe()},t.prototype.isVisible=function(t,e){var n=this._dom.boundingOffset(t),o=this._dom.boundingOffset(e);return!(o.top-n.bottom>i.THRESHOLD_DIFF)&&(!(o.bottom-n.bottom<-i.THRESHOLD_DIFF)&&(!(o.right-n.right<-i.THRESHOLD_DIFF)&&!(o.left-n.left>i.THRESHOLD_DIFF)))},t=n.__decorate([o.Injectable(),n.__metadata("design:paramtypes",[c.DOMService,o.NgZone])],t)}();i.ScrollableService=l},function(t,e){t.exports=l},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=n(2),s=n(3),a=n(17),i="left",r="right",c="down",p={expand:function(t){var e="up"===t||t===c?"scaleY":"scaleX";return{start:{transform:e+"(0)",transformOrigin:t===c?"top":t===i?r:t===r?i:"bottom"},end:{transform:e+"(1)"}}},slide:function(t){var e=t===i||t===r?"translateX":"translateY";return{start:{transform:e+"("+(t===r||t===c?-100:100)+"%)"},end:{transform:e+"(0%)"}}},fade:function(){return{start:{opacity:0},end:{opacity:1}}},zoom:function(){return{start:{transform:"scale(0)"},end:{transform:"scale(1)"}}}},l=function(){function t(t){this.animationBuilder=t,this.start=new s.EventEmitter,this.end=new s.EventEmitter}return t.prototype.play=function(t,e,n){if(!this.flip||this.flip.horizontal!==n.horizontal||this.flip.vertical!==n.vertical){if(this.flip=n,!e)return void this.end.emit();var o=e.type||"slide",i=p[o];if(i){var r=i(this.getDirection(n,e));this.playStates(t,r,e)}else if(s.isDevMode())throw new Error('Unsupported animation type: "'+o+'". The supported types are slide, expand, fade and zoom.')}},t.prototype.ngOnDestroy=function(){this.stopPlayer()},t.prototype.playStates=function(t,e,n){var o=this;this.stopPlayer();var i=n.duration||100,r=this.animationBuilder.build([a.style(e.start),a.animate(i+"ms ease-in",a.style(e.end))]),s=this.player=r.create(t);s.onDone(function(){o.end.emit(),o.stopPlayer()}),this.start.emit(),s.play()},t.prototype.getDirection=function(t,e){var n=e.direction||c;return t.horizontal&&(n===i?n=r:n===r&&(n=i)),t.vertical&&(n===c?n="up":"up"===n&&(n=c)),n},t.prototype.stopPlayer=function(){this.player&&(this.player.destroy(),this.player=null)},t=o.__decorate([s.Injectable(),o.__metadata("design:paramtypes",[a.AnimationBuilder])],t)}();e.AnimationService=l},function(t,e){t.exports=u},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=n(2),i=n(3),r=n(19),s=n(4),a=n(1),c=[s.PopupComponent],p=function(){function t(){}return t=o.__decorate([i.NgModule({declarations:[c],entryComponents:[c],exports:[c],imports:[r.CommonModule],providers:[a.PopupService]})],t)}();e.PopupModule=p},function(t,e){t.exports=r}])}}});

@@ -6,3 +6,3 @@ {

"license": "SEE LICENSE in LICENSE.md",
"version": "2.0.2",
"version": "2.1.0-dev.201803161304",
"main": "dist/npm/index.js",

@@ -38,3 +38,3 @@ "module": "dist/es/index.js",

"dependencies": {
"@progress/kendo-popup-common": "^1.2.3",
"@progress/kendo-popup-common": "^1.4.0",
"tslib": "^1.7.0"

@@ -41,0 +41,0 @@ },

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc