Commit f7bb7da694e0cd49cd0d21cf7ddeb7022c727af6

Authored by Charles Oliveira
Committed by Sergio Oliveira
1 parent 2221d796

Using JS to hit SSH button on clone options

colab/proxy/gitlab/templates/proxy/gitlab.html
@@ -39,6 +39,12 @@ @@ -39,6 +39,12 @@
39 // instead of editing bootstrap.css, we just removed '.hide' css class and 39 // instead of editing bootstrap.css, we just removed '.hide' css class and
40 // toggled 40 // toggled
41 $('.hide').removeClass('hide').css('display', 'none'); 41 $('.hide').removeClass('hide').css('display', 'none');
  42 +
  43 + // When there's clone buttons for HTTPS and SSH, hit SSH and make HTTPS disapear
  44 + if(jQuery('.git-clone-holder button'))
  45 + {
  46 + jQuery('.git-clone-holder button')[0].click();
  47 + }
42 }); 48 });
43 </script> 49 </script>
44 <script type="text/javascript" src="{% static 'third-party/bootstrap/js/bootstrap.min.js' %}"></script> 50 <script type="text/javascript" src="{% static 'third-party/bootstrap/js/bootstrap.min.js' %}"></script>