title: css dynamic div width
body: <p>I need a div that takes the full width of its parent except when there is an Image in front of it. Because then i want the image to be on the same line. I have tried floating the image to the left which made the text in the div go under the image which I dont want.
  Here are some images that i hope will clear up the image:</p>
  
  <p>The thing with the image:</p>
  
  <p><img src="https://i.stack.imgur.com/OotHq.png" alt="The thing with the image"></p>
  
  <p>The thing without the image:</p>
  
  <p><img src="https://i.stack.imgur.com/nkFNE.png" alt="The thing without the image"></p>