import { Component, Input, } from '@angular/core';
import { CommonModule } from '@angular/common';
import { SimpoElementsModule } from '../../elements/index';
import { SimpoComponentModule } from '../../components/index';
import { TextEditorComponent } from '../../elements/text-editor/text-editor.component';
import { BackgroundDirective } from '../../directive/background-directive';
import { HoverDirective } from '../../directive/hover-element-directive';
import { OverlayDirective } from '../../directive/overlay-directive';
import { SpacingHorizontalDirective } from '../../directive/spacing-horizontal.directive';
import { ContentFitDirective } from '../../directive/content-fit-directive';
import { AnimationDirective } from '../../directive/animation-directive';
import BaseSection from '../BaseSection';
import * as i0 from "@angular/core";
import * as i1 from "@angular/common";
import * as i2 from "../../elements/simpo-button/simpo-button.component";
import * as i3 from "../../elements/svg-divider/svg-divider.component";
import * as i4 from "../../components/hover-elements/hover-elements.component";
import * as i5 from "../../components/delete-hover-element/delete-hover-element.component";
export class ButtonGridSectionComponent extends BaseSection {
    ngOnInit() {
        this.content = this.data?.content || {};
        this.style = this.data?.styles || {};
    }
    get stylesLayout() {
        return { ...this.style?.layout };
    }
    static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: ButtonGridSectionComponent, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
    static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.13", type: ButtonGridSectionComponent, isStandalone: true, selector: "simpo-button-grid-section", inputs: { edit: "edit", data: "data", customClass: "customClass", nextComponentColor: "nextComponentColor", index: "index", delete: "delete" }, usesInheritance: true, ngImport: i0, template: "<section>\r\n  <div [id]=\"data?.id\" simpoHover (hovering)=\"showEditTabs($event)\" class=\"button-grid-wrapper total-container\"\r\n    [attr.style]=\"customClass\" [simpoBackground]=\"style?.background\">\r\n    <div #mainContainer [id]=\"data?.id\" [spacingHorizontal]=\"stylesLayout\" [simpoLayout]=\"style?.layout\"\r\n      class=\"button-grid-container d-flex flex-column\" [simpoOverlay]=\"style?.background\"\r\n      [simpoAnimation]=\"style?.animation\">\r\n\r\n      <div class=\"heading-section\" *ngIf=\"content?.inputText?.length\">\r\n        <div class=\"main-heading\" *ngIf=\"content?.inputText?.[0]\">\r\n          <simpo-text-editor [(value)]=\"content.inputText[0].value\" [editable]=\"edit || false\" [sectionId]=\"data?.id\" [inputTextIndex]=\"0\" [isRTE]=\"content?.inputText[0]?.isRTE\"></simpo-text-editor>\r\n        </div>\r\n\r\n        <div class=\"sub-heading\" *ngIf=\"content?.inputText?.[1] && (content.inputText[1].value || edit)\">\r\n          <simpo-text-editor [(value)]=\"content.inputText[1].value\" [editable]=\"edit || false\" [sectionId]=\"data?.id\" [inputTextIndex]=\"1\" [isRTE]=\"content?.inputText[1]?.isRTE\"></simpo-text-editor>\r\n        </div>\r\n      </div>\r\n\r\n      <div class=\"buttons-scroll-wrapper w-100\">\r\n        <div class=\"buttons-grid\">\r\n          <div class=\"grid-button\" *ngFor=\"let item of data.action.buttons; let i = index\">\r\n            <app-button-element [buttonContent]=\"item.content\" [buttonStyle]=\"item.styles\" [buttonId]=\"item?.id\"\r\n              [sectionId]=\"data?.id\" [color]=\"data?.styles?.background?.accentColor\" [edit]=\"edit\"\r\n              [backgroundInfo]=\"data?.styles?.background\">\r\n            </app-button-element>\r\n          </div>\r\n        </div>\r\n      </div>\r\n    </div>\r\n\r\n    <ng-container *ngIf=\"style?.devider?.display\">\r\n      <simpo-svg-divider [dividerType]=\"style?.devider?.deviderType\"\r\n        [color]=\"nextComponentColor?.color\"></simpo-svg-divider>\r\n    </ng-container>\r\n\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\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>\r\n</section>", styles: [".button-grid-wrapper{width:100%}.total-container{height:auto;position:relative}.button-grid-container{width:100%;padding:50px 40px 35px}.heading-section{text-align:center;margin-bottom:34px;flex-shrink:0}.main-heading{font-size:42px;font-weight:600;line-height:1.2;color:#0a4f9f;margin-bottom:12px}.sub-heading{font-size:16px;line-height:1.6;color:#555;max-width:900px;margin:0 auto}.buttons-scroll-wrapper{max-height:370px;overflow-y:auto;overflow-x:hidden;padding-right:8px}.buttons-scroll-wrapper::-webkit-scrollbar{width:8px}.buttons-scroll-wrapper::-webkit-scrollbar-track{background:transparent}.buttons-scroll-wrapper::-webkit-scrollbar-thumb{background:#0003;border-radius:20px}.buttons-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:32px 36px;padding:5px 0}.grid-button{width:100%;min-width:0;display:flex}.grid-button app-button-element{display:block;width:100%;flex:1}.grid-button ::ng-deep app-button-element>*{width:100%}.grid-button ::ng-deep button,.grid-button ::ng-deep .simpo-btn,.grid-button ::ng-deep a{width:100%!important;min-height:60px;display:flex!important;align-items:center;justify-content:center;text-align:center;font-size:18px;font-weight:600;letter-spacing:.4px;padding:18px 16px!important;line-height:1.4;height:auto;white-space:normal;word-break:break-word;overflow-wrap:anywhere}@media (min-width: 1200px){.button-grid-container{padding:55px 52px 40px}.main-heading{font-size:46px}.buttons-scroll-wrapper{max-height:370px}}@media (min-width: 768px) and (max-width: 1024px){.button-grid-container{padding:38px 26px 30px}.main-heading{font-size:34px}.sub-heading{font-size:15px}.buttons-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:18px 20px}.buttons-scroll-wrapper{max-height:420px}.grid-button ::ng-deep button,.grid-button ::ng-deep .simpo-btn,.grid-button ::ng-deep a{min-height:68px;font-size:16px}}@media (max-width: 767px){.button-grid-container{padding:28px 16px 24px}.heading-section{margin-bottom:22px}.main-heading{font-size:28px;margin-bottom:8px}.sub-heading{font-size:14px}.buttons-grid{grid-template-columns:repeat(1,minmax(0,1fr));gap:14px}.buttons-scroll-wrapper{max-height:360px;padding-right:4px}.grid-button ::ng-deep button,.grid-button ::ng-deep .simpo-btn,.grid-button ::ng-deep a{min-height:58px;font-size:14px;padding:14px 12px!important}}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "ngmodule", type: SimpoElementsModule }, { kind: "component", type: i2.SimpoButtonComponent, selector: "app-button-element", inputs: ["buttonContent", "buttonStyle", "buttonId", "color", "sectionId", "edit", "backgroundInfo", "disabled", "loading", "isFullWidth"] }, { kind: "component", type: i3.SvgDividerComponent, selector: "simpo-svg-divider", inputs: ["dividerType", "color"] }, { 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: "component", type: TextEditorComponent, selector: "simpo-text-editor", inputs: ["value", "editable", "isRTE", "sectionId", "label", "type", "inputTextIndex", "itemIndex"], outputs: ["valueChange"] }, { kind: "directive", type: BackgroundDirective, selector: "[simpoBackground]", inputs: ["simpoBackground", "scrollValue"] }, { kind: "directive", type: HoverDirective, selector: "[simpoHover]", outputs: ["hovering"] }, { kind: "directive", type: OverlayDirective, selector: "[simpoOverlay]", inputs: ["simpoOverlay"] }, { kind: "directive", type: SpacingHorizontalDirective, selector: "[spacingHorizontal]", inputs: ["spacingHorizontal", "isHeader"] }, { kind: "directive", type: AnimationDirective, selector: "[simpoAnimation]", inputs: ["simpoAnimation"] }, { kind: "directive", type: ContentFitDirective, selector: "[simpoLayout]", inputs: ["simpoLayout"] }] }); }
}
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: ButtonGridSectionComponent, decorators: [{
            type: Component,
            args: [{ selector: 'simpo-button-grid-section', standalone: true, imports: [
                        CommonModule,
                        SimpoElementsModule,
                        SimpoComponentModule,
                        TextEditorComponent,
                        BackgroundDirective,
                        HoverDirective,
                        OverlayDirective,
                        SpacingHorizontalDirective,
                        AnimationDirective,
                        ContentFitDirective
                    ], template: "<section>\r\n  <div [id]=\"data?.id\" simpoHover (hovering)=\"showEditTabs($event)\" class=\"button-grid-wrapper total-container\"\r\n    [attr.style]=\"customClass\" [simpoBackground]=\"style?.background\">\r\n    <div #mainContainer [id]=\"data?.id\" [spacingHorizontal]=\"stylesLayout\" [simpoLayout]=\"style?.layout\"\r\n      class=\"button-grid-container d-flex flex-column\" [simpoOverlay]=\"style?.background\"\r\n      [simpoAnimation]=\"style?.animation\">\r\n\r\n      <div class=\"heading-section\" *ngIf=\"content?.inputText?.length\">\r\n        <div class=\"main-heading\" *ngIf=\"content?.inputText?.[0]\">\r\n          <simpo-text-editor [(value)]=\"content.inputText[0].value\" [editable]=\"edit || false\" [sectionId]=\"data?.id\" [inputTextIndex]=\"0\" [isRTE]=\"content?.inputText[0]?.isRTE\"></simpo-text-editor>\r\n        </div>\r\n\r\n        <div class=\"sub-heading\" *ngIf=\"content?.inputText?.[1] && (content.inputText[1].value || edit)\">\r\n          <simpo-text-editor [(value)]=\"content.inputText[1].value\" [editable]=\"edit || false\" [sectionId]=\"data?.id\" [inputTextIndex]=\"1\" [isRTE]=\"content?.inputText[1]?.isRTE\"></simpo-text-editor>\r\n        </div>\r\n      </div>\r\n\r\n      <div class=\"buttons-scroll-wrapper w-100\">\r\n        <div class=\"buttons-grid\">\r\n          <div class=\"grid-button\" *ngFor=\"let item of data.action.buttons; let i = index\">\r\n            <app-button-element [buttonContent]=\"item.content\" [buttonStyle]=\"item.styles\" [buttonId]=\"item?.id\"\r\n              [sectionId]=\"data?.id\" [color]=\"data?.styles?.background?.accentColor\" [edit]=\"edit\"\r\n              [backgroundInfo]=\"data?.styles?.background\">\r\n            </app-button-element>\r\n          </div>\r\n        </div>\r\n      </div>\r\n    </div>\r\n\r\n    <ng-container *ngIf=\"style?.devider?.display\">\r\n      <simpo-svg-divider [dividerType]=\"style?.devider?.deviderType\"\r\n        [color]=\"nextComponentColor?.color\"></simpo-svg-divider>\r\n    </ng-container>\r\n\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\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>\r\n</section>", styles: [".button-grid-wrapper{width:100%}.total-container{height:auto;position:relative}.button-grid-container{width:100%;padding:50px 40px 35px}.heading-section{text-align:center;margin-bottom:34px;flex-shrink:0}.main-heading{font-size:42px;font-weight:600;line-height:1.2;color:#0a4f9f;margin-bottom:12px}.sub-heading{font-size:16px;line-height:1.6;color:#555;max-width:900px;margin:0 auto}.buttons-scroll-wrapper{max-height:370px;overflow-y:auto;overflow-x:hidden;padding-right:8px}.buttons-scroll-wrapper::-webkit-scrollbar{width:8px}.buttons-scroll-wrapper::-webkit-scrollbar-track{background:transparent}.buttons-scroll-wrapper::-webkit-scrollbar-thumb{background:#0003;border-radius:20px}.buttons-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:32px 36px;padding:5px 0}.grid-button{width:100%;min-width:0;display:flex}.grid-button app-button-element{display:block;width:100%;flex:1}.grid-button ::ng-deep app-button-element>*{width:100%}.grid-button ::ng-deep button,.grid-button ::ng-deep .simpo-btn,.grid-button ::ng-deep a{width:100%!important;min-height:60px;display:flex!important;align-items:center;justify-content:center;text-align:center;font-size:18px;font-weight:600;letter-spacing:.4px;padding:18px 16px!important;line-height:1.4;height:auto;white-space:normal;word-break:break-word;overflow-wrap:anywhere}@media (min-width: 1200px){.button-grid-container{padding:55px 52px 40px}.main-heading{font-size:46px}.buttons-scroll-wrapper{max-height:370px}}@media (min-width: 768px) and (max-width: 1024px){.button-grid-container{padding:38px 26px 30px}.main-heading{font-size:34px}.sub-heading{font-size:15px}.buttons-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:18px 20px}.buttons-scroll-wrapper{max-height:420px}.grid-button ::ng-deep button,.grid-button ::ng-deep .simpo-btn,.grid-button ::ng-deep a{min-height:68px;font-size:16px}}@media (max-width: 767px){.button-grid-container{padding:28px 16px 24px}.heading-section{margin-bottom:22px}.main-heading{font-size:28px;margin-bottom:8px}.sub-heading{font-size:14px}.buttons-grid{grid-template-columns:repeat(1,minmax(0,1fr));gap:14px}.buttons-scroll-wrapper{max-height:360px;padding-right:4px}.grid-button ::ng-deep button,.grid-button ::ng-deep .simpo-btn,.grid-button ::ng-deep a{min-height:58px;font-size:14px;padding:14px 12px!important}}\n"] }]
        }], propDecorators: { edit: [{
                type: Input
            }], data: [{
                type: Input
            }], customClass: [{
                type: Input
            }], nextComponentColor: [{
                type: Input
            }], index: [{
                type: Input
            }], delete: [{
                type: Input
            }] } });
//# sourceMappingURL=data:application/json;base64, 