Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Block: Column - Add word-break CSS to allow wrapping of long lines #10198

Closed
wants to merge 0 commits into from
Closed

Conversation

eddhurst
Copy link

@eddhurst eddhurst commented Sep 26, 2018

Description

As per #7921, this allows long-lines to break within columns.

To replicate: Create a columns area with single unbroken stream of letters. This wraps correctly in the back-end but unexpectedly pushes the second column out of bounds of the page whilst on the front-end.

How has this been tested?

I could replicate the fix on Chrome, Safari, Firefox and Chrome. IE11 seemingly never had the problem, Edge 16 and Edge 17 do.

To note - the break-word property is not supported on Edge. The suggested solution to use -ms-break-word: break-all; is a bad solution as it then breaks the entire word - which seems like an unexpected and bad user experience.

Screenshots

screen shot 2018-09-26 at 15 19 14

screen shot 2018-09-26 at 16 19 17

Types of changes

Single line change to style.scss of Columns block.

Checklist:

  • My code is tested.
  • My code follows the WordPress code style.
  • My code follows the accessibility standards.
  • My code has proper inline documentation.

@eddhurst
Copy link
Author

Amended initial PR to be cross-browser compatible. This now uses word-wrap instead of break-word which has better flexibility and more support across devices.

@eddhurst eddhurst closed this Nov 28, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant