Commit Graph

8 Commits

Author SHA1 Message Date
Chris Hill-Scott
558ae87baa Hide ‘back to …’ link if it’s not your service
This can happen if you click a link for a service you don’t have access
to. We shouldn’t show the back to service link in this case because:
- you shouldn’t be able to find out the service’s name from just knowing
  the link
- if you click the link you only get a `403` anyway
2019-01-15 17:31:55 +00:00
Chris Hill-Scott
f9421789d0 Only show ‘back to service name’ link if signed in
When you’re not signed in you can still have a service in your session.
But there’s no point trying to get to its dashboard until you’re signed
in – you’ll just be sent back to the ‘sign in’ page.
2018-05-09 15:32:46 +01:00
Leo Hemsted
2f37e37278 rename choose_service to choose_account 2018-03-14 15:39:55 +00:00
Chris Hill-Scott
f2d0f75fce Only show back to service link if you have service
It doesn’t make sense to show the back to service link if, for example,
you are in the onboarding flow and haven’t created a service yet.
2017-03-15 14:26:04 +00:00
Chris Hill-Scott
51d736178c Add back to service link
When we moved the ‘Switch service’ link out of the nav on non-service
pages it removed any obvious way of getting back to your service on a
page that doesn’t have the service navigation (the non-obvious way is to
click ‘GOV.UK Notify’ in the black bar).

So this commit adds a ‘Back to service’ link which does the same thing
as clicking ‘GOV.UK Notify’ (tries to send you to your last-used
service, sends you to the list of services if it can’t).
2017-03-14 14:51:28 +00:00
Chris Hill-Scott
397ad05db9 Make a full width base template
We need this because the top section of the new product page will be
going full-bleed.
2016-12-07 16:14:30 +00:00
Chris Hill-Scott
8e607debd4 Use <main> element in semantically appropriate way
Assistive technologies use the `<main>` element to navigate around a document.
In `<main>` their users expect to find:

> [content] unique to the document, excluding any content that is
> repeated across a set of documents such as sidebars, navigation links,
> copyright information, site logos, and search forms…
— https://developer.mozilla.org/en/docs/Web/HTML/Element/main

Previously, the `<main>` element also wrapped the sidebar navigation. This
commit moves the `<main>` element to only wrap the content of the page when the
page has a navigation sidebar.

This commit also removes the `page-container` class which wasn’t being used for
anything.
2016-02-10 12:33:11 +00:00
Chris Hill-Scott
2ef1057180 Make spacing and position of banners consistent
Banners should always be the first thing on the page.

Because headers already have padding we don’t want to put padding on the
container.

So banners should also have top padding to distance then from the red bar.

They should also sit in the 3/4 column if the page has side navigation. This
commit adds a new template (`withoutnav_template.html`) which extends
`admin_template.html`. All views then extend one or the other, never the
`admin_template.html` directly. This means that `admin_template.html` doesn’t
have to make decisions about where the flash messages are displayed.
2016-02-01 13:52:46 +00:00