diff --git a/x-pack/plugins/watcher/public/components/threshold_watch_expression/components/threshold_watch_agg_field/threshold_watch_agg_field.html b/x-pack/plugins/watcher/public/components/threshold_watch_expression/components/threshold_watch_agg_field/threshold_watch_agg_field.html index f220d73ac3e32f..a103fbecfc5881 100644 --- a/x-pack/plugins/watcher/public/components/threshold_watch_expression/components/threshold_watch_agg_field/threshold_watch_agg_field.html +++ b/x-pack/plugins/watcher/public/components/threshold_watch_expression/components/threshold_watch_agg_field/threshold_watch_agg_field.html @@ -16,9 +16,9 @@ xpack-aria-describes="{{thresholdWatchAggField.makeId('aggField')}}" class="kuiInputNote kuiInputNote--danger" ng-if="thresholdWatchAggField.isValidationMessageVisible('aggField', 'required')" - > - Please select a field. - + i18n-id="xpack.watcher.thresholdWatchExpression.aggType.fieldIsRequiredValidationMessage" + i18n-default-message="Please select a field." + > diff --git a/x-pack/plugins/watcher/public/components/threshold_watch_expression/components/threshold_watch_agg_field/threshold_watch_agg_field.js b/x-pack/plugins/watcher/public/components/threshold_watch_expression/components/threshold_watch_agg_field/threshold_watch_agg_field.js index 6448027aa99987..756ca66f47fcd8 100644 --- a/x-pack/plugins/watcher/public/components/threshold_watch_expression/components/threshold_watch_agg_field/threshold_watch_agg_field.js +++ b/x-pack/plugins/watcher/public/components/threshold_watch_expression/components/threshold_watch_agg_field/threshold_watch_agg_field.js @@ -12,7 +12,7 @@ import 'plugins/watcher/components/xpack_aria_describes'; const app = uiModules.get('xpack/watcher'); -app.directive('thresholdWatchAggField', function ($injector) { +app.directive('thresholdWatchAggField', function ($injector, i18n) { const htmlIdGeneratorFactory = $injector.get('xpackWatcherHtmlIdGeneratorFactory'); return { @@ -51,11 +51,16 @@ app.directive('thresholdWatchAggField', function ($injector) { } }); - this.itemDescription = 'Of'; + this.itemDescription = i18n('xpack.watcher.thresholdWatchExpression.aggField.itemDescription', { + defaultMessage: 'Of', + }); } get itemValue() { - return this.aggField ? this.aggField.name : 'select a field'; + return this.aggField ? this.aggField.name : i18n( + 'xpack.watcher.thresholdWatchExpression.aggField.selectFieldTextMessage', { + defaultMessage: 'select a field', + }); } } }; diff --git a/x-pack/plugins/watcher/public/components/threshold_watch_expression/components/threshold_watch_agg_type/threshold_watch_agg_type.html b/x-pack/plugins/watcher/public/components/threshold_watch_expression/components/threshold_watch_agg_type/threshold_watch_agg_type.html index c41c4314f27041..981fcf12aa131c 100644 --- a/x-pack/plugins/watcher/public/components/threshold_watch_expression/components/threshold_watch_agg_type/threshold_watch_agg_type.html +++ b/x-pack/plugins/watcher/public/components/threshold_watch_expression/components/threshold_watch_agg_type/threshold_watch_agg_type.html @@ -16,9 +16,9 @@ xpack-aria-describes="{{thresholdWatchAggType.makeId('aggType')}}" class="kuiInputNote kuiInputNote--danger" ng-if="thresholdWatchAggType.isValidationMessageVisible('aggType', 'required')" - > - Please select an aggregation type. - + i18n-id="xpack.watcher.thresholdWatchExpression.aggType.requiredTypeValidationMessage" + i18n-default-message="Please select an aggregation type." + > - + diff --git a/x-pack/plugins/watcher/public/components/threshold_watch_expression/components/threshold_watch_group_by/threshold_watch_group_by.js b/x-pack/plugins/watcher/public/components/threshold_watch_expression/components/threshold_watch_group_by/threshold_watch_group_by.js index 29048c1fe92849..e89a23070dd269 100644 --- a/x-pack/plugins/watcher/public/components/threshold_watch_expression/components/threshold_watch_group_by/threshold_watch_group_by.js +++ b/x-pack/plugins/watcher/public/components/threshold_watch_expression/components/threshold_watch_group_by/threshold_watch_group_by.js @@ -12,7 +12,7 @@ import 'plugins/watcher/components/xpack_aria_describes'; const app = uiModules.get('xpack/watcher'); -app.directive('thresholdWatchGroupBy', function ($injector) { +app.directive('thresholdWatchGroupBy', function ($injector, i18n) { const htmlIdGeneratorFactory = $injector.get('xpackWatcherHtmlIdGeneratorFactory'); return { @@ -57,7 +57,15 @@ app.directive('thresholdWatchGroupBy', function ($injector) { } get itemDescription() { - return (this.groupByType && this.groupByType.sizeRequired) ? 'Grouped over' : 'Over'; + const itemDescription = (this.groupByType && this.groupByType.sizeRequired) + ? i18n('xpack.watcher.thresholdWatchExpression.groupBy.groupedItemDescription', { + defaultMessage: 'Grouped over', + }) + : i18n('xpack.watcher.thresholdWatchExpression.groupBy.itemDescription', { + defaultMessage: 'Over', + }); + + return itemDescription; } get itemValue() { diff --git a/x-pack/plugins/watcher/public/components/threshold_watch_expression/components/threshold_watch_threshold_level/threshold_watch_threshold_level.html b/x-pack/plugins/watcher/public/components/threshold_watch_expression/components/threshold_watch_threshold_level/threshold_watch_threshold_level.html index 51aa630e6736d2..76be0699679e0e 100644 --- a/x-pack/plugins/watcher/public/components/threshold_watch_expression/components/threshold_watch_threshold_level/threshold_watch_threshold_level.html +++ b/x-pack/plugins/watcher/public/components/threshold_watch_expression/components/threshold_watch_threshold_level/threshold_watch_threshold_level.html @@ -16,17 +16,17 @@ xpack-aria-describes="{{thresholdWatchThresholdLevel.makeId('threshold')}}" class="kuiInputNote kuiInputNote--danger" ng-if="thresholdWatchThresholdLevel.isValidationMessageVisible('threshold', 'required')" - > - A value is required. - + i18n-id="xpack.watcher.thresholdWatchExpression.thresholdLevel.valueIsRequiredValidationMessage" + i18n-default-message="A value is required." + >
- Value must be a valid number. -
+ i18n-id="xpack.watcher.thresholdWatchExpression.thresholdLevel.valueMustBeValidNumberValidationMessage" + i18n-default-message="Value must be a valid number." + > - To e-mail address is required. - + i18n-id="xpack.watcher.watchActions.email.emailAddressIsRequiredValidationMessage" + i18n-default-message="To e-mail address is required." + >
+ i18n-id="xpack.watcher.watchActions.email.subjectLabel" + i18n-default-message="Subject" + > - Subject is required. -
+ i18n-id="xpack.watcher.watchActions.email.subjectIsRequiredValidationMessage" + i18n-default-message="Subject is required." + >
+ i18n-id="xpack.watcher.watchActions.email.bodyLabel" + i18n-default-message="Body" + >