mirror of
https://gitcode.com/gh_mirrors/hy/Hydro.git
synced 2026-10-18 01:36:08 +08:00
ui: fix messagepad render, fix #1074
This commit is contained in:
4 files changed
+13
-20
No files matched your search
@@ -55,7 +55,7 @@ export default connect(mapStateToProps, mapDispatchToProps)(class MessagePadInpu
|
||||
);
|
||||
if (this.focusInput) {
|
||||
const { scrollX, scrollY } = window;
|
||||
this.refs.input.focus();
|
||||
this.state.ref?.focus();
|
||||
window.scrollTo(scrollX, scrollY);
|
||||
}
|
||||
}
|
||||
@@ -81,7 +81,7 @@ export default connect(mapStateToProps, mapDispatchToProps)(class MessagePadInpu
|
||||
<div className={cn}>
|
||||
<div className="messagepad__textarea-container">
|
||||
<textarea
|
||||
ref="input"
|
||||
ref={(ref) => this.setState({ ...this.state, ref })}
|
||||
data-markdown
|
||||
disabled={this.props.isPosting}
|
||||
value={this.props.inputValue}
|
||||
|
||||
Reference in new issue
Block a user