From 89a592a6e1874fc97d887730baf24eb78b8c56d0 Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Sun, 1 Jan 2023 23:15:52 +0100 Subject: js: Do not finish token on space when inside a prefixed phrase. --- assets/js/tokeninput.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/assets/js/tokeninput.js b/assets/js/tokeninput.js index 41c8762..72a3c82 100644 --- a/assets/js/tokeninput.js +++ b/assets/js/tokeninput.js @@ -1254,7 +1254,7 @@ T.prototype.onSpace = function( e ) { if ( this.options.spaceToAdd ) { var val = this.getInputElementValue(); - if (val.startsWith('"')) { + if (val.startsWith('"') || (val.search(/:"/) !== -1)) { if (val.endsWith('"')) { this.onEnter( e ); } -- cgit v1.2.3