import { Component, HostBinding } from '@angular/core';
import { EclSiteHeaderLoginComponent } from '../../common/ecl-site-header-login.component';
import * as i0 from "@angular/core";
import * as i1 from "../../../ecl-icon/ecl-icon.component";
import * as i2 from "@angular/common";
import * as i3 from "../../../ecl-link/ecl-link.directive";
import * as i4 from "@ngx-translate/core";
export class EclSiteHeaderHarmonisedLoginComponent extends EclSiteHeaderLoginComponent {
    constructor() {
        super(...arguments);
        this.class = 'ecl-site-header-harmonised__login-container';
    }
    getLoginBoxCssClasses() {
        return [
            'ecl-site-header-harmonised__login-box',
            this.isLoginBoxActive ? 'ecl-site-header-harmonised__login-box--active' : ''
        ].join(' ');
    }
}
/** @nocollapse */ /** @nocollapse */ EclSiteHeaderHarmonisedLoginComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.0", ngImport: i0, type: EclSiteHeaderHarmonisedLoginComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
/** @nocollapse */ /** @nocollapse */ EclSiteHeaderHarmonisedLoginComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.2.0", type: EclSiteHeaderHarmonisedLoginComponent, selector: "ecl-site-header-harmonised-login", host: { properties: { "class": "this.class" } }, usesInheritance: true, ngImport: i0, template: "<ng-container *ngIf=\"!isLoggedIn\">\n    <a eclLink\n        href=\"#\"\n        variant=\"standalone\" \n        class=\"ecl-site-header-harmonised__login-toggle\" \n        [attr.aria-expanded]=\"isLoginBoxActive\"\n        (click)=\"onLoginClick($event)\">\n        <ecl-icon icon=\"log-in\" size=\"s\" class=\"ecl-site-header-harmonised__icon\"></ecl-icon>\n        {{ 'ecl.site-header.LOGIN' | translate }}\n    </a>\n</ng-container>\n<ng-container *ngIf=\"isLoggedIn\">\n    <a eclLink\n        href=\"#\"\n        class=\"ecl-site-header-harmonised__login-toggle\" \n        aria-controls=\"login-box-id\" \n        [attr.aria-expanded]=\"isLoginBoxActive\"\n        (click)=\"onLoginBoxToggle($event)\">\n        <ecl-icon icon=\"logged-in\" size=\"s\" class=\"ecl-site-header-harmonised__icon\"></ecl-icon>\n        {{ 'ecl.site-header.LOGGED-IN' | translate }}\n        <ecl-icon icon=\"corner-arrow\" size=\"xs\" class=\"ecl-site-header-harmonised__login-arrow\"></ecl-icon>\n    </a>\n    <div class=\"{{ getLoginBoxCssClasses() }}\">\n        <ng-content></ng-content>\n    </div>\n</ng-container>", styles: [".ecl-site-header-harmonised__login-toggle .ecl-site-header-harmonised__login-arrow{display:inline-flex}\n"], components: [{ type: i1.EclIconComponent, selector: "ecl-icon", inputs: ["iconSet", "icon", "size", "color", "transform", "ariaLabelledby", "role", "ariaHidden", "focusable"] }], directives: [{ type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i3.EclLinkDirective, selector: "[eclLink]", inputs: ["variant", "isNegative", "isNoVisited"] }], pipes: { "translate": i4.TranslatePipe } });
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.0", ngImport: i0, type: EclSiteHeaderHarmonisedLoginComponent, decorators: [{
            type: Component,
            args: [{ selector: 'ecl-site-header-harmonised-login', styles: [`
        .ecl-site-header-harmonised__login-toggle .ecl-site-header-harmonised__login-arrow {
            display: inline-flex;
        }
    `], template: "<ng-container *ngIf=\"!isLoggedIn\">\n    <a eclLink\n        href=\"#\"\n        variant=\"standalone\" \n        class=\"ecl-site-header-harmonised__login-toggle\" \n        [attr.aria-expanded]=\"isLoginBoxActive\"\n        (click)=\"onLoginClick($event)\">\n        <ecl-icon icon=\"log-in\" size=\"s\" class=\"ecl-site-header-harmonised__icon\"></ecl-icon>\n        {{ 'ecl.site-header.LOGIN' | translate }}\n    </a>\n</ng-container>\n<ng-container *ngIf=\"isLoggedIn\">\n    <a eclLink\n        href=\"#\"\n        class=\"ecl-site-header-harmonised__login-toggle\" \n        aria-controls=\"login-box-id\" \n        [attr.aria-expanded]=\"isLoginBoxActive\"\n        (click)=\"onLoginBoxToggle($event)\">\n        <ecl-icon icon=\"logged-in\" size=\"s\" class=\"ecl-site-header-harmonised__icon\"></ecl-icon>\n        {{ 'ecl.site-header.LOGGED-IN' | translate }}\n        <ecl-icon icon=\"corner-arrow\" size=\"xs\" class=\"ecl-site-header-harmonised__login-arrow\"></ecl-icon>\n    </a>\n    <div class=\"{{ getLoginBoxCssClasses() }}\">\n        <ng-content></ng-content>\n    </div>\n</ng-container>" }]
        }], propDecorators: { class: [{
                type: HostBinding,
                args: ['class']
            }] } });
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZWNsLXNpdGUtaGVhZGVyLWhhcm1vbmlzZWQtbG9naW4uY29tcG9uZW50LmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4vLi4vLi4vLi4vLi4vc3JjL2xpYi9jb21wb25lbnRzL2VjbC1zaXRlLWhlYWRlci9lY2wtc2l0ZS1oZWFkZXItaGFybW9uaXNlZC9sb2dpbi9lY2wtc2l0ZS1oZWFkZXItaGFybW9uaXNlZC1sb2dpbi5jb21wb25lbnQudHMiLCIuLi8uLi8uLi8uLi8uLi8uLi8uLi9zcmMvbGliL2NvbXBvbmVudHMvZWNsLXNpdGUtaGVhZGVyL2VjbC1zaXRlLWhlYWRlci1oYXJtb25pc2VkL2xvZ2luL2VjbC1zaXRlLWhlYWRlci1oYXJtb25pc2VkLWxvZ2luLmNvbXBvbmVudC5odG1sIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBLE9BQU8sRUFBRSxTQUFTLEVBQUUsV0FBVyxFQUFhLE1BQU0sZUFBZSxDQUFDO0FBRWxFLE9BQU8sRUFBRSwyQkFBMkIsRUFBRSxNQUFNLDhDQUE4QyxDQUFDOzs7Ozs7QUFXM0YsTUFBTSxPQUFPLHFDQUFzQyxTQUFRLDJCQUEyQjtJQVR0Rjs7UUFVMEIsVUFBSyxHQUFHLDZDQUE2QyxDQUFDO0tBUS9FO0lBT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