refactor: Update search input layout and improve SVG icon positioning

This commit is contained in:
2026-02-25 20:16:54 -05:00
parent 490ac51495
commit 656c2819d3

View File

@@ -19,9 +19,11 @@
<span class="text-2xl font-bold">Servers</span> <span class="text-2xl font-bold">Servers</span>
@if(count($servers) > 1) @if(count($servers) > 1)
<div class="relative w-full sm:w-80" x-data="{ search: '' }"> <div class="relative w-full sm:w-80" x-data="{ search: '' }">
<svg class="absolute left-3 top-1/2 -translate-y-1/2 size-4 text-base/40 pointer-events-none" fill="none" viewBox="0 0 24 24" stroke="currentColor"> <div class="absolute inset-y-0 left-0 flex items-center pl-3 pointer-events-none">
<path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M21 21l-6-6m2-5a7 7 0 11-14 0 7 7 0 0114 0z"/> <svg class="size-4 text-base/60" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2">
</svg> <path stroke-linecap="round" stroke-linejoin="round" d="M21 21l-6-6m2-5a7 7 0 11-14 0 7 7 0 0114 0z"/>
</svg>
</div>
<input type="text" <input type="text"
x-model="search" x-model="search"
@input=" @input="
@@ -33,7 +35,7 @@
}); });
" "
placeholder="Filter servers..." placeholder="Filter servers..."
class="w-full pl-9 pr-3 py-2 text-sm rounded-lg border border-neutral bg-background focus:outline-none focus:ring-1 focus:ring-primary focus:border-primary placeholder:text-base/40" /> class="w-full pl-10 pr-3 py-2 text-sm rounded-lg border border-neutral bg-background focus:outline-none focus:ring-1 focus:ring-primary focus:border-primary placeholder:text-base/40" />
</div> </div>
@endif @endif
</div> </div>