diff --git a/main.js b/main.js index bb4271a..809f19a 100644 --- a/main.js +++ b/main.js @@ -1673,6 +1673,13 @@ function commandpalette() text: s, suffix: s == "password" ? null : [settings[s]] }; + })) + .concat(JSON.parse((getnote("bookmarks") || {content: "[]"}).content).map(b => + { + return { + prefix: "open bookmark ", + text: b.title + }; }))) .then(selected => { @@ -1690,6 +1697,10 @@ function commandpalette() { editsetting(selected.text); } + else if (selected.prefix == "open bookmark ") + { + window.open(JSON.parse(getnote("bookmarks").content).find(b => b.title == selected.text).url, "_blank"); + } else { var command = commands.find(c => c.hint == selected.text);