add translations

alerting/better-search-2^2
Gilles De Mey 10 months ago
parent a93b4aeef8
commit 9b437bd866
No known key found for this signature in database
  1. 53
      public/app/features/alerting/unified/components/rules/Filter/RulesFilter.v2.tsx
  2. 19
      public/locales/en-US/grafana.json
  3. 19
      public/locales/pseudo-LOCALE/grafana.json

@ -17,6 +17,7 @@ import {
TabsBar,
useStyles2,
} from '@grafana/ui';
import { Trans } from 'app/core/internationalization';
import { PopupCard } from '../../HoverCard';
import MoreButton from '../../MoreButton';
@ -66,7 +67,9 @@ export default function RulesFilter({ onClear = () => {} }: RulesFilterProps) {
return (
<Stack direction="column" gap={0}>
<Label>Search</Label>
<Label>
<Trans i18nKey="common.search">Search</Trans>
</Label>
<Stack direction="row">
<Input prefix={filterOptions} />
</Stack>
@ -78,17 +81,29 @@ const FilterOptions = () => {
return (
<Stack direction="column" alignItems="end" gap={2}>
<Grid columns={2} gap={2} alignItems="center">
<Label>Folder / Namespace</Label>
<Label>
<Trans i18nKey="alerting.search.property.namespace">Folder / Namespace</Trans>
</Label>
<Select options={[]} onChange={() => {}}></Select>
<Label>Alert rule name</Label>
<Label>
<Trans i18nKey="alerting.search.property.rule-name">Alerting rule name</Trans>
</Label>
<Input />
<Label>Evaluation group</Label>
<Label>
<Trans i18nKey="alerting.search.property.evaluation-group">Evaluation group</Trans>
</Label>
<Input />
<Label>Labels</Label>
<Label>
<Trans i18nKey="alerting.search.property.labels">Labels</Trans>
</Label>
<Input />
<Label>Data source</Label>
<Label>
<Trans i18nKey="alerting.search.property.data-source">Data source</Trans>
</Label>
<Select options={[]} onChange={() => {}}></Select>
<Label>State</Label>
<Label>
<Trans i18nKey="alerting.search.property.state">State</Trans>
</Label>
<RadioButtonGroup
value={'*'}
options={[
@ -98,7 +113,9 @@ const FilterOptions = () => {
{ label: 'Firing', value: 'firing' },
]}
/>
<Label>Type</Label>
<Label>
<Trans i18nKey="alerting.search.property.rule-type">Type</Trans>
</Label>
<RadioButtonGroup
value={'*'}
options={[
@ -107,7 +124,9 @@ const FilterOptions = () => {
{ label: 'Recording rule', value: 'recording' },
]}
/>
<Label>Health</Label>
<Label>
<Trans i18nKey="alerting.search.property.rule-health">Health</Trans>
</Label>
<RadioButtonGroup
value={'*'}
options={[
@ -119,8 +138,12 @@ const FilterOptions = () => {
/>
</Grid>
<Stack direction="row" alignItems="center">
<Button variant="secondary">Clear</Button>
<Button>Apply</Button>
<Button variant="secondary">
<Trans i18nKey="common.clear">Clear</Trans>
</Button>
<Button>
<Trans i18nKey="common.apply">Apply</Trans>
</Button>
</Stack>
</Stack>
);
@ -138,7 +161,7 @@ const SavedSearches = () => {
<>
<Stack direction="column" gap={2} alignItems="flex-end">
<Button variant="secondary" size="sm">
Save current search
<Trans i18nKey="alerting.search.save-query">Save current search</Trans>
</Button>
<InteractiveTable<TableColumns>
columns={[
@ -157,7 +180,7 @@ const SavedSearches = () => {
cell: ({ row }) => (
<Stack direction="row" alignItems="center">
<Button variant="secondary" fill="outline" size="sm" onClick={() => applySearch(row.original.name)}>
Apply
<Trans i18nKey="common.apply">Apply</Trans>
</Button>
<MoreButton size="sm" fill="outline" />
</Stack>
@ -178,7 +201,9 @@ const SavedSearches = () => {
]}
getRowId={(row) => row.name}
/>
<Button variant="secondary">Close</Button>
<Button variant="secondary">
<Trans i18nKey="common.close">Close</Trans>
</Button>
</Stack>
</>
);

@ -218,6 +218,19 @@
"update-rule": {
"success": "Rule updated successfully"
}
},
"search": {
"property": {
"data-source": "Data source",
"evaluation-group": "Evaluation group",
"labels": "Labels",
"namespace": "Folder / Namespace",
"rule-health": "Health",
"rule-name": "Alerting rule name",
"rule-type": "Type",
"state": "State"
},
"save-query": "Save current search"
}
},
"annotations": {
@ -360,11 +373,15 @@
}
},
"common": {
"apply": "Apply",
"cancel": "Cancel",
"clear": "Clear",
"close": "Close",
"locale": {
"default": "Default"
},
"save": "Save"
"save": "Save",
"search": "Search"
},
"complete": "complete",
"connections": {

@ -218,6 +218,19 @@
"update-rule": {
"success": "Ŗūľę ūpđäŧęđ şūččęşşƒūľľy"
}
},
"search": {
"property": {
"data-source": "Đäŧä şőūřčę",
"evaluation-group": "Ēväľūäŧįőʼn ģřőūp",
"labels": "Ŀäþęľş",
"namespace": "Főľđęř / Ńämęşpäčę",
"rule-health": "Ħęäľŧĥ",
"rule-name": "Åľęřŧįʼnģ řūľę ʼnämę",
"rule-type": "Ŧypę",
"state": "Ŝŧäŧę"
},
"save-query": "Ŝävę čūřřęʼnŧ şęäřčĥ"
}
},
"annotations": {
@ -360,11 +373,15 @@
}
},
"common": {
"apply": "Åppľy",
"cancel": "Cäʼnčęľ",
"clear": "Cľęäř",
"close": "Cľőşę",
"locale": {
"default": "Đęƒäūľŧ"
},
"save": "Ŝävę"
"save": "Ŝävę",
"search": "Ŝęäřčĥ"
},
"complete": "čőmpľęŧę",
"connections": {

Loading…
Cancel
Save