Follow

Keep Up to Date with the Most Important News

By pressing the Subscribe button, you confirm that you have read and are agreeing to our Privacy Policy and Terms of Use
Contact

How to make div with text to expand if the text does not fit there

My page: page

Html code for message block:

<div class="message-body row">
      <div class="text-box ">
        <p>{{message.text}}</p>
      </div>
    </div>

Css styles:

MEDevel.com: Open-source for Healthcare and Education

Collecting and validating open-source software for healthcare, education, enterprise, development, medical imaging, medical records, and digital pathology.

Visit Medevel

.text-box {
  display: flex;
  margin-left: 10px;
}

message-body does not have any styles from css

>Solution :

.text-box { display: flex; margin-left: 10px; word-break: break-all; }

Add a comment

Leave a Reply

Keep Up to Date with the Most Important News

By pressing the Subscribe button, you confirm that you have read and are agreeing to our Privacy Policy and Terms of Use

Discover more from Dev solutions

Subscribe now to keep reading and get access to the full archive.

Continue reading