linkButton = (label, url, backgroundColor = "#12e") => {
const id = DOM.uid("button");
return md`
<a href="${url}" target="_blank">
<button type="button" class='link-button' id='${id.id}'>${label}</button>
</a><br/>
<small class="url"><a href="${url}" target="_blank">${url}</a></small>
<style>
#${id.id} {
background: ${backgroundColor};
}
.link-button {
cursor: pointer;
padding: .5em;
font-size: 1em;
font-weight: 700;
color: #fffd;
border: none;
border-radius: .25em;
opacity: 0.8;
}
.link-button:hover {
opacity: 1;
}
.url {
font-family: monospace;
}
</style>`;
}