Today, while experimenting with new angular features, I encountered an issue that is shown in the link below:
https://i.sstatic.net/p4pNc.png
The "tags" on the page are expanding beyond the boundaries of their parent container (the white div). They wrap, but not very neatly, as you can see.
I would like them to avoid breaking in the middle of a word. For example, the phrase "software engineering" should be fully displayed on the second line.
The tags are enclosed within a div structured like this:
<div class="menu-block">
<div class="menu-header">
<strong>» Tags</strong>
</div>
<div class="menu-content tags">
<tags></tags>
</div>
</div>
Here are the corresponding CSS classes used:
.menu-block {
border-bottom: 1px solid #eeeeee;
padding: 1.2em;
border-left: 1px solid #eeeeee;
background-color: #fcfcfc;
}
.menu-block .menu-header {
margin-bottom: 1em;
font-size: 14pt;
}
.menu-block .menu-content {
font-size: 11pt;
/* Review specifications below */
}
.menu-block .tags {
font-size: 11pt;
line-height: 2.2em;
}
The .menu-block element is contained within a bootstrap .col-4 column.
Lastly, regarding the angular component (annotated for clarity):
@Component({
selector: 'tags',
template: `
<a *ngFor="let tagFeed of tagFeeds" class="tag" href="/tag/{{tagFeed.id}}">{{tagFeed.id}}</a>
`,
})