mirror of
https://github.com/discourse/discourse.git
synced 2025-05-25 00:32:52 +08:00
FIX: don't steal focus when text in editor is replaced (#6712)
This commit is contained in:
@ -804,6 +804,10 @@ composerTestCase("replace-text event for composer", async function(assert) {
|
||||
assert,
|
||||
textarea
|
||||
) {
|
||||
const focusEvent = $.Event("focus");
|
||||
const $input = $('textarea.d-editor-input');
|
||||
$input.trigger(focusEvent);
|
||||
|
||||
this.set("value", BEFORE);
|
||||
await setSelection(textarea, CASE.before);
|
||||
|
||||
|
Reference in New Issue
Block a user