From 1fed02d23fb74572d3e49439a90a54188fcce047 Mon Sep 17 00:00:00 2001 From: jialin Date: Mon, 30 Sep 2024 19:08:39 +0800 Subject: [PATCH] fix: modal title does not upate after change language --- src/pages/llmodels/components/table-list.tsx | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/pages/llmodels/components/table-list.tsx b/src/pages/llmodels/components/table-list.tsx index e966163a..167b4d42 100644 --- a/src/pages/llmodels/components/table-list.tsx +++ b/src/pages/llmodels/components/table-list.tsx @@ -95,7 +95,6 @@ const Models: React.FC = ({ width: 600, source: modelSourceMap.huggingface_value }); - const [title, setTitle] = useState(''); const [currentData, setCurrentData] = useState({} as ListItem); const [currentInstanceUrl, setCurrentInstanceUrl] = useState(''); const modalRef = useRef(null); @@ -366,7 +365,6 @@ const Models: React.FC = ({ const handleEdit = (row: ListItem) => { setCurrentData(row); setOpenAddModal(true); - setTitle(intl.formatMessage({ id: 'models.title.edit' })); }; const handleSelect = useCallback((val: any, row: ListItem) => { @@ -599,7 +597,7 @@ const Models: React.FC = ({