fix: remove CORS checking for downloading remote model file

This commit is contained in:
Xiaohan-Tian
2026-05-15 12:53:36 -07:00
parent 1fd2c283f2
commit b2bbc08761
7 changed files with 212 additions and 46 deletions
@@ -232,6 +232,10 @@ const GeneralSettings: React.FC = () => {
}
};
const localRuntimeMessage = localModelState.runtimeSupport.reason;
const hasLocalRuntimeHardFailure = !localModelState.runtimeSupport.supported;
const hasLocalRuntimeWarning = localModelState.runtimeSupport.supported && !!localRuntimeMessage;
// NOTE: Gemini and Claude are not supported yet due to CORS issues.
return (
<div className="settings-section">
@@ -282,9 +286,15 @@ const GeneralSettings: React.FC = () => {
<div className="settings-group">
<h4>{LOCAL_LLM_DISPLAY_NAME} Local Runtime</h4>
{!localModelState.runtimeSupport.supported && (
{hasLocalRuntimeWarning && (
<div className="settings-help" style={{ fontSize: '12px', color: '#d0a56b', marginTop: '4px', marginBottom: '8px' }}>
{localModelState.runtimeSupport.reason}
{localRuntimeMessage}
</div>
)}
{hasLocalRuntimeHardFailure && (
<div className="settings-help" style={{ fontSize: '12px', color: '#d45a5a', marginTop: '4px', marginBottom: '8px' }}>
{localRuntimeMessage}
</div>
)}