Index pattern field editor - copy improvements (#96269)

* copy update

* remove stray colon from copy
This commit is contained in:
Matthew Kime 2021-04-06 10:36:24 -05:00 committed by GitHub
parent b066e9714d
commit 70b3b2bbc1
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 15 additions and 6 deletions

View file

@ -64,14 +64,14 @@ const geti18nTexts = (fieldsToDelete?: string[]) => {
typeConfirm: i18n.translate(
'indexPatternFieldEditor.deleteRuntimeField.confirmModal.typeConfirm',
{
defaultMessage: "Type 'REMOVE' to confirm",
defaultMessage: 'Enter REMOVE to confirm',
}
),
warningRemovingFields: i18n.translate(
'indexPatternFieldEditor.deleteRuntimeField.confirmModal.warningRemovingFields',
{
defaultMessage:
'Warning: Removing fields may break searches or visualizations that rely on this field.',
'Removing fields can break searches and visualizations that rely on this field.',
}
),
};

View file

@ -53,20 +53,29 @@ const geti18nTexts = (field?: Field) => {
confirmButtonText: i18n.translate(
'indexPatternFieldEditor.deleteRuntimeField.confirmationModal.saveButtonLabel',
{
defaultMessage: 'Save',
defaultMessage: 'Save changes',
}
),
warningChangingFields: i18n.translate(
'indexPatternFieldEditor.deleteRuntimeField.confirmModal.warningChangingFields',
{
defaultMessage:
'Warning: Changing name or type may break searches or visualizations that rely on this field.',
'Changing name or type can break searches and visualizations that rely on this field.',
}
),
typeConfirm: i18n.translate(
'indexPatternFieldEditor.saveRuntimeField.confirmModal.typeConfirm',
{
defaultMessage: "Type 'CHANGE' to continue:",
defaultMessage: 'Enter CHANGE to continue',
}
),
titleConfirmChanges: i18n.translate(
'indexPatternFieldEditor.saveRuntimeField.confirmModal.title',
{
defaultMessage: `Save changes to '{name}'`,
values: {
name: field?.name,
},
}
),
};
@ -211,7 +220,7 @@ const FieldEditorFlyoutContentComponent = ({
const modal = isModalVisible ? (
<EuiConfirmModal
title={`Confirm changes to '${field?.name}'`}
title={i18nTexts.titleConfirmChanges}
data-test-subj="runtimeFieldSaveConfirmModal"
cancelButtonText={i18nTexts.cancelButtonText}
confirmButtonText={i18nTexts.confirmButtonText}