- content_for :page_content do
  = cadmus_renderer.render(@page.liquid_template, :html)

- if can? :update, @page
  .row
    .col-md-9
      = content_for :page_content
    .col-md-3
      .card
        .card-header= @page.name
        %ul.list-group.list-group-flush
          %li.list-group-item
            = link_to "Edit page", [:edit, @page]
          - if can?(:delete?, @page) && @page.parent.root_page != @page
            %li.list-group-item
              = link_to "Delete page", page_path(@page), :method => :delete, "data-confirm" => "Are you sure you want to delete this page?"
- else
  = content_for :page_content
- content_for :page_content do
  = cadmus_renderer.render(@page.liquid_template, :html)

- if can? :update, @page
  %nav.navbar.navbar-expand-md.navbar-dark.bg-dark.mb-4
    .collapse.navbar-collapse
      .navbar-brand
        Admin options
      .navbar-nav
        = link_to "Edit page", [:edit, @page], class: 'nav-item nav-link'
        - if can?(:delete?, @page) && @page.parent.root_page != @page
          = link_to "Delete page", page_path(@page), :method => :delete, "data-confirm" => "Are you sure you want to delete this page?", class: 'nav-item nav-link'

= content_for :page_content

Use a non-layout-breaking admin bar for pages
Use a non-layout-breaking admin bar for pages
