1
0

Auto-reload the screenshot

This commit is contained in:
vlad 2024-10-07 17:06:35 -07:00
parent f5249e361c
commit b1d53b845d

View File

@ -28,6 +28,9 @@
screenshotImage.src = imageUrl;
screenshotImage.style.display = 'block';
})
.then(() => {
setTimeout(takeScreenshot, 500);
})
.catch(error => {
console.error('Error taking screenshot:', error);
});
@ -58,7 +61,6 @@
</script>
</head>
<body onload="init()">
<button onclick="takeScreenshot()">Refresh Screenshot</button>
<div id="screenshot-div">
<p><strong>Click on the Image to Trigger Click at X, Y:</strong></p>
<img id="screenshot" width='1280px' height='720px' style="display:none;" />