Translate pie and vislib_basic_options
This commit is contained in:
parent
0600e689ee
commit
8df9757b28
|
@ -3,6 +3,7 @@
|
|||
"common.ui": "src/ui",
|
||||
"inputControl":"src/core_plugins/input_control_vis",
|
||||
"kbn": "src/core_plugins/kibana",
|
||||
"kbnVislibVisTypes": "src/core_plugins/kbn_vislib_vis_types",
|
||||
"markdownVis": "src/core_plugins/markdown_vis",
|
||||
"metricVis": "src/core_plugins/metric_vis",
|
||||
"statusPage": "src/core_plugins/status_page",
|
||||
|
|
|
@ -1,8 +1,11 @@
|
|||
<div class="form-group">
|
||||
<div class="kuiSideBarFormRow">
|
||||
<label class="kuiSideBarFormRow__label" for="visualizeBasicSettingsLegendPosition">
|
||||
Legend Position
|
||||
</label>
|
||||
<label
|
||||
class="kuiSideBarFormRow__label"
|
||||
for="visualizeBasicSettingsLegendPosition"
|
||||
i18n-id="kbnVislibVisTypes.controls.vislibBasicOptions.legendPositionLabel"
|
||||
i18n-default-message="Legend Position"
|
||||
></label>
|
||||
<div class="kuiSideBarFormRow__control">
|
||||
<select
|
||||
id="visualizeBasicSettingsLegendPosition"
|
||||
|
@ -15,9 +18,12 @@
|
|||
</div>
|
||||
|
||||
<div class="kuiSideBarFormRow">
|
||||
<label class="kuiSideBarFormRow__label" for="showTooltip">
|
||||
Show Tooltip
|
||||
</label>
|
||||
<label
|
||||
class="kuiSideBarFormRow__label"
|
||||
for="showTooltip"
|
||||
i18n-id="kbnVislibVisTypes.controls.vislibBasicOptions.showTooltipLabel"
|
||||
i18n-default-message="Show Tooltip"
|
||||
></label>
|
||||
<div class="kuiSideBarFormRow__control">
|
||||
<input id="showTooltip" type="checkbox" ng-model="editorState.params.addTooltip">
|
||||
</div>
|
||||
|
|
|
@ -1,15 +1,20 @@
|
|||
<div class="kuiSideBarSection">
|
||||
<div class="form-group">
|
||||
<div class="kuiSideBarSectionTitle">
|
||||
<div class="kuiSideBarSectionTitle__text">
|
||||
Pie Settings
|
||||
</div>
|
||||
<div
|
||||
class="kuiSideBarSectionTitle__text"
|
||||
i18n-id="kbnVislibVisTypes.editors.pie.pieSettingsTitle"
|
||||
i18n-default-message="Pie Settings"
|
||||
></div>
|
||||
</div>
|
||||
|
||||
<div class="kuiSideBarFormRow">
|
||||
<label class="kuiSideBarFormRow__label" for="isDonut">
|
||||
Donut
|
||||
</label>
|
||||
<label
|
||||
class="kuiSideBarFormRow__label"
|
||||
for="isDonut"
|
||||
i18n-id="kbnVislibVisTypes.editors.pie.donutLabel"
|
||||
i18n-default-message="Donut"
|
||||
></label>
|
||||
<div class="kuiSideBarFormRow__control">
|
||||
<input id="isDonut" name="isDonut" type="checkbox" value="{{isDonut}}"
|
||||
ng-checked="editorState.params.isDonut"
|
||||
|
@ -26,42 +31,56 @@
|
|||
<div class="kuiSideBarSection">
|
||||
<div class="form-group">
|
||||
<div class="kuiSideBarSectionTitle">
|
||||
<div class="kuiSideBarSectionTitle__text">
|
||||
Labels Settings
|
||||
</div>
|
||||
<div
|
||||
class="kuiSideBarSectionTitle__text"
|
||||
i18n-id="kbnVislibVisTypes.editors.pie.labelsSettingsTitle"
|
||||
i18n-default-message="Labels Settings"
|
||||
></div>
|
||||
</div>
|
||||
|
||||
<div class="kuiSideBarFormRow">
|
||||
<label class="kuiSideBarFormRow__label" for="showLabels">
|
||||
Show Labels
|
||||
</label>
|
||||
<label
|
||||
class="kuiSideBarFormRow__label"
|
||||
for="showLabels"
|
||||
i18n-id="kbnVislibVisTypes.editors.pie.showLabelsLabel"
|
||||
i18n-default-message="Show Labels"
|
||||
></label>
|
||||
<div class="kuiSideBarFormRow__control">
|
||||
<input class="kuiCheckBox" id="showLabels" type="checkbox" ng-model="editorState.params.labels.show">
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="kuiSideBarFormRow">
|
||||
<label class="kuiSideBarFormRow__label" for="showLastLevel">
|
||||
Show Top Level Only
|
||||
</label>
|
||||
<label
|
||||
class="kuiSideBarFormRow__label"
|
||||
for="showLastLevel"
|
||||
i18n-id="kbnVislibVisTypes.editors.pie.showTopLevelOnlyLabel"
|
||||
i18n-default-message="Show Top Level Only"
|
||||
></label>
|
||||
<div class="kuiSideBarFormRow__control">
|
||||
<input class="kuiCheckBox" id="showLastLevel" type="checkbox" ng-model="editorState.params.labels.last_level">
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="kuiSideBarFormRow">
|
||||
<label class="kuiSideBarFormRow__label" for="showValues">
|
||||
Show Values
|
||||
</label>
|
||||
<label
|
||||
class="kuiSideBarFormRow__label"
|
||||
for="showValues"
|
||||
i18n-id="kbnVislibVisTypes.editors.pie.showValuesLabel"
|
||||
i18n-default-message="Show Values"
|
||||
></label>
|
||||
<div class="kuiSideBarFormRow__control">
|
||||
<input class="kuiCheckBox" id="showValues" type="checkbox" ng-model="editorState.params.labels.values">
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="kuiSideBarFormRow">
|
||||
<label class="kuiSideBarFormRow__label" for="truncateLabels">
|
||||
Truncate
|
||||
</label>
|
||||
<label
|
||||
class="kuiSideBarFormRow__label"
|
||||
for="truncateLabels"
|
||||
i18n-id="kbnVislibVisTypes.editors.pie.truncateLabel"
|
||||
i18n-default-message="Truncate"
|
||||
></label>
|
||||
<div class="kuiSideBarFormRow__control">
|
||||
<input
|
||||
id="truncateLabels"
|
||||
|
|
|
@ -22,14 +22,14 @@ import { Schemas } from 'ui/vis/editors/default/schemas';
|
|||
import { CATEGORY } from 'ui/vis/vis_category';
|
||||
import pieTemplate from './editors/pie.html';
|
||||
|
||||
export default function HistogramVisType(Private) {
|
||||
export default function HistogramVisType(Private, i18n) {
|
||||
const VisFactory = Private(VisFactoryProvider);
|
||||
|
||||
return VisFactory.createVislibVisualization({
|
||||
name: 'pie',
|
||||
title: 'Pie',
|
||||
title: i18n('kbnVislibVisTypes.pie.pieTitle', { defaultMessage: 'Pie' }),
|
||||
icon: 'visPie',
|
||||
description: 'Compare parts of a whole',
|
||||
description: i18n('kbnVislibVisTypes.pie.pieDescription', { defaultMessage: 'Compare parts of a whole' }),
|
||||
category: CATEGORY.BASIC,
|
||||
visConfig: {
|
||||
defaults: {
|
||||
|
@ -67,7 +67,7 @@ export default function HistogramVisType(Private) {
|
|||
{
|
||||
group: 'metrics',
|
||||
name: 'metric',
|
||||
title: 'Slice Size',
|
||||
title: i18n('kbnVislibVisTypes.pie.metricTitle', { defaultMessage: 'Slice Size' }),
|
||||
min: 1,
|
||||
max: 1,
|
||||
aggFilter: ['sum', 'count', 'cardinality', 'top_hits'],
|
||||
|
@ -79,7 +79,7 @@ export default function HistogramVisType(Private) {
|
|||
group: 'buckets',
|
||||
name: 'segment',
|
||||
icon: 'fa fa-scissors',
|
||||
title: 'Split Slices',
|
||||
title: i18n('kbnVislibVisTypes.pie.segmentTitle', { defaultMessage: 'Split Slices' }),
|
||||
min: 0,
|
||||
max: Infinity,
|
||||
aggFilter: ['!geohash_grid', '!filter']
|
||||
|
@ -88,7 +88,7 @@ export default function HistogramVisType(Private) {
|
|||
group: 'buckets',
|
||||
name: 'split',
|
||||
icon: 'fa fa-th',
|
||||
title: 'Split Chart',
|
||||
title: i18n('kbnVislibVisTypes.pie.splitTitle', { defaultMessage: 'Split Chart' }),
|
||||
mustBeFirst: true,
|
||||
min: 0,
|
||||
max: 1,
|
||||
|
|
Loading…
Reference in a new issue