title: Select text with double click is selecting wrong text
body: <p>So I have a web application that has a panel area. This area contains a text that can be copied to the clipboard. The problem is that every time I select this text (with 3 left button clicks) the text from the button bellow is also selected.</p>
  
  <p><a href="https://i.stack.imgur.com/iIFb1.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/iIFb1.png" alt="enter image description here"></a></p>
  
  <p>From the image above, if I select the TEXT TO COPY and Ctrl+C I will get the following clipboard (which is wrong):</p>
  
  <blockquote>
    <p>TEXT TO COPY</p>
    
    <p>CLICK ME</p>
  </blockquote>
  
  <p>This is the HTML code where this is inserted.</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-html lang-html prettyprint-override"><code>&lt;div class="panel panel-default"&gt;
      &lt;div class="panel-body wrapped-pannel"&gt;
          &lt;table&gt;
              &lt;tr&gt;
                  &lt;td&gt;TEXT TO COPY&lt;/td&gt;
              &lt;/tr&gt;
          &lt;/table&gt;
      &lt;/div&gt;
  &lt;/div&gt;
      
  &lt;form class="form-horizontal" role="form" novalidate&gt;
      &lt;div style="clear: both"&gt;&lt;/div&gt;
      &lt;div class="form-group"&gt;
          &lt;div class="col-md-3"&gt;
              &lt;button class="btn btn-primary"
                      ng-show="canclick"&gt;
                  CLICK ME
              &lt;/button&gt;
  
              &lt;button class="btn btn-default"&gt;
                  BACK
              &lt;/button&gt;
          &lt;/div&gt;
      &lt;/div&gt;
  &lt;/form&gt;</code></pre>
  </div>
  </div>
  </p>
  
  <p>Can anyone understand why is this happening? Many thanks.</p>