(file)
| 37 | }; |
| 38 | |
| 39 | const openProjectFromFile = async (file) => { |
| 40 | const loaded = await readProjectFromFile(file); |
| 41 | setProject(loaded); |
| 42 | // The file represents a saved state — mark the recent entry as saved. |
| 43 | saveRecent(loaded, { lastSavedAt: new Date().toISOString() }); |
| 44 | return loaded; |
| 45 | }; |
| 46 | |
| 47 | // Resume a project from a stored recent snapshot (no file read). |
| 48 | const openProjectFromSnapshot = (snapshot) => { |
no test coverage detected