diff --git a/web/app/(commonLayout)/plugins/test/update/page.tsx b/web/app/(commonLayout)/plugins/test/update/page.tsx index cbd6da1d62..0f3d05ea7b 100644 --- a/web/app/(commonLayout)/plugins/test/update/page.tsx +++ b/web/app/(commonLayout)/plugins/test/update/page.tsx @@ -32,9 +32,14 @@ const UpdatePlugin = () => { payload: { type: PluginSource.github, github: { - repo: 'repo_xxx', - originalPluginId: 'original_xxx', - version: 'version_xxx', + originalPackageInfo: { + id: '111', + repo: 'aaa/bbb', + version: 'xxx', + url: 'aaa/bbb', + currVersion: '1.2.3', + currPackage: 'pack1', + } as any, }, }, onCancelCallback: () => { diff --git a/web/app/components/plugins/install-plugin/install-from-github/index.tsx b/web/app/components/plugins/install-plugin/install-from-github/index.tsx index a064cab53e..979622f433 100644 --- a/web/app/components/plugins/install-plugin/install-from-github/index.tsx +++ b/web/app/components/plugins/install-plugin/install-from-github/index.tsx @@ -18,6 +18,7 @@ import { useTranslation } from 'react-i18next' type InstallFromGitHubProps = { updatePayload?: UpdateFromGitHubPayload onClose: () => void + onSuccess: () => void } const InstallFromGitHub: React.FC = ({ updatePayload, onClose }) => { diff --git a/web/app/components/plugins/update-plugin/from-github.tsx b/web/app/components/plugins/update-plugin/from-github.tsx index 3d71547c7f..9bc2f2ad3e 100644 --- a/web/app/components/plugins/update-plugin/from-github.tsx +++ b/web/app/components/plugins/update-plugin/from-github.tsx @@ -2,6 +2,7 @@ import type { FC } from 'react' import React from 'react' import type { UpdateFromGitHubPayload } from '../types' +import InstallFromGitHub from '../install-plugin/install-from-github' type Props = { payload: UpdateFromGitHubPayload @@ -11,11 +12,15 @@ type Props = { const FromGitHub: FC = ({ payload, + onSave, + onCancel, }) => { return ( -
- {JSON.stringify(payload)} -
+ ) } export default React.memo(FromGitHub)