Allow off-canvas dialog to be rendered on the left of the page in Drupal 8

this is my current code to display a custom block off-canvas. $build[‘link’] = [ ‘#title’ => ‘Select Sources’, ‘#type’ => ‘link’, ‘#url’ => Url::fromRoute(‘heritage_ui.sourcesmenu’, [‘textid’ => $textid]), ‘#attributes’ => [ ‘class’ => [‘use-ajax’], ‘data-dialog-type’ => ‘dialog’, ‘data-dialog-renderer’ => ‘off_canvas’, ‘data-dialog-options’ => Json::encode([‘width’ => 400]), ], ‘#attached’ => [ ‘library’ => [ ‘core/drupal.dialog.ajax’, ], ], ];…

Magento 2 admin menu action result Invalid security or form key. Please refresh the page. on click

I have succesfully added a new admin menu. But the problem is whenever i clicked the admin menu button, I got Invalid security or form key. Please refresh the page. Here’re some of my codes. This is my menu.xml    <add id=”Testing_Basic::menu_item” title=”Manage Items” module=”Testing_Basic” sortOrder=”10″ parent=”Testing_Basic::menu” action=”Webpage/Create/Index” resource=”Testing_Basic::menu_item”/> And this is my directories looks like.

Allow off-canvas dialog to be rendered on the left of the page in Drupal 8

this is my current code to display a custom block off-canvas. $build[‘link’] = [ ‘#title’ => ‘Select Sources’, ‘#type’ => ‘link’, ‘#url’ => Url::fromRoute(‘heritage_ui.sourcesmenu’, [‘textid’ => $textid]), ‘#attributes’ => [ ‘class’ => [‘use-ajax’], ‘data-dialog-type’ => ‘dialog’, ‘data-dialog-renderer’ => ‘off_canvas’, ‘data-dialog-options’ => Json::encode([‘width’ => 400]), ], ‘#attached’ => [ ‘library’ => [ ‘core/drupal.dialog.ajax’, ], ], ];…