}
/>
}
/>
}
/>
}
/>
}
/>
diff --git a/web/app/components/plugins/marketplace/marketplace-wrapper.tsx b/web/app/components/plugins/marketplace/marketplace-wrapper.tsx
deleted file mode 100644
index 6c78d73c39..0000000000
--- a/web/app/components/plugins/marketplace/marketplace-wrapper.tsx
+++ /dev/null
@@ -1,12 +0,0 @@
-'use client'
-
-type WrapperProps = {
- children: React.ReactNode
-}
-const MarketplaceWrapper = ({
- children,
-}: WrapperProps) => {
- return children
-}
-
-export default MarketplaceWrapper
diff --git a/web/app/components/plugins/marketplace/marketplace.tsx b/web/app/components/plugins/marketplace/marketplace.tsx
deleted file mode 100644
index bc40e6c245..0000000000
--- a/web/app/components/plugins/marketplace/marketplace.tsx
+++ /dev/null
@@ -1,41 +0,0 @@
-import SearchBox from './search-box'
-import PluginTypeSwitch from './plugin-type-switch'
-import List from './list'
-
-const Marketplace = () => {
- return (
-
-
-
- Empower your AI development
-
-
- Discover
-
- models
-
- ,
-
- tools
-
- ,
-
- extensions
-
- and
-
- bundles
-
- in Dify Marketplace
-
-
- {}} />
-
-
{}} />
-
-
-
- )
-}
-
-export default Marketplace
diff --git a/web/app/components/plugins/marketplace/plugin-type-switch.tsx b/web/app/components/plugins/marketplace/plugin-type-switch.tsx
index 607bd362a6..9c9d73cdb7 100644
--- a/web/app/components/plugins/marketplace/plugin-type-switch.tsx
+++ b/web/app/components/plugins/marketplace/plugin-type-switch.tsx
@@ -8,7 +8,7 @@ import {
import cn from '@/utils/classnames'
type PluginTypeSwitchProps = {
- onChange: (type: string) => void
+ onChange?: (type: string) => void
}
const options = [
{
@@ -54,7 +54,7 @@ const PluginTypeSwitch = ({
)}
onClick={() => {
setActiveType(option.value)
- onChange(option.value)
+ onChange?.(option.value)
}}
>
{option.icon}
diff --git a/web/app/components/plugins/marketplace/search-box/index.tsx b/web/app/components/plugins/marketplace/search-box/index.tsx
index 627f387aef..cb01f0ad10 100644
--- a/web/app/components/plugins/marketplace/search-box/index.tsx
+++ b/web/app/components/plugins/marketplace/search-box/index.tsx
@@ -9,7 +9,7 @@ import TagsFilter from './tags-filter'
import ActionButton from '@/app/components/base/action-button'
type SearchBoxProps = {
- onChange: (searchText: string, tags: string[]) => void
+ onChange?: (searchText: string, tags: string[]) => void
}
const SearchBox = ({
onChange,
@@ -19,7 +19,7 @@ const SearchBox = ({
const handleTagsChange = useCallback((tags: string[]) => {
setSelectedTags(tags)
- onChange(searchText, tags)
+ onChange?.(searchText, tags)
}, [searchText, onChange])
return (
@@ -36,7 +36,7 @@ const SearchBox = ({
value={searchText}
onChange={(e) => {
setSearchText(e.target.value)
- onChange(e.target.value, selectedTags)
+ onChange?.(e.target.value, selectedTags)
}}
/>
{