Commit Graph

33 Commits

Author SHA1 Message Date
Beverly Nguyen
e9b9072ae6 updated datetimes based on style guide 2024-03-18 15:10:26 -07:00
Jonathan Bobel
b1c6a768ec Committing before merge 2023-08-30 11:07:38 -04:00
Jonathan Bobel
a4fc40bcba Renamed components folder, put failing tests back in to get some assistance with those 2023-08-22 12:40:53 -04:00
Jonathan Bobel
348e29fb40 - Removed links to the gov uk stylesheets
- Deleted /stylesheets folder
- Removed sass build from gulpfile
- Changed gov links to usa links
- Changed other govuk styles, like breadcrumbs
- Changed name of uk_components file to us_components
- Fixed a few tests that broke on account of the changes
2023-08-08 16:19:17 -04:00
Jonathan Bobel
f266084ddb Test passed, good time to commit 2023-06-16 14:55:24 -04:00
stvnrlly
ac1d5f0983 move vendored uk components to templates 2022-12-14 11:55:21 -05:00
Katie Smith
0f0b8b8ae4 Move back link outside of main where it was used in the page header
The page_header macro includes an optional back link. Since the
page_header is always used inside `<main>`, where the back link should
not be, this stops setting the back link in the page header and instead
sets it in the new `backLink` block.
2021-08-03 11:28:15 +01:00
Chris Hill-Scott
a27dbd24a7 Fix the ‘revoke’ links on the API keys page
They were missing the `govuk-link--destructive` class which turns them
red, consistent with other links we use for deleting or suspending
things.
2021-03-03 15:24:38 +00:00
Katie Smith
6512b8fad3 Add descriptive links to API keys page
The links had no descriptive text, so all read 'Revoke'. This adds
hidden text specific to the item they relate to.
2021-02-24 14:36:21 +00:00
Chris Hill-Scott
c31264d4c9 Rename ‘whitelist’ to ‘guest list’ in UI
This commit changes all the places where a user would see the term
‘whitelist’ in the content of page to say guestlist instead.

We’re removing the term ‘whitelist’ for two reasons. The first reason
is that we agree with the National Cyber Security Centre say:

> It's fairly common to say whitelisting and blacklisting to describe
> desirable and undesirable things in cyber security. For instance, when
> talking about which applications you will allow or deny on your
> corporate network; or deciding which bad passwords you want your users
> not to be able to use.

> However, there's an issue with the terminology. It only makes sense if
> you equate white with 'good, permitted, safe' and black with 'bad,
> dangerous, forbidden'. There are some obvious problems with this. So
> in the name of helping to stamp out racism in cyber security, we will
> avoid this casually pejorative wording on our website in the future.
> No, it's not the biggest issue in the world - but to borrow a slogan
> from elsewhere: every little helps.

– https://www.ncsc.gov.uk/blog-post/terminology-its-not-black-and-white

The second reason is that we’ve observed some users think that they have
to put recipients in the whitelist even when they’re already with in the
team. We think that the term ‘whitelist’ might be reinforcing this
mental model because of how ‘whitelists’ might work in other
applications.

We considered the following alternatives or concepts:
- Development
- Recipients
- Sandbox
- Extended team
- Smoke test recipients
- Allowed
- Nominated
- Bonus
- Additional
- Safe
- Team list
- Trusted contacts
- Designated people
- Guest list
- Team key list

We also considered not giving it a name, and explaining it as a nuance
of how the team key works. After mocking this up it felt more disjoined.
We think it’s still useful for the thing to have a name so that it’s
easy to refer to between the docs and the UI.

We like the term ‘guest list’ because:
- of how it sits with team members – members and guests in the abstract
- a guest list is a concept that a lot of people will be familiar with
  – a list of people who can access a thing
- ‘guest’ is very different to ‘recipient’ – we want to mitigate any
  confusion between this and the (emergency) contact lists
2020-06-12 09:56:31 +01:00
Tom Byers
ee9f348ce4 Update all links to use GOVUK Frontend style
Includes:
- turning off :visited styles to match existing
  design
- swapping heading classes used to make links bold
  for the GOVUK Frontend bold override class
- adding visually hidden text to some links to
  make them work when isolated from their context

We may need to revisit whether some links, such as
those for documentation and features, may benefit
from having some indication that their target has
been visited.
2020-02-25 10:47:24 +00:00
Tom Byers
5b306dde4d Revert "Convert all links to govuk frontend" 2020-02-24 11:56:38 +00:00
Tom Byers
cd36182ea6 Update all links to use GOVUK Frontend style
Includes:
- turning off :visited styles to match existing
  design
- swapping heading classes used to make links bold
  for the GOVUK Frontend bold override class
- adding visually hidden text to some links to
  make them work when isolated from their context

We may need to revisit whether some links, such as
those for documentation and features, may benefit
from having some indication that their target has
been visited.
2020-02-20 09:11:26 +00:00
Katie Smith
f3bb93f460 Replace straightforward buttons and links styled like buttons
This replaces the buttons that aren't part of a macro and that we don't
need to write additional styles for with their govuk-frontend equivalent.

There were some links that were styled to look like buttons, so these
have also been replaced with the new govuk-frontend macro.

There was one button on the `choose-account.html` template that was in a
section of code that was never reached - this has been deleted.
2020-02-17 08:05:05 +00:00
karlchillmaid
bb1ad89357 Replace haven't with have not 2019-09-23 13:22:27 +01:00
Chris Hill-Scott
74fb30ce5f Add GOV.UK Design System style back links
The Design System has standardised on back links being at the top of the
page, decorated with a small text-coloured arrow.

I think this makes more sense than having them at the bottom, because it
suggests, in some way, being able to go back before commiting to any of
the forms on the page. Whereas the things at the bottom of the page
should be performing actions on what’s in the page.

The reason for making this change now is that it de-clutters the area
around the green buttons. This was presenting a design challenge where
multiple levels of interaction were happening in the same form. Moving
these back links to the top of the page should mean that, in these
complicated forms, there’s one fewer thing to compete for the user’s
attention.

I’ve componentised this into a `page_header` macro so that the change is
easier to roll out and maintain.
2019-04-30 15:29:39 +01:00
Chris Hill-Scott
afdc749e36 Make ‘Add new’ buttons sticky on more pages
For consistency with the template management page.
2019-02-01 14:25:35 +00:00
Pea Tyczynska
a43e6a8885 Make deletion confirmation banner messages consistent across our app
Also introduce a way to provide context to a banner / flash message
that will be displayed in plain font style.
2018-11-16 11:05:52 +00:00
Chris Hill-Scott
d1c9dcfb1d Put API keys on service model
Similar to how we put templates on the service model, it means less
logic needs to happen in the view code.
2018-11-12 16:11:13 +00:00
Chris Hill-Scott
9aa4a7267a Use <button> not <input>s for form submission
Both `<button type='submit'>Submit<button>` and
`<input type='submit' value='Submit'>` can be used to submit a form.

We have historically[1] used `<input>` because it’s better-supported by
IE6 in that:
- the `submit` attribute is mandatory on `<button>`, not on `<input>`
- the `innerHTML` of a button will be submitted to the server, not the
  value (as in other browsers)

Reasons to now use `<button>` instead:
- IE6/7 support is no longer a concern (especially with deprecation of
  TLS 1.0 on the way)
- Because an `<input>` element can’t have children, the pseudo-element
  hack[2] used to ensure the top edge of the button is clickable doesn’t
  work. We’re seeing this bug[3] affect real users in research.

1. We inhereted our buttons from Digital Marketplace, here is me making
   that change in their code:  8df7e2e79e (diff-b1420f7b7a25657d849edf90a70ef541)
2. 24e1906c0d (diff-ef0e4eb6f1e90b44b0c3fe39dce274a4R79)

3. https://github.com/alphagov/govuk_elements/issues/545
2018-02-01 13:53:45 +00:00
Chris Hill-Scott
e2bd2e0439 Ensure only one <h1> per page, even with errors
A page should have only one `<h1>` element. So if there’s an error
message, which contains a `<h1>`, it should replace the page’s normal
`<h1>` element, rather than sit above it.
2017-07-27 11:52:54 +01:00
Chris Hill-Scott
40e79c6827 Use confirmation banner for revoking API keys
Currently revoking an API key takes you to a separate page. It should
work the same way as other destructive actions, ie staying on the same
page but with a banner asking you to confirm the action.
2017-07-27 11:52:54 +01:00
Chris Hill-Scott
8a4c8526fa Use 19px not 16px type in more places
Making the navigation narrower means that we have more space on every
page. So on pages where we had to use 16px type just to fit stuff on the
page we can now bump the type size up to something less miserly. This is
mainly the team and settings pages.

We still need to use 16px on pages which list notifications or previews
of spreadsheets, because we’re still trying to fit a lot of information
onto these pages, so every little space-saving helps.
2017-03-20 11:59:12 +00:00
Chris Hill-Scott
135ff1ee77 Include service name in page <title>
In pages specific to a service (e.g. dashboard and sub pages) the title
needs to distinguish which service it applies to. This is mainly to give
context to screen reader users who could be managing multiple services.

Implementing this uses template inheritance:

`page_title` includes `per_page_title` includes `service_page_title`

‘GOV.UK Notify’ is inserted into every page title.

Pages that set `service_page_title` get the service name inserted too.
2017-02-14 11:53:53 +00:00
Pete Herlihy
97a4975985 Stopped hiding the label that showed if a key was a live key
Happy to be overruled by @quis on this one....
2017-02-02 13:01:15 +00:00
Pete Herlihy
4040429f41 Updated API key type hint text on list of keys page 2017-02-02 12:52:11 +00:00
Chris Hill-Scott
4ae28386a6 Always show live key, reword key labels
This is trying to resolve these confusions:

- that you’re in trial mode, which means you can’t have a live key yet (
  or you can but it wont work, which is what we used to have)
- what does simulate mean

The create key page is the right place to resolve these confusions
because it’s where users are actively reading.

This commit also removes the trial mode banner from API integration
page because this where users _aren’t_ actively reading. A whole bunch
of users weren’t seeing this banner at all.

The implementation of the disabled API key options is kinda clunky
because WTForms doesn’t have a native way of doing this.

¯\_(ツ)_/¯
2016-11-04 14:05:30 +00:00
Chris Hill-Scott
6946d3af54 Make API key combination of secret and service ID
In research we’ve seen people mix up the service ID and API key because
they’re both 36 character UUIDs. We can’t get rid of the service ID
because it’s used to look up the API key.

Instead, we should change API key to be one long string, which contains
both the service ID, API key and (optionally) the name of the key. For
example:

```
casework_production-8b3aa916-ec82-434e-b0c5-d5d9b371d6a3-dcdc5083-2fee-4fba-8afd-51f3f4bcb7b0
```

We still need to keep the old, separate, key and service ID for a while
until people have updated their clients. But they’re now both on this
page, rather than on two separate pages, which should make for less
fussing anyway.

This shouldn’t be rolled out until the new clients are available.

- [ ] https://github.com/alphagov/notifications-python-client/pull/36
- [ ] https://github.com/alphagov/notifications-node-client/pull/10
- [ ] https://github.com/alphagov/notifications-ruby-client/pull/15
- [ ] https://github.com/alphagov/notifications-java-client/pull/38
- [ ] PHP????
2016-10-18 12:21:00 +01:00
Chris Hill-Scott
4ddc99781f Make revoked message in API keys table lighter
It’s secondary information so works better in the secondary text colour.
2016-10-18 11:57:46 +01:00
Chris Hill-Scott
73469c1067 Make whitelist available to live services
Why would a live servie need the whitelist? Because the team key will
also let you send to members of your whitelist (so this commit relabels
it to say so).
2016-10-07 15:01:49 +01:00
Chris Hill-Scott
70a9582c91 Make ‘add new’ button line up with <h1>
Having changed the layout of the API keys page a bit the vertical
misalignment was apparent.
2016-09-28 17:00:45 +01:00
Chris Hill-Scott
d9cc936972 Add an index page for the API integration
This commit adds a placeholder page which, for now, just has links to
the API keys page and links to the clients.

There’s more stuff to come on this page, but this commit just does the
reorganising so that it’s easier to review.
2016-09-28 17:00:45 +01:00
Chris Hill-Scott
c22eb0f081 Reorganise templates for API keys page
This adds another layer of folder structure to the templates to match
the new URLs, which have another layer of hierarchy.
2016-09-28 17:00:44 +01:00