Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

RAS-1284 Banner Menu Headings #1034

Open
wants to merge 3 commits into
base: survey-respondent-help-journey
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ docker-test: test

#remove -i 70612 once jinja2 is upgraded past v3.1.4
lint:
pipenv check -i 70612 -i 74735
pipenv check -i 70612 -i 74735
pipenv run isort .
pipenv run black --line-length 120 .
pipenv run djlint frontstage/ --ignore=H037,H021
Expand Down
1 change: 1 addition & 0 deletions frontstage/templates/layouts/_base.html
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@
"title": "ONS Business Surveys",
}
} %}
{% include 'layouts/configs/banner_menu.html' %}
{% include 'layouts/configs/service-links.html' %}
{% include 'layouts/configs/footer.html' %}
{% from "components/panel/_macro.njk" import onsPanel %}
Expand Down
28 changes: 28 additions & 0 deletions frontstage/templates/layouts/configs/banner_menu.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
{% if 'authorization' in request.cookies %}
{% set banner_menu = {
"id": "navigation-menu",
"currentPath": request.path,
"ariaLabel": "Navigation menu",
"ariraListLabel": "Navigation menu list",
"toggleNavigationButton":{
"text": "Navigation menu",
"ariaLabel": "Navigation menu",
},
"itemsList": [
{
"title": "Surveys",
"url": "/surveys/todo"
},
{
"title": "Completed Surveys",
"url": "/surveys/history"
},
{
"title": "Messages",
"url": "/secure-message/threads"
},
]
} %}

{% do pageConfig.header | setAttribute("navigation", banner_menu) %}
{% endif %}
18 changes: 0 additions & 18 deletions frontstage/templates/partials/tab_list.html

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
{% set page_title = "Messages" %}

{% block content %}
{% include "partials/tab_list.html" %}

{% with messages = get_flashed_messages() %}
{% if messages %}
Expand Down
1 change: 0 additions & 1 deletion frontstage/templates/secure-messages/messages.html
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
{% extends 'layouts/_base.html' %}

{% block content %}
{% include "partials/tab_list.html" %}

<div>
{% block messages %}
Expand Down
1 change: 0 additions & 1 deletion frontstage/templates/surveys/surveys-history.html
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
{% set page_title = "Completed surveys" %}

{% block content %}
{% include "partials/tab_list.html" %}

{% set emptySurveyListLabel = 'No items to show' %}
<div class="ons-container">
Expand Down
2 changes: 1 addition & 1 deletion frontstage/templates/surveys/surveys-todo.html
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
{% endfor %}
{% endif %}
{% endwith %}
{% include "partials/tab_list.html" %}

<div class="ons-container">
<div class="ons-grid">
<div class="ons-grid__col ons-col-8@m ">
Expand Down