-
Notifications
You must be signed in to change notification settings - Fork 8.4k
feat: Allow renaming and deleting the Starter Project folder #11462
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
|
Important Review skippedAuto incremental reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the You can disable this status message by setting the
WalkthroughThese changes refactor the folder sidebar button components by removing the Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~10 minutes Important Pre-merge checks failedPlease resolve all errors before merging. Addressing warnings is optional. ❌ Failed checks (2 warnings, 1 inconclusive)
✅ Passed checks (4 passed)
✨ Finishing touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Codecov Report✅ All modified and coverable lines are covered by tests. ❌ Your project check has failed because the head coverage (41.55%) is below the target coverage (60.00%). You can increase the head coverage or adjust the target coverage. Additional details and impacted files@@ Coverage Diff @@
## main #11462 +/- ##
==========================================
- Coverage 34.88% 34.85% -0.04%
==========================================
Files 1420 1420
Lines 68215 68179 -36
Branches 9984 9974 -10
==========================================
- Hits 23797 23762 -35
- Misses 43184 43193 +9
+ Partials 1234 1224 -10
Flags with carried forward coverage won't be shown. Click here to find out more.
🚀 New features to boost your workflow:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 0
Caution
Some comments are outside the diff and can’t be posted inline due to platform limitations.
⚠️ Outside diff range comments (1)
src/frontend/src/components/core/folderSidebarComponent/components/sideBarFolderButtons/components/select-options.tsx (1)
15-27: Guard against undefined delete handler or make it required.Delete is now always visible, but
handleDeleteFolderis optional in the prop definition. InhandleSelectChange(line 12), the handler is invoked with the non-null assertion operator!without checking if it's defined. Selecting Delete when the handler isundefinedwill throw a runtime error. Either:
- Make
handleDeleteFolderrequired in the prop type, or- Guard the delete case in
handleSelectChangeto check if the handler exists before calling it
Jira: LE-118
GH Issue: #8174
This pull request simplifies the logic for handling folder actions in the sidebar by removing checks and dependencies related to the default folder name and folder index. Now, actions like renaming and deleting folders are always available, regardless of the folder type or position. This streamlines the user experience and reduces unnecessary code.
Sidebar folder actions simplification:
useUtilityStoreand thedefaultFolderNamecheck in bothselect-options.tsxandindex.tsx, so the rename and delete options are now always shown for all folders. [1] [2] [3] [4] [5] [6]indexprop inSelectOptionsand its associated logic, allowing delete actions for all folders regardless of their position in the list. [1] [2] [3]Summary by CodeRabbit
Bug Fixes
Improvements
✏️ Tip: You can customize this high-level summary in your review settings.