Skip to content

Commit

Permalink
Standardize List View feature name to use title case capitalization. (#…
Browse files Browse the repository at this point in the history
…61535)

* Standardize List View feature name to use title case capitalization.

* Update one occurrence of block List View by removing the word block.

Co-authored-by: afercia <[email protected]>
Co-authored-by: alexstine <[email protected]>
Co-authored-by: SergeyBiryukov <[email protected]>
  • Loading branch information
4 people authored May 14, 2024
1 parent 7376042 commit e2a0a54
Show file tree
Hide file tree
Showing 5 changed files with 13 additions and 13 deletions.
6 changes: 3 additions & 3 deletions packages/block-library/src/latest-posts/edit.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ import {
ToggleControl,
ToolbarGroup,
} from '@wordpress/components';
import { __, sprintf } from '@wordpress/i18n';
import { __, _x, sprintf } from '@wordpress/i18n';
import { dateI18n, format, getSettings } from '@wordpress/date';
import {
InspectorControls,
Expand Down Expand Up @@ -416,13 +416,13 @@ export default function LatestPostsEdit( { attributes, setAttributes } ) {
const layoutControls = [
{
icon: list,
title: __( 'List view' ),
title: _x( 'List view', 'Latest posts block display setting' ),
onClick: () => setAttributes( { postLayout: 'list' } ),
isActive: postLayout === 'list',
},
{
icon: grid,
title: __( 'Grid view' ),
title: _x( 'Grid view', 'Latest posts block display setting' ),
onClick: () => setAttributes( { postLayout: 'grid' } ),
isActive: postLayout === 'grid',
},
Expand Down
6 changes: 3 additions & 3 deletions packages/block-library/src/post-template/edit.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import clsx from 'clsx';
*/
import { memo, useMemo, useState } from '@wordpress/element';
import { useSelect } from '@wordpress/data';
import { __ } from '@wordpress/i18n';
import { __, _x } from '@wordpress/i18n';
import {
BlockControls,
BlockContextProvider,
Expand Down Expand Up @@ -246,13 +246,13 @@ export default function PostTemplateEdit( {
const displayLayoutControls = [
{
icon: list,
title: __( 'List view' ),
title: _x( 'List view', 'Post template block display setting' ),
onClick: () => setDisplayLayout( { type: 'default' } ),
isActive: layoutType === 'default' || layoutType === 'constrained',
},
{
icon: grid,
title: __( 'Grid view' ),
title: _x( 'Grid view', 'Post template block display setting' ),
onClick: () =>
setDisplayLayout( {
type: 'grid',
Expand Down
6 changes: 3 additions & 3 deletions packages/block-library/src/rss/edit.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import {
} from '@wordpress/components';
import { useState } from '@wordpress/element';
import { grid, list, edit, rss } from '@wordpress/icons';
import { __ } from '@wordpress/i18n';
import { __, _x } from '@wordpress/i18n';
import { prependHTTP } from '@wordpress/url';
import ServerSideRender from '@wordpress/server-side-render';

Expand Down Expand Up @@ -106,13 +106,13 @@ export default function RSSEdit( { attributes, setAttributes } ) {
},
{
icon: list,
title: __( 'List view' ),
title: _x( 'List view', 'RSS block display setting' ),
onClick: () => setAttributes( { blockLayout: 'list' } ),
isActive: blockLayout === 'list',
},
{
icon: grid,
title: __( 'Grid view' ),
title: _x( 'Grid view', 'RSS block display setting' ),
onClick: () => setAttributes( { blockLayout: 'grid' } ),
isActive: blockLayout === 'grid',
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ function EditorKeyboardShortcutsRegister() {
registerShortcut( {
name: 'core/editor/toggle-list-view',
category: 'global',
description: __( 'Open the block list view.' ),
description: __( 'Open the List View.' ),
keyCombination: {
modifier: 'access',
character: 'o',
Expand Down
6 changes: 3 additions & 3 deletions packages/editor/src/components/preferences-modal/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -70,9 +70,9 @@ export default function EditorPreferencesModal( { extraSections = {} } ) {
scope="core"
featureName="showListViewByDefault"
help={ __(
'Opens the block list view sidebar by default.'
'Opens the List View sidebar by default.'
) }
label={ __( 'Always open list view' ) }
label={ __( 'Always open List View' ) }
/>
{ showBlockBreadcrumbsOption && (
<PreferenceToggleControl
Expand All @@ -88,7 +88,7 @@ export default function EditorPreferencesModal( { extraSections = {} } ) {
scope="core"
featureName="allowRightClickOverrides"
help={ __(
'Allows contextual list view menus via right-click, overriding browser defaults.'
'Allows contextual List View menus via right-click, overriding browser defaults.'
) }
label={ __(
'Allow right-click contextual menus'
Expand Down

0 comments on commit e2a0a54

Please sign in to comment.