[1.0.0-beta1] Evaluate Navigation module's top bar API

Created on 9 June 2025, 28 days ago

Problem/Motivation

The display builder's toolbar template looks like that:

<div {{ attributes.addClass('db-toolbar').addClass('db-background') }}>
  <aside class="db-toolbar__start">
    {{ start }}
  </aside>
  <nav class="db-toolbar__middle">
    {{ middle }}
  </nav>
  <aside class="db-toolbar__end">
    {{ end }}
  </aside>
</div>

Drupal's TopBar has 3 similar regions:

enum TopBarRegion: string {
  case Tools = 'tools';
  case Context = 'context';
  case Actions = 'actions';
}

Where:

  • tools is at the start (so the left in LFR)
  • context is in the middle
  • actions in the end (so the right for LTR)

Proposed resolution

Instead of our own toolbar, can we use the upcoming Core navigation module's?

Notes:

  • To avoid being displayed in pages when there is no display builder, we can return empty array from ::build() method
  • Main part of the display builder stays in the page main content
  • The difficulty will be to inject the builder ID from the main content to the toolbar
  • It will simplify the rendering of display_builder:display_builder component. will it be enough to remove it?
📌 Task
Status

Active

Version

1.0

Component

UI/UX/Islands

Created by

🇫🇷France pdureau Paris

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Production build 0.71.5 2024