Skip to content

Commit

Permalink
feat(Affix): receive the change of offset props
Browse files Browse the repository at this point in the history
  • Loading branch information
jinchanz committed Jan 28, 2019
1 parent c2e84cf commit f190bc7
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/affix/index.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,11 @@ class Affix extends React.Component {
});
}

componentWillReceiveProps(props) {
this.affixMode = this._getAffixMode(props);
this.updatePosition();
}

componentWillUnmount() {
if (this.timeout) {
clearTimeout(this.timeout);
Expand Down

0 comments on commit f190bc7

Please sign in to comment.