Skip to content

Commit

Permalink
perf: btn color
Browse files Browse the repository at this point in the history
  • Loading branch information
c121914yu committed Oct 23, 2023
1 parent bf6dbfb commit 27a56be
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 11 deletions.
3 changes: 2 additions & 1 deletion projects/app/public/locales/en/common.json
Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,7 @@
"folder": {
"Drag Tip": "Click and move",
"Move Success": "Move Success",
"No Folder": "No Folder",
"No Folder": "There are no subdirectories~",
"Root Path": "Root Folder"
}
},
Expand Down Expand Up @@ -189,6 +189,7 @@
"Click to view folder": "To Folder",
"Collection Embedding": "{{total}}Embedding",
"Confirm to delete the folder": "Are you sure to delete this folder and all its contents?",
"Create And Import": "Create/Import",
"Create Training Data": "Training-{{filename}}",
"Create Virtual File Success": "Create Virtual File Success",
"Data Amount": "Data Amount",
Expand Down
3 changes: 2 additions & 1 deletion projects/app/public/locales/zh/common.json
Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,7 @@
"folder": {
"Drag Tip": "点我可拖动",
"Move Success": "移动成功",
"No Folder": "这个目录空空的~",
"No Folder": "没有子目录了,就这吧~",
"Root Path": "根目录"
}
},
Expand Down Expand Up @@ -189,6 +189,7 @@
"Click to view folder": "进入目录",
"Collection Embedding": "{{total}}组索引中",
"Confirm to delete the folder": "确认删除该文件夹及里面所有内容?",
"Create And Import": "新建/导入",
"Create Training Data": "文件训练-{{filename}}",
"Create Virtual File Success": "创建虚拟文件成功",
"Data Amount": "数据总量",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,6 @@ import { getCollectionIcon } from '@fastgpt/global/core/dataset/utils';
import EditFolderModal, { useEditFolder } from '../../component/EditFolderModal';
import { TabEnum } from '..';
import ParentPath from '@/components/common/ParentPaths';
import { useDatasetStore } from '@/web/core/dataset/store/dataset';
import dynamic from 'next/dynamic';
import { useDrag } from '@/web/common/hooks/useDrag';
import SelectCollections from '@/web/core/dataset/components/SelectCollections';
Expand All @@ -68,7 +67,6 @@ const CollectionCard = () => {
const { isPc } = useSystemStore();
const [searchText, setSearchText] = useState('');
const { setLoading } = useSystemStore();
const { datasetDetail, loadDatasetDetail } = useDatasetStore();

const { openConfirm, ConfirmModal } = useConfirm({
content: t('dataset.Confirm to delete the file')
Expand Down Expand Up @@ -114,8 +112,7 @@ const CollectionCard = () => {
}
});

const { moveDataId, setMoveDataId, dragStartId, setDragStartId, dragTargetId, setDragTargetId } =
useDrag();
const { dragStartId, setDragStartId, dragTargetId, setDragTargetId } = useDrag();

// change search
const debounceRefetch = useCallback(
Expand Down Expand Up @@ -209,7 +206,6 @@ const CollectionCard = () => {
getDatasetCollectionPathById(parentId)
);

useQuery(['loadDatasetDetail', datasetId], () => loadDatasetDetail(datasetId));
useQuery(
['refreshCollection'],
() => {
Expand Down Expand Up @@ -279,7 +275,7 @@ const CollectionCard = () => {
</Flex>
)}
<MyMenu
offset={[-10, 10]}
offset={[-40, 10]}
width={120}
Button={
<MenuButton
Expand All @@ -290,15 +286,17 @@ const CollectionCard = () => {
>
<Flex
alignItems={'center'}
border={theme.borders.base}
px={5}
py={2}
borderRadius={'md'}
cursor={'pointer'}
bg={'myBlue.600'}
overflow={'hidden'}
color={'white'}
h={['28px', '35px']}
>
<AddIcon mr={2} />
<Box>{t('Create New')}</Box>
<MyIcon name={'importLight'} mr={2} w={'14px'} />
<Box>{t('dataset.collections.Create And Import')}</Box>
</Flex>
</MenuButton>
}
Expand Down

0 comments on commit 27a56be

Please sign in to comment.