Size on small screens too small

Home Forums Easy FancyBox Pro Size on small screens too small

Tagged: , ,

This topic contains 2 replies, has 2 voices, and was last updated by  subhash 2 years ago.

  • Author
    Posts
  • #5053

    subhash
    Participant

    Another problem on small screens, tested with an actual iPhone and an old iPod Touch:

    The image doesn’t open as large as possible but shows rather small in a broder white box. When closing the image becomes bigger for a very short time. For example:

    http://fineart-fotografie.at/architectures-of-moedling/

  • #5095

    RavanH
    Keymaster

    Hi subhash,

    In the next release, there will be an option to disable FancyBox for small screen sizes. Until then, you could add the following script snippet to your sites footer.php (must come before the usual <?php wp_footer(); ?> there!) or in a Text widget:

    
    <script type="text/javascript">
    var pixelRatio = window.devicePixelRatio || 1;
    if(window.innerWidth/pixelRatio < 641 ) {
      easy_fancybox_handler = null;
    };
    </script>
    

    Note that the value 641 is an example for a max 641px wide screen size. It can be changed to anything you prefer 🙂

  • #5122

    subhash
    Participant

    Thank you very much!
    (I was not notified of your advice so it took long to see it.)

You must be logged in to reply to this topic.