Commit df53a3b
fix: clear model field when provider changes to show loading state
When switching providers (e.g., OpenAI to Anthropic), the model dropdown
briefly showed a blank value while new models were loading. This happened
because the old model value remained in the form field but didn't match
any models in the empty filteredModels array during loading.
Fix: Clear the model field when provider changes and models are loading
or unavailable. This ensures the "Loading models..." placeholder is
visible instead of a blank dropdown, providing better UX feedback during
provider switching.
Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>1 parent fe88a09 commit df53a3b
1 file changed
Lines changed: 11 additions & 0 deletions
Lines changed: 11 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
145 | 145 | | |
146 | 146 | | |
147 | 147 | | |
| 148 | + | |
| 149 | + | |
| 150 | + | |
| 151 | + | |
| 152 | + | |
| 153 | + | |
| 154 | + | |
| 155 | + | |
| 156 | + | |
| 157 | + | |
| 158 | + | |
148 | 159 | | |
149 | 160 | | |
150 | 161 | | |
| |||
0 commit comments