@extends('layouts.front') @section('title', 'الرئيسية') @section('content')
{{-- 📰 العمود الرئيسي --}}
{{-- 🌟 الأخبار المميزة --}} @if($trending->count())

المميزة

عرض الكل
@foreach($trending as $post)
@if($post->cover)
{{ $post->title }}
{{ optional($post->category)->name }}
@endif

{{ $post->title }}

{{ Str::limit(strip_tags($post->excerpt ?? $post->body), 120) }}

{{ $post->published_at->diffForHumans() }}
@endforeach
@endif {{-- 🎥 قسم الفيديوهات --}} @php $videos = \App\Models\Video::latest()->take(6)->get(); @endphp @if($videos->count())

الفيديوهات

عرض الكل
@foreach($videos as $video)
@if(Str::contains($video->url, 'youtube')) @elseif($video->thumbnail) @endif

{{ $video->title }}

@endforeach
@endif {{-- 🗞️ قسم الجرائد --}} @php $newspapers = \App\Models\Newspaper::latest()->take(6)->get(); @endphp @if($newspapers->count())

الجريدة

عرض الكل
@foreach($newspapers as $paper)
{{ $paper->title }}

{{ $paper->title }}

{{ $paper->created_at->format('Y/m/d') }}

@endforeach
@endif {{-- 🏷️ الأقسام المعتادة --}} @foreach($cats as $cat) @php $posts = $cat->posts()->published()->latest('published_at')->take(4)->get(); @endphp @if($posts->count())

{{ $cat->name }}

عرض الكل
@foreach($posts as $post)
@if($post->cover)
{{ $post->title }}
@endif

{{ $post->title }}

{{ Str::limit(strip_tags($post->excerpt ?? $post->body), 120) }}

{{ $post->published_at->diffForHumans() }}
@endforeach
@endif @endforeach
{{-- 📎 العمود الجانبي --}} @include('front.partials.sidebar')
@endsection