entity_reference_modal
Base on module Entity Reference Modal Create. Module Entity reference modal has most bugs fixed and drupal 10 compatible. This module offers a autocomplete widget or quick search entity with an "Add new" button for entity reference fields within Drupal. With this module, you can effortlessly search and reference existing entities or create new ones using a modal window entity form. It provides complete support for form modes, which can be conveniently configured from the widget settings.
Key Features:
Quick search entity: It will list all the entities according to the method to select (note that it will not high performance work like module entity browser). If your entity field use view entity references, do not use pagination, you have to show all rows. it only supports bootstrap 5 theme, other theme use custom css by itself (There is a Load bootstrap option. If your admin interface is not bootstrap 5 admin, it will load bootstrap 5 cdn.)
Effortless Entity Creation: You can create new entities directly from the autocomplete widget by simply clicking the "Add new" button. This opens an entity form in a modal window, making entity creation a seamless part of your workflow.
Flexible Form Mode Selection: Choose the appropriate form mode for creating new entities within the modal window, ensuring that the entity is created with the specific settings you need.
Customizable Modal Settings: Adjust the modal's width and title to suit your site's design and requirements. You have full control over the modal's appearance.
Check permission: Check current user has right to create entity
Bundle Selection: While currently supporting a single bundle for the "Add new" modal, you can choose the bundle that best fits your needs when creating new entities.
User-Friendly Autocomplete: The autocomplete search field is similar to Drupal's core functionality, offering a smoother user experience without the "(id)" suffix (Tagify usage option is in progress).
How to Get Started:
- Install the Entity Reference Modal module like any other Drupal module.
- Navigate to the "Manage form display" of a Drupal entity that contains an entity reference field.
- Set the widget to "Autocomplete (add new with Modal)."
- Open the widget settings to fine-tune the module to your preferences. Adjust settings such as allowing the addition of new entities, specifying the "Add" button title (support html code)