mirror of
https://github.com/danny-avila/LibreChat.git
synced 2026-11-16 13:00:55 +00:00
* feat: pick the deployment theme in librechat.yaml Add `interface.theme` to the config schema, accepting a bundled theme name or an inline theme definition. The interface loader passes it through, the pre-login config payload carries it so the login page paints it, and a DeploymentTheme wrapper around ThemeProvider resolves and validates it and applies it without persisting it over the user's stored theme. * fix: restore the user theme when the deployment theme is withdrawn Move the pre-login interface selection out of the /api route into buildPreLoginInterface in packages/api, so the route only wires it up. When an authenticated config drops interface.theme (a principal override tombstoning it), hand ThemeProvider the user's stored theme instead of clearing to the LibreChat palette. The e2e scenarios now cover inline and invalid themes, the withdrawn case, and high-contrast precedence. * fix: read a legacy stored theme behind a corrupt stored definition * perf: rebind the deployment theme observer on a cache add, not every event useIsFetching recomputed the fetch count across every query on each cache event, which slowed streamed renders enough to break the highlight-throttle scenario. Subscribe to the query cache and re-render only when a startup config query is rebuilt. * test: wait for the composer after sign-in so mobile runs pass * fix: keep deployment themes whole and restore legacy themes as legacy A principal override with an inline theme merged into the base theme, keeping the base's other mode, brands and tokens; interfaceConfig.theme now replaces whole during override merging. A withdrawn deployment theme restored a legacy-source stored theme as a versioned definition, dropping its colors in dark mode; it now goes back through ThemeProvider's legacy color path. * fix: persist the user's theme changes after the deployment theme is withdrawn Persistence now stays off only while a deployment theme is applied and for the render that restores the stored theme, so later changes through the theme API are saved again. * refactor: derive deployment theme persistence from the current theme |
||
|---|---|---|
| .. | ||
| controllers | ||
| middleware | ||
| routes | ||
| services | ||
| utils | ||
| cleanup.js | ||
| csp.spec.js | ||
| experimental.js | ||
| experimental.spec.js | ||
| index.js | ||
| index.metrics.spec.js | ||
| index.spec.js | ||
| socialLogins.js | ||
| socialLogins.spec.js | ||
| telemetry.js | ||
| telemetry.spec.js | ||