mirror of
https://github.com/vector-im/element-web.git
synced 2024-11-18 06:35:35 +08:00
Adjust the scroll position when the gemini panel is resized
Make sure we restore the scroll state of the message panel when it is resized
This commit is contained in:
parent
8a4a810d1f
commit
61cd66304e
@ -33,7 +33,7 @@
|
|||||||
"q": "^1.4.1",
|
"q": "^1.4.1",
|
||||||
"react": "^0.14.2",
|
"react": "^0.14.2",
|
||||||
"react-dom": "^0.14.2",
|
"react-dom": "^0.14.2",
|
||||||
"react-gemini-scrollbar": "matrix-org/react-gemini-scrollbar#d9a808d",
|
"react-gemini-scrollbar": "matrix-org/react-gemini-scrollbar#3ee2648",
|
||||||
"sanitize-html": "^1.11.1",
|
"sanitize-html": "^1.11.1",
|
||||||
"velocity-animate": "^1.2.3",
|
"velocity-animate": "^1.2.3",
|
||||||
"velocity-ui-pack": "^1.2.2"
|
"velocity-ui-pack": "^1.2.2"
|
||||||
|
@ -470,7 +470,8 @@ module.exports = React.createClass({
|
|||||||
// TODO: the classnames on the div and ol could do with being updated to
|
// TODO: the classnames on the div and ol could do with being updated to
|
||||||
// reflect the fact that we don't necessarily contain a list of messages.
|
// reflect the fact that we don't necessarily contain a list of messages.
|
||||||
// it's not obvious why we have a separate div and ol anyway.
|
// it's not obvious why we have a separate div and ol anyway.
|
||||||
return (<GeminiScrollbar autoshow={true} ref="geminiPanel" onScroll={ this.onScroll }
|
return (<GeminiScrollbar autoshow={true} ref="geminiPanel"
|
||||||
|
onScroll={this.onScroll} onResize={this.checkScroll}
|
||||||
className={this.props.className} style={this.props.style}>
|
className={this.props.className} style={this.props.style}>
|
||||||
<div className="mx_RoomView_messageListWrapper">
|
<div className="mx_RoomView_messageListWrapper">
|
||||||
<ol ref="itemlist" className="mx_RoomView_MessageList" aria-live="polite">
|
<ol ref="itemlist" className="mx_RoomView_MessageList" aria-live="polite">
|
||||||
|
Loading…
Reference in New Issue
Block a user