import {LinkButton} from 'sentry/components/button'; import {t} from 'sentry/locale'; import type {Organization} from 'sentry/types/organization'; import trackGetsentryAnalytics from 'getsentry/utils/trackGetsentryAnalytics'; const learnMoreClicked = ({ source, organization, }: Pick) => trackGetsentryAnalytics('learn_more_link.clicked', { organization, source, }); type Props = React.PropsWithChildren<{ organization: Organization; source: string; analyticsData?: Record; 'aria-label'?: string; children?: React.ReactChild; }> & React.ComponentProps; function LearnMoreButton({organization, source, children, ...props}: Props) { return ( learnMoreClicked({source, organization})} {...props}> {children || t('Learn More')} ); } export default LearnMoreButton;