Improve layout builder usage

Created on 13 September 2018, over 6 years ago
Updated 2 August 2023, over 1 year ago

This module is very handy for adding an entity browser to the new core Layout Builder to make it easy to populate a block with an entity reference. Unfortunately the table display of the results is pretty unusable in the tiny off-canvas space provided. It would be nice if the code detected that it was being used in that off-canvas area and display results in divs instead of a table, or some other way that stacks the results vertically instead of horizontally.

Summary of what's included in this patch:

  • Reworks the empty state of the selector to help the user understand what to do next.
  • Automatically opens the browser to avoid an extra click (requires a patch to entity browser, #3008700: Prevent "auto_open" infinite loop β†’ ).
  • Adds css to arrange the table cells vertically instead of horizontally so they fit better in the tiny space.
  • Adds css to highlight the title of the selected item so it doesn't blend into the background.
  • Adds an option to select which view modes should be allowed in Layout Builder for better defaults and editorial UX.
  • Hides the title option which would otherwise give every block the title of the name of the entity browser.
✨ Feature request
Status

Needs work

Version

1.0

Component

Code

Created by

πŸ‡ΊπŸ‡ΈUnited States KarenS

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

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

  • πŸ‡ΊπŸ‡ΈUnited States dave reid Nebraska USA

    I think in general we'd still like this upstream instead of a separate module (which itself is not Drupal 10 compatible currently).

  • πŸ‡¨πŸ‡¦Canada Liam Morland Ontario, CA πŸ‡¨πŸ‡¦

    The development version of entity_browser_block_layout is compatible with Drupal 10. I will tag a release once the most recent commit is two weeks old.

Production build 0.71.5 2024