@koi-br/ocr-web-sdk 1.0.13 → 1.0.15
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/README.md +2 -0
- package/dist/index-5IMQOcsf.js +215 -0
- package/dist/index-CN8cqjVg.mjs +44886 -0
- package/dist/index.cjs.js +2 -202
- package/dist/index.esm.js +11 -44802
- package/dist/src/index.d.ts +2 -0
- package/dist/tiff.min-C3LBZ-yg.js +6 -0
- package/dist/tiff.min-Dzh69tcl.mjs +195485 -0
- package/package.json +2 -1
- package/preview/ofdPreview.vue +1 -26
- package/preview/tifPreview.vue +447 -363
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@koi-br/ocr-web-sdk",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.15",
|
|
4
4
|
"description": "一个支持多种Office文件格式预览的Vue3组件SDK,包括PDF、Word、Excel、图片、OFD、TIF等格式",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"module": "dist/index.esm.js",
|
|
@@ -46,6 +46,7 @@
|
|
|
46
46
|
"docx-preview": "^0.1.12",
|
|
47
47
|
"lucide-vue-next": "^0.344.0",
|
|
48
48
|
"pdfjs-dist": "^3.11.174",
|
|
49
|
+
"tiff.js": "^1.0.0",
|
|
49
50
|
"vue": "^3.0.0"
|
|
50
51
|
},
|
|
51
52
|
"devDependencies": {
|
package/preview/ofdPreview.vue
CHANGED
|
@@ -1,23 +1,6 @@
|
|
|
1
1
|
<template>
|
|
2
2
|
<div class="preview-container">
|
|
3
3
|
<!-- 工具栏 -->
|
|
4
|
-
<div class="preview-toolbar preview-toolbar-right" v-if="isDownload">
|
|
5
|
-
<div class="toolbar-group">
|
|
6
|
-
<ATooltip
|
|
7
|
-
mini
|
|
8
|
-
position="bottom"
|
|
9
|
-
content="下载"
|
|
10
|
-
>
|
|
11
|
-
<AButton
|
|
12
|
-
size="small"
|
|
13
|
-
type="outline"
|
|
14
|
-
@click="emit('download')"
|
|
15
|
-
>
|
|
16
|
-
<Download :size="16" />
|
|
17
|
-
</AButton>
|
|
18
|
-
</ATooltip>
|
|
19
|
-
</div>
|
|
20
|
-
</div>
|
|
21
4
|
<OfdView
|
|
22
5
|
:show-open-file-button="false"
|
|
23
6
|
:ofd-link="props.url"
|
|
@@ -31,17 +14,12 @@
|
|
|
31
14
|
import { ref, watch, onMounted } from 'vue';
|
|
32
15
|
import { OfdView } from 'bestofdview';
|
|
33
16
|
import 'bestofdview/dist/style.css';
|
|
34
|
-
import { Message
|
|
35
|
-
import { Download } from 'lucide-vue-next';
|
|
17
|
+
import { Message } from '@arco-design/web-vue';
|
|
36
18
|
|
|
37
19
|
const props = defineProps({
|
|
38
20
|
url: {
|
|
39
21
|
type: String,
|
|
40
22
|
required: true
|
|
41
|
-
},
|
|
42
|
-
isDownload: {
|
|
43
|
-
type: Boolean,
|
|
44
|
-
default: false
|
|
45
23
|
}
|
|
46
24
|
});
|
|
47
25
|
|
|
@@ -102,6 +80,3 @@ defineExpose({
|
|
|
102
80
|
});
|
|
103
81
|
</script>
|
|
104
82
|
|
|
105
|
-
<style lang="less" scoped>
|
|
106
|
-
// 样式已统一到公共样式文件,这里只保留组件特定样式
|
|
107
|
-
</style>
|