pptxtojson 1.2.2 → 1.3.0

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
@@ -161,10 +161,10 @@ document.querySelector('input').addEventListener('change', evt => {
161
161
  - 垂直坐标 `top`
162
162
  - 宽度 `width`
163
163
  - 高度 `height`
164
- - 边框颜色 `borderColor`
165
- - 边框宽度 `borderWidth`
166
- - 边框类型(实线、点线、虚线) `borderType`
164
+ - 边框(4边) `borders`
167
165
  - 表格数据 `data`
166
+ - 行高 `rowHeights`
167
+ - 列宽 `colWidths`
168
168
 
169
169
  ##### 图表
170
170
  - 类型 `type='chart'`
@@ -231,11 +231,4 @@ document.querySelector('input').addEventListener('change', evt => {
231
231
  > 与它们不同的是:PPTX2HTML 和 PPTXjs 是将PPT文件转换为能够运行的 HTML 页面,而 pptxtojson 做的是将PPT文件转换为干净的 JSON 数据,且在原有基础上进行了大量优化(包括代码质量和提取信息准确度)。
232
232
 
233
233
  # 📄 开源协议
234
- MIT License | Copyright © 2020-PRESENT [pipipi-pikachu](https://github.com/pipipi-pikachu)
235
-
236
- # ☕ 打赏
237
- 如果该项目帮到了您,还请您不吝打赏!
238
-
239
- <p align="left">
240
- <img src='/dist/wx.png' />
241
- </p>
234
+ MIT License | Copyright © 2020-PRESENT [pipipi-pikachu](https://github.com/pipipi-pikachu)
package/dist/index.d.ts CHANGED
@@ -32,6 +32,12 @@ export interface GradientFill {
32
32
 
33
33
  export type Fill = ColorFill | ImageFill | GradientFill
34
34
 
35
+ export interface Border {
36
+ borderColor: string
37
+ borderWidth: number
38
+ borderType:'solid' | 'dashed' | 'dotted'
39
+ }
40
+
35
41
  export interface Shape {
36
42
  type: 'shape'
37
43
  left: number
@@ -99,6 +105,12 @@ export interface TableCell {
99
105
  fillColor?: string
100
106
  fontColor?: string
101
107
  fontBold?: boolean
108
+ borders: {
109
+ top?: Border
110
+ bottom?: Border
111
+ left?: Border
112
+ right?: Border
113
+ }
102
114
  }
103
115
  export interface Table {
104
116
  type: 'table'
@@ -107,10 +119,15 @@ export interface Table {
107
119
  width: number
108
120
  height: number
109
121
  data: TableCell[][]
110
- borderColor: string
111
- borderWidth: number
112
- borderType: 'solid' | 'dashed' | 'dotted'
122
+ borders: {
123
+ top?: Border
124
+ bottom?: Border
125
+ left?: Border
126
+ right?: Border
127
+ }
113
128
  order: number
129
+ rowHeights: number[]
130
+ colWidths: number[]
114
131
  }
115
132
 
116
133
  export type ChartType = 'lineChart' |