Issue
We are developing a plugin.
Immediately after resizing Artboard, globalDrawBounds value of the padding group is not correct.
Steps to reproduce
Created sample.
PaddingBox
- Size:200x80
- Responsive Resize Fix: top bottom left right
- Padding: Same padding for all edges.
Plugin code.
Selected node resize and children height size log output.
async function resizeArtboard(selection, root) {
let node = selection.items[0]
const bounds = node.globalBounds
node.resize(bounds.width + 100, bounds.height + 100)
node.children.forEach(child=>{
const bounds = child.globalBounds
const drawBounds = child.globalDrawBounds
console.log(`${child.name}: ${bounds.height} ${drawBounds.height}`)
})
}
- Select artboard.
- Run plugin.
- check Developer Console.
- console output: “PaddingBox: 180 166”
Expected Behavior
output: “PaddingBox: 180 180”
Actual Behavior
console output: “PaddingBox: 180 166”,
Presumably, the output value was not added the padding size.
Additional Information
When padding off, got the right result.