0.0.6 • Published 6 years ago
@cypherlab/react-stepbar v0.0.6
DEPRECATED check https://github.com/cypherlab/react-flow
@cypherlab/react-stepbar
Install
npm i @cypherlab/react-stepbarUsage
See Live demo
See Code example
import StepBar from '@cypherlab/react-stepbar'
const props = {
steps: ['Cart', 'Shipping', 'Recap', 'Payment']
, theme: 'dark'
, onRef: ref => (window['myStepBar'] = ref)
}
// render
<StepBar {...props} />
// ref usage
window['myStepBar'].setStep(3)Table options
| option | info |
|---|---|
| steps | steps data. array of anything. required |
| onRef | |
| onStep | |
| theme | predefined theme |
Methods
| option | info |
|---|---|
| setStep |
Test
You can play with the component in the browser via the index.html.
(yarn|npm) run dev