fix: dsl check plugin

This commit is contained in:
StyleZhang
2024-11-15 14:54:01 +08:00
parent bc927868f4
commit 984e4564f8
4 changed files with 18 additions and 16 deletions

View File

@ -1,13 +1,25 @@
import { useCallback } from 'react'
import { useStore } from './store'
import InstallBundle from '@/app/components/plugins/install-plugin/install-bundle'
const PluginDependency = () => {
const dependencies = useStore(s => s.dependencies)
const handleCancelInstallBundle = useCallback(() => {
const { setDependencies } = useStore.getState()
setDependencies([])
}, [])
if (!dependencies.length)
return null
return (
<div>a</div>
<div>
<InstallBundle
fromDSLPayload={dependencies}
onClose={handleCancelInstallBundle}
/>
</div>
)
}