mirror of
https://github.com/wanglin2/mind-map.git
synced 2026-02-21 10:27:44 +08:00
Fix:修复safari浏览器节点存在图标时文字位置错位的问题
This commit is contained in:
parent
f087b7102e
commit
794d3e9a53
@ -360,7 +360,8 @@ class Node {
|
||||
// 文字
|
||||
if (this._textData) {
|
||||
this._textData.node.attr('data-offsetx', textContentOffsetX)
|
||||
this._textData.node.x(textContentOffsetX).y(0)
|
||||
// 修复safari浏览器节点存在图标时文字位置不正确的问题
|
||||
;(this._textData.nodeContent || this._textData.node).x(textContentOffsetX).y(0)
|
||||
textContentNested.add(this._textData.node)
|
||||
textContentOffsetX += this._textData.width + textContentItemMargin
|
||||
}
|
||||
|
||||
@ -170,6 +170,7 @@ function createRichTextNode() {
|
||||
g.add(foreignObject)
|
||||
return {
|
||||
node: g,
|
||||
nodeContent: foreignObject,
|
||||
width,
|
||||
height
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user