mirror of
https://github.com/makeplane/plane
synced 2024-06-14 14:31:34 +00:00
fixed modal form issue
This commit is contained in:
parent
ff29c1c87e
commit
99618e93a7
@ -379,30 +379,23 @@ export const IssueForm: FC<IssueFormProps> = (props) => {
|
|||||||
<Controller
|
<Controller
|
||||||
name="description_html"
|
name="description_html"
|
||||||
control={control}
|
control={control}
|
||||||
render={({ field: { value, onChange } }) => {
|
render={({ field: { value, onChange } }) => (
|
||||||
if (!value && !watch("description_html")) return <></>;
|
|
||||||
|
|
||||||
return (
|
|
||||||
<RichTextEditorWithRef
|
<RichTextEditorWithRef
|
||||||
uploadFile={fileService.getUploadFileFunction(workspaceSlug as string)}
|
uploadFile={fileService.getUploadFileFunction(workspaceSlug as string)}
|
||||||
deleteFile={fileService.deleteImage}
|
deleteFile={fileService.deleteImage}
|
||||||
ref={editorRef}
|
ref={editorRef}
|
||||||
debouncedUpdatesEnabled={false}
|
debouncedUpdatesEnabled={false}
|
||||||
value={
|
value={!value ||
|
||||||
!value ||
|
value === "" ||
|
||||||
value === "" ||
|
(typeof value === "object" && Object.keys(value).length === 0)
|
||||||
(typeof value === "object" && Object.keys(value).length === 0)
|
? watch("description_html")
|
||||||
? watch("description_html")
|
: value}
|
||||||
: value
|
customClassName="min-h-[150px]"
|
||||||
}
|
onChange={(description: Object, description_html: string) => {
|
||||||
customClassName="min-h-[150px]"
|
onChange(description_html);
|
||||||
onChange={(description: Object, description_html: string) => {
|
setValue("description", description);
|
||||||
onChange(description_html);
|
} } />
|
||||||
setValue("description", description);
|
)}
|
||||||
}}
|
|
||||||
/>
|
|
||||||
);
|
|
||||||
}}
|
|
||||||
/>
|
/>
|
||||||
<GptAssistantModal
|
<GptAssistantModal
|
||||||
isOpen={gptAssistantModal}
|
isOpen={gptAssistantModal}
|
||||||
|
Loading…
Reference in New Issue
Block a user