I can only offer 2 thoughts.
- It might be a design issue if the dynamic text isn't wrapped itself by anything that doesn't wrap its peer elements.
- You might be able to get there by using some of the special parts of CSS https://www.tutorialspoint.com/css/css_syntax.htm Shows you how to look for descendents:
Imagine you had a dialog structured like this:
<img class="dialog-icon" src="../someicon.ico" />
<div class="dialog-title">My Dialog Title</div>
<div class="randomclass"> 1. random text 1</div>
<div class="randomclass-2"> 2. random text 2</div>
<div class="randomclass-2"> 6. random text 6</div>
<img class="random-image-3" src="../randominage3.png" />
4. Stand Alone Text
<img class="random-image-5" src="../randomimage5.gif" />
<div class="randomclass-2"> 7. random text 6</div>
<div class="dialog footer">
... some footer stuff here ...
You might be able to get at the second line of text (2.) with the following CSS which you can test in the Chrome Dev Tools Console with the following command (the part in single quotes is the CSS selector)