mirror of https://github.com/vector-im/riot-web
Fix local echo comment for scroll tokens
Co-authored-by: Michael Telatynski <7t3chguy@gmail.com>pull/21833/head
parent
d111f4cbb1
commit
ea6904ce2a
|
@ -906,6 +906,8 @@ export default class EventTile extends React.Component<IProps, IState> {
|
|||
permalink = this.props.permalinkCreator.forEvent(this.props.mxEvent.getId());
|
||||
}
|
||||
|
||||
// we can't use local echoes as scroll tokens, because their event IDs change.
|
||||
// Local echos have a send "status".
|
||||
const scrollToken = this.props.mxEvent.status
|
||||
? undefined
|
||||
: this.props.mxEvent.getId();
|
||||
|
@ -1153,8 +1155,6 @@ export default class EventTile extends React.Component<IProps, IState> {
|
|||
"tabIndex": -1,
|
||||
"aria-live": ariaLive,
|
||||
"aria-atomic": "true",
|
||||
// we can't use local echoes as scroll tokens, because their event IDs change.
|
||||
// Local echos have a send "status".
|
||||
"data-scroll-tokens": scrollToken,
|
||||
"onMouseEnter": () => this.setState({ hover: true }),
|
||||
"onMouseLeave": () => this.setState({ hover: false }),
|
||||
|
|
Loading…
Reference in New Issue