i18n: Add translation for json editor settings (#75549)

* add translation for json editor settings

* add different translations

* update translation

* update pseudo locale

* update locales

* Use Trans and new i118n key

* add psuedo locale translations

* Update public/locales/pseudo-LOCALE/grafana.json

Co-authored-by: Isabel <76437239+imatwawana@users.noreply.github.com>

* Update public/locales/en-US/grafana.json

Co-authored-by: Isabel <76437239+imatwawana@users.noreply.github.com>

* Update public/app/features/dashboard/components/DashboardSettings/JsonEditorSettings.tsx

Co-authored-by: Isabel <76437239+imatwawana@users.noreply.github.com>

---------

Co-authored-by: Isabel <76437239+imatwawana@users.noreply.github.com>
pull/75463/head
otilor 2 years ago committed by GitHub
parent 169c5262a5
commit 6ff767a6bb
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 9
      public/app/features/dashboard/components/DashboardSettings/JsonEditorSettings.tsx
  2. 6
      public/locales/de-DE/grafana.json
  3. 6
      public/locales/en-US/grafana.json
  4. 6
      public/locales/es-ES/grafana.json
  5. 6
      public/locales/fr-FR/grafana.json
  6. 6
      public/locales/pseudo-LOCALE/grafana.json
  7. 6
      public/locales/zh-Hans/grafana.json

@ -4,6 +4,7 @@ import React, { useState } from 'react';
import { GrafanaTheme2 } from '@grafana/data';
import { Button, CodeEditor, useStyles2 } from '@grafana/ui';
import { Page } from 'app/core/components/Page/Page';
import { t, Trans } from 'app/core/internationalization';
import { dashboardWatcher } from 'app/features/live/dashboard/dashboardWatcher';
import { getDashboardSrv } from '../../services/DashboardSrv';
@ -19,8 +20,10 @@ export function JsonEditorSettings({ dashboard, sectionNav }: SettingsPageProps)
};
const styles = useStyles2(getStyles);
const subTitle =
'The JSON model below is the data structure that defines the dashboard. This includes dashboard settings, panel settings, layout, queries, and so on';
const subTitle = t(
'dashboard-settings.json-editor.subtitle',
'The JSON model below is the data structure that defines the dashboard. This includes dashboard settings, panel settings, layout, queries, and so on.'
);
return (
<Page navModel={sectionNav} subTitle={subTitle}>
@ -36,7 +39,7 @@ export function JsonEditorSettings({ dashboard, sectionNav }: SettingsPageProps)
{dashboard.meta.canSave && (
<div>
<Button type="submit" onClick={onClick}>
Save changes
<Trans i18nKey="dashboard-settings.json-editor.save-button">Save changes</Trans>
</Button>
</div>
)}

@ -215,6 +215,12 @@
"unmark-favorite": "Markierung als Favorit entfernen"
}
},
"dashboard-settings": {
"json-editor": {
"save-button": "",
"subtitle": ""
}
},
"data-source-picker": {
"open-advanced-button": ""
},

@ -215,6 +215,12 @@
"unmark-favorite": "Unmark as favorite"
}
},
"dashboard-settings": {
"json-editor": {
"save-button": "Save changes",
"subtitle": "The JSON model below is the data structure that defines the dashboard. This includes dashboard settings, panel settings, layout, queries, and so on."
}
},
"data-source-picker": {
"open-advanced-button": "Open advanced data source picker"
},

@ -220,6 +220,12 @@
"unmark-favorite": "Deshacer marca como favorito"
}
},
"dashboard-settings": {
"json-editor": {
"save-button": "",
"subtitle": ""
}
},
"data-source-picker": {
"open-advanced-button": ""
},

@ -220,6 +220,12 @@
"unmark-favorite": "Supprimer des favoris"
}
},
"dashboard-settings": {
"json-editor": {
"save-button": "",
"subtitle": ""
}
},
"data-source-picker": {
"open-advanced-button": ""
},

@ -215,6 +215,12 @@
"unmark-favorite": "Ůʼnmäřĸ äş ƒävőřįŧę"
}
},
"dashboard-settings": {
"json-editor": {
"save-button": "Ŝävę čĥäʼnģęş",
"subtitle": "Ŧĥę ĴŜØŃ mőđęľ þęľőŵ įş ŧĥę đäŧä şŧřūčŧūřę ŧĥäŧ đęƒįʼnęş ŧĥę đäşĥþőäřđ. Ŧĥįş įʼnčľūđęş đäşĥþőäřđ şęŧŧįʼnģş, päʼnęľ şęŧŧįʼnģş, ľäyőūŧ, qūęřįęş, äʼnđ şő őʼn."
}
},
"data-source-picker": {
"open-advanced-button": "Øpęʼn äđväʼnčęđ đäŧä şőūřčę pįčĸęř"
},

@ -210,6 +210,12 @@
"unmark-favorite": "取消标记为收藏"
}
},
"dashboard-settings": {
"json-editor": {
"save-button": "",
"subtitle": ""
}
},
"data-source-picker": {
"open-advanced-button": ""
},

Loading…
Cancel
Save