1.0.5 • Published 3 years ago

ngp-enter-section v1.0.5

Weekly downloads
-
License
-
Repository
-
Last release
3 years ago

NgpEnterSectionDirective

Angular library for creating animations on web content. Creates transitions on the X and Y axes that create the nice effect of entering content as the user scrolls.

Installation

npm i ngp-enter-section --save

Usages

You must import the module NgpEnterSectionModule where you will use it and use the component

***
import { NgpEnterSectionModule } from 'ngp-enter-section';
@NgModule({
  ***
  imports: [
    NgpEnterSectionModule,
  ],
****
})

In your component:

 <div class="container">
    <div ngpEnterSection dirX="left">
        <h1 class="h1" >{{'Disfruta nuestras realizaciones'}}</h1>
        <h4>
          {{'Observa en tu dispositivo móvil o pc de escritorio, series, spots, documentales, podcats y mucho más.'}}
        </h4>
      </div>
      
    <div ngpEnterSection dirX="right" dirY="bottom" >
        <img class="image-section section1" src="assets/images/image-section-1.png" />
        <video id="video-section1" class="video-play" autoplay="true" muted="muted" loop="true">
          <source src="assets/videos/video-section-2.mp4" type="video/mp4" />
        </video>
    </div>

The example above creates an entry from the left for the first div and creates an entry from the right upwards in the second div

More configuration

The NgpEnterSectionDirective has more parameters like direction = 'left|right' and the timing for the animation, default value is '1s'

 <div ngpEnterSection dirY="top" time=".5s">
    <p>{{'Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum.'}}</h1>
  </div>
1.0.5

3 years ago

1.0.4

3 years ago

1.0.3

3 years ago

1.0.2

3 years ago

1.0.1

3 years ago

1.0.0

3 years ago