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

init_discussion_tab.js « image_diff « javascripts « assets « app - gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: dbe4c06a4e9ed3a374d6e471e7d87efc16e98bc7 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
import imageDiffHelper from './helpers/index';

export default () => {
  // Always pass can-create-note as false because a user
  // cannot place new badge markers on discussion tab
  const canCreateNote = false;
  const renderCommentBadge = true;

  const diffFileEls = document.querySelectorAll('.timeline-content .diff-file.js-image-file');
  [...diffFileEls].forEach(diffFileEl =>
    imageDiffHelper.initImageDiff(diffFileEl, canCreateNote, renderCommentBadge),
  );
};