diff --git a/website/src/pages/plugins/index.tsx b/website/src/pages/plugins/index.tsx
index bec8ff1207..31ee27b62c 100644
--- a/website/src/pages/plugins/index.tsx
+++ b/website/src/pages/plugins/index.tsx
@@ -71,16 +71,12 @@ function highlightMatch(text: string, query: string): React.ReactNode {
function PluginCard({
plugin,
query,
- expanded,
- onToggle,
onPick,
onCategoryClick,
style,
}: {
plugin: CatalogPlugin;
query: string;
- expanded: boolean;
- onToggle: () => void;
/** Picker embed mode: render "+ Add to this Agent" and call this. */
onPick?: (plugin: CatalogPlugin) => void;
onCategoryClick?: (category: string) => void;
@@ -95,14 +91,21 @@ function PluginCard({
const pagePath = pluginPagePath(plugin.name);
const history = useHistory();
const pageHref = useBaseUrl(pagePath); // adds baseUrl itself; history.push does not
- // Outside the Desktop picker a card is a link to the plugin's own page (shareable, indexable);
- // inside the picker iframe navigation would leave the host's embed, so the card keeps
- // expanding in place there.
- const onCardClick = onPick ? onToggle : () => history.push(pageHref);
+ // A card IS the link to the plugin's own page: nothing expands or collapses in place. Inside
+ // the Desktop picker iframe an in-frame navigation would leave the host's embed, so the page
+ // opens in a new tab there instead.
+ const onCardClick = onPick
+ ? () => window.open(new URL(pageHref, window.location.href).toString(), "_blank", "noopener,noreferrer")
+ : () => history.push(pageHref);
return (
{
+ if (e.key === "Enter") onCardClick();
+ }}
onClick={onCardClick}
style={style}
>
@@ -159,7 +162,7 @@ function PluginCard({
-
+
{highlightMatch(plugin.description || "No description available.", query)}