defaults to project folders; examining zones
This commit is contained in:
@ -42,15 +42,21 @@ window.electronAPI = {
|
||||
},
|
||||
|
||||
openProject: async (): Promise<string | null> => {
|
||||
const projectDir = await invoke<string>('get_projects_directory');
|
||||
const result = await open({
|
||||
multiple: false,
|
||||
defaultPath: projectDir,
|
||||
filters: PROJECT_FILTERS,
|
||||
});
|
||||
return typeof result === 'string' ? result : null;
|
||||
},
|
||||
|
||||
saveProject: async (): Promise<string | null> => {
|
||||
const result = await save({ filters: PROJECT_FILTERS });
|
||||
const projectDir = await invoke<string>('get_projects_directory');
|
||||
const result = await save({
|
||||
defaultPath: `${projectDir}/project.aive`,
|
||||
filters: PROJECT_FILTERS,
|
||||
});
|
||||
return result ?? null;
|
||||
},
|
||||
|
||||
|
||||
Reference in New Issue
Block a user