@progress/kendo-angular-dialog
Advanced tools
Comparing version 3.1.0-dev.201802070905 to 3.1.0
@@ -1,1 +0,1 @@ | ||
System.register("@progress/kendo-angular-dialog",["tslib","@progress/kendo-angular-l10n","@angular/core","@angular/animations","rxjs/Subject","rxjs/observable/merge","rxjs/operators/take","rxjs/Subscription","rxjs/observable/of","@progress/kendo-angular-buttons","rxjs/operators/tap","rxjs/operators/map","@progress/kendo-popup-common","rxjs/operators/switchMap","rxjs/operators/takeUntil","rxjs/operators/delay","@angular/common","@telerik/kendo-draggable"],function(t){var e,n,i,o,r,a,s,d,c,p,u,l,g,m,f,h,_,y;function v(t){return t.__useDefault?t.default:t}return{setters:[function(t){e=v(t)},function(t){n=v(t)},function(t){i=v(t)},function(t){o=v(t)},function(t){r=v(t)},function(t){a=v(t)},function(t){s=v(t)},function(t){d=v(t)},function(t){c=v(t)},function(t){p=v(t)},function(t){u=v(t)},function(t){l=v(t)},function(t){g=v(t)},function(t){m=v(t)},function(t){f=v(t)},function(t){h=v(t)},function(t){_=v(t)},function(t){y=v(t)}],execute:function(){!function(t){var e={};function n(i){if(e[i])return e[i].exports;var o=e[i]={exports:{},id:i,loaded:!1};return t[i].call(o.exports,o,o.exports,n),o.loaded=!0,o.exports}n.m=t,n.c=e,n.p="",n(0)}([function(e,n,i){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o=i(1);n.DialogComponent=o.DialogComponent;var r=i(7);n.DialogTitleBarComponent=r.DialogTitleBarComponent;var a=i(6);n.DialogActionsComponent=a.DialogActionsComponent;var s=i(8);n.DialogService=s.DialogService;var d=i(13);n.DialogCloseResult=d.DialogCloseResult,n.DialogRef=d.DialogRef,n.DialogSettings=d.DialogSettings,n.DialogAction=d.DialogAction;var c=i(14);n.WindowComponent=c.WindowComponent;var p=i(28);n.WindowTitleBarComponent=p.WindowTitleBarComponent;var u=i(29);n.WindowMaximizeActionDirective=u.WindowMaximizeActionDirective;var l=i(31);n.WindowMinimizeActionDirective=l.WindowMinimizeActionDirective;var g=i(32);n.WindowCloseActionDirective=g.WindowCloseActionDirective;var m=i(33);n.WindowRestoreActionDirective=m.WindowRestoreActionDirective;var f=i(34);n.WindowSettings=f.WindowSettings,n.WindowRef=f.WindowRef,n.WindowCloseResult=f.WindowCloseResult;var h=i(35);n.WindowService=h.WindowService;var _=i(37);n.DialogModule=_.DialogModule;var y=i(41);n.WindowModule=y.WindowModule;var v=i(43);n.DialogsModule=v.DialogsModule,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 i=n(2),o=n(3),r=n(4),a=n(5),s=n(6),d=n(7),c=function(){function t(t,e,n){this._elRef=t,this._renderer=e,this.action=new o.EventEmitter,this.close=new o.EventEmitter,this.subscriptions=[],this.direction=n?"rtl":"ltr"}return Object.defineProperty(t.prototype,"dir",{get:function(){return this.direction},enumerable:!0,configurable:!0}),t.prototype.ngAfterContentInit=function(){this.bubble("close",this.titlebarContent)},t.prototype.ngAfterViewInit=function(){this.bubble("close",this.titlebarView),this.bubble("action",this.actionsView)},t.prototype.ngOnInit=function(){this._renderer.removeAttribute(this._elRef.nativeElement,"title")},t.prototype.ngOnDestroy=function(){this.subscriptions.forEach(function(t){return t.unsubscribe()}),this.subscriptions=[]},Object.defineProperty(t.prototype,"wrapperClass",{get:function(){return!0},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"styles",{get:function(){var t={};return this.width&&(t.width=this.width+"px"),this.height&&(t.height=this.height+"px"),this.minWidth&&(t.minWidth=this.minWidth+"px"),t},enumerable:!0,configurable:!0}),t.prototype.bubble=function(t,e){var n=this;if(e){var i=e[t].subscribe(function(e){return n[t].emit(e)});this.subscriptions.push(i)}},i.__decorate([o.Input(),i.__metadata("design:type",String)],t.prototype,"title",void 0),i.__decorate([o.Input(),i.__metadata("design:type",String)],t.prototype,"actions",void 0),i.__decorate([o.Input(),i.__metadata("design:type",Number)],t.prototype,"width",void 0),i.__decorate([o.Input(),i.__metadata("design:type",Number)],t.prototype,"minWidth",void 0),i.__decorate([o.Input(),i.__metadata("design:type",Number)],t.prototype,"height",void 0),i.__decorate([o.Output(),i.__metadata("design:type",o.EventEmitter)],t.prototype,"action",void 0),i.__decorate([o.Output(),i.__metadata("design:type",o.EventEmitter)],t.prototype,"close",void 0),i.__decorate([o.HostBinding("attr.dir"),i.__metadata("design:type",String),i.__metadata("design:paramtypes",[])],t.prototype,"dir",null),i.__decorate([o.ContentChild(d.DialogTitleBarComponent),i.__metadata("design:type",d.DialogTitleBarComponent)],t.prototype,"titlebarContent",void 0),i.__decorate([o.ViewChild(d.DialogTitleBarComponent),i.__metadata("design:type",d.DialogTitleBarComponent)],t.prototype,"titlebarView",void 0),i.__decorate([o.ViewChild(s.DialogActionsComponent),i.__metadata("design:type",s.DialogActionsComponent)],t.prototype,"actionsView",void 0),i.__decorate([o.HostBinding("class.k-dialog-wrapper"),i.__metadata("design:type",Boolean),i.__metadata("design:paramtypes",[])],t.prototype,"wrapperClass",null),t=i.__decorate([o.Component({animations:[r.trigger("overlayAppear",[r.state("in",r.style({opacity:1})),r.transition("void => *",[r.style({opacity:.1}),r.animate(".3s cubic-bezier(.2, .6, .4, 1)")])]),r.trigger("dialogSlideInAppear",[r.state("in",r.style({transform:"translate(0, 0)"})),r.transition("void => *",[r.style({transform:"translate(0, -10%)"}),r.animate(".3s cubic-bezier(.2, 1, .2, 1)")])])],exportAs:"kendoDialog",selector:"kendo-dialog",template:'\n <div class="k-overlay" @overlayAppear></div>\n\n <div class="k-widget k-window k-dialog" [ngStyle]="styles" @dialogSlideInAppear>\n\n <kendo-dialog-titlebar *ngIf="title">{{title}}</kendo-dialog-titlebar>\n <ng-content select="kendo-dialog-titlebar" *ngIf="!title"></ng-content>\n\n <div class="k-content k-window-content k-dialog-content">\n <ng-content *ngIf="!contentTemplate"></ng-content>\n <ng-template [ngTemplateOutlet]="contentTemplate" *ngIf="contentTemplate"></ng-template>\n </div>\n\n <ng-content select="kendo-dialog-actions" *ngIf="!actions"></ng-content>\n <kendo-dialog-actions [actions]="actions" *ngIf="actions"></kendo-dialog-actions>\n\n </div>\n '}),i.__param(2,o.Optional()),i.__param(2,o.Inject(a.RTL)),i.__metadata("design:paramtypes",[o.ElementRef,o.Renderer2,Boolean])],t)}();e.DialogComponent=c},function(t,n){t.exports=e},function(t,e){t.exports=i},function(t,e){t.exports=o},function(t,e){t.exports=n},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n(2),o=n(3),r=function(){function t(){this.action=new o.EventEmitter}return Object.defineProperty(t.prototype,"className",{get:function(){return!0},enumerable:!0,configurable:!0}),t.prototype.actionTemplate=function(){return this.actions instanceof o.TemplateRef},t.prototype.onButtonClick=function(t,e){this.action.emit(t)},t.prototype.buttonClass=function(t){var e=["k-button"];return t.primary&&e.push("k-primary"),e.join(" ")},i.__decorate([o.Input(),i.__metadata("design:type",Object)],t.prototype,"actions",void 0),i.__decorate([o.Output(),i.__metadata("design:type",o.EventEmitter)],t.prototype,"action",void 0),i.__decorate([o.HostBinding("class.k-button-group"),o.HostBinding("class.k-dialog-buttongroup"),o.HostBinding("class.k-dialog-button-layout-stretched"),i.__metadata("design:type",Boolean),i.__metadata("design:paramtypes",[])],t.prototype,"className",null),t=i.__decorate([o.Component({selector:"kendo-dialog-actions",template:'\n <ng-content *ngIf="!actions"></ng-content>\n <ng-container *ngIf="!actionTemplate()">\n <button\n [ngClass]="buttonClass(action)"\n (click)="onButtonClick(action, $event)"\n *ngFor="let action of actions">\n {{ action.text }}\n </button>\n </ng-container>\n <ng-template [ngTemplateOutlet]="actions" *ngIf="actionTemplate()"></ng-template>\n '})],t)}();e.DialogActionsComponent=r},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n(2),o=n(3),r=function(){function t(){this.close=new o.EventEmitter}return Object.defineProperty(t.prototype,"className",{get:function(){return!0},enumerable:!0,configurable:!0}),t.prototype.onCloseClick=function(t){t.preventDefault(),this.close.emit()},i.__decorate([o.Output(),i.__metadata("design:type",o.EventEmitter)],t.prototype,"close",void 0),i.__decorate([o.HostBinding("class.k-window-titlebar"),o.HostBinding("class.k-dialog-titlebar"),o.HostBinding("class.k-header"),i.__metadata("design:type",Boolean),i.__metadata("design:paramtypes",[])],t.prototype,"className",null),t=i.__decorate([o.Component({selector:"kendo-dialog-titlebar",template:'\n <div class="k-window-title k-dialog-title">\n <ng-content></ng-content>\n </div>\n <div class="k-window-actions k-dialog-actions">\n <a href="#" role="button"\n aria-label="Close"\n class="k-button k-bare k-button-icon k-window-action k-dialog-action k-dialog-close"\n (click)="onCloseClick($event)">\n <span class="k-icon k-i-x"></span>\n </a>\n </div>\n '})],t)}();e.DialogTitleBarComponent=r},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n(2),o=n(9),r=n(10),a=n(11),s=n(3),d=n(1),c=n(12),p=n(13),u=function(){function t(t,e){this.getDialogRef=t,this.parentInjector=e}return t.prototype.get=function(t,e){return t===p.DialogRef?this.getDialogRef():this.parentInjector.get(t,e)},t}(),l=function(){function t(t,e){this.resolver=t,this.containerService=e}return t.prototype.open=function(t){var e=this.resolver.resolveComponentFactory(d.DialogComponent),n=t.appendTo||this.containerService.container;if(!n)throw new Error("\nCannot attach dialog to the page.\nAdd an element that uses the kendoDialogContainer directive, or set the 'appendTo' property.\nSee http://www.telerik.com/kendo-angular-ui/components/dialog/service/ .\n ");var i={close:function(){},content:null,dialog:null,result:null},s=this.contentFrom(t.content,n,i),c=n.createComponent(e,void 0,void 0,s.nodes);i.dialog=c,this.applyOptions(c.instance,t);var u=new o.Subject,l=function(t){u.next(t||new p.DialogCloseResult),s.componentRef&&s.componentRef.destroy(),c.destroy()},g=r.merge(u,c.instance.close,c.instance.action).pipe(a.take(1));return g.subscribe(l),i.close=l,i.result=g,i},t.prototype.applyOptions=function(t,e){t.title=e.title,t.actions=e.actions,t.width=e.width,t.minWidth=e.minWidth,t.height=e.height,e.content instanceof s.TemplateRef&&(t.contentTemplate=e.content)},t.prototype.contentFrom=function(t,e,n){var i=e.injector.get(s.Renderer2),o=[],r=null;if("string"==typeof t)o=[i.createText(t)];else if(t&&!(t instanceof s.TemplateRef)){var a=new u(function(){return n},e.injector),d=this.resolver.resolveComponentFactory(t);o=[(r=e.createComponent(d,void 0,a)).location.nativeElement],n.content=r}return{componentRef:r,nodes:[[],o,[]]}},t=i.__decorate([s.Injectable(),i.__metadata("design:paramtypes",[s.ComponentFactoryResolver,c.DialogContainerService])],t)}();e.DialogService=l},function(t,e){t.exports=r},function(t,e){t.exports=a},function(t,e){t.exports=s},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n(2),o=n(3),r=function(){function t(){}return e=t,Object.defineProperty(t.prototype,"container",{get:function(){return e.container},set:function(t){e.container=t},enumerable:!0,configurable:!0}),t=e=i.__decorate([o.Injectable()],t);var e}();e.DialogContainerService=r},function(t,e){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var n=function(){return function(){}}();e.DialogAction=n;var i=function(){return function(){}}();e.DialogCloseResult=i;var o=function(){return function(){}}();e.DialogSettings=o;var r=function(){return function(){}}();e.DialogRef=r},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n(2),o=n(3),r=n(5),a=n(5),s=n(15),d=n(16),c=n(21),p=n(21),u=n(25),l=n(28),g=function(){function t(t,e,n,i,r){this.el=t,this.renderer=e,this.service=n,this.ngZone=i,this.keepContent=!1,this.dragStart=new o.EventEmitter,this.dragEnd=new o.EventEmitter,this.resizeStart=new o.EventEmitter,this.resizeEnd=new o.EventEmitter,this.close=new o.EventEmitter,this.widthChange=new o.EventEmitter,this.heightChange=new o.EventEmitter,this.topChange=new o.EventEmitter,this.leftChange=new o.EventEmitter,this.stateChange=new o.EventEmitter,this.tabIndex=0,this.focused=!1,this.draged=!1,this.resized=!1,this.windowSubscription=new s.Subscription,this.direction=r?"rtl":"ltr",this.resizeDirections=p.RESIZE_DIRECTIONS,this.subscribeEvents()}return Object.defineProperty(t.prototype,"draggable",{get:function(){return this.options.draggable},set:function(t){this.options.draggable=t},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"resizable",{get:function(){return this.options.resizable},set:function(t){this.options.resizable=t},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"state",{get:function(){return this.options.state},set:function(t){this.options.state=t},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"minWidth",{get:function(){return this.options.minWidth},set:function(t){this.setOption("minWidth",t)},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"minHeight",{get:function(){return this.options.minHeight},set:function(t){this.setOption("minHeight",t)},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"width",{get:function(){return this.options.width},set:function(t){this.setOption("width",t)},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"height",{get:function(){return this.options.height},set:function(t){this.setOption("height",t)},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"top",{get:function(){return this.options.top},set:function(t){this.setOption("top",t)},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"left",{get:function(){return this.options.left},set:function(t){this.setOption("left",t)},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"hostClasses",{get:function(){return!0},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"dir",{get:function(){return this.direction},enumerable:!0,configurable:!0}),t.prototype.ngAfterViewInit=function(){this.setNextZIndex(),this.setInitialOffset()},t.prototype.ngOnInit=function(){this.renderer.removeAttribute(this.el.nativeElement,"title"),this.service.init(this.el)},t.prototype.ngOnChanges=function(t){var e=this;if(c.OFFSET_STYLES.forEach(function(n){c.isChanged(n,t)&&e.updateOffset(n,e.options[n])}),c.isChanged("draggable",t)){var n=c.isPresent(this.titleBarContent)?this.titleBarContent:this.titleBarView;c.isTruthy(t.draggable.currentValue)?n.subscribeDrag():n.unsubscribeDrag()}},t.prototype.ngOnDestroy=function(){this.windowSubscription&&this.windowSubscription.unsubscribe()},Object.defineProperty(t.prototype,"showDefaultTitleBar",{get:function(){return!c.isPresent(this.titleBarContent)},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"windowClasses",{get:function(){return!0},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"styleMinWidth",{get:function(){return this.minWidth+"px"},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"styleMinHeight",{get:function(){return this.minHeight+"px"},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"stylePosition",{get:function(){return this.options.position},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"wrapperMaximizedClass",{get:function(){return"maximized"===this.state},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"wrapperFocusedClass",{get:function(){return this.focused},enumerable:!0,configurable:!0}),t.prototype.onComponentFocus=function(){this.focused=!0,this.setNextZIndex()},t.prototype.onComponentBlur=function(){this.focused=!1},t.prototype.subscribeEvents=function(){var t=this;p.isDocumentAvailable()&&(this.windowSubscription.add(this.service.focus.subscribe(function(){t.el.nativeElement.focus()})),this.windowSubscription.add(this.service.dragStart.subscribe(function(){t.draged=!0,t.ngZone.run(function(){t.dragStart.emit()})})),this.windowSubscription.add(this.service.dragEnd.subscribe(function(){t.draged&&(t.draged=!1,t.ngZone.run(function(){t.dragEnd.emit()}))})),this.windowSubscription.add(this.service.close.subscribe(function(){t.close.emit()})),this.windowSubscription.add(this.service.resizeStart.subscribe(function(){t.resized=!0,t.ngZone.run(function(){t.resizeStart.emit()})})),this.windowSubscription.add(this.service.resizeEnd.subscribe(function(){t.resized&&(t.resized=!1,t.ngZone.run(function(){t.resizeEnd.emit()}))})),this.windowSubscription.add(this.service.change.subscribe(function(e){c.OFFSET_STYLES.forEach(function(n){if(c.isPresent(e[n])&&(t.updateOffset(n,e[n]),"maximized"!==t.state)){var i=t[n+"Change"];i.observers.length&&t.ngZone.run(function(){i.emit(e[n])})}})})),this.windowSubscription.add(this.service.stateChange.subscribe(function(e){t.updateAllOffset(),t.stateChange.emit(e)})))},t.prototype.setNextZIndex=function(){this.renderer.setStyle(this.el.nativeElement,"z-index",this.service.nextZIndex)},t.prototype.setInitialOffset=function(){"maximized"!==this.state&&this.updateAllOffset(),c.isPresent(this.left)||c.isPresent(this.top)||"maximized"===this.state||this.service.center()},t.prototype.updateAllOffset=function(){var t=this;c.OFFSET_STYLES.forEach(function(e){c.isPresent(t[e])&&t.updateOffset(e,t[e])})},t.prototype.updateOffset=function(t,e){this.renderer.setStyle(this.el.nativeElement,t,e+"px")},Object.defineProperty(t.prototype,"options",{get:function(){return this.service.options},enumerable:!0,configurable:!0}),t.prototype.setOption=function(t,e){if("number"==typeof e)this.options[t]=e;else{if("string"!=typeof e)throw new Error("Invalid type used for "+t);this.options[t]=parseInt(e,10)}},i.__decorate([o.Input(),i.__metadata("design:type",String)],t.prototype,"title",void 0),i.__decorate([o.Input(),i.__metadata("design:type",Boolean),i.__metadata("design:paramtypes",[Boolean])],t.prototype,"draggable",null),i.__decorate([o.Input(),i.__metadata("design:type",Boolean),i.__metadata("design:paramtypes",[Boolean])],t.prototype,"resizable",null),i.__decorate([o.Input(),i.__metadata("design:type",Boolean)],t.prototype,"keepContent",void 0),i.__decorate([o.Input(),i.__metadata("design:type",String),i.__metadata("design:paramtypes",[String])],t.prototype,"state",null),i.__decorate([o.Input(),i.__metadata("design:type",Number),i.__metadata("design:paramtypes",[Number])],t.prototype,"minWidth",null),i.__decorate([o.Input(),i.__metadata("design:type",Number),i.__metadata("design:paramtypes",[Number])],t.prototype,"minHeight",null),i.__decorate([o.Input(),i.__metadata("design:type",Number),i.__metadata("design:paramtypes",[Number])],t.prototype,"width",null),i.__decorate([o.Input(),i.__metadata("design:type",Number),i.__metadata("design:paramtypes",[Number])],t.prototype,"height",null),i.__decorate([o.Input(),i.__metadata("design:type",Number),i.__metadata("design:paramtypes",[Number])],t.prototype,"top",null),i.__decorate([o.Input(),i.__metadata("design:type",Number),i.__metadata("design:paramtypes",[Number])],t.prototype,"left",null),i.__decorate([o.Output(),i.__metadata("design:type",o.EventEmitter)],t.prototype,"dragStart",void 0),i.__decorate([o.Output(),i.__metadata("design:type",o.EventEmitter)],t.prototype,"dragEnd",void 0),i.__decorate([o.Output(),i.__metadata("design:type",o.EventEmitter)],t.prototype,"resizeStart",void 0),i.__decorate([o.Output(),i.__metadata("design:type",o.EventEmitter)],t.prototype,"resizeEnd",void 0),i.__decorate([o.Output(),i.__metadata("design:type",o.EventEmitter)],t.prototype,"close",void 0),i.__decorate([o.Output(),i.__metadata("design:type",o.EventEmitter)],t.prototype,"widthChange",void 0),i.__decorate([o.Output(),i.__metadata("design:type",o.EventEmitter)],t.prototype,"heightChange",void 0),i.__decorate([o.Output(),i.__metadata("design:type",o.EventEmitter)],t.prototype,"topChange",void 0),i.__decorate([o.Output(),i.__metadata("design:type",o.EventEmitter)],t.prototype,"leftChange",void 0),i.__decorate([o.Output(),i.__metadata("design:type",o.EventEmitter)],t.prototype,"stateChange",void 0),i.__decorate([o.HostBinding("attr.tabIndex"),i.__metadata("design:type",Number)],t.prototype,"tabIndex",void 0),i.__decorate([o.HostBinding("class.k-widget"),o.HostBinding("class.k-window"),i.__metadata("design:type",Boolean),i.__metadata("design:paramtypes",[])],t.prototype,"hostClasses",null),i.__decorate([o.HostBinding("attr.dir"),i.__metadata("design:type",String),i.__metadata("design:paramtypes",[])],t.prototype,"dir",null),i.__decorate([o.ViewChild(l.WindowTitleBarComponent),i.__metadata("design:type",l.WindowTitleBarComponent)],t.prototype,"titleBarView",void 0),i.__decorate([o.ContentChild(l.WindowTitleBarComponent),i.__metadata("design:type",l.WindowTitleBarComponent)],t.prototype,"titleBarContent",void 0),i.__decorate([o.ViewChildren(u.ResizeHandleDirective),i.__metadata("design:type",o.QueryList)],t.prototype,"resizeHandles",void 0),i.__decorate([o.HostBinding("class.k-window-wrapper"),i.__metadata("design:type",Boolean),i.__metadata("design:paramtypes",[])],t.prototype,"windowClasses",null),i.__decorate([o.HostBinding("style.minWidth"),i.__metadata("design:type",String),i.__metadata("design:paramtypes",[])],t.prototype,"styleMinWidth",null),i.__decorate([o.HostBinding("style.minHeight"),i.__metadata("design:type",String),i.__metadata("design:paramtypes",[])],t.prototype,"styleMinHeight",null),i.__decorate([o.HostBinding("style.position"),i.__metadata("design:type",String),i.__metadata("design:paramtypes",[])],t.prototype,"stylePosition",null),i.__decorate([o.HostBinding("class.k-window-maximized"),i.__metadata("design:type",Boolean),i.__metadata("design:paramtypes",[])],t.prototype,"wrapperMaximizedClass",null),i.__decorate([o.HostBinding("class.k-state-focused"),i.__metadata("design:type",Boolean),i.__metadata("design:paramtypes",[])],t.prototype,"wrapperFocusedClass",null),i.__decorate([o.HostListener("focus"),i.__metadata("design:type",Function),i.__metadata("design:paramtypes",[]),i.__metadata("design:returntype",void 0)],t.prototype,"onComponentFocus",null),i.__decorate([o.HostListener("blur"),i.__metadata("design:type",Function),i.__metadata("design:paramtypes",[]),i.__metadata("design:returntype",void 0)],t.prototype,"onComponentBlur",null),t=i.__decorate([o.Component({exportAs:"kendoWindow",providers:[d.DragResizeService,a.LocalizationService,{provide:a.L10N_PREFIX,useValue:"kendo.window"}],selector:"kendo-window",template:'\n <kendo-window-titlebar *ngIf="showDefaultTitleBar" [template]="titleBarTemplate">\n <div class="k-window-title">{{title}}</div>\n <button kendoWindowMinimizeAction></button>\n <button kendoWindowMaximizeAction></button>\n <button kendoWindowRestoreAction></button>\n <button kendoWindowCloseAction></button>\n </kendo-window-titlebar>\n <ng-content select="kendo-window-titlebar" *ngIf="!showDefaultTitleBar"></ng-content>\n\n <div *ngIf="state !== \'minimized\' || keepContent"\n [hidden]="state === \'minimized\' && keepContent"\n class="k-content k-window-content">\n <ng-content *ngIf="!contentTemplate"></ng-content>\n <ng-template [ngTemplateOutlet]="contentTemplate" *ngIf="contentTemplate"></ng-template>\n </div>\n\n <ng-template [ngIf]=\'resizable\'>\n <div *ngFor=\'let dir of resizeDirections\'\n [direction]="dir"\n kendoWindowResizeHandle\n kendoWindowDraggable>\n </div>\n </ng-template>\n '}),i.__param(4,o.Optional()),i.__param(4,o.Inject(r.RTL)),i.__metadata("design:paramtypes",[o.ElementRef,o.Renderer2,d.DragResizeService,o.NgZone,Boolean])],t)}();e.WindowComponent=g},function(t,e){t.exports=d},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n(2),o=n(3),r=n(15),a=n(17),s=n(18),d=n(19),c=n(20),p=n(21),u=n(24),l=10002,g={draggable:!0,height:null,left:null,minHeight:100,minWidth:120,position:"absolute",resizable:!0,state:"default",top:null,width:null},m=function(t,e){return function(n){return t.kendo.drag.pipe(c.takeUntil(t.kendo.release.pipe(a.tap(function(){e.emit()}))),s.map(function(t){var e=t.pageX,i=t.pageY;return{originalX:n.pageX,originalY:n.pageY,pageX:e,pageY:i}}))}},f=function(){function t(t){this.ngZone=t,this.close=new o.EventEmitter,this.focus=new o.EventEmitter,this.change=new o.EventEmitter,this.stateChange=new o.EventEmitter,this.dragStart=new o.EventEmitter,this.dragEnd=new o.EventEmitter,this.resizeStart=new o.EventEmitter,this.resizeEnd=new o.EventEmitter,this.options=Object.assign({},g),this.subscriptions=new r.Subscription,this.dragSubscription=new r.Subscription}return t.prototype.ngOnDestroy=function(){this.subscriptions&&this.subscriptions.unsubscribe(),this.dragSubscription&&this.dragSubscription.unsubscribe()},t.prototype.init=function(t){this.window=t,"minimized"===this.options.state&&(this.restoreOptions=Object.assign({},this.options),this.options.height=0,this.options.minHeight=0)},t.prototype.onDrag=function(t){var e=this;this.subscriptions.add(this.ngZone.runOutsideAngular(function(){var n,i;e.dragSubscription=t.kendo.press.pipe(a.tap(function(t){p.preventDefault(t),e.focus.emit(),n=e.currentPosition(),i=!1}),d.switchMap(p.preventOnDblClick(t.kendo.release)),d.switchMap(m(t,e.dragEnd))).subscribe(function(t){var o=t.pageX,r=t.pageY,a=t.originalX,s=t.originalY;i||(e.dragStart.emit(),i=!0),e.handleDrag({originalX:a,originalY:s,pageX:o,pageY:r,startPosition:n})})}))},t.prototype.handleDrag=function(t){var e=t.originalX,n=t.originalY,i=t.pageX,o=t.pageY,r=t.startPosition;this.options.left=r.x+i-e,this.options.top=r.y+o-n,"minimized"===this.options.state&&p.isPresent(this.restoreOptions)&&(this.restoreOptions.left=this.options.left,this.restoreOptions.top=this.options.top),this.change.emit({left:r.x+i-e,top:r.y+o-n})},t.prototype.onResize=function(t,e){var n=this;this.subscriptions.add(this.ngZone.runOutsideAngular(function(){var i,o=!1;t.kendo.press.pipe(a.tap(function(t){p.preventDefault(t),n.focus.emit(),i=n.currentOffsetAndPosition(),o=!1}),d.switchMap(p.preventOnDblClick(t.kendo.release)),d.switchMap(m(t,n.resizeEnd))).subscribe(function(t){var r=t.pageX,a=t.pageY,s=t.originalX,d=t.originalY;o||(n.resizeStart.emit(e),o=!0);var c=r-s,p=a-d;n.handleResize(i,e,c,p)})}))},t.prototype.handleResize=function(t,e,n,i){var o=this,r=this.options,a={};e.indexOf("e")>=0&&((c=t.width+n)!==r.width&&c>=r.minWidth&&(a.width=c));if(e.indexOf("n")>=0){var s=t.height-i,d=t.y+i;s!==r.height&&s>=r.minHeight&&d!==r.top&&(a.height=s,a.top=d)}e.indexOf("s")>=0&&((s=t.height+i)!==r.height&&s>=r.minHeight&&(a.height=s));if(e.indexOf("w")>=0){var c,u=t.x+n;(c=t.width-n)!==r.width&&c>=r.minWidth&&u!==r.left&&(a.width=c,a.left=u)}(p.isPresent(a.width)||p.isPresent(a.height))&&(p.OFFSET_STYLES.forEach(function(t){p.isPresent(a[t])&&(o.options[t]=a[t])}),this.change.emit(a))},t.prototype.restoreAction=function(){p.isPresent(this.restoreOptions)&&(this.options=Object.assign({},this.restoreOptions)),this.options.state="default",this.stateChange.emit("default")},t.prototype.storeOptions=function(){if(this.restoreOptions=Object.assign({},this.options),!p.isPresent(this.options.width)||!p.isPresent(this.options.height)){var t=u.offset(this.window.nativeElement);this.restoreOptions.width=t.width,this.restoreOptions.height=t.height}},t.prototype.maximizeAction=function(){if("maximized"!==this.options.state){this.storeOptions();var t=u.getWindowViewPort(this.window.nativeElement);this.options=Object.assign({},this.options,{height:t.height,left:0,position:"fixed",state:"maximized",top:0,width:t.width}),this.stateChange.emit("maximized")}},t.prototype.minimizeAction=function(){"minimized"!==this.options.state&&(this.storeOptions(),this.options=Object.assign({},this.options,{height:0,minHeight:0,state:"minimized"}),this.stateChange.emit("minimized"))},t.prototype.closeAction=function(){this.close.emit()},t.prototype.center=function(){if("maximized"!==this.options.state){var t=u.scrollPosition(this.window.nativeElement),e=u.getWindowViewPort(this.window.nativeElement),n=u.offset(this.window.nativeElement);this.options.left=t.x+Math.max(0,(e.width-n.width)/2),this.options.top=t.y+Math.max(0,(e.height-n.height)/2),this.change.emit({left:this.options.left,top:this.options.top})}},t.prototype.currentOffsetAndPosition=function(){var t=this.options,e=u.offset(this.window.nativeElement);return Object.assign({},this.currentPosition(),{height:t.height?t.height:e.height,width:t.width?t.width:e.width})},t.prototype.currentPosition=function(){var t=this.options;return t.top&&t.left||this.setPosition(),{x:this.options.left,y:this.options.top}},t.prototype.setPosition=function(){var t=u.positionWithScroll(this.window.nativeElement,u.getDocumentElement(this.window.nativeElement));this.options.left=t.left,this.options.top=t.top},Object.defineProperty(t.prototype,"nextZIndex",{get:function(){return l++},enumerable:!0,configurable:!0}),t=i.__decorate([o.Injectable(),i.__metadata("design:paramtypes",[o.NgZone])],t)}();e.DragResizeService=f},function(t,e){t.exports=u},function(t,e){t.exports=l},function(t,e){t.exports=m},function(t,e){t.exports=f},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n(22),o=n(23),r=n(20);e.isPresent=function(t){return null!==t&&void 0!==t},e.isTruthy=function(t){return!!t};var a=function(t){return String(t).trim().split(" ")},s=/^(?:a|input|select|textarea|button|object)$/i;e.hasClasses=function(t,e){var n=a(e);return Boolean(a(t.className).find(function(t){return n.indexOf(t)>=0}))},e.isVisible=function(t){var e=t.getBoundingClientRect();return!(!e.width||!e.height)&&"hidden"!==window.getComputedStyle(t).visibility},e.isFocusable=function(t,n){if(void 0===n&&(n=!0),t.tagName){var i=t.tagName.toLowerCase(),o=t.getAttribute("tabIndex"),r=null!==o&&!isNaN(o)&&o>-1;return(s.test(i)?!t.disabled:r)&&(!n||e.isVisible(t))}return!1},e.isChanged=function(t,e,n){return void 0===n&&(n=!0),e[t]&&(!e[t].isFirstChange()||!n)&&e[t].previousValue!==e[t].currentValue},e.preventDefault=function(t){var e=t.originalEvent;e.stopPropagation(),e.preventDefault()},e.isDocumentAvailable=function(){return"undefined"!=typeof document&&!!document.body},e.isWindowAvailable=function(){return"undefined"!=typeof window},e.preventOnDblClick=function(t){return function(e){return i.of(e).pipe(o.delay(150),r.takeUntil(t))}},e.RESIZE_DIRECTIONS=["n","e","s","w","se","sw","ne","nw"],e.OFFSET_STYLES=["top","left","width","height"]},function(t,e){t.exports=c},function(t,e){t.exports=h},function(t,e){t.exports=g},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n(2),o=n(3),r=n(26),a=n(16),s=n(15),d=n(22),c=n(10),p=function(){function t(t,e,n,i){this.draggable=t,this.el=e,this.renderer=n,this.service=i,this.subscriptions=new s.Subscription}return Object.defineProperty(t.prototype,"hostClass",{get:function(){return!0},enumerable:!0,configurable:!0}),t.prototype.ngOnInit=function(){var t=this;this.setDisplay(),this.renderer.addClass(this.el.nativeElement,"k-resize-"+this.direction),this.subscriptions.add(d.of(this.draggable).subscribe(function(e){t.service.onResize(e,t.direction)})),this.subscriptions.add(this.service.resizeStart.subscribe(function(e){e!==t.direction&&t.setDisplay("none")})),this.subscriptions.add(this.service.dragStart.subscribe(function(){t.setDisplay("none")})),this.subscriptions.add(c.merge(this.service.resizeEnd,this.service.dragEnd).subscribe(function(){t.setDisplay("block")})),this.subscriptions.add(this.service.stateChange.subscribe(function(e){t.setDisplay("default"===e?"block":"none")}))},t.prototype.ngOnDestroy=function(){this.subscriptions.unsubscribe()},t.prototype.setDisplay=function(t){void 0===t&&(t="block"),this.renderer.setStyle(this.el.nativeElement,"display","default"===this.service.options.state?t:"none")},i.__decorate([o.Input(),i.__metadata("design:type",String)],t.prototype,"direction",void 0),i.__decorate([o.HostBinding("class.k-resize-handle"),i.__metadata("design:type",Boolean),i.__metadata("design:paramtypes",[])],t.prototype,"hostClass",null),t=i.__decorate([o.Directive({selector:"[kendoWindowResizeHandle]"}),i.__param(0,o.Host()),i.__metadata("design:paramtypes",[r.DraggableDirective,o.ElementRef,o.Renderer2,a.DragResizeService])],t)}();e.ResizeHandleDirective=p},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n(2),o=n(3),r=n(27),a=function(){function t(t,e){this.elem=t,this.ngZone=e,this.kendo={drag:new o.EventEmitter,press:new o.EventEmitter,release:new o.EventEmitter}}return t.prototype.ngOnInit=function(){var t=this;"undefined"!=typeof document&&(this.draggable=new r.default({drag:function(e){return t.kendo.drag.next(e)},press:function(e){return t.kendo.press.next(e)},release:function(e){return t.kendo.release.next(e)}}),this.ngZone.runOutsideAngular(function(){return t.draggable.bindTo(t.elem.nativeElement)}))},t.prototype.ngOnDestroy=function(){"undefined"!=typeof document&&this.draggable.destroy()},Object.defineProperty(t.prototype,"nativeElement",{get:function(){return this.elem.nativeElement},enumerable:!0,configurable:!0}),t=i.__decorate([o.Directive({outputs:["kendo.press","kendo.drag","kendo.release"],selector:"[kendoWindowDraggable]"}),i.__metadata("design:paramtypes",[o.ElementRef,o.NgZone])],t)}();e.DraggableDirective=a},function(t,e){t.exports=y},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n(2),o=n(3),r=n(26),a=n(16),s=n(15),d=n(22),c=n(21),p=function(){function t(t,e,n){this.el=t,this.service=e,this.ngZone=n,this.dragSubscription=new s.Subscription}return t.prototype.ngOnInit=function(){this.dragDirective=new r.DraggableDirective(this.el,this.ngZone),this.dragDirective.ngOnInit(),this.service.options.draggable&&this.subscribeDrag()},t.prototype.ngOnDestroy=function(){this.dragDirective.ngOnDestroy(),this.dragSubscription&&this.unsubscribeDrag()},t.prototype.subscribeDrag=function(){var t=this;this.dragSubscription=d.of(this.dragDirective).subscribe(function(e){t.service.onDrag(e)})},t.prototype.unsubscribeDrag=function(){this.dragSubscription&&(this.service.dragSubscription.unsubscribe(),this.dragSubscription.unsubscribe(),this.dragSubscription=null)},Object.defineProperty(t.prototype,"className",{get:function(){return!0},enumerable:!0,configurable:!0}),t.prototype.handle=function(t){var e=t.target,n=this.service.options.state;c.hasClasses(e,"k-icon")||c.isFocusable(e,!1)||!this.service.options.resizable||("default"===n?this.service.maximizeAction():"maximized"===n&&this.service.restoreAction())},i.__decorate([o.Input(),i.__metadata("design:type",o.TemplateRef)],t.prototype,"template",void 0),i.__decorate([o.HostBinding("class.k-window-titlebar"),o.HostBinding("class.k-dialog-titlebar"),o.HostBinding("class.k-header"),i.__metadata("design:type",Boolean),i.__metadata("design:paramtypes",[])],t.prototype,"className",null),i.__decorate([o.HostListener("dblclick",["$event"]),i.__metadata("design:type",Function),i.__metadata("design:paramtypes",[MouseEvent]),i.__metadata("design:returntype",void 0)],t.prototype,"handle",null),t=i.__decorate([o.Component({selector:"kendo-window-titlebar",template:'\n <ng-content *ngIf="!template"></ng-content>\n <ng-template\n [ngTemplateOutlet]="template"\n [ngTemplateOutletContext]="{\'$implicit\': service}" *ngIf="template">\n </ng-template>\n '}),i.__metadata("design:paramtypes",[o.ElementRef,a.DragResizeService,o.NgZone])],t)}();e.WindowTitleBarComponent=p},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n(2),o=n(3),r=n(16),a=n(30),s=n(5),d=function(t){function e(e,n,i,o){var r=t.call(this,e,n,null,o)||this;return r.window=i,r.look="bare",r.icon="window-maximize",r}return i.__extends(e,t),e.prototype.onClick=function(){this.window.maximizeAction()},Object.defineProperty(e.prototype,"visible",{get:function(){return"default"===this.window.options.state?"inline-flex":"none"},enumerable:!0,configurable:!0}),i.__decorate([o.Input(),i.__metadata("design:type",Object)],e.prototype,"window",void 0),i.__decorate([o.HostListener("click"),i.__metadata("design:type",Function),i.__metadata("design:paramtypes",[]),i.__metadata("design:returntype",void 0)],e.prototype,"onClick",null),i.__decorate([o.HostBinding("style.display"),i.__metadata("design:type",String),i.__metadata("design:paramtypes",[])],e.prototype,"visible",null),e=i.__decorate([o.Directive({exportAs:"kendoWindowMaximizeAction",selector:"button[kendoWindowMaximizeAction]"}),i.__param(2,o.Optional()),i.__param(3,o.Optional()),i.__param(3,o.Inject(s.RTL)),i.__metadata("design:paramtypes",[o.ElementRef,o.Renderer2,r.DragResizeService,Boolean])],e)}(a.Button);e.WindowMaximizeActionDirective=d},function(t,e){t.exports=p},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n(2),o=n(3),r=n(16),a=n(30),s=n(5),d=function(t){function e(e,n,i,o){var r=t.call(this,e,n,null,o)||this;return r.window=i,r.look="bare",r.icon="window-minimize",r}return i.__extends(e,t),e.prototype.onClick=function(){this.window.minimizeAction()},Object.defineProperty(e.prototype,"visible",{get:function(){return"default"===this.window.options.state?"inline-flex":"none"},enumerable:!0,configurable:!0}),i.__decorate([o.Input(),i.__metadata("design:type",Object)],e.prototype,"window",void 0),i.__decorate([o.HostListener("click"),i.__metadata("design:type",Function),i.__metadata("design:paramtypes",[]),i.__metadata("design:returntype",void 0)],e.prototype,"onClick",null),i.__decorate([o.HostBinding("style.display"),i.__metadata("design:type",String),i.__metadata("design:paramtypes",[])],e.prototype,"visible",null),e=i.__decorate([o.Directive({exportAs:"kendoWindowMinimizeAction",selector:"button[kendoWindowMinimizeAction]"}),i.__param(2,o.Optional()),i.__param(3,o.Optional()),i.__param(3,o.Inject(s.RTL)),i.__metadata("design:paramtypes",[o.ElementRef,o.Renderer2,r.DragResizeService,Boolean])],e)}(a.Button);e.WindowMinimizeActionDirective=d},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n(2),o=n(3),r=n(30),a=n(5),s=n(16),d=function(t){function e(e,n,i,o){var r=t.call(this,e,n,null,o)||this;return r.window=i,r.look="bare",r.icon="close",r}return i.__extends(e,t),e.prototype.onClick=function(){this.window.closeAction()},i.__decorate([o.Input(),i.__metadata("design:type",Object)],e.prototype,"window",void 0),i.__decorate([o.HostListener("click"),i.__metadata("design:type",Function),i.__metadata("design:paramtypes",[]),i.__metadata("design:returntype",void 0)],e.prototype,"onClick",null),e=i.__decorate([o.Directive({exportAs:"kendoWindowCloseAction",selector:"button[kendoWindowCloseAction]"}),i.__param(2,o.Optional()),i.__param(3,o.Optional()),i.__param(3,o.Inject(a.RTL)),i.__metadata("design:paramtypes",[o.ElementRef,o.Renderer2,s.DragResizeService,Boolean])],e)}(r.Button);e.WindowCloseActionDirective=d},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n(2),o=n(3),r=n(16),a=n(30),s=n(5),d=function(t){function e(e,n,i,o){var r=t.call(this,e,n,null,o)||this;return r.window=i,r.look="bare",r.icon="window-restore",r}return i.__extends(e,t),e.prototype.onClick=function(){this.window.restoreAction()},Object.defineProperty(e.prototype,"visible",{get:function(){return"default"===this.window.options.state?"none":"inline-flex"},enumerable:!0,configurable:!0}),i.__decorate([o.Input(),i.__metadata("design:type",Object)],e.prototype,"window",void 0),i.__decorate([o.HostListener("click"),i.__metadata("design:type",Function),i.__metadata("design:paramtypes",[]),i.__metadata("design:returntype",void 0)],e.prototype,"onClick",null),i.__decorate([o.HostBinding("style.display"),i.__metadata("design:type",String),i.__metadata("design:paramtypes",[])],e.prototype,"visible",null),e=i.__decorate([o.Directive({exportAs:"kendoWindowRestoreAction",selector:"button[kendoWindowRestoreAction]"}),i.__param(2,o.Optional()),i.__param(3,o.Optional()),i.__param(3,o.Inject(s.RTL)),i.__metadata("design:paramtypes",[o.ElementRef,o.Renderer2,r.DragResizeService,Boolean])],e)}(a.Button);e.WindowRestoreActionDirective=d},function(t,e){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var n=function(){return function(){}}();e.WindowSettings=n;var i=function(){return function(){}}();e.WindowCloseResult=i;var o=function(){return function(){}}();e.WindowRef=o},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n(2),o=n(3),r=n(36),a=n(34),s=n(14),d=n(21),c=n(9),p=n(10),u=n(11),l=function(){function t(t,e){this.getWindowRef=t,this.parentInjector=e}return t.prototype.get=function(t,e){return t===a.WindowRef?this.getWindowRef():this.parentInjector.get(t,e)},t}(),g=function(){function t(t,e){this.resolver=t,this.containerService=e}return t.prototype.open=function(t){var e=this.resolver.resolveComponentFactory(s.WindowComponent),n=t.appendTo||this.containerService.container;if(!n)throw new Error("Cannot attach window to the page.\n Add an element that uses the kendoWindowContainer directive, or set the 'appendTo' property.");var i={close:function(){},content:null,result:null,window:null},o=this.contentFrom(t.content,n,i),r=n.createComponent(e,void 0,void 0,o.nodes);i.window=r,this.applyOptions(r.instance,t);var d=new c.Subject,l=function(t){d.next(t||new a.WindowCloseResult),o.componentRef&&o.componentRef.destroy(),r.destroy()},g=p.merge(d,r.instance.close).pipe(u.take(1));return g.subscribe(l),i.close=l,i.result=g,i},t.prototype.applyOptions=function(t,e){d.isPresent(e.title)&&(t.title=e.title),d.isPresent(e.keepContent)&&(t.keepContent=e.keepContent),d.isPresent(e.width)&&(t.width=e.width),d.isPresent(e.minWidth)&&(t.minWidth=e.minWidth),d.isPresent(e.height)&&(t.height=e.height),d.isPresent(e.minHeight)&&(t.minHeight=e.minHeight),d.isPresent(e.left)&&(t.left=e.left),d.isPresent(e.top)&&(t.top=e.top),d.isPresent(e.draggable)&&(t.draggable=e.draggable),d.isPresent(e.resizable)&&(t.resizable=e.resizable),d.isPresent(e.state)&&(t.state=e.state,"minimized"===e.state&&(t.keepContent=!0)),e.content instanceof o.TemplateRef&&(t.contentTemplate=e.content),e.titleBarContent instanceof o.TemplateRef&&(t.titleBarTemplate=e.titleBarContent)},t.prototype.contentFrom=function(t,e,n){var i=e.injector.get(o.Renderer2),r=[],a=null;if("string"==typeof t)r=[i.createText(t)];else if(t&&!(t instanceof o.TemplateRef)){var s=new l(function(){return n},e.injector),d=this.resolver.resolveComponentFactory(t);r=[(a=e.createComponent(d,void 0,s)).location.nativeElement],n.content=a}return{componentRef:a,nodes:[[],r]}},t=i.__decorate([o.Injectable(),i.__metadata("design:paramtypes",[o.ComponentFactoryResolver,r.WindowContainerService])],t)}();e.WindowService=g},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n(2),o=n(3),r=function(){function t(){}return e=t,Object.defineProperty(t.prototype,"container",{get:function(){return e.container},set:function(t){e.container=t},enumerable:!0,configurable:!0}),t=e=i.__decorate([o.Injectable()],t);var e}();e.WindowContainerService=r},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n(2),o=n(3),r=n(1),a=n(7),s=n(8),d=n(38),c=n(12),p=n(39);e.DIALOG_DIRECTIVES=[r.DialogComponent,a.DialogTitleBarComponent];var u=function(){function t(){}return t=i.__decorate([o.NgModule({declarations:[e.DIALOG_DIRECTIVES,d.DialogContainerDirective],entryComponents:[e.DIALOG_DIRECTIVES],exports:[e.DIALOG_DIRECTIVES,p.SHARED_DIRECTIVES,d.DialogContainerDirective],imports:[p.SharedModule],providers:[c.DialogContainerService,s.DialogService]})],t)}();e.DialogModule=u},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n(2),o=n(3),r=n(12),a=function(){function t(t,e){e.container=t}return t=i.__decorate([o.Directive({selector:"[kendoDialogContainer]"}),i.__metadata("design:paramtypes",[o.ViewContainerRef,r.DialogContainerService])],t)}();e.DialogContainerDirective=a},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n(2),o=n(3),r=n(40),a=n(6);e.SHARED_DIRECTIVES=[a.DialogActionsComponent];var s=function(){function t(){}return t=i.__decorate([o.NgModule({declarations:[e.SHARED_DIRECTIVES],exports:[e.SHARED_DIRECTIVES,r.CommonModule],imports:[r.CommonModule]})],t)}();e.SharedModule=s},function(t,e){t.exports=_},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n(2),o=n(3),r=n(14),a=n(28),s=n(26),d=n(25),c=n(29),p=n(31),u=n(32),l=n(33),g=n(35),m=n(36),f=n(42),h=n(39),_=[s.DraggableDirective,d.ResizeHandleDirective,r.WindowComponent,a.WindowTitleBarComponent,u.WindowCloseActionDirective,p.WindowMinimizeActionDirective,c.WindowMaximizeActionDirective,l.WindowRestoreActionDirective],y=[r.WindowComponent,a.WindowTitleBarComponent],v=[r.WindowComponent,u.WindowCloseActionDirective,p.WindowMinimizeActionDirective,c.WindowMaximizeActionDirective,l.WindowRestoreActionDirective,a.WindowTitleBarComponent],b=function(){function t(){}return t=i.__decorate([o.NgModule({declarations:[_,f.WindowContainerDirective],entryComponents:[y],exports:[v,h.SHARED_DIRECTIVES,f.WindowContainerDirective],imports:[h.SharedModule],providers:[m.WindowContainerService,g.WindowService]})],t)}();e.WindowModule=b},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n(2),o=n(3),r=n(36),a=function(){function t(t,e){e.container=t}return t=i.__decorate([o.Directive({selector:"[kendoWindowContainer]"}),i.__metadata("design:paramtypes",[o.ViewContainerRef,r.WindowContainerService])],t)}();e.WindowContainerDirective=a},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n(2),o=n(3),r=n(37),a=n(41),s=function(){function t(){}return t=i.__decorate([o.NgModule({exports:[r.DialogModule,a.WindowModule]})],t)}();e.DialogsModule=s}])}}}); | ||
System.register("@progress/kendo-angular-dialog",["tslib","@angular/core","@progress/kendo-angular-l10n","@angular/animations","rxjs/Subject","rxjs/operators/take","rxjs/observable/merge","rxjs/Subscription","rxjs/observable/of","@progress/kendo-angular-buttons","@telerik/kendo-draggable","rxjs/operators/tap","rxjs/operators/switchMap","rxjs/operators/takeUntil","rxjs/operators/map","@progress/kendo-popup-common","rxjs/operators/delay","@angular/common"],function(t){var e,n,i,o,r,a,s,d,c,p,u,l,g,m,f,h,_,y;function v(t){return t.__useDefault?t.default:t}return{setters:[function(t){e=v(t)},function(t){n=v(t)},function(t){i=v(t)},function(t){o=v(t)},function(t){r=v(t)},function(t){a=v(t)},function(t){s=v(t)},function(t){d=v(t)},function(t){c=v(t)},function(t){p=v(t)},function(t){u=v(t)},function(t){l=v(t)},function(t){g=v(t)},function(t){m=v(t)},function(t){f=v(t)},function(t){h=v(t)},function(t){_=v(t)},function(t){y=v(t)}],execute:function(){!function(t){var e={};function n(i){if(e[i])return e[i].exports;var o=e[i]={exports:{},id:i,loaded:!1};return t[i].call(o.exports,o,o.exports,n),o.loaded=!0,o.exports}n.m=t,n.c=e,n.p="",n(0)}([function(e,n,i){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o=i(1);n.DialogComponent=o.DialogComponent;var r=i(7);n.DialogTitleBarComponent=r.DialogTitleBarComponent;var a=i(6);n.DialogActionsComponent=a.DialogActionsComponent;var s=i(8);n.DialogService=s.DialogService;var d=i(13);n.DialogCloseResult=d.DialogCloseResult,n.DialogRef=d.DialogRef,n.DialogSettings=d.DialogSettings,n.DialogAction=d.DialogAction;var c=i(14);n.WindowComponent=c.WindowComponent;var p=i(28);n.WindowTitleBarComponent=p.WindowTitleBarComponent;var u=i(29);n.WindowMaximizeActionDirective=u.WindowMaximizeActionDirective;var l=i(31);n.WindowMinimizeActionDirective=l.WindowMinimizeActionDirective;var g=i(32);n.WindowCloseActionDirective=g.WindowCloseActionDirective;var m=i(33);n.WindowRestoreActionDirective=m.WindowRestoreActionDirective;var f=i(34);n.WindowSettings=f.WindowSettings,n.WindowRef=f.WindowRef,n.WindowCloseResult=f.WindowCloseResult;var h=i(35);n.WindowService=h.WindowService;var _=i(37);n.DialogModule=_.DialogModule;var y=i(41);n.WindowModule=y.WindowModule;var v=i(43);n.DialogsModule=v.DialogsModule,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 i=n(2),o=n(3),r=n(4),a=n(5),s=n(6),d=n(7),c=function(){function t(t,e,n){this._elRef=t,this._renderer=e,this.action=new o.EventEmitter,this.close=new o.EventEmitter,this.subscriptions=[],this.direction=n?"rtl":"ltr"}return Object.defineProperty(t.prototype,"dir",{get:function(){return this.direction},enumerable:!0,configurable:!0}),t.prototype.ngAfterContentInit=function(){this.bubble("close",this.titlebarContent)},t.prototype.ngAfterViewInit=function(){this.bubble("close",this.titlebarView),this.bubble("action",this.actionsView)},t.prototype.ngOnInit=function(){this._renderer.removeAttribute(this._elRef.nativeElement,"title")},t.prototype.ngOnDestroy=function(){this.subscriptions.forEach(function(t){return t.unsubscribe()}),this.subscriptions=[]},Object.defineProperty(t.prototype,"wrapperClass",{get:function(){return!0},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"styles",{get:function(){var t={};return this.width&&(t.width=this.width+"px"),this.height&&(t.height=this.height+"px"),this.minWidth&&(t.minWidth=this.minWidth+"px"),t},enumerable:!0,configurable:!0}),t.prototype.bubble=function(t,e){var n=this;if(e){var i=e[t].subscribe(function(e){return n[t].emit(e)});this.subscriptions.push(i)}},i.__decorate([o.Input(),i.__metadata("design:type",String)],t.prototype,"title",void 0),i.__decorate([o.Input(),i.__metadata("design:type",String)],t.prototype,"actions",void 0),i.__decorate([o.Input(),i.__metadata("design:type",Number)],t.prototype,"width",void 0),i.__decorate([o.Input(),i.__metadata("design:type",Number)],t.prototype,"minWidth",void 0),i.__decorate([o.Input(),i.__metadata("design:type",Number)],t.prototype,"height",void 0),i.__decorate([o.Output(),i.__metadata("design:type",o.EventEmitter)],t.prototype,"action",void 0),i.__decorate([o.Output(),i.__metadata("design:type",o.EventEmitter)],t.prototype,"close",void 0),i.__decorate([o.HostBinding("attr.dir"),i.__metadata("design:type",String),i.__metadata("design:paramtypes",[])],t.prototype,"dir",null),i.__decorate([o.ContentChild(d.DialogTitleBarComponent),i.__metadata("design:type",d.DialogTitleBarComponent)],t.prototype,"titlebarContent",void 0),i.__decorate([o.ViewChild(d.DialogTitleBarComponent),i.__metadata("design:type",d.DialogTitleBarComponent)],t.prototype,"titlebarView",void 0),i.__decorate([o.ViewChild(s.DialogActionsComponent),i.__metadata("design:type",s.DialogActionsComponent)],t.prototype,"actionsView",void 0),i.__decorate([o.HostBinding("class.k-dialog-wrapper"),i.__metadata("design:type",Boolean),i.__metadata("design:paramtypes",[])],t.prototype,"wrapperClass",null),t=i.__decorate([o.Component({animations:[r.trigger("overlayAppear",[r.state("in",r.style({opacity:1})),r.transition("void => *",[r.style({opacity:.1}),r.animate(".3s cubic-bezier(.2, .6, .4, 1)")])]),r.trigger("dialogSlideInAppear",[r.state("in",r.style({transform:"translate(0, 0)"})),r.transition("void => *",[r.style({transform:"translate(0, -10%)"}),r.animate(".3s cubic-bezier(.2, 1, .2, 1)")])])],exportAs:"kendoDialog",selector:"kendo-dialog",template:'\n <div class="k-overlay" @overlayAppear></div>\n\n <div class="k-widget k-window k-dialog" [ngStyle]="styles" @dialogSlideInAppear>\n\n <kendo-dialog-titlebar *ngIf="title">{{title}}</kendo-dialog-titlebar>\n <ng-content select="kendo-dialog-titlebar" *ngIf="!title"></ng-content>\n\n <div class="k-content k-window-content k-dialog-content">\n <ng-content *ngIf="!contentTemplate"></ng-content>\n <ng-template [ngTemplateOutlet]="contentTemplate" *ngIf="contentTemplate"></ng-template>\n </div>\n\n <ng-content select="kendo-dialog-actions" *ngIf="!actions"></ng-content>\n <kendo-dialog-actions [actions]="actions" *ngIf="actions"></kendo-dialog-actions>\n\n </div>\n '}),i.__param(2,o.Optional()),i.__param(2,o.Inject(a.RTL)),i.__metadata("design:paramtypes",[o.ElementRef,o.Renderer2,Boolean])],t)}();e.DialogComponent=c},function(t,n){t.exports=e},function(t,e){t.exports=n},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 i=n(2),o=n(3),r=function(){function t(){this.action=new o.EventEmitter}return Object.defineProperty(t.prototype,"className",{get:function(){return!0},enumerable:!0,configurable:!0}),t.prototype.actionTemplate=function(){return this.actions instanceof o.TemplateRef},t.prototype.onButtonClick=function(t,e){this.action.emit(t)},t.prototype.buttonClass=function(t){var e=["k-button"];return t.primary&&e.push("k-primary"),e.join(" ")},i.__decorate([o.Input(),i.__metadata("design:type",Object)],t.prototype,"actions",void 0),i.__decorate([o.Output(),i.__metadata("design:type",o.EventEmitter)],t.prototype,"action",void 0),i.__decorate([o.HostBinding("class.k-button-group"),o.HostBinding("class.k-dialog-buttongroup"),o.HostBinding("class.k-dialog-button-layout-stretched"),i.__metadata("design:type",Boolean),i.__metadata("design:paramtypes",[])],t.prototype,"className",null),t=i.__decorate([o.Component({selector:"kendo-dialog-actions",template:'\n <ng-content *ngIf="!actions"></ng-content>\n <ng-container *ngIf="!actionTemplate()">\n <button\n [ngClass]="buttonClass(action)"\n (click)="onButtonClick(action, $event)"\n *ngFor="let action of actions">\n {{ action.text }}\n </button>\n </ng-container>\n <ng-template [ngTemplateOutlet]="actions" *ngIf="actionTemplate()"></ng-template>\n '})],t)}();e.DialogActionsComponent=r},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n(2),o=n(3),r=function(){function t(){this.close=new o.EventEmitter}return Object.defineProperty(t.prototype,"className",{get:function(){return!0},enumerable:!0,configurable:!0}),t.prototype.onCloseClick=function(t){t.preventDefault(),this.close.emit()},i.__decorate([o.Output(),i.__metadata("design:type",o.EventEmitter)],t.prototype,"close",void 0),i.__decorate([o.HostBinding("class.k-window-titlebar"),o.HostBinding("class.k-dialog-titlebar"),o.HostBinding("class.k-header"),i.__metadata("design:type",Boolean),i.__metadata("design:paramtypes",[])],t.prototype,"className",null),t=i.__decorate([o.Component({selector:"kendo-dialog-titlebar",template:'\n <div class="k-window-title k-dialog-title">\n <ng-content></ng-content>\n </div>\n <div class="k-window-actions k-dialog-actions">\n <a href="#" role="button"\n aria-label="Close"\n class="k-button k-bare k-button-icon k-window-action k-dialog-action k-dialog-close"\n (click)="onCloseClick($event)">\n <span class="k-icon k-i-x"></span>\n </a>\n </div>\n '})],t)}();e.DialogTitleBarComponent=r},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n(2),o=n(9),r=n(10),a=n(11),s=n(3),d=n(1),c=n(12),p=n(13),u=function(){function t(t,e){this.getDialogRef=t,this.parentInjector=e}return t.prototype.get=function(t,e){return t===p.DialogRef?this.getDialogRef():this.parentInjector.get(t,e)},t}(),l=function(){function t(t,e){this.resolver=t,this.containerService=e}return t.prototype.open=function(t){var e=this.resolver.resolveComponentFactory(d.DialogComponent),n=t.appendTo||this.containerService.container;if(!n)throw new Error("\nCannot attach dialog to the page.\nAdd an element that uses the kendoDialogContainer directive, or set the 'appendTo' property.\nSee http://www.telerik.com/kendo-angular-ui/components/dialog/service/ .\n ");var i={close:function(){},content:null,dialog:null,result:null},s=this.contentFrom(t.content,n,i),c=n.createComponent(e,void 0,void 0,s.nodes);i.dialog=c,this.applyOptions(c.instance,t);var u=new o.Subject,l=function(t){u.next(t||new p.DialogCloseResult),s.componentRef&&s.componentRef.destroy(),c.destroy()},g=r.merge(u,c.instance.close,c.instance.action).pipe(a.take(1));return g.subscribe(l),i.close=l,i.result=g,i},t.prototype.applyOptions=function(t,e){t.title=e.title,t.actions=e.actions,t.width=e.width,t.minWidth=e.minWidth,t.height=e.height,e.content instanceof s.TemplateRef&&(t.contentTemplate=e.content)},t.prototype.contentFrom=function(t,e,n){var i=e.injector.get(s.Renderer2),o=[],r=null;if("string"==typeof t)o=[i.createText(t)];else if(t&&!(t instanceof s.TemplateRef)){var a=new u(function(){return n},e.injector),d=this.resolver.resolveComponentFactory(t);o=[(r=e.createComponent(d,void 0,a)).location.nativeElement],n.content=r}return{componentRef:r,nodes:[[],o,[]]}},t=i.__decorate([s.Injectable(),i.__metadata("design:paramtypes",[s.ComponentFactoryResolver,c.DialogContainerService])],t)}();e.DialogService=l},function(t,e){t.exports=r},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 i=n(2),o=n(3),r=function(){function t(){}return e=t,Object.defineProperty(t.prototype,"container",{get:function(){return e.container},set:function(t){e.container=t},enumerable:!0,configurable:!0}),t=e=i.__decorate([o.Injectable()],t);var e}();e.DialogContainerService=r},function(t,e){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var n=function(){return function(){}}();e.DialogAction=n;var i=function(){return function(){}}();e.DialogCloseResult=i;var o=function(){return function(){}}();e.DialogSettings=o;var r=function(){return function(){}}();e.DialogRef=r},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n(2),o=n(3),r=n(5),a=n(5),s=n(15),d=n(16),c=n(21),p=n(21),u=n(25),l=n(28),g=function(){function t(t,e,n,i,r){this.el=t,this.renderer=e,this.service=n,this.ngZone=i,this.keepContent=!1,this.dragStart=new o.EventEmitter,this.dragEnd=new o.EventEmitter,this.resizeStart=new o.EventEmitter,this.resizeEnd=new o.EventEmitter,this.close=new o.EventEmitter,this.widthChange=new o.EventEmitter,this.heightChange=new o.EventEmitter,this.topChange=new o.EventEmitter,this.leftChange=new o.EventEmitter,this.stateChange=new o.EventEmitter,this.tabIndex=0,this.focused=!1,this.draged=!1,this.resized=!1,this.windowSubscription=new s.Subscription,this.direction=r?"rtl":"ltr",this.resizeDirections=p.RESIZE_DIRECTIONS,this.subscribeEvents()}return Object.defineProperty(t.prototype,"draggable",{get:function(){return this.options.draggable},set:function(t){this.options.draggable=t},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"resizable",{get:function(){return this.options.resizable},set:function(t){this.options.resizable=t},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"state",{get:function(){return this.options.state},set:function(t){this.options.state=t},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"minWidth",{get:function(){return this.options.minWidth},set:function(t){this.setOption("minWidth",t)},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"minHeight",{get:function(){return this.options.minHeight},set:function(t){this.setOption("minHeight",t)},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"width",{get:function(){return this.options.width},set:function(t){this.setOption("width",t)},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"height",{get:function(){return this.options.height},set:function(t){this.setOption("height",t)},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"top",{get:function(){return this.options.top},set:function(t){this.setOption("top",t)},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"left",{get:function(){return this.options.left},set:function(t){this.setOption("left",t)},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"hostClasses",{get:function(){return!0},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"dir",{get:function(){return this.direction},enumerable:!0,configurable:!0}),t.prototype.ngAfterViewInit=function(){this.setNextZIndex(),this.setInitialOffset()},t.prototype.ngOnInit=function(){this.renderer.removeAttribute(this.el.nativeElement,"title"),this.service.init(this.el)},t.prototype.ngOnChanges=function(t){var e=this;if(c.OFFSET_STYLES.forEach(function(n){c.isChanged(n,t)&&e.updateOffset(n,e.options[n])}),c.isChanged("draggable",t)){var n=c.isPresent(this.titleBarContent)?this.titleBarContent:this.titleBarView;c.isTruthy(t.draggable.currentValue)?n.subscribeDrag():n.unsubscribeDrag()}},t.prototype.ngOnDestroy=function(){this.windowSubscription&&this.windowSubscription.unsubscribe()},Object.defineProperty(t.prototype,"showDefaultTitleBar",{get:function(){return!c.isPresent(this.titleBarContent)},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"windowClasses",{get:function(){return!0},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"styleMinWidth",{get:function(){return this.minWidth+"px"},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"styleMinHeight",{get:function(){return this.minHeight+"px"},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"stylePosition",{get:function(){return this.options.position},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"wrapperMaximizedClass",{get:function(){return"maximized"===this.state},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"wrapperFocusedClass",{get:function(){return this.focused},enumerable:!0,configurable:!0}),t.prototype.onComponentFocus=function(){this.focused=!0,this.setNextZIndex()},t.prototype.onComponentBlur=function(){this.focused=!1},t.prototype.subscribeEvents=function(){var t=this;p.isDocumentAvailable()&&(this.windowSubscription.add(this.service.focus.subscribe(function(){t.el.nativeElement.focus()})),this.windowSubscription.add(this.service.dragStart.subscribe(function(){t.draged=!0,t.ngZone.run(function(){t.dragStart.emit()})})),this.windowSubscription.add(this.service.dragEnd.subscribe(function(){t.draged&&(t.draged=!1,t.ngZone.run(function(){t.dragEnd.emit()}))})),this.windowSubscription.add(this.service.close.subscribe(function(){t.close.emit()})),this.windowSubscription.add(this.service.resizeStart.subscribe(function(){t.resized=!0,t.ngZone.run(function(){t.resizeStart.emit()})})),this.windowSubscription.add(this.service.resizeEnd.subscribe(function(){t.resized&&(t.resized=!1,t.ngZone.run(function(){t.resizeEnd.emit()}))})),this.windowSubscription.add(this.service.change.subscribe(function(e){c.OFFSET_STYLES.forEach(function(n){if(c.isPresent(e[n])&&(t.updateOffset(n,e[n]),"maximized"!==t.state)){var i=t[n+"Change"];i.observers.length&&t.ngZone.run(function(){i.emit(e[n])})}})})),this.windowSubscription.add(this.service.stateChange.subscribe(function(e){t.updateAllOffset(),t.stateChange.emit(e)})))},t.prototype.setNextZIndex=function(){this.renderer.setStyle(this.el.nativeElement,"z-index",this.service.nextZIndex)},t.prototype.setInitialOffset=function(){"maximized"!==this.state&&this.updateAllOffset(),c.isPresent(this.left)||c.isPresent(this.top)||"maximized"===this.state||this.service.center()},t.prototype.updateAllOffset=function(){var t=this;c.OFFSET_STYLES.forEach(function(e){c.isPresent(t[e])&&t.updateOffset(e,t[e])})},t.prototype.updateOffset=function(t,e){this.renderer.setStyle(this.el.nativeElement,t,e+"px")},Object.defineProperty(t.prototype,"options",{get:function(){return this.service.options},enumerable:!0,configurable:!0}),t.prototype.setOption=function(t,e){if("number"==typeof e)this.options[t]=e;else{if("string"!=typeof e)throw new Error("Invalid type used for "+t);this.options[t]=parseInt(e,10)}},i.__decorate([o.Input(),i.__metadata("design:type",String)],t.prototype,"title",void 0),i.__decorate([o.Input(),i.__metadata("design:type",Boolean),i.__metadata("design:paramtypes",[Boolean])],t.prototype,"draggable",null),i.__decorate([o.Input(),i.__metadata("design:type",Boolean),i.__metadata("design:paramtypes",[Boolean])],t.prototype,"resizable",null),i.__decorate([o.Input(),i.__metadata("design:type",Boolean)],t.prototype,"keepContent",void 0),i.__decorate([o.Input(),i.__metadata("design:type",String),i.__metadata("design:paramtypes",[String])],t.prototype,"state",null),i.__decorate([o.Input(),i.__metadata("design:type",Number),i.__metadata("design:paramtypes",[Number])],t.prototype,"minWidth",null),i.__decorate([o.Input(),i.__metadata("design:type",Number),i.__metadata("design:paramtypes",[Number])],t.prototype,"minHeight",null),i.__decorate([o.Input(),i.__metadata("design:type",Number),i.__metadata("design:paramtypes",[Number])],t.prototype,"width",null),i.__decorate([o.Input(),i.__metadata("design:type",Number),i.__metadata("design:paramtypes",[Number])],t.prototype,"height",null),i.__decorate([o.Input(),i.__metadata("design:type",Number),i.__metadata("design:paramtypes",[Number])],t.prototype,"top",null),i.__decorate([o.Input(),i.__metadata("design:type",Number),i.__metadata("design:paramtypes",[Number])],t.prototype,"left",null),i.__decorate([o.Output(),i.__metadata("design:type",o.EventEmitter)],t.prototype,"dragStart",void 0),i.__decorate([o.Output(),i.__metadata("design:type",o.EventEmitter)],t.prototype,"dragEnd",void 0),i.__decorate([o.Output(),i.__metadata("design:type",o.EventEmitter)],t.prototype,"resizeStart",void 0),i.__decorate([o.Output(),i.__metadata("design:type",o.EventEmitter)],t.prototype,"resizeEnd",void 0),i.__decorate([o.Output(),i.__metadata("design:type",o.EventEmitter)],t.prototype,"close",void 0),i.__decorate([o.Output(),i.__metadata("design:type",o.EventEmitter)],t.prototype,"widthChange",void 0),i.__decorate([o.Output(),i.__metadata("design:type",o.EventEmitter)],t.prototype,"heightChange",void 0),i.__decorate([o.Output(),i.__metadata("design:type",o.EventEmitter)],t.prototype,"topChange",void 0),i.__decorate([o.Output(),i.__metadata("design:type",o.EventEmitter)],t.prototype,"leftChange",void 0),i.__decorate([o.Output(),i.__metadata("design:type",o.EventEmitter)],t.prototype,"stateChange",void 0),i.__decorate([o.HostBinding("attr.tabIndex"),i.__metadata("design:type",Number)],t.prototype,"tabIndex",void 0),i.__decorate([o.HostBinding("class.k-widget"),o.HostBinding("class.k-window"),i.__metadata("design:type",Boolean),i.__metadata("design:paramtypes",[])],t.prototype,"hostClasses",null),i.__decorate([o.HostBinding("attr.dir"),i.__metadata("design:type",String),i.__metadata("design:paramtypes",[])],t.prototype,"dir",null),i.__decorate([o.ViewChild(l.WindowTitleBarComponent),i.__metadata("design:type",l.WindowTitleBarComponent)],t.prototype,"titleBarView",void 0),i.__decorate([o.ContentChild(l.WindowTitleBarComponent),i.__metadata("design:type",l.WindowTitleBarComponent)],t.prototype,"titleBarContent",void 0),i.__decorate([o.ViewChildren(u.ResizeHandleDirective),i.__metadata("design:type",o.QueryList)],t.prototype,"resizeHandles",void 0),i.__decorate([o.HostBinding("class.k-window-wrapper"),i.__metadata("design:type",Boolean),i.__metadata("design:paramtypes",[])],t.prototype,"windowClasses",null),i.__decorate([o.HostBinding("style.minWidth"),i.__metadata("design:type",String),i.__metadata("design:paramtypes",[])],t.prototype,"styleMinWidth",null),i.__decorate([o.HostBinding("style.minHeight"),i.__metadata("design:type",String),i.__metadata("design:paramtypes",[])],t.prototype,"styleMinHeight",null),i.__decorate([o.HostBinding("style.position"),i.__metadata("design:type",String),i.__metadata("design:paramtypes",[])],t.prototype,"stylePosition",null),i.__decorate([o.HostBinding("class.k-window-maximized"),i.__metadata("design:type",Boolean),i.__metadata("design:paramtypes",[])],t.prototype,"wrapperMaximizedClass",null),i.__decorate([o.HostBinding("class.k-state-focused"),i.__metadata("design:type",Boolean),i.__metadata("design:paramtypes",[])],t.prototype,"wrapperFocusedClass",null),i.__decorate([o.HostListener("focus"),i.__metadata("design:type",Function),i.__metadata("design:paramtypes",[]),i.__metadata("design:returntype",void 0)],t.prototype,"onComponentFocus",null),i.__decorate([o.HostListener("blur"),i.__metadata("design:type",Function),i.__metadata("design:paramtypes",[]),i.__metadata("design:returntype",void 0)],t.prototype,"onComponentBlur",null),t=i.__decorate([o.Component({exportAs:"kendoWindow",providers:[d.DragResizeService,a.LocalizationService,{provide:a.L10N_PREFIX,useValue:"kendo.window"}],selector:"kendo-window",template:'\n <kendo-window-titlebar *ngIf="showDefaultTitleBar" [template]="titleBarTemplate">\n <div class="k-window-title">{{title}}</div>\n <button kendoWindowMinimizeAction></button>\n <button kendoWindowMaximizeAction></button>\n <button kendoWindowRestoreAction></button>\n <button kendoWindowCloseAction></button>\n </kendo-window-titlebar>\n <ng-content select="kendo-window-titlebar" *ngIf="!showDefaultTitleBar"></ng-content>\n\n <div *ngIf="state !== \'minimized\' || keepContent"\n [hidden]="state === \'minimized\' && keepContent"\n class="k-content k-window-content">\n <ng-content *ngIf="!contentTemplate"></ng-content>\n <ng-template [ngTemplateOutlet]="contentTemplate" *ngIf="contentTemplate"></ng-template>\n </div>\n\n <ng-template [ngIf]=\'resizable\'>\n <div *ngFor=\'let dir of resizeDirections\'\n [direction]="dir"\n kendoWindowResizeHandle\n kendoWindowDraggable>\n </div>\n </ng-template>\n '}),i.__param(4,o.Optional()),i.__param(4,o.Inject(r.RTL)),i.__metadata("design:paramtypes",[o.ElementRef,o.Renderer2,d.DragResizeService,o.NgZone,Boolean])],t)}();e.WindowComponent=g},function(t,e){t.exports=d},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n(2),o=n(3),r=n(15),a=n(17),s=n(18),d=n(19),c=n(20),p=n(21),u=n(24),l=10002,g={draggable:!0,height:null,left:null,minHeight:100,minWidth:120,position:"absolute",resizable:!0,state:"default",top:null,width:null},m=function(t,e){return function(n){return t.kendo.drag.pipe(c.takeUntil(t.kendo.release.pipe(a.tap(function(){e.emit()}))),s.map(function(t){var e=t.pageX,i=t.pageY;return{originalX:n.pageX,originalY:n.pageY,pageX:e,pageY:i}}))}},f=function(){function t(t){this.ngZone=t,this.close=new o.EventEmitter,this.focus=new o.EventEmitter,this.change=new o.EventEmitter,this.stateChange=new o.EventEmitter,this.dragStart=new o.EventEmitter,this.dragEnd=new o.EventEmitter,this.resizeStart=new o.EventEmitter,this.resizeEnd=new o.EventEmitter,this.options=Object.assign({},g),this.subscriptions=new r.Subscription,this.dragSubscription=new r.Subscription}return t.prototype.ngOnDestroy=function(){this.subscriptions&&this.subscriptions.unsubscribe(),this.dragSubscription&&this.dragSubscription.unsubscribe()},t.prototype.init=function(t){this.window=t,"minimized"===this.options.state&&(this.restoreOptions=Object.assign({},this.options),this.options.height=0,this.options.minHeight=0)},t.prototype.onDrag=function(t){var e=this;this.subscriptions.add(this.ngZone.runOutsideAngular(function(){var n,i;e.dragSubscription=t.kendo.press.pipe(a.tap(function(t){p.preventDefault(t),e.focus.emit(),n=e.currentPosition(),i=!1}),d.switchMap(p.preventOnDblClick(t.kendo.release)),d.switchMap(m(t,e.dragEnd))).subscribe(function(t){var o=t.pageX,r=t.pageY,a=t.originalX,s=t.originalY;i||(e.dragStart.emit(),i=!0),e.handleDrag({originalX:a,originalY:s,pageX:o,pageY:r,startPosition:n})})}))},t.prototype.handleDrag=function(t){var e=t.originalX,n=t.originalY,i=t.pageX,o=t.pageY,r=t.startPosition;this.options.left=r.x+i-e,this.options.top=r.y+o-n,"minimized"===this.options.state&&p.isPresent(this.restoreOptions)&&(this.restoreOptions.left=this.options.left,this.restoreOptions.top=this.options.top),this.change.emit({left:r.x+i-e,top:r.y+o-n})},t.prototype.onResize=function(t,e){var n=this;this.subscriptions.add(this.ngZone.runOutsideAngular(function(){var i,o=!1;t.kendo.press.pipe(a.tap(function(t){p.preventDefault(t),n.focus.emit(),i=n.currentOffsetAndPosition(),o=!1}),d.switchMap(p.preventOnDblClick(t.kendo.release)),d.switchMap(m(t,n.resizeEnd))).subscribe(function(t){var r=t.pageX,a=t.pageY,s=t.originalX,d=t.originalY;o||(n.resizeStart.emit(e),o=!0);var c=r-s,p=a-d;n.handleResize(i,e,c,p)})}))},t.prototype.handleResize=function(t,e,n,i){var o=this,r=this.options,a={};e.indexOf("e")>=0&&((c=t.width+n)!==r.width&&c>=r.minWidth&&(a.width=c));if(e.indexOf("n")>=0){var s=t.height-i,d=t.y+i;s!==r.height&&s>=r.minHeight&&d!==r.top&&(a.height=s,a.top=d)}e.indexOf("s")>=0&&((s=t.height+i)!==r.height&&s>=r.minHeight&&(a.height=s));if(e.indexOf("w")>=0){var c,u=t.x+n;(c=t.width-n)!==r.width&&c>=r.minWidth&&u!==r.left&&(a.width=c,a.left=u)}(p.isPresent(a.width)||p.isPresent(a.height))&&(p.OFFSET_STYLES.forEach(function(t){p.isPresent(a[t])&&(o.options[t]=a[t])}),this.change.emit(a))},t.prototype.restoreAction=function(){p.isPresent(this.restoreOptions)&&(this.options=Object.assign({},this.restoreOptions)),this.options.state="default",this.stateChange.emit("default")},t.prototype.storeOptions=function(){if(this.restoreOptions=Object.assign({},this.options),!p.isPresent(this.options.width)||!p.isPresent(this.options.height)){var t=u.offset(this.window.nativeElement);this.restoreOptions.width=t.width,this.restoreOptions.height=t.height}},t.prototype.maximizeAction=function(){if("maximized"!==this.options.state){this.storeOptions();var t=u.getWindowViewPort(this.window.nativeElement);this.options=Object.assign({},this.options,{height:t.height,left:0,position:"fixed",state:"maximized",top:0,width:t.width}),this.stateChange.emit("maximized")}},t.prototype.minimizeAction=function(){"minimized"!==this.options.state&&(this.storeOptions(),this.options=Object.assign({},this.options,{height:0,minHeight:0,state:"minimized"}),this.stateChange.emit("minimized"))},t.prototype.closeAction=function(){this.close.emit()},t.prototype.center=function(){if("maximized"!==this.options.state){var t=u.scrollPosition(this.window.nativeElement),e=u.getWindowViewPort(this.window.nativeElement),n=u.offset(this.window.nativeElement);this.options.left=t.x+Math.max(0,(e.width-n.width)/2),this.options.top=t.y+Math.max(0,(e.height-n.height)/2),this.change.emit({left:this.options.left,top:this.options.top})}},t.prototype.currentOffsetAndPosition=function(){var t=this.options,e=u.offset(this.window.nativeElement);return Object.assign({},this.currentPosition(),{height:t.height?t.height:e.height,width:t.width?t.width:e.width})},t.prototype.currentPosition=function(){var t=this.options;return t.top&&t.left||this.setPosition(),{x:this.options.left,y:this.options.top}},t.prototype.setPosition=function(){var t=u.positionWithScroll(this.window.nativeElement,u.getDocumentElement(this.window.nativeElement));this.options.left=t.left,this.options.top=t.top},Object.defineProperty(t.prototype,"nextZIndex",{get:function(){return l++},enumerable:!0,configurable:!0}),t=i.__decorate([o.Injectable(),i.__metadata("design:paramtypes",[o.NgZone])],t)}();e.DragResizeService=f},function(t,e){t.exports=l},function(t,e){t.exports=f},function(t,e){t.exports=g},function(t,e){t.exports=m},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n(22),o=n(23),r=n(20);e.isPresent=function(t){return null!==t&&void 0!==t},e.isTruthy=function(t){return!!t};var a=function(t){return String(t).trim().split(" ")},s=/^(?:a|input|select|textarea|button|object)$/i;e.hasClasses=function(t,e){var n=a(e);return Boolean(a(t.className).find(function(t){return n.indexOf(t)>=0}))},e.isVisible=function(t){var e=t.getBoundingClientRect();return!(!e.width||!e.height)&&"hidden"!==window.getComputedStyle(t).visibility},e.isFocusable=function(t,n){if(void 0===n&&(n=!0),t.tagName){var i=t.tagName.toLowerCase(),o=t.getAttribute("tabIndex"),r=null!==o&&!isNaN(o)&&o>-1;return(s.test(i)?!t.disabled:r)&&(!n||e.isVisible(t))}return!1},e.isChanged=function(t,e,n){return void 0===n&&(n=!0),e[t]&&(!e[t].isFirstChange()||!n)&&e[t].previousValue!==e[t].currentValue},e.preventDefault=function(t){var e=t.originalEvent;e.stopPropagation(),e.preventDefault()},e.isDocumentAvailable=function(){return"undefined"!=typeof document&&!!document.body},e.isWindowAvailable=function(){return"undefined"!=typeof window},e.preventOnDblClick=function(t){return function(e){return i.of(e).pipe(o.delay(150),r.takeUntil(t))}},e.RESIZE_DIRECTIONS=["n","e","s","w","se","sw","ne","nw"],e.OFFSET_STYLES=["top","left","width","height"]},function(t,e){t.exports=c},function(t,e){t.exports=_},function(t,e){t.exports=h},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n(2),o=n(3),r=n(26),a=n(16),s=n(15),d=n(22),c=n(10),p=function(){function t(t,e,n,i){this.draggable=t,this.el=e,this.renderer=n,this.service=i,this.subscriptions=new s.Subscription}return Object.defineProperty(t.prototype,"hostClass",{get:function(){return!0},enumerable:!0,configurable:!0}),t.prototype.ngOnInit=function(){var t=this;this.setDisplay(),this.renderer.addClass(this.el.nativeElement,"k-resize-"+this.direction),this.subscriptions.add(d.of(this.draggable).subscribe(function(e){t.service.onResize(e,t.direction)})),this.subscriptions.add(this.service.resizeStart.subscribe(function(e){e!==t.direction&&t.setDisplay("none")})),this.subscriptions.add(this.service.dragStart.subscribe(function(){t.setDisplay("none")})),this.subscriptions.add(c.merge(this.service.resizeEnd,this.service.dragEnd).subscribe(function(){t.setDisplay("block")})),this.subscriptions.add(this.service.stateChange.subscribe(function(e){t.setDisplay("default"===e?"block":"none")}))},t.prototype.ngOnDestroy=function(){this.subscriptions.unsubscribe()},t.prototype.setDisplay=function(t){void 0===t&&(t="block"),this.renderer.setStyle(this.el.nativeElement,"display","default"===this.service.options.state?t:"none")},i.__decorate([o.Input(),i.__metadata("design:type",String)],t.prototype,"direction",void 0),i.__decorate([o.HostBinding("class.k-resize-handle"),i.__metadata("design:type",Boolean),i.__metadata("design:paramtypes",[])],t.prototype,"hostClass",null),t=i.__decorate([o.Directive({selector:"[kendoWindowResizeHandle]"}),i.__param(0,o.Host()),i.__metadata("design:paramtypes",[r.DraggableDirective,o.ElementRef,o.Renderer2,a.DragResizeService])],t)}();e.ResizeHandleDirective=p},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n(2),o=n(3),r=n(27),a=function(){function t(t,e){this.elem=t,this.ngZone=e,this.kendo={drag:new o.EventEmitter,press:new o.EventEmitter,release:new o.EventEmitter}}return t.prototype.ngOnInit=function(){var t=this;"undefined"!=typeof document&&(this.draggable=new r.default({drag:function(e){return t.kendo.drag.next(e)},press:function(e){return t.kendo.press.next(e)},release:function(e){return t.kendo.release.next(e)}}),this.ngZone.runOutsideAngular(function(){return t.draggable.bindTo(t.elem.nativeElement)}))},t.prototype.ngOnDestroy=function(){"undefined"!=typeof document&&this.draggable.destroy()},Object.defineProperty(t.prototype,"nativeElement",{get:function(){return this.elem.nativeElement},enumerable:!0,configurable:!0}),t=i.__decorate([o.Directive({outputs:["kendo.press","kendo.drag","kendo.release"],selector:"[kendoWindowDraggable]"}),i.__metadata("design:paramtypes",[o.ElementRef,o.NgZone])],t)}();e.DraggableDirective=a},function(t,e){t.exports=u},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n(2),o=n(3),r=n(26),a=n(16),s=n(15),d=n(22),c=n(21),p=function(){function t(t,e,n){this.el=t,this.service=e,this.ngZone=n,this.dragSubscription=new s.Subscription}return t.prototype.ngOnInit=function(){this.dragDirective=new r.DraggableDirective(this.el,this.ngZone),this.dragDirective.ngOnInit(),this.service.options.draggable&&this.subscribeDrag()},t.prototype.ngOnDestroy=function(){this.dragDirective.ngOnDestroy(),this.dragSubscription&&this.unsubscribeDrag()},t.prototype.subscribeDrag=function(){var t=this;this.dragSubscription=d.of(this.dragDirective).subscribe(function(e){t.service.onDrag(e)})},t.prototype.unsubscribeDrag=function(){this.dragSubscription&&(this.service.dragSubscription.unsubscribe(),this.dragSubscription.unsubscribe(),this.dragSubscription=null)},Object.defineProperty(t.prototype,"className",{get:function(){return!0},enumerable:!0,configurable:!0}),t.prototype.handle=function(t){var e=t.target,n=this.service.options.state;c.hasClasses(e,"k-icon")||c.isFocusable(e,!1)||!this.service.options.resizable||("default"===n?this.service.maximizeAction():"maximized"===n&&this.service.restoreAction())},i.__decorate([o.Input(),i.__metadata("design:type",o.TemplateRef)],t.prototype,"template",void 0),i.__decorate([o.HostBinding("class.k-window-titlebar"),o.HostBinding("class.k-dialog-titlebar"),o.HostBinding("class.k-header"),i.__metadata("design:type",Boolean),i.__metadata("design:paramtypes",[])],t.prototype,"className",null),i.__decorate([o.HostListener("dblclick",["$event"]),i.__metadata("design:type",Function),i.__metadata("design:paramtypes",[MouseEvent]),i.__metadata("design:returntype",void 0)],t.prototype,"handle",null),t=i.__decorate([o.Component({selector:"kendo-window-titlebar",template:'\n <ng-content *ngIf="!template"></ng-content>\n <ng-template\n [ngTemplateOutlet]="template"\n [ngTemplateOutletContext]="{\'$implicit\': service}" *ngIf="template">\n </ng-template>\n '}),i.__metadata("design:paramtypes",[o.ElementRef,a.DragResizeService,o.NgZone])],t)}();e.WindowTitleBarComponent=p},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n(2),o=n(3),r=n(16),a=n(30),s=n(5),d=function(t){function e(e,n,i,o){var r=t.call(this,e,n,null,o)||this;return r.window=i,r.look="bare",r.icon="window-maximize",r}return i.__extends(e,t),e.prototype.onClick=function(){this.window.maximizeAction()},Object.defineProperty(e.prototype,"visible",{get:function(){return"default"===this.window.options.state?"inline-flex":"none"},enumerable:!0,configurable:!0}),i.__decorate([o.Input(),i.__metadata("design:type",Object)],e.prototype,"window",void 0),i.__decorate([o.HostListener("click"),i.__metadata("design:type",Function),i.__metadata("design:paramtypes",[]),i.__metadata("design:returntype",void 0)],e.prototype,"onClick",null),i.__decorate([o.HostBinding("style.display"),i.__metadata("design:type",String),i.__metadata("design:paramtypes",[])],e.prototype,"visible",null),e=i.__decorate([o.Directive({exportAs:"kendoWindowMaximizeAction",selector:"button[kendoWindowMaximizeAction]"}),i.__param(2,o.Optional()),i.__param(3,o.Optional()),i.__param(3,o.Inject(s.RTL)),i.__metadata("design:paramtypes",[o.ElementRef,o.Renderer2,r.DragResizeService,Boolean])],e)}(a.Button);e.WindowMaximizeActionDirective=d},function(t,e){t.exports=p},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n(2),o=n(3),r=n(16),a=n(30),s=n(5),d=function(t){function e(e,n,i,o){var r=t.call(this,e,n,null,o)||this;return r.window=i,r.look="bare",r.icon="window-minimize",r}return i.__extends(e,t),e.prototype.onClick=function(){this.window.minimizeAction()},Object.defineProperty(e.prototype,"visible",{get:function(){return"default"===this.window.options.state?"inline-flex":"none"},enumerable:!0,configurable:!0}),i.__decorate([o.Input(),i.__metadata("design:type",Object)],e.prototype,"window",void 0),i.__decorate([o.HostListener("click"),i.__metadata("design:type",Function),i.__metadata("design:paramtypes",[]),i.__metadata("design:returntype",void 0)],e.prototype,"onClick",null),i.__decorate([o.HostBinding("style.display"),i.__metadata("design:type",String),i.__metadata("design:paramtypes",[])],e.prototype,"visible",null),e=i.__decorate([o.Directive({exportAs:"kendoWindowMinimizeAction",selector:"button[kendoWindowMinimizeAction]"}),i.__param(2,o.Optional()),i.__param(3,o.Optional()),i.__param(3,o.Inject(s.RTL)),i.__metadata("design:paramtypes",[o.ElementRef,o.Renderer2,r.DragResizeService,Boolean])],e)}(a.Button);e.WindowMinimizeActionDirective=d},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n(2),o=n(3),r=n(30),a=n(5),s=n(16),d=function(t){function e(e,n,i,o){var r=t.call(this,e,n,null,o)||this;return r.window=i,r.look="bare",r.icon="close",r}return i.__extends(e,t),e.prototype.onClick=function(){this.window.closeAction()},i.__decorate([o.Input(),i.__metadata("design:type",Object)],e.prototype,"window",void 0),i.__decorate([o.HostListener("click"),i.__metadata("design:type",Function),i.__metadata("design:paramtypes",[]),i.__metadata("design:returntype",void 0)],e.prototype,"onClick",null),e=i.__decorate([o.Directive({exportAs:"kendoWindowCloseAction",selector:"button[kendoWindowCloseAction]"}),i.__param(2,o.Optional()),i.__param(3,o.Optional()),i.__param(3,o.Inject(a.RTL)),i.__metadata("design:paramtypes",[o.ElementRef,o.Renderer2,s.DragResizeService,Boolean])],e)}(r.Button);e.WindowCloseActionDirective=d},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n(2),o=n(3),r=n(16),a=n(30),s=n(5),d=function(t){function e(e,n,i,o){var r=t.call(this,e,n,null,o)||this;return r.window=i,r.look="bare",r.icon="window-restore",r}return i.__extends(e,t),e.prototype.onClick=function(){this.window.restoreAction()},Object.defineProperty(e.prototype,"visible",{get:function(){return"default"===this.window.options.state?"none":"inline-flex"},enumerable:!0,configurable:!0}),i.__decorate([o.Input(),i.__metadata("design:type",Object)],e.prototype,"window",void 0),i.__decorate([o.HostListener("click"),i.__metadata("design:type",Function),i.__metadata("design:paramtypes",[]),i.__metadata("design:returntype",void 0)],e.prototype,"onClick",null),i.__decorate([o.HostBinding("style.display"),i.__metadata("design:type",String),i.__metadata("design:paramtypes",[])],e.prototype,"visible",null),e=i.__decorate([o.Directive({exportAs:"kendoWindowRestoreAction",selector:"button[kendoWindowRestoreAction]"}),i.__param(2,o.Optional()),i.__param(3,o.Optional()),i.__param(3,o.Inject(s.RTL)),i.__metadata("design:paramtypes",[o.ElementRef,o.Renderer2,r.DragResizeService,Boolean])],e)}(a.Button);e.WindowRestoreActionDirective=d},function(t,e){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var n=function(){return function(){}}();e.WindowSettings=n;var i=function(){return function(){}}();e.WindowCloseResult=i;var o=function(){return function(){}}();e.WindowRef=o},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n(2),o=n(3),r=n(36),a=n(34),s=n(14),d=n(21),c=n(9),p=n(10),u=n(11),l=function(){function t(t,e){this.getWindowRef=t,this.parentInjector=e}return t.prototype.get=function(t,e){return t===a.WindowRef?this.getWindowRef():this.parentInjector.get(t,e)},t}(),g=function(){function t(t,e){this.resolver=t,this.containerService=e}return t.prototype.open=function(t){var e=this.resolver.resolveComponentFactory(s.WindowComponent),n=t.appendTo||this.containerService.container;if(!n)throw new Error("Cannot attach window to the page.\n Add an element that uses the kendoWindowContainer directive, or set the 'appendTo' property.");var i={close:function(){},content:null,result:null,window:null},o=this.contentFrom(t.content,n,i),r=n.createComponent(e,void 0,void 0,o.nodes);i.window=r,this.applyOptions(r.instance,t);var d=new c.Subject,l=function(t){d.next(t||new a.WindowCloseResult),o.componentRef&&o.componentRef.destroy(),r.destroy()},g=p.merge(d,r.instance.close).pipe(u.take(1));return g.subscribe(l),i.close=l,i.result=g,i},t.prototype.applyOptions=function(t,e){d.isPresent(e.title)&&(t.title=e.title),d.isPresent(e.keepContent)&&(t.keepContent=e.keepContent),d.isPresent(e.width)&&(t.width=e.width),d.isPresent(e.minWidth)&&(t.minWidth=e.minWidth),d.isPresent(e.height)&&(t.height=e.height),d.isPresent(e.minHeight)&&(t.minHeight=e.minHeight),d.isPresent(e.left)&&(t.left=e.left),d.isPresent(e.top)&&(t.top=e.top),d.isPresent(e.draggable)&&(t.draggable=e.draggable),d.isPresent(e.resizable)&&(t.resizable=e.resizable),d.isPresent(e.state)&&(t.state=e.state,"minimized"===e.state&&(t.keepContent=!0)),e.content instanceof o.TemplateRef&&(t.contentTemplate=e.content),e.titleBarContent instanceof o.TemplateRef&&(t.titleBarTemplate=e.titleBarContent)},t.prototype.contentFrom=function(t,e,n){var i=e.injector.get(o.Renderer2),r=[],a=null;if("string"==typeof t)r=[i.createText(t)];else if(t&&!(t instanceof o.TemplateRef)){var s=new l(function(){return n},e.injector),d=this.resolver.resolveComponentFactory(t);r=[(a=e.createComponent(d,void 0,s)).location.nativeElement],n.content=a}return{componentRef:a,nodes:[[],r]}},t=i.__decorate([o.Injectable(),i.__metadata("design:paramtypes",[o.ComponentFactoryResolver,r.WindowContainerService])],t)}();e.WindowService=g},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n(2),o=n(3),r=function(){function t(){}return e=t,Object.defineProperty(t.prototype,"container",{get:function(){return e.container},set:function(t){e.container=t},enumerable:!0,configurable:!0}),t=e=i.__decorate([o.Injectable()],t);var e}();e.WindowContainerService=r},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n(2),o=n(3),r=n(1),a=n(7),s=n(8),d=n(38),c=n(12),p=n(39);e.DIALOG_DIRECTIVES=[r.DialogComponent,a.DialogTitleBarComponent];var u=function(){function t(){}return t=i.__decorate([o.NgModule({declarations:[e.DIALOG_DIRECTIVES,d.DialogContainerDirective],entryComponents:[e.DIALOG_DIRECTIVES],exports:[e.DIALOG_DIRECTIVES,p.SHARED_DIRECTIVES,d.DialogContainerDirective],imports:[p.SharedModule],providers:[c.DialogContainerService,s.DialogService]})],t)}();e.DialogModule=u},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n(2),o=n(3),r=n(12),a=function(){function t(t,e){e.container=t}return t=i.__decorate([o.Directive({selector:"[kendoDialogContainer]"}),i.__metadata("design:paramtypes",[o.ViewContainerRef,r.DialogContainerService])],t)}();e.DialogContainerDirective=a},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n(2),o=n(3),r=n(40),a=n(6);e.SHARED_DIRECTIVES=[a.DialogActionsComponent];var s=function(){function t(){}return t=i.__decorate([o.NgModule({declarations:[e.SHARED_DIRECTIVES],exports:[e.SHARED_DIRECTIVES,r.CommonModule],imports:[r.CommonModule]})],t)}();e.SharedModule=s},function(t,e){t.exports=y},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n(2),o=n(3),r=n(14),a=n(28),s=n(26),d=n(25),c=n(29),p=n(31),u=n(32),l=n(33),g=n(35),m=n(36),f=n(42),h=n(39),_=[s.DraggableDirective,d.ResizeHandleDirective,r.WindowComponent,a.WindowTitleBarComponent,u.WindowCloseActionDirective,p.WindowMinimizeActionDirective,c.WindowMaximizeActionDirective,l.WindowRestoreActionDirective],y=[r.WindowComponent,a.WindowTitleBarComponent],v=[r.WindowComponent,u.WindowCloseActionDirective,p.WindowMinimizeActionDirective,c.WindowMaximizeActionDirective,l.WindowRestoreActionDirective,a.WindowTitleBarComponent],b=function(){function t(){}return t=i.__decorate([o.NgModule({declarations:[_,f.WindowContainerDirective],entryComponents:[y],exports:[v,h.SHARED_DIRECTIVES,f.WindowContainerDirective],imports:[h.SharedModule],providers:[m.WindowContainerService,g.WindowService]})],t)}();e.WindowModule=b},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n(2),o=n(3),r=n(36),a=function(){function t(t,e){e.container=t}return t=i.__decorate([o.Directive({selector:"[kendoWindowContainer]"}),i.__metadata("design:paramtypes",[o.ViewContainerRef,r.WindowContainerService])],t)}();e.WindowContainerDirective=a},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n(2),o=n(3),r=n(37),a=n(41),s=function(){function t(){}return t=i.__decorate([o.NgModule({exports:[r.DialogModule,a.WindowModule]})],t)}();e.DialogsModule=s}])}}}); |
@@ -6,3 +6,3 @@ { | ||
"license": "SEE LICENSE in LICENSE.md", | ||
"version": "3.1.0-dev.201802070905", | ||
"version": "3.1.0", | ||
"main": "dist/npm/main.js", | ||
@@ -9,0 +9,0 @@ "module": "dist/es/main.js", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
No v1
QualityPackage is not semver >=1. This means it is not stable and does not support ^ ranges.
Found 1 instance in 1 package
2
748992