mirror of
https://github.com/stan-smith/FossFLOW.git
synced 2025-12-23 22:48:57 -05:00
feat: add click-based connector creation mode with empty space support (#108)
* fix: eliminate re-render loop causing export failures - Remove onModelUpdated callback that triggered infinite re-render cycles - Replace debounce hack with controlled useEffect-based export timing - Ensure DOM stability before export execution to prevent null containerRef - Add isExporting guard to prevent concurrent export operations Resolves issue where image export functionality was completely broken due to infinite re-rendering caused by onModelUpdated callback. Fixes #84 * Update packages/fossflow-lib/src/components/ExportImageDialog/ExportImageDialog.tsx Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> * Fixed connectors * Fix duplicate downloadFile --------- Co-authored-by: Manfred Michaelis <mm@michm.de> Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> Co-authored-by: Stan <stanleylsmith@pm.me>
This commit is contained in:
@@ -105,6 +105,7 @@ export const ExportImageDialog = ({ onClose, quality = 1.5 }: Props) => {
|
||||
}, 100);
|
||||
|
||||
return () => clearTimeout(timer);
|
||||
|
||||
}, [showGrid, backgroundColor]);
|
||||
|
||||
const downloadFile = useCallback(() => {
|
||||
@@ -117,7 +118,6 @@ export const ExportImageDialog = ({ onClose, quality = 1.5 }: Props) => {
|
||||
|
||||
downloadFileUtil(data, generateGenericFilename('png'));
|
||||
}, [imageData]);
|
||||
>>>>>>> 10145c9 (fix: eliminate re-render loop causing export failures)
|
||||
|
||||
useEffect(() => {
|
||||
const timer = setTimeout(() => {
|
||||
|
||||
Reference in New Issue
Block a user