Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[CCR] Copy edits #29676

Merged
merged 22 commits into from
Feb 2, 2019
Merged
Show file tree
Hide file tree
Changes from 10 commits
Commits
Show all changes
22 commits
Select commit Hold shift + click to select a range
21b38b8
Use 'Resume/pause data replication' in context menu and row actions.
cjcenizal Jan 30, 2019
f95b77f
Update copy of 'Update' confirm modal for a paused follower index.
cjcenizal Jan 31, 2019
b544ab9
Update copy of 'Update' confirm modal for an active follower index.
cjcenizal Jan 31, 2019
ee721ca
Update copy of 'Pause data replication' confirm modal.
cjcenizal Jan 31, 2019
0beee6c
Update copy of 'Resume data replication' confirm modal.
cjcenizal Jan 31, 2019
2403120
Update copy for permissions check.
cjcenizal Jan 31, 2019
120e1a3
Update copy of table empty state.
cjcenizal Jan 31, 2019
bf405b1
Update copy around tables.
cjcenizal Jan 31, 2019
950bf23
Update form copy.
cjcenizal Jan 31, 2019
0eba66d
Update copy for RemoteClustersFormField callouts.
cjcenizal Jan 31, 2019
aaa62b0
Convert 'data replication' -> 'replication'.
cjcenizal Jan 31, 2019
571a84d
Update copy for Unfollow confirm modal.
cjcenizal Jan 31, 2019
976e521
Update copy for form API error and Auto-follow Patterns table.
cjcenizal Jan 31, 2019
eea6e2f
Update form save button labels to be 'Create' and 'Update'.
cjcenizal Jan 31, 2019
aada6bc
Move API errors to bottom of form, into same posiion as sync validati…
cjcenizal Jan 31, 2019
ed5bf46
Fix i18n error.
cjcenizal Jan 31, 2019
4bbc5d3
Update copy with feedback from Gail.
cjcenizal Jan 31, 2019
f136ebf
Fix bug with remoteClusterNotConnectedEditable throwing an error.
cjcenizal Feb 1, 2019
a5921d6
Rephrase 'replication of leader index' -> 'replication to leader index'.
cjcenizal Feb 1, 2019
f183122
Tweak leader index description to reinforce relationship with remote …
cjcenizal Feb 1, 2019
3de1955
Tweak leader index description to clarify role of leader index and fo…
cjcenizal Feb 1, 2019
d86fcd0
Merge branch 'feature/ccr' into ccr/copy-edits
cjcenizal Feb 1, 2019
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion src/ui/public/indices/constants/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -19,4 +19,9 @@

import { INDEX_PATTERN_ILLEGAL_CHARACTERS_VISIBLE } from 'ui/index_patterns';

export const INDEX_ILLEGAL_CHARACTERS_VISIBLE = INDEX_PATTERN_ILLEGAL_CHARACTERS_VISIBLE.concat(',');
export const INDEX_ILLEGAL_CHARACTERS_VISIBLE = [ ...INDEX_PATTERN_ILLEGAL_CHARACTERS_VISIBLE ];

// Insert the comma into the middle, so it doesn't look as if it has grammatical meaning when
// these characters are rendered in the UI.
const insertionIndex = Math.floor(INDEX_PATTERN_ILLEGAL_CHARACTERS_VISIBLE.length / 2);
INDEX_ILLEGAL_CHARACTERS_VISIBLE.splice(insertionIndex, 0, ',');
5 changes: 3 additions & 2 deletions x-pack/plugins/cross_cluster_replication/public/app/app.js
Original file line number Diff line number Diff line change
Expand Up @@ -182,14 +182,15 @@ export const App = injectI18n(
<h2>
<FormattedMessage
id="xpack.crossClusterReplication.app.deniedPermissionTitle"
defaultMessage="Permission denied"
defaultMessage="You're missing cluster privileges"
/>
</h2>}
body={
<p>
<FormattedMessage
id="xpack.crossClusterReplication.app.deniedPermissionDescription"
defaultMessage="You do not have required cluster privileges ({clusterPrivileges}) for Cross Cluster Replication."
defaultMessage="To use Cross Cluster Replication, you must have {clusterPrivileges,
plural, one {this cluster privilege} other {these cluster privileges}}: {clusterPrivileges}."
values={{ clusterPrivileges: missingClusterPrivileges.join(', ') }}
/>
</p>}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -301,13 +301,13 @@ export class AutoFollowPatternFormUI extends PureComponent {
/>),
remoteClusterNotConnectedNotEditable: () => (<FormattedMessage
id="xpack.crossClusterReplication.autoFollowPatternForm.currentRemoteClusterNotConnectedCallOutDescription"
defaultMessage="You need to connect it before editing this auto-follow pattern. Edit the remote cluster to
fix the problem."
defaultMessage="The remote cluster must be connected to edit this auto-follow pattern."
/>),
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can't edit auto-follow pattern because remote cluster 'test' is not connected.

You can address this by editing the remote cluster.

Edit remote cluster

remoteClusterDoesNotExist: () => (<FormattedMessage
remoteClusterDoesNotExist: (name) => (<FormattedMessage
id="xpack.crossClusterReplication.autoFollowPatternForm.currentRemoteClusterNotFoundCallOutDescription"
defaultMessage="It might have been removed. In order to edit this auto-follow pattern,
you need to add a remote cluster with the same name."
defaultMessage="Before you can edit this auto-follow pattern, you must add a remote cluster
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

To edit this

named '{name}'."
values={{ name }}
/>)
};

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ const byteUnitsHelpText = (
<a href={byteUnitsUrl} target="_blank">
<FormattedMessage
id="xpack.crossClusterReplication.followerIndexForm.advancedSettings.byteUnitsHelpTextLinkMessage"
defaultMessage="Learn more."
defaultMessage="Learn more"
/>
</a>
) }}
Expand All @@ -33,7 +33,7 @@ const timeUnitsHelpText = (
<a href={timeUnitsUrl} target="_blank">
<FormattedMessage
id="xpack.crossClusterReplication.followerIndexForm.advancedSettings.timeUnitsHelpTextLinkMessage"
defaultMessage="Learn more."
defaultMessage="Learn more"
/>
</a>
) }}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -343,7 +343,7 @@ export const FollowerIndexForm = injectI18n(

const indexNameLabel = i18n.translate(
'xpack.crossClusterReplication.followerIndexForm.sectionFollowerIndexNameTitle', {
defaultMessage: 'Name'
defaultMessage: 'Follower index'
}
);

Expand All @@ -359,7 +359,7 @@ export const FollowerIndexForm = injectI18n(
)}
label={indexNameLabel}
description={i18n.translate('xpack.crossClusterReplication.followerIndexForm.sectionFollowerIndexNameDescription', {
defaultMessage: 'A name for the follower index.'
defaultMessage: 'A unique name for your index.'
})}
helpText={indexNameHelpText}
isLoading={isValidatingIndexName}
Expand All @@ -382,13 +382,13 @@ export const FollowerIndexForm = injectI18n(
/>),
remoteClusterNotConnectedNotEditable: () => (<FormattedMessage
id="xpack.crossClusterReplication.followerIndexForm.currentRemoteClusterNotConnectedCallOutDescription"
defaultMessage="You need to connect it before editing this follower index. Edit the remote cluster to
fix the problem."
defaultMessage="The remote cluster must be connected to edit this follower index."
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can't edit follower index because remote cluster 'text' is not connected.

You can address this by editing the remote cluster.

Edit remote cluster

/>),
remoteClusterDoesNotExist: () => (<FormattedMessage
remoteClusterDoesNotExist: (name) => (<FormattedMessage
id="xpack.crossClusterReplication.followerIndexForm.currentRemoteClusterNotFoundCallOutDescription"
defaultMessage="It might have been removed. In order to edit this follower index,
you need to add a remote cluster with the same name."
defaultMessage="Before you can edit this follower index, you must add a remote cluster
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

To edit this

named '{name}'."
values={{ name }}
/>)
};

Expand All @@ -407,7 +407,7 @@ export const FollowerIndexForm = injectI18n(
description={(
<FormattedMessage
id="xpack.crossClusterReplication.followerIndexForm.sectionRemoteClusterDescription"
defaultMessage="The remote cluster to replicate your leader index from."
defaultMessage="The cluster that contains the index to replicate."
/>
)}
fullWidth
Expand Down Expand Up @@ -449,9 +449,31 @@ export const FollowerIndexForm = injectI18n(
</EuiTitle>
)}
label={leaderIndexLabel}
description={i18n.translate('xpack.crossClusterReplication.followerIndexForm.sectionLeaderIndexDescription', {
defaultMessage: 'The leader index you want to replicate from the remote cluster.'
})}
description={(
<Fragment>
<p>
<FormattedMessage
id="xpack.crossClusterReplication.followerIndexForm.sectionLeaderIndexDescription"
defaultMessage="The index you want to replicate."
/>
</p>

<p>
<FormattedMessage
id="xpack.crossClusterReplication.followerIndexForm.sectionLeaderIndexDescription2"
defaultMessage="{note} the leader index must already exist."
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Capitalize The

values={{ note: (
<strong>
<FormattedMessage
id="xpack.crossClusterReplication.followerIndexForm.sectionLeaderIndexDescription2.noteLabel"
defaultMessage="Note:"
/>
</strong>
) }}
/>
</p>
</Fragment>
)}
helpText={(
<FormattedMessage
id="xpack.crossClusterReplication.followerIndexForm.indexNameHelpLabel"
Expand Down Expand Up @@ -489,8 +511,7 @@ export const FollowerIndexForm = injectI18n(
<p>
<FormattedMessage
id="xpack.crossClusterReplication.followerIndexForm.advancedSettingsDescription"
defaultMessage="Customize advanced settings to control the rate at which data is replicated.
If you don't customize them, default advanced settings will be applied."
defaultMessage="Advanced settings control the rate at which data is replicated.."
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remove second period.

Advanced settings control the rate of replication.

/>
</p>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -56,11 +56,11 @@ class Provider extends PureComponent {
const title = isSingle
? intl.formatMessage({
id: 'xpack.crossClusterReplication.pauseFollowerIndex.confirmModal.pauseSingleTitle',
defaultMessage: 'Pause follower index \'{name}\'?',
defaultMessage: 'Pause data replication of follower index \'{name}\'?',

This comment was marked as resolved.

This comment was marked as resolved.

}, { name: indices[0].name })
: intl.formatMessage({
id: 'xpack.crossClusterReplication.pauseFollowerIndex.confirmModal.pauseMultipleTitle',
defaultMessage: 'Pause {count} follower indices?',
defaultMessage: 'Pause data replication of {count} follower indices?',
}, { count: indices.length });
const hasCustomSettings = indices.some(index => !areAllSettingsDefault(index));

Expand All @@ -78,50 +78,42 @@ class Provider extends PureComponent {
})
}
buttonColor={hasCustomSettings ? 'danger' : 'primary'}
confirmButtonText={
hasCustomSettings ? intl.formatMessage({
id: 'xpack.crossClusterReplication.pauseFollowerIndex.confirmModal.confirmButtonTextWithSettingWarning',
defaultMessage: 'Pause and revert advanced settings to defaults',
}) : intl.formatMessage({
id: 'xpack.crossClusterReplication.pauseFollowerIndex.confirmModal.confirmButtonText',
defaultMessage: 'Pause',
})
}
confirmButtonText={intl.formatMessage({
id: 'xpack.crossClusterReplication.pauseFollowerIndex.confirmModal.confirmButtonText',
defaultMessage: 'Pause data replication',
})}
onMouseOver={this.onMouseOverModal}
>
{isSingle ? (
<Fragment>
{
hasCustomSettings ? (
<p>
<FormattedMessage
id="xpack.crossClusterReplication.pauseFollowerIndex.confirmModal.singlePauseDescriptionWithSettingWarning"
defaultMessage="The custom advanced settings on this follower index will be reverted to default
advanced settings."
/>
</p>
) : null
}
</Fragment>
) : (
{hasCustomSettings && (
<p>
{isSingle ? (
<FormattedMessage
id="xpack.crossClusterReplication.pauseFollowerIndex.confirmModal.singlePauseDescriptionWithSettingWarning"
defaultMessage="Pausing data replication of this follower index clears its custom
advanced settings."
/>
) : (
<FormattedMessage
id="xpack.crossClusterReplication.pauseFollowerIndex.confirmModal.multiplePauseDescriptionWithSettingWarning"
defaultMessage="Pausing data replication of a follower index clears its custom
advanced settings."
/>
)}
</p>
)}

{!isSingle && (
<Fragment>
<p>
{
hasCustomSettings ? (
<FormattedMessage
id="xpack.crossClusterReplication.pauseFollowerIndex.confirmModal.multiplePauseDescriptionWithSettingWarning"
defaultMessage="The follower indices below will be paused. Custom advanced settings on one or more
of these follower indices will be reverted to default advanced settings."
/>
) : (
<FormattedMessage
id="xpack.crossClusterReplication.pauseFollowerIndex.confirmModal.multiplePauseDescription"
defaultMessage="These follower indices will be paused:"
/>
)
}
<FormattedMessage
id="xpack.crossClusterReplication.pauseFollowerIndex.confirmModal.multiplePauseDescription"
defaultMessage="These follower indices will pause data replication:"
/>
</p>
<ul>{indices.map(index => <li key={index.name}>{index.name}</li>)}</ul>

<ul>
{indices.map(index => <li key={index.name}>{index.name}</li>)}
</ul>
</Fragment>
)}
</EuiConfirmModal>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -57,11 +57,11 @@ class Provider extends PureComponent {
const title = isSingle
? intl.formatMessage({
id: 'xpack.crossClusterReplication.resumeFollowerIndex.confirmModal.resumeSingleTitle',
defaultMessage: 'Resume follower index \'{name}\'?',
defaultMessage: 'Resume data replication of follower index \'{name}\'?',
}, { name: ids[0] })
: intl.formatMessage({
id: 'xpack.crossClusterReplication.resumeFollowerIndex.confirmModal.resumeMultipleTitle',
defaultMessage: 'Resume {count} follower indices?',
defaultMessage: 'Resume data replication of {count} follower indices?',
}, { count: ids.length });

return (
Expand All @@ -81,7 +81,7 @@ class Provider extends PureComponent {
confirmButtonText={
intl.formatMessage({
id: 'xpack.crossClusterReplication.resumeFollowerIndex.confirmModal.confirmButtonText',
defaultMessage: 'Resume using default advanced settings',
defaultMessage: 'Resume data replication',
})
}
onMouseOver={this.onMouseOverModal}
Expand All @@ -90,14 +90,14 @@ class Provider extends PureComponent {
<p>
<FormattedMessage
id="xpack.crossClusterReplication.resumeFollowerIndex.confirmModal.singleResumeDescription"
defaultMessage="This follower index will be resumed using default advanced settings.
To resume using custom advanced settings, {editLink}."
defaultMessage="Data replication resumes using the default advanced settings. To use
custom advanced settings, {editLink}."
values={{
editLink: (
<EuiLink href={routing.getFollowerIndexPath(ids[0])}>
<FormattedMessage
id="xpack.crossClusterReplication.resumeFollowerIndex.confirmModal.singleResumeEditLink"
defaultMessage="edit this follower index instead"
defaultMessage="edit the follower index"
/>
</EuiLink>
),
Expand All @@ -106,14 +106,23 @@ class Provider extends PureComponent {
</p>
) : (
<Fragment>
<p>
<FormattedMessage
id="xpack.crossClusterReplication.resumeFollowerIndex.confirmModal.multipleResumeDescriptionWithSettingWarning"
defaultMessage="Data replication resumes using the default advanced settings."
/>
</p>

<p>
<FormattedMessage
id="xpack.crossClusterReplication.resumeFollowerIndex.confirmModal.multipleResumeDescription"
defaultMessage="The follower indices below will be resumed using default advanced settings.
To resume using custom advanced settings, edit each follower index instead."
defaultMessage="These follower indices will resume data replication:"
/>
</p>
<ul>{ids.map(id => <li key={id}>{id}</li>)}</ul>

<ul>
{ids.map(id => <li key={id}>{id}</li>)}
</ul>
</Fragment>
)}
</EuiConfirmModal>
Expand Down
Loading