fix(core): prevent overwriting size in node styles object (#1608)
* fix(core): prevent overwriting size in node styles object Signed-off-by: braks <78412429+bcakmakoglu@users.noreply.github.com> * fix(core): update node styles if `updateStyles` is `true` Signed-off-by: braks <78412429+bcakmakoglu@users.noreply.github.com> * chore(core): update pkg json links Signed-off-by: braks <78412429+bcakmakoglu@users.noreply.github.com> * chore(changeset): add Signed-off-by: braks <78412429+bcakmakoglu@users.noreply.github.com> --------- Signed-off-by: braks <78412429+bcakmakoglu@users.noreply.github.com>
This commit is contained in:
@@ -142,11 +142,11 @@ const NodeWrapper = defineComponent({
|
||||
const width = node.width instanceof Function ? node.width(node) : node.width
|
||||
const height = node.height instanceof Function ? node.height(node) : node.height
|
||||
|
||||
if (width) {
|
||||
if (!styles.width && width) {
|
||||
styles.width = typeof width === 'string' ? width : `${width}px`
|
||||
}
|
||||
|
||||
if (height) {
|
||||
if (!styles.height && height) {
|
||||
styles.height = typeof height === 'string' ? height : `${height}px`
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user