import { Component, Input, HostListener } from '@angular/core';
import { SimpoElementsModule } from './../../elements/index';
import { CommonModule } from '@angular/common';
import { SimpoComponentModule } from '../../components/index';
import { MatGridListModule } from '@angular/material/grid-list';
import { SimpoButtonComponent } from '../../elements/simpo-button/simpo-button.component';
import { AnimationDirective } from '../../directive/animation-directive';
import { BackgroundDirective } from '../../directive/background-directive';
import { ContentFitDirective } from '../../directive/content-fit-directive';
import { BannerContentFitDirective } from '../../directive/banner-content-fit-directive';
import { BorderDirective } from '../../directive/border-directive';
import { ButtonDirectiveDirective } from '../../directive/button-directive.directive';
import { ColumnDirectiveDirective } from '../../directive/column-directive.directive';
import { ContainerFitDirective } from '../../directive/container-fir.directive';
import { simpoConetenAlignmentDirective } from '../../directive/content-alignment-directive';
import { CornerDirective } from '../../directive/corner-directive';
import { SimpoFooterLayoutDirective } from '../../directive/footer-layout-directive';
import { HoverDirective } from '../../directive/hover-element-directive';
import { ImageDirectiveDirective } from '../../directive/image-directive.directive';
import { OverlayDirective } from '../../directive/overlay-directive';
import { PositionLayoutDirectiveDirective } from '../../directive/position-layout-directive.directive';
import { TextBackgroundDirectiveDirective } from '../../directive/text-background-directive.directive';
import { ObjectPositionDirective } from './../../directive/image-position.directive';
import BaseSection from '../BaseSection';
import { SimpoContainerAligment } from '../../directive/container-alignment.directive';
import { ColorDirective } from './../../directive/color.directive';
import { TextSizeDirective } from '../../directive/text-size.directive';
import { SanitizeHtmlPipe } from '../../services/sanitizeHtml';
import { TextEditorComponent } from '../../elements/text-editor/text-editor.component';
import { ImageEditorDirective } from '../../directive/image-editor.directive';
import { SpacingHorizontalDirective } from '../../directive/spacing-horizontal.directive';
import * as i0 from "@angular/core";
import * as i1 from "./../../services/events.service";
import * as i2 from "../../elements/svg-divider/svg-divider.component";
import * as i3 from "@angular/common";
import * as i4 from "../../components/hover-elements/hover-elements.component";
import * as i5 from "../../components/delete-hover-element/delete-hover-element.component";
export class ProcessModernComponent extends BaseSection {
    constructor(_eventService) {
        super();
        this._eventService = _eventService;
        this.scrWidth = 0;
        this.getScreenSize();
    }
    getScreenSize() {
        this.scrWidth = window.innerWidth;
    }
    ngOnInit() {
        this.content = this.data?.content;
        this.styles = this.data?.styles;
        this.deleteSelected = this.delete;
        if (!this.styles || !this.content)
            return;
        // this.styles.layout.bannerImageDisplay = this.content.image.showImage;
    }
    get stylesLayout() {
        return { ...this.styles?.layout };
    }
    get getJustifyContent() {
        return "justify-content: center !important;";
    }
    editSection() {
        if (window.innerWidth <= 475)
            return;
        this._eventService.toggleEditorEvent.emit(false);
        setTimeout(() => {
            this._eventService.editSection.emit({ data: this.data });
        }, 100);
    }
    static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: ProcessModernComponent, deps: [{ token: i1.EventsService }], target: i0.ɵɵFactoryTarget.Component }); }
    static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.13", type: ProcessModernComponent, isStandalone: true, selector: "simpo-process-modern", inputs: { data: "data", index: "index", edit: "edit", delete: "delete", customClass: "customClass", nextComponentColor: "nextComponentColor" }, host: { listeners: { "window: resize": "getScreenSize($event)" } }, usesInheritance: true, ngImport: i0, template: "<div [id]=\"data?.id\" simpoHover (hovering)=\"showEditTabs($event)\" class=\"total-container\" [attr.style]=\"customClass\">\r\n  <div class=\"col-xxl-8 w-100\" [id]=\"data?.id\" [simpoBorder]=\"styles?.border\"\r\n    [simpoBackground]=\"styles?.background\" style=\"overflow-x: hidden;\">\r\n    <div class=\"row\" [id]=\"data?.id\">\r\n      <div  [id]=\"data?.id\" [simpoOverlay]=\"styles?.background\" [spacingHorizontal]=\"stylesLayout\"\r\n         [simpoLayout]=\"styles?.layout\">\r\n        <div class=\"container-fluid d-flex flex-column content-side\" [id]=\"data?.id\"\r\n          [simpoAnimation]=\"styles?.animation\">\r\n          <div class=\"row w-100\" [id]=\"data?.id\">\r\n            <div *ngFor=\"let text of data?.content?.inputText; let i = index\">\r\n              <simpo-text-editor [(value)]=\"text.value\" [editable]=\"edit || false\" [sectionId]=\"data?.id\" [inputTextIndex]=\"i\" [isRTE]=\"text.isRTE\"></simpo-text-editor>\r\n\r\n            </div>\r\n          </div>\r\n          <div *ngFor=\"let item of content?.listItem?.data ;let i = index\"\r\n            class=\"single_card content-side d-flex justify-content-center\">\r\n            <div class=\"rowFlexContainer w-100\" [ngClass]=\"{'flex-row-reverse': i % 2 === 1}\">\r\n              <div class=\"imageContainer\" [ngClass]=\"{'no-image': item.image.url===''}\">\r\n                <div *ngIf=\"scrWidth <= 500\" class=\"numberStyle\">\r\n                  {{ i + 1}}\r\n                </div>\r\n                <img loading=\"lazy\"  class=\"section_image\" [src]=\"item.image.url\" [alt]=\"item.image.altText\"\r\n                  [simpoImageDirective]=\"styles?.image\" [id]=\"data?.id\" [simpoCorner]=\"styles?.corners\"\r\n                  loading=\"lazy\"   [appImageEditor]=\"edit || false\" [imageData]=\"item?.image\" [sectionId]=\"data?.id\" [itemIndex]=\"i\" [class]=\"data?.id+(item?.image?.id || '')\" [simpoObjectPosition]=\"item?.image?.position\">\r\n              </div>\r\n              <div class=\"content\" [ngClass]=\"{'no-image-content': item.image.url===''}\">\r\n                <div *ngIf=\"scrWidth > 500\" class=\"numberStyle\">\r\n                  {{ i + 1}}\r\n                </div>\r\n                <simpo-text-editor [(value)]=\"item.inputText[0].value\" [editable]=\"edit || false\" [sectionId]=\"data?.id\" [inputTextIndex]=\"0\" [itemIndex]=\"i\" [isRTE]=\"item.inputText[0]?.isRTE\"></simpo-text-editor>\r\n                <simpo-text-editor [(value)]=\"item.inputText[1].value\" [editable]=\"edit || false\" [sectionId]=\"data?.id\" [inputTextIndex]=\"1\" [itemIndex]=\"i\" [isRTE]=\"item.inputText[1]?.isRTE\"></simpo-text-editor>\r\n              </div>\r\n            </div>\r\n          </div>\r\n        </div>\r\n      </div>\r\n    </div>\r\n  </div>\r\n\r\n  <ng-container *ngIf=\"styles?.devider?.display\">\r\n    <simpo-svg-divider [dividerType]=\"styles?.devider?.deviderType\"\r\n      [color]=\"nextComponentColor?.color\"></simpo-svg-divider>\r\n  </ng-container>\r\n  <div [ngClass]=\"{'hover_effect': edit}\" *ngIf=\"showEditors\">\r\n    <simpo-hover-elements [data]=\"data\" [index]=\"index\" [editOptions]=\"edit\"></simpo-hover-elements>\r\n  </div>\r\n  <div *ngIf=\"showDelete\" [ngClass]=\"{'hover_effect': delete}\">\r\n    <simpo-delete-hover-element [data]=\"data\" [index]=\"index\"></simpo-delete-hover-element>\r\n  </div>\r\n</div>", styles: [".single_card{width:100%}.rowFlexContainer{display:flex;flex-direction:row;margin:3% 0 0;justify-content:space-between!important}.flex-row-reverse{flex-direction:row-reverse}.imageContainer{width:40%!important;height:250px;line-height:30px}.section_image{width:100%;height:100%;object-fit:cover;border-radius:10px}.img{vertical-align:middle}.content{width:55%!important;height:100%;display:flex;flex-direction:column;justify-content:flex-start;font-size:18px}.numberStyle{height:50px;padding:10px!important;border-radius:50%;border:1px solid black;width:50px!important;display:flex;align-items:center;justify-content:center}.contentHeading{margin-bottom:0;margin-top:20px;font-size:24px;font-weight:400}.contentDescription{padding-top:10px;line-height:28px;width:90%!important;text-overflow:ellipsis;overflow:hidden;font-size:18px;font-weight:400}.hover_effect{position:unset;width:100%;top:0;left:0;height:100%}.total-container{position:relative;height:auto}.no-image{display:none}.no-image-content{width:40%!important;margin-left:auto;margin-right:auto}.no-image-content .contentDescription{width:100%!important}@media only screen and (max-width: 475px){.rowFlexContainer{flex-direction:column!important;width:100%!important;height:auto!important}.imageContainer{width:100%!important;height:auto!important}.section_image{width:100%;height:auto;object-fit:cover;border-radius:10px}.content{width:100%!important;margin-top:15px;margin-right:0}.numberStyle{margin-bottom:15px;width:50px;height:50px}.contentDescription{width:100%!important}.row{margin-left:.2px}}\n"], dependencies: [{ kind: "ngmodule", type: SimpoElementsModule }, { kind: "component", type: i2.SvgDividerComponent, selector: "simpo-svg-divider", inputs: ["dividerType", "color"] }, { kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i3.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i3.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i3.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "ngmodule", type: SimpoComponentModule }, { kind: "component", type: i4.HoverElementsComponent, selector: "simpo-hover-elements", inputs: ["data", "index", "editOptions", "isMerged", "isEcommerce"], outputs: ["edit"] }, { kind: "component", type: i5.DeleteHoverElementComponent, selector: "simpo-delete-hover-element", inputs: ["index", "data"], outputs: ["edit"] }, { kind: "ngmodule", type: MatGridListModule }, { kind: "component", type: TextEditorComponent, selector: "simpo-text-editor", inputs: ["value", "editable", "isRTE", "sectionId", "label", "type", "inputTextIndex", "itemIndex"], outputs: ["valueChange"] }, { kind: "directive", type: AnimationDirective, selector: "[simpoAnimation]", inputs: ["simpoAnimation"] }, { kind: "directive", type: BackgroundDirective, selector: "[simpoBackground]", inputs: ["simpoBackground", "scrollValue"] }, { kind: "directive", type: BorderDirective, selector: "[simpoBorder]", inputs: ["simpoBorder"] }, { kind: "directive", type: ContentFitDirective, selector: "[simpoLayout]", inputs: ["simpoLayout"] }, { kind: "directive", type: CornerDirective, selector: "[simpoCorner]", inputs: ["simpoCorner"] }, { kind: "directive", type: HoverDirective, selector: "[simpoHover]", outputs: ["hovering"] }, { kind: "directive", type: ImageDirectiveDirective, selector: "[simpoImageDirective]", inputs: ["simpoImageDirective"] }, { kind: "directive", type: OverlayDirective, selector: "[simpoOverlay]", inputs: ["simpoOverlay"] }, { kind: "directive", type: ObjectPositionDirective, selector: "[simpoObjectPosition]", inputs: ["simpoObjectPosition"] }, { kind: "directive", type: ImageEditorDirective, selector: "[appImageEditor]", inputs: ["appImageEditor", "imageData", "sectionId", "showIcon", "iconData", "itemIndex"] }, { kind: "directive", type: SpacingHorizontalDirective, selector: "[spacingHorizontal]", inputs: ["spacingHorizontal", "isHeader"] }] }); }
}
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: ProcessModernComponent, decorators: [{
            type: Component,
            args: [{ selector: 'simpo-process-modern', standalone: true, imports: [
                        SimpoElementsModule,
                        CommonModule,
                        SimpoComponentModule,
                        MatGridListModule,
                        SimpoButtonComponent,
                        TextEditorComponent,
                        //directive
                        SimpoContainerAligment,
                        AnimationDirective,
                        BackgroundDirective,
                        BannerContentFitDirective,
                        BorderDirective,
                        ButtonDirectiveDirective,
                        ColumnDirectiveDirective,
                        ContainerFitDirective,
                        simpoConetenAlignmentDirective,
                        ContentFitDirective,
                        CornerDirective,
                        SimpoFooterLayoutDirective,
                        HoverDirective,
                        ImageDirectiveDirective,
                        OverlayDirective,
                        PositionLayoutDirectiveDirective,
                        TextBackgroundDirectiveDirective,
                        ObjectPositionDirective,
                        ColorDirective,
                        TextSizeDirective,
                        SanitizeHtmlPipe,
                        ImageEditorDirective,
                        ObjectPositionDirective,
                        SpacingHorizontalDirective
                    ], template: "<div [id]=\"data?.id\" simpoHover (hovering)=\"showEditTabs($event)\" class=\"total-container\" [attr.style]=\"customClass\">\r\n  <div class=\"col-xxl-8 w-100\" [id]=\"data?.id\" [simpoBorder]=\"styles?.border\"\r\n    [simpoBackground]=\"styles?.background\" style=\"overflow-x: hidden;\">\r\n    <div class=\"row\" [id]=\"data?.id\">\r\n      <div  [id]=\"data?.id\" [simpoOverlay]=\"styles?.background\" [spacingHorizontal]=\"stylesLayout\"\r\n         [simpoLayout]=\"styles?.layout\">\r\n        <div class=\"container-fluid d-flex flex-column content-side\" [id]=\"data?.id\"\r\n          [simpoAnimation]=\"styles?.animation\">\r\n          <div class=\"row w-100\" [id]=\"data?.id\">\r\n            <div *ngFor=\"let text of data?.content?.inputText; let i = index\">\r\n              <simpo-text-editor [(value)]=\"text.value\" [editable]=\"edit || false\" [sectionId]=\"data?.id\" [inputTextIndex]=\"i\" [isRTE]=\"text.isRTE\"></simpo-text-editor>\r\n\r\n            </div>\r\n          </div>\r\n          <div *ngFor=\"let item of content?.listItem?.data ;let i = index\"\r\n            class=\"single_card content-side d-flex justify-content-center\">\r\n            <div class=\"rowFlexContainer w-100\" [ngClass]=\"{'flex-row-reverse': i % 2 === 1}\">\r\n              <div class=\"imageContainer\" [ngClass]=\"{'no-image': item.image.url===''}\">\r\n                <div *ngIf=\"scrWidth <= 500\" class=\"numberStyle\">\r\n                  {{ i + 1}}\r\n                </div>\r\n                <img loading=\"lazy\"  class=\"section_image\" [src]=\"item.image.url\" [alt]=\"item.image.altText\"\r\n                  [simpoImageDirective]=\"styles?.image\" [id]=\"data?.id\" [simpoCorner]=\"styles?.corners\"\r\n                  loading=\"lazy\"   [appImageEditor]=\"edit || false\" [imageData]=\"item?.image\" [sectionId]=\"data?.id\" [itemIndex]=\"i\" [class]=\"data?.id+(item?.image?.id || '')\" [simpoObjectPosition]=\"item?.image?.position\">\r\n              </div>\r\n              <div class=\"content\" [ngClass]=\"{'no-image-content': item.image.url===''}\">\r\n                <div *ngIf=\"scrWidth > 500\" class=\"numberStyle\">\r\n                  {{ i + 1}}\r\n                </div>\r\n                <simpo-text-editor [(value)]=\"item.inputText[0].value\" [editable]=\"edit || false\" [sectionId]=\"data?.id\" [inputTextIndex]=\"0\" [itemIndex]=\"i\" [isRTE]=\"item.inputText[0]?.isRTE\"></simpo-text-editor>\r\n                <simpo-text-editor [(value)]=\"item.inputText[1].value\" [editable]=\"edit || false\" [sectionId]=\"data?.id\" [inputTextIndex]=\"1\" [itemIndex]=\"i\" [isRTE]=\"item.inputText[1]?.isRTE\"></simpo-text-editor>\r\n              </div>\r\n            </div>\r\n          </div>\r\n        </div>\r\n      </div>\r\n    </div>\r\n  </div>\r\n\r\n  <ng-container *ngIf=\"styles?.devider?.display\">\r\n    <simpo-svg-divider [dividerType]=\"styles?.devider?.deviderType\"\r\n      [color]=\"nextComponentColor?.color\"></simpo-svg-divider>\r\n  </ng-container>\r\n  <div [ngClass]=\"{'hover_effect': edit}\" *ngIf=\"showEditors\">\r\n    <simpo-hover-elements [data]=\"data\" [index]=\"index\" [editOptions]=\"edit\"></simpo-hover-elements>\r\n  </div>\r\n  <div *ngIf=\"showDelete\" [ngClass]=\"{'hover_effect': delete}\">\r\n    <simpo-delete-hover-element [data]=\"data\" [index]=\"index\"></simpo-delete-hover-element>\r\n  </div>\r\n</div>", styles: [".single_card{width:100%}.rowFlexContainer{display:flex;flex-direction:row;margin:3% 0 0;justify-content:space-between!important}.flex-row-reverse{flex-direction:row-reverse}.imageContainer{width:40%!important;height:250px;line-height:30px}.section_image{width:100%;height:100%;object-fit:cover;border-radius:10px}.img{vertical-align:middle}.content{width:55%!important;height:100%;display:flex;flex-direction:column;justify-content:flex-start;font-size:18px}.numberStyle{height:50px;padding:10px!important;border-radius:50%;border:1px solid black;width:50px!important;display:flex;align-items:center;justify-content:center}.contentHeading{margin-bottom:0;margin-top:20px;font-size:24px;font-weight:400}.contentDescription{padding-top:10px;line-height:28px;width:90%!important;text-overflow:ellipsis;overflow:hidden;font-size:18px;font-weight:400}.hover_effect{position:unset;width:100%;top:0;left:0;height:100%}.total-container{position:relative;height:auto}.no-image{display:none}.no-image-content{width:40%!important;margin-left:auto;margin-right:auto}.no-image-content .contentDescription{width:100%!important}@media only screen and (max-width: 475px){.rowFlexContainer{flex-direction:column!important;width:100%!important;height:auto!important}.imageContainer{width:100%!important;height:auto!important}.section_image{width:100%;height:auto;object-fit:cover;border-radius:10px}.content{width:100%!important;margin-top:15px;margin-right:0}.numberStyle{margin-bottom:15px;width:50px;height:50px}.contentDescription{width:100%!important}.row{margin-left:.2px}}\n"] }]
        }], ctorParameters: () => [{ type: i1.EventsService }], propDecorators: { data: [{
                type: Input
            }], index: [{
                type: Input
            }], edit: [{
                type: Input
            }], delete: [{
                type: Input
            }], customClass: [{
                type: Input
            }], nextComponentColor: [{
                type: Input
            }], getScreenSize: [{
                type: HostListener,
                args: ["window: resize", ["$event"]]
            }] } });
//# sourceMappingURL=data:application/json;base64, 