import MinecraftButton from "@/components/minecraft-button"; import { Input } from "@/components/ui/input"; import { Label } from "@/components/ui/label"; import { redirect } from "next/navigation"; import { ReactElement } from "react"; /** * A component for searching for a player. * * @param query the query to search for * @returns the search component jsx */ const PlayerSearch = ({ query, }: { query: string | undefined; }): ReactElement => { const handleRedirect = async (form: FormData): Promise => { "use server"; redirect(`/player/${form.get("query")}`); }; return (
Search
); }; export default PlayerSearch;