From c27ccb84750a32a8fb141c663f780d93420eeeb3 Mon Sep 17 00:00:00 2001 From: Copilot <198982749+Copilot@users.noreply.github.com> Date: Sun, 16 Nov 2025 23:37:40 +0800 Subject: [PATCH] feat(web): Add centered empty state messages to pipeline extension dialogs (#1784) * Initial plan * feat: add empty state messages in pipeline extension dialogs Co-authored-by: RockChinQ <45992437+RockChinQ@users.noreply.github.com> * fix: center empty state messages in dialog content area Co-authored-by: RockChinQ <45992437+RockChinQ@users.noreply.github.com> --------- Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: RockChinQ <45992437+RockChinQ@users.noreply.github.com> --- .../pipeline-extensions/PipelineExtension.tsx | 174 ++++++++++-------- web/src/i18n/locales/en-US.ts | 2 + web/src/i18n/locales/ja-JP.ts | 2 + web/src/i18n/locales/zh-Hans.ts | 2 + web/src/i18n/locales/zh-Hant.ts | 2 + 5 files changed, 104 insertions(+), 78 deletions(-) diff --git a/web/src/app/home/pipelines/components/pipeline-extensions/PipelineExtension.tsx b/web/src/app/home/pipelines/components/pipeline-extensions/PipelineExtension.tsx index b1bf4922..06e059f0 100644 --- a/web/src/app/home/pipelines/components/pipeline-extensions/PipelineExtension.tsx +++ b/web/src/app/home/pipelines/components/pipeline-extensions/PipelineExtension.tsx @@ -331,48 +331,56 @@ export default function PipelineExtension({ {t('pipelines.extensions.selectPlugins')}
- {allPlugins.map((plugin) => { - const pluginId = getPluginId(plugin); - const metadata = plugin.manifest.manifest.metadata; - const isSelected = tempSelectedPluginIds.includes(pluginId); - return ( -
handleTogglePlugin(pluginId)} - > - - +

+ {t('pipelines.extensions.noPluginsInstalled')} +

+
+ ) : ( + allPlugins.map((plugin) => { + const pluginId = getPluginId(plugin); + const metadata = plugin.manifest.manifest.metadata; + const isSelected = tempSelectedPluginIds.includes(pluginId); + return ( +
handleTogglePlugin(pluginId)} + > + + {metadata.name} +
+
{metadata.name}
+
+ {metadata.author} • v{metadata.version} +
+
+ +
+
+ {!plugin.enabled && ( + + {t('pipelines.extensions.disabled')} + )} - alt={metadata.name} - className="w-10 h-10 rounded-lg border bg-muted object-cover flex-shrink-0" - /> -
-
{metadata.name}
-
- {metadata.author} • v{metadata.version} -
-
- -
- {!plugin.enabled && ( - - {t('pipelines.extensions.disabled')} - - )} -
- ); - })} + ); + }) + )}