diff options
author | Stas Vilchik <stas.vilchik@sonarsource.com> | 2018-04-04 08:43:42 +0200 |
---|---|---|
committer | Janos Gyerik <janos.gyerik@sonarsource.com> | 2018-04-04 14:40:51 +0200 |
commit | 75abdef0c27dc443aaa4f05c2e868119887afb3c (patch) | |
tree | 518a685db666e6a38b6c92212bffbdfa39054849 /server/sonar-web/src/main/js/components/intl | |
parent | 941cdf85a80bdf1049a6e3a2dfaa0690969a5e45 (diff) | |
download | sonarqube-75abdef0c27dc443aaa4f05c2e868119887afb3c.tar.gz sonarqube-75abdef0c27dc443aaa4f05c2e868119887afb3c.zip |
SONAR-9697 Ensure tooltips are always placed correctly (#77)
Diffstat (limited to 'server/sonar-web/src/main/js/components/intl')
-rw-r--r-- | server/sonar-web/src/main/js/components/intl/DateTooltipFormatter.tsx | 8 | ||||
-rw-r--r-- | server/sonar-web/src/main/js/components/intl/TimeTooltipFormatter.tsx | 8 |
2 files changed, 4 insertions, 12 deletions
diff --git a/server/sonar-web/src/main/js/components/intl/DateTooltipFormatter.tsx b/server/sonar-web/src/main/js/components/intl/DateTooltipFormatter.tsx index 6cc226349dd..ff16ad68432 100644 --- a/server/sonar-web/src/main/js/components/intl/DateTooltipFormatter.tsx +++ b/server/sonar-web/src/main/js/components/intl/DateTooltipFormatter.tsx @@ -26,18 +26,14 @@ import { parseDate } from '../../helpers/dates'; interface Props { className?: string; date: Date | string | number; - placement?: string; } -export default function DateTooltipFormatter({ className, date, placement }: Props) { +export default function DateTooltipFormatter({ className, date }: Props) { const parsedDate = parseDate(date); return ( <DateFormatter date={parsedDate} long={true}> {formattedDate => ( - <Tooltip - overlay={<DateTimeFormatter date={parsedDate} />} - placement={placement} - mouseEnterDelay={0.5}> + <Tooltip mouseEnterDelay={0.5} overlay={<DateTimeFormatter date={parsedDate} />}> <time className={className} dateTime={parsedDate.toISOString()}> {formattedDate} </time> diff --git a/server/sonar-web/src/main/js/components/intl/TimeTooltipFormatter.tsx b/server/sonar-web/src/main/js/components/intl/TimeTooltipFormatter.tsx index 0c16f785b8a..e73ba24ee7c 100644 --- a/server/sonar-web/src/main/js/components/intl/TimeTooltipFormatter.tsx +++ b/server/sonar-web/src/main/js/components/intl/TimeTooltipFormatter.tsx @@ -25,18 +25,14 @@ import { parseDate } from '../../helpers/dates'; interface Props { className?: string; date: Date | string | number; - placement?: string; } -export default function TimeTooltipFormatter({ className, date, placement }: Props) { +export default function TimeTooltipFormatter({ className, date }: Props) { const parsedDate = parseDate(date); return ( <TimeFormatter date={parsedDate} long={false}> {formattedTime => ( - <Tooltip - overlay={<TimeFormatter date={parsedDate} long={true} />} - placement={placement} - mouseEnterDelay={0.5}> + <Tooltip mouseEnterDelay={0.5} overlay={<TimeFormatter date={parsedDate} long={true} />}> <time className={className} dateTime={parsedDate.toISOString()}> {formattedTime} </time> |