Просмотр исходного кода

Merge pull request #14746 from overleaf/td-review-panel-empty-comment-edit

React review panel: populate comment box when editing

GitOrigin-RevId: ba284bd419dd507eef17847b5f4c55b8fd8338f5
Tim Down 3 лет назад
Родитель
Сommit
1dc3d12c1d

+ 1 - 0
services/web/frontend/js/features/source-editor/components/review-panel/entries/comment.tsx

@@ -67,6 +67,7 @@ function Comment({ thread, threadId, comment }: CommentProps) {
         {editing ? (
         {editing ? (
           <AutoExpandingTextArea
           <AutoExpandingTextArea
             className="rp-comment-input"
             className="rp-comment-input"
+            defaultValue={comment.content}
             onKeyPress={handleSaveEditOnEnter}
             onKeyPress={handleSaveEditOnEnter}
             onBlur={handleSaveEdit}
             onBlur={handleSaveEdit}
             onClick={e => e.stopPropagation()}
             onClick={e => e.stopPropagation()}