Skip to content

Commit 7045ebe

Browse files
Merge branch 'main' into nbs
2 parents b6dee1a + cb71818 commit 7045ebe

61 files changed

Lines changed: 1689 additions & 307 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

app/_layouts/product.njk

Lines changed: 45 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,9 @@
22

33
{% block content %}
44
{{ content }}
5-
<div class="govuk-grid-row">
6-
{# Paginate posts if front matter includes the pagination key #}
7-
{% if pagination %}
5+
{# Paginate posts if front matter includes the pagination key #}
6+
{% if pagination %}
7+
<div class="govuk-grid-row">
88
<section class="govuk-grid-column-two-thirds">
99
<h2 class="govuk-heading-l govuk-!-font-size-27">
1010
{{ posts.title or app.posts.title or "Posts" }}
@@ -23,44 +23,54 @@
2323
items: pagination | itemsFromPagination
2424
}) if pagination.pages.length > 1 }}
2525
</section>
26-
{% if aside or related %}
26+
</div>
27+
{% if aside or related %}
28+
<div class="govuk-grid-row">
2729
<div class="govuk-grid-column-one-third">
2830
{% include "layouts/shared/related.njk" %}
2931
</div>
30-
{% endif %}
31-
{# List sections (pages with a parent that is the homepage) if homepage has no pagination key set #}
32-
{% elif eleventyNavigation.key == options.homeKey %}
32+
</div>
33+
{% endif %}
34+
{# List sections (pages with a parent that is the homepage) if homepage has no pagination key set #}
35+
{% elif eleventyNavigation.key == options.homeKey %}
3336

34-
{% set sections = [
35-
{ title: "Screening", services: [
36-
"Bowel screening",
37-
"Explore team",
38-
"HPV Self-Sampling",
39-
"Manage breast screening",
40-
"Manage your screening"
41-
] },
42-
{ title: "Vaccinations", services: [
43-
"Book a vaccination",
44-
"Manage vaccinations in schools",
45-
"Manage your appointments",
46-
"Record a vaccination",
47-
"Select people for invitation",
48-
"Vaccinations in the app"
49-
] },
50-
{ title: "Personalised prevention", services: [
51-
"Personalised prevention platform",
52-
"Smoking cessation"
53-
] }
54-
] %}
37+
{% set sections = [
38+
{ title: "Screening", services: [
39+
"Bowel screening",
40+
"Cohort manager",
41+
"Explore team",
42+
"Manage breast screening",
43+
"Manage your screening",
44+
"HPV self-sampling",
45+
"Invite"
46+
] },
47+
{ title: "Vaccinations", services: [
48+
"Book a vaccination",
49+
"Manage vaccinations in schools",
50+
"Manage your appointments",
51+
"Record a vaccination",
52+
"Select people for invitation",
53+
"Vaccinations in the app"
54+
] },
55+
{ title: "Personalised prevention", services: [
56+
"Lung health check",
57+
"Personalised prevention platform",
58+
"Smoking cessation"
59+
] }
60+
] %}
5561

56-
{% for section in sections %}
62+
{% for section in sections %}
63+
<div class="govuk-grid-row">
5764
<div class="govuk-grid-column-two-thirds">
5865
<h2 class="govuk-heading-l">
5966
{{ section.title }}
6067
</h2>
6168
</div>
69+
</div>
6270

63-
{% for service in section.services %}
71+
{% for batch in section.services | batch(2) %}
72+
<div class="govuk-grid-row">
73+
{% for service in batch %}
6474
{% for item in collections.all | eleventyNavigation(options.homeKey) %}
6575
{% if (service == item.title) %}
6676
<section class="govuk-grid-column-one-half govuk-!-margin-bottom-6">
@@ -72,8 +82,11 @@
7282
{% endif %}
7383
{% endfor %}
7484
{% endfor %}
85+
</div>
7586
{% endfor %}
87+
{% endfor %}
7688

89+
<div class="govuk-grid-row">
7790
<div class="govuk-grid-column-full">
7891
<hr class="govuk-section-break govuk-section-break--xl govuk-section-break--visible">
7992

@@ -85,10 +98,8 @@
8598
<p class="govuk-body">{{ item.excerpt }}</p>
8699
{% endif %}
87100
{% endfor %}
88-
89-
90101
</div>
102+
</div>
91103

92-
{% endif %}
93-
</div>
104+
{% endif %}
94105
{% endblock %}

app/guide/how-to-add-a-new-service.md

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -10,14 +10,15 @@ Posts in this design history are grouped by the service or team they relate to.
1010

1111
You may want to [look at an existing pull request](https://github.com/NHSDigital/prevention-services-design-history/pull/20) to see the files you need to update.
1212

13-
You will need to create some files and folders based on the name of your service, using lowercase and hypens. For example, for `Manage breast screening` you would use `manage-breast-screening`
13+
You will need to create some files and folders based on the name of your service, using lowercase and hypens. For example, for `Manage breast screening` you would use `manage-breast-screening`.
1414

1515
You’ll need to:
1616

1717
* create a Markdown file in `app/posts/`, for example `app/posts/your-service-name.md`. Copy an existing example and update any references to match your service.
18-
* create a folder for your service in `app/images/`, for example `app/images/your-service-name/`
19-
* create a folder for your service in `app/posts/`, for example `app/posts/your-service-name/`
18+
* create a folder for your service in `app/images/`, for example `app/images/your-service-name/`.
19+
* create a folder for your service in `app/posts/`, for example `app/posts/your-service-name/`.
2020
* inside your service’s post folder, ceate a json file `your-service-name.json`, for exampole `app/posts/your-service-name/your-service-name.json`. Copy an existing example for what to put in it.
21-
* update `eleventy.config.js` to create a new 'collection' for your service (copy one of the existing examples)
22-
* update `app/_layouts/_product.njk` to list your new service in the sections variable
23-
* open a pull request with your changes
21+
* update `eleventy.config.js` to create a new 'collection' for your service (copy one of the existing examples).
22+
* update `app/_layouts/_product.njk` to list your new service in the sections variable.
23+
* **note:** you will need to [add a post](/guide/how-to-publish/) before the service can be found in the navigation.
24+
* open a pull request with your changes.
15.8 KB
Loading
29.5 KB
Loading
43.3 KB
Loading
77 KB
Loading
270 KB
Loading
36.9 KB
Loading
Loading
Loading

0 commit comments

Comments
 (0)