Commit d09a467
authored
feat: save last used project (#778)
### TL;DR
Update the task directory handling to persist the last used directory when changed in the TaskInput component.
### What changed?
- Added a new `setLastUsedDirectory` function to the `taskDirectoryStore`
- Updated the `TaskInput` component to call `setLastUsedDirectory` when a directory is selected
- This ensures the last used directory is properly saved when changed through the UI
### How to test?
1. Open the application and create a new task
2. Select a directory for the task
3. Create another new task
4. Verify that the previously selected directory is pre-selected
### Why make this change?
Previously, when a user selected a directory in the TaskInput component, the selection wasn't being saved to the store's `lastUsedDirectory` state. This change improves the user experience by remembering their last directory choice, making it faster to create multiple tasks in the same directory.1 parent 57d229a commit d09a467
2 files changed
Lines changed: 3 additions & 3 deletions
File tree
- apps/twig/src/renderer
- features/task-detail/components
- stores
Lines changed: 1 addition & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
70 | 70 | | |
71 | 71 | | |
72 | 72 | | |
73 | | - | |
| 73 | + | |
74 | 74 | | |
75 | 75 | | |
76 | 76 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
10 | 10 | | |
11 | 11 | | |
12 | 12 | | |
13 | | - | |
| 13 | + | |
14 | 14 | | |
15 | 15 | | |
16 | 16 | | |
| |||
52 | 52 | | |
53 | 53 | | |
54 | 54 | | |
55 | | - | |
| 55 | + | |
56 | 56 | | |
57 | 57 | | |
58 | 58 | | |
| |||
0 commit comments