title: Flex item is squashed by it's own margin
body: <p>I have a flex container with a single child and an unwrapped text near it.</p>
  
  <p>The child is a square box with explicit width and height and a lateral margin which moves it apart from the text.</p>
  
  <p>When the text is too long to fit container's width and wraps in multiple lines, box's width shrinks a little, while it's margin keeps proper value.</p>
  
  <p><div class="snippet" data-lang="js" data-hide="false" data-console="true" data-babel="false">
  <div class="snippet-code">
  <pre class="snippet-code-css lang-css prettyprint-override"><code>div {
    display: flex;
    border: 1px solid #D0D0D0;
    width: 200px;
  }
  
  span {
    width: 1em; /* both width and flex-basis yield same results */
    height: 1em;
    margin-right: 1em;
    background-color: black;
  }</code></pre>
  <pre class="snippet-code-html lang-html prettyprint-override"><code>&lt;div&gt;
    &lt;span&gt;&lt;/span&gt; 
    box behaves normally
  &lt;/div&gt;
  
  &lt;div&gt;
    &lt;span&gt;&lt;/span&gt; 
    box's width shrinks near a text which doesn't fit parent's width
  &lt;/div&gt;</code></pre>
  </div>
  </div>
  </p>
  
  <p><a href="https://i.stack.imgur.com/PZxyy.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/PZxyy.png" alt="enter image description here"></a></p>
  
  <p>Can anyone explain why the box shrinks?</p>