mirror of
https://github.com/danny-avila/LibreChat.git
synced 2025-12-22 03:10:15 +01:00
fix: to set default value when change endpoint of preset
This commit is contained in:
parent
d864da6a21
commit
0c4b754fba
1 changed files with 6 additions and 5 deletions
|
|
@ -20,14 +20,15 @@ const EditPresetDialog = ({ open, onOpenChange, preset: _preset, title }) => {
|
|||
const setPresets = useSetRecoilState(store.presets);
|
||||
|
||||
const availableEndpoints = useRecoilValue(store.availableEndpoints);
|
||||
|
||||
const setOption = param => newValue => {
|
||||
let update = {};
|
||||
update[param] = newValue;
|
||||
setPreset(prevState => ({
|
||||
setPreset(prevState =>
|
||||
cleanupPreset({
|
||||
...prevState,
|
||||
...update
|
||||
}));
|
||||
})
|
||||
);
|
||||
};
|
||||
|
||||
const defaultTextProps =
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue