From 40ce2a8edd4003b8f30d5411a1983eb8fb6338d8 Mon Sep 17 00:00:00 2001 From: Kai Schlamp Date: Mon, 12 Feb 2024 01:11:13 +0000 Subject: [PATCH] Rename nav menu items to main menu items --- radis/core/site.py | 8 ++++---- radis/core/templates/core/_navbar_links.html | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/radis/core/site.py b/radis/core/site.py index d672218d..edcd1561 100644 --- a/radis/core/site.py +++ b/radis/core/site.py @@ -5,16 +5,16 @@ from django.middleware.csrf import get_token -class NavMenuItem(NamedTuple): +class MainMenuItem(NamedTuple): url_name: str label: str -nav_menu_items: list[NavMenuItem] = [] +main_menu_items: list[MainMenuItem] = [] def register_main_menu_item(url_name: str, label: str) -> None: - nav_menu_items.append(NavMenuItem(url_name, label)) + main_menu_items.append(MainMenuItem(url_name, label)) def base_context_processor(request: HttpRequest) -> dict[str, Any]: @@ -32,7 +32,7 @@ def base_context_processor(request: HttpRequest) -> dict[str, Any]: "version": settings.RADIS_VERSION, "base_url": settings.BASE_URL, "support_email": settings.SUPPORT_EMAIL, - "nav_menu_items": nav_menu_items, + "main_menu_items": main_menu_items, "theme": theme, "theme_color": theme_color, # Variables in public are also available on the client via JavaScript, diff --git a/radis/core/templates/core/_navbar_links.html b/radis/core/templates/core/_navbar_links.html index 845b53cf..1dd689a0 100644 --- a/radis/core/templates/core/_navbar_links.html +++ b/radis/core/templates/core/_navbar_links.html @@ -1,6 +1,6 @@