@extends('admin.layout')
@section('title', 'Contact & Social')
@php
/**
* Font Awesome icon classes for social platforms.
*/
$socialIconMap = [
'facebook' => 'fa-brands fa-facebook-f',
'instagram' => 'fa-brands fa-instagram',
'whatsapp' => 'fa-brands fa-whatsapp',
'tiktok' => 'fa-brands fa-tiktok',
'twitter_x' => 'fa-brands fa-x-twitter',
'linkedin' => 'fa-brands fa-linkedin-in',
'youtube' => 'fa-brands fa-youtube',
'snapchat' => 'fa-brands fa-snapchat',
'telegram' => 'fa-brands fa-telegram',
'pinterest' => 'fa-brands fa-pinterest-p',
'github' => 'fa-brands fa-github',
'gitlab' => 'fa-brands fa-gitlab',
'dribbble' => 'fa-brands fa-dribbble',
'behance' => 'fa-brands fa-behance',
'custom' => 'fa-solid fa-link',
];
/**
* Font Awesome icon classes for contact items.
* Keep your existing contactIconOptions keys; just add icon class for each one.
*/
$contactFaIconMap = [
'email' => 'fa-solid fa-envelope',
'phone' => 'fa-solid fa-phone',
'mobile' => 'fa-solid fa-mobile-screen-button',
'whatsapp' => 'fa-brands fa-whatsapp',
'location' => 'fa-solid fa-location-dot',
'website' => 'fa-solid fa-globe',
'hours' => 'fa-regular fa-clock',
'fax' => 'fa-solid fa-fax',
'custom' => 'fa-solid fa-circle-question',
];
@endphp
@push('styles')
@endpush
@section('body')
{{-- Contact Section Text --}}
{{-- Contact Items --}}
{{-- Social Links --}}
| Platform |
Link / Number |
Type |
Status |
Actions |
@forelse($socials as $social)
@php
$platformKey = strtolower($social->platform_key ?? 'custom');
$platformMeta = $socialPlatforms[$platformKey] ?? $socialPlatforms['custom'] ?? [];
$platformIconClass = $socialIconMap[$platformKey] ?? $socialIconMap['custom'];
@endphp
{{ $social->label }}
{{ $social->platform_key }}
|
@if($social->platform_key === 'whatsapp' && $social->whatsapp_number)
+{{ $social->whatsapp_number }}
@elseif($social->href)
{{ $social->href }}
@else
—
@endif
|
@if($social->is_floating)
Floating
@else
Footer
@endif
|
{{ $social->is_active ? 'Active' : 'Hidden' }}
|
|
@empty
|
No social links yet. Add one above.
|
@endforelse
@endsection
@push('scripts')
@endpush