是否有要在DART / Angulardart Chrome Packaged App中使用的PDF查看器? [英] Is there a PDF viewer to be used in a DART/Angulardart Chrome Packaged App ?

查看:131
本文介绍了是否有要在DART / Angulardart Chrome Packaged App中使用的PDF查看器?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想在我的Chrome打包应用中找到一个合适的PDF查看器,以便简单地显示PDF网址(外部)/或文件(在创建外部网址的blob之后)。尝试各种东西,webview / sandbox页面和使用pdf.js。但没有运气到目前为止。我能够获得PDF显示与webview第一次,但不能动态更改webview的src;因为我相信有一个问题。是否有任何人在Chrome打包的应用程序/如何显示动态外部PDF网址?

I am trying to find a suitable PDF viewer to simply display PDF URLs ( external ) / or files ( after creating blobs to the external URLs) in my Chrome packaged app. Tried various things , webview/sandbox pages and using pdf.js. but no luck so far. I am able to get the PDF show up with the webview for the first time but not able to dynamically change the webview's src; as I believe there is an issue with that. Is there anyone displaying dynamic external PDF URLs in a chrome packaged app / how ?

推荐答案

我最终使用webview元素,使用chrome的默认查看器加载PDF,但如果我做display =none和display =block,它遇到CSP安全问题,所以我的工作围绕我移动PDF窗口可见,并更新src链接动态后回来。

I ended up using webview element which loads the PDF using chrome's default viewer, but if I do display ="none", and display ="block", it encounters CSP security issues, so as work around I move the PDF window out of visible and bring it back after updating the src link dynamically.

这篇关于是否有要在DART / Angulardart Chrome Packaged App中使用的PDF查看器?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆