| /** |
| * @fileoverview added by tsickle |
| * @suppress {checkTypes,extraRequire,missingReturn,uselessCode} checked by tsc |
| */ |
| import { Component, Input, ViewChild, Optional } from '@angular/core'; |
| import { Router } from '@angular/router'; |
| import { MatSidenav } from '@angular/material/sidenav'; |
| export class TdLayoutNavListComponent { |
| /** |
| * @param {?} _router |
| */ |
| constructor(_router) { |
| this._router = _router; |
| /** |
| * color?: string |
| * |
| * toolbar color option: primary | accent | warn. |
| * If [color] is not set, primary is used. |
| */ |
| this.color = 'primary'; |
| /** |
| * mode?: 'side', 'push' or 'over' |
| * |
| * The mode or styling of the sidenav. |
| * Defaults to "side". |
| * See "MatSidenav" documentation for more info. |
| * |
| * https://github.com/angular/material2/tree/master/src/lib/sidenav |
| */ |
| this.mode = 'side'; |
| /** |
| * opened?: boolean |
| * Whether or not the sidenav is opened. Use this binding to open/close the sidenav. |
| * Defaults to "true". |
| * |
| * See "MatSidenav" documentation for more info. |
| * |
| * https://github.com/angular/material2/tree/master/src/lib/sidenav |
| */ |
| this.opened = true; |
| /** |
| * sidenavWidth?: string |
| * |
| * Sets the "width" of the sidenav in either "px" or "%" |
| * Defaults to "350px". |
| * |
| * https://github.com/angular/material2/tree/master/src/lib/sidenav |
| */ |
| this.sidenavWidth = '350px'; |
| /** |
| * containerAutosize?: boolean |
| * |
| * Sets "autosize" of the sidenav-container. |
| * Defaults to "false". |
| * |
| * See documentation for more info and potential performance risks. |
| * |
| * https://github.com/angular/material2/blob/master/src/lib/sidenav/sidenav.md#resizing-an-open-sidenav |
| */ |
| this.containerAutosize = false; |
| } |
| /** |
| * Checks if `ESC` should close the sidenav |
| * Should only close it for `push` and `over` modes |
| * @return {?} |
| */ |
| get disableClose() { |
| return this.mode === 'side'; |
| } |
| /** |
| * Checks if router was injected. |
| * @return {?} |
| */ |
| get routerEnabled() { |
| return !!this._router && !!this.navigationRoute; |
| } |
| /** |
| * @return {?} |
| */ |
| handleNavigationClick() { |
| if (this.routerEnabled) { |
| this._router.navigateByUrl(this.navigationRoute); |
| } |
| } |
| /** |
| * Proxy toggle method to access sidenav from outside (from td-layout template). |
| * @return {?} |
| */ |
| toggle() { |
| return this.sidenav.toggle(!this.sidenav.opened); |
| } |
| /** |
| * Proxy open method to access sidenav from outside (from td-layout template). |
| * @return {?} |
| */ |
| open() { |
| return this.sidenav.open(); |
| } |
| /** |
| * Proxy close method to access sidenav from outside (from td-layout template). |
| * @return {?} |
| */ |
| close() { |
| return this.sidenav.close(); |
| } |
| } |
| TdLayoutNavListComponent.decorators = [ |
| { type: Component, args: [{ |
| selector: 'td-layout-nav-list', |
| template: "<div class=\"td-layout-nav-list-wrapper\">\n <mat-sidenav-container fullscreen [autosize]=\"containerAutosize\" class=\"td-layout-nav-list\">\n <mat-sidenav #sidenav\n position=\"start\"\n [mode]=\"mode\"\n [opened]=\"opened\"\n [disableClose]=\"disableClose\"\n [style.max-width]=\"sidenavWidth\"\n [style.min-width]=\"sidenavWidth\">\n <mat-toolbar [color]=\"color\">\n <ng-content select=\"[td-menu-button]\"></ng-content>\n <span *ngIf=\"icon || logo || toolbarTitle\"\n class=\"td-layout-nav-list-toolbar-content\"\n [class.cursor-pointer]=\"routerEnabled\"\n (click)=\"handleNavigationClick()\">\n <mat-icon *ngIf=\"icon\">{{icon}}</mat-icon>\n <mat-icon *ngIf=\"logo && !icon\" class=\"mat-icon-logo\" [svgIcon]=\"logo\"></mat-icon>\n <span *ngIf=\"toolbarTitle\">{{toolbarTitle}}</span>\n </span>\n <ng-content select=\"[td-sidenav-toolbar-content]\"></ng-content>\n </mat-toolbar>\n <div class=\"td-layout-nav-list-content\" cdkScrollable>\n <ng-content select=\"[td-sidenav-content]\"></ng-content>\n </div>\n </mat-sidenav>\n <div class=\"td-layout-nav-list-main\">\n <mat-toolbar [color]=\"color\">\n <ng-content select=\"[td-toolbar-content]\"></ng-content>\n </mat-toolbar>\n <div class=\"td-layout-nav-list-content\" cdkScrollable>\n <ng-content></ng-content>\n </div>\n <ng-content select=\"td-layout-footer-inner\"></ng-content>\n </div>\n </mat-sidenav-container>\n</div>\n<ng-content select=\"td-layout-footer\"></ng-content>", |
| styles: [":host{margin:0;width:100%;min-height:100%;height:100%;overflow:hidden;-webkit-box-orient:vertical;-webkit-box-direction:normal;-ms-flex-direction:column;flex-direction:column;-webkit-box-sizing:border-box;box-sizing:border-box;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-flex:1;-ms-flex:1;flex:1}:host .td-layout-nav-list-wrapper>.mat-sidenav-container>mat-sidenav.mat-drawer-side{border-right:0}[dir=rtl] :host .td-layout-nav-list-wrapper>.mat-sidenav-container>mat-sidenav.mat-drawer-side{border-left:0}:host .td-layout-nav-list-wrapper{-webkit-box-orient:vertical;-webkit-box-direction:normal;-ms-flex-direction:column;flex-direction:column;-webkit-box-sizing:border-box;box-sizing:border-box;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-flex:1;-ms-flex:1;flex:1;position:relative;overflow:auto;-webkit-overflow-scrolling:touch}:host .td-layout-nav-list-wrapper .td-layout-nav-list-toolbar-content{-webkit-box-orient:horizontal;-webkit-box-direction:normal;-ms-flex-direction:row;flex-direction:row;-webkit-box-sizing:border-box;box-sizing:border-box;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-ms-flex-line-pack:center;align-content:center;max-width:100%;-webkit-box-pack:start;-ms-flex-pack:start;justify-content:flex-start}:host .td-layout-nav-list-wrapper .td-layout-nav-list-content{text-align:start;-webkit-box-flex:1;-ms-flex:1;flex:1;display:block;position:relative;overflow:auto;-webkit-overflow-scrolling:touch}:host .td-layout-nav-list-wrapper .td-layout-nav-list-main{-webkit-box-orient:vertical;-webkit-box-direction:normal;-ms-flex-direction:column;flex-direction:column;-webkit-box-sizing:border-box;box-sizing:border-box;display:-webkit-box;display:-ms-flexbox;display:flex;margin:0;width:100%;min-height:100%;height:100%;position:relative;overflow:auto}:host .td-layout-nav-list-wrapper .td-layout-nav-list-main .td-layout-nav-list-content{display:block;position:relative;overflow:auto;-webkit-overflow-scrolling:touch;-webkit-box-flex:1;-ms-flex:1;flex:1}:host .td-layout-nav-list-wrapper mat-sidenav-container.td-layout-nav-list{-webkit-box-flex:1;-ms-flex:1;flex:1}:host .td-layout-nav-list-wrapper mat-sidenav-container.td-layout-nav-list>mat-sidenav.mat-drawer-closed,:host .td-layout-nav-list-wrapper mat-sidenav-container.td-layout-nav-list>mat-sidenav.mat-drawer-closing,:host .td-layout-nav-list-wrapper mat-sidenav-container.td-layout-nav-list>mat-sidenav.mat-drawer-opened,:host .td-layout-nav-list-wrapper mat-sidenav-container.td-layout-nav-list>mat-sidenav.mat-drawer-opening{-webkit-box-shadow:none;box-shadow:none}:host ::ng-deep mat-sidenav-container.td-layout-nav-list>.mat-drawer-content{-webkit-box-flex:1;-ms-flex-positive:1;flex-grow:1}:host ::ng-deep mat-sidenav-container.td-layout-nav-list>.mat-drawer>.mat-drawer-inner-container{-webkit-box-shadow:0 1px 3px 0 rgba(0,0,0,.2),0 1px 1px 0 rgba(0,0,0,.14),0 2px 1px -1px rgba(0,0,0,.12);box-shadow:0 1px 3px 0 rgba(0,0,0,.2),0 1px 1px 0 rgba(0,0,0,.14),0 2px 1px -1px rgba(0,0,0,.12);-webkit-box-sizing:border-box;box-sizing:border-box;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:vertical;-webkit-box-direction:normal;-ms-flex-direction:column;flex-direction:column}"] |
| }] } |
| ]; |
| /** @nocollapse */ |
| TdLayoutNavListComponent.ctorParameters = () => [ |
| { type: Router, decorators: [{ type: Optional }] } |
| ]; |
| TdLayoutNavListComponent.propDecorators = { |
| sidenav: [{ type: ViewChild, args: [MatSidenav,] }], |
| toolbarTitle: [{ type: Input, args: ['toolbarTitle',] }], |
| icon: [{ type: Input, args: ['icon',] }], |
| logo: [{ type: Input, args: ['logo',] }], |
| color: [{ type: Input, args: ['color',] }], |
| mode: [{ type: Input, args: ['mode',] }], |
| opened: [{ type: Input, args: ['opened',] }], |
| sidenavWidth: [{ type: Input, args: ['sidenavWidth',] }], |
| containerAutosize: [{ type: Input, args: ['containerAutosize',] }], |
| navigationRoute: [{ type: Input, args: ['navigationRoute',] }] |
| }; |
| if (false) { |
| /** @type {?} */ |
| TdLayoutNavListComponent.prototype.sidenav; |
| /** |
| * toolbarTitle?: string |
| * |
| * Title set in toolbar. |
| * @type {?} |
| */ |
| TdLayoutNavListComponent.prototype.toolbarTitle; |
| /** |
| * icon?: string |
| * icon name to be displayed before the title |
| * @type {?} |
| */ |
| TdLayoutNavListComponent.prototype.icon; |
| /** |
| * logo?: string |
| * |
| * logo icon name to be displayed before the title. |
| * If [icon] is set, then this will not be shown. |
| * @type {?} |
| */ |
| TdLayoutNavListComponent.prototype.logo; |
| /** |
| * color?: string |
| * |
| * toolbar color option: primary | accent | warn. |
| * If [color] is not set, primary is used. |
| * @type {?} |
| */ |
| TdLayoutNavListComponent.prototype.color; |
| /** |
| * mode?: 'side', 'push' or 'over' |
| * |
| * The mode or styling of the sidenav. |
| * Defaults to "side". |
| * See "MatSidenav" documentation for more info. |
| * |
| * https://github.com/angular/material2/tree/master/src/lib/sidenav |
| * @type {?} |
| */ |
| TdLayoutNavListComponent.prototype.mode; |
| /** |
| * opened?: boolean |
| * Whether or not the sidenav is opened. Use this binding to open/close the sidenav. |
| * Defaults to "true". |
| * |
| * See "MatSidenav" documentation for more info. |
| * |
| * https://github.com/angular/material2/tree/master/src/lib/sidenav |
| * @type {?} |
| */ |
| TdLayoutNavListComponent.prototype.opened; |
| /** |
| * sidenavWidth?: string |
| * |
| * Sets the "width" of the sidenav in either "px" or "%" |
| * Defaults to "350px". |
| * |
| * https://github.com/angular/material2/tree/master/src/lib/sidenav |
| * @type {?} |
| */ |
| TdLayoutNavListComponent.prototype.sidenavWidth; |
| /** |
| * containerAutosize?: boolean |
| * |
| * Sets "autosize" of the sidenav-container. |
| * Defaults to "false". |
| * |
| * See documentation for more info and potential performance risks. |
| * |
| * https://github.com/angular/material2/blob/master/src/lib/sidenav/sidenav.md#resizing-an-open-sidenav |
| * @type {?} |
| */ |
| TdLayoutNavListComponent.prototype.containerAutosize; |
| /** |
| * navigationRoute?: string |
| * |
| * option to set the combined route for the icon, logo, and toolbarTitle. |
| * @type {?} |
| */ |
| TdLayoutNavListComponent.prototype.navigationRoute; |
| /** @type {?} */ |
| TdLayoutNavListComponent.prototype._router; |
| } |
| //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoibGF5b3V0LW5hdi1saXN0LmNvbXBvbmVudC5qcyIsInNvdXJjZVJvb3QiOiJuZzovL0Bjb3ZhbGVudC9jb3JlL2xheW91dC8iLCJzb3VyY2VzIjpbImxheW91dC1uYXYtbGlzdC9sYXlvdXQtbmF2LWxpc3QuY29tcG9uZW50LnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7Ozs7QUFBQSxPQUFPLEVBQUUsU0FBUyxFQUFFLEtBQUssRUFBRSxTQUFTLEVBQUUsUUFBUSxFQUFFLE1BQU0sZUFBZSxDQUFDO0FBQ3RFLE9BQU8sRUFBRSxNQUFNLEVBQUUsTUFBTSxpQkFBaUIsQ0FBQztBQUV6QyxPQUFPLEVBQUUsVUFBVSxFQUF5QixNQUFNLDJCQUEyQixDQUFDO0FBUzlFLE1BQU0sT0FBTyx3QkFBd0I7Ozs7SUFtR25DLFlBQWdDLE9BQWU7UUFBZixZQUFPLEdBQVAsT0FBTyxDQUFROzs7Ozs7O1FBcEUvQixVQUFLLEdBQVcsU0FBUyxDQUFDOzs7Ozs7Ozs7O1FBVzNCLFNBQUksR0FBNkIsTUFBTSxDQUFDOzs7Ozs7Ozs7O1FBV3RDLFdBQU0sR0FBWSxJQUFJLENBQUM7Ozs7Ozs7OztRQVVqQixpQkFBWSxHQUFXLE9BQU8sQ0FBQzs7Ozs7Ozs7Ozs7UUFZMUIsc0JBQWlCLEdBQVksS0FBSyxDQUFDO0lBd0JiLENBQUM7Ozs7OztJQVhuRCx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