diff --git a/web/js/autocompleter.js b/web/js/autocompleter.js index cad9b24..55d0f5e 100644 --- a/web/js/autocompleter.js +++ b/web/js/autocompleter.js @@ -285,6 +285,7 @@ app.registerExtension({ words[v] = { text: v, info: () => new EmbeddingInfoDialog(emb).show("embeddings", emb), + use_replacer: false, }; } @@ -303,6 +304,7 @@ app.registerExtension({ words[v] = { text: v, info: () => new LoraInfoDialog(lora).show("loras", lora), + use_replacer: false, }; } diff --git a/web/js/common/autocomplete.js b/web/js/common/autocomplete.js index 08e54b9..8db269e 100644 --- a/web/js/common/autocomplete.js +++ b/web/js/common/autocomplete.js @@ -576,7 +576,8 @@ export class TextAreaAutoComplete { onclick: () => { this.el.focus(); let value = wordInfo.value ?? wordInfo.text; - if (TextAreaAutoComplete.replacer) { + const use_replacer = wordInfo.use_replacer ?? true; + if (TextAreaAutoComplete.replacer && use_replacer) { value = TextAreaAutoComplete.replacer(value); } this.helper.insertAtCursor(value + this.separator, -before.length, wordInfo.caretOffset);