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

Improve Site Editor usability by adding descriptions under Design menu items #68850

Draft
wants to merge 1 commit into
base: trunk
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
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
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ export default function SidebarNavigationItem( {
uid,
to,
onClick,
description,
children,
...props
} ) {
Expand Down Expand Up @@ -80,6 +81,11 @@ export default function SidebarNavigationItem( {
) }
{ ! withChevron && suffix }
</HStack>
{ description && (
<p className="edit-site-sidebar-navigation-item__description">
{ description }
</p>
) }
</Item>
);
}
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,10 @@
}
}

.edit-site-sidebar-navigation-item__description {
margin: 10px 0;
}

.edit-site-sidebar-navigation-screen__content .block-editor-list-view-block-select-button {
cursor: grab;
padding: $grid-unit-10 $grid-unit-10 $grid-unit-10 0;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,13 +27,19 @@ export function MainSidebarNavigationContent( { isBlockBasedTheme = true } ) {
to="/navigation"
withChevron
icon={ navigation }
description={ __(
'Manage your Navigation menus. (Navigation, Footer navigation\u2026)'
) }
>
{ __( 'Navigation' ) }
</SidebarNavigationItem>
<SidebarNavigationItemGlobalStyles
to="/styles"
uid="global-styles-navigation-item"
icon={ styles }
description={ __(
'Choose a different style combination for the theme styles. (Blue, Green, Orange\u2026)'
) }
>
{ __( 'Styles' ) }
</SidebarNavigationItemGlobalStyles>
Expand All @@ -42,6 +48,9 @@ export function MainSidebarNavigationContent( { isBlockBasedTheme = true } ) {
to="/page"
withChevron
icon={ page }
description={ __(
'Browse and edit pages on your site. (Home page, index, Sample page\u2026)'
) }
>
{ __( 'Pages' ) }
</SidebarNavigationItem>
Expand All @@ -50,6 +59,9 @@ export function MainSidebarNavigationContent( { isBlockBasedTheme = true } ) {
to="/template"
withChevron
icon={ layout }
description={ __(
'Express the layout of your site with templates. (Page, single posts, 404\u2026)'
) }
>
{ __( 'Templates' ) }
</SidebarNavigationItem>
Expand All @@ -70,6 +82,9 @@ export function MainSidebarNavigationContent( { isBlockBasedTheme = true } ) {
to="/pattern"
withChevron
icon={ symbol }
description={ __(
'Manage what patterns are available when editing the site. (Call to action, headers, footers\u2026)'
) }
>
{ __( 'Patterns' ) }
</SidebarNavigationItem>
Expand Down
Loading