Skip to content

Commit

Permalink
modify
Browse files Browse the repository at this point in the history
  • Loading branch information
veasion committed Sep 26, 2024
1 parent daa9752 commit 44bfe8f
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions static/ppt2svg.js
Original file line number Diff line number Diff line change
Expand Up @@ -1635,6 +1635,7 @@ function Ppt2Svg(_svg, svgWidth, svgHeight) {
]
let div = document.createElement('div')
div.id = 'move_element_operate'
div.style.zIndex = 9999
div.style.position = 'fixed'
div.style.userSelect = 'none'
div.style.pointerEvents = 'none'
Expand Down Expand Up @@ -2059,8 +2060,8 @@ function Ppt2Svg(_svg, svgWidth, svgHeight) {
textarea.style.left = (rect.x + scrollX) + 'px'
textarea.style.top = (rect.y + scrollY) + 'px'
let textWordWrap = textObj.extInfo.property.textWordWrap ?? true
textarea.style.width = (textObj.point[2] || rect.width) + 'px'
textarea.style.height = (textObj.point[3] || rect.height) + 'px'
textarea.style.width = Math.max(scaleValue(textObj.point[2]) || rect.width, fontSize) + 'px'
textarea.style.height = Math.max(scaleValue(textObj.point[3]) || rect.height, fontSize) + 'px'
let rotation = (textObj.extInfo.property || {}).rotation
if (rotation) {
textarea.style.transformOrigin = 'center'
Expand Down Expand Up @@ -2154,6 +2155,11 @@ function Ppt2Svg(_svg, svgWidth, svgHeight) {
this.toColorValue = toColorValue
this.loadImage = loadImage
this.text = text
this.scaleValue = scaleValue
this.showPoint = showPoint
this.removePoint = removePoint
this.addElementMoveScale = addElementMoveScale
this.removeElementMoveScale = removeElementMoveScale

d3.addEventListener('document', 'mousemove', function(event) {
if (!pptx) {
Expand Down

0 comments on commit 44bfe8f

Please sign in to comment.