[i18n] Translate Agg_response, Agg_table (#26875)

* Translate agg_response

* Translate agg_table

* Fix issues
This commit is contained in:
Nox911 2018-12-14 11:10:16 +03:00 committed by GitHub
parent 71ca3692ec
commit 34a2a47029
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 28 additions and 6 deletions

View file

@ -1,8 +1,16 @@
<table class="visTooltip__table">
<thead>
<tr class="eui-textLeft visTooltip__label">
<th scope="col">field</th>
<th scope="col">value</th>
<th
scope="col"
i18n-id="common.ui.aggResponse.fieldLabel"
i18n-default-message="field"
></th>
<th
scope="col"
i18n-id="common.ui.aggResponse.valueLabel"
i18n-default-message="value"
></th>
<th scope="col">{{metricCol.label}}</th>
</tr>
</thead>

View file

@ -18,10 +18,13 @@
*/
import { AggType } from '../../agg_types/agg_type';
import { i18n } from '@kbn/i18n';
const allAgg = new AggType({
name: 'all',
title: 'All docs',
title: i18n.translate('common.ui.aggResponse.allDocsTitle', {
defaultMessage: 'All docs'
}),
ordered: false,
hasNoDsl: true
});

View file

@ -8,12 +8,23 @@
totalFunc="totalFunc">
<div class="kbnAggTable__controls">
<small>Export:</small>&nbsp;&nbsp;
<small
i18n-id="common.ui.aggTable.exportLabel"
i18n-default-message="Export:"
></small>&nbsp;&nbsp;
<a class="small" ng-click="aggTable.exportAsCsv(false)">
Raw <i aria-hidden="true" class="fa fa-download"></i>
<span
i18n-id="common.ui.aggTable.rawLabel"
i18n-default-message="Raw"
></span>
<i aria-hidden="true" class="fa fa-download"></i>
</a>&nbsp;&nbsp;&nbsp;
<a class="small" ng-click="aggTable.exportAsCsv(true)">
Formatted <i aria-hidden="true" class="fa fa-download"></i>
<span
i18n-id="common.ui.aggTable.formattedLabel"
i18n-default-message="Formatted"
></span>
<i aria-hidden="true" class="fa fa-download"></i>
</a>
<paginate-controls></paginate-controls>
</div>