diff --git a/web/app/components/header/account-setting/model-provider-page/index.tsx b/web/app/components/header/account-setting/model-provider-page/index.tsx
index 87f7c25b9c..3a45424a8a 100644
--- a/web/app/components/header/account-setting/model-provider-page/index.tsx
+++ b/web/app/components/header/account-setting/model-provider-page/index.tsx
@@ -10,7 +10,6 @@ import {
} from '@remixicon/react'
import SystemModelSelector from './system-model-selector'
import ProviderAddedCard, { UPDATE_MODEL_PROVIDER_CUSTOM_MODEL_LIST } from './provider-added-card'
-// import ProviderCard from './provider-card'
import type {
CustomConfigurationModelFixedFields,
ModelProvider,
@@ -35,6 +34,7 @@ import {
useMarketplacePlugins,
} from '@/app/components/plugins/marketplace/hooks'
import { PluginType } from '@/app/components/plugins/types'
+import { MARKETPLACE_URL_PREFIX } from '@/config'
import cn from '@/utils/classnames'
type Props = {
@@ -213,7 +213,7 @@ const ModelProviderPage = ({ searchText }: Props) => {
{t('common.modelProvider.discoverMore')}
-
+
Dify Marketplace
@@ -221,8 +221,8 @@ const ModelProviderPage = ({ searchText }: Props) => {
{!collapse && !isPluginsLoading && (
- {plugins.map((plugin, index) => (
-
+ {plugins.map(plugin => (
+
))}
)}
diff --git a/web/app/components/plugins/marketplace/list/card-wrapper.tsx b/web/app/components/plugins/marketplace/list/card-wrapper.tsx
index 52538a0bae..c9d83f32ac 100644
--- a/web/app/components/plugins/marketplace/list/card-wrapper.tsx
+++ b/web/app/components/plugins/marketplace/list/card-wrapper.tsx
@@ -3,6 +3,7 @@ import { RiArrowRightUpLine } from '@remixicon/react'
import Card from '@/app/components/plugins/card'
import CardMoreInfo from '@/app/components/plugins/card/card-more-info'
import type { Plugin } from '@/app/components/plugins/types'
+import { MARKETPLACE_URL_PREFIX } from '@/config'
import Button from '@/app/components/base/button'
type CardWrapperProps = {
@@ -37,6 +38,7 @@ const CardWrapper = ({
diff --git a/web/app/components/plugins/provider-card.tsx b/web/app/components/plugins/provider-card.tsx
index 7d9f21ea43..2ced311100 100644
--- a/web/app/components/plugins/provider-card.tsx
+++ b/web/app/components/plugins/provider-card.tsx
@@ -1,8 +1,6 @@
'use client'
import React from 'react'
-import { useContext } from 'use-context-selector'
import type { FC } from 'react'
-import Link from 'next/link'
import { RiArrowRightUpLine, RiVerifiedBadgeLine } from '@remixicon/react'
import Badge from '../base/badge'
import type { Plugin } from './types'
@@ -11,70 +9,66 @@ import Icon from './card/base/card-icon'
import Title from './card/base/title'
import DownloadCount from './card/base/download-count'
import Button from '@/app/components/base/button'
+import { useGetLanguage } from '@/context/i18n'
+import { MARKETPLACE_URL_PREFIX } from '@/config'
import cn from '@/utils/classnames'
-import I18n from '@/context/i18n'
type Props = {
className?: string
payload: Plugin
- installed?: boolean
}
const ProviderCard: FC = ({
className,
payload,
- installed = true,
}) => {
- const { locale } = useContext(I18n)
+ const language = useGetLanguage()
const { org, label } = payload
return (
-
- {/* Header */}
-
-
-
-
-
-
-
-
-
+ {/* Header */}
+
+
+
-
-
- {['LLM', 'text embedding', 'speech2text'].map(tag => (
-
- ))}
-
- {!installed && (
-
-
-
-
- )}
-
+
+
+
+ {payload.tags.map(tag => (
+
+ ))}
+
+
)
}
diff --git a/web/app/components/plugins/types.ts b/web/app/components/plugins/types.ts
index ae16b0b300..3c7894a576 100644
--- a/web/app/components/plugins/types.ts
+++ b/web/app/components/plugins/types.ts
@@ -103,6 +103,7 @@ export type Plugin = {
type: PluginType
org: string
name: string
+ plugin_id: string
version: string
latest_version: string
icon: string