forked from coreui/coreui-angular
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathcoreui-angular.umd.min.js
2 lines (2 loc) · 27.6 KB
/
coreui-angular.umd.min.js
1
2
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports,require("@angular/common"),require("@angular/core"),require("@angular/router"),require("rxjs"),require("rxjs/operators")):"function"==typeof define&&define.amd?define("@coreui/angular",["exports","@angular/common","@angular/core","@angular/router","rxjs","rxjs/operators"],t):t(((e=e||self).coreui=e.coreui||{},e.coreui.angular={}),e.ng.common,e.ng.core,e.ng.router,e.rxjs,e.rxjs.operators)}(this,function(e,t,n,r,i,s){"use strict";var a=["sidebar-show","sidebar-sm-show","sidebar-md-show","sidebar-lg-show","sidebar-xl-show"],o=["aside-menu-show","aside-menu-sm-show","aside-menu-md-show","aside-menu-lg-show","aside-menu-xl-show"],d=function(){function e(e,t){this.document=e,this.renderer=t}return e.prototype.removeClasses=function(e){var t=this;return-1!==e.map(function(e){return t.document.body.classList.contains(e)}).indexOf(!0)},e.prototype.toggleClasses=function(e,t){var n=this,r=t.indexOf(e),i=t.slice(0,r+1);this.removeClasses(i)?i.map(function(e){return n.renderer.removeClass(n.document.body,e)}):this.renderer.addClass(this.document.body,e)},e.decorators=[{type:n.Injectable}],e.ctorParameters=function(){return[{type:undefined,decorators:[{type:n.Inject,args:[t.DOCUMENT]}]},{type:n.Renderer2}]},e}(),p=function(){function e(e){this.classToggler=e}return e.prototype.ngOnInit=function(){this.bp=this.breakpoint},e.prototype.toggleOpen=function(e){e.preventDefault();var t=this.bp?"sidebar-"+this.bp+"-show":a[0];this.classToggler.toggleClasses(t,a)},e.decorators=[{type:n.Directive,args:[{selector:"[appSidebarToggler]",providers:[d]}]}],e.ctorParameters=function(){return[{type:d}]},e.propDecorators={breakpoint:[{type:n.Input,args:["appSidebarToggler"]}],toggleOpen:[{type:n.HostListener,args:["click",["$event"]]}]},e}(),l=function(){function e(e,t){this.document=e,this.renderer=t}return e.prototype.toggleOpen=function(e){e.preventDefault();var t=this.document.body;t.classList.contains("sidebar-minimized")?this.renderer.removeClass(t,"sidebar-minimized"):this.renderer.addClass(t,"sidebar-minimized")},e.decorators=[{type:n.Directive,args:[{selector:"[appSidebarMinimizer]"}]}],e.ctorParameters=function(){return[{type:undefined,decorators:[{type:n.Inject,args:[t.DOCUMENT]}]},{type:n.Renderer2}]},e.propDecorators={toggleOpen:[{type:n.HostListener,args:["click",["$event"]]}]},e}(),c=function(){function e(e,t){this.document=e,this.renderer=t}return e.prototype.toggleOpen=function(e){e.preventDefault();var t=this.document.body;t.classList.contains("sidebar-show")?this.renderer.removeClass(t,"sidebar-show"):this.renderer.addClass(t,"sidebar-show")},e.decorators=[{type:n.Directive,args:[{selector:"[appMobileSidebarToggler]"}]}],e.ctorParameters=function(){return[{type:undefined,decorators:[{type:n.Inject,args:[t.DOCUMENT]}]},{type:n.Renderer2}]},e.propDecorators={toggleOpen:[{type:n.HostListener,args:["click",["$event"]]}]},e}(),u=function(){function e(e,t){this.document=e,this.renderer=t}return e.prototype.toggleOpen=function(e){e.preventDefault();var t=this.document.body;t.classList.contains("sidebar-off-canvas")&&(t.classList.contains("sidebar-show")?this.renderer.removeClass(t,"sidebar-show"):this.renderer.addClass(t,"sidebar-show"))},e.decorators=[{type:n.Directive,args:[{selector:"[appSidebarClose]"}]}],e.ctorParameters=function(){return[{type:undefined,decorators:[{type:n.Inject,args:[t.DOCUMENT]}]},{type:n.Renderer2}]},e.propDecorators={toggleOpen:[{type:n.HostListener,args:["click",["$event"]]}]},e}(),m=function(){function e(e,t){this.document=e,this.renderer=t}return e.prototype.toggleOpen=function(e){e.preventDefault();var t=this.document.body;t.classList.contains("brand-minimized")?this.renderer.removeClass(t,"brand-minimized"):this.renderer.addClass(t,"brand-minimized")},e.decorators=[{type:n.Directive,args:[{selector:"[appBrandMinimizer]"}]}],e.ctorParameters=function(){return[{type:undefined,decorators:[{type:n.Inject,args:[t.DOCUMENT]}]},{type:n.Renderer2}]},e.propDecorators={toggleOpen:[{type:n.HostListener,args:["click",["$event"]]}]},e}(),g=function(){function e(e){this.classToggler=e}return e.prototype.ngOnInit=function(){this.bp=this.breakpoint},e.prototype.toggleOpen=function(e){e.preventDefault();var t=this.bp?"aside-menu-"+this.bp+"-show":o[0];this.classToggler.toggleClasses(t,o)},e.decorators=[{type:n.Directive,args:[{selector:"[appAsideMenuToggler]",providers:[d]}]}],e.ctorParameters=function(){return[{type:d}]},e.propDecorators={breakpoint:[{type:n.Input,args:["appAsideMenuToggler"]}],toggleOpen:[{type:n.HostListener,args:["click",["$event"]]}]},e}(),h=function(){function e(e,t){this.renderer=e,this.el=t}return e.prototype.ngOnInit=function(){var e=this.appHtmlAttr;for(var t in e)"style"===t&&"object"==typeof e[t]?this.setStyle(e[t]):"class"===t?this.addClass(e[t]):this.setAttrib(t,e[t])},e.prototype.setStyle=function(e){for(var t in e)this.renderer.setStyle(this.el.nativeElement,t,e[t])},e.prototype.addClass=function(e){var t=this;(Array.isArray(e)?e:e.split(" ")).filter(function(e){return e.length>0}).forEach(function(e){t.renderer.addClass(t.el.nativeElement,e)})},e.prototype.setAttrib=function(e,t){null!==t?this.renderer.setAttribute(this.el.nativeElement,e,t):this.renderer.removeAttribute(this.el.nativeElement,e)},e.decorators=[{type:n.Directive,args:[{selector:"[appHtmlAttr]"}]}],e.ctorParameters=function(){return[{type:n.Renderer2},{type:n.ElementRef}]},e.propDecorators={appHtmlAttr:[{type:n.Input}]},e}(),f=function(){function e(){}return e.decorators=[{type:n.NgModule,args:[{imports:[t.CommonModule],exports:[g,m,c,p,l,u,h],declarations:[g,m,c,p,l,u,h],providers:[d]}]}],e}();var b=function(){function e(e,t,n){this.document=e,this.renderer=t,this.hostElement=n,this.fixedClass="aside-menu-fixed",t.addClass(n.nativeElement,"aside-menu")}return e.prototype.ngOnInit=function(){this.isFixed(this.fixed),this.isOffCanvas(this.offCanvas),this.displayBreakpoint(this.display)},e.prototype.ngOnDestroy=function(){this.renderer.removeClass(this.document.body,this.fixedClass)},e.prototype.isFixed=function(e){void 0===e&&(e=this.fixed),e&&this.renderer.addClass(this.document.body,this.fixedClass)},e.prototype.isOffCanvas=function(e){void 0===e&&(e=this.offCanvas),e&&this.renderer.addClass(this.document.body,"aside-menu-off-canvas")},e.prototype.displayBreakpoint=function(e){if(void 0===e&&(e=this.display),!1!==e){var t=this.display?"aside-menu-"+this.display+"-show":o[0];this.renderer.addClass(this.document.body,t)}},e.decorators=[{type:n.Component,args:[{selector:"app-aside, cui-aside",template:"<ng-content></ng-content>"}]}],e.ctorParameters=function(){return[{type:undefined,decorators:[{type:n.Inject,args:[t.DOCUMENT]}]},{type:n.Renderer2},{type:n.ElementRef}]},e.propDecorators={display:[{type:n.Input}],fixed:[{type:n.Input}],offCanvas:[{type:n.Input}]},e}(),y=function(){function e(){}return e.decorators=[{type:n.NgModule,args:[{imports:[t.CommonModule,f],exports:[b,f],declarations:[b]}]}],e}(),v=function(){function e(e,t){var n=this;this.router=e,this.route=t,this._breadcrumbs=new i.BehaviorSubject(new Array),this.breadcrumbs=this._breadcrumbs.asObservable(),this.router.events.pipe(s.filter(function(e){return e instanceof r.NavigationEnd})).subscribe(function(e){var t=[],r=n.route.root,i="";do{var s=r.children;r=null,s.forEach(function(e){if("primary"===e.outlet){var n=e.snapshot;i+="/"+n.url.map(function(e){return e.path}).join("/"),t.push({label:e.snapshot.data,url:i}),r=e}})}while(r);return n._breadcrumbs.next(Object.assign([],t)),t})}return e.decorators=[{type:n.Injectable}],e.ctorParameters=function(){return[{type:r.Router},{type:r.ActivatedRoute}]},e}(),C=function(){function e(e,t,n,r){this.document=e,this.renderer=t,this.service=n,this.el=r,this.fixedClass="breadcrumb-fixed"}return e.prototype.ngOnInit=function(){!function(e){for(var t=e.nativeElement,n=t.parentElement;t.firstChild;)n.insertBefore(t.firstChild,t);n.removeChild(t)}(this.el),this.isFixed(this.fixed),this.breadcrumbs=this.service.breadcrumbs},e.prototype.ngOnDestroy=function(){this.renderer.removeClass(this.document.body,this.fixedClass)},e.prototype.isFixed=function(e){void 0===e&&(e=this.fixed),e&&this.renderer.addClass(this.document.body,this.fixedClass)},e.decorators=[{type:n.Component,args:[{selector:"app-breadcrumb",template:'\n <ng-template ngFor let-breadcrumb [ngForOf]="breadcrumbs | async" let-last = last>\n <li class="breadcrumb-item"\n *ngIf="breadcrumb.label.title && (breadcrumb.url.slice(-1) == \'/\' || last)"\n [ngClass]="{active: last}">\n <a *ngIf="!last" [routerLink]="breadcrumb.url">{{breadcrumb.label.title}}</a>\n <span *ngIf="last" [routerLink]="breadcrumb.url">{{breadcrumb.label.title}}</span>\n </li>\n </ng-template>\n '}]}],e.ctorParameters=function(){return[{type:undefined,decorators:[{type:n.Inject,args:[t.DOCUMENT]}]},{type:n.Renderer2},{type:v},{type:n.ElementRef}]},e.propDecorators={fixed:[{type:n.Input}]},e}(),I=function(){function e(e,t,n){this.document=e,this.renderer=t,this.service=n,this.fixedClass="breadcrumb-fixed"}return e.prototype.ngOnInit=function(){this.isFixed(this.fixed),this.breadcrumbs=this.service.breadcrumbs},e.prototype.ngOnDestroy=function(){this.renderer.removeClass(this.document.body,this.fixedClass)},e.prototype.isFixed=function(e){void 0===e&&(e=this.fixed),e&&this.renderer.addClass(this.document.body,this.fixedClass)},e.decorators=[{type:n.Component,args:[{selector:"cui-breadcrumb",template:'<ol class="breadcrumb">\r\n <ng-template ngFor let-breadcrumb [ngForOf]="breadcrumbs | async" let-last = last>\r\n <li class="breadcrumb-item"\r\n *ngIf="breadcrumb.label.title && (breadcrumb.url.slice(-1) == \'/\' || last)"\r\n [ngClass]="{active: last}">\r\n <a *ngIf="!last" [routerLink]="breadcrumb.url">{{breadcrumb.label.title}}</a>\r\n <span *ngIf="last" [routerLink]="breadcrumb.url">{{breadcrumb.label.title}}</span>\r\n </li>\r\n </ng-template>\r\n <ng-content></ng-content>\r\n</ol>\r\n'}]}],e.ctorParameters=function(){return[{type:undefined,decorators:[{type:n.Inject,args:[t.DOCUMENT]}]},{type:n.Renderer2},{type:v}]},e.propDecorators={fixed:[{type:n.Input}]},e}(),x=function(){function e(){}return e.forRoot=function(t){return{ngModule:e,providers:[v]}},e.decorators=[{type:n.NgModule,args:[{imports:[t.CommonModule,r.RouterModule],exports:[C,I],declarations:[C,I]}]}],e}(),T=function(){function e(e,t,n){this.document=e,this.renderer=t,this.hostElement=n,this.fixedClass="footer-fixed",t.addClass(n.nativeElement,"app-footer")}return e.prototype.ngOnInit=function(){this.isFixed(this.fixed)},e.prototype.ngOnDestroy=function(){this.renderer.removeClass(this.document.body,this.fixedClass)},e.prototype.isFixed=function(e){void 0===e&&(e=this.fixed),e&&this.renderer.addClass(this.document.body,this.fixedClass)},e.decorators=[{type:n.Component,args:[{selector:"app-footer, cui-footer",template:"<ng-content></ng-content>"}]}],e.ctorParameters=function(){return[{type:undefined,decorators:[{type:n.Inject,args:[t.DOCUMENT]}]},{type:n.Renderer2},{type:n.ElementRef}]},e.propDecorators={fixed:[{type:n.Input}]},e}(),D=function(){function e(){}return e.decorators=[{type:n.NgModule,args:[{imports:[t.CommonModule],exports:[T],declarations:[T]}]}],e}(),M=function(){function e(e,t,n){this.document=e,this.renderer=t,this.hostElement=n,this.navbarBrandText={icon:"🅲",text:"🅲 CoreUI"},this.navbarBrandRouterLink="",this.fixedClass="header-fixed",this.breakpoints=["xl","lg","md","sm","xs"],this.sidebarTogglerClass="d-none d-md-block",this.sidebarTogglerMobileClass="d-lg-none",this.asideTogglerClass="d-none d-md-block",this.asideTogglerMobileClass="d-lg-none",t.addClass(n.nativeElement,"app-header"),t.addClass(n.nativeElement,"navbar")}return e.prototype.ngOnInit=function(){this.isFixed(this.fixed),this.navbarBrandImg=Boolean(this.navbarBrand||this.navbarBrandFull||this.navbarBrandMinimized),this.navbarBrandRouterLink=this.navbarBrandRouterLink[0]?this.navbarBrandRouterLink:this.navbarBrandHref,this.sidebarTogglerClass=this.setToggerBreakpointClass(this.sidebarToggler),this.sidebarTogglerMobileClass=this.setToggerMobileBreakpointClass(this.sidebarToggler),this.asideTogglerClass=this.setToggerBreakpointClass(this.asideMenuToggler),this.asideTogglerMobileClass=this.setToggerMobileBreakpointClass(this.asideMenuToggler)},e.prototype.ngOnDestroy=function(){this.renderer.removeClass(this.document.body,this.fixedClass)},e.prototype.isFixed=function(e){void 0===e&&(e=this.fixed),e&&this.renderer.addClass(this.document.body,this.fixedClass)},e.prototype.setToggerBreakpointClass=function(e){void 0===e&&(e="md");var t="d-none d-md-block";if(this.breakpoints.includes(e)){this.breakpoints.indexOf(e);t="d-none d-"+e+"-block"}return t},e.prototype.setToggerMobileBreakpointClass=function(e){void 0===e&&(e="lg");var t="d-lg-none";return this.breakpoints.includes(e)&&(t="d-"+e+"-none"),t},e.decorators=[{type:n.Component,args:[{selector:"app-header, cui-header",template:'<ng-template [ngIf]="mobileSidebarToggler != false">\n <button class="navbar-toggler {{sidebarTogglerMobileClass}}" type="button" appSidebarToggler>\n <span class="navbar-toggler-icon"></span>\n </button>\n</ng-template>\n<a class="navbar-brand" [routerLink]="navbarBrandRouterLink">\n <ng-template [ngIf]="navbarBrandImg">\n <img *ngIf="navbarBrand"\n [appHtmlAttr]="navbarBrand"\n [ngClass]="\'navbar-brand\'">\n <img *ngIf="navbarBrandFull"\n [appHtmlAttr]="navbarBrandFull"\n [ngClass]="\'navbar-brand-full\'">\n <img *ngIf="navbarBrandMinimized"\n [appHtmlAttr]="navbarBrandMinimized"\n [ngClass]="\'navbar-brand-minimized\'">\n </ng-template>\n <ng-template [ngIf]="!navbarBrandImg">\n <div class="navbar-brand-full" [innerHTML]="navbarBrandText.text"></div>\n <div class="navbar-brand-minimized" [innerHTML]="navbarBrandText.icon"></div>\n </ng-template>\n</a>\n<ng-template [ngIf]="sidebarToggler != false">\n <button class="navbar-toggler {{sidebarTogglerClass}}" type="button" [appSidebarToggler]="sidebarToggler">\n <span class="navbar-toggler-icon"></span>\n </button>\n</ng-template>\n<ng-content></ng-content>\n<ng-template [ngIf]="asideMenuToggler != false">\n <button class="navbar-toggler {{asideTogglerClass}}" type="button" [appAsideMenuToggler]="asideMenuToggler">\n <span class="navbar-toggler-icon"></span>\n </button>\n</ng-template>\n<ng-template [ngIf]="mobileAsideMenuToggler != false">\n <button class="navbar-toggler {{asideTogglerMobileClass}}" type="button" appAsideMenuToggler>\n <span class="navbar-toggler-icon"></span>\n </button>\n</ng-template>\n'}]}],e.ctorParameters=function(){return[{type:undefined,decorators:[{type:n.Inject,args:[t.DOCUMENT]}]},{type:n.Renderer2},{type:n.ElementRef}]},e.propDecorators={fixed:[{type:n.Input}],navbarBrand:[{type:n.Input}],navbarBrandFull:[{type:n.Input}],navbarBrandMinimized:[{type:n.Input}],navbarBrandText:[{type:n.Input}],navbarBrandHref:[{type:n.Input}],navbarBrandRouterLink:[{type:n.Input}],sidebarToggler:[{type:n.Input}],mobileSidebarToggler:[{type:n.Input}],asideMenuToggler:[{type:n.Input}],mobileAsideMenuToggler:[{type:n.Input}]},e}(),O=function(){function e(){}return e.decorators=[{type:n.NgModule,args:[{imports:[t.CommonModule,r.RouterModule,f],exports:[M,f],declarations:[M]}]}],e}(),k=function(){function e(e,t,n){this.document=e,this.renderer=t,this.hostElement=n,t.addClass(n.nativeElement,"sidebar")}return e.prototype.ngOnInit=function(){this.displayBreakpoint(this.display),this.isCompact(this.compact),this.isFixed(this.fixed),this.isMinimized(this.minimized),this.isOffCanvas(this.offCanvas)},e.prototype.ngOnDestroy=function(){this.renderer.removeClass(this.document.body,"sidebar-fixed")},e.prototype.isCompact=function(e){void 0===e&&(e=this.compact),e&&this.renderer.addClass(this.document.body,"sidebar-compact")},e.prototype.isFixed=function(e){void 0===e&&(e=this.fixed),e&&this.renderer.addClass(this.document.body,"sidebar-fixed")},e.prototype.isMinimized=function(e){void 0===e&&(e=this.minimized),e&&this.renderer.addClass(this.document.body,"sidebar-minimized")},e.prototype.isOffCanvas=function(e){void 0===e&&(e=this.offCanvas),e&&this.renderer.addClass(this.document.body,"sidebar-off-canvas")},e.prototype.displayBreakpoint=function(e){if(void 0===e&&(e=this.display),!1!==e){var t=e?"sidebar-"+e+"-show":a[0];this.renderer.addClass(this.document.body,t)}},e.decorators=[{type:n.Component,args:[{selector:"app-sidebar",template:"<ng-content></ng-content>"}]}],e.ctorParameters=function(){return[{type:undefined,decorators:[{type:n.Inject,args:[t.DOCUMENT]}]},{type:n.Renderer2},{type:n.ElementRef}]},e.propDecorators={compact:[{type:n.Input}],display:[{type:n.Input}],fixed:[{type:n.Input}],minimized:[{type:n.Input}],offCanvas:[{type:n.Input}]},e}(),E=function(){function e(e,t){this.renderer=e,this.hostElement=t,e.addClass(t.nativeElement,"app-sidebar-footer")}return e.prototype.ngOnInit=function(){},e.decorators=[{type:n.Component,args:[{selector:"app-sidebar-footer",template:"<ng-content></ng-content>"}]}],e.ctorParameters=function(){return[{type:n.Renderer2},{type:n.ElementRef}]},e}(),w=function(){function e(e,t){this.renderer=e,this.hostElement=t,e.addClass(t.nativeElement,"sidebar-form")}return e.prototype.ngOnInit=function(){},e.decorators=[{type:n.Component,args:[{selector:"app-sidebar-form",template:"<ng-content></ng-content>"}]}],e.ctorParameters=function(){return[{type:n.Renderer2},{type:n.ElementRef}]},e}(),B=function(){function e(e,t){this.renderer=e,this.hostElement=t,e.addClass(t.nativeElement,"sidebar-header")}return e.prototype.ngOnInit=function(){},e.decorators=[{type:n.Component,args:[{selector:"app-sidebar-header",template:"<ng-content></ng-content>"}]}],e.ctorParameters=function(){return[{type:n.Renderer2},{type:n.ElementRef}]},e}(),A=function(){function e(e,t,n){this.document=e,this.renderer=t,this.hostElement=n,this.role="button",t.addClass(n.nativeElement,"sidebar-minimizer")}return e.prototype.toggleOpen=function(e){e.preventDefault();var t=this.document.body;t.classList.contains("sidebar-minimized")?this.renderer.removeClass(t,"sidebar-minimized"):this.renderer.addClass(t,"sidebar-minimized"),t.classList.contains("brand-minimized")?this.renderer.removeClass(t,"brand-minimized"):this.renderer.addClass(t,"brand-minimized")},e.prototype.ngOnInit=function(){},e.decorators=[{type:n.Component,args:[{selector:"app-sidebar-minimizer",template:""}]}],e.ctorParameters=function(){return[{type:undefined,decorators:[{type:n.Inject,args:[t.DOCUMENT]}]},{type:n.Renderer2},{type:n.ElementRef}]},e.propDecorators={role:[{type:n.HostBinding,args:["attr.role"]}],toggleOpen:[{type:n.HostListener,args:["click",["$event"]]}]},e}(),R=function(){function e(e){this.el=e}return e.prototype.toggle=function(){this.el.nativeElement.classList.toggle("open")},e.decorators=[{type:n.Directive,args:[{selector:"[appNavDropdown]"}]}],e.ctorParameters=function(){return[{type:n.ElementRef}]},e}(),L=function(){function e(e){this.dropdown=e}return e.prototype.toggleOpen=function(e){e.preventDefault(),this.dropdown.toggle()},e.decorators=[{type:n.Directive,args:[{selector:"[appNavDropdownToggle]"}]}],e.ctorParameters=function(){return[{type:R}]},e.propDecorators={toggleOpen:[{type:n.HostListener,args:["click",["$event"]]}]},e}(),j=function(){function e(e,t,n){this.router=e,this.renderer=t,this.hostElement=n,this.role="nav",t.addClass(n.nativeElement,"sidebar-nav")}return e.prototype.ngOnChanges=function(e){this.navItemsArray=JSON.parse(JSON.stringify(this.navItems||[]))},e.decorators=[{type:n.Component,args:[{selector:"app-sidebar-nav",template:'<app-sidebar-nav-items\r\n class="nav"\r\n [items]="navItemsArray">\r\n</app-sidebar-nav-items>\r\n'}]}],e.ctorParameters=function(){return[{type:r.Router},{type:n.Renderer2},{type:n.ElementRef}]},e.propDecorators={navItems:[{type:n.Input}],role:[{type:n.HostBinding,args:["attr.role"]}]},e}(),z=function(){function e(){}return e.prototype.ngOnInit=function(){},e.decorators=[{type:n.Component,args:[{selector:"app-sidebar-nav-divider",template:""}]}],e.ctorParameters=function(){return[]},e.propDecorators={item:[{type:n.Input}]},e}(),P=function(){function e(){this.hasBadge=function(e){return Boolean(e.badge)},this.hasIcon=function(e){return Boolean(e.icon)}}return e.prototype.itemType=function(e){return e.divider?"divider":e.title?"title":e.children?"dropdown":e.label?"label":Object.keys(e).length?"link":"empty"},e.prototype.getClass=function(e){var t,n=this.itemType(e);return t=["divider","title"].includes(n)?"nav-"+n:"dropdown"===n?"nav-item nav-dropdown":"nav-item",e["class"]?t+" "+e["class"]:t},e.prototype.isActive=function(e,t){return e.isActive(t.url,!1)},e.prototype.getIconClass=function(e){var t={"nav-icon":!0};return t[e.icon]=!!e.icon,t},e.prototype.getBadgeClass=function(e){var t={badge:!0};return t["badge-"+e.badge.variant]=!!e.badge.variant,t},e}(),S=function(){function e(e){this.helper=e}return e.decorators=[{type:n.Component,args:[{selector:"app-sidebar-nav-dropdown",template:'\n <a class="nav-link nav-dropdown-toggle"\n appNavDropdownToggle\n [appHtmlAttr]="item.attributes">\n <i *ngIf="helper.hasIcon(item)" [ngClass]="helper.getIconClass(item)"></i>\n <ng-container>{{item.name}}</ng-container>\n <span *ngIf="helper.hasBadge(item)" [ngClass]="helper.getBadgeClass(item)">{{ item.badge.text }}</span>\n </a>\n <app-sidebar-nav-items\n class="nav-dropdown-items"\n [items]="item.children">\n </app-sidebar-nav-items>\n ',providers:[P],styles:[".nav-dropdown-toggle { cursor: pointer; }",".nav-dropdown-items { display: block; }"]}]}],e.ctorParameters=function(){return[{type:P}]},e.propDecorators={item:[{type:n.Input}]},e}(),H=function(){function e(e,t){this.router=e,this.helper=t}return e.decorators=[{type:n.Component,args:[{selector:"app-sidebar-nav-items",template:'\n <ng-container *ngFor="let item of items">\n <ng-container [ngSwitch]="helper.itemType(item)">\n <app-sidebar-nav-dropdown\n *ngSwitchCase="\'dropdown\'"\n [item]="item"\n [class.open]="helper.isActive(router, item)"\n [ngClass]="helper.getClass(item)"\n appNavDropdown\n routerLinkActive="open">\n </app-sidebar-nav-dropdown>\n <app-sidebar-nav-divider\n *ngSwitchCase="\'divider\'"\n [item]="item"\n [ngClass]="helper.getClass(item)"\n [appHtmlAttr]="item.attributes">\n </app-sidebar-nav-divider>\n <app-sidebar-nav-title\n *ngSwitchCase="\'title\'"\n [item]="item"\n [ngClass]="helper.getClass(item)"\n [appHtmlAttr]="item.attributes">\n </app-sidebar-nav-title>\n <app-sidebar-nav-label\n *ngSwitchCase="\'label\'"\n [item]="item"\n class="nav-item"\n [ngClass]="helper.getClass(item)">\n </app-sidebar-nav-label>\n <ng-container\n *ngSwitchCase="\'empty\'">\n </ng-container>\n <app-sidebar-nav-link\n *ngSwitchDefault\n [item]="item"\n class="nav-item"\n [ngClass]="helper.getClass(item)">\n </app-sidebar-nav-link>\n </ng-container>\n </ng-container>\n '}]}],e.ctorParameters=function(){return[{type:r.Router},{type:P}]},e.propDecorators={items:[{type:n.Input}]},e}(),N=function(){function e(e,t,n){this.document=e,this.renderer=t,this.helper=n}return e.prototype.ngOnInit=function(){this.linkType=this.getLinkType(),this.href=this.isDisabled()?"":this.item.url},e.prototype.getLinkClass=function(){var e=this.isDisabled(),t={"nav-link":!0,disabled:e,"btn-link":e};this.hasVariant()&&(t["nav-link-"+this.item.variant]=!0);return t},e.prototype.getLinkType=function(){return this.isExternalLink()?"external":"link"},e.prototype.hasVariant=function(){return!!this.item.variant},e.prototype.isDisabled=function(){return!(!this.item.attributes||!this.item.attributes.disabled)||null},e.prototype.isExternalLink=function(){return"http"===this.item.url.substring(0,4)},e.prototype.hideMobile=function(){this.document.body.classList.contains("sidebar-show")&&this.renderer.removeClass(this.document.body,"sidebar-show")},e.decorators=[{type:n.Component,args:[{selector:"app-sidebar-nav-link",template:'<ng-container [ngSwitch]="linkType">\r\n <a *ngSwitchCase="\'external\'"\r\n [ngClass]="getLinkClass()"\r\n href="{{item.url}}"\r\n [appHtmlAttr]="item.attributes">\r\n <i *ngIf="helper.hasIcon(item)" [ngClass]="helper.getIconClass(item)"></i>\r\n <ng-container>{{item.name}}</ng-container>\r\n <span *ngIf="helper.hasBadge(item)" [ngClass]="helper.getBadgeClass(item)">{{ item.badge.text }}</span>\r\n </a>\r\n <a *ngSwitchDefault\r\n [ngClass]="getLinkClass()"\r\n [appHtmlAttr]="item.attributes"\r\n [attr.disabled]="isDisabled()"\r\n routerLinkActive="active"\r\n [routerLink]="[item.url]"\r\n (click)="hideMobile()">\r\n <i *ngIf="helper.hasIcon(item)" [ngClass]="helper.getIconClass(item)"></i>\r\n <ng-container>{{item.name}}</ng-container>\r\n <span *ngIf="helper.hasBadge(item)" [ngClass]="helper.getBadgeClass(item)">{{ item.badge.text }}</span>\r\n </a>\r\n</ng-container>\r\n',providers:[P]}]}],e.ctorParameters=function(){return[{type:undefined,decorators:[{type:n.Inject,args:[t.DOCUMENT]}]},{type:n.Renderer2},{type:P}]},e.propDecorators={item:[{type:n.Input}]},e}(),F=function(){function e(e,t){this.el=e,this.renderer=t}return e.prototype.ngOnInit=function(){var e=this.el.nativeElement,t=this.renderer.createText(this.item.name);if(this.item["class"]){var n=this.item["class"];this.renderer.addClass(e,n)}if(this.item.wrapper){var r=this.renderer.createElement(this.item.wrapper.element);this.addAttribs(this.item.wrapper.attributes,r),this.renderer.appendChild(r,t),this.renderer.appendChild(e,r)}else this.renderer.appendChild(e,t)},e.prototype.addAttribs=function(e,t){if(e)for(var n in e)"style"===n&&"object"==typeof e[n]?this.setStyle(e[n],t):"class"===n?this.addClass(e[n],t):this.setAttrib(n,e[n],t)},e.prototype.setStyle=function(e,t){for(var n in e)this.renderer.setStyle(t,n,e[n])},e.prototype.addClass=function(e,t){var n=this;(Array.isArray(e)?e:e.split(" ")).filter(function(e){return e.length>0}).forEach(function(e){n.renderer.addClass(t,e)})},e.prototype.setAttrib=function(e,t,n){this.renderer.setAttribute(n,e,t)},e.decorators=[{type:n.Component,args:[{selector:"app-sidebar-nav-title",template:""}]}],e.ctorParameters=function(){return[{type:n.ElementRef},{type:n.Renderer2}]},e.propDecorators={item:[{type:n.Input}]},e}(),U=function(){function e(e){this.helper=e}return e.prototype.ngOnInit=function(){},e.prototype.getItemClass=function(){var e={"nav-label":!0,active:!0},t=this.item["class"];return e[t]=!!t,e},e.prototype.getLabelIconClass=function(){var e=this.helper.getIconClass(this.item),t="text-"+this.item.label.variant;e[t]=!!t;var n=this.item.label["class"];return e[n]=!!n,e},e.decorators=[{type:n.Component,args:[{selector:"app-sidebar-nav-label",template:'<a [ngClass]="getItemClass()"\r\n href="{{item.url}}"\r\n [appHtmlAttr]="item.attributes">\r\n <i *ngIf="helper.hasIcon(item)" [ngClass]="getLabelIconClass()"></i>\r\n <ng-container>{{item.name}}</ng-container>\r\n <span *ngIf="helper.hasBadge(item)" [ngClass]="helper.getBadgeClass(item)">{{ item.badge.text }}</span>\r\n</a>\r\n'}]}],e.ctorParameters=function(){return[{type:P}]},e.propDecorators={item:[{type:n.Input}]},e}(),$=function(){function e(){}return e.decorators=[{type:n.NgModule,args:[{imports:[t.CommonModule,r.RouterModule,f],exports:[E,w,B,A,k,H,j,z,S,N,F,R,L,f],declarations:[E,w,B,A,A,k,H,j,z,S,N,F,R,L,U],providers:[P]}]}],e}();e.AppAsideModule=y,e.AppBreadcrumbModule=x,e.AppFooterModule=D,e.AppHeaderModule=O,e.AppSidebarModule=$,e.ɵa=f,e.ɵb=p,e.ɵba=F,e.ɵbb=R,e.ɵbc=L,e.ɵbd=U,e.ɵc=l,e.ɵd=c,e.ɵe=u,e.ɵf=m,e.ɵg=g,e.ɵh=h,e.ɵi=d,e.ɵj=b,e.ɵk=C,e.ɵl=v,e.ɵm=I,e.ɵn=T,e.ɵo=M,e.ɵp=E,e.ɵq=w,e.ɵr=B,e.ɵs=A,e.ɵt=k,e.ɵu=H,e.ɵv=P,e.ɵw=j,e.ɵx=z,e.ɵy=S,e.ɵz=N,Object.defineProperty(e,"__esModule",{value:!0})});
//# sourceMappingURL=coreui-angular.umd.min.js.map