@php $levelRaw = strtolower(trim((string) ($mcq->level ?? 'easy'))); $levelClass = $levelRaw === 'hard' ? 'sr-level-hard' : ($levelRaw === 'medium' ? 'sr-level-medium' : 'sr-level-easy'); $allowedTags = '
- ';
$options = [
'A' => $mcq->option1 ?? '',
'B' => $mcq->option2 ?? '',
'C' => $mcq->option3 ?? '',
'D' => $mcq->option4 ?? '',
];
@endphp
Question #{{ $mcq->id }}
{{ ucfirst($levelRaw ?: 'Easy') }}
{!! strip_tags(htmlspecialchars_decode((string) $mcq->question), $allowedTags) !!}