45 lines
1.7 KiB
PHP
45 lines
1.7 KiB
PHP
@extends('news.layout', [
|
|
'metaTitle' => $category->name . ' — News',
|
|
'metaDescription' => $category->description ?: ('Announcements in the ' . $category->name . ' category.'),
|
|
'metaCanonical' => route('news.category', $category->slug),
|
|
])
|
|
|
|
@section('news_content')
|
|
@php
|
|
$headerBreadcrumbs = collect([
|
|
(object) ['name' => 'Community', 'url' => route('community.activity')],
|
|
(object) ['name' => 'Announcements', 'url' => route('news.index')],
|
|
(object) ['name' => $category->name, 'url' => route('news.category', $category->slug)],
|
|
]);
|
|
@endphp
|
|
|
|
<x-nova-page-header
|
|
section="Community"
|
|
:title="$category->name"
|
|
icon="fa-folder-open"
|
|
:breadcrumbs="$headerBreadcrumbs"
|
|
:description="$category->description ?: ('Announcements filed under ' . $category->name . '.')"
|
|
headerClass="pb-6"
|
|
/>
|
|
|
|
<div class="mx-auto max-w-7xl px-6 pt-8 pb-16 md:px-10">
|
|
<div class="grid gap-8 xl:grid-cols-[minmax(0,1fr)_320px]">
|
|
<section>
|
|
@if($articles->isEmpty())
|
|
<div class="rounded-[28px] border border-white/[0.06] bg-white/[0.025] px-8 py-14 text-center text-white/45">No articles in this category yet.</div>
|
|
@else
|
|
<div class="grid gap-5 md:grid-cols-2">
|
|
@foreach($articles as $article)
|
|
@include('news._article_card', ['article' => $article])
|
|
@endforeach
|
|
</div>
|
|
<div class="mt-8 flex justify-center">{{ $articles->links() }}</div>
|
|
@endif
|
|
</section>
|
|
<aside class="space-y-4">
|
|
@include('news._sidebar', ['categories' => $categories, 'trending' => $trending, 'tags' => $tags])
|
|
</aside>
|
|
</div>
|
|
</div>
|
|
@endsection
|