title: How the make PDF fit the height - ng2-pdf-viewer
body: <p>I am using <code>ng2-pdf-viewer</code> in my Angular 8 application. </p>
  
  <p>I would like to show the PDF fit to the height of the container regardless of the width. So, PDF must take all of the height as we can do by selecting <code>Page Fit</code> from the zoom option in Mozilla's PDF (link <a href="https://mozilla.github.io/pdf.js/web/viewer.html" rel="noreferrer">here</a>):</p>
  
  <p><a href="https://i.stack.imgur.com/XweAQ.png" rel="noreferrer"><img src="https://i.stack.imgur.com/XweAQ.png" alt="example of required situation"></a></p>
  
  <p>Here is what I have got right now:
  <a href="https://i.stack.imgur.com/tQN1u.png" rel="noreferrer"><img src="https://i.stack.imgur.com/tQN1u.png" alt="enter image description here"></a></p>
  
  <p>My code for <code>ng2-pdf-viewer</code> is:</p>
  
  <pre><code>            &lt;pdf-viewer
              [src]='"./assets/images/userFiles/" + file.fileName'
              [original-size]="false"
              [render-text]='false'
              [show-all]="false"
              style="display: block; height: 100%;"
              (after-load-complete)='afterLoadComplete($event)'
              (page-rendered)='pageRendered($event)'
              (pageChange)='pageChange($event)'
  
              &gt;&lt;/pdf-viewer&gt;
  </code></pre>
  
  <p>I have tried countless things for days to get this working. <code>fit-to-page</code>, giving <code>height</code> to all of the containers and much more.</p>
  
  <p>Let me know, what is the best way to get it done</p>