Snap Builder Public Codes Library
Snap | Generators | Login | Browse | Search | Enter Code | Export Snap Builder Public Codes Library

 

Category: Cascading Style Sheets (HTML5 - SCSS - CSS3 & CSS) >> Transitions >> CSS3 Transition Callback


Code Snippet </> Info


Snippet Name: CSS3 Transition Callback

Description: Add a drop and fade in effect using the CSS3 Transition Callback code in motionJS.


Compatible Browsers:
Chrome BrowserFirefox BrowserInternet Explorer BrowserOpera BrowserSafari Browser


Example: View Code Demo

Note: Adjust effect duration and/or Remove the prompt message line, if not needed.

Author: Usabli.ca

Last Modified: 2019-12-09 02:17:34

Language: css

Highlight Mode: css

Copy Codes: Use Free Notepad ++
Bookmark and Share

Snap HTML Code Editor:
Paste the source code, make changes and instantly see it in live preview.
Snap HTML Code Editor


  About Copying
Copied To Clipboard!

<html> <head> <title>CSS3 Transition Callback</title> <meta content="text/html;charset=utf-8" http-equiv="Content-Type"> <meta content="utf-8" http-equiv="encoding"> <style> #snap_word {width:600px;text-align:center;position:absolute;opacity:0;left:50%;top:0;margin-left:-250px;font-family:Arial;font-size:50px;color:#007730;} #snippet {font-family:Arial;font-size:100%;} </style> </head> <body> <div id="snippet"> [ This code example from <a href="http://snapbuilder.com/code_snippets/copy_code_snippet_244.html">CSS3 Transition Callback</a> page. ] </div> <div id="snap_word">CSS3 Transition Callback</div> </body> <!-- Download the motion.js file from: https://github.com/usablica/motion.js/blob/master/motion.js --> <script src="http://snapbuilder.com/code_snippets/view_code_example/css/transitions/motionJS/motion.js" type="text/javascript"></script> <script type="text/javascript"> <!-- /* Begin CSS3 Transition Callback == This Script Free To Use Providing This Notice Remains == == This Script Has Been Found In The https://snapbuilder.com Free Public Codes Library == == NOTICE: Though This Material May Have Been In A Public Depository, Certain Author Copyright Restrictions May Apply == == Created by: Usabli.ca : https://github.com/usablica : Creative Commons License == */ motionJs.transition({ select:"#snap_word", duration:'5s', // each 1s = 1 second style:{ top:'200px', opacity:1 }, end:function(event) { alert("End of transition demo."); // remove this line if no alert needed } }); // --> </script> </html>


[ Snippet Options ]

 

© 2002 -  Snap Builder Public Codes Library