angular-admin-lte
Version:
15 lines (13 loc) • 80.6 kB
JavaScript
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports,require("@angular/core"),require("@angular/common"),require("@angular/router"),require("rxjs"),require("@angular/platform-browser"),require("rxjs/operators"),require("@angular/forms")):"function"==typeof define&&define.amd?define("angular-admin-lte",["exports","@angular/core","@angular/common","@angular/router","rxjs","@angular/platform-browser","rxjs/operators","@angular/forms"],t):t((e="undefined"!=typeof globalThis?globalThis:e||self)["angular-admin-lte"]={},e.ng.core,e.ng.common,e.ng.router,e.rxjs,e.ng.platformBrowser,e.rxjs.operators,e.ng.forms)}(this,(function(e,t,n,o,r,i,s,a){"use strict";
/*! *****************************************************************************
Copyright (c) Microsoft Corporation.
Permission to use, copy, modify, and/or distribute this software for any
purpose with or without fee is hereby granted.
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
PERFORMANCE OF THIS SOFTWARE.
***************************************************************************** */Object.create;function l(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var o,r,i=n.call(e),s=[];try{for(;(void 0===t||t-- >0)&&!(o=i.next()).done;)s.push(o.value)}catch(e){r={error:e}}finally{try{o&&!o.done&&(n=i.return)&&n.call(i)}finally{if(r)throw r.error}}return s}function c(){for(var e=[],t=0;t<arguments.length;t++)e=e.concat(l(arguments[t]));return e}Object.create;var p=function(){function e(e){this.router=e,this.onChange=new r.BehaviorSubject(void 0),this.events=new r.BehaviorSubject(void 0),this.init()}return e.createUrl=function(e){return e.url.map((function(e){return e.toString()})).join("/")},e.isChildrenSelfRoute=function(e){var t,n,o=!1;return null===(n=null===(t=null==e?void 0:e.routeConfig)||void 0===t?void 0:t.children)||void 0===n||n.forEach((function(e){""===e.path&&(e.component||e.loadChildren)&&(o=!0)})),o},e.createBreadcrumb=function(t,n){var o,r,i,s,a=!0;return 0!==t.children.length&&(null===(r=null===(o=null==t?void 0:t.firstChild)||void 0===o?void 0:o.routeConfig)||void 0===r?void 0:r.path)&&("/"===n||(null===(i=null==t?void 0:t.routeConfig)||void 0===i?void 0:i.loadChildren)||(null===(s=null==t?void 0:t.routeConfig)||void 0===s?void 0:s.component)||e.isChildrenSelfRoute(t)||(a=!1)),{data:t.data,params:t.params,url:a?n:null}},e.prototype.init=function(){var t=this;this.router.events.subscribe((function(n){var r;if(n instanceof o.NavigationEnd){t.events.next(n);for(var i=t.router.routerState.root.snapshot,s="",a="",l=!0,c=[];i.children.length;)if(i=i.firstChild||i,s="/"+e.createUrl(i),i.outlet===o.PRIMARY_OUTLET&&((null===(r=null==i?void 0:i.routeConfig)||void 0===r?void 0:r.path)||l)){if(l=!1,i.params&&i.data)for(var p in i.params)p&&(i.data.hasOwnProperty("title")&&(i.data.title=i.data.title.replace(":"+p,i.params[p]),i.data.title=i.data.title.replace(":"+p,i.params[p])),i.data.hasOwnProperty("breadcrumbs")&&(i.data.breadcrumbs=i.data.breadcrumbs.replace(":"+p,i.params[p])),i.data.hasOwnProperty("description")&&(i.data.description=i.data.description.replace(":"+p,i.params[p])));"/"===s?c.push(e.createBreadcrumb(i,s)):(a+=s,c.push(e.createBreadcrumb(i,a)))}t.onChange.next(c)}}))},e}();p.decorators=[{type:t.Injectable}],p.ctorParameters=function(){return[{type:o.Router}]};var d=function(){function e(e,t){this.routingService=e,this.changeDetectorRef=t,this.homeIcon="fa fa-home"}return e.prototype.ngOnInit=function(){var e=this;this.subscription=this.routingService.onChange.subscribe((function(t){e.breadcrumbs=t}))},e.prototype.ngOnDestroy=function(){this.subscription&&this.subscription.unsubscribe()},e}();d.decorators=[{type:t.Component,args:[{selector:"mk-breadcrumbs",template:'<ol class="breadcrumb">\n <li *ngFor="let breadcrumb of breadcrumbs; let first = first; let last = last" [class.active]="last || !breadcrumb.url">\n <a *ngIf="breadcrumb.url && !last; else noLink" [routerLink]="breadcrumb.url">\n <i *ngIf="first" ngClass="{{homeIcon}}"></i>\n <ng-template [ngIf]="breadcrumb.data.breadcrumbs">{{breadcrumb.data.breadcrumbs}}</ng-template>\n <ng-template [ngIf]="breadcrumb.data.title">{{breadcrumb.data.title}}</ng-template>\n </a>\n <ng-template #noLink>\n <i *ngIf="first" ngClass="{{homeIcon}}"></i>\n <ng-template [ngIf]="breadcrumb.data.breadcrumbs">{{breadcrumb.data.breadcrumbs}}</ng-template>\n <ng-template [ngIf]="breadcrumb.data.title">{{breadcrumb.data.title}}</ng-template>\n </ng-template>\n </li>\n</ol>\n',styles:[".breadcrumb{background:transparent;border-radius:2px;float:right;font-size:12px;margin-bottom:0;margin-top:0;padding:7px 5px;position:absolute;right:10px;top:15px}.breadcrumb>li>a{color:#444;display:inline-block;text-decoration:none}.breadcrumb>li .fa,.breadcrumb>li .glyphicon,.breadcrumb>li .ion{margin-right:5px}"]}]}],d.ctorParameters=function(){return[{type:p},{type:t.ChangeDetectorRef}]},d.propDecorators={homeIcon:[{type:t.Input}]};var u=function(){};u.decorators=[{type:t.NgModule,args:[{imports:[n.CommonModule,o.RouterModule],exports:[d],declarations:[d]}]}];var g=function(e){this.isSidebarLeftCollapsed=!1,this.isSidebarLeftExpandOnOver=!1,this.isSidebarLeftMouseOver=!1,this.isSidebarLeftMini=!0,this.sidebarRightSkin="dark",this.isSidebarRightCollapsed=!0,this.isSidebarRightOverContent=!0,this.layout="normal",this.sidebarLeftMenu=[],this.sidebarLeftMenuActiveUrl="",this.skin="blue",Object.assign(this,e)},h=function(){function e(e){this.initialLayoutState=new g(e),this.state=new r.BehaviorSubject(this.initialLayoutState),this.layoutState=this.state.asObservable()}return Object.defineProperty(e.prototype,"windowInnerHeight",{get:function(){return this.layoutState.pipe(s.pluck("windowInnerHeight"),s.distinctUntilChanged())},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"windowInnerWidth",{get:function(){return this.layoutState.pipe(s.pluck("windowInnerWidth"),s.distinctUntilChanged())},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"isSidebarLeftCollapsed",{get:function(){return this.layoutState.pipe(s.pluck("isSidebarLeftCollapsed"),s.distinctUntilChanged())},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"isSidebarLeftExpandOnOver",{get:function(){return this.layoutState.pipe(s.pluck("isSidebarLeftExpandOnOver"),s.distinctUntilChanged())},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"isSidebarLeftMouseOver",{get:function(){return this.layoutState.pipe(s.pluck("isSidebarLeftMouseOver"),s.distinctUntilChanged())},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"isSidebarLeftMini",{get:function(){return this.layoutState.pipe(s.pluck("isSidebarLeftMini"),s.distinctUntilChanged())},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"sidebarRightSkin",{get:function(){return this.layoutState.pipe(s.pluck("sidebarRightSkin"),s.distinctUntilChanged())},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"isSidebarRightCollapsed",{get:function(){return this.layoutState.pipe(s.pluck("isSidebarRightCollapsed"),s.distinctUntilChanged())},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"isSidebarRightOverContent",{get:function(){return this.layoutState.pipe(s.pluck("isSidebarRightOverContent"),s.distinctUntilChanged())},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"sidebarLeftMenu",{get:function(){return this.layoutState.pipe(s.pluck("sidebarLeftMenu"),s.distinctUntilChanged())},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"sidebarLeftMenuActiveUrl",{get:function(){return this.layoutState.pipe(s.pluck("sidebarLeftMenuActiveUrl"),s.distinctUntilChanged())},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"sidebarLeftElementHeight",{get:function(){return this.layoutState.pipe(s.pluck("sidebarLeftElementHeight"),s.distinctUntilChanged())},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"layout",{get:function(){return this.layoutState.pipe(s.pluck("layout"),s.distinctUntilChanged())},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"skin",{get:function(){return this.layoutState.pipe(s.pluck("skin"),s.distinctUntilChanged())},enumerable:!1,configurable:!0}),e.prototype.sidebarLeftCollapsed=function(e){this.state.next(Object.assign(this.state.value,{isSidebarLeftCollapsed:e}))},e.prototype.sidebarLeftExpandOnOver=function(e){this.state.next(Object.assign(this.state.value,{isSidebarLeftExpandOnOver:e}))},e.prototype.setSidebarLeftElementHeight=function(e){this.state.next(Object.assign(this.state.value,{sidebarLeftElementHeight:e}))},e.prototype.setSidebarRightSkin=function(e){this.state.next(Object.assign(this.state.value,{sidebarRightSkin:e}))},e.prototype.sidebarLeftMouseOver=function(e){this.state.next(Object.assign(this.state.value,{isSidebarLeftMouseOver:e}))},e.prototype.sidebarLeftMini=function(e){this.state.next(Object.assign(this.state.value,{isSidebarLeftMini:e}))},e.prototype.sidebarRightCollapsed=function(e){this.state.next(Object.assign(this.state.value,{isSidebarRightCollapsed:e}))},e.prototype.sidebarRightOverContent=function(e){this.state.next(Object.assign(this.state.value,{isSidebarRightOverContent:e}))},e.prototype.setSidebarLeftMenu=function(e){this.state.next(Object.assign(this.state.value,{sidebarLeftMenu:e}))},e.prototype.setSidebarLeftMenuActiveUrl=function(e){this.state.next(Object.assign(this.state.value,{sidebarLeftMenuActiveUrl:e}))},e.prototype.setLayout=function(e){this.state.next(Object.assign(this.state.value,{layout:e}))},e.prototype.setSkin=function(e){this.state.next(Object.assign(this.state.value,{skin:e}))},e.prototype.setWindowInnerHeight=function(e){this.state.next(Object.assign(this.state.value,{windowInnerHeight:e}))},e.prototype.setWindowInnerWidth=function(e){this.state.next(Object.assign(this.state.value,{windowInnerWidth:e}))},e}(),m=function(){function e(){}return Object.defineProperty(e.prototype,"scrollHeight",{get:function(){return this.elementRef?this.elementRef.nativeElement.scrollHeight:0},enumerable:!1,configurable:!0}),e}();m.decorators=[{type:t.Injectable}];var f=function(){function e(){}return Object.defineProperty(e.prototype,"offsetHeight",{get:function(){return this.elementRef?this.elementRef.nativeElement.offsetHeight:0},enumerable:!1,configurable:!0}),e}();f.decorators=[{type:t.Injectable}];var b=function(){function e(){}return Object.defineProperty(e.prototype,"offsetHeight",{get:function(){return this.elementRef?this.elementRef.nativeElement.offsetHeight:0},enumerable:!1,configurable:!0}),e}();function y(e){return e&&e.forEach((function(e){e.unsubscribe()})),[]}function C(e){return void 0===e&&(e=[]),e&&e.forEach((function(e){e()})),[]}b.decorators=[{type:t.Injectable}];var v=function(){function e(e,t,n,o,r,i,s,a,l){this.layoutStore=e,this.routingService=t,this.titleService=n,this.elementRef=o,this.changeDetectorRef=r,this.sidebarRightService=i,this.headerService=s,this.footerService=a,this.router=l,this.navigationEnd=!1,this.subscriptions=[]}return e.prototype.ngOnInit=function(){var e=this;this.titleTag=this.titleService.getTitle(),this.subscriptions.push(this.routingService.onChange.subscribe((function(t){if(t&&t[t.length-1]&&t[t.length-1].data){var n=t[t.length-1].data;e.titleService.setTitle(e.getTitle(n.title)||""),e.header=n.title,e.description=n.description}e.changeDetectorRef.markForCheck()}))),this.subscriptions.push(this.router.events.subscribe((function(t){t instanceof o.NavigationStart&&(e.navigationEnd=!1),t instanceof o.NavigationEnd&&(e.navigationEnd=!0,e.setContentMinHeight())}))),this.subscriptions.push(this.layoutStore.sidebarLeftElementHeight.subscribe((function(t){e.sidebarLeftHeight=t,e.setContentMinHeight()}))),this.subscriptions.push(this.layoutStore.layout.subscribe((function(t){e.layout=t,e.setContentMinHeight()}))),this.subscriptions.push(this.layoutStore.windowInnerHeight.subscribe((function(t){e.windowInnerHeight=t,e.setContentMinHeight()}))),this.heightStyle=this.windowInnerHeight},e.prototype.ngOnDestroy=function(){this.subscriptions=y(this.subscriptions)},Object.defineProperty(e.prototype,"scrollHeight",{get:function(){return this.contentInnerElement.nativeElement.scrollHeight},enumerable:!1,configurable:!0}),e.prototype.getTitle=function(e){return e?e+" - "+this.titleTag:this.titleTag},e.prototype.setContentMinHeight=function(){if(this.navigationEnd){var e=0,t=this.headerService.offsetHeight+this.footerService.offsetHeight;if("fixed"===this.layout&&this.windowInnerHeight)e=this.windowInnerHeight-this.footerService.offsetHeight;else if(this.windowInnerHeight&&this.sidebarLeftHeight){var n=this.sidebarRightService.scrollHeight?this.sidebarRightService.scrollHeight-this.headerService.offsetHeight:0;e=Math.max(this.windowInnerHeight-t,this.sidebarLeftHeight-this.headerService.offsetHeight,n)}e&&e!==this.heightStyle&&(this.scrollHeight>e&&(e=0),this.heightStyle=e,this.changeDetectorRef.detectChanges())}},e}();v.decorators=[{type:t.Component,args:[{selector:"mk-layout-content",template:'<div class="content-wrapper" [style.min-height.px]="heightStyle">\n <div #contentInnerElement class="content-inner">\n <ng-content select="[mk-layout-content-before-header]"></ng-content>\n <section *ngIf="header || description" class="content-header">\n <h1>\n {{header}}\n <small *ngIf="description">{{description}}</small>\n </h1>\n <mk-breadcrumbs></mk-breadcrumbs>\n </section>\n <ng-content select="[mk-layout-content-after-header]"></ng-content>\n <section class="content">\n <ng-content></ng-content>\n </section>\n </div>\n</div>\n',changeDetection:t.ChangeDetectionStrategy.OnPush,styles:[":host{display:block}.content-wrapper{position:relative}"]}]}],v.ctorParameters=function(){return[{type:h},{type:p},{type:i.Title},{type:t.ElementRef},{type:t.ChangeDetectorRef},{type:m},{type:f},{type:b},{type:o.Router}]},v.propDecorators={contentInnerElement:[{type:t.ViewChild,args:["contentInnerElement",{static:!0}]}]};var S=function(){};S.decorators=[{type:t.NgModule,args:[{imports:[n.CommonModule,o.RouterModule,u],exports:[v],declarations:[v]}]}];var I=function(){};I.decorators=[{type:t.Component,args:[{selector:"mk-layout-footer-left",template:"<ng-template #templateRef><ng-content></ng-content></ng-template>"}]}],I.propDecorators={templateRef:[{type:t.ViewChild,args:["templateRef",{static:!0}]}]};var R=function(){};R.decorators=[{type:t.Component,args:[{selector:"mk-layout-footer-right",template:"<ng-template #templateRef><ng-content></ng-content></ng-template>"}]}],R.propDecorators={templateRef:[{type:t.ViewChild,args:["templateRef",{static:!0}]}]};var x=function(){function e(e,t){this.elementRef=e,this.footerService=t}return e.prototype.ngOnInit=function(){this.footerService.elementRef=this.elementRef},e}();x.decorators=[{type:t.Component,args:[{selector:"mk-layout-footer",template:'<footer class="main-footer">\n <div class="pull-right hidden-xs">\n <ng-template *ngIf="footerRightComponent" [ngTemplateOutlet]="footerRightComponent.templateRef"></ng-template>\n </div>\n <ng-template *ngIf="footerLeftComponent" [ngTemplateOutlet]="footerLeftComponent.templateRef"></ng-template>\n</footer>\n',styles:[":host{display:block}"]}]}],x.ctorParameters=function(){return[{type:t.ElementRef},{type:b}]},x.propDecorators={footerLeftComponent:[{type:t.ContentChild,args:[I]}],footerRightComponent:[{type:t.ContentChild,args:[R]}]};var k=function(){};k.decorators=[{type:t.NgModule,args:[{imports:[n.CommonModule],exports:[x,I,R],declarations:[x,I,R]}]}];var D=function(){};D.decorators=[{type:t.Component,args:[{selector:"mk-layout-header-logo",template:"<ng-template #templateRef><ng-content></ng-content></ng-template>"}]}],D.propDecorators={templateRef:[{type:t.ViewChild,args:["templateRef",{static:!0}]}]};var E=function(){};E.decorators=[{type:t.Component,args:[{selector:"mk-layout-header-logo-mini",template:"<ng-template #templateRef><ng-content></ng-content></ng-template>"}]}],E.propDecorators={templateRef:[{type:t.ViewChild,args:["templateRef",{static:!0}]}]};var w=function(){function e(e,t,n,o,r){this.layoutStore=e,this.ngZone=t,this.renderer2=n,this.elementRef=o,this.headerService=r,this.isSidebarLeftToggle=!0,this.isSidebarRightToggle=!0,this.logoLink="/",this.listeners=[],this.subscriptions=[]}return e.prototype.ngAfterViewInit=function(){var e=this;this.headerService.elementRef=this.headerElement,this.sidebarLeftToggleElement&&(this.subscriptions.push(this.layoutStore.isSidebarLeftCollapsed.subscribe((function(t){e.isSidebarLeftCollapsed=t}))),this.ngZone.runOutsideAngular((function(){var t;e.listeners.push(e.renderer2.listen(null===(t=e.sidebarLeftToggleElement)||void 0===t?void 0:t.nativeElement,"click",(function(t){t.preventDefault(),e.layoutStore.sidebarLeftCollapsed(!e.isSidebarLeftCollapsed)})))}))),this.sidebarRightToggleElement&&(this.subscriptions.push(this.layoutStore.isSidebarRightCollapsed.subscribe((function(t){e.isSidebarRightCollapsed=t}))),this.ngZone.runOutsideAngular((function(){var t;e.listeners.push(e.renderer2.listen(null===(t=e.sidebarRightToggleElement)||void 0===t?void 0:t.nativeElement,"click",(function(t){t.preventDefault(),e.layoutStore.sidebarRightCollapsed(!e.isSidebarRightCollapsed)})))})))},e.prototype.ngOnDestroy=function(){this.listeners=C(this.listeners),this.subscriptions=y(this.subscriptions)},e}();w.decorators=[{type:t.Component,args:[{selector:"mk-layout-header",template:'<header #headerElement class="main-header">\n <a [routerLink]="logoLink" class="logo">\n <span class="logo-mini" *ngIf="headerLogoMiniComponent"><ng-template [ngTemplateOutlet]="headerLogoMiniComponent.templateRef"></ng-template></span>\n <span class="logo-lg" *ngIf="headerLogoComponent"><ng-template [ngTemplateOutlet]="headerLogoComponent.templateRef"></ng-template></span>\n </a>\n <nav class="navbar navbar-static-top">\n <a *ngIf="isSidebarLeftToggle" #sidebarLeftToggleElement href="#" class="sidebar-toggle {{sidebarLeftToggleIconClasses ? \'sidebar-toggle-custom-icon\' : \'\'}}">\n <span class="sr-only">Toggle navigation</span>\n <ng-container *ngIf="sidebarLeftToggleIconClasses">\n <i [class]="sidebarLeftToggleIconClasses"></i>\n </ng-container>\n </a>\n <div *ngIf="isSidebarRightToggle" class="sidebar-right-toggle">\n <a #sidebarRightToggleElement href="#">\n <i [class]="sidebarRightToggleIconClasses ? sidebarRightToggleIconClasses : \'fa fa-gears\'"></i>\n </a>\n </div>\n <ng-content></ng-content>\n </nav>\n</header>\n',styles:[':host{display:block}.sidebar-right-toggle{float:right}.sidebar-right-toggle a{cursor:pointer;display:block;line-height:20px;padding:15px}.sidebar-toggle-custom-icon:before{content:""}']}]}],w.ctorParameters=function(){return[{type:h},{type:t.NgZone},{type:t.Renderer2},{type:t.ElementRef},{type:f}]},w.propDecorators={isSidebarLeftToggle:[{type:t.Input}],sidebarLeftToggleIconClasses:[{type:t.Input}],isSidebarRightToggle:[{type:t.Input}],sidebarRightToggleIconClasses:[{type:t.Input}],logoLink:[{type:t.Input}],headerLogoComponent:[{type:t.ContentChild,args:[D]}],headerLogoMiniComponent:[{type:t.ContentChild,args:[E]}],headerElement:[{type:t.ViewChild,args:["headerElement",{static:!0}]}],sidebarLeftToggleElement:[{type:t.ViewChild,args:["sidebarLeftToggleElement"]}],sidebarRightToggleElement:[{type:t.ViewChild,args:["sidebarRightToggleElement"]}]};var O=function(){};O.decorators=[{type:t.NgModule,args:[{imports:[n.CommonModule,o.RouterModule],exports:[w,D,E],declarations:[w,D,E]}]}];var L=function(){function e(e,n,o){this.elementRef=e,this.ngZone=n,this.renderer2=o,this.collapseAnimationDuration=350,this.startEventEmitter=new t.EventEmitter,this.doneEventEmitter=new t.EventEmitter,this.firstStart=!0,this.isCollapsed=!1,this.lastIsCollapsed=!1,this.transitioning=!1}return Object.defineProperty(e.prototype,"_isCollapsed",{set:function(e){this.lastIsCollapsed=this.isCollapsed,this.isCollapsed=e,this.firstStart||(this.emit("start"),e?this.collapse():e||this.unCollapse())},enumerable:!1,configurable:!0}),e.prototype.ngOnInit=function(){this.collapseAnimationDuration&&350!==this.collapseAnimationDuration&&this.renderer2.setStyle(this.elementRef.nativeElement,"transition-duration",this.collapseAnimationDuration+"ms"),this.collapseAnimationTiming&&this.renderer2.setStyle(this.elementRef.nativeElement,"transition-timing-function",this.collapseAnimationTiming)},e.prototype.ngAfterContentInit=function(){this.emit("start"),this.isCollapsed&&(this.renderer2.setStyle(this.elementRef.nativeElement,"display","none"),this.renderer2.addClass(this.elementRef.nativeElement,"collapsing")),this.emit("done"),this.firstStart=!1,this.subscriptions()},e.prototype.ngOnDestroy=function(){this.listener&&this.listener()},e.prototype.subscriptions=function(){var e=this;this.ngZone.runOutsideAngular((function(){e.listener=e.renderer2.listen(e.elementRef.nativeElement,"transitionend",(function(){e.isCollapsed?e.renderer2.setStyle(e.elementRef.nativeElement,"display","none"):(e.renderer2.removeClass(e.elementRef.nativeElement,"un-collapse"),e.renderer2.removeClass(e.elementRef.nativeElement,"collapsing")),requestAnimationFrame((function(){e.renderer2.removeStyle(e.elementRef.nativeElement,"height"),e.emit("done"),e.transitioning=!1}))}))}))},e.prototype.unCollapse=function(){this.transitioning=!0,this.renderer2.addClass(this.elementRef.nativeElement,"un-collapse"),this.renderer2.removeStyle(this.elementRef.nativeElement,"display"),this.renderer2.setStyle(this.elementRef.nativeElement,"height",this.elementRef.nativeElement.scrollHeight+"px")},e.prototype.collapse=function(){var e=this;requestAnimationFrame((function(){e.transitioning||(e.renderer2.setStyle(e.elementRef.nativeElement,"height",e.elementRef.nativeElement.offsetHeight+"px"),e.renderer2.addClass(e.elementRef.nativeElement,"collapsing")),e.transitioning=!0,requestAnimationFrame((function(){e.renderer2.setStyle(e.elementRef.nativeElement,"height","0px")}))}))},e.prototype.emit=function(e){var t={element:this.elementRef.nativeElement,fromState:void 0===this.lastIsCollapsed?"void":this.lastIsCollapsed?"1":"0",phaseName:e,toState:void 0===this.isCollapsed?"void":this.isCollapsed?"1":"0",totalTime:this.collapseAnimationDuration,triggerName:"mkCollapseAnimation"};"done"===e?this.doneEventEmitter.emit(t):"start"===e&&this.startEventEmitter.emit(t)},e}();L.decorators=[{type:t.Directive,args:[{selector:"[mkCollapseAnimation]"}]}],L.ctorParameters=function(){return[{type:t.ElementRef},{type:t.NgZone},{type:t.Renderer2}]},L.propDecorators={collapseAnimationDuration:[{type:t.Input}],collapseAnimationTiming:[{type:t.Input}],_isCollapsed:[{type:t.Input,args:["mkCollapseAnimation"]}],startEventEmitter:[{type:t.Output,args:["mkCollapseAnimation.start"]}],doneEventEmitter:[{type:t.Output,args:["mkCollapseAnimation.done"]}]};var T=function(){};T.decorators=[{type:t.NgModule,args:[{exports:[L],declarations:[L]}]}];var M=function(e){this.elementRef=e};M.decorators=[{type:t.Directive,args:[{selector:"[mkMenuToggle]"}]}],M.ctorParameters=function(){return[{type:t.ElementRef}]},M.propDecorators={item:[{type:t.Input,args:["mkMenuToggle"]}]};var A=function(){};A.decorators=[{type:t.Injectable}];var H=function(){function e(e,t,n,o,r,i,s,a){this.changeDetectorRef=e,this.layoutStore=t,this.ngZone=n,this.renderer2=o,this.router=r,this.routingService=i,this.wrapperService=s,this.headerService=a,this.isSidebarLeftMouseOver=!1,this.collapsedItems=[],this.activatedItems=[],this.toggleListeners=[],this.listeners=[],this.itemsByIds={},this.runningAnimations=0,this.subscriptions=[],this.initialized=!1}return e.prototype.ngOnInit=function(){var e=this;this.subscriptions.push(this.layoutStore.sidebarLeftMenu.subscribe((function(t){e.menu=t,e.monkeyPatchMenu(e.menu),e.initialized&&(e.setMenuListeners(e.activeUrl),e.setSidebarListeners(),e.setMenuTogglesListeners()),e.initialized=!0}))),this.subscriptions.push(this.layoutStore.sidebarLeftMenuActiveUrl.subscribe((function(t){e.activeUrl=t,e.setMenuListeners(t)}))),this.subscriptions.push(this.routingService.events.subscribe((function(t){t instanceof o.NavigationEnd&&(e.activeUrl=t.url,e.setMenuListeners(t.url))}))),this.setSidebarListeners()},e.prototype.ngAfterViewInit=function(){this.setMenuTogglesListeners(),this.checkMenuWithoutChildren()},e.prototype.ngOnDestroy=function(){this.subscriptions=y(this.subscriptions),this.listeners=C(this.listeners),this.toggleListeners=C(this.toggleListeners)},e.prototype.setSidebarListeners=function(){var e=this;this.subscriptions.push(this.layoutStore.layout.subscribe((function(t){e.layout=t,e.setSidebarHeight()}))),this.subscriptions.push(this.layoutStore.windowInnerHeight.subscribe((function(t){e.windowInnerHeight=t,e.setSidebarHeight()}))),this.subscriptions.push(this.layoutStore.sidebarLeftMenu.subscribe((function(){e.changeDetectorRef.detectChanges()}))),this.ngZone.runOutsideAngular((function(){e.listeners.push(e.renderer2.listen(e.sidebarElement.nativeElement,"mouseenter",(function(){e.layoutStore.sidebarLeftMouseOver(!0)}))),e.listeners.push(e.renderer2.listen(e.sidebarElement.nativeElement,"mouseleave",(function(){e.layoutStore.sidebarLeftMouseOver(!1)})))})),this.subscriptions.push(this.layoutStore.windowInnerWidth.subscribe((function(t){e.windowInnerWidth=t,!e.isSidebarLeftCollapsed&&e.windowInnerWidth&&e.windowInnerWidth<=767?e.layoutStore.sidebarLeftCollapsed(!0):e.windowInnerWidth&&e.windowInnerWidth>767&&e.isSidebarLeftCollapsed&&!e.isSidebarLeftExpandOnOver&&e.layoutStore.sidebarLeftCollapsed(!1)}))),this.subscriptions.push(this.layoutStore.isSidebarLeftMouseOver.subscribe((function(t){e.isSidebarLeftMouseOver=t,e.isSidebarLeftExpandOnOver&&e.layoutStore.sidebarLeftCollapsed(!t)}))),this.subscriptions.push(this.layoutStore.isSidebarLeftExpandOnOver.subscribe((function(t){e.isSidebarLeftExpandOnOver=t,e.windowInnerWidth&&e.windowInnerWidth>767&&void 0!==e.isSidebarLeftCollapsed&&e.layoutStore.sidebarLeftCollapsed(t)}))),this.subscriptions.push(this.layoutStore.isSidebarLeftCollapsed.subscribe((function(t){e.isSidebarLeftCollapsed=t,e.windowInnerWidth&&e.windowInnerWidth<=767?t?e.renderer2.removeClass(e.wrapperService.wrapperElementRef.nativeElement,"sidebar-open"):e.renderer2.addClass(e.wrapperService.wrapperElementRef.nativeElement,"sidebar-open"):(!e.isSidebarLeftExpandOnOver||e.isSidebarLeftMouseOver||t||e.layoutStore.sidebarLeftExpandOnOver(!1),t?(e.renderer2.addClass(e.wrapperService.wrapperElementRef.nativeElement,"sidebar-collapse"),e.isSidebarLeftExpandOnOver&&e.renderer2.removeClass(e.wrapperService.wrapperElementRef.nativeElement,"sidebar-expanded-on-hover")):(e.renderer2.removeClass(e.wrapperService.wrapperElementRef.nativeElement,"sidebar-collapse"),e.isSidebarLeftExpandOnOver&&e.renderer2.addClass(e.wrapperService.wrapperElementRef.nativeElement,"sidebar-expanded-on-hover")))}))),this.subscriptions.push(this.layoutStore.isSidebarLeftMini.subscribe((function(t){t?e.renderer2.addClass(e.wrapperService.wrapperElementRef.nativeElement,"sidebar-mini"):e.renderer2.removeClass(e.wrapperService.wrapperElementRef.nativeElement,"sidebar-mini")})))},e.prototype.getIconClasses=function(e){return e.iconClasses||""===e.iconClasses?e.iconClasses:"fa fa-circle-o"},e.prototype.visibilityStateStart=function(e){var t=this;this.runningAnimations++,this.ngZone.runOutsideAngular((function(){setTimeout((function(){t.runningAnimations--,t.runningAnimations||t.layoutStore.setSidebarLeftElementHeight(t.sidebarElement.nativeElement.offsetHeight)}),e.totalTime)}))},e.prototype.setMenuListeners=function(e){if("/"===e)this.activeItems(e),this.changeDetectorRef.detectChanges();else{var t=this.router.parseUrl(e).root.children[o.PRIMARY_OUTLET];t&&(this.activeItems(t.toString()),this.changeDetectorRef.detectChanges())}(this.windowInnerWidth&&this.windowInnerWidth<=767||this.isSidebarLeftExpandOnOver)&&this.layoutStore.sidebarLeftCollapsed(!0)},e.prototype.uncollapseItemParents=function(e,t){void 0===t&&(t=!1),t&&(e.isActive=!0,this.activatedItems.push(e)),e.isCollapsed=!1,this.collapsedItems.push(e),e.parentId&&this.uncollapseItemParents(this.itemsByIds[e.parentId],t)},e.prototype.findItemsByUrl=function(e,t,n){var o=this;return void 0===n&&(n=[]),t.forEach((function(t){t.route===e?n.push(t):t.children&&o.findItemsByUrl(e,t.children,n)})),n},e.prototype.activeItems=function(e){var t=this;this.menu&&(this.activatedItems.forEach((function(e){e.isActive=!1})),this.activatedItems=[],this.collapsedItems.forEach((function(e){e.isActive=!1,e.isCollapsed=!0})),this.collapsedItems=[],this.findItemsByUrl(e,this.menu).forEach((function(e){e.isActive=!0,t.uncollapseItemParents(e,!0),t.activatedItems.push(e)})))},e.prototype.monkeyPatchMenu=function(e,t){var n=this;e.forEach((function(e,o){e.id=t?Number(t+""+(o+1)):o+1,t&&(e.parentId=t),e.disableCollapse||(e.isCollapsed=!0),e.isActive=!1,(t||e.children)&&(n.itemsByIds[e.id]=e),e.children&&n.monkeyPatchMenu(e.children,e.id)}))},e.prototype.setMenuTogglesListeners=function(){var e=this;this.toggleListeners=C(this.toggleListeners),this.ngZone.runOutsideAngular((function(){e.sidebarLeftToggleDirectives.forEach((function(t){e.toggleListeners.push(e.renderer2.listen(t.elementRef.nativeElement,"click",(function(n){n.preventDefault(),t.item.isCollapsed?(e.collapsedItems.forEach((function(e){e.disableCollapse||(e.isCollapsed=!0)})),e.collapsedItems=[],e.uncollapseItemParents(t.item)):t.item.isCollapsed=!t.item.isCollapsed,e.changeDetectorRef.detectChanges()})))}))}))},e.prototype.checkMenuWithoutChildren=function(){var e,t=this;this.menu&&(this.menu.forEach((function(t){t.children&&(e=!0)})),e||this.ngZone.runOutsideAngular((function(){setTimeout((function(){t.layoutStore.setSidebarLeftElementHeight(t.sidebarElement.nativeElement.offsetHeight)}))})))},e.prototype.setSidebarHeight=function(){if("fixed"===this.layout&&this.windowInnerHeight){var e=this.windowInnerHeight-this.headerService.offsetHeight;e&&e!==this.sidebarHeight&&(this.sidebarHeight=e,this.sidebarOverflow="auto",this.changeDetectorRef.detectChanges())}else this.sidebarHeight&&(this.sidebarOverflow=this.sidebarHeight=void 0,this.changeDetectorRef.detectChanges())},e}();H.decorators=[{type:t.Component,args:[{selector:"mk-layout-sidebar-left",template:'<aside class="main-sidebar">\n <section class="sidebar" #sidebarElement [style.height.px]="sidebarHeight" [style.overflow]="sidebarOverflow">\n <ng-content></ng-content>\n \t<ul class="sidebar-menu">\n <ng-container *ngFor="let item of menu">\n <ng-container *ngTemplateOutlet="sidebarInner; context: {item: item}"></ng-container>\n </ng-container>\n \t</ul>\n </section>\n</aside>\n\n<ng-template #sidebarInner let-item="item">\n <li [class.active]="item.isActive" [class.header]="item.separator" [class.menu-open]="!item.isCollapsed">\n <span *ngIf="item.separator">{{item.label}}</span>\n <a *ngIf="!item.separator && item.route" [routerLink]="item.route">\n \t<i [class]="getIconClasses(item)"></i><span>{{item.label}}</span>\n \t<span *ngIf="item.children || item.pullRights" class="pull-right-container">\n \t\t<span *ngFor="let rightItem of item.pullRights" class="pull-right {{rightItem.classes}}">{{rightItem.text}}</span>\n \t <i *ngIf="!item.pullRights" class="fa fa-angle-left pull-right"></i>\n \t</span>\n </a>\n <a *ngIf="!item.separator && !item.route" href="#" [mkMenuToggle]="item">\n \t<i [class]="getIconClasses(item)"></i><span>{{item.label}}</span>\n \t<span *ngIf="item.children || item.pullRights" class="pull-right-container">\n \t\t<span *ngFor="let rightItem of item.pullRights" class="pull-right {{rightItem.classes}}">{{rightItem.text}}</span>\n \t <i *ngIf="!item.pullRights" class="fa fa-angle-left pull-right"></i>\n \t</span>\n </a>\n <ul *ngIf="item.children" [mkCollapseAnimation]="item.isCollapsed" (mkCollapseAnimation.start)="visibilityStateStart($event)" class="treeview-menu">\n <ng-container *ngFor="let item of item.children">\n <ng-container *ngTemplateOutlet="sidebarInner; context: {item: item}"></ng-container>\n </ng-container>\n </ul>\n </li>\n</ng-template>\n',changeDetection:t.ChangeDetectionStrategy.OnPush,styles:[".treeview-menu.collapse{display:none}.treeview-menu,.treeview-menu.collapse.in{display:block}"]}]}],H.ctorParameters=function(){return[{type:t.ChangeDetectorRef},{type:h},{type:t.NgZone},{type:t.Renderer2},{type:o.Router},{type:p},{type:A},{type:f}]},H.propDecorators={sidebarElement:[{type:t.ViewChild,args:["sidebarElement",{static:!0}]}],sidebarLeftToggleDirectives:[{type:t.ViewChildren,args:[M]}]};var P=function(){};P.decorators=[{type:t.NgModule,args:[{imports:[n.CommonModule,o.RouterModule,T],exports:[H],declarations:[M,H]}]}];var B=function(){function e(e,t,n,o,r){this.elementRef=e,this.renderer2=t,this.layoutStore=n,this.sidebarRightService=o,this.wrapperService=r,this.listeners=[],this.subscriptions=[]}return e.prototype.ngOnInit=function(){var e=this;this.renderer2.addClass(this.elementRef.nativeElement,"control-sidebar"),this.subscriptions.push(this.layoutStore.isSidebarRightCollapsed.subscribe((function(t){e.isSidebarRightCollapsed=t,t?(e.renderer2.removeClass(e.elementRef.nativeElement,"control-sidebar-open"),e.isSidebarRightOverContent||e.renderer2.removeClass(e.wrapperService.wrapperElementRef.nativeElement,"control-sidebar-open")):(e.renderer2.addClass(e.elementRef.nativeElement,"control-sidebar-open"),e.isSidebarRightOverContent||e.renderer2.addClass(e.wrapperService.wrapperElementRef.nativeElement,"control-sidebar-open"))}))),this.subscriptions.push(this.layoutStore.isSidebarRightOverContent.subscribe((function(t){e.isSidebarRightOverContent=t,e.isSidebarRightCollapsed||(t?e.renderer2.removeClass(e.wrapperService.wrapperElementRef.nativeElement,"control-sidebar-open"):e.renderer2.addClass(e.wrapperService.wrapperElementRef.nativeElement,"control-sidebar-open"))}))),this.subscriptions.push(this.layoutStore.sidebarRightSkin.subscribe((function(t){e.skin!==t&&e.renderer2.removeClass(e.elementRef.nativeElement,"control-sidebar-"+e.skin),e.skin=t,e.renderer2.addClass(e.elementRef.nativeElement,"control-sidebar-"+t)})))},e.prototype.ngAfterViewInit=function(){this.sidebarRightService.elementRef=this.sidebarContentElement},e.prototype.ngOnDestroy=function(){this.listeners=C(this.listeners),this.subscriptions=y(this.subscriptions)},e}();B.decorators=[{type:t.Component,args:[{selector:"mk-layout-sidebar-right",template:'<div #sidebarContentElement class="control-sidebar-content">\n <ng-content></ng-content>\n</div>\n<div class="control-sidebar-bg"></div>\n',changeDetection:t.ChangeDetectionStrategy.OnPush,styles:[":host{display:block;height:100%}.control-sidebar-bg{z-index:-1}/deep/ .tab-content{padding:10px 15px}"]}]}],B.ctorParameters=function(){return[{type:t.ElementRef},{type:t.Renderer2},{type:h},{type:m},{type:A}]},B.propDecorators={sidebarContentElement:[{type:t.ViewChild,args:["sidebarContentElement",{static:!0}]}]};var j=function(){};j.decorators=[{type:t.NgModule,args:[{imports:[n.CommonModule],exports:[B],declarations:[B]}]}];var F=function(){function e(e,t,n,o,r){this.elementRef=e,this.renderer2=t,this.layoutStore=n,this.wrapperService=o,this.ngZone=r,this.listeners=[],this.subscriptions=[]}return e.prototype.ngOnInit=function(){var e=this;this.layoutStore.setWindowInnerHeight(window.innerHeight),this.layoutStore.setWindowInnerWidth(window.innerWidth),this.wrapperService.wrapperElementRef=this.elementRef,this.ngZone.runOutsideAngular((function(){e.listeners.push(e.renderer2.listen("window","resize",function(e,t){var n=this,o=0;return function(){for(var r=[],i=0;i<arguments.length;i++)r[i]=arguments[i];o||(o=setTimeout((function(){e.call.apply(e,c([n],r)),o=0}),t))}}((function(){e.layoutStore.setWindowInnerHeight(window.innerHeight),e.layoutStore.setWindowInnerWidth(window.innerWidth)}),250)))})),this.subscriptions.push(this.layoutStore.layout.subscribe((function(t){"fixed"===t?e.renderer2.addClass(e.elementRef.nativeElement,"fixed"):e.renderer2.removeClass(e.elementRef.nativeElement,"fixed"),"boxed"===t?e.renderer2.addClass(e.elementRef.nativeElement,"layout-boxed"):e.renderer2.removeClass(e.elementRef.nativeElement,"layout-boxed")}))),this.subscriptions.push(this.layoutStore.skin.subscribe((function(t){e.skin&&e.skin!==t&&e.renderer2.removeClass(e.elementRef.nativeElement,"skin-"+e.skin),e.skin=t,e.renderer2.addClass(e.elementRef.nativeElement,"skin-"+e.skin)})))},e.prototype.ngOnDestroy=function(){this.subscriptions=y(this.subscriptions),this.listeners=C(this.listeners)},e}();F.decorators=[{type:t.Component,args:[{selector:"mk-layout-wrapper",template:'<div class="wrapper overflow">\n <ng-content></ng-content>\n</div>\n',styles:[".wrapper.overflow{overflow:hidden}:host{display:block}:host /deep/ .sidebar-right-toggle>a{color:#fff}:host.sidebar-mini.sidebar-collapse /deep/ .treeview-menu.collapsing{height:auto!important}:host /deep/ .sidebar-right-toggle>a:hover{background:rgba(0,0,0,.1)}:host.skin-black-light /deep/ .sidebar-right-toggle>a,:host.skin-black /deep/ .sidebar-right-toggle>a{border-right-width:0;color:#333}:host.skin-black-light /deep/ .sidebar-right-toggle>a:hover,:host.skin-black /deep/ .sidebar-right-toggle>a:hover{background-color:#fff;color:#999}:host.skin-black /deep/ .sidebar-right-toggle>a{border-left:1px solid #eee}:host.skin-black-light /deep/ .sidebar-right-toggle>a{border-left:1px solid #d2d6de}"]}]}],F.ctorParameters=function(){return[{type:t.ElementRef},{type:t.Renderer2},{type:h},{type:A},{type:t.NgZone}]};var V=function(){};V.decorators=[{type:t.NgModule,args:[{imports:[n.CommonModule],exports:[F],declarations:[F]}]}];var W=function(){function e(e){this.router=e,this.isCustomLayout=new r.BehaviorSubject(!1),this.customLayout=!1,this.init()}return e.prototype.init=function(){var e=this;this.router.events.subscribe((function(t){t instanceof o.ActivationStart&&(e.customLayout=t.snapshot.data.customLayout,e.isCustomLayout.next(e.customLayout))}))},e}();W.decorators=[{type:t.Injectable}],W.ctorParameters=function(){return[{type:o.Router}]};var N=new t.InjectionToken("layoutConfig");function U(e){return new h(e)}function Z(e){return[{provide:h,useFactory:U,deps:[N]},{provide:N,useValue:e}]}var G=function(){function e(e){if(e)throw new Error("LayoutModule is already loaded. Import it in the AppModule only!")}return e.forRoot=function(t){return{ngModule:e,providers:c(Z(t),[W])}},e}();G.decorators=[{type:t.NgModule,args:[{imports:[n.CommonModule,o.RouterModule],exports:[S,k,O,P,j,V],providers:[p,A,m,f,b]}]}],G.ctorParameters=function(){return[{type:G,decorators:[{type:t.Optional},{type:t.SkipSelf}]}]};var q=["default","primary","danger","warning","info","success"],_={aqua:"#00c0ef","aqua-active":"#00a7d0",black:"#111111","black-active":"#000000",blue:"#0073b7","blue-active":"#005384",fuchsia:"#f012be","fuchsia-active":"#db0ead",green:"#00a65a","green-active":"#008d4c",gray:"#d2d6de","gray-active":"#b5bbc8","gray-light":"#f7f7f7","light-blue":"#3c8dbc","light-blue-active":"#357ca5",lime:"#01ff70","lime-active":"#00e765",maroon:"#d81b60","maroon-active":"#ca195a",navy:"#001f3f","navy-active":"#001a35",olive:"#3d9970","olive-active":"#368763",orange:"#ff851b","orange-active":"#ff7701",purple:"#605ca8","purple-active":"#555299",red:"#dd4b39","red-active":"#d33724",teal:"#39cccc","teal-active":"#30bbbb",yellow:"#f39c12","yellow-active":"#db8b0b"},$=function(){function e(e,t){this.renderer2=e,this.elementRef=t}return e.prototype.setBackgroundColor=function(e,t,n,o){if(e&&t)if(this.resetBackgroundColor(),_.hasOwnProperty(e)){var r=_[e];this.renderer2.addClass(this.elementRef.nativeElement,"bg-color"),this.currentBackgroundStyle={property:n,color:r},this.renderer2.setStyle(this.elementRef.nativeElement,n,r)}else this.renderer2.removeClass(this.elementRef.nativeElement,"bg-color"),0===e.indexOf("#")||0===e.indexOf("rgb")?(this.currentBackgroundStyle={property:n,color:e},this.renderer2.setStyle(this.elementRef.nativeElement,n,e)):-1!==q.indexOf(e)&&(this.currentBackgroundClass=o?o+"-"+e:e,this.renderer2.addClass(this.elementRef.nativeElement,this.currentBackgroundClass))},e.prototype.resetBackgroundColor=function(){this.currentBackgroundStyle?this.renderer2.removeStyle(this.elementRef.nativeElement,this.currentBackgroundStyle.property,this.currentBackgroundStyle.color):this.currentBackgroundClass&&this.renderer2.removeClass(this.elementRef.nativeElement,this.currentBackgroundClass)},e.prototype.setFontColor=function(e){this.resetFontColor(),e&&(e.startsWith("#")||e.startsWith("rgb")?(this.currentFontStyle=e,this.renderer2.setStyle(this.elementRef.nativeElement,"color",e)):(this.currentFontClass="text-"+e,this.renderer2.addClass(this.elementRef.nativeElement,this.currentFontClass)))},e.prototype.resetFontColor=function(){this.currentFontStyle?this.renderer2.removeStyle(this.elementRef.nativeElement,"color",this.currentFontStyle):this.currentFontClass&&this.renderer2.removeClass(this.elementRef.nativeElement,this.currentFontClass)},e}();$.decorators=[{type:t.Injectable}],$.ctorParameters=function(){return[{type:t.Renderer2},{type:t.ElementRef}]};var z=function(){function e(e,t,n){this.elementRef=e,this.renderer2=t,this.colorService=n,this.condition=!0}return Object.defineProperty(e.prototype,"setPrefix",{set:function(e){this.prefix=e,this.colorService.setBackgroundColor(this.color,this.condition,this.property,this.prefix)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"setColor",{set:function(e){e&&(this.color=e,this.colorService.setBackgroundColor(this.color,this.condition,this.property,this.prefix))},enumerable:!1,configurable:!0}),e}();z.decorators=[{type:t.Directive,args:[{selector:"[mkColor]",providers:[$]}]}],z.ctorParameters=function(){return[{type:t.ElementRef},{type:t.Renderer2},{type:$}]},z.propDecorators={condition:[{type:t.Input,args:["mkColorCondition"]}],setPrefix:[{type:t.Input,args:["mkColorPrefix"]}],property:[{type:t.Input,args:["mkColorProperty"]}],setColor:[{type:t.Input,args:["mkColor"]}]};var K=function(){function e(e,t,n){this.elementRef=e,this.renderer2=t,this.colorService=n}return Object.defineProperty(e.prototype,"color",{set:function(e){this.colorService.setFontColor(e)},enumerable:!1,configurable:!0}),e}();K.decorators=[{type:t.Directive,args:[{selector:"[mkFontColor]",providers:[$]}]}],K.ctorParameters=function(){return[{type:t.ElementRef},{type:t.Renderer2},{type:$}]},K.propDecorators={color:[{type:t.Input,args:["mkFontColor"]}]};var Y=function(){};Y.decorators=[{type:t.NgModule,args:[{exports:[z,K],declarations:[z,K]}]}];var J=function(e){this.elementRef=e};J.decorators=[{type:t.Directive,args:[{selector:"[mkAccordionToggle]"}]}],J.ctorParameters=function(){return[{type:t.ElementRef}]},J.propDecorators={accordionComponent:[{type:t.Input,args:["mkAccordionToggle"]}]};var Q=function(){};Q.decorators=[{type:t.Component,args:[{selector:"mk-accordion-header",template:"<ng-template #templateRef><ng-content></ng-content></ng-template>"}]}],Q.propDecorators={templateRef:[{type:t.ViewChild,args:["templateRef",{static:!0}]}]};var X=function(){};X.decorators=[{type:t.Component,args:[{selector:"mk-accordion-content",template:"<ng-template #templateRef><ng-content></ng-content></ng-template>"}]}],X.propDecorators={templateRef:[{type:t.ViewChild,args:["templateRef",{static:!0}]}]};var ee=function(){function e(){this.contentStyleClass="box-body",this.headerStyleClass="box-header with-border",this.isCollapsing=!1,this.isCollapsed=!1,this.index=0}return e.prototype.ngOnInit=function(){this.headerStyleColor=this.headerColor},e.prototype.ngAfterViewInit=function(){if(!this.header&&!this.accordionHeaderComponent)throw new Error('Attribute "header" OR Component "mk-accordion-header" is required for component "mk-accordion"')},e}();ee.decorators=[{type:t.Component,args:[{selector:"mk-accordion",template:"<ng-template #templateRef><ng-content></ng-content></ng-template>"}]}],ee.propDecorators={borderColor:[{type:t.Input}],contentColor:[{type:t.Input}],contentStyleClass:[{type:t.Input}],header:[{type:t.Input}],headerColor:[{type:t.Input}],headerColorHover:[{type:t.Input}],headerStyleClass:[{type:t.Input}],accordionHeaderComponent:[{type:t.ContentChild,args:[Q]}],accordionContentComponent:[{type:t.ContentChild,args:[X]}],templateRef:[{type:t.ViewChild,args:["templateRef",{static:!0}]}]};var te=function(){function e(e,n,o){this.changeDetectorRef=e,this.ngZone=n,this.renderer2=o,this.isMultiple=!1,this.styleClass="box-group",this.collapseStart=new t.EventEmitter,this.collapseDone=new t.EventEmitter,this.activeIndex=[0],this.listeners=[],this.subscriptions=[]}return Object.defineProperty(e.prototype,"_activeIndex",{set:function(e){this.activeIndex=e instanceof Array?e:[e]},enumerable:!1,configurable:!0}),e.headerMouseLeave=function(e){e.headerStyleColor=e.headerColor},e.headerMouseEnter=function(e){e.headerColorHover&&(e.headerStyleColor=e.headerColorHover)},e.prototype.ngAfterContentInit=function(){var e=this;this.setAccordionsIndex(),this.updateAccordionIsCollapsed(),this.subscriptions.push(this.accordionComponents.changes.subscribe((function(){e.setAccordionsIndex()})))},e.prototype.ngAfterViewInit=function(){var e=this;this.setAccordionsToggle(),this.subscriptions.push(this.accordionToggleDirectives.changes.subscribe((function(){e.setAccordionsToggle()})))},e.prototype.ngOnChanges=function(e){e._activeIndex.firstChange||this.updateAccordionIsCollapsed()},e.prototype.ngOnDestroy=function(){C(this.listeners),y(this.subscriptions)},e.prototype.toggleAccordion=function(e,t){e.preventDefault();var n=this.activeIndex.indexOf(t);-1===n?this.isMultiple?this.activeIndex.push(t):this.activeIndex=[t]:this.isMultiple?this.activeIndex.splice(n,1):this.activeIndex=[],this.updateAccordionIsCollapsed()},e.prototype.onCollapseStart=function(e,t){t.isCollapsing=!0,this.collapseStart.emit({animationEvent:e,index:t.index})},e.prototype.onCollapseDone=function(e,t){t.isCollapsing=!1,this.collapseDone.emit({animationEvent:e,index:t.index})},e.prototype.setAccordionsIndex=function(){this.accordionComponents.forEach((function(e,t){e.index=t}))},e.prototype.setAccordionsToggle=function(){var t=this;this.listeners=C(this.listeners),this.ngZone.runOutsideAngular((function(){t.accordionToggleDirectives.forEach((function(n){t.listeners.push(t.renderer2.listen(n.elementRef.nativeElement,"click",(function(e){t.toggleAccordion(e,n.accordionComponent.index),t.changeDetectorRef.detectChanges()}))),t.listeners.push(t.renderer2.listen(n.elementRef.nativeElement,"mouseenter",(function(){e.headerMouseEnter(n.accordionComponent),t.changeDetectorRef.detectChanges()}))),t.listeners.push(t.renderer2.listen(n.elementRef.nativeElement,"mouseleave",(function(){e.headerMouseLeave(n.accordionComponent),t.changeDetectorRef.detectChanges()})))}))}))},e.prototype.updateAccordionIsCollapsed=function(){var e=this;this.accordionComponents.forEach((function(t,n){t.isCollapsed=-1===e.activeIndex.indexOf(n)}))},e}();te.decorators=[{type:t.Component,args:[{selector:"mk-accordion-group",template:'<div [ngClass]="styleClass">\n <div *ngFor="let accordion of accordionComponents" class="panel box" [mkColor]="accordion.borderColor" mkColorProperty="border-top-color" mkColorPrefix="box">\n <div [ngClass]="accordion.headerStyleClass" [class.no-border]="accordion.isCollapsed && !accordion.isCollapsing">\n <h4 class="box-title">\n <a [mkAccordionToggle]="accordion" href="#" [mkFontColor]="accordion.headerStyleColor" [class.collapsed]="accordion.isCollapsed">\n {{accordion.header}}\n <ng-template *ngIf="!accordion.header && accordion.accordionHeaderComponent" [ngTemplateOutlet]="accordion.accordionHeaderComponent.templateRef"></ng-template>\n </a>\n </h4>\n </div>\n <div class="panel-collapse" [mkCollapseAnimation]="accordion.isCollapsed" (mkCollapseAnimation.start)="onCollapseStart($event, accordion)" (mkCollapseAnimation.done)="onCollapseDone($event, accordion)">\n <div [ngClass]="accordion.contentStyleClass" [mkFontColor]="accordion.contentColor">\n <ng-template *ngIf="!accordion.accordionContentComponent" [ngTemplateOutlet]="accordion.templateRef"></ng-template>\n <ng-template *ngIf="accordion.accordionContentComponent" [ngTemplateOutlet]="accordion.accordionContentComponent.templateRef"></ng-template>\n </div>\n </div>\n </div>\n</div>\n'}]}],te.ctorParameters=function(){return[{type:t.ChangeDetectorRef},{type:t.NgZone},{type:t.Renderer2}]},te.propDecorators={_activeIndex:[{type:t.Input,args:["activeIndex"]}],isMultiple:[{type:t.Input}],styleClass:[{type:t.Input}],collapseStart:[{type:t.Output}],collapseDone:[{type:t.Output}],accordionComponents:[{type:t.ContentChildren,args:[ee]}],accordionToggleDirectives:[{type:t.ViewChildren,args:[J]}]};var ne=function(){};ne.decorators=[{type:t.NgModule,args:[{imports:[n.CommonModule,T,Y],exports:[Q,X,ee,te],declarations:[J,Q,X,ee,te]}]}];var oe=function(){function e(e,n,o,r){this.changeDetectorRef=e,this.ngZone=n,this.renderer2=o,this.viewContainerRef=r,this.backgroundColor="danger",this.styleClass="",this.collapseStart=new t.EventEmitter,this.collapseDone=new t.EventEmitter,this.dismissibleClass="alert-dismissible",this.isDismissible=!0,this.remove=!1,this.removed=!1,this.type="alert",this.listeners=[]}return Object.defineProperty(e.protot