Parallax

Around supports 2 types of parallax effect: on page scrolling and cursor position.

Around component

Background image

Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.

Sed ut perspiciatis unde omnis iste natus error sit voluptatem accusantium doloremque laudantium, totam rem aperiam, eaque ipsa quae ab illo inventore veritatis et quasi architecto beatae vitae dicta sunt explicabo. Nemo enim ipsam voluptatem quia voluptas sit aspernatur aut odit aut fugit, sed quia consequuntur magni dolores eos qui ratione voluptatem sequi nesciunt. Neque porro quisquam est, qui dolorem ipsum quia dolor sit amet, consectetur, adipisci velit, sed quia non numquam eius modi tempora incidunt ut labore et dolore magnam aliquam quaerat voluptatem. Ut enim ad minima veniam, quis nostrum exercitationem ullam corporis suscipit laboriosam, nisi ut aliquid ex ea commodi consequatur? Quis autem vel eum iure reprehenderit qui in ea voluptate velit esse quam nihil molestiae consequatur, vel illum qui dolorem eum fugiat.

Parallax backgound image

Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.

Sed ut perspiciatis unde omnis iste natus error sit voluptatem accusantium doloremque laudantium, totam rem aperiam, eaque ipsa quae ab illo inventore veritatis et quasi architecto beatae vitae dicta sunt explicabo. Nemo enim ipsam voluptatem quia voluptas sit aspernatur aut odit aut fugit, sed quia consequuntur magni dolores eos qui ratione voluptatem sequi nesciunt. Neque porro quisquam est, qui dolorem ipsum quia dolor sit amet, consectetur, adipisci velit, sed quia non numquam eius modi tempora incidunt ut labore et dolore magnam aliquam quaerat voluptatem. Ut enim ad minima veniam, quis nostrum exercitationem ullam corporis suscipit laboriosam, nisi ut aliquid ex ea commodi consequatur? Quis autem vel eum iure reprehenderit qui in ea voluptate velit esse quam nihil molestiae consequatur, vel illum qui dolorem eum fugiat.

<!-- Background image parallax -->
<div class="jarallax bg-dark py-7" data-jarallax data-speed="0.3">
  <span class="position-absolute top-0 start-0 w-100 h-100 bg-black" style="opacity: .35;"></span>
  <div class="jarallax-img" style="background-image: url(path-to-background-image);"></div>
  <div class="container  position-relative zindex-2 py-5 py-sm-7 text-center">
    <h2 class="h1 text-light mb-0">Parallax backgound image</h2>
  </div>
</div>
// Background image parallax
.jarallax.bg-dark.py-7(data-jarallax data-speed="0.3")
  span.position-absolute.top-0.start-0.w-100.h-100.bg-black(style="opacity: .35;")
  .jarallax-img(style="background-image: url(path-to-background-image);")
  .container.position-relative.zindex-2.py-5.py-sm-7.text-center
    h2.h1.text-light.mb-0 Parallax backgound image

Element parallax

A
R
O
U
N
D
<!-- Element parallax -->
<div class="d-flex">
  <div data-jarallax-element="40">
    <img src="path-to-image" alt="Alt text">
  </div>
  <div data-jarallax-element="-40">
    <img src="path-to-image" alt="Alt text">
  </div>
</div>
// Element parallax
.d-flex
  div(data-jarallax-element="40")
    img(src="path-to-image", alt="Alt text")
  div(data-jarallax-element="-40")
    img(src="path-to-image", alt="Alt text")

Cursor position parallax

Layer
Layer
Layer
Layer
Layer
Layer
Layer
Layer
Layer
Layer
Layer
Layer
Layer
Layer
<!-- Cursor position parallax -->
<div class="parallax">
  <div class="parallax-layer position-relative" data-depth="0.1">
     <img src="path-to-image" alt="Layer">
  </div>
  <div class="parallax-layer position-relative" data-depth="0.35">
     <img src="path-to-image" alt="Layer">
  </div>
  <div class="parallax-layer position-relative" data-depth="0.2">
     <img src="path-to-image" alt="Layer">
  </div>
  <!-- Add as many layers as you need with different data-depth parameters for more 3D-like effect. Make sure add position-relative to biggest layer to keep width and height. -->
</div>
// Cursor position parallax
.parallax
  .parallax-layer.position-relative(data-depth="0.1")
    img(src="path-to-image", alt="Layer")
  .parallax-layer(data-depth="0.35")
    img(src="path-to-image", alt="Layer")
  .parallax-layer(data-depth="0.2")
    img(src="path-to-image", alt="Layer")
  //- Add as many layers as you need with different data-depth parameters for more 3D-like effect. Make sure add position-relative to biggest layer to keep width and height.
Top