Pen Settings

HTML

CSS

CSS Base

Vendor Prefixing

Add External Stylesheets/Pens

Any URLs added here will be added as <link>s in order, and before the CSS in the editor. You can use the CSS from another Pen by using its URL and the proper URL extension.

+ add another resource

JavaScript

Babel includes JSX processing.

Add External Scripts/Pens

Any URL's added here will be added as <script>s in order, and run before the JavaScript in the editor. You can use the URL of any other Pen and it will include the JavaScript from that Pen.

+ add another resource

Packages

Add Packages

Search for and use JavaScript packages from npm here. By selecting a package, an import statement will be added to the top of the JavaScript editor for this package.

Behavior

Auto Save

If active, Pens will autosave every 30 seconds after being saved once.

Auto-Updating Preview

If enabled, the preview panel updates automatically as you code. If disabled, use the "Run" button to update.

Format on Save

If enabled, your code will be formatted when you actively save your Pen. Note: your code becomes un-folded during formatting.

Editor Settings

Code Indentation

Want to change your Syntax Highlighting theme, Fonts and more?

Visit your global Editor Settings.

HTML

              
                <header>
  <div class="container">
    <h1>Animate.css + wow.js</h1>
  </div>
</header>
<div class="container">
  <section id="first">
   <h2>Подключение плагина</h2>
  <p>Давайте посмотрим, как будет вести себя анимация при прокрутке контента.</p>
  <p>Ниже будут размещены блоки, которые анимируются только тогда, когда пользователь "докручивает" до них с помощью колесика мышки или вертикальной прокрутки.</p>
  <p>Этот эффект достигается за счет использования плагина <a href="https://wowjs.uk/" target="blank">WOW.js</a></p>
  <p>Вы можете загрузить этот плагин с помощью ссылки с CDN:</p>
  <pre>
    &lt;script <span class="green">src="https://cdnjs.cloudflare.com/ajax/libs/wow/1.1.2/wow.min.js"</span> integrity="sha512-Eak/29OTpb36LLo2r47IpVzPBLXnAMPAVypbSZiZ4Qkf8p/7S/XRG5xp7OKWPPYfJT6metI+IORkR5G8F900+g==" crossorigin="anonymous" referrerpolicy="no-referrer"&gt;&lt;/script&gt;
  </pre>
  <p>Затем вам нужно создать еще один блок с тегами <code>&lt;script&gt;</code> и записать в них такой код: </p>
  <pre>
  &lt;script&gt;
    new WOW().init();
  &lt;/script&gt;
  </pre>
  <div class="row">
		<div class="wow box animate__animated animate__backInDown"><img src="https://source.unsplash.com/HoC9ttceIGo/300x200" alt="Cat"></div>
		<div class="wow box animate__animated animate__fadeInUp animate__delay-1s"><img src="https://source.unsplash.com/rW-I87aPY5Y/300x200" alt="Cat"></div>
		<div class="wow box animate__animated animate__slideInRight animate__delay-2s"><img src="https://source.unsplash.com/w2DsS-ZAP4U/300x200" alt="Cat"></div>
</div>
  <h2>Классы с анимацией для wow.js</h2>
  <p>Кроме тех классов, которые вы указывали для animate.css, вам нужно будет еще добавить класс <code>wow</code>.</p>
  <pre>
    &lt;div class="wow box animate__animated animate__lightSpeedInLeft"&gt;
       &lt;img src="images/cat.jpg" alt="Cat"&gt;
   &lt;/div&gt;
  </pre>
  <p>Задержка анимации может быть задана с помощью классов animate.css или с помощью data-атрибута из wow.js.</p>
  <p>Как это сделать - выбирать вам.</p>
  <p>Для изображений ниже задана задержка анимации с помощью классов <code>animate__delay-1s</code> и др.</p>
<div class="row">
		<div class="wow box animate__animated animate__lightSpeedInLeft"><img src="https://source.unsplash.com/eMzblc6JmXM/300x200" alt="Cat"></div>
		<div class="wow box animate__animated animate__flipInY animate__delay-1s"><img src="https://source.unsplash.com/KfPwby-UisA/300x200" alt="Cat"></div>
		<div class="wow box animate__animated animate__lightSpeedInRight animate__delay-2s"><img src="https://source.unsplash.com/ZlFKIG6dApg/300x200" alt="Cat"></div>
	</div>
  </section>
  <section id="second">
    <h2>Пример с анимацией блоков с иконками</h2>
    <p>С помощью animate.css и wow.js можно анимировать как изображения, так и текстовые блоки или блоки со смешанным контентом.</p>
    <p>Для нижнего ряда блоков использована задержка, заданная с помощью data-атрибута <code>data-wow-delay</code>, которая предусмотрена в плагине wow.js, а не в animate.css.</p>
  <div class="row">
    <div class="wow animate__animated animate__rotateInDownLeft icon-service">
      <div class="icon-holder"><i class="fa fa-chess-pawn"></i></div>
      <h4>Service 1</h4>
      <p>Lorem ipsum dolor sit amet consectetur adipisicing elit. Illo aliquam sunt voluptas, et quia tempora!</p>
    </div>
    <div class="icon-service wow animate__animated animate__rotateInDownRight">
      <div class="icon-holder"><i class="fa fa-chess"></i></div>
      <h4>Service 2</h4>
      <p>Quas cupiditate aut fugiat fugit qui, voluptatibus exercitationem minus iusto facere, error voluptates reiciendis ut?</p>
    </div>
    <div class="icon-service wow animate__animated animate__rotateInUpLeft" data-wow-delay="1s">
      <div class="icon-holder"><i class="fa fa-chess-rook"></i></div>
      <h4>Service 3</h4>
      <p>Excepturi adipisci illum molestiae. Aperiam fugit praesentium dignissimos eius quisquam minus numquam ut distinctio quis.</p>
    </div>
    <div class="icon-service wow animate__animated animate__rotateInUpRight" data-wow-delay="1s">
      <div class="icon-holder"><i class="fa fa-chess-queen"></i></div>
      <h4>Service 4</h4>
      <p>Earum totam incidunt, nisi debitis ex consectetur ipsa mollitia, culpa nobis rem unde, ab a!</p>
    </div>
  </div> 
    <p class="wow animate__animated animate__fadeInLeftBig"  data-wow-delay="1.5s">Обычные абзацы с текстом вы тоже можете анимировать.</p>
    <p  class="wow animate__animated animate__fadeInRightBig" data-wow-delay="2s">Выбирайте нужные элементы для анимации, но <strong>не переборщите с ее количеством!</strong></p>
   </section>
</div>
<footer>
  <div class="container">
    <div class="row">
      <p><a href="https://animate.style/">Animate.css</a> + <a href="https://wowjs.uk/">wow.js</a></p>
      <p><a href="//html-plus.in.ua/html-page-animation-with-animate-css-and-wow-js">Статья на html-plus.in.ua</a></p>
    </div>
  </div>
</footer>

              
            
!

CSS

              
                * {
	box-sizing: border-box;
}
body {
	margin: 0;
	font-family: sans-serif;
}
.container {
  max-width: 960px;
	margin: 20px auto;
  padding-left: 15px;
  padding-right: 15px;
}
.row {
	display: flex;
	flex-wrap: wrap;
	align-content: center;
	justify-content: space-between;
	
  overflow: hidden;
}
.box {
  flex: 0 0 32%;
  margin-bottom: 20px;
}
.box img {
	display: block;
  max-width: 100%;
  border: 3px solid #dadada;
  box-shadow: 2px 2px 8px rgba(0,0,0,.4);
}
.icon-service {
  flex: 0 0 48%;
  margin-bottom: 20px;
  border: 3px solid #ddd;
  border-radius: 10px;
  padding: 8px 15px 0;
  box-shadow: 2px 2px 8px rgba(0,0,0,.4);
}
.icon-holder {
  display: inline-block;
  margin-right: 10px;
  font-size: 1.4em;
  border-radius: 8px;
  background-color: #f90;
  padding: 10px;
  min-width: 50px;
  text-align: center;
  box-shadow: 2px 2px 8px rgba(0,0,0,.4);
}
.icon-holder + h4 {
  display: inline-block;
}
pre {
  background-color: #ddd;
  border: 3px double #ccc;
  word-wrap: break-word;
  white-space: pre-line;
  padding: 10px;
}
.green {
  color: #0a0;
}
code {
  background-color: #ddd;
  font-family: 'Courier New', monospace;
}
footer, header {
  background-color: #222;
  padding: 8px 0;
  color: #fff;
}
footer a {
  color: #fff;
}
@media (max-width: 520px){
  .box {flex: 0 0 48%;}
}
              
            
!

JS

              
                new WOW().init();
              
            
!
999px

Console