pptxtojson 1.5.0 → 1.5.2
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 +15 -0
- package/dist/index.cjs +1 -1
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/dist/index.umd.js +1 -1
- package/dist/index.umd.js.map +1 -1
- package/package.json +1 -1
- package/src/shape.js +3 -4
package/package.json
CHANGED
package/src/shape.js
CHANGED
|
@@ -45,7 +45,7 @@ export function getCustomShapePath(custShapType, w, h) {
|
|
|
45
45
|
|
|
46
46
|
let moveToNode = getTextByPathList(pathNodes, ['a:moveTo'])
|
|
47
47
|
|
|
48
|
-
|
|
48
|
+
let lnToNodes = pathNodes['a:lnTo']
|
|
49
49
|
let cubicBezToNodes = pathNodes['a:cubicBezTo']
|
|
50
50
|
const arcToNodes = pathNodes['a:arcTo']
|
|
51
51
|
let closeNode = getTextByPathList(pathNodes, ['a:close'])
|
|
@@ -71,6 +71,7 @@ export function getCustomShapePath(custShapType, w, h) {
|
|
|
71
71
|
}
|
|
72
72
|
})
|
|
73
73
|
if (lnToNodes) {
|
|
74
|
+
if (!Array.isArray(lnToNodes)) lnToNodes = [lnToNodes]
|
|
74
75
|
Object.keys(lnToNodes).forEach(key => {
|
|
75
76
|
const lnToPtNode = lnToNodes[key]['a:pt']
|
|
76
77
|
if (lnToPtNode) {
|
|
@@ -91,9 +92,7 @@ export function getCustomShapePath(custShapType, w, h) {
|
|
|
91
92
|
}
|
|
92
93
|
if (cubicBezToNodes) {
|
|
93
94
|
const cubicBezToPtNodesAry = []
|
|
94
|
-
if (!Array.isArray(cubicBezToNodes))
|
|
95
|
-
cubicBezToNodes = [cubicBezToNodes]
|
|
96
|
-
}
|
|
95
|
+
if (!Array.isArray(cubicBezToNodes)) cubicBezToNodes = [cubicBezToNodes]
|
|
97
96
|
Object.keys(cubicBezToNodes).forEach(key => {
|
|
98
97
|
cubicBezToPtNodesAry.push(cubicBezToNodes[key]['a:pt'])
|
|
99
98
|
})
|