feat: centralize breadcrumbs in topbar and remove history navigation
Move breadcrumb rendering from individual page templates into the core topbar. Each page now sets $breadcrumbs in its action .php file; the topbar renders it automatically via the shared partial. - Remove global back/forward buttons and app-nav-history.js component - Remove Alt+Arrow keyboard shortcuts for history navigation - Render breadcrumb in topbar-left section (replaces button area) - Clean up breadcrumb CSS: context-neutral base (flex, no margin) - Recalculate sticky titlebar offset in details container - Migrate all 41 pages (core + helpdesk, audit, addressbook, api-docs) - Add missing breadcrumbs to addressbook detail view - Update architecture contract tests (nav-history references removed) Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -1,6 +1,5 @@
|
||||
<?php
|
||||
$breadcrumbs = $breadcrumbs ?? [];
|
||||
$items = array_values(array_filter($breadcrumbs, static function ($item) {
|
||||
$items = array_values(array_filter($breadcrumbs ?? [], static function ($item) {
|
||||
return !empty($item['label']);
|
||||
}));
|
||||
if (!$items) {
|
||||
|
||||
@@ -27,17 +27,16 @@ $moduleSlots = is_array($layoutNav['moduleSlots'] ?? null) ? $layoutNav['moduleS
|
||||
$moduleTopbarSlots = is_array($moduleSlots['topbar.right_item'] ?? null) ? $moduleSlots['topbar.right_item'] : [];
|
||||
|
||||
?>
|
||||
<header class="app-header" data-app-component="nav-history">
|
||||
<header class="app-header">
|
||||
<nav class="app-topbar">
|
||||
<ul class="app-topbar-left">
|
||||
<li>
|
||||
<a id="global-back" data-tooltip-pos="bottom" data-tooltip="<?php e(t('Back')); ?> (Alt+←)" title="<?php e(t('Back')); ?> (Alt+←)" aria-label="<?php e(t('Back')); ?> (Alt+←)" href="admin"><i class="bi bi-arrow-left"></i></a>
|
||||
</li>
|
||||
<li>
|
||||
<a id="global-forward" data-tooltip-pos="bottom" data-tooltip="<?php e(t('Forward')); ?> (Alt+→)" title="<?php e(t('Forward')); ?> (Alt+→)" aria-label="<?php e(t('Forward')); ?> (Alt+→)" href="admin"><i class="bi bi-arrow-right"></i></a>
|
||||
</li>
|
||||
<li id="async-messages" role="status" aria-live="polite" aria-hidden="true"></li>
|
||||
</ul>
|
||||
<div class="app-topbar-left">
|
||||
<?php
|
||||
if (is_array($breadcrumbs ?? null) && $breadcrumbs !== []) {
|
||||
require __DIR__ . '/app-breadcrumb.phtml';
|
||||
}
|
||||
?>
|
||||
<span id="async-messages" role="status" aria-live="polite" aria-hidden="true"></span>
|
||||
</div>
|
||||
<div class="app-topbar-center">
|
||||
<button type="button" class="app-topbar-search-trigger" data-app-search-trigger aria-label="<?php e(t('Search')); ?>" title="<?php e(t('Search')); ?>">
|
||||
<i class="bi bi-search" aria-hidden="true"></i>
|
||||
|
||||
Reference in New Issue
Block a user