import { Trans } from "@lingui/macro" import { ActionIcon, Anchor, Tooltip } from "@mantine/core" import { Constants } from "app/constants" import { markEntry } from "app/entries/thunks" import { useAppDispatch } from "app/store" import type { Entry } from "app/types" import { TbExternalLink } from "react-icons/tb" export function OpenExternalLink(props: { entry: Entry }) { const dispatch = useAppDispatch() const onClick = (e: React.MouseEvent) => { e.stopPropagation() dispatch( markEntry({ entry: props.entry, read: true, }) ) } return ( Open link} openDelay={Constants.tooltip.delay}> ) }