Scroll to reveal part of the background image allows you to reveal part of the pinned background image using the jQuery mousemove() function.
hover to reveal part of background image, background image change on hover, reveal image on hover css, css background image transition effects, image reveal animation css
Simple background Image Parallax Scroll Plugin In jQuery
How to make use of it:
1. Create a blank element for the scope effect.
<div class="scope"></div>
2. CSS to design scale effect and add a background image to your web page.
.scope { z-index: 5; position: absolute; top: calc(50% - 10rem); left: calc(50% - 10rem); width: 20rem; height: 20rem; background: url("1.jpg") 50% 50% no-repeat fixed; border-radius: 50%; }
3. Load the required jQuery JavaScript library at the end of the web page.
<script src="//ajax.googleapis.com/ajax/libs/jquery/1.11.2/jquery.min.js"></script>
4. The essence of JavaScript is to show part of the background image when you move the mouse.
$(document).ready(function() { var $magic = $(".magic"), magicWHalf = $magic.width() / 2; $(document).on("mousemove", function(e) { $magic.css({"left": e.pageX - magicWHalf, "top": e.pageY - magicWHalf}); }); });
Reveal Part Of Background Image Plugin/Github, image hover effects template
See Demo And Download
Official Website(suez): Click Here
This superior jQuery/javascript plugin is developed by suez. For extra Advanced usage, please go to the official website.