[WEB-1974] fix: images getting replaced on resize (#5233)
* fix: image resizer error * refactor: created common function to get the active image element * fix: build errors
This commit is contained in:
parent
6bb534dabc
commit
518327e380
22 changed files with 129 additions and 88 deletions
|
|
@ -72,6 +72,7 @@ export const AddComment: React.FC<Props> = observer((props) => {
|
|||
workspaceId={workspaceID?.toString() ?? ""}
|
||||
workspaceSlug={workspaceSlug?.toString() ?? ""}
|
||||
ref={editorRef}
|
||||
id="peek-overview-add-comment"
|
||||
initialValue={
|
||||
!value || value === "" || (typeof value === "object" && Object.keys(value).length === 0)
|
||||
? watch("comment_html")
|
||||
|
|
|
|||
|
|
@ -105,6 +105,7 @@ export const CommentCard: React.FC<Props> = observer((props) => {
|
|||
workspaceSlug={workspaceSlug?.toString() ?? ""}
|
||||
onEnterKeyPress={() => handleSubmit(handleCommentUpdate)()}
|
||||
ref={editorRef}
|
||||
id={comment.id}
|
||||
initialValue={value}
|
||||
value={null}
|
||||
onChange={(comment_json, comment_html) => onChange(comment_html)}
|
||||
|
|
@ -132,7 +133,7 @@ export const CommentCard: React.FC<Props> = observer((props) => {
|
|||
</div>
|
||||
</form>
|
||||
<div className={`${isEditing ? "hidden" : ""}`}>
|
||||
<LiteTextReadOnlyEditor ref={showEditorRef} initialValue={comment.comment_html} />
|
||||
<LiteTextReadOnlyEditor ref={showEditorRef} id={comment.id} initialValue={comment.comment_html} />
|
||||
<CommentReactions anchor={anchor} commentId={comment.id} />
|
||||
</div>
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -26,6 +26,7 @@ export const PeekOverviewIssueDetails: React.FC<Props> = observer((props) => {
|
|||
<h4 className="break-words text-2xl font-medium">{issueDetails.name}</h4>
|
||||
{description !== "" && description !== "<p></p>" && (
|
||||
<RichTextReadOnlyEditor
|
||||
id={issueDetails.id}
|
||||
initialValue={
|
||||
!description ||
|
||||
description === "" ||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue