diff options
Diffstat (limited to 'client/src/app/+videos/+video-watch/comment/video-comment-add.component.ts')
-rw-r--r-- | client/src/app/+videos/+video-watch/comment/video-comment-add.component.ts | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/client/src/app/+videos/+video-watch/comment/video-comment-add.component.ts b/client/src/app/+videos/+video-watch/comment/video-comment-add.component.ts index c1d0032cc..d746a614b 100644 --- a/client/src/app/+videos/+video-watch/comment/video-comment-add.component.ts +++ b/client/src/app/+videos/+video-watch/comment/video-comment-add.component.ts | |||
@@ -183,7 +183,11 @@ export class VideoCommentAddComponent extends FormReactive implements OnChanges, | |||
183 | this.textareaElement.nativeElement.focus() | 183 | this.textareaElement.nativeElement.focus() |
184 | } | 184 | } |
185 | 185 | ||
186 | // Scroll to textarea | ||
186 | this.textareaElement.nativeElement.scrollIntoView({ behavior: 'smooth', block: 'center', inline: 'nearest' }) | 187 | this.textareaElement.nativeElement.scrollIntoView({ behavior: 'smooth', block: 'center', inline: 'nearest' }) |
188 | |||
189 | // Use the native textarea autosize according to the text's break lines | ||
190 | this.textareaElement.nativeElement.dispatchEvent(new Event('input')) | ||
187 | }) | 191 | }) |
188 | 192 | ||
189 | this.form.patchValue({ text }) | 193 | this.form.patchValue({ text }) |