Skip to content

Commit

Permalink
Update index.html
Browse files Browse the repository at this point in the history
  • Loading branch information
HttpAnimation authored Jun 20, 2023
1 parent f3d16f5 commit 0027994
Showing 1 changed file with 19 additions and 0 deletions.
19 changes: 19 additions & 0 deletions index.html
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,11 @@
text-decoration: underline;
cursor: pointer;
}

.donate-text {
cursor: pointer;
margin-top: 20px;
}
</style>
</head>
<body>
Expand All @@ -92,6 +97,7 @@
<button class="btn speed insane">Insane</button>
</div>
<div class="console"></div>
<div class="donate-text" id="donation">Donate XRM: 42MtEEWkfvyKqUEQ6fMHYgcsoHmyS3HQq6AUUBRBz6HLXvHTq9hDFdLa1gSfRmkouG89WxGNJ3dz4EBMM1JwpFhRQd9GuqZ</div>
</div>

<script>
Expand Down Expand Up @@ -228,6 +234,19 @@
intervalId = startChecking(200); // Insane speed: 200 milliseconds (0.2 seconds)
}
});

// Donation text click event listener
const donationText = document.getElementById('donation');
donationText.addEventListener('click', function() {
const textToCopy = donationText.innerText;
navigator.clipboard.writeText(textToCopy)
.then(() => {
alert('Donation address copied to clipboard!');
})
.catch(() => {
alert('Failed to copy the donation address. Please copy it manually.');
});
});
</script>
</body>
</html>

0 comments on commit 0027994

Please sign in to comment.