Is it possible to prevent the green background of a child span from showing when the parent span has text overflow ellipsis applied?
.container {
border : 1px solid black;
max-width : 100px;
overflow : hidden;
text-overflow : ellipsis;
white-space : nowrap;
}
.backgroundColor {
background-color : green;
}
<div class="container">
Lorem ipsum
<span class="backgroundColor">should not be visible</span>
</div>
How can I achieve my goal of preventing the green background of the descendant span from being visible in this scenario?