3.0.4 • Published 4 years ago

@theoutfit/fadable v3.0.4

Weekly downloads
-
License
MIT
Repository
github
Last release
4 years ago

Fadable

Fade in elements as they move into view, at both the bottom and top of the viewport.

Demo

https://theoutfit-fadable.netlify.app/

How to Implement

  1. Install it: npm i @theoutfit/fadable --save
  2. Import it: import fadable from '@theoutfit/fadable'
  3. Call it: fadable()
  4. Class it: add a class of fadable to any element

Configuration

PropertyTypeDefaultDescription
initialScalenumber0.95Initial scale (from 0 - 1)
transitionDurationnumber0.75Transition speed (in seconds)
edgeDistancenumber40Transition runs at this distance from viewport edges (in pixels)

For example:

fadable({
  initialScale: 0.50,
  transitionDuration: 1.5,
  edgeDistance: 80
})

License

Fadable is available under the MIT license.

3.0.4

4 years ago

3.0.3

4 years ago

3.0.2

4 years ago

3.0.1

4 years ago

3.0.0

4 years ago