feat: implement code download functionality - Add download code funct…
feat: implement code download functionality
Add download code functionality to project breadcrumb, Update editor sandbox to support code export, Add localization strings for download feature. Resolves #1983
Description
This PR implements the code download functionality that allows users to download their project code directly from the Onlook interface. The feature adds a download button to the project breadcrumb component and integrates with the editor sandbox to export the current project state as downloadable code.
Key changes:
- Added download button and functionality to the project breadcrumb component
- Enhanced the editor sandbox to support code export capabilities
- Added proper localization strings for the download feature to support internationalization
- Implemented proper error handling and user feedback for the download process
Related Issues
Closes #1983
Type of Change
- [ ] Bug fix
- [x] New feature
- [ ] Documentation update
- [ ] Release
- [ ] Refactor
- [ ] Other (please describe):
Testing
- Verified download button appears in project breadcrumb
- Tested download functionality triggers properly
- Confirmed localization strings are properly loaded
- Verified editor sandbox integration works correctly
- Tested with different project states and configurations
- Ensured no regressions in existing functionality
Manual testing steps:
- Open a project in Onlook
- Navigate to the project breadcrumb area
- Click the download button
- Verify code is properly exported and downloaded
- Check that all UI text displays correctly (localization)
Screenshots (if applicable)
https://github.com/user-attachments/assets/8d328bc6-dcff-4627-a3b4-8ff6a3df6ca6
Additional Notes
- This feature enhances the developer experience by providing easy access to export project code
- The implementation follows existing patterns in the codebase for consistency
- Localization support ensures the feature works across different languages
- The download functionality integrates seamlessly with the existing editor workflow
@Rish-it is attempting to deploy a commit to the Onlook Team on Vercel.
A member of the Team first needs to authorize it.