Mercurial > borealpoint
diff resources/views/components/form/checkbox.blade.php @ 0:9d7dcd54c677
Initial Commit and package setup
| author | luka |
|---|---|
| date | Sat, 23 Aug 2025 22:20:51 -0400 |
| parents | |
| children |
line wrap: on
line diff
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/resources/views/components/form/checkbox.blade.php Sat Aug 23 22:20:51 2025 -0400 @@ -0,0 +1,11 @@ +@props(['name', 'label', 'checked' => false]) + +<div class="mb-3 form-check"> + <input type="checkbox" id="{{ $name }}" name="{{ $name }}" value="1" + {{ old($name, $checked) ? 'checked' : '' }} + class="form-check-input"> + <label for="{{ $name }}" class="form-check-label">{{ $label }}</label> + @error($name) + <div class="text-danger small">{{ $message }}</div> + @enderror +</div>
