Crash on iPhone on zoom
I'm using the Embed SDK to display a pdf on a page using the IN_LINE embed mode. Everything works ok until I pinch to zoom on iPhone (Safari and Chrome) at which point the page crashes. I've tried hooking into the developer console, but I don't get any perceptible changes before the crash.
Steps to reproduce the behavior:
- Go to http://staugustinesvancouver.com/solids on an iPhone
- Pinch to zoom
- Observe crash
A clear and concise description of what you expected to happen.
- no crash, just zoom
Smartphone (please complete the following information):
- Device: iPhone 14 Pro Max
- OS: iOS 16.3.1
- Browser: Safari
Here's how the document load is triggered initially
<script type="text/javascript">
document.addEventListener("adobe_dc_view_sdk.ready", function(){
switchDocument($('#dinnerMenu'));
});
</script>
And the relevant Embed API code
function switchDocument(parentDiv){
var adobeDCView = new AdobeDC.View({clientId: <ID>, divId: 'dinnerMenu'});
adobeDCView.previewFile({
content:{location: {url: parentDiv.data('pdf-path')}},
metaData:{fileName: parentDiv.data('pdf-filename')}
},
{
embedMode: "IN_LINE", defaultViewMode: "FIT_PAGE"
});
};
