Tucker McKnight
Make clone button work on new repo page Also tweak styling of top nav
119
<button class="w-100 btn btn-info btn-lg">Clone</button>
119
<button class="w-100 btn btn-info btn-lg" id="clone-popover-btn">Clone</button>
146
146
<script>
const createClonePopover = () => {
const div = document.createElement('div')
div.id = "clone-popover"
div.innerHTML = "<label class='form-label'>HTTPS URL</label><div class='input-group d-flex flex-nowrap'><span class='clone overflow-hidden input-group-text'>${repo.cloneUrl}</span><button data-clone-url='${repo.cloneUrl}' class='btn btn-primary shadow-none text-white' id='clone-button'>Copy</button></div>"
const popoverBtn = document.getElementById("clone-popover-btn")
const bsPopover = new bootstrap.Popover(popoverBtn, {
sanitize: false,
html: true,
content: div,
title: 'Clone',
placement: 'bottom',
container: 'body',
})
}
createClonePopover()
</script>
106 107
background-color: $blue;
color: white;
106 107
padding-bottom: 4px;
color: $blue;
border-bottom: 2px solid $blue;
139
139
.dropdown-branches {
list-style: none;
padding: 0;
}
.popover {
max-width: 100%;
}