Page MenuHomePhorge

report.js
No OneTemporary

Size
699 B
Referenced Files
None
Subscribers
None

report.js

function copyText(text) {
if (!navigator.clipboard || !window.isSecureContext) {
return Promise.reject(new Error('Clipboard API is unavailable'));
}
return navigator.clipboard.writeText(text);
}
document.addEventListener('click', event => {
const link = event.target.closest('[data-copy-url]');
if (!link) return;
event.preventDefault();
const url = link.getAttribute('data-copy-url');
if (!url) return;
copyText(url)
.then(() => {
const original = link.textContent;
link.textContent = 'Copied URL to clipboard';
window.setTimeout(() => {
link.textContent = original;
}, 2000);
})
.catch(() => (window.location.href = url));
});

File Metadata

Mime Type
text/plain
Expires
Sat, Aug 1, 6:25 PM (1 d, 6 h)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
603389
Default Alt Text
report.js (699 B)

Event Timeline