Skip to content

armgit / dify

Public Imported from GitHub
0

Build Agentic workflows, RAG pipelines, with rich AI model and tool support on one collaborative workspace. Deploy on cloud, VPC, or self-hosted, so teams move from prototype to production without rebuilding the stack.

fix: remove duplicated category “recommended” (#10375)

非法操作3cb2fb82504e
diff --git a/web/app/components/explore/category.tsx b/web/app/components/explore/category.tsx
index cbf6cd26fe7..8f67f0fd491 100644
--- a/web/app/components/explore/category.tsx
+++ b/web/app/components/explore/category.tsx
@@ -28,7 +28,7 @@ const Category: FC<ICategoryProps> = ({
allCategoriesEn,
}) => {
const { t } = useTranslation()
- const isAllCategories = !list.includes(value as AppCategory)
+ const isAllCategories = !list.includes(value as AppCategory) || value === allCategoriesEn
const itemClassName = (isSelected: boolean) => cn(
'flex items-center px-3 py-[7px] h-[32px] rounded-lg border-[0.5px] border-transparent text-gray-700 font-medium leading-[18px] cursor-pointer hover:bg-gray-200',
@@ -44,7 +44,7 @@ const Category: FC<ICategoryProps> = ({
<ThumbsUp className='mr-1 w-3.5 h-3.5' />
{t('explore.apps.allCategories')}
</div>
- {list.map(name => (
+ {list.filter(name => name !== allCategoriesEn).map(name => (
<div
key={name}
className={itemClassName(name === value)}