@extends('layouts.site') @section('meta_title') {{ __('site.nav_contact') }} — {{ brand_name() }} @endsection @section('title', __('site.nav_contact')) @section('content') @php $locale = app()->getLocale(); $cu = $contactUs; $cfg = is_array($contactConfig ?? null) ? $contactConfig : \App\Support\SiteSettings::contactConfig(); $heroChips = brand_contact_hero_chips(); $trustItems = is_array($cfg['trust'] ?? null) ? $cfg['trust'] : []; $hours = is_array($cfg['hours'] ?? null) ? $cfg['hours'] : []; $checklist = is_array($cfg['repair_checklist'] ?? null) ? $cfg['repair_checklist'] : []; $mapUrl = filled($cfg['map_url'] ?? null) ? (string) $cfg['map_url'] : null; $specialties = is_array($specialties ?? null) ? $specialties : []; $checklistTitle = brand_trans(site_profile()->labelKey('contact_checklist_title') ?? 'site.contact_repair_title'); $checklistSub = brand_trans(site_profile()->labelKey('contact_checklist_sub') ?? 'site.contact_repair_sub'); $checklistCta = site_profile()->cta('primary'); $phone = $cu?->mobile ?: $cu?->cellphone; $phoneAlt = ($cu?->cellphone && $cu->cellphone !== $cu->mobile) ? $cu->cellphone : null; $email = $cu?->email; $whatsappHref = site_whatsapp_url(); if ($cu?->whatsapp) { $digits = preg_replace('/\D+/', '', (string) $cu->whatsapp); if ($digits !== '') { $whatsappHref = 'https://wa.me/'.$digits; } } $address = $cu ? locale_field($cu, 'address') : null; $brand = $cu ? locale_field($cu, 'name') : brand_name(); $intro = $cu ? \Illuminate\Support\Str::limit((string) (locale_field($cu, 'text') ?: locale_field($cu, 'subject') ?: ''), 420) : ''; $heroTitle = $cu ? trim((string) (locale_field($cu, 'subject') ?: '')) : ''; $heroSubRaw = $cu ? trim((string) (locale_field($cu, 'text') ?: '')) : ''; $heroSub = $heroSubRaw !== '' ? \Illuminate\Support\Str::of($heroSubRaw) ->replaceMatches('/[#*_`>-]+/u', ' ') ->replace("\r\n", ' ') ->replace("\n", ' ') ->squish() ->limit(220) ->toString() : ''; $heroImage = $cu?->heroImageUrl(); @endphp
{{ $heroSub !== '' ? $heroSub : brand_trans('site.contact_hero_sub') }}
{{ $tValue }}
{{ $tLabel }}
{{ $checklistSub }}
{{ __('site.empty_contact') }}
@feature('repair_services') @endfeature{{ $brand }}
@endif @if ($intro !== ''){{ $intro }}
@else{{ brand_trans('site.contact_hero_sub') }}
@endif @feature('repair_services') @endfeature{{ __('site.contact_specialties_sub') }}
{{ __('site.contact_dock_title') }}
{{ brand_trans('site.contact_dock_sub') }}