• Resolved weilies

    (@weilies)


    I am using latest WP and it now came with the new “block” editor. Well i can’t really appreciate it compare to the classic.

    But here is really what annoyed me because it can’t handle the text wrap well. It should wrap by “word” and not “character”, which making the reading experience bad (check the link below)
    Text Wrap

    I confirmed it wasn’t a theme issue because the same issue happen in other theme as well.

    Thanks for the help.

    • This topic was modified 5 years, 6 months ago by weilies.
Viewing 5 replies - 1 through 5 (of 5 total)
  • You can install the Classic Editor plugin if you prefer the old editor.
    The CSS that does the bad text wrap is overflow-wrap: break-word. It’s good for really long words, but that is all.
    If the browser supports your language, you can use hyphens: auto, which is much better, but not all languages are supported (or even work with hyphens). Or you can put in manual soft hyphens (­). Or you can use text-overflow: ellipsis but that is only if you’ve used overflow or white-space to make the text go out of the container.

    Thread Starter weilies

    (@weilies)

    i am not using any looong word, very unlikely. anyway to override

    overflow-wrap: break-word

    ?

    You can put CSS rules in Customizer > Additional CSS.

    https://developer.mozilla.org/en-US/docs/Web/CSS/overflow-wrap

    Thread Starter weilies

    (@weilies)

    Amazing @joyously ! i put following code and it is working!

    table.wp-block-table td {
    word-break:keep-all;
    }

    I vote that this be included in the template. I cannot conceive a case where the author of a table would want words broken at the letter level when flowing in a cell.

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Cell text doesn’t wrap properly’ is closed to new replies.