Skip to content

Conversation

yuimbo
Copy link

@yuimbo yuimbo commented Oct 1, 2025

Summary

Allows iconUrl to point to assets hosted on the librechat instance (i.e. relative paths starting with / point to assets in client/public/)

Also when rendering an .svg as an icon, the file contents will be dynamically inserted into the DOM. This ensures curentColor still behaves correctly, allowing for icons that respond to light/dark mode.

Change Type

  • New feature (non-breaking change which adds functionality)

Testing

I followed these test steps:

  • Make one of your endpoints have the following configured: iconURL: "/assets/openai.svg"
  • Observe that it renders the OpenAI icon (The size looks a bit ugly, but that's just due to this particular asset having a hardcoded size)
  • Change dark/light theme
  • Observe that the icon's color changes accordingly

Checklist

Please delete any irrelevant options.

  • My code adheres to this project's style guidelines
  • I have performed a self-review of my own code
  • I have commented in any complex areas of my code
  • My changes do not introduce new warnings
  • Local unit tests pass with my changes

@petervcook
Copy link

Awesome addition. You wouldn't believe how much time I wasted earlier this year assuming this feature already existed, and trying to troubleshoot when it didn't work.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants