Voice add interface change

This commit is contained in:
Xin Wang
2026-02-12 18:01:05 +08:00
parent 98207936ae
commit 0f9543d8a4

View File

@@ -5,11 +5,6 @@ import { Voice } from '../types';
import { createVoice, deleteVoice, fetchVoices, previewVoice, updateVoice } from '../services/backendApi';
const SILICONFLOW_DEFAULT_MODEL = 'FunAudioLLM/CosyVoice2-0.5B';
const SILICONFLOW_MODEL_SUGGESTIONS = [
'FunAudioLLM/CosyVoice2-0.5B',
'fishaudio/fish-speech-1.5',
'fishaudio/fish-speech-1.4',
];
const buildSiliconflowVoiceKey = (rawId: string, model: string): string => {
const id = (rawId || '').trim();
@@ -414,17 +409,11 @@ const AddVoiceModal: React.FC<{
<div className="space-y-1.5">
<label className="text-[10px] font-black text-muted-foreground uppercase tracking-widest block"> (Model)</label>
<Input
className="h-9 bg-white/5 font-mono text-xs"
className="font-mono text-xs"
value={sfModel}
onChange={(e) => setSfModel(e.target.value)}
placeholder="例如: FunAudioLLM/CosyVoice2-0.5B"
list="siliconflow-model-options"
/>
<datalist id="siliconflow-model-options">
{SILICONFLOW_MODEL_SUGGESTIONS.map((m) => (
<option key={m} value={m} />
))}
</datalist>
</div>
<div className="space-y-1.5">
<label className="text-[10px] font-black text-muted-foreground uppercase tracking-widest block"> ID (Voice)</label>