Skip to content

Commit

Permalink
Release 6.1.0 (#401)
Browse files Browse the repository at this point in the history
* Feature/fsr 656 (#379)

* dependabot updates

https://eaflood.atlassian.net/browse/FSR-656

* Bump luxon from 1.28.0 to 1.28.1 (#377)

Bumps [luxon](https://github.com/moment/luxon) from 1.28.0 to 1.28.1.
- [Release notes](https://github.com/moment/luxon/releases)
- [Changelog](https://github.com/moment/luxon/blob/master/CHANGELOG.md)
- [Commits](moment/luxon@1.28.0...1.28.1)

---
updated-dependencies:
- dependency-name: luxon
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <[email protected]>

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* Bump json5 from 1.0.1 to 1.0.2 (#376)

Bumps [json5](https://github.com/json5/json5) from 1.0.1 to 1.0.2.
- [Release notes](https://github.com/json5/json5/releases)
- [Changelog](https://github.com/json5/json5/blob/main/CHANGELOG.md)
- [Commits](json5/json5@v1.0.1...v1.0.2)

---
updated-dependencies:
- dependency-name: json5
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <[email protected]>

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* dependencies updates (#380)

* dependancie updates

* updated dependencies

* Release 6.0.0 (#384)

* https://eaflood.atlassian.net/projects/FSR/versions/16012/tab/release-report-all-issues

* Fix/FSR-707 use correct icons for no longer in force

https://eaflood.atlassian.net/browse/FSR-707

No longer in force icons were incorrect

* Release 6.0.0 version update and release notes.

Release 6.0.0 version update and release notes.

Update app version number

Tweaks to docs

Co-authored-by: neil mclaughlin <[email protected]>

* Feature/fsr 702 (#385)

* remove anomalys from telemetry

https://eaflood.atlassian.net/browse/FSR-702

* created function in util to remove spike in telemetry

* sonarcloud

* refactored for sonarcloud

* refactored after peer review and sonarcloud

* updated function name

* updated function to remove spikes over 300m (#387)

* Feature/fsr 702 fix 2 (#390)

* https://eaflood.atlassian.net/browse/FSR-702

* upped to 400 max level from feedback from Kim at PO stage

* feature/FSR-734  (#395)

* altered mental health advice link

* updated clean up your home link

* Feature/fsr 700 (#394)

* added contact details to station pages

* styling changes and make related content partial dynamic

* fixed broken unit tests

* fixed broken CYLTFR link

* updated G tags to just Get-warnings

* feature/FSR-734  (#395)

* altered mental health advice link

* updated clean up your home link

* added contact details to station pages

* styling changes and make related content partial dynamic

* fixed broken unit tests

* fixed broken CYLTFR link

* updated G tags to just Get-warnings

* rebase and code smell fixes

* Feature/fsr 693 (#397)

* localised mocking files removed

* altered env variable name to be more relevant

* removed server log

* removed unused var

---------

Co-authored-by: LeeGordon83 <[email protected]>

* Release 6.1.0

https://eaflood.atlassian.net/projects/FSR/versions/16105/tab/release-report-all-issues

* added release notes and version updates

* release notes update

---------

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: neil mclaughlin <[email protected]>
Co-authored-by: Lee Gordon <[email protected]>
Co-authored-by: LeeGordon83 <[email protected]>
  • Loading branch information
5 people authored Feb 15, 2023
1 parent a041064 commit 6b9065d
Show file tree
Hide file tree
Showing 28 changed files with 8,817 additions and 1,011 deletions.
5 changes: 0 additions & 5 deletions index.js
Original file line number Diff line number Diff line change
@@ -1,15 +1,10 @@
const createServer = require('./server')
const config = require('./server/config')
const pkg = require('./package.json')

createServer()
.then((server) => {
server.start()
console.log('flood-app (%s) running on %s', pkg.version, server.info.uri)
if (config.mockExternalHttp) {
require('./mock')
server.log('info', 'External requests are being mocked')
}
})
.catch(err => {
console.log(err)
Expand Down
2 changes: 0 additions & 2 deletions mock/index.js

This file was deleted.

20 changes: 0 additions & 20 deletions mock/location/find.json

This file was deleted.

8 changes: 0 additions & 8 deletions mock/location/index.js

This file was deleted.

2,239 changes: 1,378 additions & 861 deletions package-lock.json

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "flood-app",
"version": "6.0.0",
"version": "6.1.0",
"description": "Flood risk app",
"main": "index.js",
"repository": "github:defra/flood-app",
Expand Down
26 changes: 26 additions & 0 deletions release-docs/CFF-6.1.0.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
# Check for flooding 6.1.0 Thursday 16th February 2023

# Release

6.1.0

https://eaflood.atlassian.net/projects/FSR/versions/16105/tab/release-report-all-issues

# Tickets

https://eaflood.atlassian.net/browse/FSR-700
https://eaflood.atlassian.net/browse/FSR-702
https://eaflood.atlassian.net/browse/FSR-703
https://eaflood.atlassian.net/browse/FSR-728
https://eaflood.atlassian.net/browse/FSR-656
https://eaflood.atlassian.net/browse/FSR-693
https://eaflood.atlassian.net/browse/FSR-734

# Instructions

Straight forward application build for release

1 - Execute LFW_{STAGE}_02_UPDATE_DATABASE
2 - Execute LFW_{STAGE}_04_UPDATE_FLOOD_APP_AND_SERVICE_PIPELINE

Execute smoke tests and forward results
4 changes: 2 additions & 2 deletions server/config.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ const schema = joi.object({
siteUrl: joi.string().default(`http://localhost:${defaultPort}`),
floodRiskUrl: joi.string().default(`http://localhost:${defaultPort}`),
sessionPassword: joi.string(),
mockExternalHttp: joi.boolean().default(false),
fakeBingCall: joi.boolean().default(false),
floodFisUrl: joi.string().default(`http://localhost:${defaultPort}`),
localCache: joi.boolean().default(true),
redisHost: joi.string().default(''),
Expand Down Expand Up @@ -52,7 +52,7 @@ const config = {
siteUrl: process.env.FLOOD_APP_SITE_URL,
floodRiskUrl: process.env.FLOOD_RISK_URL,
sessionPassword: process.env.FLOOD_APP_SESSION_PASSWORD,
mockExternalHttp: process.env.FLOOD_APP_MOCK_EXTERNAL_HTTP,
fakeBingCall: process.env.FLOOD_APP_FAKE_BING_CALL,
floodFisUrl: process.env.FLOOD_APP_FIS_URL,
localCache: process.env.FLOOD_APP_LOCAL_CACHE,
redisHost: process.env.FLOOD_APP_REDIS_HOST,
Expand Down
10 changes: 8 additions & 2 deletions server/models/views/national.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,8 @@ class ViewModel {
const outlookOutOfDate = (now - issueDate) > hours48

Object.assign(this, {
outlookOutOfDate,
floodRiskUrl,
pageTitle: 'Check for flooding in England',
metaDescription:
'View current flood warnings and alerts for England and the national flood forecast for the next 5 days. Also check river, sea, groundwater and rainfall levels.',
Expand All @@ -30,8 +32,12 @@ class ViewModel {
outlookUTC: moment(outlook._timestampOutlook).tz(tz).format(),
dataError: outlook.dataError,
isDummyData: floods.isDummyData,
outlookOutOfDate,
floodRiskUrl
getWarnings: 'National:Related-content:Get-warnings',
planAhead: 'National:Related-content:Plan-ahead-for-flooding',
whatToDo: 'National:Related-content:What-to-do-in-a-flood',
recoverAfter: 'National:Related-content:Recover-after-a-flood',
longTerm: 'National:Related-content:Check-long-term-risk',
reportFlood: 'National:Related-content:Report-a-flood'
})

// Strip out flood array as it is superflous to the view
Expand Down
1 change: 1 addition & 0 deletions server/models/views/river-and-sea-levels.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ function emptyResultsModel (q) {
return {
q,
metaDescription,
floodRiskUrl,
pageTitle: formatTitle(q),
clientModel: getClientModel()
}
Expand Down
13 changes: 12 additions & 1 deletion server/models/views/station.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,17 @@ class ViewModel {

Object.assign(this, {
feedback: false,
bingMaps: config.bingKeyMaps
bingMaps: config.bingKeyMaps,
getWarnings: 'Station:Related-content:Get-warnings',
planAhead: 'Station:Related-content:Plan-ahead-for-flooding',
whatToDo: 'Station:Related-content:What-to-do-in-a-flood',
recoverAfter: 'Station:Related-content:Recover-after-a-flood',
longTerm: 'Station:Related-content:Check-long-term-risk',
reportFlood: 'Station:Related-content:Report-a-flood',
twitterEvent: 'Station:Share Page:Station - Share to Twitter',
facebookEvent: 'Station:Share Page:Station - Share to Facebook',
emailEvent: 'Station:Share Page:Station - Share to email',
floodRiskUrl: config.floodRiskUrl
})
// Group warnings/alerts by severity level

Expand Down Expand Up @@ -138,6 +148,7 @@ class ViewModel {

// Gets the latest value object
if (this.telemetry.length) {
this.telemetry = util.removeSpikes(this.telemetry)
this.readings = this.telemetry.length
this.recentValue = this.telemetry[0]
this.recentValueBelowZero = this.recentValue._ <= 0
Expand Down
6 changes: 3 additions & 3 deletions server/plugins/on-post-handler.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
// Plugin is to add some fields required by the service layout to route context object
const { siteUrl, mockExternalHttp } = require('../config')
const { siteUrl, fakeBingCall } = require('../config')
const floodService = require('../services/flood')

module.exports = {
Expand All @@ -22,7 +22,7 @@ module.exports = {
request.response.source.context.isDummyData = request.response.source.context.model && request.response.source.context.model.isDummyData
request.response.source.context.setCookieUsage = request.state.set_cookie_usage
request.response.source.context.seenCookieMessage = request.state.seen_cookie_message
request.response.source.context.isMockExternalHttp = mockExternalHttp
request.response.source.context.isfakeBingCall = fakeBingCall
if (request.response.source.context.model) {
request.response.source.context.model.referer = requestHeadersReferer
} else {
Expand All @@ -34,7 +34,7 @@ module.exports = {
request.response.source.context = {
fullUrl: encodeURI(fullUrl),
isDummyData: false,
isMockExternalHttp: floodService.mockExternalHttp,
fakeBingCall: floodService.fakeBingCall,
model: {
referer: requestHeadersReferer
}
Expand Down
7 changes: 5 additions & 2 deletions server/src/sass/components/_context-footer.scss
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
.defra-context-footer {
border-top:2px solid govuk-colour('blue');
@include govuk-responsive-margin(6, 'top');
@include govuk-responsive-padding(4, 'top');
margin-top: 30px;
padding-top: 10px;
@include mq ($from: tablet) {
margin-top: 40px;
}
}
3 changes: 2 additions & 1 deletion server/src/sass/components/_related-items.scss
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
.defra-related-items {
border-top: 2px solid govuk-colour("blue");
padding-top: govuk-spacing(3);
padding-top: govuk-spacing(2);
margin-top: 20px;
@include mq ($from: tablet) {
margin-top: 0px;
}
}

// Overides
.defra-related-items .govuk-list > li {
margin-bottom: govuk-spacing(2);
}
72 changes: 27 additions & 45 deletions server/src/sass/components/_social.scss
Original file line number Diff line number Diff line change
@@ -1,62 +1,44 @@
.defra-social {
list-style: none;
margin: 0px;
padding: 0px;
&__list {
list-style: none;
margin: 0px 0px 20px;
padding: 0px;
}
&__channel {
position:relative;
display: inline-block;
margin-right: 30px;
margin-right: 20px;
@include govuk-font($size: 16, $weight: bold);
height: 32px;
padding-left: 40px;
height: 30px;
padding-left: 36px;
margin-bottom: 10px;
}
&__link {
line-height: 32px;
line-height: 30px;
}
&__link:not(:hover) {
text-decoration: none
}
&__link:before {
content: '';
&__icon {
position: absolute;
top:0px;
left:0px;
width: 32px;
height: 32px;
background-color: transparent;
background-size: 32px;
background-repeat: no-repeat;
background-position: top left;
}
&__link--email:before {
background-image: svg-url('<svg width="32" height="32" viewBox="0 0 32 32"><path d="M31.008,0L0.994,0C0.45,0.004 0.004,0.45 0,0.994L0,31.008C0,31.558 0.452,32 0.994,32L31.008,32C31.55,31.998 31.998,31.55 32,31.008L32,0.994C31.998,0.45 31.55,0.002 31.008,0Z" style="fill:#1d70b8"/><rect x="9" y="11" width="14" height="10" style="fill:none;stroke:#fff;stroke-width:2px;"/><path d="M9,10.992L15.994,17L23,11" style="fill:none;stroke:#fff;stroke-width:2px;"/></svg>');
}
&__link--email:hover:before {
background-image: svg-url('<svg width="32" height="32" viewBox="0 0 32 32"><path d="M31.008,0L0.994,0C0.45,0.004 0.004,0.45 0,0.994L0,31.008C0,31.558 0.452,32 0.994,32L31.008,32C31.55,31.998 31.998,31.55 32,31.008L32,0.994C31.998,0.45 31.55,0.002 31.008,0Z" style="fill:#003078"/><rect x="9" y="11" width="14" height="10" style="fill:none;stroke:#fff;stroke-width:2px;"/><path d="M9,10.992L15.994,17L23,11" style="fill:none;stroke:#fff;stroke-width:2px;"/></svg>');
}
&__link--email:focus:before,
&__link--email:active:before {
background-image: svg-url('<svg width="32" height="32" viewBox="0 0 32 32"><path d="M31.008,0L0.994,0C0.45,0.004 0.004,0.45 0,0.994L0,31.008C0,31.558 0.452,32 0.994,32L31.008,32C31.55,31.998 31.998,31.55 32,31.008L32,0.994C31.998,0.45 31.55,0.002 31.008,0Z" style="fill:#0b0c0c"/><rect x="9" y="11" width="14" height="10" style="fill:none;stroke:#fff;stroke-width:2px;"/><path d="M9,10.992L15.994,17L23,11" style="fill:none;stroke:#fff;stroke-width:2px;"/></svg>');
}
&__link--twitter:before {
background-image: svg-url('<svg width="32" height="32" viewBox="0 0 32 32"><path d="M31.008,0L0.994,0C0.45,0.004 0.004,0.45 0,0.994L0,31.008C0,31.558 0.452,32 0.994,32L31.008,32C31.55,31.998 31.998,31.55 32,31.008L32,0.994C31.998,0.45 31.55,0.002 31.008,0Z" style="fill:#1d70b8"/><path d="M8,21.028C9.5,21.992 11.248,22.504 13.032,22.502C19.07,22.502 22.372,17.5 22.372,13.164C22.372,13.02 22.368,12.88 22.36,12.738C23.004,12.274 23.558,11.698 24,11.04C23.4,11.304 22.766,11.478 22.114,11.556C22.8,11.146 23.312,10.5 23.556,9.74C22.912,10.122 22.206,10.392 21.472,10.536C20.85,9.87 19.98,9.49 19.07,9.49C17.27,9.49 15.79,10.972 15.79,12.77C15.79,13.026 15.82,13.28 15.88,13.53C13.24,13.398 10.778,12.15 9.114,10.1C8.822,10.6 8.67,11.17 8.67,11.75C8.668,12.846 9.218,13.874 10.13,14.482C9.608,14.466 9.098,14.324 8.642,14.072L8.642,14.112C8.642,15.668 9.75,17.022 11.276,17.332C10.792,17.464 10.286,17.482 9.794,17.388C10.222,18.722 11.458,19.642 12.86,19.668C11.696,20.58 10.26,21.074 8.784,21.072C8.522,21.072 8.26,21.058 8,21.028Z" style="fill:#fff;fill-rule:nonzero;"/></svg>');
}
&__link--twitter:hover:before {
background-image: svg-url('<svg width="32" height="32" viewBox="0 0 32 32"><path d="M31.008,0L0.994,0C0.45,0.004 0.004,0.45 0,0.994L0,31.008C0,31.558 0.452,32 0.994,32L31.008,32C31.55,31.998 31.998,31.55 32,31.008L32,0.994C31.998,0.45 31.55,0.002 31.008,0Z" style="fill:#003078"/><path d="M8,21.028C9.5,21.992 11.248,22.504 13.032,22.502C19.07,22.502 22.372,17.5 22.372,13.164C22.372,13.02 22.368,12.88 22.36,12.738C23.004,12.274 23.558,11.698 24,11.04C23.4,11.304 22.766,11.478 22.114,11.556C22.8,11.146 23.312,10.5 23.556,9.74C22.912,10.122 22.206,10.392 21.472,10.536C20.85,9.87 19.98,9.49 19.07,9.49C17.27,9.49 15.79,10.972 15.79,12.77C15.79,13.026 15.82,13.28 15.88,13.53C13.24,13.398 10.778,12.15 9.114,10.1C8.822,10.6 8.67,11.17 8.67,11.75C8.668,12.846 9.218,13.874 10.13,14.482C9.608,14.466 9.098,14.324 8.642,14.072L8.642,14.112C8.642,15.668 9.75,17.022 11.276,17.332C10.792,17.464 10.286,17.482 9.794,17.388C10.222,18.722 11.458,19.642 12.86,19.668C11.696,20.58 10.26,21.074 8.784,21.072C8.522,21.072 8.26,21.058 8,21.028Z" style="fill:#fff;fill-rule:nonzero;"/></svg>');
}
&__link--twitter:focus:before,
&__link--twitter:active:before {
background-image: svg-url('<svg width="32" height="32" viewBox="0 0 32 32"><path d="M31.008,0L0.994,0C0.45,0.004 0.004,0.45 0,0.994L0,31.008C0,31.558 0.452,32 0.994,32L31.008,32C31.55,31.998 31.998,31.55 32,31.008L32,0.994C31.998,0.45 31.55,0.002 31.008,0Z" style="fill:#0b0c0c"/><path d="M8,21.028C9.5,21.992 11.248,22.504 13.032,22.502C19.07,22.502 22.372,17.5 22.372,13.164C22.372,13.02 22.368,12.88 22.36,12.738C23.004,12.274 23.558,11.698 24,11.04C23.4,11.304 22.766,11.478 22.114,11.556C22.8,11.146 23.312,10.5 23.556,9.74C22.912,10.122 22.206,10.392 21.472,10.536C20.85,9.87 19.98,9.49 19.07,9.49C17.27,9.49 15.79,10.972 15.79,12.77C15.79,13.026 15.82,13.28 15.88,13.53C13.24,13.398 10.778,12.15 9.114,10.1C8.822,10.6 8.67,11.17 8.67,11.75C8.668,12.846 9.218,13.874 10.13,14.482C9.608,14.466 9.098,14.324 8.642,14.072L8.642,14.112C8.642,15.668 9.75,17.022 11.276,17.332C10.792,17.464 10.286,17.482 9.794,17.388C10.222,18.722 11.458,19.642 12.86,19.668C11.696,20.58 10.26,21.074 8.784,21.072C8.522,21.072 8.26,21.058 8,21.028Z" style="fill:#fff;fill-rule:nonzero;"/></svg>');
}
&__link--facebook:before {
background-image: svg-url('<svg width="32" height="32" viewBox="0 0 32 32"><path d="M31.006,0L0.994,0C0.45,0.002 0.002,0.45 0,0.994L0,31.008C0,31.558 0.452,32 0.994,32L31.006,32C31.55,31.998 31.998,31.552 32,31.008L32,0.994C31.996,0.45 31.55,0.002 31.006,0Z" style="fill:#1d70b8"/><path d="M17.892,10.752L19.678,10.752L19.678,8.01L17.216,8C14.486,8 13.864,10.046 13.864,11.354L13.864,13.182L12.284,13.182L12.284,16.006L13.864,16.006L13.864,24L17.186,24L17.186,16.006L19.428,16.006L19.72,13.182L17.186,13.182L17.186,11.52C17.188,10.898 17.602,10.752 17.892,10.752Z" style="fill:#fff;fill-rule:nonzero;"/></svg>');
}
&__link--facebook:hover:before {
background-image: svg-url('<svg width="32" height="32" viewBox="0 0 32 32"><path d="M31.006,0L0.994,0C0.45,0.002 0.002,0.45 0,0.994L0,31.008C0,31.558 0.452,32 0.994,32L31.006,32C31.55,31.998 31.998,31.552 32,31.008L32,0.994C31.996,0.45 31.55,0.002 31.006,0Z" style="fill:#003078"/><path d="M17.892,10.752L19.678,10.752L19.678,8.01L17.216,8C14.486,8 13.864,10.046 13.864,11.354L13.864,13.182L12.284,13.182L12.284,16.006L13.864,16.006L13.864,24L17.186,24L17.186,16.006L19.428,16.006L19.72,13.182L17.186,13.182L17.186,11.52C17.188,10.898 17.602,10.752 17.892,10.752Z" style="fill:#fff;fill-rule:nonzero;"/></svg>');
}
&__link--facebook:focus:before,
&__link--facebook:active:before {
background-image: svg-url('<svg width="32" height="32" viewBox="0 0 32 32"><path d="M31.006,0L0.994,0C0.45,0.002 0.002,0.45 0,0.994L0,31.008C0,31.558 0.452,32 0.994,32L31.006,32C31.55,31.998 31.998,31.552 32,31.008L32,0.994C31.996,0.45 31.55,0.002 31.006,0Z" style="fill:#0b0c0c"/><path d="M17.892,10.752L19.678,10.752L19.678,8.01L17.216,8C14.486,8 13.864,10.046 13.864,11.354L13.864,13.182L12.284,13.182L12.284,16.006L13.864,16.006L13.864,24L17.186,24L17.186,16.006L19.428,16.006L19.72,13.182L17.186,13.182L17.186,11.52C17.188,10.898 17.602,10.752 17.892,10.752Z" style="fill:#fff;fill-rule:nonzero;"/></svg>');
width: 30px;
height: 30px;
background-color: govuk-colour('blue');
box-sizing: border-box;
border: 1px solid currentcolor;
color: white;
svg {
position: relative;
margin: -2px 0 0 -2px;
}
}
&__link:hover .defra-social__icon {
background-color: $govuk-link-hover-colour;
}
&__link:focus .defra-social__icon,
&__link:active .defra-social__icon {
background-color: govuk-colour('black');
}
}
8 changes: 7 additions & 1 deletion server/util.js
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,11 @@ function cleanseLocation (location) {
}
}

function removeSpikes (data) {
const maxVal = 400
return data.filter(el => el._ < maxVal)
}

function addBufferToBbox (bbox, m) {
// Convert bbox (binding box) )into polygon, add buffer, and convert back to bbox as db query needs a bbox envelope
return turf.bbox(turf.buffer(turf.bboxPolygon(bbox), m, { units: 'meters' }))
Expand Down Expand Up @@ -146,5 +151,6 @@ module.exports = {
dateDiff,
formatRainfallTelemetry,
rainfallTelemetryPadOut,
ALLOWED_SEARCH_CHARS
ALLOWED_SEARCH_CHARS,
removeSpikes
}
38 changes: 1 addition & 37 deletions server/views/national.html
Original file line number Diff line number Diff line change
Expand Up @@ -87,43 +87,7 @@ <h2 class="defra-service-error__title" id="error-summary-title">Sorry, there is


<div class="govuk-grid-column-one-third">
<div class="defra-related-items">
<h2 class="govuk-heading-s" id="subsection-title">
Related content
</h2>
<nav role="navigation" aria-labelledby="subsection-title">
<ul class="govuk-list govuk-!-font-size-16">
<li>
<a data-journey-click="National:Related-content:Get-warnings" href="https://www.gov.uk/sign-up-for-flood-warnings">Get flood warnings by phone, text or email</a>
</li>
<li>
<a data-journey-click="National:Related-content:Plan-ahead-for-flooding" class="govuk-link" href="/plan-ahead-for-flooding">
How to plan ahead for flooding
</a>
</li>
<li>
<a data-journey-click="National:Related-content:What-to-do-in-a-flood" class="govuk-link" href="/what-to-do-in-a-flood">
What to do in a flood
</a>
</li>
<li>
<a data-journey-click="National:Related-content:Recover-after-a-flood" class="govuk-link" href="/recovering-after-a-flood">
How to recover after a flood
</a>
</li>
<li>
<a data-journey-click="National:Related-content:Check-long-term-risk" class="govuk-link" href={{model.floodRiskUrl}}>
Check your long term flood risk
</a>
<li>
<a data-journey-click="National:Related-content:Report-a-flood" class="govuk-link" href="https://www.gov.uk/report-flood-cause">
Report a flood
</a>
</li>
</ul>
</nav>
</div>
</div>
{% include "partials/related-content.html" %}
</div>

{% endblock %}
Expand Down
5 changes: 5 additions & 0 deletions server/views/partials/related-content.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,11 @@ <h2 class="govuk-heading-s" id="subsection-title">
</h2>
<nav role="navigation" aria-labelledby="subsection-title">
<ul class="govuk-list govuk-!-font-size-16">
{% if model.getWarnings %}
<li>
<a data-journey-click="{% if model.getWarnings %}{{ model.getWarnings }}{% endif %}" href="https://www.gov.uk/sign-up-for-flood-warnings">Get flood warnings by phone, text or email</a>
</li>
{% endif %}
<li>
<a data-journey-click="{% if model.planAhead %}{{ model.planAhead }}{% endif %}" class="govuk-link" href="/plan-ahead-for-flooding">
How to plan ahead for flooding
Expand Down
Loading

0 comments on commit 6b9065d

Please sign in to comment.