Skip to content

Commit

Permalink
Merge pull request #42 from AngelVenchev/develop
Browse files Browse the repository at this point in the history
Add positioning params to progress
  • Loading branch information
colbymillerdev authored May 18, 2020
2 parents d818410 + 452d48e commit a810d4a
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 3 deletions.
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -149,6 +149,8 @@ render() {
| completedCheckColor | Color of the completed step checkmark | white | String |
| activeStep | Manually specify the active step | 0 | Number |
| isComplete | Set all Steps to active state | false | Boolean |
| topOffset | Set progress bar top offset | 30 | Number |
| marginBottom | Set progress bar bottom margin | 50 | Number |

### Progress Step Component
| Name | Description | Default | Type |
Expand Down
8 changes: 6 additions & 2 deletions src/ProgressSteps/ProgressSteps.js
Original file line number Diff line number Diff line change
Expand Up @@ -71,8 +71,8 @@ class ProgressSteps extends Component {
justifyContent: 'space-evenly',
alignSelf: 'center',
flexDirection: 'row',
top: 30,
marginBottom: 50,
top: this.props.topOffset,
marginBottom: this.props.marginBottom,
},
};

Expand All @@ -94,11 +94,15 @@ class ProgressSteps extends Component {
ProgressSteps.propTypes = {
isComplete: PropTypes.bool,
activeStep: PropTypes.number,
topOffset: PropTypes.number,
marginBottom: PropTypes.number,
};

ProgressSteps.defaultProps = {
isComplete: false,
activeStep: 0,
topOffset: 30,
marginBottom: 50,
};

export default ProgressSteps;
1 change: 0 additions & 1 deletion src/ProgressSteps/StepIcon.js
Original file line number Diff line number Diff line change
Expand Up @@ -167,7 +167,6 @@ class StepIcon extends Component {
StepIcon.propTypes = {
stepCount: PropTypes.number.isRequired,
stepNum: PropTypes.number.isRequired,
label: PropTypes.string.isRequired,
isFirstStep: PropTypes.bool.isRequired,
isLastStep: PropTypes.bool.isRequired,

Expand Down

0 comments on commit a810d4a

Please sign in to comment.