@php $imagePosition = $content['image_position'] ?? 'left'; $btnLink = $content['link']['value'] ?? 'javascript:void(0)'; $btnLinkType = $content['link']['type'] ?? 'custom'; $btnNewWindow = $content['link']['new_window'] ?? false; $target = $btnNewWindow ? '_blank' : '_self'; $textAlign = $content['text_align'] ?? 'left'; $titleSpacing = $content['title_spacing'] ?? 20; $subtitleSpacing = $content['subtitle_spacing'] ?? 15; $descriptionSpacing = $content['description_spacing'] ?? 20; $contentMarginLeft = $content['content_margin_left'] ?? 0; $contentMarginRight = $content['content_margin_right'] ?? 0; $contentMarginTop = $content['content_margin_top'] ?? 0; $contentMarginBottom = $content['content_margin_bottom'] ?? 0; $imagePaddingX = $content['image_padding_x'] ?? 0; $imagePaddingY = $content['image_padding_y'] ?? 0; $hasImage = !empty($content['image']); // Handle link based on type if ($btnLinkType !== 'custom' && $btnLink) { $btnLink = '/' . $btnLinkType . '/' . $btnLink; } @endphp @if($hasImage || request('design'))
@if($hasImage)
@if ($imagePosition === 'left')
@if (!empty($content['title']))
{{ $content['title'] }}
@endif @if (!empty($content['subtitle']))
{{ $content['subtitle'] }}
@endif @if (!empty($content['description']))
{{ $content['description'] }}
@endif @if (!empty($content['button_text'])) @endif
@else
@if (!empty($content['title']))
{{ $content['title'] }}
@endif @if (!empty($content['subtitle']))
{{ $content['subtitle'] }}
@endif @if (!empty($content['description']))
{{ $content['description'] }}
@endif @if (!empty($content['button_text'])) @endif
@endif
@elseif(request('design')) @include('PageBuilder::front.partials.module-title', [ 'title' => $content['title'] ?? '', 'subtitle' => $content['subtitle'] ?? '', ]) @include('PageBuilder::front.partials.module-empty', [ 'moduleClass' => 'left-image-right-text', 'icon' => 'bi-image', 'message' => __('PageBuilder::modules.no_image'), ]) @endif
@endif