From 2d9523f963d29f9db209657e25c4e7a87c3f8bc3 Mon Sep 17 00:00:00 2001 From: Mike Cao Date: Tue, 15 Sep 2020 20:34:30 -0700 Subject: [PATCH] Messages for devices so they can be localized. --- components/common/RefreshButton.js | 11 ++++++++++- components/layout/Footer.js | 7 ++++--- components/messages.js | 17 +++++++++++++++++ components/metrics/DevicesTable.js | 2 ++ components/metrics/WebsiteHeader.module.css | 1 + components/settings/WebsiteSettings.js | 12 ++++++++++-- lang/de-DE.json | 6 ++++++ lang/en-US.json | 6 ++++++ lang/es-MX.json | 6 ++++++ lang/fr-FR.json | 8 +++++++- lang/ja-JP.json | 6 ++++++ lang/mn-MN.json | 8 +++++++- lang/nl-NL.json | 6 ++++++ lang/ru-RU.json | 6 ++++++ lang/tr-TR.json | 6 ++++++ lang/zh-CN.json | 6 ++++++ lib/constants.js | 7 ------- lib/filters.js | 9 ++++----- styles/index.css | 20 +------------------- 19 files changed, 111 insertions(+), 39 deletions(-) create mode 100644 components/messages.js diff --git a/components/common/RefreshButton.js b/components/common/RefreshButton.js index 60d0976e..b3e00a27 100644 --- a/components/common/RefreshButton.js +++ b/components/common/RefreshButton.js @@ -1,5 +1,6 @@ import React, { useState, useEffect } from 'react'; import { useDispatch, useSelector } from 'react-redux'; +import { FormattedMessage } from 'react-intl'; import { setDateRange } from 'redux/actions/websites'; import Button from './Button'; import Refresh from 'assets/redo.svg'; @@ -24,5 +25,13 @@ export default function RefreshButton({ websiteId }) { setLoading(false); }, [completed]); - return