feat: AddFolder Modal

This commit is contained in:
Anoop M D
2022-03-13 19:59:10 +05:30
parent 33ff9e603b
commit 2f594835d8
5 changed files with 83 additions and 11 deletions

View File

@@ -76,7 +76,7 @@ const reducer = (state, action) => {
if(collection) {
collection.current.items.push({
"uid": nanoid(),
"name": "New Folder",
"name": action.folderName,
"depth": 1,
"items": []
});

View File

@@ -20,7 +20,8 @@ const useIdb = (dispatch) => {
type: actions.IDB_CONNECTION_READY,
connection: connection
});
});
})
.catch((err) => console.log(err));
}, []);
};