2.0.3 • Published 1 year ago

react-scroll-progress-bar v2.0.3

Weekly downloads
571
License
MIT
Repository
github
Last release
1 year ago

react-scroll-progress-bar

React Component for a fixed scroll progress bar. The progress bar can use the default color and height, or can be customized by any user provided height and color.

Install

npm install react-scroll-progress-bar

Usage

Default Progress Bar:

import React from "react";
import ProgressBar from "react-scroll-progress-bar"; //Add this line to import the component

export default class App extends React.Component {
  render() {
    return (
      <div>
        <ProgressBar />
        //This is all you need to get the default view working
      </div>
    );
  }
}

Custom Progress Bar:

import React from "react";
import ProgressBar from "react-scroll-progress-bar";

export default class App extends React.Component {
  render() {
    return (
      <div>
        <ProgressBar height="6" bgcolor="#000" duration="0.2" />
        // Here you can add any react component or jsx // Add ProgressBar at your
        top level component or Root component. // Change height and background-color
        by setting respective props.
      </div>
    );
  }
}

Configuration:

<ProgressBar height="8" bgcolor="#F43059" duration="1" />

height - Set height of progress bar. Default height is 8px. Pass the number not the unit. Unit is px

bgcolor - Set background-color of progress bar. Default background-color is #F43059.

duration - Set timing-duration for transition property. Default is 1s. Pass the number not the unit. Unit is s(seconds)

NOTE: To remove transition animation on progress bar, simply pass duration="0" to ProgressBar component.


2.0.3

1 year ago

2.0.0

1 year ago

1.2.0

1 year ago

1.2.3

1 year ago

1.2.2

1 year ago

1.2.1

1 year ago

1.1.13

4 years ago

1.1.12

5 years ago

1.1.11

6 years ago

1.1.10

6 years ago

1.1.9

6 years ago

1.1.8

6 years ago

1.1.7

6 years ago

1.1.6

6 years ago

1.1.5

6 years ago

1.1.4

6 years ago

1.1.3

6 years ago

1.1.2

6 years ago

1.1.1

6 years ago

1.1.0

6 years ago

1.0.12

6 years ago

1.0.11

6 years ago

1.0.10

6 years ago

1.0.9

6 years ago

1.0.8

6 years ago

1.0.7

6 years ago

1.0.5

6 years ago

1.0.4

6 years ago

1.0.3

6 years ago

1.0.2

6 years ago

1.0.1

6 years ago

1.0.0

6 years ago