fix install link copy functionality
This commit is contained in:
@@ -485,13 +485,8 @@ export default function landingTemplate(manifest, config = {}) {
|
|||||||
installLink.href = 'stremio://' + location;
|
installLink.href = 'stremio://' + location;
|
||||||
}
|
}
|
||||||
|
|
||||||
installLink.addEventListener('click', ()=>{
|
installLink.addEventListener('click', function() {
|
||||||
document.addEventListener('copy', function(e) {
|
navigator.clipboard.writeText(installLink.href.replace('stremio://', 'https://'));
|
||||||
e.clipboardData.setData('text/plain', installLink.href);
|
|
||||||
e.preventDefault();
|
|
||||||
}, true);
|
|
||||||
|
|
||||||
document.execCommand('copy');
|
|
||||||
});
|
});
|
||||||
</script>
|
</script>
|
||||||
</body>
|
</body>
|
||||||
|
|||||||
Reference in New Issue
Block a user