diff --git a/static/app/components/version.tsx b/static/app/components/version.tsx index 89348e28244cce..febc40e2beeb01 100644 --- a/static/app/components/version.tsx +++ b/static/app/components/version.tsx @@ -1,4 +1,4 @@ -import {css, useTheme} from '@emotion/react'; +import {css} from '@emotion/react'; import styled from '@emotion/styled'; import {CopyToClipboardButton} from 'sentry/components/copyToClipboardButton'; @@ -68,7 +68,7 @@ function Version({ const versionToDisplay = shouldFormatVersion ? formatVersion(version, withPackage) : version; - const theme = useTheme(); + const isHashVersion = /\b[a-f0-9]{40}\b|\b[a-f0-9]{64}\b/.test(version); let releaseDetailProjectId: null | undefined | string | string[]; if (projectId) { @@ -132,27 +132,13 @@ function Version({ ); - const getOverlayStyle = () => { - // if the version name is not a hash (sha1 or sha265) and we are not on - // mobile, allow tooltip to be as wide as 500px - if (/(^[a-f0-9]{40}$)|(^[a-f0-9]{64}$)/.test(version)) { - return undefined; - } - - return css` - @media (min-width: ${theme.breakpoints.sm}) { - max-width: 500px; - } - `; - }; - return ( {renderVersion()}