@netgrif/components
Version:
Netgrif Application Engine frontend Angular components
29 lines • 9.84 kB
JavaScript
import { Component } from '@angular/core';
import { AbstractQuickPanelComponent } from '@netgrif/components-core';
import * as i0 from "@angular/core";
import * as i1 from "@netgrif/components-core";
import * as i2 from "@angular/common";
import * as i3 from "@ngbracket/ngx-layout";
import * as i4 from "@angular/material/button";
import * as i5 from "@angular/material/icon";
import * as i6 from "@angular/material/menu";
import * as i7 from "./logout-shortcut/logout-shortcut.component";
import * as i8 from "./language-selector/language-selector.component";
import * as i9 from "./internal-link/internal-link.component";
import * as i10 from "./impersonate-quick-panel/impersonate-quick-panel.component";
export class QuickPanelComponent extends AbstractQuickPanelComponent {
_select;
_paperView;
constructor(_select, _paperView) {
super(_select, _paperView);
this._select = _select;
this._paperView = _paperView;
}
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: QuickPanelComponent, deps: [{ token: i1.LanguageService }, { token: i1.PaperViewService }], target: i0.ɵɵFactoryTarget.Component });
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.3.12", type: QuickPanelComponent, selector: "nc-quick-panel", usesInheritance: true, ngImport: i0, template: "<div fxLayout=\"row\" fxLayoutAlign=\"space-between center\" class=\"quick-panel\" [style.width.px]=\"width\">\n <nc-language-selector *ngIf=\"items.includes('language')\"></nc-language-selector>\n <nc-internal-link *ngIf=\"items.includes('settings')\" icon=\"settings\" link=\"/settings\"></nc-internal-link>\n <nc-impersonate-quick-panel *ngIf=\"items.includes('impersonation')\"></nc-impersonate-quick-panel>\n <nc-logout-shortcut *ngIf=\"items.includes('logout')\"></nc-logout-shortcut>\n\n <button mat-icon-button [matMenuTriggerFor]=\"quickPanelMoreMenu\">\n <mat-icon class=\"quick-panel-more-icon\">more_vert</mat-icon>\n </button>\n</div>\n<mat-menu #quickPanelMoreMenu=\"matMenu\">\n <button mat-menu-item (click)=\"setPaperView()\" fxLayout=\"row\" fxLayoutAlign=\"start center\">\n <mat-icon *ngIf=\"isPaperView()\">cancel</mat-icon>\n <mat-icon *ngIf=\"!isPaperView()\">check</mat-icon>\n <span>{{isPaperView() ? 'Disable' : 'Enable'}} Paper View</span>\n </button>\n</mat-menu>\n", styles: [".quick-panel{height:62px;padding:8px}.quick-panel-more-icon{text-align:center;font-size:24px}\n"], dependencies: [{ kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i3.DefaultLayoutDirective, selector: " [fxLayout], [fxLayout.xs], [fxLayout.sm], [fxLayout.md], [fxLayout.lg], [fxLayout.xl], [fxLayout.lt-sm], [fxLayout.lt-md], [fxLayout.lt-lg], [fxLayout.lt-xl], [fxLayout.gt-xs], [fxLayout.gt-sm], [fxLayout.gt-md], [fxLayout.gt-lg]", inputs: ["fxLayout", "fxLayout.xs", "fxLayout.sm", "fxLayout.md", "fxLayout.lg", "fxLayout.xl", "fxLayout.lt-sm", "fxLayout.lt-md", "fxLayout.lt-lg", "fxLayout.lt-xl", "fxLayout.gt-xs", "fxLayout.gt-sm", "fxLayout.gt-md", "fxLayout.gt-lg"] }, { kind: "directive", type: i3.DefaultLayoutAlignDirective, selector: " [fxLayoutAlign], [fxLayoutAlign.xs], [fxLayoutAlign.sm], [fxLayoutAlign.md], [fxLayoutAlign.lg], [fxLayoutAlign.xl], [fxLayoutAlign.lt-sm], [fxLayoutAlign.lt-md], [fxLayoutAlign.lt-lg], [fxLayoutAlign.lt-xl], [fxLayoutAlign.gt-xs], [fxLayoutAlign.gt-sm], [fxLayoutAlign.gt-md], [fxLayoutAlign.gt-lg]", inputs: ["fxLayoutAlign", "fxLayoutAlign.xs", "fxLayoutAlign.sm", "fxLayoutAlign.md", "fxLayoutAlign.lg", "fxLayoutAlign.xl", "fxLayoutAlign.lt-sm", "fxLayoutAlign.lt-md", "fxLayoutAlign.lt-lg", "fxLayoutAlign.lt-xl", "fxLayoutAlign.gt-xs", "fxLayoutAlign.gt-sm", "fxLayoutAlign.gt-md", "fxLayoutAlign.gt-lg"] }, { kind: "component", type: i4.MatIconButton, selector: "button[mat-icon-button]", exportAs: ["matButton"] }, { kind: "component", type: i5.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "component", type: i6.MatMenu, selector: "mat-menu", inputs: ["backdropClass", "aria-label", "aria-labelledby", "aria-describedby", "xPosition", "yPosition", "overlapTrigger", "hasBackdrop", "class", "classList"], outputs: ["closed", "close"], exportAs: ["matMenu"] }, { kind: "component", type: i6.MatMenuItem, selector: "[mat-menu-item]", inputs: ["role", "disabled", "disableRipple"], exportAs: ["matMenuItem"] }, { kind: "directive", type: i6.MatMenuTrigger, selector: "[mat-menu-trigger-for], [matMenuTriggerFor]", inputs: ["mat-menu-trigger-for", "matMenuTriggerFor", "matMenuTriggerData", "matMenuTriggerRestoreFocus"], outputs: ["menuOpened", "onMenuOpen", "menuClosed", "onMenuClose"], exportAs: ["matMenuTrigger"] }, { kind: "component", type: i7.LogoutShortcutComponent, selector: "nc-logout-shortcut" }, { kind: "component", type: i8.LanguageSelectorComponent, selector: "nc-language-selector" }, { kind: "component", type: i9.InternalLinkComponent, selector: "nc-internal-link" }, { kind: "component", type: i10.ImpersonateQuickPanelComponent, selector: "nc-impersonate-quick-panel" }] });
}
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: QuickPanelComponent, decorators: [{
type: Component,
args: [{ selector: 'nc-quick-panel', template: "<div fxLayout=\"row\" fxLayoutAlign=\"space-between center\" class=\"quick-panel\" [style.width.px]=\"width\">\n <nc-language-selector *ngIf=\"items.includes('language')\"></nc-language-selector>\n <nc-internal-link *ngIf=\"items.includes('settings')\" icon=\"settings\" link=\"/settings\"></nc-internal-link>\n <nc-impersonate-quick-panel *ngIf=\"items.includes('impersonation')\"></nc-impersonate-quick-panel>\n <nc-logout-shortcut *ngIf=\"items.includes('logout')\"></nc-logout-shortcut>\n\n <button mat-icon-button [matMenuTriggerFor]=\"quickPanelMoreMenu\">\n <mat-icon class=\"quick-panel-more-icon\">more_vert</mat-icon>\n </button>\n</div>\n<mat-menu #quickPanelMoreMenu=\"matMenu\">\n <button mat-menu-item (click)=\"setPaperView()\" fxLayout=\"row\" fxLayoutAlign=\"start center\">\n <mat-icon *ngIf=\"isPaperView()\">cancel</mat-icon>\n <mat-icon *ngIf=\"!isPaperView()\">check</mat-icon>\n <span>{{isPaperView() ? 'Disable' : 'Enable'}} Paper View</span>\n </button>\n</mat-menu>\n", styles: [".quick-panel{height:62px;padding:8px}.quick-panel-more-icon{text-align:center;font-size:24px}\n"] }]
}], ctorParameters: () => [{ type: i1.LanguageService }, { type: i1.PaperViewService }] });
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicXVpY2stcGFuZWwuY29tcG9uZW50LmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4vLi4vLi4vLi4vLi4vcHJvamVjdHMvbmV0Z3JpZi1jb21wb25lbnRzL3NyYy9saWIvbmF2aWdhdGlvbi9xdWljay1wYW5lbC9jb21wb25lbnRzL3F1aWNrLXBhbmVsLmNvbXBvbmVudC50cyIsIi4uLy4uLy4uLy4uLy4uLy4uLy4uL3Byb2plY3RzL25ldGdyaWYtY29tcG9uZW50cy9zcmMvbGliL25hdmlnYXRpb24vcXVpY2stcGFuZWwvY29tcG9uZW50cy9xdWljay1wYW5lbC5jb21wb25lbnQuaHRtbCJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQSxPQUFPLEVBQUMsU0FBUyxFQUFDLE1BQU0sZUFBZSxDQUFDO0FBQ3hDLE9BQU8sRUFBQywyQkFBMkIsRUFBb0MsTUFBTSwwQkFBMEIsQ0FBQzs7Ozs7Ozs7Ozs7O0FBT3hHLE1BQU0sT0FBTyxtQkFBb0IsU0FBUSwyQkFBMkI7SUFDMUM7SU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