fix: add empty state handling to reinstall modal when no templates available

This commit is contained in:
2026-03-02 21:27:54 -05:00
parent ef1499cde4
commit 74e52a87aa

View File

@@ -164,6 +164,18 @@
</div>
<div class="space-y-3 max-h-[460px] overflow-y-auto pr-1" @if($isProtected) style="pointer-events: none; opacity: 0.6;" @endif>
@if($groupedOs->isEmpty())
<div class="flex flex-col items-center justify-center py-12 text-center">
<div class="w-16 h-16 rounded-full bg-warning/10 flex items-center justify-center mb-4">
<x-ri-error-warning-line class="size-8 text-warning" />
</div>
<h3 class="text-lg font-semibold text-base/90 mb-2">No Templates Available</h3>
<p class="text-sm text-base/60 max-w-md">
No operating system templates are configured for this server type.
Please contact support to have templates added.
</p>
</div>
@else
@foreach($groupedOs as $categoryLabel => $templates)
@php
$categoryKey = \Illuminate\Support\Str::slug($categoryLabel);
@@ -242,6 +254,7 @@
</div>
</div>
@endforeach
@endif
</div>
<div class="mt-4 pt-4 border-t border-neutral/30">