title: How can I show/hide sibling spans in SCSS?
body: <p>Given the following design:<a href="https://i.stack.imgur.com/DGFjE.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/DGFjE.png" alt="enter image description here"></a></p>
  
  <p>I'd like to hide the 'magnifier' icon and show the 'close' X icon in case the the input's placeholder is not shown.</p>
  
  <p>My markup is:</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>input:not(:placeholder-shown) {
     // hide 'magnifier' icon
     // show 'close' icon
  }</code></pre>
  <pre class="snippet-code-html lang-html prettyprint-override"><code>&lt;link href="https://stackpath.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css" rel="stylesheet"/&gt;
  &lt;link href="https://stackpath.bootstrapcdn.com/bootstrap/4.2.1/css/bootstrap.min.css" rel="stylesheet"/&gt;
  &lt;div class="input-group input-group-sm w-50" id="search-box"&gt;
    &lt;div class="input-group-prepend"&gt;
       &lt;span class="input-group-text bg-white" id="input-magnifier"&gt;
          &lt;i class="fa fa-search text-muted"&gt;&lt;/i&gt;
       &lt;/span&gt;
       &lt;span class="input-group-text bg-white"&gt;
          &lt;i class="fa fa-close text-muted"&gt;&lt;/i&gt;
       &lt;/span&gt;
    &lt;/div&gt;
  
    &lt;input type="search" placeholder="Search with &amp;#39;exact match&amp;#39;" class="form-control" /&gt;
  
    &lt;div class="input-group-append"&gt;
      &lt;div class="dropdown btn-group" role="group"&gt;
          &lt;button class="btn btn-light btn-sm dropdown-toggle" data-toggle="dropdown" aria-expanded="false" type="button"&gt;filters&lt;/button&gt;            
      &lt;/div&gt;
    &lt;/div&gt;
  &lt;/div&gt;</code></pre>
  </div>
  </div>
  </p>
  
  <p>How to make this input group behave in that way? Or in another words, how do I access the icons from my input element in Scss?</p>