aboutsummaryrefslogtreecommitdiffhomepage
path: root/client/src/app/+videos/+video-watch/comment/video-comment-add.component.ts
diff options
context:
space:
mode:
authorKimsible <2324615-kimsible@users.noreply.gitlab.com>2020-11-06 17:40:40 +0100
committerRigel Kent <par@rigelk.eu>2020-11-06 18:14:15 +0100
commit6a9498e37cbda01414b8accf3fdcac410f893500 (patch)
tree24fcef83cec2da4acb03002164418ef55d60c7f9 /client/src/app/+videos/+video-watch/comment/video-comment-add.component.ts
parent61379e431115ab9d7c200852afcccf6ab94064d5 (diff)
downloadPeerTube-6a9498e37cbda01414b8accf3fdcac410f893500.tar.gz
PeerTube-6a9498e37cbda01414b8accf3fdcac410f893500.tar.zst
PeerTube-6a9498e37cbda01414b8accf3fdcac410f893500.zip
Correct break line display for re-draft comments
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.ts4
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 })