mirror of
https://github.com/CherryHQ/cherry-studio.git
synced 2026-01-09 14:59:27 +08:00
fix: remove unused model removal function from TranslatePage component
This commit is contained in:
parent
f5a2803838
commit
6260ea76ce
@ -65,10 +65,6 @@ const TranslateSettings: FC<{
|
|||||||
setLocalPair(bidirectionalPair)
|
setLocalPair(bidirectionalPair)
|
||||||
}, [bidirectionalPair, visible])
|
}, [bidirectionalPair, visible])
|
||||||
|
|
||||||
const handleRemoveModel = () => {
|
|
||||||
db.settings.put({ id: 'translate:model', value: null })
|
|
||||||
}
|
|
||||||
|
|
||||||
const handleSave = () => {
|
const handleSave = () => {
|
||||||
if (localPair[0] === localPair[1]) {
|
if (localPair[0] === localPair[1]) {
|
||||||
window.message.warning({
|
window.message.warning({
|
||||||
@ -118,7 +114,6 @@ const TranslateSettings: FC<{
|
|||||||
options={selectOptions}
|
options={selectOptions}
|
||||||
showSearch
|
showSearch
|
||||||
/>
|
/>
|
||||||
{translateModel && <Button icon={<DeleteOutlined />} type="text" onClick={handleRemoveModel} danger />}
|
|
||||||
</HStack>
|
</HStack>
|
||||||
{!translateModel && (
|
{!translateModel && (
|
||||||
<div style={{ marginTop: 8, color: 'var(--color-warning)' }}>
|
<div style={{ marginTop: 8, color: 'var(--color-warning)' }}>
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user