- Notifications
You must be signed in to change notification settings - Fork1.1k
feat(site): add icons for .sh, .json, and .y[a]ml files in template editor#21171
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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
Uh oh!
There was an error while loading.Please reload this page.
Conversation
Added specific icons for common file types in the template file tree:- .sh files: TerminalIcon (terminal/shell scripts)- .json files: BracesIcon (JSON data files)- .yaml/.yml files: FileCodeIcon (YAML configuration files)These icons help users quickly identify file types at a glance.
eeb5a97 toc0cd338CompareThere 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.
Pull request overview
This PR enhances the template file tree UI by adding distinctive icons for three common file types (.sh, .json, .yaml/.yml) that previously had no specific visual representation. The implementation uses lucide-react icons (TerminalIcon, BracesIcon, FileCodeIcon) following the existing conditional logic pattern based on file extensions.
Key Changes:
- Added file type detection for .sh, .json, and .yaml/.yml files
- Imported three new icons from lucide-react library
- Extended icon assignment logic in the buildTreeItems function
💡Add Copilot custom instructions for smarter, more guided reviews.Learn how to get started.
Updated the main example story to include files with the new icons:- Shell scripts (.sh) - terminal icon- JSON files (.json) - braces icon- YAML files (.yml) - file code icon- Markdown (.md) and Dockerfile iconsThis shows all icon types in a single realistic file tree example.
333f052 to4dfbbfeCompareUh oh!
There was an error while loading.Please reload this page.
ed3bb76 intomainUh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
Added specific icons for common file types in the template file tree:
These icons help users quickly identify file types at a glance in the template editor.