title: How to change height of the map element on button click?
body: <p>I want to remove the styling  back and forth on button click  but when i try to resize now the map is  rendering all over the screen but without any background, only the markers that were on it.</p>
  
  <p>So basically i want to remove the styling and hide the list element and only display the map element on one click and on the next one to display again the list and to resize the map  how it was initially.</p>
  
  <p>any ideas ? </p>
  
  <pre><code>**Updated**
  
    **aura component** 
  
  &lt;aura:component &gt;
  &lt;aura:attribute name="map" type="Object"/&gt;
  &lt;aura:attribute name="buttonstate" type="Boolean" default="false"/&gt;
  
  &lt;div aura:id= "screen"&gt;        
   &lt;div id="map" aura:id="mapSize" class="mapSize" style="position:relative;"&gt;   
          &lt;lightning:button class="button" aura:id="buttonList" label="Button" onclick="{!c.handleClick}" /&gt;
   &lt;/div&gt;
  &lt;/div&gt;
     &lt;div  aura:id="listDiv" class ="listDiv"&gt;
     &lt;c:List  /&gt;
      &lt;/div&gt;        
    &lt;/div&gt;       
  &lt;/aura:component&gt;
  
  **CSS**
  
     .cAccountMap .mapSize{
     width: 100%;
     height: 80%; 
  }
  
  .cAccountMap .mapTestSize{
      height: 100%;
  }
  
  
  .THIS .listDiv{
   height: 20%;
  }
  
  }
  
  **Javascript** 
  
     handleClick : function(component,event,helper){
        var buttonName = event.getSource();
        var elements = document.getElementsByClassName("listDiv");
       var buttonstate = component.get('v.buttonstate');
      var cmpTarget = component.find('mapSize');
      if(buttonstate==false){
          buttonName.set('v.label', 'LALA');
          elements[0].style.display = 'none';
          $A.util.removeClass(cmpTarget, 'mapSize');
          $A.util.addClass(cmpTarget, 'mapTestSize');      
      }else{
          buttonName.set('v.label', 'gogo');
          elements[0].style.display = '';
          $A.util.addClass(cmpTarget, 'mapSize');
  
          $A.util.removeClass(cmpTarget, 'mapTestSize');  
      }
      component.set('v.buttonstate', !buttonstate);
  
  }
  </code></pre>