Evaluation Session

Run the full FireFit circuit in sequence, capture HR values, and store complete timing data for each segment.

@if ($evaluation) Session #{{ $evaluation->id }} · {{ str_replace('_', ' ', $evaluation->status->value) }} @endif
@if (auth()->user()?->hasRole('proctor'))
Active Department: {{ $activeDepartment?->name ?? 'Not selected' }}
@endif
@if ($requiresDepartmentSelection)

Select an active department from the header before starting or viewing evaluation work. This keeps the proctor scoped to the correct department records.

@endif @if (auth()->user()?->hasRole('proctor') && ! $proctorCertified)

This proctor account must be certified by an admin before evaluations can be started or resumed.

@endif @if (! $evaluation) @if (! $requiresDepartmentSelection && (! auth()->user()?->hasRole('proctor') || $proctorCertified)) @if ($resumableSessions->isNotEmpty())
@error('resumeEvaluationId')

{{ $message }}

@enderror
Resume Session
@endif
@error('candidateId')

{{ $message }}

@enderror
@error('notes')

{{ $message }}

@enderror
Create Session
@endif @else @php $stepTask = collect($segments)->firstWhere('sequence', 1); $stepTaskRunning = filled($stepTask['started_at'] ?? null) && empty($stepTask['ended_at'] ?? null); @endphp {{-- Window event bridge: relays BLE sensor events into this Livewire component --}}

100 BPM step cadence

Runs only for the first 3-minute Step Task and stops automatically when that segment ends.

Start Metronome Stop Metronome
@persist('wahoo-ble')

Connection Status

Connect Wahoo Connecting... Disconnect

Live Heart Rate

bpm

@endpersist
Capture Resting HR @if ($bleConnected && $liveHr !== null) Live sensor active · {{ $liveHr }} bpm @endif

Candidate

{{ $evaluation->candidate->full_name }}

Department

{{ $evaluation->department->name ?? 'N/A' }}

Proctor

{{ $evaluation->proctor->name ?? 'N/A' }}

Total Time

{{ $evaluation->total_circuit_seconds ? gmdate('i:s', (int) $evaluation->total_circuit_seconds) : 'Pending' }}

Save Session Details

Pre-Circuit Baseline

2-minute resting HR baseline is required before segment 1 starts.

Time remaining:

Baseline completed. Segment 1 is unlocked.

Start 2-Min Baseline Complete Baseline
@foreach ($segments as $segment) @php $previousSegment = $loop->index > 0 ? $segments[$loop->index - 1] : null; $isTask = $segment['segment_type'] === 'task'; $isRunning = $segment['started_at'] !== null && $segment['ended_at'] === null; $isCompleted = $segment['started_at'] !== null && $segment['ended_at'] !== null; $canStart = false; if ($isTask && $activeSegmentId === null && ! $segment['ended_at']) { if ($loop->index === 0) { $canStart = $preCircuitCompletedAt !== null; } elseif ($previousSegment) { $canStart = $previousSegment['segment_type'] === 'walk' ? ! empty($previousSegment['started_at']) : ! empty($previousSegment['ended_at']); } } $canStop = $isTask && $activeSegmentId === $segment['id']; $statusLabel = $isCompleted ? 'Completed' : ($isRunning ? 'Running' : 'Not Started'); $statusClass = $isCompleted ? 'border-emerald-300/70 bg-emerald-100 text-emerald-800' : ($isRunning ? 'border-firefit-gold/60 bg-firefit-gold/15 text-firefit-black' : 'border-black/15 bg-black/5 text-black/70'); $stopAction = ($segment['sequence'] === 1 ? "\$dispatch('metronome-stop'); " : '') . "\$wire.stopSegment({$segment['id']}, elapsedSeconds)"; @endphp

Segment {{ $segment['sequence'] }} · {{ strtoupper($segment['segment_type']) }}

{{ $statusLabel }}

{{ $segment['label'] }}

Duration

Segment Controls

@if ($isTask && $canStart) @endif @if ($isTask && $canStop) @endif @if ($isTask && ! $canStart && ! $canStop && ! $isCompleted) {{ $loop->index === 0 && $preCircuitCompletedAt === null ? 'Complete 2-min baseline first' : 'Complete previous segment first' }} @endif @if (! $isTask) Auto-timed from adjacent task transitions @endif
@if ($isTask)

Start HR and End HR auto-capture from the live sensor at Start/Stop when connected.

@if ($bleConnected && $liveHr !== null)

Live sensor ready · {{ $liveHr }} bpm

@endif
@endif
@endforeach
@php $taskSegs = collect($segments)->where('segment_type', 'task')->sortBy('sequence'); $allTasksDone = $taskSegs->isNotEmpty() && $taskSegs->every(fn($s) => $s['ended_at'] !== null); $lastTaskEndedAt = $allTasksDone ? $taskSegs->last()['ended_at'] : null; @endphp @if ($allTasksDone)

Post-Circuit Recovery

{{-- 1-Min Recovery HR --}}

1-Min Recovery HR

@if ($recoveryHr1m) {{ $recoveryHr1m }} bpm @else Auto in @endif
Capture
{{-- 2-Min Recovery HR --}}

2-Min Recovery HR

@if ($recoveryHr2m) {{ $recoveryHr2m }} bpm @else Auto in @endif
Capture

Sensor connected — HRs will be captured automatically at the 1 and 2 minute marks.

Sensor not connected — enter values manually or use Capture after connecting.

@endif @error('completion')

{{ $message }}

@enderror
@if ($evaluation->status->value !== 'completed') Discard Session @endif @if ($evaluation->status->value === 'completed') View Report @endif Complete Evaluation Session
@endif