fix(editor): ai chat panel textarea selection issue (#10461)

fix AF-2244
This commit is contained in:
pengx17
2025-02-27 02:26:57 +00:00
parent 3252dd7a31
commit f25266ec88

View File

@@ -303,9 +303,11 @@ export class ChatPanelInput extends SignalWatcher(WithDisposable(LitElement)) {
<div <div
class="chat-panel-input" class="chat-panel-input"
@pointerdown=${(e: MouseEvent) => { @pointerdown=${(e: MouseEvent) => {
// by default the div will be focused and will blur the textarea if (e.target !== this.textarea) {
e.preventDefault(); // by default the div will be focused and will blur the textarea
this.textarea.focus(); e.preventDefault();
this.textarea.focus();
}
}} }}
> >
${hasImages ${hasImages