<web-view v-if='url != "" && isShowPdf' :src="url"
style="width: 100%;height: 1500px;margin: 20px 0px;"></web-view>
viewerUrl: '/hybrid/html/web/viewer.html',
// 判断是手机系统:安卓,使用pdf.js
// #ifdef APP-PLUS
var pdfUrl = "@/../../../../static/pdf/test.pdf";
if (plus.os.name === 'Android') {
this.url = `${this.viewerUrl}?file=${encodeURIComponent(pdfUrl)}`;
}
// ios,直接访问pdf所在路径
else {
this.url = encodeURIComponent(pdfUrl);
}
console.log(this.url)
this.$nextTick(() => {
this.countDownStart = true;
this.isShowPdf = true;
});
// #endif
关键代码如上,在nvue页面查看pdf无法向下滑动。。。高度被定的高度卡死了,,,,overflow也没用。。。就是没有滑动条
结果如附件
感觉是bug啊,来个uni的工作人员啊!!!