Problem/Motivation
On Drupal 11.2, the "Add field" form now opens in a modal dialog. The functionality from this module to select a custom field prefix is no longer present in this new interface. This means all new fields are created with the default field_ prefix, and there's no way to select alternatives like schema_.
Steps to reproduce
On a Drupal 11.2 site, install and enable the
schemadotorg_field_prefix
module.
Configure alternative prefixes in the module's settings.
Go to the "Manage fields" page for any entity bundle and click "Add field".
Observe that the modal for adding a new field does not provide an option to select a prefix.
Proposed resolution
It would be ideal to restore the prefix selection functionality. A great user experience would be to allow changing the prefix directly when editing the machine name, as shown in the attached screenshot. When a user clicks the "[Edit]" link next to the machine name, they could be presented with a dropdown for the prefix and a text field for the field name itself.
Thank you for maintaining this extraordinary module.
| Comment | File | Size | Author |
|---|---|---|---|
| CleanShot 2025-06-23 at 01.22.00@2x.png | 303.43 KB | dan_metille |
Issue fork schemadotorg-3531708
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
Comments
Comment #2
jrockowitz commentedThis regression is being caused by #3386762: Use modals in field creation and field edit flow
We are most likely going to have to completely rewrite this module using the similar approach but targeting a completely different form/render array.
Comment #4
jrockowitz commentedComment #6
jrockowitz commented