diff options
author | Phil Hughes <me@iamphill.com> | 2016-08-01 10:21:57 +0100 |
---|---|---|
committer | Phil Hughes <me@iamphill.com> | 2016-08-01 10:21:57 +0100 |
commit | d6e724d90fd8a5fd93ef1f4963e22ccaf29b06de (patch) | |
tree | e29d50c12afb5036a356f2a541a028cf7b90df49 /app/assets/javascripts/single_file_diff.js | |
parent | f65d8eb3261f717340a8e8fd8a3fe65bd9fd2c20 (diff) | |
download | gitlab-ce-d6e724d90fd8a5fd93ef1f4963e22ccaf29b06de.tar.gz |
Moved method to compile components from window into diffnotesapp
Diffstat (limited to 'app/assets/javascripts/single_file_diff.js')
-rw-r--r-- | app/assets/javascripts/single_file_diff.js | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/app/assets/javascripts/single_file_diff.js b/app/assets/javascripts/single_file_diff.js index 70e80b57f91..9d181586b1d 100644 --- a/app/assets/javascripts/single_file_diff.js +++ b/app/assets/javascripts/single_file_diff.js @@ -36,11 +36,15 @@ if (!this.isOpen && !this.hasError) { this.content.hide(); this.collapsedContent.show(); - compileVueComponentsForDiffNotes(); + if (DiffNotesApp) { + DiffNotesApp.compileComponents(); + } } else if (this.content) { this.collapsedContent.hide(); this.content.show(); - compileVueComponentsForDiffNotes(); + if (DiffNotesApp) { + DiffNotesApp.compileComponents(); + } } else { return this.getContentHTML(); } @@ -55,7 +59,9 @@ if (data.html) { _this.content = $(data.html); _this.content.syntaxHighlight(); - compileVueComponentsForDiffNotes(); + if (DiffNotesApp) { + DiffNotesApp.compileComponents(); + } } else { _this.hasError = true; _this.content = $(ERROR_HTML); |