Fix 9 dashboard bugs: menu flicker, sync, test gating, toast, ollama cloud, key persistence, modal close, GLM validate, combo multi-select#61
Merged
Conversation
…, ollama cloud models, key persistence, modal outside-click, validation, combo multi-select
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Fixes 9 reported UX/correctness bugs across the dashboard and provider sync layer.
Bug 1 — Menu flicker on load. The sidebar collapsed/expanded width was decided client-side, so the first paint shipped a wide rail that snapped to narrow once
useStaterehydrated. Added an SSR-aware initial width (read from cookie) so the first paint matches the persisted state. Files:web/src/layouts/Layout.astro,web/src/shared/components/Sidebar.tsx,web/src/shared/components/layouts/DashboardLayout.tsx.Bug 2 — Sync from 9router incomplete. The catalog file
src/core/model/sources/9router.jsonwas missing the Ollama Cloud*:cloudmodels (and other recent additions) that exist upstream at https://github.com/decolua/9router. Regenerated the source catalog with the missing models and propagated them through tosrc/core/model/provider_catalog.json. Sync logic itself was sound; the gap was the inputs.Bug 3 — "Test all" clickable with zero providers. Both
ProvidersPageClientandConnectionsCardnow disable the per-section "Test all" button when no provider connections exist for that provider/section.Bug 4 — Toast styling out of place. Restyled the toast container to use the same surface tokens, border radii, and typography as the rest of the dashboard (
web/src/shared/components/styles/global.css).Bug 5 — Ollama needs cloud model suggestions. Added the new Ollama
:cloudmodels (deepseek-v4-flash:cloud,deepseek-v4-pro:cloud,glm-5.1:cloud,kimi-k2.6:cloud,minimax-m2.7:cloud,qwen3.5:cloud) to bothprovider_catalog.jsonand9router.jsonso the Ollama provider page surfaces them as suggestions.Bug 6 — API key lost when reopening edit modal. The backend was returning provider connections with
apiKeyredacted, so the dashboard couldn't tell whether a key was already on file vs. blank. Added ahasApiKeyboolean stamp insrc/server/api/mod.rs(without ever returning the secret).EditConnectionModalnow renders a masked "•••• on file" placeholder and a smart submit button: if a key is already saved and the user didn't type a new one, it tests the saved key instead of overwriting it with empty. The cleartext key is never sent back over the wire.Bug 7 — Modal closes on outside click. Changed the default
closeOnOverlaybehavior inModal.tsxtofalse. Sites that explicitly want overlay-close opt in; everywhere else, modals only close via Cancel / X / Escape.Bug 8 — GLM/Kimi/MiniMax validation always invalid + ugly browser alerts. Root cause: the Anthropic-compatible providers were being validated against the default Anthropic endpoint, so a valid GLM key always failed.
provider_validate.rsnow falls back to provider-specific endpoints (api.z.ai,api.kimi.com,api.minimax.io,api.minimaxi.com) when no custom base URL is configured, and actually sends a small/messagespayload so the auth round-trips. Also widened the model-test success check inproviders.rsto accept Anthropic (content[]) and Gemini (candidates[]) shapes, not just OpenAIchoices[]. On the UX side, replaced everyconfirm()/alert()in the providers, connections, endpoint, db-backups, provider-limits, pricing, and compatible-models surfaces with the in-appConfirmModal+ notification store, so the "delete model" flow opens a proper modal instead of the OS alert.Bug 9 — Combo selection + leftover Profile page.
closeOnSelect={false}).ModelSelectModalhighlights already-selected entries when reopened, so previous picks are visible.Modalchrome withsize="lg"./dashboard/profilepage and its sidebar entry.Review & Testing Checklist for Human
z.aikey into the GLM connection, save, reopen the modal (key should show masked "on file"), click Test → expect green pass; then click Test on a model row → expect green pass. Then delete the connection → expect the in-app red confirm modal, not the browser alert.deepseek-v4-flash:cloud,kimi-k2.6:cloud,glm-5.1:cloud,minimax-m2.7:cloud,qwen3.5:cloud, etc.) show up under/dashboard/providers/ollamasuggestions./dashboard/combos, create a combo, pick 3 models in one go (modal stays open), reopen → the 3 should be highlighted.Notes
astro buildis green locally.tsc --noEmitstill surfaces a number of pre-existing TS errors inBasicChatPageClient.tsxandcli-tools/*that are unrelated to this PR; none of the files this PR touches add new TS errors.cargo checkwas not run on the VM (Rust toolchain not installed in this Devin environment) — relying on CI for the Rust side. The Rust changes are small and self-contained: an extramatchfor provider fallback URLs, two extra success-shape checks, and ahasApiKeyboolean stamp on an existing JSON response./dashboard/profilepage was unreferenced; nothing else linked to it.