chore: add agent strategy option apart from bundle

pull/12372/head
Yi 1 year ago
parent ec6f4ee9df
commit 6dd14ca2be

@ -43,8 +43,9 @@ const Card = ({
const defaultLocale = useGetLanguage()
const locale = localeFromProps ? getLanguage(localeFromProps) : defaultLocale
const { categoriesMap } = useCategories()
const { type, category, name, org, label, brief, icon, verified } = payload
const cornerMark = !['plugin', 'model', 'tool', 'extension'].includes(type) ? categoriesMap.bundle?.label : categoriesMap[category]?.label
const { category, type, name, org, label, brief, icon, verified } = payload
const isBundle = !['plugin', 'model', 'tool', 'extension', 'agent-strategy'].includes(type)
const cornerMark = isBundle ? categoriesMap.bundle?.label : categoriesMap[category]?.label
const getLocalizedText = (obj: Record<string, string> | undefined) =>
obj?.[locale] || obj?.['en-US'] || obj?.en_US || ''

Loading…
Cancel
Save