Dialog not added inside wrapper

Created on 1 July 2024, 4 months ago

Problem/Motivation

When dialogNative adds the <dialog> element to the page, it append it to the document. This causes a problem because Drupal.dialog takes an element that should be the wrapper for the dialog. In addition to not being correctly wrapped, the event handing passes the wrapper as the dialog element breaking events ability to interact with the dialog.

Steps to reproduce

Create a dialog and view the source and see the dialog not inside the wrapper element.

Also, adding the following event handler will show the element not pointing to or able to resolve the dialog element or any of its content.

  $(window).on({
    'dialog:aftercreate': function (event, dialog, $element, settings) {
      console.log('Dialog open');
      console.log($element);
    },
  });

Proposed resolution

Remaining tasks

User interface changes

API changes

Data model changes

πŸ› Bug report
Status

Closed: outdated

Version

1.0

Component

Code

Created by

πŸ‡ΊπŸ‡ΈUnited States neclimdul Houston, TX

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

Comments & Activities

Production build 0.71.5 2024