BigW Consortium Gitlab

build_artifacts.js 789 Bytes
Newer Older
1
/* eslint-disable func-names, space-before-function-paren, wrap-iife, prefer-arrow-callback, no-unused-vars, no-return-assign, max-len */
Fatih Acet committed
2

3 4 5 6 7
window.BuildArtifacts = (function() {
  function BuildArtifacts() {
    this.disablePropagation();
    this.setupEntryClick();
  }
Fatih Acet committed
8

9 10 11 12 13 14 15 16
  BuildArtifacts.prototype.disablePropagation = function() {
    $('.top-block').on('click', '.download', function(e) {
      return e.stopPropagation();
    });
    return $('.tree-holder').on('click', 'tr[data-link] a', function(e) {
      return e.stopImmediatePropagation();
    });
  };
Fatih Acet committed
17

18 19 20 21 22 23 24 25
  BuildArtifacts.prototype.setupEntryClick = function() {
    return $('.tree-holder').on('click', 'tr[data-link]', function(e) {
      return window.location = this.dataset.link;
    });
  };

  return BuildArtifacts;
})();