-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Map 178 uof new header and footer (#646)
* MAP-178 implement new DPS header and footers * MAP-178 remove get help (/get-help) page as new footer has phone number for app support already * MAP-178 remove remaining remnants of feedback banner * MAP-178 fix dps link in fallback header and css 1. reverted css relating to contenr width because the Use of force reports' page needs a greater width to accommodate 4 tabs and a link. Have made the new headers the same width. 2. reverted crossOriginEmbedderPolicy to false as otherwise the date widget will not work. 3. Defined the digitalPrisonServiceUrldp var in nunjucks setup so that it could be accessed by the fallback header * Map-178 lint fix
- Loading branch information
1 parent
9c484db
commit 40dc910
Showing
41 changed files
with
587 additions
and
335 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
.govuk-footer { | ||
min-height: 160px; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,127 @@ | ||
.hmpps-header { | ||
@include govuk-responsive-padding(3, 'top'); | ||
@include govuk-responsive-padding(3, 'bottom'); | ||
background-color: govuk-colour('black'); | ||
color: govuk-colour('white'); | ||
|
||
&__container { | ||
@include govuk-width-container; | ||
display: flex; | ||
justify-content: space-between; | ||
align-items: center; | ||
} | ||
|
||
&__logo { | ||
@include govuk-responsive-margin(2, 'right'); | ||
position: relative; | ||
top: -2px; | ||
fill: govuk-colour('white'); | ||
} | ||
|
||
&__title { | ||
@include govuk-responsive-padding(3, 'right'); | ||
display: flex; | ||
align-items: center; | ||
|
||
&__organisation-name { | ||
@include govuk-responsive-margin(2, 'right'); | ||
@include govuk-font($size: 24, $weight: 'bold'); | ||
display: flex; | ||
align-items: center; | ||
} | ||
|
||
&__service-name { | ||
@include govuk-responsive-margin(2, 'right'); | ||
@include govuk-font(24); | ||
display: none; | ||
|
||
@include govuk-media-query($from: desktop) { | ||
display: flex; | ||
align-items: center; | ||
} | ||
} | ||
} | ||
|
||
&__link { | ||
@include govuk-link-common; | ||
@include govuk-link-style-default; | ||
|
||
text-underline-offset: 0.1em; | ||
|
||
&:link, | ||
&:visited, | ||
&:active { | ||
color: govuk-colour('white'); | ||
text-decoration: none; | ||
} | ||
|
||
&:hover { | ||
text-decoration: underline; | ||
} | ||
|
||
&:focus { | ||
color: govuk-colour('black'); | ||
|
||
svg { | ||
fill: govuk-colour('black'); | ||
} | ||
} | ||
|
||
&__sub-text { | ||
@include govuk-font(16); | ||
display: none; | ||
|
||
@include govuk-media-query($from: tablet) { | ||
display: block; | ||
} | ||
} | ||
} | ||
|
||
&__navigation { | ||
display: flex; | ||
flex-direction: column; | ||
align-items: flex-end; | ||
list-style: none; | ||
margin: 0; | ||
padding: 0; | ||
|
||
@include govuk-media-query($from: tablet) { | ||
flex-direction: row; | ||
align-items: center; | ||
} | ||
|
||
&__item { | ||
@include govuk-font(19); | ||
margin-bottom: govuk-spacing(1); | ||
text-align: right; | ||
|
||
@include govuk-media-query($from: tablet) { | ||
@include govuk-responsive-margin(4, 'right'); | ||
@include govuk-responsive-padding(4, 'right'); | ||
margin-bottom: 0; | ||
border-right: 1px solid govuk-colour('white'); | ||
} | ||
|
||
a { | ||
display: inline-block; | ||
} | ||
|
||
&:last-child { | ||
margin-right: 0; | ||
border-right: 0; | ||
padding-right: 0; | ||
} | ||
|
||
} | ||
} | ||
|
||
@media print { | ||
display: none; | ||
} | ||
} | ||
|
||
.govuk-phase-banner { | ||
@include govuk-width-container; | ||
border: none; | ||
} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
const { offender } = require('../mockApis/data') | ||
const ReportUseOfForcePage = require('../pages/createReport/reportUseOfForcePage') | ||
|
||
context('Report use of force page', () => { | ||
beforeEach(() => { | ||
cy.task('reset') | ||
cy.task('stubLogin', { firstName: 'James', lastName: 'Stuart' }) | ||
cy.task('stubOffenderDetails', offender) | ||
}) | ||
|
||
it('New components should exist', () => { | ||
cy.task('stubComponents') | ||
cy.login() | ||
|
||
const page = ReportUseOfForcePage.visit(offender.bookingId) | ||
page.commonComponentsHeader().should('exist') | ||
page.commonComponentsFooter().should('exist') | ||
}) | ||
|
||
it('New components should not exist', () => { | ||
cy.task('stubComponentsFail') | ||
cy.login() | ||
|
||
const page = ReportUseOfForcePage.visit(offender.bookingId) | ||
page.commonComponentsHeader().should('not.exist') | ||
page.commonComponentsFooter().should('not.exist') | ||
page.fallbackHeaderUserName().contains('J. Stuart') | ||
}) | ||
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.