Message

Message

Message

How to wrap text in Vaadin text area? It is by default taking style for white-space: nowrap

177 Views Asked by At

My HTML:

<div class="text-sm margin-bottom-xs" id="abcDiv">
  <div>
    <p class="padding-bottom-xs label_styles">Message</p>
    <vaadin-text-area id="abc" style="border: 1px solid black; padding: 1em; width:100%"></vaadin-text-area>
  </div>
</div>

And it looks like this:

screenshot

1

There are 1 best solutions below

8
Rolf On

As seen in the V14 documentation, the TextArea component does, in fact, wrap text inside it by default through white-space: pre-wrap. Perhaps you have some custom CSS in your application that overrides that?