|
|
@ -19,8 +19,14 @@ |
|
|
|
</button> |
|
|
|
</button> |
|
|
|
{{end}} |
|
|
|
{{end}} |
|
|
|
{{if not (and $.DisableHTTP $.DisableSSH)}} |
|
|
|
{{if not (and $.DisableHTTP $.DisableSSH)}} |
|
|
|
<script defer> |
|
|
|
<script> |
|
|
|
const isSSH = localStorage.getItem('repo-clone-protocol') === 'ssh'; |
|
|
|
<!-- /* eslint-disable */ --> |
|
|
|
|
|
|
|
window.config.pageData['repoCloneButtons']= {httpsDisabled: {{$.DisableHTTP}}}; |
|
|
|
|
|
|
|
</script> |
|
|
|
|
|
|
|
<script> |
|
|
|
|
|
|
|
(() => { |
|
|
|
|
|
|
|
const tmplData = window.config.pageData.repoCloneButtons; |
|
|
|
|
|
|
|
const isSSH = tmplData.httpsDisabled || localStorage.getItem('repo-clone-protocol') === 'ssh'; |
|
|
|
const sshButton = document.getElementById('repo-clone-ssh'); |
|
|
|
const sshButton = document.getElementById('repo-clone-ssh'); |
|
|
|
const httpsButton = document.getElementById('repo-clone-https'); |
|
|
|
const httpsButton = document.getElementById('repo-clone-https'); |
|
|
|
const input = document.getElementById('repo-clone-url'); |
|
|
|
const input = document.getElementById('repo-clone-url'); |
|
|
@ -31,5 +37,6 @@ |
|
|
|
if (sshButton) sshButton.classList.remove('no-transition'); |
|
|
|
if (sshButton) sshButton.classList.remove('no-transition'); |
|
|
|
if (httpsButton) httpsButton.classList.remove('no-transition'); |
|
|
|
if (httpsButton) httpsButton.classList.remove('no-transition'); |
|
|
|
}, 100); |
|
|
|
}, 100); |
|
|
|
|
|
|
|
})(); |
|
|
|
</script> |
|
|
|
</script> |
|
|
|
{{end}} |
|
|
|
{{end}} |
|
|
|