Compare commits

...

1 Commits

Author SHA1 Message Date
Arik Chakma
a5edae2e04 fix: todo uncheck 2024-07-10 23:59:11 +06:00
2 changed files with 8 additions and 3 deletions

View File

@@ -62,7 +62,10 @@ export function FlowRoadmapRenderer(props: FlowRoadmapRendererProps) {
}
const handleTopicRightClick = useCallback((e: MouseEvent, node: Node) => {
const target = e?.currentTarget as HTMLDivElement;
const target =
node?.type === 'todo'
? document.querySelector(`[data-id="${node.id}"]`)
: (e?.currentTarget as HTMLDivElement);
if (!target) {
return;
}

View File

@@ -161,7 +161,10 @@ export function MemberCustomProgressModal(props: ProgressMapProps) {
return;
}
const target = e?.currentTarget as HTMLDivElement;
const target =
node?.type === 'todo'
? document.querySelector(`[data-id="${node.id}"]`)
: (e?.currentTarget as HTMLDivElement);
if (!target) {
return;
}
@@ -237,7 +240,6 @@ export function MemberCustomProgressModal(props: ProgressMapProps) {
<div className="px-4 pb-2">
<ReadonlyEditor
variant="modal"
hasMinimap={false}
roadmap={roadmap!}
className="min-h-[400px]"
onRendered={() => {