@if($allCategories->count())
@endif
@forelse($categories as $category)
{{ $category->name }}
{{ $category->courses->count() }} {{ Str::plural('course', $category->courses->count()) }}
@if($category->description)
{{ $category->description }}
@endif
@foreach($category->courses as $course)
@include('public.partials.course-card', ['course' => $course])
@endforeach
@empty
@if($uncategorized->isEmpty())
No courses found
Published courses will appear here by category.
@endif
@endforelse
@if($uncategorized->isNotEmpty() && $selectedCategory === '')
Other
{{ $uncategorized->count() }} {{ Str::plural('course', $uncategorized->count()) }}
Courses without a specific category.
@foreach($uncategorized as $course)
@include('public.partials.course-card', ['course' => $course])
@endforeach
@endif