Skip to content

Commit

Permalink
Copy: use sentence case for all texts in tooltips (#8927)
Browse files Browse the repository at this point in the history
* Copy: use sentence case for all texts in tooltips

* Remove 'Publish' since it's redundant

* Update strings in tests so they pass
  • Loading branch information
eliorivero authored and talldan committed Aug 22, 2018
1 parent abac58c commit 6b2e673
Show file tree
Hide file tree
Showing 6 changed files with 32 additions and 32 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ export class BlockSettingsMenu extends Component {
'is-opened': isOpen,
'is-visible': isFocused || isOpen || ! isHidden,
} );
const label = isOpen ? __( 'Hide Options' ) : __( 'More Options' );
const label = isOpen ? __( 'Hide options' ) : __( 'More options' );

return (
<IconButton
Expand Down
2 changes: 1 addition & 1 deletion packages/editor/src/components/post-publish-panel/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ class PostPublishPanel extends Component {
aria-expanded={ true }
onClick={ onClose }
icon="no-alt"
label={ __( 'Close Publish Panel' ) }
label={ __( 'Close panel' ) }
/>
</div>
<div className="editor-post-publish-panel__content">
Expand Down
2 changes: 1 addition & 1 deletion packages/editor/src/components/table-of-contents/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ function TableOfContents( { hasBlocks } ) {
onClick={ onToggle }
icon="info-outline"
aria-expanded={ isOpen }
label={ __( 'Content Structure' ) }
label={ __( 'Content structure' ) }
disabled={ ! hasBlocks }
/>
) }
Expand Down
30 changes: 15 additions & 15 deletions packages/editor/src/store/defaults.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,82 +21,82 @@ export const EDITOR_SETTINGS_DEFAULTS = {
alignWide: false,
colors: [
{
name: __( 'pale pink' ),
name: __( 'Pale pink' ),
slug: 'pale-pink',
color: '#f78da7',
},
{ name: __( 'vivid red' ),
{ name: __( 'Vivid red' ),
slug: 'vivid-red',
color: '#cf2e2e',
},
{
name: __( 'luminous vivid orange' ),
name: __( 'Luminous vivid orange' ),
slug: 'luminous-vivid-orange',
color: '#ff6900',
},
{
name: __( 'luminous vivid amber' ),
name: __( 'Luminous vivid amber' ),
slug: 'luminous-vivid-amber',
color: '#fcb900',
},
{
name: __( 'light green cyan' ),
name: __( 'Light green cyan' ),
slug: 'light-green-cyan',
color: '#7bdcb5',
},
{
name: __( 'vivid green cyan' ),
name: __( 'Vivid green cyan' ),
slug: 'vivid-green-cyan',
color: '#00d084',
},
{
name: __( 'pale cyan blue' ),
name: __( 'Pale cyan blue' ),
slug: 'pale-cyan-blue',
color: '#8ed1fc',
},
{
name: __( 'vivid cyan blue' ),
name: __( 'Vivid cyan blue' ),
slug: 'vivid-cyan-blue',
color: '#0693e3',
},
{
name: __( 'very light gray' ),
name: __( 'Very light gray' ),
slug: 'very-light-gray',
color: '#eeeeee',
},
{
name: __( 'cyan bluish gray' ),
name: __( 'Cyan bluish gray' ),
slug: 'cyan-bluish-gray',
color: '#abb8c3',
},
{
name: __( 'very dark gray' ),
name: __( 'Very dark gray' ),
slug: 'very-dark-gray',
color: '#313131',
},
],

fontSizes: [
{
name: __( 'small' ),
name: __( 'Small' ),
shortName: __( 'S' ),
size: 14,
slug: 'small',
},
{
name: __( 'regular' ),
name: __( 'Regular' ),
shortName: __( 'M' ),
size: 16,
slug: 'regular',
},
{
name: __( 'large' ),
name: __( 'Large' ),
shortName: __( 'L' ),
size: 36,
slug: 'large',
},
{
name: __( 'larger' ),
name: __( 'Larger' ),
shortName: __( 'XL' ),
size: 48,
slug: 'larger',
Expand Down
16 changes: 8 additions & 8 deletions test/e2e/specs/editor-modes.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,8 @@ describe( 'Editing modes (visual/HTML)', () => {
expect( visualBlock ).toHaveLength( 1 );

// Change editing mode from "Visual" to "HTML".
await page.waitForSelector( 'button[aria-label="More Options"]' );
await page.click( 'button[aria-label="More Options"]' );
await page.waitForSelector( 'button[aria-label="More options"]' );
await page.click( 'button[aria-label="More options"]' );
let changeModeButton = await page.waitForXPath( '//button[text()="Edit as HTML"]' );
await changeModeButton.click();

Expand All @@ -26,8 +26,8 @@ describe( 'Editing modes (visual/HTML)', () => {
expect( htmlBlock ).toHaveLength( 1 );

// Change editing mode from "HTML" back to "Visual".
await page.waitForSelector( 'button[aria-label="More Options"]' );
await page.click( 'button[aria-label="More Options"]' );
await page.waitForSelector( 'button[aria-label="More options"]' );
await page.click( 'button[aria-label="More options"]' );
changeModeButton = await page.waitForXPath( '//button[text()="Edit visually"]' );
await changeModeButton.click();

Expand All @@ -38,8 +38,8 @@ describe( 'Editing modes (visual/HTML)', () => {

it( 'should display sidebar in HTML mode', async () => {
// Change editing mode from "Visual" to "HTML".
await page.waitForSelector( 'button[aria-label="More Options"]' );
await page.click( 'button[aria-label="More Options"]' );
await page.waitForSelector( 'button[aria-label="More options"]' );
await page.click( 'button[aria-label="More options"]' );
const changeModeButton = await page.waitForXPath( '//button[text()="Edit as HTML"]' );
await changeModeButton.click();

Expand All @@ -51,8 +51,8 @@ describe( 'Editing modes (visual/HTML)', () => {

it( 'should update HTML in HTML mode when sidebar is used', async () => {
// Change editing mode from "Visual" to "HTML".
await page.waitForSelector( 'button[aria-label="More Options"]' );
await page.click( 'button[aria-label="More Options"]' );
await page.waitForSelector( 'button[aria-label="More options"]' );
await page.click( 'button[aria-label="More options"]' );
const changeModeButton = await page.waitForXPath( '//button[text()="Edit as HTML"]' );
await changeModeButton.click();

Expand Down
12 changes: 6 additions & 6 deletions test/e2e/specs/reusable-blocks.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -38,8 +38,8 @@ describe( 'Reusable Blocks', () => {
await page.mouse.move( 250, 350, { steps: 10 } );

// Convert block to a reusable block
await page.waitForSelector( 'button[aria-label="More Options"]' );
await page.click( 'button[aria-label="More Options"]' );
await page.waitForSelector( 'button[aria-label="More options"]' );
await page.click( 'button[aria-label="More options"]' );
const convertButton = await page.waitForXPath( '//button[text()="Add to Reusable Blocks"]' );
await convertButton.click();

Expand Down Expand Up @@ -85,8 +85,8 @@ describe( 'Reusable Blocks', () => {
await page.mouse.move( 250, 350, { steps: 10 } );

// Convert block to a reusable block
await page.waitForSelector( 'button[aria-label="More Options"]' );
await page.click( 'button[aria-label="More Options"]' );
await page.waitForSelector( 'button[aria-label="More options"]' );
await page.click( 'button[aria-label="More options"]' );
const convertButton = await page.waitForXPath( '//button[text()="Add to Reusable Blocks"]' );
await convertButton.click();

Expand Down Expand Up @@ -160,7 +160,7 @@ describe( 'Reusable Blocks', () => {
await insertBlock( 'Surprised greeting block' );

// Convert block to a regular block
await page.click( 'button[aria-label="More Options"]' );
await page.click( 'button[aria-label="More options"]' );
const convertButton = await page.waitForXPath(
'//button[text()="Convert to Regular Block"]'
);
Expand All @@ -183,7 +183,7 @@ describe( 'Reusable Blocks', () => {
await insertBlock( 'Surprised greeting block' );

// Delete the block and accept the confirmation dialog
await page.click( 'button[aria-label="More Options"]' );
await page.click( 'button[aria-label="More options"]' );
const convertButton = await page.waitForXPath( '//button[text()="Remove from Reusable Blocks"]' );
await Promise.all( [ waitForAndAcceptDialog(), convertButton.click() ] );

Expand Down

0 comments on commit 6b2e673

Please sign in to comment.