askbot-dragon 1.4.38 → 1.4.40
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
package/public/index.html
CHANGED
|
@@ -33,12 +33,12 @@
|
|
|
33
33
|
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/pdf.js/3.5.141/pdf_viewer.min.css" integrity="sha512-Jf9DLkegLgARLR151csVkPvcVt4cOUhslrSZwiTAe9mqFL/BbYRDmxCOioCtbHifEgjsBFbrVhOMQ3mYPDLrqQ==" crossorigin="anonymous" referrerpolicy="no-referrer" /> -->
|
|
34
34
|
|
|
35
35
|
|
|
36
|
-
<script src="https://guoranopen-zjk.oss-cn-zhangjiakou.aliyuncs.com/cdn-common/pdfJS2.1.266/pdf.min.js"
|
|
37
|
-
<script src="https://guoranopen-zjk.oss-cn-zhangjiakou.aliyuncs.com/cdn-common/pdfJS2.1.266/pdf.worker.min.js"
|
|
38
|
-
<script src="https://guoranopen-zjk.oss-cn-zhangjiakou.aliyuncs.com/cdn-common/pdfJS2.1.266/pdf_viewer.js"
|
|
39
|
-
<link rel="stylesheet" href="https://guoranopen-zjk.oss-cn-zhangjiakou.aliyuncs.com/cdn-common/pdfJS2.1.266/pdf_viewer_01.css"
|
|
36
|
+
<script src="https://guoranopen-zjk.oss-cn-zhangjiakou.aliyuncs.com/cdn-common/pdfJS2.1.266/pdf.min.js" referrerpolicy="no-referrer"></script>
|
|
37
|
+
<script src="https://guoranopen-zjk.oss-cn-zhangjiakou.aliyuncs.com/cdn-common/pdfJS2.1.266/pdf.worker.min.js" referrerpolicy="no-referrer"></script>
|
|
38
|
+
<script src="https://guoranopen-zjk.oss-cn-zhangjiakou.aliyuncs.com/cdn-common/pdfJS2.1.266/pdf_viewer.js" referrerpolicy="no-referrer"></script>
|
|
39
|
+
<link rel="stylesheet" href="https://guoranopen-zjk.oss-cn-zhangjiakou.aliyuncs.com/cdn-common/pdfJS2.1.266/pdf_viewer_01.css" referrerpolicy="no-referrer" />
|
|
40
40
|
<!-- hammer.js -->
|
|
41
|
-
|
|
41
|
+
<script src="https://cdnjs.cloudflare.com/ajax/libs/hammer.js/2.0.8/hammer.min.js" integrity="sha512-UXumZrZNiOwnTcZSHLOfcTs0aos2MzBWHXOHOuB0J/R44QB0dwY5JgfbvljXcklVf65Gc4El6RjZ+lnwd2az2g==" crossorigin="anonymous" referrerpolicy="no-referrer"></script>
|
|
42
42
|
<style>
|
|
43
43
|
*{
|
|
44
44
|
margin: 0;
|
|
@@ -13,10 +13,10 @@
|
|
|
13
13
|
'onRadioClick',msg.id +'_' + index + '_' + option.value + '_' + option.name,option.name, msg.apiKey,msg.actionCategory, msg.msgId?msg.msgId:''
|
|
14
14
|
)">
|
|
15
15
|
|
|
16
|
-
<el-tooltip class="item" effect="dark" :content="option.name" placement="bottom-start" v-if="!isMobile">
|
|
17
|
-
<span
|
|
18
|
-
</el-tooltip>
|
|
19
|
-
<span
|
|
16
|
+
<!-- <el-tooltip class="item" effect="dark" :content="option.name" placement="bottom-start" v-if="!isMobile">
|
|
17
|
+
<span > {{ option.name }}</span>
|
|
18
|
+
</el-tooltip> -->
|
|
19
|
+
<span> {{ option.name }}</span>
|
|
20
20
|
<i class="arsenal_icon arsenalangle-right-solid"></i>
|
|
21
21
|
</div>
|
|
22
22
|
</div>
|
|
@@ -72,7 +72,7 @@ export default {
|
|
|
72
72
|
/* padding-top: 10px;*/
|
|
73
73
|
/*padding-right: 10px;*/
|
|
74
74
|
.options-item{
|
|
75
|
-
height: 25px;
|
|
75
|
+
// height: 25px;
|
|
76
76
|
line-height: 25px;
|
|
77
77
|
background-color: #ffffff;
|
|
78
78
|
color: #366aff;
|
|
@@ -305,9 +305,12 @@ export default {
|
|
|
305
305
|
if(this.transformSalce !== null) {
|
|
306
306
|
startNum = Math.ceil(this.$refs.pdfView.scrollTop / ((this.pageSize.height + this.PAGE_INTVERVAL) * this.transformSalce))
|
|
307
307
|
endNum = startNum + Math.ceil(height / ((this.pageSize.height + this.PAGE_INTVERVAL) * this.transformSalce))
|
|
308
|
+
console.log( Math.ceil(height / ((this.pageSize.height + this.PAGE_INTVERVAL) * this.transformSalce)),this.pageSize.height , this.PAGE_INTVERVAL, height, this.transformSalce,'startNum');
|
|
309
|
+
|
|
308
310
|
} else {
|
|
309
311
|
startNum = Math.ceil(this.$refs.pdfView.scrollTop / (this.pageSize.height + this.PAGE_INTVERVAL))
|
|
310
312
|
endNum = startNum + Math.ceil(height / (this.pageSize.height + this.PAGE_INTVERVAL))
|
|
313
|
+
|
|
311
314
|
}
|
|
312
315
|
for (let pageIndex = startNum; pageIndex <= endNum; pageIndex++) {
|
|
313
316
|
if(pageIndex > 0 && pageIndex <= this.pages.length) {
|
|
@@ -351,6 +354,7 @@ export default {
|
|
|
351
354
|
that.loadPdfData(pageIndex)
|
|
352
355
|
}
|
|
353
356
|
}
|
|
357
|
+
console.log('=======');
|
|
354
358
|
}, 200),
|
|
355
359
|
directScrolling (e, that) {
|
|
356
360
|
if (this.fisrtLoad) {
|
|
@@ -386,12 +390,12 @@ export default {
|
|
|
386
390
|
let j = pageIndex + 1;
|
|
387
391
|
// pageIndex - 1 表示当前页码数 对应的下标位置
|
|
388
392
|
pagesToRender.push(this.pages[pageIndex - 1]);
|
|
389
|
-
while (pagesToRender.length <
|
|
393
|
+
while (pagesToRender.length < 8 && pagesToRender.length < this.pages.length) {
|
|
390
394
|
if (i > 0) {
|
|
391
395
|
pagesToRender.push(this.pages[i - 1]);
|
|
392
396
|
i -= 1;
|
|
393
397
|
}
|
|
394
|
-
if (pagesToRender.length >=
|
|
398
|
+
if (pagesToRender.length >= 8) {
|
|
395
399
|
break;
|
|
396
400
|
}
|
|
397
401
|
if (j <= this.pages.length) {
|
|
@@ -51,29 +51,31 @@
|
|
|
51
51
|
<i class="iconfont guoran-shanchu"></i>
|
|
52
52
|
</section>
|
|
53
53
|
</div>
|
|
54
|
-
<
|
|
55
|
-
<
|
|
56
|
-
|
|
57
|
-
<template v-else>
|
|
58
|
-
<div v-if="fileType == 'VIDEO'" style="width: 100%;height:calc(100% - 60px)">
|
|
59
|
-
<video :src="url" controls width="100%;" height="98%"></video>
|
|
60
|
-
</div>
|
|
61
|
-
<div v-else-if="fileType == 'HTML'" style="width: 100%;height:calc(100% - 60px)">
|
|
62
|
-
<div class="preview_iframe_html" style="text-algin:left" v-html="fileText"></div>
|
|
63
|
-
</div>
|
|
64
|
-
<template v-else-if="url.includes('https://www') || url.includes('http://www')">
|
|
65
|
-
<iframe class="preview_iframe"
|
|
66
|
-
:src="url"
|
|
67
|
-
width="100%"
|
|
68
|
-
height="100%"
|
|
69
|
-
scrolling="100%"
|
|
70
|
-
frameborder="no"
|
|
71
|
-
border="0"></iframe>
|
|
54
|
+
<div id="drawer_content_pre">
|
|
55
|
+
<template v-if="tagIds && tagIds.length != 0 && drawer">
|
|
56
|
+
<pdfPosition :tagIds="tagIds" :isMessageRecord="isMessageRecord"></pdfPosition>
|
|
72
57
|
</template>
|
|
73
58
|
<template v-else>
|
|
74
|
-
<
|
|
59
|
+
<div v-if="fileType == 'VIDEO'" style="width: 100%;height:calc(100% - 60px)">
|
|
60
|
+
<video :src="url" controls width="100%;" height="98%"></video>
|
|
61
|
+
</div>
|
|
62
|
+
<div v-else-if="fileType == 'HTML'" style="width: 100%;height:calc(100% - 60px)">
|
|
63
|
+
<div class="preview_iframe_html" style="text-algin:left" v-html="fileText"></div>
|
|
64
|
+
</div>
|
|
65
|
+
<template v-else-if="url.includes('https://www') || url.includes('http://www')">
|
|
66
|
+
<iframe class="preview_iframe"
|
|
67
|
+
:src="url"
|
|
68
|
+
width="100%"
|
|
69
|
+
height="100%"
|
|
70
|
+
scrolling="100%"
|
|
71
|
+
frameborder="no"
|
|
72
|
+
border="0"></iframe>
|
|
73
|
+
</template>
|
|
74
|
+
<template v-else>
|
|
75
|
+
<iframe class="preview_iframe" :src="previewUrl" style="border:none;"></iframe>
|
|
76
|
+
</template>
|
|
75
77
|
</template>
|
|
76
|
-
</
|
|
78
|
+
</div>
|
|
77
79
|
<div class="loading_img" v-show="loading">
|
|
78
80
|
<img src="https://guoranopen-zjk.oss-cn-zhangjiakou.aliyuncs.com/cdn-common/images/loading.gif" alt="">
|
|
79
81
|
</div>
|
|
@@ -82,6 +84,7 @@
|
|
|
82
84
|
|
|
83
85
|
<script>
|
|
84
86
|
import pdfPosition from './pdfPosition.vue'
|
|
87
|
+
// import { zoomElement } from '../assets/js/hammer'
|
|
85
88
|
export default {
|
|
86
89
|
data () {
|
|
87
90
|
return {
|
|
@@ -96,7 +99,7 @@ export default {
|
|
|
96
99
|
}
|
|
97
100
|
},
|
|
98
101
|
mounted() {
|
|
99
|
-
|
|
102
|
+
// zoomElement(document.getElementById('drawer_content_pre'))
|
|
100
103
|
},
|
|
101
104
|
props:{
|
|
102
105
|
url:{
|
|
@@ -256,4 +259,7 @@ export default {
|
|
|
256
259
|
/deep/.el-drawer__body{
|
|
257
260
|
height: 100%;
|
|
258
261
|
}
|
|
262
|
+
#drawer_content_pre {
|
|
263
|
+
height: 100%;
|
|
264
|
+
}
|
|
259
265
|
</style>
|