mirror of
https://github.com/zadam/trilium.git
synced 2025-10-30 01:36:24 +01:00
use selected text to apply filtering for add link dialog, closes #1515
This commit is contained in:
@@ -55,6 +55,17 @@ function clearText($el) {
|
||||
$el.autocomplete("val", "").trigger('change');
|
||||
}
|
||||
|
||||
function setText($el, text) {
|
||||
if (utils.isMobile()) {
|
||||
return;
|
||||
}
|
||||
|
||||
$el.setSelectedNotePath("");
|
||||
$el
|
||||
.autocomplete("val", text.trim())
|
||||
.autocomplete("open");
|
||||
}
|
||||
|
||||
function showRecentNotes($el) {
|
||||
if (utils.isMobile()) {
|
||||
return;
|
||||
@@ -200,5 +211,6 @@ export default {
|
||||
autocompleteSourceForCKEditor,
|
||||
initNoteAutocomplete,
|
||||
showRecentNotes,
|
||||
setText,
|
||||
init
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user