forked from michalsnik/aos
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master' into 2.0.0-dev
- Loading branch information
Showing
5 changed files
with
68 additions
and
11 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
<!DOCTYPE html> | ||
<html> | ||
<head> | ||
<meta charset="utf-8"> | ||
<title>AOS - Animate on scroll library</title> | ||
<meta name="viewport" content="width=device-width"> | ||
<link rel="stylesheet" href="css/styles.css" /> | ||
<link rel="stylesheet" href="../dist/aos.css" /> | ||
</head> | ||
<body> | ||
<div id="aos-demo" class="aos-all"> | ||
<div class="aos-item" aos="fade-up"> | ||
<div class="aos-item__inner colored-1"><h3>Lorem ipsum</h3></div> | ||
</div> | ||
<div class="aos-item" aos="fade-down"> | ||
<div class="aos-item__inner colored-2"><h3>dolor sit amet</h3></div> | ||
</div> | ||
<div class="aos-item" aos="zoom-out-down"> | ||
<div class="aos-item__inner colored-3"><h3>onsectetur adipisicing</h3></div> | ||
</div> | ||
</div> | ||
|
||
<script src="../dist/aos.js"></script> | ||
<script> | ||
AOS.init({ | ||
easing: 'ease-in-out-sine' | ||
}); | ||
|
||
setInterval(addItem, 1000); | ||
|
||
var itemsCounter = 4; | ||
var container = document.getElementById('aos-demo'); | ||
|
||
function addItem () { | ||
var item = document.createElement('div'); | ||
item.classList.add('aos-item'); | ||
item.setAttribute('aos', 'fade-up'); | ||
item.innerHTML = '<div class="aos-item__inner colored-' + itemsCounter + '"><h3>Lorem ipsum</h3></div>'; | ||
container.appendChild(item); | ||
} | ||
</script> | ||
</body> | ||
</html> |
Oops, something went wrong.