Update React-scroll, getting rid of the need to manually set the url hash

This commit is contained in:
Fabio Berger
2018-08-01 17:33:28 +02:00
parent 9b24459108
commit 11869122b4
7 changed files with 12 additions and 22 deletions

View File

@@ -69,13 +69,13 @@ export class AnchorTitle extends React.Component<AnchorTitleProps, AnchorTitleSt
</div>
<ScrollLink
to={this.props.id}
hashSpy={true}
offset={headerSizeToScrollOffset[this.props.headerSize]}
duration={constants.DOCS_SCROLL_DURATION_MS}
containerId={constants.DOCS_CONTAINER_ID}
>
<i
className="zmdi zmdi-link"
onClick={utils.setUrlHash.bind(utils, this.props.id)}
style={{ ...styles.anchor, opacity }}
onMouseOver={this._setHoverState.bind(this, true)}
onMouseOut={this._setHoverState.bind(this, false)}