Skip to content

Sidebar (page list) as Gutenberg block #132

@brylie

Description

@brylie

Problem

Our default layout currently displays a sidebar. The sidebar renders a page list where the pages are children of the parent:

<aside class="sidebar">
<?php
$parent = CC_Site::get_parent_page();
echo '<nav class="side-navigation padding-vertical-big">';
echo '<ul class="list-pages">';
wp_list_pages(
array(
'child_of' => $parent,
'show_date' => '',
'depth' => 3,
'title_li' => '',
)
);
echo '</ul>';
echo '</nav>';
get_sidebar();
?>
</aside>

However, having the sidebar doesn't allow Gutenberg blocks to display full-width.

Description

Determine how best to handle the sidebar menu, such as

  • moving it to a custom Gutenberg widget
  • using the default Gutenberg page list block (which doesn't allow specifying a root page)
  • making the default template have no sidebar and creating a "page with sidebar" theme

Related resources

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    Status

    Backlog

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions