Autocomplete options hidden by modal

Created on 13 November 2023, about 1 year ago
Updated 5 March 2024, 9 months ago

My site has paragraph types for media -- image, remote video, etc. The upload form for the entity browser for these paragraph types includes an autocomplete taxonomy term field. When uploading a new media item within Mercury Editor, the autocomplete options for that field are hidden by the entity browser modal popup, rendering it unusable. (Screenshot attached.)

πŸ› Bug report
Status

Fixed

Version

2.1

Component

User interface

Created by

πŸ‡ΊπŸ‡ΈUnited States jesss

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Merge Requests

Comments & Activities

  • Issue created by @jesss
  • Status changed to Postponed: needs info about 1 year ago
  • πŸ‡ΊπŸ‡ΈUnited States pixelwhip

    You mentioned an Entity Browser. Do you see this same behavior using the core Media Broswer widget for selecting and adding related media to the paragraph?

    Based on your screenshot, it looks like the native element in the shadow-dom of the web component probably has the "modal" attribute. This will cause the element and its contents to sit in the browser's top-layer. Drupal's autocomplete dropdown gets appended to the element of the page which sits underneath the top-layer. This would cause the options to render behind the modal's overlay.

    If this is the case, we would need to figure out how to remove the modal attribute from the inner or move the autocomplete results inside the element so it gets hoisted to the top-layer as well.

    Do you have a minimal way to reproduce this?

  • Status changed to Active about 1 year ago
  • πŸ‡ΊπŸ‡ΈUnited States jesss

    My apologies for the confusion -- we're using the core Media Library widget, not Entity Browser.

    Steps to reproduce:

    1. Add an autocomplete entity reference field to a media type using the Media Library widget on the form display.
    2. Create a paragraph type for that media type.
    3. Within Mercury Editor, add a paragraph of that type.
    4. After uploading your media, attempt to add an entity reference to that media item. See how the autocomplete dropdown is hidden by the modal.
  • πŸ‡ΊπŸ‡ΈUnited States keiserjb

    I've had this problem as well. I added a Media Keywords field to my media types that references a taxonomy. I upload a media item and try to fill in terms. The autocomplete dropdown is behind the media library modal.

  • πŸ‡ΊπŸ‡ΈUnited States jesss

    I am still seeing this behavior in alpha14 on 10.2.3. Any chance of a fix?

  • First commit to issue fork.
  • Status changed to Needs review 9 months ago
  • πŸ‡ΊπŸ‡ΈUnited States justin2pin
  • Pipeline finished with Skipped
    9 months ago
    #99752
  • Status changed to Fixed 9 months ago
  • πŸ‡ΊπŸ‡ΈUnited States justin2pin
  • Automatically closed - issue fixed for 2 weeks with no activity.

Production build 0.71.5 2024