Pre text format in width

123 Views Asked by At

I am using topcoat css on a cordova mobile app. I want pre-text to fit within width and not word-wrap.

http://codepen.io/civilwar/pen/JEebd

I have text that I want to keep the return characters between paragraphs. I do not want to keep the width of the text. To get around this issue I have my pre text to be in a div that has word wrap break word. This converts the text to only appear within the width of the mobile app ( i.e. I don't have to scroll to the right). Getting rid of word wrap break word makes the pre text go out to its original width. I want to disable word wrap but keep my pre-text within the width of the app how do I do that?

1

There are 1 best solutions below

4
On BEST ANSWER

Working Demo

Just this CSS

.summary > pre {
    white-space: normal;
}

good luck!