Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

226
Views
Wrap the message if it's too long in a mat expansion panel

I want to wrap an XML message in a mat-expansion-panel if it's too long so it continues down instead of going beyond the panel.

<mat-expansion-panel class="panel">
  <pre>{{pretty(message.content)}}</pre>
</mat-expansion-panel>
.panel {
  max-height: 80vh;
  width: 1000px;
  overflow: auto;
}
pretty(message: string) {
  return vkbeautify.xml(message);
}

I've tried using white-space, word-break, wrapping the message in <p> tag and setting the width to 85% but all these things didn't seem to do anything.

Image

about 4 years ago · Santiago Gelvez
1 answers
Answer question

0

Target to pre tag

.panel pre {
  max-height: 80vh;
  width: 1000px;
  overflow: auto;
}
about 4 years ago · Santiago Gelvez Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!