Formfield display option id : id is set to upper div, not to the field
toto975 opened this issue · 0 comments
toto975 commented
Laravel version
9.31
PHP version
8.24
Voyager version
1.5
Database
MariaDB 10.3
Description
The custom id set in the bread for a text field or media picker field is set to the upper div, not to the field itself.
The for property of the label is not good also.
Steps to reproduce
In the bread, set the custom id
"display": {
"id": "titre_id"
},
Open the form
the custom id is set to the upper div.
<div class="form-group col-md-12 " =====> id="titre_id" <===== >
<label class="control-label" =====> for="name" <===== >Titre</label>
<input required="" type="text" class="form-control" name="titre" placeholder="Titre" value="test pour carrousel">
</div>
Expected behavior
The id must be set, not the name.
something like :
<div class="form-group col-md-12 ">
<label class="control-label" =====> for="titre_id" <===== >Titre</label>
<input required="" type="text" =====> id="titre_id" <===== class="form-control" name="titre" placeholder="Titre" value="test pour carrousel">
</div>
Screenshots
Additional context
No response