diff options
author | Filipa Lacerda <filipa@gitlab.com> | 2017-10-10 15:31:50 +0300 |
---|---|---|
committer | Filipa Lacerda <filipa@gitlab.com> | 2017-10-10 15:31:50 +0300 |
commit | 9f1c9b3d9b2ea858943cdb45cc96b05f59bdb8aa (patch) | |
tree | f8532fc469ffd7bcabf5692ef3486b72245f279a /app | |
parent | c47b33ad33fbb9f95e88ad688261aedf7eeb580f (diff) | |
parent | 74438cd1be759903091e093bffa3ec32ec84a874 (diff) |
Merge branch 'acet-fix-paste-on-comment-form' into 'master'
Trigger change event of the markdown textarea to allow Vue catch the programmatic changes.
Closes #38441
See merge request gitlab-org/gitlab-ce!14539
Diffstat (limited to 'app')
-rw-r--r-- | app/assets/javascripts/dropzone_input.js | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/app/assets/javascripts/dropzone_input.js b/app/assets/javascripts/dropzone_input.js index 1cba65d17cd..bd45da8c422 100644 --- a/app/assets/javascripts/dropzone_input.js +++ b/app/assets/javascripts/dropzone_input.js @@ -237,9 +237,12 @@ window.DropzoneInput = (function() { }; const insertToTextArea = function(filename, url) { - return $(child).val(function(index, val) { + const $child = $(child); + $child.val(function(index, val) { return val.replace(`{{${filename}}}`, url); }); + + $child.trigger('change'); }; const appendToTextArea = function(url) { |