From ddbe93fdcc5f3538ec84590c6ab5ee143bbcd3c4 Mon Sep 17 00:00:00 2001 From: ls-root Date: Sun, 1 Feb 2026 13:23:20 +0100 Subject: [PATCH] feat(frontend): add contribution CTA to empty search state (#11412) When a user searches for a script that does not exist, the CommandMenu now displays a link to the contribution guide. This encourages community contributions. --- frontend/src/components/command-menu.tsx | 25 ++++++++++++++++++++++-- 1 file changed, 23 insertions(+), 2 deletions(-) diff --git a/frontend/src/components/command-menu.tsx b/frontend/src/components/command-menu.tsx index 9d4cb9442..7596b8307 100644 --- a/frontend/src/components/command-menu.tsx +++ b/frontend/src/components/command-menu.tsx @@ -1,5 +1,5 @@ import { useRouter } from "next/navigation"; -import { Sparkles } from "lucide-react"; +import { ArrowRightIcon, Sparkles } from "lucide-react"; import Image from "next/image"; import React from "react"; @@ -21,6 +21,7 @@ import { Tooltip, TooltipContent, TooltipProvider, TooltipTrigger } from "./ui/t import { DialogTitle } from "./ui/dialog"; import { Button } from "./ui/button"; import { Badge } from "./ui/badge"; +import Link from "next/link"; export function formattedBadge(type: string) { switch (type) { @@ -211,7 +212,27 @@ function CommandMenu() { Search scripts - {isLoading ? "Loading..." : "No scripts found."} + + {isLoading ? ( + "Searching..." + ) : ( +
+

No scripts match your search.

+
+

Want to add a new script?

+ +
+
+ )} +
{Object.entries(uniqueScriptsByCategory).map(([categoryName, scripts]) => ( {scripts.map(script => (