{{-- Auto-refresh while comparison is running --}} @if ($state === 'comparing')
@endif @php $duplicateNamePoliciesCountValue = (int) ($duplicateNamePoliciesCount ?? 0); @endphp @if ($duplicateNamePoliciesCountValue > 0) @endif {{-- Row 1: Stats Overview --}} @if (in_array($state, ['ready', 'idle', 'comparing', 'failed']))
{{-- Stat: Assigned Baseline --}}
{{ __('baseline-compare.stat_assigned_baseline') }}
{{ $profileName ?? '—' }}
@if ($snapshotId) {{ __('baseline-compare.badge_snapshot', ['id' => $snapshotId]) }} @endif @if (filled($coverageStatus)) {{ $coverageStatus === 'ok' ? __('baseline-compare.badge_coverage_ok') : __('baseline-compare.badge_coverage_warnings') }} @endif @if (filled($fidelity)) {{ __('baseline-compare.badge_fidelity', ['level' => Str::title($fidelity)]) }} @endif @if ($hasEvidenceGaps) {{ __('baseline-compare.badge_evidence_gaps', ['count' => $evidenceGapsCountValue]) }} @endif
@if ($hasEvidenceGaps && filled($evidenceGapsSummary))
{{ __('baseline-compare.evidence_gaps_tooltip', ['summary' => $evidenceGapsSummary]) }}
@endif
{{-- Stat: Total Findings --}}
{{ __('baseline-compare.stat_total_findings') }}
@if ($state === 'failed')
{{ __('baseline-compare.stat_error') }}
@else
{{ $findingsCount ?? 0 }}
@endif @if ($state === 'comparing')
{{ __('baseline-compare.comparing_indicator') }}
@elseif (($findingsCount ?? 0) === 0 && $state === 'ready') {{ $whyNoFindingsMessage ?? $whyNoFindingsFallback }} @endif
{{-- Stat: Last Compared --}}
{{ __('baseline-compare.stat_last_compared') }}
{{ $lastComparedAt ?? __('baseline-compare.stat_last_compared_never') }}
@if ($this->getRunUrl()) {{ __('baseline-compare.button_view_run') }} @endif
@endif {{-- Coverage warnings banner --}} @if ($state === 'ready' && $hasCoverageWarnings) @endif {{-- Failed run banner --}} @if ($state === 'failed') @endif {{-- Critical drift banner --}} @if ($state === 'ready' && ($severityCounts['high'] ?? 0) > 0) @endif {{-- State: No tenant / no assignment / no snapshot --}} @if (in_array($state, ['no_tenant', 'no_assignment', 'no_snapshot']))
@if ($state === 'no_tenant')
{{ __('baseline-compare.empty_no_tenant') }}
@elseif ($state === 'no_assignment')
{{ __('baseline-compare.empty_no_assignment') }}
@elseif ($state === 'no_snapshot')
{{ __('baseline-compare.empty_no_snapshot') }}
@endif
{{ $message }}
@endif {{-- Severity breakdown + actions --}} @if ($state === 'ready' && ($findingsCount ?? 0) > 0) {{ $findingsCount }} {{ Str::plural('Finding', $findingsCount) }} {{ __('baseline-compare.findings_description') }}
@if (($severityCounts['high'] ?? 0) > 0) {{ $severityCounts['high'] }} High @endif @if (($severityCounts['medium'] ?? 0) > 0) {{ $severityCounts['medium'] }} Medium @endif @if (($severityCounts['low'] ?? 0) > 0) {{ $severityCounts['low'] }} Low @endif
@if ($this->getFindingsUrl()) {{ __('baseline-compare.button_view_findings') }} @endif @if ($this->getRunUrl()) {{ __('baseline-compare.button_review_last_run') }} @endif
@endif {{-- Ready: no drift --}} @if ($state === 'ready' && ($findingsCount ?? 0) === 0 && ! $hasCoverageWarnings)
{{ __('baseline-compare.no_drift_title') }}
{{ __('baseline-compare.no_drift_body') }}
@if ($this->getRunUrl()) {{ __('baseline-compare.button_review_last_run') }} @endif
@endif {{-- Ready: warnings, no findings --}} @if ($state === 'ready' && ($findingsCount ?? 0) === 0 && $hasCoverageWarnings)
{{ __('baseline-compare.coverage_warnings_title') }}
{{ __('baseline-compare.coverage_warnings_body') }}
@if ($this->getRunUrl()) {{ __('baseline-compare.button_review_last_run') }} @endif
@endif {{-- Idle state --}} @if ($state === 'idle')
{{ __('baseline-compare.idle_title') }}
{{ $message }}
@endif