malele81 downloadsPromote or demote heading levels together with all sub-headings at once, like Typora.
Promote or demote heading levels together with all sub-headings at once, similar to Typora's behavior when shifting an entire section's hierarchy.
# from the heading (H1 → plain text)# to the heading (H6 stays H6)Before (cursor on ## Section A):
# Document
## Section A
### Sub A1
some text
## Section B
After promote → ## Section A and its child ### Sub A1 both shift up:
# Document
# Section A
## Sub A1
some text
## Section B
Note: Sibling ## Section B is unaffected. The sub-tree scope ends at the next heading with level ≤ the root.
| Action | Shortcut | Command Name |
|---|---|---|
| Promote (with sub-headings) | Ctrl+Shift+= |
Promote heading (with sub-headings) |
| Demote (with sub-headings) | Ctrl+Shift+- |
Demote heading (with sub-headings) |
heading)Ctrl+P)From Community Plugins:
Manual:
main.js and manifest.json<your vault>/.obsidian/plugins/heading-shift/MIT
一键整体提升 / 降低标题一级(连同其下方所有子标题一起),复刻 Typora 里把一个章节整段挪层级的行为。
# 减少(H1 再提升 → 变普通段落)# 增加(H6 再降低 → 保持 H6,不越界)``` / ~~~)内部的 # 行提升前(光标在 ## 二级 A 上):
# 文档
## 二级 A
### 三级 A1
some text
## 二级 B
提升后 → ## 二级 A 及其子标题 ### 三级 A1 同步提升:
# 文档
# 二级 A
## 三级 A1
some text
## 二级 B
注意:同级兄弟 ## 二级 B 不受影响,子树范围到「下一个同级或更高级标题」为止。
| 操作 | 快捷键 | 命令名 |
|---|---|---|
| 提升一级(含子标题) | Ctrl+Shift+= |
Promote heading (with sub-headings) |
| 降低一级(含子标题) | Ctrl+Shift+- |
Demote heading (with sub-headings) |
heading 自行改键Ctrl+P)触发从社区插件市场:
手动安装:
main.js 和 manifest.json<你的 vault>/.obsidian/plugins/heading-shift/# 行;若不在标题行上,回退到上方最近的标题MIT