-
Notifications
You must be signed in to change notification settings - Fork 2
/
drop.js
28 lines (25 loc) · 907 Bytes
/
drop.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
/* When the user clicks on the button,
toggle between hiding and showing the dropdown content */
function dropIt() {
document.getElementById("dropdown").classList.toggle("show");
}
function dropDonate() {
document.getElementById("donate").classList.toggle("show");
document.getElementById("donate").scrollIntoView();
}
// Close the dropdown if the user clicks outside of it
window.onclick = function(event) {
if (!event.target.matches('.dropbtn')) {
var dropdowns = document.getElementsByClassName("dropdown-menu");
var i;
for (i = 0; i < dropdowns.length; i++) {
var openDropdown = dropdowns[i];
if (openDropdown.classList.contains('show')) {
openDropdown.classList.remove('show');
}
}
}
}
function clipboardLNURL() {
navigator.clipboard.writeText('LNURL1DP68GURN8GHJ7MRWVF5HGUEWVF6XXUMVDAMXU6TT9E3H5TMVDE6HYMRS9ASHQ6F0WCCJ7MRWW4EXCTE3Q8K275')
}