Add getTextFieldValues to buildFieldTrait to handle multi-valued text-based fields
>>> [!note] Migrated issue <!-- Drupal.org comment --> <!-- Migrated from issue #3324474. --> Reported by: [dipakmdhrm](https://www.drupal.org/user/1687410) Related to !22 >>> <h3 id="summary-problem-motivation">Problem/Motivation</h3> <p>We have `BuildFieldTrait::getTextFieldValue`, but then it's used on multivalued fields, it returns comma separated values, which is an issue if the text itself contains comma.</p> <h3 id="summary-proposed-resolution">Proposed resolution</h3> <p>Add `BuildFieldTrait::getTextFieldValues` to return multiple values in an array. The pairing of `BuildFieldTrait::getTextFieldValue` &amp; `BuildFieldTrait::getTextFieldValues` will be analogous to `BuildFieldTrait::getReferencedEntityFromField` and `BuildFieldTrait::getReferencedEntitiesFromField`</p> <h3 id="summary-api-changes">API changes</h3> <p>- No changes to existing methods.<br> - A new method `BuildFieldTrait::getTextFieldValues()` will now returns an array of values for multi-field text-based fields.</p>
issue