Fix/tool provider tag internationalization (#26710)

Co-authored-by: qiaofenglin <qiaofenglin@baidu.com>
This commit is contained in:
fenglin
2025-10-10 15:52:09 +08:00
committed by GitHub
parent 3a5aa4587c
commit 294e01a8c1
2 changed files with 64 additions and 47 deletions

View File

@@ -21,6 +21,7 @@ import { useCheckInstalled, useInvalidateInstalledPluginList } from '@/service/u
import { useGlobalPublicStore } from '@/context/global-public-context'
import { ToolTypeEnum } from '../workflow/block-selector/types'
import { useMarketplace } from './marketplace/hooks'
import { useTags } from '@/app/components/plugins/hooks'
const getToolType = (type: string) => {
switch (type) {
@@ -40,6 +41,7 @@ const ProviderList = () => {
// const searchParams = useSearchParams()
// searchParams.get('category') === 'workflow'
const { t } = useTranslation()
const { getTagLabel } = useTags()
const { enable_marketplace } = useGlobalPublicStore(s => s.systemFeatures)
const containerRef = useRef<HTMLDivElement>(null)
@@ -180,7 +182,7 @@ const ProviderList = () => {
} as any}
footer={
<CardMoreInfo
tags={collection.labels}
tags={collection.labels?.map(label => getTagLabel(label)) || []}
/>
}
/>