mirror of
https://github.com/zadam/trilium.git
synced 2025-10-20 07:08:55 +02:00
feat(command_palette): sort commands by name
This commit is contained in:
parent
18d11523a6
commit
de8b7e9ebe
@ -169,7 +169,12 @@ class CommandRegistry {
|
||||
}
|
||||
|
||||
getAllCommands(): CommandDefinition[] {
|
||||
return Array.from(this.commands.values());
|
||||
const commands = Array.from(this.commands.values());
|
||||
|
||||
// Sort commands by name
|
||||
commands.sort((a, b) => a.name.localeCompare(b.name));
|
||||
|
||||
return commands;
|
||||
}
|
||||
|
||||
searchCommands(query: string): CommandDefinition[] {
|
||||
|
Loading…
x
Reference in New Issue
Block a user