[PP-1] Break long text strings in layout edit

Created on 27 November 2018, about 6 years ago
Updated 12 April 2024, 9 months ago

In the layout builder edit screen, fields seem to be prefilled with the maximum number of characters allowed with no breaks. This can cause UI issues with certain themes.

To reproduce:

1. add a field with a 255 character length.
2. use an admin theme with a contained content area
3. edit the entity layout

Expected:

Layout builder to wrap the text to contain field in theme content area.

Actual:

The text overflows the container and pulls the dashed region to the edge of the screen. If you have a 2 column region, and place the field in the first column, it will overflow and push the second column below.

I don't know if there are other cases / components that can cause content to overflow the region, but the fix for this seems pretty simple to me, just a little css:

#layout-builder .field__item {
  overflow-wrap: break-word;
}

Screenshot from before fix:

Screenshot from after fix with patch from #9 β†’

πŸ› Bug report
Status

Closed: outdated

Version

11.0 πŸ”₯

Component
Layout builderΒ  β†’

Last updated 4 days ago

Created by

πŸ‡ΊπŸ‡ΈUnited States scottsawyer Atlanta

Live updates comments and jobs are added and updated live.
  • Blocks-Layouts

    Blocks and Layouts Initiative. See the #2811175 Add layouts to Drupal issue.

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.

Production build 0.71.5 2024