-
Notifications
You must be signed in to change notification settings - Fork 1.1k
feat: implement DEPRECATED_ICONS
#21346
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
This stack of pull requests is managed by Graphite. Learn more about stacking. |
aslilac
left a comment
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.
I think we could get rid of the const iconsWithoutSuffix but other than that this looks good
|
|
||
| const iconsWithoutSuffix = icons.map((icon) => icon.split(".")[0]); | ||
| const filteredIcons = icons.filter((icon) => !DEPRECATED_ICONS.includes(icon)); | ||
| const iconsWithoutSuffix = filteredIcons.map((icon) => icon.split(".")[0]); |
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.
super nit: this could strip more than just the file extension if we wanted to add a file like "coder.ai.svg"
maybe not the best example but also not that far fetched lol
the more "rigorous" thing to do would be like this:
const dotIndex = icon.lastIndexOf(".");
return dotIndex > 0 ? icon.slice(0, dotIndex) : icon;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.
actually wait, does this value even get used anywhere? what is this for?
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.
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.
oh, I misread the diff originally and didn't realize this was already in here. this code is my fault. 💀 anyway, can we fix it pls?



Closes #21320
This PR introduces a list of deprecated icons that should no longer be displayed in the UI. These icons are kept for backward compatibility but are now filtered out from:
The deprecated icons include:
apple-grey.svg→apple-black.svg)aws.png→aws.svg)docker-white.svg)