@include('components.pagination-bar', ['paginator' => $exams])
@if($exams->count() > 0)
@foreach($exams as $exam)
@php
$bestScore = $myResults[$exam->id] ?? null;
$attempts = $myAttempts[$exam->id] ?? 0;
@endphp
@if($exam->examCategory)
{{ $exam->examCategory->name }}
@endif
@if($exam->subject)
{{ $exam->subject->name }}
@endif
{{ $exam->visibility_label }}
{{ $exam->title }}
@if($exam->description)
{{ Str::limit($exam->description, 80) }}
@endif
{{ $exam->questions_count }} 題
@if($exam->creator)
{{ $exam->creator->name }}
@endif
@endforeach
@include('components.pagination-bar', ['paginator' => $exams])
@else
目前沒有可用的考試
請等待老師發佈考試,或自行建立練習
@endif
@endsection