Separate "Load from preset" into its own action in the tools menu #3605
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Problem
The current tools dropdown combines "Load from file/folder" and "Load from preset" into a single menu item that opens a modal with a toggle between the two modes. This creates a confusing user experience where users have to:
This doesn't make much sense from a UX perspective since these are fundamentally different actions that users want to perform directly.
Solution
This PR separates the combined action into two distinct menu items in the tools dropdown:
Changes
New Components
FileLoadModal.tsx
- Dedicated modal for file/folder importing using the existingFilePreset
componentPresetLoadModal.tsx
- Dedicated modal for preset loading using the existingDefaultPreset
componentUpdated Components
ToolsDropdown.tsx
- Now renders two separate menu items instead of one combined itemPresetModal
for the new workflowTranslation Updates
Added new translation keys in multiple languages:
loadFromFile
- "Load from file/folder"loadFromPreset
- "Load from preset"Test Updates
TokenBottomBar.test.tsx
to work with the new separate menu structureBenefits
The original
PresetModal
with its toggle functionality remains available for any other parts of the codebase that might need it, ensuring backward compatibility.Original prompt
✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.