pytest-html icon indicating copy to clipboard operation
pytest-html copied to clipboard

Possible to have --self-contained-html extra.image open in new tab

Open jonathantizard opened this issue 5 years ago • 1 comments
trafficstars

Hi,

So currently I would like to pass images from web driver as base 64 encoded straight into your extra.image helper.

When setting to --self-contained-html. This works great, the only downside is that the images are no longer clickable. They don't open in a new tab.

Would it be possible to embed a little bit of JS on an onClick handler so that the image can open in a new tab? I'd love to submit a pull request but Im not Pythonic enough just yet!

This would be the icing on the cake for the self contained option!

Thanks

jonathantizard avatar Apr 23 '20 16:04 jonathantizard

Sorry for not responding to this earlier @jonathantizard !

There are currently a bunch of open issues and PRs that together would get us some way towards fulfilling your wish.

As soon as those are solved, I can revisit this.

BeyondEvil avatar May 13 '20 15:05 BeyondEvil