---
import type { Input as Props } from 'types';

const {value, checked ,name, label, autocomplete, placeholder, divClass, inputClass} = Astro.props;

---

<>
  {
    name && (
      <div class={"flex flex-row items-center " + divClass}>
        <input
          type="checkbox"
          name={name}
          id={name}
          checked={checked}
          value={value}
          autocomplete={autocomplete}
          placeholder={placeholder}
          class={"mr-2 size-5 " + inputClass}
        />
        {label && (
          <label for={name} class="block text-lg font-medium">
            {label}
          </label>
        )}
      </div>
    )
  }
</>
