Skip to content

📈 Open source, privacy-first web analytics — a cookie-less Google Analytics alternative with built-in error tracking and performance monitoring. Self-host it or use our cloud. Get started for free!

displaying notification when export as img fails

Blue Mousef1ba22bf0b12
diff --git a/public/locales/de.json b/public/locales/de.json
index fdb314984..1491f9e9d 100644
--- a/public/locales/de.json
+++ b/public/locales/de.json
@@ -460,6 +460,7 @@
"week": "Woche",
"month": "Monat",
"resetFilters": "Reset filters",
+ "exportImgError": "Exporting data as image failed",
"settings": {
"verify": "Bitte bestätigen Sie zunächst Ihre E-Mail-Adresse",
"updated": "Die Projekteinstellungen wurden aktualisiert",
diff --git a/public/locales/el.json b/public/locales/el.json
index ce13b1666..30c3e23da 100644
--- a/public/locales/el.json
+++ b/public/locales/el.json
@@ -460,6 +460,7 @@
"week": "Εβδομάδα",
"month": "Μήνας",
"resetFilters": "Reset filters",
+ "exportImgError": "Exporting data as image failed",
"settings": {
"verify": "Παρακαλώ, επαληθεύστε πρώτα τη διεύθυνση email σας",
"updated": "Οι ρυθμίσεις του έργου ενημερώθηκαν",
diff --git a/public/locales/en.json b/public/locales/en.json
index 24983d1f6..6095d54f1 100644
--- a/public/locales/en.json
+++ b/public/locales/en.json
@@ -460,6 +460,7 @@
"week": "Week",
"month": "Month",
"resetFilters": "Reset filters",
+ "exportImgError": "Exporting data as image failed",
"settings": {
"verify": "Please, verify your email address first",
"updated": "The project's settings were updated",
diff --git a/public/locales/es.json b/public/locales/es.json
index 24983d1f6..6095d54f1 100644
--- a/public/locales/es.json
+++ b/public/locales/es.json
@@ -460,6 +460,7 @@
"week": "Week",
"month": "Month",
"resetFilters": "Reset filters",
+ "exportImgError": "Exporting data as image failed",
"settings": {
"verify": "Please, verify your email address first",
"updated": "The project's settings were updated",
diff --git a/public/locales/fr.json b/public/locales/fr.json
index 24983d1f6..6095d54f1 100644
--- a/public/locales/fr.json
+++ b/public/locales/fr.json
@@ -460,6 +460,7 @@
"week": "Week",
"month": "Month",
"resetFilters": "Reset filters",
+ "exportImgError": "Exporting data as image failed",
"settings": {
"verify": "Please, verify your email address first",
"updated": "The project's settings were updated",
diff --git a/public/locales/hi.json b/public/locales/hi.json
index 78381fa3c..f2240b93a 100644
--- a/public/locales/hi.json
+++ b/public/locales/hi.json
@@ -460,6 +460,7 @@
"week": "सप्ताह",
"month": "महीना",
"resetFilters": "Reset filters",
+ "exportImgError": "Exporting data as image failed",
"settings": {
"verify": "कृपया, पहले अपना ईमेल पता सत्यापित करें",
"updated": "प्रोजेक्ट की सेटिंग्स को अपडेट किया गया",
diff --git a/public/locales/it.json b/public/locales/it.json
index 24983d1f6..6095d54f1 100644
--- a/public/locales/it.json
+++ b/public/locales/it.json
@@ -460,6 +460,7 @@
"week": "Week",
"month": "Month",
"resetFilters": "Reset filters",
+ "exportImgError": "Exporting data as image failed",
"settings": {
"verify": "Please, verify your email address first",
"updated": "The project's settings were updated",
diff --git a/public/locales/ru.json b/public/locales/ru.json
index 12d3103fa..b07b311bb 100644
--- a/public/locales/ru.json
+++ b/public/locales/ru.json
@@ -460,6 +460,7 @@
"week": "Неделя",
"month": "Месяц",
"resetFilters": "Сбросить фильтры",
+ "exportImgError": "Не удалось экспортировать данные как изображение",
"settings": {
"verify": "Пожалуйста, сначала подтвердите адрес эл. почты",
"updated": "Настройки проекта были обновлены",
diff --git a/public/locales/sv.json b/public/locales/sv.json
index 619a2b0b0..cf098667e 100644
--- a/public/locales/sv.json
+++ b/public/locales/sv.json
@@ -460,6 +460,7 @@
"week": "Vecka",
"month": "Månad",
"resetFilters": "Reset filters",
+ "exportImgError": "Exporting data as image failed",
"settings": {
"verify": "Vänligen verifiera din e-postadress först",
"updated": "Projektets inställningar var uppdaterats",
diff --git a/public/locales/uk.json b/public/locales/uk.json
index d584e7195..073f7d0d1 100644
--- a/public/locales/uk.json
+++ b/public/locales/uk.json
@@ -460,6 +460,7 @@
"week": "Тиждень",
"month": "Місяць",
"resetFilters": "Скинути фільтри",
+ "exportImgError": "Не вдалося експортувати дані як зображення",
"settings": {
"verify": "Будь ласка, спочатку підтвердіть вашу ел. адресу",
"updated": "Налаштування проєкту було оновлено",
diff --git a/public/locales/zh.json b/public/locales/zh.json
index e7783a9ee..91cf904a6 100644
--- a/public/locales/zh.json
+++ b/public/locales/zh.json
@@ -460,6 +460,7 @@
"week": "周",
"month": "月",
"resetFilters": "Reset filters",
+ "exportImgError": "Exporting data as image failed",
"settings": {
"verify": "请先验证您的电子邮件地址",
"updated": "项目的设置已更新",
diff --git a/src/pages/Project/View/ViewProject.jsx b/src/pages/Project/View/ViewProject.jsx
index fb21c8ab7..c917eb108 100644
--- a/src/pages/Project/View/ViewProject.jsx
+++ b/src/pages/Project/View/ViewProject.jsx
@@ -770,6 +770,7 @@ const ViewProject = ({
const blob = await domToImage.toBlob(dashboardRef.current)
saveAs(blob, `swetrix-${dayjs().format('YYYY-MM-DD-HH-mm-ss')}.png`)
} catch (e) {
+ showError(t('project.exportImgError'))
console.error('[ERROR] Error while generating export image.')
console.error(e)
} finally {