From d1becbe1e32e777544de534052b6d458651dbc6b Mon Sep 17 00:00:00 2001 From: Chris Hill-Scott Date: Wed, 16 Mar 2016 11:01:19 +0000 Subject: [PATCH 1/3] Add cookie banner text, page, and footer links MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit > Let’s start the footer links with the cookie page. > Banner to say: "GOV.UK Notify uses cookies to make the site simpler. Find out > more about cookies" > Standard style one... see > https://www.registertovote.service.gov.uk/register-to-vote/cookies or > https://www.digitalmarketplace.service.gov.uk/cookies > > Let's link to the feedback form too... > https://docs.google.com/forms/d/1AL8U-xJX_HAFEiQiJszGQw0PcEaEUnYATSntEghNDGo/viewform > Call it Support and feedback https://www.pivotaltracker.com/story/show/115483375 --- app/assets/stylesheets/_grids.scss | 16 +++++ app/assets/stylesheets/app.scss | 8 +++ app/main/views/index.py | 5 ++ app/templates/admin_template.html | 12 ++++ app/templates/views/cookies.html | 81 ++++++++++++++++++++++ tests/app/main/views/test_accept_invite.py | 2 +- 6 files changed, 123 insertions(+), 1 deletion(-) create mode 100644 app/templates/views/cookies.html diff --git a/app/assets/stylesheets/_grids.scss b/app/assets/stylesheets/_grids.scss index ec083e809..f0008d51e 100644 --- a/app/assets/stylesheets/_grids.scss +++ b/app/assets/stylesheets/_grids.scss @@ -30,3 +30,19 @@ padding-left: 2px; padding-right: 2px; } + +.global-cookie-message { + p { + @extend %site-width-container; + } +} + +.footer-nav { + @include copy-16; + margin-bottom: $gutter-two-thirds; + + a { + display: inline-block; + margin-right: $gutter-half; + } +} diff --git a/app/assets/stylesheets/app.scss b/app/assets/stylesheets/app.scss index d7eeacb62..d2d7fb838 100644 --- a/app/assets/stylesheets/app.scss +++ b/app/assets/stylesheets/app.scss @@ -80,3 +80,11 @@ a { } } + +td { + vertical-align: top; +} + +.heading-xlarge { + margin-bottom: 20px; +} diff --git a/app/main/views/index.py b/app/main/views/index.py index 5f7d700df..a37968740 100644 --- a/app/main/views/index.py +++ b/app/main/views/index.py @@ -16,3 +16,8 @@ def index(): @login_required def verify_mobile(): return render_template('views/verify-mobile.html') + + +@main.route('/cookies') +def cookies(): + return render_template('views/cookies.html') diff --git a/app/templates/admin_template.html b/app/templates/admin_template.html index bd1eba398..846ee2a91 100644 --- a/app/templates/admin_template.html +++ b/app/templates/admin_template.html @@ -24,6 +24,10 @@ {% endblock %} {% block cookie_message %} +

+ GOV.UK Notify uses cookies to make the site simpler. + Find out more about cookies +

{% endblock %} {% block inside_header %} @@ -68,6 +72,14 @@ {% endblock %} +{% block footer_support_links %} + +{% endblock %} + {% block body_end %} {% endblock %} diff --git a/app/templates/views/cookies.html b/app/templates/views/cookies.html new file mode 100644 index 000000000..6337c1f77 --- /dev/null +++ b/app/templates/views/cookies.html @@ -0,0 +1,81 @@ +{% extends "withoutnav_template.html" %} + +{% block page_title %} + Cookies – GOV.UK Notify +{% endblock %} + +{% block maincolumn_content %} + +
+
+

Cookies

+

+ GOV.UK Notify puts small files (known as ‘cookies’) + on to your computer. +

+

These cookies are used to remember you once you’ve logged in

+

+ Find out how to manage cookies. +

+ +

Session cookies

+

+ We store session cookies on your computer to help keep your information + secure while you use the service. +

+ + + + + + + + + + + + + + + +
NamePurposeExpires
+ notify_admin_session + + Used to keep you logged in + + 1 hour +
+ +

Introductory message cookie

+

+ When you first use the service, you may see a pop-up ‘welcome’ message. + Once you’ve seen the message, we store a cookie on your computer so it + knows not to show it again. +

+ + + + + + + + + + + + + + + +
NamePurposeExpires
+ seen_cookie_message + + Saves a message to let us know that you have seen our cookie + message + + 1 month +
+
+
+ +{% endblock %} diff --git a/tests/app/main/views/test_accept_invite.py b/tests/app/main/views/test_accept_invite.py index 2cf6f3198..cb2133f38 100644 --- a/tests/app/main/views/test_accept_invite.py +++ b/tests/app/main/views/test_accept_invite.py @@ -175,7 +175,7 @@ def test_new_user_accept_invite_calls_api_and_views_registration_page(app_, page = BeautifulSoup(response.data.decode('utf-8'), 'html.parser') assert page.h1.string.strip() == 'Create an account' - email_in_page = page.find('p') + email_in_page = page.find('main').find('p') assert email_in_page.text.strip() == 'Your account will be created with this email: invited_user@test.gov.uk' # noqa form = page.find('form') From 774ac17ee97eca8e8d7242855b4db974b562494d Mon Sep 17 00:00:00 2001 From: Chris Hill-Scott Date: Thu, 17 Mar 2016 13:44:33 +0000 Subject: [PATCH 2/3] Add a help page that explains trial mode > We start in trial mode and there are a bunch of things that we need to know, so > let's explain this with a page, accessed from the footer. Not requiring log in. > Should explain: > 50 messages per day > Can only send to yourself or team members > How to go live > We can then link to this from the dashboard (and any other place) where we > tell you that you're in trial mode. https://www.pivotaltracker.com/story/show/115775751 --- app/main/views/index.py | 5 ++ app/templates/admin_template.html | 1 + app/templates/views/help.html | 79 +++++++++++++++++++++++++++++++ 3 files changed, 85 insertions(+) create mode 100644 app/templates/views/help.html diff --git a/app/main/views/index.py b/app/main/views/index.py index a37968740..47780a1e7 100644 --- a/app/main/views/index.py +++ b/app/main/views/index.py @@ -21,3 +21,8 @@ def verify_mobile(): @main.route('/cookies') def cookies(): return render_template('views/cookies.html') + + +@main.route('/help') +def help(): + return render_template('views/help.html') diff --git a/app/templates/admin_template.html b/app/templates/admin_template.html index 846ee2a91..666add0bb 100644 --- a/app/templates/admin_template.html +++ b/app/templates/admin_template.html @@ -74,6 +74,7 @@ {% block footer_support_links %}