mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-12-16 22:50:13 +01:00
🎨 The heading block convert doc block to preserve symbols as much as possible https://github.com/siyuan-note/siyuan/issues/11126
This commit is contained in:
parent
3b17b1ccfd
commit
d432982f15
6 changed files with 14 additions and 6 deletions
|
|
@ -287,7 +287,10 @@ func Heading2Doc(srcHeadingID, targetBoxID, targetPath string) (srcRootBlockID,
|
|||
|
||||
box := Conf.Box(targetBoxID)
|
||||
headingText := getNodeRefText0(headingNode)
|
||||
headingText = util.FilterFileName(headingText)
|
||||
if strings.Contains(headingText, "/") {
|
||||
headingText = strings.ReplaceAll(headingText, "/", "_")
|
||||
util.PushMsg(Conf.language(246), 7000)
|
||||
}
|
||||
|
||||
moveToRoot := "/" == targetPath
|
||||
toHP := path.Join("/", headingText)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue