diff --git a/lib/assets/javascripts/jquery.mentionsInput.js b/lib/assets/javascripts/jquery.mentionsInput.js index 17dca0f81..e1a73ff4c 100644 --- a/lib/assets/javascripts/jquery.mentionsInput.js +++ b/lib/assets/javascripts/jquery.mentionsInput.js @@ -9,8 +9,9 @@ * * Modifcations for Diaspora: * - * Prevent replacing the wrong text by marking the replacement position with a special character - * Don't add a space after inserting a mention + * Prevent replacing the wrong text by marking the replacement position with a special character + * Don't add a space after inserting a mention + * Only use the first div as a wrapperBox */ (function ($, _, undefined) { @@ -88,7 +89,7 @@ elmInputWrapper = elmInputBox.parent(); elmWrapperBox = $(settings.templates.wrapper()); elmInputBox.wrapAll(elmWrapperBox); - elmWrapperBox = elmInputWrapper.find('> div'); + elmWrapperBox = elmInputWrapper.find('> div').first(); elmInputBox.attr('data-mentions-input', 'true'); elmInputBox.bind('keydown', onInputBoxKeyDown);