diff --git a/src/components/Hack/HackOptionsMenu.tsx b/src/components/Hack/HackOptionsMenu.tsx index c3eb82f..8f5b965 100644 --- a/src/components/Hack/HackOptionsMenu.tsx +++ b/src/components/Hack/HackOptionsMenu.tsx @@ -3,7 +3,7 @@ import React from "react"; import { useRouter } from "next/navigation"; import { FiMoreVertical } from "react-icons/fi"; -import { Menu, MenuButton, MenuItem, MenuItems, MenuSeparator, Transition } from "@headlessui/react"; +import { Menu, MenuButton, MenuItem, MenuItems, MenuSeparator } from "@headlessui/react"; interface HackOptionsMenuProps { slug: string; @@ -23,49 +23,42 @@ export default function HackOptionsMenu({ slug, canEdit }: HackOptionsMenuProps) - - + { + // TODO: Implement share + }} + className="block w-full px-3 py-2 text-left text-sm data-focus:bg-black/5 dark:data-focus:bg-white/10"> + Share + + { + // TODO: Implement report + }} + className="block w-full px-3 py-2 text-left text-sm data-focus:bg-black/5 dark:data-focus:bg-white/10"> + Report + + {canEdit && <> + { - // TODO: Implement share - }} - className="block w-full px-3 py-2 text-left text-sm data-focus:bg-black/5 dark:data-focus:bg-white/10"> - Share - - { - // TODO: Implement report - }} + as="a" + href={`/hack/${slug}/edit`} className="block w-full px-3 py-2 text-left text-sm data-focus:bg-black/5 dark:data-focus:bg-white/10"> - Report + Edit - {canEdit && <> - - - Edit - - - Upload new version - - } - - + + Upload new version + + } + ); }