Commit e67f64e5 authored by lauriii's avatar lauriii

Issue #2811717 by tedbow, drpal, RajabNatshah, droplet, alexpott: [outsidein]...

Issue #2811717 by tedbow, drpal, RajabNatshah, droplet, alexpott: [outsidein] Uncaught TypeError: Cannot read property 'addEventListener' of null
parent 5380355d
......@@ -124,6 +124,9 @@
* True enable edit mode, false disable edit mode.
*/
function setEditModeState(editMode) {
if (!document.querySelector('[data-off-canvas-main-canvas]')) {
throw new Error('data-off-canvas-main-canvas is missing from outside-in-page-wrapper.html.twig');
}
editMode = !!editMode;
var $editButton = $(toggleEditSelector);
var $editables;
......
......@@ -3,7 +3,9 @@
* @file
* Default theme implementation for a page wrapper.
*
* For consistent wrapping to {{ page }} render in all themes.
* For consistent wrapping to {{ page }} render in all themes. The
* "data-off-canvas-main-canvas" attribute is required by the off-canvas dialog.
* It cannot be removed without breaking the off-canvas dialog functionality.
*
* Available variables:
* - children: Contains the child elements of the page.
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment