chrome-devtools-java-client icon indicating copy to clipboard operation
chrome-devtools-java-client copied to clipboard

Get screenshot of a particular element

Open abhishekgoyal1994 opened this issue 5 years ago • 1 comments

Hi,

I see that chrome dev tools has an option in commands menu to take screenshot of a specific element. I didn't find this in any of the APIs provided by dev tools protocol. I tried using the Page.captureScreenshot with the required viewport that I want, but its not working when the element is outside of view-port and requires scroll. Requesting your help on, to take screenshots of elements outside of viewport (which are visible after desired scrolling).

abhishekgoyal1994 avatar Jul 10 '20 19:07 abhishekgoyal1994

I see that your examples only have full screenshot example. Can u please provide an example of taking snapshot for a particular element?

abhishekgoyal1994 avatar Jul 10 '20 19:07 abhishekgoyal1994