chore: add icons to commands

This commit is contained in:
Kodai Nakamura 2025-12-12 23:45:43 +09:00
parent d40b8d29f7
commit 1dfcc8da0a
2 changed files with 5 additions and 2 deletions

View file

@ -1,4 +1,4 @@
# Automatic Linker
# 🪄 Automatic Linker 🔮
Automatically convert plain text file references into Obsidian wiki links as you write. Keep your knowledge graph connected without manual linking.

View file

@ -146,7 +146,7 @@ export default class AutomaticLinkerPlugin extends Plugin {
const editor = this.getEditor();
if (!editor) return;
let fileContent = editor.getValue();
const fileContent = editor.getValue();
const oldText = fileContent;
const newText = this.modifyLinks(fileContent, activeFile.path);
updateEditor(oldText, newText, editor);
@ -342,6 +342,7 @@ export default class AutomaticLinkerPlugin extends Plugin {
this.addCommand({
id: "format-file",
name: "Format file",
icon: "wand-sparkles",
editorCallback: async () => {
try {
await this.modifyLinksForActiveFile();
@ -354,6 +355,7 @@ export default class AutomaticLinkerPlugin extends Plugin {
this.addCommand({
id: "format-vault",
name: "Format vault",
icon: "drill",
editorCallback: async () => {
try {
await this.modifyLinksForVault();
@ -366,6 +368,7 @@ export default class AutomaticLinkerPlugin extends Plugin {
this.addCommand({
id: "rebuild-index",
name: "Rebuild index",
icon: "refresh-ccw",
editorCallback: async () => {
try {
this.refreshFileDataAndTrie();