// © 2022 SolarWinds Worldwide, LLC. All rights reserved.
//
// Permission is hereby granted, free of charge, to any person obtaining a copy
//  of this software and associated documentation files (the "Software"), to
//  deal in the Software without restriction, including without limitation the
//  rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
//  sell copies of the Software, and to permit persons to whom the Software is
//  furnished to do so, subject to the following conditions:
//
// The above copyright notice and this permission notice shall be included in
//  all copies or substantial portions of the Software.
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
//  IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
//  FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
//  AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
//  LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
//  OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
//  THE SOFTWARE.
import { ChangeDetectorRef, Component, EventEmitter, HostBinding, Input, Output, } from "@angular/core";
import * as i0 from "@angular/core";
/** @ignore */
export class TabHeadingComponent {
    /** This adds 'disabled' class to the host component depending on the 'disabled' @Input to properly style disabled tabs */
    get isDisabled() {
        return this.disabled;
    }
    /** Tab active state toggle */
    set active(isActive) {
        this._active = isActive;
        this.changeDetector.detectChanges();
    }
    get active() {
        return this._active;
    }
    constructor(changeDetector) {
        this.changeDetector = changeDetector;
        /** Event is fired when tab became active, $event:Tab equals to selected instance of Tab component */
        this.selected = new EventEmitter();
    }
    selectTab() {
        this.selected.emit(this);
    }
}
TabHeadingComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.1.5", ngImport: i0, type: TabHeadingComponent, deps: [{ token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
TabHeadingComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.1.5", type: TabHeadingComponent, selector: "nui-tab-heading", inputs: { disabled: "disabled", active: "active", tabId: "tabId" }, outputs: { selected: "selected" }, host: { attributes: { "role": "tab" }, properties: { "class.disabled": "this.isDisabled" } }, ngImport: i0, template: "<div class=\"nui-tab-heading\" [class.active]=\"active\">\n    <span class=\"tab-link\" (click)=\"selectTab()\">\n        <ng-content></ng-content>\n    </span>\n</div>\n", styles: [":host{max-width:250px;min-height:37px;background-color:var(--nui-color-bg-transparent,transparent)}:host .nui-tab-heading{white-space:nowrap}:host .nui-tab-heading.active{border-left:none;border-bottom:3px solid;border-bottom-color:var(--nui-color-selected-contrast,#00c4d2)}:host .nui-tab-heading.active>.tab-link{color:var(--nui-color-text-default,#111);background-color:var(--nui-color-bg-content,#fff)}:host .nui-tab-heading .tab-link{background:var(--nui-color-bg-transparent,transparent);color:var(--nui-color-text-secondary,rgba(17, 17, 17, .6));line-height:var(--nui-line-height-default,18px);font-weight:var(--nui-font-weight-semibold,600);font-size:var(--nui-font-size-default,13px);display:block;padding:10px 15px;text-transform:uppercase;min-height:37px;cursor:pointer}:host .nui-tab-heading .tab-link:hover{background:var(--transparent,transparent)}:host.disabled>.nui-tab-heading .tab-link{cursor:not-allowed;color:var(--nui-color-text-disabled,rgba(17, 17, 17, .3))}:host.disabled>.nui-tab-heading .tab-link:hover{background:transparent}:host.disabled:hover{background:transparent}:host:hover{background:var(--nui-color-bg-transparent-hover,rgba(17, 17, 17, .05))}:host:focus{outline:none}:host-context(nui-tab-heading-group.vertical) .nui-tab-heading{max-width:250px;min-height:40px;border-left:3px solid transparent}:host-context(nui-tab-heading-group.vertical) .nui-tab-heading.active{border-bottom:none;border-left:3px solid;border-left-color:var(--nui-color-selected-contrast,#00c4d2)}:host-context(nui-tab-heading-group.vertical) .nui-tab-heading .tab-link{min-height:40px}\n"] });
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.1.5", ngImport: i0, type: TabHeadingComponent, decorators: [{
            type: Component,
            args: [{ selector: "nui-tab-heading", host: { role: "tab" }, template: "<div class=\"nui-tab-heading\" [class.active]=\"active\">\n    <span class=\"tab-link\" (click)=\"selectTab()\">\n        <ng-content></ng-content>\n    </span>\n</div>\n", styles: [":host{max-width:250px;min-height:37px;background-color:var(--nui-color-bg-transparent,transparent)}:host .nui-tab-heading{white-space:nowrap}:host .nui-tab-heading.active{border-left:none;border-bottom:3px solid;border-bottom-color:var(--nui-color-selected-contrast,#00c4d2)}:host .nui-tab-heading.active>.tab-link{color:var(--nui-color-text-default,#111);background-color:var(--nui-color-bg-content,#fff)}:host .nui-tab-heading .tab-link{background:var(--nui-color-bg-transparent,transparent);color:var(--nui-color-text-secondary,rgba(17, 17, 17, .6));line-height:var(--nui-line-height-default,18px);font-weight:var(--nui-font-weight-semibold,600);font-size:var(--nui-font-size-default,13px);display:block;padding:10px 15px;text-transform:uppercase;min-height:37px;cursor:pointer}:host .nui-tab-heading .tab-link:hover{background:var(--transparent,transparent)}:host.disabled>.nui-tab-heading .tab-link{cursor:not-allowed;color:var(--nui-color-text-disabled,rgba(17, 17, 17, .3))}:host.disabled>.nui-tab-heading .tab-link:hover{background:transparent}:host.disabled:hover{background:transparent}:host:hover{background:var(--nui-color-bg-transparent-hover,rgba(17, 17, 17, .05))}:host:focus{outline:none}:host-context(nui-tab-heading-group.vertical) .nui-tab-heading{max-width:250px;min-height:40px;border-left:3px solid transparent}:host-context(nui-tab-heading-group.vertical) .nui-tab-heading.active{border-bottom:none;border-left:3px solid;border-left-color:var(--nui-color-selected-contrast,#00c4d2)}:host-context(nui-tab-heading-group.vertical) .nui-tab-heading .tab-link{min-height:40px}\n"] }]
        }], ctorParameters: function () { return [{ type: i0.ChangeDetectorRef }]; }, propDecorators: { isDisabled: [{
                type: HostBinding,
                args: ["class.disabled"]
            }], disabled: [{
                type: Input
            }], active: [{
                type: Input
            }], tabId: [{
                type: Input
            }], selected: [{
                type: Output
            }] } });
//# sourceMappingURL=data:application/json;base64, 