Hey there!

First, I randomly stumbled upon this module and I'm super happy I did. It solves one of the main issues I have with the UI of Layout Builder. Thanks a lot for your effort!

I have one problem though: It works well when clicking on one of the prerendered list items of a block. But when I search for a block and the list gets built in the browser, the links become invalid (they contain 'null' instead of region, delta and node):

/layout_builder/add/block/overrides/null/null/null/block_content%3A8d0a950b-d6e9-4518-8f7c-cf87e8cfb5ff

A quick look at layout_builder_simplify.search.js shows these values are read from localStorage:

var r = localStorage.getItem('Drupal.layout_builder.region');
var d = localStorage.getItem('Drupal.layout_builder.delta');
var n = localStorage.getItem('Drupal.layout_builder.node');

All these keys don't exist in localStorage for me. I looked through the source of layout_builder's JS file and was not able to find a reference to where these items are set.

It's possible one of the other contrib modules installed in my project overrides this or I'm missing a module that sets these items.

Any idea what could be the issue here?

Comments

dulnan created an issue. See original summary.

avpaderno’s picture

Category: Bug report » Support request
rahul.nahar001’s picture

Status: Active » Needs review
StatusFileSize
new792 bytes

Please find the patch for above mentioned issue.

darshanchoudhary’s picture

Version: 1.0.x-dev » 1.0.1
Assigned: Unassigned » darshanchoudhary
Status: Needs review » Fixed

Thank @rahul.nahar001 for the fix and @dulnan for appreciating the module and higlighting the issue.

The patch has been tested and released in 1.0.1.

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.