mirror of
https://github.com/langgenius/dify.git
synced 2024-11-16 03:32:23 +08:00
fix title & description of tool provider
This commit is contained in:
parent
973cd126bb
commit
5e3160e6f6
|
@ -1,6 +1,5 @@
|
|||
'use client'
|
||||
import React from 'react'
|
||||
import { useContext } from 'use-context-selector'
|
||||
import { RiVerifiedBadgeLine } from '@remixicon/react'
|
||||
import type { Plugin } from '../types'
|
||||
import Icon from '../card/base/card-icon'
|
||||
|
@ -10,7 +9,7 @@ import OrgInfo from './base/org-info'
|
|||
import Description from './base/description'
|
||||
import Placeholder from './base/placeholder'
|
||||
import cn from '@/utils/classnames'
|
||||
import I18n from '@/context/i18n'
|
||||
import { useGetLanguage } from '@/context/i18n'
|
||||
|
||||
type Props = {
|
||||
className?: string
|
||||
|
@ -35,7 +34,7 @@ const Card = ({
|
|||
isLoading = false,
|
||||
loadingFileName,
|
||||
}: Props) => {
|
||||
const { locale } = useContext(I18n)
|
||||
const locale = useGetLanguage()
|
||||
|
||||
const { type, name, org, label, brief, icon } = payload
|
||||
|
||||
|
|
|
@ -9,10 +9,7 @@ import { useTabSearchParams } from '@/hooks/use-tab-searchparams'
|
|||
import TabSliderNew from '@/app/components/base/tab-slider-new'
|
||||
import LabelFilter from '@/app/components/tools/labels/filter'
|
||||
import SearchInput from '@/app/components/base/search-input'
|
||||
import { DotsGrid } from '@/app/components/base/icons/src/vender/line/general'
|
||||
import { Colors } from '@/app/components/base/icons/src/vender/line/others'
|
||||
import { Route } from '@/app/components/base/icons/src/vender/line/mapsAndTravel'
|
||||
import CustomCreateCard from '@/app/components/tools/provider/custom-create-card'
|
||||
// import CustomCreateCard from '@/app/components/tools/provider/custom-create-card'
|
||||
import ProviderDetail from '@/app/components/tools/provider/detail'
|
||||
import Empty from '@/app/components/tools/add-tool-modal/empty'
|
||||
import { fetchCollectionList } from '@/service/tools'
|
||||
|
@ -31,9 +28,9 @@ const ProviderList = () => {
|
|||
defaultTab: 'builtin',
|
||||
})
|
||||
const options = [
|
||||
{ value: 'builtin', text: t('tools.type.builtIn'), icon: <DotsGrid className='w-[14px] h-[14px] mr-1' /> },
|
||||
{ value: 'api', text: t('tools.type.custom'), icon: <Colors className='w-[14px] h-[14px] mr-1' /> },
|
||||
{ value: 'workflow', text: t('tools.type.workflow'), icon: <Route className='w-[14px] h-[14px] mr-1' /> },
|
||||
{ value: 'builtin', text: t('tools.type.builtIn') },
|
||||
{ value: 'api', text: t('tools.type.custom') },
|
||||
{ value: 'workflow', text: t('tools.type.workflow') },
|
||||
]
|
||||
const [tagFilterValue, setTagFilterValue] = useState<string[]>([])
|
||||
const handleTagsChange = (value: string[]) => {
|
||||
|
@ -100,7 +97,7 @@ const ProviderList = () => {
|
|||
'relative grid content-start grid-cols-1 gap-4 px-12 pt-2 pb-4 sm:grid-cols-2 md:grid-cols-3 lg:grid-cols-4 grow shrink-0',
|
||||
currentProvider && 'pr-6 sm:grid-cols-1 md:grid-cols-2 lg:grid-cols-3',
|
||||
)}>
|
||||
{activeTab === 'api' && <CustomCreateCard onRefreshData={getProviderList} />}
|
||||
{/* {activeTab === 'api' && <CustomCreateCard onRefreshData={getProviderList} />} */}
|
||||
{filteredCollectionList.map(collection => (
|
||||
<div
|
||||
key={collection.id}
|
||||
|
|
|
@ -4,7 +4,7 @@ const translation = {
|
|||
customToolTip: 'Learn more about Dify custom tools',
|
||||
type: {
|
||||
all: 'All',
|
||||
builtIn: 'Built-in',
|
||||
builtIn: 'Tools',
|
||||
custom: 'Custom',
|
||||
workflow: 'Workflow',
|
||||
},
|
||||
|
|
|
@ -4,7 +4,7 @@ const translation = {
|
|||
customToolTip: '了解更多关于 Dify 自定义工具的信息',
|
||||
type: {
|
||||
all: '全部',
|
||||
builtIn: '内置',
|
||||
builtIn: '工具',
|
||||
custom: '自定义',
|
||||
workflow: '工作流',
|
||||
},
|
||||
|
|
Loading…
Reference in New Issue
Block a user