mirror of
https://github.com/discourse/discourse.git
synced 2025-02-21 03:19:10 +00:00
FIX: Firefox wasn't focusing on d-editor
This commit is contained in:
parent
40c8d39137
commit
83be335c54
@ -318,6 +318,9 @@ export default Ember.Component.extend({
|
||||
_selectText(from, length) {
|
||||
Ember.run.scheduleOnce('afterRender', () => {
|
||||
const textarea = this.$('textarea.d-editor-input')[0];
|
||||
if (!this.capabilities.isIOS) {
|
||||
textarea.focus();
|
||||
}
|
||||
textarea.selectionStart = from;
|
||||
textarea.selectionEnd = textarea.selectionStart + length;
|
||||
});
|
||||
|
Loading…
x
Reference in New Issue
Block a user