|
1 | 1 | module.exports = function (eleventyConfig) { |
2 | 2 | // Options to customise the appearance of your design history |
3 | 3 | // https://x-govuk.github.io/govuk-eleventy-plugin/options/ |
4 | | - eleventyConfig.addPlugin(require("@x-govuk/govuk-eleventy-plugin"), { |
5 | | - stylesheets: ["/styles/application.css"], |
6 | | - themeColour: "#005eb8", |
| 4 | + eleventyConfig.addPlugin(require('@x-govuk/govuk-eleventy-plugin'), { |
| 5 | + stylesheets: [ |
| 6 | + '/styles/application.css' |
| 7 | + ], |
| 8 | + themeColour: '#005eb8', |
7 | 9 | icons: { |
8 | | - mask: "mask-icon.svg", |
9 | | - shortcut: "favicon.ico", |
10 | | - touch: "apple-touch-icon.png", |
| 10 | + mask: 'mask-icon.svg', |
| 11 | + shortcut: 'favicon.ico', |
| 12 | + touch: 'apple-touch-icon.png' |
11 | 13 | }, |
12 | | - opengraphImageUrl: "opengraph-image.png", |
| 14 | + opengraphImageUrl: 'opengraph-image.png', |
13 | 15 | headingPermalinks: true, |
14 | 16 | header: { |
15 | 17 | logotype: { |
16 | 18 | html: `<svg class="app-logo" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 80 32" height="40" aria-hidden="true" focusable="false"><path fill="currentColor" d="M80 0v32H0V0h80ZM69 2.2c-5.8 0-11.6 2-11.6 8.8 0 7.4 10.2 5.8 10.2 10 0 2.6-3.4 3-5.6 3-2.2 0-5-.6-6.4-1.4L54 28c2.2.8 5.4 1.4 8 1.4 6.2 0 12.8-1.8 12.8-9 0-7.8-10.2-6.6-10.2-10.2 0-2.2 2.2-2.6 5-2.6 2.6 0 4.4.6 5.8 1.2L77 3.4c-1.8-.8-4.8-1.2-8-1.2ZM16.6 3H7.8L2.2 29h6.6l3.6-18h.2L18 29h8.6l5.6-26h-6.6L22 21h-.2L16.6 3Zm25.2 0h-7.2l-5.2 26h6.8l2.4-11.2h8.2L44.6 29h7L57 3h-7l-2.2 9.8h-8l2-9.8Z"/></svg>`, |
17 | 19 | }, |
18 | | - productName: "Digital prevention services design history", |
| 20 | + productName: 'Digital prevention services design history', |
19 | 21 | organisationName: "NHS Digital prevention services design history", |
20 | 22 | search: { |
21 | | - indexPath: "/search.json", |
22 | | - sitemapPath: "/sitemap", |
23 | | - }, |
| 23 | + indexPath: '/search.json', |
| 24 | + sitemapPath: '/sitemap' |
| 25 | + } |
24 | 26 | }, |
25 | 27 | footer: { |
26 | 28 | meta: { |
27 | 29 | items: [ |
28 | 30 | { |
29 | 31 | href: "https://github.com/NHSDigital/prevention-services-design-history", |
30 | | - text: "Github source", |
| 32 | + text: "Github source" |
31 | 33 | }, |
32 | 34 | { |
33 | 35 | href: "/sitemap", |
34 | | - text: "Sitemap", |
| 36 | + text: "Sitemap" |
35 | 37 | }, |
36 | 38 | { |
37 | 39 | href: "/tags", |
38 | | - text: "Tags", |
39 | | - }, |
| 40 | + text: "Tags" |
| 41 | + } |
40 | 42 | ], |
41 | 43 | html: `<p class="app-footer--text">Made by the NHS with <a class="govuk-footer__link" href="https://github.com/x-govuk/nhsuk-design-history-template">X-GOVUK NHS design history template</a></p> |
42 | | - <p class="app-footer--text">All data and personal information shown in prototypes are fictional and for demonstration purposes only</p>`, |
| 44 | + <p class="app-footer--text">All data and personal information shown in prototypes are fictional and for demonstration purposes only</p>` |
43 | 45 | }, |
44 | 46 | copyright: { |
45 | | - text: "© NHS England", |
| 47 | + text: '© NHS England' |
46 | 48 | }, |
47 | | - contentLicence: false, |
| 49 | + contentLicence: false |
48 | 50 | }, |
49 | 51 | url: |
50 | 52 | process.env.GITHUB_ACTIONS && |
51 | | - "https://design-history.prevention-services.nhs.uk/", |
52 | | - }); |
| 53 | + 'https://design-history.prevention-services.nhs.uk/' |
| 54 | + }) |
53 | 55 |
|
54 | 56 | // Passthrough |
55 | | - eleventyConfig.addPassthroughCopy({ "./app/images": "." }); |
| 57 | + eleventyConfig.addPassthroughCopy({ './app/images': '.' }) |
56 | 58 |
|
57 | 59 | // Screening collections |
58 | | - eleventyConfig.addCollection("explore-team", (collection) => { |
59 | | - return collection.getFilteredByGlob("app/posts/explore-team/**/*.md"); |
60 | | - }); |
| 60 | + eleventyConfig.addCollection('explore-team', collection => { |
| 61 | + return collection.getFilteredByGlob('app/posts/explore-team/**/*.md') |
| 62 | + }) |
61 | 63 |
|
62 | | - eleventyConfig.addCollection("manage-breast-screening", (collection) => { |
63 | | - return collection.getFilteredByGlob( |
64 | | - "app/posts/manage-breast-screening/**/*.md" |
65 | | - ); |
66 | | - }); |
| 64 | + eleventyConfig.addCollection('manage-breast-screening', collection => { |
| 65 | + return collection.getFilteredByGlob('app/posts/manage-breast-screening/**/*.md') |
| 66 | + }) |
67 | 67 |
|
68 | 68 | eleventyConfig.addCollection("manage-your-screening", (collection) => { |
69 | | - return collection.getFilteredByGlob( |
70 | | - "app/posts/manage-your-screening/**/*.md" |
71 | | - ); |
| 69 | + return collection.getFilteredByGlob("app/posts/manage-your-screening/**/*.md") |
72 | 70 | }); |
73 | 71 |
|
74 | 72 | eleventyConfig.addCollection("bowel-screening", (collection) => { |
75 | | - return collection.getFilteredByGlob("app/posts/bowel-screening/**/*.md"); |
| 73 | + return collection.getFilteredByGlob("app/posts/bowel-screening/**/*.md") |
76 | 74 | }); |
77 | 75 |
|
78 | 76 | eleventyConfig.addCollection('hpv-self-sampling', collection => { |
79 | 77 | return collection.getFilteredByGlob('app/posts/hpv-self-sampling/**/*.md') |
80 | 78 | }) |
81 | 79 |
|
82 | 80 | // Vaccination collections |
83 | | - eleventyConfig.addCollection("book-a-vaccination", (collection) => { |
84 | | - return collection.getFilteredByGlob("app/posts/book-a-vaccination/**/*.md"); |
85 | | - }); |
| 81 | + eleventyConfig.addCollection('book-a-vaccination', collection => { |
| 82 | + return collection.getFilteredByGlob('app/posts/book-a-vaccination/**/*.md') |
| 83 | + }) |
86 | 84 |
|
87 | | - eleventyConfig.addCollection("manage-your-appointments", (collection) => { |
88 | | - return collection.getFilteredByGlob( |
89 | | - "app/posts/manage-your-appointments/**/*.md" |
90 | | - ); |
91 | | - }); |
| 85 | + eleventyConfig.addCollection('manage-your-appointments', collection => { |
| 86 | + return collection.getFilteredByGlob('app/posts/manage-your-appointments/**/*.md') |
| 87 | + }) |
92 | 88 |
|
93 | | - eleventyConfig.addCollection("record-a-vaccination", (collection) => { |
94 | | - return collection.getFilteredByGlob( |
95 | | - "app/posts/record-a-vaccination/**/*.md" |
96 | | - ); |
97 | | - }); |
| 89 | + eleventyConfig.addCollection('record-a-vaccination', collection => { |
| 90 | + return collection.getFilteredByGlob('app/posts/record-a-vaccination/**/*.md') |
| 91 | + }) |
98 | 92 |
|
99 | | - eleventyConfig.addCollection("select-people-for-invitation", (collection) => { |
100 | | - return collection.getFilteredByGlob( |
101 | | - "app/posts/select-people-for-invitation/**/*.md" |
102 | | - ); |
103 | | - }); |
| 93 | + eleventyConfig.addCollection('select-people-for-invitation', collection => { |
| 94 | + return collection.getFilteredByGlob('app/posts/select-people-for-invitation/**/*.md') |
| 95 | + }) |
104 | 96 |
|
105 | 97 | // Personalised prevention collections |
106 | | - eleventyConfig.addCollection("digital-nhs-health-check", (collection) => { |
107 | | - return collection.getFilteredByGlob( |
108 | | - "app/posts/digital-nhs-health-check/**/*.md" |
109 | | - ); |
110 | | - }); |
| 98 | + eleventyConfig.addCollection('digital-nhs-health-check', collection => { |
| 99 | + return collection.getFilteredByGlob('app/posts/digital-nhs-health-check/**/*.md') |
| 100 | + }) |
111 | 101 |
|
112 | | - eleventyConfig.addCollection( |
113 | | - "personalised-prevention-platform", |
114 | | - (collection) => { |
115 | | - return collection.getFilteredByGlob( |
116 | | - "app/posts/personalised-prevention-platform/**/*.md" |
117 | | - ); |
118 | | - } |
119 | | - ); |
| 102 | + eleventyConfig.addCollection('personalised-prevention-platform', collection => { |
| 103 | + return collection.getFilteredByGlob('app/posts/personalised-prevention-platform/**/*.md') |
| 104 | + }) |
120 | 105 |
|
121 | | - eleventyConfig.addCollection("talking-therapies", (collection) => { |
122 | | - return collection.getFilteredByGlob("app/posts/talking-therapies/**/*.md"); |
123 | | - }); |
| 106 | + eleventyConfig.addCollection('talking-therapies', collection => { |
| 107 | + return collection.getFilteredByGlob('app/posts/talking-therapies/**/*.md') |
| 108 | + }) |
124 | 109 |
|
125 | | - eleventyConfig.addCollection("smoking-cessation", (collection) => { |
126 | | - return collection.getFilteredByGlob("app/posts/smoking-cessation/**/*.md"); |
127 | | - }); |
| 110 | + eleventyConfig.addCollection('smoking-cessation', collection => { |
| 111 | + return collection.getFilteredByGlob('app/posts/smoking-cessation/**/*.md') |
| 112 | + }) |
128 | 113 |
|
129 | | - eleventyConfig.addCollection("guide", (collection) => { |
130 | | - return collection.getFilteredByGlob("app/guide/**/*.md"); |
131 | | - }); |
| 114 | + eleventyConfig.addCollection('guide', collection => { |
| 115 | + return collection.getFilteredByGlob('app/guide/**/*.md') |
| 116 | + }) |
132 | 117 |
|
133 | 118 | // Config |
134 | 119 | return { |
135 | | - dataTemplateEngine: "njk", |
136 | | - htmlTemplateEngine: "njk", |
137 | | - markdownTemplateEngine: "njk", |
| 120 | + dataTemplateEngine: 'njk', |
| 121 | + htmlTemplateEngine: 'njk', |
| 122 | + markdownTemplateEngine: 'njk', |
138 | 123 | dir: { |
139 | | - input: "app", |
140 | | - layouts: "_layouts", |
141 | | - includes: "_components", |
142 | | - }, |
143 | | - }; |
144 | | -}; |
| 124 | + input: 'app', |
| 125 | + layouts: '_layouts', |
| 126 | + includes: '_components' |
| 127 | + } |
| 128 | + } |
| 129 | +} |
0 commit comments