# react-step-progress-bar-line

> progress bar with delimited sections

Latest version **1.0.0** (published 2021-09-16) · MIT license · 0 weekly downloads

## Install

```sh
npm install react-step-progress-bar-line
pnpm add react-step-progress-bar-line
yarn add react-step-progress-bar-line
bun add react-step-progress-bar-line
```

## Health

**Score 30/100 (F)** — status: abandoned.

Positive: has types; esm support; no vulnerabilities; high quality score.

Warnings: low downloads.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.0 |
| Published | 2021-09-16 |
| First published | 2021-09-16 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | ESM + CommonJS |
| Dependencies | 1 |
| Unpacked size | 23.8 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 0 |
| Author | webster6667 |
| Maintainers | webster6667 |

## Links

- npm: https://www.npmjs.com/package/react-step-progress-bar-line
- Repository: https://github.com/webster6667/react-step-progress-bar-line
- Homepage: https://github.com/webster6667/react-step-progress-bar-line#readme
- Issues: https://github.com/webster6667/react-step-progress-bar-line/issues
- npm.io page: https://npm.io/package/react-step-progress-bar-line

## Dependencies (1)

- [@babel/runtime](https://npm.io/package/@babel/runtime.md) ^7.14.0

## Recent versions

- 1.0.0 (latest) — 2021-09-16

## README

<p align="center" style="text-align:center">
    <img src="./illustration.svg" alt="illustration" width="100"/>
</p>

# react-step-progress-bar-line

> progress bar with delimited sections

[![npm version](https://badge.fury.io/js/react-step-progress-bar-line.svg)](https://www.npmjs.com/package/react-step-progress-bar-line)

### Install

```shell
npm i react-step-progress-bar-line
```

import component styles to main scss style
```scss
@import "~react-line-progress-bar/dist/style/index.css";


//add your animation setting for line move
.progress-bar__line {
  transition: transform 0.5s 0s ease;
}

```

```typescript jsx
import React, {useState} from 'react'
import ReactDOM from 'react-dom'

import {useStepProgressBar, StepProgressBarLine} from 'react-step-progress-bar-line'

export default function Index() {

    const [activeStep, sections, nextStep, prevStep] = useStepProgressBar({
        activeStep: 0,
        sections: [
            {
                stepsCount: 2
            },
            {
                stepsCount: 3
            },
            {
                stepsCount: 5
            },
        ],
        stepChangeCallback: (step) => {
            console.log('change',step);

            return true
        },
        finishCallback: () => {
            alert('finish');

            return true
        }
    })

    
    return (
        <div >

            <StepProgressBarLine activeStep={activeStep} sections={sections} />

            <button onClick={prevStep}>
                Prev
            </button>

            <button onClick={nextStep}>
                Nxt
            </button>


        </div>
    )

}

```

## Author

webster6667

---
_Source: https://npm.io/package/react-step-progress-bar-line · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
