@progress/kendo-angular-popup
Advanced tools
Comparing version 1.2.1 to 1.2.2-dev.201710041427
@@ -1,1 +0,1 @@ | ||
!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("tslib"),require("@angular/core"),require("rxjs/Observable"),require("rxjs/add/observable/fromEvent"),require("rxjs/add/operator/auditTime"),require("rxjs/add/observable/merge"),require("@angular/common")):"function"==typeof define&&define.amd?define(["tslib","@angular/core","rxjs/Observable","rxjs/add/observable/fromEvent","rxjs/add/operator/auditTime","rxjs/add/observable/merge","@angular/common"],t):"object"==typeof exports?exports.KendoAngularPopup=t(require("tslib"),require("@angular/core"),require("rxjs/Observable"),require("rxjs/add/observable/fromEvent"),require("rxjs/add/operator/auditTime"),require("rxjs/add/observable/merge"),require("@angular/common")):e.KendoAngularPopup=t(e.tslib,e["@angular/core"],e["rxjs/Observable"],e["rxjs/add/observable/fromEvent"],e["rxjs/add/operator/auditTime"],e["rxjs/add/observable/merge"],e["@angular/common"])}(this,function(e,t,n,o,i,r,s){return function(e){function t(o){if(n[o])return n[o].exports;var i=n[o]={exports:{},id:o,loaded:!1};return e[o].call(i.exports,i,i.exports,t),i.loaded=!0,i.exports}var n={};return t.m=e,t.c=n,t.p="",t(0)}([function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=n(1);t.PopupService=o.PopupService,t.POPUP_CONTAINER=o.POPUP_CONTAINER;var i=n(4);t.PopupComponent=i.PopupComponent;var r=n(16);t.PopupModule=r.PopupModule},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=n(2),i=n(3),r=n(4);t.POPUP_CONTAINER=new i.InjectionToken("Popup Container");var s=function(){function e(e,t,n,o){this.applicationRef=e,this.componentFactoryResolver=t,this.injector=n,this.container=o}return Object.defineProperty(e.prototype,"rootViewContainer",{get:function(){var e=this.applicationRef.components||[];if(e[0])return e[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(e.prototype,"rootViewContainerNode",{get:function(){return this.container?this.container.nativeElement:this.getComponentRootNode(this.rootViewContainer)},enumerable:!0,configurable:!0}),e.prototype.open=function(e){void 0===e&&(e={});var t=this.contentFrom(e.content),n=t.component,o=t.nodes,i=this.appendPopup(o,e.appendTo),r=i.instance;return this.projectComponentInputs(i,e),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}},e.prototype.appendPopup=function(e,t){var n=this.applicationRef,o=this.createComponent(r.PopupComponent,e,t);return t||(n.attachView(o.hostView),this.rootViewContainerNode.appendChild(this.getComponentRootNode(o))),o},e.prototype.getComponentRootNode=function(e){return e.hostView.rootNodes[0]},e.prototype.getComponentFactory=function(e){return this.componentFactoryResolver.resolveComponentFactory(e)},e.prototype.createComponent=function(e,t,n){var o=this.getComponentFactory(e);return n?n.createComponent(o,void 0,this.injector,t):o.create(this.injector,t)},e.prototype.projectComponentInputs=function(e,t){return Object.getOwnPropertyNames(t).filter(function(e){return"content"!==e||t.content instanceof i.TemplateRef}).map(function(n){e.instance[n]=t[n]}),e},e.prototype.contentFrom=function(e){if(!e||e instanceof i.TemplateRef)return{component:null,nodes:[[]]};var t=this.createComponent(e),n=t?[t.location.nativeElement]:[];return{component:t,nodes:[n]}},e}();s=o.__decorate([i.Injectable(),o.__param(3,i.Inject(t.POPUP_CONTAINER)),o.__param(3,i.Optional()),o.__metadata("design:paramtypes",[i.ApplicationRef,i.ComponentFactoryResolver,i.Injector,i.ElementRef])],s),t.PopupService=s},function(t,n){t.exports=e},function(e,n){e.exports=t},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=n(2),i=n(3),r=n(5),s=n(6),a=n(9),l=n(10),c=n(14),p=n(8),u={left:-1e4,top:0},f="k-animation-container",d="k-animation-container-fixed",h=function(){function e(e,t,n,o,r,s,a,l){this.container=e,this._alignService=t,this._domService=n,this._cdr=o,this._positionService=r,this._resizeService=s,this._scrollableService=a,this._renderer=l,this.animate=!0,this.anchorAlign={horizontal:"left",vertical:"bottom"},this.collision={horizontal:"fit",vertical:"flip"},this.popupAlign={horizontal:"left",vertical:"top"},this.positionMode="fixed",this.offset=u,this.anchorViewportLeave=new i.EventEmitter,this.close=new i.EventEmitter,this.open=new i.EventEmitter,this.direction="down",this.currentOffset=u,this.resolvedPromised=Promise.resolve(null),this._renderer.addClass(e.nativeElement,f),this.updateFixedClass()}return Object.defineProperty(e.prototype,"offsetLeft",{get:function(){return this.currentOffset.left},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"offsetTop",{get:function(){return this.currentOffset.top},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"getZIndex",{get:function(){return this.anchor?this.hostZIndex:null},enumerable:!0,configurable:!0}),e.prototype.ngOnInit=function(){var e=this.reposition.bind(this);this._resizeService.subscribe(e),this._scrollableService.forElement(this.anchor||this.container).subscribe(this.onScroll.bind(this)),this.hostZIndex=this._domService.zIndex(this.anchor,this.container),this.updateFixedClass()},e.prototype.ngOnChanges=function(e){e.positionMode&&this.updateFixedClass()},e.prototype.ngAfterViewChecked=function(){var e=this;if(p.isDocumentAvailable()){var t=this.position(),n=t.flipped,o=t.offset,i=this.getDirection(n);(this.direction!==i||p.isDifferentOffset(this.currentOffset,o))&&this.resolvedPromised.then(function(){e.currentOffset=o,e.direction=i,e._cdr.markForCheck()})}},e.prototype.ngOnDestroy=function(){this.anchorViewportLeave.complete(),this.close.emit(),this.close.complete(),this._resizeService.unsubscribe(),this._scrollableService.unsubscribe()},e.prototype.triggerOpen=function(e){this._renderer.addClass(this.container.nativeElement,"k-animation-container-shown"),this.open.emit(),this.open.complete()},e.prototype.reposition=function(){if(p.isDocumentAvailable()){var e=this.position(),t=e.flipped,n=e.offset;this.direction=this.getDirection(t),this.currentOffset=n}},e.prototype.position=function(){var e=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:e,element:this.container,elementAlign:this.popupAlign,positionMode:this.positionMode})},e.prototype.getDirection=function(e){return this.animate?e?"up":"down":"none"},e.prototype.onScroll=function(e){e?this.reposition():this.anchorViewportLeave.emit()},e.prototype.updateFixedClass=function(){var e=this.container.nativeElement,t="fixed"===this.positionMode?"addClass":"removeClass";this._renderer[t](e,d)},e}();o.__decorate([i.Input(),o.__metadata("design:type",Boolean)],h.prototype,"animate",void 0),o.__decorate([i.Input(),o.__metadata("design:type",i.ElementRef)],h.prototype,"anchor",void 0),o.__decorate([i.Input(),o.__metadata("design:type",Object)],h.prototype,"anchorAlign",void 0),o.__decorate([i.Input(),o.__metadata("design:type",Object)],h.prototype,"collision",void 0),o.__decorate([i.Input(),o.__metadata("design:type",Object)],h.prototype,"popupAlign",void 0),o.__decorate([i.Input(),o.__metadata("design:type",Object)],h.prototype,"popupClass",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],h.prototype,"positionMode",void 0),o.__decorate([i.Input(),o.__metadata("design:type",Object)],h.prototype,"offset",void 0),o.__decorate([i.Output(),o.__metadata("design:type",i.EventEmitter)],h.prototype,"anchorViewportLeave",void 0),o.__decorate([i.Output(),o.__metadata("design:type",i.EventEmitter)],h.prototype,"close",void 0),o.__decorate([i.Output(),o.__metadata("design:type",i.EventEmitter)],h.prototype,"open",void 0),o.__decorate([i.HostBinding("style.left.px"),o.__metadata("design:type",Number),o.__metadata("design:paramtypes",[])],h.prototype,"offsetLeft",null),o.__decorate([i.HostBinding("style.top.px"),o.__metadata("design:type",Number),o.__metadata("design:paramtypes",[])],h.prototype,"offsetTop",null),o.__decorate([i.HostBinding("style.z-index"),o.__metadata("design:type",Number),o.__metadata("design:paramtypes",[])],h.prototype,"getZIndex",null),h=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:[r.AlignService,s.DOMService,a.PositionService,l.ResizeService,c.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,r.AlignService,s.DOMService,i.ChangeDetectorRef,a.PositionService,l.ResizeService,c.ScrollableService,i.Renderer2])],h),t.PopupComponent=h},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=n(2),i=n(3),r=n(6),s=n(8),a=function(){function e(e){this._dom=e}return e.prototype.alignElement=function(e){var t=e.anchor,n=e.element,o=e.anchorAlign,i=e.elementAlign,r=e.offset,s=e.positionMode,a="fixed"===s||!this._dom.hasOffsetParent(n),l=a?this.absoluteRect(t,n,r):this.relativeRect(t,n,r);return this._dom.align({anchorAlign:o,anchorRect:l,elementAlign:i,elementRect:this._dom.offset(n)})},e.prototype.absoluteRect=function(e,t,n){return this._dom.removeScroll(this._dom.addScroll(s.removeStackingOffset(s.eitherRect(this._dom.offset(e),n),this._dom.stackingElementOffset(t)),this._dom.stackingElementScroll(t)),this.elementScrollPosition(e,t))},e.prototype.elementScrollPosition=function(e,t){return e?{x:0,y:0}:this._dom.scrollPosition(t)},e.prototype.relativeRect=function(e,t,n){return s.eitherRect(this._dom.position(e,t),n)},e}();a=o.__decorate([i.Injectable(),o.__metadata("design:paramtypes",[r.DOMService])],a),t.AlignService=a},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=n(2),i=n(3),r=n(7),s=n(8),a=function(){function e(){}return e.prototype.addOffset=function(e,t){return{left:e.left+t.left,top:e.top+t.top}},e.prototype.align=function(e){return r.align(e)},e.prototype.boundingOffset=function(e){return r.boundingOffset(this.nativeElement(e))},e.prototype.getWindow=function(){return s.isWindowAvailable()?window:null},e.prototype.isBodyOffset=function(e){return r.isBodyOffset(this.nativeElement(e))},e.prototype.hasOffsetParent=function(e){return!!e&&!!this.nativeElement(e).offsetParent},e.prototype.offset=function(e){return e?r.offset(this.nativeElement(e)):null},e.prototype.staticOffset=function(e){if(!e)return null;var t=this.nativeElement(e),n=t.style,o=n.left,i=n.top;t.style.left="0px",t.style.top="0px";var s=r.offset(t);return t.style.left=o,t.style.top=i,s},e.prototype.nativeElement=function(e){return e?e.nativeElement||e:null},e.prototype.position=function(e,t){if(!e||!t)return null;var n=this.nativeElement(e),o=r.siblingContainer(n,this.nativeElement(t));return r.positionWithScroll(n,o)},e.prototype.relativeOffset=function(e,t){return r.applyLocationOffset(this.offset(e),t,this.isBodyOffset(e))},e.prototype.addScroll=function(e,t){return r.addScroll(e,t)},e.prototype.removeScroll=function(e,t){return r.removeScroll(e,t)},e.prototype.restrictToView=function(e){return r.restrictToView(e)},e.prototype.scrollPosition=function(e){return r.scrollPosition(this.nativeElement(e))},e.prototype.scrollableParents=function(e){return s.scrollableParents(this.nativeElement(e))},e.prototype.stackingElementOffset=function(e){var t=this.getRelativeContextElement(e);return t?r.offset(t):null},e.prototype.stackingElementScroll=function(e){var t=this.getRelativeContextElement(e);return t?{x:t.scrollLeft,y:t.scrollTop}:{x:0,y:0}},e.prototype.stackingElementViewPort=function(e){var t=this.getRelativeContextElement(e);return t?{height:t.scrollHeight,width:t.scrollWidth}:null},e.prototype.getRelativeContextElement=function(e){if(!e||!s.HAS_RELATIVE_STACKING_CONTEXT)return null;for(var t=this.nativeElement(e).parentElement;t;){if("none"!==window.getComputedStyle(t).transform)return t;t=t.parentElement}return null},e.prototype.useRelativePosition=function(e){return!!this.getRelativeContextElement(e)},e.prototype.windowViewPort=function(e){return r.getWindowViewPort(this.nativeElement(e))},e.prototype.zIndex=function(e,t){return s.zIndex(this.nativeElement(e),this.nativeElement(t))},e.prototype.zoomLevel=function(){return s.isDocumentAvailable()&&s.isWindowAvailable()?parseFloat((document.documentElement.clientWidth/window.innerWidth).toFixed(2)):1},e.prototype.isZoomed=function(){return this.zoomLevel()>1},e}();a=o.__decorate([i.Injectable()],a),t.DOMService=a},function(e,t){"use strict";function n(e,t){return{top:e.top+t.y,left:e.left+t.x,height:e.height,width:e.width}}function o(e,t,n){var o=e.top,i=e.left;return n&&(i=0,o=0),{top:o+t.top,left:i+t.left,height:e.height,width:e.width}}function i(e){var t=f(e);return t?g(t):{x:0,y:0}}function r(e,t){return{top:e.top-t.y,left:e.left-t.x,height:e.height,width:e.width}}function s(e){var t=u(e),n=y(e);return{x:n.pageXOffset||t.scrollLeft||0,y:n.pageYOffset||t.scrollTop||0}}function a(e){var t=y(e);return{height:t.innerHeight,width:t.innerWidth}}Object.defineProperty(t,"__esModule",{value:!0});var l={bottom:"bottom",center:"center",middle:"middle",left:"left",right:"right",top:"top"},c=function(e){var t=e.anchorRect,n=e.anchorAlign,o=e.elementRect,i=e.elementAlign,r=n.horizontal,s=n.vertical,a=i.horizontal,c=i.vertical,p=t.top,u=t.left;return s===l.bottom&&(p+=t.height),s!==l.center&&s!==l.middle||(p+=Math.round(t.height/2)),c===l.bottom&&(p-=o.height),c!==l.center&&c!==l.middle||(p-=Math.round(o.height/2)),r===l.right&&(u+=t.width),r!==l.center&&r!==l.middle||(u+=Math.round(t.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(e){if(!e.getBoundingClientRect)return{bottom:e.innerHeight,left:0,right:e.innerWidth,top:0};var t=e.getBoundingClientRect(),n=t.bottom,o=t.left,i=t.right,r=t.top;return{bottom:n,left:o,right:i,top:r}},u=function(e){return e.ownerDocument.documentElement},f=function(e){for(var t=e.offsetParent;t&&"static"===t.style.position;)t=t.offsetParent;return t||u(e)},d=function(e){return f(e)===e.ownerDocument.body},h=function(e){var t=e.style,n=t.display,o=t.left,i=t.position;e.style.display="",e.style.left="-10000px",e.style.position="absolute";var r=e.getBoundingClientRect();return e.style.display=n,e.style.left=o,e.style.position=i,r},m=function(e){var t=e.getBoundingClientRect(),n=t.left,o=t.top;return t.height||t.width||(t=h(e)),{top:o,left:n,height:t.height,width:t.width}},v=function(e,t){for(var n=[],o=e.parentNode;o&&(n.push(o),o!==t);)o=o.parentNode;return n},g=function(e){return{x:e.scrollLeft,y:e.scrollTop}},y=function(e){return e.ownerDocument.defaultView},_=function(e,t){var n=y(e),o=n.getComputedStyle(e),i=m(e),r=t||f(e),s=n.getComputedStyle(r),a={top:0,left:0};return"fixed"!==o.position&&r!==e.ownerDocument.body&&(a=m(r),a.top+=parseInt(s.borderTopWidth,10),a.left+=parseInt(s.borderLeftWidth,10)),{top:i.top-a.top-parseInt(o.marginTop,10),left:i.left-a.left-parseInt(o.marginLeft,10),height:i.height,width:i.width}},b=function(e,t){var n=t?f(t):null,o=_(e,n),r=o.top,s=o.left,a=o.height,l=o.width,c=n?g(n):i(e),p=c.x,u=c.y;return{top:r+u,left:s+p,height:a,width:l}},w={fit:"fit",flip:"flip"},O=function(e,t,n){var o=0;return e+t>n&&(o=n-(e+t)),e<0&&(o=-e),o},P=function(e){var t=e.offset,n=e.size,o=e.anchorSize,i=e.viewPortSize,r=e.anchorAlignPoint,s=e.elementAlignPoint,a=0,c=s===l.center||s===l.middle,p=r===l.center||r===l.middle;return s!==r&&!c&&!p&&t>-1&&(t+n>i&&(a+=-(o+n)),t+a<0&&(a+=o+n)),a},E=function(e){var t=e.anchorRect,n=e.anchorAlign,o=e.elementRect,i=e.elementAlign,r=e.collisions,s=e.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;return r.vertical===w.fit&&(h+=O(a,c,u)),r.horizontal===w.fit&&(d+=O(l,p,f)),v&&(h+=P({offset:a,size:c,anchorSize:t.height,viewPortSize:u,anchorAlignPoint:n.vertical,elementAlignPoint:i.vertical})),m&&(d+=P({offset:l,size:p,anchorSize:t.width,viewPortSize:f,anchorAlignPoint:n.horizontal,elementAlignPoint:i.horizontal})),{flipped:m&&0!==d||v&&0!==h,offset:{left:d,top:h}}},C=function(e){for(var t=[],n=e.parentNode.firstElementChild;n;)n!==e&&t.push(n),n=n.nextElementSibling;return t},x=function(e,t){for(var n,o,i=v(e),r=t;r&&(n=C(r),!(o=i.reduce(function(e,t){return e.concat(n.filter(function(e){return e===t}))},[])[0]));)r=r.parentElement;return o};t.align=c,t.addScroll=n,t.applyLocationOffset=o,t.boundingOffset=p,t.isBodyOffset=d,t.offsetParent=f,t.offset=m,t.parents=v,t.parentScrollPosition=i,t.position=_,t.positionWithScroll=b,t.removeScroll=r,t.restrictToView=E,t.scrollPosition=s,t.siblingContainer=x,t.siblings=C,t.getDocumentElement=u,t.getWindow=y,t.getWindowViewPort=a,t.AlignPoint=l,t.Collision=w},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=n(7);t.eitherRect=function(e,t){return e?e:{height:0,left:t.left,top:t.top,width:0}},t.replaceOffset=function(e,t){if(!t)return e;var n={height:e.height,left:t.left,top:t.top,width:e.width};return n},t.removeStackingOffset=function(e,t){if(!t)return e;var n={height:e.height,left:e.left-t.left,top:e.top-t.top,width:e.width};return n},t.isDifferentOffset=function(e,t){var n=e.left,o=e.top,i=t.left,r=t.top;return Math.abs(n-i)>=1||Math.abs(o-r)>=1},t.isDocumentAvailable=function(){return"undefined"!=typeof document&&!!document.body},t.isWindowAvailable=function(){return"undefined"!=typeof window},t.hasBoundingRect=function(e){return!!e.getBoundingClientRect},t.OVERFLOW_REGEXP=/auto|scroll/;var i=function(e){var t=window.getComputedStyle(e);return""+t.overflow+t.overflowX+t.overflowY};t.scrollableParents=function(e){var n=[];if(!t.isDocumentAvailable()||!t.isWindowAvailable())return n;for(var o=e.parentElement;o;)t.OVERFLOW_REGEXP.test(i(o))&&n.push(o),o=o.parentElement;return n.push(window),n},t.FRAME_DURATION=1e3/60,t.hasRelativeStackingContext=function(){if(!t.isDocumentAvailable())return!1;var e=10,n=document.createElement("div");n.style.transform="matrix(10, 0, 0, 10, 0, 0)",n.innerHTML='<div style="position: fixed; top: '+e+'px;">child</div>',document.body.appendChild(n);var o=n.children[0].getBoundingClientRect().top!==e;return document.body.removeChild(n),o},t.HAS_RELATIVE_STACKING_CONTEXT=t.hasRelativeStackingContext(),t.zIndex=function(e,n){if(!e||!t.isDocumentAvailable()||!t.isWindowAvailable())return null;var i=o.siblingContainer(e,n);if(!i)return null;var r=[e].concat(o.parents(e,i)).reduce(function(e,t){var n=t.style.zIndex||window.getComputedStyle(t).zIndex,o=parseInt(n,10);return o>e?o:e},0);return r?r+1:null}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=n(2),i=n(3),r=n(6),s=n(8),a=function(){function e(e){this._dom=e}return e.prototype.positionElement=function(e){var t=e.anchor,n=e.currentLocation,o=e.positionMode,i=e.element,r=e.anchorAlign,a=e.elementAlign,l=e.collisions,c=this._dom,p=e.viewPort||c.stackingElementViewPort(i)||c.windowViewPort(i),u=s.eitherRect(c.offset(t),n),f=s.replaceOffset(c.staticOffset(i),n),d=this.elementRect(i,f,o),h=c.restrictToView({anchorAlign:r,anchorRect:u,collisions:l,elementAlign:a,elementRect:d,viewPort:p});return{flipped:h.flipped,offset:c.addOffset(f,h.offset)}},e.prototype.elementRect=function(e,t,n){return"fixed"===n?t:this._dom.removeScroll(t,this._dom.scrollPosition(e))},e}();a=o.__decorate([i.Injectable(),o.__metadata("design:paramtypes",[r.DOMService])],a),t.PositionService=a},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=n(2),i=n(3),r=n(11);n(12),n(13);var s=n(8),a=n(6),l=function(){function e(e,t){this._dom=e,this._zone=t}return e.prototype.subscribe=function(e){var t=this;s.isDocumentAvailable()&&this._zone.runOutsideAngular(function(){t.subscription=r.Observable.fromEvent(t._dom.getWindow(),"resize").auditTime(s.FRAME_DURATION).subscribe(function(){return t._zone.run(function(){return e()})})})},e.prototype.unsubscribe=function(){this.subscription&&this.subscription.unsubscribe()},e.prototype.isUnsubscribed=function(){return this.subscription&&this.subscription.closed},e}();l=o.__decorate([i.Injectable(),o.__metadata("design:paramtypes",[a.DOMService,i.NgZone])],l),t.ResizeService=l},function(e,t){e.exports=n},function(e,t){e.exports=o},function(e,t){e.exports=i},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=n(2),i=n(3),r=n(11);n(12),n(15),n(13);var s=n(6),a=n(8),l=function(){function e(e,t){this._dom=e,this._zone=t}return e.prototype.forElement=function(e){return this.unsubscribe(),this.element=e,this},e.prototype.subscribe=function(e){var t=this;if(e&&a.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(e){return r.Observable.fromEvent(e,"scroll").auditTime(a.FRAME_DURATION)}),s=function(o){return t._zone.run(function(){return e(t.isVisible(n,o.target))})};t.subscription=r.Observable.merge.apply(r.Observable,i).subscribe(s)})}},e.prototype.unsubscribe=function(){this.subscription&&this.subscription.unsubscribe()},e.prototype.isVisible=function(e,t){var n=this._dom.boundingOffset(e),o=this._dom.boundingOffset(t);return!(n.bottom<o.top)&&(!(n.bottom>o.bottom)&&(!(n.right>o.right)&&!(n.left<o.left)))},e}();l=o.__decorate([i.Injectable(),o.__metadata("design:paramtypes",[s.DOMService,i.NgZone])],l),t.ScrollableService=l},function(e,t){e.exports=r},function(e,t,n){"use strict";Object.defineProperty(t,"__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 e(){}return e}();c=o.__decorate([i.NgModule({declarations:[l],entryComponents:[l],exports:[l],imports:[r.CommonModule],providers:[a.PopupService]})],c),t.PopupModule=c},function(e,t){e.exports=s}])}); | ||
!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("tslib"),require("@angular/core"),require("rxjs/Observable"),require("rxjs/add/observable/fromEvent"),require("rxjs/add/operator/auditTime"),require("rxjs/add/observable/merge"),require("@angular/common")):"function"==typeof define&&define.amd?define(["tslib","@angular/core","rxjs/Observable","rxjs/add/observable/fromEvent","rxjs/add/operator/auditTime","rxjs/add/observable/merge","@angular/common"],t):"object"==typeof exports?exports.KendoAngularPopup=t(require("tslib"),require("@angular/core"),require("rxjs/Observable"),require("rxjs/add/observable/fromEvent"),require("rxjs/add/operator/auditTime"),require("rxjs/add/observable/merge"),require("@angular/common")):e.KendoAngularPopup=t(e.tslib,e["@angular/core"],e["rxjs/Observable"],e["rxjs/add/observable/fromEvent"],e["rxjs/add/operator/auditTime"],e["rxjs/add/observable/merge"],e["@angular/common"])}(this,function(e,t,n,o,i,r,s){return function(e){function t(o){if(n[o])return n[o].exports;var i=n[o]={exports:{},id:o,loaded:!1};return e[o].call(i.exports,i,i.exports,t),i.loaded=!0,i.exports}var n={};return t.m=e,t.c=n,t.p="",t(0)}([function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=n(1);t.PopupService=o.PopupService,t.POPUP_CONTAINER=o.POPUP_CONTAINER;var i=n(4);t.PopupComponent=i.PopupComponent;var r=n(16);t.PopupModule=r.PopupModule},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=n(2),i=n(3),r=n(4);t.POPUP_CONTAINER=new i.InjectionToken("Popup Container");var s=function(){function e(e,t,n,o){this.applicationRef=e,this.componentFactoryResolver=t,this.injector=n,this.container=o}return Object.defineProperty(e.prototype,"rootViewContainer",{get:function(){var e=this.applicationRef.components||[];if(e[0])return e[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(e.prototype,"rootViewContainerNode",{get:function(){return this.container?this.container.nativeElement:this.getComponentRootNode(this.rootViewContainer)},enumerable:!0,configurable:!0}),e.prototype.open=function(e){void 0===e&&(e={});var t=this.contentFrom(e.content),n=t.component,o=t.nodes,i=this.appendPopup(o,e.appendTo),r=i.instance;return this.projectComponentInputs(i,e),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}},e.prototype.appendPopup=function(e,t){var n=this.applicationRef,o=this.createComponent(r.PopupComponent,e,t);return t||(n.attachView(o.hostView),this.rootViewContainerNode.appendChild(this.getComponentRootNode(o))),o},e.prototype.getComponentRootNode=function(e){return e.hostView.rootNodes[0]},e.prototype.getComponentFactory=function(e){return this.componentFactoryResolver.resolveComponentFactory(e)},e.prototype.createComponent=function(e,t,n){var o=this.getComponentFactory(e);return n?n.createComponent(o,void 0,this.injector,t):o.create(this.injector,t)},e.prototype.projectComponentInputs=function(e,t){return Object.getOwnPropertyNames(t).filter(function(e){return"content"!==e||t.content instanceof i.TemplateRef}).map(function(n){e.instance[n]=t[n]}),e},e.prototype.contentFrom=function(e){if(!e||e instanceof i.TemplateRef)return{component:null,nodes:[[]]};var t=this.createComponent(e),n=t?[t.location.nativeElement]:[];return{component:t,nodes:[n]}},e}();s=o.__decorate([i.Injectable(),o.__param(3,i.Inject(t.POPUP_CONTAINER)),o.__param(3,i.Optional()),o.__metadata("design:paramtypes",[i.ApplicationRef,i.ComponentFactoryResolver,i.Injector,i.ElementRef])],s),t.PopupService=s},function(t,n){t.exports=e},function(e,n){e.exports=t},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=n(2),i=n(3),r=n(5),s=n(6),a=n(9),l=n(10),c=n(14),p=n(8),u={left:-1e4,top:0},f="k-animation-container",d="k-animation-container-fixed",h=function(){function e(e,t,n,o,r,s,a,l){this.container=e,this._alignService=t,this._domService=n,this._cdr=o,this._positionService=r,this._resizeService=s,this._scrollableService=a,this._renderer=l,this.animate=!0,this.anchorAlign={horizontal:"left",vertical:"bottom"},this.collision={horizontal:"fit",vertical:"flip"},this.popupAlign={horizontal:"left",vertical:"top"},this.positionMode="fixed",this.offset=u,this.anchorViewportLeave=new i.EventEmitter,this.close=new i.EventEmitter,this.open=new i.EventEmitter,this.direction="down",this.currentOffset=u,this.resolvedPromised=Promise.resolve(null),this._renderer.addClass(e.nativeElement,f),this.updateFixedClass()}return Object.defineProperty(e.prototype,"offsetLeft",{get:function(){return this.currentOffset.left},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"offsetTop",{get:function(){return this.currentOffset.top},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"getZIndex",{get:function(){return this.anchor?this.hostZIndex:null},enumerable:!0,configurable:!0}),e.prototype.ngOnInit=function(){var e=this.reposition.bind(this);this._resizeService.subscribe(e),this._scrollableService.forElement(this.anchor||this.container).subscribe(this.onScroll.bind(this)),this.hostZIndex=this._domService.zIndex(this.anchor,this.container),this.updateFixedClass()},e.prototype.ngOnChanges=function(e){e.positionMode&&this.updateFixedClass()},e.prototype.ngAfterViewChecked=function(){var e=this;if(p.isDocumentAvailable()){var t=this.position(),n=t.flipped,o=t.offset,i=this.getDirection(n);(this.direction!==i||p.isDifferentOffset(this.currentOffset,o))&&this.resolvedPromised.then(function(){e.currentOffset=o,e.direction=i,e._cdr.markForCheck()})}},e.prototype.ngOnDestroy=function(){this.anchorViewportLeave.complete(),this.close.emit(),this.close.complete(),this._resizeService.unsubscribe(),this._scrollableService.unsubscribe()},e.prototype.triggerOpen=function(e){this._renderer.addClass(this.container.nativeElement,"k-animation-container-shown"),this.open.emit(),this.open.complete()},e.prototype.reposition=function(){if(p.isDocumentAvailable()){var e=this.position(),t=e.flipped,n=e.offset;this.direction=this.getDirection(t),this.currentOffset=n}},e.prototype.position=function(){var e=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:e,element:this.container,elementAlign:this.popupAlign,positionMode:this.positionMode})},e.prototype.getDirection=function(e){return this.animate?e?"up":"down":"none"},e.prototype.onScroll=function(e){e?this.reposition():this.anchorViewportLeave.emit()},e.prototype.updateFixedClass=function(){var e=this.container.nativeElement,t="fixed"===this.positionMode?"addClass":"removeClass";this._renderer[t](e,d)},e}();o.__decorate([i.Input(),o.__metadata("design:type",Boolean)],h.prototype,"animate",void 0),o.__decorate([i.Input(),o.__metadata("design:type",i.ElementRef)],h.prototype,"anchor",void 0),o.__decorate([i.Input(),o.__metadata("design:type",Object)],h.prototype,"anchorAlign",void 0),o.__decorate([i.Input(),o.__metadata("design:type",Object)],h.prototype,"collision",void 0),o.__decorate([i.Input(),o.__metadata("design:type",Object)],h.prototype,"popupAlign",void 0),o.__decorate([i.Input(),o.__metadata("design:type",Object)],h.prototype,"popupClass",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],h.prototype,"positionMode",void 0),o.__decorate([i.Input(),o.__metadata("design:type",Object)],h.prototype,"offset",void 0),o.__decorate([i.Output(),o.__metadata("design:type",i.EventEmitter)],h.prototype,"anchorViewportLeave",void 0),o.__decorate([i.Output(),o.__metadata("design:type",i.EventEmitter)],h.prototype,"close",void 0),o.__decorate([i.Output(),o.__metadata("design:type",i.EventEmitter)],h.prototype,"open",void 0),o.__decorate([i.HostBinding("style.left.px"),o.__metadata("design:type",Number),o.__metadata("design:paramtypes",[])],h.prototype,"offsetLeft",null),o.__decorate([i.HostBinding("style.top.px"),o.__metadata("design:type",Number),o.__metadata("design:paramtypes",[])],h.prototype,"offsetTop",null),o.__decorate([i.HostBinding("style.z-index"),o.__metadata("design:type",Number),o.__metadata("design:paramtypes",[])],h.prototype,"getZIndex",null),h=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:[r.AlignService,s.DOMService,a.PositionService,l.ResizeService,c.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,r.AlignService,s.DOMService,i.ChangeDetectorRef,a.PositionService,l.ResizeService,c.ScrollableService,i.Renderer2])],h),t.PopupComponent=h},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=n(2),i=n(3),r=n(6),s=n(8),a=function(){function e(e){this._dom=e}return e.prototype.alignElement=function(e){var t=e.anchor,n=e.element,o=e.anchorAlign,i=e.elementAlign,r=e.offset,s=e.positionMode,a="fixed"===s||!this._dom.hasOffsetParent(n),l=a?this.absoluteRect(t,n,r):this.relativeRect(t,n,r);return this._dom.align({anchorAlign:o,anchorRect:l,elementAlign:i,elementRect:this._dom.offset(n)})},e.prototype.absoluteRect=function(e,t,n){return this._dom.removeScroll(this._dom.addScroll(s.removeStackingOffset(s.eitherRect(this._dom.offset(e),n),this._dom.stackingElementOffset(t)),this._dom.stackingElementScroll(t)),this.elementScrollPosition(e,t))},e.prototype.elementScrollPosition=function(e,t){return e?{x:0,y:0}:this._dom.scrollPosition(t)},e.prototype.relativeRect=function(e,t,n){return s.eitherRect(this._dom.position(e,t),n)},e}();a=o.__decorate([i.Injectable(),o.__metadata("design:paramtypes",[r.DOMService])],a),t.AlignService=a},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=n(2),i=n(3),r=n(7),s=n(8),a=function(){function e(){}return e.prototype.addOffset=function(e,t){return{left:e.left+t.left,top:e.top+t.top}},e.prototype.align=function(e){return r.align(e)},e.prototype.boundingOffset=function(e){return r.boundingOffset(this.nativeElement(e))},e.prototype.getWindow=function(){return s.isWindowAvailable()?window:null},e.prototype.isBodyOffset=function(e){return r.isBodyOffset(this.nativeElement(e))},e.prototype.hasOffsetParent=function(e){return!!e&&!!this.nativeElement(e).offsetParent},e.prototype.offset=function(e){return e?r.offset(this.nativeElement(e)):null},e.prototype.staticOffset=function(e){if(!e)return null;var t=this.nativeElement(e),n=t.style,o=n.left,i=n.top;t.style.left="0px",t.style.top="0px";var s=r.offset(t);return t.style.left=o,t.style.top=i,s},e.prototype.nativeElement=function(e){return e?e.nativeElement||e:null},e.prototype.position=function(e,t){if(!e||!t)return null;var n=this.nativeElement(e),o=r.siblingContainer(n,this.nativeElement(t));return r.positionWithScroll(n,o)},e.prototype.relativeOffset=function(e,t){return r.applyLocationOffset(this.offset(e),t,this.isBodyOffset(e))},e.prototype.addScroll=function(e,t){return r.addScroll(e,t)},e.prototype.removeScroll=function(e,t){return r.removeScroll(e,t)},e.prototype.restrictToView=function(e){return r.restrictToView(e)},e.prototype.scrollPosition=function(e){return r.scrollPosition(this.nativeElement(e))},e.prototype.scrollableParents=function(e){return s.scrollableParents(this.nativeElement(e))},e.prototype.stackingElementOffset=function(e){var t=this.getRelativeContextElement(e);return t?r.offset(t):null},e.prototype.stackingElementScroll=function(e){var t=this.getRelativeContextElement(e);return t?{x:t.scrollLeft,y:t.scrollTop}:{x:0,y:0}},e.prototype.stackingElementViewPort=function(e){var t=this.getRelativeContextElement(e);return t?{height:t.scrollHeight,width:t.scrollWidth}:null},e.prototype.getRelativeContextElement=function(e){if(!e||!s.HAS_RELATIVE_STACKING_CONTEXT)return null;for(var t=this.nativeElement(e).parentElement;t;){if("none"!==window.getComputedStyle(t).transform)return t;t=t.parentElement}return null},e.prototype.useRelativePosition=function(e){return!!this.getRelativeContextElement(e)},e.prototype.windowViewPort=function(e){return r.getWindowViewPort(this.nativeElement(e))},e.prototype.zIndex=function(e,t){return s.zIndex(this.nativeElement(e),this.nativeElement(t))},e.prototype.zoomLevel=function(){return s.isDocumentAvailable()&&s.isWindowAvailable()?parseFloat((document.documentElement.clientWidth/window.innerWidth).toFixed(2)):1},e.prototype.isZoomed=function(){return this.zoomLevel()>1},e}();a=o.__decorate([i.Injectable()],a),t.DOMService=a},function(e,t){"use strict";function n(e,t){return{top:e.top+t.y,left:e.left+t.x,height:e.height,width:e.width}}function o(e,t,n){var o=e.top,i=e.left;return n&&(i=0,o=0),{top:o+t.top,left:i+t.left,height:e.height,width:e.width}}function i(e){var t=u(e),n=g(e);return{x:n.pageXOffset||t.scrollLeft||0,y:n.pageYOffset||t.scrollTop||0}}function r(e){var t=f(e);return t?y(t):{x:0,y:0}}function s(e,t){return{top:e.top-t.y,left:e.left-t.x,height:e.height,width:e.width}}function a(e){var t=g(e);return{height:t.innerHeight,width:t.innerWidth}}Object.defineProperty(t,"__esModule",{value:!0});var l={bottom:"bottom",center:"center",middle:"middle",left:"left",right:"right",top:"top"},c=function(e){var t=e.anchorRect,n=e.anchorAlign,o=e.elementRect,i=e.elementAlign,r=n.horizontal,s=n.vertical,a=i.horizontal,c=i.vertical,p=t.top,u=t.left;return s===l.bottom&&(p+=t.height),s!==l.center&&s!==l.middle||(p+=Math.round(t.height/2)),c===l.bottom&&(p-=o.height),c!==l.center&&c!==l.middle||(p-=Math.round(o.height/2)),r===l.right&&(u+=t.width),r!==l.center&&r!==l.middle||(u+=Math.round(t.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(e){if(!e.getBoundingClientRect)return{bottom:e.innerHeight,left:0,right:e.innerWidth,top:0};var t=e.getBoundingClientRect(),n=t.bottom,o=t.left,i=t.right,r=t.top;return{bottom:n,left:o,right:i,top:r}},u=function(e){return e.ownerDocument.documentElement},f=function(e){for(var t=e.offsetParent;t&&"static"===t.style.position;)t=t.offsetParent;return t||u(e)},d=function(e){return f(e)===e.ownerDocument.body},h=function(e){var t=e.style,n=t.display,o=t.left,i=t.position;e.style.display="",e.style.left="-10000px",e.style.position="absolute";var r=e.getBoundingClientRect();return e.style.display=n,e.style.left=o,e.style.position=i,r},m=function(e){var t=e.getBoundingClientRect(),n=t.left,o=t.top;return t.height||t.width||(t=h(e)),{top:o,left:n,height:t.height,width:t.width}},v=function(e,t){for(var n=[],o=e.parentNode;o&&(n.push(o),o!==t);)o=o.parentNode;return n},g=function(e){return e.ownerDocument.defaultView},y=function(e){return e===(e.ownerDocument||{}).body?i(e):{x:e.scrollLeft,y:e.scrollTop}},_=function(e,t){var n=g(e),o=n.getComputedStyle(e),i=m(e),r=t||f(e),s=n.getComputedStyle(r),a={top:0,left:0};return"fixed"!==o.position&&r!==e.ownerDocument.body&&(a=m(r),a.top+=parseInt(s.borderTopWidth,10),a.left+=parseInt(s.borderLeftWidth,10)),{top:i.top-a.top-parseInt(o.marginTop,10),left:i.left-a.left-parseInt(o.marginLeft,10),height:i.height,width:i.width}},b=function(e,t){return e?y(e):r(t)},w=function(e,t){var n=t?f(t):null,o=_(e,n),i=o.top,r=o.left,s=o.height,a=o.width,l=b(n,e),c=l.x,p=l.y;return{top:i+p,left:r+c,height:s,width:a}},O={fit:"fit",flip:"flip"},P=function(e,t,n){var o=0;return e+t>n&&(o=n-(e+t)),e<0&&(o=-e),o},E=function(e){var t=e.offset,n=e.size,o=e.anchorSize,i=e.viewPortSize,r=e.anchorAlignPoint,s=e.elementAlignPoint,a=0,c=s===l.center||s===l.middle,p=r===l.center||r===l.middle;return s!==r&&!c&&!p&&t>-1&&(t+n>i&&(a+=-(o+n)),t+a<0&&(a+=o+n)),a},C=function(e){var t=e.anchorRect,n=e.anchorAlign,o=e.elementRect,i=e.elementAlign,r=e.collisions,s=e.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===O.flip,v=r.vertical===O.flip;return r.vertical===O.fit&&(h+=P(a,c,u)),r.horizontal===O.fit&&(d+=P(l,p,f)),v&&(h+=E({offset:a,size:c,anchorSize:t.height,viewPortSize:u,anchorAlignPoint:n.vertical,elementAlignPoint:i.vertical})),m&&(d+=E({offset:l,size:p,anchorSize:t.width,viewPortSize:f,anchorAlignPoint:n.horizontal,elementAlignPoint:i.horizontal})),{flipped:m&&0!==d||v&&0!==h,offset:{left:d,top:h}}},x=function(e){for(var t=[],n=e.parentNode.firstElementChild;n;)n!==e&&t.push(n),n=n.nextElementSibling;return t},S=function(e,t){for(var n,o,i=v(e),r=t;r&&(n=x(r),!(o=i.reduce(function(e,t){return e.concat(n.filter(function(e){return e===t}))},[])[0]));)r=r.parentElement;return o};t.align=c,t.addScroll=n,t.applyLocationOffset=o,t.boundingOffset=p,t.isBodyOffset=d,t.offsetParent=f,t.offset=m,t.parents=v,t.parentScrollPosition=r,t.position=_,t.positionWithScroll=w,t.removeScroll=s,t.restrictToView=C,t.scrollPosition=i,t.siblingContainer=S,t.siblings=x,t.getDocumentElement=u,t.getWindow=g,t.getWindowViewPort=a,t.AlignPoint=l,t.Collision=O},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=n(7);t.eitherRect=function(e,t){return e?e:{height:0,left:t.left,top:t.top,width:0}},t.replaceOffset=function(e,t){if(!t)return e;var n={height:e.height,left:t.left,top:t.top,width:e.width};return n},t.removeStackingOffset=function(e,t){if(!t)return e;var n={height:e.height,left:e.left-t.left,top:e.top-t.top,width:e.width};return n},t.isDifferentOffset=function(e,t){var n=e.left,o=e.top,i=t.left,r=t.top;return Math.abs(n-i)>=1||Math.abs(o-r)>=1},t.isDocumentAvailable=function(){return"undefined"!=typeof document&&!!document.body},t.isWindowAvailable=function(){return"undefined"!=typeof window},t.hasBoundingRect=function(e){return!!e.getBoundingClientRect},t.OVERFLOW_REGEXP=/auto|scroll/;var i=function(e){var t=window.getComputedStyle(e);return""+t.overflow+t.overflowX+t.overflowY};t.scrollableParents=function(e){var n=[];if(!t.isDocumentAvailable()||!t.isWindowAvailable())return n;for(var o=e.parentElement;o;)t.OVERFLOW_REGEXP.test(i(o))&&n.push(o),o=o.parentElement;return n.push(window),n},t.FRAME_DURATION=1e3/60,t.hasRelativeStackingContext=function(){if(!t.isDocumentAvailable())return!1;var e=10,n=document.createElement("div");n.style.transform="matrix(10, 0, 0, 10, 0, 0)",n.innerHTML='<div style="position: fixed; top: '+e+'px;">child</div>',document.body.appendChild(n);var o=n.children[0].getBoundingClientRect().top!==e;return document.body.removeChild(n),o},t.HAS_RELATIVE_STACKING_CONTEXT=t.hasRelativeStackingContext(),t.zIndex=function(e,n){if(!e||!t.isDocumentAvailable()||!t.isWindowAvailable())return null;var i=o.siblingContainer(e,n);if(!i)return null;var r=[e].concat(o.parents(e,i)).reduce(function(e,t){var n=t.style.zIndex||window.getComputedStyle(t).zIndex,o=parseInt(n,10);return o>e?o:e},0);return r?r+1:null}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=n(2),i=n(3),r=n(6),s=n(8),a=function(){function e(e){this._dom=e}return e.prototype.positionElement=function(e){var t=e.anchor,n=e.currentLocation,o=e.positionMode,i=e.element,r=e.anchorAlign,a=e.elementAlign,l=e.collisions,c=this._dom,p=e.viewPort||c.stackingElementViewPort(i)||c.windowViewPort(i),u=s.eitherRect(c.offset(t),n),f=s.replaceOffset(c.staticOffset(i),n),d=this.elementRect(i,f,o),h=c.restrictToView({anchorAlign:r,anchorRect:u,collisions:l,elementAlign:a,elementRect:d,viewPort:p});return{flipped:h.flipped,offset:c.addOffset(f,h.offset)}},e.prototype.elementRect=function(e,t,n){return"fixed"===n?t:this._dom.removeScroll(t,this._dom.scrollPosition(e))},e}();a=o.__decorate([i.Injectable(),o.__metadata("design:paramtypes",[r.DOMService])],a),t.PositionService=a},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=n(2),i=n(3),r=n(11);n(12),n(13);var s=n(8),a=n(6),l=function(){function e(e,t){this._dom=e,this._zone=t}return e.prototype.subscribe=function(e){var t=this;s.isDocumentAvailable()&&this._zone.runOutsideAngular(function(){t.subscription=r.Observable.fromEvent(t._dom.getWindow(),"resize").auditTime(s.FRAME_DURATION).subscribe(function(){return t._zone.run(function(){return e()})})})},e.prototype.unsubscribe=function(){this.subscription&&this.subscription.unsubscribe()},e.prototype.isUnsubscribed=function(){return this.subscription&&this.subscription.closed},e}();l=o.__decorate([i.Injectable(),o.__metadata("design:paramtypes",[a.DOMService,i.NgZone])],l),t.ResizeService=l},function(e,t){e.exports=n},function(e,t){e.exports=o},function(e,t){e.exports=i},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=n(2),i=n(3),r=n(11);n(12),n(15),n(13);var s=n(6),a=n(8),l=function(){function e(e,t){this._dom=e,this._zone=t}return e.prototype.forElement=function(e){return this.unsubscribe(),this.element=e,this},e.prototype.subscribe=function(e){var t=this;if(e&&a.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(e){return r.Observable.fromEvent(e,"scroll").auditTime(a.FRAME_DURATION)}),s=function(o){return t._zone.run(function(){return e(t.isVisible(n,o.target))})};t.subscription=r.Observable.merge.apply(r.Observable,i).subscribe(s)})}},e.prototype.unsubscribe=function(){this.subscription&&this.subscription.unsubscribe()},e.prototype.isVisible=function(e,t){var n=this._dom.boundingOffset(e),o=this._dom.boundingOffset(t);return!(n.bottom<o.top)&&(!(n.bottom>o.bottom)&&(!(n.right>o.right)&&!(n.left<o.left)))},e}();l=o.__decorate([i.Injectable(),o.__metadata("design:paramtypes",[s.DOMService,i.NgZone])],l),t.ScrollableService=l},function(e,t){e.exports=r},function(e,t,n){"use strict";Object.defineProperty(t,"__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 e(){}return e}();c=o.__decorate([i.NgModule({declarations:[l],entryComponents:[l],exports:[l],imports:[r.CommonModule],providers:[a.PopupService]})],c),t.PopupModule=c},function(e,t){e.exports=s}])}); |
{ | ||
"name": "@progress/kendo-angular-popup", | ||
"description": "Kendo UI Angular 2 Popup component", | ||
"version": "1.2.1", | ||
"version": "1.2.2-dev.201710041427", | ||
"main": "dist/npm/main.js", | ||
@@ -30,5 +30,5 @@ "module": "dist/es/main.js", | ||
"peerDependencies": { | ||
"@angular/animations": "^4.0.0", | ||
"@angular/common": "^4.0.0", | ||
"@angular/core": "^4.0.0", | ||
"@angular/animations": "^4.0.0 || ^5.0.0", | ||
"@angular/common": "^4.0.0 || ^5.0.0", | ||
"@angular/core": "^4.0.0 || ^5.0.0", | ||
"rxjs": "^5.0.1" | ||
@@ -35,0 +35,0 @@ }, |
No v1
QualityPackage is not semver >=1. This means it is not stable and does not support ^ ranges.
Found 1 instance in 1 package
313993
129
3