{{-- Toolbar (hidden when printing) --}}
arrow_back Back to course
{{-- Header --}}
description

Course Transcript

{{ $course->title }}

{{ $user->name }} · Generated {{ now()->format('j M Y, H:i') }}

@if($course->summary)

{{ $course->summary }}

@endif
{{-- Modules (the final assessment is excluded — its answer key must not be printed) --}} @php $transcriptModules = $course->modules->where('module_type', '!=', 'final_assessment')->values(); @endphp @forelse($transcriptModules as $module)

Module {{ $module->module_number }}: {{ $module->title }}

@php $modImg = \App\Models\CourseContentBlock::imageUrl($module->module_image); @endphp @if($modImg){{ $module->title }}@endif @if($module->content)

{{ $module->content }}

@endif @foreach($module->blocks as $block) @php $d = $block->data ?? []; @endphp @switch($block->type) @case('heading')

{{ data_get($d, 'text') }}

@break @case('paragraph') @case('callout')

{{ data_get($d, 'text') }}

@break @case('text_image') @php $src = \App\Models\CourseContentBlock::imageUrl(data_get($d, 'path')); @endphp @if(data_get($d, 'text'))

{{ data_get($d, 'text') }}

@endif @if($src)
{{ data_get($d, 'alt') }} @if(data_get($d, 'caption'))
{{ data_get($d, 'caption') }}
@endif
@endif @break @case('image') @php $src = \App\Models\CourseContentBlock::imageUrl(data_get($d, 'path')); @endphp @if($src)
{{ data_get($d, 'alt') }} @if(data_get($d, 'caption'))
{{ data_get($d, 'caption') }}
@endif
@elseif(data_get($d, 'caption') || data_get($d, 'alt'))

[Image: {{ data_get($d, 'caption') ?: data_get($d, 'alt') }}]

@endif @break @case('video')

{{ data_get($d, 'title') ?: 'Video' }}

@if(data_get($d, 'transcript'))
{{ data_get($d, 'transcript') }}
@else

[No transcript provided for this video]

@endif @break @case('accordion') @foreach((array) data_get($d, 'items', []) as $item)

{{ data_get($item, 'title') }}

@if(data_get($item, 'body'))

{{ data_get($item, 'body') }}

@endif @php $isrc = \App\Models\CourseContentBlock::imageUrl(data_get($item, 'image')); @endphp @if($isrc){{ data_get($item, 'title') }}@endif @endforeach @break @case('carousel') @foreach((array) data_get($d, 'slides', []) as $slide) @php $ssrc = \App\Models\CourseContentBlock::imageUrl(data_get($slide, 'image')); @endphp @if($ssrc){{ data_get($slide, 'title') }}@endif @if(data_get($slide, 'title') || data_get($slide, 'caption'))

{{ data_get($slide, 'title') }}@if(data_get($slide, 'caption')) — {{ data_get($slide, 'caption') }}@endif

@endif @endforeach @break @case('flip_card')

{{ data_get($d, 'front') }} — {{ data_get($d, 'back') }}

@break @case('knowledge_check')

Knowledge check: {{ data_get($d, 'question') }}

@if(data_get($d, 'explanation'))

Why: {{ data_get($d, 'explanation') }}

@endif @break @endswitch @endforeach {{-- Assessment questions (assessment modules) --}} @if($module->questions->isNotEmpty())

Assessment questions

    @foreach($module->questions as $q)
  1. {{ $q->text }}
      @foreach($q->options as $opt)
    • {{ $opt->text }}@if($opt->is_correct) (correct)@endif
    • @endforeach
    @if($q->explanation)

    Why: {{ $q->explanation }}

    @endif
  2. @endforeach
@endif
@empty

This course has no content yet.

@endforelse

Segra LMS · Course transcript for {{ $user->name }}