mirror of
https://github.com/GSA/notifications-admin.git
synced 2026-08-23 15:57:23 -04:00
Remove <h2> tag around service name in nav
The heading structure of most pages is incorrect (`<h2>` followed by `<h1>`). The `<h1>` indicates the main purpose of the page, the service name (currently the first `<h2>`) doesn't need to be a heading.
This commit is contained in:
@@ -9,7 +9,7 @@
|
|||||||
margin: 0 0 10px;
|
margin: 0 0 10px;
|
||||||
position: relative;
|
position: relative;
|
||||||
|
|
||||||
h2 {
|
&-name {
|
||||||
@include bold-19;
|
@include bold-19;
|
||||||
margin: 0 0 0 0;
|
margin: 0 0 0 0;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -7,9 +7,9 @@
|
|||||||
{% block fullwidth_content %}
|
{% block fullwidth_content %}
|
||||||
<div id="content">
|
<div id="content">
|
||||||
<div class="navigation-service">
|
<div class="navigation-service">
|
||||||
<h2 class="navigation-service-name">
|
<div class="navigation-service-name">
|
||||||
{{ current_service.name }}
|
{{ current_service.name }}
|
||||||
</h2>
|
</div>
|
||||||
<a href="{{ url_for('main.choose_service') }}" class="navigation-service-switch">Switch service</a>
|
<a href="{{ url_for('main.choose_service') }}" class="navigation-service-switch">Switch service</a>
|
||||||
</div>
|
</div>
|
||||||
<div class="grid-row">
|
<div class="grid-row">
|
||||||
|
|||||||
@@ -105,7 +105,6 @@ def test_should_show_recent_templates_on_dashboard(
|
|||||||
|
|
||||||
page = BeautifulSoup(response.data.decode('utf-8'), 'html.parser')
|
page = BeautifulSoup(response.data.decode('utf-8'), 'html.parser')
|
||||||
headers = [header.text.strip() for header in page.find_all('h2') + page.find_all('h1')]
|
headers = [header.text.strip() for header in page.find_all('h2') + page.find_all('h1')]
|
||||||
assert 'Test Service' in headers
|
|
||||||
assert 'In the last 7 days' in headers
|
assert 'In the last 7 days' in headers
|
||||||
|
|
||||||
table_rows = page.find_all('tbody')[1].find_all('tr')
|
table_rows = page.find_all('tbody')[1].find_all('tr')
|
||||||
|
|||||||
@@ -102,7 +102,7 @@ def test_show_restricted_service(
|
|||||||
response = logged_in_client.get(url_for('main.service_settings', service_id=service_one['id']))
|
response = logged_in_client.get(url_for('main.service_settings', service_id=service_one['id']))
|
||||||
page = BeautifulSoup(response.data.decode('utf-8'), 'html.parser')
|
page = BeautifulSoup(response.data.decode('utf-8'), 'html.parser')
|
||||||
assert page.find('h1').text == 'Settings'
|
assert page.find('h1').text == 'Settings'
|
||||||
assert page.find_all('h2')[1].text == 'Your service is in trial mode'
|
assert page.find_all('h2')[0].text == 'Your service is in trial mode'
|
||||||
|
|
||||||
|
|
||||||
def test_switch_service_to_live(
|
def test_switch_service_to_live(
|
||||||
|
|||||||
Reference in New Issue
Block a user