Auto-publish on Fri 8 Aug 18:27:52 BST 2025

This commit is contained in:
2025-08-08 18:27:52 +01:00
parent 0309c458ba
commit 1fa7e85a58
18 changed files with 752 additions and 2198 deletions

21
output/assets/script.js Normal file
View File

@@ -0,0 +1,21 @@
// COPY BUTTON:
document.addEventListener("DOMContentLoaded", function () {
document.querySelectorAll("pre.src").forEach(function (block) {
const button = document.createElement("button");
button.innerText = "Copy";
button.className = "copy-btn";
// Append button inside <pre>
block.appendChild(button);
button.addEventListener("click", function () {
const text = block.innerText.replace(button.innerText, ""); // exclude button text
navigator.clipboard.writeText(text.trim()).then(() => {
button.innerText = "Copied!";
setTimeout(() => (button.innerText = "Copy"), 1500);
});
});
});
});