Module breaks Layout Builder or any module using the core "drupal.dialog.off_canvas" library

Created on 19 January 2024, 5 months ago
Updated 5 February 2024, 5 months ago

Problem/Motivation

Currently, if we are using any module, which has a dependency to the core "drupal.dialog.off_canvas" library (e.g. "layout_builder"), the output breaks, and an error gets displayed in the console:

An error occurred during the execution of the Ajax response: TypeError: $element.dialog is not a function

This happens, because "drupal.dialog.off_canvas" uses Drupal.dialog SOMEWHERE in their code. I only could find calls using the jquery-ui library:
line 305-307:

    getContainer($element) {
      return $element.dialog('widget');
    },

and line 247-249

      $element
        .dialog('option', adjustedOptions)
        .trigger('dialogContentResize.off-canvas');

But these are just plain jquery .dialogs call.

Steps to reproduce

Proposed resolution

Create an adapter library for the drupal.dialog.off_canvas

Remaining tasks

User interface changes

API changes

Data model changes

πŸ› Bug report
Status

Active

Version

1.0

Component

Code

Created by

πŸ‡©πŸ‡ͺGermany Grevil

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

Comments & Activities

Production build 0.69.0 2024