diff --git a/web/app/components/plugins/plugin-detail-panel/tool-selector/tool-item.tsx b/web/app/components/plugins/plugin-detail-panel/tool-selector/tool-item.tsx
index 5927318619..45a9abd592 100644
--- a/web/app/components/plugins/plugin-detail-panel/tool-selector/tool-item.tsx
+++ b/web/app/components/plugins/plugin-detail-panel/tool-selector/tool-item.tsx
@@ -5,8 +5,6 @@ import {
RiDeleteBinLine,
RiEqualizer2Line,
RiErrorWarningFill,
- RiInstallLine,
- RiLoader2Line,
} from '@remixicon/react'
import { Group } from '@/app/components/base/icons/src/vender/other'
import AppIcon from '@/app/components/base/app-icon'
@@ -15,6 +13,7 @@ import Button from '@/app/components/base/button'
import Indicator from '@/app/components/header/indicator'
import ActionButton from '@/app/components/base/action-button'
import Tooltip from '@/app/components/base/tooltip'
+import { InstallPluginButton } from '@/app/components/workflow/nodes/_base/components/install-plugin-button'
import cn from '@/utils/classnames'
type Props = {
@@ -30,7 +29,7 @@ type Props = {
isError?: boolean
errorTip?: any
uninstalled?: boolean
- isInstalling?: boolean
+ installInfo?: string
onInstall?: () => void
open: boolean
}
@@ -47,7 +46,7 @@ const ToolItem = ({
noAuth,
onAuth,
uninstalled,
- isInstalling,
+ installInfo,
onInstall,
isError,
errorTip,
@@ -115,20 +114,15 @@ const ToolItem = ({
)}
- {!isError && uninstalled && (
-
+ />
)}
{isError && (
= ({
const setCurrentPluginID = usePluginPageContext(v => v.setCurrentPluginID)
const invalidateInstalledPluginList = useInvalidateInstalledPluginList()
const invalidateAllToolProviders = useInvalidateAllToolProviders()
+ const invalidateAllBuiltinTools = useInvalidateAllBuiltInTools()
const { refreshModelProviders } = useProviderContext()
const {
@@ -62,8 +63,10 @@ const PluginItem: FC = ({
invalidateInstalledPluginList()
if (PluginType.model.includes(category))
refreshModelProviders()
- if (PluginType.tool.includes(category))
+ if (PluginType.tool.includes(category)) {
invalidateAllToolProviders()
+ invalidateAllBuiltinTools()
+ }
}
const getValueFromI18nObject = useRenderI18nObject()
const title = getValueFromI18nObject(label)
diff --git a/web/app/components/plugins/plugin-page/plugin-tasks/hooks.ts b/web/app/components/plugins/plugin-page/plugin-tasks/hooks.ts
index e15f9b963a..f32a812c13 100644
--- a/web/app/components/plugins/plugin-page/plugin-tasks/hooks.ts
+++ b/web/app/components/plugins/plugin-page/plugin-tasks/hooks.ts
@@ -64,14 +64,16 @@ export const usePluginTaskStatus = () => {
const timerRef = useRef(null)
useEffect(() => {
- if (isSuccess && opacity > 0) {
+ if (isSuccess) {
if (timerRef.current) {
clearTimeout(timerRef.current)
timerRef.current = null
}
- timerRef.current = setTimeout(() => {
- setOpacity(v => v - 0.1)
- }, 200)
+ if (opacity > 0) {
+ timerRef.current = setTimeout(() => {
+ setOpacity(v => v - 0.1)
+ }, 200)
+ }
}
if (!isSuccess)
diff --git a/web/app/components/workflow/block-selector/market-place-plugin/list.tsx b/web/app/components/workflow/block-selector/market-place-plugin/list.tsx
index 596b6f21c5..8509faf253 100644
--- a/web/app/components/workflow/block-selector/market-place-plugin/list.tsx
+++ b/web/app/components/workflow/block-selector/market-place-plugin/list.tsx
@@ -15,14 +15,16 @@ type Props = {
list: Plugin[]
searchText: string
tags: string[]
+ disableMaxWidth?: boolean
}
-const List = ({
+const List = forwardRef<{ handleScroll: () => void }, Props>(({
wrapElemRef,
searchText,
tags,
list,
-}: Props, ref: any) => {
+ disableMaxWidth = false,
+}, ref) => {
const { t } = useTranslation()
const hasFilter = !searchText
const hasRes = list.length > 0
@@ -95,7 +97,7 @@ const List = ({
)}
-