@php
if (empty($routeParams)) {
$routeParams = [];
}

if (! isset($inativosSelecionado)) {
$inativosSelecionado = false;
}
@endphp

<div class="col-md-4 float-right">
    <form id="form-busca" action="{{ route($route, $routeParams) }}">
        <div class="input-group mb-3">
            <input type="text" name="busca" class="form-control" placeholder="Busca" value="{{ $busca ?? $busca }}">
            <div class="input-group-append">
                <button class="btn btn-outline-secondary" title="Filtrar"><i data-feather="search"></i></button>
                <a href="{{ route($route, $routeParams) }}" class="btn btn-outline-secondary" title="Limpar"><i data-feather="x"></i></a>
            </div>
        </div>
    </form>
</div>
<div class="form-group float-right">
    @if (isset($inativos))
    <label class="mt-2" for="inativos">Retornar inativos?</label>
    <input type="checkbox" id="inativos" name="inativos" form="form-busca" {{ $inativosSelecionado ? 'checked' : '' }}>
    @endif
</div>