diff --git a/Frontend/src/app/components/simple-tooltip.tsx b/Frontend/src/app/components/simple-tooltip.tsx new file mode 100644 index 0000000..5061efb --- /dev/null +++ b/Frontend/src/app/components/simple-tooltip.tsx @@ -0,0 +1,39 @@ +import { ReactElement, ReactNode } from "react"; +import { + Tooltip, + TooltipContent, + TooltipTrigger, +} from "@/components/ui/tooltip"; + +/** + * The props for a simple tooltip. + */ +type SimpleTooltipProps = { + /** + * The content to display in the tooltip. + */ + content: string; + + /** + * The children to render in this tooltip. + */ + children: ReactNode; +}; + +/** + * A simple tooltip, this is wrapping the + * shadcn tooltip to make it easier to use. + * + * @return the tooltip jsx + */ +const SimpleTooltip = ({ + content, + children, +}: SimpleTooltipProps): ReactElement => ( + + {children} + {content} + +); + +export default SimpleTooltip;