Skip to content

enhancement: Move module navigation rendering to centralized, module-aware sidebar logic - #50

Open
glitched-matrix44 wants to merge 6 commits into
mainfrom
IQU-enhancement-49
Open

enhancement: Move module navigation rendering to centralized, module-aware sidebar logic#50
glitched-matrix44 wants to merge 6 commits into
mainfrom
IQU-enhancement-49

Conversation

@glitched-matrix44

Copy link
Copy Markdown
Contributor

This PR updates the User Interface package to consume the new Foundation navigation model by replacing static module rendering with a centralized, navigation-driven workflow. Module tabs, sidebars, and shared layout components now render from Foundation navigation data while client-side rendering, active-state management, and navigation behavior are consolidated into a dedicated navigation renderer.

Key Changes
Rebuilt module-tabs.blade.php to render navigation from Foundation records instead of installed modules.
Added authentication and module-access filtering to ensure only authorized navigation items are displayed.
Introduced public/js/navigation/navigation-renderer.js to centralize sidebar rendering, active-state management, and navigation behavior.
Removed the legacy inline sidebar rendering logic from layouts/sidebar.blade.php.
Updated the header, minibar, mobile navigation, and module tab layouts to consume the shared navigation renderer.
Updated the UI controller and service provider to support the new navigation workflow.

Issue: #49

Comment thread public/js/navigation/navigation-renderer.js Fixed
const moduleTab = e.target.closest('.module-tab[data-href]');
if (moduleTab) {
const href = moduleTab.dataset.href || moduleTab.getAttribute('href');
if (href && href !== '#' && !href.startsWith('javascript:')) {
const dropdownItem = e.target.closest('.dropdown-item[data-menu][data-href]');
if (dropdownItem) {
const href = dropdownItem.dataset.href || dropdownItem.getAttribute('href');
if (href && href !== '#' && !href.startsWith('javascript:')) {
const primarySidebarUrl = getPrimarySidebarUrl(menu);
const targetHref = primarySidebarUrl || href;

if (!targetHref || targetHref === '#' || targetHref.startsWith('javascript:')) {
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

enhancement: support centralized module-aware navigation rendering in User Interface

2 participants