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

snow only over one image #34

Closed
skarmoutsosv opened this issue Dec 21, 2017 · 2 comments
Closed

snow only over one image #34

skarmoutsosv opened this issue Dec 21, 2017 · 2 comments

Comments

@skarmoutsosv
Copy link

I currently use java at http://www.skarmoutsos.gr/vaggelis.htm to have a snow effect over an image.
Is it possible to have snow over one image instead of a page, using Snowstorm?

@scottschiller
Copy link
Owner

scottschiller commented Feb 3, 2018

Sorry I missed this one over the holidays! 😅

Snowstorm can be constrained to a target element (DOM node), so it's entirely possible to have it snow only within a single <div> which could have your desired image as its only child.

The trick is to have your container element be absolute or relatively-positioned, so that snowflakes inside it can be positioned correctly.

@skarmoutsosv
Copy link
Author

Once you confirmed it can be done, it was just a matter of reading http://www.schillmania.com/projects/snowstorm/#customizing to achieve the needed result.
Thank you

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

2 participants