React Wizard Component
npm install
npm start
http://localhost:8000/examples/
online example: http://xuqingkuang.github.io/rc-wizard/
import React from 'react';
import Wizard from 'rc-wizard';
const Test = () => {
return (
<Wizard id="test" onDone={() => { alert('Wizard is done'); }}>
<Wizard.Step key="1">
I am the first page.
</Wizard.Step>
<Wizard.Step key="2">
I am the second page.
</Wizard.Step>
<Wizard.Step key="3">
I am the third page.
</Wizard.Step>
</Wizard>
)
}
React.render(<Test />, document.getElementById('container'));
name | type | default | description |
---|---|---|---|
id | String | Absolute identification | |
className | String | wizard | additional css class of root dom node |
displayKey | String | The key will be displayed by default | |
onDone | Function | Callback when the wizard is completed |
name | type | default | description |
---|---|---|---|
key | String | Required, unique "key" prop | |
onPrevious | Function | Callback for previous button clicked | |
onNext | Function | Callback for next button clicked |
npm test
npm run chrome-test
npm run coverage
open coverage/ dir
rc-wizard is released under the MIT license.