Skip to main content
Participant
January 30, 2023
Question

New PDF Embed API: prevent fullscreen prompt for sized containers on mobile

  • January 30, 2023
  • 1 reply
  • 1460 views

Hi,

 

I just transitioned from the legacy Embed API to the new modern PDF viewer on my educational website. I use the API to display a pdf in SIZED_CONTAINER mode but otherwise control all aspects of navigation myself as the PDF is a background for a complex interactive educational module with many other overlying HTML elements. 

 

In the legacy API, this worked very well. However, with the modern API, on mobile, there is an automatic prompt in the center of the PDF element to enter fullscreen which is undesirable since my users can't interact with the PDF element directly. Is there any way to disable this automatic prompt or add an option to disable this? Setting the showFullScreen configuration to false does not prevent the prompt in mobile, just removes the fullscreen button from the bottom toolbar.

 

Thank you

    This topic has been closed for replies.

    1 reply

    Raymond Camden
    Community Manager
    Community Manager
    January 30, 2023

    I did a quick test using our online demo (https://documentcloud.adobe.com/view-sdk-demo/index.html#/view/SIZED_CONTAINER/Bodea%20Brochure.pdf) and devtools to emulate an iPhone and I wasn't able to reproduce this. Can you share the URL to your site so I can see?

    Participant
    January 30, 2023

    Thank you for the reply. I can actually see the issue in the online demo you provided as well. You can use this link to see my website usage in action: edneurorad.com/spinal-cord-lesions/. This works fine in desktop/tablet mode and even if you start the webpage in desktop mode and then emulate a phone using devtools. It only occurs if you actually use a phone to load the page (but I can replicate the issue if I emulate a phone in devtools and then reload the page). See snapshot below, notice the fullscreen button forced in the middle of the screen which is the pdf element (all other buttons are my own custom controls for the educational module):