@work-zhanguo/light-file-preview 0.0.15 → 0.0.17

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 CHANGED
@@ -10,6 +10,8 @@
10
10
  <a href="https://gitee.com/hou_zhan_guo/light-file-preview" target="_blank" rel="noreferrer">Gitee</a>
11
11
  ·
12
12
  <a href="https://www.npmjs.com/package/@work-zhanguo/light-file-preview" target="_blank" rel="noreferrer">npm</a>
13
+ ·
14
+ <a href="http://49.234.120.202:9990/" target="_blank" rel="noreferrer">在线演示 Demo</a>
13
15
  </p>
14
16
 
15
17
  <p align="center">
@@ -23,12 +25,15 @@
23
25
 
24
26
  ## 项目简介
25
27
 
26
- - 当前版本:`0.0.15`
28
+ - 当前版本:`0.0.17`
27
29
  - 适用场景:业务系统附件预览、在线查看、弹窗预览、新页面预览
28
30
  - 支持 Vue 3、Vue 2 适配入口,以及非 Vue 项目的 standalone 产物
31
+ - 在线演示:可通过顶部 `在线演示 Demo` 入口访问
29
32
 
30
33
  最近更新:
31
34
 
35
+ - `0.0.17`:补全 `PPTX` 在线预览能力,接入 `@work-zhanguo/pptx-preview`,同步更新演示文件与项目文档
36
+ - `0.0.16`:修复 `style.css` 引入后污染业务全局样式的问题,组件样式已收敛到 `.lfp-*` 作用域
32
37
  - `0.0.15`:新增 npm `README.md` 的中英文双版本折叠切换展示,同步调整包描述与文档版本信息
33
38
  - `0.0.14`:优化 `xlsx` 空白区域填充,移除未声明的表头/首列固定效果,并为 `PDF`、`DOCX` 增加默认分页与全部展示切换
34
39
  - `0.0.13`:修复弹窗失败后同文件无法重试、运行时配置更新不生效的问题,补充 README 示例图与发包说明
@@ -54,11 +59,11 @@
54
59
 
55
60
  ![PDF 预览效果](https://unpkg.com/@work-zhanguo/light-file-preview/public/screenshots/effect-pdf.png)
56
61
 
57
- ### PPTX 降级展示
62
+ ### PPTX
58
63
 
59
- 当前 `PPT` / `PPTX` 不做在线解析,组件会保留下载入口,不会伪装成已支持的在线预览。
64
+ `PPTX` 现已支持在线预览,适合业务系统里常见的汇报、方案、说明类演示文稿查看。旧版 `PPT` 仍保持下载入口降级。
60
65
 
61
- ![PPTX 降级效果](https://unpkg.com/@work-zhanguo/light-file-preview/public/screenshots/effect-pptx.png)
66
+ ![PPTX 预览效果](https://unpkg.com/@work-zhanguo/light-file-preview/public/screenshots/effect-pptx.png)
62
67
 
63
68
  ## 支持文件
64
69
 
@@ -82,6 +87,7 @@
82
87
  - `CSS`
83
88
  - `MD`
84
89
  - `DOCX`
90
+ - `PPTX`
85
91
  - `XLS`
86
92
  - `XLSX`
87
93
  - `CSV`
@@ -94,7 +100,6 @@
94
100
 
95
101
  - `DOC`
96
102
  - `PPT`
97
- - `PPTX`
98
103
  - 其他未识别格式
99
104
 
100
105
  补充说明:
@@ -107,6 +112,7 @@
107
112
 
108
113
  - [pdf.js](https://github.com/mozilla/pdf.js)
109
114
  - [docx-preview](https://github.com/VolodymyrBaydalka/docxjs)
115
+ - [@work-zhanguo/pptx-preview](https://www.npmjs.com/package/@work-zhanguo/pptx-preview)
110
116
  - [SheetJS](https://github.com/SheetJS/sheetjs)
111
117
  - [marked](https://github.com/markedjs/marked)
112
118
  - [DOMPurify](https://github.com/cure53/DOMPurify)
@@ -291,12 +297,15 @@ npm run build:site
291
297
 
292
298
  ## Overview
293
299
 
294
- - Current version: `0.0.15`
300
+ - Current version: `0.0.17`
295
301
  - Use cases: attachment preview in business systems, inline viewing, dialog preview, and standalone preview pages
296
302
  - Supports Vue 3, a Vue 2 adapter entry, and standalone assets for non-Vue projects
303
+ - Demo: available through the `在线演示 Demo` link at the top of this document
297
304
 
298
305
  Recent updates:
299
306
 
307
+ - `0.0.17`: added online `PPTX` preview through `@work-zhanguo/pptx-preview`, and synchronized the demo file and project documentation
308
+ - `0.0.16`: fixed global style leakage caused by importing `style.css`, and scoped published component styles to `.lfp-*` rules only
300
309
  - `0.0.15`: rewrote `README.md` for npm with collapsible Chinese and English sections, and synchronized package description and documentation version info
301
310
  - `0.0.14`: optimized blank area handling in `xlsx`, removed undeclared frozen header/column behavior, and added paged/all display switching for `PDF` and `DOCX`
302
311
  - `0.0.13`: fixed retry behavior after preview failures in dialog mode, refreshed README examples, and clarified packaging details
@@ -322,11 +331,11 @@ The images below use the npm CDN URL. Local repository changes do not affect the
322
331
 
323
332
  ![PDF preview](https://unpkg.com/@work-zhanguo/light-file-preview/public/screenshots/effect-pdf.png)
324
333
 
325
- ### PPTX fallback
334
+ ### PPTX
326
335
 
327
- `PPT` / `PPTX` files are intentionally not parsed as online previews for now. The component keeps a download entry instead of pretending the format is fully supported.
336
+ `PPTX` files are now supported for online preview, which fits common slide decks used in business systems. Legacy `PPT` files still fall back to a download entry.
328
337
 
329
- ![PPTX fallback](https://unpkg.com/@work-zhanguo/light-file-preview/public/screenshots/effect-pptx.png)
338
+ ![PPTX preview](https://unpkg.com/@work-zhanguo/light-file-preview/public/screenshots/effect-pptx.png)
330
339
 
331
340
  ## Supported Files
332
341
 
@@ -350,6 +359,7 @@ Supported for online preview:
350
359
  - `CSS`
351
360
  - `MD`
352
361
  - `DOCX`
362
+ - `PPTX`
353
363
  - `XLS`
354
364
  - `XLSX`
355
365
  - `CSV`
@@ -362,7 +372,6 @@ Fallback to download entry:
362
372
 
363
373
  - `DOC`
364
374
  - `PPT`
365
- - `PPTX`
366
375
  - any unrecognized format
367
376
 
368
377
  Notes:
@@ -375,6 +384,7 @@ Notes:
375
384
 
376
385
  - [pdf.js](https://github.com/mozilla/pdf.js)
377
386
  - [docx-preview](https://github.com/VolodymyrBaydalka/docxjs)
387
+ - [@work-zhanguo/pptx-preview](https://www.npmjs.com/package/@work-zhanguo/pptx-preview)
378
388
  - [SheetJS](https://github.com/SheetJS/sheetjs)
379
389
  - [marked](https://github.com/markedjs/marked)
380
390
  - [DOMPurify](https://github.com/cure53/DOMPurify)