import { Component, Inject, NgModule } from '@angular/core';
import { CommonModule } from '@angular/common';
import { UxTabsComponentModule, UxTabComponentModule, } from '@eui/components/legacy/ux-tab';
import { BaseGroupComponent } from '../../../core/base-group/base-group.component';
import { DYNAMIC_COMPONENT_CONFIG } from '@eui/core';
import { UxDynFormChildContainerComponentModule } from '../../core/form-child-container/form-child-container.component';
import * as i0 from "@angular/core";
import * as i1 from "@eui/components/legacy/ux-tab";
import * as i2 from "../../core/form-child-container/form-child-container.component";
import * as i3 from "@angular/common";
export class TabContainerComponent extends BaseGroupComponent {
    constructor(config) {
        super(config);
        this.inputs = this.context.inputs;
        if (this.inputs.tabs[0] && typeof this.inputs.tabs[0] === 'string') {
            this.simpleMode = true;
            this.stringTabs = this.inputs.tabs;
        }
        else {
            this.simpleMode = false;
            this.configTabs = this.inputs.tabs;
        }
    }
    ngOnInit() {
    }
}
/** @nocollapse */ TabContainerComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.11", ngImport: i0, type: TabContainerComponent, deps: [{ token: DYNAMIC_COMPONENT_CONFIG }], target: i0.ɵɵFactoryTarget.Component });
/** @nocollapse */ TabContainerComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.11", type: TabContainerComponent, selector: "ux-dyn-tab-container", usesInheritance: true, ngImport: i0, template: "<ng-container *ngIf=\"simpleMode\">\n<ux-tabs styleClass=\"white\">\n    <ux-tab *ngFor=\"let tab of stringTabs; let i = index\" [label]=\"tab\" [isActive]=\"!i?true:false\">\n        <ux-dyn-form-child-container [config]=\"childrenConfig[i]\" [frameId]=\"frameId\" [parent]=\"dynFormGroup\">\n        </ux-dyn-form-child-container>\n    </ux-tab>\n</ux-tabs>\n</ng-container>\n<ng-container *ngIf=\"!simpleMode\">\n    <ux-tabs styleClass=\"white\">\n        <ux-tab *ngFor=\"let tab of configTabs;let i = index\"\n                [label]=\"tab.label\"\n                [subLabel]=\"tab.subLabel\"\n                [isActive]=\"tab.active\"\n                [isClosable]=\"tab.closable\"\n                [isDisabled]=\"tab.disabled\"\n                [isVisible]=\"tab.visible\"\n        >\n            <ux-dyn-form-child-container [config]=\"childrenConfig[i]\" [frameId]=\"frameId\" [parent]=\"dynFormGroup\">\n            </ux-dyn-form-child-container>\n        </ux-tab>\n    </ux-tabs>\n</ng-container>\n", styles: [""], components: [{ type: i1.UxTabsComponent, selector: "ux-tabs", inputs: ["styleClass", "tabs", "isMainNavigation", "isSubTabs", "activeTabIndex", "e2eAttr"], outputs: ["tabSelected", "tabClosed", "activeTabIndexChange"] }, { type: i1.UxTabComponent, selector: "ux-tab", inputs: ["id", "index", "label", "subLabel", "iconClass", "iconTypeClass", "isClosable", "isDisabled", "tag", "tagTypeClass", "hasMarker", "markerTypeClass", "isActive", "url", "isVisible", "hasValidationErrors", "styleClass", "labelStyleClass", "e2eAttr"] }, { type: i2.FormChildContainerComponent, selector: "ux-dyn-form-child-container", inputs: ["config", "frameId", "parent", "parentData"] }], directives: [{ type: i3.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i3.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }] });
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.11", ngImport: i0, type: TabContainerComponent, decorators: [{
            type: Component,
            args: [{ selector: 'ux-dyn-tab-container', template: "<ng-container *ngIf=\"simpleMode\">\n<ux-tabs styleClass=\"white\">\n    <ux-tab *ngFor=\"let tab of stringTabs; let i = index\" [label]=\"tab\" [isActive]=\"!i?true:false\">\n        <ux-dyn-form-child-container [config]=\"childrenConfig[i]\" [frameId]=\"frameId\" [parent]=\"dynFormGroup\">\n        </ux-dyn-form-child-container>\n    </ux-tab>\n</ux-tabs>\n</ng-container>\n<ng-container *ngIf=\"!simpleMode\">\n    <ux-tabs styleClass=\"white\">\n        <ux-tab *ngFor=\"let tab of configTabs;let i = index\"\n                [label]=\"tab.label\"\n                [subLabel]=\"tab.subLabel\"\n                [isActive]=\"tab.active\"\n                [isClosable]=\"tab.closable\"\n                [isDisabled]=\"tab.disabled\"\n                [isVisible]=\"tab.visible\"\n        >\n            <ux-dyn-form-child-container [config]=\"childrenConfig[i]\" [frameId]=\"frameId\" [parent]=\"dynFormGroup\">\n            </ux-dyn-form-child-container>\n        </ux-tab>\n    </ux-tabs>\n</ng-container>\n", styles: [""] }]
        }], ctorParameters: function () { return [{ type: undefined, decorators: [{
                    type: Inject,
                    args: [DYNAMIC_COMPONENT_CONFIG]
                }] }]; } });
export class UxDynTabContainerComponentModule {
}
/** @nocollapse */ UxDynTabContainerComponentModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.11", ngImport: i0, type: UxDynTabContainerComponentModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
/** @nocollapse */ UxDynTabContainerComponentModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.3.11", ngImport: i0, type: UxDynTabContainerComponentModule, declarations: [TabContainerComponent], imports: [CommonModule,
        UxTabsComponentModule,
        UxTabComponentModule,
        UxDynFormChildContainerComponentModule], exports: [TabContainerComponent] });
/** @nocollapse */ UxDynTabContainerComponentModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.3.11", ngImport: i0, type: UxDynTabContainerComponentModule, imports: [[
            CommonModule,
            UxTabsComponentModule,
            UxTabComponentModule,
            UxDynFormChildContainerComponentModule,
        ]] });
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.11", ngImport: i0, type: UxDynTabContainerComponentModule, decorators: [{
            type: NgModule,
            args: [{
                    imports: [
                        CommonModule,
                        UxTabsComponentModule,
                        UxTabComponentModule,
                        UxDynFormChildContainerComponentModule,
                    ],
                    exports: [TabContainerComponent],
                    declarations: [TabContainerComponent],
                }]
        }] });
//# sourceMappingURL=data:application/json;base64, 