diff --git a/packages/web/components/common/Icon/constants.ts b/packages/web/components/common/Icon/constants.ts index a6465f3ed..086199708 100644 --- a/packages/web/components/common/Icon/constants.ts +++ b/packages/web/components/common/Icon/constants.ts @@ -7,10 +7,12 @@ export const iconPaths = { closeSolid: () => import('./icons/closeSolid.svg'), collectionLight: () => import('./icons/collectionLight.svg'), collectionSolid: () => import('./icons/collectionSolid.svg'), + 'common/add2': () => import('./icons/common/add2.svg'), 'common/addCircleLight': () => import('./icons/common/addCircleLight.svg'), 'common/addLight': () => import('./icons/common/addLight.svg'), 'common/backFill': () => import('./icons/common/backFill.svg'), 'common/backLight': () => import('./icons/common/backLight.svg'), + 'common/check': () => import('./icons/common/check.svg'), 'common/clearLight': () => import('./icons/common/clearLight.svg'), 'common/closeLight': () => import('./icons/common/closeLight.svg'), 'common/confirm/commonTip': () => import('./icons/common/confirm/commonTip.svg'), diff --git a/packages/web/components/common/Icon/icons/common/add2.svg b/packages/web/components/common/Icon/icons/common/add2.svg new file mode 100644 index 000000000..0494665aa --- /dev/null +++ b/packages/web/components/common/Icon/icons/common/add2.svg @@ -0,0 +1,5 @@ + + + + + diff --git a/packages/web/components/common/Icon/icons/common/check.svg b/packages/web/components/common/Icon/icons/common/check.svg new file mode 100644 index 000000000..f9d5d37f1 --- /dev/null +++ b/packages/web/components/common/Icon/icons/common/check.svg @@ -0,0 +1,3 @@ + + + \ No newline at end of file diff --git a/packages/web/styles/theme.ts b/packages/web/styles/theme.ts index 633d69db8..89cc0c30f 100644 --- a/packages/web/styles/theme.ts +++ b/packages/web/styles/theme.ts @@ -477,6 +477,7 @@ const Checkbox = checkBoxMultiStyle({ _checked: { bg: 'primary.50', borderColor: 'primary.600', + borderWidth: '1px', color: 'primary.600', boxShadow: `${shadowLight} !important`, _hover: { diff --git a/projects/app/src/components/core/app/DatasetParamsModal.tsx b/projects/app/src/components/core/app/DatasetParamsModal.tsx index 2e8386e51..854789d2f 100644 --- a/projects/app/src/components/core/app/DatasetParamsModal.tsx +++ b/projects/app/src/components/core/app/DatasetParamsModal.tsx @@ -206,7 +206,12 @@ const DatasetParamsModal = ({ - + } + /> diff --git a/projects/app/src/components/core/app/InputGuideConfig.tsx b/projects/app/src/components/core/app/InputGuideConfig.tsx index d8d5d2c56..9668901c5 100644 --- a/projects/app/src/components/core/app/InputGuideConfig.tsx +++ b/projects/app/src/components/core/app/InputGuideConfig.tsx @@ -433,6 +433,7 @@ const LexiconConfigModal = ({ appId, onClose }: { appId: string; onClose: () => } onChange={(e) => { if (e.target.checked) { setSelectedRows([...selectedRows, item._id]); diff --git a/projects/app/src/components/core/chat/ChatContainer/ChatBox/index.tsx b/projects/app/src/components/core/chat/ChatContainer/ChatBox/index.tsx index c5bd0eed1..ef30b6408 100644 --- a/projects/app/src/components/core/chat/ChatContainer/ChatBox/index.tsx +++ b/projects/app/src/components/core/chat/ChatContainer/ChatBox/index.tsx @@ -57,6 +57,7 @@ import type { StreamResponseType } from '@/web/common/api/fetch'; import { useContextSelector } from 'use-context-selector'; import { useSystem } from '@fastgpt/web/hooks/useSystem'; import { useThrottleFn } from 'ahooks'; +import MyIcon from '@fastgpt/web/components/common/Icon'; const ResponseTags = dynamic(() => import('./components/ResponseTags')); const FeedbackModal = dynamic(() => import('./components/FeedbackModal')); @@ -962,7 +963,10 @@ const ChatBox = ( - + } + > {text} diff --git a/projects/app/src/components/core/dataset/RawSourceBox.tsx b/projects/app/src/components/core/dataset/RawSourceBox.tsx index fe4de5bef..ad6a65cfa 100644 --- a/projects/app/src/components/core/dataset/RawSourceBox.tsx +++ b/projects/app/src/components/core/dataset/RawSourceBox.tsx @@ -48,7 +48,7 @@ const RawSourceBox = ({ : {})} {...props} > - + } onChange={onChange} /> void; onSucces alignItems="center" key={member.tmbId} cursor={'pointer'} - _hover={{ bg: 'myGray.50' }} + _hover={{ + bg: 'myGray.50', + ...(!selected.includes(member) ? { svg: { color: 'myGray.50' } } : {}) + }} _notLast={{ mb: 2 }} onClick={() => { if (selected.indexOf(member) == -1) { @@ -111,7 +114,10 @@ function AddManagerModal({ onClose, onSuccess }: { onClose: () => void; onSucces } }} > - + } + /> {member.memberName} diff --git a/projects/app/src/pages/app/detail/components/SimpleApp/AppCard.tsx b/projects/app/src/pages/app/detail/components/SimpleApp/AppCard.tsx index 07a3e450e..8d854f8ce 100644 --- a/projects/app/src/pages/app/detail/components/SimpleApp/AppCard.tsx +++ b/projects/app/src/pages/app/detail/components/SimpleApp/AppCard.tsx @@ -167,7 +167,10 @@ const AppCard = () => { {appT('transition_to_workflow_create_new_tip')} setTransitionCreateNew((state) => !state)}> - + } + /> {appT('transition_to_workflow_create_new_placeholder')} diff --git a/projects/app/src/pages/dataset/detail/components/CollectionCard/HeaderTagPopOver.tsx b/projects/app/src/pages/dataset/detail/components/CollectionCard/HeaderTagPopOver.tsx index 6e0dcbbd1..def249a14 100644 --- a/projects/app/src/pages/dataset/detail/components/CollectionCard/HeaderTagPopOver.tsx +++ b/projects/app/src/pages/dataset/detail/components/CollectionCard/HeaderTagPopOver.tsx @@ -96,6 +96,10 @@ const HeaderTagPopOver = () => { overflow={'hidden'} h={['28px', '36px']} fontSize={'sm'} + _hover={{ + boxShadow: '0px 0px 0px 2.4px rgba(51, 112, 255, 0.15)', + borderColor: 'primary.300' + }} > {t('dataset:tag.tags')} @@ -158,9 +162,12 @@ const HeaderTagPopOver = () => { py={1} my={1} cursor={'pointer'} - bg={checked ? '#1118240D' : 'transparent'} color={checked ? 'primary.700' : 'myGray.600'} - _hover={{ bg: '#1118240D', color: 'primary.700' }} + _hover={{ + bg: '#1118240D', + color: 'primary.700', + ...(checked ? {} : { svg: { color: '#F3F3F4' } }) + }} borderRadius={'xs'} key={item._id} onClick={(e) => { @@ -174,6 +181,7 @@ const HeaderTagPopOver = () => { checkTags(item); }} size={'md'} + icon={} /> {item.tag} @@ -186,6 +194,7 @@ const HeaderTagPopOver = () => { fontSize={'sm'} _hover={{ bg: '#1118240D', color: 'primary.700' }} borderRadius={'none'} + borderBottomLeftRadius={'md'} variant={'unstyled'} onClick={() => { setCheckedTags([]); @@ -202,6 +211,7 @@ const HeaderTagPopOver = () => { fontSize={'sm'} _hover={{ bg: '#1118240D', color: 'primary.700' }} borderRadius={'none'} + borderBottomRightRadius={'md'} variant={'unstyled'} onClick={() => { onOpenTagManageModal(); diff --git a/projects/app/src/pages/dataset/detail/components/CollectionCard/TagManageModal.tsx b/projects/app/src/pages/dataset/detail/components/CollectionCard/TagManageModal.tsx index 90266e828..05de61fff 100644 --- a/projects/app/src/pages/dataset/detail/components/CollectionCard/TagManageModal.tsx +++ b/projects/app/src/pages/dataset/detail/components/CollectionCard/TagManageModal.tsx @@ -305,7 +305,7 @@ const TagManageModal = ({ onClose }: { onClose: () => void }) => { }} cursor={'pointer'} > - + } onChange={() => { setSelectedCollections((prev) => { if (prev.includes(collection.id)) { @@ -517,8 +524,8 @@ const AddTagToCollections = ({ }} isChecked={selectedCollections.includes(collection.id)} /> - - + + {collection.name} diff --git a/projects/app/src/pages/dataset/detail/components/CollectionCard/TagsPopOver.tsx b/projects/app/src/pages/dataset/detail/components/CollectionCard/TagsPopOver.tsx index 9debc0d3b..d4f422323 100644 --- a/projects/app/src/pages/dataset/detail/components/CollectionCard/TagsPopOver.tsx +++ b/projects/app/src/pages/dataset/detail/components/CollectionCard/TagsPopOver.tsx @@ -155,9 +155,10 @@ const TagsPopOver = ({ { onCreateCollectionTag(searchTag); + // setCheckedTags([...checkedTags, item]); }} > @@ -228,13 +230,16 @@ const TagsPopOver = ({ alignItems={'center'} fontSize={'xs'} px={1} - py={0.5} - my={0.5} + py={1} + my={1} key={item._id} cursor={'pointer'} - bg={tagsList.includes(item.tag) ? '#1118240D' : 'transparent'} color={tagsList.includes(item.tag) ? '#2B5FD9' : 'myGray.600'} - _hover={{ bg: '#1118240D', color: '#2B5FD9' }} + _hover={{ + bg: '#1118240D', + color: '#2B5FD9', + ...(tagsList.includes(item.tag) ? {} : { svg: { color: '#F3F3F4' } }) + }} borderRadius={'xs'} onClick={(e) => { e.preventDefault(); @@ -254,8 +259,9 @@ const TagsPopOver = ({ setCheckedTags(checkedTags.filter((t) => t._id !== item._id)); } }} + icon={} /> - {item.tag} + {item.tag} ); })} diff --git a/projects/app/src/pages/dataset/detail/components/CollectionCard/index.tsx b/projects/app/src/pages/dataset/detail/components/CollectionCard/index.tsx index 1f8d9978e..e73a1170a 100644 --- a/projects/app/src/pages/dataset/detail/components/CollectionCard/index.tsx +++ b/projects/app/src/pages/dataset/detail/components/CollectionCard/index.tsx @@ -237,12 +237,12 @@ const CollectionCard = () => { > - + - + {collection.name}