mirror of
https://github.com/flarum/core.git
synced 2025-07-28 04:00:40 +02:00
Refactor Composer rendering for smoother animations
Also fixes a couple of miscellaneous bugs: - Minimise the Composer when clicking the preview button in full-screen mode on desktop. - Minimise the Composer when clicking the link to the discussion/post in the header on mobile/full-screen mode.
This commit is contained in:
@@ -19,7 +19,7 @@ export default class TextEditor extends Component {
|
||||
/**
|
||||
* The value of the textarea.
|
||||
*
|
||||
* @type {[type]}
|
||||
* @type {String}
|
||||
*/
|
||||
this.value = m.prop(this.props.value || '');
|
||||
}
|
||||
@@ -27,14 +27,14 @@ export default class TextEditor extends Component {
|
||||
view() {
|
||||
return (
|
||||
<div className="TextEditor">
|
||||
<textarea className="FormControl TextEditor-flexible"
|
||||
<textarea className="FormControl Composer-flexible"
|
||||
config={this.configTextarea.bind(this)}
|
||||
oninput={m.withAttr('value', this.oninput.bind(this))}
|
||||
placeholder={this.props.placeholder || ''}
|
||||
disabled={!!this.props.disabled}
|
||||
value={this.value()}/>
|
||||
|
||||
<ul className="TextEditor-controls">
|
||||
<ul className="TextEditor-controls Composer-footer">
|
||||
{listItems(this.controlItems().toArray())}
|
||||
</ul>
|
||||
</div>
|
||||
|
Reference in New Issue
Block a user