Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Gerhardt <code@dgerhardt.net>2015-07-10 20:46:40 +0300
committerDaniel Gerhardt <code@dgerhardt.net>2015-07-10 20:46:40 +0300
commit1ea2dfa5de7930ddc9602ed376d2c557077f45e6 (patch)
tree09564be45d01b4fffe273367fd618dc06af16e45 /app/assets
parent526813581b042bc6abad60eb4e582be81620be77 (diff)
Do not add the same icon multiple times to dropzones
Some DOM queries were to broad which caused paperclip icons and spinners to be added multiple times to a dropzone in case of multiple dropzones on a page.
Diffstat (limited to 'app/assets')
-rw-r--r--app/assets/javascripts/dropzone_input.js.coffee6
1 files changed, 3 insertions, 3 deletions
diff --git a/app/assets/javascripts/dropzone_input.js.coffee b/app/assets/javascripts/dropzone_input.js.coffee
index a7476146010..a4f511301c1 100644
--- a/app/assets/javascripts/dropzone_input.js.coffee
+++ b/app/assets/javascripts/dropzone_input.js.coffee
@@ -25,10 +25,10 @@ class @DropzoneInput
form_dropzone = $(form).find('.div-dropzone')
form_dropzone.parent().addClass "div-dropzone-wrapper"
form_dropzone.append divHover
- $(".div-dropzone-hover").append iconPaperclip
+ form_dropzone.find(".div-dropzone-hover").append iconPaperclip
form_dropzone.append divSpinner
- $(".div-dropzone-spinner").append iconSpinner
- $(".div-dropzone-spinner").css
+ form_dropzone.find(".div-dropzone-spinner").append iconSpinner
+ form_dropzone.find(".div-dropzone-spinner").css
"opacity": 0
"display": "none"