Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support for sharp.overlayWith #115

Open
larc63 opened this issue Mar 4, 2019 · 0 comments
Open

Support for sharp.overlayWith #115

larc63 opened this issue Mar 4, 2019 · 0 comments

Comments

@larc63
Copy link

larc63 commented Mar 4, 2019

Can support for sharp.overlayWith be added?

As a proof of concept I added
if(config.watermark !== false){ image.overlayWith('admin/wm.png', { gravity: sharp.gravity.southeast } ); }
to lib/sharp.js

So, at least the current sharp version already supports this api. "All that's needed" is to wire up an appropriate API from gulp-responsive to call this function. I can think of an easy way with
{overlayFile, gravity} or additionally/optionally, calculating the position in pixels by passing in a percentage for width and height.

I'd be happy to give this a go if you'd be ok with some hand-holding with the git process (I've never used git in a formal team before).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant