HelloWorld1
HelloWorld1

Reputation: 14100

How to make a notice with fade in and fade out

I would like to have fade in and fade out when this notice info will displace.

I still use the same source code but I still can't retrieve the fade in and face out effect.

What part am I missing in order to achieve it?

Thank you!

More info can be read at http://bootstrap-notify.remabledesigns.com/

Same source code in jsfiddle and jsbin but it only work at jsbin.

https://jsfiddle.net/qenn83yg/

http://jsbin.com/cofigosute/edit?html,js,output

$.notify({
	title: "Welcome:",
	message: "This plugin has been provided to you by Robert McIntosh aka mouse0270"
});
<!DOCTYPE html>
<html>
<head>
  <meta charset="utf-8">
  <meta name="viewport" content="width=device-width">
  <title>JS Bin</title>
</head>
<body>
  
<link href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/css/bootstrap.min.css" rel="stylesheet" type="text/css" /> 
<link href="https://cdnjs.cloudflare.com/ajax/libs/bootstrap-notify/0.2.0/css/bootstrap-notify.min.css" rel="stylesheet" type="text/css" />
<link href="https://cdnjs.cloudflare.com/ajax/libs/bootstrap-notify/0.2.0/css/bootstrap-notify.min.css" rel="stylesheet" type="text/css" />
<link href="https://cdnjs.cloudflare.com/ajax/libs/bootstrap-notify/0.2.0/css/styles/alert-blackgloss.min.css" rel="stylesheet" type="text/css" />



<script src="//cdnjs.cloudflare.com/ajax/libs/jquery/2.1.1/jquery.min.js"></script>
<script src="//maxcdn.bootstrapcdn.com/bootstrap/3.3.1/js/bootstrap.min.js"></script>
<script src="//cdnjs.cloudflare.com/ajax/libs/highlight.js/8.4/highlight.min.js"></script>

  
  
 

  
  
<script src="//cdnjs.cloudflare.com/ajax/libs/highlight.js/8.4/highlight.min.js"></script>

<script src="http://bootstrap-notify.remabledesigns.com/js/bootstrap-notify.min.js"></script>

</body>
</html>

Upvotes: 1

Views: 1917

Answers (1)

Amal
Amal

Reputation: 3426

Try this code

Add animate.css

https://cdnjs.cloudflare.com/ajax/libs/animate.css/3.5.2/animate.css

modified code

$.notify({
    title: "Welcome:",
    message: "This plugin has been provided to you by Robert McIntosh aka mouse0270",
  animate: {
        enter: 'animated fadeInDown',
        exit: 'animated fadeOutUp'
    }
});

DEMO

Upvotes: 0

Related Questions