Internationalization: Translate CalendarFooter component (#58326)

This commit is contained in:
Laura Fernández
2022-11-07 14:42:20 +01:00
committed by GitHub
parent 97df6e682e
commit e5d4d00c1f
7 changed files with 15 additions and 2 deletions
@@ -4,6 +4,7 @@ import React from 'react';
import { GrafanaTheme2 } from '@grafana/data';
import { useStyles2 } from '../../../themes';
import { Trans } from '../../../utils/i18n';
import { Button } from '../../Button';
import { TimePickerCalendarProps } from './TimePickerCalendar';
@@ -14,10 +15,10 @@ export function Footer({ onClose, onApply }: TimePickerCalendarProps) {
return (
<div className={styles.container}>
<Button className={styles.apply} onClick={onApply}>
Apply time range
<Trans i18nKey="time-picker.calendar.apply-button">Apply time range</Trans>
</Button>
<Button variant="secondary" onClick={onClose}>
Cancel
<Trans i18nKey="time-picker.calendar.cancel-button">Cancel</Trans>
</Button>
</div>
);