From fef0051b509f990629b50feae326073a09ea3af8 Mon Sep 17 00:00:00 2001 From: Larry Gregory Date: Mon, 10 Dec 2018 14:35:22 -0500 Subject: [PATCH 1/3] copy tweaks --- .../management/edit_space/manage_space_page.tsx | 4 ++-- .../views/management/lib/validate_space.test.ts | 12 ++++++------ .../public/views/management/lib/validate_space.ts | 10 +++++----- .../__snapshots__/spaces_grid_pages.test.tsx.snap | 2 +- .../management/spaces_grid/spaces_grid_page.tsx | 2 +- 5 files changed, 15 insertions(+), 15 deletions(-) diff --git a/x-pack/plugins/spaces/public/views/management/edit_space/manage_space_page.tsx b/x-pack/plugins/spaces/public/views/management/edit_space/manage_space_page.tsx index 59d1eefe6fce5..55beed9d05f86 100644 --- a/x-pack/plugins/spaces/public/views/management/edit_space/manage_space_page.tsx +++ b/x-pack/plugins/spaces/public/views/management/edit_space/manage_space_page.tsx @@ -213,7 +213,7 @@ class ManageSpacePageUI extends Component { name="description" placeholder={intl.formatMessage({ id: 'xpack.spaces.management.manageSpacePage.hereMagicHappensPlaceholder', - defaultMessage: 'This is where the magic happens', + defaultMessage: 'This is where the magic happens.', })} value={description} onChange={this.onDescriptionChange} @@ -250,7 +250,7 @@ class ManageSpacePageUI extends Component { return ( ); }; diff --git a/x-pack/plugins/spaces/public/views/management/lib/validate_space.test.ts b/x-pack/plugins/spaces/public/views/management/lib/validate_space.test.ts index 04d81a9479498..fbf11c87f8df0 100644 --- a/x-pack/plugins/spaces/public/views/management/lib/validate_space.test.ts +++ b/x-pack/plugins/spaces/public/views/management/lib/validate_space.test.ts @@ -30,7 +30,7 @@ describe('validateSpaceName', () => { expect(validator.validateSpaceName(space)).toEqual({ isInvalid: true, - error: `Name is required`, + error: `Name is required.`, }); }); @@ -42,7 +42,7 @@ describe('validateSpaceName', () => { expect(validator.validateSpaceName(space)).toEqual({ isInvalid: true, - error: `Name is required`, + error: `Name is required.`, }); }); @@ -54,7 +54,7 @@ describe('validateSpaceName', () => { expect(validator.validateSpaceName(space)).toEqual({ isInvalid: true, - error: `Name must not exceed 1024 characters`, + error: `Name must not exceed 1024 characters.`, }); }); }); @@ -78,7 +78,7 @@ describe('validateSpaceDescription', () => { expect(validator.validateSpaceDescription(space)).toEqual({ isInvalid: true, - error: `Description must not exceed 2000 characters`, + error: `Description must not exceed 2000 characters.`, }); }); }); @@ -102,7 +102,7 @@ describe('validateURLIdentifier', () => { expect(validator.validateURLIdentifier(space)).toEqual({ isInvalid: true, - error: `URL identifier is required`, + error: `URL identifier is required.`, }); }); @@ -114,7 +114,7 @@ describe('validateURLIdentifier', () => { expect(validator.validateURLIdentifier(space)).toEqual({ isInvalid: true, - error: 'URL identifier can only contain a-z, 0-9, and the characters "_" and "-"', + error: 'URL identifier can only contain a-z, 0-9, and the characters "_" and "-".', }); }); diff --git a/x-pack/plugins/spaces/public/views/management/lib/validate_space.ts b/x-pack/plugins/spaces/public/views/management/lib/validate_space.ts index cc935ce653b58..a40c0bf6efb40 100644 --- a/x-pack/plugins/spaces/public/views/management/lib/validate_space.ts +++ b/x-pack/plugins/spaces/public/views/management/lib/validate_space.ts @@ -35,7 +35,7 @@ export class SpaceValidator { if (!space.name || !space.name.trim()) { return invalid( i18n.translate('xpack.spaces.management.validateSpace.requiredNameErrorMessage', { - defaultMessage: 'Name is required', + defaultMessage: 'Name is required.', }) ); } @@ -43,7 +43,7 @@ export class SpaceValidator { if (space.name.length > 1024) { return invalid( i18n.translate('xpack.spaces.management.validateSpace.nameMaxLengthErrorMessage', { - defaultMessage: 'Name must not exceed 1024 characters', + defaultMessage: 'Name must not exceed 1024 characters.', }) ); } @@ -59,7 +59,7 @@ export class SpaceValidator { if (space.description && space.description.length > 2000) { return invalid( i18n.translate('xpack.spaces.management.validateSpace.describeMaxLengthErrorMessage', { - defaultMessage: 'Description must not exceed 2000 characters', + defaultMessage: 'Description must not exceed 2000 characters.', }) ); } @@ -79,7 +79,7 @@ export class SpaceValidator { if (!space.id) { return invalid( i18n.translate('xpack.spaces.management.validateSpace.urlIdentifierRequiredErrorMessage', { - defaultMessage: 'URL identifier is required', + defaultMessage: 'URL identifier is required.', }) ); } @@ -90,7 +90,7 @@ export class SpaceValidator { 'xpack.spaces.management.validateSpace.urlIdentifierAllowedCharactersErrorMessage', { defaultMessage: - 'URL identifier can only contain a-z, 0-9, and the characters "_" and "-"', + 'URL identifier can only contain a-z, 0-9, and the characters "_" and "-".', } ) ); diff --git a/x-pack/plugins/spaces/public/views/management/spaces_grid/__snapshots__/spaces_grid_pages.test.tsx.snap b/x-pack/plugins/spaces/public/views/management/spaces_grid/__snapshots__/spaces_grid_pages.test.tsx.snap index bebda86fa9721..7cce15ce0643f 100644 --- a/x-pack/plugins/spaces/public/views/management/spaces_grid/__snapshots__/spaces_grid_pages.test.tsx.snap +++ b/x-pack/plugins/spaces/public/views/management/spaces_grid/__snapshots__/spaces_grid_pages.test.tsx.snap @@ -51,7 +51,7 @@ exports[`SpacesGridPage renders as expected 1`] = ` type="button" > diff --git a/x-pack/plugins/spaces/public/views/management/spaces_grid/spaces_grid_page.tsx b/x-pack/plugins/spaces/public/views/management/spaces_grid/spaces_grid_page.tsx index 6a840680104aa..117cc538da6fd 100644 --- a/x-pack/plugins/spaces/public/views/management/spaces_grid/spaces_grid_page.tsx +++ b/x-pack/plugins/spaces/public/views/management/spaces_grid/spaces_grid_page.tsx @@ -139,7 +139,7 @@ class SpacesGridPageUI extends Component { > ); From b691300d2e30aa2b4e259d8a1efcdb4f255e0fba Mon Sep 17 00:00:00 2001 From: Larry Gregory Date: Mon, 10 Dec 2018 14:58:34 -0500 Subject: [PATCH 2/3] update save space toast --- .../public/views/management/edit_space/manage_space_page.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/x-pack/plugins/spaces/public/views/management/edit_space/manage_space_page.tsx b/x-pack/plugins/spaces/public/views/management/edit_space/manage_space_page.tsx index 55beed9d05f86..283c58a6faf36 100644 --- a/x-pack/plugins/spaces/public/views/management/edit_space/manage_space_page.tsx +++ b/x-pack/plugins/spaces/public/views/management/edit_space/manage_space_page.tsx @@ -406,7 +406,7 @@ class ManageSpacePageUI extends Component { { id: 'xpack.spaces.management.manageSpacePage.spaceSuccessfullySavedNotificationMessage', - defaultMessage: '{name} was saved', + defaultMessage: '{name} space was saved', }, { name: `'${name}'`, From 4adc21446f6aea6afbd47e63a1583d3e92d9c985 Mon Sep 17 00:00:00 2001 From: Larry Gregory Date: Mon, 10 Dec 2018 16:46:32 -0500 Subject: [PATCH 3/3] adjust save toast --- .../public/views/management/edit_space/manage_space_page.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/x-pack/plugins/spaces/public/views/management/edit_space/manage_space_page.tsx b/x-pack/plugins/spaces/public/views/management/edit_space/manage_space_page.tsx index 283c58a6faf36..949f37f9fc8d0 100644 --- a/x-pack/plugins/spaces/public/views/management/edit_space/manage_space_page.tsx +++ b/x-pack/plugins/spaces/public/views/management/edit_space/manage_space_page.tsx @@ -406,7 +406,7 @@ class ManageSpacePageUI extends Component { { id: 'xpack.spaces.management.manageSpacePage.spaceSuccessfullySavedNotificationMessage', - defaultMessage: '{name} space was saved', + defaultMessage: `Space {name} was saved.`, }, { name: `'${name}'`,