Changeset a744c90 for components/AddComponentDialog.tsx
- Timestamp:
- 01/28/26 12:13:13 (5 months ago)
- Branches:
- main
- Children:
- 1d8f088
- Parents:
- e03e6fb (diff), 87b79bc (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the(diff)links above to see all the changes relative to each parent. - File:
-
- 1 edited
-
components/AddComponentDialog.tsx (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
components/AddComponentDialog.tsx
re03e6fb ra744c90 20 20 ]; 21 21 22 export default function AddComponentDialog({ open, onClose, onSuccess }: {22 export default function AddComponentDialog({ open, onClose, onSuccess, prefillData }: { 23 23 open: boolean; 24 24 onClose: () => void; 25 25 onSuccess: () => void; 26 prefillData?: { 27 type?: string; 28 suggestionLink?: string; 29 suggestionDescription?: string; 30 }; 26 31 }) { 27 32 const [name, setName] = useState(''); … … 68 73 } 69 74 }, [type]); 75 76 useEffect(() => { 77 if (open && prefillData) { 78 if (prefillData.type) setType(prefillData.type); 79 } 80 }, [open, prefillData]); 70 81 71 82 const handleFieldChange = (fieldName: string, value: any) => {
Note:
See TracChangeset
for help on using the changeset viewer.
