Add alias: /toc and /ol (#2161)

This commit is contained in:
Peter Tripp
2026-05-08 01:20:27 +01:00
committed by GitHub
parent ec51ca7815
commit c9fa6e20b3
@@ -132,7 +132,7 @@ const CommandGroups: SlashMenuGroupedItemsType = {
{ {
title: "Numbered list", title: "Numbered list",
description: "Create a list with numbering.", description: "Create a list with numbering.",
searchTerms: ["numbered", "ordered", "list"], searchTerms: ["numbered", "ordered", "list", "ol"],
icon: IconListNumbers, icon: IconListNumbers,
command: ({ editor, range }: CommandProps) => { command: ({ editor, range }: CommandProps) => {
editor.chain().focus().deleteRange(range).toggleOrderedList().run(); editor.chain().focus().deleteRange(range).toggleOrderedList().run();
@@ -471,7 +471,14 @@ const CommandGroups: SlashMenuGroupedItemsType = {
{ {
title: "Subpages (Child pages)", title: "Subpages (Child pages)",
description: "List all subpages of the current page", description: "List all subpages of the current page",
searchTerms: ["subpages", "child", "children", "nested", "hierarchy"], searchTerms: [
"subpages",
"child",
"children",
"nested",
"hierarchy",
"toc",
],
icon: IconSitemap, icon: IconSitemap,
command: ({ editor, range }: CommandProps) => { command: ({ editor, range }: CommandProps) => {
editor.chain().focus().deleteRange(range).insertSubpages().run(); editor.chain().focus().deleteRange(range).insertSubpages().run();