# rc-steps

> steps ui component for react

Latest version **6.0.1** (published 2023-07-19) · MIT license · 0 weekly downloads

## Install

```sh
npm install rc-steps
pnpm add rc-steps
yarn add rc-steps
bun add rc-steps
```

## Health

**Score 45/100 (D)** — status: abandoned.

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

Warnings: low downloads.

Negative: abandoned.

## Facts

| | |
|---|---|
| Version | 6.0.1 |
| Published | 2023-07-19 |
| First published | 2015-06-25 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | ESM + CommonJS |
| Node | >=8.x |
| Dependencies | 3 |
| Unpacked size | 47.1 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 332 |
| Maintainers | benjycui, yesmeck, zhujun24, afc163, yuhangge, yiminghe, ddcat1115, zombiej, 07akioni, madccc |
| Keywords | react, react-component, react-steps |

## Links

- npm: https://www.npmjs.com/package/rc-steps
- Repository:  git+ssh://git@github.com/react-component/steps
- Homepage: http://github.com/react-component/steps
- Issues: http://github.com/react-component/steps/issues
- npm.io page: https://npm.io/package/rc-steps

## Dependencies (3)

- [rc-util](https://npm.io/package/rc-util.md) ^5.16.1
- [classnames](https://npm.io/package/classnames.md) ^2.2.3
- [@babel/runtime](https://npm.io/package/@babel/runtime.md) ^7.16.7

## Alternatives

- [mobx-react](https://npm.io/package/mobx-react.md) — 2.8M weekly downloads
- [rc-tree](https://npm.io/package/rc-tree.md) — 2.6M weekly downloads
- [@react-oauth/google](https://npm.io/package/@react-oauth/google.md) — 1.3M weekly downloads
- [@wagmi/connectors](https://npm.io/package/@wagmi/connectors.md) — 877.0K weekly downloads
- [vee-validate](https://npm.io/package/vee-validate.md) — 836.4K weekly downloads

## Recent versions

- 6.0.1 (latest) — 2023-07-19
- 6.0.0 — 2022-12-29
- 6.0.0-alpha.2 — 2022-11-05
- 6.0.0-alpha.1 — 2022-11-02
- 6.0.0-alpha.0 — 2022-11-01
- 5.0.0 — 2022-11-01
- 5.0.0-alpha.2 — 2022-11-01
- 5.0.0-alpha.1 — 2022-11-01
- 5.0.0-alpha.0 — 2022-09-13
- 4.1.4 — 2021-09-27
- 4.1.3 — 2020-10-21
- 4.1.2 — 2020-07-27
- 4.1.0 — 2020-07-24
- 4.0.1 — 2020-06-22
- 4.0.0 — 2020-06-01
- … 59 more at https://npm.io/package/rc-steps/versions

## README

# rc-steps

---

React steps component.

[![NPM version][npm-image]][npm-url]
[![build status][travis-image]][travis-url]
[![Test coverage][codecov-image]][codecov-url]
[![npm download][download-image]][download-url]
[![bundle size][bundlephobia-image]][bundlephobia-url]

[npm-image]: http://img.shields.io/npm/v/rc-steps.svg?style=flat-square
[npm-url]: http://npmjs.org/package/rc-steps
[travis-image]: https://img.shields.io/travis/react-component/steps.svg?style=flat-square
[travis-url]: https://travis-ci.org/react-component/steps
[codecov-image]: https://img.shields.io/codecov/c/github/react-component/steps/master.svg?style=flat-square
[codecov-url]: https://codecov.io/gh/react-component/steps/branch/master
[download-image]: https://img.shields.io/npm/dm/rc-steps.svg?style=flat-square
[download-url]: https://npmjs.org/package/rc-steps
[bundlephobia-url]: https://bundlephobia.com/result?p=rc-steps
[bundlephobia-image]: https://badgen.net/bundlephobia/minzip/rc-steps

## Usage

```bash
npm install rc-steps
```

```jsx | pure
<Steps current={1}>
  <Steps.Step title="first" />
  <Steps.Step title="second" />
  <Steps.Step title="third" />
</Steps>
```

## Example

https://react-component.github.io/steps/

## API

<table class="table table-bordered table-striped">
  <thead>
    <tr>
      <th style="width: 100px;">name</th>
      <th style="width: 50px;">type</th>
      <th style="width: 50px;">default</th>
      <th>description</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <td>type</td>
      <td>string</td>
      <td>default</td>
      <td>diretypetion of Steps, could be `default` `navigation` `inline`</td>
    </tr>
    <tr>
      <td>direction</td>
      <td>string</td>
      <td>horizontal</td>
      <td>direction of Steps, enum: `horizontal` or `vertical`</td>
    </tr>
    <tr>
      <td>current</td>
      <td>number</td>
      <td>0</td>
      <td>index of current step</td>
    </tr>
    <tr>
      <td>initial</td>
      <td>number</td>
      <td>0</td>
      <td>index initial</td>
    </tr>
    <tr>
      <td>size</td>
      <td>string</td>
      <td></td>
      <td>size of Steps, could be `small`</td>
    </tr>
    <tr>
      <td>labelPlacement</td>
      <td>string</td>
      <td></td>
      <td>placement of step title, could be `vertical`</td>
    </tr>
    <tr>
      <td>status</td>
      <td>string</td>
      <td>wait</td>
      <td>status of current Steps, could be `error` `process` `finish` `wait`</td>
    </tr>
    <tr>
      <td>icons</td>
      <td>{ finish: ReactNode, error: ReactNode }</td>
      <td></td>
      <td>specify the default finish icon and error icon</td>
    </tr>
    <tr>
      <td>itemRender</td>
      <td>(item: StepProps, stepItem: React.ReactNode) => React.ReactNode</td>
      <td></td>
      <td>custom step item renderer</td>
    </tr>
    <tr>
      <td>onChange</td>
      <td>(current: number) => void</td>
      <td></td>
      <td>Trigger when Step changed</td>
    </tr>
  </tbody>
</table>

### Steps.Step

<table class="table table-bordered table-striped">
  <thead>
    <tr>
      <th style="width: 100px;">name</th>
      <th style="width: 50px;">type</th>
      <th style="width: 50px;">default</th>
      <th>description</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <td>title</td>
      <td>ReactNode</td>
      <td></td>
      <td>title of step item</td>
    </tr>
    <tr>
      <td>subTitle</td>
      <td>ReactNode</td>
      <td></td>
      <td>subTitle of step item</td>
    </tr>
    <tr>
      <td>description</td>
      <td>ReactNode</td>
      <td></td>
      <td>description of step item</td>
    </tr>
    <tr>
      <td>icon</td>
      <td>ReactNode</td>
      <td></td>
      <td>set icon of step item</td>
    </tr>
    <tr>
      <td>status</td>
      <td>string</td>
      <td></td>
      <td>status of current Steps, could be `error` `process` `finish` `wait`</td>
    </tr>
    <tr>
      <td>tailContent</td>
      <td>ReactNode</td>
      <td></td>
      <td>content above tail</td>
    </tr>
    <tr>
      <td>disabled</td>
      <td>bool</td>
      <td>false</td>
      <td>disabled step when onChange exist</td>
    </tr>
    <tr>
      <td>render</td>
      <td>(stepItem: React.ReactNode) => React.ReactNode</td>
      <td></td>
      <td>custom step item renderer</td>
    </tr>
  </tbody>
</table>

## Development

```
npm install
npm start
```

## License

rc-steps is released under the MIT license.

---
_Source: https://npm.io/package/rc-steps · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
