mirror of
https://github.com/pipipi-pikachu/PPTist.git
synced 2025-04-15 02:20:00 +08:00
fix: prop error
This commit is contained in:
parent
f2b25336f4
commit
6739bbff6f
@ -267,9 +267,9 @@ export default () => {
|
||||
element.viewBox = [el.width, el.height]
|
||||
|
||||
const pathFormula = SHAPE_PATH_FORMULAS[shape.pathFormula]
|
||||
if ('editable' in pathFormula) {
|
||||
if ('editable' in pathFormula && pathFormula.editable) {
|
||||
element.path = pathFormula.formula(el.width, el.height, pathFormula.defaultValue)
|
||||
element.keypoint = pathFormula.defaultValue
|
||||
element.keypoints = pathFormula.defaultValue
|
||||
}
|
||||
else element.path = pathFormula.formula(el.width, el.height)
|
||||
}
|
||||
|
@ -188,7 +188,7 @@ const updateShapePathData = (width: number, height: number) => {
|
||||
const pathFormula = SHAPE_PATH_FORMULAS[handleElement.value.pathFormula]
|
||||
|
||||
let path = ''
|
||||
if ('editable' in pathFormula) path = pathFormula.formula(width, height, handleElement.value.keypoint!)
|
||||
if ('editable' in pathFormula && pathFormula.editable) path = pathFormula.formula(width, height, handleElement.value.keypoints!)
|
||||
else path = pathFormula.formula(width, height)
|
||||
|
||||
return {
|
||||
|
Loading…
x
Reference in New Issue
Block a user