Fix Required Field Validation Issues with Autocomplete in Drupal Forms
>>> [!note] Migrated issue <!-- Drupal.org comment --> <!-- Migrated from issue #3485619. --> Reported by: [ibrahim tameme](https://www.drupal.org/user/3747976) Related to !111 >>> <h3 id="summary-problem-motivation">Problem/Motivation</h3> <p>Field result on json autocomplete when autocomplete is enabled for browser and the field is required.</p> <p><img src="https://www.drupal.org/files/issues/2024-11-05/Screenshot%20from%202024-11-05%2014-03-59.png" width="600" height="600" alt="issue img"></p> <h4 id="summary-steps-reproduce">Steps to reproduce</h4> <p>1- Enable autcomplete on browser.<br> 2- Add required field as tagify.<br> 3- Try to save without adding any tag or show the field and press on it some browsers show the autocomplete without showing the field.</p> <h3 id="summary-proposed-resolution">Proposed resolution</h3> <p>There was 2 solutions either make the input type hidden or add autocomplete attr as off and I landed on adding the autocomplete attr because it will keep the front end validation.</p> <h3 id="summary-remaining-tasks">Remaining tasks</h3> <h3 id="summary-ui-changes">User interface changes</h3> <h3 id="summary-api-changes">API changes</h3> <h3 id="summary-data-model-changes">Data model changes</h3>
issue